neuphlo-editor 2.1.0 → 2.2.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,7 +312,6 @@ var ImageBlock = import_extension_image.Image.extend({
312
312
  addOptions() {
313
313
  return {
314
314
  ...this.parent?.(),
315
- uploadImage: void 0,
316
315
  inline: false
317
316
  };
318
317
  },
@@ -1360,10 +1359,11 @@ var VideoBlock = import_core5.Node.create({
1360
1359
  };
1361
1360
  },
1362
1361
  addNodeView() {
1362
+ console.log("[VideoBlock] addNodeView called, options:", Object.keys(this.options), "hasNodeView:", !!this.options.nodeView);
1363
1363
  if (this.options.nodeView) {
1364
1364
  return (0, import_react11.ReactNodeViewRenderer)(this.options.nodeView);
1365
1365
  }
1366
- return null;
1366
+ return void 0;
1367
1367
  }
1368
1368
  });
1369
1369
 
@@ -2485,6 +2485,7 @@ function ImageMenu({
2485
2485
  // src/react/menus/ImageBlock/ImageBlockView.tsx
2486
2486
  var import_react26 = require("@tiptap/react");
2487
2487
  var import_react27 = require("react");
2488
+ var import_icons_react9 = require("@tabler/icons-react");
2488
2489
 
2489
2490
  // src/react/menus/ImageBlock/ImageBlockMenu.tsx
2490
2491
  var import_state6 = require("@tiptap/pm/state");
@@ -2563,6 +2564,7 @@ var ImageBlockMenu = ({ editor, getPos, appendTo }) => {
2563
2564
  const { state } = ctx.editor;
2564
2565
  const { selection } = state;
2565
2566
  if (!ctx.editor.isEditable) return { isVisible: false, align: "center", width: 100 };
2567
+ if (!ctx.editor.isFocused) return { isVisible: false, align: "center", width: 100 };
2566
2568
  const isNodeSel = selection instanceof import_state6.NodeSelection;
2567
2569
  const isThisNode = isNodeSel && selection.from === getPos();
2568
2570
  const visible = isThisNode;
@@ -2756,6 +2758,31 @@ var ImageUploader = ({ onUpload, editor }) => {
2756
2758
  if (loading) {
2757
2759
  return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ImageBlockLoading, {});
2758
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
+ }
2759
2786
  return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
2760
2787
  "div",
2761
2788
  {
@@ -2768,34 +2795,19 @@ var ImageUploader = ({ onUpload, editor }) => {
2768
2795
  /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_icons_react8.IconPhoto, { size: 48, className: "nph-image-uploader__icon" }),
2769
2796
  /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { className: "nph-image-uploader__content", children: [
2770
2797
  /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { className: "nph-image-uploader__text", children: draggedInside ? "Drop image here" : "Drag and drop or" }),
2771
- /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { className: "nph-image-uploader__actions", children: [
2772
- /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
2773
- "button",
2774
- {
2775
- type: "button",
2776
- disabled: draggedInside,
2777
- onClick: handleUploadClick,
2778
- className: "nph-btn nph-btn-ghost nph-btn-sm nph-image-uploader__button",
2779
- children: [
2780
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_icons_react8.IconUpload, { size: 16 }),
2781
- "Upload an image"
2782
- ]
2783
- }
2784
- ),
2785
- browseAssets && /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
2786
- "button",
2787
- {
2788
- type: "button",
2789
- disabled: draggedInside,
2790
- onClick: () => browseAssets(onUpload),
2791
- className: "nph-btn nph-btn-ghost nph-btn-sm nph-image-uploader__button",
2792
- children: [
2793
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_icons_react8.IconPhoto, { size: 16 }),
2794
- "Browse assets"
2795
- ]
2796
- }
2797
- )
2798
- ] })
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
+ ) })
2799
2811
  ] }),
2800
2812
  /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
2801
2813
  "input",
