@yoopta/editor 4.0.0-rc.10 → 4.0.0-rc.12

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 (31) hide show
  1. package/LICENSE +21 -0
  2. package/dist/UI/BlockOptions/BlockOptions.d.ts.map +1 -1
  3. package/dist/YooptaEditor.d.ts +1 -1
  4. package/dist/YooptaEditor.d.ts.map +1 -1
  5. package/dist/components/Block/BlockActions.d.ts.map +1 -1
  6. package/dist/components/Editor/Editor.d.ts.map +1 -1
  7. package/dist/contexts/UltraYooptaContext/UltraYooptaContext.d.ts.map +1 -1
  8. package/dist/editor/index.d.ts.map +1 -1
  9. package/dist/editor/textFormats/toggle.d.ts.map +1 -1
  10. package/dist/editor/textFormats/update.d.ts.map +1 -1
  11. package/dist/editor/transforms/createBlock.d.ts.map +1 -1
  12. package/dist/editor/transforms/decreaseBlockDepth.d.ts.map +1 -1
  13. package/dist/editor/transforms/deleteBlock.d.ts.map +1 -1
  14. package/dist/editor/transforms/duplicateBlock.d.ts.map +1 -1
  15. package/dist/editor/transforms/increaseBlockDepth.d.ts.map +1 -1
  16. package/dist/editor/transforms/insertBlock.d.ts.map +1 -1
  17. package/dist/editor/transforms/moveBlock.d.ts.map +1 -1
  18. package/dist/editor/transforms/splitBlock.d.ts.map +1 -1
  19. package/dist/editor/transforms/toggleBlock.d.ts.map +1 -1
  20. package/dist/editor/transforms/updateBlock.d.ts.map +1 -1
  21. package/dist/editor/transforms/updateBlockElement.d.ts.map +1 -1
  22. package/dist/editor/types.d.ts +3 -2
  23. package/dist/editor/types.d.ts.map +1 -1
  24. package/dist/index.js +2 -8
  25. package/dist/marks/FakeSelectionMark.d.ts +5 -0
  26. package/dist/marks/FakeSelectionMark.d.ts.map +1 -0
  27. package/dist/plugins/SlateEditorComponent.d.ts.map +1 -1
  28. package/dist/plugins/createYooptaPlugin.d.ts +10 -2
  29. package/dist/plugins/createYooptaPlugin.d.ts.map +1 -1
  30. package/dist/plugins/extenstions/withInlines.d.ts.map +1 -1
  31. package/package.json +7 -7
