@bundle-stats/ui 4.13.0-beta.9 → 4.13.0-rc.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.
- package/lib/app/app.js +4 -8
- package/lib/app/app.js.map +1 -1
- package/lib/app/app.module.css +2 -2
- package/lib/assets/icons.svg +70 -67
- package/lib/assets/icons.svg.js +14 -12
- package/lib/assets/icons.svg.js.map +1 -1
- package/lib/components/bundle-assets/bundle-assets.js +61 -26
- package/lib/components/bundle-assets/bundle-assets.js.map +1 -1
- package/lib/components/bundle-assets/bundle-assets.module.css +0 -5
- package/lib/components/bundle-assets/index.js +3 -1
- package/lib/components/bundle-assets/index.js.map +1 -1
- package/lib/components/bundle-assets-totals/bundle-assets-totals.js +14 -12
- package/lib/components/bundle-assets-totals/bundle-assets-totals.js.map +1 -1
- package/lib/components/bundle-modules/bundle-modules.i18n.js +1 -1
- package/lib/components/bundle-modules/bundle-modules.js +42 -15
- package/lib/components/bundle-modules/bundle-modules.js.map +1 -1
- package/lib/components/bundle-modules/bundle-modules.module.css +0 -5
- package/lib/components/bundle-modules/bundle-modules.utils.js +2 -13
- package/lib/components/bundle-modules/bundle-modules.utils.js.map +1 -1
- package/lib/components/bundle-modules/index.js +2 -1
- package/lib/components/bundle-modules/index.js.map +1 -1
- package/lib/components/bundle-packages/bundle-packages.js +48 -9
- package/lib/components/bundle-packages/bundle-packages.js.map +1 -1
- package/lib/components/bundle-packages/bundle-packages.module.css +0 -5
- package/lib/components/delta/delta.js +1 -1
- package/lib/components/delta/delta.js.map +1 -1
- package/lib/components/delta/delta.module.css +10 -1
- package/lib/components/jobs-header/jobs-header.module.css +0 -4
- package/lib/components/metrics-display-selector/metrics-display-selector.js +41 -4
- package/lib/components/metrics-display-selector/metrics-display-selector.js.map +1 -1
- package/lib/components/metrics-display-selector/metrics-display-selector.module.css +15 -7
- package/lib/components/metrics-treemap/index.js +4 -0
- package/lib/components/metrics-treemap/index.js.map +1 -1
- package/lib/components/metrics-treemap/metrics-treemap.constants.js +10 -0
- package/lib/components/metrics-treemap/metrics-treemap.constants.js.map +1 -0
- package/lib/components/metrics-treemap/metrics-treemap.i18n.js +6 -0
- package/lib/components/metrics-treemap/metrics-treemap.i18n.js.map +1 -0
- package/lib/components/metrics-treemap/metrics-treemap.js +131 -95
- package/lib/components/metrics-treemap/metrics-treemap.js.map +1 -1
- package/lib/components/metrics-treemap/metrics-treemap.module.css +179 -54
- package/lib/components/metrics-treemap/metrics-treemap.utils.js +168 -0
- package/lib/components/metrics-treemap/metrics-treemap.utils.js.map +1 -0
- package/lib/components/module-info/module-info.js +1 -2
- package/lib/components/module-info/module-info.js.map +1 -1
- package/lib/components/run-info/run-info.module.css +7 -7
- package/lib/css/variables.css +14 -13
- package/lib/hooks/metrics-display-type.js +45 -24
- package/lib/hooks/metrics-display-type.js.map +1 -1
- package/lib/hooks/search-params.js +1 -0
- package/lib/hooks/search-params.js.map +1 -1
- package/lib/layout/box/box.module.css +4 -2
- package/lib/layout/flex-stack/flex-stack.js +3 -4
- package/lib/layout/flex-stack/flex-stack.js.map +1 -1
- package/lib/layout/flex-stack/flex-stack.module.css +19 -23
- package/lib/ui/button/button.js +5 -4
- package/lib/ui/button/button.js.map +1 -1
- package/lib/ui/button/button.module.css +55 -53
- package/lib/ui/dropdown/dropdown.js +2 -2
- package/lib/ui/dropdown/dropdown.js.map +1 -1
- package/lib/ui/filters/filters.js +2 -2
- package/lib/ui/filters/filters.js.map +1 -1
- package/lib/ui/filters/filters.module.css +8 -1
- package/lib/ui/hover-card/hover-card.js +1 -1
- package/lib/ui/hover-card/hover-card.js.map +1 -1
- package/lib/ui/icon/icon.js +2 -1
- package/lib/ui/icon/icon.js.map +1 -1
- package/lib/ui/input-search/input-search.js +1 -1
- package/lib/ui/input-search/input-search.js.map +1 -1
- package/lib/ui/loader/loader.js +1 -1
- package/lib/ui/loader/loader.js.map +1 -1
- package/lib/ui/table/table.module.css +30 -0
- package/lib/ui/tag/tag.module.css +3 -3
- package/lib/ui/toolbar/toolbar.module.css +1 -3
- package/lib/utils/colors.js +22 -0
- package/lib/utils/colors.js.map +1 -0
- package/lib/{utils.js → utils/components.js} +2 -17
- package/lib/utils/components.js.map +1 -0
- package/lib/utils/index.js +20 -0
- package/lib/utils/index.js.map +1 -0
- package/lib/utils/jobs.js +18 -0
- package/lib/utils/jobs.js.map +1 -0
- package/lib-esm/app/app.js +4 -8
- package/lib-esm/app/app.js.map +1 -1
- package/lib-esm/app/app.module.css +2 -2
- package/lib-esm/assets/icons.svg +70 -67
- package/lib-esm/assets/icons.svg.js +14 -12
- package/lib-esm/assets/icons.svg.js.map +1 -1
- package/lib-esm/components/bundle-assets/bundle-assets.js +62 -28
- package/lib-esm/components/bundle-assets/bundle-assets.js.map +1 -1
- package/lib-esm/components/bundle-assets/bundle-assets.module.css +0 -5
- package/lib-esm/components/bundle-assets/index.js +3 -1
- package/lib-esm/components/bundle-assets/index.js.map +1 -1
- package/lib-esm/components/bundle-assets-totals/bundle-assets-totals.js +15 -13
- package/lib-esm/components/bundle-assets-totals/bundle-assets-totals.js.map +1 -1
- package/lib-esm/components/bundle-modules/bundle-modules.i18n.js +1 -1
- package/lib-esm/components/bundle-modules/bundle-modules.js +43 -16
- package/lib-esm/components/bundle-modules/bundle-modules.js.map +1 -1
- package/lib-esm/components/bundle-modules/bundle-modules.module.css +0 -5
- package/lib-esm/components/bundle-modules/bundle-modules.utils.js +1 -11
- package/lib-esm/components/bundle-modules/bundle-modules.utils.js.map +1 -1
- package/lib-esm/components/bundle-modules/index.js +3 -2
- package/lib-esm/components/bundle-modules/index.js.map +1 -1
- package/lib-esm/components/bundle-packages/bundle-packages.js +49 -10
- package/lib-esm/components/bundle-packages/bundle-packages.js.map +1 -1
- package/lib-esm/components/bundle-packages/bundle-packages.module.css +0 -5
- package/lib-esm/components/delta/delta.js +1 -1
- package/lib-esm/components/delta/delta.js.map +1 -1
- package/lib-esm/components/delta/delta.module.css +10 -1
- package/lib-esm/components/jobs-header/jobs-header.module.css +0 -4
- package/lib-esm/components/metrics-display-selector/metrics-display-selector.js +41 -4
- package/lib-esm/components/metrics-display-selector/metrics-display-selector.js.map +1 -1
- package/lib-esm/components/metrics-display-selector/metrics-display-selector.module.css +15 -7
- package/lib-esm/components/metrics-treemap/index.js +1 -0
- package/lib-esm/components/metrics-treemap/index.js.map +1 -1
- package/lib-esm/components/metrics-treemap/metrics-treemap.constants.js +7 -0
- package/lib-esm/components/metrics-treemap/metrics-treemap.constants.js.map +1 -0
- package/lib-esm/components/metrics-treemap/metrics-treemap.i18n.js +3 -0
- package/lib-esm/components/metrics-treemap/metrics-treemap.i18n.js.map +1 -0
- package/lib-esm/components/metrics-treemap/metrics-treemap.js +134 -98
- package/lib-esm/components/metrics-treemap/metrics-treemap.js.map +1 -1
- package/lib-esm/components/metrics-treemap/metrics-treemap.module.css +179 -54
- package/lib-esm/components/metrics-treemap/metrics-treemap.utils.js +162 -0
- package/lib-esm/components/metrics-treemap/metrics-treemap.utils.js.map +1 -0
- package/lib-esm/components/module-info/module-info.js +1 -2
- package/lib-esm/components/module-info/module-info.js.map +1 -1
- package/lib-esm/components/run-info/run-info.module.css +7 -7
- package/lib-esm/css/variables.css +14 -13
- package/lib-esm/hooks/metrics-display-type.js +46 -24
- package/lib-esm/hooks/metrics-display-type.js.map +1 -1
- package/lib-esm/hooks/search-params.js +1 -0
- package/lib-esm/hooks/search-params.js.map +1 -1
- package/lib-esm/layout/box/box.module.css +4 -2
- package/lib-esm/layout/flex-stack/flex-stack.js +3 -4
- package/lib-esm/layout/flex-stack/flex-stack.js.map +1 -1
- package/lib-esm/layout/flex-stack/flex-stack.module.css +19 -23
- package/lib-esm/ui/button/button.js +5 -4
- package/lib-esm/ui/button/button.js.map +1 -1
- package/lib-esm/ui/button/button.module.css +55 -53
- package/lib-esm/ui/dropdown/dropdown.js +2 -2
- package/lib-esm/ui/dropdown/dropdown.js.map +1 -1
- package/lib-esm/ui/filters/filters.js +2 -2
- package/lib-esm/ui/filters/filters.js.map +1 -1
- package/lib-esm/ui/filters/filters.module.css +8 -1
- package/lib-esm/ui/hover-card/hover-card.js +1 -1
- package/lib-esm/ui/hover-card/hover-card.js.map +1 -1
- package/lib-esm/ui/icon/icon.js +2 -1
- package/lib-esm/ui/icon/icon.js.map +1 -1
- package/lib-esm/ui/input-search/input-search.js +1 -1
- package/lib-esm/ui/input-search/input-search.js.map +1 -1
- package/lib-esm/ui/loader/loader.js +1 -1
- package/lib-esm/ui/loader/loader.js.map +1 -1
- package/lib-esm/ui/table/table.module.css +30 -0
- package/lib-esm/ui/tag/tag.module.css +3 -3
- package/lib-esm/ui/toolbar/toolbar.module.css +1 -3
- package/lib-esm/utils/colors.js +15 -0
- package/lib-esm/utils/colors.js.map +1 -0
- package/lib-esm/utils/components.js +16 -0
- package/lib-esm/utils/components.js.map +1 -0
- package/lib-esm/utils/index.js +4 -0
- package/lib-esm/utils/index.js.map +1 -0
- package/lib-esm/utils/jobs.js +11 -0
- package/lib-esm/utils/jobs.js.map +1 -0
- package/package.json +9 -9
- package/src/app/app.jsx +4 -12
- package/src/app/app.module.css +2 -2
- package/src/assets/icons/check.svg +4 -0
- package/src/assets/icons.svg +70 -67
- package/src/assets/icons.svg.jsx +12 -12
- package/src/components/bundle-assets/bundle-assets.jsx +147 -66
- package/src/components/bundle-assets/bundle-assets.module.css +0 -5
- package/src/components/bundle-assets/index.jsx +4 -0
- package/src/components/bundle-assets-totals/bundle-assets-totals.jsx +53 -46
- package/src/components/bundle-modules/bundle-modules.i18n.ts +1 -1
- package/src/components/bundle-modules/bundle-modules.module.css +0 -5
- package/src/components/bundle-modules/bundle-modules.tsx +140 -56
- package/src/components/bundle-modules/bundle-modules.types.d.ts +2 -17
- package/src/components/bundle-modules/bundle-modules.utils.ts +7 -18
- package/src/components/bundle-modules/index.tsx +4 -3
- package/src/components/bundle-packages/bundle-packages.jsx +89 -20
- package/src/components/bundle-packages/bundle-packages.module.css +0 -5
- package/src/components/delta/delta.jsx +1 -1
- package/src/components/delta/delta.module.css +10 -1
- package/src/components/jobs-header/jobs-header.module.css +0 -4
- package/src/components/metrics-display-selector/metrics-display-selector.module.css +15 -7
- package/src/components/metrics-display-selector/metrics-display-selector.stories.tsx +33 -0
- package/src/components/metrics-display-selector/metrics-display-selector.tsx +83 -25
- package/src/components/metrics-treemap/__tests__/metrics-treemap.utils.ts +188 -0
- package/src/components/metrics-treemap/index.ts +1 -0
- package/src/components/metrics-treemap/metrics-treemap.constants.ts +63 -0
- package/src/components/metrics-treemap/metrics-treemap.i18n.ts +2 -0
- package/src/components/metrics-treemap/metrics-treemap.module.css +179 -54
- package/src/components/metrics-treemap/metrics-treemap.stories.tsx +44 -10
- package/src/components/metrics-treemap/metrics-treemap.tsx +453 -184
- package/src/components/metrics-treemap/metrics-treemap.utils.ts +268 -0
- package/src/components/module-info/module-info.tsx +1 -1
- package/src/components/run-info/run-info.module.css +7 -7
- package/src/css/variables.css +14 -13
- package/src/hooks/metrics-display-type.ts +79 -29
- package/src/hooks/search-params.js +1 -0
- package/src/layout/box/box.module.css +4 -2
- package/src/layout/flex-stack/flex-stack.module.css +19 -23
- package/src/layout/flex-stack/flex-stack.tsx +2 -8
- package/src/ui/button/button.module.css +55 -53
- package/src/ui/button/button.stories.tsx +16 -9
- package/src/ui/button/button.tsx +8 -7
- package/src/ui/dropdown/dropdown.tsx +2 -3
- package/src/ui/filters/filters.module.css +8 -1
- package/src/ui/filters/filters.tsx +2 -3
- package/src/ui/hover-card/hover-card.tsx +1 -1
- package/src/ui/icon/icon.tsx +2 -1
- package/src/ui/input-search/input-search.tsx +1 -0
- package/src/ui/loader/loader.jsx +1 -1
- package/src/ui/table/table.module.css +30 -0
- package/src/ui/tag/tag.module.css +3 -3
- package/src/ui/toolbar/toolbar.module.css +1 -3
- package/src/utils/colors.ts +19 -0
- package/src/utils/components.tsx +19 -0
- package/src/utils/index.ts +3 -0
- package/src/utils/jobs.ts +22 -0
- package/types/components/bundle-assets/bundle-assets.d.ts +1 -5
- package/types/components/bundle-modules/bundle-modules.d.ts +4 -2
- package/types/components/bundle-modules/bundle-modules.i18n.d.ts +1 -1
- package/types/components/bundle-modules/bundle-modules.utils.d.ts +3 -7
- package/types/components/bundle-modules/index.d.ts +2 -2
- package/types/components/delta/delta.d.ts +2 -2
- package/types/components/metrics-display-selector/metrics-display-selector.d.ts +3 -1
- package/types/components/metrics-treemap/index.d.ts +1 -0
- package/types/components/metrics-treemap/metrics-treemap.constants.d.ts +28 -0
- package/types/components/metrics-treemap/metrics-treemap.d.ts +7 -5
- package/types/components/metrics-treemap/metrics-treemap.i18n.d.ts +2 -0
- package/types/components/metrics-treemap/metrics-treemap.utils.d.ts +15 -0
- package/types/hooks/metrics-display-type.d.ts +8 -2
- package/types/ui/dropdown/dropdown.d.ts +0 -1
- package/types/ui/icon/icon.d.ts +4 -2
- package/types/ui/loader/loader.d.ts +2 -2
- package/types/utils/colors.d.ts +1 -0
- package/types/utils/components.d.ts +2 -0
- package/types/utils/index.d.ts +3 -0
- package/types/utils/jobs.d.ts +7 -0
- package/lib/components/bundle-assets-totals/bundle-assets-totals.module.css +0 -7
- package/lib/utils.js.map +0 -1
- package/lib-esm/components/bundle-assets-totals/bundle-assets-totals.module.css +0 -7
- package/lib-esm/utils.js +0 -30
- package/lib-esm/utils.js.map +0 -1
- package/src/components/bundle-assets-totals/bundle-assets-totals.module.css +0 -7
- package/src/utils.jsx +0 -38
- package/types/utils.d.ts +0 -3
|
@@ -2,6 +2,9 @@
|
|
|
2
2
|
position: relative;
|
|
3
3
|
aspect-ratio: 16/9;
|
|
4
4
|
background: var(--color-background);
|
|
5
|
+
border-bottom-left-radius: inherit;
|
|
6
|
+
border-bottom-right-radius: inherit;
|
|
7
|
+
overflow: hidden;
|
|
5
8
|
}
|
|
6
9
|
|
|
7
10
|
.canvas {
|
|
@@ -10,34 +13,133 @@
|
|
|
10
13
|
top: 0;
|
|
11
14
|
width: 100%;
|
|
12
15
|
height: 100%;
|
|
13
|
-
fill: var(--color-text);
|
|
14
|
-
font-family: var(--font-family);
|
|
15
16
|
background: var(--color-background);
|
|
16
17
|
}
|
|
17
18
|
|
|
18
|
-
/**
|
|
19
|
-
|
|
19
|
+
/**
|
|
20
|
+
* Tile group
|
|
21
|
+
*/
|
|
22
|
+
.tileGroup {
|
|
23
|
+
position: absolute;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.tileGroupTitle {
|
|
27
|
+
width: 100%;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.tileGroupTitleContent {
|
|
31
|
+
width: 100%;
|
|
32
|
+
padding: var(--space-xxxsmall) 2px var(--space-xxxsmall) var(--space-xxsmall);
|
|
33
|
+
display: flex;
|
|
34
|
+
align-items: center;
|
|
35
|
+
color: var(--color-text);
|
|
36
|
+
font-family: var(--font-family-fixed);
|
|
37
|
+
font-size: 10px;
|
|
38
|
+
line-height: var(--space-small);
|
|
39
|
+
overflow: hidden;
|
|
40
|
+
white-space: nowrap;
|
|
41
|
+
text-overflow: ellipsis;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.tileGroupTitleText,
|
|
45
|
+
.tileGroupTitleTotal {
|
|
46
|
+
flex: 0 0 auto;
|
|
47
|
+
min-width: 0;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.tileGroupTitleTotal {
|
|
51
|
+
margin-left: var(--space-xxsmall);
|
|
52
|
+
color: var(--color-text-light);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.tileGroupTitle {
|
|
20
56
|
transition: var(--ui-transition-out);
|
|
21
|
-
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.tileGroupTitle:hover .tileGroupTitleText {
|
|
60
|
+
text-decoration: underline;
|
|
61
|
+
transition: var(--ui-transition-in);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/** Tile group size variation */
|
|
65
|
+
.tileGroup {
|
|
66
|
+
transition: var(--ui-transition-in);
|
|
67
|
+
transition-property: left, top, width, height;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.tileGroup--minimal .tileGroupTitle,
|
|
71
|
+
.tileGroup--small .tileGroupTitle {
|
|
72
|
+
height: 100%; /* full height when title is missing or we do not render any children */
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
.tileGroup--minimal .tileGroupTitleContent,
|
|
76
|
+
.tileGroup--small .tileGroupTitleContent {
|
|
77
|
+
min-height: 100%;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
/** Tile group nested variation */
|
|
81
|
+
.nested .tileGroup {
|
|
82
|
+
background-color: rgba(27, 26, 33, 0.05);
|
|
83
|
+
outline: 1px solid rgba(255, 255, 255, 0.75);
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
.nested .tileGroup:has(> .tileGroupTitle:hover),
|
|
87
|
+
.nested .tileGroup:has(> .tile:hover) {
|
|
88
|
+
background-color: rgba(27, 26, 33, 0.1);
|
|
89
|
+
outline: 1px solid rgba(255, 255, 255, 1);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.nested .tileGroup--NEGATIVE {
|
|
93
|
+
background-color: rgba(194, 31, 37, 0.05);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.nested .tileGroup--NEGATIVE:has(> .tileGroupTitle:hover),
|
|
97
|
+
.nested .tileGroup--NEGATIVE:has(> .tile:hover) {
|
|
98
|
+
background-color: rgba(194, 31, 37, 0.1);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.nested .tileGroup--POSITIVE {
|
|
102
|
+
background-color: rgba(42, 147, 39, 0.05);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.nested .tileGroup--POSITIVE:has(> .tileGroupTitle:hover),
|
|
106
|
+
.nested .tileGroup--POSITIVE:has(> .tile:hover) {
|
|
107
|
+
background-color: rgba(42, 147, 39, 0.1);
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
/* reset bacground color when having a not changed group */
|
|
111
|
+
.nested .tileGroup--POSITIVE > .tileGroup--NO_CHANGE,
|
|
112
|
+
.nested .tileGroup--NEGATIVE > .tileGroup--NO_CHANGE {
|
|
113
|
+
background-color: var(--color-background);
|
|
114
|
+
background-image: linear-gradient(rgba(27, 26, 33, 0.1), rgba(27, 26, 33, 0.1));
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.nested .tileGroup--POSITIVE > .tileGroup--NO_CHANGE:has(> .tileGroupTitle:hover),
|
|
118
|
+
.nested .tileGroup--POSITIVE > .tileGroup--NO_CHANGE:has(> .tile:hover),
|
|
119
|
+
.nested .tileGroup--NEGATIVE > .tileGroup--NO_CHANGE:has(> .tileGroupTitle:hover),
|
|
120
|
+
.nested .tileGroup--NEGATIVE > .tileGroup--NEGATIVE > .tileGroup--NO_CHANGE:has(> .tile:hover) {
|
|
121
|
+
background-color: var(--color-background);
|
|
122
|
+
background-image: linear-gradient(rgba(27, 26, 33, 0.1), rgba(27, 26, 33, 0.1));
|
|
22
123
|
}
|
|
23
124
|
|
|
24
125
|
/** Leaf wrapper button */
|
|
25
|
-
.
|
|
126
|
+
.tile {
|
|
26
127
|
position: absolute;
|
|
27
128
|
appearance: none;
|
|
28
129
|
border: 0;
|
|
29
130
|
border-radius: 0;
|
|
30
131
|
padding: 0;
|
|
31
|
-
background:
|
|
132
|
+
background: var(--color-background);
|
|
32
133
|
display: flex;
|
|
33
134
|
align-items: center;
|
|
34
135
|
font-family: var(--font-family-fixed);
|
|
35
136
|
font-size: var(--size-small);
|
|
36
137
|
line-height: var(--line-height-heading);
|
|
37
138
|
text-align: left;
|
|
139
|
+
transition: var(--ui-transition-out);
|
|
38
140
|
}
|
|
39
141
|
|
|
40
|
-
.
|
|
142
|
+
.tile::before {
|
|
41
143
|
content: "";
|
|
42
144
|
display: block;
|
|
43
145
|
position: absolute;
|
|
@@ -47,18 +149,9 @@
|
|
|
47
149
|
width: 100%;
|
|
48
150
|
height: 100%;
|
|
49
151
|
background-color: currentColor;
|
|
50
|
-
color: var(--color-background);
|
|
51
|
-
transition: var(--ui-transition-out);
|
|
52
|
-
transition-property: opacity;
|
|
53
|
-
opacity: 0.6;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
.leaf:hover::before {
|
|
57
|
-
transition: var(--ui-transition-in);
|
|
58
|
-
opacity: 0.4;
|
|
59
152
|
}
|
|
60
153
|
|
|
61
|
-
.
|
|
154
|
+
.tileContent {
|
|
62
155
|
position: relative;
|
|
63
156
|
z-index: 1;
|
|
64
157
|
width: 100%;
|
|
@@ -71,80 +164,113 @@
|
|
|
71
164
|
line-height: var(--line-height-heading);
|
|
72
165
|
}
|
|
73
166
|
|
|
74
|
-
/** Align label to other elements on the first column
|
|
75
|
-
.
|
|
167
|
+
/** Align label to other elements on the first column cells */
|
|
168
|
+
.tileFirstCol .tileContent {
|
|
76
169
|
padding-left: var(--space-small);
|
|
77
170
|
}
|
|
78
171
|
|
|
79
|
-
.
|
|
172
|
+
.tileContentLabel {
|
|
80
173
|
flex: 0 1 auto;
|
|
81
174
|
width: 100%;
|
|
82
175
|
min-width: 0;
|
|
83
|
-
max-height: calc(2em * var(--line-height-heading));
|
|
176
|
+
max-height: calc(2em * var(--line-height-heading)); /* render max 2 rows */
|
|
177
|
+
overflow-wrap: break-word;
|
|
178
|
+
word-wrap: break-word;
|
|
179
|
+
word-break: break-all;
|
|
180
|
+
word-break: break-word;
|
|
181
|
+
hyphens: auto;
|
|
182
|
+
white-space: normal;
|
|
84
183
|
overflow: hidden;
|
|
85
184
|
}
|
|
86
185
|
|
|
87
|
-
.
|
|
186
|
+
.tileContentValue {
|
|
88
187
|
flex: 0 0 auto;
|
|
89
188
|
max-width: calc(100% + var(--space-xxsmall));
|
|
90
189
|
white-space: nowrap;
|
|
91
190
|
overflow: hidden;
|
|
92
191
|
}
|
|
93
192
|
|
|
94
|
-
.
|
|
193
|
+
.tileContentMetric {
|
|
95
194
|
font-weight: bold;
|
|
96
195
|
}
|
|
97
196
|
|
|
98
|
-
.
|
|
197
|
+
.tileContentDelta {
|
|
99
198
|
margin-left: var(--space-xxxsmall);
|
|
100
199
|
}
|
|
101
200
|
|
|
102
201
|
/** Tile size variation */
|
|
103
|
-
.
|
|
104
|
-
padding: var(--space-xxxsmall)
|
|
105
|
-
|
|
106
|
-
font-size: var(--size-xsmall);
|
|
202
|
+
.tileSizeSmall .tileContent {
|
|
203
|
+
padding: var(--space-xxxsmall);
|
|
204
|
+
font-size: 10px;
|
|
107
205
|
}
|
|
108
206
|
|
|
109
|
-
.
|
|
207
|
+
.tileSizeSmall .tileContentLabel {
|
|
110
208
|
margin-top: 0;
|
|
111
209
|
}
|
|
112
210
|
|
|
211
|
+
.tileSizeDefault {
|
|
212
|
+
transition: var(--ui-transition-in);
|
|
213
|
+
transition-property: left, top, width, height;
|
|
214
|
+
}
|
|
215
|
+
|
|
113
216
|
/** Tile diff variation */
|
|
114
|
-
.
|
|
115
|
-
|
|
217
|
+
.tile {
|
|
218
|
+
outline: 1px solid rgba(255, 255, 255, 1);
|
|
219
|
+
color: var(--color-text);
|
|
220
|
+
transition: var(--ui-transition-out);
|
|
116
221
|
}
|
|
117
222
|
|
|
118
|
-
.
|
|
119
|
-
color: var(--color-
|
|
223
|
+
.tile::before {
|
|
224
|
+
color: var(--color-highlight);
|
|
225
|
+
transition: var(--ui-transition-out);
|
|
226
|
+
transition-property: opacity;
|
|
227
|
+
opacity: 0.5;
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
.tile:hover::before {
|
|
231
|
+
transition: var(--ui-transition-in);
|
|
120
232
|
opacity: 0.4;
|
|
121
233
|
}
|
|
122
234
|
|
|
123
|
-
.
|
|
124
|
-
|
|
235
|
+
.tile-NO_CHANGE {
|
|
236
|
+
color: var(--color-text-light);
|
|
125
237
|
}
|
|
126
238
|
|
|
127
|
-
.
|
|
239
|
+
.tile-NO_CHANGE::before {
|
|
240
|
+
color: var(--color-gray-50);
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
.tile-HIGH_NEGATIVE::before {
|
|
128
244
|
color: var(--color-red-100);
|
|
129
245
|
}
|
|
130
246
|
|
|
131
|
-
.
|
|
247
|
+
.tile-NEGATIVE::before {
|
|
248
|
+
color: var(--color-red-50);
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
.tile-LOW_NEGATIVE::before {
|
|
132
252
|
color: var(--color-red-50);
|
|
253
|
+
opacity: 0.6;
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
.tile-LOW_NEGATIVE:hover::before {
|
|
257
|
+
opacity: 0.5;
|
|
133
258
|
}
|
|
134
259
|
|
|
135
|
-
.
|
|
136
|
-
color: var(--color-
|
|
260
|
+
.tile-LOW_POSITIVE::before {
|
|
261
|
+
color: var(--color-green-50);
|
|
262
|
+
opacity: 0.6;
|
|
137
263
|
}
|
|
138
264
|
|
|
139
|
-
.
|
|
140
|
-
|
|
265
|
+
.tile-LOW_POSITIVE:hover::before {
|
|
266
|
+
opacity: 0.5;
|
|
141
267
|
}
|
|
142
268
|
|
|
143
|
-
.
|
|
269
|
+
.tile-POSITIVE::before {
|
|
144
270
|
color: var(--color-green-50);
|
|
145
271
|
}
|
|
146
272
|
|
|
147
|
-
.
|
|
273
|
+
.tile-HIGH_POSITIVE::before {
|
|
148
274
|
color: var(--color-green-100);
|
|
149
275
|
}
|
|
150
276
|
|
|
@@ -166,7 +292,7 @@
|
|
|
166
292
|
}
|
|
167
293
|
|
|
168
294
|
/** tooltip */
|
|
169
|
-
.
|
|
295
|
+
.tileContentTooltipAnchor {
|
|
170
296
|
width: 100%;
|
|
171
297
|
height: 100%;
|
|
172
298
|
}
|
|
@@ -185,17 +311,16 @@
|
|
|
185
311
|
pointer-events: none;
|
|
186
312
|
}
|
|
187
313
|
|
|
188
|
-
|
|
189
|
-
div[role="presentation"]:has(.tooltip) {
|
|
190
|
-
pointer-events: none;
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
.leafTooltipArrow svg {
|
|
314
|
+
.tileTooltipArrow svg {
|
|
195
315
|
display: block;
|
|
196
316
|
fill: var(--color-background) !important;
|
|
197
317
|
}
|
|
198
318
|
|
|
199
|
-
.
|
|
200
|
-
font-size: var(--size-
|
|
319
|
+
.tileTooltipContentTitle {
|
|
320
|
+
font-size: var(--size-small);
|
|
321
|
+
}
|
|
322
|
+
|
|
323
|
+
/* prevent tooltip portal wrapper from capturing events */
|
|
324
|
+
div[role="presentation"]:has(.tooltip) {
|
|
325
|
+
pointer-events: none;
|
|
201
326
|
}
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.useTooltipStateWithMouseFollow = exports.resolveTileSizeDisplay = exports.resolveTileGroupSizeDisplay = exports.resolveGroupDeltaType = exports.getTreemapNodesGroupedByPath = exports.getTreemapNodes = void 0;
|
|
4
|
+
const react_1 = require("react");
|
|
5
|
+
const react_use_1 = require("react-use");
|
|
6
|
+
const tooltip_1 = require("ariakit/tooltip");
|
|
7
|
+
const utils_1 = require("@bundle-stats/utils");
|
|
8
|
+
const metrics_treemap_constants_1 = require("./metrics-treemap.constants");
|
|
9
|
+
const ROOT_LABEL = '(root)';
|
|
10
|
+
function getReportMetricRowMaxValue(item) {
|
|
11
|
+
const values = item.runs.map((run) => run?.value || 0);
|
|
12
|
+
return Math.max(...values);
|
|
13
|
+
}
|
|
14
|
+
function getTreemapNodes(items) {
|
|
15
|
+
const rootChildren = items.map((item) => ({
|
|
16
|
+
id: item.key,
|
|
17
|
+
label: item.label,
|
|
18
|
+
value: getReportMetricRowMaxValue(item),
|
|
19
|
+
item,
|
|
20
|
+
}));
|
|
21
|
+
return {
|
|
22
|
+
id: '',
|
|
23
|
+
label: ROOT_LABEL,
|
|
24
|
+
value: 0,
|
|
25
|
+
children: rootChildren,
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
exports.getTreemapNodes = getTreemapNodes;
|
|
29
|
+
function getItemValues(runs) {
|
|
30
|
+
const runCount = runs?.length;
|
|
31
|
+
const current = runs[0]?.value || 0;
|
|
32
|
+
if (runCount < 2) {
|
|
33
|
+
return { current, baseline: 0 };
|
|
34
|
+
}
|
|
35
|
+
return {
|
|
36
|
+
current,
|
|
37
|
+
baseline: runs[runCount - 1]?.value || 0,
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
function setTreeNode(nodes, slugs, currentSlugId, newNode) {
|
|
41
|
+
const baseSlugs = slugs.slice(0, currentSlugId);
|
|
42
|
+
const [currentSlug, ...restSlug] = slugs.slice(currentSlugId);
|
|
43
|
+
if (!currentSlug) {
|
|
44
|
+
nodes.push(newNode);
|
|
45
|
+
return getItemValues(newNode.item.runs);
|
|
46
|
+
}
|
|
47
|
+
const currentNodePath = [...baseSlugs, currentSlug].join('/');
|
|
48
|
+
let parentNode = nodes.find((treeNode) => treeNode.id === currentNodePath);
|
|
49
|
+
if (!parentNode) {
|
|
50
|
+
parentNode = {
|
|
51
|
+
id: currentNodePath,
|
|
52
|
+
label: currentSlug,
|
|
53
|
+
value: 0,
|
|
54
|
+
children: [],
|
|
55
|
+
total: {
|
|
56
|
+
current: 0,
|
|
57
|
+
baseline: 0,
|
|
58
|
+
},
|
|
59
|
+
};
|
|
60
|
+
nodes.push(parentNode);
|
|
61
|
+
}
|
|
62
|
+
const nodeValues = getItemValues(newNode?.item?.runs);
|
|
63
|
+
parentNode.total = {
|
|
64
|
+
current: (parentNode.total?.current || 0) + nodeValues.current,
|
|
65
|
+
baseline: (parentNode.total?.baseline || 0) + (nodeValues.baseline || 0),
|
|
66
|
+
};
|
|
67
|
+
if (restSlug.length === 0) {
|
|
68
|
+
parentNode.children.push(newNode);
|
|
69
|
+
return getItemValues(newNode.item.runs);
|
|
70
|
+
}
|
|
71
|
+
return setTreeNode(parentNode.children, slugs, currentSlugId + 1, newNode);
|
|
72
|
+
}
|
|
73
|
+
function getTreemapNodesGroupedByPath(items) {
|
|
74
|
+
const treeNodes = [];
|
|
75
|
+
const total = { current: 0, baseline: 0 };
|
|
76
|
+
items.forEach((item) => {
|
|
77
|
+
const slugs = item.key.split('/');
|
|
78
|
+
const baseSlugs = slugs.slice(0, -1);
|
|
79
|
+
const baseName = slugs.slice(-1)[0];
|
|
80
|
+
const treeNode = {
|
|
81
|
+
id: item.key,
|
|
82
|
+
label: baseName,
|
|
83
|
+
value: getReportMetricRowMaxValue(item),
|
|
84
|
+
item,
|
|
85
|
+
};
|
|
86
|
+
const childrenTotal = setTreeNode(treeNodes, baseSlugs, 0, treeNode);
|
|
87
|
+
total.current += childrenTotal.current || 0;
|
|
88
|
+
total.baseline += childrenTotal.baseline || 0;
|
|
89
|
+
});
|
|
90
|
+
return {
|
|
91
|
+
id: '',
|
|
92
|
+
label: ROOT_LABEL,
|
|
93
|
+
value: 0,
|
|
94
|
+
children: treeNodes,
|
|
95
|
+
total,
|
|
96
|
+
};
|
|
97
|
+
}
|
|
98
|
+
exports.getTreemapNodesGroupedByPath = getTreemapNodesGroupedByPath;
|
|
99
|
+
function resolveGroupDeltaType(metricRunInfo) {
|
|
100
|
+
if (!metricRunInfo) {
|
|
101
|
+
return utils_1.DeltaType.NO_CHANGE;
|
|
102
|
+
}
|
|
103
|
+
const deltaType = 'displayDelta' in metricRunInfo ? metricRunInfo.deltaType : undefined;
|
|
104
|
+
if (deltaType?.match(/NEGATIVE/)) {
|
|
105
|
+
return utils_1.DeltaType.NEGATIVE;
|
|
106
|
+
}
|
|
107
|
+
if (deltaType?.match(/POSITIVE/)) {
|
|
108
|
+
return utils_1.DeltaType.POSITIVE;
|
|
109
|
+
}
|
|
110
|
+
return utils_1.DeltaType.NO_CHANGE;
|
|
111
|
+
}
|
|
112
|
+
exports.resolveGroupDeltaType = resolveGroupDeltaType;
|
|
113
|
+
const PADDING_TOP = 8;
|
|
114
|
+
const PADDING_BOTTOM = 8;
|
|
115
|
+
const PADDING_LEFT = 8;
|
|
116
|
+
const PADDING_RIGHT = 8;
|
|
117
|
+
const LINE_HEIGHT = 16;
|
|
118
|
+
const LINE_HEIGHT_SMALL = 13.3;
|
|
119
|
+
function resolveTileGroupSizeDisplay(width, height) {
|
|
120
|
+
if (height < metrics_treemap_constants_1.NESTED_PADDING_TOP) {
|
|
121
|
+
return 'minimal';
|
|
122
|
+
}
|
|
123
|
+
if (width < 24) {
|
|
124
|
+
return 'minimal';
|
|
125
|
+
}
|
|
126
|
+
if (height < metrics_treemap_constants_1.NESTED_PADDING_TOP + 8) {
|
|
127
|
+
return 'small';
|
|
128
|
+
}
|
|
129
|
+
return 'default';
|
|
130
|
+
}
|
|
131
|
+
exports.resolveTileGroupSizeDisplay = resolveTileGroupSizeDisplay;
|
|
132
|
+
function resolveTileSizeDisplay(width, height) {
|
|
133
|
+
if (height < PADDING_TOP + PADDING_BOTTOM + LINE_HEIGHT_SMALL) {
|
|
134
|
+
return 'minimal';
|
|
135
|
+
}
|
|
136
|
+
if (width < PADDING_LEFT + PADDING_RIGHT + 42) {
|
|
137
|
+
return 'minimal';
|
|
138
|
+
}
|
|
139
|
+
if (height < PADDING_TOP + PADDING_TOP + LINE_HEIGHT * 2) {
|
|
140
|
+
return 'small';
|
|
141
|
+
}
|
|
142
|
+
if (width < PADDING_LEFT + PADDING_RIGHT + 96) {
|
|
143
|
+
return 'small';
|
|
144
|
+
}
|
|
145
|
+
return 'default';
|
|
146
|
+
}
|
|
147
|
+
exports.resolveTileSizeDisplay = resolveTileSizeDisplay;
|
|
148
|
+
function useTooltipStateWithMouseFollow(options) {
|
|
149
|
+
const { parentRef, gutter = 16, timeout = 180 } = options;
|
|
150
|
+
const pointer = (0, react_use_1.useMouseHovered)(parentRef, { whenHovered: true });
|
|
151
|
+
const getAnchorRect = (0, react_1.useCallback)(() => {
|
|
152
|
+
if (pointer.docX === 0 && pointer.docY === 0 && pointer.elW === 0 && pointer.elH === 0) {
|
|
153
|
+
return null;
|
|
154
|
+
}
|
|
155
|
+
const newRect = {
|
|
156
|
+
x: pointer.docX - (document?.defaultView?.scrollX ?? 0),
|
|
157
|
+
y: pointer.docY - (document?.defaultView?.scrollY ?? 0),
|
|
158
|
+
w: 1,
|
|
159
|
+
h: 1,
|
|
160
|
+
};
|
|
161
|
+
return newRect;
|
|
162
|
+
}, [pointer.docX, pointer.docY]);
|
|
163
|
+
const tooltipState = (0, tooltip_1.useTooltipState)({ gutter, getAnchorRect, timeout });
|
|
164
|
+
(0, react_use_1.useDebounce)(tooltipState.render, 10, [pointer.docX, pointer.docY]);
|
|
165
|
+
return tooltipState;
|
|
166
|
+
}
|
|
167
|
+
exports.useTooltipStateWithMouseFollow = useTooltipStateWithMouseFollow;
|
|
168
|
+
//# sourceMappingURL=metrics-treemap.utils.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"metrics-treemap.utils.js","sourceRoot":"","sources":["../../../src/components/metrics-treemap/metrics-treemap.utils.ts"],"names":[],"mappings":";;;AAAA,iCAAoD;AACpD,yCAAyD;AACzD,6CAAkD;AAClD,+CAK6B;AAE7B,2EAQqC;AAErC,MAAM,UAAU,GAAG,QAAQ,CAAC;AAM5B,SAAS,0BAA0B,CAAC,IAAqB;IACvD,MAAM,MAAM,GAAG,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,EAAE,KAAK,IAAI,CAAC,CAAC,CAAC;IACvD,OAAO,IAAI,CAAC,GAAG,CAAC,GAAG,MAAM,CAAC,CAAC;AAC7B,CAAC;AAKD,SAAgB,eAAe,CAAC,KAA6B;IAC3D,MAAM,YAAY,GAAoB,KAAK,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC;QACzD,EAAE,EAAE,IAAI,CAAC,GAAG;QACZ,KAAK,EAAE,IAAI,CAAC,KAAK;QACjB,KAAK,EAAE,0BAA0B,CAAC,IAAI,CAAC;QACvC,IAAI;KACL,CAAC,CAAC,CAAC;IAEJ,OAAO;QACL,EAAE,EAAE,EAAE;QACN,KAAK,EAAE,UAAU;QACjB,KAAK,EAAE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G,KAAK,CAAC,EAAE;YACtF,OAAO,IAAI,CAAC;SACb;QAED,MAAM,OAAO,GAAG;YACd,CAAC,EAAE,OAAO,CAAC,IAAI,GAAG,CAAC,QAAQ,EAAE,WAAW,EAAE,OAAO,IAAI,CAAC,CAAC;YACvD,CAAC,EAAE,OAAO,CAAC,IAAI,GAAG,CAAC,QAAQ,EAAE,WAAW,EAAE,OAAO,IAAI,CAAC,CAAC;YACvD,CAAC,EAAE,CAAC;YACJ,CAAC,EAAE,CAAC;SACL,CAAC;QAEF,OAAO,OAAO,CAAC;IACjB,CAAC,EAAE,CAAC,OAAO,CAAC,IAAI,EAAE,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC;IAEjC,MAAM,YAAY,GAAG,IAAA,yBAAe,EAAC,EAAE,MAAM,EAAE,aAAa,EAAE,OAAO,EAAE,CAAC,CAAC;IAGzE,IAAA,uBAAW,EAAC,YAAY,CAAC,MAAM,EAAE,EAAE,EAAE,CAAC,OAAO,CAAC,IAAI,EAAE,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC;IAEnE,OAAO,YAAY,CAAC;AACtB,CAAC;AA5BD,wEA4BC"}
|
|
@@ -54,8 +54,7 @@ const ModuleInfo = (props) => {
|
|
|
54
54
|
return (react_1.default.createElement(entry_info_1.EntryInfo, { item: item, labels: labels, tags: tags, onClose: onClose, className: rootClassName },
|
|
55
55
|
react_1.default.createElement(stack_1.Stack, { space: "xxxsmall" },
|
|
56
56
|
item.runs?.map((currentRun, index) => !(0, isEmpty_1.default)(currentRun?.chunkIds) && (react_1.default.createElement(entry_info_1.EntryInfo.Meta, { label: "Chunks", className: module_info_module_css_1.default.chunks },
|
|
57
|
-
|
|
58
|
-
index + 1,
|
|
57
|
+
labels[index],
|
|
59
58
|
":",
|
|
60
59
|
currentRun.chunkIds.map((chunkId) => {
|
|
61
60
|
const chunk = chunks?.find(({ id }) => id === chunkId);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"module-info.js","source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IAAA,iCAAyB,EAAC,IAAI,CAAC,QAAQ,EAAE,aAAa,CAAC,IAE1D,aAAa,CACI,CACL,CAClB;YAED,8BAAC,sBAAS,CAAC,IAAI,IAAC,KAAK,EAAC,QAAQ;gBAC5B,8BAAC,8BAAiB,IAChB,EAAE,EAAE,mBAAmB,KACnB,IAAA,gCAAwB,EAAC,IAAI,CAAC,UAAU,IAAI,KAAK,EAAE,eAAe,CAAC,EACvE,OAAO,EAAE,OAAO,IAEf,eAAe,CACE,CACL,CACX,CACE,CACb,CAAC;AACJ,CAAC,CAAC;AAtFW,QAAA,UAAU,cAsFrB"}
|
|
@@ -31,6 +31,10 @@
|
|
|
31
31
|
font-weight: bold;
|
|
32
32
|
}
|
|
33
33
|
|
|
34
|
+
.delta {
|
|
35
|
+
font-weight: normal;
|
|
36
|
+
}
|
|
37
|
+
|
|
34
38
|
.deltaValue + .deltaValue::before {
|
|
35
39
|
margin-left: calc(var(--space-xxxsmall) / 2);
|
|
36
40
|
margin-right: calc(var(--space-xxxsmall) / 2);
|
|
@@ -72,17 +76,13 @@
|
|
|
72
76
|
|
|
73
77
|
/* Size variation */
|
|
74
78
|
.small .currentMetric {
|
|
75
|
-
font-size: var(--size-
|
|
79
|
+
font-size: var(--size-medium);
|
|
76
80
|
}
|
|
77
81
|
|
|
78
82
|
.large .currentMetric {
|
|
79
|
-
font-size: var(--size-
|
|
83
|
+
font-size: var(--size-xxlarge);
|
|
80
84
|
}
|
|
81
85
|
|
|
82
86
|
.large .baselineMetric {
|
|
83
|
-
font-size: var(--size-
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
.large .delta {
|
|
87
|
-
margin-left: var(--space-xxxsmall);
|
|
87
|
+
font-size: var(--size-small);
|
|
88
88
|
}
|
package/lib/css/variables.css
CHANGED
|
@@ -29,20 +29,20 @@
|
|
|
29
29
|
/*
|
|
30
30
|
* Color scheme:
|
|
31
31
|
* https://coolors.co/287acc-da444e-55b950-efcc1a-192339
|
|
32
|
-
* http://mcg.mbitson.com/#!?mcgpalette0=%23da444e&mcgpalette1=%2355b950&mcgpalette2=%23efcc1a&mcgpalette3=%
|
|
32
|
+
* http://mcg.mbitson.com/#!?mcgpalette0=%23da444e&mcgpalette1=%2355b950&mcgpalette2=%23efcc1a&mcgpalette3=%233e3c49&mcgpalette4=%23287acc&themename=bundle-stats
|
|
33
33
|
* https://hihayk.github.io/scale/#4/5/50/90/-51/0/0/14/353138/53/49/56/white
|
|
34
34
|
*/
|
|
35
35
|
--color-gray-25: #f9f9fa;
|
|
36
36
|
--color-gray-50: #e8e8e9;
|
|
37
|
-
--color-gray-100: #
|
|
38
|
-
--color-gray-200: #
|
|
39
|
-
--color-gray-300: #
|
|
40
|
-
--color-gray-400: #
|
|
41
|
-
--color-gray-500: #
|
|
42
|
-
--color-gray-600: #
|
|
43
|
-
--color-gray-700: #
|
|
44
|
-
--color-gray-800: #
|
|
45
|
-
--color-gray-900: #
|
|
37
|
+
--color-gray-100: #c5c5c8;
|
|
38
|
+
--color-gray-200: #9f9ea4;
|
|
39
|
+
--color-gray-300: #787780;
|
|
40
|
+
--color-gray-400: #5b5964;
|
|
41
|
+
--color-gray-500: #3e3c49;
|
|
42
|
+
--color-gray-600: #383642;
|
|
43
|
+
--color-gray-700: #302e39;
|
|
44
|
+
--color-gray-800: #282731;
|
|
45
|
+
--color-gray-900: #1b1a21;
|
|
46
46
|
|
|
47
47
|
--color-gray-ultra-light: var(--color-gray-200);
|
|
48
48
|
--color-gray-light: var(--color-gray-300);
|
|
@@ -192,9 +192,10 @@
|
|
|
192
192
|
--shadow-layer: 0 0 var(--space-xxxsmall) var(--color-shadow);
|
|
193
193
|
--shadow-layer-high: 0 0 var(--space-xxsmall) var(--color-shadow);
|
|
194
194
|
|
|
195
|
-
--radius-
|
|
196
|
-
--radius-
|
|
197
|
-
--radius-
|
|
195
|
+
--radius-xsmall: 3px;
|
|
196
|
+
--radius-small: 5px;
|
|
197
|
+
--radius-medium: 7px;
|
|
198
|
+
--radius-large: 9px;
|
|
198
199
|
|
|
199
200
|
--outline-hover: 0 0 0 3px var(--color-highlight);
|
|
200
201
|
|