You've already forked AstralRinth
forked from didirus/AstralRinth
Library page (#53)
* launcher base gui initial * Bootstraps router, Omorphia, and prettier. * Adds pages. Adds Vuex. SideBar nav contains user section and pages section. * Adds Instance markup. Instances added to Home page. * Adds News to home page. * Adds settings to nav. Other touches. * Polishing initial base GUI. * Moves some styling to assets. Changes px values to rem. * Removes pointless border-radius CSS. * Implements Omorphia vars. * Adds trending mods section. * Updates home page. * Swaps Vuex implementation for Pinia. * Fixes invalid CSS on instance list item hover. * Adds @ path resolve for imports. * Fix some styling of row display * Gridview on library page * Cleaning up styles and markup. * Fixes overall layout issues. * Cleans up more styling. Modifies AppBar coloring. * instance routing * Allows pagination arrows to conditionally appear in RowDisplay. * Adds paging behavior in RowDisplay. * Initial modlist layout * Updates nav and settings button styling. * Brings in Knossos style for trending mods. Polishes News CSS. * Page redesign * More tweaks * Base library pages * Remove errant css * Update play.svg * Addressed issues --------- Co-authored-by: Jai A <jaiagr+gpg@pm.me> Co-authored-by: Zachary Baird <zdb1994@yahoo.com> Co-authored-by: Zach Baird <30800863+ZachBaird@users.noreply.github.com>
This commit is contained in:
269
theseus_gui/src/pages/instance/Index.vue
Normal file
269
theseus_gui/src/pages/instance/Index.vue
Normal file
@@ -0,0 +1,269 @@
|
||||
<template>
|
||||
<div class="instance-container">
|
||||
<div class="side-cards">
|
||||
<Card class="instance-card">
|
||||
<Avatar size="lg" :src="getInstance(instances).img"/>
|
||||
<div class="instance-info">
|
||||
<h2 class="name">{{getInstance(instances).name}}</h2>
|
||||
Fabric {{ getInstance(instances).version }}
|
||||
</div>
|
||||
<span class="button-group">
|
||||
<Button color="primary" class="instance-button">
|
||||
<PlayIcon />
|
||||
Play
|
||||
</Button>
|
||||
<Button class="instance-button" icon-only>
|
||||
<OpenFolderIcon />
|
||||
</Button>
|
||||
</span>
|
||||
</Card>
|
||||
<div class="pages-list">
|
||||
<RouterLink :to="`/instance/${this.$route.params.id}/`" class="btn">
|
||||
<BoxIcon/>
|
||||
Mods
|
||||
</RouterLink>
|
||||
<RouterLink :to="`/instance/${this.$route.params.id}/options`" class="btn">
|
||||
<SettingsIcon/>
|
||||
Options
|
||||
</RouterLink>
|
||||
<RouterLink :to="`/instance/${this.$route.params.id}/logs`" class="btn">
|
||||
<FileIcon/>
|
||||
Logs
|
||||
</RouterLink>
|
||||
</div>
|
||||
</div>
|
||||
<div class="content">
|
||||
<Promotion />
|
||||
<router-view/>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script setup>
|
||||
import {BoxIcon, SettingsIcon, FileIcon, Button, Avatar, Card, Promotion} from 'omorphia'
|
||||
import {PlayIcon, OpenFolderIcon} from "@/assets/icons";
|
||||
import {useInstances} from '@/store/state'
|
||||
|
||||
const instances = useInstances();
|
||||
instances.fetchInstances();
|
||||
</script>
|
||||
<script>
|
||||
export default {
|
||||
methods: {
|
||||
getInstance(instances) {
|
||||
return instances.instances.find((i) => i.id === parseInt(this.$route.params.id));
|
||||
}
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.instance-card {
|
||||
background: var(--color-bg);
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 1rem;
|
||||
width: 15rem;
|
||||
}
|
||||
|
||||
Button {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.button-group {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
gap: 0.5rem;
|
||||
}
|
||||
|
||||
.side-cards {
|
||||
position: absolute;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
padding: 1rem;
|
||||
background: var(--color-raised-bg);
|
||||
min-height: calc(100% - 2rem);
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.instance-nav {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
justify-content: center;
|
||||
padding: 1rem;
|
||||
gap: 0.5rem;
|
||||
background: var(--color-raised-bg);
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.name {
|
||||
font-size: 1.25rem;
|
||||
color: var(--color-contrast);
|
||||
}
|
||||
|
||||
.instance-container {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
overflow: auto;
|
||||
gap: 1rem;
|
||||
}
|
||||
|
||||
.content {
|
||||
margin-left: 18rem;
|
||||
}
|
||||
|
||||
.instance-info {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.badge {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
font-weight: bold;
|
||||
width: fit-content;
|
||||
color: var(--color-orange);
|
||||
}
|
||||
|
||||
.pages-list {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 0.5rem;
|
||||
|
||||
a {
|
||||
font-size: 100%;
|
||||
font-weight: 400;
|
||||
background: inherit;
|
||||
transition: all ease-in-out 0.1s;
|
||||
width: 100%;
|
||||
color: var(--color-primary);
|
||||
padding: var(--gap-md);
|
||||
|
||||
&.router-link-exact-active {
|
||||
background: var(--color-button-bg);
|
||||
}
|
||||
|
||||
&:hover {
|
||||
background-color: var(--color-button-bg);
|
||||
color: var(--color-contrast);
|
||||
box-shadow: 0px 4px 4px rgba(0, 0, 0, 0.25);
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
svg {
|
||||
width: 1.3rem;
|
||||
height: 1.3rem;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.header-nav {
|
||||
height: 100%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
justify-content: center;
|
||||
padding: 0.5rem;
|
||||
gap: 0.5rem;
|
||||
background: var(--color-raised-bg);
|
||||
}
|
||||
|
||||
.project-card {
|
||||
height: 100%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
justify-content: center;
|
||||
gap: 1rem;
|
||||
background: var(--color-raised-bg);
|
||||
width: 20rem;
|
||||
}
|
||||
|
||||
.instance-nav {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: flex-start;
|
||||
justify-content: left;
|
||||
padding: 1rem;
|
||||
gap: 0.5rem;
|
||||
background: var(--color-raised-bg);
|
||||
height: min-content;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.instance-button {
|
||||
width: fit-content;
|
||||
}
|
||||
|
||||
.actions {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: flex-start;
|
||||
gap: 0.5rem;
|
||||
}
|
||||
|
||||
.content {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
padding: 1rem 1rem 0 0;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
.stats {
|
||||
grid-area: stats;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
flex-wrap: wrap;
|
||||
gap: var(--gap-md);
|
||||
|
||||
.stat {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
width: fit-content;
|
||||
gap: var(--gap-xs);
|
||||
--stat-strong-size: 1.25rem;
|
||||
|
||||
strong {
|
||||
font-size: var(--stat-strong-size);
|
||||
}
|
||||
|
||||
p {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
svg {
|
||||
height: var(--stat-strong-size);
|
||||
width: var(--stat-strong-size);
|
||||
}
|
||||
}
|
||||
|
||||
.date {
|
||||
margin-top: auto;
|
||||
}
|
||||
|
||||
@media screen and (max-width: 750px) {
|
||||
flex-direction: row;
|
||||
column-gap: var(--gap-md);
|
||||
margin-top: var(--gap-xs);
|
||||
}
|
||||
|
||||
@media screen and (max-width: 600px) {
|
||||
margin-top: 0;
|
||||
|
||||
.stat-label {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.card-divider {
|
||||
background-color: var(--color-button-bg);
|
||||
border: none;
|
||||
color: var(--color-button-bg);
|
||||
height: 1px;
|
||||
margin: var(--gap-xl) 0;
|
||||
}
|
||||
</style>
|
||||
121
theseus_gui/src/pages/instance/Logs.vue
Normal file
121
theseus_gui/src/pages/instance/Logs.vue
Normal file
@@ -0,0 +1,121 @@
|
||||
<template>
|
||||
<Card class="log-card">
|
||||
<div class="button-row">
|
||||
<DropdownSelect :options="['logs/latest.log']" />
|
||||
<div class="button-group">
|
||||
<Button>
|
||||
<ClipboardCopyIcon/>
|
||||
Copy
|
||||
</Button>
|
||||
<Button color="primary">
|
||||
<SendIcon/>
|
||||
Share
|
||||
</Button>
|
||||
<Button color="danger">
|
||||
<TrashIcon/>
|
||||
Delete
|
||||
</Button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="log-text">
|
||||
<div v-for="line in fileContents.value.split('\n')"> {{ line }} </div>
|
||||
</div>
|
||||
</Card>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { Card, Button, TrashIcon, SendIcon, ClipboardCopyIcon, DropdownSelect } from 'omorphia'
|
||||
</script>
|
||||
<script>
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
fileContents: {
|
||||
value: "'ServerLevel[New World]'/minecraft:the_end\n" +
|
||||
"[22:13:02] [Server thread/INFO]: venashial lost connection: Disconnected\n" +
|
||||
"[22:13:02] [Server thread/INFO]: venashial left the game\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Stopping singleplayer server as player logged out\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Stopping server\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Saving players\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Saving worlds\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Saving chunks for level 'ServerLevel[New World]'/minecraft:overworld\n" +
|
||||
"[22:13:05] [Server thread/INFO]: Saving chunks for level 'ServerLevel[New World]'/minecraft:the_nether\n" +
|
||||
"[22:13:05] [Server thread/INFO]: Saving chunks for level 'ServerLevel[New World]'/minecraft:the_end\n" +
|
||||
"[22:13:05] [Server thread/INFO]: ThreadedAnvilChunkStorage (New World): All chunks are saved\n" +
|
||||
"[22:13:05] [Server thread/INFO]: ThreadedAnvilChunkStorage (DIM-1): All chunks are saved\n" +
|
||||
"[22:13:05] [Server thread/INFO]: ThreadedAnvilChunkStorage (DIM1): All chunks are saved\n" +
|
||||
"[22:13:05] [Server thread/INFO]: ThreadedAnvilChunkStorage: All dimensions are saved\n" +
|
||||
"[22:13:06] [Render thread/INFO]: Stopping worker threads\n" +
|
||||
"[22:13:07] [Render thread/INFO]: Stopping!\n" +
|
||||
"[22:13:07] [CraftPresence-ShutDown-Handler/INFO]: Shutting down CraftPresence...\n" +
|
||||
"'ServerLevel[New World]'/minecraft:the_end\n" +
|
||||
"[22:13:02] [Server thread/INFO]: venashial lost connection: Disconnected\n" +
|
||||
"[22:13:02] [Server thread/INFO]: venashial left the game\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Stopping singleplayer server as player logged out\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Stopping server\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Saving players\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Saving worlds\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Saving chunks for level 'ServerLevel[New World]'/minecraft:overworld\n" +
|
||||
"[22:13:05] [Server thread/INFO]: Saving chunks for level 'ServerLevel[New World]'/minecraft:the_nether\n" +
|
||||
"[22:13:05] [Server thread/INFO]: Saving chunks for level 'ServerLevel[New World]'/minecraft:the_end\n" +
|
||||
"[22:13:05] [Server thread/INFO]: ThreadedAnvilChunkStorage (New World): All chunks are saved\n" +
|
||||
"[22:13:05] [Server thread/INFO]: ThreadedAnvilChunkStorage (DIM-1): All chunks are saved\n" +
|
||||
"[22:13:05] [Server thread/INFO]: ThreadedAnvilChunkStorage (DIM1): All chunks are saved\n" +
|
||||
"[22:13:05] [Server thread/INFO]: ThreadedAnvilChunkStorage: All dimensions are saved\n" +
|
||||
"[22:13:06] [Render thread/INFO]: Stopping worker threads\n" +
|
||||
"[22:13:07] [Render thread/INFO]: Stopping!\n" +
|
||||
"[22:13:07] [CraftPresence-ShutDown-Handler/INFO]: Shutting down CraftPresence...\n" +
|
||||
"'ServerLevel[New World]'/minecraft:the_end\n" +
|
||||
"[22:13:02] [Server thread/INFO]: venashial lost connection: Disconnected\n" +
|
||||
"[22:13:02] [Server thread/INFO]: venashial left the game\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Stopping singleplayer server as player logged out\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Stopping server\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Saving players\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Saving worlds\n" +
|
||||
"[22:13:02] [Server thread/INFO]: Saving chunks for level 'ServerLevel[New World]'/minecraft:overworld\n" +
|
||||
"[22:13:05] [Server thread/INFO]: Saving chunks for level 'ServerLevel[New World]'/minecraft:the_nether\n" +
|
||||
"[22:13:05] [Server thread/INFO]: Saving chunks for level 'ServerLevel[New World]'/minecraft:the_end\n" +
|
||||
"[22:13:05] [Server thread/INFO]: ThreadedAnvilChunkStorage (New World): All chunks are saved\n" +
|
||||
"[22:13:05] [Server thread/INFO]: ThreadedAnvilChunkStorage (DIM-1): All chunks are saved\n" +
|
||||
"[22:13:05] [Server thread/INFO]: ThreadedAnvilChunkStorage (DIM1): All chunks are saved\n" +
|
||||
"[22:13:05] [Server thread/INFO]: ThreadedAnvilChunkStorage: All dimensions are saved\n" +
|
||||
"[22:13:06] [Render thread/INFO]: Stopping worker threads\n" +
|
||||
"[22:13:07] [Render thread/INFO]: Stopping!\n" +
|
||||
"[22:13:07] [CraftPresence-ShutDown-Handler/INFO]: Shutting down CraftPresence..."
|
||||
}
|
||||
};
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.log-card {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 1rem;
|
||||
}
|
||||
.button-row {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.button-group {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
gap: 0.5rem;
|
||||
}
|
||||
|
||||
.log-text {
|
||||
width: 100%;
|
||||
aspect-ratio: 2/1;
|
||||
font-family: var(--mono-font);
|
||||
background-color: var(--color-accent-contrast);
|
||||
color: var(--color-contrast);
|
||||
border-radius: var(--radius-lg);
|
||||
padding: 1.5rem;
|
||||
overflow: auto;
|
||||
white-space: normal;
|
||||
}
|
||||
</style>
|
||||
247
theseus_gui/src/pages/instance/Mods.vue
Normal file
247
theseus_gui/src/pages/instance/Mods.vue
Normal file
@@ -0,0 +1,247 @@
|
||||
<template>
|
||||
<Card class="mod-card">
|
||||
<div class="card-row">
|
||||
<div class="iconified-input">
|
||||
<SearchIcon/>
|
||||
<input
|
||||
type="text"
|
||||
placeholder="Search Mods"
|
||||
v-model="searchFilter"
|
||||
/>
|
||||
</div>
|
||||
<span class="manage">
|
||||
<span class="text-combo">
|
||||
Sort By
|
||||
<DropdownSelect :options="['Name', 'Version', 'Author']" v-model="sortFilter" default-value="Name" class="dropdown"/>
|
||||
</span>
|
||||
<Button color="primary">
|
||||
<PlusIcon />
|
||||
Add Mods
|
||||
</Button>
|
||||
</span>
|
||||
</div>
|
||||
<div class="table-container">
|
||||
<div class="table-row table-head">
|
||||
<div class="table-cell table-text">
|
||||
<Button color="success" iconOnly>
|
||||
<UpdatedIcon />
|
||||
</Button>
|
||||
</div>
|
||||
<div class="table-cell table-text name-cell"> Name </div>
|
||||
<div class="table-cell table-text"> Version </div>
|
||||
<div class="table-cell table-text"> Author </div>
|
||||
<div class="table-cell table-text"> Actions </div>
|
||||
</div>
|
||||
<div class="table-row" v-for="mod in search" :key="mod.name">
|
||||
<div class="table-cell table-text">
|
||||
<Button v-if="mod.outdated" iconOnly>
|
||||
<UpdatedIcon />
|
||||
</Button>
|
||||
<Button v-else disabled iconOnly>
|
||||
<CheckCircleIcon/>
|
||||
</Button>
|
||||
</div>
|
||||
<div class="table-cell table-text name-cell">
|
||||
<span class="mod-text">
|
||||
<Avatar :src="mod.icon"/>
|
||||
{{ mod.name }}
|
||||
</span>
|
||||
</div>
|
||||
<div class="table-cell table-text"> {{ mod.version }} </div>
|
||||
<div class="table-cell table-text"> {{ mod.author }} </div>
|
||||
<div class="table-cell table-text manage">
|
||||
<Button iconOnly>
|
||||
<TrashIcon />
|
||||
</Button>
|
||||
<input
|
||||
type="checkbox"
|
||||
class="switch stylized-toggle"
|
||||
id="switch-1"
|
||||
checked
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</Card>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: "Mods",
|
||||
data() {
|
||||
return {
|
||||
searchFilter: "",
|
||||
sortFilter: "",
|
||||
mods: [
|
||||
{
|
||||
name: "Fabric API",
|
||||
icon: "https://cdn.modrinth.com/data/P7dR8mSH/icon.png",
|
||||
version: "0.76.0+1.19.4",
|
||||
author: "modmuss50",
|
||||
description: "Lightweight and modular API providing common hooks and intercompatibility measures utilized by mods using the Fabric toolchain.",
|
||||
outdated: true
|
||||
},
|
||||
{
|
||||
name: "Spirit",
|
||||
icon: "https://cdn.modrinth.com/data/b1LdOZlE/465598dc5d89f67fb8f8de6def21240fa35e3a54.png",
|
||||
version: "2.2.4",
|
||||
author: "CodexAdrian",
|
||||
description: "Create your own configurable mob spawner!",
|
||||
outdated: true
|
||||
},
|
||||
{
|
||||
name: "Botarium",
|
||||
icon: "https://cdn.modrinth.com/data/2u6LRnMa/98b286b0d541ad4f9409e0af3df82ad09403f179.gif",
|
||||
version: "2.0.5",
|
||||
author: "CodexAdrian",
|
||||
description: "A crossplatform API for devs that makes transfer and storage of items, fluids and energy easier, as well as some other helpful things",
|
||||
outdated: true
|
||||
},
|
||||
{
|
||||
name: "Tempad",
|
||||
icon: "https://cdn.modrinth.com/data/gKNwt7xu/icon.gif",
|
||||
version: "2.2.4",
|
||||
author: "CodexAdrian",
|
||||
description: "Create a portal to anywhere from anywhere",
|
||||
outdated: false
|
||||
},
|
||||
{
|
||||
name: "Sodium",
|
||||
icon: "https://cdn.modrinth.com/data/AANobbMI/icon.png",
|
||||
version: "0.4.10",
|
||||
author: "jellysquid3",
|
||||
description: "Modern rendering engine and client-side optimization mod for Minecraft",
|
||||
outdated: false
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
updateSort(projects, sort) {
|
||||
switch (sort) {
|
||||
case 'Version':
|
||||
return projects.slice().sort((a, b) => {
|
||||
if (a.version < b.version) {
|
||||
return -1
|
||||
}
|
||||
if (a.version > b.version) {
|
||||
return 1
|
||||
}
|
||||
return 0
|
||||
})
|
||||
case 'Author':
|
||||
return projects.slice().sort((a, b) => {
|
||||
if (a.author < b.author) {
|
||||
return -1
|
||||
}
|
||||
if (a.author > b.author) {
|
||||
return 1
|
||||
}
|
||||
return 0
|
||||
})
|
||||
default:
|
||||
return projects.slice().sort((a, b) => {
|
||||
if (a.name < b.name) {
|
||||
return -1
|
||||
}
|
||||
if (a.name > b.name) {
|
||||
return 1
|
||||
}
|
||||
return 0
|
||||
})
|
||||
}
|
||||
},
|
||||
},
|
||||
computed: {
|
||||
search() {
|
||||
const filtered = this.mods.filter((mod) => {
|
||||
return mod.name.toLowerCase().includes(this.searchFilter.toLowerCase())
|
||||
})
|
||||
|
||||
return this.updateSort(filtered, this.sortFilter);
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<script setup>
|
||||
import { Avatar, Button, TrashIcon, PlusIcon, Card, CheckCircleIcon, SearchIcon, UpdatedIcon, DropdownSelect } from 'omorphia'
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.table-container {
|
||||
display: grid;
|
||||
grid-template-rows: repeat(auto-fill, auto);
|
||||
width: 100%;
|
||||
border-radius: var(--radius-md);
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.table-row {
|
||||
display: grid;
|
||||
grid-template-columns: min-content 2fr 1fr 1fr 8rem;
|
||||
}
|
||||
|
||||
.table-head {
|
||||
.table-cell {
|
||||
background-color: var(--color-accent-contrast);
|
||||
}
|
||||
}
|
||||
|
||||
.table-cell {
|
||||
padding: 1rem;
|
||||
height: 100%;
|
||||
align-items: center;
|
||||
vertical-align: center;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.table-text {
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
text-overflow: fade;
|
||||
}
|
||||
|
||||
.manage {
|
||||
display: flex;
|
||||
gap: 0.5rem;
|
||||
}
|
||||
|
||||
.mod-text {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 1rem;
|
||||
color: var(--color-contrast);
|
||||
}
|
||||
|
||||
.table-row:nth-child(even) .table-cell {
|
||||
background-color: var(--color-bg);
|
||||
}
|
||||
|
||||
.card-row {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
background-color: var(--color-raised-bg);
|
||||
}
|
||||
|
||||
.mod-card {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 1rem;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.text-combo {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0.5rem;
|
||||
}
|
||||
|
||||
.name-cell {
|
||||
padding-left: 0;
|
||||
}
|
||||
|
||||
.dropdown {
|
||||
width: 7rem !important;
|
||||
}
|
||||
</style>
|
||||
230
theseus_gui/src/pages/instance/Options.vue
Normal file
230
theseus_gui/src/pages/instance/Options.vue
Normal file
@@ -0,0 +1,230 @@
|
||||
<template>
|
||||
<Card class="settings-card">
|
||||
<h2 class="settings-title"> Java </h2>
|
||||
<div class="settings-group">
|
||||
<h3>Installation</h3>
|
||||
<input
|
||||
type="text"
|
||||
class="input installation-input"
|
||||
placeholder="/Library/Java/JavaVirtualMachines/zulu-17.jdk/Contents/Home"
|
||||
ref="javaPath"
|
||||
v-model="javaPath"
|
||||
/>
|
||||
<span class="installation-buttons">
|
||||
<Button @click="saveJavaPath">
|
||||
<SearchIcon/>
|
||||
Auto Detect
|
||||
</Button>
|
||||
<Button @click="saveJavaPath">
|
||||
<BrowseIcon/>
|
||||
Browse
|
||||
</Button>
|
||||
<Button @click="saveJavaPath">
|
||||
<PlayIcon/>
|
||||
Test
|
||||
</Button>
|
||||
</span>
|
||||
</div>
|
||||
<hr class="card-divider">
|
||||
<div class="settings-group">
|
||||
<h3>Arguments</h3>
|
||||
<input
|
||||
type="text"
|
||||
class="input installation-input"
|
||||
ref="javaArgs"
|
||||
v-model="javaArgs"
|
||||
/>
|
||||
</div>
|
||||
<hr class="card-divider">
|
||||
<div class="settings-group">
|
||||
<div class="sliders">
|
||||
<span class="slider">
|
||||
Minimum Memory
|
||||
<Slider
|
||||
v-model="javaMemory"
|
||||
:min="1024"
|
||||
:max="8192"
|
||||
:step="1024"
|
||||
/>
|
||||
</span>
|
||||
<span class="slider">
|
||||
Maximum Memory
|
||||
<Slider
|
||||
v-model="javaMemory"
|
||||
:min="1024"
|
||||
:max="8192"
|
||||
:step="1024"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</Card>
|
||||
<Card class="settings-card">
|
||||
<h2 class="settings-title"> Window </h2>
|
||||
<div class="settings-group">
|
||||
<div class="settings-group">
|
||||
<div class="sliders">
|
||||
<span class="slider">
|
||||
Width
|
||||
<Slider
|
||||
v-model="javaMemory"
|
||||
:min="1024"
|
||||
:max="8192"
|
||||
:step="1024"
|
||||
/>
|
||||
</span>
|
||||
<span class="slider">
|
||||
Height
|
||||
<Slider
|
||||
v-model="javaMemory"
|
||||
:min="1024"
|
||||
:max="8192"
|
||||
:step="1024"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
<div class="toggle-setting">
|
||||
Start in Fullscreen
|
||||
<input
|
||||
type="checkbox"
|
||||
id="fullscreen"
|
||||
name="fullscreen"
|
||||
v-model="fullscreen"
|
||||
class="switch stylized-toggle"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<hr class="card-divider">
|
||||
<div class="settings-group">
|
||||
<h3>Console</h3>
|
||||
<div class="toggle-setting">
|
||||
Show console while game is running
|
||||
<input
|
||||
type="checkbox"
|
||||
id="fullscreen"
|
||||
name="fullscreen"
|
||||
v-model="fullscreen"
|
||||
class="switch stylized-toggle"
|
||||
/>
|
||||
</div>
|
||||
<div class="toggle-setting">
|
||||
Close console when game quits
|
||||
<input
|
||||
type="checkbox"
|
||||
id="fullscreen"
|
||||
name="fullscreen"
|
||||
v-model="fullscreen"
|
||||
class="switch stylized-toggle"
|
||||
/>
|
||||
</div>
|
||||
<div class="toggle-setting">
|
||||
Show console when game crashes
|
||||
<input
|
||||
type="checkbox"
|
||||
id="fullscreen"
|
||||
name="fullscreen"
|
||||
v-model="fullscreen"
|
||||
class="switch stylized-toggle"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</Card>
|
||||
<Card class="settings-card">
|
||||
<h2 class="settings-title"> Commands </h2>
|
||||
<div class="settings-group">
|
||||
<div class="toggle-setting">
|
||||
Pre Launch
|
||||
<input
|
||||
type="text"
|
||||
class="input"
|
||||
ref="javaArgs"
|
||||
v-model="javaArgs"
|
||||
/>
|
||||
</div>
|
||||
<div class="toggle-setting">
|
||||
Wrapper
|
||||
<input
|
||||
type="text"
|
||||
class="input"
|
||||
ref="javaArgs"
|
||||
v-model="javaArgs"
|
||||
/>
|
||||
</div>
|
||||
<div class="toggle-setting">
|
||||
Post Launch
|
||||
<input
|
||||
type="text"
|
||||
class="input"
|
||||
ref="javaArgs"
|
||||
v-model="javaArgs"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</Card>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import {Card, Button, SearchIcon, Slider } from 'omorphia'
|
||||
import {BrowseIcon, PlayIcon} from "@/assets/icons";
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.settings-card {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 1rem;
|
||||
}
|
||||
|
||||
.settings-title {
|
||||
color: var(--color-contrast)
|
||||
}
|
||||
|
||||
.settings-group {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 0.5rem;
|
||||
}
|
||||
|
||||
.installation-input {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.installation-buttons {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
flex-wrap: wrap;
|
||||
align-items: center;
|
||||
gap: .5rem;
|
||||
margin: 0;
|
||||
|
||||
}
|
||||
|
||||
.sliders {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
flex-direction: row;
|
||||
gap: 1rem;
|
||||
width: 100%;
|
||||
|
||||
.slider {
|
||||
flex-grow: 1;
|
||||
}
|
||||
}
|
||||
|
||||
.toggle-setting {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
gap: 0.5rem;
|
||||
}
|
||||
|
||||
.card-divider {
|
||||
background-color: var(--color-button-bg);
|
||||
border: none;
|
||||
color: var(--color-button-bg);
|
||||
height: 1px;
|
||||
margin: var(--gap-sm) 0;
|
||||
}
|
||||
</style>
|
||||
6
theseus_gui/src/pages/instance/index.js
Normal file
6
theseus_gui/src/pages/instance/index.js
Normal file
@@ -0,0 +1,6 @@
|
||||
import Index from './Index.vue'
|
||||
import Mods from "./Mods.vue";
|
||||
import Options from "./Options.vue";
|
||||
import Logs from "./Logs.vue";
|
||||
|
||||
export { Index, Mods, Options, Logs }
|
||||
Reference in New Issue
Block a user