@conboai/storybook.components 0.3.74 → 0.3.75
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.
|
@@ -16,6 +16,7 @@ export interface ImagePlayerProps {
|
|
|
16
16
|
shapes: Shape[];
|
|
17
17
|
selectedShape?: Shape;
|
|
18
18
|
onShapeSelect?: (selectedShape: Shape | null, shapesList: Shape[]) => void;
|
|
19
|
+
shapeStyles?: any;
|
|
19
20
|
}
|
|
20
21
|
declare const ImagePlayer: React.FC<ImagePlayerProps>;
|
|
21
22
|
export default ImagePlayer;
|
|
@@ -97212,16 +97212,17 @@ const Eve = Hme, kve = (t, e) => ({
|
|
|
97212
97212
|
shapes: a,
|
|
97213
97213
|
sx: l,
|
|
97214
97214
|
selectedShape: c,
|
|
97215
|
-
onShapeSelect: u
|
|
97215
|
+
onShapeSelect: u,
|
|
97216
|
+
shapeStyles: d = {}
|
|
97216
97217
|
}) => {
|
|
97217
|
-
const [
|
|
97218
|
-
typeof
|
|
97218
|
+
const [f, A] = Ye(0), m = Ove(s), g = Lve(s), h = (v, D) => {
|
|
97219
|
+
typeof D == "number" && A(D);
|
|
97219
97220
|
};
|
|
97220
97221
|
ke(() => {
|
|
97221
|
-
o && o(t[
|
|
97222
|
-
}, [
|
|
97223
|
-
const
|
|
97224
|
-
const
|
|
97222
|
+
o && o(t[f]);
|
|
97223
|
+
}, [f, o, t]);
|
|
97224
|
+
const p = (v) => {
|
|
97225
|
+
const D = {
|
|
97225
97226
|
year: "numeric",
|
|
97226
97227
|
month: "long",
|
|
97227
97228
|
day: "numeric",
|
|
@@ -97229,17 +97230,17 @@ const Eve = Hme, kve = (t, e) => ({
|
|
|
97229
97230
|
minute: "2-digit",
|
|
97230
97231
|
second: "2-digit"
|
|
97231
97232
|
};
|
|
97232
|
-
return new Date(
|
|
97233
|
-
},
|
|
97234
|
-
|
|
97235
|
-
const
|
|
97236
|
-
return
|
|
97233
|
+
return new Date(v).toLocaleDateString(void 0, D);
|
|
97234
|
+
}, w = (v) => {
|
|
97235
|
+
A((D) => {
|
|
97236
|
+
const y = D + v;
|
|
97237
|
+
return y < 0 ? 0 : y >= t.length ? t.length - 1 : y;
|
|
97237
97238
|
});
|
|
97238
|
-
},
|
|
97239
|
+
}, C = {
|
|
97239
97240
|
...Sve,
|
|
97240
97241
|
...l
|
|
97241
97242
|
};
|
|
97242
|
-
return /* @__PURE__ */ N.jsxs(Pt, { sx:
|
|
97243
|
+
return /* @__PURE__ */ N.jsxs(Pt, { sx: C, children: [
|
|
97243
97244
|
/* @__PURE__ */ N.jsxs(Pt, { sx: Fve, children: [
|
|
97244
97245
|
/* @__PURE__ */ N.jsx(
|
|
97245
97246
|
RO,
|
|
@@ -97251,16 +97252,14 @@ const Eve = Hme, kve = (t, e) => ({
|
|
|
97251
97252
|
showPoints: !1,
|
|
97252
97253
|
selected: c,
|
|
97253
97254
|
onShapeSelect: u,
|
|
97254
|
-
styles:
|
|
97255
|
-
width: "50%"
|
|
97256
|
-
},
|
|
97255
|
+
styles: d,
|
|
97257
97256
|
children: /* @__PURE__ */ N.jsx(
|
|
97258
97257
|
Hh,
|
|
97259
97258
|
{
|
|
97260
97259
|
sx: { ...jve, objectFit: "contain" },
|
|
97261
97260
|
component: "img",
|
|
97262
|
-
image: t.length > 0 ? e(t[
|
|
97263
|
-
alt: t.length > 0 ? `Snapshot ${
|
|
97261
|
+
image: t.length > 0 ? e(t[f]) : zve,
|
|
97262
|
+
alt: t.length > 0 ? `Snapshot ${f}` : "No Data"
|
|
97264
97263
|
}
|
|
97265
97264
|
)
|
|
97266
97265
|
}
|
|
@@ -97271,21 +97270,21 @@ const Eve = Hme, kve = (t, e) => ({
|
|
|
97271
97270
|
paddingBottom: "0 !important"
|
|
97272
97271
|
}, children: /* @__PURE__ */ N.jsxs(Pt, { sx: Tve, children: [
|
|
97273
97272
|
/* @__PURE__ */ N.jsxs(Pt, { display: "flex", justifyContent: "space-between", children: [
|
|
97274
|
-
/* @__PURE__ */ N.jsx(Jt, { variant: "body2", sx:
|
|
97275
|
-
/* @__PURE__ */ N.jsx(Jt, { variant: "body2", sx:
|
|
97276
|
-
/* @__PURE__ */ N.jsx(Jt, { variant: "body2", "aria-disabled": s, sx:
|
|
97273
|
+
/* @__PURE__ */ N.jsx(Jt, { variant: "body2", sx: g, children: t.length ? p(n(t[0])) : "Start time" }),
|
|
97274
|
+
/* @__PURE__ */ N.jsx(Jt, { variant: "body2", sx: g, children: t.length ? p(n(t[f])) : "Current time" }),
|
|
97275
|
+
/* @__PURE__ */ N.jsx(Jt, { variant: "body2", "aria-disabled": s, sx: g, children: t.length ? p(n(t[t.length - 1])) : "End time" })
|
|
97277
97276
|
] }),
|
|
97278
97277
|
/* @__PURE__ */ N.jsx(
|
|
97279
97278
|
Sx,
|
|
97280
97279
|
{
|
|
97281
97280
|
disabled: s,
|
|
97282
|
-
value:
|
|
97281
|
+
value: f,
|
|
97283
97282
|
min: 0,
|
|
97284
97283
|
max: t.length - 1,
|
|
97285
|
-
onChange:
|
|
97284
|
+
onChange: h,
|
|
97286
97285
|
"aria-labelledby": "image-slider",
|
|
97287
97286
|
valueLabelDisplay: "auto",
|
|
97288
|
-
valueLabelFormat: (
|
|
97287
|
+
valueLabelFormat: (v) => p(n(t[v]))
|
|
97289
97288
|
}
|
|
97290
97289
|
),
|
|
97291
97290
|
/* @__PURE__ */ N.jsxs(
|
|
@@ -97294,14 +97293,14 @@ const Eve = Hme, kve = (t, e) => ({
|
|
|
97294
97293
|
display: "flex",
|
|
97295
97294
|
justifyContent: "center",
|
|
97296
97295
|
alignItems: "center",
|
|
97297
|
-
sx:
|
|
97296
|
+
sx: m,
|
|
97298
97297
|
gap: "12px",
|
|
97299
97298
|
children: [
|
|
97300
97299
|
/* @__PURE__ */ N.jsxs(Pt, { display: "flex", gap: "12px", children: [
|
|
97301
97300
|
/* @__PURE__ */ N.jsx(
|
|
97302
97301
|
Br,
|
|
97303
97302
|
{
|
|
97304
|
-
onClick: () =>
|
|
97303
|
+
onClick: () => w(-10),
|
|
97305
97304
|
variant: "action",
|
|
97306
97305
|
disabled: s || t.length === 0,
|
|
97307
97306
|
children: /* @__PURE__ */ N.jsx(Qoe, {})
|
|
@@ -97310,7 +97309,7 @@ const Eve = Hme, kve = (t, e) => ({
|
|
|
97310
97309
|
/* @__PURE__ */ N.jsx(
|
|
97311
97310
|
Br,
|
|
97312
97311
|
{
|
|
97313
|
-
onClick: () =>
|
|
97312
|
+
onClick: () => w(-1),
|
|
97314
97313
|
variant: "action",
|
|
97315
97314
|
disabled: s || t.length === 0,
|
|
97316
97315
|
children: /* @__PURE__ */ N.jsx(Foe, {})
|
|
@@ -97321,7 +97320,7 @@ const Eve = Hme, kve = (t, e) => ({
|
|
|
97321
97320
|
/* @__PURE__ */ N.jsx(
|
|
97322
97321
|
Br,
|
|
97323
97322
|
{
|
|
97324
|
-
onClick: () =>
|
|
97323
|
+
onClick: () => w(1),
|
|
97325
97324
|
variant: "action",
|
|
97326
97325
|
disabled: s || t.length === 0,
|
|
97327
97326
|
children: /* @__PURE__ */ N.jsx(zoe, {})
|
|
@@ -97330,7 +97329,7 @@ const Eve = Hme, kve = (t, e) => ({
|
|
|
97330
97329
|
/* @__PURE__ */ N.jsx(
|
|
97331
97330
|
Br,
|
|
97332
97331
|
{
|
|
97333
|
-
onClick: () =>
|
|
97332
|
+
onClick: () => w(10),
|
|
97334
97333
|
variant: "action",
|
|
97335
97334
|
disabled: s || t.length === 0,
|
|
97336
97335
|
children: /* @__PURE__ */ N.jsx(Yoe, {})
|