Undo BringLayerToFrontFn: put a regular layer's zIndex back to the
value it was opened with (Layer.initialZIndex) and re-sort
allLayers. The layer object is replaced via spread — elements,
regionFocus, hostPage and crossPage references are kept, so element
components do not remount.
No-op when the layer's zIndex already equals its initial value. Modal
layers are unaffected, mirroring BringLayerToFrontFn.
Undo BringLayerToFrontFn: put a regular layer's zIndex back to the value it was opened with (Layer.initialZIndex) and re-sort
allLayers. The layer object is replaced via spread —elements,regionFocus,hostPageandcrossPagereferences are kept, so element components do not remount.No-op when the layer's zIndex already equals its initial value. Modal layers are unaffected, mirroring BringLayerToFrontFn.