@entur-partner/rich-text-editor 5.0.0 → 6.0.1-alpha.0

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.
@@ -1,6 +1,7 @@
1
+ import React from 'react';
1
2
  import { LanguageKey, LanguageOption, MultiLanguageValues } from '@entur-partner/common';
2
3
  import { VariantType } from '@entur/form';
3
- declare type MultiLanguageInputProps = {
4
+ type MultiLanguageInputProps = {
4
5
  values: MultiLanguageValues;
5
6
  onChange: (values: MultiLanguageValues) => void;
6
7
  variant?: (lang: LanguageKey) => VariantType;
@@ -11,10 +12,10 @@ declare type MultiLanguageInputProps = {
11
12
  label: string;
12
13
  }[];
13
14
  };
14
- declare type ExpandableMultiLanguageRichTextEditorProps = MultiLanguageInputProps & {
15
+ type ExpandableMultiLanguageRichTextEditorProps = MultiLanguageInputProps & {
15
16
  name: string;
16
17
  title: string;
17
18
  languages: LanguageOption[];
18
19
  };
19
- export declare const ExpandableMultiLanguageRichTextEditor: ({ name, title, languages, ...rest }: ExpandableMultiLanguageRichTextEditorProps) => JSX.Element;
20
+ export declare const ExpandableMultiLanguageRichTextEditor: ({ name, title, languages, ...rest }: ExpandableMultiLanguageRichTextEditorProps) => React.JSX.Element;
20
21
  export {};
@@ -1,2 +1,3 @@
1
- declare var _default: (props: any) => JSX.Element;
1
+ declare const _default: (props: any) => React.JSX.Element;
2
2
  export default _default;
3
+ import React from "react";
@@ -1,2 +1,3 @@
1
1
  export default BlockTypeButtonControls;
2
- declare function BlockTypeButtonControls(props: any): JSX.Element;
2
+ declare function BlockTypeButtonControls(props: any): React.JSX.Element;
3
+ import React from "react";
@@ -1,2 +1,3 @@
1
- declare var _default: (props: any) => JSX.Element;
1
+ declare const _default: (props: any) => React.JSX.Element;
2
2
  export default _default;
3
+ import React from "react";
@@ -3,4 +3,5 @@ declare function BlockTypeControls({ editorState, blockTypes, onToggle }: {
3
3
  editorState: any;
4
4
  blockTypes: any;
5
5
  onToggle: any;
6
- }): JSX.Element;
6
+ }): React.JSX.Element;
7
+ import React from "react";
@@ -1,2 +1,3 @@
1
1
  export default InlineStyleControls;
2
- declare function InlineStyleControls(props: any): JSX.Element;
2
+ declare function InlineStyleControls(props: any): React.JSX.Element;
3
+ import React from "react";
@@ -1,2 +1,3 @@
1
- declare var _default: (props: any) => JSX.Element;
1
+ declare const _default: (props: any) => React.JSX.Element;
2
2
  export default _default;
3
+ import React from "react";
@@ -2,6 +2,7 @@ export function findLinkEntities(contentBlock: any, callback: any, contentState:
2
2
  export function HtmlLink({ url, children }: {
3
3
  url: any;
4
4
  children: any;
5
- }): JSX.Element;
5
+ }): React.JSX.Element;
6
6
  export default Link;
7
- declare function Link(props: any): JSX.Element;
7
+ import React from "react";
8
+ declare function Link(props: any): React.JSX.Element;
@@ -1,2 +1,3 @@
1
- declare var _default: (props: any) => JSX.Element;
1
+ declare const _default: (props: any) => React.JSX.Element;
2
2
  export default _default;
3
+ import React from "react";
@@ -50,31 +50,31 @@ export const FontList: Readonly<{
50
50
  }>;
51
51
  export const BlockTypeList: Readonly<{
52
52
  'unordered-list': {
53
- label: JSX.Element;
53
+ label: React.JSX.Element;
54
54
  style: string;
55
55
  tooltip: string;
56
56
  };
57
57
  'ordered-list': {
58
- label: JSX.Element;
58
+ label: React.JSX.Element;
59
59
  style: string;
60
60
  tooltip: string;
61
61
  };
62
62
  }>;
63
63
  export const InlineStylesList: Readonly<{
64
64
  bold: {
65
- label: JSX.Element;
65
+ label: React.JSX.Element;
66
66
  style: string;
67
67
  tooltip: string;
68
68
  hotKey: string;
69
69
  };
70
70
  italic: {
71
- label: JSX.Element;
71
+ label: React.JSX.Element;
72
72
  style: string;
73
73
  tooltip: string;
74
74
  hotKey: string;
75
75
  };
76
76
  underline: {
77
- label: JSX.Element;
77
+ label: React.JSX.Element;
78
78
  style: string;
79
79
  tooltip: string;
80
80
  hotKey: string;
@@ -90,4 +90,5 @@ export const MinifiedConfigTypes: Readonly<{
90
90
  inlineStyles: string[];
91
91
  }>;
92
92
  export const decorator: CompositeDecorator;
93
+ import React from "react";
93
94
  import { CompositeDecorator } from "draft-js";
@@ -20,7 +20,7 @@ declare class RichTextEditor extends React.Component<any, any, any> {
20
20
  blockTypes: any;
21
21
  inlineStyles: any;
22
22
  };
23
- render(): JSX.Element;
23
+ render(): React.JSX.Element;
24
24
  }
25
25
  declare namespace RichTextEditor {
26
26
  namespace propTypes {
package/dist/events.d.ts CHANGED
@@ -1,4 +1,4 @@
1
1
  export function getKey(event: any): any;
2
2
  export const Key: Readonly<{
3
- ENTER: number;
3
+ ENTER: 13;
4
4
  }>;