@atlaskit/emoji 69.5.0 → 69.5.2

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 (88) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/afm-cc/tsconfig.json +2 -2
  3. package/dist/cjs/util/analytics/analytics.js +1 -1
  4. package/dist/es2019/util/analytics/analytics.js +1 -1
  5. package/dist/esm/util/analytics/analytics.js +1 -1
  6. package/dist/types/api/EmojiResource.d.ts +25 -25
  7. package/dist/types/api/media/SiteEmojiResource.d.ts +1 -1
  8. package/dist/types/components/common/Emoji.d.ts +37 -37
  9. package/dist/types/components/common/EmojiActions.d.ts +10 -10
  10. package/dist/types/components/common/EmojiDeletePreview.d.ts +3 -3
  11. package/dist/types/components/common/EmojiErrorMessage.d.ts +1 -1
  12. package/dist/types/components/common/EmojiPlaceholder.d.ts +3 -3
  13. package/dist/types/components/common/EmojiRadioButton.d.ts +2 -2
  14. package/dist/types/components/common/EmojiUploadPicker.d.ts +4 -4
  15. package/dist/types/components/common/EmojiUploadPreview.d.ts +3 -3
  16. package/dist/types/components/common/FileChooser.d.ts +3 -3
  17. package/dist/types/components/common/LoadingEmojiComponent.d.ts +1 -1
  18. package/dist/types/components/common/Popup.d.ts +3 -3
  19. package/dist/types/components/common/ResourcedEmojiComponent.d.ts +23 -23
  20. package/dist/types/components/common/RetryableButton.d.ts +4 -4
  21. package/dist/types/components/common/Scrollable.d.ts +2 -2
  22. package/dist/types/components/common/TonePreviewButton.d.ts +2 -2
  23. package/dist/types/components/common/ToneSelector.d.ts +1 -1
  24. package/dist/types/components/common/UfoErrorBoundary.d.ts +1 -1
  25. package/dist/types/components/common/internal-types.d.ts +1 -1
  26. package/dist/types/components/picker/CategorySelector.d.ts +1 -1
  27. package/dist/types/components/picker/EmojiPicker.d.ts +4 -4
  28. package/dist/types/components/picker/EmojiPickerCategoryHeading.d.ts +1 -1
  29. package/dist/types/components/picker/EmojiPickerComponent.d.ts +5 -5
  30. package/dist/types/components/picker/EmojiPickerEmojiRow.d.ts +5 -5
  31. package/dist/types/components/picker/EmojiPickerList.d.ts +20 -20
  32. package/dist/types/components/picker/EmojiPickerListSearch.d.ts +2 -2
  33. package/dist/types/components/picker/EmojiPickerTabPanel.d.ts +1 -1
  34. package/dist/types/components/picker/VirtualList.d.ts +10 -10
  35. package/dist/types/components/typeahead/EmojiTypeAhead.d.ts +3 -3
  36. package/dist/types/components/typeahead/EmojiTypeAheadComponent.d.ts +12 -12
  37. package/dist/types/components/typeahead/EmojiTypeAheadItem.d.ts +3 -3
  38. package/dist/types/components/typeahead/EmojiTypeAheadList.d.ts +1 -1
  39. package/dist/types/components/typeahead/EmojiTypeAheadListContainer.d.ts +1 -1
  40. package/dist/types/components/uploader/EmojiUploadComponent.d.ts +2 -2
  41. package/dist/types/context/EmojiPickerListContext.d.ts +1 -1
  42. package/dist/types/types.d.ts +75 -75
  43. package/dist/types/util/analytics/analytics.d.ts +3 -3
  44. package/dist/types/util/analytics/samplingUfo.d.ts +2 -2
  45. package/dist/types/util/image.d.ts +1 -1
  46. package/dist/types/util/keymaps.d.ts +2 -2
  47. package/dist/types-ts4.5/api/EmojiResource.d.ts +25 -25
  48. package/dist/types-ts4.5/api/media/SiteEmojiResource.d.ts +1 -1
  49. package/dist/types-ts4.5/components/common/Emoji.d.ts +37 -37
  50. package/dist/types-ts4.5/components/common/EmojiActions.d.ts +10 -10
  51. package/dist/types-ts4.5/components/common/EmojiDeletePreview.d.ts +3 -3
  52. package/dist/types-ts4.5/components/common/EmojiErrorMessage.d.ts +1 -1
  53. package/dist/types-ts4.5/components/common/EmojiPlaceholder.d.ts +3 -3
  54. package/dist/types-ts4.5/components/common/EmojiRadioButton.d.ts +2 -2
  55. package/dist/types-ts4.5/components/common/EmojiUploadPicker.d.ts +4 -4
  56. package/dist/types-ts4.5/components/common/EmojiUploadPreview.d.ts +3 -3
  57. package/dist/types-ts4.5/components/common/FileChooser.d.ts +3 -3
  58. package/dist/types-ts4.5/components/common/LoadingEmojiComponent.d.ts +1 -1
  59. package/dist/types-ts4.5/components/common/Popup.d.ts +3 -3
  60. package/dist/types-ts4.5/components/common/ResourcedEmojiComponent.d.ts +23 -23
  61. package/dist/types-ts4.5/components/common/RetryableButton.d.ts +4 -4
  62. package/dist/types-ts4.5/components/common/Scrollable.d.ts +2 -2
  63. package/dist/types-ts4.5/components/common/TonePreviewButton.d.ts +2 -2
  64. package/dist/types-ts4.5/components/common/ToneSelector.d.ts +1 -1
  65. package/dist/types-ts4.5/components/common/UfoErrorBoundary.d.ts +1 -1
  66. package/dist/types-ts4.5/components/common/internal-types.d.ts +1 -1
  67. package/dist/types-ts4.5/components/picker/CategorySelector.d.ts +1 -1
  68. package/dist/types-ts4.5/components/picker/EmojiPicker.d.ts +4 -4
  69. package/dist/types-ts4.5/components/picker/EmojiPickerCategoryHeading.d.ts +1 -1
  70. package/dist/types-ts4.5/components/picker/EmojiPickerComponent.d.ts +5 -5
  71. package/dist/types-ts4.5/components/picker/EmojiPickerEmojiRow.d.ts +5 -5
  72. package/dist/types-ts4.5/components/picker/EmojiPickerList.d.ts +20 -20
  73. package/dist/types-ts4.5/components/picker/EmojiPickerListSearch.d.ts +2 -2
  74. package/dist/types-ts4.5/components/picker/EmojiPickerTabPanel.d.ts +1 -1
  75. package/dist/types-ts4.5/components/picker/VirtualList.d.ts +10 -10
  76. package/dist/types-ts4.5/components/typeahead/EmojiTypeAhead.d.ts +3 -3
  77. package/dist/types-ts4.5/components/typeahead/EmojiTypeAheadComponent.d.ts +12 -12
  78. package/dist/types-ts4.5/components/typeahead/EmojiTypeAheadItem.d.ts +3 -3
  79. package/dist/types-ts4.5/components/typeahead/EmojiTypeAheadList.d.ts +1 -1
  80. package/dist/types-ts4.5/components/typeahead/EmojiTypeAheadListContainer.d.ts +1 -1
  81. package/dist/types-ts4.5/components/uploader/EmojiUploadComponent.d.ts +2 -2
  82. package/dist/types-ts4.5/context/EmojiPickerListContext.d.ts +1 -1
  83. package/dist/types-ts4.5/types.d.ts +75 -75
  84. package/dist/types-ts4.5/util/analytics/analytics.d.ts +3 -3
  85. package/dist/types-ts4.5/util/analytics/samplingUfo.d.ts +2 -2
  86. package/dist/types-ts4.5/util/image.d.ts +1 -1
  87. package/dist/types-ts4.5/util/keymaps.d.ts +2 -2
  88. package/package.json +3 -4
