@dataloop-ai/components 0.19.260 → 0.19.261
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/package.json
CHANGED
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
</dl-input>
|
|
19
19
|
<dl-tree-table
|
|
20
20
|
v-if="isFilterString(inputValue)"
|
|
21
|
+
ref="table"
|
|
21
22
|
draggable="none"
|
|
22
23
|
separator="none"
|
|
23
24
|
:hide-pagination="true"
|
|
@@ -114,7 +115,13 @@ export default defineComponent({
|
|
|
114
115
|
items.value ? items.value[0] : null
|
|
115
116
|
)
|
|
116
117
|
|
|
117
|
-
const
|
|
118
|
+
const table = ref()
|
|
119
|
+
const handleRowClick = (event: MouseEvent, item: DlLabelPickerItem) => {
|
|
120
|
+
table.value.$el
|
|
121
|
+
.querySelectorAll('tr.selected')
|
|
122
|
+
.forEach((tr: Element) => tr.classList.remove('selected'))
|
|
123
|
+
const target = event.target as Element
|
|
124
|
+
target.closest('tr').classList.add('selected')
|
|
118
125
|
currentSelectedLabel.value = item
|
|
119
126
|
emit('selected-label', item)
|
|
120
127
|
emit('click', item)
|
|
@@ -188,6 +195,7 @@ export default defineComponent({
|
|
|
188
195
|
placeHolderText,
|
|
189
196
|
inputStyles,
|
|
190
197
|
rows,
|
|
198
|
+
table,
|
|
191
199
|
isFilterString
|
|
192
200
|
}
|
|
193
201
|
}
|