Skip to content

Commit

Permalink
feat(client): enhance theme css vars
Browse files Browse the repository at this point in the history
  • Loading branch information
shigma committed May 22, 2023
1 parent 5614aaa commit 856f49c
Show file tree
Hide file tree
Showing 38 changed files with 522 additions and 544 deletions.
8 changes: 4 additions & 4 deletions packages/client/client/components/common/k-button.vue
Original file line number Diff line number Diff line change
Expand Up @@ -65,18 +65,18 @@ function onClick(event: MouseEvent) {
&.disabled {
cursor: default;
}
// default: transparent & framed
color: var(--fg2);
border: 1px solid var(--border);
border: 1px solid var(--k-color-border);
background-color: transparent;
&.disabled {
color: var(--disabled);
border-color: var(--border);
border-color: var(--k-color-border);
}
&:hover:not(.disabled) {
color: var(--fg1);
border: 1px solid var(--border-dark);
background-color: var(--bg1);
border: 1px solid var(--k-color-border);
}
&.solid {
Expand Down
6 changes: 3 additions & 3 deletions packages/client/client/components/layout/card.vue
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ $paddingY: 1.5rem;
border-radius: 8px;
overflow: hidden;
position: relative;
background-color: var(--card-bg);
border: 1px solid var(--card-border);
box-shadow: var(--card-shadow);
background-color: var(--k-card-bg);
border: 1px solid var(--k-card-border);
box-shadow: var(--k-card-shadow);
transition: var(--color-transition);
header {
Expand Down
2 changes: 1 addition & 1 deletion packages/client/client/components/layout/empty.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
.image {
width: 10rem;
color: var(--page-bg);
color: var(--k-page-bg);
transition: color 0.3s ease;
svg {
Expand Down
2 changes: 1 addition & 1 deletion packages/client/client/components/layout/tab-item.vue
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ defineProps<{
text-overflow: ellipsis;
&.active {
background-color: var(--hover-bg);
background-color: var(--k-hover-bg);
}
}
Expand Down
7 changes: 5 additions & 2 deletions packages/client/client/components/slot.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,11 @@ const KSlotItem = defineComponent({
})

function defineSlotComponent(name: string) {
return defineComponent((_, { attrs, slots }) => {
return () => h(KSlot, { name, data: attrs, single: true }, slots)
return defineComponent({
inheritAttrs: false,
setup(_, { slots, attrs }) {
return () => h(KSlot, { name, data: attrs, single: true }, slots)
},
})
}

Expand Down
2 changes: 0 additions & 2 deletions packages/client/client/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ import { initTask } from './loader'
import { Context } from './context'
import { createI18n } from 'vue-i18n'

import './styles/index.scss'

export * from './activity'
export * from './components'
export * from './config'
Expand Down
4 changes: 2 additions & 2 deletions packages/client/client/settings/index.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<k-layout main="darker page-settings">
<k-layout main="page-settings">
<template #left>
<el-scrollbar>
<el-tree
Expand Down Expand Up @@ -57,7 +57,7 @@ function handleClick(tree: Tree) {
const path = computed({
get() {
const name = route.params.name.toString()
const name = route.params.name?.toString()
return name in components ? name : ''
},
set(value) {
Expand Down
42 changes: 0 additions & 42 deletions packages/client/client/styles/aside.scss

This file was deleted.

Loading

0 comments on commit 856f49c

Please sign in to comment.