box-content-preview 3.125.0 → 3.127.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/README.md +7 -7
- package/dist/lib/i18n/bn-IN.js +7 -0
- package/dist/lib/i18n/da-DK.js +7 -0
- package/dist/lib/i18n/de-DE.js +7 -0
- package/dist/lib/i18n/en-AU.js +7 -0
- package/dist/lib/i18n/en-CA.js +7 -0
- package/dist/lib/i18n/en-GB.js +7 -0
- package/dist/lib/i18n/en-US.js +7 -0
- package/dist/lib/i18n/en-x-pseudo.js +7 -0
- package/dist/lib/i18n/es-419.js +7 -0
- package/dist/lib/i18n/es-ES.js +7 -0
- package/dist/lib/i18n/fi-FI.js +7 -0
- package/dist/lib/i18n/fr-CA.js +7 -0
- package/dist/lib/i18n/fr-FR.js +7 -0
- package/dist/lib/i18n/hi-IN.js +7 -0
- package/dist/lib/i18n/it-IT.js +7 -0
- package/dist/lib/i18n/ja-JP.js +7 -0
- package/dist/lib/i18n/ko-KR.js +7 -0
- package/dist/lib/i18n/nb-NO.js +7 -0
- package/dist/lib/i18n/nl-NL.js +7 -0
- package/dist/lib/i18n/pl-PL.js +7 -0
- package/dist/lib/i18n/pt-BR.js +7 -0
- package/dist/lib/i18n/ru-RU.js +7 -0
- package/dist/lib/i18n/sv-SE.js +7 -0
- package/dist/lib/i18n/tr-TR.js +7 -0
- package/dist/lib/i18n/zh-CN.js +7 -0
- package/dist/lib/i18n/zh-TW.js +7 -0
- package/dist/lib/index.css +4 -3
- package/dist/lib/index.js +270 -44
- package/package.json +1 -1
package/dist/lib/index.js
CHANGED
|
@@ -1225,7 +1225,7 @@ const DEFAULT_LANGUAGE = 'en-US';
|
|
|
1225
1225
|
const MESSAGE_KEY_PREFIX = 'bcp.';
|
|
1226
1226
|
|
|
1227
1227
|
// Only the npm build defines __BCP_DEFAULT_MESSAGES__; the CDN build bakes strings in per locale.
|
|
1228
|
-
const defaultStrings = (0,_isNpmBuild__WEBPACK_IMPORTED_MODULE_0__/* .isNpmBuild */ .w)() ? {"rotate_left":"Rotate left","zoom_current_scale":"Current zoom level","zoom_in":"Zoom in","zoom_out":"Zoom out","enter_fullscreen":"Enter fullscreen","exit_fullscreen":"Exit fullscreen","controls_more":"More options","controls_find":"Find","controls_rotate_document":"Rotate document","controls_rotate_image":"Rotate image","controls_zoom_scale":"Zoom: {1}","controls_view_as_grid":"View as grid","controls_show_thumbnails":"View thumbnails","controls_hide_thumbnails":"Hide thumbnails","controls_shortcut_ctrl":"Ctrl + {1}","drawing_comment":"Markup","region_comment":"Comment on Region","highlight_text":"Highlight and Comment","exit_annotations":"Exit Annotations","annotation_tools":"Comment and markup","drawing_color":"Drawing color","drawing_color_blue":"Blue","drawing_color_green":"Green","drawing_color_red":"Red","drawing_color_orange":"Orange","drawing_color_yellow":"Yellow","drawing_color_purple":"Purple","previous_page":"Previous page","enter_page_num":"Click to enter page number","next_page":"Next page","download":"Download","print":"Print","print_notification":"Please press the print button to get a printable version of this document.","print_loading":"Preparing to print...","print_ready":"Ready to print.","print_close":"Close print dialog","previous_file":"Previous file","logo":"Logo","next_file":"Next file","loading_preview":"Loading Preview...","download_file":"Download File","text_truncated":"This file has been truncated due to size limits. Please download to view the whole file.","toggle_findbar":"Toggle findbar","toggle_thumbnails":"Toggle thumbnails","gallery_view":"Gallery view","page_gallery":"Page gallery","page_gallery_tile":"Page {1}","has_x_refs":"This preview has references you cannot view. Open the file in its native application.","find_next":"Find next","find_previous":"Find previous","find_close":"Close","find_label":"Search input","find_placeholder":"Find in document","find_match_count":"{1} of {2}","thumbnail_label":"Page thumbnails","file_preview_label":"File preview","comparison_banner_current":"Current version","comparison_banner_previous":"Previous version","comparison_banner_version":"Version {1}","comparison_banner_actions":"More actions","comparison_banner_open_full_preview":"Open Full Preview","comparison_banner_close":"Close","comparison_banner_make_current":"Make Current","comparison_banner_delete":"Delete","error_generic":"This preview didn’t load. Please try to open or download the file to view.","error_unsupported":"This preview didn’t load because the file type is unsupported. Please try to open or download the file to view.","error_account":"This preview didn’t load because your account is unable to preview this file type. Please try to open or download the file to view.","error_permissions":"This preview didn’t load because you don’t have permission. Please ask the file owner to update permissions.","error_refresh":"This preview didn’t load. Please try to open or download the file to view.","error_rate_limit":"This preview didn’t load because your request was rate limited. Please try to open or download the file to view.","error_reupload":"This preview didn’t load. Please try to open or download the file to view.","error_browser_unsupported":"Your browser doesn’t support preview for {1}. Please try to open or download the file to view.","error_document":"This preview didn’t load because the document may be protected. Please try to open or download the file to view.","error_password_protected":"This preview didn’t load because the document is protected. Please try to open or download the file to view.","error_try_again_later":"This preview didn’t load. Please refresh the page or download file to view.","error_bad_file":"This preview didn’t load. Please try to open or download the file to view.","error_not_downloadable":"Something seems to be wrong with this file. Please refresh the page, and if the issue continues, try to upload a new version.","error_flash_not_enabled":"This preview didn’t load because Flash is not enabled on your browser. Please try to enable Flash or download the file to view.","error_internet_explorer_office_online":"This version of Internet Explorer is out of date and the experience may be degraded. Please try switching to a different browser for a better experience.","error_large_file":"File exceeds supported size for preview. Open or download the file to view.","error_too_many_operations":"The file is too complex to display in your browser. Please download it to view.","error_zero_byte_file":"Cannot preview 0 B file. Open or download the file to view.","filename":"Name","last_modified_date":"Modified","size":"Size","search":"Search","search_results":"Search Results","search_placeholder":"Search files and folders","search_clear":"Clear search","breadcrumb":"Breadcrumb","breadcrumb_truncated":"Show hidden folders","media_autoplay":"Autoplay","media_autoplay_disabled":"Disabled","media_autoplay_enabled":"Enabled","media_play_next":"Play next file","media_play_next_disabled":"Disabled","media_play_next_enabled":"Enabled","media_speed":"Speed","media_speed_normal":"Normal","media_quality":"Quality","media_quality_auto":"Auto","media_guides":"Guides","media_guides_off":"Off","media_guides_default":"Default","media_guides_widescreen_hd":"Widescreen HD","media_guides_vertical":"Vertical","media_guides_square":"Square","media_guides_social_portrait":"Social Portrait","media_guides_cinemascope":"Cinemascope","media_guides_univisium":"Univisium","media_guides_cinema_flat":"Cinema Flat","media_guides_scope":"Scope","media_guides_fullscreen":"Fullscreen","media_guides_ultrawide":"Ultrawide","media_volume_slider":"Volume Slider","media_generating_waveform":"Generating waveform","media_loading":"Loading","media_zoom":"Zoom","media_zoom_slider":"Zoom Slider","media_time_slider":"Media Slider","media_comment_marker":"Comment marker","media_range_comment":"Comment","media_range_clear":"Clear","media_shuttle_forward":"Scanning forward at {1}x","media_shuttle_reverse":"Scanning backward at {1}x","media_mute":"Mute","media_unmute":"Unmute","media_play":"Play","media_pause":"Pause","media_skip_forward":"Skip forward","media_skip_backward":"Skip backward","media_settings":"Settings","media_subtitles_cc":"Subtitles/Closed Captions","media_time_format":"Time format","media_time_format_standard":"Standard time","media_time_format_timecode":"Timecode","media_time_format_frames":"Frame numbers","volume":"Volume","of":"of","subtitles":"Subtitles","off":"Off","media_audio":"Audio","track":"Track","media_auto_generated_captions":"Auto-Generated Captions","auto_generated":"Auto-Generated","box3d_animation_clips":"Animation clips","box3d_camera_projection_perspective":"Perspective","box3d_camera_projection_orthographic":"Orthographic","box3d_reset":"Reset","box3d_toggle_animation":"Play/pause animation","box3d_toggle_vr":"Toggle VR display","box3d_render_mode_lit":"Lit","box3d_render_mode_unlit":"Unlit","box3d_render_mode_normals":"Normals","box3d_render_mode_shape":"Shape","box3d_render_mode_uv_overlay":"UV Overlay","box3d_settings":"Settings","box3d_settings_render_label":"Render mode","box3d_settings_grid_label":"Show grid","box3d_settings_wireframes_label":"Show wireframes","box3d_settings_skeletons_label":"Show skeletons","box3d_settings_projection_label":"Camera Projection","box3d_settings_rotate_label":"Rotate Model","box3d_settings_rotate_left":"Rotate left around {1} axis","box3d_settings_rotate_right":"Rotate right around {1} axis","document_label":"Document Viewer","annotation_add_comment_placeholder":"Add a comment here...","annotation_reply_placeholder":"Post a reply...","annotation_done":"Done","annotation_close":"Close","annotation_cancel":"Cancel","annotation_save":"Save","annotation_post":"Post","annotation_delete":"Delete","annotation_delete_confirmation_message":"Delete this annotation?","annotation_profile_alt":"Avatar","annotation_anonymous_user_name":"Some User","annotation_posting_message":"Posting...","annotation_point_toggle":"Point annotation mode","annotation_draw_toggle":"Drawing annotation mode","annotation_highlight_toggle":"Highlight text","annotation_highlight_comment":"Add comment to highlighted text","annotation_who_highlighted":"{1} highlighted","annotation_who_drew":"{1} drew","annotation_draw_save":"Save drawing","annotation_draw_delete":"Delete drawing","annotations_load_error":"Annotations could not be loaded for this file. Please refresh the page to try again.","annotations_create_error":"This annotation could not be created. Please try again.","annotations_delete_error":"This annotation could not be deleted. Please try again.","annotations_authorization_error":"Annotations could not be loaded for this file. You may not have permission to take this action.","notification_button_default_text":"Okay","notification_button_default_label":"Clear Notification","notification_annotation_point_mode":"Click anywhere to add a comment to the document","notification_annotation_draw_mode":"Press down and drag the pointer to draw on the document","notification_degraded_preview":"Your connection to {1} is being blocked. Please reach out to your network admin to adjust firewall settings.","notification_cannot_download":"This file could not be downloaded.","notification_cannot_download_due_to_policy":"The file could not be downloaded due to a security policy.","link_contact_us":"Contact Us","360_videos":"360-degree videos","360_images":"360-degree images","3d_models":"3D models","afrikaans":"Afrikaans","albanian":"Albanian","arabic":"Arabic","armenian":"Armenian","belarusian":"Belarusian","bengali":"Bengali","bosnian":"Bosnian","bulgarian":"Bulgarian","burmese":"Burmese","catalan":"Catalan","central_khmer":"Central Khmer","chinese":"Chinese","croatian":"Croatian","czech":"Czech","danish":"Danish","dutch":"Dutch","english":"English","estonian":"Estonian","filipino":"Filipino","finnish":"Finnish","french":"French","galician":"Galician","ganda":"Ganda","georgian":"Georgian","german":"German","haitian_creole":"Haitian Creole","hebrew":"Hebrew","hindi":"Hindi","hmong":"Hmong","hungarian":"Hungarian","icelandic":"Icelandic","indonesian":"Indonesian","irish":"Irish","italian":"Italian","japanese":"Japanese","kazakh":"Kazakh","korean":"Korean","kurdish":"Kurdish","lao":"Lao","latvian":"Latvian","lithuanian":"Lithuanian","luxembourgish":"Luxembourgish","malay_macrolanguage":"Malay","modern_greek_1453_":"Greek","mongolian":"Mongolian","norwegian":"Norwegian","persian":"Persian","polish":"Polish","portuguese":"Portuguese","romanian":"Romanian","russian":"Russian","serbian":"Serbian","sichuan_yi":"Sichuan Yi","sicilian":"Sicilian","slovak":"Slovak","slovenian":"Slovenian","somali":"Somali","spanish":"Spanish","swahili_macrolanguage":"Swahili","swedish":"Swedish","swiss_german":"Swiss German","tagalog":"Tagalog","telugu":"Telugu","thai":"Thai","tibetan":"Tibetan","turkish":"Turkish","ukrainian":"Ukrainian","uzbek":"Uzbek","vietnamese":"Vietnamese"} : {};
|
|
1228
|
+
const defaultStrings = (0,_isNpmBuild__WEBPACK_IMPORTED_MODULE_0__/* .isNpmBuild */ .w)() ? {"rotate_left":"Rotate left","zoom_current_scale":"Current zoom level","zoom_in":"Zoom in","zoom_out":"Zoom out","enter_fullscreen":"Enter fullscreen","exit_fullscreen":"Exit fullscreen","controls_more":"More options","controls_find":"Find","controls_rotate_document":"Rotate document","controls_rotate_image":"Rotate image","controls_zoom_scale":"Zoom: {1}","controls_view_as_grid":"View as grid","controls_show_thumbnails":"View thumbnails","controls_hide_thumbnails":"Hide thumbnails","controls_shortcut_ctrl":"Ctrl + {1}","drawing_comment":"Markup","region_comment":"Comment on Region","highlight_text":"Highlight and Comment","exit_annotations":"Exit Annotations","annotation_tools":"Comment and markup","drawing_color":"Drawing color","drawing_color_blue":"Blue","drawing_color_green":"Green","drawing_color_red":"Red","drawing_color_orange":"Orange","drawing_color_yellow":"Yellow","drawing_color_purple":"Purple","previous_page":"Previous page","enter_page_num":"Click to enter page number","next_page":"Next page","download":"Download","print":"Print","print_notification":"Please press the print button to get a printable version of this document.","print_loading":"Preparing to print...","print_ready":"Ready to print.","print_close":"Close print dialog","previous_file":"Previous file","logo":"Logo","next_file":"Next file","loading_preview":"Loading Preview...","download_file":"Download File","text_truncated":"This file has been truncated due to size limits. Please download to view the whole file.","toggle_findbar":"Toggle findbar","toggle_thumbnails":"Toggle thumbnails","gallery_view":"Gallery view","page_gallery":"Page gallery","page_gallery_tile":"Page {1}","has_x_refs":"This preview has references you cannot view. Open the file in its native application.","find_next":"Find next","find_previous":"Find previous","find_close":"Close","find_label":"Search input","find_placeholder":"Find in document","find_match_count":"{1} of {2}","thumbnail_label":"Page thumbnails","file_preview_label":"File preview","comparison_banner_current":"Current version","comparison_banner_previous":"Previous version","comparison_banner_version":"Version {1}","comparison_banner_actions":"More actions","comparison_banner_open_full_preview":"Open Full Preview","comparison_banner_close":"Close","comparison_banner_make_current":"Make Current","comparison_banner_delete":"Delete","error_generic":"This preview didn’t load. Please try to open or download the file to view.","error_unsupported":"This preview didn’t load because the file type is unsupported. Please try to open or download the file to view.","error_account":"This preview didn’t load because your account is unable to preview this file type. Please try to open or download the file to view.","error_permissions":"This preview didn’t load because you don’t have permission. Please ask the file owner to update permissions.","error_refresh":"This preview didn’t load. Please try to open or download the file to view.","error_rate_limit":"This preview didn’t load because your request was rate limited. Please try to open or download the file to view.","error_reupload":"This preview didn’t load. Please try to open or download the file to view.","error_browser_unsupported":"Your browser doesn’t support preview for {1}. Please try to open or download the file to view.","error_document":"This preview didn’t load because the document may be protected. Please try to open or download the file to view.","error_password_protected":"This preview didn’t load because the document is protected. Please try to open or download the file to view.","error_try_again_later":"This preview didn’t load. Please refresh the page or download file to view.","error_bad_file":"This preview didn’t load. Please try to open or download the file to view.","error_not_downloadable":"Something seems to be wrong with this file. Please refresh the page, and if the issue continues, try to upload a new version.","error_flash_not_enabled":"This preview didn’t load because Flash is not enabled on your browser. Please try to enable Flash or download the file to view.","error_internet_explorer_office_online":"This version of Internet Explorer is out of date and the experience may be degraded. Please try switching to a different browser for a better experience.","error_large_file":"File exceeds supported size for preview. Open or download the file to view.","error_too_many_operations":"The file is too complex to display in your browser. Please download it to view.","error_zero_byte_file":"Cannot preview 0 B file. Open or download the file to view.","filename":"Name","last_modified_date":"Modified","size":"Size","search":"Search","search_results":"Search Results","search_placeholder":"Search files and folders","search_clear":"Clear search","breadcrumb":"Breadcrumb","breadcrumb_truncated":"Show hidden folders","media_autoplay":"Autoplay","media_autoplay_disabled":"Disabled","media_autoplay_enabled":"Enabled","media_play_next":"Play next file","media_play_next_disabled":"Disabled","media_play_next_enabled":"Enabled","media_speed":"Speed","media_speed_normal":"Normal","media_quality":"Quality","media_quality_auto":"Auto","media_guides":"Guides","media_guides_off":"Off","media_guides_default":"Default","media_guides_widescreen_hd":"Widescreen HD","media_guides_vertical":"Vertical","media_guides_square":"Square","media_guides_social_portrait":"Social Portrait","media_guides_cinemascope":"Cinemascope","media_guides_univisium":"Univisium","media_guides_cinema_flat":"Cinema Flat","media_guides_scope":"Scope","media_guides_fullscreen":"Fullscreen","media_guides_ultrawide":"Ultrawide","media_volume_slider":"Volume Slider","media_generating_waveform":"Generating waveform","media_loading":"Loading","media_zoom":"Zoom","media_zoom_slider":"Zoom Slider","media_time_slider":"Media Slider","media_comment_marker":"Comment marker","media_range_comment":"Comment","media_range_clear":"Clear","media_shuttle_forward":"Scanning forward at {1}x","media_shuttle_reverse":"Scanning backward at {1}x","media_mute":"Mute","media_unmute":"Unmute","media_play":"Play","media_pause":"Pause","media_skip_forward":"Skip forward","media_skip_backward":"Skip backward","media_settings":"Settings","media_subtitles_cc":"Subtitles/Closed Captions","media_time_format":"Time format","media_time_format_standard":"Standard time","media_time_format_timecode":"Timecode","media_time_format_frames":"Frame numbers","volume":"Volume","of":"of","subtitles":"Subtitles","off":"Off","media_audio":"Audio","track":"Track","media_auto_generated_captions":"Auto-Generated Captions","auto_generated":"Auto-Generated","box3d_animation_clips":"Animation clips","box3d_camera_projection_perspective":"Perspective","box3d_camera_projection_orthographic":"Orthographic","box3d_reset":"Reset","box3d_toggle_animation":"Play/pause animation","box3d_toggle_vr":"Toggle VR display","box3d_render_mode_lit":"Lit","box3d_render_mode_unlit":"Unlit","box3d_render_mode_normals":"Normals","box3d_render_mode_shape":"Shape","box3d_render_mode_uv_overlay":"UV Overlay","box3d_settings":"Settings","box3d_settings_render_label":"Render mode","box3d_settings_grid_label":"Show grid","box3d_settings_wireframes_label":"Show wireframes","box3d_settings_skeletons_label":"Show skeletons","box3d_settings_projection_label":"Camera Projection","box3d_settings_rotate_label":"Rotate Model","box3d_settings_rotate_left":"Rotate left around {1} axis","box3d_settings_rotate_right":"Rotate right around {1} axis","document_label":"Document Viewer","annotation_add_comment_placeholder":"Add a comment here...","annotation_reply_placeholder":"Post a reply...","annotation_done":"Done","annotation_close":"Close","annotation_cancel":"Cancel","annotation_save":"Save","annotation_post":"Post","annotation_delete":"Delete","annotation_delete_confirmation_message":"Delete this annotation?","annotation_profile_alt":"Avatar","annotation_anonymous_user_name":"Some User","annotation_posting_message":"Posting...","annotation_point_toggle":"Point annotation mode","annotation_draw_toggle":"Drawing annotation mode","annotation_highlight_toggle":"Highlight text","annotation_highlight_comment":"Add comment to highlighted text","annotation_who_highlighted":"{1} highlighted","annotation_who_drew":"{1} drew","annotation_draw_save":"Save drawing","annotation_draw_delete":"Delete drawing","annotations_load_error":"Annotations could not be loaded for this file. Please refresh the page to try again.","annotations_create_error":"This annotation could not be created. Please try again.","annotations_delete_error":"This annotation could not be deleted. Please try again.","annotations_authorization_error":"Annotations could not be loaded for this file. You may not have permission to take this action.","notification_button_default_text":"Okay","notification_button_default_label":"Clear Notification","notification_annotation_point_mode":"Click anywhere to add a comment to the document","notification_annotation_draw_mode":"Press down and drag the pointer to draw on the document","notification_degraded_preview":"Your connection to {1} is being blocked. Please reach out to your network admin to adjust firewall settings.","notification_cannot_download":"This file could not be downloaded.","notification_cannot_download_due_to_policy":"The file could not be downloaded due to a security policy.","notifications_region_label":"Notifications","notification_icon_error":"Error","notification_icon_info":"Information","notification_icon_success":"Success","notification_icon_warning":"Warning","notification_webgl_context_lost":"WebGL Context Lost","notification_webgl_context_restored":"WebGL Context Restored","link_contact_us":"Contact Us","360_videos":"360-degree videos","360_images":"360-degree images","3d_models":"3D models","afrikaans":"Afrikaans","albanian":"Albanian","arabic":"Arabic","armenian":"Armenian","belarusian":"Belarusian","bengali":"Bengali","bosnian":"Bosnian","bulgarian":"Bulgarian","burmese":"Burmese","catalan":"Catalan","central_khmer":"Central Khmer","chinese":"Chinese","croatian":"Croatian","czech":"Czech","danish":"Danish","dutch":"Dutch","english":"English","estonian":"Estonian","filipino":"Filipino","finnish":"Finnish","french":"French","galician":"Galician","ganda":"Ganda","georgian":"Georgian","german":"German","haitian_creole":"Haitian Creole","hebrew":"Hebrew","hindi":"Hindi","hmong":"Hmong","hungarian":"Hungarian","icelandic":"Icelandic","indonesian":"Indonesian","irish":"Irish","italian":"Italian","japanese":"Japanese","kazakh":"Kazakh","korean":"Korean","kurdish":"Kurdish","lao":"Lao","latvian":"Latvian","lithuanian":"Lithuanian","luxembourgish":"Luxembourgish","malay_macrolanguage":"Malay","modern_greek_1453_":"Greek","mongolian":"Mongolian","norwegian":"Norwegian","persian":"Persian","polish":"Polish","portuguese":"Portuguese","romanian":"Romanian","russian":"Russian","serbian":"Serbian","sichuan_yi":"Sichuan Yi","sicilian":"Sicilian","slovak":"Slovak","slovenian":"Slovenian","somali":"Somali","spanish":"Spanish","swahili_macrolanguage":"Swahili","swedish":"Swedish","swiss_german":"Swiss German","tagalog":"Tagalog","telugu":"Telugu","thai":"Thai","tibetan":"Tibetan","turkish":"Turkish","ukrainian":"Ukrainian","uzbek":"Uzbek","vietnamese":"Vietnamese"} : {};
|
|
1229
1229
|
let language = true ? "en-US" : 0;
|
|
1230
1230
|
let strings = defaultStrings;
|
|
1231
1231
|
function getLanguage() {
|
|
@@ -1328,7 +1328,7 @@ function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e =
|
|
|
1328
1328
|
const CLIENT_NAME = "box-content-preview"; // eslint-disable-line no-undef
|
|
1329
1329
|
const CLIENT_NAME_KEY = 'box_client_name';
|
|
1330
1330
|
const CLIENT_VERSION_KEY = 'box_client_version';
|
|
1331
|
-
const CLIENT_VERSION = "3.
|
|
1331
|
+
const CLIENT_VERSION = "3.127.0"; // eslint-disable-line no-undef
|
|
1332
1332
|
const HEADER_CLIENT_NAME = 'X-Box-Client-Name';
|
|
1333
1333
|
const HEADER_CLIENT_VERSION = 'X-Box-Client-Version';
|
|
1334
1334
|
const PROMISE_MAP = {};
|
|
@@ -6738,6 +6738,7 @@ function MediaSettingsV2({
|
|
|
6738
6738
|
onKeyDown: handleContentKeyDown,
|
|
6739
6739
|
side: "top"
|
|
6740
6740
|
}, activeSubMenu ? /*#__PURE__*/external_react_["default"].createElement(external_react_["default"].Fragment, null, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Item, {
|
|
6741
|
+
className: "bp-MediaSettingsV2-back",
|
|
6741
6742
|
"data-resin-target": "settingsBack",
|
|
6742
6743
|
"data-target-id": "MediaSettingsV2-back",
|
|
6743
6744
|
"data-testid": "bp-media-settings-back",
|
|
@@ -6747,9 +6748,10 @@ function MediaSettingsV2({
|
|
|
6747
6748
|
}
|
|
6748
6749
|
}, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Item.StartElement, {
|
|
6749
6750
|
icon: Medium_.ChevronLeft
|
|
6750
|
-
}), /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Item.MainContent, {
|
|
6751
|
-
|
|
6752
|
-
|
|
6751
|
+
}), /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Item.MainContent, null, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Text, {
|
|
6752
|
+
as: "span",
|
|
6753
|
+
variant: "bodySmallSemibold"
|
|
6754
|
+
}, activeSubMenu.label))), /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Separator, null), /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.RadioGroup, {
|
|
6753
6755
|
onValueChange: handleValueChange,
|
|
6754
6756
|
value: activeSubMenu.value
|
|
6755
6757
|
}, activeSubMenu.options.map(({
|
|
@@ -6805,17 +6807,18 @@ function MediaSettingsV2({
|
|
|
6805
6807
|
}
|
|
6806
6808
|
}, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Item.MainContent, {
|
|
6807
6809
|
label: label
|
|
6808
|
-
}), /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Item.EndElement, {
|
|
6810
|
+
}), /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Item.EndElement, null, /*#__PURE__*/external_react_["default"].createElement("span", {
|
|
6809
6811
|
className: "bp-MediaSettingsV2-value"
|
|
6810
6812
|
}, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Text, {
|
|
6811
6813
|
as: "span",
|
|
6812
|
-
color: "textOnLightSecondary"
|
|
6814
|
+
color: "textOnLightSecondary",
|
|
6815
|
+
variant: "bodySmall"
|
|
6813
6816
|
}, valueLabel), !isDisabled && /*#__PURE__*/external_react_["default"].createElement(Medium_.ChevronRight, {
|
|
6814
6817
|
"aria-hidden": true,
|
|
6815
6818
|
color: tokens_.bpIconIconOnLightSecondary,
|
|
6816
|
-
height: tokens_.
|
|
6817
|
-
width: tokens_.
|
|
6818
|
-
})))))));
|
|
6819
|
+
height: tokens_.Size3,
|
|
6820
|
+
width: tokens_.Size3
|
|
6821
|
+
}))))))));
|
|
6819
6822
|
}
|
|
6820
6823
|
|
|
6821
6824
|
/***/ },
|
|
@@ -7380,6 +7383,7 @@ function TimestampControl({
|
|
|
7380
7383
|
type: "button"
|
|
7381
7384
|
}, renderBlueprintTime(), renderChevron())), /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Content, {
|
|
7382
7385
|
align: "center",
|
|
7386
|
+
className: "bp-TimestampControl-menu",
|
|
7383
7387
|
container: portalContainer,
|
|
7384
7388
|
"data-testid": "bp-TimestampControl-flyout",
|
|
7385
7389
|
onKeyDown: handleMenuKeyDown,
|
|
@@ -21639,7 +21643,7 @@ var x = (y) => {
|
|
|
21639
21643
|
var x = {}; __webpack_require__.d(x, y); return x
|
|
21640
21644
|
}
|
|
21641
21645
|
var y = (x) => (() => (x))
|
|
21642
|
-
module.exports = x({ ["BlueprintProvider"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.BlueprintProvider), ["Breadcrumb"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Breadcrumb), ["Cell"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Cell), ["Column"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Column), ["DataTableWrapper"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.DataTableWrapper), ["DropdownMenu"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.DropdownMenu), ["EllipsizableText"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.EllipsizableText), ["Focusable"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Focusable), ["Ghost"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Ghost), ["IconButton"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.IconButton), ["IconToggleButton"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.IconToggleButton), ["LoadingIndicator"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.LoadingIndicator), ["Modal"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Modal), ["Popover"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Popover), ["Row"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Row), ["SearchInput"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.SearchInput), ["Select"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Select), ["SelectMenu"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.SelectMenu), ["Switch"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Switch), ["Table"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Table), ["TableBody"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.TableBody), ["TableHeader"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.TableHeader), ["Text"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Text), ["Toolbar"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Toolbar), ["Tooltip"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Tooltip), ["TooltipProvider"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.TooltipProvider), ["VisuallyHidden"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.VisuallyHidden), ["useNoopTreatment"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.useNoopTreatment) });
|
|
21646
|
+
module.exports = x({ ["BlueprintProvider"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.BlueprintProvider), ["Breadcrumb"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Breadcrumb), ["Cell"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Cell), ["Column"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Column), ["DataTableWrapper"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.DataTableWrapper), ["DropdownMenu"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.DropdownMenu), ["EllipsizableText"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.EllipsizableText), ["Focusable"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Focusable), ["Ghost"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Ghost), ["IconButton"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.IconButton), ["IconToggleButton"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.IconToggleButton), ["LoadingIndicator"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.LoadingIndicator), ["Modal"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Modal), ["Notification"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Notification), ["Popover"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Popover), ["Row"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Row), ["SearchInput"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.SearchInput), ["Select"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Select), ["SelectMenu"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.SelectMenu), ["Switch"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Switch), ["Table"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Table), ["TableBody"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.TableBody), ["TableHeader"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.TableHeader), ["Text"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Text), ["Toolbar"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Toolbar), ["Tooltip"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.Tooltip), ["TooltipProvider"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.TooltipProvider), ["VisuallyHidden"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.VisuallyHidden), ["useNoopTreatment"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.useNoopTreatment), ["useNotification"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_e1e285a9__.useNotification) });
|
|
21643
21647
|
|
|
21644
21648
|
/***/ },
|
|
21645
21649
|
|
|
@@ -21672,7 +21676,7 @@ var x = (y) => {
|
|
|
21672
21676
|
var x = {}; __webpack_require__.d(x, y); return x
|
|
21673
21677
|
}
|
|
21674
21678
|
var y = (x) => (() => (x))
|
|
21675
|
-
module.exports = x({ ["BoxBlue100"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.BoxBlue100), ["GreenLight100"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.GreenLight100), ["Grimace100"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.Grimace100), ["Size5"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.Size5), ["Size8"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.Size8), ["WatermelonRed100"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.WatermelonRed100), ["Yellorange100"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.Yellorange100), ["Yellow100"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.Yellow100), ["bpIconCtaIconOnDark"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.bpIconCtaIconOnDark), ["bpIconIconOnDark"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.bpIconIconOnDark), ["bpIconIconOnLightSecondary"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.bpIconIconOnLightSecondary), ["bpRadius03"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.bpRadius03) });
|
|
21679
|
+
module.exports = x({ ["BoxBlue100"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.BoxBlue100), ["GreenLight100"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.GreenLight100), ["Grimace100"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.Grimace100), ["Size3"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.Size3), ["Size5"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.Size5), ["Size8"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.Size8), ["WatermelonRed100"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.WatermelonRed100), ["Yellorange100"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.Yellorange100), ["Yellow100"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.Yellow100), ["bpIconCtaIconOnDark"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.bpIconCtaIconOnDark), ["bpIconIconOnDark"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.bpIconIconOnDark), ["bpIconIconOnLightSecondary"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.bpIconIconOnLightSecondary), ["bpRadius03"]: () => (__WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_tokens_tokens_b764a744__.bpRadius03) });
|
|
21676
21680
|
|
|
21677
21681
|
/***/ },
|
|
21678
21682
|
|
|
@@ -37304,7 +37308,7 @@ var isNpmBuild = __webpack_require__(8080);
|
|
|
37304
37308
|
;// ./src/lib/Logger.js
|
|
37305
37309
|
/* eslint-disable no-undef */
|
|
37306
37310
|
const CLIENT_NAME = "box-content-preview";
|
|
37307
|
-
const CLIENT_VERSION = "3.
|
|
37311
|
+
const CLIENT_VERSION = "3.127.0";
|
|
37308
37312
|
/* eslint-enable no-undef */
|
|
37309
37313
|
|
|
37310
37314
|
class Logger {
|
|
@@ -38902,7 +38906,7 @@ class BaseViewer extends (events_default()) {
|
|
|
38902
38906
|
const contentTemplate = (0,util/* getProp */.GT)(this.options, 'representation.content.url_template', '');
|
|
38903
38907
|
const downloadHostToNotify = this.api.reachability.constructor.getDownloadNotificationToShow(contentTemplate);
|
|
38904
38908
|
if (downloadHostToNotify) {
|
|
38905
|
-
this.previewUI.
|
|
38909
|
+
this.previewUI.showNotification((0,util/* replacePlaceholders */.Lb)(BaseViewer_('notification_degraded_preview'), [downloadHostToNotify]), null, true, 'warning');
|
|
38906
38910
|
this.api.reachability.constructor.setDownloadHostNotificationShown(downloadHostToNotify);
|
|
38907
38911
|
this.emitMetric(lib_events/* DOWNLOAD_REACHABILITY_METRICS */.DI.NOTIFICATION_SHOWN, {
|
|
38908
38912
|
host: downloadHostToNotify
|
|
@@ -39401,7 +39405,7 @@ class BaseViewer extends (events_default()) {
|
|
|
39401
39405
|
const error = new PreviewError/* default */.A(lib_events/* ERROR_CODE */.bo.LOAD_ANNOTATIONS, BaseViewer_('annotations_load_error'), {
|
|
39402
39406
|
silent: true
|
|
39403
39407
|
});
|
|
39404
|
-
this.previewUI.
|
|
39408
|
+
this.previewUI.showNotification(error.displayMessage, null, false, 'error');
|
|
39405
39409
|
this.triggerError(error);
|
|
39406
39410
|
return;
|
|
39407
39411
|
}
|
|
@@ -39644,21 +39648,21 @@ class BaseViewer extends (events_default()) {
|
|
|
39644
39648
|
case constants/* ANNOTATOR_EVENT */.GA.modeEnter:
|
|
39645
39649
|
this.disableViewerControls();
|
|
39646
39650
|
if (data.data.mode === ANNOTATION_TYPE_POINT) {
|
|
39647
|
-
this.previewUI.
|
|
39651
|
+
this.previewUI.showNotification(BaseViewer_('notification_annotation_point_mode'));
|
|
39648
39652
|
} else if (data.data.mode === ANNOTATION_TYPE_DRAW) {
|
|
39649
|
-
this.previewUI.
|
|
39653
|
+
this.previewUI.showNotification(BaseViewer_('notification_annotation_draw_mode'));
|
|
39650
39654
|
this.previewUI.replaceHeader(data.data.headerSelector);
|
|
39651
39655
|
}
|
|
39652
39656
|
break;
|
|
39653
39657
|
case constants/* ANNOTATOR_EVENT */.GA.modeExit:
|
|
39654
39658
|
this.enableViewerControls();
|
|
39655
|
-
this.previewUI.
|
|
39659
|
+
this.previewUI.hideNotification();
|
|
39656
39660
|
if (data.data.mode === ANNOTATION_TYPE_DRAW) {
|
|
39657
39661
|
this.previewUI.replaceHeader(data.data.headerSelector);
|
|
39658
39662
|
}
|
|
39659
39663
|
break;
|
|
39660
39664
|
case constants/* ANNOTATOR_EVENT */.GA.error:
|
|
39661
|
-
this.previewUI.
|
|
39665
|
+
this.previewUI.showNotification(data.data, null, false, 'error');
|
|
39662
39666
|
break;
|
|
39663
39667
|
case constants/* ANNOTATOR_EVENT */.GA.fetch:
|
|
39664
39668
|
this.emit('scale', {
|
|
@@ -41662,6 +41666,8 @@ const ANNOTATION_MODE_ICONS = {
|
|
|
41662
41666
|
[AnnotationMode.REGION]: __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_SquarePlus_c11758f1_default__
|
|
41663
41667
|
};
|
|
41664
41668
|
/* harmony default export */ const annotationModeIcons = (ANNOTATION_MODE_ICONS);
|
|
41669
|
+
// EXTERNAL MODULE: ./src/lib/viewers/controls/media/utils.ts
|
|
41670
|
+
var utils = __webpack_require__(5346);
|
|
41665
41671
|
;// ./src/lib/viewers/controls/controls-bar/ControlsBarV2.scss
|
|
41666
41672
|
// extracted by mini-css-extract-plugin
|
|
41667
41673
|
|
|
@@ -41673,6 +41679,7 @@ function ControlsBarV2_objectWithoutPropertiesLoose(r, e) { if (null == r) retur
|
|
|
41673
41679
|
|
|
41674
41680
|
|
|
41675
41681
|
|
|
41682
|
+
|
|
41676
41683
|
function ControlsBarV2(_ref, ref) {
|
|
41677
41684
|
let {
|
|
41678
41685
|
children,
|
|
@@ -41687,7 +41694,9 @@ function ControlsBarV2(_ref, ref) {
|
|
|
41687
41694
|
className: `bp-ControlsBarV2 bp-ControlsBarV2--${size}`,
|
|
41688
41695
|
colorScheme: "dark",
|
|
41689
41696
|
"data-testid": "bp-ControlsBar"
|
|
41690
|
-
}, rest
|
|
41697
|
+
}, rest, {
|
|
41698
|
+
onKeyDown: utils/* stopToolbarKeyPropagation */.B9
|
|
41699
|
+
}), children);
|
|
41691
41700
|
}
|
|
41692
41701
|
/* harmony default export */ const controls_bar_ControlsBarV2 = (/*#__PURE__*/external_react_["default"].forwardRef(ControlsBarV2));
|
|
41693
41702
|
;// ./src/lib/viewers/controls/annotations/AnnotationsPaletteV2.scss
|
|
@@ -45442,6 +45451,116 @@ class Notification {
|
|
|
45442
45451
|
}
|
|
45443
45452
|
}
|
|
45444
45453
|
/* harmony default export */ const lib_Notification = (Notification);
|
|
45454
|
+
;// ./src/lib/NotificationsV2.scss
|
|
45455
|
+
// extracted by mini-css-extract-plugin
|
|
45456
|
+
|
|
45457
|
+
;// ./src/lib/NotificationsV2.tsx
|
|
45458
|
+
/* provided dependency */ var NotificationsV2_ = __webpack_require__(441)["Tl"];
|
|
45459
|
+
function NotificationsV2_ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
45460
|
+
function NotificationsV2_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? NotificationsV2_ownKeys(Object(t), !0).forEach(function (r) { NotificationsV2_defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : NotificationsV2_ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
45461
|
+
function NotificationsV2_defineProperty(e, r, t) { return (r = NotificationsV2_toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
45462
|
+
function NotificationsV2_toPropertyKey(t) { var i = NotificationsV2_toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
|
45463
|
+
function NotificationsV2_toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
45464
|
+
|
|
45465
|
+
|
|
45466
|
+
|
|
45467
|
+
|
|
45468
|
+
|
|
45469
|
+
const getTypeIconLabel = variant => {
|
|
45470
|
+
switch (variant) {
|
|
45471
|
+
case 'error':
|
|
45472
|
+
return NotificationsV2_('notification_icon_error');
|
|
45473
|
+
case 'success':
|
|
45474
|
+
return NotificationsV2_('notification_icon_success');
|
|
45475
|
+
case 'warning':
|
|
45476
|
+
return NotificationsV2_('notification_icon_warning');
|
|
45477
|
+
default:
|
|
45478
|
+
return NotificationsV2_('notification_icon_info');
|
|
45479
|
+
}
|
|
45480
|
+
};
|
|
45481
|
+
function NotificationsBridge({
|
|
45482
|
+
onReady
|
|
45483
|
+
}) {
|
|
45484
|
+
const {
|
|
45485
|
+
addNotification,
|
|
45486
|
+
removeAllNotifications
|
|
45487
|
+
} = (0,blueprint_web_.useNotification)();
|
|
45488
|
+
external_react_["default"].useLayoutEffect(() => {
|
|
45489
|
+
onReady({
|
|
45490
|
+
addNotification,
|
|
45491
|
+
removeAllNotifications
|
|
45492
|
+
});
|
|
45493
|
+
}, [addNotification, onReady, removeAllNotifications]);
|
|
45494
|
+
return /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Notification.Viewport, {
|
|
45495
|
+
className: "bp-NotificationsV2-viewport"
|
|
45496
|
+
});
|
|
45497
|
+
}
|
|
45498
|
+
class NotificationsV2Root {
|
|
45499
|
+
constructor(containerEl) {
|
|
45500
|
+
NotificationsV2_defineProperty(this, "api", null);
|
|
45501
|
+
NotificationsV2_defineProperty(this, "hostEl", void 0);
|
|
45502
|
+
NotificationsV2_defineProperty(this, "isDestroyed", false);
|
|
45503
|
+
NotificationsV2_defineProperty(this, "pending", []);
|
|
45504
|
+
NotificationsV2_defineProperty(this, "root", void 0);
|
|
45505
|
+
// createRoot renders asynchronously, so calls made before the provider mounts are replayed once it does.
|
|
45506
|
+
NotificationsV2_defineProperty(this, "handleReady", api => {
|
|
45507
|
+
if (this.isDestroyed) {
|
|
45508
|
+
return;
|
|
45509
|
+
}
|
|
45510
|
+
this.api = api;
|
|
45511
|
+
const {
|
|
45512
|
+
pending
|
|
45513
|
+
} = this;
|
|
45514
|
+
this.pending = [];
|
|
45515
|
+
pending.forEach(call => call(api));
|
|
45516
|
+
});
|
|
45517
|
+
this.hostEl = document.createElement('div');
|
|
45518
|
+
this.hostEl.className = 'bp-NotificationsV2Root';
|
|
45519
|
+
containerEl.appendChild(this.hostEl);
|
|
45520
|
+
this.root = (0,client_.createRoot)(this.hostEl);
|
|
45521
|
+
this.root.render(/*#__PURE__*/external_react_["default"].createElement(BlueprintProviders/* default */.A, {
|
|
45522
|
+
container: this.hostEl
|
|
45523
|
+
}, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Notification.Provider, {
|
|
45524
|
+
label: NotificationsV2_('notifications_region_label')
|
|
45525
|
+
}, /*#__PURE__*/external_react_["default"].createElement(NotificationsBridge, {
|
|
45526
|
+
onReady: this.handleReady
|
|
45527
|
+
}))));
|
|
45528
|
+
}
|
|
45529
|
+
destroy() {
|
|
45530
|
+
this.isDestroyed = true;
|
|
45531
|
+
this.api = null;
|
|
45532
|
+
this.pending = [];
|
|
45533
|
+
this.root.unmount();
|
|
45534
|
+
this.hostEl.remove();
|
|
45535
|
+
}
|
|
45536
|
+
hide() {
|
|
45537
|
+
this.run(api => api.removeAllNotifications());
|
|
45538
|
+
}
|
|
45539
|
+
show(message, buttonText, persist = false, variant = 'info') {
|
|
45540
|
+
this.run(api => api.addNotification(NotificationsV2_objectSpread(NotificationsV2_objectSpread({}, persist && {
|
|
45541
|
+
duration: Infinity
|
|
45542
|
+
}), {}, {
|
|
45543
|
+
children: buttonText ? /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Notification.Button, {
|
|
45544
|
+
ariaLabel: buttonText
|
|
45545
|
+
}, buttonText) : undefined,
|
|
45546
|
+
closeButtonAriaLabel: NotificationsV2_('notification_button_default_label'),
|
|
45547
|
+
sensitivity: 'foreground',
|
|
45548
|
+
styledText: message,
|
|
45549
|
+
typeIconAriaLabel: getTypeIconLabel(variant),
|
|
45550
|
+
variant
|
|
45551
|
+
})));
|
|
45552
|
+
}
|
|
45553
|
+
run(call) {
|
|
45554
|
+
if (this.isDestroyed) {
|
|
45555
|
+
return;
|
|
45556
|
+
}
|
|
45557
|
+
if (this.api) {
|
|
45558
|
+
call(this.api);
|
|
45559
|
+
} else {
|
|
45560
|
+
this.pending.push(call);
|
|
45561
|
+
}
|
|
45562
|
+
}
|
|
45563
|
+
}
|
|
45445
45564
|
;// ./src/lib/viewers/box3d/box3DAssets.js
|
|
45446
45565
|
|
|
45447
45566
|
const STATIC_URI = `third-party/model3d/${constants/* MODEL3D_STATIC_ASSETS_VERSION */.f6}/`;
|
|
@@ -45451,6 +45570,7 @@ const JS = [`${STATIC_URI}boxsdk.min.js`, `${STATIC_URI}three.min.js`, `${STATIC
|
|
|
45451
45570
|
// extracted by mini-css-extract-plugin
|
|
45452
45571
|
|
|
45453
45572
|
;// ./src/lib/viewers/box3d/Box3DViewer.js
|
|
45573
|
+
/* provided dependency */ var Box3DViewer_ = __webpack_require__(441)["Tl"];
|
|
45454
45574
|
function Box3DViewer_defineProperty(e, r, t) { return (r = Box3DViewer_toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
45455
45575
|
function Box3DViewer_toPropertyKey(t) { var i = Box3DViewer_toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
|
45456
45576
|
function Box3DViewer_toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
@@ -45463,6 +45583,8 @@ function Box3DViewer_toPrimitive(t, r) { if ("object" != typeof t || !t) return
|
|
|
45463
45583
|
|
|
45464
45584
|
|
|
45465
45585
|
|
|
45586
|
+
|
|
45587
|
+
|
|
45466
45588
|
// Milliseconds to wait for model to load before cancelling Preview
|
|
45467
45589
|
const LOAD_TIMEOUT = 50000;
|
|
45468
45590
|
const CLASS_VR_ENABLED = 'vr-enabled';
|
|
@@ -45479,7 +45601,7 @@ class Box3DViewer extends viewers_BaseViewer {
|
|
|
45479
45601
|
Box3DViewer_defineProperty(this, "renderer", void 0);
|
|
45480
45602
|
/** @property {HTMLElement} - Parent element for nesting the 3D scene and notifications in */
|
|
45481
45603
|
Box3DViewer_defineProperty(this, "wrapperEl", void 0);
|
|
45482
|
-
/** @property {Notification} - Used to notify users of WebGL context issues */
|
|
45604
|
+
/** @property {Notification|NotificationsV2Root} - Used to notify users of WebGL context issues */
|
|
45483
45605
|
Box3DViewer_defineProperty(this, "contextNotification", void 0);
|
|
45484
45606
|
/** @property {boolean} - Used to show the VR button in the controls */
|
|
45485
45607
|
Box3DViewer_defineProperty(this, "showVrButton", false);
|
|
@@ -45509,7 +45631,7 @@ class Box3DViewer extends viewers_BaseViewer {
|
|
|
45509
45631
|
this.renderer = null;
|
|
45510
45632
|
this.wrapperEl = this.createViewer(document.createElement('div'));
|
|
45511
45633
|
this.wrapperEl.className = CSS_CLASS_BOX3D;
|
|
45512
|
-
this.contextNotification = new lib_Notification(this.wrapperEl);
|
|
45634
|
+
this.contextNotification = this.featureEnabled(constants/* BLUEPRINT_MIGRATION_SUPPORTING_UI */.Ed) ? new NotificationsV2Root(this.wrapperEl) : new lib_Notification(this.wrapperEl);
|
|
45513
45635
|
this.loadTimeout = LOAD_TIMEOUT;
|
|
45514
45636
|
}
|
|
45515
45637
|
|
|
@@ -45593,6 +45715,10 @@ class Box3DViewer extends viewers_BaseViewer {
|
|
|
45593
45715
|
super.destroy();
|
|
45594
45716
|
this.detachEventHandlers();
|
|
45595
45717
|
this.destroySubModules();
|
|
45718
|
+
if (this.contextNotification instanceof NotificationsV2Root) {
|
|
45719
|
+
this.contextNotification.destroy();
|
|
45720
|
+
this.contextNotification = null;
|
|
45721
|
+
}
|
|
45596
45722
|
this.destroyed = true;
|
|
45597
45723
|
}
|
|
45598
45724
|
|
|
@@ -45677,7 +45803,7 @@ class Box3DViewer extends viewers_BaseViewer {
|
|
|
45677
45803
|
* @return {void}
|
|
45678
45804
|
*/
|
|
45679
45805
|
handleContextLost() {
|
|
45680
|
-
this.contextNotification.show('
|
|
45806
|
+
this.contextNotification.show(Box3DViewer_('notification_webgl_context_lost'), null, false, 'warning');
|
|
45681
45807
|
this.destroySubModules();
|
|
45682
45808
|
}
|
|
45683
45809
|
|
|
@@ -45688,7 +45814,7 @@ class Box3DViewer extends viewers_BaseViewer {
|
|
|
45688
45814
|
*/
|
|
45689
45815
|
handleContextRestored() {
|
|
45690
45816
|
this.detachEventHandlers();
|
|
45691
|
-
this.contextNotification.show('
|
|
45817
|
+
this.contextNotification.show(Box3DViewer_('notification_webgl_context_restored'), null, false, 'success');
|
|
45692
45818
|
this.previewUI.showLoadingIndicator();
|
|
45693
45819
|
this.postLoad();
|
|
45694
45820
|
}
|
|
@@ -45850,8 +45976,6 @@ function Image360Controls({
|
|
|
45850
45976
|
}
|
|
45851
45977
|
;// external "@box/blueprint-web-assets/icons/Medium/VrGoggles"
|
|
45852
45978
|
|
|
45853
|
-
// EXTERNAL MODULE: ./src/lib/viewers/controls/media/utils.ts
|
|
45854
|
-
var utils = __webpack_require__(5346);
|
|
45855
45979
|
;// ./src/lib/viewers/controls/box3d/VrToggleControlV2.tsx
|
|
45856
45980
|
/* provided dependency */ var VrToggleControlV2_ = __webpack_require__(441)["Tl"];
|
|
45857
45981
|
const VrToggleControlV2_excluded = ["buttonType", "isVrShown", "onVrToggle"];
|
|
@@ -47458,6 +47582,68 @@ class PrintModalRoot {
|
|
|
47458
47582
|
}
|
|
47459
47583
|
;// ./src/lib/icons/print_checkmark.svg
|
|
47460
47584
|
const print_checkmark_namespaceObject = "<svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" focusable=\"false\">\n <path d=\"M4.187 6.48L3.067 7.6l3.6 3.6 8-8-1.12-1.12-6.88 6.88-2.48-2.48zM14.4 8c0 3.52-2.88 6.4-6.4 6.4-3.52 0-6.4-2.88-6.4-6.4 0-3.52 2.88-6.4 6.4-6.4.64 0 1.2.08 1.76.24L11.04.56C10.08.24 9.04 0 8 0 3.6 0 0 3.6 0 8s3.6 8 8 8 8-3.6 8-8h-1.6z\" fill=\"#22A7F0\" fill-rule=\"evenodd\"/>\n</svg>\n";
|
|
47585
|
+
;// ./src/lib/viewers/text/printStyles.ts
|
|
47586
|
+
// The PlainText.scss and Markdown.scss rules that can match inside the print iframe, which holds only
|
|
47587
|
+
// the text element. Keep them in sync with those files; printStyles-test.ts fails when they drift.
|
|
47588
|
+
const PLAIN_TEXT_PRINT_STYLES = `
|
|
47589
|
+
.bp-text-plain {
|
|
47590
|
+
position: absolute;
|
|
47591
|
+
inset: 0;
|
|
47592
|
+
overflow: auto;
|
|
47593
|
+
margin: 0;
|
|
47594
|
+
line-height: 1.5;
|
|
47595
|
+
text-align: left;
|
|
47596
|
+
word-wrap: break-word;
|
|
47597
|
+
white-space: pre-wrap;
|
|
47598
|
+
background-color: #fff;
|
|
47599
|
+
}
|
|
47600
|
+
|
|
47601
|
+
.bp-text-plain ul {
|
|
47602
|
+
list-style: disc;
|
|
47603
|
+
}
|
|
47604
|
+
|
|
47605
|
+
.bp-text-plain ol {
|
|
47606
|
+
list-style: decimal;
|
|
47607
|
+
}
|
|
47608
|
+
|
|
47609
|
+
.bp-text-plain ol ul,
|
|
47610
|
+
.bp-text-plain ul ul {
|
|
47611
|
+
list-style: circle;
|
|
47612
|
+
}
|
|
47613
|
+
|
|
47614
|
+
.bp-text-truncated {
|
|
47615
|
+
padding-bottom: 75px;
|
|
47616
|
+
font-family: Lato, "Helvetica Neue", Helvetica, Arial, sans-serif;
|
|
47617
|
+
text-align: center;
|
|
47618
|
+
}
|
|
47619
|
+
|
|
47620
|
+
.bp-text-truncated p {
|
|
47621
|
+
margin: 10px 0;
|
|
47622
|
+
}
|
|
47623
|
+
|
|
47624
|
+
@media print {
|
|
47625
|
+
.bp-text-plain {
|
|
47626
|
+
position: static;
|
|
47627
|
+
overflow: visible;
|
|
47628
|
+
margin: 0;
|
|
47629
|
+
padding: 0;
|
|
47630
|
+
word-wrap: break-word;
|
|
47631
|
+
}
|
|
47632
|
+
|
|
47633
|
+
.bp-text-truncated .bp-btn-download {
|
|
47634
|
+
display: none;
|
|
47635
|
+
}
|
|
47636
|
+
}
|
|
47637
|
+
`;
|
|
47638
|
+
const MARKDOWN_PRINT_STYLES = `${PLAIN_TEXT_PRINT_STYLES}
|
|
47639
|
+
.markdown-body {
|
|
47640
|
+
white-space: normal;
|
|
47641
|
+
}
|
|
47642
|
+
|
|
47643
|
+
.markdown-body ul li {
|
|
47644
|
+
list-style: disc;
|
|
47645
|
+
}
|
|
47646
|
+
`;
|
|
47461
47647
|
;// ./src/lib/viewers/text/PlainText.scss
|
|
47462
47648
|
// extracted by mini-css-extract-plugin
|
|
47463
47649
|
|
|
@@ -47478,6 +47664,8 @@ function PlainTextViewer_toPrimitive(t, r) { if ("object" != typeof t || !t) ret
|
|
|
47478
47664
|
|
|
47479
47665
|
|
|
47480
47666
|
|
|
47667
|
+
|
|
47668
|
+
|
|
47481
47669
|
// Inline web worker JS
|
|
47482
47670
|
const HIGHLIGHT_WORKER_JS = 'onmessage=function(e){importScripts(e.data.highlightSrc);postMessage(self.hljs.highlightAuto(e.data.text).value)};';
|
|
47483
47671
|
|
|
@@ -47606,7 +47794,7 @@ class PlainTextViewer extends text_TextBaseViewer {
|
|
|
47606
47794
|
*/
|
|
47607
47795
|
print() {
|
|
47608
47796
|
if (!this.printReady) {
|
|
47609
|
-
this.preparePrint(this.getCSS()
|
|
47797
|
+
this.preparePrint(this.getCSS());
|
|
47610
47798
|
this.printPopup.show(PlainTextViewer_('print_loading'), PlainTextViewer_('print'), () => {
|
|
47611
47799
|
this.printPopup.hide();
|
|
47612
47800
|
this.printIframe();
|
|
@@ -47663,6 +47851,15 @@ class PlainTextViewer extends text_TextBaseViewer {
|
|
|
47663
47851
|
return src_CSS;
|
|
47664
47852
|
}
|
|
47665
47853
|
|
|
47854
|
+
/**
|
|
47855
|
+
* Returns the viewer styles that npm builds inject into the print iframe
|
|
47856
|
+
*
|
|
47857
|
+
* @return {string} CSS text
|
|
47858
|
+
*/
|
|
47859
|
+
getPrintStyles() {
|
|
47860
|
+
return PLAIN_TEXT_PRINT_STYLES;
|
|
47861
|
+
}
|
|
47862
|
+
|
|
47666
47863
|
/**
|
|
47667
47864
|
* Finishes loading after text is highlighted.
|
|
47668
47865
|
*
|
|
@@ -47751,19 +47948,30 @@ class PlainTextViewer extends text_TextBaseViewer {
|
|
|
47751
47948
|
}
|
|
47752
47949
|
|
|
47753
47950
|
/**
|
|
47754
|
-
*
|
|
47755
|
-
* styles into an iframe that can be printed.
|
|
47951
|
+
* Writes the text element into a printable iframe and attaches its print styles.
|
|
47756
47952
|
*
|
|
47757
47953
|
* @private
|
|
47758
|
-
* @param {string[]} stylesheets -
|
|
47954
|
+
* @param {string[]} stylesheets - Third-party stylesheets needed for print, before the viewer's own styles
|
|
47759
47955
|
* @return {void}
|
|
47760
47956
|
*/
|
|
47761
47957
|
preparePrint(stylesheets) {
|
|
47762
47958
|
const assetUrlCreator = (0,util/* createAssetUrlCreator */.my)(this.options.location);
|
|
47763
47959
|
this.printframe = (0,util/* openContentInsideIframe */.G9)(this.textEl.outerHTML);
|
|
47960
|
+
const {
|
|
47961
|
+
head
|
|
47962
|
+
} = this.printframe.contentDocument;
|
|
47764
47963
|
stylesheets.forEach(stylesheet => {
|
|
47765
|
-
|
|
47964
|
+
head.appendChild((0,util/* createStylesheet */.fX)(assetUrlCreator(stylesheet)));
|
|
47766
47965
|
});
|
|
47966
|
+
|
|
47967
|
+
// npm consumers bundle the viewer CSS themselves and host no preview.css to link to.
|
|
47968
|
+
if ((0,isNpmBuild/* isNpmBuild */.w)()) {
|
|
47969
|
+
const printStyleEl = document.createElement('style');
|
|
47970
|
+
printStyleEl.textContent = this.getPrintStyles();
|
|
47971
|
+
head.appendChild(printStyleEl);
|
|
47972
|
+
} else {
|
|
47973
|
+
head.appendChild((0,util/* createStylesheet */.fX)(assetUrlCreator('preview.css')));
|
|
47974
|
+
}
|
|
47767
47975
|
setTimeout(() => {
|
|
47768
47976
|
if (this.printPopup instanceof PrintModalRoot) {
|
|
47769
47977
|
this.printPopup.showReady(PlainTextViewer_('print_ready'));
|
|
@@ -47858,6 +48066,7 @@ function MarkdownControlsV2({
|
|
|
47858
48066
|
|
|
47859
48067
|
|
|
47860
48068
|
|
|
48069
|
+
|
|
47861
48070
|
const MarkdownViewer_STATIC_URI = `third-party/text/${constants/* TEXT_STATIC_ASSETS_VERSION */.cR}/`;
|
|
47862
48071
|
class MarkdownViewer extends text_PlainTextViewer {
|
|
47863
48072
|
/**
|
|
@@ -47896,6 +48105,13 @@ class MarkdownViewer extends text_PlainTextViewer {
|
|
|
47896
48105
|
return super.getCSS().concat(`${MarkdownViewer_STATIC_URI}github-markdown.min.css`);
|
|
47897
48106
|
}
|
|
47898
48107
|
|
|
48108
|
+
/**
|
|
48109
|
+
* @inheritdoc
|
|
48110
|
+
*/
|
|
48111
|
+
getPrintStyles() {
|
|
48112
|
+
return MARKDOWN_PRINT_STYLES;
|
|
48113
|
+
}
|
|
48114
|
+
|
|
47899
48115
|
/**
|
|
47900
48116
|
* Prints text using an an iframe. Adds Github Markdown CSS to print styles.
|
|
47901
48117
|
*
|
|
@@ -47904,7 +48120,7 @@ class MarkdownViewer extends text_PlainTextViewer {
|
|
|
47904
48120
|
*/
|
|
47905
48121
|
print() {
|
|
47906
48122
|
if (!this.printReady) {
|
|
47907
|
-
this.preparePrint(this.getCSS()
|
|
48123
|
+
this.preparePrint(this.getCSS());
|
|
47908
48124
|
this.printPopup.show(MarkdownViewer_('print_loading'), MarkdownViewer_('print'), () => {
|
|
47909
48125
|
this.printPopup.hide();
|
|
47910
48126
|
this.printIframe();
|
|
@@ -66414,7 +66630,7 @@ class DocumentViewer extends doc_DocBaseViewer {
|
|
|
66414
66630
|
} = this.options.file;
|
|
66415
66631
|
const isOfficeOnlineExtension = OFFICE_ONLINE_EXTENSIONS.includes(extension);
|
|
66416
66632
|
if (isOfficeOnlineExtension && lib_Browser.isIE()) {
|
|
66417
|
-
this.options.ui.showNotification(DocumentViewer_('error_internet_explorer_office_online'), null, true);
|
|
66633
|
+
this.options.ui.showNotification(DocumentViewer_('error_internet_explorer_office_online'), null, true, 'warning');
|
|
66418
66634
|
}
|
|
66419
66635
|
}
|
|
66420
66636
|
|
|
@@ -66490,7 +66706,7 @@ class AutoCADViewer extends doc_DocumentViewer {
|
|
|
66490
66706
|
[AutoCADViewer_FIELD_HASXREFS]: hasxrefsValue
|
|
66491
66707
|
}) => {
|
|
66492
66708
|
if (hasxrefsValue) {
|
|
66493
|
-
this.options.ui.showNotification(AutoCADViewer_('has_x_refs'), null, true);
|
|
66709
|
+
this.options.ui.showNotification(AutoCADViewer_('has_x_refs'), null, true, 'warning');
|
|
66494
66710
|
this.emitMetric({
|
|
66495
66711
|
name: lib_events/* MISSING_EXTERNAL_REFS */.w0,
|
|
66496
66712
|
data: extension
|
|
@@ -71215,6 +71431,7 @@ function PreviewUI_toPrimitive(t, r) { if ("object" != typeof t || !t) return t;
|
|
|
71215
71431
|
|
|
71216
71432
|
|
|
71217
71433
|
|
|
71434
|
+
|
|
71218
71435
|
class PreviewUI {
|
|
71219
71436
|
constructor() {
|
|
71220
71437
|
/** @property {CollectionNavigationRoot} - Blueprint navigation arrows, set only with the supporting UI flag */
|
|
@@ -71254,6 +71471,10 @@ class PreviewUI {
|
|
|
71254
71471
|
this.collectionNavigation.destroy();
|
|
71255
71472
|
this.collectionNavigation = null;
|
|
71256
71473
|
}
|
|
71474
|
+
if (this.notification instanceof NotificationsV2Root) {
|
|
71475
|
+
this.notification.destroy();
|
|
71476
|
+
this.notification = null;
|
|
71477
|
+
}
|
|
71257
71478
|
if (this.container) {
|
|
71258
71479
|
this.container.innerHTML = '';
|
|
71259
71480
|
}
|
|
@@ -71450,10 +71671,14 @@ class PreviewUI {
|
|
|
71450
71671
|
* Setup notification
|
|
71451
71672
|
*
|
|
71452
71673
|
* @public
|
|
71674
|
+
* @param {Object} [features] - Preview feature flags
|
|
71453
71675
|
* @return {void}
|
|
71454
71676
|
*/
|
|
71455
|
-
setupNotification() {
|
|
71456
|
-
this.notification
|
|
71677
|
+
setupNotification(features) {
|
|
71678
|
+
if (this.notification instanceof NotificationsV2Root) {
|
|
71679
|
+
this.notification.destroy();
|
|
71680
|
+
}
|
|
71681
|
+
this.notification = isFeatureEnabled(features, constants/* BLUEPRINT_MIGRATION_SUPPORTING_UI */.Ed) ? new NotificationsV2Root(this.contentContainer) : new lib_Notification(this.contentContainer);
|
|
71457
71682
|
}
|
|
71458
71683
|
|
|
71459
71684
|
/**
|
|
@@ -71461,15 +71686,16 @@ class PreviewUI {
|
|
|
71461
71686
|
*
|
|
71462
71687
|
* @public
|
|
71463
71688
|
* @param {string} message - Notification message
|
|
71464
|
-
* @param {string} [buttonText] - Optional text to show in button
|
|
71689
|
+
* @param {string|null} [buttonText] - Optional text to show in button
|
|
71465
71690
|
* @param {boolean} [persist] - Optional boolean to persist the notification
|
|
71691
|
+
* @param {string} [variant] - Blueprint notification variant: error, info, success, or warning
|
|
71466
71692
|
* @return {void}
|
|
71467
71693
|
*/
|
|
71468
|
-
showNotification(message, buttonText, persist) {
|
|
71694
|
+
showNotification(message, buttonText, persist, variant) {
|
|
71469
71695
|
if (!this.notification) {
|
|
71470
71696
|
return;
|
|
71471
71697
|
}
|
|
71472
|
-
this.notification.show(message, buttonText, persist);
|
|
71698
|
+
this.notification.show(message, buttonText, persist, variant);
|
|
71473
71699
|
}
|
|
71474
71700
|
|
|
71475
71701
|
/**
|
|
@@ -72278,7 +72504,7 @@ class Preview extends (events_default()) {
|
|
|
72278
72504
|
const downloadErrorMsg = Preview_('notification_cannot_download');
|
|
72279
72505
|
const downloadErrorDueToPolicyMsg = Preview_('notification_cannot_download_due_to_policy');
|
|
72280
72506
|
if (!canDownload(this.file, this.options)) {
|
|
72281
|
-
this.ui.showNotification(downloadErrorMsg);
|
|
72507
|
+
this.ui.showNotification(downloadErrorMsg, null, false, 'error');
|
|
72282
72508
|
return;
|
|
72283
72509
|
}
|
|
72284
72510
|
|
|
@@ -72293,7 +72519,7 @@ class Preview extends (events_default()) {
|
|
|
72293
72519
|
if (shouldDownloadWM(this.file, this.options)) {
|
|
72294
72520
|
const contentUrlTemplate = (0,util/* getProp */.GT)(this.viewer.getRepresentation(), 'content.url_template');
|
|
72295
72521
|
if (!contentUrlTemplate) {
|
|
72296
|
-
this.ui.showNotification(downloadErrorMsg);
|
|
72522
|
+
this.ui.showNotification(downloadErrorMsg, null, false, 'error');
|
|
72297
72523
|
return;
|
|
72298
72524
|
}
|
|
72299
72525
|
|
|
@@ -72318,7 +72544,7 @@ class Preview extends (events_default()) {
|
|
|
72318
72544
|
}).catch(error => {
|
|
72319
72545
|
const code = (0,util/* getProp */.GT)(error, 'response.data.code');
|
|
72320
72546
|
const msg = code === constants/* ERROR_CODE_403_FORBIDDEN_BY_POLICY */.yC ? downloadErrorDueToPolicyMsg : downloadErrorMsg;
|
|
72321
|
-
this.ui.showNotification(msg);
|
|
72547
|
+
this.ui.showNotification(msg, null, false, 'error');
|
|
72322
72548
|
});
|
|
72323
72549
|
|
|
72324
72550
|
// Otherwise, get the content download URL of the original file and download
|
|
@@ -72332,7 +72558,7 @@ class Preview extends (events_default()) {
|
|
|
72332
72558
|
}).catch(error => {
|
|
72333
72559
|
const code = (0,util/* getProp */.GT)(error, 'response.data.code');
|
|
72334
72560
|
const msg = code === constants/* ERROR_CODE_403_FORBIDDEN_BY_POLICY */.yC ? downloadErrorDueToPolicyMsg : downloadErrorMsg;
|
|
72335
|
-
this.ui.showNotification(msg);
|
|
72561
|
+
this.ui.showNotification(msg, null, false, 'error');
|
|
72336
72562
|
});
|
|
72337
72563
|
}
|
|
72338
72564
|
this.emitLogEvent(lib_events/* PREVIEW_METRIC */.Yl, {
|
|
@@ -72649,7 +72875,7 @@ class Preview extends (events_default()) {
|
|
|
72649
72875
|
this.container = this.ui.setup(this.options, this.keydownHandler, this.navigateLeft, this.navigateRight, this.throttledMousemoveHandler);
|
|
72650
72876
|
|
|
72651
72877
|
// Set up the notification
|
|
72652
|
-
this.ui.setupNotification();
|
|
72878
|
+
this.ui.setupNotification(this.options.features);
|
|
72653
72879
|
this.updateComparisonBanner();
|
|
72654
72880
|
|
|
72655
72881
|
// Update navigation
|