package/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # @atlaskit/emoji
2
2
 
3
+ ## 69.5.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [`0fdcb6f2f96fd`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/0fdcb6f2f96fd) -
8
+ Sorted type and interface props to improve Atlaskit docs
9
+ - Updated dependencies
10
+
11
+ ## 69.5.1
12
+
13
+ ### Patch Changes
14
+
15
+ - Updated dependencies
16
+
3
17
  ## 69.5.0
4
18
 
5
19
  ### Minor Changes
@@ -3,9 +3,9 @@
3
3
  "compilerOptions": {
4
4
  "declaration": true,
5
5
  "target": "es5",
6
- "composite": true,
7
6
  "outDir": "../../../../../confluence/tsDist/@atlaskit__emoji",
8
- "rootDir": "../"
7
+ "rootDir": "../",
8
+ "composite": true
9
9
  },
10
10
  "include": [
11
11
  "../src/**/*.ts",
@@ -20,7 +20,7 @@ var createEvent = function createEvent(eventType, action, actionSubject, actionS
20
20
  actionSubjectId: actionSubjectId,
21
21
  attributes: _objectSpread({
22
22
  packageName: "@atlaskit/emoji",
23
- packageVersion: "69.4.0"
23
+ packageVersion: "69.5.1"
24
24
  }, attributes)
25
25
  };
26
26
  };
