tinacms 2.9.1 → 2.9.3

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.
Files changed (22) hide show
  1. package/dist/index.js +321 -135
  2. package/dist/index.mjs +322 -136
  3. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/blockquote-element.d.ts +1 -1
  4. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/button.d.ts +2 -2
  5. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/code-block/code-block-element.d.ts +1 -1
  6. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/code-line-element.d.ts +1 -1
  7. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/list-element.d.ts +2 -2
  8. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/paragraph-element.d.ts +1 -1
  9. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/slash-input-element.d.ts +1 -1
  10. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/table/table-cell-element.d.ts +2 -2
  11. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/table/table-element.d.ts +1 -1
  12. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/table/table-row-element.d.ts +1 -1
  13. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/plugins/ui/components.d.ts +18 -18
  14. package/dist/toolkit/form-builder/form-builder.d.ts +2 -1
  15. package/dist/toolkit/icons/TinaExtended.d.ts +4 -0
  16. package/dist/toolkit/icons/index.d.ts +1 -0
  17. package/dist/toolkit/plugin-branch-switcher/branch-button.d.ts +3 -1
  18. package/dist/toolkit/react-modals/modal/modal-actions.d.ts +2 -1
  19. package/dist/toolkit/react-sidebar/components/local-warning.d.ts +3 -1
  20. package/dist/toolkit/styles/dropdown-button.d.ts +75 -0
  21. package/dist/toolkit/styles/index.d.ts +1 -0
  22. package/package.json +2 -2
package/dist/index.js CHANGED
@@ -73,8 +73,14 @@ var __publicField = (obj, key, value) => {
73
73
  portalNode
74
74
  );
75
75
  };
