@bundle-stats/ui 3.2.5-beta.1 → 3.2.6-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (74) hide show
  1. package/CHANGELOG.md +28 -3
  2. package/lib/app/app.module.css +7 -0
  3. package/lib/components/bundle-assets/bundle-assets.js +15 -7
  4. package/lib/components/bundle-assets/bundle-assets.module.css +13 -26
  5. package/lib/components/bundle-packages/bundle-packages.js +8 -4
  6. package/lib/components/bundle-packages/bundle-packages.module.css +4 -12
  7. package/lib/components/delta/delta.module.css +1 -0
  8. package/lib/components/metrics-table-search/metrics-table-search.module.css +5 -4
  9. package/lib/css/default.css +14 -3
  10. package/lib/css/variables.css +18 -18
  11. package/lib/layout/box/box.module.css +9 -0
  12. package/lib/layout/index.js +8 -0
  13. package/lib/layout/separator.js +48 -0
  14. package/lib/layout/separator.module.css +5 -0
  15. package/lib/ui/dropdown/dropdown.js +1 -2
  16. package/lib/ui/dropdown/dropdown.module.css +7 -8
  17. package/lib/ui/filters/filters.js +10 -5
  18. package/lib/ui/filters/filters.module.css +10 -0
  19. package/lib/ui/index.js +8 -0
  20. package/lib/ui/table/table.module.css +0 -4
  21. package/lib/ui/tag/index.js +18 -0
  22. package/lib/ui/tag/tag.js +72 -0
  23. package/lib/ui/tag/tag.module.css +55 -0
  24. package/lib/ui/tag/tag.stories.js +38 -0
  25. package/lib/ui/tooltip/tooltip.module.css +1 -1
  26. package/lib-esm/app/app.module.css +7 -0
  27. package/lib-esm/components/bundle-assets/bundle-assets.js +14 -7
  28. package/lib-esm/components/bundle-assets/bundle-assets.module.css +13 -26
  29. package/lib-esm/components/bundle-packages/bundle-packages.js +7 -4
  30. package/lib-esm/components/bundle-packages/bundle-packages.module.css +4 -12
  31. package/lib-esm/components/delta/delta.module.css +1 -0
  32. package/lib-esm/components/metrics-table-search/metrics-table-search.module.css +5 -4
  33. package/lib-esm/css/default.css +14 -3
  34. package/lib-esm/css/variables.css +18 -18
  35. package/lib-esm/layout/box/box.module.css +9 -0
  36. package/lib-esm/layout/index.js +1 -0
  37. package/lib-esm/layout/separator.js +28 -0
  38. package/lib-esm/layout/separator.module.css +5 -0
  39. package/lib-esm/ui/dropdown/dropdown.js +1 -2
  40. package/lib-esm/ui/dropdown/dropdown.module.css +7 -8
  41. package/lib-esm/ui/filters/filters.js +9 -4
  42. package/lib-esm/ui/filters/filters.module.css +10 -0
  43. package/lib-esm/ui/index.js +1 -0
  44. package/lib-esm/ui/table/table.module.css +0 -4
  45. package/lib-esm/ui/tag/index.js +1 -0
  46. package/lib-esm/ui/tag/tag.js +45 -0
  47. package/lib-esm/ui/tag/tag.module.css +55 -0
  48. package/lib-esm/ui/tag/tag.stories.js +23 -0
  49. package/lib-esm/ui/tooltip/tooltip.module.css +1 -1
  50. package/package.json +17 -16
  51. package/src/app/app.jsx +6 -2
  52. package/src/app/app.module.css +7 -0
  53. package/src/components/bundle-assets/bundle-assets.jsx +58 -41
  54. package/src/components/bundle-assets/bundle-assets.module.css +13 -26
  55. package/src/components/bundle-packages/bundle-packages.jsx +10 -5
  56. package/src/components/bundle-packages/bundle-packages.module.css +4 -12
  57. package/src/components/delta/delta.module.css +1 -0
  58. package/src/components/metrics-table-search/metrics-table-search.module.css +5 -4
  59. package/src/css/default.css +14 -3
  60. package/src/css/variables.css +18 -18
  61. package/src/layout/box/box.module.css +9 -0
  62. package/src/layout/index.js +1 -0
  63. package/src/layout/separator.jsx +25 -0
  64. package/src/layout/separator.module.css +5 -0
  65. package/src/ui/dropdown/dropdown.jsx +4 -6
  66. package/src/ui/dropdown/dropdown.module.css +7 -8
  67. package/src/ui/filters/filters.jsx +53 -50
  68. package/src/ui/filters/filters.module.css +10 -0
  69. package/src/ui/index.js +1 -0
  70. package/src/ui/table/table.module.css +0 -4
  71. package/src/ui/tag/index.js +1 -0
  72. package/src/ui/tag/tag.jsx +49 -0
  73. package/src/ui/tag/tag.module.css +55 -0
  74. package/src/ui/tooltip/tooltip.module.css +1 -1
