update
This commit is contained in:
1230
package-lock.json
generated
1230
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -27,8 +27,9 @@
|
||||
"@typescript-eslint/eslint-plugin": "^5.26.0",
|
||||
"@typescript-eslint/parser": "^5.26.0",
|
||||
"cross-env": "^7.0.3",
|
||||
"eslint": "^8.16.0",
|
||||
"typescript": "^4.9.4",
|
||||
"vite": "^4.1.4"
|
||||
"eslint": "^8.40.0",
|
||||
"eslint-plugin-vue": "^9.11.0",
|
||||
"typescript": "^5.0.4",
|
||||
"vite": "^4.3.0"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,7 @@
|
||||
import { createApp } from 'vue'
|
||||
import { createPinia } from 'pinia'
|
||||
import Root from '@/ui/Root/Root.vue'
|
||||
import { createApp } from "vue";
|
||||
import Root from "@/ui/Root/Root.vue";
|
||||
import "@/ui/global.css";
|
||||
|
||||
const app = createApp(Root, { title: "Drum Slayer" });
|
||||
app.use(createPinia());
|
||||
app.mount('#app');
|
||||
app.mount("#app");
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
<beat-settings :beat-index="activeBeatIndex" />
|
||||
</div>
|
||||
<div class="sidebar-toggle">
|
||||
<div class="buttons">
|
||||
<div
|
||||
class="quick-access-button"
|
||||
:title="`${ sidebarActive ? 'Hide' : 'Show' } sidebar`"
|
||||
@@ -54,10 +55,11 @@
|
||||
<icon icon-name="download" color="var(--color-ui-neutral-dark)" />
|
||||
</div>
|
||||
</div>
|
||||
<toolbox class="toolbox" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="beat-stage-container">
|
||||
<toolbox />
|
||||
<div class="beat-stage">
|
||||
<beat-view
|
||||
:beat-index="activeBeatIndex"
|
||||
@@ -76,6 +78,8 @@
|
||||
import { BeatStoreKey, createBeatStore } from "@/BeatStore";
|
||||
import { AppStateStoreKey, createAppStateStore } from "@/AppState";
|
||||
|
||||
const TITLE = 'Drum Slayer';
|
||||
|
||||
defineProps<{
|
||||
title: string,
|
||||
}>();
|
||||
@@ -99,8 +103,6 @@
|
||||
saveDirty,
|
||||
} = beatStore;
|
||||
|
||||
const TITLE = 'Drum Slayer';
|
||||
|
||||
watch(saveDirty, (dirty) => {
|
||||
if (dirty) {
|
||||
document.title = `${ TITLE } (unsaved changes)`;
|
||||
@@ -110,9 +112,9 @@
|
||||
});
|
||||
|
||||
const mediaQueryList = window.matchMedia("screen and (max-width: 900px)");
|
||||
const onMediaChange = (event: MediaQueryListEvent | MediaQueryList) => {
|
||||
function onMediaChange(event: MediaQueryListEvent | MediaQueryList) {
|
||||
sidebarActive.value = event.matches;
|
||||
};
|
||||
}
|
||||
mediaQueryList.addEventListener('change', onMediaChange);
|
||||
onMediaChange(mediaQueryList);
|
||||
|
||||
@@ -178,12 +180,12 @@
|
||||
background-color: var(--color-bg-light);
|
||||
overflow: scroll;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.settings .title {
|
||||
.title {
|
||||
color: var(--color-title-light);
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
|
||||
.sidebar-toggle {
|
||||
z-index: 1;
|
||||
@@ -191,9 +193,15 @@
|
||||
min-width: 2em;
|
||||
background-color: var(--color-bg-light);
|
||||
left: 0;
|
||||
}
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
||||
|
||||
.buttons {
|
||||
flex: 1;
|
||||
|
||||
.quick-access-button {
|
||||
flex: 1;
|
||||
right: 0;
|
||||
width: 2em;
|
||||
height: 2em;
|
||||
@@ -205,6 +213,13 @@
|
||||
cursor: auto;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.toolbox {
|
||||
flex: 1;
|
||||
width: 2em;
|
||||
}
|
||||
}
|
||||
|
||||
.beat-stage-container {
|
||||
position: absolute;
|
||||
|
||||
@@ -1,24 +1,20 @@
|
||||
<template>
|
||||
<div class="root-toolbox">
|
||||
<div class="toolbox">
|
||||
<div class="main-row">
|
||||
<div
|
||||
<icon
|
||||
class="toolbox-button"
|
||||
icon-name="lh"
|
||||
:class="{ active: selectedTool === 'track-unit-type' }"
|
||||
@click="selectedTool = 'track-unit-type'">
|
||||
Track Type
|
||||
</div>
|
||||
<div
|
||||
@click="selectedTool = 'track-unit-type'" />
|
||||
<icon
|
||||
class="toolbox-button"
|
||||
icon-name="lf"
|
||||
:class="{ active: selectedTool === 'sticking' }"
|
||||
@click="selectedTool = 'sticking'">
|
||||
Sticking
|
||||
</div>
|
||||
<div
|
||||
@click="selectedTool = 'sticking'" />
|
||||
<icon
|
||||
class="toolbox-button"
|
||||
:class="{ active: selectedTool === 'eraser' }"
|
||||
@click="selectedTool = 'eraser'">
|
||||
Eraser
|
||||
</div>
|
||||
@click="selectedTool = 'eraser'" />
|
||||
</div>
|
||||
<div v-if="selectedTool === 'track-unit-type'" class="details">
|
||||
<div v-for="(type, i) in TrackUnitTypeList"
|
||||
@@ -57,18 +53,17 @@
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.root-toolbox { }
|
||||
|
||||
.root-toolbox .main-row {
|
||||
height: 2.5em;
|
||||
.toolbox {
|
||||
.main-row {
|
||||
margin: auto;
|
||||
display: flex;
|
||||
background-color: var(--color-ui-neutral-dark);
|
||||
justify-content: center;
|
||||
width: 100%;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.root-toolbox .details {
|
||||
.details {
|
||||
margin: auto;
|
||||
height: 4em;
|
||||
width: min-content;
|
||||
@@ -77,38 +72,45 @@
|
||||
background-color: var(--color-ui-neutral-dark-active);
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.root-toolbox .details.hidden {
|
||||
&.hidden {
|
||||
visibility: hidden;
|
||||
}
|
||||
}
|
||||
|
||||
.root-toolbox .track-unit {
|
||||
.track-unit {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.root-toolbox .toolbox-button {
|
||||
.toolbox-button {
|
||||
padding: 0.5em;
|
||||
cursor: pointer;
|
||||
color: black;
|
||||
background-color: var(--color-ui-neutral-dark);
|
||||
}
|
||||
.root-toolbox .toolbox-button:hover {
|
||||
|
||||
&:hover {
|
||||
background-color: var(--color-ui-neutral-dark-hover);
|
||||
}
|
||||
.root-toolbox .toolbox-button.active {
|
||||
background-color: var(--color-ui-neutral-dark-active);
|
||||
}
|
||||
|
||||
.root-toolbox .details .toolbox-button.active {
|
||||
&.active {
|
||||
background-color: var(--color-ui-neutral-dark-active);
|
||||
}
|
||||
}
|
||||
|
||||
.details {
|
||||
.toolbox-button {
|
||||
background-color: var(--color-ui-neutral-dark-active);
|
||||
|
||||
&.active {
|
||||
background-color: var(--color-ui-neutral-dark);
|
||||
}
|
||||
.root-toolbox .details .toolbox-button:hover {
|
||||
|
||||
&:hover {
|
||||
background-color: var(--color-ui-neutral-dark-hover);
|
||||
}
|
||||
.root-toolbox .details .toolbox-button {
|
||||
background-color: var(--color-ui-neutral-dark-active);
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user