@daisychainapp/maily-to-core 0.2.10 → 0.2.12
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/extensions/index.cjs +460 -614
- package/dist/extensions/index.cjs.map +1 -1
- package/dist/extensions/index.mjs +403 -557
- package/dist/extensions/index.mjs.map +1 -1
- package/dist/index.cjs +92 -182
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +121 -211
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -2102,6 +2102,51 @@ function HTMLBubbleMenu(props) {
|
|
|
2102
2102
|
);
|
|
2103
2103
|
}
|
|
2104
2104
|
|
|
2105
|
+
// src/editor/utils/aspect-ratio.ts
|
|
2106
|
+
function getAspectRatio(width, height) {
|
|
2107
|
+
return width / height;
|
|
2108
|
+
}
|
|
2109
|
+
function getNewHeight(width, aspectRatio) {
|
|
2110
|
+
if (width <= 0 || aspectRatio <= 0) {
|
|
2111
|
+
return 0;
|
|
2112
|
+
}
|
|
2113
|
+
return width / aspectRatio;
|
|
2114
|
+
}
|
|
2115
|
+
function getNewWidth(height, aspectRatio) {
|
|
2116
|
+
return height * aspectRatio;
|
|
2117
|
+
}
|
|
2118
|
+
|
|
2119
|
+
// src/editor/utils/border-radius.ts
|
|
2120
|
+
var borderRadius = [
|
|
2121
|
+
{
|
|
2122
|
+
name: "Sharp",
|
|
2123
|
+
value: 0
|
|
2124
|
+
},
|
|
2125
|
+
{
|
|
2126
|
+
name: "Smooth",
|
|
2127
|
+
value: 8
|
|
2128
|
+
},
|
|
2129
|
+
{
|
|
2130
|
+
name: "Smoother",
|
|
2131
|
+
value: 16
|
|
2132
|
+
},
|
|
2133
|
+
{
|
|
2134
|
+
name: "Rounded",
|
|
2135
|
+
value: 24
|
|
2136
|
+
},
|
|
2137
|
+
{
|
|
2138
|
+
name: "Circle",
|
|
2139
|
+
value: 9999
|
|
2140
|
+
}
|
|
2141
|
+
];
|
|
2142
|
+
|
|
2143
|
+
// src/editor/components/image-menu/image-bubble-menu.tsx
|
|
2144
|
+
var import_react32 = require("@tiptap/react");
|
|
2145
|
+
var import_lucide_react23 = require("lucide-react");
|
|
2146
|
+
|
|
2147
|
+
// src/editor/components/alignment-switch.tsx
|
|
2148
|
+
var import_lucide_react11 = require("lucide-react");
|
|
2149
|
+
|
|
2105
2150
|
// src/editor/nodes/logo/logo.ts
|
|
2106
2151
|
var import_extension_image = __toESM(require("@tiptap/extension-image"), 1);
|
|
2107
2152
|
var import_react23 = require("@tiptap/react");
|
|
@@ -2564,24 +2609,10 @@ var useEvent = (handler) => {
|
|
|
2564
2609
|
}, []);
|
|
2565
2610
|
};
|
|
2566
2611
|
|
|
2567
|
-
// src/editor/utils/aspect-ratio.ts
|
|
2568
|
-
function getAspectRatio(width, height) {
|
|
2569
|
-
return width / height;
|
|
2570
|
-
}
|
|
2571
|
-
function getNewHeight(width, aspectRatio) {
|
|
2572
|
-
if (width <= 0 || aspectRatio <= 0) {
|
|
2573
|
-
return 0;
|
|
2574
|
-
}
|
|
2575
|
-
return width / aspectRatio;
|
|
2576
|
-
}
|
|
2577
|
-
function getNewWidth(height, aspectRatio) {
|
|
2578
|
-
return height * aspectRatio;
|
|
2579
|
-
}
|
|
2580
|
-
|
|
2581
2612
|
// src/editor/nodes/image/image-view.tsx
|
|
2582
2613
|
var import_jsx_runtime17 = require("react/jsx-runtime");
|
|
2583
2614
|
var MIN_WIDTH = 20;
|
|
2584
|
-
var
|
|
2615
|
+
var IMAGE_MAX_WIDTH2 = 600;
|
|
2585
2616
|
var IMAGE_MAX_HEIGHT = 400;
|
|
2586
2617
|
function ImageView(props) {
|
|
2587
2618
|
const { node, updateAttributes: updateAttributes2, selected, editor } = props;
|
|
@@ -2602,7 +2633,7 @@ function ImageView(props) {
|
|
|
2602
2633
|
}
|
|
2603
2634
|
const imageParentWidth = Math.max(
|
|
2604
2635
|
imageParent.offsetWidth,
|
|
2605
|
-
|
|
2636
|
+
IMAGE_MAX_WIDTH2
|
|
2606
2637
|
);
|
|
2607
2638
|
event.preventDefault();
|
|
2608
2639
|
const direction = event.currentTarget.dataset.direction || "--";
|
|
@@ -3218,37 +3249,7 @@ var LogoExtension = import_extension_image.default.extend({
|
|
|
3218
3249
|
}
|
|
3219
3250
|
});
|
|
3220
3251
|
|
|
3221
|
-
// src/editor/utils/border-radius.ts
|
|
3222
|
-
var borderRadius = [
|
|
3223
|
-
{
|
|
3224
|
-
name: "Sharp",
|
|
3225
|
-
value: 0
|
|
3226
|
-
},
|
|
3227
|
-
{
|
|
3228
|
-
name: "Smooth",
|
|
3229
|
-
value: 8
|
|
3230
|
-
},
|
|
3231
|
-
{
|
|
3232
|
-
name: "Smoother",
|
|
3233
|
-
value: 16
|
|
3234
|
-
},
|
|
3235
|
-
{
|
|
3236
|
-
name: "Rounded",
|
|
3237
|
-
value: 24
|
|
3238
|
-
},
|
|
3239
|
-
{
|
|
3240
|
-
name: "Circle",
|
|
3241
|
-
value: 9999
|
|
3242
|
-
}
|
|
3243
|
-
];
|
|
3244
|
-
|
|
3245
|
-
// src/editor/components/image-menu/image-bubble-menu.tsx
|
|
3246
|
-
var import_react32 = require("@tiptap/react");
|
|
3247
|
-
var import_lucide_react23 = require("lucide-react");
|
|
3248
|
-
var import_tippy4 = require("tippy.js");
|
|
3249
|
-
|
|
3250
3252
|
// src/editor/components/alignment-switch.tsx
|
|
3251
|
-
var import_lucide_react11 = require("lucide-react");
|
|
3252
3253
|
var import_jsx_runtime19 = require("react/jsx-runtime");
|
|
3253
3254
|
function AlignmentSwitch(props) {
|
|
3254
3255
|
const { alignment: rawAlignment, onAlignmentChange } = props;
|
|
@@ -4837,9 +4838,10 @@ var useImageState = (editor) => {
|
|
|
4837
4838
|
};
|
|
4838
4839
|
|
|
4839
4840
|
// src/editor/components/image-menu/image-bubble-menu.tsx
|
|
4841
|
+
var import_tippy4 = require("tippy.js");
|
|
4840
4842
|
var import_jsx_runtime37 = require("react/jsx-runtime");
|
|
4841
4843
|
function ImageBubbleMenu(props) {
|
|
4842
|
-
var _a, _b, _c
|
|
4844
|
+
var _a, _b, _c;
|
|
4843
4845
|
const { editor, appendTo } = props;
|
|
4844
4846
|
if (!editor) {
|
|
4845
4847
|
return null;
|
|
@@ -4900,33 +4902,10 @@ function ImageBubbleMenu(props) {
|
|
|
4900
4902
|
}
|
|
4901
4903
|
}
|
|
4902
4904
|
),
|
|
4903
|
-
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
4904
|
-
LinkInputPopover,
|
|
4905
|
-
{
|
|
4906
|
-
defaultValue: (_a = state == null ? void 0 : state.imageSrc) != null ? _a : "",
|
|
4907
|
-
onValueChange: (value, isVariable) => {
|
|
4908
|
-
if (state.isLogoActive) {
|
|
4909
|
-
editor == null ? void 0 : editor.chain().setLogoAttributes({
|
|
4910
|
-
src: value,
|
|
4911
|
-
isSrcVariable: isVariable != null ? isVariable : false
|
|
4912
|
-
}).run();
|
|
4913
|
-
} else {
|
|
4914
|
-
editor == null ? void 0 : editor.chain().updateAttributes("image", {
|
|
4915
|
-
src: value,
|
|
4916
|
-
isSrcVariable: isVariable != null ? isVariable : false
|
|
4917
|
-
}).run();
|
|
4918
|
-
}
|
|
4919
|
-
},
|
|
4920
|
-
tooltip: "Source URL",
|
|
4921
|
-
icon: import_lucide_react23.ImageDown,
|
|
4922
|
-
editor,
|
|
4923
|
-
isVariable: state.isSrcVariable
|
|
4924
|
-
}
|
|
4925
|
-
),
|
|
4926
4905
|
state.isImageActive && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
4927
4906
|
LinkInputPopover,
|
|
4928
4907
|
{
|
|
4929
|
-
defaultValue: (
|
|
4908
|
+
defaultValue: (_a = state == null ? void 0 : state.imageExternalLink) != null ? _a : "",
|
|
4930
4909
|
onValueChange: (value, isVariable) => {
|
|
4931
4910
|
editor == null ? void 0 : editor.chain().updateAttributes("image", {
|
|
4932
4911
|
externalLink: value,
|
|
@@ -4964,7 +4943,7 @@ function ImageBubbleMenu(props) {
|
|
|
4964
4943
|
ImageSize,
|
|
4965
4944
|
{
|
|
4966
4945
|
dimension: "width",
|
|
4967
|
-
value: (
|
|
4946
|
+
value: (_b = state == null ? void 0 : state.width) != null ? _b : "",
|
|
4968
4947
|
onValueChange: (value) => {
|
|
4969
4948
|
const width = Math.min(Number(value) || 0, IMAGE_MAX_WIDTH);
|
|
4970
4949
|
const currentHeight = Number(state.height) || 0;
|
|
@@ -4984,7 +4963,7 @@ function ImageBubbleMenu(props) {
|
|
|
4984
4963
|
ImageSize,
|
|
4985
4964
|
{
|
|
4986
4965
|
dimension: "height",
|
|
4987
|
-
value: (
|
|
4966
|
+
value: (_c = state == null ? void 0 : state.height) != null ? _c : "",
|
|
4988
4967
|
onValueChange: (value) => {
|
|
4989
4968
|
const height = Number(value) || 0;
|
|
4990
4969
|
const currentHeight = Number(state.height) || 0;
|
|
@@ -5018,20 +4997,7 @@ function ImageBubbleMenu(props) {
|
|
|
5018
4997
|
}
|
|
5019
4998
|
)
|
|
5020
4999
|
] })
|
|
5021
|
-
] })
|
|
5022
|
-
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Divider, {}),
|
|
5023
|
-
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
5024
|
-
ShowPopover,
|
|
5025
|
-
{
|
|
5026
|
-
showIfKey: state.currentShowIfKey,
|
|
5027
|
-
onShowIfKeyValueChange: (value) => {
|
|
5028
|
-
editor == null ? void 0 : editor.chain().updateAttributes(state.isLogoActive ? "logo" : "image", {
|
|
5029
|
-
showIfKey: value
|
|
5030
|
-
}).run();
|
|
5031
|
-
},
|
|
5032
|
-
editor
|
|
5033
|
-
}
|
|
5034
|
-
)
|
|
5000
|
+
] })
|
|
5035
5001
|
] })
|
|
5036
5002
|
})
|
|
5037
5003
|
);
|
|
@@ -5178,10 +5144,9 @@ var useInlineImageState = (editor) => {
|
|
|
5178
5144
|
};
|
|
5179
5145
|
|
|
5180
5146
|
// src/editor/components/inline-image-menu/inline-image-bubble-menu.tsx
|
|
5181
|
-
var import_lucide_react24 = require("lucide-react");
|
|
5182
5147
|
var import_jsx_runtime38 = require("react/jsx-runtime");
|
|
5183
5148
|
function InlineImageBubbleMenu(props) {
|
|
5184
|
-
var _a
|
|
5149
|
+
var _a;
|
|
5185
5150
|
const { editor, appendTo } = props;
|
|
5186
5151
|
if (!editor) {
|
|
5187
5152
|
return null;
|
|
@@ -5211,23 +5176,7 @@ function InlineImageBubbleMenu(props) {
|
|
|
5211
5176
|
/* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
|
|
5212
5177
|
LinkInputPopover,
|
|
5213
5178
|
{
|
|
5214
|
-
defaultValue: (_a = state == null ? void 0 : state.
|
|
5215
|
-
onValueChange: (value, isVariable) => {
|
|
5216
|
-
editor == null ? void 0 : editor.chain().updateAttributes("inlineImage", {
|
|
5217
|
-
src: value,
|
|
5218
|
-
isSrcVariable: isVariable != null ? isVariable : false
|
|
5219
|
-
}).run();
|
|
5220
|
-
},
|
|
5221
|
-
tooltip: "Source URL",
|
|
5222
|
-
icon: import_lucide_react24.ImageDownIcon,
|
|
5223
|
-
editor,
|
|
5224
|
-
isVariable: state.isSrcVariable
|
|
5225
|
-
}
|
|
5226
|
-
),
|
|
5227
|
-
/* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
|
|
5228
|
-
LinkInputPopover,
|
|
5229
|
-
{
|
|
5230
|
-
defaultValue: (_b = state == null ? void 0 : state.imageExternalLink) != null ? _b : "",
|
|
5179
|
+
defaultValue: (_a = state == null ? void 0 : state.imageExternalLink) != null ? _a : "",
|
|
5231
5180
|
onValueChange: (value, isVariable) => {
|
|
5232
5181
|
editor == null ? void 0 : editor.chain().updateAttributes("inlineImage", {
|
|
5233
5182
|
externalLink: value,
|
|
@@ -5259,7 +5208,7 @@ function InlineImageBubbleMenu(props) {
|
|
|
5259
5208
|
|
|
5260
5209
|
// src/editor/components/repeat-menu/repeat-bubble-menu.tsx
|
|
5261
5210
|
var import_react36 = require("@tiptap/react");
|
|
5262
|
-
var
|
|
5211
|
+
var import_lucide_react24 = require("lucide-react");
|
|
5263
5212
|
var import_react37 = require("react");
|
|
5264
5213
|
var import_tippy6 = require("tippy.js");
|
|
5265
5214
|
|
|
@@ -5344,7 +5293,7 @@ function RepeatBubbleMenu(props) {
|
|
|
5344
5293
|
"Repeat",
|
|
5345
5294
|
/* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(Tooltip, { children: [
|
|
5346
5295
|
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(TooltipTrigger, { children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
5347
|
-
|
|
5296
|
+
import_lucide_react24.InfoIcon,
|
|
5348
5297
|
{
|
|
5349
5298
|
className: cn("mly-size-3 mly-stroke-[2.5] mly-text-gray-500")
|
|
5350
5299
|
}
|
|
@@ -5439,7 +5388,7 @@ function RepeatBubbleMenu(props) {
|
|
|
5439
5388
|
|
|
5440
5389
|
// src/editor/components/section-menu/section-bubble-menu.tsx
|
|
5441
5390
|
var import_react39 = require("@tiptap/react");
|
|
5442
|
-
var
|
|
5391
|
+
var import_lucide_react25 = require("lucide-react");
|
|
5443
5392
|
var import_react40 = require("react");
|
|
5444
5393
|
var import_tippy7 = require("tippy.js");
|
|
5445
5394
|
|
|
@@ -5879,32 +5828,19 @@ function SectionBubbleMenu(props) {
|
|
|
5879
5828
|
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
5880
5829
|
BubbleMenuButton,
|
|
5881
5830
|
{
|
|
5882
|
-
icon:
|
|
5831
|
+
icon: import_lucide_react25.Trash,
|
|
5883
5832
|
tooltip: "Delete Section",
|
|
5884
5833
|
command: () => {
|
|
5885
5834
|
deleteNode(editor, "section");
|
|
5886
5835
|
}
|
|
5887
5836
|
}
|
|
5888
5837
|
),
|
|
5889
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(Divider, {}),
|
|
5890
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
5891
|
-
ShowPopover,
|
|
5892
|
-
{
|
|
5893
|
-
showIfKey: state.currentShowIfKey,
|
|
5894
|
-
onShowIfKeyValueChange: (value) => {
|
|
5895
|
-
editor.commands.updateSection({
|
|
5896
|
-
showIfKey: value
|
|
5897
|
-
});
|
|
5898
|
-
},
|
|
5899
|
-
editor
|
|
5900
|
-
}
|
|
5901
|
-
),
|
|
5902
5838
|
state.isColumnsActive && /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(import_jsx_runtime44.Fragment, { children: [
|
|
5903
5839
|
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(Divider, {}),
|
|
5904
5840
|
/* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(Popover, { children: [
|
|
5905
5841
|
/* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(PopoverTrigger, { className: "mly-flex mly-items-center mly-gap-1 mly-rounded-md mly-px-1.5 mly-text-sm data-[state=open]:mly-bg-soft-gray hover:mly-bg-soft-gray", children: [
|
|
5906
5842
|
"Column",
|
|
5907
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
5843
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_lucide_react25.ChevronUp, { className: "mly-h-3 mly-w-3" })
|
|
5908
5844
|
] }),
|
|
5909
5845
|
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
5910
5846
|
PopoverContent,
|
|
@@ -5987,28 +5923,15 @@ function SpacerBubbleMenu(props) {
|
|
|
5987
5923
|
import_react42.BubbleMenu,
|
|
5988
5924
|
__spreadProps(__spreadValues({}, bubbleMenuProps), {
|
|
5989
5925
|
className: "mly-flex mly-gap-0.5 mly-rounded-lg mly-border mly-border-gray-200 mly-bg-white mly-p-0.5 mly-shadow-md",
|
|
5990
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime45.
|
|
5991
|
-
|
|
5992
|
-
|
|
5993
|
-
|
|
5994
|
-
|
|
5995
|
-
|
|
5996
|
-
|
|
5997
|
-
|
|
5998
|
-
|
|
5999
|
-
)),
|
|
6000
|
-
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(Divider, {}),
|
|
6001
|
-
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
6002
|
-
ShowPopover,
|
|
6003
|
-
{
|
|
6004
|
-
showIfKey: state.currentShowIfKey,
|
|
6005
|
-
onShowIfKeyValueChange: (value) => {
|
|
6006
|
-
editor.commands.setSpacerShowIfKey(value);
|
|
6007
|
-
},
|
|
6008
|
-
editor
|
|
6009
|
-
}
|
|
6010
|
-
)
|
|
6011
|
-
] })
|
|
5926
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(TooltipProvider, { children: items.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
5927
|
+
BubbleMenuButton,
|
|
5928
|
+
__spreadValues({
|
|
5929
|
+
className: "!mly-h-7 mly-w-7 mly-shrink-0 mly-p-0",
|
|
5930
|
+
iconClassName: "mly-w-3 mly-h-3",
|
|
5931
|
+
nameClassName: "mly-text-xs"
|
|
5932
|
+
}, item),
|
|
5933
|
+
index
|
|
5934
|
+
)) })
|
|
6012
5935
|
})
|
|
6013
5936
|
);
|
|
6014
5937
|
}
|
|
@@ -6844,20 +6767,7 @@ function ButtonView(props) {
|
|
|
6844
6767
|
}
|
|
6845
6768
|
}
|
|
6846
6769
|
)
|
|
6847
|
-
] })
|
|
6848
|
-
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(Divider, {}),
|
|
6849
|
-
/* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
6850
|
-
ShowPopover,
|
|
6851
|
-
{
|
|
6852
|
-
showIfKey,
|
|
6853
|
-
onShowIfKeyValueChange: (value) => {
|
|
6854
|
-
updateAttributes2({
|
|
6855
|
-
showIfKey: value
|
|
6856
|
-
});
|
|
6857
|
-
},
|
|
6858
|
-
editor
|
|
6859
|
-
}
|
|
6860
|
-
)
|
|
6770
|
+
] })
|
|
6861
6771
|
] }) })
|
|
6862
6772
|
}
|
|
6863
6773
|
)
|
|
@@ -7528,7 +7438,7 @@ var import_react54 = require("@tiptap/react");
|
|
|
7528
7438
|
|
|
7529
7439
|
// src/editor/nodes/repeat/repeat-view.tsx
|
|
7530
7440
|
var import_react53 = require("@tiptap/react");
|
|
7531
|
-
var
|
|
7441
|
+
var import_lucide_react26 = require("lucide-react");
|
|
7532
7442
|
var import_jsx_runtime52 = require("react/jsx-runtime");
|
|
7533
7443
|
function RepeatView(props) {
|
|
7534
7444
|
const { editor, getPos } = props;
|
|
@@ -7552,7 +7462,7 @@ function RepeatView(props) {
|
|
|
7552
7462
|
editor.commands.setNodeSelection(getPos());
|
|
7553
7463
|
},
|
|
7554
7464
|
children: [
|
|
7555
|
-
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
7465
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_lucide_react26.Repeat2, { className: "mly-size-3 mly-stroke-[2.5] mly-text-midnight-gray" }),
|
|
7556
7466
|
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "mly-w-[1.5px] mly-grow mly-rounded-full mly-bg-rose-300" })
|
|
7557
7467
|
]
|
|
7558
7468
|
}
|
|
@@ -7799,7 +7709,7 @@ var import_react57 = require("react");
|
|
|
7799
7709
|
var import_tippy8 = __toESM(require("tippy.js"), 1);
|
|
7800
7710
|
|
|
7801
7711
|
// src/editor/extensions/slash-command/slash-command-item.tsx
|
|
7802
|
-
var
|
|
7712
|
+
var import_lucide_react27 = require("lucide-react");
|
|
7803
7713
|
var import_react55 = require("react");
|
|
7804
7714
|
var import_jsx_runtime53 = require("react/jsx-runtime");
|
|
7805
7715
|
function SlashCommandItem(props) {
|
|
@@ -7830,7 +7740,7 @@ function SlashCommandItem(props) {
|
|
|
7830
7740
|
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)("p", { className: "mly-font-medium", children: item.title }),
|
|
7831
7741
|
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)("p", { className: "mly-text-xs mly-text-gray-400", children: item.description })
|
|
7832
7742
|
] }),
|
|
7833
|
-
isSubCommand2 && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "mly-block mly-px-1 mly-text-gray-400", children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
7743
|
+
isSubCommand2 && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "mly-block mly-px-1 mly-text-gray-400", children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_lucide_react27.ChevronRightIcon, { className: "mly-size-3.5 mly-stroke-[2.5]" }) })
|
|
7834
7744
|
] });
|
|
7835
7745
|
if (renderFunctionValue !== null && renderFunctionValue !== true) {
|
|
7836
7746
|
value = renderFunctionValue;
|
|
@@ -8462,7 +8372,7 @@ var isCustomNodeSelected = (editor, node) => {
|
|
|
8462
8372
|
var import_react64 = require("@tiptap/react");
|
|
8463
8373
|
|
|
8464
8374
|
// src/editor/components/text-menu/text-bubble-content.tsx
|
|
8465
|
-
var
|
|
8375
|
+
var import_lucide_react28 = require("lucide-react");
|
|
8466
8376
|
|
|
8467
8377
|
// src/editor/components/text-menu/use-text-menu-state.tsx
|
|
8468
8378
|
var import_react61 = require("@tiptap/react");
|
|
@@ -8503,35 +8413,35 @@ function TextBubbleContent(props) {
|
|
|
8503
8413
|
name: "bold",
|
|
8504
8414
|
isActive: () => editor == null ? void 0 : editor.isActive("bold"),
|
|
8505
8415
|
command: () => editor == null ? void 0 : editor.chain().focus().toggleBold().run(),
|
|
8506
|
-
icon:
|
|
8416
|
+
icon: import_lucide_react28.BoldIcon,
|
|
8507
8417
|
tooltip: "Bold"
|
|
8508
8418
|
},
|
|
8509
8419
|
{
|
|
8510
8420
|
name: "italic",
|
|
8511
8421
|
isActive: () => editor == null ? void 0 : editor.isActive("italic"),
|
|
8512
8422
|
command: () => editor == null ? void 0 : editor.chain().focus().toggleItalic().run(),
|
|
8513
|
-
icon:
|
|
8423
|
+
icon: import_lucide_react28.ItalicIcon,
|
|
8514
8424
|
tooltip: "Italic"
|
|
8515
8425
|
},
|
|
8516
8426
|
{
|
|
8517
8427
|
name: "underline",
|
|
8518
8428
|
isActive: () => editor == null ? void 0 : editor.isActive("underline"),
|
|
8519
8429
|
command: () => editor == null ? void 0 : editor.chain().focus().toggleUnderline().run(),
|
|
8520
|
-
icon:
|
|
8430
|
+
icon: import_lucide_react28.UnderlineIcon,
|
|
8521
8431
|
tooltip: "Underline"
|
|
8522
8432
|
},
|
|
8523
8433
|
{
|
|
8524
8434
|
name: "strike",
|
|
8525
8435
|
isActive: () => editor == null ? void 0 : editor.isActive("strike"),
|
|
8526
8436
|
command: () => editor == null ? void 0 : editor.chain().focus().toggleStrike().run(),
|
|
8527
|
-
icon:
|
|
8437
|
+
icon: import_lucide_react28.StrikethroughIcon,
|
|
8528
8438
|
tooltip: "Strikethrough"
|
|
8529
8439
|
},
|
|
8530
8440
|
{
|
|
8531
8441
|
name: "code",
|
|
8532
8442
|
isActive: () => editor == null ? void 0 : editor.isActive("code"),
|
|
8533
8443
|
command: () => editor == null ? void 0 : editor.chain().focus().toggleCode().run(),
|
|
8534
|
-
icon:
|
|
8444
|
+
icon: import_lucide_react28.CodeIcon,
|
|
8535
8445
|
tooltip: "Code"
|
|
8536
8446
|
}
|
|
8537
8447
|
];
|
|
@@ -8550,7 +8460,7 @@ function TextBubbleContent(props) {
|
|
|
8550
8460
|
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
|
|
8551
8461
|
BubbleMenuButton,
|
|
8552
8462
|
{
|
|
8553
|
-
icon:
|
|
8463
|
+
icon: import_lucide_react28.List,
|
|
8554
8464
|
command: () => {
|
|
8555
8465
|
editor.chain().focus().toggleBulletList().run();
|
|
8556
8466
|
},
|
|
@@ -8560,7 +8470,7 @@ function TextBubbleContent(props) {
|
|
|
8560
8470
|
/* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
|
|
8561
8471
|
BubbleMenuButton,
|
|
8562
8472
|
{
|
|
8563
|
-
icon:
|
|
8473
|
+
icon: import_lucide_react28.ListOrdered,
|
|
8564
8474
|
command: () => {
|
|
8565
8475
|
editor.chain().focus().toggleOrderedList().run();
|
|
8566
8476
|
},
|
|
@@ -8619,7 +8529,7 @@ function TextBubbleContent(props) {
|
|
|
8619
8529
|
}
|
|
8620
8530
|
|
|
8621
8531
|
// src/editor/components/text-menu/turn-into-block.tsx
|
|
8622
|
-
var
|
|
8532
|
+
var import_lucide_react29 = require("lucide-react");
|
|
8623
8533
|
var import_react62 = require("react");
|
|
8624
8534
|
var import_jsx_runtime57 = require("react/jsx-runtime");
|
|
8625
8535
|
var isOption = (option) => option.type === "option";
|
|
@@ -8630,7 +8540,7 @@ function TurnIntoBlock(props) {
|
|
|
8630
8540
|
() => options.find((option) => option.type === "option" && option.isActive()),
|
|
8631
8541
|
[options]
|
|
8632
8542
|
);
|
|
8633
|
-
const { icon: ActiveIcon =
|
|
8543
|
+
const { icon: ActiveIcon = import_lucide_react29.PilcrowIcon } = activeItem || {};
|
|
8634
8544
|
return /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(Popover, { children: [
|
|
8635
8545
|
/* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(Tooltip, { children: [
|
|
8636
8546
|
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(
|
|
@@ -8641,7 +8551,7 @@ function TurnIntoBlock(props) {
|
|
|
8641
8551
|
),
|
|
8642
8552
|
children: [
|
|
8643
8553
|
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(ActiveIcon, { className: "mly-h-3 mly-w-3 mly-shrink-0 mly-stroke-[2.5]" }),
|
|
8644
|
-
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
|
|
8554
|
+
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_lucide_react29.ChevronDownIcon, { className: "mly-h-3 mly-w-3 mly-shrink-0 mly-stroke-[2.5]" })
|
|
8645
8555
|
]
|
|
8646
8556
|
}
|
|
8647
8557
|
) }),
|
|
@@ -8690,7 +8600,7 @@ function TurnIntoBlock(props) {
|
|
|
8690
8600
|
|
|
8691
8601
|
// src/editor/components/text-menu/use-turn-into-block-options.tsx
|
|
8692
8602
|
var import_react63 = require("@tiptap/react");
|
|
8693
|
-
var
|
|
8603
|
+
var import_lucide_react30 = require("lucide-react");
|
|
8694
8604
|
function useTurnIntoBlockOptions(editor) {
|
|
8695
8605
|
return (0, import_react63.useEditorState)({
|
|
8696
8606
|
editor,
|
|
@@ -8701,7 +8611,7 @@ function useTurnIntoBlockOptions(editor) {
|
|
|
8701
8611
|
id: "hierarchy"
|
|
8702
8612
|
},
|
|
8703
8613
|
{
|
|
8704
|
-
icon:
|
|
8614
|
+
icon: import_lucide_react30.PilcrowIcon,
|
|
8705
8615
|
onClick: () => editor2.chain().focus().liftListItem("listItem").setParagraph().run(),
|
|
8706
8616
|
id: "paragraph",
|
|
8707
8617
|
disabled: () => !editor2.can().setParagraph(),
|
|
@@ -8710,7 +8620,7 @@ function useTurnIntoBlockOptions(editor) {
|
|
|
8710
8620
|
type: "option"
|
|
8711
8621
|
},
|
|
8712
8622
|
{
|
|
8713
|
-
icon:
|
|
8623
|
+
icon: import_lucide_react30.Heading1Icon,
|
|
8714
8624
|
onClick: () => editor2.chain().focus().liftListItem("listItem").setHeading({ level: 1 }).run(),
|
|
8715
8625
|
id: "heading1",
|
|
8716
8626
|
disabled: () => !editor2.can().setHeading({ level: 1 }),
|
|
@@ -8719,7 +8629,7 @@ function useTurnIntoBlockOptions(editor) {
|
|
|
8719
8629
|
type: "option"
|
|
8720
8630
|
},
|
|
8721
8631
|
{
|
|
8722
|
-
icon:
|
|
8632
|
+
icon: import_lucide_react30.Heading2Icon,
|
|
8723
8633
|
onClick: () => editor2.chain().focus().liftListItem("listItem").setHeading({ level: 2 }).run(),
|
|
8724
8634
|
id: "heading2",
|
|
8725
8635
|
disabled: () => !editor2.can().setHeading({ level: 2 }),
|
|
@@ -8728,7 +8638,7 @@ function useTurnIntoBlockOptions(editor) {
|
|
|
8728
8638
|
type: "option"
|
|
8729
8639
|
},
|
|
8730
8640
|
{
|
|
8731
|
-
icon:
|
|
8641
|
+
icon: import_lucide_react30.Heading3Icon,
|
|
8732
8642
|
onClick: () => editor2.chain().focus().liftListItem("listItem").setHeading({ level: 3 }).run(),
|
|
8733
8643
|
id: "heading3",
|
|
8734
8644
|
disabled: () => !editor2.can().setHeading({ level: 3 }),
|
|
@@ -8742,7 +8652,7 @@ function useTurnIntoBlockOptions(editor) {
|
|
|
8742
8652
|
id: "lists"
|
|
8743
8653
|
},
|
|
8744
8654
|
{
|
|
8745
|
-
icon:
|
|
8655
|
+
icon: import_lucide_react30.ListIcon,
|
|
8746
8656
|
onClick: () => editor2.chain().focus().toggleBulletList().run(),
|
|
8747
8657
|
id: "bulletList",
|
|
8748
8658
|
disabled: () => !editor2.can().toggleBulletList(),
|
|
@@ -8751,7 +8661,7 @@ function useTurnIntoBlockOptions(editor) {
|
|
|
8751
8661
|
type: "option"
|
|
8752
8662
|
},
|
|
8753
8663
|
{
|
|
8754
|
-
icon:
|
|
8664
|
+
icon: import_lucide_react30.ListOrderedIcon,
|
|
8755
8665
|
onClick: () => editor2.chain().focus().toggleOrderedList().run(),
|
|
8756
8666
|
id: "orderedList",
|
|
8757
8667
|
disabled: () => !editor2.can().toggleOrderedList(),
|