@@ -2883,6 +2895,7 @@ var import_jsx_runtime16 = require("react/jsx-runtime");
2883
2895
  var ImageBlockView = (props) => {
2884
2896
  const { editor, getPos, node, updateAttributes } = props;
2885
2897
  const imageWrapperRef = (0, import_react27.useRef)(null);
2898
+ const [imageError, setImageError] = (0, import_react27.useState)(false);
2886
2899
  const { src, width, align, alt, loading } = node.attrs;
2887
2900
  const handleUpload = (0, import_react27.useCallback)(
2888
2901
  (url) => {
@@ -2922,6 +2935,15 @@ var ImageBlockView = (props) => {
2922
2935
  if (loading) {
2923
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, {}) }) });
2924
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
+ }
2925
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: [
2926
2948
  editor.isEditable ? /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(ImageResizeHandle, { onResize: handleResize, currentWidth: width, children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
2927
2949
  "img",
@@ -2929,6 +2951,7 @@ var ImageBlockView = (props) => {
2929
2951
  src,
2930
2952
  alt: alt || "",
2931
2953
  onClick,
2954
+ onError: () => setImageError(true),
2932
2955
  className: "nph-image-block"
2933
2956
  }
2934
2957
  ) }) : /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
@@ -2936,6 +2959,7 @@ var ImageBlockView = (props) => {
2936
2959
  {
2937
2960
  src,
2938
2961
  alt: alt || "",
2962
+ onError: () => setImageError(true),
2939
2963
  className: "nph-image-block"
2940
2964
  }
2941
2965
  ),
@@ -2952,7 +2976,7 @@ var import_react31 = require("react");
2952
2976
  var import_state7 = require("@tiptap/pm/state");
2953
2977
  var import_react28 = require("@tiptap/react");
2954
2978
  var import_react29 = require("react");
2955
- var import_icons_react9 = require("@tabler/icons-react");
2979
+ var import_icons_react10 = require("@tabler/icons-react");
2956
2980
  var import_jsx_runtime17 = require("react/jsx-runtime");
2957
2981
  var VideoBlockMenu = ({ editor, getPos }) => {
2958
2982
  const menuRef = (0, import_react29.useRef)(null);
@@ -3016,7 +3040,7 @@ var VideoBlockMenu = ({ editor, getPos }) => {
3016
3040
  title: "Align left",
3017
3041
  onMouseDown: (e) => e.preventDefault(),
3018
3042
  onClick: onAlignLeft,
3019
- 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 })
3020
3044
  }
3021
3045
  ),
3022
3046
  /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
@@ -3027,7 +3051,7 @@ var VideoBlockMenu = ({ editor, getPos }) => {
3027
3051
  title: "Align center",
3028
3052
  onMouseDown: (e) => e.preventDefault(),
3029
3053
  onClick: onAlignCenter,
3030
- 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 })
3031
3055
  }
3032
3056
  ),
3033
3057
  /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
@@ -3038,7 +3062,7 @@ var VideoBlockMenu = ({ editor, getPos }) => {
3038
3062
  title: "Align right",
3039
3063
  onMouseDown: (e) => e.preventDefault(),
3040
3064
  onClick: onAlignRight,
3041
- 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 })
3042
3066
  }
3043
3067
  ),
3044
3068
  /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
@@ -3064,7 +3088,7 @@ var VideoBlockMenu = ({ editor, getPos }) => {
3064
3088
  title: "Remove video",
3065
3089
  onMouseDown: (e) => e.preventDefault(),
3066
3090
  onClick: onRemove,
3067
- 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 })
3068
3092
  }
3069
3093
  )
3070
3094
  ]
@@ -3073,19 +3097,26 @@ var VideoBlockMenu = ({ editor, getPos }) => {
3073
3097
  };
3074
3098
 
3075
3099
  // src/react/menus/VideoBlock/VideoBlockView.tsx
3076
- var import_icons_react10 = require("@tabler/icons-react");
3100
+ var import_icons_react11 = require("@tabler/icons-react");
3077
3101
  var import_jsx_runtime18 = require("react/jsx-runtime");
3078
3102
  function toEmbedUrl(url) {
3103
+ if (url.includes("/embed/") || url.includes("player.vimeo.com") || url.includes("loom.com/embed")) {
3104
+ return url;
3105
+ }
3079
3106
  const ytMatch = url.match(
3080
- /(?:youtube\.com\/watch\?v=|youtu\.be\/)([\w-]+)/
3107
+ /(?:youtube\.com\/(?:watch\?v=|shorts\/)|youtu\.be\/)([\w-]+)/
3081
3108
  );
3082
3109
  if (ytMatch) {
3083
3110
  return `https://www.youtube.com/embed/${ytMatch[1]}`;
3084
3111
  }
3085
- const vimeoMatch = url.match(/vimeo\.com\/(\d+)/);
3112
+ const vimeoMatch = url.match(/vimeo\.com\/(?:channels\/[\w-]+\/)?(\d+)/);
3086
3113
  if (vimeoMatch) {
3087
3114
  return `https://player.vimeo.com/video/${vimeoMatch[1]}`;
3088
3115
  }
3116
+ const loomMatch = url.match(/loom\.com\/share\/([\w-]+)/);
3117
+ if (loomMatch) {
3118
+ return `https://www.loom.com/embed/${loomMatch[1]}`;
3119
+ }
3089
3120
  return url;
3090
3121
  }
