mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
docs(changelog): 3.0.9
This commit is contained in:
parent
9dc1815b66
commit
b526bfeee9
@ -16,6 +16,19 @@ Vant follows [Semantic Versioning 2.0.0](https://semver.org/lang/zh-CN/).
|
|||||||
|
|
||||||
## Details
|
## Details
|
||||||
|
|
||||||
|
### [v3.0.9](https://github.com/youzan/vant/compare/v3.0.8...v3.0.9)
|
||||||
|
|
||||||
|
`2021-03-08`
|
||||||
|
|
||||||
|
**Feature**
|
||||||
|
|
||||||
|
- AddressList: add tag slots [#8292](https://github.com/youzan/vant/issues/8292)
|
||||||
|
|
||||||
|
**Bug Fixes**
|
||||||
|
|
||||||
|
- fix custom theme not work [#8301](https://github.com/youzan/vant/issues/8301)
|
||||||
|
- fix failed to install component in TypeScript [#8308](https://github.com/youzan/vant/issues/8308)
|
||||||
|
|
||||||
### [v3.0.8](https://github.com/youzan/vant/compare/v3.0.7...v3.0.8)
|
### [v3.0.8](https://github.com/youzan/vant/compare/v3.0.7...v3.0.8)
|
||||||
|
|
||||||
`2021-03-07`
|
`2021-03-07`
|
||||||
|
@ -16,6 +16,19 @@ Vant 遵循 [Semver](https://semver.org/lang/zh-CN/) 语义化版本规范。
|
|||||||
|
|
||||||
## 更新内容
|
## 更新内容
|
||||||
|
|
||||||
|
### [v3.0.9](https://github.com/youzan/vant/compare/v3.0.8...v3.0.9)
|
||||||
|
|
||||||
|
`2021-03-08`
|
||||||
|
|
||||||
|
**Feature**
|
||||||
|
|
||||||
|
- AddressList: 新增 tag 插槽 [#8292](https://github.com/youzan/vant/issues/8292)
|
||||||
|
|
||||||
|
**Bug Fixes**
|
||||||
|
|
||||||
|
- 修复主题定制不生效的问题 [#8301](https://github.com/youzan/vant/issues/8301)
|
||||||
|
- 修复在 TS 下使用 app.use 注册组件报错的问题 [#8308](https://github.com/youzan/vant/issues/8308)
|
||||||
|
|
||||||
### [v3.0.8](https://github.com/youzan/vant/compare/v3.0.7...v3.0.8)
|
### [v3.0.8](https://github.com/youzan/vant/compare/v3.0.7...v3.0.8)
|
||||||
|
|
||||||
`2021-03-07`
|
`2021-03-07`
|
||||||
|
@ -56,7 +56,7 @@ export default defineComponent({
|
|||||||
|
|
||||||
const renderTag = () => {
|
const renderTag = () => {
|
||||||
if (slots.tag) {
|
if (slots.tag) {
|
||||||
return slots.tag({ ...props.address });
|
return slots.tag(props.address);
|
||||||
}
|
}
|
||||||
if (props.address.isDefault && props.defaultTagText) {
|
if (props.address.isDefault && props.defaultTagText) {
|
||||||
return (
|
return (
|
||||||
|
@ -108,12 +108,12 @@ export default {
|
|||||||
|
|
||||||
### Slots
|
### Slots
|
||||||
|
|
||||||
| Name | Description | SlotProps |
|
| Name | Description | SlotProps |
|
||||||
| ----------- | --------------------------------- | --------------- |
|
| ------------ | ------------------------------ | --------------- |
|
||||||
| default | Custom content after list | - |
|
| default | Custom content after list | - |
|
||||||
| top | Custom content before list | - |
|
| top | Custom content before list | - |
|
||||||
| item-bottom | Custom content after list item | _item: Address_ |
|
| item-bottom | Custom content after list item | _item: Address_ |
|
||||||
| tag | Custom tag conetent for list item | _item: Address_ |
|
| tag `v3.0.9` | Custom tag of list item | _item: Address_ |
|
||||||
|
|
||||||
### Less Variables
|
### Less Variables
|
||||||
|
|
||||||
|
@ -112,12 +112,12 @@ export default {
|
|||||||
|
|
||||||
### Slots
|
### Slots
|
||||||
|
|
||||||
| 名称 | 说明 | 参数 |
|
| 名称 | 说明 | 参数 |
|
||||||
| ----------- | -------------------- | --------------- |
|
| ------------ | -------------------- | --------------- |
|
||||||
| default | 在列表下方插入内容 | - |
|
| default | 在列表下方插入内容 | - |
|
||||||
| top | 在顶部插入内容 | - |
|
| top | 在顶部插入内容 | - |
|
||||||
| item-bottom | 在列表项底部插入内容 | _item: Address_ |
|
| item-bottom | 在列表项底部插入内容 | _item: Address_ |
|
||||||
| tag | 列表项标签内容自定义 | _item: Address_ |
|
| tag `v3.0.9` | 自定义列表项标签内容 | _item: Address_ |
|
||||||
|
|
||||||
### 样式变量
|
### 样式变量
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||||
|
|
||||||
exports[`should render tag slot correctly 1`] = `
|
exports[`should render tag slot correctly 1`] = `
|
||||||
<div class="van-address-list">
|
<div class="van-address-list">
|
||||||
<div class="van-radio-group"
|
<div class="van-radio-group"
|
||||||
role="radiogroup"
|
role="radiogroup"
|
||||||
|
@ -51,7 +51,7 @@ test('should emit click-item event when item is clicked', () => {
|
|||||||
expect(wrapper.emitted('click-item')![0]).toEqual([list[0], 0]);
|
expect(wrapper.emitted('click-item')![0]).toEqual([list[0], 0]);
|
||||||
});
|
});
|
||||||
|
|
||||||
test('should render tag slot correctly', () => {
|
test('should render tag slot correctly', () => {
|
||||||
const wrapper = mount(AddressList, {
|
const wrapper = mount(AddressList, {
|
||||||
slots: {
|
slots: {
|
||||||
tag: () => 'Custom Tag',
|
tag: () => 'Custom Tag',
|
||||||
|
Loading…
x
Reference in New Issue
Block a user