box-content-preview 3.54.0 → 3.55.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 CHANGED
@@ -2,7 +2,7 @@
2
2
  [![Mergify Status](https://img.shields.io/endpoint.svg?url=https://gh.mergify.io/badges/box/box-content-preview&style=flat)](https://mergify.io)
3
3
  [![Styled With Prettier](https://img.shields.io/badge/styled_with-prettier-ff69b4.svg?style=flat-square)](https://github.com/prettier/prettier)
4
4
  [![build status](https://img.shields.io/travis/box/box-content-preview/master.svg?style=flat-square)](https://travis-ci.org/box/box-content-preview)
5
- [![version](https://img.shields.io/badge/version-v3.54.0-blue.svg?style=flat-square)](https://github.com/box/box-content-preview)
5
+ [![version](https://img.shields.io/badge/version-v3.55.0-blue.svg?style=flat-square)](https://github.com/box/box-content-preview)
6
6
  [![npm version](https://img.shields.io/npm/v/box-ui-elements.svg?style=flat-square)](https://www.npmjs.com/package/box-ui-elements)
7
7
 
8
8
  # [Box Content Preview](https://developer.box.com/docs/box-content-preview)
@@ -22,11 +22,11 @@ We encourage all users to update their applications to utilize modern browsers f
22
22
 
23
23
  ## Current Version
24
24
 
25
- - Version: v3.54.0
25
+ - Version: v3.55.0
26
26
  - Locale: en-US
27
27
 
28
- https://cdn01.boxcdn.net/platform/preview/3.54.0/en-US/preview.js
29
- https://cdn01.boxcdn.net/platform/preview/3.54.0/en-US/preview.css
28
+ https://cdn01.boxcdn.net/platform/preview/3.55.0/en-US/preview.js
29
+ https://cdn01.boxcdn.net/platform/preview/3.55.0/en-US/preview.css
30
30
 
31
31
  ## Supported Locales
32
32
 
@@ -52,10 +52,10 @@ You can self-host the Box Content Preview library or reference the versions avai
52
52
  <title>Box Content Preview Demo</title>
53
53
 
54
54
  <!-- Latest version of Preview SDK for your locale -->
55
- <script src="https://cdn01.boxcdn.net/platform/preview/3.54.0/en-US/preview.js"></script>
55
+ <script src="https://cdn01.boxcdn.net/platform/preview/3.55.0/en-US/preview.js"></script>
56
56
  <link
57
57
  rel="stylesheet"
58
- href="https://cdn01.boxcdn.net/platform/preview/3.54.0/en-US/preview.css"
58
+ href="https://cdn01.boxcdn.net/platform/preview/3.55.0/en-US/preview.css"
59
59
  />
60
60
  </head>
61
61
  <body>
@@ -76,7 +76,7 @@ To self-host the Box Content Preview library, follow these steps:
76
76
 
77
77
  1. Either fork the repo and check out the version you want to host or download the specific version as a zip:
78
78
 
79
- - Check out a specific version with `git checkout v3.54.0`
79
+ - Check out a specific version with `git checkout v3.55.0`
80
80
  - Download a specific version as a zip from https://github.com/box/box-content-preview/releases
81
81
 
82
82
  2. Install dependencies and build the library with `yarn install && yarn build:i18n && yarn build:prod`
@@ -22,7 +22,7 @@
22
22
  */
23
23
  .bp-archive{display:flex;width:100%;height:100%;background:#fff}
24
24
  .bp-ControlsLayer{display:flex;opacity:0;transition:opacity .5s}.bp-ControlsLayer.bp-is-visible{opacity:1}
25
- .bp-ControlsRoot{position:absolute;bottom:25px;left:50%;z-index:4;transform:translate3d(-50%, 0, 0);backface-visibility:hidden}.bp-ControlsRoot.bp-is-hidden{display:none}
25
+ .bp-ControlsRoot{position:absolute;bottom:25px;left:50%;z-index:5;transform:translate3d(-50%, 0, 0);backface-visibility:hidden}.bp-ControlsRoot.bp-is-hidden{display:none}
26
26
  .bp-AnnotationsButton{opacity:.9;transition:opacity 150ms,background-color 150ms;will-change:opacity;outline:0;display:flex;align-items:center;justify-content:center;margin:0;padding:0;color:#fff;background:transparent;border:0;border-radius:25px;cursor:pointer;-webkit-user-select:none;user-select:none;touch-action:manipulation;zoom:1}.bp-AnnotationsButton:focus:not(:disabled),.bp-AnnotationsButton:hover:not(:disabled){background-color:rgba(255,255,255,.08);opacity:1}.bp-AnnotationsButton:focus:not(:disabled) svg,.bp-AnnotationsButton:hover:not(:disabled) svg,.bp-AnnotationsButton.bp-is-active svg{transform:scale(1.09);transition:transform 150ms}.bp-AnnotationsButton.bp-is-active,.bp-AnnotationsButton:active:not(:disabled){background-color:rgba(255,255,255,.16)}.bp-AnnotationsButton.bp-is-active:focus:not(:disabled),.bp-AnnotationsButton.bp-is-active:hover:not(:disabled){background-color:rgba(255,255,255,.2)}.bp-AnnotationsButton:focus:not(:disabled){box-shadow:inset 0 0 0 1px rgba(211,211,211,.5),0 1px 2px rgba(0,0,0,.1)}.bp-AnnotationsButton:focus-visible:not(:disabled){box-shadow:inset 0 0 0 1px rgba(211,211,211,.5),0 1px 2px rgba(0,0,0,.1)}.bp-AnnotationsButton:focus:not(:focus-visible){box-shadow:none}.bp-AnnotationsButton:disabled{cursor:default;opacity:.2;pointer-events:none}.bp-AnnotationsButton svg{width:32px;height:32px;padding:5px}.bp-AnnotationsButton svg{fill:#fff}.bp-AnnotationsButton.bp-is-active{opacity:1}
27
27
  .bp-AnnotationsTooltip{max-width:408px;padding:18px 0 12px 18px}.bp-AnnotationsTooltip-title{font-weight:bold;font-size:18px}.bp-AnnotationsTooltip-body{font-size:14px;line-height:20px}
28
28
  .bp-AnnotationsControls{display:flex;gap:4px;align-items:center}.bp-AnnotationsControls:not(:first-child){padding-left:4px;border-left:1px solid #4e4e4e}.bp-AnnotationsControls-exitBtn{display:none}.ba-point-annotation-marker{z-index:3}
@@ -80,7 +80,7 @@
80
80
  .bp-FindBarToggle{opacity:.9;transition:opacity 150ms,background-color 150ms;will-change:opacity;outline:0;display:flex;align-items:center;justify-content:center;margin:0;padding:0;color:#fff;background:transparent;border:0;border-radius:25px;cursor:pointer;-webkit-user-select:none;user-select:none;touch-action:manipulation;zoom:1}.bp-FindBarToggle:focus:not(:disabled),.bp-FindBarToggle:hover:not(:disabled){background-color:rgba(255,255,255,.08);opacity:1}.bp-FindBarToggle:focus:not(:disabled) svg,.bp-FindBarToggle:hover:not(:disabled) svg,.bp-FindBarToggle.bp-is-active svg{transform:scale(1.09);transition:transform 150ms}.bp-FindBarToggle.bp-is-active,.bp-FindBarToggle:active:not(:disabled){background-color:rgba(255,255,255,.16)}.bp-FindBarToggle.bp-is-active:focus:not(:disabled),.bp-FindBarToggle.bp-is-active:hover:not(:disabled){background-color:rgba(255,255,255,.2)}.bp-FindBarToggle:focus:not(:disabled){box-shadow:inset 0 0 0 1px rgba(211,211,211,.5),0 1px 2px rgba(0,0,0,.1)}.bp-FindBarToggle:focus-visible:not(:disabled){box-shadow:inset 0 0 0 1px rgba(211,211,211,.5),0 1px 2px rgba(0,0,0,.1)}.bp-FindBarToggle:focus:not(:focus-visible){box-shadow:none}.bp-FindBarToggle:disabled{cursor:default;opacity:.2;pointer-events:none}.bp-FindBarToggle svg{width:32px;height:32px;padding:5px}
81
81
  .bp-GalleryToggle{opacity:.9;transition:opacity 150ms,background-color 150ms;will-change:opacity;outline:0;display:flex;align-items:center;justify-content:center;margin:0;padding:0;color:#fff;background:transparent;border:0;border-radius:25px;cursor:pointer;-webkit-user-select:none;user-select:none;touch-action:manipulation;zoom:1}.bp-GalleryToggle:focus:not(:disabled),.bp-GalleryToggle:hover:not(:disabled){background-color:rgba(255,255,255,.08);opacity:1}.bp-GalleryToggle:focus:not(:disabled) svg,.bp-GalleryToggle:hover:not(:disabled) svg,.bp-GalleryToggle.bp-is-active svg{transform:scale(1.09);transition:transform 150ms}.bp-GalleryToggle.bp-is-active,.bp-GalleryToggle:active:not(:disabled){background-color:rgba(255,255,255,.16)}.bp-GalleryToggle.bp-is-active:focus:not(:disabled),.bp-GalleryToggle.bp-is-active:hover:not(:disabled){background-color:rgba(255,255,255,.2)}.bp-GalleryToggle:focus:not(:disabled){box-shadow:inset 0 0 0 1px rgba(211,211,211,.5),0 1px 2px rgba(0,0,0,.1)}.bp-GalleryToggle:focus-visible:not(:disabled){box-shadow:inset 0 0 0 1px rgba(211,211,211,.5),0 1px 2px rgba(0,0,0,.1)}.bp-GalleryToggle:focus:not(:focus-visible){box-shadow:none}.bp-GalleryToggle:disabled{cursor:default;opacity:.2;pointer-events:none}.bp-GalleryToggle svg{width:32px;height:32px;padding:5px}
82
82
  .bp-ThumbnailsToggle{opacity:.9;transition:opacity 150ms,background-color 150ms;will-change:opacity;outline:0;display:flex;align-items:center;justify-content:center;margin:0;padding:0;color:#fff;background:transparent;border:0;border-radius:25px;cursor:pointer;-webkit-user-select:none;user-select:none;touch-action:manipulation;zoom:1}.bp-ThumbnailsToggle:focus:not(:disabled),.bp-ThumbnailsToggle:hover:not(:disabled){background-color:rgba(255,255,255,.08);opacity:1}.bp-ThumbnailsToggle:focus:not(:disabled) svg,.bp-ThumbnailsToggle:hover:not(:disabled) svg,.bp-ThumbnailsToggle.bp-is-active svg{transform:scale(1.09);transition:transform 150ms}.bp-ThumbnailsToggle.bp-is-active,.bp-ThumbnailsToggle:active:not(:disabled){background-color:rgba(255,255,255,.16)}.bp-ThumbnailsToggle.bp-is-active:focus:not(:disabled),.bp-ThumbnailsToggle.bp-is-active:hover:not(:disabled){background-color:rgba(255,255,255,.2)}.bp-ThumbnailsToggle:focus:not(:disabled){box-shadow:inset 0 0 0 1px rgba(211,211,211,.5),0 1px 2px rgba(0,0,0,.1)}.bp-ThumbnailsToggle:focus-visible:not(:disabled){box-shadow:inset 0 0 0 1px rgba(211,211,211,.5),0 1px 2px rgba(0,0,0,.1)}.bp-ThumbnailsToggle:focus:not(:focus-visible){box-shadow:none}.bp-ThumbnailsToggle:disabled{cursor:default;opacity:.2;pointer-events:none}.bp-ThumbnailsToggle svg{width:32px;height:32px;padding:5px}
83
- .bp-gallery-grid{position:absolute;top:0;right:0;bottom:0;left:0;z-index:2;display:grid;grid-template-columns:repeat(auto-fill, minmax(220px, 1fr));gap:16px;align-items:start;padding:40px;padding-bottom:100px;overflow-y:auto;background-color:#fff}.bp-gallery-tile{position:relative;padding:0;background:#f5f5f5;border:none;border-radius:12px;box-shadow:0 0 0 1px #eaeaea;cursor:pointer;transition:box-shadow .2s ease-in-out}.bp-gallery-tile:hover{box-shadow:0 0 0 3px #767676,0 4px 5px 0 rgba(0,0,0,.15)}.bp-gallery-tile:hover .bp-gallery-tile-badge{opacity:1}.bp-gallery-tile:focus{outline:none}.bp-gallery-tile img{display:block;width:100%;height:auto;border-radius:12px}.bp-gallery-tile--selected{box-shadow:0 0 0 3px #0061d5,0 4px 5px 0 rgba(0,0,0,.08)}.bp-gallery-tile--selected:hover,.bp-gallery-tile--selected:focus{box-shadow:0 0 0 3px #0061d5,0 4px 5px 0 rgba(0,0,0,.08)}.bp-gallery-tile--selected .bp-gallery-tile-badge{background:#0061d5;opacity:1}.bp-gallery-tile-badge{position:absolute;top:0;left:0;z-index:1;display:flex;align-items:center;justify-content:center;min-width:28px;height:24px;padding:0 4px;color:#fff;font-size:13px;line-height:1;background:#767676;border-radius:12px 0 12px 0;opacity:0;transition:opacity .15s}.bp-gallery-tile-placeholder{display:block;width:100%;padding-top:129%}
83
+ .bp-gallery-grid{position:absolute;top:0;right:0;bottom:0;left:0;z-index:4;display:grid;grid-template-columns:repeat(auto-fill, minmax(220px, 1fr));gap:16px;align-items:start;padding:40px;padding-bottom:100px;overflow-y:auto;overscroll-behavior:none;background-color:#fff}.bp-gallery-tile{position:relative;padding:0;background:#f5f5f5;border:none;border-radius:12px;box-shadow:0 0 0 1px #eaeaea;cursor:pointer;transition:box-shadow .2s ease-in-out}.bp-gallery-tile:hover{box-shadow:0 0 0 3px #767676,0 4px 5px 0 rgba(0,0,0,.15)}.bp-gallery-tile:hover .bp-gallery-tile-badge{opacity:1}.bp-gallery-tile:focus{outline:none}.bp-gallery-tile img{display:block;width:100%;height:auto;border-radius:12px}.bp-gallery-tile--selected{box-shadow:0 0 0 3px #0061d5,0 4px 5px 0 rgba(0,0,0,.08)}.bp-gallery-tile--selected:hover,.bp-gallery-tile--selected:focus{box-shadow:0 0 0 3px #0061d5,0 4px 5px 0 rgba(0,0,0,.08)}.bp-gallery-tile--selected .bp-gallery-tile-badge{background:#0061d5;opacity:1}.bp-gallery-tile-badge{position:absolute;top:0;left:0;z-index:1;display:flex;align-items:center;justify-content:center;min-width:28px;height:24px;padding:0 4px;color:#fff;font-size:13px;line-height:1;background:#767676;border-radius:12px 0 12px 0;opacity:0;transition:opacity .15s}.bp-gallery-tile-placeholder{display:block;width:100%;padding-top:129%}.bp-container:has(.bp-gallery-grid) .ba-PopupPortal{display:none}
84
84
  .custom-theme .bp .bp-thumbnail.bp-thumbnail-is-selected .bp-thumbnail-nav{box-shadow:0 0 0 3px #222,0 4px 5px 0 rgba(0,0,0,.08)}.custom-theme .bp .bp-thumbnail.bp-thumbnail-is-selected .bp-thumbnail-page-number{background:#222}.custom-theme .bp .bp-thumbnail.bp-thumbnail-is-selected.bp-thumbnail-image-loaded .bp-thumbnail-nav{background-color:#222}.bp .bp-ThumbnailsToggle{display:none}.bp .bp-thumbnails-container{position:absolute;top:0;bottom:0;left:0;display:none;flex:0 0 auto;width:191px}.bp .bp-thumbnails-container:focus{outline:none}.bp .bp-thumbnail{position:relative;display:flex;margin-right:20px;margin-left:20px;cursor:pointer;transition:transform .2s ease-in-out}.bp .bp-thumbnail:focus,.bp .bp-thumbnail:hover{transform:translateY(-1px) scale(1.02)}.bp .bp-thumbnail:focus .bp-thumbnail-page-number,.bp .bp-thumbnail:hover .bp-thumbnail-page-number{background:#767676;opacity:1}.bp .bp-thumbnail:focus .bp-thumbnail-nav,.bp .bp-thumbnail:hover .bp-thumbnail-nav{box-shadow:0 0 0 1px #767676,0 4px 5px 0 rgba(0,0,0,.15)}.bp .bp-thumbnail:focus.bp-thumbnail-image-loaded .bp-thumbnail-nav,.bp .bp-thumbnail:hover.bp-thumbnail-image-loaded .bp-thumbnail-nav{background-color:#767676}.bp .bp-thumbnail.bp-thumbnail-is-selected .bp-thumbnail-page-number{background:#0061d5;opacity:1}.bp .bp-thumbnail.bp-thumbnail-is-selected .bp-thumbnail-nav{box-shadow:0 0 0 3px #0061d5,0 4px 5px 0 rgba(0,0,0,.08)}.bp .bp-thumbnail.bp-thumbnail-is-selected.bp-thumbnail-image-loaded .bp-thumbnail-nav{background-color:#0061d5}.bp .bp-thumbnail:not(.bp-thumbnail-image-loaded) .bp-thumbnail-nav{background:#e8e8e8 url(assets/loading_ghost.gif) repeat-y;background-size:100% 100%}.bp .bp-thumbnail-nav{flex:0 0 150px;overflow:hidden;background-color:#d8d8d8;border-radius:6px;box-shadow:0 0 0 1px #e8e8e8,0 1px 4px 0 rgba(0,0,0,.08);transition:box-shadow .2s ease-in-out}.bp .bp-thumbnail-page-number{position:absolute;display:flex;align-items:center;justify-content:center;min-width:28px;height:24px;padding-right:3px;padding-left:3px;color:#fff;font-size:13px;border-radius:3px 0 6px 0;box-shadow:1px 1px 2px 0 rgba(0,0,0,.2);opacity:0}.bp .bp-thumbnail-image{background-repeat:no-repeat;background-position:center;background-size:contain;pointer-events:none}.bp .bp-thumbnails-container--dark{background-color:#444;border-right-color:#000}.bp .bp-thumbnails-container--dark .bp-thumbnail-page-number{background-color:#444}.bp .bp-thumbnails-container--dark .bp-thumbnail-nav{border-color:#444}@keyframes bp-thumbnails-open{0%{display:none;transform:translateX(-191px)}1%{display:flex;transform:translateX(-191px)}100%{transform:translateX(0)}}@media(min-width: 768px){.bp.bp-loaded.bp-thumbnails-open-active .bp-content,.bp.bp-loaded.bp-thumbnails-close-active .bp-content{transition:left 300ms cubic-bezier(0.4, 0, 0.2, 1)}.bp .bp-thumbnails-container{display:none;transition:transform 300ms cubic-bezier(0.4, 0, 0.2, 1)}.bp .bp-thumbnails-container,.bp.bp-thumbnails-close .bp-thumbnails-container,.bp.bp-thumbnails-close-active .bp-thumbnails-container{transform:translateX(-191px)}.bp.bp-thumbnails-close .bp-thumbnails-container{display:none}.bp.bp-thumbnails-close-active .bp-thumbnails-container{display:flex}.bp.bp-thumbnails-open .bp-content{left:191px}.bp.bp-thumbnails-open .bp-content.bp-is-fullscreen{left:0}.bp.bp-thumbnails-open .bp-thumbnails-container{display:flex;transform:translateX(0)}.bp.bp-thumbnails-open-active .bp-thumbnails-container{animation:bp-thumbnails-open 300ms cubic-bezier(0.4, 0, 0.2, 1)}.bp .bp-ThumbnailsToggle{display:flex}}@media(max-width: 767px){.bp-is-mobile .bp-ZoomControls{display:none}}.bp-theme-dark .bp .bp-thumbnails-container{border-right-color:#222}.bp-doc{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;margin:0;overflow:hidden;letter-spacing:normal;-webkit-user-select:none;user-select:none;-webkit-tap-highlight-color:transparent}.bp-doc [hidden]{display:none !important}.bp-doc.bp-is-scrollable{overflow:auto}.bp-doc .pdfViewer.pinching{visibility:hidden}.bp-doc .pdfViewer .page{position:relative;display:block;box-sizing:content-box !important;margin:0 auto;padding:15px 0;overflow:visible;border:0;border-image:none}.bp-doc .pdfViewer .page:not(.bp-is-invisible)::before{box-shadow:0 4px 12px 0 rgba(0,0,0,.1);position:absolute;top:15px;right:0;bottom:15px;left:0;display:block;content:""}.bp-doc .pdfViewer .page:not(.bp-is-invisible) .loadingIcon:first-child{background:#e8e8e8 url(assets/loading_ghost.gif) repeat-y;background-size:100% 100%}.bp-doc .pdfViewer .page .loadingIcon{top:15px;bottom:15px;background:none}.bp-doc .pdfViewer .page.loadingIcon::after{top:15px;bottom:15px;background:none}.bp-doc .pdfViewer .page .textAnnotation>img{opacity:0}.bp-doc .pdfViewer .page.pinch-page{padding:0;visibility:visible}.bp-doc .pdfViewer .page.pinch-page .textLayer{display:none}.bp-doc .pdfViewer.pdfViewer--viewOnly .textLayer span{cursor:unset;-webkit-user-select:none;user-select:none}.bp-doc .textLayer{top:15px;bottom:auto;z-index:1;opacity:1;caret-color:#000}.bp-doc .textLayer>div{-webkit-user-select:text;user-select:text}.bp-doc .textLayer .highlight{display:inline-block;background-color:rgba(180,0,170,.2)}.bp-doc .textLayer .highlight.selected{background-color:rgba(0,100,0,.2)}.bp-doc .textLayer .rangy-highlight{opacity:.2}.bp-doc .textLayer ::selection{background-color:rgba(0,97,213,.1)}.bp-doc input,.bp-doc p,.bp-doc span{-webkit-user-select:text;user-select:text}.bp-doc .annotationLayer h1,.bp-doc .annotationLayer h2,.bp-doc .annotationLayer h3,.bp-doc .annotationLayer h4,.bp-doc .annotationLayer h5,.bp-doc .annotationLayer h6,.bp-doc .annotationLayer p{margin:0}.bp-doc .annotationLayer h1{font-size:1em}.bp-doc .annotationLayer section{margin-top:15px}.bp-doc .annotationLayer .popup{font-size:inherit}.bp-doc .annotationLayer .popup .header{height:unset;padding:unset !important;background-color:unset}.bp-print-notification{display:none;font-size:24px}@media print{.bp-doc{display:none}.bp-print-notification{display:block}}.bp-content.bp-annotations-discoverable .ba-PopupCursor{display:none}.bp-content.bp-annotations-discoverable .textLayer{pointer-events:none}.bp-content.bp-annotations-discoverable .textLayer span{pointer-events:auto}@media(max-width: 767px){.bp-content.bp-annotations-only-controls.bp-annotations-create--drawing .bp-AnnotationsControls-exitBtn,.bp-content.bp-annotations-only-controls.bp-annotations-create--highlight .bp-AnnotationsControls-exitBtn,.bp-content.bp-annotations-only-controls.bp-annotations-create--region .bp-AnnotationsControls-exitBtn{display:block}.bp-content.bp-annotations-only-controls.bp-annotations-create--drawing .bp-ControlsBarGroup:not(:last-child),.bp-content.bp-annotations-only-controls.bp-annotations-create--drawing .bp-ControlsBarGroup>*:not(.bp-AnnotationsControls),.bp-content.bp-annotations-only-controls.bp-annotations-create--highlight .bp-ControlsBarGroup:not(:last-child),.bp-content.bp-annotations-only-controls.bp-annotations-create--highlight .bp-ControlsBarGroup>*:not(.bp-AnnotationsControls),.bp-content.bp-annotations-only-controls.bp-annotations-create--region .bp-ControlsBarGroup:not(:last-child),.bp-content.bp-annotations-only-controls.bp-annotations-create--region .bp-ControlsBarGroup>*:not(.bp-AnnotationsControls){display:none}}.bp-content.bp-annotations-create--highlight .ba-PopupCursor,.bp-content.bp-annotations-create--region .ba-PopupCursor{display:block}.bp-content.bp-annotations-create--highlight .annotationLayer,.bp-content.bp-annotations-create--region .annotationLayer{pointer-events:none}.bp-content.bp-annotations-create--highlight .ba-DrawingAnnotations-list.is-listening .ba-DrawingTarget,.bp-content.bp-annotations-create--region .ba-DrawingAnnotations-list.is-listening .ba-DrawingTarget{pointer-events:none}.bp-content.bp-annotations-create--highlight .ba-HighlightList .ba-HighlightSvg.is-listening .ba-HighlightTarget-rect,.bp-content.bp-annotations-create--region .ba-HighlightList .ba-HighlightSvg.is-listening .ba-HighlightTarget-rect{pointer-events:none}.bp-content.bp-annotations-create--highlight .ba-RegionAnnotations-list.is-listening .ba-RegionAnnotation,.bp-content.bp-annotations-create--region .ba-RegionAnnotations-list.is-listening .ba-RegionAnnotation{pointer-events:none}.bp-content.bp-annotations-create--region.bp-annotations-ftux-document-cursor-seen .ba-PopupCursor{display:none}.bp-content.bp-annotations-create--region .textLayer,.bp-content.bp-annotations-create--region .textLayer span{pointer-events:none}.bp-content.bp-is-fullscreen .bp-ThumbnailsToggle{display:none}.bp-find-bar{position:absolute;top:0;right:17px;z-index:3;display:flex;align-items:center;padding:6px;font-size:12px;font-family:Lato,"Helvetica Neue",Helvetica,Arial,sans-serif;background:#fff;border:1px solid #e8e8e8}.bp-find-bar ::-ms-clear{display:none}.bp-find-bar .bp-doc-find-field{width:200px;height:34px;padding:6px 6px 6px 25px;color:#494949;line-height:20px;border:1px solid #e8e8e8;border-radius:2px 0 0 2px;outline-style:none;transition-timing-function:ease;transition-duration:150ms;transition-property:border-color}.bp-find-bar .bp-doc-find-field:focus,.bp-find-bar .bp-doc-find-field:hover{border-color:#0061d5}.bp-find-bar .bp-doc-find-results-count{position:absolute;top:37%;right:120px;margin:0;padding:0;color:rgba(73,73,73,.25);line-height:1;text-align:right;cursor:default;-webkit-user-select:none;user-select:none}.bp-find-bar .bp-doc-find-search,.bp-find-bar .bp-doc-find-prev,.bp-find-bar .bp-doc-find-next,.bp-find-bar .bp-doc-find-close{display:flex;align-items:center;justify-content:center;width:34px;height:34px;padding:0;line-height:1;vertical-align:middle;background:none;border:1px solid #e8e8e8;border-left:0;cursor:pointer}.bp-find-bar .bp-doc-find-search svg,.bp-find-bar .bp-doc-find-prev svg,.bp-find-bar .bp-doc-find-next svg,.bp-find-bar .bp-doc-find-close svg{width:17px}.bp-find-bar .bp-doc-find-search .icon,.bp-find-bar .bp-doc-find-prev .icon,.bp-find-bar .bp-doc-find-next .icon,.bp-find-bar .bp-doc-find-close .icon{fill:rgba(73,73,73,.75)}.bp-find-bar .bp-doc-find-prev:hover .icon,.bp-find-bar .bp-doc-find-next:hover .icon,.bp-find-bar .bp-doc-find-close:hover .icon{fill:#494949}.bp-find-bar .bp-doc-find-search{position:absolute;top:15%;left:5px;margin:0;line-height:1;text-align:left;border:0;pointer-events:none}.bp-find-bar .bp-doc-find-search svg{width:12px;height:12px}.bp-find-bar .bp-doc-find-close{border:0}.bp-find-bar .bp-doc-find-close svg{width:22px}.bp-find-bar .bp-find-match-not-found,.bp-find-bar .bp-find-match-not-found:hover,.bp-find-bar .bp-find-match-not-found:focus{border-color:rgba(239,72,54,.5)}.bp-find-bar .bp-doc-find-controls{display:flex}.bp .bp-doc.bp-doc-document{overflow-y:scroll}.bp-document-preload-wrapper{position:absolute;top:0;right:0;bottom:0;left:0;height:100%;margin:0;overflow-y:scroll;scrollbar-gutter:stable;background-color:#f5f5f5;opacity:1;transition:opacity .5s}.bp-document-preload-wrapper.bp-is-invisible{visibility:hidden}.bp-document-preload-wrapper.bp-is-transparent{opacity:0}.bp-theme-dark .bp-document-preload-wrapper{background-color:#464a4f}.bp-document-preload-wrapper .bp-preload-content,.bp-document-preload-wrapper .bp-preload-overlay,.bp-document-preload-wrapper .bp-preload-placeholder::before{position:absolute;top:0;right:0;bottom:0;left:0}.bp-document-preload-wrapper .bp-preload-content{width:100%}.bp-document-preload-wrapper .bp-preload-overlay{background-color:rgba(255,255,255,.4)}.bp-document-preload-wrapper .bp-preload-placeholder{background:#e8e8e8 url(assets/loading_ghost.gif) repeat-y;background-size:100% 100%;box-shadow:0 4px 12px 0 rgba(0,0,0,.1);position:relative;margin:15px auto 30px}.bp-document-preload-wrapper .bp-preload-placeholder img.doc-first-image{width:100%;height:100%}.bp-document-preload-wrapper .bp-preload-placeholder img.loaded{visibility:visible}
85
85
  .custom-theme .bp .bp-thumbnail.bp-thumbnail-is-selected .bp-thumbnail-nav{box-shadow:0 0 0 3px #222,0 4px 5px 0 rgba(0,0,0,.08)}.custom-theme .bp .bp-thumbnail.bp-thumbnail-is-selected .bp-thumbnail-page-number{background:#222}.custom-theme .bp .bp-thumbnail.bp-thumbnail-is-selected.bp-thumbnail-image-loaded .bp-thumbnail-nav{background-color:#222}.bp .bp-ThumbnailsToggle{display:none}.bp .bp-thumbnails-container{position:absolute;top:0;bottom:0;left:0;display:none;flex:0 0 auto;width:191px}.bp .bp-thumbnails-container:focus{outline:none}.bp .bp-thumbnail{position:relative;display:flex;margin-right:20px;margin-left:20px;cursor:pointer;transition:transform .2s ease-in-out}.bp .bp-thumbnail:focus,.bp .bp-thumbnail:hover{transform:translateY(-1px) scale(1.02)}.bp .bp-thumbnail:focus .bp-thumbnail-page-number,.bp .bp-thumbnail:hover .bp-thumbnail-page-number{background:#767676;opacity:1}.bp .bp-thumbnail:focus .bp-thumbnail-nav,.bp .bp-thumbnail:hover .bp-thumbnail-nav{box-shadow:0 0 0 1px #767676,0 4px 5px 0 rgba(0,0,0,.15)}.bp .bp-thumbnail:focus.bp-thumbnail-image-loaded .bp-thumbnail-nav,.bp .bp-thumbnail:hover.bp-thumbnail-image-loaded .bp-thumbnail-nav{background-color:#767676}.bp .bp-thumbnail.bp-thumbnail-is-selected .bp-thumbnail-page-number{background:#0061d5;opacity:1}.bp .bp-thumbnail.bp-thumbnail-is-selected .bp-thumbnail-nav{box-shadow:0 0 0 3px #0061d5,0 4px 5px 0 rgba(0,0,0,.08)}.bp .bp-thumbnail.bp-thumbnail-is-selected.bp-thumbnail-image-loaded .bp-thumbnail-nav{background-color:#0061d5}.bp .bp-thumbnail:not(.bp-thumbnail-image-loaded) .bp-thumbnail-nav{background:#e8e8e8 url(assets/loading_ghost.gif) repeat-y;background-size:100% 100%}.bp .bp-thumbnail-nav{flex:0 0 150px;overflow:hidden;background-color:#d8d8d8;border-radius:6px;box-shadow:0 0 0 1px #e8e8e8,0 1px 4px 0 rgba(0,0,0,.08);transition:box-shadow .2s ease-in-out}.bp .bp-thumbnail-page-number{position:absolute;display:flex;align-items:center;justify-content:center;min-width:28px;height:24px;padding-right:3px;padding-left:3px;color:#fff;font-size:13px;border-radius:3px 0 6px 0;box-shadow:1px 1px 2px 0 rgba(0,0,0,.2);opacity:0}.bp .bp-thumbnail-image{background-repeat:no-repeat;background-position:center;background-size:contain;pointer-events:none}.bp .bp-thumbnails-container--dark{background-color:#444;border-right-color:#000}.bp .bp-thumbnails-container--dark .bp-thumbnail-page-number{background-color:#444}.bp .bp-thumbnails-container--dark .bp-thumbnail-nav{border-color:#444}@keyframes bp-thumbnails-open{0%{display:none;transform:translateX(-191px)}1%{display:flex;transform:translateX(-191px)}100%{transform:translateX(0)}}@media(min-width: 768px){.bp.bp-loaded.bp-thumbnails-open-active .bp-content,.bp.bp-loaded.bp-thumbnails-close-active .bp-content{transition:left 300ms cubic-bezier(0.4, 0, 0.2, 1)}.bp .bp-thumbnails-container{display:none;transition:transform 300ms cubic-bezier(0.4, 0, 0.2, 1)}.bp .bp-thumbnails-container,.bp.bp-thumbnails-close .bp-thumbnails-container,.bp.bp-thumbnails-close-active .bp-thumbnails-container{transform:translateX(-191px)}.bp.bp-thumbnails-close .bp-thumbnails-container{display:none}.bp.bp-thumbnails-close-active .bp-thumbnails-container{display:flex}.bp.bp-thumbnails-open .bp-content{left:191px}.bp.bp-thumbnails-open .bp-content.bp-is-fullscreen{left:0}.bp.bp-thumbnails-open .bp-thumbnails-container{display:flex;transform:translateX(0)}.bp.bp-thumbnails-open-active .bp-thumbnails-container{animation:bp-thumbnails-open 300ms cubic-bezier(0.4, 0, 0.2, 1)}.bp .bp-ThumbnailsToggle{display:flex}}@media(max-width: 767px){.bp-is-mobile .bp-ZoomControls{display:none}}.bp-theme-dark .bp .bp-thumbnails-container{border-right-color:#222}.bp-doc{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;margin:0;overflow:hidden;letter-spacing:normal;-webkit-user-select:none;user-select:none;-webkit-tap-highlight-color:transparent}.bp-doc [hidden]{display:none !important}.bp-doc.bp-is-scrollable{overflow:auto}.bp-doc .pdfViewer.pinching{visibility:hidden}.bp-doc .pdfViewer .page{position:relative;display:block;box-sizing:content-box !important;margin:0 auto;padding:15px 0;overflow:visible;border:0;border-image:none}.bp-doc .pdfViewer .page:not(.bp-is-invisible)::before{box-shadow:0 4px 12px 0 rgba(0,0,0,.1);position:absolute;top:15px;right:0;bottom:15px;left:0;display:block;content:""}.bp-doc .pdfViewer .page:not(.bp-is-invisible) .loadingIcon:first-child{background:#e8e8e8 url(assets/loading_ghost.gif) repeat-y;background-size:100% 100%}.bp-doc .pdfViewer .page .loadingIcon{top:15px;bottom:15px;background:none}.bp-doc .pdfViewer .page.loadingIcon::after{top:15px;bottom:15px;background:none}.bp-doc .pdfViewer .page .textAnnotation>img{opacity:0}.bp-doc .pdfViewer .page.pinch-page{padding:0;visibility:visible}.bp-doc .pdfViewer .page.pinch-page .textLayer{display:none}.bp-doc .pdfViewer.pdfViewer--viewOnly .textLayer span{cursor:unset;-webkit-user-select:none;user-select:none}.bp-doc .textLayer{top:15px;bottom:auto;z-index:1;opacity:1;caret-color:#000}.bp-doc .textLayer>div{-webkit-user-select:text;user-select:text}.bp-doc .textLayer .highlight{display:inline-block;background-color:rgba(180,0,170,.2)}.bp-doc .textLayer .highlight.selected{background-color:rgba(0,100,0,.2)}.bp-doc .textLayer .rangy-highlight{opacity:.2}.bp-doc .textLayer ::selection{background-color:rgba(0,97,213,.1)}.bp-doc input,.bp-doc p,.bp-doc span{-webkit-user-select:text;user-select:text}.bp-doc .annotationLayer h1,.bp-doc .annotationLayer h2,.bp-doc .annotationLayer h3,.bp-doc .annotationLayer h4,.bp-doc .annotationLayer h5,.bp-doc .annotationLayer h6,.bp-doc .annotationLayer p{margin:0}.bp-doc .annotationLayer h1{font-size:1em}.bp-doc .annotationLayer section{margin-top:15px}.bp-doc .annotationLayer .popup{font-size:inherit}.bp-doc .annotationLayer .popup .header{height:unset;padding:unset !important;background-color:unset}.bp-print-notification{display:none;font-size:24px}@media print{.bp-doc{display:none}.bp-print-notification{display:block}}.bp-content.bp-annotations-discoverable .ba-PopupCursor{display:none}.bp-content.bp-annotations-discoverable .textLayer{pointer-events:none}.bp-content.bp-annotations-discoverable .textLayer span{pointer-events:auto}@media(max-width: 767px){.bp-content.bp-annotations-only-controls.bp-annotations-create--drawing .bp-AnnotationsControls-exitBtn,.bp-content.bp-annotations-only-controls.bp-annotations-create--highlight .bp-AnnotationsControls-exitBtn,.bp-content.bp-annotations-only-controls.bp-annotations-create--region .bp-AnnotationsControls-exitBtn{display:block}.bp-content.bp-annotations-only-controls.bp-annotations-create--drawing .bp-ControlsBarGroup:not(:last-child),.bp-content.bp-annotations-only-controls.bp-annotations-create--drawing .bp-ControlsBarGroup>*:not(.bp-AnnotationsControls),.bp-content.bp-annotations-only-controls.bp-annotations-create--highlight .bp-ControlsBarGroup:not(:last-child),.bp-content.bp-annotations-only-controls.bp-annotations-create--highlight .bp-ControlsBarGroup>*:not(.bp-AnnotationsControls),.bp-content.bp-annotations-only-controls.bp-annotations-create--region .bp-ControlsBarGroup:not(:last-child),.bp-content.bp-annotations-only-controls.bp-annotations-create--region .bp-ControlsBarGroup>*:not(.bp-AnnotationsControls){display:none}}.bp-content.bp-annotations-create--highlight .ba-PopupCursor,.bp-content.bp-annotations-create--region .ba-PopupCursor{display:block}.bp-content.bp-annotations-create--highlight .annotationLayer,.bp-content.bp-annotations-create--region .annotationLayer{pointer-events:none}.bp-content.bp-annotations-create--highlight .ba-DrawingAnnotations-list.is-listening .ba-DrawingTarget,.bp-content.bp-annotations-create--region .ba-DrawingAnnotations-list.is-listening .ba-DrawingTarget{pointer-events:none}.bp-content.bp-annotations-create--highlight .ba-HighlightList .ba-HighlightSvg.is-listening .ba-HighlightTarget-rect,.bp-content.bp-annotations-create--region .ba-HighlightList .ba-HighlightSvg.is-listening .ba-HighlightTarget-rect{pointer-events:none}.bp-content.bp-annotations-create--highlight .ba-RegionAnnotations-list.is-listening .ba-RegionAnnotation,.bp-content.bp-annotations-create--region .ba-RegionAnnotations-list.is-listening .ba-RegionAnnotation{pointer-events:none}.bp-content.bp-annotations-create--region.bp-annotations-ftux-document-cursor-seen .ba-PopupCursor{display:none}.bp-content.bp-annotations-create--region .textLayer,.bp-content.bp-annotations-create--region .textLayer span{pointer-events:none}.bp-content.bp-is-fullscreen .bp-ThumbnailsToggle{display:none}.bp-find-bar{position:absolute;top:0;right:17px;z-index:3;display:flex;align-items:center;padding:6px;font-size:12px;font-family:Lato,"Helvetica Neue",Helvetica,Arial,sans-serif;background:#fff;border:1px solid #e8e8e8}.bp-find-bar ::-ms-clear{display:none}.bp-find-bar .bp-doc-find-field{width:200px;height:34px;padding:6px 6px 6px 25px;color:#494949;line-height:20px;border:1px solid #e8e8e8;border-radius:2px 0 0 2px;outline-style:none;transition-timing-function:ease;transition-duration:150ms;transition-property:border-color}.bp-find-bar .bp-doc-find-field:focus,.bp-find-bar .bp-doc-find-field:hover{border-color:#0061d5}.bp-find-bar .bp-doc-find-results-count{position:absolute;top:37%;right:120px;margin:0;padding:0;color:rgba(73,73,73,.25);line-height:1;text-align:right;cursor:default;-webkit-user-select:none;user-select:none}.bp-find-bar .bp-doc-find-search,.bp-find-bar .bp-doc-find-prev,.bp-find-bar .bp-doc-find-next,.bp-find-bar .bp-doc-find-close{display:flex;align-items:center;justify-content:center;width:34px;height:34px;padding:0;line-height:1;vertical-align:middle;background:none;border:1px solid #e8e8e8;border-left:0;cursor:pointer}.bp-find-bar .bp-doc-find-search svg,.bp-find-bar .bp-doc-find-prev svg,.bp-find-bar .bp-doc-find-next svg,.bp-find-bar .bp-doc-find-close svg{width:17px}.bp-find-bar .bp-doc-find-search .icon,.bp-find-bar .bp-doc-find-prev .icon,.bp-find-bar .bp-doc-find-next .icon,.bp-find-bar .bp-doc-find-close .icon{fill:rgba(73,73,73,.75)}.bp-find-bar .bp-doc-find-prev:hover .icon,.bp-find-bar .bp-doc-find-next:hover .icon,.bp-find-bar .bp-doc-find-close:hover .icon{fill:#494949}.bp-find-bar .bp-doc-find-search{position:absolute;top:15%;left:5px;margin:0;line-height:1;text-align:left;border:0;pointer-events:none}.bp-find-bar .bp-doc-find-search svg{width:12px;height:12px}.bp-find-bar .bp-doc-find-close{border:0}.bp-find-bar .bp-doc-find-close svg{width:22px}.bp-find-bar .bp-find-match-not-found,.bp-find-bar .bp-find-match-not-found:hover,.bp-find-bar .bp-find-match-not-found:focus{border-color:rgba(239,72,54,.5)}.bp-find-bar .bp-doc-find-controls{display:flex}.bp-doc.bp-doc-presentation{overflow:hidden}.bp-doc.bp-doc-presentation .pdfViewer .page{position:absolute;top:0;right:0;bottom:0;left:0;margin:auto}.bp-doc.bp-doc-presentation .pdfViewer .page.bp-is-invisible{opacity:0}.bp-doc.bp-doc-presentation.overflow-x{overflow-x:scroll}.bp-doc.bp-doc-presentation.overflow-y{overflow-y:scroll}.bp-doc.bp-doc-presentation.overflow-y .pdfViewer .page{margin-top:5px}.bp-presentation-preload-wrapper{position:absolute;top:0;right:0;bottom:0;left:0;align-content:center;margin:0;background-color:#f5f5f5;transition:opacity .5s}.bp-presentation-preload-wrapper.bp-is-invisible{visibility:hidden}.bp-presentation-preload-wrapper.bp-is-transparent{opacity:0}.bp-theme-dark .bp-presentation-preload-wrapper{background-color:#464a4f}.bp-presentation-preload-wrapper .bp-preload-content,.bp-presentation-preload-wrapper .bp-preload-overlay,.bp-presentation-preload-wrapper .bp-preload-placeholder::before{position:absolute;top:0;right:0;bottom:0;left:0}.bp-presentation-preload-wrapper .bp-preload-content{width:100%}.bp-presentation-preload-wrapper .bp-preload-overlay{background-color:rgba(255,255,255,.4)}.bp-presentation-preload-wrapper .bp-preload-placeholder{background:#e8e8e8 url(assets/loading_ghost.gif) repeat-y;background-size:100% 100%;box-shadow:0 4px 12px 0 rgba(0,0,0,.1);position:relative;margin:auto;padding-top:5px}.bp-presentation-preload-wrapper .bp-preload-placeholder img.doc-first-image{width:100%;height:100%}.bp-presentation-preload-wrapper .bp-preload-placeholder img.loaded{visibility:visible}
86
86
  .bp-AnimationClipsToggle{opacity:.9;transition:opacity 150ms,background-color 150ms;will-change:opacity;outline:0;display:flex;align-items:center;justify-content:center;margin:0;padding:0;color:#fff;background:transparent;border:0;border-radius:25px;cursor:pointer;-webkit-user-select:none;user-select:none;touch-action:manipulation;zoom:1}.bp-AnimationClipsToggle:focus:not(:disabled),.bp-AnimationClipsToggle:hover:not(:disabled){background-color:rgba(255,255,255,.08);opacity:1}.bp-AnimationClipsToggle:focus:not(:disabled) svg,.bp-AnimationClipsToggle:hover:not(:disabled) svg,.bp-AnimationClipsToggle.bp-is-active svg{transform:scale(1.09);transition:transform 150ms}.bp-AnimationClipsToggle.bp-is-active,.bp-AnimationClipsToggle:active:not(:disabled){background-color:rgba(255,255,255,.16)}.bp-AnimationClipsToggle.bp-is-active:focus:not(:disabled),.bp-AnimationClipsToggle.bp-is-active:hover:not(:disabled){background-color:rgba(255,255,255,.2)}.bp-AnimationClipsToggle:focus:not(:disabled){box-shadow:inset 0 0 0 1px rgba(211,211,211,.5),0 1px 2px rgba(0,0,0,.1)}.bp-AnimationClipsToggle:focus-visible:not(:disabled){box-shadow:inset 0 0 0 1px rgba(211,211,211,.5),0 1px 2px rgba(0,0,0,.1)}.bp-AnimationClipsToggle:focus:not(:focus-visible){box-shadow:none}.bp-AnimationClipsToggle:disabled{cursor:default;opacity:.2;pointer-events:none}.bp-AnimationClipsToggle svg{width:32px;height:32px;padding:5px}
package/dist/lib/index.js CHANGED
@@ -9340,7 +9340,7 @@ function util_toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var
9340
9340
  const CLIENT_NAME = "box-content-preview"; // eslint-disable-line no-undef
9341
9341
  const CLIENT_NAME_KEY = 'box_client_name';
9342
9342
  const CLIENT_VERSION_KEY = 'box_client_version';
9343
- const CLIENT_VERSION = "3.54.0"; // eslint-disable-line no-undef
9343
+ const CLIENT_VERSION = "3.55.0"; // eslint-disable-line no-undef
9344
9344
  const HEADER_CLIENT_NAME = 'X-Box-Client-Name';
9345
9345
  const HEADER_CLIENT_VERSION = 'X-Box-Client-Version';
9346
9346
  const PROMISE_MAP = {};
@@ -11065,7 +11065,7 @@ class Browser {
11065
11065
  ;// ./src/lib/Logger.js
11066
11066
  /* eslint-disable no-undef */
11067
11067
  const Logger_CLIENT_NAME = "box-content-preview";
11068
- const Logger_CLIENT_VERSION = "3.54.0";
11068
+ const Logger_CLIENT_VERSION = "3.55.0";
11069
11069
  /* eslint-enable no-undef */
11070
11070
 
11071
11071
  class Logger {
@@ -30641,12 +30641,7 @@ function DocControls(_ref) {
30641
30641
  } = _ref;
30642
30642
  return /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ExperiencesProvider, {
30643
30643
  experiences: experiences
30644
- }, isGalleryOpen ? /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ControlsBar, null, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ControlsBarGroup, null, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(GalleryToggle, {
30645
- isGalleryOpen: isGalleryOpen,
30646
- onGalleryToggle: onGalleryToggle
30647
- }), /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(FullscreenToggle, {
30648
- onFullscreenToggle: onFullscreenToggle
30649
- }))) : /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(__WEBPACK_EXTERNAL_MODULE_react_default__.Fragment, null, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ControlsBar, null, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ControlsBarGroup, null, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ThumbnailsToggle, {
30644
+ }, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ControlsBar, null, !isGalleryOpen && /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(__WEBPACK_EXTERNAL_MODULE_react_default__.Fragment, null, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ControlsBarGroup, null, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ThumbnailsToggle, {
30650
30645
  isThumbnailsOpen: isThumbnailsOpen,
30651
30646
  onThumbnailsToggle: onThumbnailsToggle
30652
30647
  }), /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(FindBarToggle, {
@@ -30668,12 +30663,12 @@ function DocControls(_ref) {
30668
30663
  scale: scale
30669
30664
  })), onRotateLeft && /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ControlsBarGroup, null, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(RotateControl, {
30670
30665
  onRotateLeft: onRotateLeft
30671
- })), /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ControlsBarGroup, null, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(GalleryToggle, {
30666
+ }))), /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ControlsBarGroup, null, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(GalleryToggle, {
30672
30667
  isGalleryOpen: isGalleryOpen,
30673
30668
  onGalleryToggle: onGalleryToggle
30674
30669
  }), /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(FullscreenToggle, {
30675
30670
  onFullscreenToggle: onFullscreenToggle
30676
- }), /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(AnnotationsControls, {
30671
+ }), !isGalleryOpen && /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(AnnotationsControls, {
30677
30672
  annotationColor: annotationColor,
30678
30673
  annotationMode: annotationMode,
30679
30674
  hasDrawing: hasDrawing,
@@ -30681,11 +30676,11 @@ function DocControls(_ref) {
30681
30676
  hasRegion: hasRegion,
30682
30677
  onAnnotationModeClick: onAnnotationModeClick,
30683
30678
  onAnnotationModeEscape: onAnnotationModeEscape
30684
- }))), /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ControlsBar, null, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(DrawingControls, {
30679
+ }))), !isGalleryOpen && /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(ControlsBar, null, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(DrawingControls, {
30685
30680
  annotationColor: annotationColor,
30686
30681
  annotationMode: annotationMode,
30687
30682
  onAnnotationColorChange: onAnnotationColorChange
30688
- }))));
30683
+ })));
30689
30684
  }
30690
30685
  ;// ./src/lib/icons/search.svg
30691
30686
  const search_namespaceObject = "<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"18\" height=\"18\" viewBox=\"0 0 15 14\" focusable=\"false\">\n <g fill=\"none\" fill-rule=\"evenodd\">\n <path d=\"M-2-3h20v20H-2z\"/>\n <path class=\"icon\" fill=\"#FFF\" d=\"M6.931 0a5.994 5.994 0 0 1 4.907 9.438l2.806 2.807a1 1 0 0 1 0 1.415l-.047.047a1 1 0 0 1-1.414 0L10.375 10.9A5.994 5.994 0 1 1 6.931 0zm0 1.998a3.996 3.996 0 1 0 0 7.992 3.996 3.996 0 0 0 0-7.992z\"/>\n </g>\n</svg>\n";
@@ -31574,11 +31569,42 @@ function GalleryGrid_toPrimitive(t, r) { if ("object" != typeof t || !t) return
31574
31569
 
31575
31570
 
31576
31571
 
31572
+
31577
31573
  const GALLERY_THUMB_MAX_WIDTH = 440;
31578
31574
  const INITIAL_LOAD_BUFFER = 40;
31579
31575
  const CONCURRENT_LOADS = 4;
31580
31576
  const SCROLL_THROTTLE_MS = 200;
31581
- function GalleryGrid(_ref) {
31577
+ const GalleryTile = /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.memo(function GalleryTile(_ref) {
31578
+ let {
31579
+ pageNum,
31580
+ isFocused,
31581
+ imageSrc,
31582
+ onClick,
31583
+ onFocus
31584
+ } = _ref;
31585
+ return (
31586
+ /*#__PURE__*/
31587
+ // eslint-disable-next-line jsx-a11y/click-events-have-key-events
31588
+ __WEBPACK_EXTERNAL_MODULE_react_default__.createElement("div", {
31589
+ "aria-label": replacePlaceholders("Page {1}", [String(pageNum)]),
31590
+ "aria-selected": isFocused,
31591
+ className: `bp-gallery-tile${isFocused ? ' bp-gallery-tile--selected' : ''}`,
31592
+ "data-page": pageNum,
31593
+ onClick: () => onClick(pageNum),
31594
+ onFocus: () => onFocus(pageNum),
31595
+ role: "option",
31596
+ tabIndex: isFocused ? 0 : -1
31597
+ }, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement("span", {
31598
+ className: "bp-gallery-tile-badge"
31599
+ }, pageNum), imageSrc ? /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement("img", {
31600
+ alt: "",
31601
+ src: imageSrc
31602
+ }) : /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement("span", {
31603
+ className: "bp-gallery-tile-placeholder"
31604
+ }))
31605
+ );
31606
+ });
31607
+ function GalleryGrid(_ref2) {
31582
31608
  let {
31583
31609
  pageCount,
31584
31610
  currentPage,
@@ -31586,7 +31612,7 @@ function GalleryGrid(_ref) {
31586
31612
  onFocusChange,
31587
31613
  onPageNavigate,
31588
31614
  thumbnail
31589
- } = _ref;
31615
+ } = _ref2;
31590
31616
  const [loadedImages, setLoadedImages] = __WEBPACK_EXTERNAL_MODULE_react_useState__({});
31591
31617
  const [focusedPage, setFocusedPage] = __WEBPACK_EXTERNAL_MODULE_react_useState__(currentPage);
31592
31618
  const gridRef = __WEBPACK_EXTERNAL_MODULE_react_useRef__(null);
@@ -31722,72 +31748,88 @@ function GalleryGrid(_ref) {
31722
31748
  };
31723
31749
  // eslint-disable-next-line react-hooks/exhaustive-deps
31724
31750
  }, []);
31751
+ const focusTile = __WEBPACK_EXTERNAL_MODULE_react_useCallback__(pageNum => {
31752
+ const grid = gridRef.current;
31753
+ if (!grid) return;
31754
+ const tile = grid.querySelector(`[data-page="${pageNum}"]`);
31755
+ if (tile) {
31756
+ tile.focus();
31757
+ }
31758
+ }, []);
31725
31759
  const handleTileFocus = __WEBPACK_EXTERNAL_MODULE_react_useCallback__(pageNum => {
31726
31760
  setFocusedPage(pageNum);
31727
31761
  if (onFocusChange) {
31728
31762
  onFocusChange(pageNum);
31729
31763
  }
31730
31764
  }, [onFocusChange]);
31765
+ const handleTileClick = __WEBPACK_EXTERNAL_MODULE_react_useCallback__(pageNum => {
31766
+ onPageNavigate(pageNum);
31767
+ }, [onPageNavigate]);
31731
31768
  const handleGridFocus = __WEBPACK_EXTERNAL_MODULE_react_useCallback__(event => {
31732
- if (event.target === gridRef.current && gridRef.current) {
31733
- const tile = gridRef.current.querySelector(`[data-page="${focusedPage}"]`);
31734
- if (tile) {
31735
- tile.focus();
31736
- }
31769
+ if (event.target === gridRef.current) {
31770
+ focusTile(focusedPage);
31737
31771
  }
31738
- }, [focusedPage]);
31772
+ }, [focusedPage, focusTile]);
31739
31773
  const handleGridKeyDown = __WEBPACK_EXTERNAL_MODULE_react_useCallback__(event => {
31740
- if (event.key === 'Escape') {
31741
- event.preventDefault();
31742
- event.stopPropagation();
31743
- onClose();
31744
- return;
31745
- }
31746
- if (event.key === 'Tab' && gridRef.current) {
31747
- const buttons = gridRef.current.querySelectorAll('button');
31748
- const first = buttons[0];
31749
- const last = buttons[buttons.length - 1];
31750
- if (event.shiftKey && document.activeElement === first) {
31774
+ const key = decodeKeydown(event);
31775
+ switch (key) {
31776
+ case 'Escape':
31751
31777
  event.preventDefault();
31752
- last.focus();
31753
- } else if (!event.shiftKey && document.activeElement === last) {
31778
+ event.stopPropagation();
31779
+ onClose();
31780
+ return;
31781
+ // Listbox is 1-D — arrows move ±1; row-aware nav comes with v2 grid role.
31782
+ case 'ArrowUp':
31783
+ case 'ArrowLeft':
31784
+ if (focusedPage > 1) {
31785
+ event.preventDefault();
31786
+ focusTile(focusedPage - 1);
31787
+ }
31788
+ return;
31789
+ case 'ArrowDown':
31790
+ case 'ArrowRight':
31791
+ if (focusedPage < pageCount) {
31792
+ event.preventDefault();
31793
+ focusTile(focusedPage + 1);
31794
+ }
31795
+ return;
31796
+ case 'Home':
31754
31797
  event.preventDefault();
31755
- first.focus();
31756
- }
31798
+ focusTile(1);
31799
+ return;
31800
+ case 'End':
31801
+ event.preventDefault();
31802
+ focusTile(pageCount);
31803
+ return;
31804
+ case 'Enter':
31805
+ case 'Space':
31806
+ event.preventDefault();
31807
+ onPageNavigate(focusedPage);
31808
+ break;
31809
+ default:
31757
31810
  }
31758
- }, [onClose]);
31811
+ }, [focusedPage, focusTile, onClose, onPageNavigate, pageCount]);
31759
31812
  const tiles = [];
31760
31813
  for (let i = 1; i <= pageCount; i += 1) {
31761
- const isFocused = i === focusedPage;
31762
- tiles.push( /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement("button", {
31814
+ tiles.push( /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement(GalleryTile, {
31763
31815
  key: i,
31764
- "aria-label": `Page ${i}${isFocused ? ', current page' : ''}`,
31765
- className: `bp-gallery-tile${isFocused ? ' bp-gallery-tile--selected' : ''}`,
31766
- "data-page": i,
31767
- onClick: () => onPageNavigate(i),
31768
- onFocus: () => handleTileFocus(i),
31769
- type: "button"
31770
- }, /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement("span", {
31771
- className: "bp-gallery-tile-badge"
31772
- }, i), loadedImages[i] ? /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement("img", {
31773
- alt: `Page ${i}`,
31774
- src: loadedImages[i]
31775
- }) : /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement("span", {
31776
- className: "bp-gallery-tile-placeholder"
31777
- })));
31816
+ imageSrc: loadedImages[i],
31817
+ isFocused: i === focusedPage,
31818
+ onClick: handleTileClick,
31819
+ onFocus: handleTileFocus,
31820
+ pageNum: i
31821
+ }));
31778
31822
  }
31779
- return (
31780
- /*#__PURE__*/
31781
- // eslint-disable-next-line jsx-a11y/no-static-element-interactions
31782
- __WEBPACK_EXTERNAL_MODULE_react_default__.createElement("div", {
31783
- ref: gridRef,
31784
- className: "bp-gallery-grid",
31785
- onFocus: handleGridFocus,
31786
- onKeyDown: handleGridKeyDown,
31787
- onScroll: handleScrollRef.current,
31788
- tabIndex: -1
31789
- }, tiles)
31790
- );
31823
+ return /*#__PURE__*/__WEBPACK_EXTERNAL_MODULE_react_default__.createElement("div", {
31824
+ ref: gridRef,
31825
+ "aria-label": "Page gallery",
31826
+ className: "bp-gallery-grid",
31827
+ onFocus: handleGridFocus,
31828
+ onKeyDown: handleGridKeyDown,
31829
+ onScroll: handleScrollRef.current,
31830
+ role: "listbox",
31831
+ tabIndex: -1
31832
+ }, tiles);
31791
31833
  }
31792
31834
  ;// ./src/lib/viewers/gallery/GalleryController.tsx
31793
31835
  function GalleryController_defineProperty(e, r, t) { return (r = GalleryController_toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
@@ -31825,6 +31867,9 @@ class GalleryController {
31825
31867
  GalleryController_defineProperty(this, "setPage", void 0);
31826
31868
  GalleryController_defineProperty(this, "toggleThumbnails", void 0);
31827
31869
  GalleryController_defineProperty(this, "requestUiUpdate", void 0);
31870
+ GalleryController_defineProperty(this, "focusToggle", void 0);
31871
+ GalleryController_defineProperty(this, "onBeforeOpen", void 0);
31872
+ GalleryController_defineProperty(this, "onAfterClose", void 0);
31828
31873
  GalleryController_defineProperty(this, "galleryRoot", null);
31829
31874
  GalleryController_defineProperty(this, "galleryEl", null);
31830
31875
  GalleryController_defineProperty(this, "galleryThumbnail", null);
@@ -31836,6 +31881,7 @@ class GalleryController {
31836
31881
  GalleryController_defineProperty(this, "toggle", () => {
31837
31882
  this.isGalleryOpen = !this.isGalleryOpen;
31838
31883
  if (this.isGalleryOpen) {
31884
+ this.onBeforeOpen();
31839
31885
  if (this.gallerySidebarTimeoutId !== null) {
31840
31886
  clearTimeout(this.gallerySidebarTimeoutId);
31841
31887
  this.gallerySidebarTimeoutId = null;
@@ -31882,6 +31928,10 @@ class GalleryController {
31882
31928
  }
31883
31929
  }
31884
31930
  this.requestUiUpdate();
31931
+ if (!this.isGalleryOpen) {
31932
+ this.onAfterClose();
31933
+ this.focusToggle();
31934
+ }
31885
31935
  });
31886
31936
  GalleryController_defineProperty(this, "handleGalleryNavigate", pageNum => {
31887
31937
  this.galleryFocusedPage = pageNum;
@@ -31898,6 +31948,9 @@ class GalleryController {
31898
31948
  this.setPage = opts.setPage;
31899
31949
  this.toggleThumbnails = opts.toggleThumbnails;
31900
31950
  this.requestUiUpdate = opts.requestUiUpdate;
31951
+ this.focusToggle = opts.focusToggle;
31952
+ this.onBeforeOpen = opts.onBeforeOpen;
31953
+ this.onAfterClose = opts.onAfterClose;
31901
31954
  }
31902
31955
  get isOpen() {
31903
31956
  return this.isGalleryOpen;
@@ -33500,7 +33553,15 @@ class DocBaseViewer extends viewers_BaseViewer {
33500
33553
  getThumbnailsSidebar: () => this.thumbnailsSidebar,
33501
33554
  setPage: n => this.setPage(n),
33502
33555
  toggleThumbnails: () => this.toggleThumbnails(),
33503
- requestUiUpdate: () => this.renderUI()
33556
+ requestUiUpdate: () => this.renderUI(),
33557
+ focusToggle: () => {
33558
+ const toggle = this.containerEl.querySelector('.bp-GalleryToggle');
33559
+ if (toggle && toggle.focus) {
33560
+ toggle.focus();
33561
+ }
33562
+ },
33563
+ onBeforeOpen: () => this.handleGalleryEnter(),
33564
+ onAfterClose: () => this.handleGalleryExit()
33504
33565
  });
33505
33566
  }
33506
33567
 
@@ -35163,6 +35224,34 @@ class DocBaseViewer extends viewers_BaseViewer {
35163
35224
  this.findBar.toggle();
35164
35225
  }
35165
35226
 
35227
+ /**
35228
+ * Called before the gallery opens. Closes the find bar and resets annotation mode.
35229
+ *
35230
+ * @protected
35231
+ * @return {void}
35232
+ */
35233
+ handleGalleryEnter() {
35234
+ if (this.findBar) {
35235
+ this.findBar.close();
35236
+ }
35237
+ this.processAnnotationModeChange(this.annotationControlsFSM.transition(AnnotationInput.RESET));
35238
+ if (this.annotator) {
35239
+ this.annotator.toggleAnnotationMode(AnnotationMode.NONE);
35240
+ }
35241
+ }
35242
+
35243
+ /**
35244
+ * Called after the gallery closes. Restores REGION mode so the region-comment cursor is active.
35245
+ *
35246
+ * @protected
35247
+ * @return {void}
35248
+ */
35249
+ handleGalleryExit() {
35250
+ if (this.annotator && this.areNewAnnotationsEnabled()) {
35251
+ this.annotator.toggleAnnotationMode(AnnotationMode.REGION);
35252
+ }
35253
+ }
35254
+
35166
35255
  /**
35167
35256
  * Callback when the toggle thumbnail sidebar button is clicked.
35168
35257
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "box-content-preview",
3
- "version": "3.54.0",
3
+ "version": "3.55.0",
4
4
  "description": "Box Content Preview UI Element",
5
5
  "author": "Box (https://www.box.com/)",
6
6
  "license": "SEE LICENSE IN LICENSE",