76
- const ModalActions = ({ children }) => {
77
- return /* @__PURE__ */ React__namespace.createElement("div", { className: "w-full flex justify-between gap-4 items-center px-5 pb-5 rounded-b-md" }, children);
76
+ const ModalActions = ({ align = "between", children }) => {
77
+ return /* @__PURE__ */ React__namespace.createElement(
78
+ "div",
79
+ {
80
+ className: `w-full flex flex-wrap-reverse justify-${align} gap-4 items-center px-5 pb-5 rounded-b-md`
81
+ },
82
+ children
83
+ );
78
84
  };
79
85
  const ModalBody = ({ className = "", padded = false, ...props }) => /* @__PURE__ */ React.createElement(
80
86
  "div",
@@ -689,12 +695,84 @@ var __publicField = (obj, key, value) => {
689
695
  },
690
696
  /* @__PURE__ */ React__namespace.createElement("path", { d: "M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0zm-3.97-3.03a.75.75 0 0 0-1.08.022L7.477 9.417 5.384 7.323a.75.75 0 0 0-1.06 1.06L6.97 11.03a.75.75 0 0 0 1.079-.02l3.992-4.99a.75.75 0 0 0-.01-1.05z" })
691
697
  );
698
+ const TinaExtendedIcon = ({ ...props }) => /* @__PURE__ */ React__namespace.createElement(
699
+ "svg",
700
+ {
701
+ viewBox: "0 0 1020 254",
702
+ fill: "currentColor",
703
+ xmlns: "http://www.w3.org/2000/svg",
704
+ ...props
705
+ },
706
+ /* @__PURE__ */ React__namespace.createElement(
707
+ "path",
708
+ {
709
+ d: "M115.685 110.921C132.719 98.699 135.293 42.2913 140.63 20.6271C145.968 -1.03697 168.043 0.0618098 168.043 0.0618098C168.043 0.0618098 162.312 10.0353 164.649 17.478C166.987 24.9207 183 31.5735 183 31.5735L179.546 40.6787C179.546 40.6787 172.334 39.7562 168.043 48.3408C156.833 70.7637 176.368 136.236 176.368 136.236C176.368 136.236 145.007 180.759 145.007 214.282C145.007 235.763 155.174 253.765 155.174 253.765H140.907C140.907 253.765 119.978 228.858 115.685 216.41C111.393 203.962 113.109 191.515 113.109 191.515C113.109 191.515 90.3595 190.227 70.1863 191.515C50.0132 192.802 36.5597 210.144 34.1316 219.844C31.7036 229.544 30.6978 253.765 30.6978 253.765H19.4169C12.5507 232.576 7.09751 224.982 10.0558 214.282C18.2501 184.647 16.6405 167.839 14.7433 160.352C12.846 152.866 0 146.331 0 146.331C6.29266 133.511 16.4152 127.265 40.3455 126.708C67.9751 126.066 98.6519 123.142 115.685 110.921Z",
710
+ fill: "#EC4815"
711
+ }
712
+ ),
713
+ /* @__PURE__ */ React__namespace.createElement(
714
+ "path",
715
+ {
716
+ d: "M44.113 213.041C44.113 213.041 47.0281 240.018 62.5148 253.765H75.7865C62.5148 238.73 61.0676 199.54 61.0676 199.54C54.3171 201.738 44.9715 209.607 44.113 213.041Z",
717
+ fill: "#EC4815"
718
+ }
719
+ ),
720
+ /* @__PURE__ */ React__namespace.createElement(
721
+ "path",
722
+ {
723
+ d: "M290 124V153.6H261.6V195.6C261.6 205 265 208.6 277.2 208.6C281.4 208.6 286.6 208.2 291.6 207.8V237C286.2 238.2 277.4 239.6 266.4 239.6C231.6 239.6 225.2 219.6 225.2 204.2V153.6H207.2V124H225.2V106.2L259.6 90.4H261.6V124H290Z",
724
+ fill: "#EC4815"
725
+ }
726
+ ),
727
+ /* @__PURE__ */ React__namespace.createElement(
728
+ "path",
729
+ {
730
+ d: "M320.581 81.2H359.781V110.4H320.581V81.2ZM302.781 153.6V124H359.581V236H323.181V153.6H302.781Z",
731
+ fill: "#EC4815"
732
+ }
733
+ ),
734
+ /* @__PURE__ */ React__namespace.createElement(
735
+ "path",
736
+ {
737
+ d: "M420.022 138.8H423.622C427.222 127.6 435.022 120 457.022 120C480.022 120 497.422 131.2 497.422 158.4V236H461.022V169.2C461.022 157 454.222 151.4 443.022 151.4C430.422 151.4 423.422 157.6 423.422 172.8V236H387.022V124H420.022V138.8Z",
738
+ fill: "#EC4815"
739
+ }
740
+ ),
741
+ /* @__PURE__ */ React__namespace.createElement(
742
+ "path",
743
+ {
744
+ d: "M592.605 219H590.605C584.805 229.8 571.005 238.8 554.005 238.8C529.005 238.8 516.205 226.4 516.205 207C516.205 187.8 527.605 176.6 548.805 173.2L580.405 168.2C587.405 167 589.205 163.2 589.205 159.8V157.6C589.205 152.6 585.605 146.4 573.605 146.4C563.405 146.4 557.405 151 556.805 158.8H522.005C523.405 136.2 538.805 120 572.005 120C606.805 120 624.005 134 624.005 156.4V206.8H636.605V236H592.605V219ZM589.205 192.4V183H587.205C585.205 185.2 582.405 186.8 578.005 187.8L563.205 191.4C556.605 193 553.405 196.8 553.405 203C553.405 210.4 558.205 214.2 567.805 214.2C582.005 214.2 589.205 204.4 589.205 192.4Z",
745
+ fill: "#EC4815"
746
+ }
747
+ ),
748
+ /* @__PURE__ */ React__namespace.createElement(
749
+ "path",
750
+ {
751
+ d: "M726.356 200H747.356C743.756 227.8 728.556 240 700.956 240C666.356 240 650.756 219.6 650.756 180C650.756 145.8 662.756 120 700.956 120C732.956 120 743.556 137.2 746.356 160H725.156C723.156 145.4 716.156 136.6 700.956 136.6C680.956 136.6 671.356 149.8 671.356 180C671.356 208 679.356 223 700.956 223C715.956 223 724.156 214.6 726.356 200Z",
752
+ fill: "#EC4815"
753
+ }
754
+ ),
755
+ /* @__PURE__ */ React__namespace.createElement(
756
+ "path",
757
+ {
758
+ d: "M846.18 139.6H848.18C851.78 128 860.38 120 874.38 120C892.98 120 900.58 132.4 900.58 158.4V236H880.58V161.6C880.58 148 877.78 138.8 865.78 138.8C854.18 138.8 847.78 148.8 847.78 167.4V236H828.18V161.6C828.18 148.2 824.98 138.8 813.58 138.8C799.78 138.8 795.18 149.8 795.18 169.2V236H775.18V124H793.98V139.6H796.38C800.58 127.2 807.78 120 821.98 120C835.38 120 842.78 126.8 846.18 139.6Z",
759
+ fill: "#EC4815"
760
+ }
761
+ ),
762
+ /* @__PURE__ */ React__namespace.createElement(
763
+ "path",
764
+ {
765
+ d: "M1018.2 155H996.6C995.2 143.4 989.2 135.6 973.6 135.6C961.6 135.6 951 140.6 951 151.8C951 159.4 954.8 164.6 965.8 167.2L988.4 172.4C1009 177 1020 188 1020 205.2C1020 224.8 1007 240 975.6 240C947.8 240 931 229.6 927 205H950C953.2 219.2 961.6 224.4 976 224.4C988 224.4 999.2 220 999.2 207.2C999.2 199.6 994.4 193.8 982 190.8L955.6 184.6C940.4 181 930.6 171.2 930.6 154C930.6 134 945.8 120 974 120C1006 120 1016.4 137.8 1018.2 155Z",
766
+ fill: "#EC4815"
767
+ }
768
+ )
769
+ );
692
770
  const ModalHeader = ({ children, close: close2 }) => {
693
- return /* @__PURE__ */ React__namespace.createElement("div", { className: "h-14 flex items-center justify-between px-5 border-b border-gray-200 m-0" }, /* @__PURE__ */ React__namespace.createElement(ModalTitle, null, children), close2 && /* @__PURE__ */ React__namespace.createElement(
771
+ return /* @__PURE__ */ React__namespace.createElement("div", { className: "h-14 flex items-center px-5 border-b border-gray-200 m-0" }, /* @__PURE__ */ React__namespace.createElement(TinaIcon, { className: "w-10 h-auto -ml-1 mr-1 my-1 fill-tina-orange" }), /* @__PURE__ */ React__namespace.createElement(ModalTitle, null, children), close2 && /* @__PURE__ */ React__namespace.createElement(
694
772
  "div",
695
773
  {
696
774
  onClick: close2,
697
- className: "flex items-center fill-gray-400 cursor-pointer transition-colors duration-100 ease-out hover:fill-gray-700"
775
+ className: "ml-auto flex justify-self-end items-center fill-gray-400 cursor-pointer transition-colors duration-100 ease-out hover:fill-gray-700"
698
776
  },
699
777
  /* @__PURE__ */ React__namespace.createElement(CloseIcon, { className: "w-6 h-auto" })
700
778
  ));
@@ -36954,7 +37032,7 @@ Please wrap them with useCallback or configure the deps array correctly.`
36954
37032
  dropdownMenuLabelVariants,
36955
37033
  ["inset"]
36956
37034
  );
36957
- const DropdownMenuSeparator = cn$2.withCn(
37035
+ const DropdownMenuSeparator$1 = cn$2.withCn(
36958
37036
  DropdownMenuPrimitive__namespace.Separator,
36959
37037
  "-mx-1 my-1 h-px bg-muted"
36960
37038
  );
@@ -38888,9 +38966,6 @@ Please wrap them with useCallback or configure the deps array correctly.`
38888
38966
  function MdOutlineClear(props) {
38889
38967
  return GenIcon({ "tag": "svg", "attr": { "viewBox": "0 0 24 24" }, "child": [{ "tag": "path", "attr": { "fill": "none", "d": "M0 0h24v24H0V0z" }, "child": [] }, { "tag": "path", "attr": { "d": "M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12 19 6.41z" }, "child": [] }] })(props);
38890
38968
  }
38891
- function MdOutlineSaveAlt(props) {
38892
- return GenIcon({ "tag": "svg", "attr": { "viewBox": "0 0 24 24" }, "child": [{ "tag": "path", "attr": { "fill": "none", "d": "M0 0h24v24H0V0z" }, "child": [] }, { "tag": "path", "attr": { "d": "M19 12v7H5v-7H3v7c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-7h-2zm-6 .67 2.59-2.58L17 11.5l-5 5-5-5 1.41-1.41L11 12.67V3h2v9.67z" }, "child": [] }] })(props);
38893
- }
38894
38969
  function MdOutlineCloud(props) {
38895
38970
  return GenIcon({ "tag": "svg", "attr": { "viewBox": "0 0 24 24" }, "child": [{ "tag": "path", "attr": { "fill": "none", "d": "M0 0h24v24H0V0z" }, "child": [] }, { "tag": "path", "attr": { "d": "M12 6c2.62 0 4.88 1.86 5.39 4.43l.3 1.5 1.53.11A2.98 2.98 0 0 1 22 15c0 1.65-1.35 3-3 3H6c-2.21 0-4-1.79-4-4 0-2.05 1.53-3.76 3.56-3.97l1.07-.11.5-.95A5.469 5.469 0 0 1 12 6m0-2C9.11 4 6.6 5.64 5.35 8.04A5.994 5.994 0 0 0 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96A7.49 7.49 0 0 0 12 4z" }, "child": [] }] })(props);
38896
38971
  }
@@ -39128,10 +39203,10 @@ Please wrap them with useCallback or configure the deps array correctly.`
39128
39203
  }) => {
39129
39204
  const baseClasses = "icon-parent inline-flex items-center font-medium focus:outline-none focus:ring-2 focus:shadow-outline text-center inline-flex justify-center transition-all duration-150 ease-out ";
39130
39205
  const variantClasses = {
39131
- primary: `shadow text-white bg-blue-500 hover:bg-blue-600 focus:ring-blue-500 border-0`,
39132
- secondary: `shadow text-gray-500 hover:text-blue-500 bg-gray-50 hover:bg-white border border-gray-100`,
39133
- white: `shadow text-gray-500 hover:text-blue-500 bg-white hover:bg-gray-50 border border-gray-100`,
39134
- ghost: `text-gray-500 hover:text-blue-500 hover:shadow border border-transparent border-0 hover:border hover:border-gray-200 bg-transparent`,
39206
+ primary: `shadow text-white bg-tina-orange-dark hover:bg-tina-orange focus:ring-tina-orange-dark border-0`,
39207
+ secondary: `shadow text-gray-500 hover:tina-orange-dark bg-gray-50 hover:bg-white border border-gray-100`,
39208
+ white: `shadow text-gray-500 hover:tina-orange-dark bg-white hover:bg-gray-50 border border-gray-100`,
39209
+ ghost: `text-gray-500 hover:tina-orange-dark hover:shadow border border-transparent border-0 hover:border hover:border-gray-200 bg-transparent`,
39135
39210
  danger: `shadow text-white bg-red-500 hover:bg-red-600 focus:ring-red-500`,
39136
39211
  accent: `shadow text-white bg-orange-500 hover:bg-orange-600 focus:ring-orange-500`,
39137
39212
  custom: ""
@@ -39181,7 +39256,7 @@ Please wrap them with useCallback or configure the deps array correctly.`
39181
39256
  }) => {
39182
39257
  const baseClasses = "icon-parent inline-flex items-center border border-transparent text-sm font-medium focus:outline-none focus:ring-2 focus:shadow-outline text-center inline-flex justify-center transition-all duration-150 ease-out rounded-full";
39183
39258
  const variantClasses = {
39184
- primary: `shadow text-white bg-blue-500 hover:bg-blue-600 focus:ring-blue-500`,
39259
+ primary: `shadow text-white bg-tina-orange-dark hover:bg-tina-orange focus:ring-tina-orange-dark`,
39185
39260
  secondary: `shadow text-gray-500 hover:text-blue-500 bg-gray-50 hover:bg-white border border-gray-200`,
39186
39261
  white: `shadow text-gray-500 hover:text-blue-500 bg-white hover:bg-gray-50 border border-gray-200`,
39187
39262
  ghost: `text-gray-500 hover:text-blue-500 hover:shadow border border-transparent hover:border-gray-200 bg-transparent`,
@@ -39353,6 +39428,176 @@ Please wrap them with useCallback or configure the deps array correctly.`
39353
39428
  ))
39354
39429
  );
39355
39430
  };
39431
+ function cn(...inputs) {
39432
+ return tailwindMerge.twMerge(clsx.clsx(inputs));
39433
+ }
39434
+ function DropdownMenu({
39435
+ ...props
39436
+ }) {
39437
+ return /* @__PURE__ */ React__namespace.createElement(DropdownMenuPrimitive__namespace.Root, { "data-slot": "dropdown-menu", ...props });
39438
+ }
39439
+ function DropdownMenuTrigger({
39440
+ ...props
39441
+ }) {
39442
+ return /* @__PURE__ */ React__namespace.createElement(
39443
+ DropdownMenuPrimitive__namespace.Trigger,
39444
+ {
39445
+ "data-slot": "dropdown-menu-trigger",
39446
+ ...props
39447
+ }
39448
+ );
39449
+ }
39450
+ function DropdownMenuContent({
39451
+ className,
39452
+ sideOffset = 4,
39453
+ ...props
39454
+ }) {
39455
+ return /* @__PURE__ */ React__namespace.createElement(DropdownMenuPrimitive__namespace.Portal, null, /* @__PURE__ */ React__namespace.createElement(
39456
+ DropdownMenuPrimitive__namespace.Content,
39457
+ {
39458
+ "data-slot": "dropdown-menu-content",
39459
+ sideOffset,
39460
+ className: cn(
39461
+ "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-base max-h-(--radix-dropdown-menu-content-available-height) min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border p-1 shadow-md",
39462
+ className
39463
+ ),
39464
+ ...props
39465
+ }
39466
+ ));
39467
+ }
39468
+ function DropdownMenuItem({
39469
+ className,
39470
+ inset,
39471
+ variant = "default",
39472
+ ...props
39473
+ }) {
39474
+ return /* @__PURE__ */ React__namespace.createElement(
39475
+ DropdownMenuPrimitive__namespace.Item,
39476
+ {
39477
+ "data-slot": "dropdown-menu-item",
39478
+ "data-inset": inset,
39479
+ "data-variant": variant,
39480
+ className: cn(
39481
+ "focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 cursor-pointer text-gray-700 hover:text-blue-500",
39482
+ className
39483
+ ),
39484
+ ...props
39485
+ }
39486
+ );
39487
+ }
39488
+ function DropdownMenuSeparator({
39489
+ className,
39490
+ ...props
39491
+ }) {
39492
+ return /* @__PURE__ */ React__namespace.createElement(
39493
+ DropdownMenuPrimitive__namespace.Separator,
39494
+ {
39495
+ "data-slot": "dropdown-menu-separator",
39496
+ className: cn("bg-border -mx-1 my-1 h-px", className),
39497
+ ...props
39498
+ }
39499
+ );
39500
+ }
39501
+ const DropdownButton = React__namespace.forwardRef(
39502
+ ({
39503
+ variant = "primary",
39504
+ size: size2 = "medium",
39505
+ busy,
39506
+ disabled,
39507
+ rounded = "full",
39508
+ children,
39509
+ className = "",
39510
+ onMainAction,
39511
+ items: items2,
39512
+ showSplitButton = true,
39513
+ ...props
39514
+ }, ref) => {
39515
+ const [open, setOpen] = React__namespace.useState(false);
39516
+ if (!onMainAction || !showSplitButton) {
39517
+ return /* @__PURE__ */ React__namespace.createElement(DropdownMenu, { open, onOpenChange: setOpen, modal: false }, /* @__PURE__ */ React__namespace.createElement(DropdownMenuTrigger, { asChild: true }, /* @__PURE__ */ React__namespace.createElement(
39518
+ Button$1,
39519
+ {
39520
+ variant,
39521
+ size: size2,
39522
+ busy,
39523
+ disabled,
39524
+ rounded,
39525
+ className: cn$1("gap-2", className),
39526
+ ...props
39527
+ },
39528
+ children,
39529
+ /* @__PURE__ */ React__namespace.createElement(
39530
+ lucideReact.ChevronDownIcon,
39531
+ {
39532
+ className: cn$1(
39533
+ "h-4 w-4 transition-transform duration-200",
39534
+ open && "rotate-180"
39535
+ )
39536
+ }
39537
+ )
39538
+ )), /* @__PURE__ */ React__namespace.createElement(DropdownMenuContent, { align: "end", side: "bottom", className: "z-[100000]" }, items2.map((item, index) => /* @__PURE__ */ React__namespace.createElement(
39539
+ DropdownMenuItem,
39540
+ {
39541
+ key: index,
39542
+ onClick: item.onClick,
39543
+ disabled: item.disabled,
39544
+ variant: item.variant
39545
+ },
39546
+ item.icon && item.icon,
39547
+ item.label
39548
+ ))));
39549
+ }
39550
+ return /* @__PURE__ */ React__namespace.createElement("div", { className: cn$1("inline-flex", className) }, /* @__PURE__ */ React__namespace.createElement(
39551
+ Button$1,
39552
+ {
39553
+ variant,
39554
+ size: size2,
39555
+ busy,
39556
+ disabled,
39557
+ rounded: "left",
39558
+ onClick: onMainAction,
39559
+ className: "border-r-0 w-full",
39560
+ ...props
39561
+ },
39562
+ children
39563
+ ), /* @__PURE__ */ React__namespace.createElement(DropdownMenu, { open, onOpenChange: setOpen }, /* @__PURE__ */ React__namespace.createElement(DropdownMenuTrigger, null, /* @__PURE__ */ React__namespace.createElement(
39564
+ Button$1,
39565
+ {
39566
+ variant,
39567
+ size: size2,
39568
+ busy,
39569
+ disabled,
39570
+ rounded: "right",
39571
+ className: "px-4 border-l",
39572
+ style: { borderColor: "#00000030" },
39573
+ "aria-label": "More options"
39574
+ },
39575
+ /* @__PURE__ */ React__namespace.createElement(
39576
+ lucideReact.ChevronDownIcon,
39577
+ {
39578
+ className: cn$1(
39579
+ "h-4 w-4 transition-transform duration-200 fill-none",
39580
+ open && "rotate-180"
39581
+ ),
39582
+ style: { fill: "none" }
39583
+ }
39584
+ )
39585
+ )), /* @__PURE__ */ React__namespace.createElement(DropdownMenuContent, { align: "end", side: "bottom" }, items2.map((item, index) => {
39586
+ var _a2;
39587
+ return /* @__PURE__ */ React__namespace.createElement(React__namespace.Fragment, { key: index }, /* @__PURE__ */ React__namespace.createElement(
39588
+ DropdownMenuItem,
39589
+ {
39590
+ onClick: item.onClick,
39591
+ disabled: item.disabled,
39592
+ variant: item.variant
39593
+ },
39594
+ item.icon && item.icon,
39595
+ item.label
39596
+ ), item.variant === "destructive" && index < items2.length - 1 && ((_a2 = items2[index + 1]) == null ? void 0 : _a2.variant) !== "destructive" && /* @__PURE__ */ React__namespace.createElement(DropdownMenuSeparator, null));
39597
+ }))));
39598
+ }
39599
+ );
39600
+ DropdownButton.displayName = "DropdownButton";
39356
39601
  function useCMS() {
39357
39602
  return useCMS$1();
39358
39603
  }
@@ -43226,7 +43471,7 @@ Please wrap them with useCallback or configure the deps array correctly.`
43226
43471
  ...eventsToAlerts
43227
43472
  };
43228
43473
  }
43229
- add(level, message, timeout = 4e3) {
43474
+ add(level, message, timeout = 8e3) {
43230
43475
  const alert = {
43231
43476
  level,
43232
43477
  message,
@@ -44277,9 +44522,6 @@ Please wrap them with useCallback or configure the deps array correctly.`
44277
44522
  )
44278
44523
  ), description && /* @__PURE__ */ React.createElement("p", { className: "mt-2 text-sm text-gray-500" }, description));
44279
44524
  };
44280
- function cn(...inputs) {
44281
- return tailwindMerge.twMerge(clsx.clsx(inputs));
44282
- }
44283
44525
  const checkerboardStyle = {
44284
44526
  backgroundImage: "linear-gradient(45deg, #eee 25%, transparent 25%), linear-gradient(-45deg, #eee 25%, transparent 25%), linear-gradient(45deg, transparent 75%, #eee 75%), linear-gradient(-45deg, transparent 75%, #eee 75%)",
44285
44527
  backgroundSize: "12px 12px",
@@ -45212,14 +45454,14 @@ Please wrap them with useCallback or configure the deps array correctly.`
45212
45454
  children
45213
45455
  );
45214
45456
  };
45215
- const LocalWarning = () => {
45457
+ const LocalWarning = ({ className = "" }) => {
45216
45458
  var _a2, _b;
45217
45459
  const cms = useCMS$1();
45218
45460
  const isLocalMode = (_b = (_a2 = cms.api) == null ? void 0 : _a2.tina) == null ? void 0 : _b.isLocalMode;
45219
45461
  if (!isLocalMode) {
45220
45462
  return null;
45221
45463
  }
45222
- return /* @__PURE__ */ React__namespace.createElement(Callout, { calloutStyle: "warning", className: "w-fit" }, /* @__PURE__ */ React__namespace.createElement("a", { href: "https://tina.io/docs/r/what-is-tinacloud/", target: "_blank" }, "You are in local mode"));
45464
+ return /* @__PURE__ */ React__namespace.createElement(Callout, { calloutStyle: "warning", className: cn("w-fit", className) }, /* @__PURE__ */ React__namespace.createElement("a", { href: "https://tina.io/docs/r/what-is-tinacloud/", target: "_blank" }, "You are in local mode"));
45223
45465
  };
45224
45466
  const BillingWarning = () => {
45225
45467
  var _a2;
@@ -45960,7 +46202,7 @@ Please wrap them with useCallback or configure the deps array correctly.`
45960
46202
  requiredArgs(1, arguments);
45961
46203
  return formatDistance(dirtyDate, Date.now(), options);
45962
46204
  }
45963
- const version$1 = "2.9.1";
46205
+ const version$1 = "2.9.3";
45964
46206
  const VersionInfo = () => {
45965
46207
  var _a2, _b, _c, _d, _e, _f;
45966
46208
  const cms = useCMS();
@@ -46196,7 +46438,7 @@ Please wrap them with useCallback or configure the deps array correctly.`
46196
46438
  toggleMenu();
46197
46439
  }
46198
46440
  },
46199
- /* @__PURE__ */ React__namespace.createElement(BiMenu, { className: "h-6 w-auto text-gray-600" })
46441
+ /* @__PURE__ */ React__namespace.createElement(BiMenu, { className: "h-8 w-auto text-gray-600" })
46200
46442
  )), /* @__PURE__ */ React__namespace.createElement(
46201
46443
  "div",
46202
46444
  {
@@ -46217,8 +46459,8 @@ Please wrap them with useCallback or configure the deps array correctly.`
46217
46459
  toggleMenu();
46218
46460
  }
46219
46461
  },
46220
- /* @__PURE__ */ React__namespace.createElement(BiMenu, { className: "h-6 w-auto text-gray-600" })
46221
- ), /* @__PURE__ */ React__namespace.createElement("span", { className: "text-left inline-flex items-center text-xl tracking-wide text-gray-800/80 flex-1 gap-1" }, /* @__PURE__ */ React__namespace.createElement(TinaIcon, { className: "w-10 h-auto -ml-1 fill-orange-500" }), /* @__PURE__ */ React__namespace.createElement("span", null, "TinaCMS"))),
46462
+ /* @__PURE__ */ React__namespace.createElement(BiMenu, { className: "h-8 w-auto text-gray-600" })
46463
+ ), /* @__PURE__ */ React__namespace.createElement("span", { className: "text-left inline-flex items-center text-xl tracking-wide text-gray-800/80 flex-1 gap-1" }, /* @__PURE__ */ React__namespace.createElement(TinaExtendedIcon, { className: "h-8 w-auto fill-orange-500" }))),
46222
46464
  children,
46223
46465
  /* @__PURE__ */ React__namespace.createElement("div", { className: "flex flex-col px-6 flex-1 overflow-auto" }, showCollections && /* @__PURE__ */ React__namespace.createElement(React__namespace.Fragment, null, /* @__PURE__ */ React__namespace.createElement("h4", { className: "flex space-x-1 justify-items-start uppercase font-sans font-bold text-sm mb-3 mt-8 text-gray-700" }, /* @__PURE__ */ React__namespace.createElement("span", null, "Collections"), isLocalMode && /* @__PURE__ */ React__namespace.createElement("span", { className: "flex items-center" }, /* @__PURE__ */ React__namespace.createElement(
46224
46466
  "a",
@@ -46468,60 +46710,6 @@ Please wrap them with useCallback or configure the deps array correctly.`
46468
46710
  /* @__PURE__ */ React__namespace.createElement("span", { className: "sr-only" }, "More")
46469
46711
  );
46470
46712
  }
46471
- function DropdownMenu({
46472
- ...props
46473
- }) {
46474
- return /* @__PURE__ */ React__namespace.createElement(DropdownMenuPrimitive__namespace.Root, { "data-slot": "dropdown-menu", ...props });
46475
- }
46476
- function DropdownMenuTrigger({
46477
- ...props
46478
- }) {
46479
- return /* @__PURE__ */ React__namespace.createElement(
46480
- DropdownMenuPrimitive__namespace.Trigger,
46481
- {
46482
- "data-slot": "dropdown-menu-trigger",
46483
- ...props
46484
- }
46485
- );
46486
- }
46487
- function DropdownMenuContent({
46488
- className,
46489
- sideOffset = 4,
46490
- ...props
46491
- }) {
46492
- return /* @__PURE__ */ React__namespace.createElement(DropdownMenuPrimitive__namespace.Portal, null, /* @__PURE__ */ React__namespace.createElement(
46493
- DropdownMenuPrimitive__namespace.Content,
46494
- {
46495
- "data-slot": "dropdown-menu-content",
46496
- sideOffset,
46497
- className: cn(
46498
- "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-base max-h-(--radix-dropdown-menu-content-available-height) min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border p-1 shadow-md",
46499
- className
46500
- ),
46501
- ...props
46502
- }
46503
- ));
46504
- }
46505
- function DropdownMenuItem({
46506
- className,
46507
- inset,
46508
- variant = "default",
46509
- ...props
46510
- }) {
46511
- return /* @__PURE__ */ React__namespace.createElement(
46512
- DropdownMenuPrimitive__namespace.Item,
46513
- {
46514
- "data-slot": "dropdown-menu-item",
46515
- "data-inset": inset,
46516
- "data-variant": variant,
46517
- className: cn(
46518
- "focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
46519
- className
46520
- ),
46521
- ...props
46522
- }
46523
- );
46524
- }
46525
46713
  const Item = ({
46526
46714
  item,
46527
46715
  depth,
@@ -46790,7 +46978,6 @@ Please wrap them with useCallback or configure the deps array correctly.`
46790
46978
  DropdownMenuItem,
46791
46979
  {
46792
46980
  key: breadcrumb.formId,
46793
- className: "cursor-pointer text-gray-700 hover:text-blue-500",
46794
46981
  onClick: (e3) => {
46795
46982
  e3.preventDefault();
46796
46983
  goBack(breadcrumb.formId, breadcrumb.formName);
@@ -47118,7 +47305,7 @@ Please wrap them with useCallback or configure the deps array correctly.`
47118
47305
  };
47119
47306
  const SidebarHeader = ({ isLocalMode }) => {
47120
47307
  const { toggleSidebarOpen, toggleMenu } = React__namespace.useContext(SidebarContext);
47121
- return /* @__PURE__ */ React__namespace.createElement(React__namespace.Fragment, null, /* @__PURE__ */ React__namespace.createElement("div", { className: "p-2 flex-grow-0 w-full" }, !isLocalMode && /* @__PURE__ */ React__namespace.createElement(BillingWarning, null), /* @__PURE__ */ React__namespace.createElement("div", { className: "w-full flex justify-between items-center" }, /* @__PURE__ */ React__namespace.createElement("div", { className: "flex" }, /* @__PURE__ */ React__namespace.createElement(
47308
+ return /* @__PURE__ */ React__namespace.createElement(React__namespace.Fragment, null, /* @__PURE__ */ React__namespace.createElement("div", { className: "p-2 flex-grow-0 w-full" }, !isLocalMode && /* @__PURE__ */ React__namespace.createElement(BillingWarning, null), /* @__PURE__ */ React__namespace.createElement("div", { className: "w-full flex justify-between items-center" }, /* @__PURE__ */ React__namespace.createElement("div", { className: "flex overflow-hidden py-1" }, /* @__PURE__ */ React__namespace.createElement(
47122
47309
  "button",
47123
47310
  {
47124
47311
  className: "p-2 hover:bg-gray-100 transition-colors duration-150 ease-in-out rounded",
@@ -47126,8 +47313,8 @@ Please wrap them with useCallback or configure the deps array correctly.`
47126
47313
  title: "Open navigation menu",
47127
47314
  "aria-label": "Open navigation menu"
47128
47315
  },
47129
- /* @__PURE__ */ React__namespace.createElement(BiMenu, { className: "h-6 w-auto text-gray-600" })
47130
- ), /* @__PURE__ */ React__namespace.createElement(BranchButton, null), /* @__PURE__ */ React__namespace.createElement("div", { className: "px-4" }, /* @__PURE__ */ React__namespace.createElement(LocalWarning, null))), /* @__PURE__ */ React__namespace.createElement("div", { className: "flex" }, /* @__PURE__ */ React__namespace.createElement(BranchPreviewButton, null), /* @__PURE__ */ React__namespace.createElement(
47316
+ /* @__PURE__ */ React__namespace.createElement(BiMenu, { className: "h-8 w-auto text-gray-600" })
47317
+ ), /* @__PURE__ */ React__namespace.createElement(TinaIcon, { className: "self-center h-10 min-w-10 w-auto text-orange-500 mr-2" }), /* @__PURE__ */ React__namespace.createElement(BranchButton, { className: "overflow-hidden mr-2" }), /* @__PURE__ */ React__namespace.createElement(LocalWarning, { className: "px-4" })), /* @__PURE__ */ React__namespace.createElement("div", { className: "flex" }, /* @__PURE__ */ React__namespace.createElement(BranchPreviewButton, null), /* @__PURE__ */ React__namespace.createElement(
47131
47318
  "button",
47132
47319
  {
47133
47320
  type: "button",
@@ -47974,10 +48161,7 @@ Please wrap them with useCallback or configure the deps array correctly.`
47974
48161
  }
47975
48162
  ))));
47976
48163
  };
47977
- const trimPrefix = (branchName) => {
47978
- return branchName.replace(/^tina\//, "");
47979
- };
47980
- const BranchButton = () => {
48164
+ const BranchButton = ({ className = "" }) => {
47981
48165
  const [open, setOpen] = React__namespace.useState(false);
47982
48166
  const { currentBranch } = useBranchData();
47983
48167
  const cms = useCMS();
@@ -47987,22 +48171,19 @@ Please wrap them with useCallback or configure the deps array correctly.`
47987
48171
  }
47988
48172
  const isProtected = cms.api.tina.usingProtectedBranch();
47989
48173
  return /* @__PURE__ */ React__namespace.createElement(React__namespace.Fragment, null, /* @__PURE__ */ React__namespace.createElement(
47990
- "button",
48174
+ Button$1,
47991
48175
  {
48176
+ variant: "secondary",
48177
+ size: "custom",
47992
48178
  className: cn(
47993
- `pointer-events-auto px-3 py-3 flex shrink gap-1 items-center justify-between form-select text-sm shadow transition-color duration-150 ease-out rounded-lg`,
47994
- `focus:outline-none focus:shadow-outline-blue focus:border-blue-300 transition duration-150 ease-in-out `,
47995
- isProtected ? "text-white hover:text-blue-50 bg-blue-500 hover:bg-blue-400 border-0" : "text-gray-500 hover:text-blue-500 bg-white hover:bg-gray-50 border border-gray-100"
48179
+ "pointer-events-auto px-3 py-3 flex shrink gap-1 items-center justify-between",
48180
+ className
47996
48181
  ),
47997
- onClick: () => setOpen(true)
48182
+ onClick: () => setOpen(true),
48183
+ title: currentBranch
47998
48184
  },
47999
- isProtected ? /* @__PURE__ */ React__namespace.createElement(BiLockAlt, { className: "flex-shrink-0 h-4 w-auto opacity-70 text-white" }) : /* @__PURE__ */ React__namespace.createElement(
48000
- BiGitBranch,
48001
- {
48002
- className: `flex-shrink-0 h-4 w-auto opacity-70 text-zinc-400`
48003
- }
48004
- ),
48005
- /* @__PURE__ */ React__namespace.createElement("span", { className: "truncate max-w-full -mr-1" }, trimPrefix(currentBranch)),
48185
+ isProtected ? /* @__PURE__ */ React__namespace.createElement(BiLockAlt, { className: "flex-shrink-0 h-6 w-auto opacity-70" }) : /* @__PURE__ */ React__namespace.createElement(BiGitBranch, { className: "flex-shrink-0 h-6 w-auto opacity-70 text-zinc-400" }),
48186
+ /* @__PURE__ */ React__namespace.createElement("span", { className: "truncate max-w-full -mr-1" }, currentBranch),
48006
48187
  /* @__PURE__ */ React__namespace.createElement(
48007
48188
  BiChevronDown,
48008
48189
  {
@@ -48032,7 +48213,7 @@ Please wrap them with useCallback or configure the deps array correctly.`
48032
48213
  className: "p-2 text-gray-500 hover:text-blue-500 hover:bg-gray-100 transition-colors duration-150 ease-in-out rounded",
48033
48214
  ...props,
48034
48215
  onClick: () => {
48035
- window.open(previewUrl, "_blank");
48216
+ window.open("", "_blank");
48036
48217
  },
48037
48218
  title: "Preview site in new tab"
48038
48219
  },
@@ -64007,13 +64188,7 @@ mutation DeleteDocument($collection: String!, $relativePath: String!){
64007
64188
  )
64008
64189
  ) : isActive ? /* @__PURE__ */ React__namespace.createElement(AiOutlineLoading, { className: "animate-spin text-lg" }) : stepNumber
64009
64190
  ),
64010
- /* @__PURE__ */ React__namespace.createElement("div", { className: "text-center max-w-24" }, /* @__PURE__ */ React__namespace.createElement(
64011
- "div",
64012
- {
64013
- className: `text-sm font-semibold leading-tight ${isActive ? "text-blue-600" : isCompleted ? "text-green-600" : "text-gray-400"}`
64014
- },
64015
- step.name
64016
- ), /* @__PURE__ */ React__namespace.createElement("div", { className: "text-xs text-gray-400 mt-1 leading-tight" }, step.description))
64191
+ /* @__PURE__ */ React__namespace.createElement("div", { className: "text-center max-w-24" }, /* @__PURE__ */ React__namespace.createElement("div", { className: "text-sm font-semibold leading-tight" }, step.name), /* @__PURE__ */ React__namespace.createElement("div", { className: "text-xs text-gray-400 mt-1 leading-tight" }, step.description))
64017
64192
  );
64018
64193
  })), /* @__PURE__ */ React__namespace.createElement("div", { className: "flex items-center justify-between mb-4" }, /* @__PURE__ */ React__namespace.createElement("div", { className: "text-sm font-medium text-gray-700" }, "Step ", currentStep > steps.length ? steps.length : currentStep, " of", " ", steps.length), isExecuting && currentStep > 0 && /* @__PURE__ */ React__namespace.createElement("div", { className: "flex items-center gap-1 text-sm text-gray-500" }, /* @__PURE__ */ React__namespace.createElement("svg", { className: "w-4 h-4", fill: "currentColor", viewBox: "0 0 20 20" }, /* @__PURE__ */ React__namespace.createElement(
64019
64194
  "path",
@@ -64050,17 +64225,19 @@ mutation DeleteDocument($collection: String!, $relativePath: String!){
64050
64225
  if (isExecuting) {
64051
64226
  return renderProgressIndicator();
64052
64227
  } else {
64053
- return /* @__PURE__ */ React__namespace.createElement("div", { className: "max-w-sm" }, errorMessage && /* @__PURE__ */ React__namespace.createElement("div", { className: "flex items-center gap-1 text-red-700 py-2 px-3 mb-4 bg-red-50 border border-red-200 rounded" }, /* @__PURE__ */ React__namespace.createElement(BiError, { className: "w-5 h-auto text-red-400 flex-shrink-0" }), /* @__PURE__ */ React__namespace.createElement("span", { className: "text-sm" }, /* @__PURE__ */ React__namespace.createElement("b", null, "Error:"), " ", errorMessage)), /* @__PURE__ */ React__namespace.createElement("p", { className: "text-lg text-gray-700 font-bold mb-2" }, "First, let's create a copy"), /* @__PURE__ */ React__namespace.createElement("p", { className: "text-sm text-gray-700 mb-4 max-w-sm" }, "To make changes, you need to create a copy then get it approved and merged for it to go live. Learn more about", " ", /* @__PURE__ */ React__namespace.createElement(
64228
+ return /* @__PURE__ */ React__namespace.createElement("div", { className: "max-w-sm" }, errorMessage && /* @__PURE__ */ React__namespace.createElement("div", { className: "flex items-center gap-1 text-red-700 py-2 px-3 mb-4 bg-red-50 border border-red-200 rounded" }, /* @__PURE__ */ React__namespace.createElement(BiError, { className: "w-5 h-auto text-red-400 flex-shrink-0" }), /* @__PURE__ */ React__namespace.createElement("span", { className: "text-sm" }, /* @__PURE__ */ React__namespace.createElement("b", null, "Error:"), " ", errorMessage)), /* @__PURE__ */ React__namespace.createElement("p", { className: "text-lg text-gray-700 font-bold mb-2" }, "First, let's create a copy"), /* @__PURE__ */ React__namespace.createElement("p", { className: "text-sm text-gray-700 mb-4 max-w-sm" }, "To make changes, create a copy then get it approved and merged for it to go live.", " ", /* @__PURE__ */ React__namespace.createElement(
64054
64229
  "a",
64055
64230
  {
64056
- className: "underline hover:text-tina-orange",
64231
+ className: "underline text-tina-orange-dark font-medium",
64057
64232
  href: "https://tina.io/docs/tinacloud/editorial-workflow",
64058
64233
  target: "_blank"
64059
64234
  },
64060
64235
  "Editorial Workflow"
64061
- ), "."), /* @__PURE__ */ React__namespace.createElement(
64236
+ )), /* @__PURE__ */ React__namespace.createElement(
64062
64237
  PrefixedTextField,
64063
64238
  {
64239
+ name: "new-branch-name",
64240
+ label: "Branch Name",
64064
64241
  placeholder: "e.g. {{PAGE-NAME}}-updates",
64065
64242
  value: newBranchName,
64066
64243
  onChange: (e3) => {
@@ -64072,42 +64249,49 @@ mutation DeleteDocument($collection: String!, $relativePath: String!){
64072
64249
  ));
64073
64250
  }
64074
64251
  };
64075
- return /* @__PURE__ */ React__namespace.createElement(Modal, { className: "flex" }, /* @__PURE__ */ React__namespace.createElement(PopupModal, { className: "w-auto" }, /* @__PURE__ */ React__namespace.createElement(ModalHeader, { close: isExecuting ? void 0 : close2 }, /* @__PURE__ */ React__namespace.createElement("div", { className: "flex items-center justify-between w-full" }, /* @__PURE__ */ React__namespace.createElement("div", { className: "flex items-center" }, /* @__PURE__ */ React__namespace.createElement(BiGitBranch, { className: "w-6 h-auto mr-1 text-blue-500 opacity-70" }), "Create Branch"))), /* @__PURE__ */ React__namespace.createElement(ModalBody, { padded: true }, renderStateContent()), !isExecuting && /* @__PURE__ */ React__namespace.createElement(ModalActions, null, /* @__PURE__ */ React__namespace.createElement(Button$1, { style: { flexGrow: 1 }, onClick: close2 }, "Cancel"), /* @__PURE__ */ React__namespace.createElement(
64076
- Button$1,
64252
+ return /* @__PURE__ */ React__namespace.createElement(Modal, { className: "flex" }, /* @__PURE__ */ React__namespace.createElement(PopupModal, { className: "w-auto" }, /* @__PURE__ */ React__namespace.createElement(ModalHeader, { close: isExecuting ? void 0 : close2 }, /* @__PURE__ */ React__namespace.createElement("div", { className: "flex items-center justify-between w-full" }, /* @__PURE__ */ React__namespace.createElement("div", { className: "flex items-center" }, "Save changes to new branch"))), /* @__PURE__ */ React__namespace.createElement(ModalBody, { padded: true }, renderStateContent()), !isExecuting && /* @__PURE__ */ React__namespace.createElement(ModalActions, { align: "end" }, /* @__PURE__ */ React__namespace.createElement(Button$1, { variant: "secondary", className: "w-full sm:w-auto" }, "Cancel"), /* @__PURE__ */ React__namespace.createElement(
64253
+ DropdownButton,
64077
64254
  {
64078
64255
  variant: "primary",
64079
- style: { flexGrow: 2 },
64256
+ align: "start",
64257
+ className: "w-full sm:w-auto",
64080
64258
  disabled: newBranchName === "" || disabled,
64081
- onClick: executeEditorialWorkflow
64082
- },
64083
- "Continue"
64084
- ), /* @__PURE__ */ React__namespace.createElement(
64085
- OverflowMenu$1,
64086
- {
64087
- className: "-ml-2",
64088
- toolbarItems: [
64259
+ onMainAction: executeEditorialWorkflow,
64260
+ items: [
64089
64261
  {
64090
- name: "override",
64091
64262
  label: "Save to Protected Branch",
64092
- Icon: /* @__PURE__ */ React__namespace.createElement(MdOutlineSaveAlt, { size: "1rem" }),
64093
- onMouseDown: () => {
64263
+ onClick: () => {
64094
64264
  close2();
64095
64265
  safeSubmit();
64096
- }
64266
+ },
64267
+ icon: /* @__PURE__ */ React__namespace.createElement(lucideReact.TriangleAlert, { className: "w-4 h-4" })
64097
64268
  }
64098
64269
  ]
64099
- }
64270
+ },
64271
+ /* @__PURE__ */ React__namespace.createElement(
64272
+ lucideReact.GitBranchIcon,
64273
+ {
64274
+ className: "w-4 h-4 mr-1",
64275
+ style: { fill: "none" }
64276
+ }
64277
+ ),
64278
+ "Save to a new branch"
64100
64279
  ))));
64101
64280
  };
64102
- const PrefixedTextField = ({ prefix = "tina/", ...props }) => {
64103
- return /* @__PURE__ */ React__namespace.createElement("div", { className: "border border-gray-200 focus-within:border-blue-200 bg-gray-100 focus-within:bg-blue-100 rounded shadow-sm focus-within:shadow-outline overflow-hidden flex items-stretch divide-x divide-gray-200 focus-within:divide-blue-100 w-full transition-all ease-out duration-150" }, /* @__PURE__ */ React__namespace.createElement("span", { className: "pl-3 pr-2 py-2 font-medium text-base text-gray-700 opacity-50" }, prefix), /* @__PURE__ */ React__namespace.createElement(
64281
+ const PrefixedTextField = ({
64282
+ label = null,
64283
+ prefix = "tina/",
64284
+ ...props
64285
+ }) => {
64286
+ return /* @__PURE__ */ React__namespace.createElement(React__namespace.Fragment, null, label && /* @__PURE__ */ React__namespace.createElement(FieldLabel, { name: props.name }, label), /* @__PURE__ */ React__namespace.createElement("div", { className: "border border-gray-200 focus-within:border-blue-200 bg-gray-100 focus-within:bg-blue-100 rounded shadow-sm focus-within:shadow-outline overflow-hidden flex items-stretch divide-x divide-gray-200 focus-within:divide-blue-100 w-full transition-all ease-out duration-150" }, /* @__PURE__ */ React__namespace.createElement("span", { className: "pl-3 pr-2 py-2 text-base text-tina-orange-dark bg-tina-orange-light" }, prefix), /* @__PURE__ */ React__namespace.createElement(
64104
64287
  "input",
64105
64288
  {
64289
+ id: props.name,
64106
64290
  type: "text",
64107
64291
  className: "shadow-inner focus:outline-none block text-base placeholder:text-gray-300 px-3 py-2 text-gray-600 flex-1 bg-white focus:text-gray-900",
64108
64292
  ...props
64109
64293
  }
64110
- ));
64294
+ )));
64111
64295
  };
64112
64296
  const NestedForm = (props) => {
64113
64297
  const FormPortal = useFormPortal();
@@ -65443,9 +65627,9 @@ mutation DeleteDocument($collection: String!, $relativePath: String!){
65443
65627
  ai: "w-full px-0 text-base md:text-sm",
65444
65628
  aiChat: "max-h-[min(70vh,320px)] w-full max-w-[700px] overflow-y-auto px-3 py-2 text-base md:text-sm",
65445
65629
  comment: cn$2.cn("rounded-none border-none bg-transparent text-sm"),
65446
- default: "size-full px-16 pt-2 text-base sm:px-[max(24px,calc(50%-350px))]",
65447
- demo: "size-full px-16 pt-2 text-base sm:px-[max(24px,calc(50%-350px))]",
65448
- fullWidth: "size-full px-16 pt-4 pb-72 text-base sm:px-12",
65630
+ default: "size-full px-2 sm:px-4 pt-2 text-base",
65631
+ demo: "size-full px-2 sm:px-4 pt-2 text-base h-[650px]",
65632
+ fullWidth: "size-full px-2 sm:px-4 pt-4 pb-72 text-base",
65449
65633
  none: "",
65450
65634
  select: "px-3 py-2 text-base data-readonly:w-fit"
65451
65635
  }
@@ -65877,7 +66061,7 @@ flowchart TD
65877
66061
  className: "w-full p-2 border border-gray-300 rounded",
65878
66062
  onChange: filterChange
65879
66063
  }
65880
- ), /* @__PURE__ */ React.createElement(DropdownMenuSeparator, null), filteredTemplates.map((template) => /* @__PURE__ */ React.createElement(
66064
+ ), /* @__PURE__ */ React.createElement(DropdownMenuSeparator$1, null), filteredTemplates.map((template) => /* @__PURE__ */ React.createElement(
65881
66065
  DropdownMenuItem$1,
65882
66066
  {
65883
66067
  key: template.name,
@@ -119249,7 +119433,7 @@ mutation addPendingDocumentMutation(
119249
119433
  }
119250
119434
  }
119251
119435
  function ModalBuilder(modalProps) {
119252
- return /* @__PURE__ */ React.createElement(Modal, null, /* @__PURE__ */ React.createElement(ModalPopup, null, /* @__PURE__ */ React.createElement(ModalHeader, null, /* @__PURE__ */ React.createElement(TinaIcon, { className: "w-10 h-auto -ml-1 mr-1 my-1 fill-orange-500" }), modalProps.title), /* @__PURE__ */ React.createElement(ModalBody, { padded: true }, modalProps.message && (typeof modalProps.message === "string" ? /* @__PURE__ */ React.createElement("p", null, modalProps.message) : modalProps.message), modalProps.error && /* @__PURE__ */ React.createElement(ErrorLabel, null, modalProps.error), modalProps.children), /* @__PURE__ */ React.createElement(ModalActions, null, modalProps.actions.map((action) => /* @__PURE__ */ React.createElement(AsyncButton, { key: action.name, ...action })))));
119436
+ return /* @__PURE__ */ React.createElement(Modal, null, /* @__PURE__ */ React.createElement(ModalPopup, null, /* @__PURE__ */ React.createElement(ModalHeader, null, modalProps.title), /* @__PURE__ */ React.createElement(ModalBody, { padded: true }, modalProps.message && (typeof modalProps.message === "string" ? /* @__PURE__ */ React.createElement("p", null, modalProps.message) : modalProps.message), modalProps.error && /* @__PURE__ */ React.createElement(ErrorLabel, null, modalProps.error), modalProps.children), /* @__PURE__ */ React.createElement(ModalActions, null, modalProps.actions.map((action) => /* @__PURE__ */ React.createElement(AsyncButton, { key: action.name, ...action })))));
119253
119437
  }
119254
119438
  const ErrorLabel = ({ style = {}, ...props }) => /* @__PURE__ */ React.createElement("p", { style: { ...style, color: "var(--tina-color-error)" }, ...props });
119255
119439
  const AsyncButton = ({ name, primary, action }) => {
@@ -120463,7 +120647,7 @@ This will work when developing locally but NOT when deployed to production.
120463
120647
  headerClassName,
120464
120648
  children
120465
120649
  }) => {
120466
- return /* @__PURE__ */ React.createElement("div", { className: "relative left-0 w-full h-full bg-gradient-to-b from-gray-50/50 to-gray-50 overflow-y-auto transition-opacity duration-300 ease-out flex flex-col opacity-100" }, /* @__PURE__ */ React.createElement("div", { className: `py-2 pl-4 pr-4 w-full ${headerClassName}` }, /* @__PURE__ */ React.createElement(LocalWarning, null), /* @__PURE__ */ React.createElement(BillingWarning, null), /* @__PURE__ */ React.createElement("div", { className: "flex justify-between items-center" }, /* @__PURE__ */ React.createElement(BranchButton, null), /* @__PURE__ */ React.createElement(BranchPreviewButton, null))), children);
120650
+ return /* @__PURE__ */ React.createElement("div", { className: "relative left-0 w-full h-full bg-gradient-to-b from-gray-50/50 to-gray-50 overflow-y-auto transition-opacity duration-300 ease-out flex flex-col opacity-100" }, /* @__PURE__ */ React.createElement("div", { className: `py-2 pr-4 w-full ${headerClassName}` }, /* @__PURE__ */ React.createElement(LocalWarning, null), /* @__PURE__ */ React.createElement(BillingWarning, null), /* @__PURE__ */ React.createElement("div", { className: "flex items-center gap-4" }, /* @__PURE__ */ React.createElement(TinaIcon, { className: "self-center h-10 min-w-10 w-auto text-orange-500" }), /* @__PURE__ */ React.createElement(BranchButton, null), /* @__PURE__ */ React.createElement(BranchPreviewButton, null))), children);
120467
120651
  };
120468
120652
  const PageHeader = ({
120469
120653
  children
@@ -120945,7 +121129,7 @@ This will work when developing locally but NOT when deployed to production.
120945
121129
  },
120946
121130
  to: "/collections/new-folder",
120947
121131
  className: cn$1(
120948
- "icon-parent inline-flex items-center font-medium focus:outline-none focus:ring-2 focus:shadow-outline text-center rounded justify-center transition-all duration-150 ease-out whitespace-nowrap shadow text-blue-500 bg-white hover:bg-[#f1f5f9] focus:ring-white focus:ring-blue-500 w-full md:w-auto text-sm h-10 px-6 mr-4",
121132
+ "icon-parent inline-flex items-center font-medium focus:outline-none focus:ring-2 focus:shadow-outline text-center rounded justify-center transition-all duration-150 ease-out whitespace-nowrap shadow text-gray-500 hover:tina-orange-dark bg-white hover:bg-gray-50 border border-gray-100 focus:ring-white focus:ring-tina-orange-dark w-full md:w-auto text-sm h-10 px-6 mr-4",
120949
121133
  collection.templates && "opacity-50 pointer-events-none cursor-not-allowed"
120950
121134
  ),
120951
121135
  "aria-disabled": !!collection.templates,
@@ -120983,7 +121167,7 @@ This will work when developing locally but NOT when deployed to production.
120983
121167
  "new",
120984
121168
  collectionName
120985
121169
  ].join("/")}`,
120986
- className: "inline-flex items-center font-medium focus:outline-none focus:ring-2 focus:shadow-outline text-center rounded justify-center transition-all duration-150 ease-out whitespace-nowrap shadow text-white bg-blue-500 hover:bg-blue-600 w-full md:w-auto text-sm h-10 px-6"
121170
+ className: "inline-flex items-center font-medium focus:ring-2 focus:outline-none focus:ring-tina-orange-dark focus:shadow-outline text-center rounded justify-center transition-all duration-150 ease-out whitespace-nowrap shadow text-white bg-tina-orange-dark hover:bg-tina-orange w-full md:w-auto text-sm h-10 px-6"
120987
121171
  },
120988
121172
  /* @__PURE__ */ React.createElement(FaFile, { className: "mr-2" }),
120989
121173
  "Add File"
@@ -122558,6 +122742,7 @@ This will work when developing locally but NOT when deployed to production.
122558
122742
  exports2.Dismissible = Dismissible;
122559
122743
  exports2.DragHandle = DragHandle;
122560
122744
  exports2.DragIcon = DragIcon;
122745
+ exports2.DropdownButton = DropdownButton;
122561
122746
  exports2.DummyMediaStore = DummyMediaStore;
122562
122747
  exports2.DuplicateIcon = DuplicateIcon;
122563
122748
  exports2.EditIcon = EditIcon;
@@ -122686,6 +122871,7 @@ This will work when developing locally but NOT when deployed to production.
122686
122871
  exports2.TinaCloudAuthProvider = TinaCloudAuthProvider;
122687
122872
  exports2.TinaCloudAuthWall = TinaCloudAuthWall;
122688
122873
  exports2.TinaCloudProvider = TinaCloudProvider;
122874
+ exports2.TinaExtendedIcon = TinaExtendedIcon;
122689
122875
  exports2.TinaField = TinaField;
122690
122876
  exports2.TinaForm = TinaForm;
122691
122877
  exports2.TinaIcon = TinaIcon;