@@ -8,7 +8,7 @@ const createEvent = (eventType, action, actionSubject, actionSubjectId, attribut
8
8
  actionSubjectId,
9
9
  attributes: {
10
10
  packageName: "@atlaskit/emoji",
11
- packageVersion: "69.4.0",
11
+ packageVersion: "69.5.1",
12
12
  ...attributes
13
13
  }
14
14
  });
@@ -13,7 +13,7 @@ var createEvent = function createEvent(eventType, action, actionSubject, actionS
13
13
  actionSubjectId: actionSubjectId,
14
14
  attributes: _objectSpread({
15
15
  packageName: "@atlaskit/emoji",
16
- packageVersion: "69.4.0"
16
+ packageVersion: "69.5.1"
17
17
  }, attributes)
18
18
  };
19
19
  };
@@ -13,21 +13,6 @@ interface GetEmojiProviderOptions {
13
13
  }
14
14
  export type { EmojiProvider, UploadingEmojiProvider } from '../types';
15
15
  export interface EmojiResourceConfig {
16
- /**
17
- * The service configuration for remotely recording emoji selections.
18
- * A post will be performed to this URL with the EmojiId as the body.
19
- */
20
- recordConfig?: ServiceConfig;
21
- /**
22
- * This defines the different providers. Later providers will override earlier
23
- * providers when performing shortName based look up.
24
- */
25
- providers: ServiceConfig[];
26
- /**
27
- * Additional configuration:
28
- * * On-demand Fetching - Useful for when a product may prefer manually controlling when providers are fetched
29
- */
30
- options?: Options;
31
16
  /**
32
17
  * Must be set to true to enable upload support in the emoji components.
33
18
  *
@@ -42,24 +27,39 @@ export interface EmojiResourceConfig {
42
27
  */
43
28
  currentUser?: User;
44
29
  /**
45
- * This is specifically used for fetching a meta information of a single emoji.
46
- * Useful for when rendering a single or a subset of emojis on a page that does not require the
47
- * whole provider list to be downloaded.
30
+ * A callback triggered on emoji load failure
48
31
  */
49
- singleEmojiApi?: SingleEmojiApiLoaderConfig;
32
+ onEmojiLoadFail?: EmojiLoadFailCallback;
33
+ /**
34
+ * A callback triggered on emoji load success
35
+ */
36
+ onEmojiLoadSuccess?: EmojiLoadSuccessCallback;
50
37
  /**
51
38
  * Renders an image while the provider is being downloaded to reduce the time
52
39
  * the user is being presented with a placeholder
53
40
  */
54
41
  optimisticImageApi?: OptimisticImageApiLoaderConfig;
55
42
  /**
56
- * A callback triggered on emoji load success
43
+ * Additional configuration:
44
+ * * On-demand Fetching - Useful for when a product may prefer manually controlling when providers are fetched
57
45
  */
58
- onEmojiLoadSuccess?: EmojiLoadSuccessCallback;
46
+ options?: Options;
59
47
  /**
60
- * A callback triggered on emoji load failure
48
+ * This defines the different providers. Later providers will override earlier
49
+ * providers when performing shortName based look up.
61
50
  */
62
- onEmojiLoadFail?: EmojiLoadFailCallback;
51
+ providers: ServiceConfig[];
52
+ /**
53
+ * The service configuration for remotely recording emoji selections.
54
+ * A post will be performed to this URL with the EmojiId as the body.
55
+ */
56
+ recordConfig?: ServiceConfig;
57
+ /**
58
+ * This is specifically used for fetching a meta information of a single emoji.
59
+ * Useful for when rendering a single or a subset of emojis on a page that does not require the
60
+ * whole provider list to be downloaded.
61
+ */
62
+ singleEmojiApi?: SingleEmojiApiLoaderConfig;
63
63
  }
64
64
  export interface OnEmojiProviderChange extends OnProviderChange<EmojiSearchResult, any, void> {
65
65
  }
@@ -67,8 +67,8 @@ export interface Retry<T> {
67
67
  (): Promise<T> | T;
68
68
  }
69
69
  export interface ResolveReject<T> {
70
- resolve(result: T): void;
71
70
  reject(reason?: any): void;
71
+ resolve(result: T): void;
72
72
  }
73
73
  /**
74
74
  * Checks if the emojiProvider can support uploading at a feature level.
@@ -79,8 +79,8 @@ export interface ResolveReject<T> {
79
79
  */
80
80
  export declare const supportsUploadFeature: (emojiProvider: EmojiProvider) => emojiProvider is UploadingEmojiProvider;
