@atlaskit/editor-core 187.10.8 → 187.12.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.
Files changed (118) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/dist/cjs/create-editor/ReactEditorViewInternal.js +1 -4
  3. package/dist/cjs/editor-next/editor-internal.js +0 -2
  4. package/dist/cjs/editor-next/hooks/useProviderFactory.js +2 -2
  5. package/dist/cjs/editor-next/index.js +0 -2
  6. package/dist/cjs/editor.js +6 -2
  7. package/dist/cjs/index.js +2 -94
  8. package/dist/cjs/plugins/help-dialog/ui/index.js +42 -42
  9. package/dist/cjs/plugins/paste/handlers.js +4 -6
  10. package/dist/cjs/plugins/text-formatting/actions.js +188 -0
  11. package/dist/cjs/plugins/text-formatting/commands/text-formatting.js +1 -180
  12. package/dist/cjs/plugins/text-formatting/index.js +11 -0
  13. package/dist/cjs/plugins/text-formatting/pm-plugins/keymap.js +8 -8
  14. package/dist/cjs/plugins/text-formatting/pm-plugins/main.js +8 -8
  15. package/dist/cjs/plugins/text-formatting/ui/Toolbar/hooks/clear-formatting-icon.js +2 -2
  16. package/dist/cjs/plugins/text-formatting/ui/Toolbar/hooks/formatting-icons.js +16 -16
  17. package/dist/cjs/plugins/text-formatting/ui/Toolbar/index.js +8 -8
  18. package/dist/cjs/plugins/text-formatting/utils.js +8 -36
  19. package/dist/cjs/ui/ContentStyles/index.js +8 -9
  20. package/dist/cjs/{editor-next/utils/deprecationWarnings.js → utils/editorDeprecationWarnings.js} +3 -3
  21. package/dist/cjs/version-wrapper.js +1 -1
  22. package/dist/cjs/version.json +1 -1
  23. package/dist/es2019/create-editor/ReactEditorViewInternal.js +1 -4
  24. package/dist/es2019/editor-next/editor-internal.js +0 -2
  25. package/dist/es2019/editor-next/hooks/useProviderFactory.js +2 -2
  26. package/dist/es2019/editor-next/index.js +0 -2
  27. package/dist/es2019/editor.js +5 -0
  28. package/dist/es2019/index.js +0 -2
  29. package/dist/es2019/plugins/help-dialog/ui/index.js +1 -1
  30. package/dist/es2019/plugins/paste/handlers.js +5 -7
  31. package/dist/es2019/plugins/text-formatting/actions.js +161 -0
  32. package/dist/es2019/plugins/text-formatting/commands/text-formatting.js +1 -159
  33. package/dist/es2019/plugins/text-formatting/index.js +115 -102
  34. package/dist/es2019/plugins/text-formatting/pm-plugins/keymap.js +8 -8
  35. package/dist/es2019/plugins/text-formatting/pm-plugins/main.js +1 -1
  36. package/dist/es2019/plugins/text-formatting/ui/Toolbar/hooks/clear-formatting-icon.js +1 -1
  37. package/dist/es2019/plugins/text-formatting/ui/Toolbar/hooks/formatting-icons.js +9 -9
  38. package/dist/es2019/plugins/text-formatting/ui/Toolbar/index.js +1 -1
  39. package/dist/es2019/plugins/text-formatting/utils.js +1 -29
  40. package/dist/es2019/ui/ContentStyles/index.js +2 -3
  41. package/dist/es2019/{editor-next/utils/deprecationWarnings.js → utils/editorDeprecationWarnings.js} +2 -2
  42. package/dist/es2019/version-wrapper.js +1 -1
  43. package/dist/es2019/version.json +1 -1
  44. package/dist/esm/create-editor/ReactEditorViewInternal.js +1 -4
  45. package/dist/esm/editor-next/editor-internal.js +0 -2
  46. package/dist/esm/editor-next/hooks/useProviderFactory.js +2 -2
  47. package/dist/esm/editor-next/index.js +0 -2
  48. package/dist/esm/editor.js +6 -2
  49. package/dist/esm/index.js +0 -2
  50. package/dist/esm/plugins/help-dialog/ui/index.js +1 -1
  51. package/dist/esm/plugins/paste/handlers.js +5 -7
  52. package/dist/esm/plugins/text-formatting/actions.js +168 -0
  53. package/dist/esm/plugins/text-formatting/commands/text-formatting.js +1 -166
  54. package/dist/esm/plugins/text-formatting/index.js +11 -0
  55. package/dist/esm/plugins/text-formatting/pm-plugins/keymap.js +8 -8
  56. package/dist/esm/plugins/text-formatting/pm-plugins/main.js +1 -1
  57. package/dist/esm/plugins/text-formatting/ui/Toolbar/hooks/clear-formatting-icon.js +1 -1
  58. package/dist/esm/plugins/text-formatting/ui/Toolbar/hooks/formatting-icons.js +9 -9
  59. package/dist/esm/plugins/text-formatting/ui/Toolbar/index.js +1 -1
  60. package/dist/esm/plugins/text-formatting/utils.js +6 -33
  61. package/dist/esm/ui/ContentStyles/index.js +2 -3
  62. package/dist/esm/{editor-next/utils/deprecationWarnings.js → utils/editorDeprecationWarnings.js} +2 -2
  63. package/dist/esm/version-wrapper.js +1 -1
  64. package/dist/esm/version.json +1 -1
  65. package/dist/types/create-editor/ReactEditorViewInternal.d.ts +0 -1
  66. package/dist/types/editor-next/hooks/useProviderFactory.d.ts +4 -4
  67. package/dist/types/editor.d.ts +1 -0
  68. package/dist/types/index.d.ts +6 -4
  69. package/dist/types/labs/next/presets/default.d.ts +50 -15
  70. package/dist/types/labs/next/presets/useUniversalPreset.d.ts +2 -2
  71. package/dist/types/plugins/media/ui/ResizableMediaSingle/guidelines.d.ts +1 -1
  72. package/dist/types/plugins/paste/handlers.d.ts +1 -2
  73. package/dist/types/plugins/text-formatting/actions.d.ts +22 -0
  74. package/dist/types/plugins/text-formatting/commands/text-formatting.d.ts +0 -31
  75. package/dist/types/plugins/text-formatting/index.d.ts +11 -2
  76. package/dist/types/plugins/text-formatting/pm-plugins/main.d.ts +1 -2
  77. package/dist/types/plugins/text-formatting/pm-plugins/plugin-key.d.ts +1 -1
  78. package/dist/types/plugins/text-formatting/utils.d.ts +1 -5
  79. package/dist/types/types/editor-props.d.ts +11 -12
  80. package/dist/types/ui/ContentStyles/index.d.ts +1 -1
  81. package/dist/types/utils/editorDeprecationWarnings.d.ts +2 -0
  82. package/dist/types-ts4.5/create-editor/ReactEditorViewInternal.d.ts +0 -1
  83. package/dist/types-ts4.5/editor-next/hooks/useProviderFactory.d.ts +4 -4
  84. package/dist/types-ts4.5/editor.d.ts +1 -0
  85. package/dist/types-ts4.5/index.d.ts +6 -4
  86. package/dist/types-ts4.5/labs/next/presets/default.d.ts +50 -15
  87. package/dist/types-ts4.5/labs/next/presets/useUniversalPreset.d.ts +2 -2
  88. package/dist/types-ts4.5/plugins/media/ui/ResizableMediaSingle/guidelines.d.ts +1 -1
  89. package/dist/types-ts4.5/plugins/paste/handlers.d.ts +1 -2
  90. package/dist/types-ts4.5/plugins/text-formatting/actions.d.ts +22 -0
  91. package/dist/types-ts4.5/plugins/text-formatting/commands/text-formatting.d.ts +0 -31
  92. package/dist/types-ts4.5/plugins/text-formatting/index.d.ts +11 -2
  93. package/dist/types-ts4.5/plugins/text-formatting/pm-plugins/main.d.ts +1 -2
  94. package/dist/types-ts4.5/plugins/text-formatting/pm-plugins/plugin-key.d.ts +1 -1
  95. package/dist/types-ts4.5/plugins/text-formatting/utils.d.ts +1 -5
  96. package/dist/types-ts4.5/types/editor-props.d.ts +11 -12
  97. package/dist/types-ts4.5/ui/ContentStyles/index.d.ts +1 -1
  98. package/dist/types-ts4.5/utils/editorDeprecationWarnings.d.ts +2 -0
  99. package/package.json +3 -3
  100. package/report.api.md +39 -166
  101. package/tmp/api-report-tmp.d.ts +36 -135
  102. package/dist/cjs/plugins/text-formatting/styles.js +0 -15
  103. package/dist/cjs/plugins/text-formatting/types.js +0 -5
  104. package/dist/cjs/plugins/text-formatting/ui/Toolbar/toolbar-messages.js +0 -95
  105. package/dist/es2019/plugins/text-formatting/styles.js +0 -5
  106. package/dist/es2019/plugins/text-formatting/types.js +0 -1
  107. package/dist/es2019/plugins/text-formatting/ui/Toolbar/toolbar-messages.js +0 -88
  108. package/dist/esm/plugins/text-formatting/styles.js +0 -7
  109. package/dist/esm/plugins/text-formatting/types.js +0 -1
  110. package/dist/esm/plugins/text-formatting/ui/Toolbar/toolbar-messages.js +0 -88
  111. package/dist/types/editor-next/utils/deprecationWarnings.d.ts +0 -2
  112. package/dist/types/plugins/text-formatting/styles.d.ts +0 -2
  113. package/dist/types/plugins/text-formatting/types.d.ts +0 -30
  114. package/dist/types/plugins/text-formatting/ui/Toolbar/toolbar-messages.d.ts +0 -87
  115. package/dist/types-ts4.5/editor-next/utils/deprecationWarnings.d.ts +0 -2
  116. package/dist/types-ts4.5/plugins/text-formatting/styles.d.ts +0 -2
  117. package/dist/types-ts4.5/plugins/text-formatting/types.d.ts +0 -30
  118. package/dist/types-ts4.5/plugins/text-formatting/ui/Toolbar/toolbar-messages.d.ts +0 -87
