@onereach/ui-components 17.1.0 → 17.1.1
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/dist/bundled/v2/components/OrDataGridV3/OrDataGrid.js +1 -1
- package/dist/bundled/v2/components/OrDataGridV3/index.js +1 -1
- package/dist/bundled/v2/components/OrSelectV3/OrSelect.js +12 -18
- package/dist/bundled/v2/components/index.js +1 -1
- package/dist/bundled/v2/index.js +1 -1
- package/dist/bundled/v3/components/OrDataGridV3/OrDataGrid.js +1 -1
- package/dist/bundled/v3/components/OrDataGridV3/index.js +1 -1
- package/dist/bundled/v3/components/OrDataGridV3/styles.js +1 -1
- package/dist/bundled/v3/components/{OrDataGridV3-054c0ff2.js → OrDataGridV3-61becb11.js} +1 -1
- package/dist/bundled/v3/components/OrSelectV3/OrSelect.js +1 -1
- package/dist/bundled/v3/components/OrSelectV3/index.js +1 -1
- package/dist/bundled/v3/components/OrSelectV3/styles.js +1 -1
- package/dist/bundled/v3/components/{OrSelectV3-bb7f767d.js → OrSelectV3-b7448701.js} +12 -17
- package/dist/bundled/v3/components/index.js +2 -2
- package/dist/bundled/v3/index.js +2 -2
- package/dist/esm/v2/{OrDataGrid-7dc6f16f.js → OrDataGrid-74589615.js} +1 -1
- package/dist/esm/v2/{OrDataGridToolbar-c414c8f2.js → OrDataGridToolbar-303a4c3d.js} +1 -1
- package/dist/esm/v2/{OrSelect-cf1f8c43.js → OrSelect-5e6734f2.js} +1 -1
- package/dist/esm/v2/{OrSelectSingleControl-ba3f3975.js → OrSelectSingleControl-450f2642.js} +12 -18
- package/dist/esm/v2/components/index.js +4 -4
- package/dist/esm/v2/components/or-data-grid-v3/index.js +4 -4
- package/dist/esm/v2/components/or-data-grid-v3/partials/index.js +3 -3
- package/dist/esm/v2/components/or-select-v3/index.js +2 -2
- package/dist/esm/v2/components/or-select-v3/partials/index.js +1 -1
- package/dist/esm/v2/components/or-select-v3/partials/or-select-single-control/OrSelectSingleControl.vue.d.ts +1 -1
- package/dist/esm/v2/components/or-select-v3/partials/or-select-single-control/index.js +1 -1
- package/dist/esm/v2/index.js +4 -4
- package/dist/esm/v3/{OrDataGrid-a91f8a87.js → OrDataGrid-f56e2527.js} +1 -1
- package/dist/esm/v3/{OrDataGridToolbar-8bebd1fd.js → OrDataGridToolbar-8fedec74.js} +1 -1
- package/dist/esm/v3/{OrSelect-27c013b2.js → OrSelect-1274c0d1.js} +1 -1
- package/dist/esm/v3/{OrSelectSingleControl-722043c2.js → OrSelectSingleControl-93cdab5b.js} +13 -18
- package/dist/esm/v3/components/index.js +4 -4
- package/dist/esm/v3/components/or-data-grid-v3/index.js +4 -4
- package/dist/esm/v3/components/or-data-grid-v3/partials/index.js +3 -3
- package/dist/esm/v3/components/or-select-v3/index.js +2 -2
- package/dist/esm/v3/components/or-select-v3/partials/index.js +1 -1
- package/dist/esm/v3/components/or-select-v3/partials/or-select-single-control/OrSelectSingleControl.vue.d.ts +1 -1
- package/dist/esm/v3/components/or-select-v3/partials/or-select-single-control/index.js +1 -1
- package/dist/esm/v3/index.js +4 -4
- package/package.json +3 -3
- package/src/components/or-select-v3/partials/or-select-single-control/OrSelectSingleControl.vue +11 -15
- /package/dist/bundled/v2/{OrDataGrid-e08ff27a.js → OrDataGrid-16e613a1.js} +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { _ as default } from '../../OrDataGrid-
|
|
1
|
+
export { _ as default } from '../../OrDataGrid-16e613a1.js';
|
|
2
2
|
import '../../normalize-component-6e8e3d80.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { D as DataGridVariant, _ as OrDataGridV3 } from '../../OrDataGrid-
|
|
1
|
+
export { D as DataGridVariant, _ as OrDataGridV3 } from '../../OrDataGrid-16e613a1.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent, ref, toRefs, computed, watch,
|
|
1
|
+
import { defineComponent, ref, toRefs, computed, watch, getCurrentInstance } from 'vue-demi';
|
|
2
2
|
import { l as useFocus } from '../../index-82dee23f.js';
|
|
3
3
|
import { useProxyModelValue } from '../../hooks/useProxyModelValue.js';
|
|
4
4
|
import { n as normalizeComponent } from '../../normalize-component-6e8e3d80.js';
|
|
@@ -494,7 +494,6 @@ var script$1 = defineComponent({
|
|
|
494
494
|
const searchControl = ref();
|
|
495
495
|
const selectionLabelRef = ref();
|
|
496
496
|
const tooltipRef = ref();
|
|
497
|
-
const isContentTruncated = ref(false);
|
|
498
497
|
// Props
|
|
499
498
|
const {
|
|
500
499
|
modelValue,
|
|
@@ -513,14 +512,6 @@ var script$1 = defineComponent({
|
|
|
513
512
|
var _a;
|
|
514
513
|
return (_a = selection.value) === null || _a === void 0 ? void 0 : _a.label;
|
|
515
514
|
});
|
|
516
|
-
/* NOTE: using watch here due to async action.
|
|
517
|
-
Computed don't work since we need not just to track the data but to analyze UI after the re-render */
|
|
518
|
-
watch(model, async () => {
|
|
519
|
-
await nextTick();
|
|
520
|
-
if (selectionLabelRef.value) {
|
|
521
|
-
isContentTruncated.value = selectionLabelRef.value.scrollWidth > selectionLabelRef.value.clientWidth;
|
|
522
|
-
}
|
|
523
|
-
});
|
|
524
515
|
watch(() => props.isOpen, () => {
|
|
525
516
|
var _a;
|
|
526
517
|
(_a = tooltipRef.value) === null || _a === void 0 ? void 0 : _a.close();
|
|
@@ -543,6 +534,11 @@ var script$1 = defineComponent({
|
|
|
543
534
|
searchControl.value.focus();
|
|
544
535
|
}
|
|
545
536
|
}
|
|
537
|
+
function checkTooltip() {
|
|
538
|
+
if (!selectionLabelRef.value) return; // to prevent fro TS error; normally ref will always be available here since the method is a mouse event callback
|
|
539
|
+
const isContentTruncated = selectionLabelRef.value.scrollWidth > selectionLabelRef.value.clientWidth;
|
|
540
|
+
if (isContentTruncated) openTooltip();
|
|
541
|
+
}
|
|
546
542
|
return {
|
|
547
543
|
root,
|
|
548
544
|
rootStyles,
|
|
@@ -553,11 +549,11 @@ var script$1 = defineComponent({
|
|
|
553
549
|
selectionLabel,
|
|
554
550
|
focus,
|
|
555
551
|
focused,
|
|
556
|
-
isContentTruncated,
|
|
557
552
|
selectionLabelRef,
|
|
558
553
|
tooltipRef,
|
|
559
554
|
openTooltip,
|
|
560
|
-
closeTooltip
|
|
555
|
+
closeTooltip,
|
|
556
|
+
checkTooltip
|
|
561
557
|
};
|
|
562
558
|
}
|
|
563
559
|
});
|
|
@@ -595,18 +591,16 @@ var __vue_render__$1 = function () {
|
|
|
595
591
|
ref: "selectionLabelRef",
|
|
596
592
|
staticClass: "truncate w-full",
|
|
597
593
|
on: {
|
|
598
|
-
"mouseenter": _vm.
|
|
599
|
-
"mouseleave":
|
|
600
|
-
_vm.tooltipRef && _vm.tooltipRef.close();
|
|
601
|
-
}
|
|
594
|
+
"mouseenter": _vm.checkTooltip,
|
|
595
|
+
"mouseleave": _vm.closeTooltip
|
|
602
596
|
}
|
|
603
|
-
}, [_vm._v("\n " + _vm._s(_vm.selectionLabel) + "\n ")]), _vm._v(" "),
|
|
597
|
+
}, [_vm._v("\n " + _vm._s(_vm.selectionLabel) + "\n ")]), _vm._v(" "), _c('OrTooltip', {
|
|
604
598
|
ref: "tooltipRef",
|
|
605
599
|
attrs: {
|
|
606
600
|
"content": _vm.selectionLabel,
|
|
607
601
|
"trigger": _vm.selectionLabelRef
|
|
608
602
|
}
|
|
609
|
-
})
|
|
603
|
+
})], 1)]]], 2);
|
|
610
604
|
};
|
|
611
605
|
var __vue_staticRenderFns__$1 = [];
|
|
612
606
|
|
|
@@ -44,7 +44,7 @@ export { default as OrConfirm } from './OrConfirm/OrConfirm.js';
|
|
|
44
44
|
export { default as OrConfirmV3 } from './OrConfirmV3/OrConfirm.js';
|
|
45
45
|
export { ConfirmType } from './OrConfirmV3/props.js';
|
|
46
46
|
export { default as OrContextMenuV3 } from './OrContextMenuV3/OrContextMenu.js';
|
|
47
|
-
export { D as DataGridVariant, _ as OrDataGridV3 } from '../OrDataGrid-
|
|
47
|
+
export { D as DataGridVariant, _ as OrDataGridV3 } from '../OrDataGrid-16e613a1.js';
|
|
48
48
|
export { default as OrDateFormatV3 } from './OrDateFormatV3/OrDateFormat.js';
|
|
49
49
|
export { default as OrDatePickerV3 } from './OrDatePickerV3/OrDatePicker.js';
|
|
50
50
|
export { default as OrDateRangePickerV3 } from './OrDateRangePickerV3/OrDateRangePicker.js';
|
package/dist/bundled/v2/index.js
CHANGED
|
@@ -18,7 +18,7 @@ export { default as OrCombinedInputV3 } from './components/OrCombinedInputV3/OrC
|
|
|
18
18
|
export { default as OrConfirm } from './components/OrConfirm/OrConfirm.js';
|
|
19
19
|
export { default as OrConfirmV3 } from './components/OrConfirmV3/OrConfirm.js';
|
|
20
20
|
export { default as OrContextMenuV3 } from './components/OrContextMenuV3/OrContextMenu.js';
|
|
21
|
-
export { D as DataGridVariant, _ as OrDataGridV3 } from './OrDataGrid-
|
|
21
|
+
export { D as DataGridVariant, _ as OrDataGridV3 } from './OrDataGrid-16e613a1.js';
|
|
22
22
|
export { default as OrDateFormatV3 } from './components/OrDateFormatV3/OrDateFormat.js';
|
|
23
23
|
export { default as OrDatePickerV3 } from './components/OrDatePickerV3/OrDatePicker.js';
|
|
24
24
|
export { default as OrDateRangePickerV3 } from './components/OrDateRangePickerV3/OrDateRangePicker.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { s as default } from '../OrDataGridV3-
|
|
1
|
+
export { s as default } from '../OrDataGridV3-61becb11.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { D as DataGridVariant, s as OrDataGridV3 } from '../OrDataGridV3-
|
|
1
|
+
export { D as DataGridVariant, s as OrDataGridV3 } from '../OrDataGridV3-61becb11.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { a as DataGrid } from '../OrDataGridV3-
|
|
1
|
+
export { a as DataGrid } from '../OrDataGridV3-61becb11.js';
|
|
@@ -5,7 +5,7 @@ import { s as script$g } from './OrDatePickerV3-b7df1103.js';
|
|
|
5
5
|
import { s as script$h } from './OrDateTimePickerV3-a996d0ed.js';
|
|
6
6
|
import { s as script$i } from './OrInputV3-335ca448.js';
|
|
7
7
|
import { s as script$j } from './OrRatingV3-e3260da7.js';
|
|
8
|
-
import { s as script$k } from './OrSelectV3-
|
|
8
|
+
import { s as script$k } from './OrSelectV3-b7448701.js';
|
|
9
9
|
import { s as script$l } from './OrSwitchV3-d504bd59.js';
|
|
10
10
|
import { s as script$m } from './OrTagInputV3-2209a961.js';
|
|
11
11
|
import { s as script$n } from './OrTimePickerV3-6dac2d43.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { s as default } from '../OrSelectV3-
|
|
1
|
+
export { s as default } from '../OrSelectV3-b7448701.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { s as OrSelectV3 } from '../OrSelectV3-
|
|
1
|
+
export { s as OrSelectV3 } from '../OrSelectV3-b7448701.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { S as Select, a as SelectControl, c as SelectDropdown, d as SelectDropdownDefault, e as SelectDropdownFlipped, f as SelectDropdownItem, h as SelectLoader, g as SelectNoSearchResults, b as SelectSearchControl } from '../OrSelectV3-
|
|
1
|
+
export { S as Select, a as SelectControl, c as SelectDropdown, d as SelectDropdownDefault, e as SelectDropdownFlipped, f as SelectDropdownItem, h as SelectLoader, g as SelectNoSearchResults, b as SelectSearchControl } from '../OrSelectV3-b7448701.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { withDirectives, openBlock, createElementBlock, normalizeStyle, normalizeClass, vModelDynamic, renderSlot, resolveComponent, createVNode, createSlots, withCtx, createTextVNode, toDisplayString, createElementVNode, vShow, createBlock, createCommentVNode, Fragment, resolveDirective, withModifiers, renderList } from 'vue';
|
|
2
|
-
import { defineComponent, ref, toRefs, computed, watch,
|
|
2
|
+
import { defineComponent, ref, toRefs, computed, watch, getCurrentInstance } from 'vue-demi';
|
|
3
3
|
import { x as useFocus } from './OrAutocompleteV3-50cc3b22.js';
|
|
4
4
|
import { useProxyModelValue } from '../hooks/useProxyModelValue.js';
|
|
5
5
|
import { s as script$5, T as TagsOverflow } from './OrTagsV3-61415f93.js';
|
|
@@ -379,7 +379,6 @@ var script$1 = defineComponent({
|
|
|
379
379
|
const searchControl = ref();
|
|
380
380
|
const selectionLabelRef = ref();
|
|
381
381
|
const tooltipRef = ref();
|
|
382
|
-
const isContentTruncated = ref(false);
|
|
383
382
|
// Props
|
|
384
383
|
const {
|
|
385
384
|
modelValue,
|
|
@@ -398,14 +397,6 @@ var script$1 = defineComponent({
|
|
|
398
397
|
var _a;
|
|
399
398
|
return (_a = selection.value) === null || _a === void 0 ? void 0 : _a.label;
|
|
400
399
|
});
|
|
401
|
-
/* NOTE: using watch here due to async action.
|
|
402
|
-
Computed don't work since we need not just to track the data but to analyze UI after the re-render */
|
|
403
|
-
watch(model, async () => {
|
|
404
|
-
await nextTick();
|
|
405
|
-
if (selectionLabelRef.value) {
|
|
406
|
-
isContentTruncated.value = selectionLabelRef.value.scrollWidth > selectionLabelRef.value.clientWidth;
|
|
407
|
-
}
|
|
408
|
-
});
|
|
409
400
|
watch(() => props.isOpen, () => {
|
|
410
401
|
var _a;
|
|
411
402
|
(_a = tooltipRef.value) === null || _a === void 0 ? void 0 : _a.close();
|
|
@@ -428,6 +419,11 @@ var script$1 = defineComponent({
|
|
|
428
419
|
searchControl.value.focus();
|
|
429
420
|
}
|
|
430
421
|
}
|
|
422
|
+
function checkTooltip() {
|
|
423
|
+
if (!selectionLabelRef.value) return; // to prevent fro TS error; normally ref will always be available here since the method is a mouse event callback
|
|
424
|
+
const isContentTruncated = selectionLabelRef.value.scrollWidth > selectionLabelRef.value.clientWidth;
|
|
425
|
+
if (isContentTruncated) openTooltip();
|
|
426
|
+
}
|
|
431
427
|
return {
|
|
432
428
|
root,
|
|
433
429
|
rootStyles,
|
|
@@ -438,11 +434,11 @@ var script$1 = defineComponent({
|
|
|
438
434
|
selectionLabel,
|
|
439
435
|
focus,
|
|
440
436
|
focused,
|
|
441
|
-
isContentTruncated,
|
|
442
437
|
selectionLabelRef,
|
|
443
438
|
tooltipRef,
|
|
444
439
|
openTooltip,
|
|
445
|
-
closeTooltip
|
|
440
|
+
closeTooltip,
|
|
441
|
+
checkTooltip
|
|
446
442
|
};
|
|
447
443
|
}
|
|
448
444
|
});
|
|
@@ -475,14 +471,13 @@ function render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
475
471
|
}, 8 /* PROPS */, ["disabled"])) : (openBlock(), createElementBlock("div", _hoisted_1$1, [createElementVNode("div", {
|
|
476
472
|
ref: "selectionLabelRef",
|
|
477
473
|
class: "truncate w-full",
|
|
478
|
-
onMouseenter: _cache[1] || (_cache[1] = (...args) => _ctx.
|
|
479
|
-
onMouseleave: _cache[2] || (_cache[2] =
|
|
480
|
-
}, toDisplayString(_ctx.selectionLabel), 545 /* TEXT, NEED_HYDRATION, NEED_PATCH */),
|
|
481
|
-
key: 0,
|
|
474
|
+
onMouseenter: _cache[1] || (_cache[1] = (...args) => _ctx.checkTooltip && _ctx.checkTooltip(...args)),
|
|
475
|
+
onMouseleave: _cache[2] || (_cache[2] = (...args) => _ctx.closeTooltip && _ctx.closeTooltip(...args))
|
|
476
|
+
}, toDisplayString(_ctx.selectionLabel), 545 /* TEXT, NEED_HYDRATION, NEED_PATCH */), createVNode(_component_OrTooltip, {
|
|
482
477
|
ref: "tooltipRef",
|
|
483
478
|
content: _ctx.selectionLabel,
|
|
484
479
|
trigger: _ctx.selectionLabelRef
|
|
485
|
-
}, null, 8 /* PROPS */, ["content", "trigger"])
|
|
480
|
+
}, null, 8 /* PROPS */, ["content", "trigger"])]))], 64 /* STABLE_FRAGMENT */))], 2 /* CLASS */);
|
|
486
481
|
}
|
|
487
482
|
|
|
488
483
|
script$1.render = render$1;
|
|
@@ -24,7 +24,7 @@ export { s as OrCombinedInputV3 } from './OrCombinedInputV3-ceff5a22.js';
|
|
|
24
24
|
export { s as OrConfirm } from './OrConfirm-004d318a.js';
|
|
25
25
|
export { C as ConfirmType, s as OrConfirmV3 } from './OrConfirmV3-7ed78857.js';
|
|
26
26
|
export { default as OrContextMenuV3 } from './OrContextMenuV3/OrContextMenu.js';
|
|
27
|
-
export { D as DataGridVariant, s as OrDataGridV3 } from './OrDataGridV3-
|
|
27
|
+
export { D as DataGridVariant, s as OrDataGridV3 } from './OrDataGridV3-61becb11.js';
|
|
28
28
|
export { s as OrDateFormatV3 } from './OrDateFormatV3-10e372f9.js';
|
|
29
29
|
export { s as OrDatePickerV3 } from './OrDatePickerV3-b7df1103.js';
|
|
30
30
|
export { s as OrDateRangePickerV3 } from './OrDateRangePickerV3-90be16a0.js';
|
|
@@ -93,7 +93,7 @@ export { default as OrSearch } from './OrSearch/OrSearch.js';
|
|
|
93
93
|
export { default as OrSearchV3 } from './OrSearchV3/OrSearch.js';
|
|
94
94
|
export { s as OrSegmentedControlV3, S as SegmentedControlSize } from './OrSegmentedControlV3-99c7f6ed.js';
|
|
95
95
|
export { s as OrSelect } from './OrSelect-eebd1857.js';
|
|
96
|
-
export { s as OrSelectV3 } from './OrSelectV3-
|
|
96
|
+
export { s as OrSelectV3 } from './OrSelectV3-b7448701.js';
|
|
97
97
|
export { OrSidebar, OrSidebarSide } from './OrSidebar/index.js';
|
|
98
98
|
export { s as OrSidebarV3, S as SidebarPlacement } from './OrSidebarV3-f0ed4bc9.js';
|
|
99
99
|
export { s as OrSkeletonCircle, a as OrSkeletonRect, b as OrSkeletonText, O as OrSkeletonTextSizes } from './OrSkeleton-21203227.js';
|
package/dist/bundled/v3/index.js
CHANGED
|
@@ -16,7 +16,7 @@ export { s as OrCombinedInputV3 } from './components/OrCombinedInputV3-ceff5a22.
|
|
|
16
16
|
export { s as OrConfirm } from './components/OrConfirm-004d318a.js';
|
|
17
17
|
export { C as ConfirmType, s as OrConfirmV3 } from './components/OrConfirmV3-7ed78857.js';
|
|
18
18
|
export { default as OrContextMenuV3 } from './components/OrContextMenuV3/OrContextMenu.js';
|
|
19
|
-
export { D as DataGridVariant, s as OrDataGridV3 } from './components/OrDataGridV3-
|
|
19
|
+
export { D as DataGridVariant, s as OrDataGridV3 } from './components/OrDataGridV3-61becb11.js';
|
|
20
20
|
export { s as OrDateFormatV3 } from './components/OrDateFormatV3-10e372f9.js';
|
|
21
21
|
export { s as OrDateRangePickerV3 } from './components/OrDateRangePickerV3-90be16a0.js';
|
|
22
22
|
export { s as OrDateTimeFormatV3 } from './components/OrDateTimeFormatV3-295547f5.js';
|
|
@@ -116,7 +116,7 @@ export { s as OrRatingV3, R as RatingVariant } from './components/OrRatingV3-e32
|
|
|
116
116
|
export { s as OrResizeablePanelV3, R as ResizeablePanelPadding, a as ResizeablePanelPlacement } from './components/OrResizeablePanelV3-c512dde5.js';
|
|
117
117
|
export { default as OrSearch } from './components/OrSearch/OrSearch.js';
|
|
118
118
|
export { default as OrSearchV3 } from './components/OrSearchV3/OrSearch.js';
|
|
119
|
-
export { s as OrSelectV3 } from './components/OrSelectV3-
|
|
119
|
+
export { s as OrSelectV3 } from './components/OrSelectV3-b7448701.js';
|
|
120
120
|
export { s as OrSortingV3 } from './components/OrSortingV3-c7afa99b.js';
|
|
121
121
|
export { s as OrSwitchV3 } from './components/OrSwitchV3-d504bd59.js';
|
|
122
122
|
export { default as OrTabHeaderItem } from './components/OrTabHeaderItem/OrTabHeaderItem.js';
|
|
@@ -5,7 +5,7 @@ import { _ as __vue_component__$h } from './OrSearch-3731baa5.js';
|
|
|
5
5
|
import './OrSkeletonCircle.vue_rollup-plugin-vue_script-f572f02f.js';
|
|
6
6
|
import './OrSkeletonRect.vue_rollup-plugin-vue_script-d2b78065.js';
|
|
7
7
|
import { _ as __vue_component__$i } from './OrSkeletonText-b6e51e70.js';
|
|
8
|
-
import { _ as __vue_component__$2, a as __vue_component__$3, b as __vue_component__$4, c as __vue_component__$5, d as __vue_component__$6, e as __vue_component__$7, f as __vue_component__$8, g as __vue_component__$9, h as __vue_component__$a, i as __vue_component__$b, j as __vue_component__$c, k as __vue_component__$d, l as __vue_component__$e, m as __vue_component__$f, D as DataGridVariant } from './OrDataGridToolbar-
|
|
8
|
+
import { _ as __vue_component__$2, a as __vue_component__$3, b as __vue_component__$4, c as __vue_component__$5, d as __vue_component__$6, e as __vue_component__$7, f as __vue_component__$8, g as __vue_component__$9, h as __vue_component__$a, i as __vue_component__$b, j as __vue_component__$c, k as __vue_component__$d, l as __vue_component__$e, m as __vue_component__$f, D as DataGridVariant } from './OrDataGridToolbar-303a4c3d.js';
|
|
9
9
|
import { n as normalizeComponent } from './normalize-component-6e8e3d80.js';
|
|
10
10
|
|
|
11
11
|
const DataGrid = [
|
|
@@ -12,7 +12,7 @@ import { _ as __vue_component__$g } from './OrDateTimePicker-4fba136b.js';
|
|
|
12
12
|
import './OrDateTimePickerTimeSelect-0ecb4686.js';
|
|
13
13
|
import { _ as __vue_component__$h } from './OrInput-52c9e48e.js';
|
|
14
14
|
import { _ as __vue_component__$i } from './OrRating-7c968949.js';
|
|
15
|
-
import { _ as __vue_component__$j } from './OrSelect-
|
|
15
|
+
import { _ as __vue_component__$j } from './OrSelect-5e6734f2.js';
|
|
16
16
|
import { _ as __vue_component__$k } from './OrSwitch-783547da.js';
|
|
17
17
|
import { _ as __vue_component__$l } from './OrTagInput-2dd90e11.js';
|
|
18
18
|
import { _ as __vue_component__$m } from './OrTimePicker-db4774fb.js';
|
|
@@ -25,7 +25,7 @@ import { _ as __vue_component__$b } from './OrPopover-45e2dbce.js';
|
|
|
25
25
|
import { T as TagsOverflow } from './OrTags-4b35fccf.js';
|
|
26
26
|
import { _ as __vue_component__$e } from './OrLoader-25e123a1.js';
|
|
27
27
|
import { _ as __vue_component__$c } from './OrSelectMultipleControl-aa5891fd.js';
|
|
28
|
-
import { _ as __vue_component__$d } from './OrSelectSingleControl-
|
|
28
|
+
import { _ as __vue_component__$d } from './OrSelectSingleControl-450f2642.js';
|
|
29
29
|
import './OrSelectPlaceholder-a6caa9e0.js';
|
|
30
30
|
import { n as normalizeComponent } from './normalize-component-6e8e3d80.js';
|
|
31
31
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent, ref, toRefs, computed, watch
|
|
1
|
+
import { defineComponent, ref, toRefs, computed, watch } from 'vue-demi';
|
|
2
2
|
import './TimeFormat-a7f5565b.js';
|
|
3
3
|
import './dom-53c9635b.js';
|
|
4
4
|
import { i as isEmpty } from './isString-cf957a95.js';
|
|
@@ -65,7 +65,6 @@ var script = defineComponent({
|
|
|
65
65
|
const searchControl = ref();
|
|
66
66
|
const selectionLabelRef = ref();
|
|
67
67
|
const tooltipRef = ref();
|
|
68
|
-
const isContentTruncated = ref(false);
|
|
69
68
|
// Props
|
|
70
69
|
const {
|
|
71
70
|
modelValue,
|
|
@@ -84,14 +83,6 @@ var script = defineComponent({
|
|
|
84
83
|
var _a;
|
|
85
84
|
return (_a = selection.value) === null || _a === void 0 ? void 0 : _a.label;
|
|
86
85
|
});
|
|
87
|
-
/* NOTE: using watch here due to async action.
|
|
88
|
-
Computed don't work since we need not just to track the data but to analyze UI after the re-render */
|
|
89
|
-
watch(model, async () => {
|
|
90
|
-
await nextTick();
|
|
91
|
-
if (selectionLabelRef.value) {
|
|
92
|
-
isContentTruncated.value = selectionLabelRef.value.scrollWidth > selectionLabelRef.value.clientWidth;
|
|
93
|
-
}
|
|
94
|
-
});
|
|
95
86
|
watch(() => props.isOpen, () => {
|
|
96
87
|
var _a;
|
|
97
88
|
(_a = tooltipRef.value) === null || _a === void 0 ? void 0 : _a.close();
|
|
@@ -114,6 +105,11 @@ var script = defineComponent({
|
|
|
114
105
|
searchControl.value.focus();
|
|
115
106
|
}
|
|
116
107
|
}
|
|
108
|
+
function checkTooltip() {
|
|
109
|
+
if (!selectionLabelRef.value) return; // to prevent fro TS error; normally ref will always be available here since the method is a mouse event callback
|
|
110
|
+
const isContentTruncated = selectionLabelRef.value.scrollWidth > selectionLabelRef.value.clientWidth;
|
|
111
|
+
if (isContentTruncated) openTooltip();
|
|
112
|
+
}
|
|
117
113
|
return {
|
|
118
114
|
root,
|
|
119
115
|
rootStyles,
|
|
@@ -124,11 +120,11 @@ var script = defineComponent({
|
|
|
124
120
|
selectionLabel,
|
|
125
121
|
focus,
|
|
126
122
|
focused,
|
|
127
|
-
isContentTruncated,
|
|
128
123
|
selectionLabelRef,
|
|
129
124
|
tooltipRef,
|
|
130
125
|
openTooltip,
|
|
131
|
-
closeTooltip
|
|
126
|
+
closeTooltip,
|
|
127
|
+
checkTooltip
|
|
132
128
|
};
|
|
133
129
|
}
|
|
134
130
|
});
|
|
@@ -166,18 +162,16 @@ var __vue_render__ = function () {
|
|
|
166
162
|
ref: "selectionLabelRef",
|
|
167
163
|
staticClass: "truncate w-full",
|
|
168
164
|
on: {
|
|
169
|
-
"mouseenter": _vm.
|
|
170
|
-
"mouseleave":
|
|
171
|
-
_vm.tooltipRef && _vm.tooltipRef.close();
|
|
172
|
-
}
|
|
165
|
+
"mouseenter": _vm.checkTooltip,
|
|
166
|
+
"mouseleave": _vm.closeTooltip
|
|
173
167
|
}
|
|
174
|
-
}, [_vm._v("\n " + _vm._s(_vm.selectionLabel) + "\n ")]), _vm._v(" "),
|
|
168
|
+
}, [_vm._v("\n " + _vm._s(_vm.selectionLabel) + "\n ")]), _vm._v(" "), _c('OrTooltip', {
|
|
175
169
|
ref: "tooltipRef",
|
|
176
170
|
attrs: {
|
|
177
171
|
"content": _vm.selectionLabel,
|
|
178
172
|
"trigger": _vm.selectionLabelRef
|
|
179
173
|
}
|
|
180
|
-
})
|
|
174
|
+
})], 1)]]], 2);
|
|
181
175
|
};
|
|
182
176
|
var __vue_staticRenderFns__ = [];
|
|
183
177
|
|
|
@@ -34,8 +34,8 @@ export { _ as OrCombinedInputV3 } from '../OrCombinedInput-da2fc9f0.js';
|
|
|
34
34
|
export { _ as OrConfirm } from '../OrConfirm-8f6d47e1.js';
|
|
35
35
|
export { C as ConfirmType, _ as OrConfirmV3 } from '../OrConfirm-e5d286c5.js';
|
|
36
36
|
export { _ as OrContextMenuV3 } from '../OrContextMenu-a6fee3eb.js';
|
|
37
|
-
export { _ as OrDataGridV3 } from '../OrDataGrid-
|
|
38
|
-
export { D as DataGridVariant } from '../OrDataGridToolbar-
|
|
37
|
+
export { _ as OrDataGridV3 } from '../OrDataGrid-74589615.js';
|
|
38
|
+
export { D as DataGridVariant } from '../OrDataGridToolbar-303a4c3d.js';
|
|
39
39
|
export { _ as OrDateFormatV3 } from '../OrDateFormat-d5b6fe55.js';
|
|
40
40
|
export { _ as OrDatePickerV3 } from '../OrDatePicker-c923babb.js';
|
|
41
41
|
export { _ as OrDateRangePickerV3 } from '../OrDateRangePicker-bc3c6062.js';
|
|
@@ -112,7 +112,7 @@ export { _ as OrSearch } from '../OrSearch-9c4cd6ca.js';
|
|
|
112
112
|
export { _ as OrSearchV3 } from '../OrSearch-3731baa5.js';
|
|
113
113
|
export { _ as OrSegmentedControlV3, S as SegmentedControlSize } from '../OrSegmentedControl-047e2414.js';
|
|
114
114
|
export { _ as OrSelect } from '../OrSelect-1df35160.js';
|
|
115
|
-
export { _ as OrSelectV3 } from '../OrSelect-
|
|
115
|
+
export { _ as OrSelectV3 } from '../OrSelect-5e6734f2.js';
|
|
116
116
|
export { _ as OrSidebar, O as OrSidebarSide } from '../OrSidebar-054b26c6.js';
|
|
117
117
|
export { _ as OrSidebarV3, S as SidebarPlacement } from '../props-dc3db737.js';
|
|
118
118
|
export { _ as OrSkeletonCircle } from '../OrSkeletonCircle-c4bf0e34.js';
|
|
@@ -243,7 +243,7 @@ import '../OrSelectMultipleControl-aa5891fd.js';
|
|
|
243
243
|
import '../isEqual-15f4b2f5.js';
|
|
244
244
|
import '../OrSelectControlInput-31d24ab9.js';
|
|
245
245
|
import '../OrSelectPlaceholder-a6caa9e0.js';
|
|
246
|
-
import '../OrSelectSingleControl-
|
|
246
|
+
import '../OrSelectSingleControl-450f2642.js';
|
|
247
247
|
import 'lodash/range';
|
|
248
248
|
import '../useOverflow-5a08887e.js';
|
|
249
249
|
import 'portal-vue/dist/portal-vue.esm.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { _ as OrDataGridV3 } from '../../OrDataGrid-
|
|
2
|
-
export { D as DataGridVariant } from '../../OrDataGridToolbar-
|
|
1
|
+
export { _ as OrDataGridV3 } from '../../OrDataGrid-74589615.js';
|
|
2
|
+
export { D as DataGridVariant } from '../../OrDataGridToolbar-303a4c3d.js';
|
|
3
3
|
import 'vue-demi';
|
|
4
4
|
import '../../OrCheckbox-f2dc364e.js';
|
|
5
5
|
import '../../useIdAttribute-3a339b79.js';
|
|
@@ -63,7 +63,7 @@ import '../../formatTime-3f37a00f.js';
|
|
|
63
63
|
import '../../getCurrentDate-e5a478c3.js';
|
|
64
64
|
import '../../OrDateTimePicker-4fba136b.js';
|
|
65
65
|
import '../../OrRating-7c968949.js';
|
|
66
|
-
import '../../OrSelect-
|
|
66
|
+
import '../../OrSelect-5e6734f2.js';
|
|
67
67
|
import '../../isString-cf957a95.js';
|
|
68
68
|
import '../../isNull-7ae26d1d.js';
|
|
69
69
|
import '../../isObject-4d5300e9.js';
|
|
@@ -77,7 +77,7 @@ import '../../OrSelectMultipleControl-aa5891fd.js';
|
|
|
77
77
|
import '../../isEqual-15f4b2f5.js';
|
|
78
78
|
import '../../OrSelectControlInput-31d24ab9.js';
|
|
79
79
|
import '../../OrSelectPlaceholder-a6caa9e0.js';
|
|
80
|
-
import '../../OrSelectSingleControl-
|
|
80
|
+
import '../../OrSelectSingleControl-450f2642.js';
|
|
81
81
|
import '../../OrSwitch-783547da.js';
|
|
82
82
|
import '../../OrTagInput-2dd90e11.js';
|
|
83
83
|
import '../../OrTimePicker-db4774fb.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { _ as OrDataGridFooter, a as OrDataGridHeader, b as OrDataGridTable, c as OrDataGridTableContent, d as OrDataGridTableContentCell, e as OrDataGridTableContentRow, f as OrDataGridTableFooter, g as OrDataGridTableFooterCell, h as OrDataGridTableFooterRow, i as OrDataGridTableHeader, j as OrDataGridTableHeaderCell, k as OrDataGridTableHeaderRow, l as OrDataGridTablePlaceholder, m as OrDataGridToolbar } from '../../../OrDataGridToolbar-
|
|
1
|
+
export { _ as OrDataGridFooter, a as OrDataGridHeader, b as OrDataGridTable, c as OrDataGridTableContent, d as OrDataGridTableContentCell, e as OrDataGridTableContentRow, f as OrDataGridTableFooter, g as OrDataGridTableFooterCell, h as OrDataGridTableFooterRow, i as OrDataGridTableHeader, j as OrDataGridTableHeaderCell, k as OrDataGridTableHeaderRow, l as OrDataGridTablePlaceholder, m as OrDataGridToolbar } from '../../../OrDataGridToolbar-303a4c3d.js';
|
|
2
2
|
import 'vue-demi';
|
|
3
3
|
import '../../../normalize-component-6e8e3d80.js';
|
|
4
4
|
import '../../../TimeFormat-a7f5565b.js';
|
|
@@ -54,7 +54,7 @@ import '../../../OrDateTimePicker-4fba136b.js';
|
|
|
54
54
|
import '../../../OrInput-52c9e48e.js';
|
|
55
55
|
import '../../../useValidationAttributes-257954f3.js';
|
|
56
56
|
import '../../../OrRating-7c968949.js';
|
|
57
|
-
import '../../../OrSelect-
|
|
57
|
+
import '../../../OrSelect-5e6734f2.js';
|
|
58
58
|
import '../../../isString-cf957a95.js';
|
|
59
59
|
import '../../../isNull-7ae26d1d.js';
|
|
60
60
|
import '../../../isObject-4d5300e9.js';
|
|
@@ -68,7 +68,7 @@ import '../../../OrSelectMultipleControl-aa5891fd.js';
|
|
|
68
68
|
import '../../../isEqual-15f4b2f5.js';
|
|
69
69
|
import '../../../OrSelectControlInput-31d24ab9.js';
|
|
70
70
|
import '../../../OrSelectPlaceholder-a6caa9e0.js';
|
|
71
|
-
import '../../../OrSelectSingleControl-
|
|
71
|
+
import '../../../OrSelectSingleControl-450f2642.js';
|
|
72
72
|
import '../../../OrSwitch-783547da.js';
|
|
73
73
|
import '../../../OrTagInput-2dd90e11.js';
|
|
74
74
|
import '../../../OrTimePicker-db4774fb.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { _ as OrSelectV3 } from '../../OrSelect-
|
|
1
|
+
export { _ as OrSelectV3 } from '../../OrSelect-5e6734f2.js';
|
|
2
2
|
import 'vue-demi';
|
|
3
3
|
import '../../dropdown-open-06d651cf.js';
|
|
4
4
|
import '../../include-2a81e823.js';
|
|
@@ -56,4 +56,4 @@ import '../../OrSelectMultipleControl-aa5891fd.js';
|
|
|
56
56
|
import '../../isEqual-15f4b2f5.js';
|
|
57
57
|
import '../../OrSelectControlInput-31d24ab9.js';
|
|
58
58
|
import '../../OrSelectPlaceholder-a6caa9e0.js';
|
|
59
|
-
import '../../OrSelectSingleControl-
|
|
59
|
+
import '../../OrSelectSingleControl-450f2642.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { _ as OrSelectMultipleControl } from '../../../OrSelectMultipleControl-aa5891fd.js';
|
|
2
|
-
export { _ as OrSelectSingleControl } from '../../../OrSelectSingleControl-
|
|
2
|
+
export { _ as OrSelectSingleControl } from '../../../OrSelectSingleControl-450f2642.js';
|
|
3
3
|
export { _ as OrSelectPlaceholder } from '../../../OrSelectPlaceholder-a6caa9e0.js';
|
|
4
4
|
import 'vue-demi';
|
|
5
5
|
import '../../../TimeFormat-a7f5565b.js';
|
|
@@ -39,11 +39,11 @@ declare const _default: import("vue-demi").DefineComponent<{
|
|
|
39
39
|
selectionLabel: import("vue-demi").ComputedRef<string | undefined>;
|
|
40
40
|
focus: () => void;
|
|
41
41
|
focused: import("vue-demi").ComputedRef<any>;
|
|
42
|
-
isContentTruncated: import("vue-demi").Ref<boolean>;
|
|
43
42
|
selectionLabelRef: import("vue-demi").Ref<HTMLDialogElement | undefined>;
|
|
44
43
|
tooltipRef: import("vue-demi").Ref<any>;
|
|
45
44
|
openTooltip: () => void;
|
|
46
45
|
closeTooltip: () => void;
|
|
46
|
+
checkTooltip: () => void;
|
|
47
47
|
}, unknown, {}, {}, import("vue-demi").ComponentOptionsMixin, import("vue-demi").ComponentOptionsMixin, "update:modelValue"[], "update:modelValue", import("vue-demi").VNodeProps & import("vue-demi").AllowedComponentProps & import("vue-demi").ComponentCustomProps, Readonly<import("vue-demi").ExtractPropTypes<{
|
|
48
48
|
modelValue: {
|
|
49
49
|
type: StringConstructor;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { _ as OrSelectSingleControl } from '../../../../OrSelectSingleControl-
|
|
1
|
+
export { _ as OrSelectSingleControl } from '../../../../OrSelectSingleControl-450f2642.js';
|
|
2
2
|
import 'vue-demi';
|
|
3
3
|
import '../../../../TimeFormat-a7f5565b.js';
|
|
4
4
|
import '../../../../dom-53c9635b.js';
|
package/dist/esm/v2/index.js
CHANGED
|
@@ -34,8 +34,8 @@ export { _ as OrCombinedInputV3 } from './OrCombinedInput-da2fc9f0.js';
|
|
|
34
34
|
export { _ as OrConfirm } from './OrConfirm-8f6d47e1.js';
|
|
35
35
|
export { C as ConfirmType, _ as OrConfirmV3 } from './OrConfirm-e5d286c5.js';
|
|
36
36
|
export { _ as OrContextMenuV3 } from './OrContextMenu-a6fee3eb.js';
|
|
37
|
-
export { _ as OrDataGridV3 } from './OrDataGrid-
|
|
38
|
-
export { D as DataGridVariant } from './OrDataGridToolbar-
|
|
37
|
+
export { _ as OrDataGridV3 } from './OrDataGrid-74589615.js';
|
|
38
|
+
export { D as DataGridVariant } from './OrDataGridToolbar-303a4c3d.js';
|
|
39
39
|
export { _ as OrDateFormatV3 } from './OrDateFormat-d5b6fe55.js';
|
|
40
40
|
export { _ as OrDatePickerV3 } from './OrDatePicker-c923babb.js';
|
|
41
41
|
export { _ as OrDateRangePickerV3 } from './OrDateRangePicker-bc3c6062.js';
|
|
@@ -112,7 +112,7 @@ export { _ as OrSearch } from './OrSearch-9c4cd6ca.js';
|
|
|
112
112
|
export { _ as OrSearchV3 } from './OrSearch-3731baa5.js';
|
|
113
113
|
export { _ as OrSegmentedControlV3, S as SegmentedControlSize } from './OrSegmentedControl-047e2414.js';
|
|
114
114
|
export { _ as OrSelect } from './OrSelect-1df35160.js';
|
|
115
|
-
export { _ as OrSelectV3 } from './OrSelect-
|
|
115
|
+
export { _ as OrSelectV3 } from './OrSelect-5e6734f2.js';
|
|
116
116
|
export { _ as OrSidebar, O as OrSidebarSide } from './OrSidebar-054b26c6.js';
|
|
117
117
|
export { _ as OrSidebarV3, S as SidebarPlacement } from './props-dc3db737.js';
|
|
118
118
|
export { _ as OrSkeletonCircle } from './OrSkeletonCircle-c4bf0e34.js';
|
|
@@ -245,7 +245,7 @@ import 'lodash/keyBy';
|
|
|
245
245
|
import './OrSelectMultipleControl-aa5891fd.js';
|
|
246
246
|
import './OrSelectControlInput-31d24ab9.js';
|
|
247
247
|
import './OrSelectPlaceholder-a6caa9e0.js';
|
|
248
|
-
import './OrSelectSingleControl-
|
|
248
|
+
import './OrSelectSingleControl-450f2642.js';
|
|
249
249
|
import 'lodash/range';
|
|
250
250
|
import 'portal-vue/dist/portal-vue.esm.js';
|
|
251
251
|
import 'portal-vue';
|
|
@@ -5,7 +5,7 @@ import { s as script$h } from './OrSearch-7d90b23b.js';
|
|
|
5
5
|
import './OrSkeletonCircle-a3eb5f53.js';
|
|
6
6
|
import './OrSkeletonRect-d0b8b2cf.js';
|
|
7
7
|
import { s as script$i } from './OrSkeletonText-5e9579c1.js';
|
|
8
|
-
import { s as script$2, a as script$3, b as script$4, c as script$5, d as script$6, e as script$7, f as script$8, g as script$9, h as script$a, i as script$b, j as script$c, k as script$d, l as script$e, m as script$f, D as DataGridVariant } from './OrDataGridToolbar-
|
|
8
|
+
import { s as script$2, a as script$3, b as script$4, c as script$5, d as script$6, e as script$7, f as script$8, g as script$9, h as script$a, i as script$b, j as script$c, k as script$d, l as script$e, m as script$f, D as DataGridVariant } from './OrDataGridToolbar-8fedec74.js';
|
|
9
9
|
import { resolveComponent, openBlock, createElementBlock, normalizeClass, createBlock, createSlots, withCtx, renderSlot, createVNode, createCommentVNode, normalizeStyle, Fragment, renderList, createTextVNode, toDisplayString } from 'vue';
|
|
10
10
|
|
|
11
11
|
const DataGrid = [
|
|
@@ -12,7 +12,7 @@ import { s as script$g } from './OrDateTimePicker-ef43a321.js';
|
|
|
12
12
|
import './OrDateTimePickerTimeSelect-8ecd5e17.js';
|
|
13
13
|
import { s as script$h } from './OrInput-684d592e.js';
|
|
14
14
|
import { s as script$i } from './OrRating-7c2f8e4d.js';
|
|
15
|
-
import { s as script$j } from './OrSelect-
|
|
15
|
+
import { s as script$j } from './OrSelect-1274c0d1.js';
|
|
16
16
|
import { s as script$k } from './OrSwitch-0fb0d361.js';
|
|
17
17
|
import { s as script$l } from './OrTagInput-fb3e1714.js';
|
|
18
18
|
import { s as script$m } from './OrTimePicker-e042d71a.js';
|
|
@@ -24,7 +24,7 @@ import { s as script$b } from './OrPopover-0daeba14.js';
|
|
|
24
24
|
import { T as TagsOverflow } from './OrTags-660ca32e.js';
|
|
25
25
|
import { s as script$e } from './OrLoader-472e965e.js';
|
|
26
26
|
import { s as script$c } from './OrSelectMultipleControl-a22cec0a.js';
|
|
27
|
-
import { s as script$d } from './OrSelectSingleControl-
|
|
27
|
+
import { s as script$d } from './OrSelectSingleControl-93cdab5b.js';
|
|
28
28
|
import './OrSelectPlaceholder-81502228.js';
|
|
29
29
|
import { resolveComponent, resolveDirective, openBlock, createElementBlock, normalizeClass, createBlock, withCtx, renderSlot, createTextVNode, toDisplayString, createCommentVNode, withDirectives, createElementVNode, withModifiers, createVNode, vShow, Fragment, renderList } from 'vue';
|
|
30
30
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent, ref, toRefs, computed, watch
|
|
1
|
+
import { defineComponent, ref, toRefs, computed, watch } from 'vue-demi';
|
|
2
2
|
import './TimeFormat-a7f5565b.js';
|
|
3
3
|
import './dom-53c9635b.js';
|
|
4
4
|
import { i as isEmpty } from './isString-cf957a95.js';
|
|
@@ -10,7 +10,7 @@ import '@onereach/styles/tailwind.config.json';
|
|
|
10
10
|
import { s as script$2 } from './OrSelectControlInput-e0116b29.js';
|
|
11
11
|
import { s as script$1 } from './OrSelectPlaceholder-81502228.js';
|
|
12
12
|
import { s as script$3 } from './OrTooltip-77d97056.js';
|
|
13
|
-
import { resolveComponent, openBlock, createElementBlock, normalizeClass, createBlock, Fragment, withCtx, createTextVNode, toDisplayString, createElementVNode,
|
|
13
|
+
import { resolveComponent, openBlock, createElementBlock, normalizeClass, createBlock, Fragment, withCtx, createTextVNode, toDisplayString, createElementVNode, createVNode } from 'vue';
|
|
14
14
|
|
|
15
15
|
const SelectSingleControlInput = [
|
|
16
16
|
// Layout
|
|
@@ -65,7 +65,6 @@ var script = defineComponent({
|
|
|
65
65
|
const searchControl = ref();
|
|
66
66
|
const selectionLabelRef = ref();
|
|
67
67
|
const tooltipRef = ref();
|
|
68
|
-
const isContentTruncated = ref(false);
|
|
69
68
|
// Props
|
|
70
69
|
const {
|
|
71
70
|
modelValue,
|
|
@@ -84,14 +83,6 @@ var script = defineComponent({
|
|
|
84
83
|
var _a;
|
|
85
84
|
return (_a = selection.value) === null || _a === void 0 ? void 0 : _a.label;
|
|
86
85
|
});
|
|
87
|
-
/* NOTE: using watch here due to async action.
|
|
88
|
-
Computed don't work since we need not just to track the data but to analyze UI after the re-render */
|
|
89
|
-
watch(model, async () => {
|
|
90
|
-
await nextTick();
|
|
91
|
-
if (selectionLabelRef.value) {
|
|
92
|
-
isContentTruncated.value = selectionLabelRef.value.scrollWidth > selectionLabelRef.value.clientWidth;
|
|
93
|
-
}
|
|
94
|
-
});
|
|
95
86
|
watch(() => props.isOpen, () => {
|
|
96
87
|
var _a;
|
|
97
88
|
(_a = tooltipRef.value) === null || _a === void 0 ? void 0 : _a.close();
|
|
@@ -114,6 +105,11 @@ var script = defineComponent({
|
|
|
114
105
|
searchControl.value.focus();
|
|
115
106
|
}
|
|
116
107
|
}
|
|
108
|
+
function checkTooltip() {
|
|
109
|
+
if (!selectionLabelRef.value) return; // to prevent fro TS error; normally ref will always be available here since the method is a mouse event callback
|
|
110
|
+
const isContentTruncated = selectionLabelRef.value.scrollWidth > selectionLabelRef.value.clientWidth;
|
|
111
|
+
if (isContentTruncated) openTooltip();
|
|
112
|
+
}
|
|
117
113
|
return {
|
|
118
114
|
root,
|
|
119
115
|
rootStyles,
|
|
@@ -124,11 +120,11 @@ var script = defineComponent({
|
|
|
124
120
|
selectionLabel,
|
|
125
121
|
focus,
|
|
126
122
|
focused,
|
|
127
|
-
isContentTruncated,
|
|
128
123
|
selectionLabelRef,
|
|
129
124
|
tooltipRef,
|
|
130
125
|
openTooltip,
|
|
131
|
-
closeTooltip
|
|
126
|
+
closeTooltip,
|
|
127
|
+
checkTooltip
|
|
132
128
|
};
|
|
133
129
|
}
|
|
134
130
|
});
|
|
@@ -161,14 +157,13 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
161
157
|
}, 8 /* PROPS */, ["disabled"])) : (openBlock(), createElementBlock("div", _hoisted_1, [createElementVNode("div", {
|
|
162
158
|
ref: "selectionLabelRef",
|
|
163
159
|
class: "truncate w-full",
|
|
164
|
-
onMouseenter: _cache[1] || (_cache[1] = (...args) => _ctx.
|
|
165
|
-
onMouseleave: _cache[2] || (_cache[2] =
|
|
166
|
-
}, toDisplayString(_ctx.selectionLabel), 545 /* TEXT, NEED_HYDRATION, NEED_PATCH */),
|
|
167
|
-
key: 0,
|
|
160
|
+
onMouseenter: _cache[1] || (_cache[1] = (...args) => _ctx.checkTooltip && _ctx.checkTooltip(...args)),
|
|
161
|
+
onMouseleave: _cache[2] || (_cache[2] = (...args) => _ctx.closeTooltip && _ctx.closeTooltip(...args))
|
|
162
|
+
}, toDisplayString(_ctx.selectionLabel), 545 /* TEXT, NEED_HYDRATION, NEED_PATCH */), createVNode(_component_OrTooltip, {
|
|
168
163
|
ref: "tooltipRef",
|
|
169
164
|
content: _ctx.selectionLabel,
|
|
170
165
|
trigger: _ctx.selectionLabelRef
|
|
171
|
-
}, null, 8 /* PROPS */, ["content", "trigger"])
|
|
166
|
+
}, null, 8 /* PROPS */, ["content", "trigger"])]))], 64 /* STABLE_FRAGMENT */))], 2 /* CLASS */);
|
|
172
167
|
}
|
|
173
168
|
|
|
174
169
|
script.render = render;
|
|
@@ -32,8 +32,8 @@ export { s as OrCombinedInputV3 } from '../OrCombinedInput-75b556fa.js';
|
|
|
32
32
|
export { s as OrConfirm } from '../OrConfirm-05a78778.js';
|
|
33
33
|
export { C as ConfirmType, s as OrConfirmV3 } from '../OrConfirm-f47d7230.js';
|
|
34
34
|
export { s as OrContextMenuV3 } from '../OrContextMenu-d8c71891.js';
|
|
35
|
-
export { s as OrDataGridV3 } from '../OrDataGrid-
|
|
36
|
-
export { D as DataGridVariant } from '../OrDataGridToolbar-
|
|
35
|
+
export { s as OrDataGridV3 } from '../OrDataGrid-f56e2527.js';
|
|
36
|
+
export { D as DataGridVariant } from '../OrDataGridToolbar-8fedec74.js';
|
|
37
37
|
export { s as OrDateFormatV3 } from '../OrDateFormat-5a4af897.js';
|
|
38
38
|
export { s as OrDatePickerV3 } from '../OrDatePicker-f0457c2a.js';
|
|
39
39
|
export { s as OrDateRangePickerV3 } from '../OrDateRangePicker-fbf1430a.js';
|
|
@@ -109,7 +109,7 @@ export { s as OrSearch } from '../OrSearch-4192737e.js';
|
|
|
109
109
|
export { s as OrSearchV3 } from '../OrSearch-7d90b23b.js';
|
|
110
110
|
export { s as OrSegmentedControlV3, S as SegmentedControlSize } from '../OrSegmentedControl-5dd163fb.js';
|
|
111
111
|
export { s as OrSelect } from '../OrSelect-2c033afb.js';
|
|
112
|
-
export { s as OrSelectV3 } from '../OrSelect-
|
|
112
|
+
export { s as OrSelectV3 } from '../OrSelect-1274c0d1.js';
|
|
113
113
|
export { s as OrSidebar, O as OrSidebarSide } from '../OrSidebar-4ab42b93.js';
|
|
114
114
|
export { s as OrSidebarV3, S as SidebarPlacement } from '../props-413bed7b.js';
|
|
115
115
|
export { s as OrSkeletonCircle } from '../OrSkeletonCircle-66e175a0.js';
|
|
@@ -231,7 +231,7 @@ import '../OrSelectMultipleControl-a22cec0a.js';
|
|
|
231
231
|
import '../isEqual-15f4b2f5.js';
|
|
232
232
|
import '../OrSelectControlInput-e0116b29.js';
|
|
233
233
|
import '../OrSelectPlaceholder-81502228.js';
|
|
234
|
-
import '../OrSelectSingleControl-
|
|
234
|
+
import '../OrSelectSingleControl-93cdab5b.js';
|
|
235
235
|
import 'lodash/range';
|
|
236
236
|
import '../styles-ed564e39.js';
|
|
237
237
|
import '../useOverflow-5a08887e.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { s as OrDataGridV3 } from '../../OrDataGrid-
|
|
2
|
-
export { D as DataGridVariant } from '../../OrDataGridToolbar-
|
|
1
|
+
export { s as OrDataGridV3 } from '../../OrDataGrid-f56e2527.js';
|
|
2
|
+
export { D as DataGridVariant } from '../../OrDataGridToolbar-8fedec74.js';
|
|
3
3
|
import 'vue-demi';
|
|
4
4
|
import '../../OrCheckbox-e353ee89.js';
|
|
5
5
|
import '../../useIdAttribute-3a339b79.js';
|
|
@@ -59,7 +59,7 @@ import '../../useTimeMask-a1c090c1.js';
|
|
|
59
59
|
import '../../formatTime-3f37a00f.js';
|
|
60
60
|
import '../../getCurrentDate-e5a478c3.js';
|
|
61
61
|
import '../../OrRating-7c2f8e4d.js';
|
|
62
|
-
import '../../OrSelect-
|
|
62
|
+
import '../../OrSelect-1274c0d1.js';
|
|
63
63
|
import '../../isString-cf957a95.js';
|
|
64
64
|
import '../../isNull-7ae26d1d.js';
|
|
65
65
|
import '../../isObject-4d5300e9.js';
|
|
@@ -73,7 +73,7 @@ import '../../OrSelectMultipleControl-a22cec0a.js';
|
|
|
73
73
|
import '../../isEqual-15f4b2f5.js';
|
|
74
74
|
import '../../OrSelectControlInput-e0116b29.js';
|
|
75
75
|
import '../../OrSelectPlaceholder-81502228.js';
|
|
76
|
-
import '../../OrSelectSingleControl-
|
|
76
|
+
import '../../OrSelectSingleControl-93cdab5b.js';
|
|
77
77
|
import '../../OrSwitch-0fb0d361.js';
|
|
78
78
|
import '../../OrTagInput-fb3e1714.js';
|
|
79
79
|
import '../../OrTimePicker-e042d71a.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { s as OrDataGridFooter, a as OrDataGridHeader, b as OrDataGridTable, c as OrDataGridTableContent, d as OrDataGridTableContentCell, e as OrDataGridTableContentRow, f as OrDataGridTableFooter, g as OrDataGridTableFooterCell, h as OrDataGridTableFooterRow, i as OrDataGridTableHeader, j as OrDataGridTableHeaderCell, k as OrDataGridTableHeaderRow, l as OrDataGridTablePlaceholder, m as OrDataGridToolbar } from '../../../OrDataGridToolbar-
|
|
1
|
+
export { s as OrDataGridFooter, a as OrDataGridHeader, b as OrDataGridTable, c as OrDataGridTableContent, d as OrDataGridTableContentCell, e as OrDataGridTableContentRow, f as OrDataGridTableFooter, g as OrDataGridTableFooterCell, h as OrDataGridTableFooterRow, i as OrDataGridTableHeader, j as OrDataGridTableHeaderCell, k as OrDataGridTableHeaderRow, l as OrDataGridTablePlaceholder, m as OrDataGridToolbar } from '../../../OrDataGridToolbar-8fedec74.js';
|
|
2
2
|
import 'vue-demi';
|
|
3
3
|
import 'vue';
|
|
4
4
|
import '../../../TimeFormat-a7f5565b.js';
|
|
@@ -50,7 +50,7 @@ import '../../../getCurrentDate-e5a478c3.js';
|
|
|
50
50
|
import '../../../OrInput-684d592e.js';
|
|
51
51
|
import '../../../useValidationAttributes-257954f3.js';
|
|
52
52
|
import '../../../OrRating-7c2f8e4d.js';
|
|
53
|
-
import '../../../OrSelect-
|
|
53
|
+
import '../../../OrSelect-1274c0d1.js';
|
|
54
54
|
import '../../../isString-cf957a95.js';
|
|
55
55
|
import '../../../isNull-7ae26d1d.js';
|
|
56
56
|
import '../../../isObject-4d5300e9.js';
|
|
@@ -64,7 +64,7 @@ import '../../../OrSelectMultipleControl-a22cec0a.js';
|
|
|
64
64
|
import '../../../isEqual-15f4b2f5.js';
|
|
65
65
|
import '../../../OrSelectControlInput-e0116b29.js';
|
|
66
66
|
import '../../../OrSelectPlaceholder-81502228.js';
|
|
67
|
-
import '../../../OrSelectSingleControl-
|
|
67
|
+
import '../../../OrSelectSingleControl-93cdab5b.js';
|
|
68
68
|
import '../../../OrSwitch-0fb0d361.js';
|
|
69
69
|
import '../../../OrTagInput-fb3e1714.js';
|
|
70
70
|
import '../../../OrTimePicker-e042d71a.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { s as OrSelectV3 } from '../../OrSelect-
|
|
1
|
+
export { s as OrSelectV3 } from '../../OrSelect-1274c0d1.js';
|
|
2
2
|
import 'vue-demi';
|
|
3
3
|
import '../../dropdown-open-06d651cf.js';
|
|
4
4
|
import '../../include-2a81e823.js';
|
|
@@ -53,4 +53,4 @@ import '../../OrSelectMultipleControl-a22cec0a.js';
|
|
|
53
53
|
import '../../isEqual-15f4b2f5.js';
|
|
54
54
|
import '../../OrSelectControlInput-e0116b29.js';
|
|
55
55
|
import '../../OrSelectPlaceholder-81502228.js';
|
|
56
|
-
import '../../OrSelectSingleControl-
|
|
56
|
+
import '../../OrSelectSingleControl-93cdab5b.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { s as OrSelectMultipleControl } from '../../../OrSelectMultipleControl-a22cec0a.js';
|
|
2
|
-
export { s as OrSelectSingleControl } from '../../../OrSelectSingleControl-
|
|
2
|
+
export { s as OrSelectSingleControl } from '../../../OrSelectSingleControl-93cdab5b.js';
|
|
3
3
|
export { s as OrSelectPlaceholder } from '../../../OrSelectPlaceholder-81502228.js';
|
|
4
4
|
import 'vue-demi';
|
|
5
5
|
import '../../../TimeFormat-a7f5565b.js';
|
|
@@ -39,11 +39,11 @@ declare const _default: import("vue-demi").DefineComponent<{
|
|
|
39
39
|
selectionLabel: import("vue-demi").ComputedRef<string | undefined>;
|
|
40
40
|
focus: () => void;
|
|
41
41
|
focused: import("vue-demi").ComputedRef<any>;
|
|
42
|
-
isContentTruncated: import("vue-demi").Ref<boolean>;
|
|
43
42
|
selectionLabelRef: import("vue-demi").Ref<HTMLDialogElement | undefined>;
|
|
44
43
|
tooltipRef: import("vue-demi").Ref<any>;
|
|
45
44
|
openTooltip: () => void;
|
|
46
45
|
closeTooltip: () => void;
|
|
46
|
+
checkTooltip: () => void;
|
|
47
47
|
}, unknown, {}, {}, import("vue-demi").ComponentOptionsMixin, import("vue-demi").ComponentOptionsMixin, "update:modelValue"[], "update:modelValue", import("vue-demi").VNodeProps & import("vue-demi").AllowedComponentProps & import("vue-demi").ComponentCustomProps, Readonly<import("vue-demi").ExtractPropTypes<{
|
|
48
48
|
modelValue: {
|
|
49
49
|
type: StringConstructor;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { s as OrSelectSingleControl } from '../../../../OrSelectSingleControl-
|
|
1
|
+
export { s as OrSelectSingleControl } from '../../../../OrSelectSingleControl-93cdab5b.js';
|
|
2
2
|
import 'vue-demi';
|
|
3
3
|
import '../../../../TimeFormat-a7f5565b.js';
|
|
4
4
|
import '../../../../dom-53c9635b.js';
|
package/dist/esm/v3/index.js
CHANGED
|
@@ -32,8 +32,8 @@ export { s as OrCombinedInputV3 } from './OrCombinedInput-75b556fa.js';
|
|
|
32
32
|
export { s as OrConfirm } from './OrConfirm-05a78778.js';
|
|
33
33
|
export { C as ConfirmType, s as OrConfirmV3 } from './OrConfirm-f47d7230.js';
|
|
34
34
|
export { s as OrContextMenuV3 } from './OrContextMenu-d8c71891.js';
|
|
35
|
-
export { s as OrDataGridV3 } from './OrDataGrid-
|
|
36
|
-
export { D as DataGridVariant } from './OrDataGridToolbar-
|
|
35
|
+
export { s as OrDataGridV3 } from './OrDataGrid-f56e2527.js';
|
|
36
|
+
export { D as DataGridVariant } from './OrDataGridToolbar-8fedec74.js';
|
|
37
37
|
export { s as OrDateFormatV3 } from './OrDateFormat-5a4af897.js';
|
|
38
38
|
export { s as OrDatePickerV3 } from './OrDatePicker-f0457c2a.js';
|
|
39
39
|
export { s as OrDateRangePickerV3 } from './OrDateRangePicker-fbf1430a.js';
|
|
@@ -109,7 +109,7 @@ export { s as OrSearch } from './OrSearch-4192737e.js';
|
|
|
109
109
|
export { s as OrSearchV3 } from './OrSearch-7d90b23b.js';
|
|
110
110
|
export { s as OrSegmentedControlV3, S as SegmentedControlSize } from './OrSegmentedControl-5dd163fb.js';
|
|
111
111
|
export { s as OrSelect } from './OrSelect-2c033afb.js';
|
|
112
|
-
export { s as OrSelectV3 } from './OrSelect-
|
|
112
|
+
export { s as OrSelectV3 } from './OrSelect-1274c0d1.js';
|
|
113
113
|
export { s as OrSidebar, O as OrSidebarSide } from './OrSidebar-4ab42b93.js';
|
|
114
114
|
export { s as OrSidebarV3, S as SidebarPlacement } from './props-413bed7b.js';
|
|
115
115
|
export { s as OrSkeletonCircle } from './OrSkeletonCircle-66e175a0.js';
|
|
@@ -233,7 +233,7 @@ import 'lodash/keyBy';
|
|
|
233
233
|
import './OrSelectMultipleControl-a22cec0a.js';
|
|
234
234
|
import './OrSelectControlInput-e0116b29.js';
|
|
235
235
|
import './OrSelectPlaceholder-81502228.js';
|
|
236
|
-
import './OrSelectSingleControl-
|
|
236
|
+
import './OrSelectSingleControl-93cdab5b.js';
|
|
237
237
|
import 'lodash/range';
|
|
238
238
|
import './styles-ed564e39.js';
|
|
239
239
|
import 'lodash/isNil';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@onereach/ui-components",
|
|
3
|
-
"version": "17.1.
|
|
3
|
+
"version": "17.1.1",
|
|
4
4
|
"npmUnpacked": "4.15.2",
|
|
5
5
|
"description": "Vue components library for v2/3",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
"@codemirror/lang-json": "6.0.1",
|
|
41
41
|
"@codemirror/lang-markdown": "6.1.1",
|
|
42
42
|
"@floating-ui/dom": "1.5.3",
|
|
43
|
-
"@onereach/styles": "^17.1.
|
|
43
|
+
"@onereach/styles": "^17.1.1",
|
|
44
44
|
"@splidejs/splide": "4.0.6",
|
|
45
45
|
"@tiptap/core": "2.0.3",
|
|
46
46
|
"@tiptap/extension-blockquote": "2.0.3",
|
|
@@ -180,5 +180,5 @@
|
|
|
180
180
|
},
|
|
181
181
|
"./package.json": "./package.json"
|
|
182
182
|
},
|
|
183
|
-
"gitHead": "
|
|
183
|
+
"gitHead": "7738670759be3878f5dd755d5d9eb5117b685510"
|
|
184
184
|
}
|
package/src/components/or-select-v3/partials/or-select-single-control/OrSelectSingleControl.vue
CHANGED
|
@@ -23,13 +23,12 @@
|
|
|
23
23
|
<div
|
|
24
24
|
ref="selectionLabelRef"
|
|
25
25
|
class="truncate w-full"
|
|
26
|
-
@mouseenter="
|
|
27
|
-
@mouseleave="
|
|
26
|
+
@mouseenter="checkTooltip"
|
|
27
|
+
@mouseleave="closeTooltip"
|
|
28
28
|
>
|
|
29
29
|
{{ selectionLabel }}
|
|
30
30
|
</div>
|
|
31
31
|
<OrTooltip
|
|
32
|
-
v-if="isContentTruncated"
|
|
33
32
|
ref="tooltipRef"
|
|
34
33
|
:content="selectionLabel"
|
|
35
34
|
:trigger="selectionLabelRef"
|
|
@@ -41,7 +40,8 @@
|
|
|
41
40
|
</template>
|
|
42
41
|
|
|
43
42
|
<script lang="ts">
|
|
44
|
-
import { PropType, computed, defineComponent, ref, toRefs, watch
|
|
43
|
+
import { PropType, computed, defineComponent, ref, toRefs, watch } from 'vue-demi';
|
|
44
|
+
|
|
45
45
|
import { useProxyModelValue } from '../../../../hooks';
|
|
46
46
|
import { isEmpty, isEqual } from '../../../../utils';
|
|
47
47
|
import { SelectItem, SelectModelValue } from '../../types';
|
|
@@ -118,7 +118,6 @@ export default defineComponent({
|
|
|
118
118
|
const searchControl = ref<InstanceType<typeof OrSelectControlInput>>();
|
|
119
119
|
const selectionLabelRef = ref<HTMLDialogElement>();
|
|
120
120
|
const tooltipRef = ref<InstanceType<typeof OrTooltip>>();
|
|
121
|
-
const isContentTruncated = ref(false);
|
|
122
121
|
|
|
123
122
|
// Props
|
|
124
123
|
const { modelValue, model, options } = toRefs(props);
|
|
@@ -138,15 +137,6 @@ export default defineComponent({
|
|
|
138
137
|
return selection.value?.label;
|
|
139
138
|
});
|
|
140
139
|
|
|
141
|
-
/* NOTE: using watch here due to async action.
|
|
142
|
-
Computed don't work since we need not just to track the data but to analyze UI after the re-render */
|
|
143
|
-
watch(model, async () => {
|
|
144
|
-
await nextTick();
|
|
145
|
-
if (selectionLabelRef.value) {
|
|
146
|
-
isContentTruncated.value = selectionLabelRef.value.scrollWidth > selectionLabelRef.value.clientWidth;
|
|
147
|
-
}
|
|
148
|
-
});
|
|
149
|
-
|
|
150
140
|
watch(
|
|
151
141
|
() => props.isOpen,
|
|
152
142
|
() => {
|
|
@@ -179,6 +169,12 @@ export default defineComponent({
|
|
|
179
169
|
}
|
|
180
170
|
}
|
|
181
171
|
|
|
172
|
+
function checkTooltip() {
|
|
173
|
+
if (!selectionLabelRef.value) return; // to prevent fro TS error; normally ref will always be available here since the method is a mouse event callback
|
|
174
|
+
const isContentTruncated = selectionLabelRef.value.scrollWidth > selectionLabelRef.value.clientWidth;
|
|
175
|
+
if (isContentTruncated) openTooltip();
|
|
176
|
+
}
|
|
177
|
+
|
|
182
178
|
return {
|
|
183
179
|
root,
|
|
184
180
|
rootStyles,
|
|
@@ -189,11 +185,11 @@ export default defineComponent({
|
|
|
189
185
|
selectionLabel,
|
|
190
186
|
focus,
|
|
191
187
|
focused,
|
|
192
|
-
isContentTruncated,
|
|
193
188
|
selectionLabelRef,
|
|
194
189
|
tooltipRef,
|
|
195
190
|
openTooltip,
|
|
196
191
|
closeTooltip,
|
|
192
|
+
checkTooltip,
|
|
197
193
|
};
|
|
198
194
|
},
|
|
199
195
|
});
|
|
File without changes
|