Skip to content

Commit d08df1b

Browse files
committed
chore: 更新文档,添加自定义图片源获取方法的说明
1 parent 3ef1842 commit d08df1b

File tree

1 file changed

+3
-21
lines changed

1 file changed

+3
-21
lines changed

docs/component/waterfall.md

Lines changed: 3 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ function handleLoadComplete() {
4242
```
4343

4444
<script setup>
45-
import { ref } from 'vue'
45+
import { ref } from 'vue'
4646
const waterfallList = ref([
4747
{
4848
id: 1,
@@ -60,25 +60,7 @@ function handleItemClick(item, index) {
6060
console.log('点击了项目:', item, index)
6161
}
6262
</script>
63-
```
6463

65-
## 自定义内容渲染
66-
67-
```vue
68-
<template>
69-
<up-waterfall
70-
:list="waterfallList"
71-
:column="2"
72-
>
73-
<template #default="{ item }">
74-
<view class="item-content">
75-
<text class="item-title">{{ item.title }}</text>
76-
<text class="item-desc">{{ item.desc }}</text>
77-
</view>
78-
</template>
79-
</up-waterfall>
80-
</template>
81-
```
8264

8365
## 自定义列数
8466

@@ -252,12 +234,12 @@ interface WaterfallItem {
252234
| resetWaterfall | 重置瀑布流 | `(list: WaterfallItem[])` |
253235
| appendNewData | 追加新数据 | `(newItems: WaterfallItem[])` |
254236

255-
## 样式变量
237+
<!-- ## 样式变量
256238
257239
组件提供了下列 CSS 变量,可用于自定义样式。
258240
259241
| 名称 | 默认值 | 描述 |
260242
|------|--------|------|
261243
| --up-waterfall-item-margin | `30rpx` | 项目间距 |
262244
| --up-waterfall-item-radius | `12rpx` | 项目圆角 |
263-
| --up-waterfall-item-shadow | `0rpx 3rpx 6rpx rgba(0, 46, 37, 0.08)` | 项目阴影 |
245+
| --up-waterfall-item-shadow | `0rpx 3rpx 6rpx rgba(0, 46, 37, 0.08)` | 项目阴影 | -->

0 commit comments

Comments
 (0)