mirror of
https://github.com/yuzu-emu/liftinstall.git
synced 2024-11-29 10:54:20 +01:00
ui: use Buefy components to...
... beautify the UI
This commit is contained in:
parent
9a28807423
commit
e83cf6cf4e
@ -17,31 +17,7 @@ function progressSimulation (res) {
|
|||||||
}, 1500)
|
}, 1500)
|
||||||
}
|
}
|
||||||
|
|
||||||
app.get('/api/attrs', (req, res) => {
|
function returnConfig (res) {
|
||||||
res.send(
|
|
||||||
`var base_attributes = {"name":"yuzu","target_url":"https://raw.githubusercontent.com/j-selby/test-installer/master/config.linux.v2.toml"};`
|
|
||||||
)
|
|
||||||
})
|
|
||||||
|
|
||||||
app.get('/api/dark-mode', (req, res) => {
|
|
||||||
res.json(false)
|
|
||||||
})
|
|
||||||
|
|
||||||
app.get('/api/installation-status', (req, res) => {
|
|
||||||
res.json({
|
|
||||||
database: { packages: [], shortcuts: [] },
|
|
||||||
install_path: null,
|
|
||||||
preexisting_install: false,
|
|
||||||
is_launcher: false,
|
|
||||||
launcher_path: null
|
|
||||||
})
|
|
||||||
})
|
|
||||||
|
|
||||||
app.get('/api/default-path', (req, res) => {
|
|
||||||
res.json({ path: '/tmp/test/' })
|
|
||||||
})
|
|
||||||
|
|
||||||
app.get('/api/config', (req, res) => {
|
|
||||||
res.json({
|
res.json({
|
||||||
installing_message:
|
installing_message:
|
||||||
'Test Banner <strong>Bold</strong> <pre>Code block</pre> <i>Italic</i> <del>Strike</del>',
|
'Test Banner <strong>Bold</strong> <pre>Code block</pre> <i>Italic</i> <del>Strike</del>',
|
||||||
@ -73,6 +49,36 @@ app.get('/api/config', (req, res) => {
|
|||||||
],
|
],
|
||||||
hide_advanced: false
|
hide_advanced: false
|
||||||
})
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
app.get('/api/attrs', (req, res) => {
|
||||||
|
res.send(
|
||||||
|
`var base_attributes = {"name":"yuzu","target_url":"https://raw.githubusercontent.com/j-selby/test-installer/master/config.linux.v2.toml"};`
|
||||||
|
)
|
||||||
|
})
|
||||||
|
|
||||||
|
app.get('/api/dark-mode', (req, res) => {
|
||||||
|
res.json(false)
|
||||||
|
})
|
||||||
|
|
||||||
|
app.get('/api/installation-status', (req, res) => {
|
||||||
|
res.json({
|
||||||
|
database: { packages: [], shortcuts: [] },
|
||||||
|
install_path: null,
|
||||||
|
preexisting_install: false,
|
||||||
|
is_launcher: false,
|
||||||
|
launcher_path: null
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
app.get('/api/default-path', (req, res) => {
|
||||||
|
res.json({ path: '/tmp/test/' })
|
||||||
|
})
|
||||||
|
|
||||||
|
app.get('/api/config', (req, res) => {
|
||||||
|
setTimeout(() => {
|
||||||
|
returnConfig(res)
|
||||||
|
}, 3000)
|
||||||
})
|
})
|
||||||
|
|
||||||
app.post('/api/start-install', (req, res) => {
|
app.post('/api/start-install', (req, res) => {
|
||||||
|
@ -2,9 +2,11 @@ import Vue from 'vue'
|
|||||||
import App from './App.vue'
|
import App from './App.vue'
|
||||||
import router from './router'
|
import router from './router'
|
||||||
import { ajax, stream_ajax } from './helpers'
|
import { ajax, stream_ajax } from './helpers'
|
||||||
|
import Buefy from 'buefy'
|
||||||
import 'buefy/dist/buefy.css'
|
import 'buefy/dist/buefy.css'
|
||||||
|
|
||||||
Vue.config.productionTip = false
|
Vue.config.productionTip = false
|
||||||
|
Vue.use(Buefy)
|
||||||
|
|
||||||
// Borrowed from http://tobyho.com/2012/07/27/taking-over-console-log/
|
// Borrowed from http://tobyho.com/2012/07/27/taking-over-console-log/
|
||||||
function intercept (method) {
|
function intercept (method) {
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
<h4 class="subtitle">Downloading config...</h4>
|
<h4 class="subtitle">Downloading config...</h4>
|
||||||
|
|
||||||
<br />
|
<br />
|
||||||
<progress class="progress is-info is-medium" value="0" max="100">
|
<progress class="progress is-info is-medium" max="100">
|
||||||
0%
|
0%
|
||||||
</progress>
|
</progress>
|
||||||
</div>
|
</div>
|
||||||
|
@ -1,9 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="column has-padding">
|
<div class="column has-padding">
|
||||||
<h4 class="subtitle">An error occurred:</h4>
|
<b-message title="An error occurred" type="is-danger" :closable="false">{{ msg }}</b-message>
|
||||||
|
|
||||||
<pre class="pre-wrap">{{ msg }}</pre>
|
|
||||||
|
|
||||||
<div class="field is-grouped is-right-floating is-bottom-floating">
|
<div class="field is-grouped is-right-floating is-bottom-floating">
|
||||||
<p class="control">
|
<p class="control">
|
||||||
<a class="button is-primary is-medium" v-if="remaining" v-on:click="go_back">Back</a>
|
<a class="button is-primary is-medium" v-if="remaining" v-on:click="go_back">Back</a>
|
||||||
|
@ -8,8 +8,9 @@
|
|||||||
<div class="tile is-child">
|
<div class="tile is-child">
|
||||||
<div class="box clickable-box" v-on:click.capture.stop="Lpackage.default = !Lpackage.default">
|
<div class="box clickable-box" v-on:click.capture.stop="Lpackage.default = !Lpackage.default">
|
||||||
<label class="checkbox">
|
<label class="checkbox">
|
||||||
<input type="checkbox" v-model="Lpackage.default" />
|
<b-checkbox v-model="Lpackage.default">
|
||||||
{{ Lpackage.name }}
|
{{ Lpackage.name }}
|
||||||
|
</b-checkbox>
|
||||||
<span v-if="Lpackage.installed"><i>(installed)</i></span>
|
<span v-if="Lpackage.installed"><i>(installed)</i></span>
|
||||||
</label>
|
</label>
|
||||||
<p>
|
<p>
|
||||||
|
Loading…
Reference in New Issue
Block a user