neuphlo-editor 2.1.1 → 2.3.0

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.
@@ -312,8 +312,6 @@ var ImageBlock = import_extension_image.Image.extend({
312
312
  addOptions() {
313
313
  return {
314
314
  ...this.parent?.(),
315
- uploadImage: void 0,
316
- browseAssets: void 0,
317
315
  inline: false
318
316
  };
319
317
  },
@@ -1361,10 +1359,11 @@ var VideoBlock = import_core5.Node.create({
1361
1359
  };
1362
1360
  },
1363
1361
  addNodeView() {
1362
+ console.log("[VideoBlock] addNodeView called, options:", Object.keys(this.options), "hasNodeView:", !!this.options.nodeView);
1364
1363
  if (this.options.nodeView) {
1365
1364
  return (0, import_react11.ReactNodeViewRenderer)(this.options.nodeView);
1366
1365
  }
1367
- return null;
1366
+ return void 0;
1368
1367
  }
1369
1368
  });
1370
1369
 
@@ -2486,6 +2485,7 @@ function ImageMenu({
2486
2485
  // src/react/menus/ImageBlock/ImageBlockView.tsx
2487
2486
  var import_react26 = require("@tiptap/react");
2488
2487
  var import_react27 = require("react");
2488
+ var import_icons_react9 = require("@tabler/icons-react");
2489
2489
 
2490
2490
  // src/react/menus/ImageBlock/ImageBlockMenu.tsx
2491
2491
  var import_state6 = require("@tiptap/pm/state");
@@ -2564,6 +2564,7 @@ var ImageBlockMenu = ({ editor, getPos, appendTo }) => {
2564
2564
  const { state } = ctx.editor;
2565
2565
  const { selection } = state;
2566
2566
  if (!ctx.editor.isEditable) return { isVisible: false, align: "center", width: 100 };
2567
+ if (!ctx.editor.isFocused) return { isVisible: false, align: "center", width: 100 };
2567
2568
  const isNodeSel = selection instanceof import_state6.NodeSelection;
2568
2569
  const isThisNode = isNodeSel && selection.from === getPos();
2569
2570
  const visible = isThisNode;
@@ -2757,6 +2758,31 @@ var ImageUploader = ({ onUpload, editor }) => {
2757
2758
  if (loading) {
2758
2759
  return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ImageBlockLoading, {});
2759
2760
  }
2761
+ if (browseAssets) {
2762
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
2763
+ "div",
2764
+ {
2765
+ className: "nph-image-uploader nph-image-uploader--browse-only",
2766
+ contentEditable: false,
2767
+ onClick: () => browseAssets(onUpload),
2768
+ role: "button",
2769
+ tabIndex: 0,
2770
+ onKeyDown: (e) => {
2771
+ if (e.key === "Enter" || e.key === " ") {
2772
+ e.preventDefault();
2773
+ browseAssets(onUpload);
2774
+ }
2775
+ },
2776
+ children: /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { className: "nph-image-uploader__browse-cta", children: [
2777
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { className: "nph-image-uploader__browse-icon-wrapper", children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_icons_react8.IconPhoto, { size: 28 }) }),
2778
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { className: "nph-image-uploader__browse-text", children: [
2779
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("span", { className: "nph-image-uploader__browse-title", children: "Choose from assets" }),
2780
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("span", { className: "nph-image-uploader__browse-subtitle", children: "Select an image from your library" })
2781
+ ] })
2782
+ ] })
2783
+ }
2784
+ );
2785
+ }
2760
2786
  return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
2761
2787
  "div",
