mirror of
https://github.com/YouHaveTrouble/GuildMaster.git
synced 2026-05-11 22:16:59 +00:00
fix up styles for the pages,
fix up some code formatting to be more consistent
This commit is contained in:
@@ -26,6 +26,7 @@ export default defineComponent({
|
|||||||
default() {
|
default() {
|
||||||
return {} as { [key: string]: Adventurer };
|
return {} as { [key: string]: Adventurer };
|
||||||
},
|
},
|
||||||
|
required: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
@@ -39,6 +40,7 @@ export default defineComponent({
|
|||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|
||||||
.slot {
|
.slot {
|
||||||
padding: 0;
|
padding: 0;
|
||||||
width: 5rem;
|
width: 5rem;
|
||||||
|
|||||||
@@ -65,12 +65,10 @@ export default defineComponent({
|
|||||||
default() {
|
default() {
|
||||||
return {} as {[key: string]: Adventurer};
|
return {} as {[key: string]: Adventurer};
|
||||||
},
|
},
|
||||||
|
required: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
print(a:string) {
|
|
||||||
console.log(a);
|
|
||||||
},
|
|
||||||
closeSelect() {
|
closeSelect() {
|
||||||
this.selection = false;
|
this.selection = false;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,7 +4,8 @@
|
|||||||
:title="adventurer.name + (adventurer.busy ? ' (busy)' : '')"
|
:title="adventurer.name + (adventurer.busy ? ' (busy)' : '')"
|
||||||
>
|
>
|
||||||
<img :src="adventurer.portrait" :alt="adventurer.name" draggable="false">
|
<img :src="adventurer.portrait" :alt="adventurer.name" draggable="false">
|
||||||
<div class="level" :title="adventurer.isMaxLevel() ? 'Max level' : ''">{{adventurer.level}}<span v-if="adventurer.isMaxLevel()">⇪</span></div>
|
<div class="level" :title="adventurer.isMaxLevel() ? 'Max level' : ''">{{ adventurer.level }}<span
|
||||||
|
v-if="adventurer.isMaxLevel()">⇪</span></div>
|
||||||
<div class="exp"></div>
|
<div class="exp"></div>
|
||||||
</article>
|
</article>
|
||||||
</template>
|
</template>
|
||||||
@@ -22,6 +23,7 @@ export default defineComponent({
|
|||||||
default() {
|
default() {
|
||||||
return {} as Adventurer;
|
return {} as Adventurer;
|
||||||
},
|
},
|
||||||
|
required: true,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data: () => ({
|
data: () => ({
|
||||||
@@ -51,6 +53,7 @@ export default defineComponent({
|
|||||||
line-height: 1;
|
line-height: 1;
|
||||||
color: rgba(0, 0, 0, 0.75);
|
color: rgba(0, 0, 0, 0.75);
|
||||||
position: relative;
|
position: relative;
|
||||||
|
|
||||||
.level {
|
.level {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
@@ -62,6 +65,7 @@ export default defineComponent({
|
|||||||
padding: 0.1rem;
|
padding: 0.1rem;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.exp {
|
.exp {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
@@ -71,6 +75,7 @@ export default defineComponent({
|
|||||||
background-color: rgba(203, 33, 213, 0.75);
|
background-color: rgba(203, 33, 213, 0.75);
|
||||||
transition: width 1s linear;
|
transition: width 1s linear;
|
||||||
}
|
}
|
||||||
|
|
||||||
img {
|
img {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ export default defineComponent({
|
|||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.changelog {
|
.changelog {
|
||||||
padding: 3rem;
|
padding-block: 3rem;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
@@ -75,10 +75,12 @@ export default defineComponent({
|
|||||||
|
|
||||||
h2 {
|
h2 {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
|
padding-inline: 1rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
hr {
|
hr {
|
||||||
border: 0;
|
border: 0;
|
||||||
|
width: calc(100% - 2rem);
|
||||||
border-bottom: 1px solid black;
|
border-bottom: 1px solid black;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -87,6 +89,7 @@ export default defineComponent({
|
|||||||
margin: 0;
|
margin: 0;
|
||||||
white-space: pre-wrap;
|
white-space: pre-wrap;
|
||||||
font-family: 'EB Garamond', serif;
|
font-family: 'EB Garamond', serif;
|
||||||
|
padding-inline: 1rem;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -61,12 +61,14 @@ export default defineComponent({
|
|||||||
default() {
|
default() {
|
||||||
return {} as Quest;
|
return {} as Quest;
|
||||||
},
|
},
|
||||||
|
required: true,
|
||||||
},
|
},
|
||||||
adventurers: {
|
adventurers: {
|
||||||
type: Object as PropType<{ [key: string]: Adventurer }>,
|
type: Object as PropType<{ [key: string]: Adventurer }>,
|
||||||
default() {
|
default() {
|
||||||
return {} as { [key: string]: Adventurer };
|
return {} as { [key: string]: Adventurer };
|
||||||
},
|
},
|
||||||
|
required: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
data: () => {
|
data: () => {
|
||||||
@@ -126,6 +128,7 @@ export default defineComponent({
|
|||||||
height: 100%;
|
height: 100%;
|
||||||
z-index: -5;
|
z-index: -5;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
|
||||||
img {
|
img {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
@@ -137,6 +140,7 @@ export default defineComponent({
|
|||||||
font-size: 1.5rem;
|
font-size: 1.5rem;
|
||||||
line-height: 1;
|
line-height: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
h3 {
|
h3 {
|
||||||
font-size: 1.15rem;
|
font-size: 1.15rem;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
@@ -148,6 +152,7 @@ export default defineComponent({
|
|||||||
margin: 0.5rem auto;
|
margin: 0.5rem auto;
|
||||||
position: relative;
|
position: relative;
|
||||||
height: 1.25rem;
|
height: 1.25rem;
|
||||||
|
|
||||||
.progress {
|
.progress {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
@@ -158,6 +163,7 @@ export default defineComponent({
|
|||||||
background-color: rgba(0, 128, 0, 0.65);
|
background-color: rgba(0, 128, 0, 0.65);
|
||||||
transition: width 250ms linear;
|
transition: width 250ms linear;
|
||||||
}
|
}
|
||||||
|
|
||||||
.percentage {
|
.percentage {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
@@ -221,6 +227,7 @@ export default defineComponent({
|
|||||||
background-size: contain;
|
background-size: contain;
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
z-index: -4;
|
z-index: -4;
|
||||||
|
|
||||||
img {
|
img {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
@@ -241,6 +248,7 @@ export default defineComponent({
|
|||||||
display: flex;
|
display: flex;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|
||||||
img {
|
img {
|
||||||
width: 45%;
|
width: 45%;
|
||||||
height: 35%;
|
height: 35%;
|
||||||
|
|||||||
@@ -25,7 +25,8 @@ export default defineComponent({
|
|||||||
type: Object as PropType<Guild>,
|
type: Object as PropType<Guild>,
|
||||||
default() {
|
default() {
|
||||||
return new Guild(1, 0) as Guild;
|
return new Guild(1, 0) as Guild;
|
||||||
}
|
},
|
||||||
|
required: true,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
@@ -47,11 +48,13 @@ export default defineComponent({
|
|||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 1rem;
|
gap: 1rem;
|
||||||
|
|
||||||
h2 {
|
h2 {
|
||||||
font-size: 1.75rem;
|
font-size: 1.75rem;
|
||||||
margin: 2rem 0 0;
|
margin: 2rem 0 0;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.upgrade {
|
.upgrade {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-size: 1.25rem;
|
font-size: 1.25rem;
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="adventurer-section">
|
<div class="adventurer-section">
|
||||||
<section class="recruit">
|
<section class="recruit panel pinned-paper">
|
||||||
<h1>Applying adventurers</h1>
|
<h1>Applying adventurers</h1>
|
||||||
<div class="adventurers">
|
<div class="adventurers">
|
||||||
<div v-if="currentlyForHire">
|
<div v-if="currentlyForHire">
|
||||||
@@ -28,8 +28,9 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
<section class="collection">
|
<section class="collection panel pinned-paper">
|
||||||
<h1>Recruited adventurers ({{ Object.keys(adventurers).length }} / {{ guild.adventurerCapacity.getAdventurerCapacity() }})</h1>
|
<h1>Recruited adventurers ({{ Object.keys(adventurers).length }} /
|
||||||
|
{{ guild.adventurerCapacity.getAdventurerCapacity() }})</h1>
|
||||||
<div class="adventurers">
|
<div class="adventurers">
|
||||||
<div class="adventurer-tile" v-for="adventurer in adventurers" :key="adventurer.id">
|
<div class="adventurer-tile" v-for="adventurer in adventurers" :key="adventurer.id">
|
||||||
<AdventurerTile class="entry" :adventurer="adventurer"/>
|
<AdventurerTile class="entry" :adventurer="adventurer"/>
|
||||||
@@ -63,12 +64,14 @@ export default defineComponent({
|
|||||||
default() {
|
default() {
|
||||||
return {} as Guild
|
return {} as Guild
|
||||||
},
|
},
|
||||||
|
required: true,
|
||||||
},
|
},
|
||||||
adventurers: {
|
adventurers: {
|
||||||
type: Object as PropType<{ [key: string]: Adventurer }>,
|
type: Object as PropType<{ [key: string]: Adventurer }>,
|
||||||
default() {
|
default() {
|
||||||
return {} as { [key: string]: Adventurer };
|
return {} as { [key: string]: Adventurer };
|
||||||
},
|
},
|
||||||
|
required: true,
|
||||||
},
|
},
|
||||||
lastRecruitTime: {
|
lastRecruitTime: {
|
||||||
type: Number as PropType<number>,
|
type: Number as PropType<number>,
|
||||||
@@ -148,22 +151,28 @@ export default defineComponent({
|
|||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.adventurer-section {
|
.adventurer-section {
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
justify-content: center;
|
|
||||||
align-items: center;
|
|
||||||
width: 100%;
|
|
||||||
section {
|
|
||||||
max-width: 1280px;
|
|
||||||
width: 100%;
|
|
||||||
text-align: center;
|
|
||||||
padding-block: 1rem;
|
padding-block: 1rem;
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-content: center;
|
||||||
|
flex-direction: column;
|
||||||
|
gap: 1rem;
|
||||||
|
width: 100%;
|
||||||
|
|
||||||
|
section {
|
||||||
|
text-align: center;
|
||||||
|
padding: 1rem;
|
||||||
|
width: calc(100% - 2rem);
|
||||||
|
max-width: 45rem;
|
||||||
|
margin: 0 auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
h1 {
|
h1 {
|
||||||
font-size: 2rem;
|
font-size: 2rem;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.adventurers {
|
.adventurers {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
@@ -171,6 +180,7 @@ export default defineComponent({
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
gap: 1rem;
|
gap: 1rem;
|
||||||
|
|
||||||
.adventurer-tile {
|
.adventurer-tile {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
@@ -178,10 +188,12 @@ export default defineComponent({
|
|||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
gap: 0.25rem;
|
gap: 0.25rem;
|
||||||
font-size: 1.1rem;
|
font-size: 1.1rem;
|
||||||
|
|
||||||
.entry {
|
.entry {
|
||||||
height: 7rem;
|
height: 7rem;
|
||||||
width: 7rem;
|
width: 7rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
b {
|
b {
|
||||||
line-height: 1;
|
line-height: 1;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
@@ -192,6 +204,7 @@ export default defineComponent({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.decision {
|
.decision {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
@@ -199,17 +212,21 @@ export default defineComponent({
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
font-size: 2rem;
|
font-size: 2rem;
|
||||||
gap: 1rem;
|
gap: 1rem;
|
||||||
|
|
||||||
span {
|
span {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
color: #fff;
|
color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
&.disabled {
|
&.disabled {
|
||||||
color: rgba(0, 0, 0, 0.5);
|
color: rgba(0, 0, 0, 0.5);
|
||||||
cursor: default;
|
cursor: default;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.hire-tile {
|
.hire-tile {
|
||||||
width: 8rem;
|
width: 8rem;
|
||||||
height: 8rem;
|
height: 8rem;
|
||||||
|
|||||||
@@ -69,8 +69,8 @@ main {
|
|||||||
gap: 1rem;
|
gap: 1rem;
|
||||||
|
|
||||||
.upgrades {
|
.upgrades {
|
||||||
padding: 1rem;
|
max-width: 45rem;
|
||||||
width: 45rem;
|
width: 100%;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -79,15 +79,16 @@ main {
|
|||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
padding: 2.5rem;
|
padding-block: 2.5rem;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
width: max-content;
|
width: 100%;
|
||||||
|
max-width: 45rem;
|
||||||
gap: 0.5rem;
|
gap: 0.5rem;
|
||||||
|
|
||||||
h1 {
|
h1 {
|
||||||
font-size: 4rem;
|
font-size: 4rem;
|
||||||
line-height: 0.75;
|
line-height: 0.75;
|
||||||
|
white-space: pre-wrap;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -103,18 +103,21 @@ export default defineComponent({
|
|||||||
default() {
|
default() {
|
||||||
return new Guild(1, 0);
|
return new Guild(1, 0);
|
||||||
},
|
},
|
||||||
|
required: true,
|
||||||
},
|
},
|
||||||
adventurers: {
|
adventurers: {
|
||||||
type: Object as PropType<{ [key: string]: Adventurer }>,
|
type: Object as PropType<{ [key: string]: Adventurer }>,
|
||||||
default() {
|
default() {
|
||||||
return {} as { [key: string]: Adventurer };
|
return {} as { [key: string]: Adventurer };
|
||||||
},
|
},
|
||||||
|
required: true,
|
||||||
},
|
},
|
||||||
quests: {
|
quests: {
|
||||||
type: Object as PropType<{ [key: string]: Quest }>,
|
type: Object as PropType<{ [key: string]: Quest }>,
|
||||||
default() {
|
default() {
|
||||||
return {} as { [key: string]: Quest };
|
return {} as { [key: string]: Quest };
|
||||||
},
|
},
|
||||||
|
required: true,
|
||||||
},
|
},
|
||||||
lastRecruitTime: {
|
lastRecruitTime: {
|
||||||
type: Number as PropType<number>,
|
type: Number as PropType<number>,
|
||||||
|
|||||||
@@ -18,9 +18,7 @@
|
|||||||
GitHub
|
GitHub
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<ChangelogComponent/>
|
<ChangelogComponent/>
|
||||||
|
|
||||||
</section>
|
</section>
|
||||||
|
|||||||
Reference in New Issue
Block a user