@@ -13,10 +13,6 @@
13
13
  text-align: left;
14
14
  }
15
15
 
16
- tr:last-child .cell {
17
- border-bottom-width: 1px;
18
- }
19
-
20
16
  .root thead .cell {
21
17
  border-width: 0 0 2px;
22
18
  text-transform: uppercase;
@@ -0,0 +1 @@
1
+ export * from './tag';
@@ -0,0 +1,45 @@
1
+ function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
+
3
+ import React from 'react';
4
+ import PropTypes from 'prop-types';
5
+ import cx from 'classnames';
6
+ import css from './tag.module.css';
7
+ export const KINDS = {
8
+ DEFAULT: 'default',
9
+ SUCCESS: 'success',
10
+ INFO: 'info',
11
+ WARNING: 'warning',
12
+ DANGER: 'danger'
13
+ };
14
+ export const SIZES = {
15
+ SMALL: 'small',
16
+ MEDIUM: 'medium',
17
+ LARGE: 'large'
18
+ };
19
+ export const Tag = props => {
20
+ const {
21
+ className = '',
22
+ as: Component = 'span',
23
+ kind = KINDS.DEFAULT,
24
+ size = SIZES.MEDIUM,
25
+ ...restProps
26
+ } = props;
27
+ const rootClassName = cx(css.root, className, css[kind], css[size]);
28
+ return /*#__PURE__*/React.createElement(Component, _extends({
29
+ className: rootClassName
30
+ }, restProps));
31
+ };
32
+ Tag.propTypes = {
33
+ className: PropTypes.string,
34
+ as: PropTypes.elementType,
35
+ kind: PropTypes.oneOf(Object.values(KINDS)),
36
+ size: PropTypes.oneOf(Object.values(SIZES))
37
+ };
38
+ Tag.defaultProps = {
39
+ className: '',
40
+ as: 'span',
41
+ kind: KINDS.DEFAULT,
42
+ size: SIZES.MEDIUM
43
+ };
44
+ Tag.KINDS = KINDS;
45
+ Tag.SIZES = SIZES;
@@ -0,0 +1,55 @@
1
+ .root {
2
+ display: inline-block;
3
+ font-family: var(--font-family);
4
+ font-weight: bold;
5
+ background: var(--color-text-light);
6
+ color: var(--color-light);
7
+ text-align: center;
8
+ text-transform: uppercase;
9
+ }
10
+
11
+ /** Kind variation */
12
+ .success {
13
+ background: var(--color-success);
14
+ }
15
+
16
+ .info {
17
+ background: var(--color-info);
18
+ }
19
+
20
+ .warning {
21
+ background: var(--color-warning-dark);
22
+ }
23
+
24
+ .danger {
25
+ background: var(--color-danger);
26
+ }
27
+
28
+ /** Size variation */
29
+ /** default: medium */
30
+ .root {
31
+ border-radius: var(--radius-medium);
32
+ padding: var(--space-xxxsmall);
33
+ min-width: var(--space-small);
34
+ height: var(--space-small);
35
+ font-size: 9px;
36
+ line-height: 1;
37
+ }
38
+
39
+ .small {
40
+ border-radius: var(--radius-small);
41
+ padding: calc(var(--space-xxxsmall) / 2);
42
+ height: var(--space-xsmall);
43
+ min-width: var(--space-xsmall);
44
+ font-size: 8px;
45
+ line-height: 1;
46
+ }
47
+
48
+ .large {
49
+ border-radius: var(--radius-large);
50
+ padding: var(--space-xxxsmall) var(--space-xxsmall);
51
+ min-width: var(--space-medium);
52
+ height: var(--space-medium);
53
+ font-size: 12px;
54
+ line-height: var(--space-small);
55
+ }
@@ -0,0 +1,23 @@
1
+ import { Tag } from '.';
2
+ export default {
3
+ title: 'UI/Tag',
4
+ component: Tag,
5
+ argTypes: {
6
+ kind: {
7
+ control: 'select',
8
+ options: Object.values(Tag.KINDS)
9
+ },
10
+ size: {
11
+ control: 'select',
12
+ options: Object.values(Tag.SIZES)
13
+ }
14
+ },
15
+ args: {
16
+ children: 'tag'
17
+ }
18
+ };
19
+ export const Default = Tag.bind();
20
+ export const OneLetter = Tag.bind();
21
+ OneLetter.args = {
22
+ children: 'd'
23
+ };
@@ -12,7 +12,7 @@
12
12
 
13
13
  .tooltip {
14
14
  padding: var(--space-xxxsmall) var(--space-xxsmall);
15
- border-radius: var(--radius-small);
15
+ border-radius: var(--radius-medium);
16
16
  background: var(--color-light);
17
17
  color: var(--color-text);
18
18
  filter: drop-shadow(0 0 var(--space-xxxsmall) var(--color-shadow));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bundle-stats/ui",
3
- "version": "3.2.5-beta.1",
3
+ "version": "3.2.6-beta.1",
4
4
  "description": "UI components for BundleStats projects.",
5
5
  "main": "lib/index.js",
6
6
  "module": "lib-esm/index.js",
@@ -36,25 +36,25 @@
36
36
  },
37
37
  "homepage": "https://github.com/relative-ci/bundle-stats/blob/master/packages/ui#readme",
38
38
  "devDependencies": {
39
- "@babel/cli": "7.16.8",
40
- "@babel/core": "7.16.12",
39
+ "@babel/cli": "7.17.6",
40
+ "@babel/core": "7.17.5",
41
41
  "@babel/plugin-proposal-class-properties": "7.16.7",
42
42
  "@babel/preset-env": "7.16.11",
43
43
  "@babel/preset-react": "7.16.7",
44
44
  "@simplyianm/babel-plugin-inline-react-svg": "1.2.0",
45
- "@storybook/addon-essentials": "6.4.14",
45
+ "@storybook/addon-essentials": "6.4.19",
46
46
  "@storybook/addon-knobs": "6.4.0",
47
47
  "@storybook/addon-postcss": "2.0.0",
48
- "@storybook/addon-storyshots": "6.4.14",
49
- "@storybook/addons": "6.4.14",
50
- "@storybook/builder-webpack5": "6.4.14",
51
- "@storybook/manager-webpack5": "6.4.14",
52
- "@storybook/react": "6.4.14",
48
+ "@storybook/addon-storyshots": "6.4.19",
49
+ "@storybook/addons": "6.4.19",
50
+ "@storybook/builder-webpack5": "6.4.19",
51
+ "@storybook/manager-webpack5": "6.4.19",
52
+ "@storybook/react": "6.4.19",
53
53
  "babel-core": "7.0.0-bridge.0",
54
- "babel-jest": "27.4.6",
54
+ "babel-jest": "27.5.1",
55
55
  "babel-plugin-lodash": "3.3.4",
56
56
  "babel-plugin-require-context-hook": "1.0.0",
57
- "chromatic": "6.4.1",
57
+ "chromatic": "6.5.1",
58
58
  "classnames": "2.3.1",
59
59
  "colormap": "2.3.2",
60
60
  "core-js": "3.20.2",
@@ -64,10 +64,10 @@
64
64
  "enzyme-to-json": "3.6.2",
65
65
  "hex-rgb": "5.0.0",
66
66
  "identity-obj-proxy": "3.0.0",
67
- "jest": "27.4.7",
67
+ "jest": "27.5.1",
68
68
  "jest-date-mock": "1.0.8",
69
69
  "lodash": "4.17.21",
70
- "postcss": "8.4.5",
70
+ "postcss": "8.4.7",
71
71
  "prop-types": "15.8.1",
72
72
  "react": "16.14.0",
73
73
  "react-dom": "16.14.0",
@@ -85,11 +85,12 @@
85
85
  "react-router-dom": "5.3.0"
86
86
  },
87
87
  "dependencies": {
88
- "@bundle-stats/utils": "^3.2.5-beta.1",
88
+ "@bundle-stats/utils": "^3.2.6-beta.1",
89
89
  "date-fns": "2.28.0",
90
- "query-string": "7.1.0",
90
+ "modern-css-reset": "1.4.0",
91
+ "query-string": "7.1.1",
91
92
  "reakit": "1.3.11",
92
93
  "use-query-params": "1.2.3"
93
94
  },
94
- "gitHead": "908630a10015a08dcf977ef625bb79f8ccadb4bf"
95
+ "gitHead": "7131e3602cc523fb84d8dc712f88fb5b47773f70"
95
96
  }