2762
2788
  {
@@ -2769,34 +2795,19 @@ var ImageUploader = ({ onUpload, editor }) => {
2769
2795
  /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_icons_react8.IconPhoto, { size: 48, className: "nph-image-uploader__icon" }),
2770
2796
  /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { className: "nph-image-uploader__content", children: [
2771
2797
  /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { className: "nph-image-uploader__text", children: draggedInside ? "Drop image here" : "Drag and drop or" }),
2772
- /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { className: "nph-image-uploader__actions", children: [
2773
- /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
2774
- "button",
2775
- {
2776
- type: "button",
2777
- disabled: draggedInside,
2778
- onClick: handleUploadClick,
2779
- className: "nph-btn nph-btn-ghost nph-btn-sm nph-image-uploader__button",
2780
- children: [
2781
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_icons_react8.IconUpload, { size: 16 }),
2782
- "Upload an image"
2783
- ]
2784
- }
2785
- ),
2786
- browseAssets && /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
2787
- "button",
2788
- {
2789
- type: "button",
2790
- disabled: draggedInside,
2791
- onClick: () => browseAssets(onUpload),
2792
- className: "nph-btn nph-btn-ghost nph-btn-sm nph-image-uploader__button",
2793
- children: [
2794
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_icons_react8.IconPhoto, { size: 16 }),
2795
- "Browse assets"
2796
- ]
2797
- }
2798
- )
2799
- ] })
2798
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { className: "nph-image-uploader__actions", children: /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
2799
+ "button",
2800
+ {
2801
+ type: "button",
2802
+ disabled: draggedInside,
2803
+ onClick: handleUploadClick,
2804
+ className: "nph-btn nph-btn-ghost nph-btn-sm nph-image-uploader__button",
2805
+ children: [
2806
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_icons_react8.IconUpload, { size: 16 }),
2807
+ "Upload an image"
2808
+ ]
2809
+ }
2810
+ ) })
2800
2811
  ] }),
2801
2812
  /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
2802
2813
  "input",
@@ -2884,6 +2895,7 @@ var import_jsx_runtime16 = require("react/jsx-runtime");
2884
2895
  var ImageBlockView = (props) => {
2885
2896
  const { editor, getPos, node, updateAttributes } = props;
2886
2897
  const imageWrapperRef = (0, import_react27.useRef)(null);
2898
+ const [imageError, setImageError] = (0, import_react27.useState)(false);
2887
2899
  const { src, width, align, alt, loading } = node.attrs;
2888
2900
  const handleUpload = (0, import_react27.useCallback)(
2889
2901
  (url) => {
@@ -2923,6 +2935,15 @@ var ImageBlockView = (props) => {
2923
2935
  if (loading) {
2924
2936
  return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react26.NodeViewWrapper, { style: getWrapperStyle(), children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("div", { ref: imageWrapperRef, children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(ImageBlockLoading, {}) }) });
2925
2937
  }
2938
+ if (imageError) {
2939
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react26.NodeViewWrapper, { style: getWrapperStyle(), children: /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("div", { contentEditable: false, ref: imageWrapperRef, style: getContentStyle(), children: [
2940
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("div", { className: "nph-image-block-error", onClick, children: [
2941
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_icons_react9.IconPhotoOff, { size: 32 }),
2942
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("span", { children: "Image could not be loaded" })
2943
+ ] }),
2944
+ editor.isEditable && /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(ImageBlockMenu, { editor, getPos, appendTo: imageWrapperRef })
2945
+ ] }) });
2946
+ }
2926
2947
  return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react26.NodeViewWrapper, { style: getWrapperStyle(), children: /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("div", { contentEditable: false, ref: imageWrapperRef, style: getContentStyle(), children: [
2927
2948
  editor.isEditable ? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(ImageResizeHandle, { onResize: handleResize, currentWidth: width, children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
2928
2949
  "img",
@@ -2930,6 +2951,7 @@ var ImageBlockView = (props) => {
2930
2951
  src,
2931
2952
  alt: alt || "",
2932
2953
  onClick,
2954
+ onError: () => setImageError(true),
2933
2955
  className: "nph-image-block"
2934
2956
  }
2935
2957
  ) }) : /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
@@ -2937,6 +2959,7 @@ var ImageBlockView = (props) => {
2937
2959
  {
2938
2960
  src,
2939
2961
  alt: alt || "",
2962
+ onError: () => setImageError(true),
2940
2963
  className: "nph-image-block"
2941
2964
  }
2942
2965
  ),
@@ -2953,7 +2976,7 @@ var import_react31 = require("react");
2953
2976
  var import_state7 = require("@tiptap/pm/state");
2954
2977
  var import_react28 = require("@tiptap/react");
2955
2978
  var import_react29 = require("react");
2956
- var import_icons_react9 = require("@tabler/icons-react");
2979
+ var import_icons_react10 = require("@tabler/icons-react");
2957
2980
  var import_jsx_runtime17 = require("react/jsx-runtime");
2958
2981
  var VideoBlockMenu = ({ editor, getPos }) => {
2959
2982
  const menuRef = (0, import_react29.useRef)(null);
@@ -3017,7 +3040,7 @@ var VideoBlockMenu = ({ editor, getPos }) => {
3017
3040
  title: "Align left",
3018
3041
  onMouseDown: (e) => e.preventDefault(),
3019
3042
  onClick: onAlignLeft,
3020
- children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_icons_react9.IconAlignLeft, { size: 16 })
3043
+ children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_icons_react10.IconAlignLeft, { size: 16 })
3021
3044
  }
3022
3045
  ),
3023
3046
  /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
@@ -3028,7 +3051,7 @@ var VideoBlockMenu = ({ editor, getPos }) => {
3028
3051
  title: "Align center",
3029
3052
  onMouseDown: (e) => e.preventDefault(),
3030
3053
  onClick: onAlignCenter,
3031
- children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_icons_react9.IconAlignCenter, { size: 16 })
3054
+ children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_icons_react10.IconAlignCenter, { size: 16 })
3032
3055
  }
