MCPcopy Create free account
hub / github.com/ionic-team/ionic-framework / setZIndex

Function setZIndex

core/src/utils/transition/index.ts:285–296  ·  view source on GitHub ↗
(
  enteringEl: HTMLElement | undefined,
  leavingEl: HTMLElement | undefined,
  direction: NavDirection | undefined
)

Source from the content-addressed store, hash-verified

283};
284
285const setZIndex = (
286 enteringEl: HTMLElement | undefined,
287 leavingEl: HTMLElement | undefined,
288 direction: NavDirection | undefined
289) => {
290 if (enteringEl !== undefined) {
291 enteringEl.style.zIndex = direction === 'back' ? '99' : '101';
292 }
293 if (leavingEl !== undefined) {
294 leavingEl.style.zIndex = '100';
295 }
296};
297
298/**
299 * Add a class to ensure that the header (if any)

Callers 1

beforeTransitionFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected