-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
31 changed files
with
142 additions
and
106 deletions.
There are no files selected for viewing
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import { Context } from '@koishijs/client' | ||
import Home from './home.vue' | ||
|
||
export default function (ctx: Context) { | ||
ctx.page({ | ||
path: '/', | ||
name: '欢迎', | ||
icon: 'activity:home', | ||
order: 1000, | ||
component: Home, | ||
}) | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import { Context } from '@koishijs/client' | ||
import Layout from './layout.vue' | ||
|
||
export default function (ctx: Context) { | ||
ctx.slot({ | ||
type: 'layout', | ||
component: Layout, | ||
order: -1000, | ||
}) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { Context } from '@koishijs/client' | ||
import Status from './status.vue' | ||
import Loading from './loading.vue' | ||
|
||
export default function (ctx: Context) { | ||
ctx.slot({ | ||
type: 'status', | ||
component: Status, | ||
order: -1000, | ||
}) | ||
|
||
ctx.slot({ | ||
type: 'status-right', | ||
component: Loading, | ||
}) | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import { Context } from '@koishijs/client' | ||
|
||
import './index.scss' | ||
|
||
export default function (ctx: Context) { | ||
ctx.theme({ | ||
id: 'default-light', | ||
name: 'Default Light', | ||
}) | ||
|
||
ctx.theme({ | ||
id: 'default-dark', | ||
name: 'Default Dark', | ||
}) | ||
|
||
ctx.theme({ | ||
id: 'hc-light', | ||
name: 'High Contrast Light', | ||
}) | ||
|
||
ctx.theme({ | ||
id: 'hc-dark', | ||
name: 'High Contrast Dark', | ||
}) | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 1 addition & 5 deletions
6
packages/client/app/theme/layouts/utils.ts → packages/client/app/theme/activity/utils.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,61 +1,10 @@ | ||
import { Context } from '@koishijs/client' | ||
import Home from './pages/home.vue' | ||
import App from './layouts/index.vue' | ||
import Layout from './layouts/layout.vue' | ||
import Status from './layouts/status.vue' | ||
import Progress from './layouts/status-loading.vue' | ||
|
||
import './styles/index.scss' | ||
import App from './index.vue' | ||
|
||
export default function (ctx: Context) { | ||
ctx.theme({ | ||
id: 'default-light', | ||
name: 'Default Light', | ||
}) | ||
|
||
ctx.theme({ | ||
id: 'default-dark', | ||
name: 'Default Dark', | ||
}) | ||
|
||
ctx.theme({ | ||
id: 'hc-light', | ||
name: 'High Contrast Light', | ||
}) | ||
|
||
ctx.theme({ | ||
id: 'hc-dark', | ||
name: 'High Contrast Dark', | ||
}) | ||
|
||
ctx.page({ | ||
path: '/', | ||
name: '欢迎', | ||
icon: 'activity:home', | ||
order: 1000, | ||
component: Home, | ||
}) | ||
|
||
ctx.slot({ | ||
type: 'status-right', | ||
component: Progress, | ||
}) | ||
|
||
ctx.slot({ | ||
type: 'root', | ||
component: App, | ||
order: -1000, | ||
}) | ||
|
||
ctx.slot({ | ||
type: 'layout', | ||
component: Layout, | ||
order: -1000, | ||
}) | ||
|
||
ctx.slot({ | ||
type: 'status', | ||
component: Status, | ||
order: -1000, | ||
}) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<template> | ||
<activity-bar></activity-bar> | ||
<router-view v-if="loaded" #="{ Component }"> | ||
<keep-alive> | ||
<component :is="Component"></component> | ||
</keep-alive> | ||
</router-view> | ||
<div class="loading" v-else v-loading="true" element-loading-text="正在加载数据……"></div> | ||
<status-bar></status-bar> | ||
<k-slot name="global"></k-slot> | ||
</template> | ||
|
||
<script lang="ts" setup> | ||
import { store } from '@koishijs/client' | ||
import { computed } from 'vue' | ||
import { useRoute } from 'vue-router' | ||
import ActivityBar from './activity/index.vue' | ||
import StatusBar from './status.vue' | ||
const route = useRoute() | ||
const loaded = computed(() => { | ||
if (!route.meta.activity?.fields) return true | ||
return route.meta.activity.fields.every((key) => store[key]) | ||
}) | ||
</script> |
This file was deleted.
Oops, something went wrong.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters