[PDFSidebarResizer] Skip the CSS.supports
checks for MOZCENTRAL builds
Since CSS variable support cannot be disabled any more in Firefox, the run-time checks are of no using for MOZCENTRAL builds.
This commit is contained in:
parent
4ae3f9fcf6
commit
c1cfe2881b
@ -47,8 +47,10 @@ class PDFSidebarResizer {
|
|||||||
this.eventBus = eventBus;
|
this.eventBus = eventBus;
|
||||||
this.l10n = l10n;
|
this.l10n = l10n;
|
||||||
|
|
||||||
if (typeof CSS === 'undefined' || typeof CSS.supports !== 'function' ||
|
if ((typeof PDFJSDev === 'undefined' || !PDFJSDev.test('MOZCENTRAL')) &&
|
||||||
!CSS.supports(SIDEBAR_WIDTH_VAR, `calc(-1 * ${SIDEBAR_MIN_WIDTH}px)`)) {
|
(typeof CSS === 'undefined' || typeof CSS.supports !== 'function' ||
|
||||||
|
!CSS.supports(SIDEBAR_WIDTH_VAR,
|
||||||
|
`calc(-1 * ${SIDEBAR_MIN_WIDTH}px)`))) {
|
||||||
console.warn('PDFSidebarResizer: ' +
|
console.warn('PDFSidebarResizer: ' +
|
||||||
'The browser does not support resizing of the sidebar.');
|
'The browser does not support resizing of the sidebar.');
|
||||||
return;
|
return;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user