@bundle-stats/ui 4.12.0 → 4.13.0-beta.0

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 (174) hide show
  1. package/lib/app/app.js +3 -7
  2. package/lib/app/app.js.map +1 -1
  3. package/lib/assets/icons.svg +26 -20
  4. package/lib/assets/icons.svg.js +27 -23
  5. package/lib/assets/icons.svg.js.map +1 -1
  6. package/lib/components/bundle-assets/bundle-assets.js +11 -3
  7. package/lib/components/bundle-assets/bundle-assets.js.map +1 -1
  8. package/lib/components/bundle-assets/index.js +3 -4
  9. package/lib/components/bundle-assets/index.js.map +1 -1
  10. package/lib/components/bundle-assets-totals/bundle-assets-totals.js +77 -0
  11. package/lib/components/bundle-assets-totals/bundle-assets-totals.js.map +1 -0
  12. package/lib/components/bundle-assets-totals/bundle-assets-totals.module.css +7 -0
  13. package/lib/{ui/horizontal-bar-chart → components/bundle-assets-totals}/index.js +1 -1
  14. package/lib/components/bundle-assets-totals/index.js.map +1 -0
  15. package/lib/components/bundle-modules/bundle-modules.js +9 -2
  16. package/lib/components/bundle-modules/bundle-modules.js.map +1 -1
  17. package/lib/components/bundle-modules/index.js +3 -4
  18. package/lib/components/bundle-modules/index.js.map +1 -1
  19. package/lib/components/bundle-packages/bundle-packages.js +10 -2
  20. package/lib/components/bundle-packages/bundle-packages.js.map +1 -1
  21. package/lib/components/bundle-packages/index.js +3 -4
  22. package/lib/components/bundle-packages/index.js.map +1 -1
  23. package/lib/components/index.js +3 -5
  24. package/lib/components/index.js.map +1 -1
  25. package/lib/components/{bundle-assets-totals-table → metrics-display-selector}/index.js +1 -1
  26. package/lib/components/metrics-display-selector/index.js.map +1 -0
  27. package/lib/components/metrics-display-selector/metrics-display-selector.js +27 -0
  28. package/lib/components/metrics-display-selector/metrics-display-selector.js.map +1 -0
  29. package/lib/components/metrics-display-selector/metrics-display-selector.module.css +10 -0
  30. package/lib/components/{bundle-assets-totals-chart-bars → metrics-treemap}/index.js +1 -1
  31. package/lib/components/metrics-treemap/index.js.map +1 -0
  32. package/lib/components/metrics-treemap/metrics-treemap.js +148 -0
  33. package/lib/components/metrics-treemap/metrics-treemap.js.map +1 -0
  34. package/lib/components/metrics-treemap/metrics-treemap.module.css +168 -0
  35. package/lib/constants.js +6 -1
  36. package/lib/constants.js.map +1 -1
  37. package/lib/hooks/metrics-display-type.js +40 -0
  38. package/lib/hooks/metrics-display-type.js.map +1 -0
  39. package/lib/hooks/show-entry.js +13 -0
  40. package/lib/hooks/show-entry.js.map +1 -0
  41. package/lib/ui/icon/icon.js +2 -0
  42. package/lib/ui/icon/icon.js.map +1 -1
  43. package/lib/ui/index.js +1 -3
  44. package/lib/ui/index.js.map +1 -1
  45. package/lib-esm/app/app.js +3 -7
  46. package/lib-esm/app/app.js.map +1 -1
  47. package/lib-esm/assets/icons.svg +26 -20
  48. package/lib-esm/assets/icons.svg.js +27 -23
  49. package/lib-esm/assets/icons.svg.js.map +1 -1
  50. package/lib-esm/components/bundle-assets/bundle-assets.js +11 -3
  51. package/lib-esm/components/bundle-assets/bundle-assets.js.map +1 -1
  52. package/lib-esm/components/bundle-assets/index.js +4 -5
  53. package/lib-esm/components/bundle-assets/index.js.map +1 -1
  54. package/lib-esm/components/bundle-assets-totals/bundle-assets-totals.js +47 -0
  55. package/lib-esm/components/bundle-assets-totals/bundle-assets-totals.js.map +1 -0
  56. package/lib-esm/components/bundle-assets-totals/bundle-assets-totals.module.css +7 -0
  57. package/lib-esm/components/bundle-assets-totals/index.js +2 -0
  58. package/lib-esm/components/bundle-assets-totals/index.js.map +1 -0
  59. package/lib-esm/components/bundle-modules/bundle-modules.js +9 -2
  60. package/lib-esm/components/bundle-modules/bundle-modules.js.map +1 -1
  61. package/lib-esm/components/bundle-modules/index.js +3 -4
  62. package/lib-esm/components/bundle-modules/index.js.map +1 -1
  63. package/lib-esm/components/bundle-packages/bundle-packages.js +10 -2
  64. package/lib-esm/components/bundle-packages/bundle-packages.js.map +1 -1
  65. package/lib-esm/components/bundle-packages/index.js +4 -5
  66. package/lib-esm/components/bundle-packages/index.js.map +1 -1
  67. package/lib-esm/components/index.js +1 -2
  68. package/lib-esm/components/index.js.map +1 -1
  69. package/lib-esm/components/metrics-display-selector/index.js +2 -0
  70. package/lib-esm/components/metrics-display-selector/index.js.map +1 -0
  71. package/lib-esm/components/metrics-display-selector/metrics-display-selector.js +20 -0
  72. package/lib-esm/components/metrics-display-selector/metrics-display-selector.js.map +1 -0
  73. package/lib-esm/components/metrics-display-selector/metrics-display-selector.module.css +10 -0
  74. package/lib-esm/components/metrics-treemap/index.js +2 -0
  75. package/lib-esm/components/metrics-treemap/index.js.map +1 -0
  76. package/lib-esm/components/metrics-treemap/metrics-treemap.js +119 -0
  77. package/lib-esm/components/metrics-treemap/metrics-treemap.js.map +1 -0
  78. package/lib-esm/components/metrics-treemap/metrics-treemap.module.css +168 -0
  79. package/lib-esm/constants.js +5 -0
  80. package/lib-esm/constants.js.map +1 -1
  81. package/lib-esm/hooks/metrics-display-type.js +36 -0
  82. package/lib-esm/hooks/metrics-display-type.js.map +1 -0
  83. package/lib-esm/hooks/show-entry.js +9 -0
  84. package/lib-esm/hooks/show-entry.js.map +1 -0
  85. package/lib-esm/ui/icon/icon.js +2 -0
  86. package/lib-esm/ui/icon/icon.js.map +1 -1
  87. package/lib-esm/ui/index.js +0 -1
  88. package/lib-esm/ui/index.js.map +1 -1
  89. package/package.json +11 -6
  90. package/src/app/app.jsx +4 -8
  91. package/src/assets/icons/table.svg +3 -0
  92. package/src/assets/icons/treemap.svg +4 -0
  93. package/src/assets/icons.svg +26 -20
  94. package/src/assets/icons.svg.jsx +91 -55
  95. package/src/components/bundle-assets/bundle-assets.jsx +25 -11
  96. package/src/components/bundle-assets/index.jsx +4 -4
  97. package/src/components/bundle-assets-totals/bundle-assets-totals.jsx +94 -0
  98. package/src/components/bundle-assets-totals/bundle-assets-totals.module.css +7 -0
  99. package/src/components/bundle-assets-totals/index.js +1 -0
  100. package/src/components/bundle-modules/bundle-modules.tsx +26 -12
  101. package/src/components/bundle-modules/index.tsx +4 -3
  102. package/src/components/bundle-packages/bundle-packages.jsx +24 -10
  103. package/src/components/bundle-packages/index.jsx +4 -4
  104. package/src/components/index.js +1 -2
  105. package/src/components/metrics-display-selector/index.tsx +1 -0
  106. package/src/components/metrics-display-selector/metrics-display-selector.module.css +10 -0
  107. package/src/components/metrics-display-selector/metrics-display-selector.tsx +51 -0
  108. package/src/components/metrics-treemap/index.ts +1 -0
  109. package/src/components/metrics-treemap/metrics-treemap.module.css +168 -0
  110. package/src/components/metrics-treemap/metrics-treemap.stories.tsx +23 -0
  111. package/src/components/metrics-treemap/metrics-treemap.tsx +271 -0
  112. package/src/{constants.js → constants.ts} +5 -0
  113. package/src/hooks/metrics-display-type.ts +56 -0
  114. package/src/hooks/show-entry.ts +17 -0
  115. package/src/types.d.ts +2 -0
  116. package/src/ui/icon/icon.tsx +2 -0
  117. package/src/ui/index.js +0 -1
  118. package/types/components/bundle-assets/bundle-assets.d.ts +2 -1
  119. package/types/components/{bundle-assets-totals-table/bundle-assets-totals-table.d.ts → bundle-assets-totals/bundle-assets-totals.d.ts} +2 -2
  120. package/types/components/bundle-assets-totals/index.d.ts +1 -0
  121. package/types/components/bundle-modules/bundle-modules.d.ts +2 -1
  122. package/types/components/bundle-modules/index.d.ts +1 -1
  123. package/types/components/bundle-packages/bundle-packages.d.ts +1 -0
  124. package/types/components/index.d.ts +1 -2
  125. package/types/components/metrics-display-selector/index.d.ts +1 -0
  126. package/types/components/metrics-display-selector/metrics-display-selector.d.ts +9 -0
  127. package/types/components/metrics-treemap/index.d.ts +1 -0
  128. package/types/components/metrics-treemap/metrics-treemap.d.ts +9 -0
  129. package/types/constants.d.ts +19 -15
  130. package/types/hooks/metrics-display-type.d.ts +4 -0
  131. package/types/hooks/show-entry.d.ts +10 -0
  132. package/types/ui/icon/icon.d.ts +4 -0
  133. package/types/ui/index.d.ts +0 -1
  134. package/lib/components/bundle-assets-totals-chart-bars/bundle-assets-totals-chart-bars.js +0 -95
  135. package/lib/components/bundle-assets-totals-chart-bars/bundle-assets-totals-chart-bars.js.map +0 -1
  136. package/lib/components/bundle-assets-totals-chart-bars/bundle-assets-totals-chart-bars.module.css +0 -42
  137. package/lib/components/bundle-assets-totals-chart-bars/index.js.map +0 -1
  138. package/lib/components/bundle-assets-totals-table/bundle-assets-totals-table.js +0 -57
  139. package/lib/components/bundle-assets-totals-table/bundle-assets-totals-table.js.map +0 -1
  140. package/lib/components/bundle-assets-totals-table/bundle-assets-totals-table.module.css +0 -3
  141. package/lib/components/bundle-assets-totals-table/index.js.map +0 -1
  142. package/lib/ui/horizontal-bar-chart/horizontal-bar-chart.js +0 -102
  143. package/lib/ui/horizontal-bar-chart/horizontal-bar-chart.js.map +0 -1
  144. package/lib/ui/horizontal-bar-chart/horizontal-bar-chart.module.css +0 -42
  145. package/lib/ui/horizontal-bar-chart/index.js.map +0 -1
  146. package/lib-esm/components/bundle-assets-totals-chart-bars/bundle-assets-totals-chart-bars.js +0 -66
  147. package/lib-esm/components/bundle-assets-totals-chart-bars/bundle-assets-totals-chart-bars.js.map +0 -1
  148. package/lib-esm/components/bundle-assets-totals-chart-bars/bundle-assets-totals-chart-bars.module.css +0 -42
  149. package/lib-esm/components/bundle-assets-totals-chart-bars/index.js +0 -2
  150. package/lib-esm/components/bundle-assets-totals-chart-bars/index.js.map +0 -1
  151. package/lib-esm/components/bundle-assets-totals-table/bundle-assets-totals-table.js +0 -27
  152. package/lib-esm/components/bundle-assets-totals-table/bundle-assets-totals-table.js.map +0 -1
  153. package/lib-esm/components/bundle-assets-totals-table/bundle-assets-totals-table.module.css +0 -3
  154. package/lib-esm/components/bundle-assets-totals-table/index.js +0 -2
  155. package/lib-esm/components/bundle-assets-totals-table/index.js.map +0 -1
  156. package/lib-esm/ui/horizontal-bar-chart/horizontal-bar-chart.js +0 -96
  157. package/lib-esm/ui/horizontal-bar-chart/horizontal-bar-chart.js.map +0 -1
  158. package/lib-esm/ui/horizontal-bar-chart/horizontal-bar-chart.module.css +0 -42
  159. package/lib-esm/ui/horizontal-bar-chart/index.js +0 -2
  160. package/lib-esm/ui/horizontal-bar-chart/index.js.map +0 -1
  161. package/src/components/bundle-assets-totals-chart-bars/bundle-assets-totals-chart-bars.jsx +0 -106
  162. package/src/components/bundle-assets-totals-chart-bars/bundle-assets-totals-chart-bars.module.css +0 -42
  163. package/src/components/bundle-assets-totals-chart-bars/index.js +0 -1
  164. package/src/components/bundle-assets-totals-table/bundle-assets-totals-table.jsx +0 -55
  165. package/src/components/bundle-assets-totals-table/bundle-assets-totals-table.module.css +0 -3
  166. package/src/components/bundle-assets-totals-table/index.js +0 -1
  167. package/src/ui/horizontal-bar-chart/horizontal-bar-chart.jsx +0 -156
  168. package/src/ui/horizontal-bar-chart/horizontal-bar-chart.module.css +0 -42
  169. package/src/ui/horizontal-bar-chart/index.js +0 -1
  170. package/types/components/bundle-assets-totals-chart-bars/bundle-assets-totals-chart-bars.d.ts +0 -22
  171. package/types/components/bundle-assets-totals-chart-bars/index.d.ts +0 -1
  172. package/types/components/bundle-assets-totals-table/index.d.ts +0 -1
  173. package/types/ui/horizontal-bar-chart/horizontal-bar-chart.d.ts +0 -23
  174. package/types/ui/horizontal-bar-chart/index.d.ts +0 -1
