@atlaskit/editor-plugin-alignment 12.0.15 → 13.0.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 (28) hide show
  1. package/CHANGELOG.md +32 -0
  2. package/alignmentPlugin/package.json +1 -8
  3. package/alignmentPluginType/package.json +1 -8
  4. package/package.json +16 -24
  5. package/types/package.json +1 -8
  6. package/dist/types-ts4.5/alignmentPlugin.d.ts +0 -2
  7. package/dist/types-ts4.5/alignmentPluginType.d.ts +0 -22
  8. package/dist/types-ts4.5/editor-commands/index.d.ts +0 -10
  9. package/dist/types-ts4.5/entry-points/alignmentPlugin.d.ts +0 -1
  10. package/dist/types-ts4.5/entry-points/alignmentPluginType.d.ts +0 -1
  11. package/dist/types-ts4.5/entry-points/types.d.ts +0 -1
  12. package/dist/types-ts4.5/index.d.ts +0 -3
  13. package/dist/types-ts4.5/pm-plugins/keymap.d.ts +0 -4
  14. package/dist/types-ts4.5/pm-plugins/main.d.ts +0 -6
  15. package/dist/types-ts4.5/pm-plugins/types.d.ts +0 -9
  16. package/dist/types-ts4.5/pm-plugins/utils/index.d.ts +0 -3
  17. package/dist/types-ts4.5/ui/Alignment/AlignmentButton/index.d.ts +0 -13
  18. package/dist/types-ts4.5/ui/Alignment/index.d.ts +0 -16
  19. package/dist/types-ts4.5/ui/FloatingToolbarComponent.d.ts +0 -10
  20. package/dist/types-ts4.5/ui/PrimaryToolbarComponent.d.ts +0 -15
  21. package/dist/types-ts4.5/ui/Toolbar/AlignmentMenu.d.ts +0 -7
  22. package/dist/types-ts4.5/ui/Toolbar/AlignmentMenuItem.d.ts +0 -12
  23. package/dist/types-ts4.5/ui/Toolbar/MenuSection.d.ts +0 -8
  24. package/dist/types-ts4.5/ui/Toolbar/options.d.ts +0 -3
  25. package/dist/types-ts4.5/ui/Toolbar/types.d.ts +0 -11
  26. package/dist/types-ts4.5/ui/ToolbarAlignment/icon-map.d.ts +0 -6
  27. package/dist/types-ts4.5/ui/ToolbarAlignment/index.d.ts +0 -25
  28. package/dist/types-ts4.5/ui/toolbar-components.d.ts +0 -4
package/CHANGELOG.md CHANGED
@@ -1,5 +1,37 @@
1
1
  # @atlaskit/editor-plugin-alignment
2
2
 
3
+ ## 13.0.0
4
+
5
+ ### Major Changes
6
+
7
+ - [`f2dc9097319f0`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/f2dc9097319f0) - ###
8
+ Dropped support for _legacy_ Typescript 4 types. **Typescript 5 is now the new minimum**.
9
+
10
+ Removes the `typesVersions` property and `dist/types-ts4.5` directory from the dist.
11
+
12
+ Types are now exclusively via the `"types": "dist/types/index.d.ts"` property.
13
+
14
+ ```diff
15
+ - "typesVersions": {
16
+ - ">=4.5 <4.9": {
17
+ - "*": [
18
+ - "dist/types-ts4.5/*",
19
+ - "dist/types-ts4.5/index.d.ts"
20
+ - ]
21
+ - }
22
+ - },
23
+ ```
24
+
25
+ ### Patch Changes
26
+
27
+ - Updated dependencies
28
+
29
+ ## 12.0.16
30
+
31
+ ### Patch Changes
32
+
33
+ - Updated dependencies
34
+
3
35
  ## 12.0.15
4
36
 
5
37
  ### Patch Changes
@@ -6,12 +6,5 @@
6
6
  "sideEffects": [
7
7
  "**/*.compiled.css"
8
8
  ],