package/src/app/app.jsx CHANGED
@@ -58,8 +58,12 @@ Layout.defaultProps = {
58
58
 
59
59
  const AppComponent = ({ version, jobs }) => {
60
60
  const [bundleStatsState, bundleStatsSetState] = useComponentQueryState(COMPONENT.BUNDLE_ASSETS);
61
- const [bundlePackagesState, bundlePackagesSetState] = useComponentQueryState(COMPONENT.BUNDLE_PACKAGES);
62
- const [bundleModulesState, bundleModulesSetState] = useComponentQueryState(COMPONENT.BUNDLE_MODULES);
61
+ const [bundlePackagesState, bundlePackagesSetState] = useComponentQueryState(
62
+ COMPONENT.BUNDLE_PACKAGES,
63
+ );
64
+ const [bundleModulesState, bundleModulesSetState] = useComponentQueryState(
65
+ COMPONENT.BUNDLE_MODULES,
66
+ );
63
67
 
64
68
  if (jobs.length === 0) {
65
69
  return (
@@ -19,6 +19,7 @@
19
19
 
20
20
  .tabsContainer {
21
21
  border-bottom: 1px solid var(--color-outline);
22
+ background: var(--color-light);
22
23
  }
23
24
 
24
25
  .tabs {
@@ -54,4 +55,10 @@
54
55
  background-color: var(--color-background);
55
56
  border-bottom: 1px solid var(--color-outline);
56
57
  }
58
+
59
+ .tabsContainer {
60
+ position: sticky;
61
+ top: var(--header-height);
62
+ z-index: 100;
63
+ }
57
64
  }
@@ -2,7 +2,12 @@ import React, { useMemo } from 'react';
2
2
  import PropTypes from 'prop-types';
3
3
  import cx from 'classnames';
4
4
  import { get, map } from 'lodash';
5
- import { ASSET_ENTRY_TYPE, ASSET_FILE_TYPE, ASSET_FILTERS, FILE_TYPE_LABELS } from '@bundle-stats/utils';
5
+ import {
6
+ ASSET_ENTRY_TYPE,
7
+ ASSET_FILE_TYPE,
8
+ ASSET_FILTERS,
9
+ FILE_TYPE_LABELS,
10
+ } from '@bundle-stats/utils';
6
11
 
7
12
  import config from '../../config.json';
8
13
  import I18N from '../../i18n';
@@ -11,6 +16,7 @@ import { Icon } from '../../ui/icon';
11
16
  import { FileName } from '../../ui/file-name';
12
17
  import { Popover } from '../../ui/popover';
13
18
  import { Tooltip } from '../../ui/tooltip';
19
+ import { Tag } from '../../ui/tag';
14
20
  import { Filters } from '../../ui/filters';
15
21
  import { SortDropdown } from '../../ui/sort-dropdown';
16
22
  import { EmptySet } from '../../ui/empty-set';
@@ -71,47 +77,58 @@ TooltipNotPredictive.propTypes = {
71
77
  runs: PropTypes.array, // eslint-disable-line react/forbid-prop-types
72
78
  };
73
79
 
74
- const getRenderRowHeader = ({ labels, CustomComponentLink, chunks }) => (item) => {
75
- const { label, isNotPredictive, runs, isChunk, isEntry, isInitial } = item;
80
+ const getRenderRowHeader =
81
+ ({ labels, CustomComponentLink, chunks }) =>
82
+ (item) => {
83
+ const { label, isNotPredictive, runs, isChunk, isEntry, isInitial } = item;
76
84
 
77
- return (
78
- <Popover
79
- label={<FileName name={label} />}
80
- icon={
81
- <div className={css.assetInfoFlags}>
82
- {isNotPredictive && (
83
- <Tooltip className={css.notPredictive} title={<TooltipNotPredictive runs={runs} />}>
84
- <Icon className={css.notPredictiveIcon} glyph="warning" />
85
- </Tooltip>
86
- )}
87
- {isChunk && (
88
- <span title="Chunk" className={css.flagChunk}>
89
- c
90
- </span>
91
- )}
92
- {isEntry && (
93
- <span title="Entrypoint" className={css.flagEntry}>
94
- e
95
- </span>
96
- )}
97
- {isInitial && (
98
- <span title="Initial" className={css.flagInitial}>
99
- i
100
- </span>
101
- )}
102
- </div>
103
- }
104
- >
105
- <AssetInfo
106
- className={css.assetInfo}
107
- item={item}
108
- labels={labels}
109
- chunks={chunks}
110
- CustomComponentLink={CustomComponentLink}
111
- />
112
- </Popover>
113
- );
114
- };
85
+ return (
86
+ <Popover
87
+ label={<FileName name={label} />}
88
+ icon={
89
+ <div className={css.assetInfoFlags}>
90
+ {isNotPredictive && (
91
+ <Tooltip className={css.notPredictive} title={<TooltipNotPredictive runs={runs} />}>
92
+ <Icon className={css.notPredictiveIcon} glyph="warning" />
93
+ </Tooltip>
94
+ )}
95
+ {isChunk && (
96
+ <Tag
97
+ title="Chunk"
98
+ size={Tag.SIZES.SMALL}
99
+ kind={Tag.KINDS.INFO}
100
+ className={cx(css.tag, css.tagChunk)}
101
+ />
102
+ )}
103
+ {isEntry && (
104
+ <Tag
105
+ title="Entrypoint"
106
+ size={Tag.SIZES.SMALL}
107
+ kind={Tag.KINDS.INFO}
108
+ className={cx(css.tag, css.tagEntry)}
109
+ />
110
+ )}
111
+ {isInitial && (
112
+ <Tag
113
+ title="Initial"
114
+ size={Tag.SIZES.SMALL}
115
+ kind={Tag.KINDS.INFO}
116
+ className={cx(css.tag, css.tagInitial)}
117
+ />
118
+ )}
119
+ </div>
120
+ }
121
+ >
122
+ <AssetInfo
123
+ className={css.assetInfo}
124
+ item={item}
125
+ labels={labels}
126
+ chunks={chunks}
127
+ CustomComponentLink={CustomComponentLink}
128
+ />
129
+ </Popover>
130
+ );
131
+ };
115
132
 
116
133
  export const BundleAssets = (props) => {
117
134
  const {
@@ -30,41 +30,28 @@
30
30
  display: none;
31
31
  }
32
32
 
33
- .flag {
34
- display: inline-block;
35
- width: var(--space-xsmall);
36
- height: var(--space-xsmall);
37
- font-family: var(--font-family);
38
- font-size: 8px;
39
- font-weight: bold;
40
- background: var(--color-highlight);
41
- color: var(--color-text-light);
42
- line-height: var(--space-xsmall);
43
- text-align: center;
44
- text-transform: uppercase;
45
- vertical-align: middle;
46
- }
47
-
48
- .flag + .flag {
33
+ .tag + .tag {
49
34
  margin-left: 2px;
50
35
  }
51
36
 
52
- .flagEntry {
53
- composes: flag;
37
+ .tagEntry {
54
38
  background: var(--color-info-light);
55
- color: var(--color-background);
56
39
  }
57
40
 
58
- .flagInitial {
59
- composes: flag;
41
+ .tagEntry::before {
42
+ content: 'e';
43
+ }
44
+
45
+ .tagInitial {
60
46
  background: var(--color-info-light);
61
- color: var(--color-background);
62
47
  }
63
48
 
64
- .flagChunk {
65
- composes: flag;
66
- background: var(--color-info);
67
- color: var(--color-background);
49
+ .tagInitial::before {
50
+ content: 'i';
51
+ }
52
+
53
+ .tagChunk::before {
54
+ content: 'c';
68
55
  }
69
56
 
70
57
  /* Tooltip not predictive */
@@ -1,4 +1,4 @@
1
- import React, {useCallback} from 'react';
1
+ import React, { useCallback } from 'react';
2
2
  import PropTypes from 'prop-types';
3
3
  import cx from 'classnames';
4
4
  import {
@@ -17,6 +17,7 @@ import { EmptySet } from '../../ui/empty-set';
17
17
  import { Filters } from '../../ui/filters';
18
18
  import { Popover } from '../../ui/popover';
19
19
  import { SortDropdown } from '../../ui/sort-dropdown';
20
+ import { Tag } from '../../ui/tag';
20
21
  import { Toolbar } from '../../ui/toolbar';
21
22
  import { FileName } from '../../ui/file-name';
22
23
  import { ComponentLink } from '../component-link';
@@ -27,7 +28,8 @@ import { MetricsTableTitle } from '../metrics-table-title';
27
28
  import css from './bundle-packages.module.css';
28
29
 
29
30
  const PackagePopoverContent = ({ name, fullName, path, duplicate, CustomComponentLink }) => {
30
- const normalizedPackagePath = path || `node_modules/${fullName.split(PACKAGES_SEPARATOR).join('/node_modules/')}/`;
31
+ const normalizedPackagePath =
32
+ path || `node_modules/${fullName.split(PACKAGES_SEPARATOR).join('/node_modules/')}/`;
31
33
  const [normalizedName, packageId] = name.split(PACKAGE_ID_SEPARATOR);
32
34
 
33
35
  return (
@@ -105,9 +107,12 @@ const PackageRowHeader = ({ item, CustomComponentLink }) => {
105
107
  {packageNames.map((packageName, index) => {
106
108
  // Render duplicate flag only for the last entry
107
109
  const duplicateFlag = index === packageNames.length - 1 && item.duplicate && (
108
- <span className={css.duplicate} title="Duplicate package">
109
- D
110
- </span>
110
+ <Tag
111
+ title="Duplicate package"
112
+ kind={Tag.KINDS.DANGER}
113
+ size={Tag.SIZES.SMALL}
114
+ className={css.tagDuplicate}
115
+ />
111
116
  );
112
117
 
113
118
  return (
@@ -12,20 +12,12 @@
12
12
  margin-right: -1px; /** collapse border */
13
13
  }
14
14
 
15
- .duplicate {
15
+ .tagDuplicate {
16
16
  margin-right: var(--space-xxxsmall);
17
- display: inline-block;
18
- width: var(--space-small);
19
- height: var(--space-small);
20
- font-size: 10px;
21
- font-weight: bold;
22
- line-height: var(--space-small);
23
- text-align: center;
24
- text-transform: uppercase;
25
- vertical-align: middle;
17
+ }
26
18
 
27
- background: var(--color-danger);
28
- color: var(--color-light);
19
+ .tagDuplicate::before {
20
+ content: 'd';
29
21
  }
30
22
 
31
23
  .packageName {
@@ -28,6 +28,7 @@
28
28
  }
29
29
 
30
30
  .inverted {
31
+ border-radius: var(--radius-small);
31
32
  background-color: var(--color-gray-ultra-light);
32
33
  color: var(--color-light);
33
34
  }
@@ -5,6 +5,7 @@
5
5
  }
6
6
 
7
7
  .input {
8
+ border-radius: var(--radius-small) 0 0 var(--radius-small);
8
9
  height: var(--space-large);
9
10
  border-color: var(--color-outline);
10
11
  }
@@ -21,12 +22,12 @@
21
22
  cursor: pointer;
22
23
  border-radius: 50%;
23
24
  position: absolute;
24
- right: 0;
25
+ right: 2px;
25
26
  top: 50%;
26
27
  transform: translateY(-50%);
27
- padding: var(--space-xxsmall);
28
- width: var(--space-large);
29
- height: var(--space-large);
28
+ padding: var(--space-xxxsmall);
29
+ width: var(--space-medium);
30
+ height: var(--space-medium);
30
31
  background: radial-gradient(var(--color-background) 50%, transparent);
31
32
  color: var(--color-text-ultra-light);
32
33
  transition: var(--transition-in);
@@ -1,18 +1,29 @@
1
+ @import url("~modern-css-reset/dist/reset.css");
2
+
1
3
  :root {
2
4
  --chart-height: 180px;
3
5
  }
4
6
 
7
+ /** modern-css-reset updates */
8
+ pre,
9
+ ul,
10
+ ol,
11
+ button {
12
+ margin: 0;
13
+ }
14
+
5
15
  html {
16
+ font-family: var(--font-family);
6
17
  font-size: 81.25%;
7
- line-height: 1.8461;
18
+ line-height: 1.6;
8
19
  }
9
20
 
10
21
  body {
22
+ background: var(--color-background);
11
23
  color: var(--color-text);
12
24
  }
13
25
 
14
- h1, h2, h3, h4, h5 {
15
- margin-bottom: var(--space-small);
26
+ h1, h2, h3, h4, h5, h6 {
16
27
  color: var(--color-heading);
17
28
  font-weight: 500;
18
29
  }
@@ -23,30 +23,30 @@
23
23
  --size-xxlarge: 1.424rem;
24
24
  --size-xxxlarge: 1.602rem;
25
25
 
26
- --line-height: var(--space-medium);
26
+ --line-height: 1.6em;
27
27
 
28
28
  /*
29
29
  * Color scheme:
30
- * http://mcg.mbitson.com/#!?mcgpalette0=%23dd555e&mcgpalette1=%2363bf5e&mcgpalette2=%23f7e37d&mcgpalette3=%23636568&mcgpalette4=%233385d6&themename=mcgtheme
31
30
  * https://coolors.co/3385d6-dd555e-63bf5e-f7e37d-192339
31
+ * http://mcg.mbitson.com/#!?mcgpalette0=%23dd555e&mcgpalette1=%2363bf5e&mcgpalette2=%23f7e37d&mcgpalette3=%235b5d60&mcgpalette4=%233385d6&themename=mcgtheme
32
32
  */
33
33
  --color-gray-25: #fafafa;
34
- --color-gray-50: #eceded;
35
- --color-gray-100: #d0d1d2;
36
- --color-gray-200: #b1b2b4;
37
- --color-gray-300: #929395;
38
- --color-gray-400: #7a7c7f;
39
- --color-gray-500: #636568;
40
- --color-gray-600: #5b5d60;
41
- --color-gray-700: #515355;
42
- --color-gray-800: #47494b;
43
- --color-gray-900: #35373a;
34
+ --color-gray-50: #e4e4e5;
35
+ --color-gray-100: #cececf;
36
+ --color-gray-200: #adaeb0;
37
+ --color-gray-300: #8c8e90;
38
+ --color-gray-400: #747578;
39
+ --color-gray-500: #5b5d60;
40
+ --color-gray-600: #535558;
41
+ --color-gray-700: #494b4e;
42
+ --color-gray-800: #404144;
43
+ --color-gray-900: #2f3033;
44
44
 
45
45
  --color-gray-ultra-light: var(--color-gray-200);
46
46
  --color-gray-light: var(--color-gray-300);
47
47
  --color-gray: var(--color-gray-500);
48
- --color-gray-dark: var(--color-gray-700);
49
- --color-gray-ultra-dark: var(--color-gray-900);
48
+ --color-gray-dark: var(--color-gray-600);
49
+ --color-gray-ultra-dark: var(--color-gray-700);
50
50
 
51
51
  --color-red-25: #fdf5f6;
52
52
  --color-red-50: #fbebec;
@@ -170,7 +170,7 @@
170
170
  --color-outline-warning: var(--color-yellow-200);
171
171
  --color-outline-danger: var(--color-red-100);
172
172
 
173
- --color-shadow: rgba(0, 0, 0, 0.2);
173
+ --color-shadow: rgba(0, 0, 0, 0.1);
174
174
 
175
175
  --transition-in: all 0.2s ease-in;
176
176
  --transition-out: all 0.17s ease-out;
@@ -181,9 +181,9 @@
181
181
  --layer-high: 1000;
182
182
  --layer-xhigh: 10000;
183
183
 
184
- --radius-small: var(--space-xxxsmall);
185
- --radius-medium: var(--space-xxsmall);
186
- --radius-large: var(--space-small);
184
+ --radius-small: 2px;
185
+ --radius-medium: var(--space-xxxsmall);
186
+ --radius-large: var(--space-xxsmall);
187
187
 
188
188
  /** Layout */
189
189
  --max-width: 80rem;
@@ -4,6 +4,15 @@
4
4
 
5
5
  .outline {
6
6
  border: 1px solid var(--color-outline);
7
+ border-radius: var(--radius-medium);
8
+ }
9
+
10
+ .outline > :first-child {
11
+ border-radius: var(--radius-medium) var(--radius-medium) 0 0;
12
+ }
13
+
14
+ .outline > :last-child {
15
+ border-radius: 0 0 var(--radius-medium) var(--radius-medium);
7
16
  }
8
17
 
9
18
  .padding-xxxsmall {
@@ -1,6 +1,7 @@
1
1
  export { Box } from './box';
2
2
  export { Footer } from './footer';
3
3
  export { Header } from './header';
4
+ export { Separator } from './separator';
4
5
  export { SubHeader } from './sub-header';
5
6
  export { Stack } from './stack';
6
7
  export { FlexStack } from './flex-stack';