@didaoktv/didaoui-uniapp 2.2.0 → 2.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/components/dd-package-sku/dd-package-sku.vue +277 -0
- package/components/dd-package-sku/package-sku.ts +124 -0
- package/index.ts +11 -3
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
- **帝王级配色** — 帝王金 `#F5A623` + 皇家蓝 `#2D4BA0` 双主色,暗色主题默认
|
|
8
8
|
- **玻璃拟态设计** — 多层级玻璃拟态效果,打造高端夜店沉浸感
|
|
9
|
-
- **
|
|
9
|
+
- **97 个精心打磨的组件** — 覆盖表单、导航、布局卡片、数据展示、浮层反馈、交互、画布七大类,含 KTV 业务组件(房态卡、账单明细、工单卡、日历、二维码)
|
|
10
10
|
- **Vue3 + TypeScript** — 完整类型定义,Composition API
|
|
11
11
|
- **多端兼容** — H5 / 微信小程序 / 抖音小程序 / Android / iOS
|
|
12
12
|
|
|
@@ -50,7 +50,7 @@ import { DdButton, DdInput } from '@didaoktv/didaoui-uniapp'
|
|
|
50
50
|
|
|
51
51
|
| 分类 | 数量 | 组件 |
|
|
52
52
|
| ----- | -- | --------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
53
|
-
| 表单输入 |
|
|
53
|
+
| 表单输入 | 25 | Button, CodeButton, Input, Form, Field, Switch, Checkbox, CheckboxGroup, Radio, RadioGroup, Stepper, SearchBar, Slider, DatePicker, Picker, Rate, Upload, Icon, Keyboard, NumberKeyboard, CarKeyboard, Cascader, GoodsSku, PackageSku, TreeSelect |
|
|
54
54
|
| 导航 | 14 | Navigation, TopNavbar, SegmentedTab, SwipeableTab, Drawer, Tabbar, TabbarItem, Backtop, Collapse, CollapseItem, DropdownMenu, DropdownItem, Sidebar, SidebarItem | |
|
|
55
55
|
| 布局/卡片 | 10 | Card, RoomCard, GoodsCard, FeatureGrid, Sticky, BillDetail, WorkorderCard, Calendar, Qrcode, SubmitBar |
|
|
56
56
|
| 数据展示 | 25 | Tag, StatCard, ChampionCard, Avatar, AvatarGroup, Badge, ListCell, Cell, CellGroup, CountDown, Divider, Image, Progress, Skeleton, EmptyState, Step, Steps, Text, Link, Copy, Album, Coupon, Parse, Markdown, Price |
|
|
@@ -0,0 +1,277 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<view class="dd-package-sku">
|
|
3
|
+
<view @click="open">
|
|
4
|
+
<slot name="trigger"></slot>
|
|
5
|
+
</view>
|
|
6
|
+
<dd-popup
|
|
7
|
+
v-model="show"
|
|
8
|
+
position="bottom"
|
|
9
|
+
round
|
|
10
|
+
:closeable="closeable"
|
|
11
|
+
@close="close"
|
|
12
|
+
>
|
|
13
|
+
<view class="dd-package-sku__container">
|
|
14
|
+
<view class="dd-package-sku__title">{{ title }}</view>
|
|
15
|
+
|
|
16
|
+
<scroll-view class="dd-package-sku__content" scroll-y>
|
|
17
|
+
<view v-for="group in groups" :key="group.id" class="dd-package-sku__group">
|
|
18
|
+
<view class="dd-package-sku__group__header">
|
|
19
|
+
<text class="dd-package-sku__group__header__name">{{ group.name }}</text>
|
|
20
|
+
<text class="dd-package-sku__group__header__hint">{{ hintText(group) }}</text>
|
|
21
|
+
</view>
|
|
22
|
+
<view class="dd-package-sku__group__list">
|
|
23
|
+
<view
|
|
24
|
+
v-for="item in group.items"
|
|
25
|
+
:key="item.id"
|
|
26
|
+
class="dd-package-sku__chip"
|
|
27
|
+
:class="{
|
|
28
|
+
'dd-package-sku__chip--active': isSelected(group, item),
|
|
29
|
+
'dd-package-sku__chip--disabled': itemDisabled(item),
|
|
30
|
+
'dd-package-sku__chip--fixed': isFixedGroup(group),
|
|
31
|
+
}"
|
|
32
|
+
@click="onItemClick(group, item)"
|
|
33
|
+
>
|
|
34
|
+
<text>{{ item.name }}</text>
|
|
35
|
+
<text v-if="surchargeText(item)" class="dd-package-sku__chip__surcharge">{{ surchargeText(item) }}</text>
|
|
36
|
+
<text v-if="itemDisabled(item)" class="dd-package-sku__chip__soldout">已售罄</text>
|
|
37
|
+
</view>
|
|
38
|
+
</view>
|
|
39
|
+
</view>
|
|
40
|
+
</scroll-view>
|
|
41
|
+
|
|
42
|
+
<view class="dd-package-sku__footer">
|
|
43
|
+
<text v-if="!canConfirmNow" class="dd-package-sku__footer__tip">{{ unmetTip }}</text>
|
|
44
|
+
<dd-button type="primary" :disabled="!canConfirmNow" @click="onConfirm">
|
|
45
|
+
{{ confirmText }}
|
|
46
|
+
</dd-button>
|
|
47
|
+
</view>
|
|
48
|
+
</view>
|
|
49
|
+
</dd-popup>
|
|
50
|
+
</view>
|
|
51
|
+
</template>
|
|
52
|
+
|
|
53
|
+
<script setup lang="ts">
|
|
54
|
+
/**
|
|
55
|
+
* 套餐可选组选择弹层(N选M 多选 + 加价 + 售罄置灰)
|
|
56
|
+
* - groups 通用形状,不绑业务 DTO;FIXED 组只读展示,OPTIONAL 组按 minSel/maxSel 校验
|
|
57
|
+
* - confirm emit { options:[{groupId,skuId}], surchargeFen, selectedText };确认后不自动关闭,由调用方 ref.close()
|
|
58
|
+
*/
|
|
59
|
+
import { computed, reactive, ref } from 'vue'
|
|
60
|
+
import DdPopup from '../dd-popup/dd-popup.vue'
|
|
61
|
+
import DdButton from '../dd-button/dd-button.vue'
|
|
62
|
+
import {
|
|
63
|
+
type PackageSkuGroup,
|
|
64
|
+
type PackageSkuItem,
|
|
65
|
+
type PackageSkuOption,
|
|
66
|
+
type PackageSkuSelections,
|
|
67
|
+
isFixed,
|
|
68
|
+
isItemDisabled,
|
|
69
|
+
groupHint,
|
|
70
|
+
groupMax,
|
|
71
|
+
isGroupSatisfied,
|
|
72
|
+
canConfirm as calcCanConfirm,
|
|
73
|
+
unmetText,
|
|
74
|
+
buildOptions,
|
|
75
|
+
computeSurchargeFen,
|
|
76
|
+
buildSelectedText,
|
|
77
|
+
surchargeLabel,
|
|
78
|
+
} from './package-sku'
|
|
79
|
+
|
|
80
|
+
interface Props {
|
|
81
|
+
/** 选择组列表 */
|
|
82
|
+
groups?: PackageSkuGroup[]
|
|
83
|
+
/** 弹层标题 */
|
|
84
|
+
title?: string
|
|
85
|
+
/** 确认按钮文字 */
|
|
86
|
+
confirmText?: string
|
|
87
|
+
/** 是否显示关闭弹窗按钮 */
|
|
88
|
+
closeable?: boolean
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
const props = withDefaults(defineProps<Props>(), {
|
|
92
|
+
groups: () => [],
|
|
93
|
+
title: '选择套餐内容',
|
|
94
|
+
confirmText: '确定',
|
|
95
|
+
closeable: true,
|
|
96
|
+
})
|
|
97
|
+
|
|
98
|
+
const emit = defineEmits<{
|
|
99
|
+
(e: 'open'): void
|
|
100
|
+
(e: 'confirm', val: { options: PackageSkuOption[]; surchargeFen: number; selectedText: string }): void
|
|
101
|
+
(e: 'close'): void
|
|
102
|
+
}>()
|
|
103
|
+
|
|
104
|
+
const show = ref(false)
|
|
105
|
+
/** 已选项:key = String(group.id) */
|
|
106
|
+
const selections = reactive<PackageSkuSelections>({})
|
|
107
|
+
|
|
108
|
+
const canConfirmNow = computed(() => calcCanConfirm(props.groups, selections))
|
|
109
|
+
const unmetTip = computed(() => unmetText(props.groups, selections))
|
|
110
|
+
|
|
111
|
+
// 模板内避免复杂表达式(小程序约束),逐一下沉为方法
|
|
112
|
+
function isFixedGroup(group: PackageSkuGroup): boolean {
|
|
113
|
+
return isFixed(group)
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
function itemDisabled(item: PackageSkuItem): boolean {
|
|
117
|
+
return isItemDisabled(item)
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
function hintText(group: PackageSkuGroup): string {
|
|
121
|
+
return groupHint(group)
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
function surchargeText(item: PackageSkuItem): string {
|
|
125
|
+
return surchargeLabel(item)
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
function isSelected(group: PackageSkuGroup, item: PackageSkuItem): boolean {
|
|
129
|
+
return (selections[String(group.id)] ?? []).includes(item.id)
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
function onItemClick(group: PackageSkuGroup, item: PackageSkuItem): void {
|
|
133
|
+
if (isFixed(group) || isItemDisabled(item)) return
|
|
134
|
+
const key = String(group.id)
|
|
135
|
+
const selected = selections[key] ?? []
|
|
136
|
+
const at = selected.indexOf(item.id)
|
|
137
|
+
if (at >= 0) {
|
|
138
|
+
selected.splice(at, 1)
|
|
139
|
+
} else if (selected.length >= groupMax(group)) {
|
|
140
|
+
uni.showToast({ title: `最多选择${groupMax(group)}项`, icon: 'none' })
|
|
141
|
+
return
|
|
142
|
+
} else {
|
|
143
|
+
selected.push(item.id)
|
|
144
|
+
}
|
|
145
|
+
selections[key] = selected
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
function reset(): void {
|
|
149
|
+
Object.keys(selections).forEach((key) => delete selections[key])
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
function open(): void {
|
|
153
|
+
show.value = true
|
|
154
|
+
emit('open')
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
function close(): void {
|
|
158
|
+
show.value = false
|
|
159
|
+
emit('close')
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
function onConfirm(): void {
|
|
163
|
+
if (!canConfirmNow.value) return
|
|
164
|
+
emit('confirm', {
|
|
165
|
+
options: buildOptions(props.groups, selections),
|
|
166
|
+
surchargeFen: computeSurchargeFen(props.groups, selections),
|
|
167
|
+
selectedText: buildSelectedText(props.groups, selections),
|
|
168
|
+
})
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
defineExpose({ open, close, reset })
|
|
172
|
+
</script>
|
|
173
|
+
|
|
174
|
+
<style lang="scss" scoped>
|
|
175
|
+
@import '../../scss/variables';
|
|
176
|
+
@import '../../scss/mixins';
|
|
177
|
+
|
|
178
|
+
.dd-package-sku {
|
|
179
|
+
background-color: var(--dd-bg-elevated, #{$dd-bg-elevated});
|
|
180
|
+
overflow: hidden;
|
|
181
|
+
|
|
182
|
+
&__container {
|
|
183
|
+
padding: 4rpx 30rpx;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
&__title {
|
|
187
|
+
padding: 30rpx 0 10rpx;
|
|
188
|
+
font-size: 32rpx;
|
|
189
|
+
font-weight: bold;
|
|
190
|
+
color: var(--dd-text-primary, #{$dd-text-primary});
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
&__content {
|
|
194
|
+
max-height: 640rpx;
|
|
195
|
+
padding-bottom: 10rpx;
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
&__group {
|
|
199
|
+
margin-bottom: 30rpx;
|
|
200
|
+
|
|
201
|
+
&__header {
|
|
202
|
+
display: flex;
|
|
203
|
+
flex-direction: row;
|
|
204
|
+
align-items: baseline;
|
|
205
|
+
justify-content: space-between;
|
|
206
|
+
margin-bottom: 20rpx;
|
|
207
|
+
|
|
208
|
+
&__name {
|
|
209
|
+
font-size: 28rpx;
|
|
210
|
+
color: var(--dd-text-primary, #{$dd-text-primary});
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
&__hint {
|
|
214
|
+
font-size: 24rpx;
|
|
215
|
+
color: var(--dd-text-tertiary, #{$dd-text-tertiary});
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
&__list {
|
|
220
|
+
display: flex;
|
|
221
|
+
flex-direction: row;
|
|
222
|
+
flex-wrap: wrap;
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
&__chip {
|
|
227
|
+
display: flex;
|
|
228
|
+
flex-direction: row;
|
|
229
|
+
align-items: center;
|
|
230
|
+
padding: 10rpx 20rpx;
|
|
231
|
+
border: 2rpx solid var(--dd-border-default, #{$dd-border-default});
|
|
232
|
+
border-radius: 10rpx;
|
|
233
|
+
margin-right: 20rpx;
|
|
234
|
+
margin-bottom: 20rpx;
|
|
235
|
+
font-size: 26rpx;
|
|
236
|
+
color: var(--dd-text-primary, #{$dd-text-primary});
|
|
237
|
+
background-color: var(--dd-bg-elevated, #{$dd-bg-elevated});
|
|
238
|
+
|
|
239
|
+
&--active {
|
|
240
|
+
border-color: var(--dd-primary, #{$dd-primary});
|
|
241
|
+
color: var(--dd-primary, #{$dd-primary});
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
&--disabled {
|
|
245
|
+
color: var(--dd-muted, #{$dd-muted});
|
|
246
|
+
border-color: var(--dd-border-default, #{$dd-border-default});
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
&--fixed {
|
|
250
|
+
color: var(--dd-text-secondary, #{$dd-text-secondary});
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
&__surcharge {
|
|
254
|
+
margin-left: 8rpx;
|
|
255
|
+
font-size: 24rpx;
|
|
256
|
+
color: var(--dd-error-400, #{$dd-error-400});
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
&__soldout {
|
|
260
|
+
margin-left: 8rpx;
|
|
261
|
+
font-size: 22rpx;
|
|
262
|
+
color: var(--dd-error-400, #{$dd-error-400});
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
&__footer {
|
|
267
|
+
padding: 20rpx 0 40rpx 0;
|
|
268
|
+
|
|
269
|
+
&__tip {
|
|
270
|
+
display: block;
|
|
271
|
+
margin-bottom: 16rpx;
|
|
272
|
+
font-size: 24rpx;
|
|
273
|
+
color: var(--dd-error-400, #{$dd-error-400});
|
|
274
|
+
}
|
|
275
|
+
}
|
|
276
|
+
}
|
|
277
|
+
</style>
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
// dd-package-sku 纯逻辑(可选组 N选M 校验/加价合计/文案),供组件与 scripts/package-sku-selfcheck.ts 共用
|
|
2
|
+
// ponytail: 通用形状不绑业务 DTO;qty 缺省视为不限量(enabled 缺省视为可选)
|
|
3
|
+
|
|
4
|
+
export interface PackageSkuItem {
|
|
5
|
+
id: string | number
|
|
6
|
+
name: string
|
|
7
|
+
/** 加价金额(分),0/缺省 = 不加价 */
|
|
8
|
+
priceFen?: number
|
|
9
|
+
/** 库存数量,<=0 置灰;缺省视为有货 */
|
|
10
|
+
qty?: number
|
|
11
|
+
/** false 置灰;缺省视为可用 */
|
|
12
|
+
enabled?: boolean
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export interface PackageSkuGroup {
|
|
16
|
+
id: string | number
|
|
17
|
+
name: string
|
|
18
|
+
/** 最少选择数,缺省 0 */
|
|
19
|
+
minSel?: number
|
|
20
|
+
/** 最多选择数,缺省 = items.length */
|
|
21
|
+
maxSel?: number
|
|
22
|
+
/** FIXED = 只读展示不可选;缺省 OPTIONAL */
|
|
23
|
+
groupType?: 'FIXED' | 'OPTIONAL'
|
|
24
|
+
items: PackageSkuItem[]
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export interface PackageSkuOption {
|
|
28
|
+
groupId: string | number
|
|
29
|
+
skuId: string | number
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/** 选择状态:key = String(group.id),value = 已选 item.id 数组 */
|
|
33
|
+
export type PackageSkuSelections = Record<string, (string | number)[]>
|
|
34
|
+
|
|
35
|
+
export function isFixed(group: PackageSkuGroup): boolean {
|
|
36
|
+
return group.groupType === 'FIXED'
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export function isItemDisabled(item: PackageSkuItem): boolean {
|
|
40
|
+
return item.enabled === false || (item.qty !== undefined && item.qty <= 0)
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export function groupMin(group: PackageSkuGroup): number {
|
|
44
|
+
return group.minSel ?? 0
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
export function groupMax(group: PackageSkuGroup): number {
|
|
48
|
+
return group.maxSel ?? group.items.length
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/** 组标题右侧文案:N选M / 选x~y项 / 最多选y项;FIXED 无文案 */
|
|
52
|
+
export function groupHint(group: PackageSkuGroup): string {
|
|
53
|
+
if (isFixed(group)) return ''
|
|
54
|
+
const min = groupMin(group)
|
|
55
|
+
const max = groupMax(group)
|
|
56
|
+
if (min === max) return `${group.items.length}选${max}`
|
|
57
|
+
if (min > 0) return `选${min}~${max}项`
|
|
58
|
+
return `最多选${max}项`
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
/** 组是否已选满最低要求(上限在点击时拦截,不会超) */
|
|
62
|
+
export function isGroupSatisfied(group: PackageSkuGroup, selections: PackageSkuSelections): boolean {
|
|
63
|
+
if (isFixed(group)) return true
|
|
64
|
+
const selected = selections[String(group.id)] ?? []
|
|
65
|
+
return selected.length >= groupMin(group)
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export function canConfirm(groups: PackageSkuGroup[], selections: PackageSkuSelections): boolean {
|
|
69
|
+
return groups.every((g) => isGroupSatisfied(g, selections))
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/** 首个未满足组的提示文案(全部满足返回空串) */
|
|
73
|
+
export function unmetText(groups: PackageSkuGroup[], selections: PackageSkuSelections): string {
|
|
74
|
+
for (const g of groups) {
|
|
75
|
+
if (isFixed(g)) continue
|
|
76
|
+
const need = groupMin(g) - (selections[String(g.id)] ?? []).length
|
|
77
|
+
if (need > 0) return `「${g.name}」还需选择 ${need} 项`
|
|
78
|
+
}
|
|
79
|
+
return ''
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export function buildOptions(groups: PackageSkuGroup[], selections: PackageSkuSelections): PackageSkuOption[] {
|
|
83
|
+
const options: PackageSkuOption[] = []
|
|
84
|
+
for (const g of groups) {
|
|
85
|
+
if (isFixed(g)) continue
|
|
86
|
+
for (const skuId of selections[String(g.id)] ?? []) {
|
|
87
|
+
options.push({ groupId: g.id, skuId })
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
return options
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
/** 已选 OPTIONAL 项加价合计(分) */
|
|
94
|
+
export function computeSurchargeFen(groups: PackageSkuGroup[], selections: PackageSkuSelections): number {
|
|
95
|
+
let sum = 0
|
|
96
|
+
for (const g of groups) {
|
|
97
|
+
if (isFixed(g)) continue
|
|
98
|
+
for (const skuId of selections[String(g.id)] ?? []) {
|
|
99
|
+
const item = g.items.find((it) => it.id === skuId)
|
|
100
|
+
sum += item?.priceFen ?? 0
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
return sum
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
/** 已选 OPTIONAL 项名称顿号拼接 */
|
|
107
|
+
export function buildSelectedText(groups: PackageSkuGroup[], selections: PackageSkuSelections): string {
|
|
108
|
+
const names: string[] = []
|
|
109
|
+
for (const g of groups) {
|
|
110
|
+
if (isFixed(g)) continue
|
|
111
|
+
for (const skuId of selections[String(g.id)] ?? []) {
|
|
112
|
+
const item = g.items.find((it) => it.id === skuId)
|
|
113
|
+
if (item) names.push(item.name)
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
return names.join('、')
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
/** 加价标签:「+¥X」(元,去尾零);无加价返回空串 */
|
|
120
|
+
export function surchargeLabel(item: PackageSkuItem): string {
|
|
121
|
+
const fen = item.priceFen ?? 0
|
|
122
|
+
if (fen <= 0) return ''
|
|
123
|
+
return `+¥${fen / 100}`
|
|
124
|
+
}
|
package/index.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { App } from 'vue'
|
|
2
2
|
|
|
3
|
-
// === Input (
|
|
3
|
+
// === Input (25) ===
|
|
4
4
|
import DdButton from './components/dd-button/dd-button.vue'
|
|
5
5
|
import DdCodeButton from './components/dd-code-button/dd-code-button.vue'
|
|
6
6
|
import DdInput from './components/dd-input/dd-input.vue'
|
|
@@ -24,6 +24,7 @@ import DdNumberKeyboard from './components/dd-number-keyboard/dd-number-keyboard
|
|
|
24
24
|
import DdCarKeyboard from './components/dd-car-keyboard/dd-car-keyboard.vue'
|
|
25
25
|
import DdCascader from './components/dd-cascader/dd-cascader.vue'
|
|
26
26
|
import DdGoodsSku from './components/dd-goods-sku/dd-goods-sku.vue'
|
|
27
|
+
import DdPackageSku from './components/dd-package-sku/dd-package-sku.vue'
|
|
27
28
|
import DdTreeSelect from './components/dd-tree-select/dd-tree-select.vue'
|
|
28
29
|
|
|
29
30
|
// === Navigation (14) ===
|
|
@@ -116,7 +117,7 @@ const components = {
|
|
|
116
117
|
DdButton, DdCodeButton, DdInput, DdSwitch, DdCheckbox, DdCheckboxGroup, DdRadio, DdRadioGroup, DdForm,
|
|
117
118
|
DdSearchBar, DdSlider, DdStepper, DdDatePicker, DdField,
|
|
118
119
|
DdPicker, DdRate, DdUpload, DdIcon,
|
|
119
|
-
DdKeyboard, DdNumberKeyboard, DdCarKeyboard, DdCascader, DdGoodsSku, DdTreeSelect,
|
|
120
|
+
DdKeyboard, DdNumberKeyboard, DdCarKeyboard, DdCascader, DdGoodsSku, DdPackageSku, DdTreeSelect,
|
|
120
121
|
DdNavigation, DdTopNavbar, DdSegmentedTab, DdSwipeableTab,
|
|
121
122
|
DdDrawer, DdTabbar, DdTabbarItem, DdBacktop,
|
|
122
123
|
DdCollapse, DdCollapseItem, DdDropdownMenu, DdDropdownItem,
|
|
@@ -148,7 +149,7 @@ export {
|
|
|
148
149
|
DdButton, DdCodeButton, DdInput, DdSwitch, DdCheckbox, DdCheckboxGroup, DdRadio, DdRadioGroup, DdForm,
|
|
149
150
|
DdSearchBar, DdSlider, DdStepper, DdDatePicker, DdField,
|
|
150
151
|
DdPicker, DdRate, DdUpload, DdIcon,
|
|
151
|
-
DdKeyboard, DdNumberKeyboard, DdCarKeyboard, DdCascader, DdGoodsSku, DdTreeSelect,
|
|
152
|
+
DdKeyboard, DdNumberKeyboard, DdCarKeyboard, DdCascader, DdGoodsSku, DdPackageSku, DdTreeSelect,
|
|
152
153
|
DdNavigation, DdTopNavbar, DdSegmentedTab, DdSwipeableTab,
|
|
153
154
|
DdDrawer, DdTabbar, DdTabbarItem, DdBacktop,
|
|
154
155
|
DdCollapse, DdCollapseItem, DdDropdownMenu, DdDropdownItem,
|
|
@@ -176,5 +177,12 @@ export type {
|
|
|
176
177
|
DdFormContext,
|
|
177
178
|
} from './components/dd-form/rules'
|
|
178
179
|
|
|
180
|
+
// 套餐可选组类型(dd-package-sku 配套)
|
|
181
|
+
export type {
|
|
182
|
+
PackageSkuItem,
|
|
183
|
+
PackageSkuGroup,
|
|
184
|
+
PackageSkuOption,
|
|
185
|
+
} from './components/dd-package-sku/package-sku'
|
|
186
|
+
|
|
179
187
|
// 图标元数据(供 demo/文档消费,与 dd-icon.vue 内 SCSS &-- 规则保持一致)
|
|
180
188
|
export { iconNames, iconGroups, iconLabels } from './components/dd-icon/dd-icon.vue'
|