@bigbinary/neeto-editor 1.47.40 → 1.47.42

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.
Files changed (40) hide show
  1. package/dist/Editor.js +12 -4
  2. package/dist/Editor.js.map +1 -1
  3. package/dist/cjs/Editor.cjs.js +12 -4
  4. package/dist/cjs/Editor.cjs.js.map +1 -1
  5. package/dist/editor-stats.html +1 -1
  6. package/package.json +3 -1
  7. package/src/translations/ar.json +2 -1
  8. package/src/translations/bg.json +2 -1
  9. package/src/translations/ca.json +2 -1
  10. package/src/translations/cs.json +2 -1
  11. package/src/translations/da.json +2 -1
  12. package/src/translations/de.json +2 -1
  13. package/src/translations/en.json +1 -0
  14. package/src/translations/es-MX.json +2 -1
  15. package/src/translations/es.json +2 -1
  16. package/src/translations/et.json +2 -1
  17. package/src/translations/fi.json +2 -1
  18. package/src/translations/fil.json +2 -1
  19. package/src/translations/fr.json +2 -1
  20. package/src/translations/hi.json +2 -1
  21. package/src/translations/hr.json +2 -1
  22. package/src/translations/id.json +2 -1
  23. package/src/translations/it.json +2 -1
  24. package/src/translations/ja.json +2 -1
  25. package/src/translations/ko.json +2 -1
  26. package/src/translations/nl.json +2 -1
  27. package/src/translations/pl.json +2 -1
  28. package/src/translations/pt-BR.json +2 -1
  29. package/src/translations/pt.json +2 -1
  30. package/src/translations/ro.json +2 -1
  31. package/src/translations/ru.json +2 -1
  32. package/src/translations/sk.json +2 -1
  33. package/src/translations/sl.json +2 -1
  34. package/src/translations/sv.json +2 -1
  35. package/src/translations/th.json +2 -1
  36. package/src/translations/tr.json +2 -1
  37. package/src/translations/uk.json +2 -1
  38. package/src/translations/vi.json +2 -1
  39. package/src/translations/zh-CN.json +2 -1
  40. package/src/translations/zh-TW.json +2 -1
@@ -13418,6 +13418,7 @@ var Placeholder = Menu$3.Extension.create({
13418
13418
  emptyEditorClass: "is-editor-empty",
13419
13419
  emptyNodeClass: "is-empty",
13420
13420
  placeholder: i18n.t("neetoEditor.placeholders.writeSomething"),
13421
+ slashCommandsPlaceholder: i18n.t("neetoEditor.placeholders.writeSlashForCommands"),
13421
13422
  showOnlyWhenEditable: true,
13422
13423
  showOnlyCurrent: false,
13423
13424
  includeChildren: false
@@ -13442,12 +13443,16 @@ var Placeholder = Menu$3.Extension.create({
13442
13443
  var isExcluded = _this.options.excludeNodeTypes.includes(node.type.name);
13443
13444
  if ((hasAnchor || !_this.options.showOnlyCurrent) && !isExcluded && isEmpty) {
13444
13445
  var classes = [_this.options.emptyNodeClass];
13446
+ var placeholderText = _this.options.placeholder;
13445
13447
  if (_this.editor.isEmpty) {
13446
13448
  classes.push(_this.options.emptyEditorClass);
13449
+ if (_this.options.isSlashCommandsActive && !_this.options.placeholder) {
13450
+ placeholderText = _this.options.slashCommandsPlaceholder;
13451
+ }
13447
13452
  }
13448
13453
  var decoration = Menu$3.Decoration.node(pos, pos + node.nodeSize, {
13449
13454
  "class": classes.join(" "),
13450
- "data-placeholder": _this.options.placeholder
13455
+ "data-placeholder": placeholderText
13451
13456
  });
13452
13457
  decorations.push(decoration);
13453
13458
  }
@@ -19463,7 +19468,9 @@ var EmbedComponent = function EmbedComponent(_ref) {
19463
19468
  deleteNode: deleteNode,
19464
19469
  editor: editor,
19465
19470
  updateAttributes: updateAttributes
19466
- }), /*#__PURE__*/jsxRuntime.jsx("iframe", _objectSpread$2({}, node.attrs))]
19471
+ }), /*#__PURE__*/jsxRuntime.jsx("iframe", _objectSpread$2(_objectSpread$2({}, node.attrs), {}, {
19472
+ allowFullScreen: true
19473
+ }))]
19467
19474
  })
19468
19475
  });
19469
19476
  };
@@ -19722,7 +19729,8 @@ var useCustomExtensions = function useCustomExtensions(_ref) {
19722
19729
  target: openLinkInNewTab ? "_blank" : null
19723
19730
  }
19724
19731
  }), Placeholder.configure({
19725
- placeholder: placeholder
19732
+ placeholder: placeholder,
19733
+ isSlashCommandsActive: isSlashCommandsActive
19726
19734
  }), StarterKit.configure({
19727
19735
  document: false,
19728
19736
  codeBlock: false,
@@ -20239,7 +20247,7 @@ var Editor = function Editor(_ref, ref) {
20239
20247
  var isFixedMenuActive = menuType === "fixed";
20240
20248
  var isBubbleMenuActive = menuType === "bubble";
20241
20249
  var isSlashCommandsActive = !hideSlashCommands || isBubbleMenuActive && !hideSlashCommands;
20242
- var isPlaceholderActive = !!placeholder;
20250
+ var isPlaceholderActive = !!placeholder || isSlashCommandsActive;
20243
20251
  var _useState3 = React.useState(false),
20244
20252
  _useState4 = _slicedToArray(_useState3, 2),
20245
20253
  isAddLinkActive = _useState4[0],