@uxf/wysiwyg 10.0.0-beta.9 → 10.0.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.
Files changed (100) hide show
  1. package/create-all-plugins-with-ui.d.ts +9 -1
  2. package/create-all-plugins-with-ui.js +14 -12
  3. package/create-plugins-with-ui.js +1 -1
  4. package/index.d.ts +3 -3
  5. package/index.js +11 -9
  6. package/package.json +32 -30
  7. package/plugins/{block-quote/create-block-quote-plugin.js → blockquote/create-blockquote-plugin.js} +2 -2
  8. package/plugins/blockquote/types.d.ts +2 -0
  9. package/plugins/blockquote/types.js +6 -0
  10. package/plugins/button/index.d.ts +1 -1
  11. package/plugins/button/index.js +3 -3
  12. package/plugins/button/transforms/index.d.ts +1 -1
  13. package/plugins/button/transforms/index.js +3 -3
  14. package/plugins/embedded/utils.d.ts +1 -1
  15. package/plugins/embedded/utils.js +2 -2
  16. package/plugins/embedded/video/insert-video.js +1 -1
  17. package/plugins/exit-break/create-exit-break-plugin.js +2 -2
  18. package/plugins/image/transforms/insert-image.js +1 -1
  19. package/plugins/image/transforms/remove-selected-image.js +1 -1
  20. package/plugins/link/hooks/index.d.ts +1 -1
  21. package/plugins/link/hooks/index.js +3 -3
  22. package/plugins/link/transforms/insert-link.js +1 -1
  23. package/plugins/link/transforms/submit-link.js +1 -1
  24. package/plugins/list/constants.d.ts +1 -1
  25. package/plugins/list/constants.js +3 -3
  26. package/plugins/reset-node/create-reset-node.js +2 -2
  27. package/plugins/soft-break/create-soft-break-plugin.js +2 -2
  28. package/styles/styles.css +259 -0
  29. package/translations/context.d.ts +3 -0
  30. package/translations/context.js +9 -0
  31. package/translations/cs.d.ts +51 -0
  32. package/translations/cs.js +54 -0
  33. package/translations/en.d.ts +2 -0
  34. package/translations/en.js +54 -0
  35. package/translations/sk.d.ts +2 -0
  36. package/translations/sk.js +54 -0
  37. package/translations/translations.d.ts +5 -0
  38. package/translations/translations.js +6 -0
  39. package/types.d.ts +2 -2
  40. package/ui/blockquote-element.d.ts +2 -0
  41. package/ui/{block-quote-element.js → blockquote-element.js} +6 -5
  42. package/ui/bold-mark.js +3 -1
  43. package/ui/button/button-element.js +15 -14
  44. package/ui/button/insert-button-modal-content.js +24 -16
  45. package/ui/code-mark.js +3 -1
  46. package/ui/components/element/element-action-buttons.d.ts +1 -0
  47. package/ui/components/element/element-action-buttons.js +8 -7
  48. package/ui/components/element/element-with-action-buttons.d.ts +1 -0
  49. package/ui/components/element/element-with-action-buttons.js +7 -5
  50. package/ui/components/modal/modal-button-cancel.js +8 -5
  51. package/ui/components/modal/modal-button-submit.d.ts +0 -1
  52. package/ui/components/modal/modal-button-submit.js +2 -3
  53. package/ui/components/modal/modal-buttons.d.ts +1 -1
  54. package/ui/components/modal/modal-buttons.js +5 -5
  55. package/ui/components/modal/modal-content.js +5 -5
  56. package/ui/create-uxf-ui.js +3 -3
  57. package/ui/floating-link.js +47 -21
  58. package/ui/heading-elements.js +13 -6
  59. package/ui/highlight-mark.d.ts +1 -1
  60. package/ui/highlight-mark.js +3 -1
  61. package/ui/image/image-element.js +7 -5
  62. package/ui/image/insert-image-modal-content.js +28 -23
  63. package/ui/italic-mark.js +3 -1
  64. package/ui/link-element.js +3 -1
  65. package/ui/list-item-element.js +3 -1
  66. package/ui/list-ordered-element.js +3 -1
  67. package/ui/list-unordered-element.js +3 -1
  68. package/ui/paragraph-element.js +3 -1
  69. package/ui/toolbar/buttons/button-toolbar-button.d.ts +1 -0
  70. package/ui/toolbar/buttons/button-toolbar-button.js +8 -5
  71. package/ui/toolbar/buttons/element-toolbar-button.d.ts +1 -0
  72. package/ui/toolbar/buttons/element-toolbar-button.js +3 -1
  73. package/ui/toolbar/buttons/image-toolbar-button.d.ts +1 -0
  74. package/ui/toolbar/buttons/image-toolbar-button.js +7 -4
  75. package/ui/toolbar/buttons/link-toolbar-button.d.ts +1 -0
  76. package/ui/toolbar/buttons/link-toolbar-button.js +8 -5
  77. package/ui/toolbar/buttons/list-toolbar-button.d.ts +3 -1
  78. package/ui/toolbar/buttons/list-toolbar-button.js +3 -1
  79. package/ui/toolbar/buttons/mark-toolbar-button.d.ts +1 -0
  80. package/ui/toolbar/buttons/mark-toolbar-button.js +3 -2
  81. package/ui/toolbar/buttons/modal-toolbar-button.d.ts +2 -1
  82. package/ui/toolbar/buttons/modal-toolbar-button.js +7 -5
  83. package/ui/toolbar/buttons/toolbar-button.d.ts +2 -1
  84. package/ui/toolbar/buttons/toolbar-button.js +10 -8
  85. package/ui/toolbar/buttons/undo-redo-button-group.d.ts +6 -2
  86. package/ui/toolbar/buttons/undo-redo-button-group.js +15 -11
  87. package/ui/toolbar/buttons/video-toolbar-button.d.ts +1 -0
  88. package/ui/toolbar/buttons/video-toolbar-button.js +8 -5
  89. package/ui/toolbar/toolbar.js +47 -41
  90. package/ui/underline-mark.js +3 -1
  91. package/ui/video/insert-video-modal-content.js +13 -6
  92. package/ui/video/video-element.js +11 -7
  93. package/utils.d.ts +2 -2
  94. package/utils.js +8 -6
  95. package/wysiwyg-editor.d.ts +3 -0
  96. package/wysiwyg-editor.js +19 -6
  97. package/plugins/block-quote/types.d.ts +0 -2
  98. package/plugins/block-quote/types.js +0 -6
  99. package/ui/block-quote-element.d.ts +0 -2
  100. /package/plugins/{block-quote/create-block-quote-plugin.d.ts → blockquote/create-blockquote-plugin.d.ts} +0 -0