@@ -0,0 +1,119 @@
1
+ import React, { forwardRef, useCallback, useMemo, useRef, useState } from 'react';
2
+ import cx from 'classnames';
3
+ import { useMeasure } from 'react-use';
4
+ import { hierarchy, treemap, treemapSquarify } from 'd3';
5
+ import { FloatingPortal, useClientPoint, useFloating, useHover, useInteractions, } from '@floating-ui/react';
6
+ import { arrow, offset } from '@floating-ui/react-dom';
7
+ import { Stack } from '../../layout/stack';
8
+ import { FileName } from '../../ui/file-name';
9
+ import { Delta } from '../delta';
10
+ import { RunInfo } from '../run-info';
11
+ import css from './metrics-treemap.module.css';
12
+ const SQUARIFY_RATIO = 1.78;
13
+ const PADDING_OUTER = 0;
14
+ const PADDING_INNER = 1;
15
+ const PADDING_TOP = 4;
16
+ const PADDING_BOTTOM = 2;
17
+ const PADDING_LEFT = 16;
18
+ const PADDING_RIGHT = 4;
19
+ const VERTICAL_SPACING = 4;
20
+ const LINE_HEIGHT = 16;
21
+ const LINE_HEIGHT_SMALL = 13.3;
22
+ function resolveTileSizeDisplay(width, height) {
23
+ if (height > PADDING_TOP + PADDING_BOTTOM + VERTICAL_SPACING + LINE_HEIGHT * 2 &&
24
+ width > PADDING_LEFT + PADDING_RIGHT + 96) {
25
+ return 'default';
26
+ }
27
+ if (height > PADDING_TOP + PADDING_BOTTOM + LINE_HEIGHT_SMALL * 2 &&
28
+ width > PADDING_LEFT + PADDING_BOTTOM + 48) {
29
+ return 'small';
30
+ }
31
+ return 'minimal';
32
+ }
33
+ const TooltipContent = (props) => {
34
+ const { data } = props;
35
+ const currentRun = data.runs[0];
36
+ const baselineRun = data.runs[data.runs.length - 1];
37
+ return (React.createElement(Stack, { space: "small", className: css.tooltipContent },
38
+ React.createElement("h3", { className: css.tooltipContentTitle },
39
+ React.createElement(FileName, { as: "code", name: data.label })),
40
+ React.createElement(RunInfo, { current: currentRun.displayValue, delta: currentRun.displayDeltaPercentage, deltaType: currentRun.deltaType, baseline: (baselineRun === null || baselineRun === void 0 ? void 0 : baselineRun.displayValue) || '0B' })));
41
+ };
42
+ const TileButton = forwardRef((props, ref) => (React.createElement("button", { type: "button", xmlns: "http://www.w3.org/1999/xhtml", ref: ref, ...props })));
43
+ const Tile = (props) => {
44
+ var _a, _b;
45
+ const { x, y, width, height, data, onClick } = props;
46
+ const { item } = data;
47
+ const runInfo = (_a = item.runs) === null || _a === void 0 ? void 0 : _a[0];
48
+ const [isOpen, setIsOpen] = useState(false);
49
+ const arrowRef = useRef(null);
50
+ const { refs, floatingStyles, context, middlewareData } = useFloating({
51
+ placement: 'top',
52
+ open: isOpen,
53
+ onOpenChange: setIsOpen,
54
+ middleware: [arrow({ element: arrowRef }), offset(16)],
55
+ });
56
+ const clientPoint = useClientPoint(context);
57
+ const hover = useHover(context);
58
+ const { getReferenceProps, getFloatingProps } = useInteractions([hover, clientPoint]);
59
+ const tileSizeDisplay = useMemo(() => resolveTileSizeDisplay(width, height), [width, height]);
60
+ const handleOnClick = useCallback(() => {
61
+ if (onClick) {
62
+ onClick(item.key);
63
+ }
64
+ }, [item.key]);
65
+ return (React.createElement("g", { className: cx(css.tile, !item.changed && css['tile-NO_CHANGE'], css[`tile-${runInfo.deltaType}`], tileSizeDisplay === 'small' && css.tileSmall) },
66
+ React.createElement("rect", { x: x, y: y, width: width, height: height, className: css.tileOverlay }),
67
+ React.createElement("foreignObject", { height: height, width: width, x: x, y: y },
68
+ React.createElement(TileButton, { onClick: handleOnClick, className: css.tileContent, ref: refs.setReference, ...getReferenceProps() }, tileSizeDisplay !== 'minimal' && (React.createElement("div", { className: css.tileContentWrapper },
69
+ React.createElement("p", { className: css.tileContentLabel }, item.label),
70
+ React.createElement("p", { className: css.tileContentValue },
71
+ React.createElement("span", { className: css.tileContentMetric }, runInfo.displayValue),
72
+ React.createElement(Delta, { className: css.tileContentDelta, displayValue: runInfo.displayDeltaPercentage, deltaType: runInfo.deltaType }))))),
73
+ isOpen && (React.createElement(FloatingPortal, null,
74
+ React.createElement("div", { ref: refs.setFloating, style: floatingStyles, ...getFloatingProps(), className: css.tooltip },
75
+ React.createElement("div", { ref: arrowRef, style: { left: (_b = middlewareData.arrow) === null || _b === void 0 ? void 0 : _b.x }, className: css.tooltipArrow }),
76
+ React.createElement(TooltipContent, { data: item })))))));
77
+ };
78
+ export const MetricsTreemap = (props) => {
79
+ const { className = '', items, onItemClick, emptyMessage = 'No data', ...restProps } = props;
80
+ const [containerRef, { width, height }] = useMeasure();
81
+ const treemapHierarchy = useMemo(() => {
82
+ const children = items.map((item) => {
83
+ const values = item.runs.map((run) => (run === null || run === void 0 ? void 0 : run.value) || 0);
84
+ const value = Math.max(...values);
85
+ return {
86
+ id: item.key,
87
+ value,
88
+ item,
89
+ };
90
+ });
91
+ const treemapData = {
92
+ id: 'root',
93
+ name: 'root',
94
+ value: 0,
95
+ children,
96
+ };
97
+ const customHierarchy = hierarchy(treemapData);
98
+ customHierarchy.sum((node) => node.value);
99
+ customHierarchy.sort((a, b) => b.value - a.value);
100
+ return customHierarchy;
101
+ }, [items]);
102
+ const cells = useMemo(() => {
103
+ const createTremapLayout = treemap()
104
+ .size([width, height])
105
+ .tile(treemapSquarify.ratio(SQUARIFY_RATIO))
106
+ .paddingOuter(PADDING_OUTER)
107
+ .paddingInner(PADDING_INNER);
108
+ const tremapLayout = createTremapLayout(treemapHierarchy);
109
+ return tremapLayout.leaves().filter((leaf) => Boolean(leaf.parent));
110
+ }, [height, width, treemapHierarchy]);
111
+ return (React.createElement("div", { className: cx(css.root, className), ...restProps, ref: containerRef }, cells.length > 0 ? (React.createElement("svg", { width: width, height: height, viewBox: `0 0 ${width} ${height}`, className: css.canvas }, cells.map((leaf) => {
112
+ if (!leaf.parent) {
113
+ return null;
114
+ }
115
+ return (React.createElement(Tile, { x: leaf.x0, y: leaf.y0, width: leaf.x1 - leaf.x0, height: leaf.y1 - leaf.y0, data: leaf.data, key: leaf.id, onClick: onItemClick }));
116
+ }))) : (React.createElement("div", { className: css.emptyMessage },
117
+ React.createElement("div", { className: css.emptyMessageWrapper }, emptyMessage)))));
118
+ };
119
+ //# sourceMappingURL=metrics-treemap.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"metrics-treemap.js","sourceRoot":"","sources":["../../../src/components/metrics-treemap/metrics-treemap.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,UAAU,EAAE,WAAW,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAClF,OAAO,EAAE,MAAM,YAAY,CAAC;AAC5B,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAEvC,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,eAAe,EAAE,MAAM,IAAI,CAAC;AACzD,OAA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,CAAC,CAAC,CACF,6BAAK,SAAS,EAAE,GAAG,CAAC,YAAY;QAC9B,6BAAK,SAAS,EAAE,GAAG,CAAC,mBAAmB,IAAG,YAAY,CAAO,CACzD,CACP,CACG,CACP,CAAC;AACJ,CAAC,CAAC"}
@@ -0,0 +1,168 @@
1
+ .root {
2
+ position: relative;
3
+ aspect-ratio: 16/9;
4
+ background: var(--color-background);
5
+ }
6
+
7
+ .canvas {
8
+ position: absolute;
9
+ left: 0;
10
+ top: 0;
11
+ width: 100%;
12
+ height: 100%;
13
+ fill: var(--color-text);
14
+ font-family: var(--font-family);
15
+ }
16
+
17
+ /** Tile overlay fill background transition */
18
+ .root {
19
+ transition: var(--ui-transition-out);
20
+ transition-property: opacity;
21
+ }
22
+
23
+ .tileOverlay {
24
+ fill: var(--color-outline);
25
+ transition: var(--ui-transition-out);
26
+ transition-property: opacity;
27
+ opacity: 0.4;
28
+ }
29
+
30
+ .root .tile:hover .tileOverlay {
31
+ transition: var(--ui-transition-in);
32
+ opacity: 0.8;
33
+ }
34
+
35
+ /** Tile content */
36
+ .tileContent {
37
+ appearance: none;
38
+ border: 0;
39
+ border-radius: none;
40
+ padding: 0;
41
+ background: none;
42
+
43
+ width: 100%;
44
+ height: 100%;
45
+ padding: var(--space-xxsmall) var(--space-small);
46
+ display: flex;
47
+ align-items: center;
48
+ font-family: var(--font-family-fixed);
49
+ font-size: var(--size-small);
50
+ line-height: var(--line-height-heading);
51
+ text-align: left;
52
+ }
53
+
54
+ .tileContentWrapper {
55
+ width: 100%;
56
+ max-height: 100%;
57
+ display: flex;
58
+ flex-flow: column;
59
+ gap: 4px;
60
+ }
61
+
62
+ .tileContentLabel {
63
+ margin-right: calc(0px - var(--space-xxsmall)); /* take more space if necessary */
64
+ margin-bottom: calc(0px - 2px);
65
+ flex: 1 1 auto;
66
+ max-width: calc(100% + var(--space-xxsmall)); /* take more space if necessary */
67
+ overflow: hidden;
68
+ word-break: break-word;
69
+ }
70
+
71
+ .tileContentValue {
72
+ flex: 0 0 auto;
73
+ max-width: calc(100% + var(--space-xxsmall));
74
+ margin-right: calc(0px - var(--space-xxsmall)); /* take more space if necessary */
75
+ white-space: nowrap;
76
+ overflow: hidden;
77
+ }
78
+
79
+ .tileContentMetric {
80
+ font-weight: bold;
81
+ }
82
+
83
+ .tileContentDelta {
84
+ margin-left: var(--space-xxxsmall);
85
+ }
86
+
87
+ /** Tile size variation */
88
+ .tileSmall .tileContent {
89
+ font-size: var(--size-xsmall);
90
+ }
91
+
92
+ .tileSmall .tileContentLabel {
93
+ margin-top: 0;
94
+ }
95
+
96
+ /** Tile diff variation */
97
+ .tile-NO_CHANGE .tileContent {
98
+ color: var(--color-text-light);
99
+ }
100
+
101
+ .tile-HIGH_NEGATIVE .tileOverlay {
102
+ fill: var(--color-red-100);
103
+ }
104
+
105
+ .tile-NEGATIVE .tileOverlay {
106
+ fill: var(--color-red-50);
107
+ }
108
+
109
+ .tile-LOW_NEGATIVE .tileOverlay {
110
+ fill: var(--color-red-25);
111
+ }
112
+
113
+ .tile-LOW_POSITIVE .tileOverlay {
114
+ fill: var(--color-green-25);
115
+ }
116
+
117
+ .tile-POSITIVE .tileOverlay {
118
+ fill: var(--color-green-50);
119
+ }
120
+
121
+ .tile-HIGH_POSITIVE .tileOverlay {
122
+ fill: var(--color-green-100);
123
+ }
124
+
125
+
126
+ /** empty message */
127
+ .emptyMessage {
128
+ position: absolute;
129
+ left: 0;
130
+ top: 0;
131
+ width: 100%;
132
+ height: 100%;
133
+ display: flex;
134
+ align-items: center;
135
+ justify-content: center;
136
+ }
137
+
138
+ .emptyMessageWrapper {
139
+ max-width: 100%;
140
+ text-align: center;
141
+ }
142
+
143
+ /** tooltip content */
144
+ .tooltip {
145
+ z-index: var(--layer-xxhigh);
146
+ padding: var(--space-xsmall) var(--space-small);
147
+ border-radius: var(--radius-medium);
148
+ width: calc(100vw - 2 * var(--space-small));
149
+ max-width: 340px;
150
+ outline: none;
151
+ filter: drop-shadow(var(--shadow-layer-high));
152
+ will-change: filter;
153
+ background: var(--color-light);
154
+ font-size: var(--size-small);
155
+ }
156
+
157
+ .tooltipArrow {
158
+ border: var(--space-xxsmall) solid var(--color-background);
159
+ border-width: var(--space-xxsmall) var(--space-xxsmall) 0;
160
+ border-left-color: transparent;
161
+ border-right-color: transparent;
162
+ position: absolute;
163
+ top: 100%;
164
+ }
165
+
166
+ .tooltipContentTitle {
167
+ font-size: var(--size-medium);
168
+ }
@@ -32,4 +32,9 @@ export const SORT = {
32
32
  ASC: 'asc',
33
33
  DESC: 'desc',
34
34
  };