@@ -145,6 +145,9 @@ import { setTextSelection } from '@atlaskit/editor-common/utils';
145
145
  import type { SEVERITY } from '@atlaskit/editor-common/utils';
146
146
  import type { TaskDecisionProvider } from '@atlaskit/task-decision';
147
147
  import { TeamMentionResource } from '@atlaskit/mention/team-resource';
148
+ import { InputMethodBasic as TextFormattingInputMethodBasic } from '@atlaskit/editor-common/types';
149
+ import { InputMethodToolbar as TextFormattingInputMethodToolbar } from '@atlaskit/editor-common/types';
150
+ import type { TextFormattingOptions } from '@atlaskit/editor-common/types';
148
151
  import { ToolbarUIComponentFactory } from '@atlaskit/editor-common/types';
149
152
  import type { Transaction } from '@atlaskit/editor-prosemirror/state';
150
153
  import { TransactionTracking } from '@atlaskit/editor-common/types';
@@ -533,6 +536,7 @@ export { DropdownOptionT }
533
536
 
534
537
  // @public (undocumented)
535
538
  export class Editor extends React_2.Component<EditorProps> {
539
+ constructor(props: EditorProps);
536
540
  // (undocumented)
537
541
  static defaultProps: EditorProps;
538
542
  // (undocumented)
@@ -591,8 +595,6 @@ interface EditorBaseProps {
591
595
  // (undocumented)
592
596
  assistiveLabel?: string;
593
597
  // (undocumented)
594
- codeBlock?: CodeBlockOptions;
595
- // (undocumented)
596
598
  contentComponents?: ReactComponents;
597
599
  // (undocumented)
598
600
  contentTransformerProvider?: (schema: Schema) => Transformer_2<string>;
@@ -645,8 +647,6 @@ interface EditorBaseProps {
645
647
  secondaryToolbarComponents?: ReactComponents;
646
648
  // (undocumented)
647
649
  shouldFocus?: boolean;
648
- // (undocumented)
649
- textFormatting?: TextFormattingOptions;
650
650
  trackValidTransactions?: boolean | {
651
651
  samplingRate: number;
652
652
  };
@@ -738,6 +738,8 @@ export { EditorPlugin }
738
738
 
739
739
  // @public (undocumented)
740
740
  interface EditorPluginFeatureProps {
741
+ // (undocumented)
742
+ allowAnalyticsGASV3?: boolean;
741
743
  // (undocumented)
742
744
  allowBlockType?: BlockTypePluginOptions['allowBlockType'];
743
745
  // (undocumented)
@@ -776,6 +778,8 @@ interface EditorPluginFeatureProps {
776
778
  menuDisabled: boolean;
777
779
  };
778
780
  // (undocumented)
781
+ allowTables?: PluginConfig | boolean;
782
+ // (undocumented)
779
783
  allowTasksAndDecisions?: boolean;
780
784
  // (undocumented)
781
785
  allowTemplatePlaceholders?: PlaceholderTextOptions | boolean;
@@ -796,6 +800,8 @@ interface EditorPluginFeatureProps {
796
800
  // (undocumented)
797
801
  feedbackInfo?: FeedbackInfo;
798
802
  // (undocumented)
803
+ insertMenuItems?: MenuItem[];
804
+ // (undocumented)
799
805
  maxContentSize?: number;
800
806
  // (undocumented)
801
807
  mention?: MentionPluginConfig;
@@ -803,7 +809,11 @@ interface EditorPluginFeatureProps {
803
809
  mentionInsertDisplayName?: boolean;
804
810
  // (undocumented)
805
811
  saveOnEnter?: boolean;
812
+ // @deprecated (undocumented)
813
+ smartLinks?: CardOptions;
806
814
  UNSAFE_allowBorderMark?: boolean;
815
+ // @deprecated (undocumented)
816
+ UNSAFE_cards?: CardOptions;
807
817
  // (undocumented)
808
818
  uploadErrorHandler?: (state: MediaState) => void;
809
819
  // (undocumented)
@@ -842,6 +852,8 @@ interface EditorProviderProps {
842
852
  // (undocumented)
843
853
  collabEditProvider?: Providers['collabEditProvider'];
844
854
  // (undocumented)
855
+ contextIdentifierProvider?: Promise<ContextIdentifierProvider>;
856
+ // (undocumented)
845
857
  emojiProvider?: Providers['emojiProvider'];
846
858
  // (undocumented)
847
859
  legacyImageUploadProvider?: Providers['imageUploadProvider'];
@@ -859,18 +871,12 @@ interface EditorProviderProps {
859
871
 
860
872
  // @public (undocumented)
861
873
  interface EditorSharedPropsWithPlugins {
862
- // (undocumented)
863
- allowAnalyticsGASV3?: boolean;
864
- // (undocumented)
865
- allowTables?: PluginConfig | boolean;
866
874
  // (undocumented)
867
875
  allowUndoRedoButtons?: boolean;
868
876
  // (undocumented)
869
- collabEdit?: CollabEditOptions;
870
- // (undocumented)
871
- contextIdentifierProvider?: Promise<ContextIdentifierProvider>;
877
+ codeBlock?: CodeBlockOptions;
872
878
  // (undocumented)
873
- insertMenuItems?: MenuItem[];
879
+ collabEdit?: CollabEditOptions;
874
880
  linking?: LinkingOptions;
875
881
  // (undocumented)
876
882
  media?: MediaOptions;
@@ -881,16 +887,12 @@ interface EditorSharedPropsWithPlugins {
881
887
  primaryToolbarComponents?: PrimaryToolbarComponents;
882
888
  // (undocumented)
883
889
  sanitizePrivateContent?: boolean;
884
- // @deprecated (undocumented)
885
- smartLinks?: CardOptions;
886
- // @deprecated (undocumented)
887
- UNSAFE_cards?: CardOptions;
890
+ // (undocumented)
891
+ textFormatting?: TextFormattingOptions;
888
892
  }
889
893
 
890
894
  // @public (undocumented)
891
895
  interface EditorViewProps {
892
- // (undocumented)
893
- allowAnalyticsGASV3?: boolean;
894
896
  // (undocumented)
895
897
  createAnalyticsEvent?: CreateUIAnalyticsEvent;
896
898
  // (undocumented)
@@ -1927,74 +1929,24 @@ export type TextColorPluginState = {
1927
1929
  color: null | string;
1928
1930
  };
1929
1931
 
1930
- // @public (undocumented)
1931
- export type TextFormattingInputMethodBasic = INPUT_METHOD.FORMATTING | INPUT_METHOD.SHORTCUT | TextFormattingInputMethodToolbar;
1932
-
1933
- // @public (undocumented)
1934
- export type TextFormattingInputMethodToolbar = INPUT_METHOD.TOOLBAR;
1932
+ export { TextFormattingInputMethodBasic }
1935
1933
 
1936
- // @public (undocumented)
1937
- interface TextFormattingOptions {
1938
- // (undocumented)
1939
- disableCode?: boolean;
1940
- // (undocumented)
1941
- disableSmartTextCompletion?: boolean;
1942
- // (undocumented)
1943
- disableSuperscriptAndSubscript?: boolean;
1944
- // (undocumented)
1945
- disableUnderline?: boolean;
1946
- // (undocumented)
1947
- responsiveToolbarMenu?: boolean;
1948
- }
1949
-
1950
- // @public (undocumented)
1951
- export interface TextFormattingState {
1952
- // (undocumented)
1953
- codeActive?: boolean;
1954
- // (undocumented)
1955
- codeDisabled?: boolean;
1956
- // (undocumented)
1957
- codeHidden?: boolean;
1958
- // (undocumented)
1959
- emActive?: boolean;
1960
- // (undocumented)
1961
- emDisabled?: boolean;
1962
- // (undocumented)
1963
- emHidden?: boolean;
1964
- // (undocumented)
1965
- strikeActive?: boolean;
1966
- // (undocumented)
1967
- strikeDisabled?: boolean;
1968
- // (undocumented)
1969
- strikeHidden?: boolean;
1970
- // (undocumented)
1971
- strongActive?: boolean;
1972
- // (undocumented)
1973
- strongDisabled?: boolean;
1974
- // (undocumented)
1975
- strongHidden?: boolean;
1976
- // (undocumented)
1977
- subscriptActive?: boolean;
1978
- // (undocumented)
1979
- subscriptDisabled?: boolean;
1980
- // (undocumented)
1981
- subscriptHidden?: boolean;
1982
- // (undocumented)
1983
- superscriptActive?: boolean;
1984
- // (undocumented)
1985
- superscriptDisabled?: boolean;
1986
- // (undocumented)
1987
- superscriptHidden?: boolean;
1988
- // (undocumented)
1989
- underlineActive?: boolean;
1990
- // (undocumented)
1991
- underlineDisabled?: boolean;
1992
- // (undocumented)
1993
- underlineHidden?: boolean;
1994
- }
1934
+ export { TextFormattingInputMethodToolbar }
1995
1935
 
1996
1936
  // @public (undocumented)
1997
- export const textFormattingStateKey: PluginKey<TextFormattingState>;
1937
+ export const textFormattingPlugin: NextEditorPlugin<'textFormatting', {
1938
+ pluginConfiguration: TextFormattingOptions | undefined;
1939
+ dependencies: [OptionalPlugin<typeof analyticsPlugin>];
1940
+ actions: {
1941
+ toggleSuperscript: ToggleMarkWithAnalyticsCommand;
1942
+ toggleSubscript: ToggleMarkWithAnalyticsCommand;
1943
+ toggleStrike: ToggleMarkWithAnalyticsCommand;
1944
+ toggleCode: ToggleMarkWithAnalyticsCommand;
1945
+ toggleUnderline: ToggleMarkWithAnalyticsCommand;
1946
+ toggleEm: ToggleMarkWithAnalyticsCommand;
1947
+ toggleStrong: ToggleMarkWithAnalyticsCommand;
1948
+ };
1949
+ }>;
1998
1950
 
1999
1951
  // @public (undocumented)
2000
1952
  interface TextSelectionData {
@@ -2007,58 +1959,7 @@ interface TextSelectionData {
2007
1959
  }
2008
1960
 
2009
1961
  // @public (undocumented)
2010
- export const toggleCode: () => Command_2;
2011
-
2012
- // @public (undocumented)
2013
- export const toggleCodeWithAnalytics: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => ({ inputMethod }: {
2014
- inputMethod: TextFormattingInputMethodBasic;
2015
- }) => Command_2;
2016
-
2017
- // @public (undocumented)
2018
- export const toggleEm: () => Command_2;
2019
-
2020
- // @public (undocumented)
2021
- export const toggleEmWithAnalytics: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => ({ inputMethod }: {
2022
- inputMethod: TextFormattingInputMethodBasic;
2023
- }) => Command_2;
2024
-
2025
- // @public (undocumented)
2026
- export const toggleStrike: () => Command_2;
2027
-
2028
- // @public (undocumented)
2029
- export const toggleStrikeWithAnalytics: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => ({ inputMethod }: {
2030
- inputMethod: TextFormattingInputMethodBasic;
2031
- }) => Command_2;
2032
-
2033
- // @public (undocumented)
2034
- export const toggleStrong: () => Command_2;
2035
-
2036
- // @public (undocumented)
2037
- export const toggleStrongWithAnalytics: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => ({ inputMethod }: {
2038
- inputMethod: TextFormattingInputMethodBasic;
2039
- }) => Command_2;
2040
-
2041
- // @public (undocumented)
2042
- export const toggleSubscript: () => Command_2;
2043
-
2044
- // @public (undocumented)
2045
- export const toggleSubscriptWithAnalytics: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => ({ inputMethod }: {
2046
- inputMethod: TextFormattingInputMethodBasic;
2047
- }) => Command_2;
2048
-
2049
- // @public (undocumented)
2050
- export const toggleSuperscript: () => Command_2;
2051
-
2052
- // @public (undocumented)
2053
- export const toggleSuperscriptWithAnalytics: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => ({ inputMethod }: {
2054
- inputMethod: TextFormattingInputMethodBasic;
2055
- }) => Command_2;
2056
-
2057
- // @public (undocumented)
2058
- export const toggleUnderline: () => Command_2;
2059
-
2060
- // @public (undocumented)
2061
- export const toggleUnderlineWithAnalytics: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => ({ inputMethod }: {
1962
+ type ToggleMarkWithAnalyticsCommand = (analyticsMetadata: {
2062
1963
  inputMethod: TextFormattingInputMethodBasic;
2063
1964
  }) => Command_2;
2064
1965
 
@@ -1,15 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
- Object.defineProperty(exports, "__esModule", {
5
- value: true
6
- });
7
- exports.textFormattingStyles = void 0;
8
- var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
9
- var _react = require("@emotion/react");
10
- var _styles = require("@atlaskit/editor-common/styles");
11
- var _templateObject;
12
- var textFormattingStyles = function textFormattingStyles(props) {
13
- return (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n ", "\n"])), (0, _styles.codeMarkSharedStyles)(props));
14
- };
15
- exports.textFormattingStyles = textFormattingStyles;
@@ -1,5 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
@@ -1,95 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.toolbarMessages = void 0;
7
- var _reactIntlNext = require("react-intl-next");
8
- var toolbarMessages = (0, _reactIntlNext.defineMessages)({
9
- underline: {
10
- id: 'fabric.editor.underline',
11
- defaultMessage: 'Underline',
12
- description: 'Whether the text selection has underlined text'
13
- },
14
- strike: {
15
- id: 'fabric.editor.strike',
16
- defaultMessage: 'Strikethrough',
17
- description: 'Whether the text selection has crossed out text'
18
- },
19
- code: {
20
- id: 'fabric.editor.code',
21
- defaultMessage: 'Code',
22
- description: 'Whether the text selection has monospaced/code font'
23
- },
24
- codeOn: {
25
- id: 'fabric.editor.code.on',
26
- defaultMessage: '{textFormattingOff}, Code On',
27
- description: 'Reports that code formatting has been turned on'
28
- },
29
- subscript: {
30
- id: 'fabric.editor.subscript',
31
- defaultMessage: 'Subscript',
32
- description: 'Whether the text selection is written below the line in a slightly smaller size'
33
- },
34
- subscriptOffSuperscriptOn: {
35
- id: 'fabric.editor.subscript.off.superscript.on',
36
- defaultMessage: 'Subscript Off, Superscript On',
37
- description: 'Reports text formatting in case when subscript off and superscript on'
38
- },
39
- superscript: {
40
- id: 'fabric.editor.superscript',
41
- defaultMessage: 'Superscript',
42
- description: 'Whether the text selection is written above the line in a slightly smaller size'
43
- },
44
- superscriptOffSubscriptOn: {
45
- id: 'fabric.editor.superscript.off.subscript.on',
46
- defaultMessage: 'Superscript Off, Subscript On',
47
- description: 'Describe text formatting in case when Superscript Off and Subscript on'
48
- },
49
- clearFormatting: {
50
- id: 'fabric.editor.clearFormatting',
51
- defaultMessage: 'Clear formatting',
52
- description: 'Remove all rich text formatting from the selected text'
53
- },
54
- moreFormatting: {
55
- id: 'fabric.editor.moreFormatting',
56
- defaultMessage: 'More formatting',
57
- description: 'Clicking this will show a menu with additional formatting options'
58
- },
59
- bold: {
60
- id: 'fabric.editor.bold',
61
- defaultMessage: 'Bold',
62
- description: 'This refers to bold or “strong” formatting, indicates that its contents have strong importance, seriousness, or urgency.'
63
- },
64
- italic: {
65
- id: 'fabric.editor.italic',
66
- defaultMessage: 'Italic',
67
- description: 'This refers to italics or emphasized formatting.'
68
- },
69
- on: {
70
- id: 'fabric.editor.on',
71
- defaultMessage: '{formattingType} On',
72
- description: 'Reports that text formatting has been turned on'
73
- },
74
- off: {
75
- id: 'fabric.editor.off',
76
- defaultMessage: '{formattingType} Off',
77
- description: 'Reports that text formatting has been turned off'
78
- },
79
- textFormattingOff: {
80
- id: 'fabric.editor.text.formatting.off',
81
- defaultMessage: 'Text formatting Off',
82
- description: 'Reports that text formatting has been turned off'
83
- },
84
- navigateToEditorToolbar: {
85
- id: 'fabric.editor.navigate.toolbar.editor',
86
- defaultMessage: 'Navigate to editor toolbar',
87
- description: 'Navigate to the main editor toolbar.'
88
- },
89
- navigateToFloatingToolbar: {
90
- id: 'fabric.editor.navigate.toolbar.floating',
91
- defaultMessage: 'Navigate to floating toolbar',
92
- description: 'Navigate to a floating toolbar for relevant nodes (e.g. tables or panels).'
93
- }
94
- });
95
- exports.toolbarMessages = toolbarMessages;
@@ -1,5 +0,0 @@
1
- import { css } from '@emotion/react';
2
- import { codeMarkSharedStyles } from '@atlaskit/editor-common/styles';
3
- export const textFormattingStyles = props => css`
4
- ${codeMarkSharedStyles(props)}
5
- `;
@@ -1 +0,0 @@
1
- export {};
@@ -1,88 +0,0 @@
1
- import { defineMessages } from 'react-intl-next';
2
- export const toolbarMessages = defineMessages({
3
- underline: {
4
- id: 'fabric.editor.underline',
5
- defaultMessage: 'Underline',
6
- description: 'Whether the text selection has underlined text'
7
- },
8
- strike: {
9
- id: 'fabric.editor.strike',
10
- defaultMessage: 'Strikethrough',
11
- description: 'Whether the text selection has crossed out text'
12
- },
13
- code: {
14
- id: 'fabric.editor.code',
15
- defaultMessage: 'Code',
16
- description: 'Whether the text selection has monospaced/code font'
17
- },
18
- codeOn: {
19
- id: 'fabric.editor.code.on',
20
- defaultMessage: '{textFormattingOff}, Code On',
21
- description: 'Reports that code formatting has been turned on'
22
- },
23
- subscript: {
24
- id: 'fabric.editor.subscript',
25
- defaultMessage: 'Subscript',
26
- description: 'Whether the text selection is written below the line in a slightly smaller size'
27
- },
28
- subscriptOffSuperscriptOn: {
29
- id: 'fabric.editor.subscript.off.superscript.on',
30
- defaultMessage: 'Subscript Off, Superscript On',
31
- description: 'Reports text formatting in case when subscript off and superscript on'
32
- },
33
- superscript: {
34
- id: 'fabric.editor.superscript',
35
- defaultMessage: 'Superscript',
36
- description: 'Whether the text selection is written above the line in a slightly smaller size'
37
- },
38
- superscriptOffSubscriptOn: {
39
- id: 'fabric.editor.superscript.off.subscript.on',
40
- defaultMessage: 'Superscript Off, Subscript On',
41
- description: 'Describe text formatting in case when Superscript Off and Subscript on'
42
- },
43
- clearFormatting: {
44
- id: 'fabric.editor.clearFormatting',
45
- defaultMessage: 'Clear formatting',
46
- description: 'Remove all rich text formatting from the selected text'
47
- },
48
- moreFormatting: {
49
- id: 'fabric.editor.moreFormatting',
50
- defaultMessage: 'More formatting',
51
- description: 'Clicking this will show a menu with additional formatting options'
52
- },
53
- bold: {
54
- id: 'fabric.editor.bold',
55
- defaultMessage: 'Bold',
56
- description: 'This refers to bold or “strong” formatting, indicates that its contents have strong importance, seriousness, or urgency.'
57
- },
58
- italic: {
59
- id: 'fabric.editor.italic',
60
- defaultMessage: 'Italic',
61
- description: 'This refers to italics or emphasized formatting.'
62
- },
63
- on: {
64
- id: 'fabric.editor.on',
65
- defaultMessage: '{formattingType} On',
66
- description: 'Reports that text formatting has been turned on'
67
- },
68
- off: {
69
- id: 'fabric.editor.off',
70
- defaultMessage: '{formattingType} Off',
71
- description: 'Reports that text formatting has been turned off'
72
- },
73
- textFormattingOff: {
74
- id: 'fabric.editor.text.formatting.off',
75
- defaultMessage: 'Text formatting Off',
76
- description: 'Reports that text formatting has been turned off'
77
- },
78
- navigateToEditorToolbar: {
79
- id: 'fabric.editor.navigate.toolbar.editor',
80
- defaultMessage: 'Navigate to editor toolbar',
81
- description: 'Navigate to the main editor toolbar.'
82
- },
83
- navigateToFloatingToolbar: {
84
- id: 'fabric.editor.navigate.toolbar.floating',
85
- defaultMessage: 'Navigate to floating toolbar',
86
- description: 'Navigate to a floating toolbar for relevant nodes (e.g. tables or panels).'
87
- }
88
- });
@@ -1,7 +0,0 @@
1
- import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
2
- var _templateObject;
3
- import { css } from '@emotion/react';
4
- import { codeMarkSharedStyles } from '@atlaskit/editor-common/styles';
5
- export var textFormattingStyles = function textFormattingStyles(props) {
6
- return css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n ", "\n"])), codeMarkSharedStyles(props));
7
- };
@@ -1 +0,0 @@
1
- export {};
@@ -1,88 +0,0 @@
1
- import { defineMessages } from 'react-intl-next';
2
- export var toolbarMessages = defineMessages({
3
- underline: {
4
- id: 'fabric.editor.underline',
5
- defaultMessage: 'Underline',
6
- description: 'Whether the text selection has underlined text'
7
- },
8
- strike: {
9
- id: 'fabric.editor.strike',
10
- defaultMessage: 'Strikethrough',
11
- description: 'Whether the text selection has crossed out text'
12
- },
13
- code: {
14
- id: 'fabric.editor.code',
15
- defaultMessage: 'Code',
16
- description: 'Whether the text selection has monospaced/code font'
17
- },
18
- codeOn: {
19
- id: 'fabric.editor.code.on',
20
- defaultMessage: '{textFormattingOff}, Code On',
21
- description: 'Reports that code formatting has been turned on'
22
- },
23
- subscript: {
24
- id: 'fabric.editor.subscript',
25
- defaultMessage: 'Subscript',
26
- description: 'Whether the text selection is written below the line in a slightly smaller size'
27
- },
28
- subscriptOffSuperscriptOn: {
29
- id: 'fabric.editor.subscript.off.superscript.on',
30
- defaultMessage: 'Subscript Off, Superscript On',
31
- description: 'Reports text formatting in case when subscript off and superscript on'
32
- },
33
- superscript: {
34
- id: 'fabric.editor.superscript',
35
- defaultMessage: 'Superscript',
36
- description: 'Whether the text selection is written above the line in a slightly smaller size'
37
- },
38
- superscriptOffSubscriptOn: {
39
- id: 'fabric.editor.superscript.off.subscript.on',
40
- defaultMessage: 'Superscript Off, Subscript On',
41
- description: 'Describe text formatting in case when Superscript Off and Subscript on'
42
- },
43
- clearFormatting: {
44
- id: 'fabric.editor.clearFormatting',
45
- defaultMessage: 'Clear formatting',
46
- description: 'Remove all rich text formatting from the selected text'
47
- },
48
- moreFormatting: {
49
- id: 'fabric.editor.moreFormatting',
50
- defaultMessage: 'More formatting',
51
- description: 'Clicking this will show a menu with additional formatting options'
52
- },
53
- bold: {
54
- id: 'fabric.editor.bold',
55
- defaultMessage: 'Bold',
56
- description: 'This refers to bold or “strong” formatting, indicates that its contents have strong importance, seriousness, or urgency.'
57
- },
58
- italic: {
59
- id: 'fabric.editor.italic',
60
- defaultMessage: 'Italic',
61
- description: 'This refers to italics or emphasized formatting.'
62
- },
63
- on: {
64
- id: 'fabric.editor.on',
65
- defaultMessage: '{formattingType} On',
66
- description: 'Reports that text formatting has been turned on'
67
- },
68
- off: {
69
- id: 'fabric.editor.off',
70
- defaultMessage: '{formattingType} Off',
71
- description: 'Reports that text formatting has been turned off'
72
- },
73
- textFormattingOff: {
74
- id: 'fabric.editor.text.formatting.off',
75
- defaultMessage: 'Text formatting Off',
76
- description: 'Reports that text formatting has been turned off'
77
- },
78
- navigateToEditorToolbar: {
79
- id: 'fabric.editor.navigate.toolbar.editor',
80
- defaultMessage: 'Navigate to editor toolbar',
81
- description: 'Navigate to the main editor toolbar.'
82
- },
83
- navigateToFloatingToolbar: {
84
- id: 'fabric.editor.navigate.toolbar.floating',
85
- defaultMessage: 'Navigate to floating toolbar',
86
- description: 'Navigate to a floating toolbar for relevant nodes (e.g. tables or panels).'
87
- }
88
- });
@@ -1,2 +0,0 @@
1
- import { EditorNextProps, EditorProps } from '../../types/editor-props';
2
- export default function deprecationWarnings(props: EditorProps | EditorNextProps): void;
@@ -1,2 +0,0 @@
1
- import { ThemeProps } from '@atlaskit/theme/types';
2
- export declare const textFormattingStyles: (props: ThemeProps) => import("@emotion/react").SerializedStyles;
@@ -1,30 +0,0 @@
1
- export interface TextFormattingOptions {
2
- disableSuperscriptAndSubscript?: boolean;
3
- disableUnderline?: boolean;
4
- disableCode?: boolean;
5
- disableSmartTextCompletion?: boolean;
6
- responsiveToolbarMenu?: boolean;
7
- }
8
- export interface TextFormattingState {
9
- emActive?: boolean;
10
- emDisabled?: boolean;
11
- emHidden?: boolean;
12
- codeActive?: boolean;
13
- codeDisabled?: boolean;
14
- codeHidden?: boolean;
15
- underlineActive?: boolean;
16
- underlineDisabled?: boolean;
17
- underlineHidden?: boolean;
18
- strikeActive?: boolean;
19
- strikeDisabled?: boolean;
20
- strikeHidden?: boolean;
21
- strongActive?: boolean;
22
- strongDisabled?: boolean;
23
- strongHidden?: boolean;
24
- superscriptActive?: boolean;
25
- superscriptDisabled?: boolean;
26
- superscriptHidden?: boolean;
27
- subscriptActive?: boolean;
28
- subscriptDisabled?: boolean;
29
- subscriptHidden?: boolean;
30
- }