camox 0.35.0 → 0.36.1

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.
@@ -11,11 +11,11 @@ import { Navbar } from "../studio/components/Navbar.js";
11
11
  import { previewStore } from "./previewStore.js";
12
12
  import { CreatePageModal } from "./components/CreatePageModal.js";
13
13
  import { DraftSwitchDialog } from "./components/DraftSwitchDialog.js";
14
- import { pageFullQueryFn } from "./previewQueryFns.js";
15
14
  import { LeftSidebar } from "./components/LeftSidebar.js";
16
15
  import { PeekedBlock } from "./components/PeekedBlock.js";
17
16
  import { PreviewPanel } from "./components/PreviewPanel.js";
18
17
  import { RightSidebar } from "./components/RightSidebar.js";
18
+ import { pageFullQueryFn } from "./previewQueryFns.js";
19
19
  import { c } from "react/compiler-runtime";
20
20
  import { keepPreviousData, useQuery, useQueryClient, useSuspenseQuery } from "@tanstack/react-query";
21
21
  import * as React from "react";
@@ -51,9 +51,9 @@ function pageStructureQueryFn(path, projectSlug, source) {
51
51
  }
52
52
  function usePreviewedPage() {
53
53
  const $ = c(26);
54
- if ($[0] !== "670b66d6cc9d1448ea3caf37ecbbb00789310266338f543cbce54775c049c772") {
54
+ if ($[0] !== "08efc24964e6f71a0b75d26676e04d8253640e7adc88fa9c6e2293e86440c27a") {
55
55
  for (let $i = 0; $i < 26; $i += 1) $[$i] = Symbol.for("react.memo_cache_sentinel");
56
- $[0] = "670b66d6cc9d1448ea3caf37ecbbb00789310266338f543cbce54775c049c772";
56
+ $[0] = "08efc24964e6f71a0b75d26676e04d8253640e7adc88fa9c6e2293e86440c27a";
57
57
  }
58
58
  const { pathname } = useLocation();
59
59
  const queryClient = useQueryClient();
@@ -150,9 +150,9 @@ function _temp(state) {
150
150
  }
151
151
  const BlockRenderer = (t0) => {
152
152
  const $ = c(23);
153
- if ($[0] !== "670b66d6cc9d1448ea3caf37ecbbb00789310266338f543cbce54775c049c772") {
153
+ if ($[0] !== "08efc24964e6f71a0b75d26676e04d8253640e7adc88fa9c6e2293e86440c27a") {
154
154
  for (let $i = 0; $i < 23; $i += 1) $[$i] = Symbol.for("react.memo_cache_sentinel");
155
- $[0] = "670b66d6cc9d1448ea3caf37ecbbb00789310266338f543cbce54775c049c772";
155
+ $[0] = "08efc24964e6f71a0b75d26676e04d8253640e7adc88fa9c6e2293e86440c27a";
156
156
  }
157
157
  const { blockId, mode, showAddBlockTop, showAddBlockBottom } = t0;
158
158
  const previewSource = useSelector(previewStore, _temp3);
@@ -295,9 +295,9 @@ const PageContent = () => {
295
295
  };
296
296
  function useHydrateDraftCache() {
297
297
  const $ = c(7);
298
- if ($[0] !== "670b66d6cc9d1448ea3caf37ecbbb00789310266338f543cbce54775c049c772") {
298
+ if ($[0] !== "08efc24964e6f71a0b75d26676e04d8253640e7adc88fa9c6e2293e86440c27a") {
299
299
  for (let $i = 0; $i < 7; $i += 1) $[$i] = Symbol.for("react.memo_cache_sentinel");
300
- $[0] = "670b66d6cc9d1448ea3caf37ecbbb00789310266338f543cbce54775c049c772";
300
+ $[0] = "08efc24964e6f71a0b75d26676e04d8253640e7adc88fa9c6e2293e86440c27a";
301
301
  }
302
302
  const isAuthenticated = useIsAuthenticated();
303
303
  const queryClient = useQueryClient();
@@ -347,15 +347,17 @@ function useHydrateDraftCache() {
347
347
  }
348
348
  function _temp4() {}
349
349
  const CamoxPreview = (t0) => {
350
- const $ = c(35);
351
- if ($[0] !== "670b66d6cc9d1448ea3caf37ecbbb00789310266338f543cbce54775c049c772") {
352
- for (let $i = 0; $i < 35; $i += 1) $[$i] = Symbol.for("react.memo_cache_sentinel");
353
- $[0] = "670b66d6cc9d1448ea3caf37ecbbb00789310266338f543cbce54775c049c772";
350
+ const $ = c(40);
351
+ if ($[0] !== "08efc24964e6f71a0b75d26676e04d8253640e7adc88fa9c6e2293e86440c27a") {
352
+ for (let $i = 0; $i < 40; $i += 1) $[$i] = Symbol.for("react.memo_cache_sentinel");
353
+ $[0] = "08efc24964e6f71a0b75d26676e04d8253640e7adc88fa9c6e2293e86440c27a";
354
354
  }
355
355
  const { children } = t0;
356
356
  const isAuthenticated = useIsAuthenticated();
357
357
  const isEditMode = useSelector(previewStore, _temp5);
358
- const previewSource = useSelector(previewStore, _temp6);
358
+ const isToolbarHidden = useSelector(previewStore, _temp6);
359
+ const isAddBlockSidebarOpen = useSelector(previewStore, _temp7);
360
+ const previewSource = useSelector(previewStore, _temp8);
359
361
  const pageData = usePreviewedPage();
360
362
  useHydrateDraftCache();
361
363
  const hasLiveCheckpoint = pageData.page.livePublishedCheckpointId != null;
@@ -375,7 +377,7 @@ const CamoxPreview = (t0) => {
375
377
  ],
376
378
  groupLabel: "Preview",
377
379
  checkIfAvailable: () => isAuthenticated && isEditMode,
378
- execute: _temp7,
380
+ execute: _temp9,
379
381
  shortcut: {
380
382
  key: "Enter",
381
383
  withMeta: true
@@ -391,7 +393,7 @@ const CamoxPreview = (t0) => {
391
393
  ],
392
394
  groupLabel: "Preview",
393
395
  checkIfAvailable: () => isAuthenticated && !isEditMode,
394
- execute: _temp8,
396
+ execute: _temp0,
395
397
  shortcut: {
396
398
  key: "Enter",
397
399
  withMeta: true
@@ -407,7 +409,7 @@ const CamoxPreview = (t0) => {
407
409
  ],
408
410
  groupLabel: "Preview",
409
411
  checkIfAvailable: () => isAuthenticated && previewSource === "draft" && hasLiveCheckpoint,
410
- execute: _temp9,
412
+ execute: _temp1,
411
413
  shortcut: {
412
414
  key: "d",
413
415
  withAlt: true
@@ -423,7 +425,7 @@ const CamoxPreview = (t0) => {
423
425
  ],
424
426
  groupLabel: "Preview",
425
427
  checkIfAvailable: () => isAuthenticated && previewSource === "live",
426
- execute: _temp0,
428
+ execute: _temp10,
427
429
  shortcut: {
428
430
  key: "d",
429
431
  withAlt: true
@@ -434,8 +436,8 @@ const CamoxPreview = (t0) => {
434
436
  label: "Clear selection",
435
437
  aliases: ["Deselect", "Unselect"],
436
438
  groupLabel: "Preview",
437
- checkIfAvailable: _temp1,
438
- execute: _temp10,
439
+ checkIfAvailable: _temp11,
440
+ execute: _temp12,
439
441
  shortcut: { key: "Escape" }
440
442
  }
441
443
  ];
@@ -446,7 +448,7 @@ const CamoxPreview = (t0) => {
446
448
  return () => {
447
449
  actionsStore.send({
448
450
  type: "unregisterManyActions",
449
- ids: actions.map(_temp11)
451
+ ids: actions.map(_temp13)
450
452
  });
451
453
  };
452
454
  };
@@ -476,7 +478,6 @@ const CamoxPreview = (t0) => {
476
478
  } else t3 = $[8];
477
479
  return t3;
478
480
  }
479
- const shouldShowStudioChrome = isEditMode;
480
481
  const t3 = !isEditMode && "bg-black";
481
482
  let t4;
482
483
  if ($[9] !== t3) {
@@ -485,85 +486,107 @@ const CamoxPreview = (t0) => {
485
486
  $[10] = t4;
486
487
  } else t4 = $[10];
487
488
  let t5;
488
- if ($[11] !== shouldShowStudioChrome) {
489
- t5 = shouldShowStudioChrome && /* @__PURE__ */ jsx(Navbar, {});
490
- $[11] = shouldShowStudioChrome;
491
- $[12] = t5;
492
- } else t5 = $[12];
489
+ if ($[11] !== isAddBlockSidebarOpen || $[12] !== isToolbarHidden) {
490
+ t5 = !isToolbarHidden && /* @__PURE__ */ jsxs("div", {
491
+ className: "relative",
492
+ children: [/* @__PURE__ */ jsx(Navbar, {}), isAddBlockSidebarOpen && /* @__PURE__ */ jsx("div", {
493
+ className: "absolute inset-0 z-20",
494
+ style: { background: "rgba(0, 0, 0, 0.66)" },
495
+ onClick: _temp14
496
+ })]
497
+ });
498
+ $[11] = isAddBlockSidebarOpen;
499
+ $[12] = isToolbarHidden;
500
+ $[13] = t5;
501
+ } else t5 = $[13];
493
502
  let t6;
494
- if ($[13] !== pageData.page || $[14] !== shouldShowStudioChrome) {
495
- t6 = shouldShowStudioChrome && /* @__PURE__ */ jsx(LeftSidebar, { page: pageData.page });
496
- $[13] = pageData.page;
497
- $[14] = shouldShowStudioChrome;
498
- $[15] = t6;
499
- } else t6 = $[15];
503
+ if ($[14] !== isEditMode || $[15] !== pageData.page) {
504
+ t6 = isEditMode && /* @__PURE__ */ jsx(LeftSidebar, { page: pageData.page });
505
+ $[14] = isEditMode;
506
+ $[15] = pageData.page;
507
+ $[16] = t6;
508
+ } else t6 = $[16];
500
509
  let t7;
501
- if ($[16] !== shouldShowStudioChrome) {
502
- t7 = shouldShowStudioChrome && /* @__PURE__ */ jsx("div", { style: {
510
+ if ($[17] !== hasLiveCheckpoint || $[18] !== pageData.page.status) {
511
+ t7 = {
512
+ pageStatus: pageData.page.status,
513
+ hasLiveVersion: hasLiveCheckpoint
514
+ };
515
+ $[17] = hasLiveCheckpoint;
516
+ $[18] = pageData.page.status;
517
+ $[19] = t7;
518
+ } else t7 = $[19];
519
+ let t8;
520
+ if ($[20] !== isEditMode) {
521
+ t8 = isEditMode && /* @__PURE__ */ jsx("div", { style: {
503
522
  height: "80px",
504
523
  background: "transparent"
505
524
  } });
506
- $[16] = shouldShowStudioChrome;
507
- $[17] = t7;
508
- } else t7 = $[17];
509
- let t8;
510
- if ($[18] !== children || $[19] !== t7) {
511
- t8 = /* @__PURE__ */ jsxs(PreviewPanel, { children: [children, t7] });
512
- $[18] = children;
513
- $[19] = t7;
514
- $[20] = t8;
515
- } else t8 = $[20];
525
+ $[20] = isEditMode;
526
+ $[21] = t8;
527
+ } else t8 = $[21];
516
528
  let t9;
517
- if ($[21] !== pageData.page.id || $[22] !== shouldShowStudioChrome) {
518
- t9 = shouldShowStudioChrome && /* @__PURE__ */ jsx(RightSidebar, { pageId: pageData.page.id });
519
- $[21] = pageData.page.id;
520
- $[22] = shouldShowStudioChrome;
521
- $[23] = t9;
522
- } else t9 = $[23];
529
+ if ($[22] !== children || $[23] !== t7 || $[24] !== t8) {
530
+ t9 = /* @__PURE__ */ jsxs(PreviewPanel, {
531
+ toolbarProps: t7,
532
+ children: [children, t8]
533
+ });
534
+ $[22] = children;
535
+ $[23] = t7;
536
+ $[24] = t8;
537
+ $[25] = t9;
538
+ } else t9 = $[25];
523
539
  let t10;
524
- if ($[24] !== t6 || $[25] !== t8 || $[26] !== t9) {
525
- t10 = /* @__PURE__ */ jsxs("div", {
540
+ if ($[26] !== isEditMode || $[27] !== pageData.page.id) {
541
+ t10 = isEditMode && /* @__PURE__ */ jsx(RightSidebar, { pageId: pageData.page.id });
542
+ $[26] = isEditMode;
543
+ $[27] = pageData.page.id;
544
+ $[28] = t10;
545
+ } else t10 = $[28];
546
+ let t11;
547
+ if ($[29] !== t10 || $[30] !== t6 || $[31] !== t9) {
548
+ t11 = /* @__PURE__ */ jsxs("div", {
526
549
  className: "flex h-full flex-row items-stretch",
527
550
  children: [
528
551
  t6,
529
- t8,
530
- t9
552
+ t9,
553
+ t10
531
554
  ]
532
555
  });
533
- $[24] = t6;
534
- $[25] = t8;
535
- $[26] = t9;
536
- $[27] = t10;
537
- } else t10 = $[27];
538
- let t11;
539
- if ($[28] !== shouldShowStudioChrome) {
540
- t11 = shouldShowStudioChrome && /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(CreatePageModal, {}), /* @__PURE__ */ jsx(DraftSwitchDialog, {})] });
541
- $[28] = shouldShowStudioChrome;
542
- $[29] = t11;
543
- } else t11 = $[29];
556
+ $[29] = t10;
557
+ $[30] = t6;
558
+ $[31] = t9;
559
+ $[32] = t11;
560
+ } else t11 = $[32];
544
561
  let t12;
545
- if ($[30] !== t10 || $[31] !== t11 || $[32] !== t4 || $[33] !== t5) {
546
- t12 = /* @__PURE__ */ jsxs("div", {
562
+ if ($[33] !== isEditMode) {
563
+ t12 = isEditMode && /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(CreatePageModal, {}), /* @__PURE__ */ jsx(DraftSwitchDialog, {})] });
564
+ $[33] = isEditMode;
565
+ $[34] = t12;
566
+ } else t12 = $[34];
567
+ let t13;
568
+ if ($[35] !== t11 || $[36] !== t12 || $[37] !== t4 || $[38] !== t5) {
569
+ t13 = /* @__PURE__ */ jsxs("div", {
547
570
  className: t4,
548
571
  children: [
549
572
  t5,
550
- t10,
551
- t11
573
+ t11,
574
+ t12
552
575
  ]
553
576
  });
554
- $[30] = t10;
555
- $[31] = t11;
556
- $[32] = t4;
557
- $[33] = t5;
558
- $[34] = t12;
559
- } else t12 = $[34];
560
- return t12;
577
+ $[35] = t11;
578
+ $[36] = t12;
579
+ $[37] = t4;
580
+ $[38] = t5;
581
+ $[39] = t13;
582
+ } else t13 = $[39];
583
+ return t13;
561
584
  };
562
585
  function usePreviewPagesActions() {
563
586
  const $ = c(13);
564
- if ($[0] !== "670b66d6cc9d1448ea3caf37ecbbb00789310266338f543cbce54775c049c772") {
587
+ if ($[0] !== "08efc24964e6f71a0b75d26676e04d8253640e7adc88fa9c6e2293e86440c27a") {
565
588
  for (let $i = 0; $i < 13; $i += 1) $[$i] = Symbol.for("react.memo_cache_sentinel");
566
- $[0] = "670b66d6cc9d1448ea3caf37ecbbb00789310266338f543cbce54775c049c772";
589
+ $[0] = "08efc24964e6f71a0b75d26676e04d8253640e7adc88fa9c6e2293e86440c27a";
567
590
  }
568
591
  const navigate = useNavigate();
569
592
  const { pathname } = useLocation();
@@ -604,8 +627,8 @@ function usePreviewPagesActions() {
604
627
  label: "Create page",
605
628
  aliases: ["New page", "Add page"],
606
629
  groupLabel: "Preview",
607
- checkIfAvailable: _temp12,
608
- execute: _temp13
630
+ checkIfAvailable: _temp15,
631
+ execute: _temp16
609
632
  },
610
633
  {
611
634
  id: "edit-current-page",
@@ -636,14 +659,14 @@ function usePreviewPagesActions() {
636
659
  groupLabel: "Preview",
637
660
  checkIfAvailable: () => !!pages,
638
661
  hasChildren: true,
639
- execute: _temp14
662
+ execute: _temp17
640
663
  },
641
664
  ...pages ? pages.map((page) => ({
642
665
  id: `go-to-page-${page.id}`,
643
666
  parentActionId: "go-to-page",
644
667
  label: `Go to "${page.nickname}"`,
645
668
  groupLabel: "Preview",
646
- checkIfAvailable: _temp15,
669
+ checkIfAvailable: _temp18,
647
670
  execute: () => navigate({ to: page.fullPath })
648
671
  })) : []
649
672
  ];
@@ -654,7 +677,7 @@ function usePreviewPagesActions() {
654
677
  return () => {
655
678
  actionsStore.send({
656
679
  type: "unregisterManyActions",
657
- ids: actions.map(_temp16)
680
+ ids: actions.map(_temp19)
658
681
  });
659
682
  };
660
683
  };
@@ -674,17 +697,17 @@ function usePreviewPagesActions() {
674
697
  }
675
698
  React.useEffect(t4, t5);
676
699
  }
677
- function _temp16(a) {
700
+ function _temp19(a) {
678
701
  return a.id;
679
702
  }
680
- function _temp15() {
703
+ function _temp18() {
681
704
  return true;
682
705
  }
683
- function _temp14() {}
684
- function _temp13() {
706
+ function _temp17() {}
707
+ function _temp16() {
685
708
  return previewStore.send({ type: "openCreatePageModal" });
686
709
  }
687
- function _temp12() {
710
+ function _temp15() {
688
711
  return true;
689
712
  }
690
713
  function _temp3(state) {
@@ -694,35 +717,44 @@ function _temp5(state) {
694
717
  return state.context.isEditMode;
695
718
  }
696
719
  function _temp6(state_0) {
697
- return state_0.context.previewSource;
720
+ return state_0.context.isToolbarHidden;
721
+ }
722
+ function _temp7(state_1) {
723
+ return state_1.context.isAddBlockSidebarOpen;
698
724
  }
699
- function _temp7() {
725
+ function _temp8(state_2) {
726
+ return state_2.context.previewSource;
727
+ }
728
+ function _temp9() {
700
729
  return previewStore.send({ type: "exitEditMode" });
701
730
  }
702
- function _temp8() {
731
+ function _temp0() {
703
732
  return previewStore.send({ type: "enterEditMode" });
704
733
  }
705
- function _temp9() {
734
+ function _temp1() {
706
735
  return previewStore.send({
707
736
  type: "setPreviewSource",
708
737
  source: "live"
709
738
  });
710
739
  }
711
- function _temp0() {
740
+ function _temp10() {
712
741
  return previewStore.send({
713
742
  type: "setPreviewSource",
714
743
  source: "draft"
715
744
  });
716
745
  }
717
- function _temp1() {
746
+ function _temp11() {
718
747
  return true;
719
748
  }
720
- function _temp10() {
749
+ function _temp12() {
721
750
  previewStore.send({ type: "clearSelection" });
722
751
  }
723
- function _temp11(a) {
752
+ function _temp13(a) {
724
753
  return a.id;
725
754
  }
755
+ function _temp14() {
756
+ return previewStore.send({ type: "closeAddBlockSidebar" });
757
+ }
726
758
 
727
759
  //#endregion
728
760
  export { CamoxPreview, PageContent, usePreviewPagesActions, usePreviewedPage };
@@ -16,8 +16,8 @@ import { toast } from "@camox/ui/toaster";
16
16
  import { Dialog, DialogContent, DialogTitle } from "@camox/ui/dialog";
17
17
  import { Label } from "@camox/ui/label";
18
18
  import { ButtonGroup } from "@camox/ui/button-group";
19
- import { Switch } from "@camox/ui/switch";
20
19
  import { Tooltip, TooltipContent, TooltipTrigger } from "@camox/ui/tooltip";
20
+ import { Switch } from "@camox/ui/switch";
21
21
 
22
22
  //#region src/features/preview/components/AssetLightbox.tsx
23
23
  function DeliveredSize(t0) {
@@ -272,7 +272,7 @@ const PageEditorSidebar = () => {
272
272
  children: [/* @__PURE__ */ jsx(Spinner, { className: "mr-2 size-3.5" }), " Loading block..."]
273
273
  });
274
274
  const fieldHasOwnView = fieldInfo ? fieldTypesDictionary[fieldInfo.fieldType].hasOwnView : false;
275
- const [pageNavigationItem, ...contentNavigationItems] = [
275
+ const navigationItems = [
276
276
  {
277
277
  key: "page",
278
278
  label: "Page",
@@ -307,47 +307,57 @@ const PageEditorSidebar = () => {
307
307
  ];
308
308
  return /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx("div", {
309
309
  className: "border-border flex flex-col gap-1.5 border-b px-2 py-4",
310
- children: /* @__PURE__ */ jsxs("nav", {
310
+ children: /* @__PURE__ */ jsx("nav", {
311
311
  "aria-label": "Selection path",
312
312
  className: "text-muted-foreground text-sm",
313
- children: [pageNavigationItem?.onClick ? /* @__PURE__ */ jsx("button", {
314
- type: "button",
315
- className: "hover:text-foreground block min-w-0 cursor-pointer truncate py-0.5 text-left transition-colors",
316
- onClick: pageNavigationItem.onClick,
317
- children: pageNavigationItem.label
318
- }) : /* @__PURE__ */ jsx("span", {
319
- className: "text-foreground block min-w-0 truncate py-0.5 font-medium",
320
- children: pageNavigationItem?.label
321
- }), /* @__PURE__ */ jsx("ol", {
313
+ children: /* @__PURE__ */ jsx("ol", {
322
314
  className: "flex flex-col",
323
- children: contentNavigationItems.map((item, index) => {
315
+ children: navigationItems.map((item, index) => {
316
+ const isFirstItem = index === 0;
317
+ const isLastItem = index === navigationItems.length - 1;
324
318
  return /* @__PURE__ */ jsxs("li", {
325
319
  className: "relative min-w-0 pl-6",
326
- children: [/* @__PURE__ */ jsx("svg", {
320
+ children: [/* @__PURE__ */ jsxs("svg", {
327
321
  "aria-hidden": "true",
328
- className: "text-muted-foreground pointer-events-none absolute top-0 left-0 h-full w-4",
322
+ className: "text-muted-foreground pointer-events-none absolute top-0 left-0 h-7 w-4",
329
323
  fill: "none",
330
324
  preserveAspectRatio: "none",
331
- viewBox: "0 0 16 24",
332
- children: /* @__PURE__ */ jsx("path", {
333
- d: index < contentNavigationItems.length - 1 ? "M1 0 V24 M1 5 Q1 12 8 12 H16" : "M1 0 V5 Q1 12 8 12 H16",
334
- stroke: "currentColor",
335
- strokeLinecap: "square",
336
- strokeWidth: "1.25",
337
- vectorEffect: "non-scaling-stroke"
338
- })
325
+ viewBox: "0 0 16 28",
326
+ children: [
327
+ !isFirstItem && /* @__PURE__ */ jsx("path", {
328
+ d: "M8 0 V10",
329
+ stroke: "currentColor",
330
+ strokeWidth: "1.5",
331
+ vectorEffect: "non-scaling-stroke"
332
+ }),
333
+ !isLastItem && /* @__PURE__ */ jsx("path", {
334
+ d: "M8 18 V28",
335
+ stroke: "currentColor",
336
+ strokeWidth: "1.5",
337
+ vectorEffect: "non-scaling-stroke"
338
+ }),
339
+ /* @__PURE__ */ jsx("circle", {
340
+ className: "fill-background",
341
+ cx: "8",
342
+ cy: "14",
343
+ r: "4",
344
+ stroke: "currentColor",
345
+ strokeWidth: "1.5",
346
+ vectorEffect: "non-scaling-stroke"
347
+ })
348
+ ]
339
349
  }), item.onClick ? /* @__PURE__ */ jsx("button", {
340
350
  type: "button",
341
- className: cn("hover:text-foreground relative -top-px block min-w-0 cursor-pointer truncate py-0.5 text-left transition-colors", item.isCurrent && "text-foreground font-medium"),
351
+ className: cn("hover:text-foreground flex h-7 min-w-0 cursor-pointer items-center truncate text-left transition-colors", item.isCurrent && "text-foreground font-medium"),
342
352
  onClick: item.onClick,
343
353
  children: item.label
344
354
  }) : /* @__PURE__ */ jsx("span", {
345
- className: "text-foreground relative -top-px block min-w-0 truncate py-0.5 font-medium",
355
+ className: "text-foreground block h-7 min-w-0 truncate leading-7 font-medium",
346
356
  children: item.label
347
357
  })]
348
358
  }, item.key);
349
359
  })
350
- })]
360
+ })
351
361
  })
352
362
  }), /* @__PURE__ */ jsxs("div", {
353
363
  className: "relative flex-1 overflow-auto",
@@ -25,8 +25,8 @@ import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from "@
25
25
  import { useForm } from "@tanstack/react-form";
26
26
  import { InputGroup, InputGroupAddon, InputGroupButton, InputGroupText } from "@camox/ui/input-group";
27
27
  import { Input } from "@camox/ui/input";
28
- import { Switch } from "@camox/ui/switch";
29
28
  import { Tooltip, TooltipContent, TooltipTrigger } from "@camox/ui/tooltip";
29
+ import { Switch } from "@camox/ui/switch";
30
30
 
31
31
  //#region src/features/preview/components/PageInfoSidebar.tsx
32
32
  const usePageMetadataData = (pageId) => {