jodit-react 5.3.15 → 5.3.16

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.
@@ -4,7 +4,7 @@ import type { Jodit as JoditBaseConstructor } from 'jodit/esm/index';
4
4
  import type { Config } from 'jodit/esm/config';
5
5
  import { Jodit } from './include.jodit';
6
6
  import type { DeepPartial } from 'jodit/esm/types';
7
- interface Props<T extends typeof JoditBaseConstructor = typeof Jodit> {
7
+ export interface JoditEditorProps<T extends typeof JoditBaseConstructor = typeof Jodit> {
8
8
  JoditConstructor?: T;
9
9
  config?: DeepPartial<Config>;
10
10
  className?: string;
@@ -16,5 +16,5 @@ interface Props<T extends typeof JoditBaseConstructor = typeof Jodit> {
16
16
  value?: string;
17
17
  editorRef?: (editor: IJodit) => void;
18
18
  }
19
- declare const JoditEditor: React.ForwardRefExoticComponent<Props<typeof JoditBaseConstructor> & React.RefAttributes<IJodit>>;
19
+ declare const JoditEditor: React.ForwardRefExoticComponent<JoditEditorProps<typeof JoditBaseConstructor> & React.RefAttributes<IJodit>>;
20
20
  export default JoditEditor;
@@ -2,3 +2,4 @@ import JoditEditor from './JoditEditor';
2
2
  import { Jodit } from './include.jodit';
3
3
  export default JoditEditor;
4
4
  export { Jodit };
5
+ export type { JoditEditorProps } from './JoditEditor';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jodit-react",
3
- "version": "5.3.15",
3
+ "version": "5.3.16",
4
4
  "description": "Jodit is awesome and usefully wysiwyg editor with filebrowser",
5
5
  "main": "build/jodit-react.js",
6
6
  "module": "./build/esm/index.mjs",
@@ -15,6 +15,16 @@
15
15
  "types": "./build/types/index.d.ts",
16
16
  "default": "./build/react-jodit.js"
17
17
  }
18
+ },
19
+ "./types/JoditEditor": {
20
+ "import": {
21
+ "types": "./build/esm/JoditEditor.d.mts",
22
+ "default": "./build/esm/JoditEditor.mjs"
23
+ },
24
+ "require": {
25
+ "types": "./build/types/JoditEditor.d.ts",
26
+ "default": "./build/types/JoditEditor.js"
27
+ }
18
28
  }
19
29
  },
20
30
  "files": [
@@ -33,7 +43,7 @@
33
43
  "rte"
34
44
  ],
35
45
  "dependencies": {
36
- "jodit": "^4.8.9"
46
+ "jodit": "^4.8.8"
37
47
  },
38
48
  "peerDependencies": {
39
49
  "react": "~0.14 || ^15 || ^16 || ^17 || ^18 || ^19",
@@ -84,7 +94,7 @@
84
94
  "build": "npm run build:react && npm run build:types && npm run build:esm",
85
95
  "build:react": "cross-env NODE_ENV=production node -r @swc-node/register ./node_modules/.bin/webpack --mode production",
86
96
  "build:types": "rm -rf ./build/types && tsc --project tsconfig.types.json && npm run remove-css",
87
- "build:esm": "tsup src/index.ts --dts --format esm -d ./build/esm --clean",
97
+ "build:esm": "tsup src/index.ts src/JoditEditor.tsx --dts --format esm -d ./build/esm --clean",
88
98
  "remove-css": "replace \"import '[^']+.css';\" ''./build/**/*.ts",
89
99
  "github": "npm run git && git push --tags origin HEAD:main",
90
100
  "git": "git add --all && git commit -m \"New version $npm_package_version. Read more https://github.com/jodit/jodit-react/releases/tag/$npm_package_version \" && git tag $npm_package_version",