3033
3056
  ),
3034
3057
  /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
@@ -3039,7 +3062,7 @@ var VideoBlockMenu = ({ editor, getPos }) => {
3039
3062
  title: "Align right",
3040
3063
  onMouseDown: (e) => e.preventDefault(),
3041
3064
  onClick: onAlignRight,
3042
- children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_icons_react9.IconAlignRight, { size: 16 })
3065
+ children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_icons_react10.IconAlignRight, { size: 16 })
3043
3066
  }
3044
3067
  ),
3045
3068
  /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
@@ -3065,7 +3088,7 @@ var VideoBlockMenu = ({ editor, getPos }) => {
3065
3088
  title: "Remove video",
3066
3089
  onMouseDown: (e) => e.preventDefault(),
3067
3090
  onClick: onRemove,
3068
- children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_icons_react9.IconTrash, { size: 16 })
3091
+ children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_icons_react10.IconTrash, { size: 16 })
3069
3092
  }
3070
3093
  )
3071
3094
  ]
@@ -3074,19 +3097,26 @@ var VideoBlockMenu = ({ editor, getPos }) => {
3074
3097
  };
3075
3098
 
3076
3099
  // src/react/menus/VideoBlock/VideoBlockView.tsx
3077
- var import_icons_react10 = require("@tabler/icons-react");
3100
+ var import_icons_react11 = require("@tabler/icons-react");
3078
3101
  var import_jsx_runtime18 = require("react/jsx-runtime");