@@ -0,0 +1,5 @@
1
+ import { YooptaMarkProps } from '../plugins/types';
2
+ type FakeSelectionMarkProps = YooptaMarkProps<'italic', boolean>;
3
+ declare const FakeSelectionMark: import(".").YooptaMark<FakeSelectionMarkProps>;
4
+ export { FakeSelectionMark };
5
+ //# sourceMappingURL=FakeSelectionMark.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"FakeSelectionMark.d.ts","sourceRoot":"","sources":["../../src/marks/FakeSelectionMark.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAEnD,KAAK,sBAAsB,GAAG,eAAe,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC;AAEjE,QAAA,MAAM,iBAAiB,gDAKrB,CAAC;AAEH,OAAO,EAAE,iBAAiB,EAAE,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"SlateEditorComponent.d.ts","sourceRoot":"","sources":["../../src/plugins/SlateEditorComponent.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAEtC,OAAO,EAIL,YAAY,EAEb,MAAM,SAAS,CAAC;AAcjB,KAAK,KAAK,CAAC,KAAK,SAAS,MAAM,EAAE,MAAM,EAAE,QAAQ,IAAI,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,CAAC,GAAG;IAC3F,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,CAAC,EAAE,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;IAC1B,OAAO,EAAE,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,CAAC,CAAC,SAAS,CAAC,CAAC;IAC1D,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAgBF,QAAA,MAAM,oBAAoB,2LAgLzB,CAAC;AAkFF,OAAO,EAAE,oBAAoB,EAAE,CAAC"}
1
+ {"version":3,"file":"SlateEditorComponent.d.ts","sourceRoot":"","sources":["../../src/plugins/SlateEditorComponent.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAEtC,OAAO,EAA0E,YAAY,EAAE,MAAM,SAAS,CAAC;AAY/G,KAAK,KAAK,CAAC,KAAK,SAAS,MAAM,EAAE,MAAM,EAAE,QAAQ,IAAI,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,CAAC,GAAG;IAC3F,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,CAAC,EAAE,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;IAC1B,OAAO,EAAE,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,CAAC,CAAC,SAAS,CAAC,CAAC;IAC1D,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAgBF,QAAA,MAAM,oBAAoB,2LAyKzB,CAAC;AAgHF,OAAO,EAAE,oBAAoB,EAAE,CAAC"}
@@ -1,9 +1,17 @@
1
+ /// <reference types="react" />
1
2
  import { Descendant } from 'slate';
2
- import { PluginOptions, PluginParams } from './types';
3
+ import { PluginElementRenderProps, PluginParams } from './types';
4
+ export type ExtendPluginRender<TKeys extends string> = {
5
+ [x in TKeys]: (props: PluginElementRenderProps) => JSX.Element;
6
+ };
7
+ export type ExtendPlugin<TKeys extends string, TOptions = Record<string, unknown>> = {
8
+ renders?: ExtendPluginRender<TKeys>;
9
+ options?: TOptions;
10
+ };
3
11
  export declare class YooptaPlugin<TKeys extends string = string, TProps = Descendant, TOptions = Record<string, unknown>> {
4
12
  private readonly plugin;
5
13
  constructor(plugin: PluginParams<TKeys, TProps, TOptions>);
6
14
  get getPlugin(): PluginParams<TKeys, TProps, TOptions>;
7
- extend(options: Partial<PluginOptions<TOptions>>): YooptaPlugin<TKeys, TProps, TOptions>;
15
+ extend(extendPlugin: ExtendPlugin<TKeys, TOptions>): YooptaPlugin<TKeys, TProps, TOptions>;
8
16
  }
9
17
  //# sourceMappingURL=createYooptaPlugin.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"createYooptaPlugin.d.ts","sourceRoot":"","sources":["../../src/plugins/createYooptaPlugin.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AACnC,OAAO,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAEtD,qBAAa,YAAY,CAAC,KAAK,SAAS,MAAM,GAAG,MAAM,EAAE,MAAM,GAAG,UAAU,EAAE,QAAQ,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAC9G,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAwC;gBAEnD,MAAM,EAAE,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,CAAC;IAIzD,IAAI,SAAS,0CAEZ;IAED,MAAM,CAAC,OAAO,EAAE,OAAO,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC,GAAG,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,CAAC;CAUzF"}
1
+ {"version":3,"file":"createYooptaPlugin.d.ts","sourceRoot":"","sources":["../../src/plugins/createYooptaPlugin.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AACnC,OAAO,EAAE,wBAAwB,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAEjE,MAAM,MAAM,kBAAkB,CAAC,KAAK,SAAS,MAAM,IAAI;KACpD,CAAC,IAAI,KAAK,GAAG,CAAC,KAAK,EAAE,wBAAwB,KAAK,GAAG,CAAC,OAAO;CAC/D,CAAC;AAEF,MAAM,MAAM,YAAY,CAAC,KAAK,SAAS,MAAM,EAAE,QAAQ,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,IAAI;IACnF,OAAO,CAAC,EAAE,kBAAkB,CAAC,KAAK,CAAC,CAAC;IACpC,OAAO,CAAC,EAAE,QAAQ,CAAC;CACpB,CAAC;AAEF,qBAAa,YAAY,CAAC,KAAK,SAAS,MAAM,GAAG,MAAM,EAAE,MAAM,GAAG,UAAU,EAAE,QAAQ,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAC9G,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAwC;gBAEnD,MAAM,EAAE,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,CAAC;IAIzD,IAAI,SAAS,0CAEZ;IAED,MAAM,CAAC,YAAY,EAAE,YAAY,CAAC,KAAK,EAAE,QAAQ,CAAC,GAAG,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,CAAC;CAiC3F"}
@@ -1 +1 @@
1
- {"version":3,"file":"withInlines.d.ts","sourceRoot":"","sources":["../../../src/plugins/extenstions/withInlines.ts"],"names":[],"mappings":"AAmDA,eAAO,MAAM,WAAW,sBA0BvB,CAAC"}
1
+ {"version":3,"file":"withInlines.d.ts","sourceRoot":"","sources":["../../../src/plugins/extenstions/withInlines.ts"],"names":[],"mappings":"AAmDA,eAAO,MAAM,WAAW,sBAwBvB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yoopta/editor",
3
- "version": "4.0.0-rc.10",
3
+ "version": "4.0.0-rc.12",
4
4
  "license": "MIT",
5
5
  "private": false,
6
6
  "type": "module",
@@ -21,14 +21,13 @@
21
21
  "is-hotkey": "^0.2.0",
22
22
  "lodash.clonedeep": "^4.5.0",
23
23
  "nanoid": "^4.0.1",
24
- "react-error-boundary": "^4.0.13",
25
- "slate": "^0.102.0",
26
- "slate-history": "^0.100.0",
27
- "slate-react": "^0.102.0"
24
+ "slate-history": "^0.100.0"
28
25
  },
29
26
  "peerDependencies": {
30
27
  "react": ">=17.0.2",
31
- "react-dom": ">=17.0.2"
28
+ "react-dom": ">=17.0.2",
29
+ "slate": "^0.102.0",
30
+ "slate-react": "^0.102.0"
32
31
  },
33
32
  "scripts": {
34
33
  "start": "rollup --config rollup.config.js --watch --bundleConfigAsCjs --environment NODE_ENV:development",
@@ -68,5 +67,6 @@
68
67
  "bugs": {
69
68
  "url": "https://github.com/Darginec05/Yoopta-Editor/issues"
70
69
  },
71
- "homepage": "https://github.com/Darginec05/Yoopta-Editor#readme"
70
+ "homepage": "https://github.com/Darginec05/Yoopta-Editor#readme",
71
+ "gitHead": "301c0cc901a5633c09ae0d7450c9dcbe7a6e47cc"
72
72
  }