@conboai/storybook.components 0.2.7 → 0.2.9

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.
@@ -7,6 +7,7 @@ export interface ICustomSelect {
7
7
  value: string | number;
8
8
  label: string;
9
9
  }[];
10
+ value: string | number;
10
11
  onChange: (event: SelectChangeEvent) => void;
11
12
  }
12
13
  declare const CustomSelect: React.FC<ICustomSelect & SelectProps>;
@@ -39782,7 +39782,7 @@ const R2 = {
39782
39782
  };
39783
39783
  St.extend(DL);
39784
39784
  St.extend(OL);
39785
- const l4 = ({
39785
+ const l3 = ({
39786
39786
  label: t = "",
39787
39787
  onChange: e,
39788
39788
  value: n,
@@ -40839,7 +40839,7 @@ const Ly = {
40839
40839
  id: n.key,
40840
40840
  subItemValues: r.subItemValues
40841
40841
  };
40842
- }), c4 = ({
40842
+ }), c3 = ({
40843
40843
  title: t,
40844
40844
  filterTitle: e,
40845
40845
  data: n,
@@ -41158,7 +41158,7 @@ const Ly = {
41158
41158
  ]
41159
41159
  }
41160
41160
  ) });
41161
- }, u4 = ({
41161
+ }, u3 = ({
41162
41162
  tabs: t,
41163
41163
  activeId: e,
41164
41164
  onDelete: n,
@@ -41205,7 +41205,7 @@ const Ly = {
41205
41205
  ] })
41206
41206
  }
41207
41207
  );
