panelui-native 0.62.0 → 0.63.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.
- package/lib/module/components/area-chart/index.js +14 -4
- package/lib/module/components/area-chart/index.js.map +1 -1
- package/lib/module/components/bar-chart/index.js +14 -4
- package/lib/module/components/bar-chart/index.js.map +1 -1
- package/lib/module/components/candlestick-chart/index.js +14 -4
- package/lib/module/components/candlestick-chart/index.js.map +1 -1
- package/lib/module/components/card/index.js +26 -1
- package/lib/module/components/card/index.js.map +1 -1
- package/lib/module/components/dialog/index.js +49 -3
- package/lib/module/components/dialog/index.js.map +1 -1
- package/lib/module/components/hex-chart/index.js +2 -2
- package/lib/module/components/hex-chart/index.js.map +1 -1
- package/lib/module/components/line-chart/index.js +14 -4
- package/lib/module/components/line-chart/index.js.map +1 -1
- package/lib/module/components/pie-chart/index.js +2 -2
- package/lib/module/components/pie-chart/index.js.map +1 -1
- package/lib/module/components/plot/index.js +1329 -0
- package/lib/module/components/plot/index.js.map +1 -0
- package/lib/module/components/polar-area-chart/index.js +2 -2
- package/lib/module/components/polar-area-chart/index.js.map +1 -1
- package/lib/module/components/radar-chart/index.js +14 -4
- package/lib/module/components/radar-chart/index.js.map +1 -1
- package/lib/module/components/ring-chart/index.js +2 -2
- package/lib/module/components/ring-chart/index.js.map +1 -1
- package/lib/module/components/section-rail/index.js +120 -15
- package/lib/module/components/section-rail/index.js.map +1 -1
- package/lib/module/components/selection-mode/index.js +129 -18
- package/lib/module/components/selection-mode/index.js.map +1 -1
- package/lib/module/components/sortable/index.js +15 -5
- package/lib/module/components/sortable/index.js.map +1 -1
- package/lib/module/index.js +7 -0
- package/lib/module/index.js.map +1 -1
- package/lib/typescript/src/components/area-chart/index.d.ts.map +1 -1
- package/lib/typescript/src/components/bar-chart/index.d.ts.map +1 -1
- package/lib/typescript/src/components/candlestick-chart/index.d.ts +6 -3
- package/lib/typescript/src/components/candlestick-chart/index.d.ts.map +1 -1
- package/lib/typescript/src/components/card/index.d.ts +48 -1
- package/lib/typescript/src/components/card/index.d.ts.map +1 -1
- package/lib/typescript/src/components/dialog/index.d.ts +47 -2
- package/lib/typescript/src/components/dialog/index.d.ts.map +1 -1
- package/lib/typescript/src/components/line-chart/index.d.ts.map +1 -1
- package/lib/typescript/src/components/plot/index.d.ts +471 -0
- package/lib/typescript/src/components/plot/index.d.ts.map +1 -0
- package/lib/typescript/src/components/radar-chart/index.d.ts.map +1 -1
- package/lib/typescript/src/components/section-rail/index.d.ts +8 -1
- package/lib/typescript/src/components/section-rail/index.d.ts.map +1 -1
- package/lib/typescript/src/components/selection-mode/index.d.ts +82 -6
- package/lib/typescript/src/components/selection-mode/index.d.ts.map +1 -1
- package/lib/typescript/src/components/sortable/index.d.ts.map +1 -1
- package/lib/typescript/src/index.d.ts +2 -0
- package/lib/typescript/src/index.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/components/area-chart/index.tsx +14 -4
- package/src/components/bar-chart/index.tsx +14 -4
- package/src/components/candlestick-chart/index.tsx +20 -7
- package/src/components/card/index.tsx +32 -7
- package/src/components/dialog/index.tsx +55 -2
- package/src/components/hex-chart/index.tsx +2 -2
- package/src/components/line-chart/index.tsx +14 -4
- package/src/components/pie-chart/index.tsx +2 -2
- package/src/components/plot/index.tsx +1564 -0
- package/src/components/polar-area-chart/index.tsx +2 -2
- package/src/components/radar-chart/index.tsx +14 -4
- package/src/components/ring-chart/index.tsx +2 -2
- package/src/components/section-rail/index.tsx +133 -14
- package/src/components/selection-mode/index.tsx +163 -26
- package/src/components/sortable/index.tsx +15 -5
- package/src/index.ts +46 -0
- package/theme.css +24 -0
|
@@ -221,7 +221,7 @@ const LineChartRoot = forwardRef<LineChartHandle, LineChartProps>(function LineC
|
|
|
221
221
|
xDataKey = 'date',
|
|
222
222
|
status = 'ready',
|
|
223
223
|
aspectRatio = 2,
|
|
224
|
-
animationDuration =
|
|
224
|
+
animationDuration = 700,
|
|
225
225
|
domainDuration = 500,
|
|
226
226
|
yDomain,
|
|
227
227
|
curve = 'monotone',
|
|
@@ -341,17 +341,27 @@ const LineChartRoot = forwardRef<LineChartHandle, LineChartProps>(function LineC
|
|
|
341
341
|
reveal.value = 0;
|
|
342
342
|
reveal.value = withTiming(1, {
|
|
343
343
|
duration: animationDuration,
|
|
344
|
-
easing: Easing.
|
|
344
|
+
easing: Easing.out(Easing.cubic),
|
|
345
345
|
});
|
|
346
346
|
},
|
|
347
347
|
[reducedMotion, animationDuration, reveal]
|
|
348
348
|
);
|
|
349
349
|
|
|
350
350
|
useEffect(() => {
|
|
351
|
-
|
|
351
|
+
/*
|
|
352
|
+
* Going back to `loading` arms the reveal again. Without this a chart that
|
|
353
|
+
* is refetched comes back fully drawn on the frame the data lands, which
|
|
354
|
+
* reads as the loading state having been for nothing.
|
|
355
|
+
*/
|
|
356
|
+
if (loading) {
|
|
357
|
+
revealed.current = false;
|
|
358
|
+
reveal.value = 0;
|
|
359
|
+
return;
|
|
360
|
+
}
|
|
361
|
+
if (revealed.current || plot.width <= 0 || !data.length) return;
|
|
352
362
|
revealed.current = true;
|
|
353
363
|
playReveal();
|
|
354
|
-
}, [loading, plot.width, data.length, playReveal]);
|
|
364
|
+
}, [loading, plot.width, data.length, playReveal, reveal]);
|
|
355
365
|
|
|
356
366
|
// `replay()` re-runs the reveal — for a control the caller wires up.
|
|
357
367
|
useImperativeHandle(ref, () => ({ replay: playReveal }), [playReveal]);
|
|
@@ -206,7 +206,7 @@ const PieChartRoot = forwardRef<PieChartHandle, PieChartProps>(function PieChart
|
|
|
206
206
|
endAngle = 360,
|
|
207
207
|
padAngle = 0,
|
|
208
208
|
minAngle = 0,
|
|
209
|
-
animationDuration =
|
|
209
|
+
animationDuration = 620,
|
|
210
210
|
status = 'ready',
|
|
211
211
|
activeIndex: activeIndexProp,
|
|
212
212
|
onActiveIndexChange,
|
|
@@ -290,7 +290,7 @@ const PieChartRoot = forwardRef<PieChartHandle, PieChartProps>(function PieChart
|
|
|
290
290
|
reveal.value = 0;
|
|
291
291
|
reveal.value = withTiming(1, {
|
|
292
292
|
duration: animationDuration,
|
|
293
|
-
easing: Easing.
|
|
293
|
+
easing: Easing.out(Easing.cubic),
|
|
294
294
|
});
|
|
295
295
|
},
|
|
296
296
|
[reducedMotion, animationDuration, reveal]
|