3079
3102
  function toEmbedUrl(url) {
3103
+ if (url.includes("/embed/") || url.includes("player.vimeo.com") || url.includes("loom.com/embed")) {
3104
+ return url;
3105
+ }
3080
3106
  const ytMatch = url.match(
3081
- /(?:youtube\.com\/watch\?v=|youtu\.be\/)([\w-]+)/
3107
+ /(?:youtube\.com\/(?:watch\?v=|shorts\/)|youtu\.be\/)([\w-]+)/
3082
3108
  );
3083
3109
  if (ytMatch) {
3084
3110
  return `https://www.youtube.com/embed/${ytMatch[1]}`;
3085
3111
  }
3086
- const vimeoMatch = url.match(/vimeo\.com\/(\d+)/);
3112
+ const vimeoMatch = url.match(/vimeo\.com\/(?:channels\/[\w-]+\/)?(\d+)/);
3087
3113
  if (vimeoMatch) {
3088
3114
  return `https://player.vimeo.com/video/${vimeoMatch[1]}`;
3089
3115
  }
3116
+ const loomMatch = url.match(/loom\.com\/share\/([\w-]+)/);
3117
+ if (loomMatch) {
3118
+ return `https://www.loom.com/embed/${loomMatch[1]}`;
3119
+ }
3090
3120
  return url;
3091
3121
  }
3092
3122
  var VideoBlockView = (props) => {
@@ -3094,6 +3124,7 @@ var VideoBlockView = (props) => {
3094
3124
  const wrapperRef = (0, import_react31.useRef)(null);
3095
3125
  const { src, width, align } = node.attrs;
3096
3126
  const [inputUrl, setInputUrl] = (0, import_react31.useState)("");
3127
+ const [videoError, setVideoError] = (0, import_react31.useState)(false);
3097
3128
  const isSelected = (0, import_react30.useEditorState)({
3098
3129
  editor,
3099
3130
  selector: (ctx) => {
@@ -3121,8 +3152,8 @@ var VideoBlockView = (props) => {
3121
3152
  }, [getPos, editor.commands]);
3122
3153
  const getWrapperStyle = () => {
3123
3154
  const baseStyle = {
3124
- width: "fit-content",
3125
- maxWidth: width || "100%"
3155
+ width: width || "100%",
3156
+ maxWidth: "100%"
3126
3157
  };
3127
3158
  if (align === "left") {
3128
3159
  return { ...baseStyle, marginLeft: 0, marginRight: "auto" };
@@ -3134,18 +3165,23 @@ var VideoBlockView = (props) => {
3134
3165
  };
3135
3166
  if (!src || src === "") {
3136
3167
  if (!editor.isEditable) return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react30.NodeViewWrapper, {});
3137
- return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react30.NodeViewWrapper, { style: getWrapperStyle(), children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { ref: wrapperRef, children: /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "nph-video-input", children: [
3138
- /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className: "nph-video-input__icon", children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_icons_react10.IconVideo, { size: 24 }) }),
3139
- /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "nph-video-input__content", children: [
3168
+ return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react30.NodeViewWrapper, { style: getWrapperStyle(), children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { ref: wrapperRef, children: /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "nph-video-placeholder", onClick, children: [
3169
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className: "nph-video-placeholder__icon", children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_icons_react11.IconVideo, { size: 28, stroke: 1.5 }) }),
3170
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { style: { display: "flex", flexDirection: "column", alignItems: "center", gap: "2px" }, children: [
3171
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { style: { fontSize: "14px", fontWeight: 600, lineHeight: "20px" }, children: "Add a video" }),
3172
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { style: { fontSize: "13px", opacity: 0.5, lineHeight: "18px" }, children: "Paste a URL to embed" })
3173
+ ] }),
3174
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "nph-video-placeholder__input", children: [
3140
3175
  /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
3141
3176
  "input",
3142
3177
  {
3143
3178
  type: "text",
3144
3179
  className: "nph-video-input__field",
3145
- placeholder: "Paste a YouTube, Vimeo, or video URL...",
3180
+ placeholder: "YouTube, Vimeo, or Loom URL...",
3146
3181
  value: inputUrl,
3147
3182
  onChange: (e) => setInputUrl(e.target.value),
3148
- onKeyDown: handleKeyDown
3183
+ onKeyDown: handleKeyDown,
3184
+ onClick: (e) => e.stopPropagation()
3149
3185
  }
3150
3186
  ),
3151
3187
  /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
@@ -3153,7 +3189,10 @@ var VideoBlockView = (props) => {
3153
3189
  {
3154
3190
  type: "button",
3155
3191
  className: "nph-video-input__button",
3156
- onClick: handleEmbed,
3192
+ onClick: (e) => {
3193
+ e.stopPropagation();
3194
+ handleEmbed();
3195
+ },
3157
3196
  disabled: !inputUrl.trim(),
3158
3197
  children: "Embed"
3159
3198
  }
@@ -3161,6 +3200,16 @@ var VideoBlockView = (props) => {
3161
3200
  ] })
3162
3201
  ] }) }) });