35
+ export var MetricsDisplayType;
36
+ (function (MetricsDisplayType) {
37
+ MetricsDisplayType["TABLE"] = "table";
38
+ MetricsDisplayType["TREEMAP"] = "treemap";
39
+ })(MetricsDisplayType || (MetricsDisplayType = {}));
35
40
  //# sourceMappingURL=constants.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"","sources":["../src/constants.js"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAE3D,MAAM,CAAC,MAAM,IAAI,GAAG;IAClB,QAAQ,EAAE,GAAG;IACb,MAAM,EAAE,SAAS;IACjB,OAAO,EAAE,UAAU;IACnB,QAAQ,EAAE,WAAW;CACtB,CAAC;AAEF,MAAM,CAAC,MAAM,YAAY,GAAG;IAC1B,CAAC,QAAQ,CAAC,MAAM,CAAC,EAAE,IAAI,CAAC,QAAQ;IAChC,CAAC,QAAQ,CAAC,MAAM,CAAC,EAAE,IAAI,CAAC,MAAM;IAC9B,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,OAAO;IAChC,CAAC,QAAQ,CAAC,QAAQ,CAAC,EAAE,IAAI,CAAC,QAAQ;CACnC,CAAC;AAEF,MAAM,CAAC,MAAM,0BAA0B,GAAG,UAAU,CAAC,MAAM,CACzD,CAAC,GAAG,EAAE,QAAQ,EAAE,EAAE,CAAC,CAAC;IAClB,GAA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AC,CAAC;IAClB,GAAG,GAAG;IACN,CAAC,gCAAgC,QAAQ,EAAE,CAAC,EAAE,QAAQ;CACvD,CAAC,EACF,EAAE,CACH,CAAC;AAEF,MAAM,CAAC,MAAM,uBAAuB,GAAG;IACrC,4BAA4B;IAC5B,4BAA4B;IAC5B,6BAA6B;IAC7B,2BAA2B;CAC5B,CAAC;AACF,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,oBAAoB,EAAE,oBAAoB,CAAC,CAAC;AACnF,MAAM,CAAC,MAAM,uBAAuB,GAAG;IACrC,qBAAqB;IACrB,+BAA+B;IAC/B,uBAAuB;CACxB,CAAC;AACF,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,sBAAsB,EAAE,gCAAgC,CAAC,CAAC;AAEnG,MAAM,CAAC,MAAM,IAAI,GAAG;IAClB,GAAG,EAAE,KAAK;IACV,IAAI,EAAE,MAAM;CACb,CAAC;AAEF,MAAM,CAAN,IAAY,kBAGX;AAHD,WAAY,kBAAkB;IAC5B,qCAAe,CAAA;IACf,yCAAmB,CAAA;AACrB,CAAC,EAHW,kBAAkB,KAAlB,kBAAkB,QAG7B"}