9
- "types": "../dist/types/entry-points/alignmentPlugin.d.ts",
10
- "typesVersions": {
11
- ">=4.5 <5.9": {
12
- "*": [
13
- "../dist/types-ts4.5/entry-points/alignmentPlugin.d.ts"
14
- ]
15
- }
16
- }
9
+ "types": "../dist/types/entry-points/alignmentPlugin.d.ts"
17
10
  }
@@ -6,12 +6,5 @@
6
6
  "sideEffects": [
7
7
  "**/*.compiled.css"
8
8
  ],
9
- "types": "../dist/types/entry-points/alignmentPluginType.d.ts",
10
- "typesVersions": {
11
- ">=4.5 <5.9": {
12
- "*": [
13
- "../dist/types-ts4.5/entry-points/alignmentPluginType.d.ts"
14
- ]
15
- }
16
- }
9
+ "types": "../dist/types/entry-points/alignmentPluginType.d.ts"
17
10
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-alignment",
3
- "version": "12.0.15",
3
+ "version": "13.0.0",
4
4
  "description": "Alignment plugin for @atlaskit/editor-core",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -26,25 +26,25 @@
26
26
  }
27
27
  },
28
28
  "dependencies": {
29
- "@atlaskit/adf-schema": "^54.0.0",
30
- "@atlaskit/css": "^0.19.0",
31
- "@atlaskit/editor-plugin-analytics": "^11.0.0",
32
- "@atlaskit/editor-plugin-interaction": "^20.0.0",
33
- "@atlaskit/editor-plugin-primary-toolbar": "^12.0.0",
34
- "@atlaskit/editor-plugin-selection-toolbar": "^12.0.0",
35
- "@atlaskit/editor-plugin-toolbar": "^8.0.0",
36
- "@atlaskit/editor-prosemirror": "^7.3.0",
37
- "@atlaskit/editor-tables": "^2.10.0",
38
- "@atlaskit/editor-toolbar": "^1.10.0",
39
- "@atlaskit/icon": "^35.4.0",
40
- "@atlaskit/platform-feature-flags": "^1.1.0",
41
- "@atlaskit/tmp-editor-statsig": "^102.0.0",
42
- "@atlaskit/tokens": "^13.4.0",
29
+ "@atlaskit/adf-schema": "^55.0.0",
30
+ "@atlaskit/css": "^1.0.0",
31
+ "@atlaskit/editor-plugin-analytics": "^12.0.0",
32
+ "@atlaskit/editor-plugin-interaction": "^21.0.0",
33
+ "@atlaskit/editor-plugin-primary-toolbar": "^13.0.0",
34
+ "@atlaskit/editor-plugin-selection-toolbar": "^13.0.0",
35
+ "@atlaskit/editor-plugin-toolbar": "^9.0.0",
36
+ "@atlaskit/editor-prosemirror": "^8.0.0",
37
+ "@atlaskit/editor-tables": "^3.0.0",
38
+ "@atlaskit/editor-toolbar": "^2.0.0",
39
+ "@atlaskit/icon": "^36.0.0",
40
+ "@atlaskit/platform-feature-flags": "^2.0.0",
41
+ "@atlaskit/tmp-editor-statsig": "^104.0.0",
42
+ "@atlaskit/tokens": "^14.0.0",
43
43
  "@babel/runtime": "^7.0.0",
44
44
  "@compiled/react": "^0.20.0"
45
45
  },
46
46
  "peerDependencies": {
47
- "@atlaskit/editor-common": "^115.15.0",
47
+ "@atlaskit/editor-common": "^116.0.0",
48
48
  "react": "^18.2.0",
49
49
  "react-dom": "^18.2.0",
50
50
  "react-intl": "^5.25.1 || ^6.0.0 || ^7.0.0"
@@ -91,13 +91,5 @@
91
91
  "import-no-extraneous-disable-for-examples-and-docs"
92
92
  ]
93
93
  }
94
- },
95
- "typesVersions": {
96
- ">=4.5 <4.9": {
97
- "*": [
98
- "dist/types-ts4.5/*",
99
- "dist/types-ts4.5/index.d.ts"
100
- ]
101
- }
102
94
  }
