Add تنظیمات وبسایت before پیکربندی with landing_* subsections, and show unit addon on numeric setting fields. Co-authored-by: Cursor <cursoragent@cursor.com>
64 lines
1.8 KiB
Vue
64 lines
1.8 KiB
Vue
<template>
|
|
<div class="website-settings">
|
|
<BasicMainCard>
|
|
<div class="flex h-full min-h-0 flex-col md:flex-row">
|
|
<BasicMenu
|
|
width="100%"
|
|
:menu="menu"
|
|
mode="horizontal"
|
|
class="website-settings__menu website-settings__menu--mobile overflow-auto md:hidden"
|
|
/>
|
|
<BasicMenu
|
|
width="17rem"
|
|
:menu="menu"
|
|
class="website-settings__menu website-settings__menu--side hidden min-w-[17rem] overflow-auto md:inline"
|
|
/>
|
|
<RouterView
|
|
:key="route.name"
|
|
class="mt-5 min-h-0 w-full flex-1 overflow-hidden md:mr-5 md:mt-0"
|
|
/>
|
|
</div>
|
|
</BasicMainCard>
|
|
</div>
|
|
</template>
|
|
|
|
<script setup lang="ts">
|
|
import { computed } from 'vue'
|
|
import { useRoute } from 'vue-router'
|
|
import BasicMenu from '@/components/BasicMenu/index.vue'
|
|
import { useRouterStore } from '@core/stores/router'
|
|
import { get } from 'lodash'
|
|
import type { RouteRecordRaw } from 'vue-router'
|
|
|
|
const routerStore = useRouterStore()
|
|
const route = useRoute()
|
|
|
|
const menu = computed(() => {
|
|
const item = routerStore.routes.find((row) => row.name === 'websiteSettings')
|
|
const children = get(item, 'children[0].children', []) as RouteRecordRaw[]
|
|
return children
|
|
.filter((child) => !child.meta?.hideMenu)
|
|
.sort((a, b) => (Number(a.meta?.order) || 99) - (Number(b.meta?.order) || 99))
|
|
})
|
|
</script>
|
|
|
|
<style scoped lang="less">
|
|
.website-settings__menu {
|
|
:deep(.ant-menu-item),
|
|
:deep(.ant-menu-submenu-title) {
|
|
height: auto !important;
|
|
min-height: 2.5rem;
|
|
line-height: 1.35 !important;
|
|
white-space: normal !important;
|
|
padding-block: 0.55rem !important;
|
|
}
|
|
|
|
:deep(.ant-menu-title-content) {
|
|
white-space: normal !important;
|
|
overflow: visible !important;
|
|
text-overflow: clip !important;
|
|
line-height: 1.35;
|
|
}
|
|
}
|
|
</style>
|