@@ -0,0 +1,36 @@
1
+ import { useCallback, useEffect, useMemo } from 'react';
2
+ import { useLocalStorage } from 'react-use';
3
+ import { StringParam, useQueryParams } from 'use-query-params';
4
+ import { MetricsDisplayType } from '../constants';
5
+ const DEFAULT_DISPLAY_TYPE = MetricsDisplayType.TABLE;
6
+ const PARAM_NAME = 'dt';
7
+ export const useMetricsDisplayType = () => {
8
+ const [{ [PARAM_NAME]: queryDisplayType }, setQueryParams] = useQueryParams({
9
+ [PARAM_NAME]: StringParam,
10
+ });
11
+ const [storageDisplayType, setStoreageDisplayType] = useLocalStorage(PARAM_NAME, MetricsDisplayType.TABLE);
12
+ const displayType = useMemo(() => {
13
+ const value = queryDisplayType || storageDisplayType;
14
+ if (!value) {
15
+ return DEFAULT_DISPLAY_TYPE;
16
+ }
17
+ if (!Object.values(MetricsDisplayType).includes(value)) {
18
+ return DEFAULT_DISPLAY_TYPE;
19
+ }
20
+ return value;
21
+ }, [queryDisplayType, storageDisplayType]);
22
+ useEffect(() => {
23
+ if (queryDisplayType !== displayType) {
24
+ setQueryParams({ [PARAM_NAME]: displayType });
25
+ }
26
+ if (storageDisplayType !== displayType) {
27
+ setStoreageDisplayType(queryDisplayType);
28
+ }
29
+ }, [displayType, queryDisplayType, storageDisplayType, setQueryParams, setStoreageDisplayType]);
30
+ const setDisplayType = useCallback((value) => {
31
+ setStoreageDisplayType(value);
32
+ setQueryParams({ [PARAM_NAME]: value });
33
+ }, [setStoreageDisplayType, setQueryParams]);
34
+ return [displayType, setDisplayType];
35
+ };
36
+ //# sourceMappingURL=metrics-display-type.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"metrics-display-type.js","sourceRoot":"","sources":["../../src/hooks/metrics-display-type.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AACxD,OAAO,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAE/D,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAElD,MAAM,oBAAoB,GAAG,kBAAkB,CAAC,KAAK,CAAC;AACtD,MAAM,UAAU,GAAG,IAAI,CAAC;AAIxB,MAAM,CAAC,MAAM,qBAAqB,GAAG,GAA0B,EAAE;IAC/D,MAAM,CAAC,EAAE,CAAC,UAAU,CAAC,EAAE,gBAAgB,EAAE,EAAE,cAAc,CAAC,GAAG,cAAc,CAAC;QAC1E,CAAC,UAAU,CAAC,EAAE,WAAW;KAC1B,CAAC,CAAC;IACH,MAAM,CAAC,kBAAkB,EAAE,sBAAsB,CAAC,GAAG,eAAe,CAClE,UAAU,EACV,kBAAkB,CAAC,KAAK,CACzB,CAAC;IAEF,MAAM,WAAW,GAAG,OAAO,CAAC,GAAG,EAAE;QAC/B,MAAM,KAAK,GAAG,gBAAgB,IAAI,kBAAkB,CAAC;QAErD,IAAI,CAAC,KAAK,EAAE;YACV,OAAO,oBAAoB,CAAC;SAC7B;QAED,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,kBAAkB,CAAC,CAAC,QAAQ,CAAC,KAA2B,CAAC,EAAE;YAC5E,OAAO,oBAAoB,CAAC;SAC7B;QAED,OAAO,KAA2B,CAAC;IACrC,CAAC,EAAE,CAAC,gBAAgB,EAAE,kBAAkB,CAAC,CAAC,CAAC;IAE3C,SAAS,CAAC,GAAG,EAAE;QAEb,IAAI,gBAAgB,KAAK,WAAW,EAAE;YACpC,cAAc,CAAC,EAAE,CAAC,UAAU,CAAC,EAAE,WAAW,EAAE,CAAC,CAAC;SAC/C;QAGD,IAAI,kBAAkB,KAAK,WAAW,EAAE;YACtC,sBAAsB,CAAC,gBAAsC,CAAC,CAAC;SAChE;IACH,CAAC,EAAE,CAAC,WAAW,EAAE,gBAAgB,EAAE,kBAAkB,EAAE,cAAc,EAAE,sBAAsB,CAAC,CAAC,CAAC;IAEhG,MAAM,cAAc,GAAG,WAAW,CAChC,CAAC,KAAyB,EAAE,EAAE;QAC5B,sBAAsB,CAAC,KAAK,CAAC,CAAC;QAC9B,cAAc,CAAC,EAAE,CAAC,UAAU,CAAC,EAAE,KAAK,EAAE,CAAC,CAAC;IAC1C,CAAC,EACD,CAAC,sBAAsB,EAAE,cAAc,CAAC,CACzC,CAAC;IAEF,OAAO,CAAC,WAAW,EAAE,cAAc,CAAC,CAAC;AACvC,CAAC,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { useMemo } from 'react';
2
+ export const useShowEntry = (params) => {
3
+ const { setState } = params;
4
+ return useMemo(() => ({
5
+ hideEntryInfo: () => setState({ entryId: '' }),
6
+ showEntryInfo: (entryId) => setState({ entryId }),
7
+ }), [setState]);
8
+ };
9
+ //# sourceMappingURL=show-entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"show-entry.js","sourceRoot":"","sources":["../../src/hooks/show-entry.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAMhC,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,MAAwB,EAAE,EAAE;IACvD,MAAM,EAAE,QAAQ,EAAE,GAAG,MAAM,CAAC;IAE5B,OAAO,OAAO,CACZ,GAAG,EAAE,CAAC,CAAC;QACL,aAAa,EAAE,GAAG,EAAE,CAAC,QAAQ,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;QAC9C,aAAa,EAAE,CAAC,OAAe,EAAE,EAAE,CAAC,QAAQ,CAAC,EAAE,OAAO,EAAE,CAAC;KAC1D,CAAC,EACF,CAAC,QAAQ,CAAC,CACX,CAAC;AACJ,CAAC,CAAC"}
@@ -16,6 +16,8 @@ const ICONS = {
16
16
  GITHUB: 'github',
17
17
  INFO: 'info',
18
18
  HELP: 'help',
19
+ TABLE: 'table',
20
+ TREEMAP: 'treemap',
19
21
  MENU: 'menu',
20
22
  MORE_VERTICAL: 'more-vertical',
21
23
  SORT: 'sort',
@@ -1 +1 @@
1
- {"version":3,"file":"icon.js","sourceRoot":"","sources":["../../../src/ui/icon/icon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,MAAM,YAAY,CAAC;AAE5B,OAAO,GAAG,MAAM,mBAAmB,CAAC;AAEpC,MAAM,KAAK,GAAG;IACZ,KAAK,EAAE,OAAO;IACd,kBAAkB,EAAE,oBAAoB;IACxC,MAAM,EAAE,OAAO;IACf,YAAY,EAAE,cAAc;IAC5B,UAAU,EAAE,YAAY;IACxB,KAAK,EAAE,OAAO;IACd,KAAK,EAAE,OAAO;IACd,MAAM,EAAE,QAAQ;IAChB,KAAK,EAAE,OAAO;IACd,aAAa,EAAE,eAAe;IAC9B,MAAM,EAAE,QAAQ;IAChB,MAAM,EAAE,QAAQ;IAChB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,WAAW,GAAG,IAAI,CAAC,MAAM,CAAC;AAC/B,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,KAAK,CAAC;AAC7B,IAAI,CAAC,KAAK,GAAG,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC"}
@@ -6,7 +6,6 @@ export { Dropdown } from './dropdown';
6
6
  export { EmptySet } from './empty-set';
7
7
  export { FileName } from './file-name';
8
8
  export { Filters } from './filters';
9
- export { HorizontalBarChart } from './horizontal-bar-chart';
10
9
  export { HoverCard } from './hover-card';
11
10
  export { Icon } from './icon';
12
11
  export { Input } from './input';
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/ui/index.js"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAC5D,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAC5B,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/ui/index.js"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAC5B,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bundle-stats/ui",
3
- "version": "4.12.0",
3
+ "version": "4.13.0-beta.0",
4
4
  "description": "UI components for BundleStats projects.",
5
5
  "main": "lib/index.js",
6
6
  "module": "lib-esm/index.js",
@@ -15,7 +15,7 @@
15
15
  "build-assets-esm": "rsync -arm --include '*/' --include '*.json' --include '*.css' --include 'icons.svg' --exclude '*' src/ lib-esm",
16
16
  "build-storybook": "storybook build -c ./build/storybook",
17
17
  "generate-chart-colors": "node scripts/generate-chart-colors.js",
18
- "generate-svg-sprite": "npx svg-sprite -s --si --no-svg-namespace-classnames src/assets/icons/*.svg && mv symbol/svg/sprite.symbol.svg src/assets/icons.svg",
18
+ "generate-svg-sprite": "npx svg-sprite -s --si --no-svg-namespace-classnames src/assets/icons/*.svg && mv symbol/svg/sprite.css.svg src/assets/icons.svg",
19
19
  "lint": "eslint",
20
20
  "start": "cross-env NODE_ENV=development storybook dev -c ./build/storybook -p 8080",
21
21
  "test": "jest src --passWithNoTests"
@@ -36,13 +36,14 @@
36
36
  },
37
37
  "homepage": "https://github.com/relative-ci/bundle-stats/blob/master/packages/ui#readme",
38
38
  "devDependencies": {
39
- "@babel/preset-env": "7.23.9",
39
+ "@babel/preset-env": "7.24.0",
40
40
  "@babel/preset-react": "7.23.3",
41
41
  "@babel/preset-typescript": "7.23.3",
42
42
  "@storybook/addon-essentials": "7.6.17",
43
43
  "@storybook/react": "7.6.17",
44
44
  "@storybook/react-webpack5": "7.6.17",
45
- "@types/react": "18.2.60",
45
+ "@types/d3": "7.4.3",
46
+ "@types/react": "18.2.64",
46
47
  "@types/react-router-dom": "5.3.3",
47
48
  "babel-plugin-require-context-hook": "1.0.0",
48
49
  "classnames": "2.5.1",
@@ -72,10 +73,14 @@
72
73
  "react-router-dom": "^5.0.0"
73
74
  },
74
75
  "dependencies": {
75
- "@bundle-stats/utils": "^4.12.0",
76
+ "@bundle-stats/utils": "4.13.0-beta.0",
77
+ "@floating-ui/react": "0.26.9",
78
+ "@floating-ui/react-dom": "2.0.8",
76
79
  "ariakit": "2.0.0-next.44",
80
+ "d3": "^7.8.5",
77
81
  "modern-css-reset": "1.4.0",
82
+ "react-use": "^17.5.0",
78
83
  "use-query-params": "2.2.1"
79
84
  },
80
- "gitHead": "e5b069c804249e9b11295de52bed1893a419a10a"
85
+ "gitHead": "f8197677d480f9b0b2112456526c821f49ed5a7d"
81
86
  }
