mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-11-09 16:16:41 +08:00
fix(prerender): local references to window/document
This commit is contained in:
@ -43,8 +43,8 @@ export type Side = 'start' | 'end';
|
||||
* @param side the side
|
||||
* @param isRTL whether the application dir is rtl
|
||||
*/
|
||||
export function isRightSide(side: Side): boolean {
|
||||
const isRTL = document.dir === 'rtl';
|
||||
export function isRightSide(win: Window, side: Side): boolean {
|
||||
const isRTL = win.document.dir === 'rtl';
|
||||
switch (side) {
|
||||
case 'start': return isRTL;
|
||||
case 'end': return !isRTL;
|
||||
|
||||
Reference in New Issue
Block a user