feat: 优化 diy editor

This commit is contained in:
xingyu4j
2025-11-05 18:31:37 +08:00
parent f60069d662
commit 56ae9c0230
45 changed files with 213 additions and 332 deletions

View File

@@ -161,25 +161,22 @@ function handleProductCategorySelected(id: number) {
@ok="handleSubmit"
>
<div class="flex h-[500px] gap-2">
<div class="flex flex-col">
<!-- 左侧分组列表 -->
<div
class="h-full overflow-y-auto border-r border-gray-200 pr-2"
ref="groupScrollbar"
<!-- 左侧分组列表 -->
<div
class="flex h-full flex-col overflow-y-auto border-r border-gray-200 pr-2"
ref="groupScrollbar"
>
<Button
v-for="(group, groupIndex) in APP_LINK_GROUP_LIST"
:key="groupIndex"
class="!ml-0 mb-1 mr-4 !justify-start"
:class="[{ active: activeGroup === group.name }]"
ref="groupBtnRefs"
:type="activeGroup === group.name ? 'primary' : 'default'"
@click="handleGroupSelected(group.name)"
>
<Button
v-for="(group, groupIndex) in APP_LINK_GROUP_LIST"
:key="groupIndex"
class="!ml-0 mb-1 mr-4 !justify-start"
:class="[{ active: activeGroup === group.name }]"
ref="groupBtnRefs"
:type="activeGroup === group.name ? 'primary' : 'default'"
:ghost="activeGroup !== group.name"
@click="handleGroupSelected(group.name)"
>
{{ group.name }}
</Button>
</div>
{{ group.name }}
</Button>
</div>
<!-- 右侧链接列表 -->
<div

View File

@@ -48,17 +48,13 @@ watch(
<template>
<Input v-model:value="appLink" placeholder="输入或选择链接">
<template #addonAfter>
<Button @click="handleOpenDialog" class="!border-none">选择</Button>
<Button
@click="handleOpenDialog"
class="!border-none !bg-transparent !p-0"
>
选择
</Button>
</template>
</Input>
<AppLinkSelectDialog ref="dialogRef" @change="handleLinkSelected" />
</template>
<style scoped lang="scss">
:deep(.ant-input-group-addon) {
padding: 0;
background: transparent;
border: 0;
}
</style>