package/src/app/app.jsx CHANGED
@@ -6,14 +6,12 @@ import { COMPONENT } from '@bundle-stats/utils';
6
6
 
7
7
  import { URLS } from '../constants';
8
8
  import { BundleAssets } from '../components/bundle-assets';
9
- import { BundleAssetsTotalsChartBars } from '../components/bundle-assets-totals-chart-bars';
10
- import { BundleAssetsTotalsTable } from '../components/bundle-assets-totals-table';
9
+ import { BundleAssetsTotals } from '../components/bundle-assets-totals';
11
10
  import { BundleModules } from '../components/bundle-modules';
12
11
  import { BundlePackages } from '../components/bundle-packages';
13
12
  import { Insights } from '../components/insights';
14
13
  import { MetricsTableTitle } from '../components';
15
14
  import { Summary } from '../components/summary';
16
- import { TotalSizeTypeTitle } from '../components/total-size-type-title';
17
15
  import { Box } from '../layout/box';
18
16
  import { Footer } from '../layout/footer';
19
17
  import { Stack } from '../layout/stack';
@@ -99,11 +97,9 @@ const OverviewContent = () => {
99
97
  </Container>
100
98
  )}
101
99
  <Container>
102
- <Stack space="small">
103
- <TotalSizeTypeTitle />
104
- <BundleAssetsTotalsChartBars jobs={jobs} />
105
- <BundleAssetsTotalsTable jobs={jobs} outline />
106
- </Stack>
100
+ <Box outline>
101
+ <BundleAssetsTotals jobs={jobs} />
102
+ </Box>
107
103
  </Container>
