@atlaskit/media-ui 25.2.0 → 25.3.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @atlaskit/media-ui
2
2
 
3
+ ## 25.3.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#77668](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/77668) [`c8a08df51a9f`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/c8a08df51a9f) - Add password protected pdf support for media viewer
8
+
3
9
  ## 25.2.0
4
10
 
5
11
  ### Minor Changes
@@ -52,7 +52,7 @@ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflec
52
52
  function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */ // Keep media player components used in media-viewer to use static colors from the new color palette to
53
53
  // support the hybrid theming in media viewer https://product-fabric.atlassian.net/browse/DSP-6067
54
54
  var packageName = "@atlaskit/media-ui";
55
- var packageVersion = "25.2.0";
55
+ var packageVersion = "25.3.0";
56
56
  var MEDIUM_VIDEO_MAX_WIDTH = 400;
57
57
  var SMALL_VIDEO_MAX_WIDTH = 160;
58
58
  var MINIMUM_DURATION_BEFORE_SAVING_TIME = 60;
@@ -326,6 +326,26 @@ var messages = exports.messages = (0, _reactIntlNext.defineMessages)({
326
326
  defaultMessage: 'No PDF artifacts found for this file.',
327
327
  description: 'Error case for when we cant preview a PDF file'
328
328
  },
329
+ password_protected_pdf: {
330
+ id: 'fabric.media.password_protected_pdf',
331
+ defaultMessage: 'This file is password protected.',
332
+ description: 'Describing that a PDF cannot be viewed because it is protected by password'
333
+ },
334
+ enter_password: {
335
+ id: 'fabric.media.enter_password',
336
+ defaultMessage: 'Enter password',
337
+ description: 'Prompting user to enter the password.'
338
+ },
339
+ incorrect_password: {
340
+ id: 'fabric.media.incorrect_password',
341
+ defaultMessage: 'Incorrect password. Please try again.',
342
+ description: 'Error case for when a wrong password is inputted.'
343
+ },
344
+ submit: {
345
+ id: 'fabric.media.submit',
346
+ defaultMessage: 'Submit',
347
+ description: 'Description for a button to submit the form.'
348
+ },
329
349
  give_feedback: {
330
350
  id: 'fabric.media.give_feedback',
331
351
  defaultMessage: 'Give feedback',
@@ -31,6 +31,7 @@ var Shortcut = exports.Shortcut = /*#__PURE__*/function (_Component) {
31
31
  args[_key] = arguments[_key];
32
32
  }
33
33
  _this = _super.call.apply(_super, [this].concat(args));
34
+ (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "eventType", 'keydown');
34
35
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "keyHandler", function (e) {
35
36
  var _this$props = _this.props,
36
37
  handler = _this$props.handler,
@@ -40,10 +41,13 @@ var Shortcut = exports.Shortcut = /*#__PURE__*/function (_Component) {
40
41
  }
41
42
  });
42
43
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "init", function () {
43
- document.addEventListener('keydown', _this.keyHandler);
44
+ var _this$props$eventType = _this.props.eventType,
45
+ eventType = _this$props$eventType === void 0 ? 'keydown' : _this$props$eventType;
46
+ _this.eventType = eventType;
47
+ document.addEventListener(_this.eventType, _this.keyHandler);
44
48
  });
45
49
  (0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "release", function () {
46
- document.removeEventListener('keydown', _this.keyHandler);
50
+ document.removeEventListener(_this.eventType, _this.keyHandler);
47
51
  });
48
52
  return _this;
49
53
  }
@@ -35,7 +35,7 @@ import Tooltip from '@atlaskit/tooltip';
35
35
  import { SkipTenBackwardIcon, SkipTenForwardIcon } from './icons';
36
36
  import { getControlsWrapperClassName } from './getControlsWrapperClassName';
37
37
  const packageName = "@atlaskit/media-ui";
38
- const packageVersion = "25.2.0";
38
+ const packageVersion = "25.3.0";
39
39
  const MEDIUM_VIDEO_MAX_WIDTH = 400;
40
40
  const SMALL_VIDEO_MAX_WIDTH = 160;
41
41
  const MINIMUM_DURATION_BEFORE_SAVING_TIME = 60;