3163
3202
  }
3203
+ if (videoError) {
3204
+ return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react30.NodeViewWrapper, { style: getWrapperStyle(), children: /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { contentEditable: false, ref: wrapperRef, style: { position: "relative" }, children: [
3205
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "nph-video-block-error", onClick, children: [
3206
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_icons_react11.IconVideoOff, { size: 32 }),
3207
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("span", { children: "Video could not be loaded" }),
3208
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("span", { className: "nph-video-block-error__url", children: src })
3209
+ ] }),
3210
+ editor.isEditable && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(VideoBlockMenu, { editor, getPos })
3211
+ ] }) });
3212
+ }
3164
3213
  return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react30.NodeViewWrapper, { style: getWrapperStyle(), children: /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(
3165
3214
  "div",
3166
3215
  {
@@ -3175,7 +3224,8 @@ var VideoBlockView = (props) => {
3175
3224
  src,
3176
3225
  className: "nph-video-block__iframe",
3177
3226
  allow: "accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",
3178
- allowFullScreen: true
3227
+ allowFullScreen: true,
3228
+ onError: () => setVideoError(true)
3179
3229
  }
3180
3230
  ),
3181
3231
  !isSelected && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
@@ -3193,7 +3243,7 @@ var VideoBlockView = (props) => {
3193
3243
  };
3194
3244
 
3195
3245
  // src/react/menus/DragHandle/BlockActionMenu.tsx
3196
- var import_icons_react11 = require("@tabler/icons-react");
3246
+ var import_icons_react12 = require("@tabler/icons-react");
3197
3247
  var import_react32 = require("react");
3198
3248
  var import_jsx_runtime19 = require("react/jsx-runtime");
3199
3249
  function BlockActionMenu({ editor, onClose }) {
@@ -3296,7 +3346,7 @@ function BlockActionMenu({ editor, onClose }) {
3296
3346
  onClick: handleDelete,
3297
3347
  onMouseDown: (e) => e.preventDefault(),
3298
3348
  children: [
3299
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react11.IconTrash, { size: 16 }),
3349
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react12.IconTrash, { size: 16 }),
3300
3350
  /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { children: "Delete" })
3301
3351
  ]
3302
3352
  }
@@ -3309,7 +3359,7 @@ function BlockActionMenu({ editor, onClose }) {
3309
3359
  onClick: handleDuplicate,
3310
3360
  onMouseDown: (e) => e.preventDefault(),
3311
3361
  children: [
3312
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react11.IconCopy, { size: 16 }),
3362
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react12.IconCopy, { size: 16 }),
3313
3363
  /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { children: "Duplicate" })
3314
3364
  ]
3315
3365
  }
@@ -3322,7 +3372,7 @@ function BlockActionMenu({ editor, onClose }) {
3322
3372
  onClick: handleCopyToClipboard,
3323
3373
  onMouseDown: (e) => e.preventDefault(),
3324
3374
  children: [
3325
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react11.IconClipboard, { size: 16 }),
3375
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react12.IconClipboard, { size: 16 }),
3326
3376
  /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { children: "Copy to clipboard" })
3327
3377
  ]
3328
3378
  }
@@ -3335,7 +3385,7 @@ function BlockActionMenu({ editor, onClose }) {
3335
3385
  onClick: handleMoveUp,
3336
3386
  onMouseDown: (e) => e.preventDefault(),
3337
3387
  children: [
3338
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react11.IconArrowUp, { size: 16 }),
3388
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react12.IconArrowUp, { size: 16 }),
3339
3389
  /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { children: "Move up" })