108
104
  </Stack>
109
105
  );
@@ -0,0 +1,3 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
2
+ <path d="M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v18m0 0h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9m0 0h18"/>
3
+ </svg>
@@ -0,0 +1,4 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2">
2
+ <path d="M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 21h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9" />
3
+ <path d="M12.025 3.422 12 20.652ZM12.85 9l7.347.025zm-.153 6 7.576.025zm4.334.764L17 20.326Z" />
4
+ </svg>
@@ -1,26 +1,26 @@
1
1
  <svg width="0" height="0" style="position:absolute">
2
- <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" id="arrow" xmlns="http://www.w3.org/2000/svg">
2
+ <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-down" id="arrow" xmlns="http://www.w3.org/2000/svg">
3
3
  <path d="M12 5v14M19 12l-7 7-7-7"/>
4
4
  </symbol>
5
- <symbol fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" viewBox="0 0 24 24" id="arrow-right-circle" xmlns="http://www.w3.org/2000/svg">
5
+ <symbol fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-arrow-right-circle" viewBox="0 0 24 24" id="arrow-right-circle" xmlns="http://www.w3.org/2000/svg">
6
6
  <circle cx="12" cy="12" r="10"/>
7
- <path d="M12 16l4-4-4-4M8 12h8"/>
7
+ <path d="m12 16 4-4-4-4M8 12h8"/>
8
8
  </symbol>