@@ -320,6 +320,26 @@ export const messages = defineMessages({
320
320
  defaultMessage: 'No PDF artifacts found for this file.',
321
321
  description: 'Error case for when we cant preview a PDF file'
322
322
  },
323
+ password_protected_pdf: {
324
+ id: 'fabric.media.password_protected_pdf',
325
+ defaultMessage: 'This file is password protected.',
326
+ description: 'Describing that a PDF cannot be viewed because it is protected by password'
327
+ },
328
+ enter_password: {
329
+ id: 'fabric.media.enter_password',
330
+ defaultMessage: 'Enter password',
331
+ description: 'Prompting user to enter the password.'
332
+ },
333
+ incorrect_password: {
334
+ id: 'fabric.media.incorrect_password',
335
+ defaultMessage: 'Incorrect password. Please try again.',
336
+ description: 'Error case for when a wrong password is inputted.'
337
+ },
338
+ submit: {
339
+ id: 'fabric.media.submit',
340
+ defaultMessage: 'Submit',
341
+ description: 'Description for a button to submit the form.'
342
+ },
323
343
  give_feedback: {
324
344
  id: 'fabric.media.give_feedback',
325
345
  defaultMessage: 'Give feedback',
@@ -9,6 +9,7 @@ export const keyCodes = {
9
9
  export class Shortcut extends Component {
10
10
  constructor(...args) {
11
11
  super(...args);
12
+ _defineProperty(this, "eventType", 'keydown');
12
13
  _defineProperty(this, "keyHandler", e => {
13
14
  const {
14
15
  handler,
@@ -19,10 +20,14 @@ export class Shortcut extends Component {
19
20
  }
20
21
  });
21
22
  _defineProperty(this, "init", () => {
22
- document.addEventListener('keydown', this.keyHandler);
23
+ const {
24
+ eventType = 'keydown'
25
+ } = this.props;
26
+ this.eventType = eventType;
27
+ document.addEventListener(this.eventType, this.keyHandler);
23
28
  });
24
29
  _defineProperty(this, "release", () => {
25
- document.removeEventListener('keydown', this.keyHandler);
30
+ document.removeEventListener(this.eventType, this.keyHandler);
26
31
  });
27
32
  }
28
33
  componentDidMount() {
@@ -45,7 +45,7 @@ import Tooltip from '@atlaskit/tooltip';
45
45
  import { SkipTenBackwardIcon, SkipTenForwardIcon } from './icons';
46
46
  import { getControlsWrapperClassName } from './getControlsWrapperClassName';
47
47
  var packageName = "@atlaskit/media-ui";
48
- var packageVersion = "25.2.0";
48
+ var packageVersion = "25.3.0";
49
49
  var MEDIUM_VIDEO_MAX_WIDTH = 400;
50
50
  var SMALL_VIDEO_MAX_WIDTH = 160;
51
51
  var MINIMUM_DURATION_BEFORE_SAVING_TIME = 60;
@@ -320,6 +320,26 @@ export var messages = defineMessages({
320
320
  defaultMessage: 'No PDF artifacts found for this file.',
321
321
  description: 'Error case for when we cant preview a PDF file'
322
322
  },
323
+ password_protected_pdf: {
324
+ id: 'fabric.media.password_protected_pdf',
325
+ defaultMessage: 'This file is password protected.',
326
+ description: 'Describing that a PDF cannot be viewed because it is protected by password'
327
+ },
328
+ enter_password: {
329
+ id: 'fabric.media.enter_password',
330
+ defaultMessage: 'Enter password',
331
+ description: 'Prompting user to enter the password.'
332
+ },
333
+ incorrect_password: {
334
+ id: 'fabric.media.incorrect_password',
335
+ defaultMessage: 'Incorrect password. Please try again.',
336
+ description: 'Error case for when a wrong password is inputted.'
337
+ },
338
+ submit: {
339
+ id: 'fabric.media.submit',
340
+ defaultMessage: 'Submit',
341
+ description: 'Description for a button to submit the form.'
342
+ },
323
343
  give_feedback: {
324
344
  id: 'fabric.media.give_feedback',
325
345
  defaultMessage: 'Give feedback',
@@ -24,6 +24,7 @@ export var Shortcut = /*#__PURE__*/function (_Component) {
24
24
  args[_key] = arguments[_key];
25
25
  }
26
26
  _this = _super.call.apply(_super, [this].concat(args));
27
+ _defineProperty(_assertThisInitialized(_this), "eventType", 'keydown');
27
28
  _defineProperty(_assertThisInitialized(_this), "keyHandler", function (e) {
28
29
  var _this$props = _this.props,
29
30
  handler = _this$props.handler,
@@ -33,10 +34,13 @@ export var Shortcut = /*#__PURE__*/function (_Component) {
33
34
  }
34
35
  });
35
36
  _defineProperty(_assertThisInitialized(_this), "init", function () {
36
- document.addEventListener('keydown', _this.keyHandler);
37
+ var _this$props$eventType = _this.props.eventType,
38
+ eventType = _this$props$eventType === void 0 ? 'keydown' : _this$props$eventType;
39
+ _this.eventType = eventType;
40
+ document.addEventListener(_this.eventType, _this.keyHandler);
37
41
  });
38
42
  _defineProperty(_assertThisInitialized(_this), "release", function () {
39
- document.removeEventListener('keydown', _this.keyHandler);
43
+ document.removeEventListener(_this.eventType, _this.keyHandler);
40
44
  });
41
45
  return _this;
42
46
  }
@@ -1,6 +1,6 @@
1
1
  import { MessageDescriptor } from 'react-intl-next';
2
2
  export type RequestAccessMessageKey = 'request_access_description' | 'click_to_join_description' | 'request_access_pending_description' | 'click_to_join' | 'request_access' | 'request_access_pending' | 'forbidden_description' | 'request_denied_description';
3
- export type MessageKey = 'retry' | 'failed_to_load' | 'failed_to_upload' | 'recent_uploads' | 'upload_file' | 'drag_and_drop_your_files' | 'drag_and_drop_your_files_and_folders' | 'drop_your_files' | 'upload' | 'cancel' | 'search_all_gifs' | 'cant_retrieve_gifs' | 'cant_retrieve_files' | 'check_your_network' | 'try_again' | 'try_another_account' | 'no_gifs_found' | 'no_gifs_found_suggestion' | 'load_more_gifs' | 'add_account' | 'unlink_account' | 'upload_file_from' | 'connect_to' | 'connect_account_description' | 'connect_link_account' | 'connect_link_account_card' | 'connect_link_account_card_name' | 'connect_link_account_card_description' | 'invalid_permissions' | 'invalid_permissions_description' | 'select_an_avatar' | 'upload_an_avatar' | 'or_select_default_avatars' | 'select_an_avatar_from_all_defaults' | 'show_more_avatars_btn_label' | 'loading' | 'loading_file' | 'save' | 'or' | 'upload_photo' | 'default_avatars' | 'avatar_picker_back_btn_label' | 'drag_and_drop_images_here' | 'upload_image' | 'image_url_invalid_error' | 'image_format_invalid_error' | 'image_size_too_large_error' | 'something_went_wrong' | 'might_be_a_hiccup' | 'couldnt_generate_preview' | 'couldnt_generate_encrypted_entry_preview' | 'cant_preview_file_type' | 'item_not_found_in_list' | 'not_found_title' | 'not_found_description' | 'no_pdf_artifacts' | 'give_feedback' | 'try_downloading_file' | 'webgl_warning_description' | 'unable_to_annotate_image' | 'learn_more' | 'accounts' | 'actions' | 'error_hint_retry' | 'error_hint_critical' | 'close' | 'could_not_load_editor' | 'could_not_save_image' | 'could_not_load_link' | 'annotate' | 'annotate_tool_arrow' | 'annotate_tool_text' | 'annotate_tool_shape' | 'annotate_tool_brush' | 'annotate_tool_blur' | 'annotate_tool_line_thickness' | 'annotate_tool_color' | 'annotate_confirmation_close_anyway' | 'annotate_confirmation_heading' | 'annotate_confirmation_content' | 'drop_your_files_here' | 'share_files_instantly' | 'insert_files' | 'zoom_out' | 'zoom_in' | 'remove_image' | 'play' | 'pause' | 'disable_fullscreen' | 'enable_fullscreen' | 'error_loading_file' | 'error_generating_preview' | 'download' | 'unknown' | 'document' | 'audio' | 'video' | 'image' | 'archive' | 'email' | 'text' | 'displayThumbnail' | 'search' | 'view' | 'viewIn' | 'viewOriginal' | 'changeView' | 'playbackSpeed' | 'skipBackward' | 'skipForward' | 'playbackDefaultSpeed' | 'preview' | 'preview_unavailable' | 'preview_currently_unavailable' | 'creating_preview' | 'couldnt_load_file' | 'error_429' | 'close_and_reopen' | 'viewer_rateLimited' | 'zip_entry_load_fail' | 'file_image_is_selected' | 'file_video_is_selected' | 'file_audio_is_selected' | 'file_doc_is_selected' | 'file_archive_is_selected' | 'file_unknown_is_selected' | 'open_file_in_viewer' | RequestAccessMessageKey;
3
+ export type MessageKey = 'retry' | 'failed_to_load' | 'failed_to_upload' | 'recent_uploads' | 'upload_file' | 'drag_and_drop_your_files' | 'drag_and_drop_your_files_and_folders' | 'drop_your_files' | 'upload' | 'cancel' | 'search_all_gifs' | 'cant_retrieve_gifs' | 'cant_retrieve_files' | 'check_your_network' | 'try_again' | 'try_another_account' | 'no_gifs_found' | 'no_gifs_found_suggestion' | 'load_more_gifs' | 'add_account' | 'unlink_account' | 'upload_file_from' | 'connect_to' | 'connect_account_description' | 'connect_link_account' | 'connect_link_account_card' | 'connect_link_account_card_name' | 'connect_link_account_card_description' | 'invalid_permissions' | 'invalid_permissions_description' | 'select_an_avatar' | 'upload_an_avatar' | 'or_select_default_avatars' | 'select_an_avatar_from_all_defaults' | 'show_more_avatars_btn_label' | 'loading' | 'loading_file' | 'save' | 'or' | 'upload_photo' | 'default_avatars' | 'avatar_picker_back_btn_label' | 'drag_and_drop_images_here' | 'upload_image' | 'image_url_invalid_error' | 'image_format_invalid_error' | 'image_size_too_large_error' | 'something_went_wrong' | 'might_be_a_hiccup' | 'couldnt_generate_preview' | 'couldnt_generate_encrypted_entry_preview' | 'cant_preview_file_type' | 'item_not_found_in_list' | 'not_found_title' | 'not_found_description' | 'no_pdf_artifacts' | 'password_protected_pdf' | 'enter_password' | 'incorrect_password' | 'submit' | 'give_feedback' | 'try_downloading_file' | 'webgl_warning_description' | 'unable_to_annotate_image' | 'learn_more' | 'accounts' | 'actions' | 'error_hint_retry' | 'error_hint_critical' | 'close' | 'could_not_load_editor' | 'could_not_save_image' | 'could_not_load_link' | 'annotate' | 'annotate_tool_arrow' | 'annotate_tool_text' | 'annotate_tool_shape' | 'annotate_tool_brush' | 'annotate_tool_blur' | 'annotate_tool_line_thickness' | 'annotate_tool_color' | 'annotate_confirmation_close_anyway' | 'annotate_confirmation_heading' | 'annotate_confirmation_content' | 'drop_your_files_here' | 'share_files_instantly' | 'insert_files' | 'zoom_out' | 'zoom_in' | 'remove_image' | 'play' | 'pause' | 'disable_fullscreen' | 'enable_fullscreen' | 'error_loading_file' | 'error_generating_preview' | 'download' | 'unknown' | 'document' | 'audio' | 'video' | 'image' | 'archive' | 'email' | 'text' | 'displayThumbnail' | 'search' | 'view' | 'viewIn' | 'viewOriginal' | 'changeView' | 'playbackSpeed' | 'skipBackward' | 'skipForward' | 'playbackDefaultSpeed' | 'preview' | 'preview_unavailable' | 'preview_currently_unavailable' | 'creating_preview' | 'couldnt_load_file' | 'error_429' | 'close_and_reopen' | 'viewer_rateLimited' | 'zip_entry_load_fail' | 'file_image_is_selected' | 'file_video_is_selected' | 'file_audio_is_selected' | 'file_doc_is_selected' | 'file_archive_is_selected' | 'file_unknown_is_selected' | 'open_file_in_viewer' | RequestAccessMessageKey;
4
4
  type Messages = {
5
5
  [K in MessageKey]: MessageDescriptor;
6
6
  };
@@ -11,8 +11,10 @@ type WithCode = {
11
11
  };
12
12
  export type ShortcutProps = {
13
13
  handler: () => void;
14
+ eventType?: 'keyup' | 'keydown';
14
15
  } & WithCode;
15
16
  export declare class Shortcut extends Component<ShortcutProps, {}> {
17
+ eventType: keyof DocumentEventMap;
16
18
  componentDidMount(): void;
17
19
  componentWillUnmount(): void;
18
20
  render(): null;
@@ -1,6 +1,6 @@
1
1
  import { MessageDescriptor } from 'react-intl-next';
2
2
  export type RequestAccessMessageKey = 'request_access_description' | 'click_to_join_description' | 'request_access_pending_description' | 'click_to_join' | 'request_access' | 'request_access_pending' | 'forbidden_description' | 'request_denied_description';
3
- export type MessageKey = 'retry' | 'failed_to_load' | 'failed_to_upload' | 'recent_uploads' | 'upload_file' | 'drag_and_drop_your_files' | 'drag_and_drop_your_files_and_folders' | 'drop_your_files' | 'upload' | 'cancel' | 'search_all_gifs' | 'cant_retrieve_gifs' | 'cant_retrieve_files' | 'check_your_network' | 'try_again' | 'try_another_account' | 'no_gifs_found' | 'no_gifs_found_suggestion' | 'load_more_gifs' | 'add_account' | 'unlink_account' | 'upload_file_from' | 'connect_to' | 'connect_account_description' | 'connect_link_account' | 'connect_link_account_card' | 'connect_link_account_card_name' | 'connect_link_account_card_description' | 'invalid_permissions' | 'invalid_permissions_description' | 'select_an_avatar' | 'upload_an_avatar' | 'or_select_default_avatars' | 'select_an_avatar_from_all_defaults' | 'show_more_avatars_btn_label' | 'loading' | 'loading_file' | 'save' | 'or' | 'upload_photo' | 'default_avatars' | 'avatar_picker_back_btn_label' | 'drag_and_drop_images_here' | 'upload_image' | 'image_url_invalid_error' | 'image_format_invalid_error' | 'image_size_too_large_error' | 'something_went_wrong' | 'might_be_a_hiccup' | 'couldnt_generate_preview' | 'couldnt_generate_encrypted_entry_preview' | 'cant_preview_file_type' | 'item_not_found_in_list' | 'not_found_title' | 'not_found_description' | 'no_pdf_artifacts' | 'give_feedback' | 'try_downloading_file' | 'webgl_warning_description' | 'unable_to_annotate_image' | 'learn_more' | 'accounts' | 'actions' | 'error_hint_retry' | 'error_hint_critical' | 'close' | 'could_not_load_editor' | 'could_not_save_image' | 'could_not_load_link' | 'annotate' | 'annotate_tool_arrow' | 'annotate_tool_text' | 'annotate_tool_shape' | 'annotate_tool_brush' | 'annotate_tool_blur' | 'annotate_tool_line_thickness' | 'annotate_tool_color' | 'annotate_confirmation_close_anyway' | 'annotate_confirmation_heading' | 'annotate_confirmation_content' | 'drop_your_files_here' | 'share_files_instantly' | 'insert_files' | 'zoom_out' | 'zoom_in' | 'remove_image' | 'play' | 'pause' | 'disable_fullscreen' | 'enable_fullscreen' | 'error_loading_file' | 'error_generating_preview' | 'download' | 'unknown' | 'document' | 'audio' | 'video' | 'image' | 'archive' | 'email' | 'text' | 'displayThumbnail' | 'search' | 'view' | 'viewIn' | 'viewOriginal' | 'changeView' | 'playbackSpeed' | 'skipBackward' | 'skipForward' | 'playbackDefaultSpeed' | 'preview' | 'preview_unavailable' | 'preview_currently_unavailable' | 'creating_preview' | 'couldnt_load_file' | 'error_429' | 'close_and_reopen' | 'viewer_rateLimited' | 'zip_entry_load_fail' | 'file_image_is_selected' | 'file_video_is_selected' | 'file_audio_is_selected' | 'file_doc_is_selected' | 'file_archive_is_selected' | 'file_unknown_is_selected' | 'open_file_in_viewer' | RequestAccessMessageKey;
3
+ export type MessageKey = 'retry' | 'failed_to_load' | 'failed_to_upload' | 'recent_uploads' | 'upload_file' | 'drag_and_drop_your_files' | 'drag_and_drop_your_files_and_folders' | 'drop_your_files' | 'upload' | 'cancel' | 'search_all_gifs' | 'cant_retrieve_gifs' | 'cant_retrieve_files' | 'check_your_network' | 'try_again' | 'try_another_account' | 'no_gifs_found' | 'no_gifs_found_suggestion' | 'load_more_gifs' | 'add_account' | 'unlink_account' | 'upload_file_from' | 'connect_to' | 'connect_account_description' | 'connect_link_account' | 'connect_link_account_card' | 'connect_link_account_card_name' | 'connect_link_account_card_description' | 'invalid_permissions' | 'invalid_permissions_description' | 'select_an_avatar' | 'upload_an_avatar' | 'or_select_default_avatars' | 'select_an_avatar_from_all_defaults' | 'show_more_avatars_btn_label' | 'loading' | 'loading_file' | 'save' | 'or' | 'upload_photo' | 'default_avatars' | 'avatar_picker_back_btn_label' | 'drag_and_drop_images_here' | 'upload_image' | 'image_url_invalid_error' | 'image_format_invalid_error' | 'image_size_too_large_error' | 'something_went_wrong' | 'might_be_a_hiccup' | 'couldnt_generate_preview' | 'couldnt_generate_encrypted_entry_preview' | 'cant_preview_file_type' | 'item_not_found_in_list' | 'not_found_title' | 'not_found_description' | 'no_pdf_artifacts' | 'password_protected_pdf' | 'enter_password' | 'incorrect_password' | 'submit' | 'give_feedback' | 'try_downloading_file' | 'webgl_warning_description' | 'unable_to_annotate_image' | 'learn_more' | 'accounts' | 'actions' | 'error_hint_retry' | 'error_hint_critical' | 'close' | 'could_not_load_editor' | 'could_not_save_image' | 'could_not_load_link' | 'annotate' | 'annotate_tool_arrow' | 'annotate_tool_text' | 'annotate_tool_shape' | 'annotate_tool_brush' | 'annotate_tool_blur' | 'annotate_tool_line_thickness' | 'annotate_tool_color' | 'annotate_confirmation_close_anyway' | 'annotate_confirmation_heading' | 'annotate_confirmation_content' | 'drop_your_files_here' | 'share_files_instantly' | 'insert_files' | 'zoom_out' | 'zoom_in' | 'remove_image' | 'play' | 'pause' | 'disable_fullscreen' | 'enable_fullscreen' | 'error_loading_file' | 'error_generating_preview' | 'download' | 'unknown' | 'document' | 'audio' | 'video' | 'image' | 'archive' | 'email' | 'text' | 'displayThumbnail' | 'search' | 'view' | 'viewIn' | 'viewOriginal' | 'changeView' | 'playbackSpeed' | 'skipBackward' | 'skipForward' | 'playbackDefaultSpeed' | 'preview' | 'preview_unavailable' | 'preview_currently_unavailable' | 'creating_preview' | 'couldnt_load_file' | 'error_429' | 'close_and_reopen' | 'viewer_rateLimited' | 'zip_entry_load_fail' | 'file_image_is_selected' | 'file_video_is_selected' | 'file_audio_is_selected' | 'file_doc_is_selected' | 'file_archive_is_selected' | 'file_unknown_is_selected' | 'open_file_in_viewer' | RequestAccessMessageKey;
4
4
  type Messages = {
5
5
  [K in MessageKey]: MessageDescriptor;
6
6
  };
@@ -11,8 +11,10 @@ type WithCode = {
11
11
  };
12
12
  export type ShortcutProps = {
13
13
  handler: () => void;
14
+ eventType?: 'keyup' | 'keydown';
14
15
  } & WithCode;
15
16
  export declare class Shortcut extends Component<ShortcutProps, {}> {
17
+ eventType: keyof DocumentEventMap;
16
18
  componentDidMount(): void;
17
19
  componentWillUnmount(): void;
18
20
  render(): null;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/media-ui",
3
- "version": "25.2.0",
3
+ "version": "25.3.0",
4
4
  "description": "Includes common components and utilities used by other media packages",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -24,7 +24,7 @@
24
24
  },
25
25
  "dependencies": {
26
26
  "@atlaskit/analytics-next": "^9.2.0",
27
- "@atlaskit/button": "^17.5.0",
27
+ "@atlaskit/button": "^17.6.0",
28
28
  "@atlaskit/code": "^15.1.0",
29
29
  "@atlaskit/icon": "^22.1.0",
30
30
  "@atlaskit/icon-file-type": "^6.4.0",