box-content-preview 3.120.0 → 3.121.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 +6 -0
- package/dist/lib/i18n/da-DK.js +6 -0
- package/dist/lib/i18n/de-DE.js +6 -0
- package/dist/lib/i18n/en-AU.js +6 -0
- package/dist/lib/i18n/en-CA.js +6 -0
- package/dist/lib/i18n/en-GB.js +6 -0
- package/dist/lib/i18n/en-US.js +6 -0
- package/dist/lib/i18n/en-x-pseudo.js +6 -0
- package/dist/lib/i18n/es-419.js +6 -0
- package/dist/lib/i18n/es-ES.js +6 -0
- package/dist/lib/i18n/fi-FI.js +6 -0
- package/dist/lib/i18n/fr-CA.js +6 -0
- package/dist/lib/i18n/fr-FR.js +6 -0
- package/dist/lib/i18n/hi-IN.js +6 -0
- package/dist/lib/i18n/it-IT.js +6 -0
- package/dist/lib/i18n/ja-JP.js +6 -0
- package/dist/lib/i18n/ko-KR.js +6 -0
- package/dist/lib/i18n/nb-NO.js +6 -0
- package/dist/lib/i18n/nl-NL.js +6 -0
- package/dist/lib/i18n/pl-PL.js +6 -0
- package/dist/lib/i18n/pt-BR.js +6 -0
- package/dist/lib/i18n/ru-RU.js +6 -0
- package/dist/lib/i18n/sv-SE.js +6 -0
- package/dist/lib/i18n/tr-TR.js +6 -0
- package/dist/lib/i18n/zh-CN.js +6 -0
- package/dist/lib/i18n/zh-TW.js +6 -0
- package/dist/lib/index.css +4 -0
- package/dist/lib/index.js +705 -109
- package/dist/lib/pdfjs-images/altText_add.svg +3 -0
- package/dist/lib/pdfjs-images/altText_disclaimer.svg +3 -0
- package/dist/lib/pdfjs-images/altText_done.svg +3 -0
- package/dist/lib/pdfjs-images/altText_spinner.svg +30 -0
- package/dist/lib/pdfjs-images/altText_warning.svg +3 -0
- package/dist/lib/pdfjs-images/annotation-check.svg +11 -0
- package/dist/lib/pdfjs-images/annotation-comment.svg +16 -0
- package/dist/lib/pdfjs-images/annotation-help.svg +26 -0
- package/dist/lib/pdfjs-images/annotation-insert.svg +10 -0
- package/dist/lib/pdfjs-images/annotation-key.svg +11 -0
- package/dist/lib/pdfjs-images/annotation-newparagraph.svg +11 -0
- package/dist/lib/pdfjs-images/annotation-noicon.svg +7 -0
- package/dist/lib/pdfjs-images/annotation-note.svg +42 -0
- package/dist/lib/pdfjs-images/annotation-paperclip.svg +6 -0
- package/dist/lib/pdfjs-images/annotation-paragraph.svg +16 -0
- package/dist/lib/pdfjs-images/annotation-pushpin.svg +7 -0
- package/dist/lib/pdfjs-images/checkmark.svg +5 -0
- package/dist/lib/pdfjs-images/comment-actionsButton.svg +3 -0
- package/dist/lib/pdfjs-images/comment-closeButton.svg +3 -0
- package/dist/lib/pdfjs-images/comment-editButton.svg +8 -0
- package/dist/lib/pdfjs-images/comment-popup-editButton.svg +5 -0
- package/dist/lib/pdfjs-images/cursor-editorFreeHighlight.svg +6 -0
- package/dist/lib/pdfjs-images/cursor-editorFreeText.svg +3 -0
- package/dist/lib/pdfjs-images/cursor-editorInk.svg +4 -0
- package/dist/lib/pdfjs-images/cursor-editorTextHighlight.svg +8 -0
- package/dist/lib/pdfjs-images/editor-toolbar-delete.svg +5 -0
- package/dist/lib/pdfjs-images/editor-toolbar-edit.svg +3 -0
- package/dist/lib/pdfjs-images/findbarButton-next.svg +3 -0
- package/dist/lib/pdfjs-images/findbarButton-previous.svg +3 -0
- package/dist/lib/pdfjs-images/gv-toolbarButton-download.svg +3 -0
- package/dist/lib/pdfjs-images/loading-icon.gif +0 -0
- package/dist/lib/pdfjs-images/loading.svg +1 -0
- package/dist/lib/pdfjs-images/messageBar_closingButton.svg +3 -0
- package/dist/lib/pdfjs-images/messageBar_info.svg +3 -0
- package/dist/lib/pdfjs-images/messageBar_warning.svg +3 -0
- package/dist/lib/pdfjs-images/pages_closeButton.svg +3 -0
- package/dist/lib/pdfjs-images/pages_selected.svg +7 -0
- package/dist/lib/pdfjs-images/pages_viewArrow.svg +3 -0
- package/dist/lib/pdfjs-images/pages_viewButton.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-documentProperties.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-firstPage.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-handTool.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-lastPage.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-rotateCcw.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-rotateCw.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-scrollHorizontal.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-scrollPage.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-scrollVertical.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-scrollWrapped.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-selectTool.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-spreadEven.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-spreadNone.svg +3 -0
- package/dist/lib/pdfjs-images/secondaryToolbarButton-spreadOdd.svg +3 -0
- package/dist/lib/pdfjs-images/signature-properties-row-check.svg +4 -0
- package/dist/lib/pdfjs-images/toolbarButton-bookmark.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-currentOutlineItem.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-download.svg +4 -0
- package/dist/lib/pdfjs-images/toolbarButton-editorFreeText.svg +5 -0
- package/dist/lib/pdfjs-images/toolbarButton-editorHighlight.svg +6 -0
- package/dist/lib/pdfjs-images/toolbarButton-editorInk.svg +4 -0
- package/dist/lib/pdfjs-images/toolbarButton-editorSignature.svg +6 -0
- package/dist/lib/pdfjs-images/toolbarButton-editorStamp.svg +8 -0
- package/dist/lib/pdfjs-images/toolbarButton-menuArrow.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-menuArrowNova.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-openFile.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-pageDown.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-pageUp.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-presentationMode.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-print.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-search.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-secondaryToolbarToggle.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-signaturePropertiesError.svg +7 -0
- package/dist/lib/pdfjs-images/toolbarButton-signaturePropertiesVerified.svg +7 -0
- package/dist/lib/pdfjs-images/toolbarButton-viewAttachments.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-viewLayers.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-viewOutline.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-viewThumbnail.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-viewsManagerToggle.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-zoomIn.svg +3 -0
- package/dist/lib/pdfjs-images/toolbarButton-zoomOut.svg +3 -0
- package/dist/lib/pdfjs-images/treeitem-collapsed.svg +1 -0
- package/dist/lib/pdfjs-images/treeitem-expanded.svg +1 -0
- package/package.json +1 -1
package/dist/lib/index.js
CHANGED
|
@@ -51,16 +51,17 @@ import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Me
|
|
|
51
51
|
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Minus_cc9df143_default__ } from "@box/blueprint-web-assets/icons/Medium/Minus";
|
|
52
52
|
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Plus_aaa7b14f_default__ } from "@box/blueprint-web-assets/icons/Medium/Plus";
|
|
53
53
|
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_CheckmarkCircle_e8bd4624_default__ } from "@box/blueprint-web-assets/icons/Medium/CheckmarkCircle";
|
|
54
|
+
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_GridView_ac92b674_default__ } from "@box/blueprint-web-assets/icons/Medium/GridView";
|
|
55
|
+
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Nav_d41e959a_default__ } from "@box/blueprint-web-assets/icons/Medium/Nav";
|
|
56
|
+
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_RotateLeft_c726d679_default__ } from "@box/blueprint-web-assets/icons/Medium/RotateLeft";
|
|
57
|
+
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Search_ef3e4aba_default__ } from "@box/blueprint-web-assets/icons/Medium/Search";
|
|
54
58
|
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_XMark_07fbe0f0_default__ } from "@box/blueprint-web-assets/icons/Medium/XMark";
|
|
55
59
|
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_PencilTip_154ad3fd_default__ } from "@box/blueprint-web-assets/icons/Medium/PencilTip";
|
|
56
60
|
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_SquarePlus_c11758f1_default__ } from "@box/blueprint-web-assets/icons/Medium/SquarePlus";
|
|
57
61
|
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_TCursorHighlight_508374cb_default__ } from "@box/blueprint-web-assets/icons/Medium/TCursorHighlight";
|
|
58
|
-
import { default as
|
|
59
|
-
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_GridView_ac92b674_default__ } from "@box/blueprint-web-assets/icons/Medium/GridView";
|
|
62
|
+
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_EllipsisVertical_06d33c4b_default__ } from "@box/blueprint-web-assets/icons/Medium/EllipsisVertical";
|
|
60
63
|
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_ChevronDown_a545a634_default__ } from "@box/blueprint-web-assets/icons/Medium/ChevronDown";
|
|
61
64
|
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_ChevronUp_d399c022_default__ } from "@box/blueprint-web-assets/icons/Medium/ChevronUp";
|
|
62
|
-
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_RotateLeft_c726d679_default__ } from "@box/blueprint-web-assets/icons/Medium/RotateLeft";
|
|
63
|
-
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Nav_d41e959a_default__ } from "@box/blueprint-web-assets/icons/Medium/Nav";
|
|
64
65
|
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_MediumFilled_Nav_ae6d790f_default__ } from "@box/blueprint-web-assets/icons/MediumFilled/Nav";
|
|
65
66
|
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Checkmark_52a58454_default__ } from "@box/blueprint-web-assets/icons/Medium/Checkmark";
|
|
66
67
|
import { default as __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Download_0dc63cde_default__ } from "@box/blueprint-web-assets/icons/Medium/Download";
|
|
@@ -1113,7 +1114,7 @@ const DEFAULT_LANGUAGE = 'en-US';
|
|
|
1113
1114
|
const MESSAGE_KEY_PREFIX = 'bcp.';
|
|
1114
1115
|
|
|
1115
1116
|
// Only the npm build defines __BCP_DEFAULT_MESSAGES__; the CDN build bakes strings in per locale.
|
|
1116
|
-
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_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","thumbnail_label":"Page thumbnails","file_preview_label":"File preview","comparison_banner_current":"Current version","comparison_banner_previous":"Previous version","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"} : {};
|
|
1117
|
+
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_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","thumbnail_label":"Page thumbnails","file_preview_label":"File preview","comparison_banner_current":"Current version","comparison_banner_previous":"Previous version","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"} : {};
|
|
1117
1118
|
let language = true ? "en-US" : 0;
|
|
1118
1119
|
let strings = defaultStrings;
|
|
1119
1120
|
function getLanguage() {
|
|
@@ -1216,7 +1217,7 @@ function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e =
|
|
|
1216
1217
|
const CLIENT_NAME = "box-content-preview"; // eslint-disable-line no-undef
|
|
1217
1218
|
const CLIENT_NAME_KEY = 'box_client_name';
|
|
1218
1219
|
const CLIENT_VERSION_KEY = 'box_client_version';
|
|
1219
|
-
const CLIENT_VERSION = "3.
|
|
1220
|
+
const CLIENT_VERSION = "3.121.0"; // eslint-disable-line no-undef
|
|
1220
1221
|
const HEADER_CLIENT_NAME = 'X-Box-Client-Name';
|
|
1221
1222
|
const HEADER_CLIENT_VERSION = 'X-Box-Client-Version';
|
|
1222
1223
|
const PROMISE_MAP = {};
|
|
@@ -1509,8 +1510,8 @@ function createAssetUrlCreator(location) {
|
|
|
1509
1510
|
if (name.indexOf('http') === 0) {
|
|
1510
1511
|
// This is a full url
|
|
1511
1512
|
asset = name;
|
|
1512
|
-
} else if (name.indexOf('third-party') === 0 || name.indexOf('exif/') === 0 || name.indexOf('cmaps/') === 0 || name.indexOf('iccs/') === 0 || name.indexOf('wasm/') === 0 || name.indexOf('standard_fonts/') === 0) {
|
|
1513
|
-
// Static
|
|
1513
|
+
} else if (name.indexOf('third-party') === 0 || name.indexOf('exif/') === 0 || name.indexOf('cmaps/') === 0 || name.indexOf('iccs/') === 0 || name.indexOf('wasm/') === 0 || name.indexOf('standard_fonts/') === 0 || name.indexOf('pdfjs-images/') === 0) {
|
|
1514
|
+
// Static asset shared by every version and locale
|
|
1514
1515
|
asset = staticBaseURI + name;
|
|
1515
1516
|
} else {
|
|
1516
1517
|
// This is our own asset that is localized
|
|
@@ -4081,6 +4082,8 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
4081
4082
|
|
|
4082
4083
|
// EXTERNAL MODULE: external "react"
|
|
4083
4084
|
var external_react_ = __webpack_require__(1649);
|
|
4085
|
+
// EXTERNAL MODULE: external "react-dom"
|
|
4086
|
+
var external_react_dom_ = __webpack_require__(7516);
|
|
4084
4087
|
// EXTERNAL MODULE: external "react-dom/client"
|
|
4085
4088
|
var client_ = __webpack_require__(6662);
|
|
4086
4089
|
// EXTERNAL MODULE: ./node_modules/prop-types/index.js
|
|
@@ -5496,6 +5499,7 @@ function BoxArchive_toPrimitive(t, r) { if ("object" != typeof t || !t) return t
|
|
|
5496
5499
|
|
|
5497
5500
|
|
|
5498
5501
|
|
|
5502
|
+
|
|
5499
5503
|
class BoxArchive {
|
|
5500
5504
|
/**
|
|
5501
5505
|
* [constructor]
|
|
@@ -5554,9 +5558,11 @@ class BoxArchive {
|
|
|
5554
5558
|
resin: this.resin,
|
|
5555
5559
|
v2: v2
|
|
5556
5560
|
});
|
|
5557
|
-
|
|
5558
|
-
|
|
5559
|
-
|
|
5561
|
+
(0,external_react_dom_.flushSync)(() => {
|
|
5562
|
+
this.root.render(v2 ? /*#__PURE__*/external_react_["default"].createElement(v2.BlueprintProviders, {
|
|
5563
|
+
container: this.archiveEl
|
|
5564
|
+
}, explorer) : explorer);
|
|
5565
|
+
});
|
|
5560
5566
|
}
|
|
5561
5567
|
|
|
5562
5568
|
/**
|
|
@@ -6372,7 +6378,7 @@ function MediaSettingsMenuSubtitles({
|
|
|
6372
6378
|
|
|
6373
6379
|
/***/ },
|
|
6374
6380
|
|
|
6375
|
-
/***/
|
|
6381
|
+
/***/ 3519
|
|
6376
6382
|
(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
6377
6383
|
|
|
6378
6384
|
|
|
@@ -6394,22 +6400,8 @@ var Medium_ = __webpack_require__(9747);
|
|
|
6394
6400
|
var tokens_ = __webpack_require__(8380);
|
|
6395
6401
|
// EXTERNAL MODULE: ./src/lib/viewers/controls/settings/SettingsRadioItem.tsx + 1 modules
|
|
6396
6402
|
var SettingsRadioItem = __webpack_require__(8394);
|
|
6397
|
-
|
|
6398
|
-
|
|
6399
|
-
|
|
6400
|
-
// An open tooltip sits above the menu in the dismiss stack, so it would cover the menu and take its first Escape.
|
|
6401
|
-
function MenuTriggerTooltipV2({
|
|
6402
|
-
children,
|
|
6403
|
-
content,
|
|
6404
|
-
isMenuOpen
|
|
6405
|
-
}) {
|
|
6406
|
-
const [isOpen, setIsOpen] = external_react_["default"].useState(false);
|
|
6407
|
-
return /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Tooltip, {
|
|
6408
|
-
content: content,
|
|
6409
|
-
onOpenChange: setIsOpen,
|
|
6410
|
-
open: isOpen && !isMenuOpen
|
|
6411
|
-
}, children);
|
|
6412
|
-
}
|
|
6403
|
+
// EXTERNAL MODULE: ./src/lib/viewers/controls/tooltip/MenuTriggerTooltipV2.tsx
|
|
6404
|
+
var MenuTriggerTooltipV2 = __webpack_require__(6014);
|
|
6413
6405
|
;// ./src/lib/viewers/controls/settings/SettingsToggleV2.scss
|
|
6414
6406
|
// extracted by mini-css-extract-plugin
|
|
6415
6407
|
|
|
@@ -6442,7 +6434,7 @@ function SettingsToggleV2(props, ref) {
|
|
|
6442
6434
|
// IconButton renders only its icon, so the badge sits beside the button in a positioned wrapper.
|
|
6443
6435
|
return /*#__PURE__*/external_react_["default"].createElement("span", {
|
|
6444
6436
|
className: "bp-SettingsToggleV2"
|
|
6445
|
-
}, /*#__PURE__*/external_react_["default"].createElement(MenuTriggerTooltipV2, {
|
|
6437
|
+
}, /*#__PURE__*/external_react_["default"].createElement(MenuTriggerTooltipV2/* default */.A, {
|
|
6446
6438
|
content: label,
|
|
6447
6439
|
isMenuOpen: isMenuOpen
|
|
6448
6440
|
}, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.IconButton, _extends({
|
|
@@ -6460,7 +6452,7 @@ function SettingsToggleV2(props, ref) {
|
|
|
6460
6452
|
label
|
|
6461
6453
|
} = props,
|
|
6462
6454
|
rest = _objectWithoutProperties(props, _excluded2);
|
|
6463
|
-
return /*#__PURE__*/external_react_["default"].createElement(MenuTriggerTooltipV2, {
|
|
6455
|
+
return /*#__PURE__*/external_react_["default"].createElement(MenuTriggerTooltipV2/* default */.A, {
|
|
6464
6456
|
content: label,
|
|
6465
6457
|
isMenuOpen: isMenuOpen
|
|
6466
6458
|
}, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Toolbar.Button, _extends({
|
|
@@ -6476,20 +6468,8 @@ function SettingsToggleV2(props, ref) {
|
|
|
6476
6468
|
}, badge))));
|
|
6477
6469
|
}
|
|
6478
6470
|
/* harmony default export */ const settings_SettingsToggleV2 = (/*#__PURE__*/external_react_["default"].forwardRef(SettingsToggleV2));
|
|
6479
|
-
|
|
6480
|
-
|
|
6481
|
-
// (e.g. preview-client's HotkeyLayer on window). Escape must still reach Radix's document listener to close the menu.
|
|
6482
|
-
function stopKeyPropagation(event) {
|
|
6483
|
-
if (event.key !== 'Escape') {
|
|
6484
|
-
event.stopPropagation();
|
|
6485
|
-
}
|
|
6486
|
-
}
|
|
6487
|
-
|
|
6488
|
-
// For a Radix layer's onEscapeKeyDown, which runs on document after the layer has closed, so the host's Escape
|
|
6489
|
-
// hotkey doesn't close the whole preview too.
|
|
6490
|
-
function stopEscapePropagation(event) {
|
|
6491
|
-
event.stopPropagation();
|
|
6492
|
-
}
|
|
6471
|
+
// EXTERNAL MODULE: ./src/lib/viewers/controls/settings/stopMenuKeyPropagation.ts
|
|
6472
|
+
var stopMenuKeyPropagation = __webpack_require__(9646);
|
|
6493
6473
|
// EXTERNAL MODULE: ./src/lib/viewers/controls/media/MediaSettingsAudioTracks.tsx
|
|
6494
6474
|
var MediaSettingsAudioTracks = __webpack_require__(9306);
|
|
6495
6475
|
// EXTERNAL MODULE: ./src/lib/viewers/controls/media/MediaSettingsMenuGuides.tsx
|
|
@@ -6662,10 +6642,10 @@ function MediaSettingsV2({
|
|
|
6662
6642
|
event.preventDefault();
|
|
6663
6643
|
closeSubMenu();
|
|
6664
6644
|
}
|
|
6665
|
-
stopKeyPropagation(event);
|
|
6645
|
+
(0,stopMenuKeyPropagation/* stopKeyPropagation */.a)(event);
|
|
6666
6646
|
};
|
|
6667
6647
|
const handleEscapeKeyDown = event => {
|
|
6668
|
-
stopEscapePropagation(event);
|
|
6648
|
+
(0,stopMenuKeyPropagation/* stopEscapePropagation */.s)(event);
|
|
6669
6649
|
if (activeSubMenu) {
|
|
6670
6650
|
event.preventDefault();
|
|
6671
6651
|
closeSubMenu();
|
|
@@ -9093,6 +9073,29 @@ function SettingsRadioItem(props, ref) {
|
|
|
9093
9073
|
|
|
9094
9074
|
/***/ },
|
|
9095
9075
|
|
|
9076
|
+
/***/ 9646
|
|
9077
|
+
(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
9078
|
+
|
|
9079
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
9080
|
+
/* harmony export */ a: () => (/* binding */ stopKeyPropagation),
|
|
9081
|
+
/* harmony export */ s: () => (/* binding */ stopEscapePropagation)
|
|
9082
|
+
/* harmony export */ });
|
|
9083
|
+
// For a menu's onKeyDown, so its keys don't reach preview's file navigation on document or the host's hotkeys
|
|
9084
|
+
// (e.g. preview-client's HotkeyLayer on window). Escape must still reach Radix's document listener to close the menu.
|
|
9085
|
+
function stopKeyPropagation(event) {
|
|
9086
|
+
if (event.key !== 'Escape') {
|
|
9087
|
+
event.stopPropagation();
|
|
9088
|
+
}
|
|
9089
|
+
}
|
|
9090
|
+
|
|
9091
|
+
// For a Radix layer's onEscapeKeyDown, which runs on document after the layer has closed, so the host's Escape
|
|
9092
|
+
// hotkey doesn't close the whole preview too.
|
|
9093
|
+
function stopEscapePropagation(event) {
|
|
9094
|
+
event.stopPropagation();
|
|
9095
|
+
}
|
|
9096
|
+
|
|
9097
|
+
/***/ },
|
|
9098
|
+
|
|
9096
9099
|
/***/ 4937
|
|
9097
9100
|
(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
9098
9101
|
|
|
@@ -9275,6 +9278,32 @@ function SliderControl(_ref) {
|
|
|
9275
9278
|
|
|
9276
9279
|
/***/ },
|
|
9277
9280
|
|
|
9281
|
+
/***/ 6014
|
|
9282
|
+
(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
9283
|
+
|
|
9284
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
9285
|
+
/* harmony export */ A: () => (/* binding */ MenuTriggerTooltipV2)
|
|
9286
|
+
/* harmony export */ });
|
|
9287
|
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1649);
|
|
9288
|
+
/* harmony import */ var _box_blueprint_web__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8912);
|
|
9289
|
+
|
|
9290
|
+
|
|
9291
|
+
// An open tooltip sits above the menu in the dismiss stack, so it would cover the menu and take its first Escape.
|
|
9292
|
+
function MenuTriggerTooltipV2({
|
|
9293
|
+
children,
|
|
9294
|
+
content,
|
|
9295
|
+
isMenuOpen
|
|
9296
|
+
}) {
|
|
9297
|
+
const [isOpen, setIsOpen] = react__WEBPACK_IMPORTED_MODULE_0__["default"].useState(false);
|
|
9298
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__["default"].createElement(_box_blueprint_web__WEBPACK_IMPORTED_MODULE_1__.Tooltip, {
|
|
9299
|
+
content: content,
|
|
9300
|
+
onOpenChange: setIsOpen,
|
|
9301
|
+
open: isOpen && !isMenuOpen
|
|
9302
|
+
}, children);
|
|
9303
|
+
}
|
|
9304
|
+
|
|
9305
|
+
/***/ },
|
|
9306
|
+
|
|
9278
9307
|
/***/ 9974
|
|
9279
9308
|
(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
9280
9309
|
|
|
@@ -9309,8 +9338,8 @@ var blueprint_web_ = __webpack_require__(8912);
|
|
|
9309
9338
|
var MediaLoadingIndicator = __webpack_require__(4301);
|
|
9310
9339
|
// EXTERNAL MODULE: ./src/lib/viewers/controls/media/MediaSettings.tsx + 2 modules
|
|
9311
9340
|
var MediaSettings = __webpack_require__(112);
|
|
9312
|
-
// EXTERNAL MODULE: ./src/lib/viewers/controls/media/MediaSettingsV2.tsx +
|
|
9313
|
-
var MediaSettingsV2 = __webpack_require__(
|
|
9341
|
+
// EXTERNAL MODULE: ./src/lib/viewers/controls/media/MediaSettingsV2.tsx + 3 modules
|
|
9342
|
+
var MediaSettingsV2 = __webpack_require__(3519);
|
|
9314
9343
|
// EXTERNAL MODULE: ./src/lib/viewers/controls/media/PlayOverlayIcon.tsx
|
|
9315
9344
|
var PlayOverlayIcon = __webpack_require__(2048);
|
|
9316
9345
|
// EXTERNAL MODULE: ./src/lib/viewers/controls/media/PlayPauseToggle.tsx + 1 modules
|
|
@@ -37204,7 +37233,7 @@ var isNpmBuild = __webpack_require__(8080);
|
|
|
37204
37233
|
;// ./src/lib/Logger.js
|
|
37205
37234
|
/* eslint-disable no-undef */
|
|
37206
37235
|
const CLIENT_NAME = "box-content-preview";
|
|
37207
|
-
const CLIENT_VERSION = "3.
|
|
37236
|
+
const CLIENT_VERSION = "3.121.0";
|
|
37208
37237
|
/* eslint-enable no-undef */
|
|
37209
37238
|
|
|
37210
37239
|
class Logger {
|
|
@@ -38837,7 +38866,13 @@ class BaseViewer extends (events_default()) {
|
|
|
38837
38866
|
* @return {void}
|
|
38838
38867
|
*/
|
|
38839
38868
|
toggleFullscreen(isFullscreen, fullscreenToggleEl) {
|
|
38840
|
-
|
|
38869
|
+
// The keyboard shortcut has no button to return focus to, so keep the last toggle unless it has
|
|
38870
|
+
// since unmounted, as when it collapses into or out of the overflow menu
|
|
38871
|
+
if (fullscreenToggleEl) {
|
|
38872
|
+
this.fullscreenToggleEl = fullscreenToggleEl;
|
|
38873
|
+
} else if (this.fullscreenToggleEl && !this.fullscreenToggleEl.isConnected) {
|
|
38874
|
+
this.fullscreenToggleEl = null;
|
|
38875
|
+
}
|
|
38841
38876
|
lib_Fullscreen.toggle(this.containerEl);
|
|
38842
38877
|
}
|
|
38843
38878
|
|
|
@@ -38987,7 +39022,7 @@ class BaseViewer extends (events_default()) {
|
|
|
38987
39022
|
* @return {void}
|
|
38988
39023
|
*/
|
|
38989
39024
|
emitFirstRenderMetric() {
|
|
38990
|
-
if (this.firstRenderEmitted) {
|
|
39025
|
+
if (this.isDestroyed() || this.firstRenderEmitted) {
|
|
38991
39026
|
return;
|
|
38992
39027
|
}
|
|
38993
39028
|
const {
|
|
@@ -39806,6 +39841,7 @@ class ArchiveViewer extends viewers_BaseViewer {
|
|
|
39806
39841
|
* @return {void}
|
|
39807
39842
|
*/
|
|
39808
39843
|
finishRender() {
|
|
39844
|
+
this.emitFirstRenderMetric();
|
|
39809
39845
|
this.loaded = true;
|
|
39810
39846
|
this.emit(lib_events/* VIEWER_EVENT */.Oi.load);
|
|
39811
39847
|
}
|
|
@@ -41493,7 +41529,7 @@ class ImageViewer extends image_ImageBaseViewer {
|
|
|
41493
41529
|
* @return {void}
|
|
41494
41530
|
*/
|
|
41495
41531
|
emitFirstRenderMetric() {
|
|
41496
|
-
if (this.firstRenderEmitted) {
|
|
41532
|
+
if (this.isDestroyed() || this.firstRenderEmitted) {
|
|
41497
41533
|
return;
|
|
41498
41534
|
}
|
|
41499
41535
|
const {
|
|
@@ -45220,25 +45256,45 @@ function TextControls({
|
|
|
45220
45256
|
|
|
45221
45257
|
|
|
45222
45258
|
|
|
45223
|
-
function
|
|
45259
|
+
function getZoomState({
|
|
45224
45260
|
maxScale = MAX_SCALE,
|
|
45225
45261
|
minScale = MIN_SCALE,
|
|
45226
|
-
onZoomIn,
|
|
45227
|
-
onZoomOut,
|
|
45228
|
-
resinTargetZoomIn = 'zoomIn',
|
|
45229
|
-
resinTargetZoomOut = 'zoomOut',
|
|
45230
45262
|
scale = 1
|
|
45231
45263
|
}) {
|
|
45232
45264
|
const currentScale = Math.round((scale + Number.EPSILON) * 100) / 100;
|
|
45233
45265
|
const maxScaleValue = isFinite_default()(maxScale) ? Math.min(maxScale, MAX_SCALE) : MAX_SCALE;
|
|
45234
45266
|
const minScaleValue = isFinite_default()(minScale) ? Math.max(minScale, MIN_SCALE) : MIN_SCALE;
|
|
45267
|
+
return {
|
|
45268
|
+
canZoomIn: currentScale < maxScaleValue,
|
|
45269
|
+
canZoomOut: currentScale > minScaleValue,
|
|
45270
|
+
currentScale
|
|
45271
|
+
};
|
|
45272
|
+
}
|
|
45273
|
+
function ZoomControlsV2({
|
|
45274
|
+
maxScale,
|
|
45275
|
+
minScale,
|
|
45276
|
+
onZoomIn,
|
|
45277
|
+
onZoomOut,
|
|
45278
|
+
resinTargetZoomIn = 'zoomIn',
|
|
45279
|
+
resinTargetZoomOut = 'zoomOut',
|
|
45280
|
+
scale
|
|
45281
|
+
}) {
|
|
45282
|
+
const {
|
|
45283
|
+
canZoomIn,
|
|
45284
|
+
canZoomOut,
|
|
45285
|
+
currentScale
|
|
45286
|
+
} = getZoomState({
|
|
45287
|
+
maxScale,
|
|
45288
|
+
minScale,
|
|
45289
|
+
scale
|
|
45290
|
+
});
|
|
45235
45291
|
return /*#__PURE__*/external_react_["default"].createElement(external_react_["default"].Fragment, null, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Tooltip, {
|
|
45236
45292
|
content: ZoomControlsV2_('zoom_out')
|
|
45237
45293
|
}, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Toolbar.Button, {
|
|
45238
45294
|
"aria-label": ZoomControlsV2_('zoom_out'),
|
|
45239
45295
|
"data-resin-target": resinTargetZoomOut,
|
|
45240
45296
|
"data-testid": "bp-ZoomControls-out",
|
|
45241
|
-
disabled:
|
|
45297
|
+
disabled: !canZoomOut,
|
|
45242
45298
|
onClick: onZoomOut
|
|
45243
45299
|
}, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Toolbar.Icon, {
|
|
45244
45300
|
icon: __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Minus_cc9df143_default__
|
|
@@ -45254,7 +45310,7 @@ function ZoomControlsV2({
|
|
|
45254
45310
|
"aria-label": ZoomControlsV2_('zoom_in'),
|
|
45255
45311
|
"data-resin-target": resinTargetZoomIn,
|
|
45256
45312
|
"data-testid": "bp-ZoomControls-in",
|
|
45257
|
-
disabled:
|
|
45313
|
+
disabled: !canZoomIn,
|
|
45258
45314
|
onClick: onZoomIn
|
|
45259
45315
|
}, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Toolbar.Icon, {
|
|
45260
45316
|
icon: __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Plus_aaa7b14f_default__
|
|
@@ -53674,8 +53730,8 @@ function VideoControls({
|
|
|
53674
53730
|
onFullscreenToggle: onFullscreenToggle
|
|
53675
53731
|
})))));
|
|
53676
53732
|
}
|
|
53677
|
-
// EXTERNAL MODULE: ./src/lib/viewers/controls/media/MediaSettingsV2.tsx +
|
|
53678
|
-
var MediaSettingsV2 = __webpack_require__(
|
|
53733
|
+
// EXTERNAL MODULE: ./src/lib/viewers/controls/media/MediaSettingsV2.tsx + 3 modules
|
|
53734
|
+
var MediaSettingsV2 = __webpack_require__(3519);
|
|
53679
53735
|
// EXTERNAL MODULE: ./src/lib/viewers/controls/media/PlayPauseButton.tsx + 2 modules
|
|
53680
53736
|
var PlayPauseButton = __webpack_require__(5760);
|
|
53681
53737
|
// EXTERNAL MODULE: ./src/lib/viewers/controls/media/SkipButton.tsx + 2 modules
|
|
@@ -56634,6 +56690,8 @@ class Video360Loader extends box3d_Base360Loader {
|
|
|
56634
56690
|
}
|
|
56635
56691
|
}
|
|
56636
56692
|
/* harmony default export */ const video360_Video360Loader = (new Video360Loader());
|
|
56693
|
+
// EXTERNAL MODULE: external "react-dom"
|
|
56694
|
+
var external_react_dom_ = __webpack_require__(7516);
|
|
56637
56695
|
;// ./src/lib/viewers/controls/icons/IconSearchMedium24.tsx
|
|
56638
56696
|
function IconSearchMedium24_extends() { return IconSearchMedium24_extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, IconSearchMedium24_extends.apply(null, arguments); }
|
|
56639
56697
|
|
|
@@ -56867,6 +56925,14 @@ function DocControls({
|
|
|
56867
56925
|
onAnnotationColorChange: onAnnotationColorChange
|
|
56868
56926
|
})));
|
|
56869
56927
|
}
|
|
56928
|
+
;// external "@box/blueprint-web-assets/icons/Medium/GridView"
|
|
56929
|
+
|
|
56930
|
+
;// external "@box/blueprint-web-assets/icons/Medium/Nav"
|
|
56931
|
+
|
|
56932
|
+
;// external "@box/blueprint-web-assets/icons/Medium/RotateLeft"
|
|
56933
|
+
|
|
56934
|
+
;// external "@box/blueprint-web-assets/icons/Medium/Search"
|
|
56935
|
+
|
|
56870
56936
|
;// external "@box/blueprint-web-assets/icons/Medium/XMark"
|
|
56871
56937
|
|
|
56872
56938
|
;// ./src/lib/viewers/controls/annotations/AnnotationsExitButtonV2.scss
|
|
@@ -57119,8 +57185,350 @@ function ColorPickerControlV2({
|
|
|
57119
57185
|
onClick: () => onColorSelect(color)
|
|
57120
57186
|
}))));
|
|
57121
57187
|
}
|
|
57122
|
-
;//
|
|
57188
|
+
;// ./src/lib/viewers/controls/controls-bar/useControlsOverflow.ts
|
|
57189
|
+
|
|
57190
|
+
|
|
57191
|
+
|
|
57192
|
+
const ALWAYS_OVERFLOW = 0;
|
|
57193
|
+
// The space the mocks leave between the bar and the edges of the viewer
|
|
57194
|
+
const EDGE_MARGIN = 40;
|
|
57195
|
+
// One toolbar button, the estimate for a control or the overflow trigger before it has been measured
|
|
57196
|
+
const DEFAULT_WIDTH = 32;
|
|
57197
|
+
const isCollapsible = ({
|
|
57198
|
+
menu,
|
|
57199
|
+
priority
|
|
57200
|
+
}) => !!menu && priority !== undefined;
|
|
57201
|
+
function getOverflowIds(items, availableWidth, metrics) {
|
|
57202
|
+
const {
|
|
57203
|
+
chrome,
|
|
57204
|
+
gap,
|
|
57205
|
+
triggerWidth = DEFAULT_WIDTH,
|
|
57206
|
+
widths
|
|
57207
|
+
} = metrics;
|
|
57208
|
+
const overflowIds = new Set(items.filter(item => isCollapsible(item) && item.priority === ALWAYS_OVERFLOW).map(({
|
|
57209
|
+
id
|
|
57210
|
+
}) => id));
|
|
57211
|
+
const getBarWidth = () => {
|
|
57212
|
+
const slots = items.filter(({
|
|
57213
|
+
id
|
|
57214
|
+
}) => !overflowIds.has(id)).map(({
|
|
57215
|
+
id
|
|
57216
|
+
}) => widths.get(id) ?? DEFAULT_WIDTH);
|
|
57217
|
+
if (overflowIds.size) {
|
|
57218
|
+
slots.push(triggerWidth);
|
|
57219
|
+
}
|
|
57220
|
+
return chrome + slots.reduce((total, width) => total + width, 0) + gap * Math.max(slots.length - 1, 0);
|
|
57221
|
+
};
|
|
57222
|
+
const priorities = items.filter(item => isCollapsible(item) && item.priority !== ALWAYS_OVERFLOW).map(({
|
|
57223
|
+
priority
|
|
57224
|
+
}) => priority).sort((a, b) => a - b);
|
|
57225
|
+
Array.from(new Set(priorities)).every(priority => {
|
|
57226
|
+
if (getBarWidth() <= availableWidth) {
|
|
57227
|
+
return false;
|
|
57228
|
+
}
|
|
57229
|
+
items.filter(item => isCollapsible(item) && item.priority === priority).forEach(({
|
|
57230
|
+
id
|
|
57231
|
+
}) => overflowIds.add(id));
|
|
57232
|
+
return true;
|
|
57233
|
+
});
|
|
57234
|
+
return overflowIds;
|
|
57235
|
+
}
|
|
57236
|
+
const getStyleWidth = (style, properties) => properties.reduce((total, property) => total + (parseFloat(style.getPropertyValue(property)) || 0), 0);
|
|
57237
|
+
function useControlsOverflow(items) {
|
|
57238
|
+
const barRef = external_react_["default"].useRef(null);
|
|
57239
|
+
const metricsRef = external_react_["default"].useRef({
|
|
57240
|
+
chrome: 0,
|
|
57241
|
+
gap: 0,
|
|
57242
|
+
widths: new Map()
|
|
57243
|
+
});
|
|
57244
|
+
const portalContainer = external_react_["default"].useContext(BlueprintProviders/* PortalContainerContext */.n);
|
|
57245
|
+
const [availableWidth, setAvailableWidth] = external_react_["default"].useState(Number.POSITIVE_INFINITY);
|
|
57246
|
+
const [, forceUpdate] = external_react_["default"].useReducer(count => count + 1, 0);
|
|
57247
|
+
|
|
57248
|
+
// A control can only be measured while it is on the bar, so each width is cached as it renders and
|
|
57249
|
+
// reused to decide whether that control would fit again
|
|
57250
|
+
external_react_["default"].useLayoutEffect(() => {
|
|
57251
|
+
const bar = barRef.current;
|
|
57252
|
+
if (!bar) {
|
|
57253
|
+
return;
|
|
57254
|
+
}
|
|
57255
|
+
const metrics = metricsRef.current;
|
|
57256
|
+
const style = window.getComputedStyle(bar);
|
|
57257
|
+
const chrome = getStyleWidth(style, ['padding-left', 'padding-right', 'border-left-width', 'border-right-width']);
|
|
57258
|
+
const gap = getStyleWidth(style, ['column-gap']);
|
|
57259
|
+
let hasChanged = chrome !== metrics.chrome || gap !== metrics.gap;
|
|
57260
|
+
metrics.chrome = chrome;
|
|
57261
|
+
metrics.gap = gap;
|
|
57262
|
+
Array.from(bar.children).forEach(child => {
|
|
57263
|
+
const {
|
|
57264
|
+
offsetWidth
|
|
57265
|
+
} = child;
|
|
57266
|
+
const {
|
|
57267
|
+
overflowId,
|
|
57268
|
+
overflowTrigger
|
|
57269
|
+
} = child.dataset;
|
|
57270
|
+
if (!offsetWidth) {
|
|
57271
|
+
return;
|
|
57272
|
+
}
|
|
57273
|
+
if (overflowId && metrics.widths.get(overflowId) !== offsetWidth) {
|
|
57274
|
+
metrics.widths.set(overflowId, offsetWidth);
|
|
57275
|
+
hasChanged = true;
|
|
57276
|
+
}
|
|
57277
|
+
if (overflowTrigger !== undefined && metrics.triggerWidth !== offsetWidth) {
|
|
57278
|
+
metrics.triggerWidth = offsetWidth;
|
|
57279
|
+
hasChanged = true;
|
|
57280
|
+
}
|
|
57281
|
+
});
|
|
57282
|
+
if (hasChanged) {
|
|
57283
|
+
forceUpdate();
|
|
57284
|
+
}
|
|
57285
|
+
});
|
|
57286
|
+
|
|
57287
|
+
// The bar renders nothing without items, so the viewer lookup reruns once it mounts
|
|
57288
|
+
const hasItems = items.length > 0;
|
|
57289
|
+
|
|
57290
|
+
// The controls root is centered and shrinks to fit the bar, so the space the bar can grow into is the
|
|
57291
|
+
// viewer's. Fullscreen resizes the viewer too, which the observer picks up.
|
|
57292
|
+
external_react_["default"].useLayoutEffect(() => {
|
|
57293
|
+
const container = portalContainer ?? barRef.current?.closest(`.${constants/* CLASS_BOX_PREVIEW_CONTENT */.SG}`) ?? null;
|
|
57294
|
+
if (!container) {
|
|
57295
|
+
return undefined;
|
|
57296
|
+
}
|
|
57297
|
+
const updateAvailableWidth = () => {
|
|
57298
|
+
const {
|
|
57299
|
+
clientWidth
|
|
57300
|
+
} = container;
|
|
57301
|
+
|
|
57302
|
+
// A container that has not been laid out yet measures zero, which would collapse everything
|
|
57303
|
+
setAvailableWidth(clientWidth > 0 ? clientWidth - EDGE_MARGIN : Number.POSITIVE_INFINITY);
|
|
57304
|
+
};
|
|
57305
|
+
updateAvailableWidth();
|
|
57306
|
+
if (typeof ResizeObserver === 'undefined') {
|
|
57307
|
+
return undefined;
|
|
57308
|
+
}
|
|
57309
|
+
const observer = new ResizeObserver(updateAvailableWidth);
|
|
57310
|
+
observer.observe(container);
|
|
57311
|
+
return () => observer.disconnect();
|
|
57312
|
+
}, [hasItems, portalContainer]);
|
|
57313
|
+
const overflowIds = getOverflowIds(items, availableWidth, metricsRef.current);
|
|
57314
|
+
return {
|
|
57315
|
+
barRef,
|
|
57316
|
+
overflowItems: items.filter(({
|
|
57317
|
+
id
|
|
57318
|
+
}) => overflowIds.has(id)),
|
|
57319
|
+
visibleItems: items.filter(({
|
|
57320
|
+
id
|
|
57321
|
+
}) => !overflowIds.has(id))
|
|
57322
|
+
};
|
|
57323
|
+
}
|
|
57324
|
+
;// external "@box/blueprint-web-assets/icons/Medium/EllipsisVertical"
|
|
57325
|
+
|
|
57326
|
+
// EXTERNAL MODULE: ./src/lib/viewers/controls/tooltip/MenuTriggerTooltipV2.tsx
|
|
57327
|
+
var MenuTriggerTooltipV2 = __webpack_require__(6014);
|
|
57328
|
+
// EXTERNAL MODULE: ./src/lib/viewers/controls/settings/stopMenuKeyPropagation.ts
|
|
57329
|
+
var stopMenuKeyPropagation = __webpack_require__(9646);
|
|
57330
|
+
;// ./src/lib/viewers/controls/controls-bar/ControlsOverflowMenuV2.scss
|
|
57331
|
+
// extracted by mini-css-extract-plugin
|
|
57332
|
+
|
|
57333
|
+
;// ./src/lib/viewers/controls/controls-bar/ControlsOverflowMenuV2.tsx
|
|
57334
|
+
/* provided dependency */ var ControlsOverflowMenuV2_ = __webpack_require__(441)["Tl"];
|
|
57335
|
+
function ControlsOverflowMenuV2_extends() { return ControlsOverflowMenuV2_extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, ControlsOverflowMenuV2_extends.apply(null, arguments); }
|
|
57336
|
+
|
|
57337
|
+
|
|
57338
|
+
|
|
57339
|
+
|
|
57340
|
+
|
|
57341
|
+
|
|
57342
|
+
|
|
57343
|
+
|
|
57344
|
+
// Handlers that return focus to the control that invoked them get the trigger, since the row unmounts with the menu
|
|
57345
|
+
const ControlsOverflowTriggerContext = /*#__PURE__*/external_react_["default"].createContext({
|
|
57346
|
+
current: null
|
|
57347
|
+
});
|
|
57123
57348
|
|
|
57349
|
+
// The menu portals out of the controls root, so it carries the root's Resin attributes itself
|
|
57350
|
+
const getResinAttributes = element => {
|
|
57351
|
+
const resinComponent = element?.closest('[data-resin-component]');
|
|
57352
|
+
return resinComponent ? Object.fromEntries(Array.from(resinComponent.attributes).filter(({
|
|
57353
|
+
name
|
|
57354
|
+
}) => name.startsWith('data-resin-')).map(({
|
|
57355
|
+
name,
|
|
57356
|
+
value
|
|
57357
|
+
}) => [name, value])) : {};
|
|
57358
|
+
};
|
|
57359
|
+
function ControlsOverflowToggle(props, ref) {
|
|
57360
|
+
const isMenuOpen = props['aria-expanded'] === true || props['aria-expanded'] === 'true';
|
|
57361
|
+
return /*#__PURE__*/external_react_["default"].createElement(MenuTriggerTooltipV2/* default */.A, {
|
|
57362
|
+
content: ControlsOverflowMenuV2_('controls_more'),
|
|
57363
|
+
isMenuOpen: isMenuOpen
|
|
57364
|
+
}, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Toolbar.Button, ControlsOverflowMenuV2_extends({
|
|
57365
|
+
ref: ref,
|
|
57366
|
+
"aria-label": ControlsOverflowMenuV2_('controls_more'),
|
|
57367
|
+
"data-resin-target": "moreOptions",
|
|
57368
|
+
"data-testid": "bp-ControlsBar-overflowBtn"
|
|
57369
|
+
}, props), /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Toolbar.Icon, {
|
|
57370
|
+
icon: __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_EllipsisVertical_06d33c4b_default__
|
|
57371
|
+
})));
|
|
57372
|
+
}
|
|
57373
|
+
const ControlsOverflowToggleV2 = /*#__PURE__*/external_react_["default"].forwardRef(ControlsOverflowToggle);
|
|
57374
|
+
function ControlsOverflowMenuV2({
|
|
57375
|
+
items
|
|
57376
|
+
}) {
|
|
57377
|
+
const container = external_react_["default"].useContext(BlueprintProviders/* PortalContainerContext */.n) ?? undefined;
|
|
57378
|
+
const {
|
|
57379
|
+
setIsForced
|
|
57380
|
+
} = external_react_["default"].useContext(ControlsLayerContext);
|
|
57381
|
+
const triggerRef = external_react_["default"].useRef(null);
|
|
57382
|
+
const [isOpen, setIsOpen] = external_react_["default"].useState(false);
|
|
57383
|
+
const [resinAttributes, setResinAttributes] = external_react_["default"].useState({});
|
|
57384
|
+
const handleOpenChange = open => {
|
|
57385
|
+
if (open) {
|
|
57386
|
+
setResinAttributes(getResinAttributes(triggerRef.current));
|
|
57387
|
+
}
|
|
57388
|
+
setIsOpen(open);
|
|
57389
|
+
};
|
|
57390
|
+
|
|
57391
|
+
// The menu sits outside the controls layer, which would otherwise hide the bar under the open menu
|
|
57392
|
+
external_react_["default"].useEffect(() => {
|
|
57393
|
+
if (!isOpen) {
|
|
57394
|
+
return undefined;
|
|
57395
|
+
}
|
|
57396
|
+
setIsForced(true);
|
|
57397
|
+
return () => setIsForced(false);
|
|
57398
|
+
}, [isOpen, setIsForced]);
|
|
57399
|
+
return /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Root, {
|
|
57400
|
+
modal: false,
|
|
57401
|
+
onOpenChange: handleOpenChange,
|
|
57402
|
+
open: isOpen
|
|
57403
|
+
}, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Trigger, {
|
|
57404
|
+
ref: triggerRef,
|
|
57405
|
+
asChild: true,
|
|
57406
|
+
"data-overflow-ids": items.map(({
|
|
57407
|
+
id
|
|
57408
|
+
}) => id).join(' '),
|
|
57409
|
+
"data-overflow-trigger": ""
|
|
57410
|
+
}, /*#__PURE__*/external_react_["default"].createElement(ControlsOverflowToggleV2, null)), /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Content, ControlsOverflowMenuV2_extends({
|
|
57411
|
+
align: "end",
|
|
57412
|
+
className: "bp-ControlsOverflowMenuV2",
|
|
57413
|
+
container: container,
|
|
57414
|
+
"data-testid": "bp-ControlsBar-overflowMenu",
|
|
57415
|
+
onEscapeKeyDown: stopMenuKeyPropagation/* stopEscapePropagation */.s,
|
|
57416
|
+
onKeyDown: stopMenuKeyPropagation/* stopKeyPropagation */.a,
|
|
57417
|
+
side: "top"
|
|
57418
|
+
}, resinAttributes), /*#__PURE__*/external_react_["default"].createElement(ControlsOverflowTriggerContext.Provider, {
|
|
57419
|
+
value: triggerRef
|
|
57420
|
+
}, items.map(({
|
|
57421
|
+
id,
|
|
57422
|
+
menu
|
|
57423
|
+
}) => /*#__PURE__*/external_react_["default"].createElement(external_react_["default"].Fragment, {
|
|
57424
|
+
key: id
|
|
57425
|
+
}, menu)))));
|
|
57426
|
+
}
|
|
57427
|
+
;// ./src/lib/viewers/controls/controls-bar/shortcuts.ts
|
|
57428
|
+
/* provided dependency */ var shortcuts_ = __webpack_require__(441)["Tl"];
|
|
57429
|
+
|
|
57430
|
+
// iPads report a Mac user agent, and their keyboards have the command key too
|
|
57431
|
+
const isApplePlatform = () => /Mac|iPhone|iPad|iPod/.test(navigator.userAgent);
|
|
57432
|
+
|
|
57433
|
+
// Preview binds its shortcuts to both Cmd and Ctrl, so each platform is shown the modifier its keyboard labels
|
|
57434
|
+
function getShortcut(key) {
|
|
57435
|
+
return isApplePlatform() ? {
|
|
57436
|
+
keys: `Meta+${key}`,
|
|
57437
|
+
label: `⌘ + ${key}`
|
|
57438
|
+
} : {
|
|
57439
|
+
keys: `Control+${key}`,
|
|
57440
|
+
label: (0,util/* replacePlaceholders */.Lb)(shortcuts_('controls_shortcut_ctrl'), [key])
|
|
57441
|
+
};
|
|
57442
|
+
}
|
|
57443
|
+
;// ./src/lib/viewers/controls/controls-bar/ControlsMenuItemV2.scss
|
|
57444
|
+
// extracted by mini-css-extract-plugin
|
|
57445
|
+
|
|
57446
|
+
;// ./src/lib/viewers/controls/controls-bar/ControlsMenuItemV2.tsx
|
|
57447
|
+
const ControlsMenuItemV2_excluded = ["bareKey", "icon", "keepOpen", "label", "onSelect", "shortcutKey"];
|
|
57448
|
+
function ControlsMenuItemV2_extends() { return ControlsMenuItemV2_extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, ControlsMenuItemV2_extends.apply(null, arguments); }
|
|
57449
|
+
function ControlsMenuItemV2_objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = ControlsMenuItemV2_objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var n = Object.getOwnPropertySymbols(e); for (r = 0; r < n.length; r++) o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } return i; }
|
|
57450
|
+
function ControlsMenuItemV2_objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } return t; }
|
|
57451
|
+
|
|
57452
|
+
|
|
57453
|
+
|
|
57454
|
+
|
|
57455
|
+
|
|
57456
|
+
// The menu form of a bar control. Toggles are plain rows whose label names the next action, since checkbox
|
|
57457
|
+
// rows reserve space for a checkmark that the mocks do not have.
|
|
57458
|
+
function ControlsMenuItemV2(_ref) {
|
|
57459
|
+
let {
|
|
57460
|
+
bareKey,
|
|
57461
|
+
icon,
|
|
57462
|
+
keepOpen,
|
|
57463
|
+
label,
|
|
57464
|
+
onSelect,
|
|
57465
|
+
shortcutKey
|
|
57466
|
+
} = _ref,
|
|
57467
|
+
rest = ControlsMenuItemV2_objectWithoutProperties(_ref, ControlsMenuItemV2_excluded);
|
|
57468
|
+
const triggerRef = external_react_["default"].useContext(ControlsOverflowTriggerContext);
|
|
57469
|
+
let shortcut = null;
|
|
57470
|
+
if (shortcutKey) {
|
|
57471
|
+
shortcut = getShortcut(shortcutKey);
|
|
57472
|
+
} else if (bareKey) {
|
|
57473
|
+
shortcut = {
|
|
57474
|
+
keys: bareKey,
|
|
57475
|
+
label: bareKey
|
|
57476
|
+
};
|
|
57477
|
+
}
|
|
57478
|
+
const handleSelect = event => {
|
|
57479
|
+
if (keepOpen) {
|
|
57480
|
+
event.preventDefault();
|
|
57481
|
+
}
|
|
57482
|
+
onSelect(triggerRef.current);
|
|
57483
|
+
};
|
|
57484
|
+
return /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Item, ControlsMenuItemV2_extends({
|
|
57485
|
+
"aria-keyshortcuts": shortcut?.keys,
|
|
57486
|
+
onSelect: handleSelect
|
|
57487
|
+
}, rest, {
|
|
57488
|
+
className: "bp-ControlsMenuItemV2"
|
|
57489
|
+
}), /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Item.StartElement, {
|
|
57490
|
+
icon: icon
|
|
57491
|
+
}), /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Item.MainContent, {
|
|
57492
|
+
label: label
|
|
57493
|
+
}), shortcut && /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Item.EndElement, {
|
|
57494
|
+
"aria-hidden": true
|
|
57495
|
+
}, shortcut.label));
|
|
57496
|
+
}
|
|
57497
|
+
;// ./src/lib/viewers/controls/controls-bar/ResponsiveControlsBarV2.scss
|
|
57498
|
+
// extracted by mini-css-extract-plugin
|
|
57499
|
+
|
|
57500
|
+
;// ./src/lib/viewers/controls/controls-bar/ResponsiveControlsBarV2.tsx
|
|
57501
|
+
|
|
57502
|
+
|
|
57503
|
+
|
|
57504
|
+
|
|
57505
|
+
|
|
57506
|
+
// Moves controls into an overflow menu as the viewer narrows. Bars that always show everything, like the
|
|
57507
|
+
// annotations palette, use ControlsBarV2 directly.
|
|
57508
|
+
function ResponsiveControlsBarV2({
|
|
57509
|
+
items
|
|
57510
|
+
}) {
|
|
57511
|
+
const {
|
|
57512
|
+
barRef,
|
|
57513
|
+
overflowItems,
|
|
57514
|
+
visibleItems
|
|
57515
|
+
} = useControlsOverflow(items);
|
|
57516
|
+
if (!items.length) {
|
|
57517
|
+
return null;
|
|
57518
|
+
}
|
|
57519
|
+
return /*#__PURE__*/external_react_["default"].createElement(controls_bar_ControlsBarV2, {
|
|
57520
|
+
ref: barRef
|
|
57521
|
+
}, visibleItems.map(({
|
|
57522
|
+
control,
|
|
57523
|
+
id
|
|
57524
|
+
}) => /*#__PURE__*/external_react_["default"].createElement("div", {
|
|
57525
|
+
key: id,
|
|
57526
|
+
className: "bp-ResponsiveControlsBarV2-item",
|
|
57527
|
+
"data-overflow-id": id
|
|
57528
|
+
}, control)), overflowItems.length > 0 && /*#__PURE__*/external_react_["default"].createElement(ControlsOverflowMenuV2, {
|
|
57529
|
+
items: overflowItems
|
|
57530
|
+
}));
|
|
57531
|
+
}
|
|
57124
57532
|
;// ./src/lib/viewers/controls/findbar/FindBarToggleV2.tsx
|
|
57125
57533
|
/* provided dependency */ var FindBarToggleV2_ = __webpack_require__(441)["Tl"];
|
|
57126
57534
|
|
|
@@ -57144,8 +57552,6 @@ function FindBarToggleV2({
|
|
|
57144
57552
|
icon: __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Search_ef3e4aba_default__
|
|
57145
57553
|
})));
|
|
57146
57554
|
}
|
|
57147
|
-
;// external "@box/blueprint-web-assets/icons/Medium/GridView"
|
|
57148
|
-
|
|
57149
57555
|
;// ./src/lib/viewers/controls/gallery/GalleryToggleV2.tsx
|
|
57150
57556
|
/* provided dependency */ var GalleryToggleV2_ = __webpack_require__(441)["Tl"];
|
|
57151
57557
|
|
|
@@ -57325,8 +57731,6 @@ function PageControlsV2({
|
|
|
57325
57731
|
icon: __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_ChevronDown_a545a634_default__
|
|
57326
57732
|
}))));
|
|
57327
57733
|
}
|
|
57328
|
-
;// external "@box/blueprint-web-assets/icons/Medium/RotateLeft"
|
|
57329
|
-
|
|
57330
57734
|
;// ./src/lib/viewers/controls/rotate/RotateControlV2.tsx
|
|
57331
57735
|
/* provided dependency */ var RotateControlV2_ = __webpack_require__(441)["Tl"];
|
|
57332
57736
|
|
|
@@ -57345,8 +57749,6 @@ function RotateControlV2({
|
|
|
57345
57749
|
icon: __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_RotateLeft_c726d679_default__
|
|
57346
57750
|
})));
|
|
57347
57751
|
}
|
|
57348
|
-
;// external "@box/blueprint-web-assets/icons/Medium/Nav"
|
|
57349
|
-
|
|
57350
57752
|
;// external "@box/blueprint-web-assets/icons/MediumFilled/Nav"
|
|
57351
57753
|
|
|
57352
57754
|
;// ./src/lib/viewers/controls/sidebar/ThumbnailsToggleV2.scss
|
|
@@ -57383,7 +57785,90 @@ function ThumbnailsToggleV2({
|
|
|
57383
57785
|
value: "thumbnails"
|
|
57384
57786
|
}))));
|
|
57385
57787
|
}
|
|
57788
|
+
;// ./src/lib/viewers/controls/hooks/useMediaQuery.ts
|
|
57789
|
+
|
|
57790
|
+
const getMatches = query => typeof window.matchMedia === 'function' && window.matchMedia(query).matches;
|
|
57791
|
+
function useMediaQuery(query) {
|
|
57792
|
+
const [matches, setMatches] = external_react_["default"].useState(() => getMatches(query));
|
|
57793
|
+
external_react_["default"].useEffect(() => {
|
|
57794
|
+
if (typeof window.matchMedia !== 'function') {
|
|
57795
|
+
return undefined;
|
|
57796
|
+
}
|
|
57797
|
+
const mediaQueryList = window.matchMedia(query);
|
|
57798
|
+
const handleChange = () => setMatches(mediaQueryList.matches);
|
|
57799
|
+
handleChange();
|
|
57800
|
+
mediaQueryList.addEventListener('change', handleChange);
|
|
57801
|
+
return () => mediaQueryList.removeEventListener('change', handleChange);
|
|
57802
|
+
}, [query]);
|
|
57803
|
+
return matches;
|
|
57804
|
+
}
|
|
57805
|
+
;// ./src/lib/viewers/controls/zoom/ZoomMenuItemsV2.scss
|
|
57806
|
+
// extracted by mini-css-extract-plugin
|
|
57807
|
+
|
|
57808
|
+
;// ./src/lib/viewers/controls/zoom/ZoomMenuItemsV2.tsx
|
|
57809
|
+
/* provided dependency */ var ZoomMenuItemsV2_ = __webpack_require__(441)["Tl"];
|
|
57810
|
+
|
|
57811
|
+
|
|
57812
|
+
|
|
57813
|
+
|
|
57814
|
+
|
|
57815
|
+
|
|
57816
|
+
|
|
57817
|
+
|
|
57818
|
+
|
|
57819
|
+
// The overflow menu form of the zoom controls: the current scale, then zoom in and zoom out
|
|
57820
|
+
function ZoomMenuItemsV2({
|
|
57821
|
+
maxScale,
|
|
57822
|
+
minScale,
|
|
57823
|
+
onZoomIn,
|
|
57824
|
+
onZoomOut,
|
|
57825
|
+
resinTargetZoomIn = 'zoomIn',
|
|
57826
|
+
resinTargetZoomOut = 'zoomOut',
|
|
57827
|
+
scale
|
|
57828
|
+
}) {
|
|
57829
|
+
const {
|
|
57830
|
+
canZoomIn,
|
|
57831
|
+
canZoomOut,
|
|
57832
|
+
currentScale
|
|
57833
|
+
} = getZoomState({
|
|
57834
|
+
maxScale,
|
|
57835
|
+
minScale,
|
|
57836
|
+
scale
|
|
57837
|
+
});
|
|
57838
|
+
const scaleLabel = (0,util/* replacePlaceholders */.Lb)(ZoomMenuItemsV2_('controls_zoom_scale'), [`${Math.round(currentScale * 100)}%`]);
|
|
57839
|
+
return /*#__PURE__*/external_react_["default"].createElement(external_react_["default"].Fragment, null, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Text, {
|
|
57840
|
+
as: "div",
|
|
57841
|
+
className: "bp-ZoomMenuItemsV2-scale",
|
|
57842
|
+
color: "textOnLightSecondary",
|
|
57843
|
+
"data-testid": "bp-ZoomMenuItems-scale",
|
|
57844
|
+
variant: "caption"
|
|
57845
|
+
}, scaleLabel), /*#__PURE__*/external_react_["default"].createElement(ControlsMenuItemV2, {
|
|
57846
|
+
"data-resin-target": resinTargetZoomIn,
|
|
57847
|
+
"data-testid": "bp-ZoomControls-in-menuItem",
|
|
57848
|
+
disabled: !canZoomIn,
|
|
57849
|
+
icon: __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Plus_aaa7b14f_default__,
|
|
57850
|
+
keepOpen: true,
|
|
57851
|
+
label: ZoomMenuItemsV2_('zoom_in'),
|
|
57852
|
+
onSelect: () => onZoomIn()
|
|
57853
|
+
}), /*#__PURE__*/external_react_["default"].createElement(ControlsMenuItemV2, {
|
|
57854
|
+
"data-resin-target": resinTargetZoomOut,
|
|
57855
|
+
"data-testid": "bp-ZoomControls-out-menuItem",
|
|
57856
|
+
disabled: !canZoomOut,
|
|
57857
|
+
icon: __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Minus_cc9df143_default__,
|
|
57858
|
+
keepOpen: true,
|
|
57859
|
+
label: ZoomMenuItemsV2_('zoom_out'),
|
|
57860
|
+
onSelect: () => onZoomOut()
|
|
57861
|
+
}), /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Separator, null));
|
|
57862
|
+
}
|
|
57386
57863
|
;// ./src/lib/viewers/doc/DocControlsV2.tsx
|
|
57864
|
+
/* provided dependency */ var DocControlsV2_ = __webpack_require__(441)["Tl"];
|
|
57865
|
+
|
|
57866
|
+
|
|
57867
|
+
|
|
57868
|
+
|
|
57869
|
+
|
|
57870
|
+
|
|
57871
|
+
|
|
57387
57872
|
|
|
57388
57873
|
|
|
57389
57874
|
|
|
@@ -57402,7 +57887,21 @@ function ThumbnailsToggleV2({
|
|
|
57402
57887
|
|
|
57403
57888
|
|
|
57404
57889
|
|
|
57890
|
+
// The thumbnails sidebar only opens at this width (box-ui-elements $size-large-min)
|
|
57891
|
+
const THUMBNAILS_MEDIA_QUERY = '(min-width: 768px)';
|
|
57405
57892
|
|
|
57893
|
+
// From the responsive mocks: find stays in the menu at every width, and gallery does too until the grid is
|
|
57894
|
+
// open. Then the grid toggle is the button itself, and nothing else collapses into a more options menu.
|
|
57895
|
+
// Rotate collapses next, then thumbnails and fullscreen together, then zoom. Page and the markup trigger
|
|
57896
|
+
// have no menu form and never collapse.
|
|
57897
|
+
const PRIORITY = {
|
|
57898
|
+
find: ALWAYS_OVERFLOW,
|
|
57899
|
+
fullscreen: 2,
|
|
57900
|
+
gallery: ALWAYS_OVERFLOW,
|
|
57901
|
+
rotate: 1,
|
|
57902
|
+
thumbnails: 2,
|
|
57903
|
+
zoom: 3
|
|
57904
|
+
};
|
|
57406
57905
|
function DocControlsV2({
|
|
57407
57906
|
annotationColor,
|
|
57408
57907
|
annotationMode = AnnotationMode.NONE,
|
|
@@ -57433,6 +57932,7 @@ function DocControlsV2({
|
|
|
57433
57932
|
}) {
|
|
57434
57933
|
const annotationsToggleRef = external_react_["default"].useRef(null);
|
|
57435
57934
|
const isFullscreen = useFullscreen();
|
|
57935
|
+
const canShowThumbnails = useMediaQuery(THUMBNAILS_MEDIA_QUERY);
|
|
57436
57936
|
|
|
57437
57937
|
// Listed in the palette's button order, which is also the order the toggle falls back to
|
|
57438
57938
|
const annotationModes = [];
|
|
@@ -57454,42 +57954,113 @@ function DocControlsV2({
|
|
|
57454
57954
|
mode: AnnotationMode.NONE
|
|
57455
57955
|
});
|
|
57456
57956
|
};
|
|
57457
|
-
|
|
57458
|
-
|
|
57459
|
-
|
|
57460
|
-
|
|
57461
|
-
|
|
57462
|
-
}), /*#__PURE__*/external_react_["default"].createElement(FindBarToggleV2, {
|
|
57463
|
-
onFindBarToggle: onFindBarToggle
|
|
57464
|
-
}), /*#__PURE__*/external_react_["default"].createElement(PageControlsV2, {
|
|
57465
|
-
onPageChange: onPageChange,
|
|
57466
|
-
onPageSubmit: onPageSubmit,
|
|
57467
|
-
pageCount: pageCount,
|
|
57468
|
-
pageNumber: pageNumber
|
|
57469
|
-
})), (!isGalleryOpen || hasGalleryZoom) && /*#__PURE__*/external_react_["default"].createElement(ZoomControlsV2, {
|
|
57470
|
-
maxScale: maxScale,
|
|
57471
|
-
minScale: minScale,
|
|
57472
|
-
onZoomIn: onZoomIn,
|
|
57473
|
-
onZoomOut: onZoomOut,
|
|
57957
|
+
const zoomProps = {
|
|
57958
|
+
maxScale,
|
|
57959
|
+
minScale,
|
|
57960
|
+
onZoomIn,
|
|
57961
|
+
onZoomOut,
|
|
57474
57962
|
resinTargetZoomIn: isGalleryOpen ? 'galleryZoomIn' : undefined,
|
|
57475
57963
|
resinTargetZoomOut: isGalleryOpen ? 'galleryZoomOut' : undefined,
|
|
57476
|
-
scale
|
|
57477
|
-
}
|
|
57478
|
-
|
|
57479
|
-
|
|
57480
|
-
|
|
57481
|
-
|
|
57482
|
-
|
|
57483
|
-
|
|
57484
|
-
|
|
57485
|
-
|
|
57486
|
-
|
|
57487
|
-
|
|
57488
|
-
|
|
57489
|
-
|
|
57490
|
-
|
|
57491
|
-
|
|
57492
|
-
|
|
57964
|
+
scale
|
|
57965
|
+
};
|
|
57966
|
+
|
|
57967
|
+
// Each control is gated here rather than only inside it, so the bar never reserves width for a control
|
|
57968
|
+
// that would render nothing
|
|
57969
|
+
const items = [!isGalleryOpen && !isFullscreen && canShowThumbnails && onThumbnailsToggle && {
|
|
57970
|
+
control: /*#__PURE__*/external_react_["default"].createElement(ThumbnailsToggleV2, {
|
|
57971
|
+
isThumbnailsOpen: isThumbnailsOpen,
|
|
57972
|
+
onThumbnailsToggle: onThumbnailsToggle
|
|
57973
|
+
}),
|
|
57974
|
+
id: 'thumbnails',
|
|
57975
|
+
menu: /*#__PURE__*/external_react_["default"].createElement(external_react_["default"].Fragment, null, /*#__PURE__*/external_react_["default"].createElement(ControlsMenuItemV2, {
|
|
57976
|
+
"data-resin-target": "thumbnails",
|
|
57977
|
+
icon: __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Nav_d41e959a_default__,
|
|
57978
|
+
label: isThumbnailsOpen ? DocControlsV2_('controls_hide_thumbnails') : DocControlsV2_('controls_show_thumbnails'),
|
|
57979
|
+
onSelect: () => onThumbnailsToggle()
|
|
57980
|
+
}), /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.DropdownMenu.Separator, null)),
|
|
57981
|
+
priority: PRIORITY.thumbnails
|
|
57982
|
+
}, !isGalleryOpen && pageCount > 1 && {
|
|
57983
|
+
control: /*#__PURE__*/external_react_["default"].createElement(PageControlsV2, {
|
|
57984
|
+
onPageChange: onPageChange,
|
|
57985
|
+
onPageSubmit: onPageSubmit,
|
|
57986
|
+
pageCount: pageCount,
|
|
57987
|
+
pageNumber: pageNumber
|
|
57988
|
+
}),
|
|
57989
|
+
id: 'page'
|
|
57990
|
+
}, (!isGalleryOpen || hasGalleryZoom) && {
|
|
57991
|
+
control: /*#__PURE__*/external_react_["default"].createElement(ZoomControlsV2, zoomProps),
|
|
57992
|
+
id: 'zoom',
|
|
57993
|
+
menu: !isGalleryOpen && /*#__PURE__*/external_react_["default"].createElement(ZoomMenuItemsV2, zoomProps),
|
|
57994
|
+
priority: isGalleryOpen ? undefined : PRIORITY.zoom
|
|
57995
|
+
}, !isGalleryOpen && onFindBarToggle && {
|
|
57996
|
+
control: /*#__PURE__*/external_react_["default"].createElement(FindBarToggleV2, {
|
|
57997
|
+
onFindBarToggle: onFindBarToggle
|
|
57998
|
+
}),
|
|
57999
|
+
id: 'find',
|
|
58000
|
+
menu: /*#__PURE__*/external_react_["default"].createElement(ControlsMenuItemV2, {
|
|
58001
|
+
"data-resin-target": "findBar",
|
|
58002
|
+
icon: __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_Search_ef3e4aba_default__,
|
|
58003
|
+
label: DocControlsV2_('controls_find'),
|
|
58004
|
+
onSelect: onFindBarToggle,
|
|
58005
|
+
shortcutKey: "F"
|
|
58006
|
+
}),
|
|
58007
|
+
priority: PRIORITY.find
|
|
58008
|
+
}, !isGalleryOpen && onRotateLeft && {
|
|
58009
|
+
control: /*#__PURE__*/external_react_["default"].createElement(RotateControlV2, {
|
|
58010
|
+
onRotateLeft: onRotateLeft
|
|
58011
|
+
}),
|
|
58012
|
+
id: 'rotate',
|
|
58013
|
+
menu: /*#__PURE__*/external_react_["default"].createElement(ControlsMenuItemV2, {
|
|
58014
|
+
"data-resin-target": "rotate",
|
|
58015
|
+
icon: __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_RotateLeft_c726d679_default__,
|
|
58016
|
+
bareKey: "R",
|
|
58017
|
+
label: DocControlsV2_('controls_rotate_document'),
|
|
58018
|
+
onSelect: () => onRotateLeft()
|
|
58019
|
+
}),
|
|
58020
|
+
priority: PRIORITY.rotate
|
|
58021
|
+
}, onGalleryToggle && {
|
|
58022
|
+
control: /*#__PURE__*/external_react_["default"].createElement(GalleryToggleV2, {
|
|
58023
|
+
isGalleryOpen: isGalleryOpen,
|
|
58024
|
+
onGalleryToggle: onGalleryToggle
|
|
58025
|
+
}),
|
|
58026
|
+
id: 'gallery',
|
|
58027
|
+
menu: !isGalleryOpen && /*#__PURE__*/external_react_["default"].createElement(ControlsMenuItemV2, {
|
|
58028
|
+
"data-resin-target": "galleryView",
|
|
58029
|
+
icon: __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_GridView_ac92b674_default__,
|
|
58030
|
+
label: DocControlsV2_('controls_view_as_grid'),
|
|
58031
|
+
onSelect: () => onGalleryToggle()
|
|
58032
|
+
}),
|
|
58033
|
+
priority: isGalleryOpen ? undefined : PRIORITY.gallery
|
|
58034
|
+
}, {
|
|
58035
|
+
control: /*#__PURE__*/external_react_["default"].createElement(FullscreenToggleV2, {
|
|
58036
|
+
onFullscreenToggle: onFullscreenToggle
|
|
58037
|
+
}),
|
|
58038
|
+
id: 'fullscreen',
|
|
58039
|
+
menu: !isGalleryOpen && /*#__PURE__*/external_react_["default"].createElement(ControlsMenuItemV2, {
|
|
58040
|
+
"data-resin-target": "fullscreen",
|
|
58041
|
+
icon: isFullscreen ? __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_ArrowsMinimize_35faab95_default__ : __WEBPACK_EXTERNAL_MODULE__box_blueprint_web_assets_icons_Medium_ArrowsMaximize_12b9ae40_default__,
|
|
58042
|
+
bareKey: "F",
|
|
58043
|
+
label: isFullscreen ? DocControlsV2_('exit_fullscreen') : DocControlsV2_('enter_fullscreen'),
|
|
58044
|
+
onSelect: trigger => onFullscreenToggle(!isFullscreen, trigger)
|
|
58045
|
+
}),
|
|
58046
|
+
priority: isGalleryOpen ? undefined : PRIORITY.fullscreen
|
|
58047
|
+
}, hasAnnotations && {
|
|
58048
|
+
control: /*#__PURE__*/external_react_["default"].createElement(external_react_["default"].Fragment, null, /*#__PURE__*/external_react_["default"].createElement(blueprint_web_.Toolbar.Separator, null), /*#__PURE__*/external_react_["default"].createElement(AnnotationsExitButtonV2, {
|
|
58049
|
+
onClick: handleAnnotationsExit
|
|
58050
|
+
}), /*#__PURE__*/external_react_["default"].createElement(annotations_AnnotationsToggleV2, {
|
|
58051
|
+
ref: annotationsToggleRef,
|
|
58052
|
+
annotationMode: annotationMode,
|
|
58053
|
+
modes: annotationModes,
|
|
58054
|
+
onAnnotationModeClick: onAnnotationModeClick,
|
|
58055
|
+
onAnnotationModeEscape: onAnnotationModeEscape
|
|
58056
|
+
})),
|
|
58057
|
+
id: 'annotations'
|
|
58058
|
+
}];
|
|
58059
|
+
return /*#__PURE__*/external_react_["default"].createElement(ExperiencesProvider, {
|
|
58060
|
+
experiences: experiences
|
|
58061
|
+
}, /*#__PURE__*/external_react_["default"].createElement(ResponsiveControlsBarV2, {
|
|
58062
|
+
items: items.filter(item => !!item)
|
|
58063
|
+
}), hasAnnotations && annotationMode !== AnnotationMode.NONE && /*#__PURE__*/external_react_["default"].createElement(annotations_AnnotationsPaletteV2, null, /*#__PURE__*/external_react_["default"].createElement(annotations_AnnotationsPaletteV2.Modes, {
|
|
57493
58064
|
annotationMode: annotationMode,
|
|
57494
58065
|
onAnnotationModeClick: onAnnotationModeClick
|
|
57495
58066
|
}, annotationModes.map(mode => /*#__PURE__*/external_react_["default"].createElement(annotations_AnnotationsPaletteV2.Mode, {
|
|
@@ -61057,8 +61628,6 @@ class ThumbnailsSidebar {
|
|
|
61057
61628
|
}
|
|
61058
61629
|
}
|
|
61059
61630
|
/* harmony default export */ const lib_ThumbnailsSidebar = (ThumbnailsSidebar);
|
|
61060
|
-
// EXTERNAL MODULE: external "react-dom"
|
|
61061
|
-
var external_react_dom_ = __webpack_require__(7516);
|
|
61062
61631
|
;// ./src/lib/ThumbnailsSidebarV2.scss
|
|
61063
61632
|
// extracted by mini-css-extract-plugin
|
|
61064
61633
|
|
|
@@ -61251,6 +61820,7 @@ function DocBaseViewer_toPrimitive(t, r) { if ("object" != typeof t || !t) retur
|
|
|
61251
61820
|
|
|
61252
61821
|
|
|
61253
61822
|
|
|
61823
|
+
|
|
61254
61824
|
|
|
61255
61825
|
|
|
61256
61826
|
const DOC_FIRST_PAGES_ENABLED = 'docFirstPages.enabled';
|
|
@@ -61413,9 +61983,17 @@ class DocBaseViewer extends viewers_BaseViewer {
|
|
|
61413
61983
|
getThumbnailsSidebar: () => this.thumbnailsSidebar,
|
|
61414
61984
|
setPage: n => this.setPage(n),
|
|
61415
61985
|
toggleThumbnails: () => this.toggleThumbnails(),
|
|
61416
|
-
requestUiUpdate: () =>
|
|
61986
|
+
requestUiUpdate: () => {
|
|
61987
|
+
// The v2 bar moves the gallery toggle between the bar and its overflow menu, so the bar must be
|
|
61988
|
+
// committed before focusToggle looks the toggle up
|
|
61989
|
+
if (this.featureEnabled(constants/* BLUEPRINT_MIGRATION_CONTROLS_BAR */.OQ)) {
|
|
61990
|
+
(0,external_react_dom_.flushSync)(() => this.renderUI());
|
|
61991
|
+
} else {
|
|
61992
|
+
this.renderUI();
|
|
61993
|
+
}
|
|
61994
|
+
},
|
|
61417
61995
|
focusToggle: () => {
|
|
61418
|
-
const toggle = this.containerEl.querySelector('.bp-GalleryToggle, [data-bp-gallery-toggle]');
|
|
61996
|
+
const toggle = this.containerEl.querySelector('.bp-GalleryToggle, [data-bp-gallery-toggle], [data-overflow-ids~="gallery"]');
|
|
61419
61997
|
if (toggle && toggle.focus) {
|
|
61420
61998
|
toggle.focus();
|
|
61421
61999
|
}
|
|
@@ -61649,7 +62227,7 @@ class DocBaseViewer extends viewers_BaseViewer {
|
|
|
61649
62227
|
const isWatermarked = file && file.watermark_info && file.watermark_info.is_watermarked;
|
|
61650
62228
|
if (assets) {
|
|
61651
62229
|
if (this.featureEnabled('useNpmPdfjs') || (0,isNpmBuild/* isNpmBuild */.w)()) {
|
|
61652
|
-
this.prefetchAssets(EXIF_READER,
|
|
62230
|
+
this.prefetchAssets(EXIF_READER, []);
|
|
61653
62231
|
} else {
|
|
61654
62232
|
const ASSETS = this.featureEnabled(DOC_FIRST_PAGES_ENABLED) ? [...JS_NO_EXIF, ...EXIF_READER] : docAssets_JS;
|
|
61655
62233
|
this.prefetchAssets(ASSETS, docAssets_CSS);
|
|
@@ -62104,6 +62682,22 @@ class DocBaseViewer extends viewers_BaseViewer {
|
|
|
62104
62682
|
case ']':
|
|
62105
62683
|
this.nextPage();
|
|
62106
62684
|
break;
|
|
62685
|
+
case 'r':
|
|
62686
|
+
case 'R':
|
|
62687
|
+
// The rotate control is hidden while the gallery is open, so the key follows it.
|
|
62688
|
+
// These bare keys belong to the v2 controls bar; the older bar has no such shortcuts.
|
|
62689
|
+
if (this.featureEnabled(constants/* BLUEPRINT_MIGRATION_CONTROLS_BAR */.OQ) && !this.galleryController?.isOpen && this.featureEnabled('rotate.enabled')) {
|
|
62690
|
+
this.rotateLeft();
|
|
62691
|
+
break;
|
|
62692
|
+
}
|
|
62693
|
+
return this.findBar ? this.findBar.onKeydown(event) : false;
|
|
62694
|
+
case 'f':
|
|
62695
|
+
case 'F':
|
|
62696
|
+
if (this.featureEnabled(constants/* BLUEPRINT_MIGRATION_CONTROLS_BAR */.OQ)) {
|
|
62697
|
+
this.toggleFullscreen();
|
|
62698
|
+
break;
|
|
62699
|
+
}
|
|
62700
|
+
return this.findBar ? this.findBar.onKeydown(event) : false;
|
|
62107
62701
|
default:
|
|
62108
62702
|
if (this.findBar) {
|
|
62109
62703
|
return this.findBar.onKeydown(event);
|
|
@@ -62313,7 +62907,7 @@ class DocBaseViewer extends viewers_BaseViewer {
|
|
|
62313
62907
|
container: this.docEl,
|
|
62314
62908
|
eventBus: this.pdfEventBus,
|
|
62315
62909
|
findController: this.pdfFindController,
|
|
62316
|
-
imageResourcesPath: assetUrlCreator(IMAGES),
|
|
62910
|
+
imageResourcesPath: this.featureEnabled('useNpmPdfjs') ? assetUrlCreator('pdfjs-images/') : assetUrlCreator(IMAGES),
|
|
62317
62911
|
linkService: this.pdfLinkService,
|
|
62318
62912
|
maxCanvasPixels: this.isMobile ? MOBILE_MAX_CANVAS_SIZE : -1,
|
|
62319
62913
|
renderInteractiveForms: false,
|
|
@@ -70457,7 +71051,9 @@ class Preview extends (events_default()) {
|
|
|
70457
71051
|
// Start the preview load and render timers when the user starts to perceive preview's load
|
|
70458
71052
|
lib_Timer.start(lib_Timer.createTag(this.file.id, lib_events/* LOAD_METRIC */.Yy.previewLoadTime));
|
|
70459
71053
|
lib_Timer.start(lib_Timer.createTag(this.file.id, lib_events/* RENDER_METRIC */.QQ));
|
|
70460
|
-
lib_Timer.
|
|
71054
|
+
const firstRenderTag = lib_Timer.createTag(this.file.id, lib_events/* FIRST_RENDER_METRIC */.VT);
|
|
71055
|
+
lib_Timer.reset(firstRenderTag);
|
|
71056
|
+
lib_Timer.start(firstRenderTag);
|
|
70461
71057
|
|
|
70462
71058
|
// If file version ID is specified, increment retry count if it matches current file version ID
|
|
70463
71059
|
if (fileVersionId) {
|