9
- <symbol fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" viewBox="0 0 24 24" id="chevron-down" xmlns="http://www.w3.org/2000/svg">
10
- <path d="M6 9l6 6 6-6"/>
9
+ <symbol fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-chevron-down" viewBox="0 0 24 24" id="chevron-down" xmlns="http://www.w3.org/2000/svg">
10
+ <path d="m6 9 6 6 6-6"/>
11
11
  </symbol>
12
- <symbol fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" viewBox="0 0 24 24" id="chevron-up" xmlns="http://www.w3.org/2000/svg">
13
- <path d="M18 15l-6-6-6 6"/>
12
+ <symbol fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-chevron-up" viewBox="0 0 24 24" id="chevron-up" xmlns="http://www.w3.org/2000/svg">
13
+ <path d="m18 15-6-6-6 6"/>
14
14
  </symbol>
15
- <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" id="clock" xmlns="http://www.w3.org/2000/svg">
15
+ <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-clock" id="clock" xmlns="http://www.w3.org/2000/svg">
16
16
  <circle cx="12" cy="12" r="10"/>
17
17
  <path d="M12 6v6l4 2"/>
18
18
  </symbol>
19
- <symbol fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" viewBox="0 0 24 24" id="close" xmlns="http://www.w3.org/2000/svg">
19
+ <symbol fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-x-circle" viewBox="0 0 24 24" id="close" xmlns="http://www.w3.org/2000/svg">
20
20
  <circle cx="12" cy="12" r="10"/>
21
- <path d="M15 9l-6 6M9 9l6 6"/>
21
+ <path d="m15 9-6 6M9 9l6 6"/>
22
22
  </symbol>
23
- <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" id="commit" xmlns="http://www.w3.org/2000/svg">
23
+ <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-git-commit" id="commit" xmlns="http://www.w3.org/2000/svg">
24
24
  <circle cx="12" cy="12" r="4"/>
