@dataloop-ai/components 0.19.57 → 0.19.59

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
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dataloop-ai/components",
3
- "version": "0.19.57",
3
+ "version": "0.19.59",
4
4
  "exports": {
5
5
  ".": "./index.ts",
6
6
  "./models": "./models.ts",
@@ -262,6 +262,10 @@ export default defineComponent({
262
262
  )
263
263
  }
264
264
 
265
+ const show = () => (menuRef.value as any)?.show()
266
+
267
+ const hide = () => (menuRef.value as any)?.hide()
268
+
265
269
  return {
266
270
  menuProps,
267
271
  modelV,
@@ -280,7 +284,9 @@ export default defineComponent({
280
284
  handleBeforeHide,
281
285
  handleShow,
282
286
  handleHide,
283
- updateModelValue
287
+ updateModelValue,
288
+ hide,
289
+ show
284
290
  }
285
291
  }
286
292
  })
@@ -1291,6 +1291,7 @@ export default defineComponent({
1291
1291
  const setIsDragging = (val: boolean) => (isDragging.value = val)
1292
1292
  const getIsDragging = () => isDragging.value
1293
1293
  const getIsResizing = () => isResizing.value
1294
+ const getVisibleColumnsState = () => visibleColumnsState.value
1294
1295
 
1295
1296
  // table slots
1296
1297
  const hasSlotByName = (name: string) => !!slots[name]
@@ -1905,6 +1906,7 @@ export default defineComponent({
1905
1906
  setIsDragging,
1906
1907
  getIsResizing,
1907
1908
  getIsDragging,
1909
+ getVisibleColumnsState,
1908
1910
  getTableKey
1909
1911
  })
1910
1912
 
@@ -6,13 +6,21 @@
6
6
  <div>This is to test v-model reactivity</div>
7
7
  <dl-input
8
8
  v-model="textVal"
9
- placeholder="testestestset"
9
+ placeholder="Test reactivity"
10
+ />
11
+ <dl-input
12
+ v-model="textVal"
13
+ placeholder="Test reactivity disabled"
10
14
  disabled
11
15
  />
12
16
  <dl-input
13
17
  v-model="textVal"
14
18
  disabled
15
19
  />
20
+ <dl-input
21
+ v-model="textVal"
22
+ readonly
23
+ />
16
24
  <dl-input v-model="trimmedValue" />
17
25
  </div>
18
26
 
@@ -288,10 +296,10 @@ export default defineComponent({
288
296
  const val = ref('')
289
297
  const trimmedValue = computed<string>({
290
298
  get: () => {
291
- return val.value.trim()
299
+ return textVal.value.trim()
292
300
  },
293
301
  set: (value: string) => {
294
- val.value = value.trim()
302
+ textVal.value = value
295
303
  }
296
304
  })
297
305
 
@@ -467,6 +467,7 @@
467
467
  tableColumns.slice(0, -1).map((c) => c.name)
468
468
  "
469
469
  loading
470
+ :resizable="true"
470
471
  >
471
472
  <template #body-cell-row-actions>
472
473
  <dl-button label="ActionButton" />
@@ -17,7 +17,10 @@ export function applyResizableColumns(table: HTMLTableElement, vm: any) {
17
17
  let targetIndex: number = null
18
18
 
19
19
  watch(
20
- () => vm.proxy.getIsDragging(),
20
+ [
21
+ () => vm.proxy.getIsDragging(),
22
+ () => vm.proxy.getVisibleColumnsState()
23
+ ],
21
24
  () => {
22
25
  const vnodeEl = isVue2 ? vm.vnode.elm : vm.vnode.el
23
26
  table = vnodeEl?.querySelector('table')