3091
3122
  var VideoBlockView = (props) => {
@@ -3093,6 +3124,7 @@ var VideoBlockView = (props) => {
3093
3124
  const wrapperRef = (0, import_react31.useRef)(null);
3094
3125
  const { src, width, align } = node.attrs;
3095
3126
  const [inputUrl, setInputUrl] = (0, import_react31.useState)("");
3127
+ const [videoError, setVideoError] = (0, import_react31.useState)(false);
3096
3128
  const isSelected = (0, import_react30.useEditorState)({
3097
3129
  editor,
3098
3130
  selector: (ctx) => {
@@ -3120,8 +3152,8 @@ var VideoBlockView = (props) => {
3120
3152
  }, [getPos, editor.commands]);
3121
3153
  const getWrapperStyle = () => {
3122
3154
  const baseStyle = {
3123
- width: "fit-content",
3124
- maxWidth: width || "100%"
3155
+ width: width || "100%",
3156
+ maxWidth: "100%"
3125
3157
  };
3126
3158
  if (align === "left") {
3127
3159
  return { ...baseStyle, marginLeft: 0, marginRight: "auto" };
@@ -3134,7 +3166,7 @@ var VideoBlockView = (props) => {
3134
3166
  if (!src || src === "") {
3135
3167
  if (!editor.isEditable) return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react30.NodeViewWrapper, {});
3136
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-input", children: [
3137
- /* @__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 }) }),
3169
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className: "nph-video-input__icon", children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_icons_react11.IconVideo, { size: 24 }) }),
3138
3170
  /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "nph-video-input__content", children: [
3139
3171
  /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
3140
3172
  "input",
@@ -3160,6 +3192,16 @@ var VideoBlockView = (props) => {
3160
3192
  ] })
3161
3193
  ] }) }) });
3162
3194
  }
3195
+ if (videoError) {
3196
+ 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: [
3197
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "nph-video-block-error", onClick, children: [
3198
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_icons_react11.IconVideoOff, { size: 32 }),
3199
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("span", { children: "Video could not be loaded" }),
3200
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("span", { className: "nph-video-block-error__url", children: src })
3201
+ ] }),
3202
+ editor.isEditable && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(VideoBlockMenu, { editor, getPos })
3203
+ ] }) });
3204
+ }
3163
3205
  return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react30.NodeViewWrapper, { style: getWrapperStyle(), children: /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(
3164
3206
  "div",
3165
3207
  {
@@ -3174,7 +3216,8 @@ var VideoBlockView = (props) => {
3174
3216
  src,
3175
3217
  className: "nph-video-block__iframe",
3176
3218
  allow: "accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",
3177
- allowFullScreen: true
3219
+ allowFullScreen: true,
3220
+ onError: () => setVideoError(true)
3178
3221
  }
3179
3222
  ),
3180
3223
  !isSelected && /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
@@ -3192,7 +3235,7 @@ var VideoBlockView = (props) => {
3192
3235
  };
3193
3236
 
3194
3237
  // src/react/menus/DragHandle/BlockActionMenu.tsx
3195
- var import_icons_react11 = require("@tabler/icons-react");
3238
+ var import_icons_react12 = require("@tabler/icons-react");
3196
3239
  var import_react32 = require("react");
3197
3240
  var import_jsx_runtime19 = require("react/jsx-runtime");
3198
3241
  function BlockActionMenu({ editor, onClose }) {
@@ -3295,7 +3338,7 @@ function BlockActionMenu({ editor, onClose }) {
3295
3338
  onClick: handleDelete,
3296
3339
  onMouseDown: (e) => e.preventDefault(),
3297
3340
  children: [
3298
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react11.IconTrash, { size: 16 }),
3341
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react12.IconTrash, { size: 16 }),
3299
3342
  /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { children: "Delete" })
3300
3343
  ]
3301
3344
  }
@@ -3308,7 +3351,7 @@ function BlockActionMenu({ editor, onClose }) {
3308
3351
  onClick: handleDuplicate,
3309
3352
  onMouseDown: (e) => e.preventDefault(),
3310
3353
  children: [
3311
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react11.IconCopy, { size: 16 }),
3354
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react12.IconCopy, { size: 16 }),
3312
3355
  /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { children: "Duplicate" })
3313
3356
  ]
3314
3357
  }
@@ -3321,7 +3364,7 @@ function BlockActionMenu({ editor, onClose }) {
3321
3364
  onClick: handleCopyToClipboard,
3322
3365
  onMouseDown: (e) => e.preventDefault(),
3323
3366
  children: [
3324
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react11.IconClipboard, { size: 16 }),
3367
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react12.IconClipboard, { size: 16 }),
3325
3368
  /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { children: "Copy to clipboard" })
3326
3369
  ]
3327
3370
  }
@@ -3334,7 +3377,7 @@ function BlockActionMenu({ editor, onClose }) {
3334
3377
  onClick: handleMoveUp,
3335
3378
  onMouseDown: (e) => e.preventDefault(),
3336
3379
  children: [
3337
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react11.IconArrowUp, { size: 16 }),
3380
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react12.IconArrowUp, { size: 16 }),
3338
3381
  /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { children: "Move up" })
3339
3382
  ]
3340
3383
  }
@@ -3347,7 +3390,7 @@ function BlockActionMenu({ editor, onClose }) {
3347
3390
  onClick: handleMoveDown,
3348
3391
  onMouseDown: (e) => e.preventDefault(),
3349
3392
  children: [
3350
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react11.IconArrowDown, { size: 16 }),
3393
+ /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_icons_react12.IconArrowDown, { size: 16 }),
3351
3394
  /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("span", { children: "Move down" })
3352
3395
  ]
3353
3396
  }
@@ -3357,7 +3400,7 @@ function BlockActionMenu({ editor, onClose }) {
3357
3400
 
3358
3401
  // src/react/menus/TableMenu.tsx
3359
3402
  var import_react33 = require("@tiptap/react");
3360
- var import_icons_react12 = require("@tabler/icons-react");
3403
+ var import_icons_react13 = require("@tabler/icons-react");
3361
3404
  var import_react34 = require("react");
3362
3405
  var import_react_dom2 = require("react-dom");
3363
3406
  var import_jsx_runtime20 = require("react/jsx-runtime");
@@ -3642,7 +3685,7 @@ function TableMenu({ className: _className }) {
3642
3685
  const columnDropdownItems = [
3643
3686
  {
3644
3687
  label: "Toggle header column",
3645
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconTableColumn, { size: 16 }),
3688
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconTableColumn, { size: 16 }),
3646
3689
  action: () => {
3647
3690
  editor.chain().focus().toggleHeaderColumn().run();
3648
3691
  setDropdown(null);
@@ -3650,7 +3693,7 @@ function TableMenu({ className: _className }) {
3650
3693
  },
3651
3694
  {
3652
3695
  label: "Insert column before",
3653
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconColumnInsertLeft, { size: 16 }),
3696
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconColumnInsertLeft, { size: 16 }),
3654
3697
  action: () => {
3655
3698
  editor.chain().focus().addColumnBefore().run();
3656
3699
  setDropdown(null);
@@ -3659,7 +3702,7 @@ function TableMenu({ className: _className }) {
3659
3702
  },
3660
3703
  {
3661
3704
  label: "Insert column after",
3662
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconColumnInsertRight, { size: 16 }),
3705
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconColumnInsertRight, { size: 16 }),
3663
3706
  action: () => {
3664
3707
  editor.chain().focus().addColumnAfter().run();
3665
3708
  setDropdown(null);
@@ -3667,7 +3710,7 @@ function TableMenu({ className: _className }) {
3667
3710
  },
3668
3711
  {
3669
3712
  label: "Merge cells",
3670
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconArrowMerge, { size: 16 }),
3713
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconArrowMerge, { size: 16 }),
3671
3714
  action: () => {
3672
3715
  editor.chain().focus().mergeCells().run();
3673
3716
  setDropdown(null);
@@ -3676,7 +3719,7 @@ function TableMenu({ className: _className }) {
3676
3719
  },
3677
3720
  {
3678
3721
  label: "Split cell",
3679
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconArrowsSplit, { size: 16 }),
3722
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconArrowsSplit, { size: 16 }),
3680
3723
  action: () => {
3681
3724
  editor.chain().focus().splitCell().run();
3682
3725
  setDropdown(null);
@@ -3684,7 +3727,7 @@ function TableMenu({ className: _className }) {
3684
3727
  },
3685
3728
  {
3686
3729
  label: "Delete column",
3687
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconColumnRemove, { size: 16 }),
3730
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconColumnRemove, { size: 16 }),
3688
3731
  action: () => {
3689
3732
  editor.chain().focus().deleteColumn().run();
3690
3733
  setDropdown(null);
@@ -3696,7 +3739,7 @@ function TableMenu({ className: _className }) {
3696
3739
  const rowDropdownItems = [
3697
3740
  {
3698
3741
  label: "Toggle header row",
3699
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconTableRow, { size: 16 }),
3742
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconTableRow, { size: 16 }),
3700
3743
  action: () => {
3701
3744
  editor.chain().focus().toggleHeaderRow().run();
3702
3745
  setDropdown(null);
@@ -3704,7 +3747,7 @@ function TableMenu({ className: _className }) {
3704
3747
  },
3705
3748
  {
3706
3749
  label: "Insert row above",
3707
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconRowInsertTop, { size: 16 }),
3750
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconRowInsertTop, { size: 16 }),
3708
3751
  action: () => {
3709
3752
  editor.chain().focus().addRowBefore().run();
3710
3753
  setDropdown(null);
@@ -3713,7 +3756,7 @@ function TableMenu({ className: _className }) {
3713
3756
  },
3714
3757
  {
3715
3758
  label: "Insert row below",
3716
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconRowInsertBottom, { size: 16 }),
3759
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconRowInsertBottom, { size: 16 }),
3717
3760
  action: () => {
3718
3761
  editor.chain().focus().addRowAfter().run();
3719
3762
  setDropdown(null);
@@ -3721,7 +3764,7 @@ function TableMenu({ className: _className }) {
3721
3764
  },
3722
3765
  {
3723
3766
  label: "Merge cells",
3724
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconArrowMerge, { size: 16 }),
3767
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconArrowMerge, { size: 16 }),
3725
3768
  action: () => {
3726
3769
  editor.chain().focus().mergeCells().run();
3727
3770
  setDropdown(null);
@@ -3730,7 +3773,7 @@ function TableMenu({ className: _className }) {
3730
3773
  },
3731
3774
  {
3732
3775
  label: "Split cell",
3733
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconArrowsSplit, { size: 16 }),
3776
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconArrowsSplit, { size: 16 }),
3734
3777
  action: () => {
3735
3778
  editor.chain().focus().splitCell().run();
3736
3779
  setDropdown(null);
@@ -3738,7 +3781,7 @@ function TableMenu({ className: _className }) {
3738
3781
  },
3739
3782
  {
3740
3783
  label: "Delete row",
3741
- icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconRowRemove, { size: 16 }),
3784
+ icon: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconRowRemove, { size: 16 }),
3742
3785
  action: () => {
3743
3786
  editor.chain().focus().deleteRow().run();
3744
3787
  setDropdown(null);
@@ -3766,7 +3809,7 @@ function TableMenu({ className: _className }) {
3766
3809
  onMouseDown: (e) => handleGripDragStart("column", i, e),
3767
3810
  onClick: (e) => handleColGripClick(i, e),
3768
3811
  "aria-label": `Column ${i + 1} options`,
3769
- children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconGripHorizontal, { size: 14 })
3812
+ children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconGripHorizontal, { size: 14 })
3770
3813
  },
3771
3814
  `col-${i}`
3772
3815
  )),
@@ -3786,7 +3829,7 @@ function TableMenu({ className: _className }) {
3786
3829
  onMouseDown: (e) => handleGripDragStart("row", i, e),
3787
3830
  onClick: (e) => handleRowGripClick(i, e),
3788
3831
  "aria-label": `Row ${i + 1} options`,
3789
- children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconGripVertical, { size: 14 })
3832
+ children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconGripVertical, { size: 14 })
3790
3833
  },
3791
3834
  `row-${i}`
3792
3835
  )),
@@ -3808,7 +3851,7 @@ function TableMenu({ className: _className }) {
3808
3851
  },
3809
3852
  "aria-label": "Delete table",
3810
3853
  children: [
3811
- /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react12.IconTableOff, { size: 14 }),
3854
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_icons_react13.IconTableOff, { size: 14 }),
3812
3855
  /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("span", { style: { fontSize: 12 }, children: "Delete table" })
3813
3856
  ]
3814
3857
  }