diff --git a/admin-fe/package.json b/admin-fe/package.json index 051fd3f..ae2f49d 100644 --- a/admin-fe/package.json +++ b/admin-fe/package.json @@ -20,9 +20,10 @@ "@types/node": "^18.11.10", "@vitejs/plugin-vue": "^3.2.0", "@vitejs/plugin-vue-jsx": "^2.1.1", - "typescript": "^4.9.3", - "vite": "^3.2.4", "less": "^4.1.3", + "typescript": "^4.9.3", + "unplugin-vue-define-options": "^1.0.0", + "vite": "^3.2.4", "vue-tsc": "^1.0.11" } } diff --git a/admin-fe/src/assets/app.css b/admin-fe/src/assets/app.less similarity index 74% rename from admin-fe/src/assets/app.css rename to admin-fe/src/assets/app.less index ab97519..a6d3ce4 100644 --- a/admin-fe/src/assets/app.css +++ b/admin-fe/src/assets/app.less @@ -38,6 +38,8 @@ --info-color: #1890ff; --info-color-deprecated-bg: #e6f7ff; --info-color-deprecated-border: #91d5ff; + --placeholder-color: #ccc; + --border-color: #d9d9d9; --primary-color-text: #333; --font-size: 14px; @@ -48,7 +50,8 @@ --border-radius-middle: calc(var(--border-radius) + 2px); --border-radius-large: calc(var(--border-radius) + 3px); - --header-height: 80px; + --header-bg: #001529; + --header-height: 50px; --left-menu-width: 200px; } @@ -119,13 +122,55 @@ body { .pointer-cursor { cursor: pointer; } -table{ - width: 100%; - border-left: solid 1px #eee; - border-top: solid 1px #eee; + +.table-wrapper { + .table-toolbar{ + display: flex; + justify-content: space-between; + margin-bottom: 20px; + } + table { + width: 100%; + border: solid 1px #eee; + border-collapse: collapse; + font-size: 13px; + } + th{ + background-color: #f5f7fa; + } + td, th { + text-align: left; + border-bottom: solid 1px #eee; + padding: 6px 8px; + } + tr{ + &:hover{ + background-color: #f5f7fa; + } + } } -td,th { - border-right: solid 1px #eee; - border-bottom: solid 1px #eee; - padding:2px 4px; + +.page-wrapper { + margin: 20px 0; + font-size: 12px; + text-align: right; + + .page-item { + cursor: pointer; + border: solid 1px var(--primary-2); + border-radius: var(--border-radius-middle); + display: inline-block; + padding: 4px 6px; + margin: 0 5px; + min-width: 26px; + text-align: center; + + &:hover, &.current-page { + border-color: var(--primary-color); + color: var(--primary-color) + } + } +} +.display-flex{ + display: flex; } \ No newline at end of file diff --git a/admin-fe/src/components/button/Index.vue b/admin-fe/src/components/button/Index.vue new file mode 100644 index 0000000..ffc8996 --- /dev/null +++ b/admin-fe/src/components/button/Index.vue @@ -0,0 +1,94 @@ + + + + + \ No newline at end of file diff --git a/admin-fe/src/components/icon/ArrowDown.vue b/admin-fe/src/components/icon/ArrowDown.vue new file mode 100644 index 0000000..bb1e5dc --- /dev/null +++ b/admin-fe/src/components/icon/ArrowDown.vue @@ -0,0 +1,17 @@ + + + \ No newline at end of file diff --git a/admin-fe/src/components/icon/Loading.vue b/admin-fe/src/components/icon/Loading.vue new file mode 100644 index 0000000..424a154 --- /dev/null +++ b/admin-fe/src/components/icon/Loading.vue @@ -0,0 +1,18 @@ + + + \ No newline at end of file diff --git a/admin-fe/src/components/input/input.vue b/admin-fe/src/components/input/input.vue index 1c60bda..0be918a 100644 --- a/admin-fe/src/components/input/input.vue +++ b/admin-fe/src/components/input/input.vue @@ -24,144 +24,151 @@ import Eye from "../icon/Eye.vue"; import EyeClose from "../icon/EyeClose.vue"; interface PInputEvents { - 'update:modelValue': (value: string) => void + 'update:modelValue': (value: any) => void } type PInputProps = { - placeholder?: string - modelValue?: string - type?: 'text' | 'password' | 'textarea' + placeholder?: string + modelValue?: any + type?: 'text' | 'password' | 'textarea' } const props = defineProps() const emit = defineEmits() const slots = useSlots() const state = reactive({ - focus: false, - hover: false, - passwordVisible: false + focus: false, + hover: false, + passwordVisible: false }) const inputType = computed(() => { - const type = props.type || 'text'; - if (type === 'password' && state.passwordVisible) return 'text'; - return type; + const type = props.type || 'text'; + if (type === 'password' && state.passwordVisible) return 'text'; + return type; }) const value = computed({ - get() { - return props.modelValue - }, - set(value) { - emit('update:modelValue', value) - } + get() { + return props.modelValue + }, + set(value) { + emit('update:modelValue', value) + } }) \ No newline at end of file diff --git a/admin-fe/src/components/modal/modal.vue b/admin-fe/src/components/modal/modal.vue index 73fe993..67a02e8 100644 --- a/admin-fe/src/components/modal/modal.vue +++ b/admin-fe/src/components/modal/modal.vue @@ -1,7 +1,9 @@