@xihan-ui/vue 1.0.0-alpha.1 → 1.0.0-alpha.2
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/CHANGELOG.md +91 -0
- package/dist/components/affix/affix.d.ts +10 -6
- package/dist/components/affix/affix.d.ts.map +1 -1
- package/dist/components/affix/affix.js +1 -0
- package/dist/components/affix/affix.js.map +1 -1
- package/dist/components/anchor/anchor.d.ts +1 -1
- package/dist/components/back-top/back-top.d.ts +11 -7
- package/dist/components/back-top/back-top.d.ts.map +1 -1
- package/dist/components/back-top/back-top.js +1 -0
- package/dist/components/back-top/back-top.js.map +1 -1
- package/dist/components/calendar/calendar.d.ts +21 -17
- package/dist/components/calendar/calendar.d.ts.map +1 -1
- package/dist/components/calendar/calendar.js +1 -0
- package/dist/components/calendar/calendar.js.map +1 -1
- package/dist/components/carousel/carousel.d.ts +17 -13
- package/dist/components/carousel/carousel.d.ts.map +1 -1
- package/dist/components/carousel/carousel.js +1 -0
- package/dist/components/carousel/carousel.js.map +1 -1
- package/dist/components/cascader/cascader.d.ts +32 -22
- package/dist/components/cascader/cascader.d.ts.map +1 -1
- package/dist/components/cascader/cascader.js +2 -0
- package/dist/components/cascader/cascader.js.map +1 -1
- package/dist/components/checkbox-group/checkbox-group.d.ts +10 -4
- package/dist/components/checkbox-group/checkbox-group.d.ts.map +1 -1
- package/dist/components/checkbox-group/checkbox-group.js +1 -0
- package/dist/components/checkbox-group/checkbox-group.js.map +1 -1
- package/dist/components/clipboard/clipboard.d.ts +14 -9
- package/dist/components/clipboard/clipboard.d.ts.map +1 -1
- package/dist/components/clipboard/clipboard.js +1 -0
- package/dist/components/clipboard/clipboard.js.map +1 -1
- package/dist/components/color-picker/color-picker.d.ts +28 -24
- package/dist/components/color-picker/color-picker.d.ts.map +1 -1
- package/dist/components/color-picker/color-picker.js +1 -0
- package/dist/components/color-picker/color-picker.js.map +1 -1
- package/dist/components/combobox/combobox.d.ts +13 -6
- package/dist/components/combobox/combobox.d.ts.map +1 -1
- package/dist/components/combobox/combobox.js +1 -0
- package/dist/components/combobox/combobox.js.map +1 -1
- package/dist/components/composer/composer.d.ts +11 -7
- package/dist/components/composer/composer.d.ts.map +1 -1
- package/dist/components/composer/composer.js +1 -0
- package/dist/components/composer/composer.js.map +1 -1
- package/dist/components/context-menu/context-menu.d.ts +18 -8
- package/dist/components/context-menu/context-menu.d.ts.map +1 -1
- package/dist/components/context-menu/context-menu.js +2 -0
- package/dist/components/context-menu/context-menu.js.map +1 -1
- package/dist/components/countdown/countdown.d.ts +9 -5
- package/dist/components/countdown/countdown.d.ts.map +1 -1
- package/dist/components/countdown/countdown.js +1 -0
- package/dist/components/countdown/countdown.js.map +1 -1
- package/dist/components/date-field/date-field.d.ts +21 -11
- package/dist/components/date-field/date-field.d.ts.map +1 -1
- package/dist/components/date-field/date-field.js +2 -0
- package/dist/components/date-field/date-field.js.map +1 -1
- package/dist/components/date-picker/date-picker.d.ts +46 -32
- package/dist/components/date-picker/date-picker.d.ts.map +1 -1
- package/dist/components/date-picker/date-picker.js +2 -0
- package/dist/components/date-picker/date-picker.js.map +1 -1
- package/dist/components/descriptions/descriptions.d.ts +1 -1
- package/dist/components/dialog/dialog.d.ts +15 -11
- package/dist/components/dialog/dialog.d.ts.map +1 -1
- package/dist/components/dialog/dialog.js +1 -0
- package/dist/components/dialog/dialog.js.map +1 -1
- package/dist/components/drawer/drawer.d.ts +15 -11
- package/dist/components/drawer/drawer.d.ts.map +1 -1
- package/dist/components/drawer/drawer.js +1 -0
- package/dist/components/drawer/drawer.js.map +1 -1
- package/dist/components/dynamic-input/dynamic-input.d.ts +17 -13
- package/dist/components/dynamic-input/dynamic-input.d.ts.map +1 -1
- package/dist/components/dynamic-input/dynamic-input.js +1 -0
- package/dist/components/dynamic-input/dynamic-input.js.map +1 -1
- package/dist/components/editable/editable.d.ts +17 -13
- package/dist/components/editable/editable.d.ts.map +1 -1
- package/dist/components/editable/editable.js +1 -0
- package/dist/components/editable/editable.js.map +1 -1
- package/dist/components/ellipsis/ellipsis.d.ts +9 -4
- package/dist/components/ellipsis/ellipsis.d.ts.map +1 -1
- package/dist/components/ellipsis/ellipsis.js +1 -0
- package/dist/components/ellipsis/ellipsis.js.map +1 -1
- package/dist/components/field/field.d.ts +7 -3
- package/dist/components/field/field.d.ts.map +1 -1
- package/dist/components/field/field.js +1 -0
- package/dist/components/field/field.js.map +1 -1
- package/dist/components/file-upload/file-upload.d.ts +22 -18
- package/dist/components/file-upload/file-upload.d.ts.map +1 -1
- package/dist/components/file-upload/file-upload.js +1 -0
- package/dist/components/file-upload/file-upload.js.map +1 -1
- package/dist/components/flex/flex.d.ts +1 -1
- package/dist/components/float-button/float-button.d.ts +13 -9
- package/dist/components/float-button/float-button.d.ts.map +1 -1
- package/dist/components/float-button/float-button.js +1 -0
- package/dist/components/float-button/float-button.js.map +1 -1
- package/dist/components/form/form.d.ts +39 -13
- package/dist/components/form/form.d.ts.map +1 -1
- package/dist/components/form/form.js +4 -0
- package/dist/components/form/form.js.map +1 -1
- package/dist/components/highlight/highlight.d.ts +1 -1
- package/dist/components/hover-card/hover-card.d.ts +13 -9
- package/dist/components/hover-card/hover-card.d.ts.map +1 -1
- package/dist/components/hover-card/hover-card.js +1 -0
- package/dist/components/hover-card/hover-card.js.map +1 -1
- package/dist/components/image/image.d.ts +11 -6
- package/dist/components/image/image.d.ts.map +1 -1
- package/dist/components/image/image.js +1 -0
- package/dist/components/image/image.js.map +1 -1
- package/dist/components/image-viewer/image-viewer.d.ts +16 -12
- package/dist/components/image-viewer/image-viewer.d.ts.map +1 -1
- package/dist/components/image-viewer/image-viewer.js +1 -0
- package/dist/components/image-viewer/image-viewer.js.map +1 -1
- package/dist/components/infinite-scroll/infinite-scroll.d.ts +10 -5
- package/dist/components/infinite-scroll/infinite-scroll.d.ts.map +1 -1
- package/dist/components/infinite-scroll/infinite-scroll.js +1 -0
- package/dist/components/infinite-scroll/infinite-scroll.js.map +1 -1
- package/dist/components/listbox/listbox.d.ts +10 -4
- package/dist/components/listbox/listbox.d.ts.map +1 -1
- package/dist/components/listbox/listbox.js +1 -0
- package/dist/components/listbox/listbox.js.map +1 -1
- package/dist/components/loading-bar/loading-bar.d.ts +11 -7
- package/dist/components/loading-bar/loading-bar.d.ts.map +1 -1
- package/dist/components/loading-bar/loading-bar.js +1 -0
- package/dist/components/loading-bar/loading-bar.js.map +1 -1
- package/dist/components/log/log.d.ts +12 -8
- package/dist/components/log/log.d.ts.map +1 -1
- package/dist/components/log/log.js +1 -0
- package/dist/components/log/log.js.map +1 -1
- package/dist/components/mention/mention.d.ts +12 -6
- package/dist/components/mention/mention.d.ts.map +1 -1
- package/dist/components/mention/mention.js +1 -0
- package/dist/components/mention/mention.js.map +1 -1
- package/dist/components/menu/menu.d.ts +17 -7
- package/dist/components/menu/menu.d.ts.map +1 -1
- package/dist/components/menu/menu.js +2 -0
- package/dist/components/menu/menu.js.map +1 -1
- package/dist/components/menubar/menubar.d.ts +10 -5
- package/dist/components/menubar/menubar.d.ts.map +1 -1
- package/dist/components/menubar/menubar.js +1 -0
- package/dist/components/menubar/menubar.js.map +1 -1
- package/dist/components/number-animation/number-animation.d.ts +10 -6
- package/dist/components/number-animation/number-animation.d.ts.map +1 -1
- package/dist/components/number-animation/number-animation.js +1 -0
- package/dist/components/number-animation/number-animation.js.map +1 -1
- package/dist/components/number-field/number-field.d.ts +13 -9
- package/dist/components/number-field/number-field.d.ts.map +1 -1
- package/dist/components/number-field/number-field.js +1 -0
- package/dist/components/number-field/number-field.js.map +1 -1
- package/dist/components/pagination/pagination.d.ts +13 -9
- package/dist/components/pagination/pagination.d.ts.map +1 -1
- package/dist/components/pagination/pagination.js +1 -0
- package/dist/components/pagination/pagination.js.map +1 -1
- package/dist/components/pin-input/pin-input.d.ts +12 -8
- package/dist/components/pin-input/pin-input.d.ts.map +1 -1
- package/dist/components/pin-input/pin-input.js +1 -0
- package/dist/components/pin-input/pin-input.js.map +1 -1
- package/dist/components/popconfirm/popconfirm.d.ts +16 -12
- package/dist/components/popconfirm/popconfirm.d.ts.map +1 -1
- package/dist/components/popconfirm/popconfirm.js +1 -0
- package/dist/components/popconfirm/popconfirm.js.map +1 -1
- package/dist/components/popover/popover.d.ts +17 -13
- package/dist/components/popover/popover.d.ts.map +1 -1
- package/dist/components/popover/popover.js +1 -0
- package/dist/components/popover/popover.js.map +1 -1
- package/dist/components/popselect/popselect.d.ts +10 -6
- package/dist/components/popselect/popselect.d.ts.map +1 -1
- package/dist/components/popselect/popselect.js +1 -0
- package/dist/components/popselect/popselect.js.map +1 -1
- package/dist/components/rating/rating.d.ts +18 -10
- package/dist/components/rating/rating.d.ts.map +1 -1
- package/dist/components/rating/rating.js +2 -0
- package/dist/components/rating/rating.js.map +1 -1
- package/dist/components/scroll-area/scroll-area.d.ts +14 -10
- package/dist/components/scroll-area/scroll-area.d.ts.map +1 -1
- package/dist/components/scroll-area/scroll-area.js +1 -0
- package/dist/components/scroll-area/scroll-area.js.map +1 -1
- package/dist/components/select/select.d.ts +13 -7
- package/dist/components/select/select.d.ts.map +1 -1
- package/dist/components/select/select.js +1 -0
- package/dist/components/select/select.js.map +1 -1
- package/dist/components/side-nav/side-nav.d.ts +20 -16
- package/dist/components/side-nav/side-nav.d.ts.map +1 -1
- package/dist/components/side-nav/side-nav.js +1 -0
- package/dist/components/side-nav/side-nav.js.map +1 -1
- package/dist/components/slider/slider.d.ts +23 -13
- package/dist/components/slider/slider.d.ts.map +1 -1
- package/dist/components/slider/slider.js +2 -0
- package/dist/components/slider/slider.js.map +1 -1
- package/dist/components/splitter/splitter.d.ts +20 -7
- package/dist/components/splitter/splitter.d.ts.map +1 -1
- package/dist/components/splitter/splitter.js +1 -0
- package/dist/components/splitter/splitter.js.map +1 -1
- package/dist/components/steps/steps.d.ts +18 -14
- package/dist/components/steps/steps.d.ts.map +1 -1
- package/dist/components/steps/steps.js +1 -0
- package/dist/components/steps/steps.js.map +1 -1
- package/dist/components/table/table.d.ts +24 -20
- package/dist/components/table/table.d.ts.map +1 -1
- package/dist/components/table/table.js +1 -0
- package/dist/components/table/table.js.map +1 -1
- package/dist/components/tags-input/tags-input.d.ts +20 -16
- package/dist/components/tags-input/tags-input.d.ts.map +1 -1
- package/dist/components/tags-input/tags-input.js +1 -0
- package/dist/components/tags-input/tags-input.js.map +1 -1
- package/dist/components/text-field/text-field.d.ts +12 -8
- package/dist/components/text-field/text-field.d.ts.map +1 -1
- package/dist/components/text-field/text-field.js +1 -0
- package/dist/components/text-field/text-field.js.map +1 -1
- package/dist/components/thread/thread.d.ts +13 -9
- package/dist/components/thread/thread.d.ts.map +1 -1
- package/dist/components/thread/thread.js +1 -0
- package/dist/components/thread/thread.js.map +1 -1
- package/dist/components/time/time.d.ts +1 -1
- package/dist/components/time-field/time-field.d.ts +13 -9
- package/dist/components/time-field/time-field.d.ts.map +1 -1
- package/dist/components/time-field/time-field.js +1 -0
- package/dist/components/time-field/time-field.js.map +1 -1
- package/dist/components/time-picker/time-picker.d.ts +28 -18
- package/dist/components/time-picker/time-picker.d.ts.map +1 -1
- package/dist/components/time-picker/time-picker.js +2 -0
- package/dist/components/time-picker/time-picker.js.map +1 -1
- package/dist/components/toast/toast.d.ts +14 -10
- package/dist/components/toast/toast.d.ts.map +1 -1
- package/dist/components/toast/toast.js +1 -0
- package/dist/components/toast/toast.js.map +1 -1
- package/dist/components/toaster/toaster.d.ts +27 -8
- package/dist/components/toaster/toaster.d.ts.map +1 -1
- package/dist/components/toaster/toaster.js +2 -0
- package/dist/components/toaster/toaster.js.map +1 -1
- package/dist/components/toolbar/toolbar.d.ts +12 -7
- package/dist/components/toolbar/toolbar.d.ts.map +1 -1
- package/dist/components/toolbar/toolbar.js +1 -0
- package/dist/components/toolbar/toolbar.js.map +1 -1
- package/dist/components/tooltip/tooltip.d.ts +13 -9
- package/dist/components/tooltip/tooltip.d.ts.map +1 -1
- package/dist/components/tooltip/tooltip.js +1 -0
- package/dist/components/tooltip/tooltip.js.map +1 -1
- package/dist/components/tour/tour.d.ts +22 -18
- package/dist/components/tour/tour.d.ts.map +1 -1
- package/dist/components/tour/tour.js +1 -0
- package/dist/components/tour/tour.js.map +1 -1
- package/dist/components/transfer/transfer.d.ts +34 -6
- package/dist/components/transfer/transfer.d.ts.map +1 -1
- package/dist/components/transfer/transfer.js +3 -0
- package/dist/components/transfer/transfer.js.map +1 -1
- package/dist/components/tree/tree.d.ts +20 -16
- package/dist/components/tree/tree.d.ts.map +1 -1
- package/dist/components/tree/tree.js +1 -0
- package/dist/components/tree/tree.js.map +1 -1
- package/dist/components/tree-select/tree-select.d.ts +30 -26
- package/dist/components/tree-select/tree-select.d.ts.map +1 -1
- package/dist/components/tree-select/tree-select.js +1 -0
- package/dist/components/tree-select/tree-select.js.map +1 -1
- package/dist/components/virtualizer/virtualizer.d.ts +14 -10
- package/dist/components/virtualizer/virtualizer.d.ts.map +1 -1
- package/dist/components/virtualizer/virtualizer.js +1 -0
- package/dist/components/virtualizer/virtualizer.js.map +1 -1
- package/dist/config/config.d.ts +2 -36
- package/dist/config/config.d.ts.map +1 -1
- package/dist/config/config.js.map +1 -1
- package/dist/index.d.ts +63 -63
- package/package.json +14 -13
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,96 @@
|
|
|
1
1
|
# @xihan-ui/vue
|
|
2
2
|
|
|
3
|
+
## 1.0.0-alpha.2
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 466f143: 新增两个包:`@xihan-ui/motion` 收动效原语,`@xihan-ui/animations` 收现成的动效。
|
|
8
|
+
|
|
9
|
+
动效的东西原先散在三处:缓动表与减弱动效探测在 `behavior`,补间与帧循环在 `headless/src/shared`,两套缓动的档名和值还对不上。`@xihan-ui/motion` 把它们收成一处,并补上真正缺的两样——解析解弹簧与 Web Animations 的薄封装。缓动从此只有一份来源:CSS 侧的 cubic-bezier 串与 JS 侧的采样函数同名同源。弹簧按阻尼比分三支算沉降时长,与 dt=0.1ms 的四阶龙格-库塔积分逐点对拍。减弱动效在系统偏好之上叠了一层应用级 override,接得上产品自己的"减弱动效"设置项。
|
|
10
|
+
|
|
11
|
+
`behavior` 与 `headless` 原样重新导出搬走的名字,公开面一个没少。
|
|
12
|
+
|
|
13
|
+
`@xihan-ui/animations` 是建在上面的效果层:11 个进场预设、6 个注意预设、错开起播与文字拆分。一段动画是一份可 JSON 序列化的配方,能存进数据库、由界面下拉切换。减弱动效的降级由 `motion` 统一兜住,这一层不另开通道——降级只影响中间帧存不存在,不影响控制流。
|
|
14
|
+
|
|
15
|
+
### Patch Changes
|
|
16
|
+
|
|
17
|
+
- 09b5ad8: 「collection 铺开的结构凑齐必备部件」这条判据改成机检,并把三档语义写进文档。
|
|
18
|
+
|
|
19
|
+
`collection` 收了数据不等于会替你渲染结构,而这件事此前既没有对外判据、也没有任何东西守着:
|
|
20
|
+
14 个组件里 13 个在根上代铺、popselect 只在 content 里铺,使用者只能一个个试。
|
|
21
|
+
官网落地时那棵树就是把数据写了一遍、DOM 又手码了一遍,两份得自己保持同步。
|
|
22
|
+
|
|
23
|
+
新增 `tests/collection-required-parts.spec.ts`:逐个组件只交 `collection`、不写任何部件,
|
|
24
|
+
断言铺出来的 DOM 含该组件 `meta.requiredParts` 里的每一个部件。少一个就是渲染出一个
|
|
25
|
+
看着正常、其实不工作的组件——浮层打不开、方向键找不到条目、同一份结构写到自定义元素那侧
|
|
26
|
+
会报 `wc.missing-part`。给新组件加代铺时先往这份测试加一行,铺漏了当场红。
|
|
27
|
+
|
|
28
|
+
顺带查出并钉住两处此前没人测的差别:`popselect` 的铺开落在 content 部件里而不是根上
|
|
29
|
+
(`<XhPopselectRoot :collection>` 单独用什么都不出),`mention` 的候选浮层没有 `defaultOpen`、
|
|
30
|
+
敲下前缀字符才铺开。
|
|
31
|
+
|
|
32
|
+
`guide/anatomy.md` 补「collection 管不管铺开结构」一节,三档逐个列出组件名,
|
|
33
|
+
并写明判据是结构的自由度:扁平集合的 DOM 形状是确定的,代铺挡不住任何写法;
|
|
34
|
+
层级与多区(`tree` / `cascader` / `transfer`)的结构有太多合理变体,代铺只会逼作者推翻重写。
|
|
35
|
+
|
|
36
|
+
- ae21590: 75 个组件的插槽写上真类型,`vue-tsc` 从此接得住插槽名与载荷键名的拼写错误。
|
|
37
|
+
|
|
38
|
+
组件是渲染函数写的,`.d.ts` 里插槽泛型一直是空的(`DefineComponent` 的 `S` 位是 `{}`),
|
|
39
|
+
于是 `#panel="node"`、`v-slot="{ pages, page }"` 这些载荷在消费端全是 `any`:
|
|
40
|
+
键名写错不报、插槽名写错不报,只在运行期渲染出 `undefined`。props 与 emits 早就有完整类型,
|
|
41
|
+
唯独插槽这一层没有对外描述——而无头库恰恰是靠插槽把控制权交回作者的。
|
|
42
|
+
|
|
43
|
+
现在每个带载荷的插槽都有具名载荷类型(`TabsPanelSlotProps`、`StepsRootSlotProps` 这样命名,
|
|
44
|
+
均从主入口导出),组件上声明 `slots: Object as SlotsType<…>`:
|
|
45
|
+
|
|
46
|
+
```vue
|
|
47
|
+
<template #panel="node">{{ node.lable }}</template>
|
|
48
|
+
<!-- TS2551: Property 'lable' does not exist on type 'TabsNodeMeta'. Did you mean 'label'? -->
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
两条形状上的取舍值得写下来:
|
|
52
|
+
|
|
53
|
+
- **键一律可选**。非可选时 `slots.default ? 作者内容 : 按 collection 铺开` 这类判断在类型上恒为真,
|
|
54
|
+
而它承载的正是「没写默认插槽就铺开整套结构」的核心行为——类型不能对着它撒谎。
|
|
55
|
+
- **值一律写成函数类型**而不是裸载荷类型。Vue 的 `UnwrapSlotsType` 对函数类型原样保留、
|
|
56
|
+
对裸类型套一层 `Slot<T>`,而 `Slot<T>` 的实参元组在 `T` 不 extends `undefined` 时是 `[T]`
|
|
57
|
+
——零参调用会变成非法,而库里到处是 `slots.default?.()`。
|
|
58
|
+
|
|
59
|
+
新增 `check-slot-types` 门禁盯住这两条与「带载荷就必须声明」,`pnpm gate` 由十七项变十八项。
|
|
60
|
+
|
|
61
|
+
- ba3b3aa: 自定义元素补上全局文案层:`setXhConfig`。
|
|
62
|
+
|
|
63
|
+
`provideXhConfig` 一直只有 Vue 适配器有。自定义元素拿不到 provide/inject,文案又是对象、
|
|
64
|
+
只能走 property 不能走 attribute,于是 31 个元素只能在 JS 里逐实例各设一次 `.translations`——
|
|
65
|
+
一个中文应用要为此写几十行。而 `guide/i18n.md` 通篇把 `provideXhConfig` 当作「这套机制」讲,
|
|
66
|
+
一次都没提 Web Components,读的人会以为两端通用。
|
|
67
|
+
|
|
68
|
+
现在两端各有一处全局出口,取值优先级一致:**实例 → 全局 → 组件内建默认(英文)**,
|
|
69
|
+
`translations` 逐键合并。切语言再调一次 `setXhConfig` 即可,已挂载的元素跟着重渲。
|
|
70
|
+
|
|
71
|
+
接线落在 `MachineController` 一处——31 个元素的机器 props 都从那里过,不必逐个改。
|
|
72
|
+
|
|
73
|
+
`XhTranslationOverrides` 那张 31 条的映射表下沉到 `@xihan-ui/headless`,两个适配器共用一份。
|
|
74
|
+
在 WC 侧另抄一份是唯一的替代方案,而两份 31 条的表迟早会漂。Vue 侧原样再导出,导出名不变。
|
|
75
|
+
|
|
76
|
+
与 Vue 侧的两处差别写进文档了:`setXhConfig` 是整份替换而非深合并;它是模块级的,
|
|
77
|
+
没有「只在某棵子树里换语言」的能力。
|
|
78
|
+
|
|
79
|
+
- Updated dependencies [3469066]
|
|
80
|
+
- Updated dependencies [466f143]
|
|
81
|
+
- Updated dependencies [7a5d898]
|
|
82
|
+
- Updated dependencies [52729a1]
|
|
83
|
+
- Updated dependencies [ba3b3aa]
|
|
84
|
+
- @xihan-ui/backgrounds@1.0.0-alpha.2
|
|
85
|
+
- @xihan-ui/headless@1.0.0-alpha.2
|
|
86
|
+
- @xihan-ui/motion@1.0.0-alpha.2
|
|
87
|
+
- @xihan-ui/behavior@1.0.0-alpha.2
|
|
88
|
+
- @xihan-ui/kernel@1.0.0-alpha.2
|
|
89
|
+
- @xihan-ui/machine@1.0.0-alpha.2
|
|
90
|
+
- @xihan-ui/code-highlight@1.0.0-alpha.2
|
|
91
|
+
- @xihan-ui/position@1.0.0-alpha.2
|
|
92
|
+
- @xihan-ui/sound@1.0.0-alpha.2
|
|
93
|
+
|
|
3
94
|
## 1.0.0-alpha.1
|
|
4
95
|
|
|
5
96
|
### Major Changes
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { PayloadOf } from "../../runtime/payload.js";
|
|
2
|
-
import { PropType } from "vue";
|
|
3
|
-
import { AffixSchema } from "@xihan-ui/headless";
|
|
2
|
+
import { PropType, SlotsType, VNode } from "vue";
|
|
3
|
+
import { AffixApi, AffixSchema } from "@xihan-ui/headless";
|
|
4
4
|
//#region src/components/affix/affix.d.ts
|
|
5
5
|
type AffixProps = AffixSchema['props'];
|
|
6
|
+
/** 默认插槽的载荷:此刻是不是吸住了。 */
|
|
7
|
+
type AffixRootSlotProps = Pick<AffixApi, 'affixed'>;
|
|
6
8
|
/** 根节点是占位盒:content 吸住时脱流,它留在原位撑住那块空间。 */
|
|
7
9
|
declare const XhAffixRoot: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
8
10
|
offsetTop: {
|
|
@@ -18,7 +20,7 @@ declare const XhAffixRoot: import("vue").DefineComponent<import("vue").ExtractPr
|
|
|
18
20
|
type: PropType<HTMLElement | null>;
|
|
19
21
|
default: undefined;
|
|
20
22
|
};
|
|
21
|
-
}>, () =>
|
|
23
|
+
}>, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
22
24
|
[key: string]: any;
|
|
23
25
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
24
26
|
'affix-change': (_details: PayloadOf<AffixProps, "onAffixChange">) => true;
|
|
@@ -42,11 +44,13 @@ declare const XhAffixRoot: import("vue").DefineComponent<import("vue").ExtractPr
|
|
|
42
44
|
offsetTop: number;
|
|
43
45
|
offsetBottom: number;
|
|
44
46
|
target: HTMLElement | null;
|
|
45
|
-
}, {
|
|
47
|
+
}, SlotsType<{
|
|
48
|
+
default?: (props: AffixRootSlotProps) => VNode[];
|
|
49
|
+
}>, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
46
50
|
/** 吸住时脱离常规流钉在可视区边上,落位由机器量好写进内联样式。 */
|
|
47
|
-
declare const XhAffixContent: import("vue").DefineComponent<{}, () =>
|
|
51
|
+
declare const XhAffixContent: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
48
52
|
[key: string]: any;
|
|
49
53
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
50
54
|
//#endregion
|
|
51
|
-
export { XhAffixContent, XhAffixRoot };
|
|
55
|
+
export { AffixRootSlotProps, XhAffixContent, XhAffixRoot };
|
|
52
56
|
//# sourceMappingURL=affix.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"affix.d.ts","names":[],"sources":["../../../src/components/affix/affix.ts"],"mappings":";;;;KAOK,aAAa;;
|
|
1
|
+
{"version":3,"file":"affix.d.ts","names":[],"sources":["../../../src/components/affix/affix.ts"],"mappings":";;;;KAOK,aAAa;;KAGN,qBAAqB,KAAK;;cAGzB,2BAAW,8BAAA;;;;;;;;;;;IAOM,MAAA,SAAS;;;;;;EAGR,iBAAA,UAAA,UAAU;;;;;;;;;;;;IAHX,MAAA,SAAS;;;;;;;;;;EAMzB,WAAC,OAAO,uBAAuB;kCAY3C;;cAGW,8BAAc,0BAAA,oBAAA,4BAAA;;8BAMzB,qCAAA,iDAAA,aAAA,eAAA,oDAAA"}
|
|
@@ -21,6 +21,7 @@ const XhAffixRoot = defineComponent({
|
|
|
21
21
|
}
|
|
22
22
|
},
|
|
23
23
|
emits: { "affix-change": (_details) => true },
|
|
24
|
+
slots: Object,
|
|
24
25
|
setup(props, { slots, emit }) {
|
|
25
26
|
const notify = (details) => emit("affix-change", details);
|
|
26
27
|
const ctx = useAffix(props, notify, () => props.target ?? null);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"affix.js","names":[],"sources":["../../../src/components/affix/affix.ts"],"sourcesContent":["import type { AffixSchema } from '@xihan-ui/headless'\nimport type { PropType } from 'vue'\nimport type { PayloadOf } from '../../runtime/payload'\nimport { defineComponent, h } from 'vue'\nimport { provideAffix, useAffixContext } from './context'\nimport { useAffix } from './use-affix'\n\ntype AffixProps = AffixSchema['props']\n\n/** 根节点是占位盒:content 吸住时脱流,它留在原位撑住那块空间。 */\nexport const XhAffixRoot = defineComponent({\n name: 'XhAffixRoot',\n // 缺省值由机器与 connect 决定,这里一律 default: undefined\n props: {\n offsetTop: { type: Number, default: undefined },\n offsetBottom: { type: Number, default: undefined },\n /** 滚动容器,缺省即整页滚动;经 refs 交给观察器。 */\n target: { type: Object as PropType<HTMLElement | null>, default: undefined },\n },\n emits: {\n 'affix-change': (_details: PayloadOf<AffixProps, 'onAffixChange'>) => true,\n },\n setup(props, { slots, emit }) {\n const notify: AffixProps['onAffixChange'] = details => emit('affix-change', details)\n // 传响应式 props 对象本身而非快照,供机器每次读时重新展开\n const ctx = useAffix(props as AffixProps, notify, () => props.target ?? null)\n provideAffix(ctx)\n return () => h('div', {\n ...ctx.api.value.getRootProps() as Record<string, unknown>,\n ref: (el: unknown) => { ctx.rootRef.value = el as HTMLElement },\n }, slots.default?.({ affixed: ctx.api.value.affixed }))\n },\n})\n\n/** 吸住时脱离常规流钉在可视区边上,落位由机器量好写进内联样式。 */\nexport const XhAffixContent = defineComponent({\n name: 'XhAffixContent',\n setup(_, { slots }) {\n const ctx = useAffixContext()\n return () => h('div', ctx.api.value.getContentProps() as Record<string, unknown>, slots.default?.())\n },\n})\n"],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"affix.js","names":[],"sources":["../../../src/components/affix/affix.ts"],"sourcesContent":["import type { AffixApi, AffixSchema } from '@xihan-ui/headless'\nimport type { PropType, SlotsType, VNode } from 'vue'\nimport type { PayloadOf } from '../../runtime/payload'\nimport { defineComponent, h } from 'vue'\nimport { provideAffix, useAffixContext } from './context'\nimport { useAffix } from './use-affix'\n\ntype AffixProps = AffixSchema['props']\n\n/** 默认插槽的载荷:此刻是不是吸住了。 */\nexport type AffixRootSlotProps = Pick<AffixApi, 'affixed'>\n\n/** 根节点是占位盒:content 吸住时脱流,它留在原位撑住那块空间。 */\nexport const XhAffixRoot = defineComponent({\n name: 'XhAffixRoot',\n // 缺省值由机器与 connect 决定,这里一律 default: undefined\n props: {\n offsetTop: { type: Number, default: undefined },\n offsetBottom: { type: Number, default: undefined },\n /** 滚动容器,缺省即整页滚动;经 refs 交给观察器。 */\n target: { type: Object as PropType<HTMLElement | null>, default: undefined },\n },\n emits: {\n 'affix-change': (_details: PayloadOf<AffixProps, 'onAffixChange'>) => true,\n },\n slots: Object as SlotsType<{\n default?: (props: AffixRootSlotProps) => VNode[]\n }>,\n setup(props, { slots, emit }) {\n const notify: AffixProps['onAffixChange'] = details => emit('affix-change', details)\n // 传响应式 props 对象本身而非快照,供机器每次读时重新展开\n const ctx = useAffix(props as AffixProps, notify, () => props.target ?? null)\n provideAffix(ctx)\n return () => h('div', {\n ...ctx.api.value.getRootProps() as Record<string, unknown>,\n ref: (el: unknown) => { ctx.rootRef.value = el as HTMLElement },\n }, slots.default?.({ affixed: ctx.api.value.affixed }))\n },\n})\n\n/** 吸住时脱离常规流钉在可视区边上,落位由机器量好写进内联样式。 */\nexport const XhAffixContent = defineComponent({\n name: 'XhAffixContent',\n setup(_, { slots }) {\n const ctx = useAffixContext()\n return () => h('div', ctx.api.value.getContentProps() as Record<string, unknown>, slots.default?.())\n },\n})\n"],"mappings":";;;;;AAaA,MAAa,cAAc,gBAAgB;CACzC,MAAM;CAEN,OAAO;EACL,WAAW;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EAC9C,cAAc;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;;EAEjD,QAAQ;GAAE,MAAM;GAAwC,SAAS,KAAA;EAAU;CAC7E;CACA,OAAO,EACL,iBAAiB,aAAqD,KACxE;CACA,OAAO;CAGP,MAAM,OAAO,EAAE,OAAO,QAAQ;EAC5B,MAAM,UAAsC,YAAW,KAAK,gBAAgB,OAAO;EAEnF,MAAM,MAAM,SAAS,OAAqB,cAAc,MAAM,UAAU,IAAI;EAC5E,aAAa,GAAG;EAChB,aAAa,EAAE,OAAO;GACpB,GAAG,IAAI,IAAI,MAAM,aAAa;GAC9B,MAAM,OAAgB;IAAE,IAAI,QAAQ,QAAQ;GAAkB;EAChE,GAAG,MAAM,UAAU,EAAE,SAAS,IAAI,IAAI,MAAM,QAAQ,CAAC,CAAC;CACxD;AACF,CAAC;;AAGD,MAAa,iBAAiB,gBAAgB;CAC5C,MAAM;CACN,MAAM,GAAG,EAAE,SAAS;EAClB,MAAM,MAAM,gBAAgB;EAC5B,aAAa,EAAE,OAAO,IAAI,IAAI,MAAM,gBAAgB,GAA8B,MAAM,UAAU,CAAC;CACrG;AACF,CAAC"}
|
|
@@ -112,10 +112,10 @@ declare const XhAnchorRoot: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
112
112
|
dir: Direction;
|
|
113
113
|
tone: Tone;
|
|
114
114
|
size: Size;
|
|
115
|
-
smooth: boolean;
|
|
116
115
|
translations: Partial<AnchorTranslations>;
|
|
117
116
|
targets: readonly string[];
|
|
118
117
|
offset: number;
|
|
118
|
+
smooth: boolean;
|
|
119
119
|
scrollElement: HTMLElement | null;
|
|
120
120
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
121
121
|
declare const XhAnchorList: import("vue").DefineComponent<{}, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { PayloadOf } from "../../runtime/payload.js";
|
|
2
|
-
import { PropType } from "vue";
|
|
3
|
-
import { BackTopBehavior, BackTopSchema, BackTopTranslations } from "@xihan-ui/headless";
|
|
2
|
+
import { PropType, SlotsType, VNode } from "vue";
|
|
3
|
+
import { BackTopApi, BackTopBehavior, BackTopSchema, BackTopTranslations } from "@xihan-ui/headless";
|
|
4
4
|
import { Size, Tone } from "@xihan-ui/kernel";
|
|
5
5
|
//#region src/components/back-top/back-top.d.ts
|
|
6
6
|
type BackTopProps = BackTopSchema['props'];
|
|
7
|
+
/** 默认插槽的载荷:按钮此刻露不露面。 */
|
|
8
|
+
type BackTopRootSlotProps = Pick<BackTopApi, 'visible'>;
|
|
7
9
|
/** 根节点是定位壳:把按钮钉在视口一角,收起时整块让位。 */
|
|
8
10
|
declare const XhBackTopRoot: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
9
11
|
visibilityHeight: {
|
|
@@ -31,7 +33,7 @@ declare const XhBackTopRoot: import("vue").DefineComponent<import("vue").Extract
|
|
|
31
33
|
type: PropType<HTMLElement | null>;
|
|
32
34
|
default: undefined;
|
|
33
35
|
};
|
|
34
|
-
}>, () =>
|
|
36
|
+
}>, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
35
37
|
[key: string]: any;
|
|
36
38
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
37
39
|
'visible-change': (_details: PayloadOf<BackTopProps, "onVisibleChange">) => true;
|
|
@@ -67,14 +69,16 @@ declare const XhBackTopRoot: import("vue").DefineComponent<import("vue").Extract
|
|
|
67
69
|
tone: Tone;
|
|
68
70
|
size: Size;
|
|
69
71
|
target: HTMLElement | null;
|
|
72
|
+
translations: Partial<BackTopTranslations>;
|
|
70
73
|
visibilityHeight: number;
|
|
71
74
|
behavior: BackTopBehavior;
|
|
72
|
-
|
|
73
|
-
|
|
75
|
+
}, SlotsType<{
|
|
76
|
+
default?: (props: BackTopRootSlotProps) => VNode[];
|
|
77
|
+
}>, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
74
78
|
/** 原生 button:Enter / Space 的激活与 Tab 停靠都由平台提供。 */
|
|
75
|
-
declare const XhBackTopTrigger: import("vue").DefineComponent<{}, () =>
|
|
79
|
+
declare const XhBackTopTrigger: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
76
80
|
[key: string]: any;
|
|
77
81
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
78
82
|
//#endregion
|
|
79
|
-
export { XhBackTopRoot, XhBackTopTrigger };
|
|
83
|
+
export { BackTopRootSlotProps, XhBackTopRoot, XhBackTopTrigger };
|
|
80
84
|
//# sourceMappingURL=back-top.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"back-top.d.ts","names":[],"sources":["../../../src/components/back-top/back-top.ts"],"mappings":";;;;;KASK,eAAe;;
|
|
1
|
+
{"version":3,"file":"back-top.d.ts","names":[],"sources":["../../../src/components/back-top/back-top.ts"],"mappings":";;;;;KASK,eAAe;;KAGR,uBAAuB,KAAK;;cAG3B,6BAAa,8BAAA;;;;;;IAKM,MAAA,SAAS;;;;IACL,MAAA,SAAS,QAAQ;;;;IACzB,MAAA,SAAS;;;;IACT,MAAA,SAAS;;;;;IAEP,MAAA,SAAS;;;;;;EAGN,mBAAA,UAAA,UAAU;;;;;;;IARX,MAAA,SAAS;;;;IACL,MAAA,SAAS,QAAQ;;;;IACzB,MAAA,SAAS;;;;IACT,MAAA,SAAS;;;;;IAEP,MAAA,SAAS;;;;;;;;;;;;;EAMzB,WAAC,OAAO,yBAAyB;kCAW7C;;cAGW,gCAAgB,0BAAA,oBAAA,4BAAA;;8BAM3B,qCAAA,iDAAA,aAAA,eAAA,oDAAA"}
|
|
@@ -34,6 +34,7 @@ const XhBackTopRoot = defineComponent({
|
|
|
34
34
|
}
|
|
35
35
|
},
|
|
36
36
|
emits: { "visible-change": (_details) => true },
|
|
37
|
+
slots: Object,
|
|
37
38
|
setup(props, { slots, emit }) {
|
|
38
39
|
const notify = (details) => emit("visible-change", details);
|
|
39
40
|
const ctx = useBackTop(withXhConfig("back-top", props), notify, () => props.target ?? null);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"back-top.js","names":[],"sources":["../../../src/components/back-top/back-top.ts"],"sourcesContent":["import type { BackTopBehavior, BackTopSchema, BackTopTranslations } from '@xihan-ui/headless'\nimport type { Size, Tone } from '@xihan-ui/kernel'\nimport type { PropType } from 'vue'\nimport type { PayloadOf } from '../../runtime/payload'\nimport { defineComponent, h } from 'vue'\nimport { withXhConfig } from '../../config/config'\nimport { provideBackTop, useBackTopContext } from './context'\nimport { useBackTop } from './use-back-top'\n\ntype BackTopProps = BackTopSchema['props']\n\n/** 根节点是定位壳:把按钮钉在视口一角,收起时整块让位。 */\nexport const XhBackTopRoot = defineComponent({\n name: 'XhBackTopRoot',\n // 缺省值由机器与 connect 决定,这里一律 default: undefined\n props: {\n visibilityHeight: { type: Number, default: undefined },\n behavior: { type: String as PropType<BackTopBehavior>, default: undefined },\n translations: { type: Object as PropType<Partial<BackTopTranslations>>, default: undefined },\n tone: { type: String as PropType<Tone>, default: undefined },\n size: { type: String as PropType<Size>, default: undefined },\n /** 滚动容器,缺省即整页滚动;经 refs 交给观察器。 */\n target: { type: Object as PropType<HTMLElement | null>, default: undefined },\n },\n emits: {\n 'visible-change': (_details: PayloadOf<BackTopProps, 'onVisibleChange'>) => true,\n },\n setup(props, { slots, emit }) {\n const notify: BackTopProps['onVisibleChange'] = details => emit('visible-change', details)\n // 传响应式 props 对象本身而非快照,供机器每次读时重新展开\n const ctx = useBackTop(withXhConfig('back-top', props) as BackTopProps, notify, () => props.target ?? null)\n provideBackTop(ctx)\n return () => h('div', ctx.api.value.getRootProps() as Record<string, unknown>, slots.default?.({\n visible: ctx.api.value.visible,\n }))\n },\n})\n\n/** 原生 button:Enter / Space 的激活与 Tab 停靠都由平台提供。 */\nexport const XhBackTopTrigger = defineComponent({\n name: 'XhBackTopTrigger',\n setup(_, { slots }) {\n const ctx = useBackTopContext()\n return () => h('button', ctx.api.value.getTriggerProps() as Record<string, unknown>, slots.default?.())\n },\n})\n"],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"back-top.js","names":[],"sources":["../../../src/components/back-top/back-top.ts"],"sourcesContent":["import type { BackTopApi, BackTopBehavior, BackTopSchema, BackTopTranslations } from '@xihan-ui/headless'\nimport type { Size, Tone } from '@xihan-ui/kernel'\nimport type { PropType, SlotsType, VNode } from 'vue'\nimport type { PayloadOf } from '../../runtime/payload'\nimport { defineComponent, h } from 'vue'\nimport { withXhConfig } from '../../config/config'\nimport { provideBackTop, useBackTopContext } from './context'\nimport { useBackTop } from './use-back-top'\n\ntype BackTopProps = BackTopSchema['props']\n\n/** 默认插槽的载荷:按钮此刻露不露面。 */\nexport type BackTopRootSlotProps = Pick<BackTopApi, 'visible'>\n\n/** 根节点是定位壳:把按钮钉在视口一角,收起时整块让位。 */\nexport const XhBackTopRoot = defineComponent({\n name: 'XhBackTopRoot',\n // 缺省值由机器与 connect 决定,这里一律 default: undefined\n props: {\n visibilityHeight: { type: Number, default: undefined },\n behavior: { type: String as PropType<BackTopBehavior>, default: undefined },\n translations: { type: Object as PropType<Partial<BackTopTranslations>>, default: undefined },\n tone: { type: String as PropType<Tone>, default: undefined },\n size: { type: String as PropType<Size>, default: undefined },\n /** 滚动容器,缺省即整页滚动;经 refs 交给观察器。 */\n target: { type: Object as PropType<HTMLElement | null>, default: undefined },\n },\n emits: {\n 'visible-change': (_details: PayloadOf<BackTopProps, 'onVisibleChange'>) => true,\n },\n slots: Object as SlotsType<{\n default?: (props: BackTopRootSlotProps) => VNode[]\n }>,\n setup(props, { slots, emit }) {\n const notify: BackTopProps['onVisibleChange'] = details => emit('visible-change', details)\n // 传响应式 props 对象本身而非快照,供机器每次读时重新展开\n const ctx = useBackTop(withXhConfig('back-top', props) as BackTopProps, notify, () => props.target ?? null)\n provideBackTop(ctx)\n return () => h('div', ctx.api.value.getRootProps() as Record<string, unknown>, slots.default?.({\n visible: ctx.api.value.visible,\n }))\n },\n})\n\n/** 原生 button:Enter / Space 的激活与 Tab 停靠都由平台提供。 */\nexport const XhBackTopTrigger = defineComponent({\n name: 'XhBackTopTrigger',\n setup(_, { slots }) {\n const ctx = useBackTopContext()\n return () => h('button', ctx.api.value.getTriggerProps() as Record<string, unknown>, slots.default?.())\n },\n})\n"],"mappings":";;;;;;AAeA,MAAa,gBAAgB,gBAAgB;CAC3C,MAAM;CAEN,OAAO;EACL,kBAAkB;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EACrD,UAAU;GAAE,MAAM;GAAqC,SAAS,KAAA;EAAU;EAC1E,cAAc;GAAE,MAAM;GAAkD,SAAS,KAAA;EAAU;EAC3F,MAAM;GAAE,MAAM;GAA0B,SAAS,KAAA;EAAU;EAC3D,MAAM;GAAE,MAAM;GAA0B,SAAS,KAAA;EAAU;;EAE3D,QAAQ;GAAE,MAAM;GAAwC,SAAS,KAAA;EAAU;CAC7E;CACA,OAAO,EACL,mBAAmB,aAAyD,KAC9E;CACA,OAAO;CAGP,MAAM,OAAO,EAAE,OAAO,QAAQ;EAC5B,MAAM,UAA0C,YAAW,KAAK,kBAAkB,OAAO;EAEzF,MAAM,MAAM,WAAW,aAAa,YAAY,KAAK,GAAmB,cAAc,MAAM,UAAU,IAAI;EAC1G,eAAe,GAAG;EAClB,aAAa,EAAE,OAAO,IAAI,IAAI,MAAM,aAAa,GAA8B,MAAM,UAAU,EAC7F,SAAS,IAAI,IAAI,MAAM,QACzB,CAAC,CAAC;CACJ;AACF,CAAC;;AAGD,MAAa,mBAAmB,gBAAgB;CAC9C,MAAM;CACN,MAAM,GAAG,EAAE,SAAS;EAClB,MAAM,MAAM,kBAAkB;EAC9B,aAAa,EAAE,UAAU,IAAI,IAAI,MAAM,gBAAgB,GAA8B,MAAM,UAAU,CAAC;CACxG;AACF,CAAC"}
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { PayloadOf } from "../../runtime/payload.js";
|
|
2
|
-
import { PropType } from "vue";
|
|
3
|
-
import { CalendarSchema, CalendarSelectionMode, CalendarWeekdayFormat } from "@xihan-ui/headless";
|
|
2
|
+
import { PropType, SlotsType, VNode } from "vue";
|
|
3
|
+
import { CalendarApi, CalendarSchema, CalendarSelectionMode, CalendarWeekdayFormat } from "@xihan-ui/headless";
|
|
4
4
|
//#region src/components/calendar/calendar.d.ts
|
|
5
5
|
type CalendarProps = CalendarSchema['props'];
|
|
6
|
+
/** 默认插槽的载荷:选中值与聚焦日、展示月的日期矩阵与表头,以及选中、聚焦、翻月的动作。 */
|
|
7
|
+
type CalendarRootSlotProps = Pick<CalendarApi, 'value' | 'focusedValue' | 'visibleMonth' | 'weeks' | 'weekDays' | 'headingLabel' | 'canGoPrev' | 'canGoNext' | 'isSelected' | 'isUnavailable' | 'setValue' | 'select' | 'focus' | 'goToPrevMonth' | 'goToNextMonth'>;
|
|
6
8
|
declare const XhCalendarRoot: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
7
9
|
value: {
|
|
8
10
|
type: PropType<string | string[]>;
|
|
@@ -51,7 +53,7 @@ declare const XhCalendarRoot: import("vue").DefineComponent<import("vue").Extrac
|
|
|
51
53
|
default: undefined;
|
|
52
54
|
};
|
|
53
55
|
fixedWeeks: BooleanConstructor;
|
|
54
|
-
}>, () =>
|
|
56
|
+
}>, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
55
57
|
[key: string]: any;
|
|
56
58
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
57
59
|
'value-change': (_details: PayloadOf<CalendarProps, "onValueChange">) => true;
|
|
@@ -116,8 +118,8 @@ declare const XhCalendarRoot: import("vue").DefineComponent<import("vue").Extrac
|
|
|
116
118
|
defaultValue: string | string[];
|
|
117
119
|
disabled: boolean;
|
|
118
120
|
max: string;
|
|
119
|
-
readOnly: boolean;
|
|
120
121
|
focusedValue: string;
|
|
122
|
+
readOnly: boolean;
|
|
121
123
|
fixedWeeks: boolean;
|
|
122
124
|
selectionMode: CalendarSelectionMode;
|
|
123
125
|
defaultFocusedValue: string;
|
|
@@ -126,29 +128,31 @@ declare const XhCalendarRoot: import("vue").DefineComponent<import("vue").Extrac
|
|
|
126
128
|
locale: string;
|
|
127
129
|
timeZone: string;
|
|
128
130
|
weekdayFormat: CalendarWeekdayFormat;
|
|
129
|
-
}, {
|
|
130
|
-
|
|
131
|
+
}, SlotsType<{
|
|
132
|
+
default?: (props: CalendarRootSlotProps) => VNode[];
|
|
133
|
+
}>, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
134
|
+
declare const XhCalendarHeader: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
131
135
|
[key: string]: any;
|
|
132
136
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
133
|
-
declare const XhCalendarPrevTrigger: import("vue").DefineComponent<{}, () =>
|
|
137
|
+
declare const XhCalendarPrevTrigger: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
134
138
|
[key: string]: any;
|
|
135
139
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
136
|
-
declare const XhCalendarNextTrigger: import("vue").DefineComponent<{}, () =>
|
|
140
|
+
declare const XhCalendarNextTrigger: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
137
141
|
[key: string]: any;
|
|
138
142
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
139
|
-
declare const XhCalendarHeading: import("vue").DefineComponent<{}, () =>
|
|
143
|
+
declare const XhCalendarHeading: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
140
144
|
[key: string]: any;
|
|
141
145
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
142
|
-
declare const XhCalendarGrid: import("vue").DefineComponent<{}, () =>
|
|
146
|
+
declare const XhCalendarGrid: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
143
147
|
[key: string]: any;
|
|
144
148
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
145
|
-
declare const XhCalendarGridHead: import("vue").DefineComponent<{}, () =>
|
|
149
|
+
declare const XhCalendarGridHead: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
146
150
|
[key: string]: any;
|
|
147
151
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
148
|
-
declare const XhCalendarGridBody: import("vue").DefineComponent<{}, () =>
|
|
152
|
+
declare const XhCalendarGridBody: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
149
153
|
[key: string]: any;
|
|
150
154
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
151
|
-
declare const XhCalendarWeekRow: import("vue").DefineComponent<{}, () =>
|
|
155
|
+
declare const XhCalendarWeekRow: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
152
156
|
[key: string]: any;
|
|
153
157
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
154
158
|
declare const XhCalendarWeekDay: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
@@ -156,7 +160,7 @@ declare const XhCalendarWeekDay: import("vue").DefineComponent<import("vue").Ext
|
|
|
156
160
|
type: PropType<number | string>;
|
|
157
161
|
required: true;
|
|
158
162
|
};
|
|
159
|
-
}>, () =>
|
|
163
|
+
}>, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
160
164
|
[key: string]: any;
|
|
161
165
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
162
166
|
value: {
|
|
@@ -170,7 +174,7 @@ declare const XhCalendarCell: import("vue").DefineComponent<import("vue").Extrac
|
|
|
170
174
|
type: StringConstructor;
|
|
171
175
|
required: true;
|
|
172
176
|
};
|
|
173
|
-
}>, () =>
|
|
177
|
+
}>, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
174
178
|
[key: string]: any;
|
|
175
179
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
176
180
|
/** ISO 日期串。 */
|
|
@@ -179,9 +183,9 @@ declare const XhCalendarCell: import("vue").DefineComponent<import("vue").Extrac
|
|
|
179
183
|
required: true;
|
|
180
184
|
};
|
|
181
185
|
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
182
|
-
declare const XhCalendarCellTrigger: import("vue").DefineComponent<{}, () =>
|
|
186
|
+
declare const XhCalendarCellTrigger: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
183
187
|
[key: string]: any;
|
|
184
188
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
185
189
|
//#endregion
|
|
186
|
-
export { XhCalendarCell, XhCalendarCellTrigger, XhCalendarGrid, XhCalendarGridBody, XhCalendarGridHead, XhCalendarHeader, XhCalendarHeading, XhCalendarNextTrigger, XhCalendarPrevTrigger, XhCalendarRoot, XhCalendarWeekDay, XhCalendarWeekRow };
|
|
190
|
+
export { CalendarRootSlotProps, XhCalendarCell, XhCalendarCellTrigger, XhCalendarGrid, XhCalendarGridBody, XhCalendarGridHead, XhCalendarHeader, XhCalendarHeading, XhCalendarNextTrigger, XhCalendarPrevTrigger, XhCalendarRoot, XhCalendarWeekDay, XhCalendarWeekRow };
|
|
187
191
|
//# sourceMappingURL=calendar.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"calendar.d.ts","names":[],"sources":["../../../src/components/calendar/calendar.ts"],"mappings":";;;;KAQK,gBAAgB;
|
|
1
|
+
{"version":3,"file":"calendar.d.ts","names":[],"sources":["../../../src/components/calendar/calendar.ts"],"mappings":";;;;KAQK,gBAAgB;;KAGT,wBAAwB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BAAA,oBAAA,4BAAA;;8BAOhC,qCAAA,iDAAA,aAAA,eAAA,oDAAA"}
|
|
@@ -60,6 +60,7 @@ const XhCalendarRoot = defineComponent({
|
|
|
60
60
|
"focused-value-change": (_details) => true,
|
|
61
61
|
"update:focusedValue": (_focusedValue) => true
|
|
62
62
|
},
|
|
63
|
+
slots: Object,
|
|
63
64
|
setup(props, { slots, emit }) {
|
|
64
65
|
const notifyValue = (details) => {
|
|
65
66
|
emit("value-change", details);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"calendar.js","names":[],"sources":["../../../src/components/calendar/calendar.ts"],"sourcesContent":["import type { CalendarCellProps, CalendarSchema, CalendarSelectionMode, CalendarWeekdayFormat } from '@xihan-ui/headless'\nimport type { PropType } from 'vue'\nimport type { PayloadOf } from '../../runtime/payload'\nimport { computed, defineComponent, h } from 'vue'\nimport { withXhConfig } from '../../config/config'\nimport { provideCalendar, provideCalendarCell, useCalendarCellContext, useCalendarContext } from './context'\nimport { useCalendar } from './use-calendar'\n\ntype CalendarProps = CalendarSchema['props']\n\nexport const XhCalendarRoot = defineComponent({\n name: 'XhCalendarRoot',\n // 缺省值由 connect 与机器给出,这里一律 default: undefined\n props: {\n value: { type: [String, Array] as PropType<string | string[]>, default: undefined },\n defaultValue: { type: [String, Array] as PropType<string | string[]>, default: undefined },\n selectionMode: { type: String as PropType<CalendarSelectionMode>, default: undefined },\n focusedValue: { type: String, default: undefined },\n defaultFocusedValue: { type: String, default: undefined },\n min: { type: String, default: undefined },\n max: { type: String, default: undefined },\n isDateUnavailable: { type: Function as PropType<(value: string) => boolean>, default: undefined },\n locale: { type: String, default: undefined },\n timeZone: { type: String, default: undefined },\n disabled: Boolean,\n readOnly: Boolean,\n weekdayFormat: { type: String as PropType<CalendarWeekdayFormat>, default: undefined },\n fixedWeeks: Boolean,\n },\n // *-change 携带 details 对象,update:* 携带裸值;选中值恒为数组,单选时长度 ≤ 1\n emits: {\n 'value-change': (_details: PayloadOf<CalendarProps, 'onValueChange'>) => true,\n 'update:value': (_value: PayloadOf<CalendarProps, 'onValueChange'>['value']) => true,\n 'focused-value-change': (_details: PayloadOf<CalendarProps, 'onFocusedValueChange'>) => true,\n 'update:focusedValue': (_focusedValue: PayloadOf<CalendarProps, 'onFocusedValueChange'>['focusedValue']) => true,\n },\n setup(props, { slots, emit }) {\n const notifyValue: CalendarProps['onValueChange'] = (details) => {\n emit('value-change', details)\n emit('update:value', details.value)\n }\n const notifyFocus: CalendarProps['onFocusedValueChange'] = (details) => {\n emit('focused-value-change', details)\n emit('update:focusedValue', details.focusedValue)\n }\n const ctx = useCalendar(withXhConfig('calendar', props) as CalendarProps, notifyValue, notifyFocus)\n provideCalendar(ctx)\n // 网格与表头由作者照插槽里的 weeks / weekDays 自行渲染\n return () => h('div', ctx.api.value.getRootProps() as Record<string, unknown>, slots.default?.({\n value: ctx.api.value.value,\n focusedValue: ctx.api.value.focusedValue,\n visibleMonth: ctx.api.value.visibleMonth,\n weeks: ctx.api.value.weeks,\n weekDays: ctx.api.value.weekDays,\n headingLabel: ctx.api.value.headingLabel,\n canGoPrev: ctx.api.value.canGoPrev,\n canGoNext: ctx.api.value.canGoNext,\n isSelected: ctx.api.value.isSelected,\n isUnavailable: ctx.api.value.isUnavailable,\n setValue: ctx.api.value.setValue,\n select: ctx.api.value.select,\n focus: ctx.api.value.focus,\n goToPrevMonth: ctx.api.value.goToPrevMonth,\n goToNextMonth: ctx.api.value.goToNextMonth,\n }))\n },\n})\n\nexport const XhCalendarHeader = defineComponent({\n name: 'XhCalendarHeader',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h('div', ctx.api.value.getHeaderProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCalendarPrevTrigger = defineComponent({\n name: 'XhCalendarPrevTrigger',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h('button', ctx.api.value.getPrevTriggerProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCalendarNextTrigger = defineComponent({\n name: 'XhCalendarNextTrigger',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h('button', ctx.api.value.getNextTriggerProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCalendarHeading = defineComponent({\n name: 'XhCalendarHeading',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n // 有插槽用插槽,否则渲染 headingLabel\n return () => h(\n 'div',\n ctx.api.value.getHeadingProps() as Record<string, unknown>,\n slots.default?.() ?? ctx.api.value.headingLabel,\n )\n },\n})\n\nexport const XhCalendarGrid = defineComponent({\n name: 'XhCalendarGrid',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h(\n 'div',\n { ...ctx.api.value.getGridProps() as Record<string, unknown>, ref: ctx.gridRef },\n slots.default?.(),\n )\n },\n})\n\nexport const XhCalendarGridHead = defineComponent({\n name: 'XhCalendarGridHead',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h('div', ctx.api.value.getGridHeadProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCalendarGridBody = defineComponent({\n name: 'XhCalendarGridBody',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h('div', ctx.api.value.getGridBodyProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\n// 表头行与日期行共用同一个 role=row\nexport const XhCalendarWeekRow = defineComponent({\n name: 'XhCalendarWeekRow',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h('div', ctx.api.value.getWeekRowProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCalendarWeekDay = defineComponent({\n name: 'XhCalendarWeekDay',\n props: {\n // 列序 0-6,兼收字符串\n value: { type: [Number, String] as PropType<number | string>, required: true },\n },\n setup(props, { slots }) {\n const ctx = useCalendarContext()\n const index = computed(() => Number(props.value))\n return () => h(\n 'span',\n ctx.api.value.getWeekDayProps({ value: index.value }) as Record<string, unknown>,\n slots.default?.() ?? ctx.api.value.weekDays[index.value]?.label,\n )\n },\n})\n\nexport const XhCalendarCell = defineComponent({\n name: 'XhCalendarCell',\n props: {\n /** ISO 日期串。 */\n value: { type: String, required: true },\n },\n setup(props, { slots }) {\n const ctx = useCalendarContext()\n const cell = computed<CalendarCellProps>(() => ({ value: props.value }))\n provideCalendarCell({ cell })\n // 不上报格子卸载,翻月后由机器按聚焦日重新落点\n return () => h('div', ctx.api.value.getCellProps(cell.value) as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCalendarCellTrigger = defineComponent({\n name: 'XhCalendarCellTrigger',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n const { cell } = useCalendarCellContext()\n return () => h('div', ctx.api.value.getCellTriggerProps(cell.value) as Record<string, unknown>, slots.default?.())\n },\n})\n"],"mappings":";;;;;AAUA,MAAa,iBAAiB,gBAAgB;CAC5C,MAAM;CAEN,OAAO;EACL,OAAO;GAAE,MAAM,CAAC,QAAQ,KAAK;GAAkC,SAAS,KAAA;EAAU;EAClF,cAAc;GAAE,MAAM,CAAC,QAAQ,KAAK;GAAkC,SAAS,KAAA;EAAU;EACzF,eAAe;GAAE,MAAM;GAA2C,SAAS,KAAA;EAAU;EACrF,cAAc;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EACjD,qBAAqB;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EACxD,KAAK;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EACxC,KAAK;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EACxC,mBAAmB;GAAE,MAAM;GAAkD,SAAS,KAAA;EAAU;EAChG,QAAQ;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EAC3C,UAAU;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EAC7C,UAAU;EACV,UAAU;EACV,eAAe;GAAE,MAAM;GAA2C,SAAS,KAAA;EAAU;EACrF,YAAY;CACd;CAEA,OAAO;EACL,iBAAiB,aAAwD;EACzE,iBAAiB,WAA+D;EAChF,yBAAyB,aAA+D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AAC;AAED,MAAa,oBAAoB,gBAAgB;CAC/C,MAAM;CACN,OAAO,EAEL,OAAO;EAAE,MAAM,CAAC,QAAQ,MAAM;EAAgC,UAAU;CAAK,EAC/E;CACA,MAAM,OAAO,EAAE,SAAS;EACtB,MAAM,MAAM,mBAAmB;EAC/B,MAAM,QAAQ,eAAe,OAAO,MAAM,KAAK,CAAC;EAChD,aAAa,EACX,QACA,IAAI,IAAI,MAAM,gBAAgB,EAAE,OAAO,MAAM,MAAM,CAAC,GACpD,MAAM,UAAU,KAAK,IAAI,IAAI,MAAM,SAAS,MAAM,MAAM,EAAE,KAC5D;CACF;AACF,CAAC;AAED,MAAa,iBAAiB,gBAAgB;CAC5C,MAAM;CACN,OAAO;;AAEL,OAAO;EAAE,MAAM;EAAQ,UAAU;CAAK,EACxC;CACA,MAAM,OAAO,EAAE,SAAS;EACtB,MAAM,MAAM,mBAAmB;EAC/B,MAAM,OAAO,gBAAmC,EAAE,OAAO,MAAM,MAAM,EAAE;EACvE,oBAAoB,EAAE,KAAK,CAAC;EAE5B,aAAa,EAAE,OAAO,IAAI,IAAI,MAAM,aAAa,KAAK,KAAK,GAA8B,MAAM,UAAU,CAAC;CAC5G;AACF,CAAC;AAED,MAAa,wBAAwB,gBAAgB;CACnD,MAAM;CACN,MAAM,GAAG,EAAE,SAAS;EAClB,MAAM,MAAM,mBAAmB;EAC/B,MAAM,EAAE,SAAS,uBAAuB;EACxC,aAAa,EAAE,OAAO,IAAI,IAAI,MAAM,oBAAoB,KAAK,KAAK,GAA8B,MAAM,UAAU,CAAC;CACnH;AACF,CAAC"}
|
|
1
|
+
{"version":3,"file":"calendar.js","names":[],"sources":["../../../src/components/calendar/calendar.ts"],"sourcesContent":["import type { CalendarApi, CalendarCellProps, CalendarSchema, CalendarSelectionMode, CalendarWeekdayFormat } from '@xihan-ui/headless'\nimport type { PropType, SlotsType, VNode } from 'vue'\nimport type { PayloadOf } from '../../runtime/payload'\nimport { computed, defineComponent, h } from 'vue'\nimport { withXhConfig } from '../../config/config'\nimport { provideCalendar, provideCalendarCell, useCalendarCellContext, useCalendarContext } from './context'\nimport { useCalendar } from './use-calendar'\n\ntype CalendarProps = CalendarSchema['props']\n\n/** 默认插槽的载荷:选中值与聚焦日、展示月的日期矩阵与表头,以及选中、聚焦、翻月的动作。 */\nexport type CalendarRootSlotProps = Pick<\n CalendarApi,\n | 'value'\n | 'focusedValue'\n | 'visibleMonth'\n | 'weeks'\n | 'weekDays'\n | 'headingLabel'\n | 'canGoPrev'\n | 'canGoNext'\n | 'isSelected'\n | 'isUnavailable'\n | 'setValue'\n | 'select'\n | 'focus'\n | 'goToPrevMonth'\n | 'goToNextMonth'\n>\n\nexport const XhCalendarRoot = defineComponent({\n name: 'XhCalendarRoot',\n // 缺省值由 connect 与机器给出,这里一律 default: undefined\n props: {\n value: { type: [String, Array] as PropType<string | string[]>, default: undefined },\n defaultValue: { type: [String, Array] as PropType<string | string[]>, default: undefined },\n selectionMode: { type: String as PropType<CalendarSelectionMode>, default: undefined },\n focusedValue: { type: String, default: undefined },\n defaultFocusedValue: { type: String, default: undefined },\n min: { type: String, default: undefined },\n max: { type: String, default: undefined },\n isDateUnavailable: { type: Function as PropType<(value: string) => boolean>, default: undefined },\n locale: { type: String, default: undefined },\n timeZone: { type: String, default: undefined },\n disabled: Boolean,\n readOnly: Boolean,\n weekdayFormat: { type: String as PropType<CalendarWeekdayFormat>, default: undefined },\n fixedWeeks: Boolean,\n },\n // *-change 携带 details 对象,update:* 携带裸值;选中值恒为数组,单选时长度 ≤ 1\n emits: {\n 'value-change': (_details: PayloadOf<CalendarProps, 'onValueChange'>) => true,\n 'update:value': (_value: PayloadOf<CalendarProps, 'onValueChange'>['value']) => true,\n 'focused-value-change': (_details: PayloadOf<CalendarProps, 'onFocusedValueChange'>) => true,\n 'update:focusedValue': (_focusedValue: PayloadOf<CalendarProps, 'onFocusedValueChange'>['focusedValue']) => true,\n },\n slots: Object as SlotsType<{\n default?: (props: CalendarRootSlotProps) => VNode[]\n }>,\n setup(props, { slots, emit }) {\n const notifyValue: CalendarProps['onValueChange'] = (details) => {\n emit('value-change', details)\n emit('update:value', details.value)\n }\n const notifyFocus: CalendarProps['onFocusedValueChange'] = (details) => {\n emit('focused-value-change', details)\n emit('update:focusedValue', details.focusedValue)\n }\n const ctx = useCalendar(withXhConfig('calendar', props) as CalendarProps, notifyValue, notifyFocus)\n provideCalendar(ctx)\n // 网格与表头由作者照插槽里的 weeks / weekDays 自行渲染\n return () => h('div', ctx.api.value.getRootProps() as Record<string, unknown>, slots.default?.({\n value: ctx.api.value.value,\n focusedValue: ctx.api.value.focusedValue,\n visibleMonth: ctx.api.value.visibleMonth,\n weeks: ctx.api.value.weeks,\n weekDays: ctx.api.value.weekDays,\n headingLabel: ctx.api.value.headingLabel,\n canGoPrev: ctx.api.value.canGoPrev,\n canGoNext: ctx.api.value.canGoNext,\n isSelected: ctx.api.value.isSelected,\n isUnavailable: ctx.api.value.isUnavailable,\n setValue: ctx.api.value.setValue,\n select: ctx.api.value.select,\n focus: ctx.api.value.focus,\n goToPrevMonth: ctx.api.value.goToPrevMonth,\n goToNextMonth: ctx.api.value.goToNextMonth,\n }))\n },\n})\n\nexport const XhCalendarHeader = defineComponent({\n name: 'XhCalendarHeader',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h('div', ctx.api.value.getHeaderProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCalendarPrevTrigger = defineComponent({\n name: 'XhCalendarPrevTrigger',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h('button', ctx.api.value.getPrevTriggerProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCalendarNextTrigger = defineComponent({\n name: 'XhCalendarNextTrigger',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h('button', ctx.api.value.getNextTriggerProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCalendarHeading = defineComponent({\n name: 'XhCalendarHeading',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n // 有插槽用插槽,否则渲染 headingLabel\n return () => h(\n 'div',\n ctx.api.value.getHeadingProps() as Record<string, unknown>,\n slots.default?.() ?? ctx.api.value.headingLabel,\n )\n },\n})\n\nexport const XhCalendarGrid = defineComponent({\n name: 'XhCalendarGrid',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h(\n 'div',\n { ...ctx.api.value.getGridProps() as Record<string, unknown>, ref: ctx.gridRef },\n slots.default?.(),\n )\n },\n})\n\nexport const XhCalendarGridHead = defineComponent({\n name: 'XhCalendarGridHead',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h('div', ctx.api.value.getGridHeadProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCalendarGridBody = defineComponent({\n name: 'XhCalendarGridBody',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h('div', ctx.api.value.getGridBodyProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\n// 表头行与日期行共用同一个 role=row\nexport const XhCalendarWeekRow = defineComponent({\n name: 'XhCalendarWeekRow',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n return () => h('div', ctx.api.value.getWeekRowProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCalendarWeekDay = defineComponent({\n name: 'XhCalendarWeekDay',\n props: {\n // 列序 0-6,兼收字符串\n value: { type: [Number, String] as PropType<number | string>, required: true },\n },\n setup(props, { slots }) {\n const ctx = useCalendarContext()\n const index = computed(() => Number(props.value))\n return () => h(\n 'span',\n ctx.api.value.getWeekDayProps({ value: index.value }) as Record<string, unknown>,\n slots.default?.() ?? ctx.api.value.weekDays[index.value]?.label,\n )\n },\n})\n\nexport const XhCalendarCell = defineComponent({\n name: 'XhCalendarCell',\n props: {\n /** ISO 日期串。 */\n value: { type: String, required: true },\n },\n setup(props, { slots }) {\n const ctx = useCalendarContext()\n const cell = computed<CalendarCellProps>(() => ({ value: props.value }))\n provideCalendarCell({ cell })\n // 不上报格子卸载,翻月后由机器按聚焦日重新落点\n return () => h('div', ctx.api.value.getCellProps(cell.value) as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCalendarCellTrigger = defineComponent({\n name: 'XhCalendarCellTrigger',\n setup(_, { slots }) {\n const ctx = useCalendarContext()\n const { cell } = useCalendarCellContext()\n return () => h('div', ctx.api.value.getCellTriggerProps(cell.value) as Record<string, unknown>, slots.default?.())\n },\n})\n"],"mappings":";;;;;AA8BA,MAAa,iBAAiB,gBAAgB;CAC5C,MAAM;CAEN,OAAO;EACL,OAAO;GAAE,MAAM,CAAC,QAAQ,KAAK;GAAkC,SAAS,KAAA;EAAU;EAClF,cAAc;GAAE,MAAM,CAAC,QAAQ,KAAK;GAAkC,SAAS,KAAA;EAAU;EACzF,eAAe;GAAE,MAAM;GAA2C,SAAS,KAAA;EAAU;EACrF,cAAc;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EACjD,qBAAqB;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EACxD,KAAK;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EACxC,KAAK;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EACxC,mBAAmB;GAAE,MAAM;GAAkD,SAAS,KAAA;EAAU;EAChG,QAAQ;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EAC3C,UAAU;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EAC7C,UAAU;EACV,UAAU;EACV,eAAe;GAAE,MAAM;GAA2C,SAAS,KAAA;EAAU;EACrF,YAAY;CACd;CAEA,OAAO;EACL,iBAAiB,aAAwD;EACzE,iBAAiB,WAA+D;EAChF,yBAAyB,aAA+D;EACxF,wBAAwB,kBAAoF;CAC9G;CACA,OAAO;CAGP,MAAM,OAAO,EAAE,OAAO,QAAQ;EAC5B,MAAM,eAA+C,YAAY;GAC/D,KAAK,gBAAgB,OAAO;GAC5B,KAAK,gBAAgB,QAAQ,KAAK;EACpC;EACA,MAAM,eA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AAmB;EAC/B,MAAM,QAAQ,eAAe,OAAO,MAAM,KAAK,CAAC;EAChD,aAAa,EACX,QACA,IAAI,IAAI,MAAM,gBAAgB,EAAE,OAAO,MAAM,MAAM,CAAC,GACpD,MAAM,UAAU,KAAK,IAAI,IAAI,MAAM,SAAS,MAAM,MAAM,EAAE,KAC5D;CACF;AACF,CAAC;AAED,MAAa,iBAAiB,gBAAgB;CAC5C,MAAM;CACN,OAAO;;AAEL,OAAO;EAAE,MAAM;EAAQ,UAAU;CAAK,EACxC;CACA,MAAM,OAAO,EAAE,SAAS;EACtB,MAAM,MAAM,mBAAmB;EAC/B,MAAM,OAAO,gBAAmC,EAAE,OAAO,MAAM,MAAM,EAAE;EACvE,oBAAoB,EAAE,KAAK,CAAC;EAE5B,aAAa,EAAE,OAAO,IAAI,IAAI,MAAM,aAAa,KAAK,KAAK,GAA8B,MAAM,UAAU,CAAC;CAC5G;AACF,CAAC;AAED,MAAa,wBAAwB,gBAAgB;CACnD,MAAM;CACN,MAAM,GAAG,EAAE,SAAS;EAClB,MAAM,MAAM,mBAAmB;EAC/B,MAAM,EAAE,SAAS,uBAAuB;EACxC,aAAa,EAAE,OAAO,IAAI,IAAI,MAAM,oBAAoB,KAAK,KAAK,GAA8B,MAAM,UAAU,CAAC;CACnH;AACF,CAAC"}
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { PayloadOf } from "../../runtime/payload.js";
|
|
2
|
-
import { PropType } from "vue";
|
|
3
|
-
import { CarouselSchema, CarouselTranslations } from "@xihan-ui/headless";
|
|
2
|
+
import { PropType, SlotsType, VNode } from "vue";
|
|
3
|
+
import { CarouselApi, CarouselSchema, CarouselTranslations } from "@xihan-ui/headless";
|
|
4
4
|
import { Direction, Orientation } from "@xihan-ui/kernel";
|
|
5
5
|
//#region src/components/carousel/carousel.d.ts
|
|
6
6
|
type CarouselProps = CarouselSchema['props'];
|
|
7
|
+
/** 默认插槽的载荷:当前页与翻页区间、自动播放与拖拽状态,以及翻页、播放的命令。 */
|
|
8
|
+
type CarouselRootSlotProps = Pick<CarouselApi, 'page' | 'totalPages' | 'slideCount' | 'slideRange' | 'pageSnapPoints' | 'canScrollPrev' | 'canScrollNext' | 'autoplaying' | 'paused' | 'dragging' | 'isInView' | 'setPage' | 'goToPrev' | 'goToNext' | 'play' | 'pause' | 'resume'>;
|
|
7
9
|
declare const XhCarouselRoot: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
8
10
|
page: {
|
|
9
11
|
type: NumberConstructor;
|
|
@@ -53,7 +55,7 @@ declare const XhCarouselRoot: import("vue").DefineComponent<import("vue").Extrac
|
|
|
53
55
|
type: PropType<Partial<CarouselTranslations>>;
|
|
54
56
|
default: undefined;
|
|
55
57
|
};
|
|
56
|
-
}>, () =>
|
|
58
|
+
}>, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
57
59
|
[key: string]: any;
|
|
58
60
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
59
61
|
'page-change': (_details: PayloadOf<CarouselProps, "onPageChange">) => true;
|
|
@@ -116,18 +118,20 @@ declare const XhCarouselRoot: import("vue").DefineComponent<import("vue").Extrac
|
|
|
116
118
|
dir: Direction;
|
|
117
119
|
translations: Partial<CarouselTranslations>;
|
|
118
120
|
page: number;
|
|
119
|
-
defaultPage: number;
|
|
120
121
|
slideCount: number;
|
|
122
|
+
defaultPage: number;
|
|
121
123
|
slidesPerPage: number;
|
|
122
124
|
slidesPerMove: number;
|
|
123
125
|
loop: boolean;
|
|
124
126
|
allowPointerDrag: boolean;
|
|
125
127
|
spacing: string;
|
|
126
|
-
}, {
|
|
127
|
-
|
|
128
|
+
}, SlotsType<{
|
|
129
|
+
default?: (props: CarouselRootSlotProps) => VNode[];
|
|
130
|
+
}>, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
131
|
+
declare const XhCarouselViewport: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
128
132
|
[key: string]: any;
|
|
129
133
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
130
|
-
declare const XhCarouselItemGroup: import("vue").DefineComponent<{}, () =>
|
|
134
|
+
declare const XhCarouselItemGroup: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
131
135
|
[key: string]: any;
|
|
132
136
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
133
137
|
declare const XhCarouselItem: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
@@ -135,7 +139,7 @@ declare const XhCarouselItem: import("vue").DefineComponent<import("vue").Extrac
|
|
|
135
139
|
type: PropType<number | string>;
|
|
136
140
|
required: true;
|
|
137
141
|
};
|
|
138
|
-
}>, () =>
|
|
142
|
+
}>, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
139
143
|
[key: string]: any;
|
|
140
144
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
141
145
|
index: {
|
|
@@ -143,13 +147,13 @@ declare const XhCarouselItem: import("vue").DefineComponent<import("vue").Extrac
|
|
|
143
147
|
required: true;
|
|
144
148
|
};
|
|
145
149
|
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
146
|
-
declare const XhCarouselPrevTrigger: import("vue").DefineComponent<{}, () =>
|
|
150
|
+
declare const XhCarouselPrevTrigger: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
147
151
|
[key: string]: any;
|
|
148
152
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
149
|
-
declare const XhCarouselNextTrigger: import("vue").DefineComponent<{}, () =>
|
|
153
|
+
declare const XhCarouselNextTrigger: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
150
154
|
[key: string]: any;
|
|
151
155
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
152
|
-
declare const XhCarouselIndicatorGroup: import("vue").DefineComponent<{}, () =>
|
|
156
|
+
declare const XhCarouselIndicatorGroup: import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
153
157
|
[key: string]: any;
|
|
154
158
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
155
159
|
declare const XhCarouselIndicator: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
@@ -157,7 +161,7 @@ declare const XhCarouselIndicator: import("vue").DefineComponent<import("vue").E
|
|
|
157
161
|
type: PropType<number | string>;
|
|
158
162
|
required: true;
|
|
159
163
|
};
|
|
160
|
-
}>, () =>
|
|
164
|
+
}>, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
161
165
|
[key: string]: any;
|
|
162
166
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
163
167
|
index: {
|
|
@@ -166,5 +170,5 @@ declare const XhCarouselIndicator: import("vue").DefineComponent<import("vue").E
|
|
|
166
170
|
};
|
|
167
171
|
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
168
172
|
//#endregion
|
|
169
|
-
export { XhCarouselIndicator, XhCarouselIndicatorGroup, XhCarouselItem, XhCarouselItemGroup, XhCarouselNextTrigger, XhCarouselPrevTrigger, XhCarouselRoot, XhCarouselViewport };
|
|
173
|
+
export { CarouselRootSlotProps, XhCarouselIndicator, XhCarouselIndicatorGroup, XhCarouselItem, XhCarouselItemGroup, XhCarouselNextTrigger, XhCarouselPrevTrigger, XhCarouselRoot, XhCarouselViewport };
|
|
170
174
|
//# sourceMappingURL=carousel.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"carousel.d.ts","names":[],"sources":["../../../src/components/carousel/carousel.ts"],"mappings":";;;;;KASK,gBAAgB;
|
|
1
|
+
{"version":3,"file":"carousel.d.ts","names":[],"sources":["../../../src/components/carousel/carousel.ts"],"mappings":";;;;;KASK,gBAAgB;;KAGT,wBAAwB,KAClC;cAoBW,8BAAc,8BAAA;;;;;;;;;;;;;;;;;;;;;;IASQ,MAAA,SAAS;;;;IACjB,MAAA,SAAS;;;;;;;;IAGO,MAAA;;;;;;;;;;;;IAGP,MAAA,SAAS,QAAQ;;;;;;EAIvB,gBAAA,UAAA,UAAU;EACb,gBAAA,OAAA,UAAU;;;;;;;;;;;;;;;;;;;;;;;IAZF,MAAA,SAAS;;;;IACjB,MAAA,SAAS;;;;;;;;IAGO,MAAA;;;;;;;;;;;;IAGP,MAAA,SAAS,QAAQ;;;;;;;;;;;;;;;;;;;;EAQvC,WAAC,OAAO,0BAA0B;kCA6B9C;cAEW,kCAAkB,0BAAA,oBAAA,4BAAA;;8BAM7B,qCAAA,iDAAA,aAAA,eAAA,oDAAA;cAEW,mCAAmB,0BAAA,oBAAA,4BAAA;;8BAM9B,qCAAA,iDAAA,aAAA,eAAA,oDAAA;cAEW,8BAAc,8BAAA;;IAIY,MAAA;;;;;;;IAAA,MAAA;;;MAUrC,oDAAA;cAEW,qCAAqB,0BAAA,oBAAA,4BAAA;;8BAMhC,qCAAA,iDAAA,aAAA,eAAA,oDAAA;cAEW,qCAAqB,0BAAA,oBAAA,4BAAA;;8BAMhC,qCAAA,iDAAA,aAAA,eAAA,oDAAA;cAEW,wCAAwB,0BAAA,oBAAA,4BAAA;;8BAMnC,qCAAA,iDAAA,aAAA,eAAA,oDAAA;cAEW,mCAAmB,8BAAA;;IAIO,MAAA;;;;;;;IAAA,MAAA;;;MAUrC,oDAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"carousel.js","names":[],"sources":["../../../src/components/carousel/carousel.ts"],"sourcesContent":["import type { CarouselSchema, CarouselTranslations } from '@xihan-ui/headless'\nimport type { Direction, Orientation } from '@xihan-ui/kernel'\nimport type { PropType } from 'vue'\nimport type { PayloadOf } from '../../runtime/payload'\nimport { defineComponent, h } from 'vue'\nimport { withXhConfig } from '../../config/config'\nimport { provideCarousel, useCarouselContext } from './context'\nimport { useCarousel } from './use-carousel'\n\ntype CarouselProps = CarouselSchema['props']\n\nexport const XhCarouselRoot = defineComponent({\n name: 'XhCarouselRoot',\n // 缺省值由 connect 给出,这里一律 default: undefined\n props: {\n page: { type: Number, default: undefined },\n defaultPage: { type: Number, default: undefined },\n slideCount: { type: Number, default: undefined },\n slidesPerPage: { type: Number, default: undefined },\n slidesPerMove: { type: Number, default: undefined },\n orientation: { type: String as PropType<Orientation>, default: undefined },\n dir: { type: String as PropType<Direction>, default: undefined },\n loop: { type: Boolean, default: undefined },\n // 布尔或毫秒:true 用默认间隔,数值即间隔\n autoplay: { type: [Boolean, Number] as PropType<boolean | number>, default: undefined },\n allowPointerDrag: { type: Boolean, default: undefined },\n spacing: { type: String, default: undefined },\n translations: { type: Object as PropType<Partial<CarouselTranslations>>, default: undefined },\n },\n // page-change 携带 { page },update:page 携带裸页码\n emits: {\n 'page-change': (_details: PayloadOf<CarouselProps, 'onPageChange'>) => true,\n 'update:page': (_page: PayloadOf<CarouselProps, 'onPageChange'>['page']) => true,\n },\n setup(props, { slots, emit }) {\n const notify: CarouselProps['onPageChange'] = (details) => {\n emit('page-change', details)\n emit('update:page', details.page)\n }\n const ctx = useCarousel(withXhConfig('carousel', props) as CarouselProps, notify)\n provideCarousel(ctx)\n return () => h('div', ctx.api.value.getRootProps() as Record<string, unknown>, slots.default?.({\n page: ctx.api.value.page,\n totalPages: ctx.api.value.totalPages,\n slideCount: ctx.api.value.slideCount,\n slideRange: ctx.api.value.slideRange,\n pageSnapPoints: ctx.api.value.pageSnapPoints,\n canScrollPrev: ctx.api.value.canScrollPrev,\n canScrollNext: ctx.api.value.canScrollNext,\n autoplaying: ctx.api.value.autoplaying,\n paused: ctx.api.value.paused,\n dragging: ctx.api.value.dragging,\n isInView: ctx.api.value.isInView,\n setPage: ctx.api.value.setPage,\n goToPrev: ctx.api.value.goToPrev,\n goToNext: ctx.api.value.goToNext,\n play: ctx.api.value.play,\n pause: ctx.api.value.pause,\n resume: ctx.api.value.resume,\n }))\n },\n})\n\nexport const XhCarouselViewport = defineComponent({\n name: 'XhCarouselViewport',\n setup(_, { slots }) {\n const ctx = useCarouselContext()\n return () => h('div', ctx.api.value.getViewportProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCarouselItemGroup = defineComponent({\n name: 'XhCarouselItemGroup',\n setup(_, { slots }) {\n const ctx = useCarouselContext()\n return () => h('div', ctx.api.value.getItemGroupProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCarouselItem = defineComponent({\n name: 'XhCarouselItem',\n props: {\n // 下标由作者声明,兼收字符串以支持模板里写 index=\"0\"\n index: { type: [Number, String] as PropType<number | string>, required: true },\n },\n setup(props, { slots }) {\n const ctx = useCarouselContext()\n return () => h(\n 'div',\n ctx.api.value.getItemProps({ index: Number(props.index) }) as Record<string, unknown>,\n slots.default?.(),\n )\n },\n})\n\nexport const XhCarouselPrevTrigger = defineComponent({\n name: 'XhCarouselPrevTrigger',\n setup(_, { slots }) {\n const ctx = useCarouselContext()\n return () => h('button', ctx.api.value.getPrevTriggerProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCarouselNextTrigger = defineComponent({\n name: 'XhCarouselNextTrigger',\n setup(_, { slots }) {\n const ctx = useCarouselContext()\n return () => h('button', ctx.api.value.getNextTriggerProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCarouselIndicatorGroup = defineComponent({\n name: 'XhCarouselIndicatorGroup',\n setup(_, { slots }) {\n const ctx = useCarouselContext()\n return () => h('div', ctx.api.value.getIndicatorGroupProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCarouselIndicator = defineComponent({\n name: 'XhCarouselIndicator',\n props: {\n // 指示点对应的页码,0 基;兼收字符串\n index: { type: [Number, String] as PropType<number | string>, required: true },\n },\n setup(props, { slots }) {\n const ctx = useCarouselContext()\n return () => h(\n 'button',\n ctx.api.value.getIndicatorProps({ index: Number(props.index) }) as Record<string, unknown>,\n slots.default?.(),\n )\n },\n})\n"],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"carousel.js","names":[],"sources":["../../../src/components/carousel/carousel.ts"],"sourcesContent":["import type { CarouselApi, CarouselSchema, CarouselTranslations } from '@xihan-ui/headless'\nimport type { Direction, Orientation } from '@xihan-ui/kernel'\nimport type { PropType, SlotsType, VNode } from 'vue'\nimport type { PayloadOf } from '../../runtime/payload'\nimport { defineComponent, h } from 'vue'\nimport { withXhConfig } from '../../config/config'\nimport { provideCarousel, useCarouselContext } from './context'\nimport { useCarousel } from './use-carousel'\n\ntype CarouselProps = CarouselSchema['props']\n\n/** 默认插槽的载荷:当前页与翻页区间、自动播放与拖拽状态,以及翻页、播放的命令。 */\nexport type CarouselRootSlotProps = Pick<\n CarouselApi,\n | 'page'\n | 'totalPages'\n | 'slideCount'\n | 'slideRange'\n | 'pageSnapPoints'\n | 'canScrollPrev'\n | 'canScrollNext'\n | 'autoplaying'\n | 'paused'\n | 'dragging'\n | 'isInView'\n | 'setPage'\n | 'goToPrev'\n | 'goToNext'\n | 'play'\n | 'pause'\n | 'resume'\n>\n\nexport const XhCarouselRoot = defineComponent({\n name: 'XhCarouselRoot',\n // 缺省值由 connect 给出,这里一律 default: undefined\n props: {\n page: { type: Number, default: undefined },\n defaultPage: { type: Number, default: undefined },\n slideCount: { type: Number, default: undefined },\n slidesPerPage: { type: Number, default: undefined },\n slidesPerMove: { type: Number, default: undefined },\n orientation: { type: String as PropType<Orientation>, default: undefined },\n dir: { type: String as PropType<Direction>, default: undefined },\n loop: { type: Boolean, default: undefined },\n // 布尔或毫秒:true 用默认间隔,数值即间隔\n autoplay: { type: [Boolean, Number] as PropType<boolean | number>, default: undefined },\n allowPointerDrag: { type: Boolean, default: undefined },\n spacing: { type: String, default: undefined },\n translations: { type: Object as PropType<Partial<CarouselTranslations>>, default: undefined },\n },\n // page-change 携带 { page },update:page 携带裸页码\n emits: {\n 'page-change': (_details: PayloadOf<CarouselProps, 'onPageChange'>) => true,\n 'update:page': (_page: PayloadOf<CarouselProps, 'onPageChange'>['page']) => true,\n },\n slots: Object as SlotsType<{\n default?: (props: CarouselRootSlotProps) => VNode[]\n }>,\n setup(props, { slots, emit }) {\n const notify: CarouselProps['onPageChange'] = (details) => {\n emit('page-change', details)\n emit('update:page', details.page)\n }\n const ctx = useCarousel(withXhConfig('carousel', props) as CarouselProps, notify)\n provideCarousel(ctx)\n return () => h('div', ctx.api.value.getRootProps() as Record<string, unknown>, slots.default?.({\n page: ctx.api.value.page,\n totalPages: ctx.api.value.totalPages,\n slideCount: ctx.api.value.slideCount,\n slideRange: ctx.api.value.slideRange,\n pageSnapPoints: ctx.api.value.pageSnapPoints,\n canScrollPrev: ctx.api.value.canScrollPrev,\n canScrollNext: ctx.api.value.canScrollNext,\n autoplaying: ctx.api.value.autoplaying,\n paused: ctx.api.value.paused,\n dragging: ctx.api.value.dragging,\n isInView: ctx.api.value.isInView,\n setPage: ctx.api.value.setPage,\n goToPrev: ctx.api.value.goToPrev,\n goToNext: ctx.api.value.goToNext,\n play: ctx.api.value.play,\n pause: ctx.api.value.pause,\n resume: ctx.api.value.resume,\n }))\n },\n})\n\nexport const XhCarouselViewport = defineComponent({\n name: 'XhCarouselViewport',\n setup(_, { slots }) {\n const ctx = useCarouselContext()\n return () => h('div', ctx.api.value.getViewportProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCarouselItemGroup = defineComponent({\n name: 'XhCarouselItemGroup',\n setup(_, { slots }) {\n const ctx = useCarouselContext()\n return () => h('div', ctx.api.value.getItemGroupProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCarouselItem = defineComponent({\n name: 'XhCarouselItem',\n props: {\n // 下标由作者声明,兼收字符串以支持模板里写 index=\"0\"\n index: { type: [Number, String] as PropType<number | string>, required: true },\n },\n setup(props, { slots }) {\n const ctx = useCarouselContext()\n return () => h(\n 'div',\n ctx.api.value.getItemProps({ index: Number(props.index) }) as Record<string, unknown>,\n slots.default?.(),\n )\n },\n})\n\nexport const XhCarouselPrevTrigger = defineComponent({\n name: 'XhCarouselPrevTrigger',\n setup(_, { slots }) {\n const ctx = useCarouselContext()\n return () => h('button', ctx.api.value.getPrevTriggerProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCarouselNextTrigger = defineComponent({\n name: 'XhCarouselNextTrigger',\n setup(_, { slots }) {\n const ctx = useCarouselContext()\n return () => h('button', ctx.api.value.getNextTriggerProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCarouselIndicatorGroup = defineComponent({\n name: 'XhCarouselIndicatorGroup',\n setup(_, { slots }) {\n const ctx = useCarouselContext()\n return () => h('div', ctx.api.value.getIndicatorGroupProps() as Record<string, unknown>, slots.default?.())\n },\n})\n\nexport const XhCarouselIndicator = defineComponent({\n name: 'XhCarouselIndicator',\n props: {\n // 指示点对应的页码,0 基;兼收字符串\n index: { type: [Number, String] as PropType<number | string>, required: true },\n },\n setup(props, { slots }) {\n const ctx = useCarouselContext()\n return () => h(\n 'button',\n ctx.api.value.getIndicatorProps({ index: Number(props.index) }) as Record<string, unknown>,\n slots.default?.(),\n )\n },\n})\n"],"mappings":";;;;;AAiCA,MAAa,iBAAiB,gBAAgB;CAC5C,MAAM;CAEN,OAAO;EACL,MAAM;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EACzC,aAAa;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EAChD,YAAY;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EAC/C,eAAe;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EAClD,eAAe;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EAClD,aAAa;GAAE,MAAM;GAAiC,SAAS,KAAA;EAAU;EACzE,KAAK;GAAE,MAAM;GAA+B,SAAS,KAAA;EAAU;EAC/D,MAAM;GAAE,MAAM;GAAS,SAAS,KAAA;EAAU;EAE1C,UAAU;GAAE,MAAM,CAAC,SAAS,MAAM;GAAiC,SAAS,KAAA;EAAU;EACtF,kBAAkB;GAAE,MAAM;GAAS,SAAS,KAAA;EAAU;EACtD,SAAS;GAAE,MAAM;GAAQ,SAAS,KAAA;EAAU;EAC5C,cAAc;GAAE,MAAM;GAAmD,SAAS,KAAA;EAAU;CAC9F;CAEA,OAAO;EACL,gBAAgB,aAAuD;EACvE,gBAAgB,UAA4D;CAC9E;CACA,OAAO;CAGP,MAAM,OAAO,EAAE,OAAO,QAAQ;EAC5B,MAAM,UAAyC,YAAY;GACzD,KAAK,eAAe,OAAO;GAC3B,KAAK,eAAe,QAAQ,IAAI;EAClC;EACA,MAAM,MAAM,YAAY,aAAa,YAAY,KAAK,GAAoB,MAAM;EAChF,gBAAgB,GAAG;EACnB,aAAa,EAAE,OAAO,IAAI,IAAI,MAAM,aAAa,GAA8B,MAAM,UAAU;GAC7F,MA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