@makolabs/ripple 0.2.1-0 → 0.3.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.
@@ -127,7 +127,7 @@
127
127
  function getAreaStyle(seriesConfig: SeriesConfig<any>) {
128
128
  if (!seriesConfig.color) return undefined;
129
129
  if (!seriesConfig.showArea) return undefined;
130
-
130
+
131
131
  const baseLinearAreaStyle = {
132
132
  type: 'linear',
133
133
  x: 0,
@@ -265,7 +265,7 @@
265
265
  type: actualType,
266
266
  yAxisIndex: seriesConfig.yAxisIndex || 0,
267
267
  data: seriesData,
268
- stack: null,
268
+ stack: seriesConfig.stack,
269
269
  barWidth:
270
270
  seriesConfig.barWidth ||
271
271
  (barSeriesCount > 3 ? '15%' : barSeriesCount > 1 ? '25%' : '60%'),
@@ -274,7 +274,7 @@
274
274
  color: getColor(seriesConfig.color),
275
275
  itemStyle: {
276
276
  color: getColor(seriesConfig.color),
277
- borderRadius: [4, 4, 0, 0],
277
+ borderRadius: [0, 0, 0, 0],
278
278
  opacity: seriesConfig.opacity || 1
279
279
  }
280
280
  }),
@@ -1,7 +1,7 @@
1
1
  <script lang="ts">
2
2
  import { onMount } from 'svelte';
3
3
  import { Button, Table, Color, Size } from '../index.js';
4
- import type { TableColumn } from '../index.js';
4
+ import type { TableColumn, FileBrowserProps } from '../index.js';
5
5
  import { formatDate } from '../utils/dateUtils.js';
6
6
  import type {
7
7
  StorageAdapter,
@@ -9,7 +9,7 @@
9
9
  Breadcrumb,
10
10
  FileAction,
11
11
  FileActionBatch,
12
- FileActionSingle
12
+ FileActionSingle,
13
13
  } from '../adapters/storage/index.js';
14
14
 
15
15
  let {
@@ -18,16 +18,7 @@
18
18
  actions = [],
19
19
  infoSection,
20
20
  selectedFiles = $bindable([])
21
- } = $props<{
22
- adapter: StorageAdapter;
23
- startPath?: string;
24
- actions?: FileAction[];
25
- selectedFiles?: string[];
26
- infoSection?: (props: {
27
- selectedFiles: string[];
28
- navToFileFolder: (fileKey: string) => void;
29
- }) => any;
30
- }>();
21
+ }: FileBrowserProps = $props();
31
22
 
32
23
  let files = $state<FileItem[]>([]);
33
24
  let displayFiles = $state<FileItem[]>([]);
@@ -118,7 +109,6 @@
118
109
  const fileItem = files.find((f) => f.key === fileKey);
119
110
  if (fileItem && !selected.some((s) => s.key === fileKey)) {
120
111
  selected = [...selected, fileItem];
121
- console.log('selected [SETTIMEOUT, FILEITEM]', selected);
122
112
  }
123
113
  }
124
114
  }, 100);
@@ -251,7 +241,6 @@
251
241
  if (filesToSelect.length > 0) {
252
242
  selectedFiles = filesToSelect;
253
243
  selected = displayFiles.filter((file) => filesToSelect.includes(file.key));
254
- console.log('selected [NAVIGATETOFOLDER]', selected);
255
244
  }
256
245
 
257
246
  // Restore fileQueue to ensure we keep track of all selected files
@@ -265,10 +254,10 @@
265
254
  navigateToFolder(file.key);
