Skip to content

Commit c55401e

Browse files
committed
update swapFunctions
1 parent cfabcb0 commit c55401e

File tree

3 files changed

+84
-251
lines changed

3 files changed

+84
-251
lines changed

components/swap-functions.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,13 @@ const shouldCopyProps = (el) => {
8686
const persistProps = el.dataset.astroTransitionPersistProps;
8787
return persistProps == null || persistProps === "false";
8888
};
89+
const swapFunctions = {
90+
deselectScripts,
91+
swapRootAttributes,
92+
swapHeadElements,
93+
swapBodyElement,
94+
saveFocus
95+
};
8996
const swap = (doc) => {
9097
deselectScripts(doc);
9198
swapRootAttributes(doc);
@@ -100,6 +107,7 @@ export {
100107
saveFocus,
101108
swap,
102109
swapBodyElement,
110+
swapFunctions,
103111
swapHeadElements,
104112
swapRootAttributes
105113
};

0 commit comments

Comments
 (0)