jobdone-shared-files 1.0.20 → 1.0.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -1
- package/package.json +1 -1
- package/style/scss/Layout/LayoutBase.scss +0 -4
- package/tree.vue +2 -2
- package/treeItem.vue +3 -3
package/README.md
CHANGED
|
@@ -97,8 +97,10 @@ import OOXX from '../../node_modules/jobdone-shared-files/OOXX.vue';
|
|
|
97
97
|
<template v-slot:icon-start>
|
|
98
98
|
// 前方箭頭後的 slot 插槽
|
|
99
99
|
</template>
|
|
100
|
-
<template v-slot:icon>
|
|
100
|
+
<template v-slot:icon="slotProps">
|
|
101
101
|
// 後方的 slot 插槽,預設為 radio icon
|
|
102
|
+
// 透過 slotProps 取得每一個 item 的資料
|
|
103
|
+
{{slotProps.item}}
|
|
102
104
|
</template>
|
|
103
105
|
</tree>
|
|
104
106
|
</template>
|
package/package.json
CHANGED
package/tree.vue
CHANGED
package/treeItem.vue
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
<div class="btn-title d-flex text-start rounded-0 flex-grow-1"
|
|
9
9
|
:for="item.id" @click="clickItem(item)">
|
|
10
10
|
<div class="btn btn-text border-start">{{item.title}}</div>
|
|
11
|
-
<slot name="icon">
|
|
11
|
+
<slot name="icon" :item="item">
|
|
12
12
|
<div class="btn d-flex align-items-center border-start rounded-0 text-primary h-100 ms-auto">
|
|
13
13
|
<span class="material-icons icon-18"></span>
|
|
14
14
|
</div>
|
|
@@ -27,8 +27,8 @@
|
|
|
27
27
|
<template v-slot:icon-start>
|
|
28
28
|
<slot name="icon-start"></slot>
|
|
29
29
|
</template>
|
|
30
|
-
<template v-slot:icon>
|
|
31
|
-
<slot name="icon">
|
|
30
|
+
<template v-slot:icon="slotProps">
|
|
31
|
+
<slot name="icon" :item="slotProps.item">
|
|
32
32
|
<div class="btn d-flex align-items-center border-start rounded-0 text-primary h-100 ms-auto">
|
|
33
33
|
<span class="material-icons icon-18"></span>
|
|
34
34
|
</div>
|