refactor: move ui code to subfolder

This commit is contained in:
Derrick Hammer 2023-07-17 07:25:53 -04:00
parent 3d4d275770
commit 735082cdd6
Signed by: pcfreak30
GPG Key ID: C997C339BE476FF2
34 changed files with 49 additions and 49 deletions

View File

@ -6,6 +6,6 @@
</head> </head>
<body> <body>
<div id="app"></div> <div id="app"></div>
<script type="module" src="/src/account.js"></script> <script type="module" src="./account.js"></script>
</body> </body>
</html> </html>

View File

@ -1,4 +1,4 @@
import Account from '/src/components/account/Account.svelte' import Account from './components/account/Account.svelte'
const app = new Account({ const app = new Account({
target: document.getElementById('app'), target: document.getElementById('app'),

View File

Before

Width:  |  Height:  |  Size: 773 B

After

Width:  |  Height:  |  Size: 773 B

View File

Before

Width:  |  Height:  |  Size: 391 B

After

Width:  |  Height:  |  Size: 391 B

View File

Before

Width:  |  Height:  |  Size: 969 B

After

Width:  |  Height:  |  Size: 969 B

View File

Before

Width:  |  Height:  |  Size: 764 B

After

Width:  |  Height:  |  Size: 764 B

View File

Before

Width:  |  Height:  |  Size: 8.0 KiB

After

Width:  |  Height:  |  Size: 8.0 KiB

View File

Before

Width:  |  Height:  |  Size: 719 KiB

After

Width:  |  Height:  |  Size: 719 KiB

View File

Before

Width:  |  Height:  |  Size: 684 KiB

After

Width:  |  Height:  |  Size: 684 KiB

View File

Before

Width:  |  Height:  |  Size: 921 KiB

After

Width:  |  Height:  |  Size: 921 KiB

View File

Before

Width:  |  Height:  |  Size: 815 KiB

After

Width:  |  Height:  |  Size: 815 KiB

View File

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

View File

Before

Width:  |  Height:  |  Size: 2.2 KiB

After

Width:  |  Height:  |  Size: 2.2 KiB

View File

@ -4,8 +4,8 @@
import * as bip39 from '@scure/bip39'; import * as bip39 from '@scure/bip39';
import { wordlist } from '@scure/bip39/wordlists/english'; import { wordlist } from '@scure/bip39/wordlists/english';
import '/src/styles/global.scss'; import '../../styles/global.scss';
import lumeLogo from '/src/assets/lume-logo.png'; import lumeLogo from '../../assets/lume-logo.png';
let action; let action;
let createAccountStep; let createAccountStep;
@ -340,9 +340,9 @@
</main> </main>
<style lang="scss"> <style lang="scss">
@import "/src/styles/artwork.scss"; @import "../../styles/artwork";
@import "/src/styles/mixins.scss"; @import "../../styles/mixins";
@import "/src/styles/vars.scss"; @import "../../styles/vars";
main { main {
position: relative; position: relative;

View File

@ -1,11 +1,11 @@
<script> <script>
import '/src/styles/global.scss'; import '../../styles/global.scss';
import lumeLogo from '/src/assets/lume-logo.png'; import lumeLogo from '../../assets/lume-logo.png';
import svgGithub from '/src/assets/icon/github.svg?raw'; import svgGithub from '../../assets/icon/github.svg?raw';
import svgDiscord from '/src/assets/icon/discord.svg?raw'; import svgDiscord from '../../assets/icon/discord.svg?raw';
import svgTwitter from '/src/assets/icon/twitter.svg?raw'; import svgTwitter from '../../assets/icon/twitter.svg?raw';
import svgFacebook from '/src/assets/icon/facebook.svg?raw'; import svgFacebook from '../../assets/icon/facebook.svg?raw';
let step = 1; let step = 1;
let userCount; let userCount;
@ -151,9 +151,9 @@
</main> </main>
<style lang="scss"> <style lang="scss">
@import "/src/styles/artwork.scss"; @import "../../styles/artwork";
@import "/src/styles/mixins.scss"; @import "../../styles/mixins";
@import "/src/styles/vars.scss"; @import "../../styles/vars";
.icon { .icon {
display: block; display: block;
@ -171,14 +171,14 @@
} }
&.icon-wait { &.icon-wait {
background-image: url("/src/assets/wait-icon-orange.png"); background-image: url("../../assets/wait-icon-orange.png");
background-size: 1.125em 1.125em; background-size: 1.125em 1.125em;
background-repeat: no-repeat; background-repeat: no-repeat;
background-position: 50%; background-position: 50%;
} }
&.icon-wait-yellow { &.icon-wait-yellow {
background-image: url("/src/assets/wait-icon-yellow.png"); background-image: url("../../assets/wait-icon-yellow.png");
} }
&.icon-error { &.icon-error {

View File

@ -1,6 +1,6 @@
<script> <script>
import '/src/styles/global.scss'; import '../../styles/global.scss';
import lumeLogo from '/src/assets/lume-logo.png'; import lumeLogo from '../../assets/lume-logo.png';
let started = false; let started = false;
let step = 1; let step = 1;
@ -72,8 +72,8 @@
</main> </main>
<style lang="scss"> <style lang="scss">
@import "/src/styles/mixins.scss"; @import "../../styles/mixins";
@import "/src/styles/vars.scss"; @import "../../styles/vars";
main { main {
position: relative; position: relative;
@ -89,7 +89,7 @@
.art-1 { .art-1 {
left: 0; left: 0;
background-image: url("/src/assets/onboarding-1.jpg"); background-image: url("../../assets/onboarding-1.jpg");
background-position: 50%; background-position: 50%;
background-size: cover; background-size: cover;
border-right: 1px solid #363636; border-right: 1px solid #363636;
@ -97,7 +97,7 @@
.art-2 { .art-2 {
left: 50%; left: 50%;
background-image: url("/src/assets/onboarding-2.jpg"); background-image: url("../../assets/onboarding-2.jpg");
background-position: 50%; background-position: 50%;
background-size: cover; background-size: cover;
border-left: 1px solid #363636; border-left: 1px solid #363636;
@ -106,7 +106,7 @@
.art-3 { .art-3 {
left: 50%; left: 50%;
background-image: url("/src/assets/onboarding-3.jpg"); background-image: url("../../assets/onboarding-3.jpg");
background-position: 50%; background-position: 50%;
background-size: cover; background-size: cover;
border-left: 1px solid #363636; border-left: 1px solid #363636;
@ -116,7 +116,7 @@
.art-4 { .art-4 {
left: 50%; left: 50%;
background-image: url("/src/assets/onboarding-4.jpg"); background-image: url("../../assets/onboarding-4.jpg");
background-position: 50%; background-position: 50%;
background-size: cover; background-size: cover;
border-left: 1px solid #363636; border-left: 1px solid #363636;

View File

@ -6,6 +6,6 @@
</head> </head>
<body> <body>
<div id="app"></div> <div id="app"></div>
<script type="module" src="/src/dashboard.js"></script> <script type="module" src="./dashboard.js"></script>
</body> </body>
</html> </html>

View File

@ -1,4 +1,4 @@
import Dashboard from '/src/components/dashboard/Dashboard.svelte' import Dashboard from './components/dashboard/Dashboard.svelte'
const app = new Dashboard({ const app = new Dashboard({
target: document.getElementById('app'), target: document.getElementById('app'),

View File

@ -6,6 +6,6 @@
</head> </head>
<body> <body>
<div id="app"></div> <div id="app"></div>
<script type="module" src="/src/onboarding.js"></script> <script type="module" src="./onboarding.js"></script>
</body> </body>
</html> </html>

View File

@ -1,4 +1,4 @@
import Onboarding from '/src/components/onboarding/Onboarding.svelte' import Onboarding from './components/onboarding/Onboarding.svelte'
const app = new Onboarding({ const app = new Onboarding({
target: document.getElementById('app'), target: document.getElementById('app'),

View File

@ -1,5 +1,5 @@
@import "./mixins.scss"; @import "mixins";
@import "./vars.scss"; @import "vars";
@font-face { @font-face {
font-family: 'JetBrains Mono'; font-family: 'JetBrains Mono';

17
ui/vite.config.js Normal file
View File

@ -0,0 +1,17 @@
import { defineConfig } from "vite";
import { svelte } from "@sveltejs/vite-plugin-svelte";
import { resolve } from "path";
// https://vitejs.dev/config/
export default defineConfig({
plugins: [svelte()],
build: {
rollupOptions: {
input: {
onboarding: resolve(__dirname, "onboarding.html"),
account: resolve(__dirname, "account.html"),
dashboard: resolve(__dirname, "dashboard.html"),
},
},
},
});

View File

@ -1,17 +0,0 @@
import { defineConfig } from 'vite';
import { svelte } from '@sveltejs/vite-plugin-svelte';
import { resolve } from 'path';
// https://vitejs.dev/config/
export default defineConfig({
plugins: [svelte()],
build: {
rollupOptions: {
input: {
onboarding: resolve(__dirname, 'onboarding.html'),
account: resolve(__dirname, 'account.html'),
dashboard: resolve(__dirname, 'dashboard.html')
}
},
},
});