25
25
  <path d="M1.05 12H7M17.01 12h5.95"/>
26
26
  </symbol>
@@ -28,24 +28,24 @@
28
28
  <circle cx="12" cy="12" r="10"/>
29
29
  <path d="M12 8v4M12 16h.01"/>
30
30
  </symbol>
31
- <symbol fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" viewBox="0 0 24 24" id="external-link" xmlns="http://www.w3.org/2000/svg">
32
- <path d="M18 13v6a2 2 0 01-2 2H5a2 2 0 01-2-2V8a2 2 0 012-2h6M15 3h6v6M10 14L21 3"/>
31
+ <symbol fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-external-link" viewBox="0 0 24 24" id="external-link" xmlns="http://www.w3.org/2000/svg">
32
+ <path d="M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6M15 3h6v6M10 14 21 3"/>
33
33
  </symbol>
34
- <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" id="filter" xmlns="http://www.w3.org/2000/svg">
34
+ <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-bar-chart" id="filter" xmlns="http://www.w3.org/2000/svg">
35
35
  <path d="M12 20V10M18 20V4M6 20v-4"/>
36
36
  </symbol>
37
37
  <symbol viewBox="0 0 98 96" id="github" xmlns="http://www.w3.org/2000/svg">
38
- <path fill-rule="evenodd" clip-rule="evenodd" d="M48.854 0C21.839 0 0 22 0 49.217c0 21.756 13.993 40.172 33.405 46.69 2.427.49 3.316-1.059 3.316-2.362 0-1.141-.08-5.052-.08-9.127-13.59 2.934-16.42-5.867-16.42-5.867-2.184-5.704-5.42-7.17-5.42-7.17-4.448-3.015.324-3.015.324-3.015 4.934.326 7.523 5.052 7.523 5.052 4.367 7.496 11.404 5.378 14.235 4.074.404-3.178 1.699-5.378 3.074-6.6-10.839-1.141-22.243-5.378-22.243-24.283 0-5.378 1.94-9.778 5.014-13.2-.485-1.222-2.184-6.275.486-13.038 0 0 4.125-1.304 13.426 5.052a46.97 46.97 0 0112.214-1.63c4.125 0 8.33.571 12.213 1.63 9.302-6.356 13.427-5.052 13.427-5.052 2.67 6.763.97 11.816.485 13.038 3.155 3.422 5.015 7.822 5.015 13.2 0 18.905-11.404 23.06-22.324 24.283 1.78 1.548 3.316 4.481 3.316 9.126 0 6.6-.08 11.897-.08 13.526 0 1.304.89 2.853 3.316 2.364 19.412-6.52 33.405-24.935 33.405-46.691C97.707 22 75.788 0 48.854 0z" fill="currentColor"/>
38
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M48.854 0C21.839 0 0 22 0 49.217c0 21.756 13.993 40.172 33.405 46.69 2.427.49 3.316-1.059 3.316-2.362 0-1.141-.08-5.052-.08-9.127-13.59 2.934-16.42-5.867-16.42-5.867-2.184-5.704-5.42-7.17-5.42-7.17-4.448-3.015.324-3.015.324-3.015 4.934.326 7.523 5.052 7.523 5.052 4.367 7.496 11.404 5.378 14.235 4.074.404-3.178 1.699-5.378 3.074-6.6-10.839-1.141-22.243-5.378-22.243-24.283 0-5.378 1.94-9.778 5.014-13.2-.485-1.222-2.184-6.275.486-13.038 0 0 4.125-1.304 13.426 5.052a46.97 46.97 0 0 1 12.214-1.63c4.125 0 8.33.571 12.213 1.63 9.302-6.356 13.427-5.052 13.427-5.052 2.67 6.763.97 11.816.485 13.038 3.155 3.422 5.015 7.822 5.015 13.2 0 18.905-11.404 23.06-22.324 24.283 1.78 1.548 3.316 4.481 3.316 9.126 0 6.6-.08 11.897-.08 13.526 0 1.304.89 2.853 3.316 2.364 19.412-6.52 33.405-24.935 33.405-46.691C97.707 22 75.788 0 48.854 0z" fill="currentColor"/>
39
39
  </symbol>
40
- <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" id="help" xmlns="http://www.w3.org/2000/svg">
40
+ <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-help-circle" id="help" xmlns="http://www.w3.org/2000/svg">
41
41
  <circle cx="12" cy="12" r="10"/>
42
- <path d="M9.09 9a3 3 0 015.83 1c0 2-3 3-3 3M12 17h.01"/>
42
+ <path d="M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3M12 17h.01"/>
43
43
  </symbol>
44
44
  <symbol fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" viewBox="0 0 24 24" id="info" xmlns="http://www.w3.org/2000/svg">
45
45
  <circle cx="12" cy="12" r="10"/>
46
46
  <path d="M12 16v-4M12 8h.01"/>
47
47
  </symbol>
48
- <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" id="menu" xmlns="http://www.w3.org/2000/svg">
48
+ <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-menu" id="menu" xmlns="http://www.w3.org/2000/svg">
49
49
  <path d="M3 12h18M3 6h18M3 18h18"/>
50
50
  </symbol>
51
51
  <symbol fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" viewBox="0 0 24 24" id="more-vertical" xmlns="http://www.w3.org/2000/svg">
@@ -57,7 +57,13 @@
57
57
  <path d="M3 18h6v-2H3v2zM3 6v2h18V6H3zm0 7h12v-2H3v2z"/>
58
58
  <path d="M0 0h24v24H0z" fill="none"/>
59
59
  </symbol>
60
- <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" id="warning" xmlns="http://www.w3.org/2000/svg">
61
- <path d="M10.29 3.86L1.82 18a2 2 0 001.71 3h16.94a2 2 0 001.71-3L13.71 3.86a2 2 0 00-3.42 0zM12 9v4M12 17h.01"/>
60
+ <symbol fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" viewBox="0 0 24 24" id="table" xmlns="http://www.w3.org/2000/svg">
61
+ <path d="M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v18m0 0h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9m0 0h18"/>
62
+ </symbol>
63
+ <symbol fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" viewBox="0 0 24 24" id="treemap" xmlns="http://www.w3.org/2000/svg">
64
+ <path d="M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 21h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9M12.025 3.422 12 20.652ZM12.85 9l7.347.025zm-.153 6 7.576.025zm4.334.764L17 20.326Z"/>
65
+ </symbol>
66
+ <symbol viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-alert-triangle" id="warning" xmlns="http://www.w3.org/2000/svg">
67
+ <path d="M10.29 3.86 1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0zM12 9v4M12 17h.01"/>
62
68
  </symbol>
63
69
  </svg>