103
95
  }
@@ -6,12 +6,5 @@
6
6
  "sideEffects": [
7
7
  "**/*.compiled.css"
8
8
  ],
9
- "types": "../dist/types/entry-points/types.d.ts",
10
- "typesVersions": {
11
- ">=4.5 <5.9": {
12
- "*": [
13
- "../dist/types-ts4.5/entry-points/types.d.ts"
14
- ]
15
- }
16
- }
9
+ "types": "../dist/types/entry-points/types.d.ts"
17
10
  }
@@ -1,2 +0,0 @@
1
- import type { AlignmentPlugin } from './alignmentPluginType';
2
- export declare const alignmentPlugin: AlignmentPlugin;
@@ -1,22 +0,0 @@
1
- import type { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
2
- import type { NextEditorPlugin, OptionalPlugin } from '@atlaskit/editor-common/types';
3
- import type { AnalyticsPlugin } from '@atlaskit/editor-plugin-analytics';
4
- import type { InteractionPlugin } from '@atlaskit/editor-plugin-interaction';
5
- import type { PrimaryToolbarPlugin } from '@atlaskit/editor-plugin-primary-toolbar';
6
- import type { SelectionToolbarPlugin } from '@atlaskit/editor-plugin-selection-toolbar';
7
- import type { ToolbarPlugin } from '@atlaskit/editor-plugin-toolbar';
8
- import type { UserPreferencesPlugin } from '@atlaskit/editor-plugin-user-preferences';
9
- import type { AlignmentPluginState } from './pm-plugins/types';
10
- export type AlignmentPluginDependencies = [
11
- OptionalPlugin<PrimaryToolbarPlugin>,
12
- OptionalPlugin<SelectionToolbarPlugin>,
13
- OptionalPlugin<AnalyticsPlugin>,
14
- OptionalPlugin<UserPreferencesPlugin>,
15
- OptionalPlugin<ToolbarPlugin>,
16
- OptionalPlugin<InteractionPlugin>
17
- ];
18
- export type AlignmentPlugin = NextEditorPlugin<'alignment', {
19
- dependencies: AlignmentPluginDependencies;
20
- sharedState: AlignmentPluginState | undefined;
21
- }>;
22
- export type InputMethod = INPUT_METHOD.TOOLBAR | INPUT_METHOD.FLOATING_TB | INPUT_METHOD.SHORTCUT;
@@ -1,10 +0,0 @@
1
- import type { Command, EditorCommand, ExtractInjectionAPI } from '@atlaskit/editor-common/types';
2
- import type { AlignmentPlugin, InputMethod } from '../alignmentPluginType';
3
- import type { AlignmentState } from '../pm-plugins/types';
4
- export declare const isAlignable: (align?: AlignmentState) => Command;
5
- /**
6
- *
7
- * @deprecated use changeAlignmentTr instead
8
- */
9
- export declare const changeAlignment: (align?: AlignmentState, api?: ExtractInjectionAPI<AlignmentPlugin>, inputMethod?: InputMethod) => Command;
10
- export declare const changeAlignmentTr: (api: ExtractInjectionAPI<AlignmentPlugin> | undefined, align?: AlignmentState, inputMethod?: InputMethod) => EditorCommand;
@@ -1 +0,0 @@
1
- export { alignmentPlugin } from '../alignmentPlugin';
@@ -1 +0,0 @@
1
- export type { AlignmentPlugin, AlignmentPluginDependencies } from '../alignmentPluginType';
@@ -1 +0,0 @@
1
- export type { AlignmentPluginState } from '../pm-plugins/types';
@@ -1,3 +0,0 @@
1
- export { alignmentPlugin } from './alignmentPlugin';
2
- export type { AlignmentPlugin, AlignmentPluginDependencies } from './alignmentPluginType';
3
- export type { AlignmentPluginState } from './pm-plugins/types';
@@ -1,4 +0,0 @@
1
- import type { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
2
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
- import type { AlignmentPlugin } from '../alignmentPluginType';
4
- export declare function keymapPlugin(api?: ExtractInjectionAPI<AlignmentPlugin>): SafePlugin;
@@ -1,6 +0,0 @@
1
- import type { Dispatch } from '@atlaskit/editor-common/event-dispatcher';
2
- import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
3
- import { PluginKey } from '@atlaskit/editor-prosemirror/state';
4
- import type { AlignmentPluginState } from './types';
5
- export declare const pluginKey: PluginKey<AlignmentPluginState>;
6
- export declare function createPlugin(dispatch: Dispatch, pluginConfig: AlignmentPluginState): SafePlugin<AlignmentPluginState>;
@@ -1,9 +0,0 @@
1
- export type AlignmentState = 'start' | 'end' | 'center';
2
- export type AlignmentPluginState = {
3
- align: AlignmentState;
4
- isEnabled?: boolean;
5
- };
6
- export declare enum ToolbarType {
7
- PRIMARY = "primaryToolbar",
8
- FLOATING = "floatingToolbar"
9
- }
@@ -1,3 +0,0 @@
1
- import type { EditorState } from '@atlaskit/editor-prosemirror/state';
2
- import type { AlignmentState } from '../types';
3
- export declare const getActiveAlignment: (state: EditorState) => AlignmentState | undefined;
@@ -1,13 +0,0 @@
1
- import React from 'react';
2
- import type { Keymap } from '@atlaskit/editor-common/keymaps';
3
- import type { AlignmentState } from '../../../pm-plugins/types';
4
- export interface Props {
5
- content: React.ReactElement;
6
- isSelected?: boolean;
7
- label: string;
8
- onClick: (value: AlignmentState, shouldClosePopup: boolean) => void;
9
- shortcut?: Keymap;
10
- value: AlignmentState;
11
- }
12
- declare function AlignmentButton({ label, isSelected, content, shortcut, onClick, value, }: Props): React.JSX.Element;
13
- export default AlignmentButton;
@@ -1,16 +0,0 @@
1
- /**
2
- * @jsxRuntime classic
3
- * @jsx jsx
4
- */
5
- import type { FC, ComponentType } from 'react';
6
- import type { WithIntlProps, WrappedComponentProps } from 'react-intl';
7
- import type { AlignmentState } from '../../pm-plugins/types';
8
- export interface Props {
9
- className?: string;
10
- onClick: (value: AlignmentState) => void;
11
- selectedAlignment?: string;
12
- }
13
- declare const _default_1: FC<WithIntlProps<Props & WrappedComponentProps>> & {
14
- WrappedComponent: ComponentType<Props & WrappedComponentProps>;
15
- };
16
- export default _default_1;
@@ -1,10 +0,0 @@
1
- import React from 'react';
2
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
- import type { EditorView } from '@atlaskit/editor-prosemirror/view';
4
- import type { AlignmentPlugin } from '../alignmentPluginType';
5
- interface FloatingToolbarComponentProps {
6
- api: ExtractInjectionAPI<AlignmentPlugin> | undefined;
7
- editorView: EditorView;
8
- }
9
- export declare function FloatingToolbarComponent({ api, editorView, }: FloatingToolbarComponentProps): React.JSX.Element;
10
- export {};
@@ -1,15 +0,0 @@
1
- import React from 'react';
2
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
- import type { EditorView } from '@atlaskit/editor-prosemirror/view';
4
- import type { AlignmentPlugin } from '../alignmentPluginType';
5
- interface PrimaryToolbarComponentProps {
6
- api: ExtractInjectionAPI<AlignmentPlugin> | undefined;
7
- disabled: boolean;
8
- editorView: EditorView;
9
- isToolbarReducedSpacing: boolean;
10
- popupsBoundariesElement?: HTMLElement;
11
- popupsMountPoint?: HTMLElement;
12
- popupsScrollableElement?: HTMLElement;
13
- }
14
- export declare function PrimaryToolbarComponent({ api, editorView, disabled, popupsMountPoint, popupsBoundariesElement, popupsScrollableElement, isToolbarReducedSpacing, }: PrimaryToolbarComponentProps): React.JSX.Element;
15
- export {};
@@ -1,7 +0,0 @@
1
- import React from 'react';
2
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
- import type { AlignmentPlugin } from '../../alignmentPluginType';
4
- export declare const AlignmentMenu: ({ children, api, }: {
5
- api: ExtractInjectionAPI<AlignmentPlugin> | undefined;
6
- children?: React.ReactNode;
7
- }) => React.JSX.Element;
@@ -1,12 +0,0 @@
1
- import React from 'react';
2
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
- import type { ToolbarComponentTypes } from '@atlaskit/editor-toolbar-model';
4
- import type { AlignmentPlugin } from '../../alignmentPluginType';
5
- import type { AlignmentState } from '../../pm-plugins/types';
6
- import type { OptionInfo } from './types';
7
- export declare const AlignmentMenuItem: ({ option: { label, icon: Icon, keymap }, api, alignment, parents, }: {
8
- alignment: AlignmentState;
9
- api: ExtractInjectionAPI<AlignmentPlugin> | undefined;
10
- option: OptionInfo;
11
- parents: ToolbarComponentTypes;
12
- }) => React.JSX.Element;
@@ -1,8 +0,0 @@
1
- import React from 'react';
2
- import type { ReactNode } from 'react';
3
- import type { CommonComponentProps } from '@atlaskit/editor-toolbar-model';
4
- export declare const MenuSection: ({ children, title, parents, }: {
5
- children?: ReactNode;
6
- parents: CommonComponentProps["parents"];
7
- title?: string;
8
- }) => React.JSX.Element;
@@ -1,3 +0,0 @@
1
- import type { AlignmentState } from '../../pm-plugins/types';
2
- import type { OptionInfo } from './types';
3
- export declare const alignmentOptions: () => Record<AlignmentState, OptionInfo>;
@@ -1,11 +0,0 @@
1
- import type { MessageDescriptor } from 'react-intl';
2
- import type { Keymap } from '@atlaskit/editor-common/keymaps';
3
- import type { IconComponent } from '@atlaskit/editor-toolbar';
4
- export type OptionInfo = {
5
- icon: IconComponent;
6
- key: string;
7
- keymap: Keymap;
8
- label: MessageDescriptor;
9
- rank: number;
10
- type: 'menu-item';
11
- };
@@ -1,6 +0,0 @@
1
- import React from 'react';
2
- type Props = {
3
- alignment: string;
4
- };
5
- export declare const IconMap: (props: Props) => React.JSX.Element;
6
- export {};
@@ -1,25 +0,0 @@
1
- /**
2
- * @jsxRuntime classic
3
- * @jsx jsx
4
- */
5
- import React from 'react';
6
- import type { WithIntlProps, WrappedComponentProps } from 'react-intl';
7
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
8
- import type { AlignmentPlugin } from '../../alignmentPluginType';
9
- import { ToolbarType } from '../../pm-plugins/types';
10
- import type { AlignmentState } from '../../pm-plugins/types';
11
- export interface Props {
12
- align: AlignmentState | undefined;
13
- api: ExtractInjectionAPI<AlignmentPlugin> | undefined;
14
- changeAlignment: (align: AlignmentState) => void;
15
- disabled?: boolean;
16
- isReducedSpacing?: boolean;
17
- popupsBoundariesElement?: HTMLElement;
18
- popupsMountPoint?: HTMLElement;
19
- popupsScrollableElement?: HTMLElement;
20
- toolbarType: ToolbarType;
21
- }
22
- declare const _default_1: React.FC<WithIntlProps<Props & WrappedComponentProps>> & {
23
- WrappedComponent: React.ComponentType<Props & WrappedComponentProps>;
24
- };
25
- export default _default_1;
@@ -1,4 +0,0 @@
1
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
2
- import type { RegisterComponent } from '@atlaskit/editor-toolbar-model';
3
- import type { AlignmentPlugin } from '../alignmentPluginType';
4
- export declare const getToolbarComponents: (api: ExtractInjectionAPI<AlignmentPlugin> | undefined) => RegisterComponent[];