diff options
author | kaotisk <kaotisk@arching-kaos.org> | 2024-11-29 16:23:39 +0200 |
---|---|---|
committer | kaotisk <kaotisk@arching-kaos.org> | 2024-11-29 16:23:39 +0200 |
commit | afcedd44615d20423d58f4d9c9d8cfa3838a54d4 (patch) | |
tree | e16cd7f2eb4040f7b237baa45aa3f8f80516dcc4 /src/js/ui/mainLayout.js | |
parent | 084e3ce6efc49c2d43ce9b44d96e430f8057848e (diff) | |
download | arching-kaos-web-ui-afcedd44615d20423d58f4d9c9d8cfa3838a54d4.tar.gz arching-kaos-web-ui-afcedd44615d20423d58f4d9c9d8cfa3838a54d4.tar.bz2 arching-kaos-web-ui-afcedd44615d20423d58f4d9c9d8cfa3838a54d4.zip |
Major refactoring
Diffstat (limited to 'src/js/ui/mainLayout.js')
-rw-r--r-- | src/js/ui/mainLayout.js | 33 |
1 files changed, 9 insertions, 24 deletions
diff --git a/src/js/ui/mainLayout.js b/src/js/ui/mainLayout.js index 6201e2b..5c0e0bf 100644 --- a/src/js/ui/mainLayout.js +++ b/src/js/ui/mainLayout.js @@ -1,28 +1,13 @@ import { makeElement } from "../arching-kaos-generator.js"; +import { headerSpawn } from "./header.js"; +import { menuSpawn } from "./menu.js"; +import { mainSpawn } from "./main.js"; +import { footerSpawn } from "./footer.js"; -var scripts = [ - { - element:"script", - type: "module", - src:"./js/ui/header.js" - }, - { - element:"script", - type: "module", - src:"./js/ui/menu.js" - }, - { - element:"script", - type: "module", - src:"./js/ui/main.js" - }, - { - element:"script", - type: "module", - src:"./js/ui/footer.js" - } -] -for ( var i = 0; i < scripts.length; i++ ) +export function mainLayoutSpawn() { - makeElement(scripts[i], document.querySelector('body')); + headerSpawn(); + menuSpawn(); + mainSpawn(); + footerSpawn(); } |