neuphlo-editor 2.2.0 → 2.3.1

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.
@@ -1359,7 +1359,6 @@ var VideoBlock = import_core5.Node.create({
1359
1359
  };
1360
1360
  },
1361
1361
  addNodeView() {
1362
- console.log("[VideoBlock] addNodeView called, options:", Object.keys(this.options), "hasNodeView:", !!this.options.nodeView);
1363
1362
  if (this.options.nodeView) {
1364
1363
  return (0, import_react11.ReactNodeViewRenderer)(this.options.nodeView);
1365
1364
  }
@@ -3165,18 +3164,23 @@ var VideoBlockView = (props) => {
3165
3164
  };
3166
3165
  if (!src || src === "") {
3167
3166
  if (!editor.isEditable) return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react30.NodeViewWrapper, {});
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: [
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 }) }),
3170
- /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "nph-video-input__content", children: [
3167
+ 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: [
3168
+ /* @__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 }) }),
3169
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { style: { display: "flex", flexDirection: "column", alignItems: "center", gap: "2px" }, children: [
3170
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { style: { fontSize: "14px", fontWeight: 600, lineHeight: "20px" }, children: "Add a video" }),
3171
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { style: { fontSize: "13px", opacity: 0.5, lineHeight: "18px" }, children: "Paste a URL to embed" })
3172
+ ] }),
3173
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "nph-video-placeholder__input", children: [
3171
3174
  /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
3172
3175
  "input",
3173
3176
  {
3174
3177
  type: "text",
3175
3178
  className: "nph-video-input__field",
3176
- placeholder: "Paste a YouTube, Vimeo, or video URL...",
3179
+ placeholder: "YouTube, Vimeo, or Loom URL...",
3177
3180
  value: inputUrl,
3178
3181
  onChange: (e) => setInputUrl(e.target.value),
3179
- onKeyDown: handleKeyDown
3182
+ onKeyDown: handleKeyDown,
3183
+ onClick: (e) => e.stopPropagation()
3180
3184
  }
3181
3185
  ),
3182
3186
  /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
@@ -3184,7 +3188,10 @@ var VideoBlockView = (props) => {
3184
3188
  {
3185
3189
  type: "button",
3186
3190
  className: "nph-video-input__button",
3187
- onClick: handleEmbed,
3191
+ onClick: (e) => {
3192
+ e.stopPropagation();
3193
+ handleEmbed();
3194
+ },
3188
3195
  disabled: !inputUrl.trim(),
3189
3196
  children: "Embed"
3190
3197
  }