@@ -1,7 +1,7 @@
1
+ import { CSSProperties } from "react";
1
2
  import { HeadingsPluginOptions } from "./plugins/heading/create-headings-plugin";
2
3
  import { UxfImagePluginOptions } from "./plugins/image/types";
3
4
  import { ElementUiComponent } from "./types";
4
- import { CSSProperties } from "react";
5
5
  export declare const createHeadingsPluginWithUi: (options?: HeadingsPluginOptions) => {
6
6
  plugin: import("@udecode/plate-core").PlatePlugin<HeadingsPluginOptions, import("./types").WysiwygContent, import("@udecode/plate-core").PlateEditor<import("./types").WysiwygContent>>;
7
7
  components: {
@@ -40,6 +40,10 @@ export declare const createListPluginWithUi: () => {
40
40
  li: ElementUiComponent;
41
41
  };
42
42
  };
43
+ export declare const createLinkPluginWithUi: () => {
44
+ plugin: import("@udecode/plate-core").PlatePlugin<import("@udecode/plate-link").LinkPlugin, import("./types").WysiwygContent, import("./types").UxfEditor>;
45
+ component: ElementUiComponent<import("./plugins/link/types").TLinkElement>;
46
+ };
43
47
  export declare const createImagePluginWithUi: (options: UxfImagePluginOptions) => {
44
48
  plugin: import("@udecode/plate-core").PlatePlugin<UxfImagePluginOptions, import("./types").WysiwygContent, import("@udecode/plate-core").PlateEditor<import("./types").WysiwygContent>>;
45
49
  component: ElementUiComponent<import("./types").UxfImageElement>;
@@ -48,6 +52,10 @@ export declare const createVideoPluginWithUi: () => {
48
52
  plugin: import("@udecode/plate-core").PlatePlugin<import("@udecode/plate-media").MediaPlugin, import("./types").WysiwygContent, import("@udecode/plate-core").PlateEditor<import("./types").WysiwygContent>>;
49
53
  component: ElementUiComponent<import("./types").UxfVideoElement>;
50
54
  };
55
+ export declare const createButtonPluginWithUi: () => {
56
+ plugin: import("@udecode/plate-core").PlatePlugin<import("@udecode/utils").AnyObject, import("./types").WysiwygContent, import("@udecode/plate-core").PlateEditor<import("./types").WysiwygContent>>;
57
+ component: ElementUiComponent<import("./types").UxfButtonElement>;
58
+ };
51
59
  export interface CreateAllPluginsOptions {
52
60
  image: UxfImagePluginOptions;
53
61
  headings?: HeadingsPluginOptions;
@@ -1,11 +1,14 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.createAllPluginsWithUi = exports.createVideoPluginWithUi = exports.createImagePluginWithUi = exports.createListPluginWithUi = exports.createCodePluginWithUi = exports.createUnderlinePluginWithUi = exports.createItalicPluginWithUi = exports.createHighlightPluginWithUi = exports.createBoldPluginWithUi = exports.createBlockQuotePluginWithUi = exports.createHeadingsPluginWithUi = void 0;
3
+ exports.createAllPluginsWithUi = exports.createButtonPluginWithUi = exports.createVideoPluginWithUi = exports.createImagePluginWithUi = exports.createLinkPluginWithUi = exports.createListPluginWithUi = exports.createCodePluginWithUi = exports.createUnderlinePluginWithUi = exports.createItalicPluginWithUi = exports.createHighlightPluginWithUi = exports.createBoldPluginWithUi = exports.createBlockQuotePluginWithUi = exports.createHeadingsPluginWithUi = void 0;
4
+ const tw_colors_1 = require("@uxf/ui/tw-tokens/tw-colors");
4
5
  const create_plugins_with_ui_1 = require("./create-plugins-with-ui");
5
- const create_block_quote_plugin_1 = require("./plugins/block-quote/create-block-quote-plugin");
6
+ const create_blockquote_plugin_1 = require("./plugins/blockquote/create-blockquote-plugin");
7
+ const button_1 = require("./plugins/button");
6
8
  const create_video_plugin_1 = require("./plugins/embedded/video/create-video-plugin");
7
9
  const constants_1 = require("./plugins/heading/constants");
8
10
  const create_headings_plugin_1 = require("./plugins/heading/create-headings-plugin");
11
+ const createHighlightPlugin_1 = require("./plugins/highlight/createHighlightPlugin");
9
12
  const create_image_plugin_1 = require("./plugins/image/create-image-plugin");
10
13
  const create_link_plugin_1 = require("./plugins/link/create-link-plugin");
11
14
  const create_list_plugin_1 = require("./plugins/list/create-list-plugin");
@@ -13,10 +16,12 @@ const create_bold_plugin_1 = require("./plugins/mark-bold/create-bold-plugin");
13
16
  const create_code_plugin_1 = require("./plugins/mark-code/create-code-plugin");
14
17
  const create_italic_plugin_1 = require("./plugins/mark-italic/create-italic-plugin");
15
18
  const create_underline_plugin_1 = require("./plugins/mark-underline/create-underline-plugin");
16
- const block_quote_element_1 = require("./ui/block-quote-element");
19
+ const blockquote_element_1 = require("./ui/blockquote-element");
17
20
  const bold_mark_1 = require("./ui/bold-mark");
21
+ const button_2 = require("./ui/button");
18
22
  const code_mark_1 = require("./ui/code-mark");
19
23
  const heading_elements_1 = require("./ui/heading-elements");
24
+ const highlight_mark_1 = require("./ui/highlight-mark");
20
25
  const image_element_1 = require("./ui/image/image-element");
21
26
  const italic_mark_1 = require("./ui/italic-mark");
22
27
  const link_element_1 = require("./ui/link-element");
@@ -25,11 +30,6 @@ const list_ordered_element_1 = require("./ui/list-ordered-element");
25
30
  const list_unordered_element_1 = require("./ui/list-unordered-element");
26
31
  const underline_mark_1 = require("./ui/underline-mark");
27
32
  const video_element_1 = require("./ui/video/video-element");
28
- const button_1 = require("./plugins/button");
29
- const button_2 = require("./ui/button");
30
- const createHighlightPlugin_1 = require("./plugins/highlight/createHighlightPlugin");
31
- const highlight_mark_1 = require("./ui/highlight-mark");
32
- const tw_colors_1 = require("@uxf/ui/tw-tokens/tw-colors");
33
33
  const createHeadingsPluginWithUi = (options) => {
34
34
  var _a;
35
35
  const disabledLevels = (_a = options === null || options === void 0 ? void 0 : options.disabledLevels) !== null && _a !== void 0 ? _a : [];
@@ -49,8 +49,8 @@ const createHeadingsPluginWithUi = (options) => {
49
49
  };
50
50
  exports.createHeadingsPluginWithUi = createHeadingsPluginWithUi;
51
51
  const createBlockQuotePluginWithUi = () => ({
52
- plugin: (0, create_block_quote_plugin_1.createBlockquotePlugin)(),
53
- component: block_quote_element_1.BlockQuoteElement,
52
+ plugin: (0, create_blockquote_plugin_1.createBlockquotePlugin)(),
53
+ component: blockquote_element_1.BlockquoteElement,
54
54
  });
55
55
  exports.createBlockQuotePluginWithUi = createBlockQuotePluginWithUi;
56
56
  const createBoldPluginWithUi = () => ({
@@ -91,6 +91,7 @@ const createLinkPluginWithUi = () => ({
91
91
  plugin: (0, create_link_plugin_1.createLinkPlugin)(),
92
92
  component: link_element_1.LinkElement,
93
93
  });
94
+ exports.createLinkPluginWithUi = createLinkPluginWithUi;
94
95
  const createImagePluginWithUi = (options) => ({
95
96
  plugin: (0, create_image_plugin_1.createImagePlugin)({
96
97
  options,
@@ -107,6 +108,7 @@ const createButtonPluginWithUi = () => ({
107
108
  plugin: (0, button_1.createButtonPlugin)(),
108
109
  component: button_2.ButtonElement,
109
110
  });
111
+ exports.createButtonPluginWithUi = createButtonPluginWithUi;
110
112
  const createAllPluginsWithUi = (options) => (0, create_plugins_with_ui_1.createPluginsWithUi)([
111
113
  (0, exports.createHeadingsPluginWithUi)(options.headings),
112
114
  (0, exports.createBlockQuotePluginWithUi)(),
@@ -115,10 +117,10 @@ const createAllPluginsWithUi = (options) => (0, create_plugins_with_ui_1.createP
115
117
  (0, exports.createUnderlinePluginWithUi)(),
116
118
  (0, exports.createCodePluginWithUi)(),
117
119
  (0, exports.createListPluginWithUi)(),
118
- createLinkPluginWithUi(),
120
+ (0, exports.createLinkPluginWithUi)(),
119
121
  (0, exports.createImagePluginWithUi)(options.image),
120
122
  (0, exports.createVideoPluginWithUi)(),
121
- createButtonPluginWithUi(),
123
+ (0, exports.createButtonPluginWithUi)(),
122
124
  (0, exports.createHighlightPluginWithUi)(options.highlightColor),
123
125
  ]);
124
126
  exports.createAllPluginsWithUi = createAllPluginsWithUi;
@@ -41,7 +41,7 @@ const createPluginsWithUi = (wysiwygPlugins, options) => {
41
41
  ...plugins,
42
42
  ], {
43
43
  ...options,
44
- components: pluginComponents,
44
+ components: pluginComponents /* TODO: fix this type mismatch */,
45
45
  });
46
46
  };
47
47
  exports.createPluginsWithUi = createPluginsWithUi;
package/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
- export { WysiwygEditor } from "./wysiwyg-editor";
1
+ export { createAllPluginsWithUi, createBlockQuotePluginWithUi, createBoldPluginWithUi, createButtonPluginWithUi, createCodePluginWithUi, createHeadingsPluginWithUi, createHighlightPluginWithUi, createImagePluginWithUi, createItalicPluginWithUi, createLinkPluginWithUi, createListPluginWithUi, createUnderlinePluginWithUi, createVideoPluginWithUi, type CreateAllPluginsOptions, } from "./create-all-plugins-with-ui";
2
+ export * from "./hooks";
2
3
  export * from "./types";
3
4
  export * from "./utils";
4
- export * from "./hooks";
5
- export { createAllPluginsWithUi, createVideoPluginWithUi, createBoldPluginWithUi, createCodePluginWithUi, createHeadingsPluginWithUi, createBlockQuotePluginWithUi, createImagePluginWithUi, createItalicPluginWithUi, createListPluginWithUi, createUnderlinePluginWithUi, createHighlightPluginWithUi, type CreateAllPluginsOptions, } from "./create-all-plugins-with-ui";
5
+ export { WysiwygEditor } from "./wysiwyg-editor";
6
6
  export { createPluginsWithUi } from "./create-plugins-with-ui";
package/index.js CHANGED
@@ -14,23 +14,25 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- exports.createPluginsWithUi = exports.createHighlightPluginWithUi = exports.createUnderlinePluginWithUi = exports.createListPluginWithUi = exports.createItalicPluginWithUi = exports.createImagePluginWithUi = exports.createBlockQuotePluginWithUi = exports.createHeadingsPluginWithUi = exports.createCodePluginWithUi = exports.createBoldPluginWithUi = exports.createVideoPluginWithUi = exports.createAllPluginsWithUi = exports.WysiwygEditor = void 0;
18
- var wysiwyg_editor_1 = require("./wysiwyg-editor");
19
- Object.defineProperty(exports, "WysiwygEditor", { enumerable: true, get: function () { return wysiwyg_editor_1.WysiwygEditor; } });
20
- __exportStar(require("./types"), exports);
21
- __exportStar(require("./utils"), exports);
22
- __exportStar(require("./hooks"), exports);
17
+ exports.createPluginsWithUi = exports.WysiwygEditor = exports.createVideoPluginWithUi = exports.createUnderlinePluginWithUi = exports.createListPluginWithUi = exports.createLinkPluginWithUi = exports.createItalicPluginWithUi = exports.createImagePluginWithUi = exports.createHighlightPluginWithUi = exports.createHeadingsPluginWithUi = exports.createCodePluginWithUi = exports.createButtonPluginWithUi = exports.createBoldPluginWithUi = exports.createBlockQuotePluginWithUi = exports.createAllPluginsWithUi = void 0;
23
18
  var create_all_plugins_with_ui_1 = require("./create-all-plugins-with-ui");
24
19
  Object.defineProperty(exports, "createAllPluginsWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createAllPluginsWithUi; } });
25
- Object.defineProperty(exports, "createVideoPluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createVideoPluginWithUi; } });
20
+ Object.defineProperty(exports, "createBlockQuotePluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createBlockQuotePluginWithUi; } });
26
21
  Object.defineProperty(exports, "createBoldPluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createBoldPluginWithUi; } });
22
+ Object.defineProperty(exports, "createButtonPluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createButtonPluginWithUi; } });
27
23
  Object.defineProperty(exports, "createCodePluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createCodePluginWithUi; } });
28
24
  Object.defineProperty(exports, "createHeadingsPluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createHeadingsPluginWithUi; } });
29
- Object.defineProperty(exports, "createBlockQuotePluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createBlockQuotePluginWithUi; } });
25
+ Object.defineProperty(exports, "createHighlightPluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createHighlightPluginWithUi; } });
30
26
  Object.defineProperty(exports, "createImagePluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createImagePluginWithUi; } });
31
27
  Object.defineProperty(exports, "createItalicPluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createItalicPluginWithUi; } });
28
+ Object.defineProperty(exports, "createLinkPluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createLinkPluginWithUi; } });
32
29
  Object.defineProperty(exports, "createListPluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createListPluginWithUi; } });
33
30
  Object.defineProperty(exports, "createUnderlinePluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createUnderlinePluginWithUi; } });
34
- Object.defineProperty(exports, "createHighlightPluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createHighlightPluginWithUi; } });
31
+ Object.defineProperty(exports, "createVideoPluginWithUi", { enumerable: true, get: function () { return create_all_plugins_with_ui_1.createVideoPluginWithUi; } });
32
+ __exportStar(require("./hooks"), exports);
33
+ __exportStar(require("./types"), exports);
34
+ __exportStar(require("./utils"), exports);
35
+ var wysiwyg_editor_1 = require("./wysiwyg-editor");
36
+ Object.defineProperty(exports, "WysiwygEditor", { enumerable: true, get: function () { return wysiwyg_editor_1.WysiwygEditor; } });
35
37
  var create_plugins_with_ui_1 = require("./create-plugins-with-ui");
36
38
  Object.defineProperty(exports, "createPluginsWithUi", { enumerable: true, get: function () { return create_plugins_with_ui_1.createPluginsWithUi; } });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uxf/wysiwyg",
3
- "version": "10.0.0-beta.9",
3
+ "version": "10.0.1",
4
4
  "description": "UXF Wysiwyg editor",
5
5
  "author": "Robin Dvorak <dvorak@uxf.cz>",
6
6
  "homepage": "https://gitlab.com/uxf-npm/wysiwyg",
@@ -9,37 +9,39 @@
9
9
  "build": "tsc -P tsconfig.json",
10
10
  "typecheck": "tsc --noEmit --skipLibCheck"
11
11
  },
12
- "devDependencies": {
13
- "@uxf/ui": "10.0.0-beta.9",
14
- "autoprefixer": "^10.4.14",
15
- "react": "^18.2.0",
16
- "react-dom": "^18.2.0"
12
+ "dependencies": {
13
+ "@floating-ui/react": "0.26.0",
14
+ "@headlessui/react": "1.7.14",
15
+ "@udecode/plate-basic-marks": "20.7.2",
16
+ "@udecode/plate-block-quote": "20.7.2",
17
+ "@udecode/plate-break": "20.7.2",
18
+ "@udecode/plate-code-block": "20.7.2",
19
+ "@udecode/plate-common": "20.7.2",
20
+ "@udecode/plate-core": "20.7.2",
21
+ "@udecode/plate-floating": "20.7.2",
22
+ "@udecode/plate-link": "20.7.2",
23
+ "@udecode/plate-list": "20.7.2",
24
+ "@udecode/plate-media": "20.7.2",
25
+ "@udecode/plate-node-id": "20.7.2",
26
+ "@udecode/plate-paragraph": "20.7.2",
27
+ "@udecode/plate-reset-node": "20.7.2",
28
+ "@udecode/plate-select": "20.7.2",
29
+ "@udecode/plate-trailing-block": "20.7.2",
30
+ "@uxf/core": "10.0.0",
31
+ "@uxf/ui": "10.0.1",
32
+ "slate": "0.90.0",
33
+ "slate-history": "0.86.0",
34
+ "slate-hyperscript": "0.77.0",
35
+ "slate-react": "0.91.11"
17
36
  },
18
37
  "peerDependencies": {
19
- "@uxf/ui": "10.0.0-beta.9",
20
- "react": ">=18.0.0",
21
- "react-dom": ">=18.0.0"
38
+ "react": ">=18.2.0",
39
+ "react-dom": ">=18.2.0"
22
40
  },
23
- "dependencies": {
24
- "@headlessui/react": "1.7.14",
25
- "@udecode/plate-basic-marks": "^20.4.0",
26
- "@udecode/plate-block-quote": "^20.4.0",
27
- "@udecode/plate-break": "^20.4.0",
28
- "@udecode/plate-code-block": "^20.4.0",
29
- "@udecode/plate-common": "^20.4.0",
30
- "@udecode/plate-core": "^20.4.0",
31
- "@udecode/plate-floating": "^20.4.0",
32
- "@udecode/plate-link": "^20.4.0",
33
- "@udecode/plate-list": "^20.4.0",
34
- "@udecode/plate-media": "^20.4.0",
35
- "@udecode/plate-node-id": "^20.4.0",
36
- "@udecode/plate-paragraph": "^20.4.0",
37
- "@udecode/plate-reset-node": "^20.4.0",
38
- "@udecode/plate-select": "^20.4.0",
39
- "@udecode/plate-trailing-block": "^20.4.0",
40
- "slate": "^0.90.0",
41
- "slate-history": "^0.86.0",
42
- "slate-hyperscript": "^0.77.0",
43
- "slate-react": "^0.91.0"
41
+ "devDependencies": {
42
+ "@types/react": "18.2.27",
43
+ "@types/react-dom": "18.2.12",
44
+ "react": "18.2.0",
45
+ "react-dom": "18.2.0"
44
46
  }
45
47
  }
@@ -5,8 +5,8 @@ const plate_block_quote_1 = require("@udecode/plate-block-quote");
5
5
  const types_1 = require("./types");
6
6
  const createBlockquotePlugin = () => (0, plate_block_quote_1.createBlockquotePlugin)({
7
7
  props: {
8
- className: "block-quote-class-name",
8
+ className: "blockquote-class-name",
9
9
  },
10
- type: types_1.BLOCK_QUOTE_PLUGIN_TYPE,
10
+ type: types_1.BLOCKQUOTE_PLUGIN_TYPE,
11
11
  });
12
12
  exports.createBlockquotePlugin = createBlockquotePlugin;
@@ -0,0 +1,2 @@
1
+ export declare const BLOCKQUOTE_PLUGIN_KEY = "blockquote";
2
+ export declare const BLOCKQUOTE_PLUGIN_TYPE = "block-quote";
@@ -0,0 +1,6 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.BLOCKQUOTE_PLUGIN_TYPE = exports.BLOCKQUOTE_PLUGIN_KEY = void 0;
4
+ const plate_block_quote_1 = require("@udecode/plate-block-quote");
5
+ exports.BLOCKQUOTE_PLUGIN_KEY = plate_block_quote_1.ELEMENT_BLOCKQUOTE;
6
+ exports.BLOCKQUOTE_PLUGIN_TYPE = "block-quote";
@@ -1,3 +1,3 @@
1
- export { createButtonPlugin } from "./create-button-plugin";
2
1
  export { PLUGIN_BUTTON_KEY, PLUGIN_BUTTON_TYPE } from "./constants";
2
+ export { createButtonPlugin } from "./create-button-plugin";
3
3
  export * from "./transforms";
@@ -14,10 +14,10 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- exports.PLUGIN_BUTTON_TYPE = exports.PLUGIN_BUTTON_KEY = exports.createButtonPlugin = void 0;
18
- var create_button_plugin_1 = require("./create-button-plugin");
19
- Object.defineProperty(exports, "createButtonPlugin", { enumerable: true, get: function () { return create_button_plugin_1.createButtonPlugin; } });
17
+ exports.createButtonPlugin = exports.PLUGIN_BUTTON_TYPE = exports.PLUGIN_BUTTON_KEY = void 0;
20
18
  var constants_1 = require("./constants");
21
19
  Object.defineProperty(exports, "PLUGIN_BUTTON_KEY", { enumerable: true, get: function () { return constants_1.PLUGIN_BUTTON_KEY; } });
22
20
  Object.defineProperty(exports, "PLUGIN_BUTTON_TYPE", { enumerable: true, get: function () { return constants_1.PLUGIN_BUTTON_TYPE; } });
21
+ var create_button_plugin_1 = require("./create-button-plugin");
22
+ Object.defineProperty(exports, "createButtonPlugin", { enumerable: true, get: function () { return create_button_plugin_1.createButtonPlugin; } });
23
23
  __exportStar(require("./transforms"), exports);
@@ -1,4 +1,4 @@
1
- export { isButtonActive } from "./is-button-active";
2
1
  export { getActiveButton } from "./get-active-button";
3
2
  export { insertButton } from "./insert-button";
3
+ export { isButtonActive } from "./is-button-active";
4
4
  export { updateButton } from "./update-button";
@@ -1,11 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.updateButton = exports.insertButton = exports.getActiveButton = exports.isButtonActive = void 0;
4
- var is_button_active_1 = require("./is-button-active");
5
- Object.defineProperty(exports, "isButtonActive", { enumerable: true, get: function () { return is_button_active_1.isButtonActive; } });
3
+ exports.updateButton = exports.isButtonActive = exports.insertButton = exports.getActiveButton = void 0;
6
4
  var get_active_button_1 = require("./get-active-button");
7
5
  Object.defineProperty(exports, "getActiveButton", { enumerable: true, get: function () { return get_active_button_1.getActiveButton; } });
8
6
  var insert_button_1 = require("./insert-button");
9
7
  Object.defineProperty(exports, "insertButton", { enumerable: true, get: function () { return insert_button_1.insertButton; } });
8
+ var is_button_active_1 = require("./is-button-active");
9
+ Object.defineProperty(exports, "isButtonActive", { enumerable: true, get: function () { return is_button_active_1.isButtonActive; } });
10
10
  var update_button_1 = require("./update-button");
11
11
  Object.defineProperty(exports, "updateButton", { enumerable: true, get: function () { return update_button_1.updateButton; } });
@@ -1 +1 @@
1
- export { parseTwitterUrl, parseVideoUrl, parseIframeUrl } from "@udecode/plate-media";
1
+ export { parseIframeUrl, parseTwitterUrl, parseVideoUrl } from "@udecode/plate-media";
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.parseIframeUrl = exports.parseVideoUrl = exports.parseTwitterUrl = void 0;
3
+ exports.parseVideoUrl = exports.parseTwitterUrl = exports.parseIframeUrl = void 0;
4
4
  var plate_media_1 = require("@udecode/plate-media");
5
+ Object.defineProperty(exports, "parseIframeUrl", { enumerable: true, get: function () { return plate_media_1.parseIframeUrl; } });
5
6
  Object.defineProperty(exports, "parseTwitterUrl", { enumerable: true, get: function () { return plate_media_1.parseTwitterUrl; } });
6
7
  Object.defineProperty(exports, "parseVideoUrl", { enumerable: true, get: function () { return plate_media_1.parseVideoUrl; } });
7
- Object.defineProperty(exports, "parseIframeUrl", { enumerable: true, get: function () { return plate_media_1.parseIframeUrl; } });
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.insertVideo = void 0;
4
- const create_video_plugin_1 = require("./create-video-plugin");
5
4
  const utils_1 = require("../../../utils");
5
+ const create_video_plugin_1 = require("./create-video-plugin");
6
6
  const insertVideo = (editor, url, embeddedUrl, provider, videoId) => {
7
7
  const text = { text: "" };
8
8
  const element = {
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.createExitBreakPlugin = void 0;
4
4
  const plate_break_1 = require("@udecode/plate-break");
5
- const types_1 = require("../block-quote/types");
5
+ const types_1 = require("../blockquote/types");
6
6
  const constants_1 = require("../heading/constants");
7
7
  const createExitBreakPlugin = () => (0, plate_break_1.createExitBreakPlugin)({
8
8
  options: {
@@ -19,7 +19,7 @@ const createExitBreakPlugin = () => (0, plate_break_1.createExitBreakPlugin)({
19
19
  query: {
20
20
  start: true,
21
21
  end: true,
22
- allow: [...constants_1.KEYS_HEADING, types_1.BLOCK_QUOTE_PLUGIN_KEY],
22
+ allow: [...constants_1.KEYS_HEADING, types_1.BLOCKQUOTE_PLUGIN_KEY],
23
23
  },
24
24
  relative: true,
25
25
  level: 1,
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.insertImage = void 0;
4
- const types_1 = require("../types");
5
4
  const utils_1 = require("../../../utils");
5
+ const types_1 = require("../types");
6
6
  const insertImage = (editor, file, alt, caption, source, url) => {
7
7
  const text = { text: "" };
8
8
  const image = {
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.removeSelectedImage = void 0;
4
- const get_active_image_1 = require("./get-active-image");
5
4
  const utils_1 = require("../../../utils");
5
+ const get_active_image_1 = require("./get-active-image");
6
6
  const removeSelectedImage = (editor) => {
7
7
  const activeImage = (0, get_active_image_1.getActiveImage)(editor);
8
8
  if (!activeImage) {
@@ -1,4 +1,4 @@
1
- export { useLinkSubmitOnEnter } from "./use-link-submit-on-enter";
2
1
  export { useFloatingLinkSelectors } from "@udecode/plate-link";
3
2
  export { useLinkActions } from "./use-link-actions";
4
3
  export { useLinkCancelOnEscape } from "./use-link-cancel-on-escape";
4
+ export { useLinkSubmitOnEnter } from "./use-link-submit-on-enter";
@@ -1,11 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.useLinkCancelOnEscape = exports.useLinkActions = exports.useFloatingLinkSelectors = exports.useLinkSubmitOnEnter = void 0;
4
- var use_link_submit_on_enter_1 = require("./use-link-submit-on-enter");
5
- Object.defineProperty(exports, "useLinkSubmitOnEnter", { enumerable: true, get: function () { return use_link_submit_on_enter_1.useLinkSubmitOnEnter; } });
3
+ exports.useLinkSubmitOnEnter = exports.useLinkCancelOnEscape = exports.useLinkActions = exports.useFloatingLinkSelectors = void 0;
6
4
  var plate_link_1 = require("@udecode/plate-link");
7
5
  Object.defineProperty(exports, "useFloatingLinkSelectors", { enumerable: true, get: function () { return plate_link_1.useFloatingLinkSelectors; } });
8
6
  var use_link_actions_1 = require("./use-link-actions");
9
7
  Object.defineProperty(exports, "useLinkActions", { enumerable: true, get: function () { return use_link_actions_1.useLinkActions; } });
10
8
  var use_link_cancel_on_escape_1 = require("./use-link-cancel-on-escape");
11
9
  Object.defineProperty(exports, "useLinkCancelOnEscape", { enumerable: true, get: function () { return use_link_cancel_on_escape_1.useLinkCancelOnEscape; } });
10
+ var use_link_submit_on_enter_1 = require("./use-link-submit-on-enter");
11
+ Object.defineProperty(exports, "useLinkSubmitOnEnter", { enumerable: true, get: function () { return use_link_submit_on_enter_1.useLinkSubmitOnEnter; } });
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.insertLink = void 0;
4
- const plate_core_1 = require("@udecode/plate-core");
5
4
  const plate_common_1 = require("@udecode/plate-common");
5
+ const plate_core_1 = require("@udecode/plate-core");
6
6
  const plate_link_1 = require("@udecode/plate-link");
7
7
  const insertLink = (editor, url, text, target) => {
8
8
  if (!editor.selection) {
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.submitLink = void 0;
4
+ const plate_common_1 = require("@udecode/plate-common");
4
5
  const plate_core_1 = require("@udecode/plate-core");
5
6
  const plate_link_1 = require("@udecode/plate-link");
6
- const plate_common_1 = require("@udecode/plate-common");
7
7
  /**
8
8
  * Insert transforms if url is valid from store
9
9
  * Text is url if empty.
@@ -1,4 +1,4 @@
1
1
  export declare const LIST_PLUGIN_KEY = "list";
2
2
  export declare const LIST_ORDERED_TYPE = "ol";
3
3
  export declare const LIST_UNORDERED_TYPE = "ul";
4
- export { ELEMENT_UL, ELEMENT_OL, ELEMENT_LI, ELEMENT_LIC, getListItemEntry, toggleList } from "@udecode/plate-list";
4
+ export { ELEMENT_LI, ELEMENT_LIC, ELEMENT_OL, ELEMENT_UL, getListItemEntry, toggleList } from "@udecode/plate-list";
@@ -1,14 +1,14 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.toggleList = exports.getListItemEntry = exports.ELEMENT_LIC = exports.ELEMENT_LI = exports.ELEMENT_OL = exports.ELEMENT_UL = exports.LIST_UNORDERED_TYPE = exports.LIST_ORDERED_TYPE = exports.LIST_PLUGIN_KEY = void 0;
3
+ exports.toggleList = exports.getListItemEntry = exports.ELEMENT_UL = exports.ELEMENT_OL = exports.ELEMENT_LIC = exports.ELEMENT_LI = exports.LIST_UNORDERED_TYPE = exports.LIST_ORDERED_TYPE = exports.LIST_PLUGIN_KEY = void 0;
4
4
  const plate_list_1 = require("@udecode/plate-list");
5
5
  exports.LIST_PLUGIN_KEY = "list";
6
6
  exports.LIST_ORDERED_TYPE = plate_list_1.ELEMENT_OL;
7
7
  exports.LIST_UNORDERED_TYPE = plate_list_1.ELEMENT_UL;
8
8
  var plate_list_2 = require("@udecode/plate-list");
9
- Object.defineProperty(exports, "ELEMENT_UL", { enumerable: true, get: function () { return plate_list_2.ELEMENT_UL; } });
10
- Object.defineProperty(exports, "ELEMENT_OL", { enumerable: true, get: function () { return plate_list_2.ELEMENT_OL; } });
11
9
  Object.defineProperty(exports, "ELEMENT_LI", { enumerable: true, get: function () { return plate_list_2.ELEMENT_LI; } });
12
10
  Object.defineProperty(exports, "ELEMENT_LIC", { enumerable: true, get: function () { return plate_list_2.ELEMENT_LIC; } });
11
+ Object.defineProperty(exports, "ELEMENT_OL", { enumerable: true, get: function () { return plate_list_2.ELEMENT_OL; } });
12
+ Object.defineProperty(exports, "ELEMENT_UL", { enumerable: true, get: function () { return plate_list_2.ELEMENT_UL; } });
13
13
  Object.defineProperty(exports, "getListItemEntry", { enumerable: true, get: function () { return plate_list_2.getListItemEntry; } });
14
14
  Object.defineProperty(exports, "toggleList", { enumerable: true, get: function () { return plate_list_2.toggleList; } });
@@ -3,10 +3,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.createResetNodePlugin = void 0;
4
4
  const plate_common_1 = require("@udecode/plate-common");
5
5
  const plate_reset_node_1 = require("@udecode/plate-reset-node");
6
- const types_1 = require("../block-quote/types");
6
+ const types_1 = require("../blockquote/types");
7
7
  const types_2 = require("../paragraph/types");
8
8
  const resetBlockTypesCommonRule = {
9
- types: [types_1.BLOCK_QUOTE_PLUGIN_KEY],
9
+ types: [types_1.BLOCKQUOTE_PLUGIN_KEY],
10
10
  defaultType: types_2.PARAGRAPH_PLUGIN_KEY,
11
11
  };
12
12
  const createResetNodePlugin = () => (0, plate_reset_node_1.createResetNodePlugin)({
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.createSoftBreakPlugin = void 0;
4
4
  const plate_break_1 = require("@udecode/plate-break");
5
- const types_1 = require("../block-quote/types");
5
+ const types_1 = require("../blockquote/types");
6
6
  const types_2 = require("../paragraph/types");
7
7
  const createSoftBreakPlugin = () => (0, plate_break_1.createSoftBreakPlugin)({
8
8
  options: {
@@ -13,7 +13,7 @@ const createSoftBreakPlugin = () => (0, plate_break_1.createSoftBreakPlugin)({
13
13
  {
14
14
  hotkey: "enter",
15
15
  query: {
16
- allow: [types_2.PARAGRAPH_PLUGIN_KEY, types_1.BLOCK_QUOTE_PLUGIN_KEY],
16
+ allow: [types_2.PARAGRAPH_PLUGIN_KEY, types_1.BLOCKQUOTE_PLUGIN_KEY],
17
17
  },
18
18
  },
19
19
  ],