docs(changelog): 3.0.9

This commit is contained in:
chenjiahan
2021-03-08 17:37:31 +08:00
parent 9dc1815b66
commit b526bfeee9
7 changed files with 41 additions and 15 deletions
+1 -1
View File
@@ -56,7 +56,7 @@ export default defineComponent({
const renderTag = () => {
if (slots.tag) {
return slots.tag({ ...props.address });
return slots.tag(props.address);
}
if (props.address.isDefault && props.defaultTagText) {
return (
+6 -6
View File
@@ -108,12 +108,12 @@ export default {
### Slots
| Name | Description | SlotProps |
| ----------- | --------------------------------- | --------------- |
| default | Custom content after list | - |
| top | Custom content before list | - |
| item-bottom | Custom content after list item | _item: Address_ |
| tag | Custom tag conetent for list item | _item: Address_ |
| Name | Description | SlotProps |
| ------------ | ------------------------------ | --------------- |
| default | Custom content after list | - |
| top | Custom content before list | - |
| item-bottom | Custom content after list item | _item: Address_ |
| tag `v3.0.9` | Custom tag of list item | _item: Address_ |
### Less Variables
+6 -6
View File
@@ -112,12 +112,12 @@ export default {
### Slots
| 名称 | 说明 | 参数 |
| ----------- | -------------------- | --------------- |
| default | 在列表下方插入内容 | - |
| top | 在顶部插入内容 | - |
| item-bottom | 在列表项底部插入内容 | _item: Address_ |
| tag | 列表项标签内容自定义 | _item: Address_ |
| 名称 | 说明 | 参数 |
| ------------ | -------------------- | --------------- |
| default | 在列表下方插入内容 | - |
| top | 在顶部插入内容 | - |
| item-bottom | 在列表项底部插入内容 | _item: Address_ |
| tag `v3.0.9` | 自定义列表项标签内容 | _item: Address_ |
### 样式变量
@@ -1,6 +1,6 @@
// 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-radio-group"
role="radiogroup"
+1 -1
View File
@@ -51,7 +51,7 @@ test('should emit click-item event when item is clicked', () => {
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, {
slots: {
tag: () => 'Custom Tag',