41208
- }, d4 = ({ children: t }) => /* @__PURE__ */ T.jsx(
41208
+ }, d3 = ({ children: t }) => /* @__PURE__ */ T.jsx(
41209
41209
  lt,
41210
41210
  {
41211
41211
  justifyContent: "space-between",
@@ -41215,7 +41215,7 @@ const Ly = {
41215
41215
  sx: { backgroundColor: yb, display: "flex" },
41216
41216
  children: t
41217
41217
  }
41218
- ), f4 = ({ linkContent: t, link: e }) => /* @__PURE__ */ T.jsx(e0, { href: e, height: "100%", children: t }), pB = ({
41218
+ ), f3 = ({ linkContent: t, link: e }) => /* @__PURE__ */ T.jsx(e0, { href: e, height: "100%", children: t }), pB = ({
41219
41219
  setValue: t,
41220
41220
  value: e,
41221
41221
  tabs: n,
@@ -41256,7 +41256,7 @@ const Ly = {
41256
41256
  }
41257
41257
  ),
41258
41258
  /* @__PURE__ */ T.jsx(hB, { tabsContent: r })
41259
- ] }), p4 = ({ tabsContent: t, tabs: e, onChange: n }) => {
41259
+ ] }), p3 = ({ tabsContent: t, tabs: e, onChange: n }) => {
41260
41260
  const [r, o] = ft("0"), i = { background: "none", padding: "20px" };
41261
41261
  return /* @__PURE__ */ T.jsx(ct, { sx: i, children: /* @__PURE__ */ T.jsx(
41262
41262
  mB,
@@ -41282,7 +41282,7 @@ const Ly = {
41282
41282
  /* @__PURE__ */ T.jsx("circle", { cx: "2", cy: "14", r: "2", fill: "black", fillOpacity: "0.6" })
41283
41283
  ]
41284
41284
  }
41285
- ), h4 = ({ title: t }) => /* @__PURE__ */ T.jsxs(
41285
+ ), h3 = ({ title: t }) => /* @__PURE__ */ T.jsxs(
41286
41286
  lt,
41287
41287
  {
41288
41288
  container: !0,
@@ -41306,7 +41306,7 @@ const Ly = {
41306
41306
  ]
41307
41307
  }
41308
41308
  ), gB = { display: "flex", flexWrap: "wrap", gap: 0.5 };
41309
- function m4({
41309
+ function m3({
41310
41310
  options: t,
41311
41311
  label: e,
41312
41312
  value: n,
@@ -58190,7 +58190,9 @@ const $5 = {
58190
58190
  justifyContent: "center",
58191
58191
  alignItems: t ? "center" : "flex-start",
58192
58192
  height: t ? "100vh" : "auto",
58193
- overflow: t ? "hidden" : "visible"
58193
+ overflow: t ? "hidden" : "visible",
58194
+ paddingLeft: "15px",
58195
+ paddingRight: 0
58194
58196
  }), j5 = (t) => ({
58195
58197
  display: t ? "none" : "block",
58196
58198
  maxWidth: "100%"
@@ -58243,7 +58245,6 @@ const $5 = {
58243
58245
  return /* @__PURE__ */ T.jsx(
58244
58246
  Yb,
58245
58247
  {
58246
- maxWidth: "md",
58247
58248
  ref: p,
58248
58249
  onMouseMove: x,
58249
58250
  sx: B5(o),
@@ -58285,8 +58286,7 @@ const $5 = {
58285
58286
  xs: 12,
58286
58287
  justifyContent: "center",
58287
58288
  alignItems: "center",
58288
- spacing: 2,
58289
- paddingTop: "15px",
58289
+ padding: "0",
58290
58290
  sx: V5(o),
58291
58291
  margin: "0",
58292
58292
  children: [
@@ -58381,7 +58381,7 @@ const $5 = {
58381
58381
  isHls: o,
58382
58382
  isModalOpen: t
58383
58383
  }
58384
- ) }), y4 = ({
58384
+ ) }), y3 = ({
58385
58385
  onGenerate: t,
58386
58386
  isLoading: e,
58387
58387
  src: n,
@@ -58395,7 +58395,7 @@ const $5 = {
58395
58395
  lt,
58396
58396
  {
58397
58397
  width: "100%",
58398
- height: "264px",
58398
+ height: "auto",
58399
58399
  justifyContent: "center",
58400
58400
  alignItems: "center",
58401
58401
  sx: { display: "flex", backgroundColor: un },
@@ -58423,7 +58423,7 @@ const $5 = {
58423
58423
  }
58424
58424
  );
58425
58425
  };
58426
- function v4({ label: t, imageSrc: e }) {
58426
+ function v3({ label: t, imageSrc: e }) {
58427
58427
  return /* @__PURE__ */ T.jsxs(
58428
58428
  ct,
58429
58429
  {
@@ -58447,7 +58447,7 @@ function v4({ label: t, imageSrc: e }) {
58447
58447
  const G5 = {
58448
58448
  border: `1px solid ${un}`,
58449
58449
  opacity: "40%"
58450
- }, x4 = () => /* @__PURE__ */ T.jsx(ct, { sx: G5 }), Y5 = {
58450
+ }, x3 = () => /* @__PURE__ */ T.jsx(ct, { sx: G5 }), Y5 = {
58451
58451
  width: "36px",
58452
58452
  height: "36px",
58453
58453
  borderRadius: "50%",
@@ -58457,7 +58457,7 @@ const G5 = {
58457
58457
  fontSize: "20px",
58458
58458
  lineHeight: "20px",
58459
58459
  color: un
58460
- }, T4 = ({ logo: t, title: e }) => /* @__PURE__ */ T.jsxs(lt, { container: !0, gap: "8px", alignItems: "center", children: [
58460
+ }, T3 = ({ logo: t, title: e }) => /* @__PURE__ */ T.jsxs(lt, { container: !0, gap: "8px", alignItems: "center", children: [
58461
58461
  /* @__PURE__ */ T.jsx(ct, { sx: Y5, display: "flex", alignItems: "center", justifyContent: "center", children: /* @__PURE__ */ T.jsx("img", { src: t, alt: e, loading: "lazy" }) }),
58462
58462
  /* @__PURE__ */ T.jsx(wt, { sx: K5, children: e })
58463
58463
  ] }), q5 = (t) => {
@@ -58478,16 +58478,16 @@ const G5 = {
58478
58478
  }, J5 = (t) => ({
58479
58479
  ...t,
58480
58480
  boxShadow: "none"
58481
- }), S4 = ({ columnDefs: t, data: e, sx: n }) => /* @__PURE__ */ T.jsx(Ld, { component: Rr, sx: J5(n), children: /* @__PURE__ */ T.jsx(al, { children: /* @__PURE__ */ T.jsx(Pd, { children: t.map((r, o) => /* @__PURE__ */ T.jsxs(Go, { children: [
58481
+ }), S3 = ({ columnDefs: t, data: e, sx: n }) => /* @__PURE__ */ T.jsx(Ld, { component: Rr, sx: J5(n), children: /* @__PURE__ */ T.jsx(al, { children: /* @__PURE__ */ T.jsx(Pd, { children: t.map((r, o) => /* @__PURE__ */ T.jsxs(Go, { children: [
58482
58482
  /* @__PURE__ */ T.jsx(hr, { component: "th", scope: "row", sx: Q5, children: /* @__PURE__ */ T.jsx(wt, { fontWeight: "500", children: r.headerName }) }),
58483
58483
  /* @__PURE__ */ T.jsx(hr, { sx: Z5, children: r.renderCell ? r.renderCell(e[r.field]) : X5(e[r.field]) })
58484
- ] }, o)) }) }) }), e4 = {
58484
+ ] }, o)) }) }) }), e3 = {
58485
58485
  width: "36px",
58486
58486
  height: "36px",
58487
58487
  borderRadius: "50%",
58488
58488
  overflow: "hidden",
58489
58489
  cursor: "pointer"
58490
- }, E4 = ({ imageSrc: t, alt: e }) => /* @__PURE__ */ T.jsx(ct, { sx: e4, children: /* @__PURE__ */ T.jsx("img", { src: t, alt: e }) }), t4 = {
58490
+ }, E3 = ({ imageSrc: t, alt: e }) => /* @__PURE__ */ T.jsx(ct, { sx: e3, children: /* @__PURE__ */ T.jsx("img", { src: t, alt: e }) }), t3 = {
58491
58491
  "& .MuiSwitch-switchBase.Mui-checked": {
58492
58492
  color: un
58493
58493
  },
@@ -58501,7 +58501,7 @@ const G5 = {
58501
58501
  lineHeight: "16px",
58502
58502
  letterSpacing: "0.15px",
58503
58503
  color: Vl
58504
- }, C4 = ({
58504
+ }, C3 = ({
58505
58505
  checked: t,
58506
58506
  onChange: e,
58507
58507
  leftLabel: n,
@@ -58513,13 +58513,13 @@ const G5 = {
58513
58513
  Ei,
58514
58514
  {
58515
58515
  sx: { margin: 0 },
58516
- control: /* @__PURE__ */ T.jsx(p0, { checked: t, onChange: e, sx: t4 }),
58516
+ control: /* @__PURE__ */ T.jsx(p0, { checked: t, onChange: e, sx: t3 }),
58517
58517
  label: ""
58518
58518
  }
58519
58519
  ),
58520
58520
  o && /* @__PURE__ */ T.jsx(bo, { sx: eg, children: o })
58521
58521
  ] });
58522
- function R4({ images: t }) {
58522
+ function R3({ images: t }) {
58523
58523
  const [e, n] = ft(0), r = () => {
58524
58524
  n((i) => (i + 1) % t.length);
58525
58525
  }, o = () => {
@@ -58597,14 +58597,15 @@ function R4({ images: t }) {
58597
58597
  )
58598
58598
  ] });
58599
58599
  }
58600
- const w4 = ({
58600
+ const w3 = ({
58601
58601
  label: t,
58602
58602
  options: e,
58603
- onChange: n
58603
+ value: n,
58604
+ onChange: r
58604
58605
  }) => /* @__PURE__ */ T.jsxs(Os, { fullWidth: !0, size: "small", children: [
58605
58606
  /* @__PURE__ */ T.jsx(bo, { sx: $y, children: t }),
58606
- /* @__PURE__ */ T.jsx(Ro, { sx: Ny, label: t, onChange: n, children: e.map((r) => /* @__PURE__ */ T.jsx(Co, { value: r.value, children: r.label }, r.value)) })
58607
- ] }), n4 = (t) => t.replace(/_/g, " ").replace(/\b\w/g, (e) => e.toUpperCase()), I4 = (t) => t.join(", "), tg = (t, e, n) => St().startOf(t).set(e, n), r4 = (t, e, n) => St().endOf(t).set(e, n), o4 = (t) => St().subtract(1, "day").startOf("day").set("hour", t), ng = (t, e) => St().subtract(t, e), s4 = () => {
58607
+ /* @__PURE__ */ T.jsx(Ro, { sx: Ny, label: t, onChange: r, value: n, children: e.map((o) => /* @__PURE__ */ T.jsx(Co, { value: o.value, children: o.label }, o.value)) })
58608
+ ] }), n3 = (t) => t.replace(/_/g, " ").replace(/\b\w/g, (e) => e.toUpperCase()), I3 = (t) => t.join(", "), tg = (t, e, n) => St().startOf(t).set(e, n), r3 = (t, e, n) => St().endOf(t).set(e, n), o3 = (t) => St().subtract(1, "day").startOf("day").set("hour", t), ng = (t, e) => St().subtract(t, e), s3 = () => {
58608
58609
  const e = new Intl.DateTimeFormat(void 0, {
58609
58610
  year: "numeric",
58610
58611
  month: "2-digit",
@@ -58632,27 +58633,27 @@ const w4 = ({
58632
58633
  }
58633
58634
  }).join("");
58634
58635
  return n ? r.replace("hh", "hh") : r.replace("hh", "HH");
58635
- }, D4 = (t) => {
58636
- const e = s4();
58636
+ }, D3 = (t) => {
58637
+ const e = s3();
58637
58638
  return St(t).format(e);
58638
- }, A4 = (t) => {
58639
+ }, A3 = (t) => {
58639
58640
  const r = Math.floor(t / 6e4);
58640
58641
  t %= 6e4;
58641
58642
  const o = Math.floor(t / 1e3);
58642
58643
  let i = "";
58643
58644
  return r > 0 ? (i += `${r} min`, o > 0 && (i += ` ${o} sec`), i) : o > 0 ? (i += `${o} sec`, i) : "0 sec";
58644
- }, O4 = [
58645
+ }, O3 = [
58645
58646
  "Camera 1 (all items)",
58646
58647
  "Camera 5 (all items)",
58647
58648
  "Camera 2 (10 items)",
58648
58649
  "Camera 3 (Zone 1)",
58649
58650
  "Camera 4 (24 items)"
58650
- ], k4 = [
58651
+ ], k3 = [
58651
58652
  { key: "classifier", label: "Classifier" },
58652
58653
  { key: "value", label: "Value" },
58653
58654
  { key: "count", label: "Count" },
58654
58655
  { key: "score", label: "Score" }
58655
- ], P4 = [
58656
+ ], P3 = [
58656
58657
  {
58657
58658
  label: "Summary",
58658
58659
  value: "0",
@@ -58663,14 +58664,14 @@ const w4 = ({
58663
58664
  value: "1",
58664
58665
  disabled: !0
58665
58666
  }
58666
- ], L4 = [
58667
+ ], L3 = [
58667
58668
  { classifier: "Color", value: "Black", count: 50, score: "80%" },
58668
58669
  { classifier: "Color", value: "Yellow", count: 60, score: "70%" },
58669
58670
  { classifier: "Manufacture", value: "Volvo", count: 50, score: "80%" },
58670
58671
  { classifier: "Color", value: "Red", count: 50, score: "40%" },
58671
58672
  { classifier: "Color", value: "Green", count: 75, score: "70%" },
58672
58673
  { classifier: "Manufacture", value: "Man", count: 3, score: "80%" }
58673
- ], M4 = (t) => [
58674
+ ], M3 = (t) => [
58674
58675
  {
58675
58676
  value: "0",
58676
58677
  content: /* @__PURE__ */ T.jsx(aB, { ...t })
@@ -58679,7 +58680,7 @@ const w4 = ({
58679
58680
  value: "1",
58680
58681
  content: "More"
58681
58682
  }
58682
- ], _4 = {
58683
+ ], _3 = {
58683
58684
  data: [
58684
58685
  {
58685
58686
  id: "1",
@@ -58737,15 +58738,15 @@ const w4 = ({
58737
58738
  value: "kit"
58738
58739
  }
58739
58740
  ]
58740
- }, N4 = [
58741
+ }, N3 = [
58741
58742
  { key: "id", label: "ID" },
58742
58743
  { key: "name", label: "Name" },
58743
58744
  { key: "age", label: "Age" }
58744
- ], $4 = [
58745
+ ], $3 = [
58745
58746
  { id: 1, name: "John Doe", age: 30 },
58746
58747
  { id: 2, name: "Jane Smith", age: 25 },
58747
58748
  { id: 3, name: "Bob Johnson", age: 40 }
58748
- ], F4 = {
58749
+ ], F3 = {
58749
58750
  feed: 139,
58750
58751
  conbo_key: "28145-139-021-64216",
58751
58752
  event_id: "CNB-7987",
@@ -58755,12 +58756,12 @@ const w4 = ({
58755
58756
  end: "2024-05-15T21:05:27.745000Z",
58756
58757
  cargo: "N/A",
58757
58758
  zones: ["Dock main road ", "Hello dock"]
58758
- }, B4 = [
58759
+ }, B3 = [
58759
58760
  { headerName: "Event ID", field: "event_id" },
58760
58761
  {
58761
58762
  headerName: "Move",
58762
58763
  field: "move",
58763
- renderCell: (t) => n4(t)
58764
+ renderCell: (t) => n3(t)
58764
58765
  },
58765
58766
  {
58766
58767
  headerName: "Start",
@@ -58774,7 +58775,7 @@ const w4 = ({
58774
58775
  },
58775
58776
  { headerName: "Cargo", field: "cargo" },
58776
58777
  { headerName: "Zones", field: "zones" }
58777
- ], j4 = [
58778
+ ], j3 = [
58778
58779
  { id: "1", color: "#f99191", title: "New title" },
58779
58780
  {
58780
58781
  id: "2",
@@ -58782,7 +58783,7 @@ const w4 = ({
58782
58783
  title: "Message should contain more information"
58783
58784
  },
58784
58785
  { id: "3", color: "#7095f4", title: "Hello, World!" }
58785
- ], V4 = [
58786
+ ], V3 = [
58786
58787
  {
58787
58788
  label: "Start of the day",
58788
58789
  getValue: () => tg("day", "hour", 6)
@@ -58793,11 +58794,11 @@ const w4 = ({
58793
58794
  },
58794
58795
  {
58795
58796
  label: "End of day today at 18:00",
58796
- getValue: () => r4("day", "hour", 18)
58797
+ getValue: () => r3("day", "hour", 18)
58797
58798
  },
58798
58799
  {
58799
58800
  label: "Start of yesterday",
58800
- getValue: () => o4(6)
58801
+ getValue: () => o3(6)
58801
58802
  },
58802
58803
  {
58803
58804
  label: "One hour ago",
@@ -58807,7 +58808,7 @@ const w4 = ({
58807
58808
  label: "One day ago",
58808
58809
  getValue: () => ng(1, "day")
58809
58810
  }
58810
- ], U4 = [
58811
+ ], U3 = [
58811
58812
  {
58812
58813
  value: 864e5,
58813
58814
  label: "1 day"
@@ -58823,14 +58824,14 @@ export {
58823
58824
  S1 as ACTIVE_TAB,
58824
58825
  Yr as ActionButton,
58825
58826
  RL as ActionSelect,
58826
- v4 as AppTitleBar,
58827
+ v3 as AppTitleBar,
58827
58828
  ld as BETWEEN_GRAY_BORDER,
58828
58829
  d1 as BG_GRAY_COLOR,
58829
58830
  Vl as BLACK,
58830
58831
  R1 as BORDER_TAB,
58831
58832
  wL as ChipsBar,
58832
- m4 as ChipsMultiSelect,
58833
- w4 as CustomSelect,
58833
+ m3 as ChipsMultiSelect,
58834
+ w3 as CustomSelect,
58834
58835
  T1 as DARK_BLUE_BORDER,
58835
58836
  E1 as DEFAULT_TAB,
58836
58837
  Xs as DETAILS_VIEW_BG,
@@ -58840,22 +58841,22 @@ export {
58840
58841
  f1 as DISABLED_CHECKBOX,
58841
58842
  Rp as DISABLED_TEXT,
58842
58843
  b1 as DISABLED_TEXT_ICON,
58843
- l4 as DatePicker,
58844
- x4 as Delimiter,
58845
- p4 as DetailsView,
58846
- h4 as DetailsViewPanel,
58844
+ l3 as DatePicker,
58845
+ x3 as Delimiter,
58846
+ p3 as DetailsView,
58847
+ h3 as DetailsViewPanel,
58847
58848
  rB as Filter,
58848
- c4 as FilterBox,
58849
+ c3 as FilterBox,
58849
58850
  v1 as GRAY_BORDER,
58850
58851
  yb as HOVER_BTN_PRIMARY,
58851
58852
  g1 as HOVER_BTN_SECONDARY,
58852
58853
  p1 as HOVER_DARK_BLUE_ICON,
58853
58854
  C1 as HOVER_TAB,
58854
- d4 as Header,
58855
- f4 as HomeLink,
58856
- R4 as ImageBox,
58855
+ d3 as Header,
58856
+ f3 as HomeLink,
58857
+ R3 as ImageBox,
58857
58858
  x1 as LIGHT_GRAY_BORDER,
58858
- T4 as Logo,
58859
+ T3 as Logo,
58859
58860
  aB as MainTable,
58860
58861
  eB as NotificationBar,
58861
58862
  Ft as PASSIVE_BTN_PRIMARY,
@@ -58863,38 +58864,38 @@ export {
58863
58864
  ul as PLACEMENTS,
58864
58865
  Y2 as SearchInput,
58865
58866
  $t as Svg,
58866
- P4 as TABS,
58867
+ P3 as TABS,
58867
58868
  fB as Tab,
58868
- u4 as TabsBar,
58869
- C4 as Toggle,
58870
- E4 as UserAvatar,
58871
- S4 as VerticalTable,
58872
- y4 as VideoBox,
58869
+ u3 as TabsBar,
58870
+ C3 as Toggle,
58871
+ E3 as UserAvatar,
58872
+ S3 as VerticalTable,
58873
+ y3 as VideoBox,
58873
58874
  un as WHITE,
58874
- k4 as columnDefs,
58875
- N4 as columns,
58876
- O4 as dataMock,
58877
- L4 as detailsViewDataMock,
58878
- D4 as formatDateWithLocal,
58879
- A4 as formatDuration,
58880
- I4 as formatValueWithComma,
58881
- r4 as getEndTime,
58882
- s4 as getLocalDateTimeFormat,
58875
+ k3 as columnDefs,
58876
+ N3 as columns,
58877
+ O3 as dataMock,
58878
+ L3 as detailsViewDataMock,
58879
+ D3 as formatDateWithLocal,
58880
+ A3 as formatDuration,
58881
+ I3 as formatValueWithComma,
58882
+ r3 as getEndTime,
58883
+ s3 as getLocalDateTimeFormat,
58883
58884
  tg as getStartTime,
58884
- o4 as getStartTimeOfYesterday,
58885
- M4 as getTabsContent,
58885
+ o3 as getStartTimeOfYesterday,
58886
+ M3 as getTabsContent,
58886
58887
  $y as inputLabelSx,
58887
58888
  _y as loaderSx,
58888
- $4 as mainTableDataMock,
58889
- U4 as mockSelectOptions,
58890
- V4 as mockShortcut,
58891
- _4 as newFilterMock,
58889
+ $3 as mainTableDataMock,
58890
+ U3 as mockSelectOptions,
58891
+ V3 as mockShortcut,
58892
+ _3 as newFilterMock,
58892
58893
  Ny as selectSx,
58893
- n4 as snakeCaseToTitleCase,
58894
+ n3 as snakeCaseToTitleCase,
58894
58895
  ng as subtractTime,
58895
58896
  Ly as tabSx,
58896
- j4 as tabsMock,
58897
+ j3 as tabsMock,
58897
58898
  My as tabsSx,
58898
- B4 as verticalTableColumnDefs,
58899
- F4 as verticalTableDataMock
58899
+ B3 as verticalTableColumnDefs,
58900
+ F3 as verticalTableDataMock
58900
58901
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@conboai/storybook.components",
3
- "version": "0.2.7",
3
+ "version": "0.2.9",
4
4
  "main": "dist/storybook.components.mjs",
5
5
  "types": "dist/build/index.d.ts",
6
6
  "files": [