266
255
  } else {
267
256
  // Check if this file is allowed to be selected based on actions
268
- const hasAllowedAction = actions.some((action: FileAction) => {
257
+ const hasAllowedAction = actions.some((action) => {
269
258
  // Only check single file actions for individual file selection
270
259
  if ('action' in action && typeof action.action === 'function') {
271
- return action.isAllowed(file);
260
+ return (action.isAllowed as FileActionSingle['isAllowed'])(file);
272
261
  }
273
262
  return false;
274
263
  });
@@ -280,20 +269,15 @@
280
269
 
281
270
  // Toggle selection for files
282
271
  const isCurrentlySelected = selectedFiles.includes(file.key);
283
- console.log('isCurrentlySelected [HANDLEROWCLICK]', isCurrentlySelected);
284
- console.log('selectedFiles [HANDLEROWCLICK]', selectedFiles);
285
- console.log('selected [HANDLEROWCLICK]', selected);
286
272
 
287
273
  if (isCurrentlySelected) {
288
274
  // Remove from selection
289
275
  selectedFiles = selectedFiles.filter((key) => key !== file.key);
290
276
  selected = selected.filter((item) => item.key !== file.key);
291
- console.log('selected [HANDLEROWCLICK, REMOVE]', selected);
292
277
  } else {
293
278
  // Add to selection
294
279
  selectedFiles = [...selectedFiles, file.key];
295
280
  selected = [...selected, file];
296
- console.log('selected [HANDLEROWCLICK, ADD]', selected);
297
281
  }
298
282
  }
299
283
  }
@@ -430,9 +414,9 @@
430
414
  // Filter out files that aren't allowed to be selected based on actions' isAllowed logic
431
415
  const allowedItems = selectedItems.filter((item) => {
432
416
  // Check if any single action allows this file
433
- const hasAllowedAction = actions.some((action: FileAction) => {
417
+ const hasAllowedAction = actions.some((action) => {
434
418
  // Only check single file actions for individual file selection
435
- if ('action' in action && typeof action.action === 'function') {
419
+ if ('action' in action && typeof action.action === 'function' && action.action) {
436
420
  return action.isAllowed(item);
437
421
  }
438
422
  return false;
@@ -537,8 +521,6 @@
537
521
  (newItem) => !existingQueue.some((existingItem) => existingItem.key === newItem.key)
538
522
  )
539
523
  ];
540
-
541
- console.log(`Selected ${selectedFiles.length} files from folders`);
542
524
  } catch (err) {
543
525
  console.error('Error in recursive folder processing:', err);
544
526
  console.error('Failed to process some folders');
@@ -1,14 +1,4 @@
1
- import type { StorageAdapter, FileAction } from '../adapters/storage/index.js';
2
- type $$ComponentProps = {
3
- adapter: StorageAdapter;
4
- startPath?: string;
5
- actions?: FileAction[];
6
- selectedFiles?: string[];
7
- infoSection?: (props: {
8
- selectedFiles: string[];
9
- navToFileFolder: (fileKey: string) => void;
10
- }) => any;
11
- };
12
- declare const FileBrowser: import("svelte").Component<$$ComponentProps, {}, "selectedFiles">;
1
+ import type { FileBrowserProps } from '../index.js';
2
+ declare const FileBrowser: import("svelte").Component<FileBrowserProps, {}, "selectedFiles">;
13
3
  type FileBrowser = ReturnType<typeof FileBrowser>;
14
4
  export default FileBrowser;
package/dist/index.d.ts CHANGED
@@ -20,6 +20,7 @@ import type { Component } from 'svelte';
20
20
  import type { HTMLButtonAttributes, HTMLAttributeAnchorTarget } from 'svelte/elements';
21
21
  import type { ECharts } from 'echarts/types/src/export/core.js';
22
22
  import type { SuperForm } from 'sveltekit-superforms';
23
+ import type { FileAction, StorageAdapter } from './adapters/storage/types.js';
23
24
  export type BadgeProps = {
24
25
  size?: VariantSizes;
25
26
  color?: VariantColors;
@@ -164,18 +165,6 @@ export type AlertProps = {
164
165
  footer?: Snippet;
165
166
  icon?: Component;
166
167
  };
167
- export type StatsCardProps = {
168
- label?: string;
169
- value?: string | number;
170
- previousValue?: string | number;
171
- previousValuePrefix?: string;
172
- trend?: number;
173
- color?: VariantColors;
174
- chartData?: number[];
175
- children?: Snippet;
176
- class?: ClassValue;
177
- formatLargeNumbers?: boolean;
178
- };
179
168
  export type MetricDetail = {
180
169
  label: string;
181
170
  value: string | number;
@@ -354,7 +343,6 @@ export { default as Badge } from './elements/badge/Badge.svelte';
354
343
  export { default as Dropdown } from './elements/dropdown/Dropdown.svelte';
355
344
  export { default as Select } from './elements/dropdown/Select.svelte';
356
345
  export { default as Card } from './layout/card/Card.svelte';
357
- export { default as StatsCard } from './layout/card/StatsCard.svelte';
358
346
  export { default as MetricCard } from './layout/card/MetricCard.svelte';
359
347
  export { default as Alert } from './elements/alert/Alert.svelte';
360
348
  export type TabProps = {
@@ -845,9 +833,9 @@ export { CompactFilters } from './filters/index.js';
845
833
  export * from './file-browser/index.js';
846
834
  export * from './adapters/storage/index.js';
847
835
  export interface FileBrowserProps {
848
- adapter: any;
836
+ adapter: StorageAdapter;
849
837
  startPath?: string;
850
- actions?: any[];
838
+ actions?: FileAction[];
851
839
  selectedFiles?: string[];
852
840
  infoSection?: (props: {
853
841
  selectedFiles: string[];
package/dist/index.js CHANGED
@@ -27,7 +27,6 @@ export { default as Dropdown } from './elements/dropdown/Dropdown.svelte';
27
27
  export { default as Select } from './elements/dropdown/Select.svelte';
28
28
  // Elements - Card
29
29
  export { default as Card } from './layout/card/Card.svelte';
30
- export { default as StatsCard } from './layout/card/StatsCard.svelte';
31
30
  export { default as MetricCard } from './layout/card/MetricCard.svelte';
32
31
  // Elements - Alert
33
32
  export { default as Alert } from './elements/alert/Alert.svelte';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@makolabs/ripple",
3
- "version": "0.2.1-0",
3
+ "version": "0.3.0",
4
4
  "description": "Simple Svelte 5 powered component library ✨",
5
5
  "repository": {
6
6
  "type": "git",
@@ -1,266 +0,0 @@
1
- <script lang="ts">
2
- import { cn } from '../../helper/cls.js';
3
- import { statsCard } from './stats-card.js';
4
- import { onMount } from 'svelte';
5
- import * as echarts from 'echarts/core';
6
-
7
- // @ts-expect-error - ECharts types are not available
8
- import { LineChart } from 'echarts/charts';
9
-
10
- // @ts-expect-error - ECharts types are not available
11
- import { GridComponent } from 'echarts/components';
12
- // @ts-expect-error - ECharts types are not available
13
- import { SVGRenderer } from 'echarts/renderers';
14
- import { Color } from '../../variants.js';
15
- import type { StatsCardProps } from '../../index.js';
16
-
17
- // @ts-expect-error - ECharts types are not available
18
- echarts.use([LineChart, GridComponent, SVGRenderer]);
19
-
20
- let {
21
- label,
22
- value,
23
- previousValue,
24
- previousValuePrefix = 'from',
25
- trend,
26
- color = Color.PRIMARY,
27
- chartData,
28
- children,
29
- class: className = '',
30
- formatLargeNumbers = true
31
- }: StatsCardProps = $props();
32
-
33
- // Chart container reference
34
- let chartContainer: HTMLDivElement | undefined = $state();
35
- // @ts-expect-error - ECharts types are not available
36
- let chart: echarts.ECharts | undefined = $state();
37
-
38
- function getTrendDirection(trendX?: number): 'up' | 'down' | 'neutral' {
39
- if (trendX === undefined || trendX === null) return 'neutral';
40
- if (trendX > 0) {
41
- return 'up';
42
- } else if (trendX < 0) {
43
- return 'down';
44
- }
45
- return 'neutral';
46
- }
47
-
48
- function formatValue(val?: string | number): string {
49
- if (val === undefined || val === null) return '';
50
-
51
- let numValue: number;
52
- let currencySymbol: string | null = null;
53
-
54
- // Handle string inputs
55
- if (typeof val === 'string') {
56
- // Check for currency symbols
57
- const currencyMatch = val.match(/^(\$|€|£|¥)/);
58
- if (currencyMatch) {
59
- currencySymbol = currencyMatch[0];
60
- }
61
-
62
- // Extract the numeric value
63
- const cleanedStr = val.replace(/[^0-9.-]/g, '');
64
- if (/^-?\d+(\.\d+)?$/.test(cleanedStr)) {
65
- numValue = parseFloat(cleanedStr);
66
- } else {
67
- // Not a number we can format
68
- return val;
69
- }
70
- } else {
71
- // Already a number
72
- numValue = val;
73
- }
74
-
75
- // Format based on whether it's currency and size
76
- if (currencySymbol) {
77
- // Currency formatting with compact notation if needed
78
- return new Intl.NumberFormat('en-US', {
79
- style: 'currency',
80
- currency: currencySymbolToCode(currencySymbol),
81
- notation: formatLargeNumbers ? 'compact' : 'standard',
82
- compactDisplay: 'short',
83
- maximumFractionDigits: 1
84
- }).format(numValue);
85
- } else {
86
- // Regular number formatting with compact notation if needed
87
- return new Intl.NumberFormat('en-US', {
88
- notation: formatLargeNumbers ? 'compact' : 'standard',
89
- compactDisplay: 'short',
90
- maximumFractionDigits: 1
91
- }).format(numValue);
92
- }
93
- }
94
-
95
- // Helper function to convert currency symbols to ISO codes
96
- function currencySymbolToCode(symbol: string): string {
97
- const map: Record<string, string> = {
98
- $: 'USD',
99
- '€': 'EUR',
100
- '£': 'GBP',
101
- '¥': 'JPY'
102
- };
103
- return map[symbol] || 'USD';
104
- }
105
-
106
- const chartColorMap = {
107
- [Color.PRIMARY]: '#4F46E5',
108
- [Color.SECONDARY]: '#6B7280',
109
- [Color.INFO]: '#3B82F6',
110
- [Color.SUCCESS]: '#10B981',
111
- [Color.WARNING]: '#F59E0B',
112
- [Color.DANGER]: '#EF4444',
113
- [Color.DEFAULT]: '#6B7280'
114
- };
115
-
116
- const trendDirection = $derived(getTrendDirection(trend));
117
- const formattedValue = $derived(formatValue(value));
118
- const formattedPreviousValue = $derived(
119
- previousValue !== undefined ? formatValue(previousValue) : undefined
120
- );
121
-
122
- const {
123
- base,
124
- label: labelSlot,
125
- value: valueSlot,
126
- trend: trendSlot,
127
- previousValue: previousValueSlot
128
- } = $derived(
129
- statsCard({
130
- color,
131
- trendDirection
132
- })
133
- );
134
-
135
- const labelClasses = $derived(cn(labelSlot(), 'text-sm font-medium mb-1'));
136
- const valueClasses = $derived(cn(valueSlot(), 'text-4xl font-bold'));
137
- const trendClasses = $derived(cn(trendSlot(), 'text-sm font-medium ml-2'));
138
- const previousValueClasses = $derived(cn(previousValueSlot(), 'text-sm text-default-500 mt-1'));
139
-
140
- const trendFormatted = $derived.by(() => {
141
- if (trend === undefined || trend === null) return '';
142
- const absValue = Math.abs(trend);
143
- const formattedValue = absValue.toFixed(1).replace(/\.0$/, '');
144
- return trend >= 0 ? `+${formattedValue}%` : `-${formattedValue}%`;
145
- });
146
-
147
- const chartColor = $derived(chartColorMap[color] || chartColorMap[Color.DEFAULT]);
148
-
149
- onMount(() => {
150
- if (!chartData || chartData.length < 2 || !chartContainer) return;
151
-
152
- // @ts-expect-error - ECharts types are not available
153
- chart = echarts.init(chartContainer);
154
-
155
- // Set chart options
156
- const options = {
157
- grid: {
158
- left: 0,
159
- right: 0,
160
- top: 0,
161
- bottom: 0
162
- },
163
- xAxis: {
164
- type: 'category',
165
- show: false,
166
- data: Array.from({ length: chartData.length }, (_, i) => i)
167
- },
168
- yAxis: {
169
- type: 'value',
170
- show: false
171
- },
172
- series: [
173
- {
174
- data: chartData,
175
- type: 'line',
176
- symbol: 'none',
177
- lineStyle: {
178
- color: chartColor,
179
- width: 2
180
- },
181
- areaStyle: {
182
- color: {
183
- type: 'linear',
184
- x: 0,
185
- y: 0,
186
- x2: 0,
187
- y2: 1,
188
- colorStops: [
189
- {
190
- offset: 0,
191
- color: chartColor + '40' // 25% opacity
192
- },
193
- {
194
- offset: 1,
195
- color: chartColor + '00' // 0% opacity
196
- }
197
- ]
198
- }
199
- },
200
- smooth: true
201
- }
202
- ],
203
- animation: false,
204
- animationDuration: 1000
205
- };
206
-
207
- chart.setOption(options);
208
-
209
- const resizeObserver = new ResizeObserver(() => {
210
- chart && chart.resize();
211
- });
212
-
213
- resizeObserver.observe(chartContainer);
214
-
215
- return () => {
216
- resizeObserver.disconnect();
217
- chart.dispose();
218
- };
219
- });
220
- </script>
221
-
222
- <div
223
- class={cn(
224
- base(),
225
- '@container flex flex-col rounded-lg border border-default-200 bg-white p-6 shadow-sm',
226
- className
227
- )}
228
- >
229
- <div class="flex items-center justify-between">
230
- {#if label}
231
- <dt class={labelClasses}>{label}</dt>
232
- {/if}
233
- {#if trend !== undefined && trend !== null}
234
- <span class={trendClasses}>
235
- {trendFormatted}
236
- </span>
237
- {/if}
238
- </div>
239
-
240
- <div class="mt-1 flex flex-row items-center overflow-clip">
241
- <div class="w-full flex-grow">
242
- {#if value !== undefined}
243
- <dd class={valueClasses} title={value}>
244
- {formattedValue}
245
- </dd>
246
- {/if}
247
-
248
- {#if previousValue !== undefined}
249
- <div class={previousValueClasses}>
250
- {previousValuePrefix}
251
- {formattedPreviousValue}
252
- </div>
253
- {/if}
254
- </div>
255
-
256
- {#if chartData && chartData.length > 1}
257
- <div class="h-10 w-full min-w-32 @max-[212.862px]:hidden" bind:this={chartContainer}></div>
258
- {/if}
259
- </div>
260
-
261
- {#if children}
262
- <div class="mt-4">
263
- {@render children()}
264
- </div>
265
- {/if}
266
- </div>
@@ -1,4 +0,0 @@
1
- import type { StatsCardProps } from '../../index.js';
2
- declare const StatsCard: import("svelte").Component<StatsCardProps, {}, "">;
3
- type StatsCard = ReturnType<typeof StatsCard>;
4
- export default StatsCard;
@@ -1,191 +0,0 @@
1
- import { Color } from '../../variants.js';
2
- export declare const statsCard: import("tailwind-variants").TVReturnType<{
3
- color: {
4
- [Color.DEFAULT]: {
5
- label: string;
6
- value: string;
7
- trend: string;
8
- previousValue: string;
9
- };
10
- [Color.PRIMARY]: {
11
- label: string;
12
- value: string;
13
- trend: string;
14
- previousValue: string;
15
- };
16
- [Color.SECONDARY]: {
17
- label: string;
18
- value: string;
19
- trend: string;
20
- previousValue: string;
21
- };
22
- [Color.INFO]: {
23
- label: string;
24
- value: string;
25
- trend: string;
26
- previousValue: string;
27
- };
28
- [Color.SUCCESS]: {
29
- label: string;
30
- value: string;
31
- trend: string;
32
- previousValue: string;
33
- };
34
- [Color.WARNING]: {
35
- label: string;
36
- value: string;
37
- trend: string;
38
- previousValue: string;
39
- };
40
- [Color.DANGER]: {
41
- label: string;
42
- value: string;
43
- trend: string;
44
- previousValue: string;
45
- };
46
- };
47
- trendDirection: {
48
- up: {
49
- trend: string;
50
- };
51
- down: {
52
- trend: string;
53
- };
54
- neutral: {
55
- trend: string;
56
- };
57
- };
58
- }, {
59
- base: string;
60
- label: string;
61
- value: string;
62
- trend: string;
63
- previousValue: string;
64
- unit: string;
65
- }, undefined, {
66
- color: {
67
- [Color.DEFAULT]: {
68
- label: string;
69
- value: string;
70
- trend: string;
71
- previousValue: string;
72
- };
73
- [Color.PRIMARY]: {
74
- label: string;
75
- value: string;
76
- trend: string;
77
- previousValue: string;
78
- };
79
- [Color.SECONDARY]: {
80
- label: string;
81
- value: string;
82
- trend: string;
83
- previousValue: string;
84
- };
85
- [Color.INFO]: {
86
- label: string;
87
- value: string;
88
- trend: string;
89
- previousValue: string;
90
- };
91
- [Color.SUCCESS]: {
92
- label: string;
93
- value: string;
94
- trend: string;
95
- previousValue: string;
96
- };
97
- [Color.WARNING]: {
98
- label: string;
99
- value: string;
100
- trend: string;
101
- previousValue: string;
102
- };
103
- [Color.DANGER]: {
104
- label: string;
105
- value: string;
106
- trend: string;
107
- previousValue: string;
108
- };
109
- };
110
- trendDirection: {
111
- up: {
112
- trend: string;
113
- };
114
- down: {
115
- trend: string;
116
- };
117
- neutral: {
118
- trend: string;
119
- };
120
- };
121
- }, {
122
- base: string;
123
- label: string;
124
- value: string;
125
- trend: string;
126
- previousValue: string;
127
- unit: string;
128
- }, import("tailwind-variants").TVReturnType<{
129
- color: {
130
- [Color.DEFAULT]: {
131
- label: string;
132
- value: string;
133
- trend: string;
134
- previousValue: string;
135
- };
136
- [Color.PRIMARY]: {
137
- label: string;
138
- value: string;
139
- trend: string;
140
- previousValue: string;
141
- };
142
- [Color.SECONDARY]: {
143
- label: string;
144
- value: string;
145
- trend: string;
146
- previousValue: string;
147
- };
148
- [Color.INFO]: {
149
- label: string;
150
- value: string;
151
- trend: string;
152
- previousValue: string;
153
- };
154
- [Color.SUCCESS]: {
155
- label: string;
156
- value: string;
157
- trend: string;
158
- previousValue: string;
159
- };
160
- [Color.WARNING]: {
161
- label: string;
162
- value: string;
163
- trend: string;
164
- previousValue: string;
165
- };
166
- [Color.DANGER]: {
167
- label: string;
168
- value: string;
169
- trend: string;
170
- previousValue: string;
171
- };
172
- };
173
- trendDirection: {
174
- up: {
175
- trend: string;
176
- };
177
- down: {
178
- trend: string;
179
- };
180
- neutral: {
181
- trend: string;
182
- };
183
- };
184
- }, {
185
- base: string;
186
- label: string;
187
- value: string;
188
- trend: string;
189
- previousValue: string;
190
- unit: string;
191
- }, undefined, unknown, unknown, undefined>>;
@@ -1,73 +0,0 @@
1
- import { tv } from 'tailwind-variants';
2
- import { Color } from '../../variants.js';
3
- export const statsCard = tv({
4
- slots: {
5
- base: '',
6
- label: '',
7
- value: '',
8
- trend: '',
9
- previousValue: '',
10
- unit: '',
11
- },
12
- variants: {
13
- color: {
14
- [Color.DEFAULT]: {
15
- label: 'text-default-500',
16
- value: 'text-default-900',
17
- trend: 'text-default-600',
18
- previousValue: 'text-default-500'
19
- },
20
- [Color.PRIMARY]: {
21
- label: 'text-primary-500',
22
- value: 'text-primary-600',
23
- trend: 'text-primary-600',
24
- previousValue: 'text-primary-400'
25
- },
26
- [Color.SECONDARY]: {
27
- label: 'text-secondary-500',
28
- value: 'text-secondary-600',
29
- trend: 'text-secondary-600',
30
- previousValue: 'text-secondary-400'
31
- },
32
- [Color.INFO]: {
33
- label: 'text-info-500',
34
- value: 'text-info-600',
35
- trend: 'text-info-600',
36
- previousValue: 'text-info-400'
37
- },
38
- [Color.SUCCESS]: {
39
- label: 'text-success-500',
40
- value: 'text-success-600',
41
- trend: 'text-success-600',
42
- previousValue: 'text-success-400'
43
- },
44
- [Color.WARNING]: {
45
- label: 'text-warning-500',
46
- value: 'text-warning-600',
47
- trend: 'text-warning-600',
48
- previousValue: 'text-warning-400'
49
- },
50
- [Color.DANGER]: {
51
- label: 'text-danger-500',
52
- value: 'text-danger-600',
53
- trend: 'text-danger-600',
54
- previousValue: 'text-danger-400'
55
- }
56
- },
57
- trendDirection: {
58
- up: {
59
- trend: 'text-success-600'
60
- },
61
- down: {
62
- trend: 'text-danger-600'
63
- },
64
- neutral: {
65
- trend: 'text-default-600'
66
- }
67
- }
68
- },
69
- defaultVariants: {
70
- color: Color.DEFAULT,
71
- trendDirection: 'neutral'
72
- }
73
- });