Namespace: ThumbnailsPanel

UI. ThumbnailsPanel

Methods


<static> disableMultiselect()

Disable multi select in the left thumbnail panel
Example
WebViewer(...)
  .then(function(instance) {
    instance.UI.ThumbnailsPanel.disableMultiselect();
  });

<static> enableMultiselect()

Enable multi select in the left thumbnail panel
Example
WebViewer(...)
  .then(function(instance) {
    instance.UI.ThumbnailsPanel.enableMultiselect();
  });

<static> getSelectedPageNumbers()

Get the currently selected pages
Returns:
an array of select page numbers
Type
Array.<number>
Example
WebViewer(...)
  .then(function(instance) {
    instance.UI.ThumbnailsPanel.getSelectedPageNumbers();
  });

<static> selectPages(pageNumbers)

Select thumbnails in the thumbnail panel. This requires the "ThumbnailMultiselect" feature to be enabled
Parameters:
Name Type Description
pageNumbers Array.<number> array of page numbers to select
Example
WebViewer(...)
  .then(function(instance) {
    instance.UI.enableFeatures(['ThumbnailMultiselect']);

    const pageNumbersToSelect = [1, 2, 3];
    instance.UI.ThumbnailsPanel.selectPages(pageNumbersToSelect);
  });

<static> unselectPages(pageNumbers)

Unselect selected thumbnails
Parameters:
Name Type Description
pageNumbers Array.<number> array of page numbers to unselect
Example
WebViewer(...)
  .then(function(instance) {
    const pageNumbersToUnselect = [1, 2];
    instance.UI.ThumbnailsPanel.unselectPages(pageNumbersToUnselect);
  });