81
81
  export interface LastQuery {
82
- query?: string;
83
82
  options?: SearchOptions;
83
+ query?: string;
84
84
  }
85
85
  export declare class EmojiResource extends AbstractResource<string, EmojiSearchResult, any, undefined, SearchOptions> implements EmojiProvider {
86
86
  protected recordConfig?: ServiceConfig;
@@ -11,8 +11,8 @@ export interface EmojiProgessCallback {
11
11
  (progress: EmojiProgress): void;
12
12
  }
13
13
  type TokenisedEmojiRepresentation = {
14
- representation?: EmojiRepresentation;
15
14
  altRepresentation?: EmojiRepresentation;
15
+ representation?: EmojiRepresentation;
16
16
  };
17
17
  export declare const mediaProportionOfProgress: number;
18
18
  export default class SiteEmojiResource {
@@ -6,35 +6,43 @@ import React from 'react';
6
6
  import { type EmojiDescription, type OnEmojiEvent } from '../../types';
7
7
  export interface Props extends Omit<React.HTMLAttributes<HTMLSpanElement>, 'onMouseMove' | 'onFocus'> {
8
8
  /**
9
- * The emoji to render
9
+ * Auto Width takes the constraint of height and enables native scaling based on the emojis image.
10
+ * This is primarily used when rendering emojis for SSR as the component does not know the width and height
11
+ * at the time of the render. It overrides the emoji representations width with 'auto' on the images width attribute
12
+ *
13
+ * Used only for image based emojis
10
14
  */
11
- emoji: EmojiDescription;
15
+ autoWidth?: boolean;
12
16
  /**
13
- * Show the emoji as selected
17
+ * Additional css classes, if required.
14
18
  */
15
- selected?: boolean;
19
+ className?: string;
16
20
  /**
17
- * Automatically show the emoji as selected based on mouse hover.
18
- * CSS, fast, does not require a re-render, but selected state not
19
- * externally controlled via props.
21
+ * Disables lazy load on images
20
22
  */
21
- selectOnHover?: boolean;
23
+ disableLazyLoad?: boolean;
22
24
  /**
23
- * Called when an emoji is selected
25
+ * This should only be set when the emoji is being used in the Editor.
26
+ * Currently when set -- this prevents any aria labels being added.
27
+ * This is acceptable in Editor -- as it uses another technique to announce the emoji nodes.
24
28
  */
25
- onSelected?: OnEmojiEvent;
29
+ editorEmoji?: true;
26
30
  /**
27
- * Called when the mouse moves over the emoji.
31
+ * The emoji to render
28
32
  */
29
- onMouseMove?: OnEmojiEvent;
33
+ emoji: EmojiDescription;
30
34
  /**
31
- * Called when the mouse moves over the emoji.
35
+ * Fits emoji to height in pixels, keeping aspect ratio
32
36
  */
33
- onFocus?: OnEmojiEvent;
37
+ fitToHeight?: number;
34
38
  /**
35
39
  * Called when an emoji is deleted
36
40
  */
37
41
  onDelete?: OnEmojiEvent;
42
+ /**
43
+ * Called when the mouse moves over the emoji.
44
+ */
45
+ onFocus?: OnEmojiEvent;
38
46
  /**
39
47
  * Callback for if an emoji image fails to load.
40
48
  */
@@ -44,44 +52,36 @@ export interface Props extends Omit<React.HTMLAttributes<HTMLSpanElement>, 'onMo
44
52
  */
45
53
  onLoadSuccess?: (emoji: EmojiDescription) => void;
46
54
  /**
47
- * Additional css classes, if required.
55
+ * Called when the mouse moves over the emoji.
48
56
  */
49
- className?: string;
57
+ onMouseMove?: OnEmojiEvent;
50
58
  /**
51
- * Show a tooltip on mouse hover.
59
+ * Called when an emoji is selected
52
60
  */
53
- showTooltip?: boolean;
61
+ onSelected?: OnEmojiEvent;
54
62
  /**
55
- * Show a delete button on mouse hover
56
- * Used only for custom emoji
63
+ * Show the emoji as selected
57
64
  */
58
- showDelete?: boolean;
65
+ selected?: boolean;
59
66
  /**
60
- * Fits emoji to height in pixels, keeping aspect ratio
67
+ * Automatically show the emoji as selected based on mouse hover.
68
+ * CSS, fast, does not require a re-render, but selected state not
69
+ * externally controlled via props.
61
70
  */
62
- fitToHeight?: number;
71
+ selectOnHover?: boolean;
63
72
  /**
64
73
  * Indicates whether emoji is an interactive element (tab index and role) or just a view
65
74
  */
66
75
  shouldBeInteractive?: boolean;
67
76
  /**
68
- * Disables lazy load on images
69
- */
70
- disableLazyLoad?: boolean;
71
- /**
72
- * Auto Width takes the constraint of height and enables native scaling based on the emojis image.
73
- * This is primarily used when rendering emojis for SSR as the component does not know the width and height
74
- * at the time of the render. It overrides the emoji representations width with 'auto' on the images width attribute
75
- *
76
- * Used only for image based emojis
77
+ * Show a delete button on mouse hover
78
+ * Used only for custom emoji
77
79
  */
78
- autoWidth?: boolean;
80
+ showDelete?: boolean;
79
81
  /**
80
- * This should only be set when the emoji is being used in the Editor.
81
- * Currently when set -- this prevents any aria labels being added.
82
- * This is acceptable in Editor -- as it uses another technique to announce the emoji nodes.
82
+ * Show a tooltip on mouse hover.
83
83
  */
84
- editorEmoji?: true;
84
+ showTooltip?: boolean;
85
85
  }
86
86
  export declare const SpriteEmoji: (props: Props) => JSX.Element;
87
87
  export declare const ImageEmoji: (props: Props) => JSX.Element;
@@ -3,24 +3,24 @@ import type { EmojiDescription, EmojiDescriptionWithVariations, Message, OnToneS
3
3
  import { type OnDeleteEmoji } from './EmojiDeletePreview';
4
4
  import { type OnUploadEmoji } from './EmojiUploadPicker';
5
5
  export interface Props {
6
- selectedTone?: ToneSelection;
7
- onToneSelected?: OnToneSelected;
8
- onToneSelectorCancelled?: OnToneSelectorCancelled;
9
- toneEmoji?: EmojiDescriptionWithVariations;
10
- uploading: boolean;
11
- uploadEnabled: boolean;
12
6
  emojiToDelete?: EmojiDescription;
13
7
  initialUploadName?: string;
14
- uploadErrorMessage?: Message;
15
- onUploadCancelled: () => void;
16
- onUploadEmoji: OnUploadEmoji;
8
+ onChange: (value: string) => void;
17
9
  onCloseDelete: () => void;
18
10
  onDeleteEmoji: OnDeleteEmoji;
19
11
  onFileChooserClicked?: () => void;
20
12
  onOpenUpload: () => void;
13
+ onToneSelected?: OnToneSelected;
14
+ onToneSelectorCancelled?: OnToneSelectorCancelled;
15
+ onUploadCancelled: () => void;
16
+ onUploadEmoji: OnUploadEmoji;
21
17
  query?: string;
22
- onChange: (value: string) => void;
23
18
  resultsCount?: number;
19
+ selectedTone?: ToneSelection;
20
+ toneEmoji?: EmojiDescriptionWithVariations;
21
+ uploadEnabled: boolean;
22
+ uploadErrorMessage?: Message;
23
+ uploading: boolean;
24
24
  }
25
25
  export declare const emojiActionsTestId = "emoji-actions";
26
26
  export declare const uploadEmojiTestId = "upload-emoji";
@@ -6,13 +6,13 @@ export interface OnDeleteEmoji {
6
6
  export declare const emojiDeletePreviewTestId = "emoji-delete-preview";
7
7
  export interface Props {
8
8
  emoji: EmojiDescription;
9
- onDeleteEmoji: OnDeleteEmoji;
10
- onCloseDelete: () => void;
11
9
  errorMessage?: string;
10
+ onCloseDelete: () => void;
11
+ onDeleteEmoji: OnDeleteEmoji;
12
12
  }
13
13
  export interface State {
14
- loading: boolean;
15
14
  error: boolean;
15
+ loading: boolean;
16
16
  }
17
17
  declare const _default: import("react").FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps>> & {
18
18
  WrappedComponent: import("react").ComponentType<Props & WrappedComponentProps>;
@@ -1,9 +1,9 @@
1
1
  import type { Message } from '../../types';
2
2
  export type ErrorStyle = 'chooseFile' | 'delete' | 'preview';
3
3
  export interface Props {
4
+ errorStyle: ErrorStyle;
4
5
  message: Message;
5
6
  tooltip?: boolean;
6
- errorStyle: ErrorStyle;
7
7
  }
8
8
  export declare const emojiErrorScreenreaderTestId = "emoji-error-screenreader-message";
9
9
  export declare const emojiErrorMessageTestId = "emoji-error-message";
@@ -1,11 +1,11 @@
1
1
  import type { StrictXCSSProp } from '@atlaskit/css';
2
2
  import type { EmojiImageRepresentation } from '../../types';
3
3
  export interface Props {
4
+ loading?: boolean;
5
+ representation?: EmojiImageRepresentation;
4
6
  shortName: string;
5
- size?: number;
6
7
  showTooltip?: boolean;
7
- representation?: EmojiImageRepresentation;
8
- loading?: boolean;
8
+ size?: number;
9
9
  xcss?: StrictXCSSProp<'backgroundColor', never>;
10
10
  }
11
11
  export declare const emojiPlaceholderTestId: (shortName: string) => string;
@@ -5,11 +5,11 @@
5
5
  import React from 'react';
6
6
  import type { EmojiDescription } from '../../types';
7
7
  export interface Props {
8
+ ariaLabelText?: string;
9
+ defaultChecked?: boolean;
8
10
  emoji: EmojiDescription;
9
11
  onSelected?: () => void;
10
12
  selectOnHover?: boolean;
11
- ariaLabelText?: string;
12
- defaultChecked?: boolean;
13
13
  }
14
14
  export declare const EmojiRadioButton: React.ForwardRefExoticComponent<Props & React.RefAttributes<HTMLInputElement>>;
15
15
  declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<Props & React.RefAttributes<HTMLInputElement>>>;
@@ -7,12 +7,12 @@ export declare const uploadEmojiNameInputTestId = "upload-emoji-name-input";
7
7
  export declare const uploadEmojiComponentTestId = "upload-emoji-component";
8
8
  export declare const cancelEmojiUploadPickerTestId = "cancel-emoji-upload-picker";
9
9
  export interface Props {
10
- onUploadEmoji: OnUploadEmoji;
11
- onUploadCancelled: () => void;
12
- onFileChooserClicked?: () => void;
10
+ disableFocusLock?: boolean;
13
11
  errorMessage?: Message;
14
12
  initialUploadName?: string;
15
- disableFocusLock?: boolean;
13
+ onFileChooserClicked?: () => void;
14
+ onUploadCancelled: () => void;
15
+ onUploadEmoji: OnUploadEmoji;
16
16
  }
17
17
  declare const EmojiUploadPickerComponent: import("react").FC<import("react-intl-next").WithIntlProps<Props & WrappedComponentProps>> & {
18
18
  WrappedComponent: import("react").ComponentType<Props & WrappedComponentProps>;
@@ -2,12 +2,12 @@ import { type WrappedComponentProps } from 'react-intl-next';
2
2
  import type { Message } from '../../types';
3
3
  import { UploadStatus } from './internal-types';
4
4
  export interface EmojiUploadPreviewProps {
5
+ errorMessage?: Message;
5
6
  name: string;
7
+ onAddEmoji: () => void;
8
+ onUploadCancelled: () => void;
6
9
  previewImage: string;
7
10
  uploadStatus?: UploadStatus;
8
- errorMessage?: Message;
9
- onUploadCancelled: () => void;
10
- onAddEmoji: () => void;
11
11
  }
12
12
  export declare const uploadPreviewTestId = "upload-preview";
13
13
  export declare const cancelUploadButtonTestId = "cancel-upload-button";
@@ -1,11 +1,11 @@
1
1
  import React, { type ChangeEventHandler } from 'react';
2
2
  export interface Props {
3
- label: string;
3
+ accept?: string;
4
4
  ariaDescribedBy?: string;
5
+ isDisabled?: boolean;
6
+ label: string;
5
7
  onChange?: ChangeEventHandler<any>;
6
8
  onClick?: () => void;
7
- accept?: string;
8
- isDisabled?: boolean;
9
9
  }
10
10
  export declare const chooseFileButtonTestId = "choose-file-button";
11
11
  export declare const fileUploadInputTestId = "file-upload";
@@ -7,8 +7,8 @@ export interface Props {
7
7
  emojiProvider: Promise<EmojiProvider>;
8
8
  }
9
9
  export interface State {
10
- loadedEmojiProvider?: EmojiProvider;
11
10
  asyncLoadedComponent?: ComponentType<React.PropsWithChildren<any>>;
11
+ loadedEmojiProvider?: EmojiProvider;
12
12
  }
13
13
  /**
14
14
  * A base class for components that don't want to start rendering
@@ -1,12 +1,12 @@
1
1
  import React, { type ReactElement } from 'react';
2
2
  import type { RelativePosition } from '../../types';
3
3
  export interface Props {
4
- target: string | Element;
5
- relativePosition?: RelativePosition;
4
+ children: ReactElement<any>;
6
5
  offsetX?: number;
7
6
  offsetY?: number;
7
+ relativePosition?: RelativePosition;
8
+ target: string | Element;
8
9
  zIndex?: string | number;
9
- children: ReactElement<any>;
10
10
  }
11
11
  declare const Popup: (props: React.PropsWithChildren<Props>) => React.JSX.Element;
12
12
  export default Popup;
@@ -5,14 +5,23 @@ import type { EmojiLoadSuccessCallback, EmojiLoadFailCallback } from '../../api/
5
5
  import { type EmojiId } from '../../types';
6
6
  export interface BaseResourcedEmojiProps {
7
7
  /**
8
- * Emoji to display
8
+ * Custom Fallback allows a custom element or string to be rendered if an emoji fails to be fetched or found.
9
+ * By default it takes the fallback or shortName inside emojiId, but if this prop is set it override the internal
10
+ * fallbacks
11
+ * customFallback<Element | string> else emojiId.fallback else emojiId.shortName.
12
+ * Defaults to `undefined`.
9
13
  */
10
- emojiId: EmojiId;
14
+ customFallback?: JSX.Element | string;
11
15
  /**
12
- * Allows to show the tooltip.
13
- * Defaults to `false`.
16
+ * This should only be set when the emoji is being used in the Editor.
17
+ * Currently when set -- this prevents any aria labels being added.
18
+ * This is acceptable in Editor -- as it uses another technique to announce the emoji nodes.
14
19
  */
15
- showTooltip?: boolean;
20
+ editorEmoji?: true;
21
+ /**
22
+ * Emoji to display
23
+ */
24
+ emojiId: EmojiId;
16
25
  /**
17
26
  * Scales the emoji proportionally to provided hight.
18
27
  * Defaults to `undefined`.
@@ -25,44 +34,35 @@ export interface BaseResourcedEmojiProps {
25
34
  * Defaults to `false`.
26
35
  */
27
36
  optimistic?: boolean;
28
- /**
29
- * Custom Fallback allows a custom element or string to be rendered if an emoji fails to be fetched or found.
30
- * By default it takes the fallback or shortName inside emojiId, but if this prop is set it override the internal
31
- * fallbacks
32
- * customFallback<Element | string> else emojiId.fallback else emojiId.shortName.
33
- * Defaults to `undefined`.
34
- */
35
- customFallback?: JSX.Element | string;
36
37
  /**
37
38
  * Will attempt to render a highly condensed version of the emoji with an image url before showing the meta version.
38
39
  * All that is required for optimistic images to render is an emojiId, imageUrl and sizing props.
39
40
  * Defaults to `undefined`.
40
41
  */
41
42
  optimisticImageURL?: string;
42
- /**
43
- * This should only be set when the emoji is being used in the Editor.
44
- * Currently when set -- this prevents any aria labels being added.
45
- * This is acceptable in Editor -- as it uses another technique to announce the emoji nodes.
46
- */
47
- editorEmoji?: true;
48
43
  /**
49
44
  * allows custom styling to the placeholder component while the emoji is loading.
50
45
  */
51
46
  placeholderXcss?: StrictXCSSProp<'backgroundColor', never>;
47
+ /**
48
+ * Allows to show the tooltip.
49
+ * Defaults to `false`.
50
+ */
51
+ showTooltip?: boolean;
52
52
  }
53
53
  export interface Props extends BaseResourcedEmojiProps {
54
54
  /**
55
55
  * EmojiResource instance that handles fetching of emoji data.
56
56
  */
57
57
  emojiProvider: Promise<EmojiProvider>;
58
- /**
59
- * A callback triggered on emoji load success
60
- */
61
- onEmojiLoadSuccess?: EmojiLoadSuccessCallback;
62
58
  /**
63
59
  * A callback triggered on emoji load failure
64
60
  */
65
61
  onEmojiLoadFail?: EmojiLoadFailCallback;
62
+ /**
63
+ * A callback triggered on emoji load success
64
+ */
65
+ onEmojiLoadSuccess?: EmojiLoadSuccessCallback;
66
66
  }
67
67
  export declare const ResourcedEmojiComponent: ({ emojiProvider, emojiId, showTooltip, customFallback, fitToHeight, optimistic, optimisticImageURL, editorEmoji, placeholderXcss, onEmojiLoadSuccess, onEmojiLoadFail, }: Props) => React.JSX.Element;
68
68
  export default ResourcedEmojiComponent;
@@ -1,11 +1,11 @@
1
1
  export interface Props {
2
- label: string;
3
2
  appearance: string;
4
- error: boolean;
5
- onSubmit: () => void;
6
- loading: boolean;
7
3
  ariaDescribedBy?: string;
8
4
  ariaLabelledBy?: string;
5
+ error: boolean;
6
+ label: string;
7
+ loading: boolean;
8
+ onSubmit: () => void;
9
9
  }
10
10
  export declare const retryUploadButtonTestId = "retry-upload-button";
11
11
  export declare const uploadEmojiButtonTestId = "upload-emoji-button";
@@ -3,11 +3,11 @@ export interface OnScroll {
3
3
  (element: Element, event: UIEvent<any>): void;
4
4
  }
5
5
  export interface Props {
6
+ children?: ReactNode;
6
7
  className?: string;
7
8
  maxHeight?: string;
8
- children?: ReactNode;
9
- onScroll?: OnScroll;
10
9
  onMouseLeave?: MouseEventHandler<any>;
10
+ onScroll?: OnScroll;
11
11
  }
12
12
  export default class Scrollable extends PureComponent<Props, {}> {
13
13
  private scrollableDiv;
@@ -1,12 +1,12 @@
1
1
  import type { EmojiDescription } from '../../types';
2
2
  export declare const tonePreviewTestId = "tone-preview";
3
3
  export interface Props {
4
+ ariaExpanded?: boolean;
5
+ ariaLabelText?: string;
4
6
  emoji: EmojiDescription;
5
7
  isVisible?: boolean;
6
8
  onSelected?: () => void;
7
9
  selectOnHover?: boolean;
8
- ariaLabelText?: string;
9
- ariaExpanded?: boolean;
10
10
  }
11
11
  export declare const TonePreviewButton: import("react").ForwardRefExoticComponent<Props & import("react").RefAttributes<HTMLButtonElement>>;
12
12
  declare const _default: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<Props & import("react").RefAttributes<HTMLButtonElement>>>;
@@ -3,8 +3,8 @@ import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
3
3
  export interface Props {
4
4
  emoji: EmojiDescriptionWithVariations;
5
5
  isVisible: boolean;
6
- onToneSelected: OnToneSelected;
7
6
  onToneClose?: () => void;
7
+ onToneSelected: OnToneSelected;
8
8
  selectedTone?: ToneSelection;
9
9
  }
10
10
  export declare const toneSelectorTestId = "tone-selector";
@@ -1,8 +1,8 @@
1
1
  import React, { type ErrorInfo } from 'react';
2
2
  import type { UFOExperience } from '@atlaskit/ufo';
3
3
  export declare class UfoErrorBoundary extends React.Component<{
4
- experiences: UFOExperience[];
5
4
  children?: React.ReactNode;
5
+ experiences: UFOExperience[];
6
6
  }> {
7
7
  componentDidCatch(error: Error, errorInfo: ErrorInfo): void;
8
8
  render(): React.ReactNode;
@@ -5,8 +5,8 @@ export interface EmojiContext {
5
5
  };
6
6
  }
7
7
  interface FocusIndexes {
8
- rowIndex: number;
9
8
  columnIndex: number;
9
+ rowIndex: number;
10
10
  }
11
11
  export interface EmojiPickerListContextType {
12
12
  currentEmojisFocus: FocusIndexes;
@@ -1,9 +1,9 @@
1
1
  import type { CategoryDescription, OnCategory } from '../../types';
2
2
  import { type CategoryGroupKey, type CategoryId } from './categories';
3
3
  export interface Props {
4
- dynamicCategories?: CategoryId[];
5
4
  activeCategoryId?: CategoryId | null;
6
5
  disableCategories?: boolean;
6
+ dynamicCategories?: CategoryId[];
7
7
  onCategorySelected?: OnCategory;
8
8
  }
9
9
  export type CategoryMap = {
@@ -12,17 +12,17 @@ import type { PickerRefHandler, Props as ComponentProps } from './EmojiPickerCom
12
12
  export declare const preloadEmojiPicker: () => void;
13
13
  export interface Props extends LoadingProps {
14
14
  /**
15
- * Callback to be executed on emoji selection.
15
+ * Flag to disable tone selector.
16
16
  */
17
- onSelection?: OnEmojiEvent;
17
+ hideToneSelector?: boolean;
18
18
  /**
19
19
  * Callback to handle picker reference.
20
20
  */
21
21
  onPickerRef?: PickerRefHandler;
22
22
  /**
23
- * Flag to disable tone selector.
23
+ * Callback to be executed on emoji selection.
24
24
  */
25
- hideToneSelector?: boolean;
25
+ onSelection?: OnEmojiEvent;
26
26
  /**
27
27
  * Size of Emoji Picker. default value is 'medium'.
28
28
  */