3340
3390
  ]
3341
3391
  }
@@ -3348,7 +3398,7 @@ function BlockActionMenu({ editor, onClose }) {
3348
3398
  onClick: handleMoveDown,
3349
3399
  onMouseDown: (e) => e.preventDefault(),
3350
3400
  children: [
3351
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react11.IconArrowDown, { size: 16 }),
3401
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react12.IconArrowDown, { size: 16 }),
3352
3402
  /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { children: "Move down" })
3353
3403
  ]
3354
3404
  }
@@ -3358,7 +3408,7 @@ function BlockActionMenu({ editor, onClose }) {
3358
3408
 
3359
3409
  // src/react/menus/TableMenu.tsx
3360
3410
  var import_react33 = require("@tiptap/react");
3361
- var import_icons_react12 = require("@tabler/icons-react");
3411
+ var import_icons_react13 = require("@tabler/icons-react");
3362
3412
  var import_react34 = require("react");
3363
3413
  var import_react_dom2 = require("react-dom");
3364
3414
  var import_jsx_runtime20 = require("react/jsx-runtime");
@@ -3643,7 +3693,7 @@ function TableMenu({ className: _className }) {
3643
3693
  const columnDropdownItems = [
3644
3694
  {
3645
3695
  label: "Toggle header column",
3646
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconTableColumn, { size: 16 }),
3696
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconTableColumn, { size: 16 }),
3647
3697
  action: () => {
3648
3698
  editor.chain().focus().toggleHeaderColumn().run();
3649
3699
  setDropdown(null);
@@ -3651,7 +3701,7 @@ function TableMenu({ className: _className }) {
3651
3701
  },
3652
3702
  {
3653
3703
  label: "Insert column before",
3654
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconColumnInsertLeft, { size: 16 }),
3704
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconColumnInsertLeft, { size: 16 }),
3655
3705
  action: () => {
3656
3706
  editor.chain().focus().addColumnBefore().run();
3657
3707
  setDropdown(null);
@@ -3660,7 +3710,7 @@ function TableMenu({ className: _className }) {
3660
3710
  },
3661
3711
  {
3662
3712
  label: "Insert column after",
3663
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconColumnInsertRight, { size: 16 }),
3713
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconColumnInsertRight, { size: 16 }),
3664
3714
  action: () => {
3665
3715
  editor.chain().focus().addColumnAfter().run();
3666
3716
  setDropdown(null);
@@ -3668,7 +3718,7 @@ function TableMenu({ className: _className }) {
3668
3718
  },
3669
3719
  {
3670
3720
  label: "Merge cells",
3671
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconArrowMerge, { size: 16 }),
3721
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconArrowMerge, { size: 16 }),
3672
3722
  action: () => {
3673
3723
  editor.chain().focus().mergeCells().run();
3674
3724
  setDropdown(null);
@@ -3677,7 +3727,7 @@ function TableMenu({ className: _className }) {
3677
3727
  },
3678
3728
  {
3679
3729
  label: "Split cell",
3680
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconArrowsSplit, { size: 16 }),
3730
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconArrowsSplit, { size: 16 }),
3681
3731
  action: () => {
3682
3732
  editor.chain().focus().splitCell().run();
3683
3733
  setDropdown(null);
@@ -3685,7 +3735,7 @@ function TableMenu({ className: _className }) {
3685
3735
  },
3686
3736
  {
3687
3737
  label: "Delete column",
3688
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconColumnRemove, { size: 16 }),
3738
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconColumnRemove, { size: 16 }),
3689
3739
  action: () => {
3690
3740
  editor.chain().focus().deleteColumn().run();
3691
3741
  setDropdown(null);
@@ -3697,7 +3747,7 @@ function TableMenu({ className: _className }) {
3697
3747
  const rowDropdownItems = [
3698
3748
  {
3699
3749
  label: "Toggle header row",
3700
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconTableRow, { size: 16 }),
3750
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconTableRow, { size: 16 }),
3701
3751
  action: () => {
3702
3752
  editor.chain().focus().toggleHeaderRow().run();
3703
3753
  setDropdown(null);
@@ -3705,7 +3755,7 @@ function TableMenu({ className: _className }) {
3705
3755
  },
3706
3756
  {
3707
3757
  label: "Insert row above",
3708
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconRowInsertTop, { size: 16 }),
3758
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconRowInsertTop, { size: 16 }),
3709
3759
  action: () => {
3710
3760
  editor.chain().focus().addRowBefore().run();
3711
3761
  setDropdown(null);
@@ -3714,7 +3764,7 @@ function TableMenu({ className: _className }) {
3714
3764
  },
3715
3765
  {
3716
3766
  label: "Insert row below",
3717
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconRowInsertBottom, { size: 16 }),
3767
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconRowInsertBottom, { size: 16 }),
3718
3768
  action: () => {
3719
3769
  editor.chain().focus().addRowAfter().run();
3720
3770
  setDropdown(null);
@@ -3722,7 +3772,7 @@ function TableMenu({ className: _className }) {
3722
3772
  },
3723
3773
  {
3724
3774
  label: "Merge cells",
3725
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconArrowMerge, { size: 16 }),
3775
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconArrowMerge, { size: 16 }),
3726
3776
  action: () => {
3727
3777
  editor.chain().focus().mergeCells().run();
3728
3778
  setDropdown(null);
@@ -3731,7 +3781,7 @@ function TableMenu({ className: _className }) {
3731
3781
  },
3732
3782
  {
3733
3783
  label: "Split cell",
3734
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconArrowsSplit, { size: 16 }),
3784
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconArrowsSplit, { size: 16 }),
3735
3785
  action: () => {
3736
3786
  editor.chain().focus().splitCell().run();
3737
3787
  setDropdown(null);
@@ -3739,7 +3789,7 @@ function TableMenu({ className: _className }) {
3739
3789
  },
3740
3790
  {
3741
3791
  label: "Delete row",
3742
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconRowRemove, { size: 16 }),
3792
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconRowRemove, { size: 16 }),
3743
3793
  action: () => {
3744
3794
  editor.chain().focus().deleteRow().run();
3745
3795
  setDropdown(null);
@@ -3767,7 +3817,7 @@ function TableMenu({ className: _className }) {
3767
3817
  onMouseDown: (e) => handleGripDragStart("column", i, e),
3768
3818
  onClick: (e) => handleColGripClick(i, e),
3769
3819
  "aria-label": `Column ${i + 1} options`,
3770
- children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconGripHorizontal, { size: 14 })
3820
+ children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconGripHorizontal, { size: 14 })
3771
3821
  },
3772
3822
  `col-${i}`
3773
3823
  )),
@@ -3787,7 +3837,7 @@ function TableMenu({ className: _className }) {
3787
3837
  onMouseDown: (e) => handleGripDragStart("row", i, e),
3788
3838
  onClick: (e) => handleRowGripClick(i, e),
3789
3839
  "aria-label": `Row ${i + 1} options`,
3790
- children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconGripVertical, { size: 14 })
3840
+ children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconGripVertical, { size: 14 })
3791
3841
  },
3792
3842
  `row-${i}`
3793
3843
  )),
@@ -3809,7 +3859,7 @@ function TableMenu({ className: _className }) {
3809
3859
  },
3810
3860
  "aria-label": "Delete table",
3811
3861
  children: [
3812
- /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconTableOff, { size: 14 }),
3862
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconTableOff, { size: 14 }),
3813
3863
  /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("span", { style: { fontSize: 12 }, children: "Delete table" })
3814
3864
  ]
3815
3865
  }