Rework login page to be AJAX/Vue.js based
This commit is contained in:
23
app/views/theme/base.pug
Normal file
23
app/views/theme/base.pug
Normal file
@@ -0,0 +1,23 @@
|
||||
doctype html
|
||||
html(lang='en')
|
||||
head
|
||||
title #{title || (_app && _app.name) || 'CoreID'}
|
||||
|
||||
block meta
|
||||
meta(charset='utf-8')
|
||||
meta(name='viewport' content='width=device-width, initial-scale=1, shrink-to-fit=no')
|
||||
meta(name='description' content=(description || 'CoreID is a self-hosted, next-generation identity server.'))
|
||||
meta(name='author' content='Garrett Mills (garrett@glmdev.tech)')
|
||||
|
||||
block style
|
||||
link(rel='stylesheet' href='/assets/lib/bootstrap/bootstrap-4.4.1.min.css')
|
||||
body
|
||||
.app-container
|
||||
block app
|
||||
block script
|
||||
script(src='/assets/lib/axios/axios.min.js')
|
||||
script(src='/assets/lib/jquery/jquery-3.4.1.slim.min.js')
|
||||
script(src='/assets/lib/popper/popper-1.16.0.min.js')
|
||||
script(src='/assets/lib/bootstrap/bootstrap-4.4.1.min.js')
|
||||
script(src='/assets/lib/vue/vue-2.6.11.js')
|
||||
script(src='/assets/lib/vues6/vues6.js')
|
||||
27
app/views/theme/public/base.pug
Normal file
27
app/views/theme/public/base.pug
Normal file
@@ -0,0 +1,27 @@
|
||||
extends ../base
|
||||
|
||||
block append style
|
||||
link(rel='stylesheet' href='/style-asset/public.css')
|
||||
|
||||
block append script
|
||||
script(type='module').
|
||||
import { components } from '/assets/app/components.js'
|
||||
import VuES6Loader from '/assets/lib/vues6/vues6.js'
|
||||
|
||||
const loader = new VuES6Loader(components)
|
||||
loader.load()
|
||||
|
||||
const app = new Vue({
|
||||
el: '#vue-app-base',
|
||||
data: !{JSON.stringify(vue_state) || '\{\}'}
|
||||
})
|
||||
|
||||
block app
|
||||
block content
|
||||
header.masthead
|
||||
.container.h-100
|
||||
.row.h-100.align-items-center
|
||||
.col-12.text-center
|
||||
block masthead
|
||||
#vue-app-base
|
||||
block vue
|
||||
Reference in New Issue
Block a user