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.
- package/dist/index.js +321 -135
- package/dist/index.mjs +322 -136
- package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/blockquote-element.d.ts +1 -1
- package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/button.d.ts +2 -2
- package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/code-block/code-block-element.d.ts +1 -1
- package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/code-line-element.d.ts +1 -1
- package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/list-element.d.ts +2 -2
- package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/paragraph-element.d.ts +1 -1
- package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/slash-input-element.d.ts +1 -1
- package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/table/table-cell-element.d.ts +2 -2
- package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/table/table-element.d.ts +1 -1
- package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/table/table-row-element.d.ts +1 -1
- package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/plugins/ui/components.d.ts +18 -18
- package/dist/toolkit/form-builder/form-builder.d.ts +2 -1
- package/dist/toolkit/icons/TinaExtended.d.ts +4 -0
- package/dist/toolkit/icons/index.d.ts +1 -0
- package/dist/toolkit/plugin-branch-switcher/branch-button.d.ts +3 -1
- package/dist/toolkit/react-modals/modal/modal-actions.d.ts +2 -1
- package/dist/toolkit/react-sidebar/components/local-warning.d.ts +3 -1
- package/dist/toolkit/styles/dropdown-button.d.ts +75 -0
- package/dist/toolkit/styles/index.d.ts +1 -0
- package/package.json +2 -2
package/dist/index.mjs
CHANGED
|
@@ -15,7 +15,7 @@ import { isHotkey } from "is-hotkey";
|
|
|
15
15
|
import clsx$1, { clsx } from "clsx";
|
|
16
16
|
import { Slot } from "@radix-ui/react-slot";
|
|
17
17
|
import { isLangSupported, formatCodeBlock, insertEmptyCodeBlock, unwrapCodeBlock, isCodeBlockEmpty, isSelectionAtCodeBlockStart } from "@udecode/plate-code-block";
|
|
18
|
-
import { X, Search, ChevronDown, Check, AlertTriangle, BracesIcon, Plus, AlignCenter as AlignCenter$1, AlignJustify, AlignLeft as AlignLeft$1, AlignRight as AlignRight$1, PaintBucket, Quote, ChevronRight, ChevronsUpDown, FileCode, Baseline, RectangleVertical, Combine, Ungroup, MessageSquare, MessageSquarePlus, Trash, GripVertical, Edit2, Smile, ExternalLink, Heading1, Heading2, Heading3, Heading4, Heading5, Heading6, Indent, Keyboard, WrapText, Minus, MoreHorizontal, Outdent, Pilcrow, RotateCcw, RectangleHorizontal, Settings, Strikethrough, Subscript, Superscript, Table, Text as Text$2, Underline, Link2Off, Eye, SeparatorHorizontal, Moon, SunMedium, Twitter, PaintBucketIcon, CombineIcon, SquareSplitHorizontalIcon, Grid2X2Icon, Trash2Icon, ArrowUp, ArrowDown, XIcon, ArrowLeft, ArrowRight, EraserIcon, LoaderCircle, TriangleAlert, EllipsisVertical, List as List$1, ListOrdered, Grid3x3Icon, Link, Unlink } from "lucide-react";
|
|
18
|
+
import { X, Search, ChevronDown, Check, AlertTriangle, BracesIcon, Plus, AlignCenter as AlignCenter$1, AlignJustify, AlignLeft as AlignLeft$1, AlignRight as AlignRight$1, PaintBucket, Quote, ChevronRight, ChevronsUpDown, FileCode, Baseline, RectangleVertical, Combine, Ungroup, MessageSquare, MessageSquarePlus, Trash, GripVertical, Edit2, Smile, ExternalLink, Heading1, Heading2, Heading3, Heading4, Heading5, Heading6, Indent, Keyboard, WrapText, Minus, MoreHorizontal, Outdent, Pilcrow, RotateCcw, RectangleHorizontal, Settings, Strikethrough, Subscript, Superscript, Table, Text as Text$2, Underline, Link2Off, Eye, SeparatorHorizontal, Moon, SunMedium, Twitter, PaintBucketIcon, CombineIcon, SquareSplitHorizontalIcon, Grid2X2Icon, Trash2Icon, ArrowUp, ArrowDown, XIcon, ArrowLeft, ArrowRight, EraserIcon, ChevronDownIcon as ChevronDownIcon$1, LoaderCircle, TriangleAlert, EllipsisVertical, GitBranchIcon, List as List$1, ListOrdered, Grid3x3Icon, Link, Unlink } from "lucide-react";
|
|
19
19
|
import mermaid from "mermaid";
|
|
20
20
|
import { cva } from "class-variance-authority";
|
|
21
21
|
import { Command as Command$2 } from "cmdk";
|
|
@@ -100,8 +100,14 @@ const Modal = (props) => {
|
|
|
100
100
|
portalNode
|
|
101
101
|
);
|
|
102
102
|
};
|
|
103
|
-
const ModalActions = ({ children }) => {
|
|
104
|
-
return /* @__PURE__ */ React.createElement(
|
|
103
|
+
const ModalActions = ({ align = "between", children }) => {
|
|
104
|
+
return /* @__PURE__ */ React.createElement(
|
|
105
|
+
"div",
|
|
106
|
+
{
|
|
107
|
+
className: `w-full flex flex-wrap-reverse justify-${align} gap-4 items-center px-5 pb-5 rounded-b-md`
|
|
108
|
+
},
|
|
109
|
+
children
|
|
110
|
+
);
|
|
105
111
|
};
|
|
106
112
|
const ModalBody = ({ className = "", padded = false, ...props }) => /* @__PURE__ */ React__default.createElement(
|
|
107
113
|
"div",
|
|
@@ -716,12 +722,84 @@ const CircleCheck = ({ ...props }) => /* @__PURE__ */ React.createElement(
|
|
|
716
722
|
},
|
|
717
723
|
/* @__PURE__ */ React.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" })
|
|
718
724
|
);
|
|
725
|
+
const TinaExtendedIcon = ({ ...props }) => /* @__PURE__ */ React.createElement(
|
|
726
|
+
"svg",
|
|
727
|
+
{
|
|
728
|
+
viewBox: "0 0 1020 254",
|
|
729
|
+
fill: "currentColor",
|
|
730
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
731
|
+
...props
|
|
732
|
+
},
|
|
733
|
+
/* @__PURE__ */ React.createElement(
|
|
734
|
+
"path",
|
|
735
|
+
{
|
|
736
|
+
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",
|
|
737
|
+
fill: "#EC4815"
|
|
738
|
+
}
|
|
739
|
+
),
|
|
740
|
+
/* @__PURE__ */ React.createElement(
|
|
741
|
+
"path",
|
|
742
|
+
{
|
|
743
|
+
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",
|
|
744
|
+
fill: "#EC4815"
|
|
745
|
+
}
|
|
746
|
+
),
|
|
747
|
+
/* @__PURE__ */ React.createElement(
|
|
748
|
+
"path",
|
|
749
|
+
{
|
|
750
|
+
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",
|
|
751
|
+
fill: "#EC4815"
|
|
752
|
+
}
|
|
753
|
+
),
|
|
754
|
+
/* @__PURE__ */ React.createElement(
|
|
755
|
+
"path",
|
|
756
|
+
{
|
|
757
|
+
d: "M320.581 81.2H359.781V110.4H320.581V81.2ZM302.781 153.6V124H359.581V236H323.181V153.6H302.781Z",
|
|
758
|
+
fill: "#EC4815"
|
|
759
|
+
}
|
|
760
|
+
),
|
|
761
|
+
/* @__PURE__ */ React.createElement(
|
|
762
|
+
"path",
|
|
763
|
+
{
|
|
764
|
+
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",
|
|
765
|
+
fill: "#EC4815"
|
|
766
|
+
}
|
|
767
|
+
),
|
|
768
|
+
/* @__PURE__ */ React.createElement(
|
|
769
|
+
"path",
|
|
770
|
+
{
|
|
771
|
+
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",
|
|
772
|
+
fill: "#EC4815"
|
|
773
|
+
}
|
|
774
|
+
),
|
|
775
|
+
/* @__PURE__ */ React.createElement(
|
|
776
|
+
"path",
|
|
777
|
+
{
|
|
778
|
+
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",
|
|
779
|
+
fill: "#EC4815"
|
|
780
|
+
}
|
|
781
|
+
),
|
|
782
|
+
/* @__PURE__ */ React.createElement(
|
|
783
|
+
"path",
|
|
784
|
+
{
|
|
785
|
+
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",
|
|
786
|
+
fill: "#EC4815"
|
|
787
|
+
}
|
|
788
|
+
),
|
|
789
|
+
/* @__PURE__ */ React.createElement(
|
|
790
|
+
"path",
|
|
791
|
+
{
|
|
792
|
+
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",
|
|
793
|
+
fill: "#EC4815"
|
|
794
|
+
}
|
|
795
|
+
)
|
|
796
|
+
);
|
|
719
797
|
const ModalHeader = ({ children, close: close2 }) => {
|
|
720
|
-
return /* @__PURE__ */ React.createElement("div", { className: "h-14 flex items-center
|
|
798
|
+
return /* @__PURE__ */ React.createElement("div", { className: "h-14 flex items-center px-5 border-b border-gray-200 m-0" }, /* @__PURE__ */ React.createElement(TinaIcon, { className: "w-10 h-auto -ml-1 mr-1 my-1 fill-tina-orange" }), /* @__PURE__ */ React.createElement(ModalTitle, null, children), close2 && /* @__PURE__ */ React.createElement(
|
|
721
799
|
"div",
|
|
722
800
|
{
|
|
723
801
|
onClick: close2,
|
|
724
|
-
className: "flex items-center fill-gray-400 cursor-pointer transition-colors duration-100 ease-out hover:fill-gray-700"
|
|
802
|
+
className: "ml-auto flex justify-self-end items-center fill-gray-400 cursor-pointer transition-colors duration-100 ease-out hover:fill-gray-700"
|
|
725
803
|
},
|
|
726
804
|
/* @__PURE__ */ React.createElement(CloseIcon, { className: "w-6 h-auto" })
|
|
727
805
|
));
|
|
@@ -36981,7 +37059,7 @@ const DropdownMenuLabel = withVariants(
|
|
|
36981
37059
|
dropdownMenuLabelVariants,
|
|
36982
37060
|
["inset"]
|
|
36983
37061
|
);
|
|
36984
|
-
const DropdownMenuSeparator = withCn(
|
|
37062
|
+
const DropdownMenuSeparator$1 = withCn(
|
|
36985
37063
|
DropdownMenuPrimitive.Separator,
|
|
36986
37064
|
"-mx-1 my-1 h-px bg-muted"
|
|
36987
37065
|
);
|
|
@@ -38915,9 +38993,6 @@ function MdOutlineSettings(props) {
|
|
|
38915
38993
|
function MdOutlineClear(props) {
|
|
38916
38994
|
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);
|
|
38917
38995
|
}
|
|
38918
|
-
function MdOutlineSaveAlt(props) {
|
|
38919
|
-
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);
|
|
38920
|
-
}
|
|
38921
38996
|
function MdOutlineCloud(props) {
|
|
38922
38997
|
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);
|
|
38923
38998
|
}
|
|
@@ -39155,10 +39230,10 @@ const Button$1 = ({
|
|
|
39155
39230
|
}) => {
|
|
39156
39231
|
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 ";
|
|
39157
39232
|
const variantClasses = {
|
|
39158
|
-
primary: `shadow text-white bg-
|
|
39159
|
-
secondary: `shadow text-gray-500 hover:
|
|
39160
|
-
white: `shadow text-gray-500 hover:
|
|
39161
|
-
ghost: `text-gray-500 hover:
|
|
39233
|
+
primary: `shadow text-white bg-tina-orange-dark hover:bg-tina-orange focus:ring-tina-orange-dark border-0`,
|
|
39234
|
+
secondary: `shadow text-gray-500 hover:tina-orange-dark bg-gray-50 hover:bg-white border border-gray-100`,
|
|
39235
|
+
white: `shadow text-gray-500 hover:tina-orange-dark bg-white hover:bg-gray-50 border border-gray-100`,
|
|
39236
|
+
ghost: `text-gray-500 hover:tina-orange-dark hover:shadow border border-transparent border-0 hover:border hover:border-gray-200 bg-transparent`,
|
|
39162
39237
|
danger: `shadow text-white bg-red-500 hover:bg-red-600 focus:ring-red-500`,
|
|
39163
39238
|
accent: `shadow text-white bg-orange-500 hover:bg-orange-600 focus:ring-orange-500`,
|
|
39164
39239
|
custom: ""
|
|
@@ -39208,7 +39283,7 @@ const IconButton = ({
|
|
|
39208
39283
|
}) => {
|
|
39209
39284
|
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";
|
|
39210
39285
|
const variantClasses = {
|
|
39211
|
-
primary: `shadow text-white bg-
|
|
39286
|
+
primary: `shadow text-white bg-tina-orange-dark hover:bg-tina-orange focus:ring-tina-orange-dark`,
|
|
39212
39287
|
secondary: `shadow text-gray-500 hover:text-blue-500 bg-gray-50 hover:bg-white border border-gray-200`,
|
|
39213
39288
|
white: `shadow text-gray-500 hover:text-blue-500 bg-white hover:bg-gray-50 border border-gray-200`,
|
|
39214
39289
|
ghost: `text-gray-500 hover:text-blue-500 hover:shadow border border-transparent hover:border-gray-200 bg-transparent`,
|
|
@@ -39380,6 +39455,176 @@ const Message = ({
|
|
|
39380
39455
|
))
|
|
39381
39456
|
);
|
|
39382
39457
|
};
|
|
39458
|
+
function cn(...inputs) {
|
|
39459
|
+
return twMerge(clsx(inputs));
|
|
39460
|
+
}
|
|
39461
|
+
function DropdownMenu({
|
|
39462
|
+
...props
|
|
39463
|
+
}) {
|
|
39464
|
+
return /* @__PURE__ */ React.createElement(DropdownMenuPrimitive.Root, { "data-slot": "dropdown-menu", ...props });
|
|
39465
|
+
}
|
|
39466
|
+
function DropdownMenuTrigger({
|
|
39467
|
+
...props
|
|
39468
|
+
}) {
|
|
39469
|
+
return /* @__PURE__ */ React.createElement(
|
|
39470
|
+
DropdownMenuPrimitive.Trigger,
|
|
39471
|
+
{
|
|
39472
|
+
"data-slot": "dropdown-menu-trigger",
|
|
39473
|
+
...props
|
|
39474
|
+
}
|
|
39475
|
+
);
|
|
39476
|
+
}
|
|
39477
|
+
function DropdownMenuContent({
|
|
39478
|
+
className,
|
|
39479
|
+
sideOffset = 4,
|
|
39480
|
+
...props
|
|
39481
|
+
}) {
|
|
39482
|
+
return /* @__PURE__ */ React.createElement(DropdownMenuPrimitive.Portal, null, /* @__PURE__ */ React.createElement(
|
|
39483
|
+
DropdownMenuPrimitive.Content,
|
|
39484
|
+
{
|
|
39485
|
+
"data-slot": "dropdown-menu-content",
|
|
39486
|
+
sideOffset,
|
|
39487
|
+
className: cn(
|
|
39488
|
+
"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",
|
|
39489
|
+
className
|
|
39490
|
+
),
|
|
39491
|
+
...props
|
|
39492
|
+
}
|
|
39493
|
+
));
|
|
39494
|
+
}
|
|
39495
|
+
function DropdownMenuItem({
|
|
39496
|
+
className,
|
|
39497
|
+
inset,
|
|
39498
|
+
variant = "default",
|
|
39499
|
+
...props
|
|
39500
|
+
}) {
|
|
39501
|
+
return /* @__PURE__ */ React.createElement(
|
|
39502
|
+
DropdownMenuPrimitive.Item,
|
|
39503
|
+
{
|
|
39504
|
+
"data-slot": "dropdown-menu-item",
|
|
39505
|
+
"data-inset": inset,
|
|
39506
|
+
"data-variant": variant,
|
|
39507
|
+
className: cn(
|
|
39508
|
+
"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",
|
|
39509
|
+
className
|
|
39510
|
+
),
|
|
39511
|
+
...props
|
|
39512
|
+
}
|
|
39513
|
+
);
|
|
39514
|
+
}
|
|
39515
|
+
function DropdownMenuSeparator({
|
|
39516
|
+
className,
|
|
39517
|
+
...props
|
|
39518
|
+
}) {
|
|
39519
|
+
return /* @__PURE__ */ React.createElement(
|
|
39520
|
+
DropdownMenuPrimitive.Separator,
|
|
39521
|
+
{
|
|
39522
|
+
"data-slot": "dropdown-menu-separator",
|
|
39523
|
+
className: cn("bg-border -mx-1 my-1 h-px", className),
|
|
39524
|
+
...props
|
|
39525
|
+
}
|
|
39526
|
+
);
|
|
39527
|
+
}
|
|
39528
|
+
const DropdownButton = React.forwardRef(
|
|
39529
|
+
({
|
|
39530
|
+
variant = "primary",
|
|
39531
|
+
size: size2 = "medium",
|
|
39532
|
+
busy,
|
|
39533
|
+
disabled,
|
|
39534
|
+
rounded = "full",
|
|
39535
|
+
children,
|
|
39536
|
+
className = "",
|
|
39537
|
+
onMainAction,
|
|
39538
|
+
items: items2,
|
|
39539
|
+
showSplitButton = true,
|
|
39540
|
+
...props
|
|
39541
|
+
}, ref) => {
|
|
39542
|
+
const [open, setOpen] = React.useState(false);
|
|
39543
|
+
if (!onMainAction || !showSplitButton) {
|
|
39544
|
+
return /* @__PURE__ */ React.createElement(DropdownMenu, { open, onOpenChange: setOpen, modal: false }, /* @__PURE__ */ React.createElement(DropdownMenuTrigger, { asChild: true }, /* @__PURE__ */ React.createElement(
|
|
39545
|
+
Button$1,
|
|
39546
|
+
{
|
|
39547
|
+
variant,
|
|
39548
|
+
size: size2,
|
|
39549
|
+
busy,
|
|
39550
|
+
disabled,
|
|
39551
|
+
rounded,
|
|
39552
|
+
className: cn$1("gap-2", className),
|
|
39553
|
+
...props
|
|
39554
|
+
},
|
|
39555
|
+
children,
|
|
39556
|
+
/* @__PURE__ */ React.createElement(
|
|
39557
|
+
ChevronDownIcon$1,
|
|
39558
|
+
{
|
|
39559
|
+
className: cn$1(
|
|
39560
|
+
"h-4 w-4 transition-transform duration-200",
|
|
39561
|
+
open && "rotate-180"
|
|
39562
|
+
)
|
|
39563
|
+
}
|
|
39564
|
+
)
|
|
39565
|
+
)), /* @__PURE__ */ React.createElement(DropdownMenuContent, { align: "end", side: "bottom", className: "z-[100000]" }, items2.map((item, index) => /* @__PURE__ */ React.createElement(
|
|
39566
|
+
DropdownMenuItem,
|
|
39567
|
+
{
|
|
39568
|
+
key: index,
|
|
39569
|
+
onClick: item.onClick,
|
|
39570
|
+
disabled: item.disabled,
|
|
39571
|
+
variant: item.variant
|
|
39572
|
+
},
|
|
39573
|
+
item.icon && item.icon,
|
|
39574
|
+
item.label
|
|
39575
|
+
))));
|
|
39576
|
+
}
|
|
39577
|
+
return /* @__PURE__ */ React.createElement("div", { className: cn$1("inline-flex", className) }, /* @__PURE__ */ React.createElement(
|
|
39578
|
+
Button$1,
|
|
39579
|
+
{
|
|
39580
|
+
variant,
|
|
39581
|
+
size: size2,
|
|
39582
|
+
busy,
|
|
39583
|
+
disabled,
|
|
39584
|
+
rounded: "left",
|
|
39585
|
+
onClick: onMainAction,
|
|
39586
|
+
className: "border-r-0 w-full",
|
|
39587
|
+
...props
|
|
39588
|
+
},
|
|
39589
|
+
children
|
|
39590
|
+
), /* @__PURE__ */ React.createElement(DropdownMenu, { open, onOpenChange: setOpen }, /* @__PURE__ */ React.createElement(DropdownMenuTrigger, null, /* @__PURE__ */ React.createElement(
|
|
39591
|
+
Button$1,
|
|
39592
|
+
{
|
|
39593
|
+
variant,
|
|
39594
|
+
size: size2,
|
|
39595
|
+
busy,
|
|
39596
|
+
disabled,
|
|
39597
|
+
rounded: "right",
|
|
39598
|
+
className: "px-4 border-l",
|
|
39599
|
+
style: { borderColor: "#00000030" },
|
|
39600
|
+
"aria-label": "More options"
|
|
39601
|
+
},
|
|
39602
|
+
/* @__PURE__ */ React.createElement(
|
|
39603
|
+
ChevronDownIcon$1,
|
|
39604
|
+
{
|
|
39605
|
+
className: cn$1(
|
|
39606
|
+
"h-4 w-4 transition-transform duration-200 fill-none",
|
|
39607
|
+
open && "rotate-180"
|
|
39608
|
+
),
|
|
39609
|
+
style: { fill: "none" }
|
|
39610
|
+
}
|
|
39611
|
+
)
|
|
39612
|
+
)), /* @__PURE__ */ React.createElement(DropdownMenuContent, { align: "end", side: "bottom" }, items2.map((item, index) => {
|
|
39613
|
+
var _a2;
|
|
39614
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, { key: index }, /* @__PURE__ */ React.createElement(
|
|
39615
|
+
DropdownMenuItem,
|
|
39616
|
+
{
|
|
39617
|
+
onClick: item.onClick,
|
|
39618
|
+
disabled: item.disabled,
|
|
39619
|
+
variant: item.variant
|
|
39620
|
+
},
|
|
39621
|
+
item.icon && item.icon,
|
|
39622
|
+
item.label
|
|
39623
|
+
), item.variant === "destructive" && index < items2.length - 1 && ((_a2 = items2[index + 1]) == null ? void 0 : _a2.variant) !== "destructive" && /* @__PURE__ */ React.createElement(DropdownMenuSeparator, null));
|
|
39624
|
+
}))));
|
|
39625
|
+
}
|
|
39626
|
+
);
|
|
39627
|
+
DropdownButton.displayName = "DropdownButton";
|
|
39383
39628
|
function useCMS() {
|
|
39384
39629
|
return useCMS$1();
|
|
39385
39630
|
}
|
|
@@ -43253,7 +43498,7 @@ let Alerts$1 = class Alerts {
|
|
|
43253
43498
|
...eventsToAlerts
|
|
43254
43499
|
};
|
|
43255
43500
|
}
|
|
43256
|
-
add(level, message, timeout =
|
|
43501
|
+
add(level, message, timeout = 8e3) {
|
|
43257
43502
|
const alert = {
|
|
43258
43503
|
level,
|
|
43259
43504
|
message,
|
|
@@ -44304,9 +44549,6 @@ const CopyField = ({ label, description, value }) => {
|
|
|
44304
44549
|
)
|
|
44305
44550
|
), description && /* @__PURE__ */ React__default.createElement("p", { className: "mt-2 text-sm text-gray-500" }, description));
|
|
44306
44551
|
};
|
|
44307
|
-
function cn(...inputs) {
|
|
44308
|
-
return twMerge(clsx(inputs));
|
|
44309
|
-
}
|
|
44310
44552
|
const checkerboardStyle = {
|
|
44311
44553
|
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%)",
|
|
44312
44554
|
backgroundSize: "12px 12px",
|
|
@@ -45239,14 +45481,14 @@ const Callout = ({
|
|
|
45239
45481
|
children
|
|
45240
45482
|
);
|
|
45241
45483
|
};
|
|
45242
|
-
const LocalWarning = () => {
|
|
45484
|
+
const LocalWarning = ({ className = "" }) => {
|
|
45243
45485
|
var _a2, _b;
|
|
45244
45486
|
const cms = useCMS$1();
|
|
45245
45487
|
const isLocalMode = (_b = (_a2 = cms.api) == null ? void 0 : _a2.tina) == null ? void 0 : _b.isLocalMode;
|
|
45246
45488
|
if (!isLocalMode) {
|
|
45247
45489
|
return null;
|
|
45248
45490
|
}
|
|
45249
|
-
return /* @__PURE__ */ React.createElement(Callout, { calloutStyle: "warning", className: "w-fit" }, /* @__PURE__ */ React.createElement("a", { href: "https://tina.io/docs/r/what-is-tinacloud/", target: "_blank" }, "You are in local mode"));
|
|
45491
|
+
return /* @__PURE__ */ React.createElement(Callout, { calloutStyle: "warning", className: cn("w-fit", className) }, /* @__PURE__ */ React.createElement("a", { href: "https://tina.io/docs/r/what-is-tinacloud/", target: "_blank" }, "You are in local mode"));
|
|
45250
45492
|
};
|
|
45251
45493
|
const BillingWarning = () => {
|
|
45252
45494
|
var _a2;
|
|
@@ -45987,7 +46229,7 @@ function formatDistanceToNow(dirtyDate, options) {
|
|
|
45987
46229
|
requiredArgs(1, arguments);
|
|
45988
46230
|
return formatDistance2(dirtyDate, Date.now(), options);
|
|
45989
46231
|
}
|
|
45990
|
-
const version$1 = "2.9.
|
|
46232
|
+
const version$1 = "2.9.3";
|
|
45991
46233
|
const VersionInfo = () => {
|
|
45992
46234
|
var _a2, _b, _c, _d, _e, _f;
|
|
45993
46235
|
const cms = useCMS();
|
|
@@ -46223,7 +46465,7 @@ const Nav = ({
|
|
|
46223
46465
|
toggleMenu();
|
|
46224
46466
|
}
|
|
46225
46467
|
},
|
|
46226
|
-
/* @__PURE__ */ React.createElement(BiMenu, { className: "h-
|
|
46468
|
+
/* @__PURE__ */ React.createElement(BiMenu, { className: "h-8 w-auto text-gray-600" })
|
|
46227
46469
|
)), /* @__PURE__ */ React.createElement(
|
|
46228
46470
|
"div",
|
|
46229
46471
|
{
|
|
@@ -46244,8 +46486,8 @@ const Nav = ({
|
|
|
46244
46486
|
toggleMenu();
|
|
46245
46487
|
}
|
|
46246
46488
|
},
|
|
46247
|
-
/* @__PURE__ */ React.createElement(BiMenu, { className: "h-
|
|
46248
|
-
), /* @__PURE__ */ React.createElement("span", { className: "text-left inline-flex items-center text-xl tracking-wide text-gray-800/80 flex-1 gap-1" }, /* @__PURE__ */ React.createElement(
|
|
46489
|
+
/* @__PURE__ */ React.createElement(BiMenu, { className: "h-8 w-auto text-gray-600" })
|
|
46490
|
+
), /* @__PURE__ */ React.createElement("span", { className: "text-left inline-flex items-center text-xl tracking-wide text-gray-800/80 flex-1 gap-1" }, /* @__PURE__ */ React.createElement(TinaExtendedIcon, { className: "h-8 w-auto fill-orange-500" }))),
|
|
46249
46491
|
children,
|
|
46250
46492
|
/* @__PURE__ */ React.createElement("div", { className: "flex flex-col px-6 flex-1 overflow-auto" }, showCollections && /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.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.createElement("span", null, "Collections"), isLocalMode && /* @__PURE__ */ React.createElement("span", { className: "flex items-center" }, /* @__PURE__ */ React.createElement(
|
|
46251
46493
|
"a",
|
|
@@ -46495,60 +46737,6 @@ function BreadcrumbEllipsis({
|
|
|
46495
46737
|
/* @__PURE__ */ React.createElement("span", { className: "sr-only" }, "More")
|
|
46496
46738
|
);
|
|
46497
46739
|
}
|
|
46498
|
-
function DropdownMenu({
|
|
46499
|
-
...props
|
|
46500
|
-
}) {
|
|
46501
|
-
return /* @__PURE__ */ React.createElement(DropdownMenuPrimitive.Root, { "data-slot": "dropdown-menu", ...props });
|
|
46502
|
-
}
|
|
46503
|
-
function DropdownMenuTrigger({
|
|
46504
|
-
...props
|
|
46505
|
-
}) {
|
|
46506
|
-
return /* @__PURE__ */ React.createElement(
|
|
46507
|
-
DropdownMenuPrimitive.Trigger,
|
|
46508
|
-
{
|
|
46509
|
-
"data-slot": "dropdown-menu-trigger",
|
|
46510
|
-
...props
|
|
46511
|
-
}
|
|
46512
|
-
);
|
|
46513
|
-
}
|
|
46514
|
-
function DropdownMenuContent({
|
|
46515
|
-
className,
|
|
46516
|
-
sideOffset = 4,
|
|
46517
|
-
...props
|
|
46518
|
-
}) {
|
|
46519
|
-
return /* @__PURE__ */ React.createElement(DropdownMenuPrimitive.Portal, null, /* @__PURE__ */ React.createElement(
|
|
46520
|
-
DropdownMenuPrimitive.Content,
|
|
46521
|
-
{
|
|
46522
|
-
"data-slot": "dropdown-menu-content",
|
|
46523
|
-
sideOffset,
|
|
46524
|
-
className: cn(
|
|
46525
|
-
"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",
|
|
46526
|
-
className
|
|
46527
|
-
),
|
|
46528
|
-
...props
|
|
46529
|
-
}
|
|
46530
|
-
));
|
|
46531
|
-
}
|
|
46532
|
-
function DropdownMenuItem({
|
|
46533
|
-
className,
|
|
46534
|
-
inset,
|
|
46535
|
-
variant = "default",
|
|
46536
|
-
...props
|
|
46537
|
-
}) {
|
|
46538
|
-
return /* @__PURE__ */ React.createElement(
|
|
46539
|
-
DropdownMenuPrimitive.Item,
|
|
46540
|
-
{
|
|
46541
|
-
"data-slot": "dropdown-menu-item",
|
|
46542
|
-
"data-inset": inset,
|
|
46543
|
-
"data-variant": variant,
|
|
46544
|
-
className: cn(
|
|
46545
|
-
"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",
|
|
46546
|
-
className
|
|
46547
|
-
),
|
|
46548
|
-
...props
|
|
46549
|
-
}
|
|
46550
|
-
);
|
|
46551
|
-
}
|
|
46552
46740
|
const Item = ({
|
|
46553
46741
|
item,
|
|
46554
46742
|
depth,
|
|
@@ -46817,7 +47005,6 @@ const FormBreadcrumbs = ({
|
|
|
46817
47005
|
DropdownMenuItem,
|
|
46818
47006
|
{
|
|
46819
47007
|
key: breadcrumb.formId,
|
|
46820
|
-
className: "cursor-pointer text-gray-700 hover:text-blue-500",
|
|
46821
47008
|
onClick: (e3) => {
|
|
46822
47009
|
e3.preventDefault();
|
|
46823
47010
|
goBack(breadcrumb.formId, breadcrumb.formName);
|
|
@@ -47145,7 +47332,7 @@ const updateBodyDisplacement = ({
|
|
|
47145
47332
|
};
|
|
47146
47333
|
const SidebarHeader = ({ isLocalMode }) => {
|
|
47147
47334
|
const { toggleSidebarOpen, toggleMenu } = React.useContext(SidebarContext);
|
|
47148
|
-
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement("div", { className: "p-2 flex-grow-0 w-full" }, !isLocalMode && /* @__PURE__ */ React.createElement(BillingWarning, null), /* @__PURE__ */ React.createElement("div", { className: "w-full flex justify-between items-center" }, /* @__PURE__ */ React.createElement("div", { className: "flex" }, /* @__PURE__ */ React.createElement(
|
|
47335
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement("div", { className: "p-2 flex-grow-0 w-full" }, !isLocalMode && /* @__PURE__ */ React.createElement(BillingWarning, null), /* @__PURE__ */ React.createElement("div", { className: "w-full flex justify-between items-center" }, /* @__PURE__ */ React.createElement("div", { className: "flex overflow-hidden py-1" }, /* @__PURE__ */ React.createElement(
|
|
47149
47336
|
"button",
|
|
47150
47337
|
{
|
|
47151
47338
|
className: "p-2 hover:bg-gray-100 transition-colors duration-150 ease-in-out rounded",
|
|
@@ -47153,8 +47340,8 @@ const SidebarHeader = ({ isLocalMode }) => {
|
|
|
47153
47340
|
title: "Open navigation menu",
|
|
47154
47341
|
"aria-label": "Open navigation menu"
|
|
47155
47342
|
},
|
|
47156
|
-
/* @__PURE__ */ React.createElement(BiMenu, { className: "h-
|
|
47157
|
-
), /* @__PURE__ */ React.createElement(
|
|
47343
|
+
/* @__PURE__ */ React.createElement(BiMenu, { className: "h-8 w-auto text-gray-600" })
|
|
47344
|
+
), /* @__PURE__ */ React.createElement(TinaIcon, { className: "self-center h-10 min-w-10 w-auto text-orange-500 mr-2" }), /* @__PURE__ */ React.createElement(BranchButton, { className: "overflow-hidden mr-2" }), /* @__PURE__ */ React.createElement(LocalWarning, { className: "px-4" })), /* @__PURE__ */ React.createElement("div", { className: "flex" }, /* @__PURE__ */ React.createElement(BranchPreviewButton, null), /* @__PURE__ */ React.createElement(
|
|
47158
47345
|
"button",
|
|
47159
47346
|
{
|
|
47160
47347
|
type: "button",
|
|
@@ -48001,10 +48188,7 @@ const BranchModal = ({ close: close2 }) => {
|
|
|
48001
48188
|
}
|
|
48002
48189
|
))));
|
|
48003
48190
|
};
|
|
48004
|
-
const
|
|
48005
|
-
return branchName.replace(/^tina\//, "");
|
|
48006
|
-
};
|
|
48007
|
-
const BranchButton = () => {
|
|
48191
|
+
const BranchButton = ({ className = "" }) => {
|
|
48008
48192
|
const [open, setOpen] = React.useState(false);
|
|
48009
48193
|
const { currentBranch } = useBranchData();
|
|
48010
48194
|
const cms = useCMS();
|
|
@@ -48014,22 +48198,19 @@ const BranchButton = () => {
|
|
|
48014
48198
|
}
|
|
48015
48199
|
const isProtected = cms.api.tina.usingProtectedBranch();
|
|
48016
48200
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
48017
|
-
|
|
48201
|
+
Button$1,
|
|
48018
48202
|
{
|
|
48203
|
+
variant: "secondary",
|
|
48204
|
+
size: "custom",
|
|
48019
48205
|
className: cn(
|
|
48020
|
-
|
|
48021
|
-
|
|
48022
|
-
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"
|
|
48206
|
+
"pointer-events-auto px-3 py-3 flex shrink gap-1 items-center justify-between",
|
|
48207
|
+
className
|
|
48023
48208
|
),
|
|
48024
|
-
onClick: () => setOpen(true)
|
|
48209
|
+
onClick: () => setOpen(true),
|
|
48210
|
+
title: currentBranch
|
|
48025
48211
|
},
|
|
48026
|
-
isProtected ? /* @__PURE__ */ React.createElement(BiLockAlt, { className: "flex-shrink-0 h-
|
|
48027
|
-
|
|
48028
|
-
{
|
|
48029
|
-
className: `flex-shrink-0 h-4 w-auto opacity-70 text-zinc-400`
|
|
48030
|
-
}
|
|
48031
|
-
),
|
|
48032
|
-
/* @__PURE__ */ React.createElement("span", { className: "truncate max-w-full -mr-1" }, trimPrefix(currentBranch)),
|
|
48212
|
+
isProtected ? /* @__PURE__ */ React.createElement(BiLockAlt, { className: "flex-shrink-0 h-6 w-auto opacity-70" }) : /* @__PURE__ */ React.createElement(BiGitBranch, { className: "flex-shrink-0 h-6 w-auto opacity-70 text-zinc-400" }),
|
|
48213
|
+
/* @__PURE__ */ React.createElement("span", { className: "truncate max-w-full -mr-1" }, currentBranch),
|
|
48033
48214
|
/* @__PURE__ */ React.createElement(
|
|
48034
48215
|
BiChevronDown,
|
|
48035
48216
|
{
|
|
@@ -48059,7 +48240,7 @@ const BranchPreviewButton = (props) => {
|
|
|
48059
48240
|
className: "p-2 text-gray-500 hover:text-blue-500 hover:bg-gray-100 transition-colors duration-150 ease-in-out rounded",
|
|
48060
48241
|
...props,
|
|
48061
48242
|
onClick: () => {
|
|
48062
|
-
window.open(
|
|
48243
|
+
window.open("", "_blank");
|
|
48063
48244
|
},
|
|
48064
48245
|
title: "Preview site in new tab"
|
|
48065
48246
|
},
|
|
@@ -64034,13 +64215,7 @@ const CreateBranchModal = ({
|
|
|
64034
64215
|
)
|
|
64035
64216
|
) : isActive ? /* @__PURE__ */ React.createElement(AiOutlineLoading, { className: "animate-spin text-lg" }) : stepNumber
|
|
64036
64217
|
),
|
|
64037
|
-
/* @__PURE__ */ React.createElement("div", { className: "text-center max-w-24" }, /* @__PURE__ */ React.createElement(
|
|
64038
|
-
"div",
|
|
64039
|
-
{
|
|
64040
|
-
className: `text-sm font-semibold leading-tight ${isActive ? "text-blue-600" : isCompleted ? "text-green-600" : "text-gray-400"}`
|
|
64041
|
-
},
|
|
64042
|
-
step.name
|
|
64043
|
-
), /* @__PURE__ */ React.createElement("div", { className: "text-xs text-gray-400 mt-1 leading-tight" }, step.description))
|
|
64218
|
+
/* @__PURE__ */ React.createElement("div", { className: "text-center max-w-24" }, /* @__PURE__ */ React.createElement("div", { className: "text-sm font-semibold leading-tight" }, step.name), /* @__PURE__ */ React.createElement("div", { className: "text-xs text-gray-400 mt-1 leading-tight" }, step.description))
|
|
64044
64219
|
);
|
|
64045
64220
|
})), /* @__PURE__ */ React.createElement("div", { className: "flex items-center justify-between mb-4" }, /* @__PURE__ */ React.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.createElement("div", { className: "flex items-center gap-1 text-sm text-gray-500" }, /* @__PURE__ */ React.createElement("svg", { className: "w-4 h-4", fill: "currentColor", viewBox: "0 0 20 20" }, /* @__PURE__ */ React.createElement(
|
|
64046
64221
|
"path",
|
|
@@ -64077,17 +64252,19 @@ const CreateBranchModal = ({
|
|
|
64077
64252
|
if (isExecuting) {
|
|
64078
64253
|
return renderProgressIndicator();
|
|
64079
64254
|
} else {
|
|
64080
|
-
return /* @__PURE__ */ React.createElement("div", { className: "max-w-sm" }, errorMessage && /* @__PURE__ */ React.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.createElement(BiError, { className: "w-5 h-auto text-red-400 flex-shrink-0" }), /* @__PURE__ */ React.createElement("span", { className: "text-sm" }, /* @__PURE__ */ React.createElement("b", null, "Error:"), " ", errorMessage)), /* @__PURE__ */ React.createElement("p", { className: "text-lg text-gray-700 font-bold mb-2" }, "First, let's create a copy"), /* @__PURE__ */ React.createElement("p", { className: "text-sm text-gray-700 mb-4 max-w-sm" }, "To make changes,
|
|
64255
|
+
return /* @__PURE__ */ React.createElement("div", { className: "max-w-sm" }, errorMessage && /* @__PURE__ */ React.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.createElement(BiError, { className: "w-5 h-auto text-red-400 flex-shrink-0" }), /* @__PURE__ */ React.createElement("span", { className: "text-sm" }, /* @__PURE__ */ React.createElement("b", null, "Error:"), " ", errorMessage)), /* @__PURE__ */ React.createElement("p", { className: "text-lg text-gray-700 font-bold mb-2" }, "First, let's create a copy"), /* @__PURE__ */ React.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.createElement(
|
|
64081
64256
|
"a",
|
|
64082
64257
|
{
|
|
64083
|
-
className: "underline
|
|
64258
|
+
className: "underline text-tina-orange-dark font-medium",
|
|
64084
64259
|
href: "https://tina.io/docs/tinacloud/editorial-workflow",
|
|
64085
64260
|
target: "_blank"
|
|
64086
64261
|
},
|
|
64087
64262
|
"Editorial Workflow"
|
|
64088
|
-
)
|
|
64263
|
+
)), /* @__PURE__ */ React.createElement(
|
|
64089
64264
|
PrefixedTextField,
|
|
64090
64265
|
{
|
|
64266
|
+
name: "new-branch-name",
|
|
64267
|
+
label: "Branch Name",
|
|
64091
64268
|
placeholder: "e.g. {{PAGE-NAME}}-updates",
|
|
64092
64269
|
value: newBranchName,
|
|
64093
64270
|
onChange: (e3) => {
|
|
@@ -64099,42 +64276,49 @@ const CreateBranchModal = ({
|
|
|
64099
64276
|
));
|
|
64100
64277
|
}
|
|
64101
64278
|
};
|
|
64102
|
-
return /* @__PURE__ */ React.createElement(Modal, { className: "flex" }, /* @__PURE__ */ React.createElement(PopupModal, { className: "w-auto" }, /* @__PURE__ */ React.createElement(ModalHeader, { close: isExecuting ? void 0 : close2 }, /* @__PURE__ */ React.createElement("div", { className: "flex items-center justify-between w-full" }, /* @__PURE__ */ React.createElement("div", { className: "flex items-center" },
|
|
64103
|
-
|
|
64279
|
+
return /* @__PURE__ */ React.createElement(Modal, { className: "flex" }, /* @__PURE__ */ React.createElement(PopupModal, { className: "w-auto" }, /* @__PURE__ */ React.createElement(ModalHeader, { close: isExecuting ? void 0 : close2 }, /* @__PURE__ */ React.createElement("div", { className: "flex items-center justify-between w-full" }, /* @__PURE__ */ React.createElement("div", { className: "flex items-center" }, "Save changes to new branch"))), /* @__PURE__ */ React.createElement(ModalBody, { padded: true }, renderStateContent()), !isExecuting && /* @__PURE__ */ React.createElement(ModalActions, { align: "end" }, /* @__PURE__ */ React.createElement(Button$1, { variant: "secondary", className: "w-full sm:w-auto" }, "Cancel"), /* @__PURE__ */ React.createElement(
|
|
64280
|
+
DropdownButton,
|
|
64104
64281
|
{
|
|
64105
64282
|
variant: "primary",
|
|
64106
|
-
|
|
64283
|
+
align: "start",
|
|
64284
|
+
className: "w-full sm:w-auto",
|
|
64107
64285
|
disabled: newBranchName === "" || disabled,
|
|
64108
|
-
|
|
64109
|
-
|
|
64110
|
-
"Continue"
|
|
64111
|
-
), /* @__PURE__ */ React.createElement(
|
|
64112
|
-
OverflowMenu$1,
|
|
64113
|
-
{
|
|
64114
|
-
className: "-ml-2",
|
|
64115
|
-
toolbarItems: [
|
|
64286
|
+
onMainAction: executeEditorialWorkflow,
|
|
64287
|
+
items: [
|
|
64116
64288
|
{
|
|
64117
|
-
name: "override",
|
|
64118
64289
|
label: "Save to Protected Branch",
|
|
64119
|
-
|
|
64120
|
-
onMouseDown: () => {
|
|
64290
|
+
onClick: () => {
|
|
64121
64291
|
close2();
|
|
64122
64292
|
safeSubmit();
|
|
64123
|
-
}
|
|
64293
|
+
},
|
|
64294
|
+
icon: /* @__PURE__ */ React.createElement(TriangleAlert, { className: "w-4 h-4" })
|
|
64124
64295
|
}
|
|
64125
64296
|
]
|
|
64126
|
-
}
|
|
64297
|
+
},
|
|
64298
|
+
/* @__PURE__ */ React.createElement(
|
|
64299
|
+
GitBranchIcon,
|
|
64300
|
+
{
|
|
64301
|
+
className: "w-4 h-4 mr-1",
|
|
64302
|
+
style: { fill: "none" }
|
|
64303
|
+
}
|
|
64304
|
+
),
|
|
64305
|
+
"Save to a new branch"
|
|
64127
64306
|
))));
|
|
64128
64307
|
};
|
|
64129
|
-
const PrefixedTextField = ({
|
|
64130
|
-
|
|
64308
|
+
const PrefixedTextField = ({
|
|
64309
|
+
label = null,
|
|
64310
|
+
prefix = "tina/",
|
|
64311
|
+
...props
|
|
64312
|
+
}) => {
|
|
64313
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, label && /* @__PURE__ */ React.createElement(FieldLabel, { name: props.name }, label), /* @__PURE__ */ React.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.createElement("span", { className: "pl-3 pr-2 py-2 text-base text-tina-orange-dark bg-tina-orange-light" }, prefix), /* @__PURE__ */ React.createElement(
|
|
64131
64314
|
"input",
|
|
64132
64315
|
{
|
|
64316
|
+
id: props.name,
|
|
64133
64317
|
type: "text",
|
|
64134
64318
|
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",
|
|
64135
64319
|
...props
|
|
64136
64320
|
}
|
|
64137
|
-
));
|
|
64321
|
+
)));
|
|
64138
64322
|
};
|
|
64139
64323
|
const NestedForm = (props) => {
|
|
64140
64324
|
const FormPortal = useFormPortal();
|
|
@@ -65470,9 +65654,9 @@ const editorVariants = cva(
|
|
|
65470
65654
|
ai: "w-full px-0 text-base md:text-sm",
|
|
65471
65655
|
aiChat: "max-h-[min(70vh,320px)] w-full max-w-[700px] overflow-y-auto px-3 py-2 text-base md:text-sm",
|
|
65472
65656
|
comment: cn$2("rounded-none border-none bg-transparent text-sm"),
|
|
65473
|
-
default: "size-full px-
|
|
65474
|
-
demo: "size-full px-
|
|
65475
|
-
fullWidth: "size-full px-
|
|
65657
|
+
default: "size-full px-2 sm:px-4 pt-2 text-base",
|
|
65658
|
+
demo: "size-full px-2 sm:px-4 pt-2 text-base h-[650px]",
|
|
65659
|
+
fullWidth: "size-full px-2 sm:px-4 pt-4 pb-72 text-base",
|
|
65476
65660
|
none: "",
|
|
65477
65661
|
select: "px-3 py-2 text-base data-readonly:w-fit"
|
|
65478
65662
|
}
|
|
@@ -65904,7 +66088,7 @@ const EmbedButton = ({ editor, templates }) => {
|
|
|
65904
66088
|
className: "w-full p-2 border border-gray-300 rounded",
|
|
65905
66089
|
onChange: filterChange
|
|
65906
66090
|
}
|
|
65907
|
-
), /* @__PURE__ */ React__default.createElement(DropdownMenuSeparator, null), filteredTemplates.map((template) => /* @__PURE__ */ React__default.createElement(
|
|
66091
|
+
), /* @__PURE__ */ React__default.createElement(DropdownMenuSeparator$1, null), filteredTemplates.map((template) => /* @__PURE__ */ React__default.createElement(
|
|
65908
66092
|
DropdownMenuItem$1,
|
|
65909
66093
|
{
|
|
65910
66094
|
key: template.name,
|
|
@@ -119276,7 +119460,7 @@ class LocalSearchClient {
|
|
|
119276
119460
|
}
|
|
119277
119461
|
}
|
|
119278
119462
|
function ModalBuilder(modalProps) {
|
|
119279
|
-
return /* @__PURE__ */ React__default.createElement(Modal, null, /* @__PURE__ */ React__default.createElement(ModalPopup, null, /* @__PURE__ */ React__default.createElement(ModalHeader, null,
|
|
119463
|
+
return /* @__PURE__ */ React__default.createElement(Modal, null, /* @__PURE__ */ React__default.createElement(ModalPopup, null, /* @__PURE__ */ React__default.createElement(ModalHeader, null, modalProps.title), /* @__PURE__ */ React__default.createElement(ModalBody, { padded: true }, modalProps.message && (typeof modalProps.message === "string" ? /* @__PURE__ */ React__default.createElement("p", null, modalProps.message) : modalProps.message), modalProps.error && /* @__PURE__ */ React__default.createElement(ErrorLabel, null, modalProps.error), modalProps.children), /* @__PURE__ */ React__default.createElement(ModalActions, null, modalProps.actions.map((action) => /* @__PURE__ */ React__default.createElement(AsyncButton, { key: action.name, ...action })))));
|
|
119280
119464
|
}
|
|
119281
119465
|
const ErrorLabel = ({ style = {}, ...props }) => /* @__PURE__ */ React__default.createElement("p", { style: { ...style, color: "var(--tina-color-error)" }, ...props });
|
|
119282
119466
|
const AsyncButton = ({ name, primary, action }) => {
|
|
@@ -120490,7 +120674,7 @@ const PageWrapper = ({
|
|
|
120490
120674
|
headerClassName,
|
|
120491
120675
|
children
|
|
120492
120676
|
}) => {
|
|
120493
|
-
return /* @__PURE__ */ React__default.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__default.createElement("div", { className: `py-2
|
|
120677
|
+
return /* @__PURE__ */ React__default.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__default.createElement("div", { className: `py-2 pr-4 w-full ${headerClassName}` }, /* @__PURE__ */ React__default.createElement(LocalWarning, null), /* @__PURE__ */ React__default.createElement(BillingWarning, null), /* @__PURE__ */ React__default.createElement("div", { className: "flex items-center gap-4" }, /* @__PURE__ */ React__default.createElement(TinaIcon, { className: "self-center h-10 min-w-10 w-auto text-orange-500" }), /* @__PURE__ */ React__default.createElement(BranchButton, null), /* @__PURE__ */ React__default.createElement(BranchPreviewButton, null))), children);
|
|
120494
120678
|
};
|
|
120495
120679
|
const PageHeader = ({
|
|
120496
120680
|
children
|
|
@@ -120972,7 +121156,7 @@ const CollectionListPage = () => {
|
|
|
120972
121156
|
},
|
|
120973
121157
|
to: "/collections/new-folder",
|
|
120974
121158
|
className: cn$1(
|
|
120975
|
-
"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-
|
|
121159
|
+
"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",
|
|
120976
121160
|
collection.templates && "opacity-50 pointer-events-none cursor-not-allowed"
|
|
120977
121161
|
),
|
|
120978
121162
|
"aria-disabled": !!collection.templates,
|
|
@@ -121010,7 +121194,7 @@ const CollectionListPage = () => {
|
|
|
121010
121194
|
"new",
|
|
121011
121195
|
collectionName
|
|
121012
121196
|
].join("/")}`,
|
|
121013
|
-
className: "inline-flex items-center font-medium focus:outline-none focus:ring-
|
|
121197
|
+
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"
|
|
121014
121198
|
},
|
|
121015
121199
|
/* @__PURE__ */ React__default.createElement(FaFile, { className: "mr-2" }),
|
|
121016
121200
|
"Add File"
|
|
@@ -122578,6 +122762,7 @@ export {
|
|
|
122578
122762
|
Dismissible,
|
|
122579
122763
|
DragHandle,
|
|
122580
122764
|
DragIcon,
|
|
122765
|
+
DropdownButton,
|
|
122581
122766
|
DummyMediaStore,
|
|
122582
122767
|
DuplicateIcon,
|
|
122583
122768
|
EditIcon,
|
|
@@ -122707,6 +122892,7 @@ export {
|
|
|
122707
122892
|
TinaCloudAuthProvider,
|
|
122708
122893
|
TinaCloudAuthWall,
|
|
122709
122894
|
TinaCloudProvider,
|
|
122895
|
+
TinaExtendedIcon,
|
|
122710
122896
|
TinaField,
|
|
122711
122897
|
TinaForm,
|
|
122712
122898
|
TinaIcon,
|