@onereach/ui-components 7.0.1-beta.3531.0 → 7.0.1-beta.3533.0
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/OrSelectV3/OrSelect.js +1 -0
- package/dist/bundled/v2/components/OrTagsV3/OrTags.js +2 -1
- package/dist/bundled/v2/hooks/useOverflow.d.ts +1 -0
- package/dist/bundled/v2/hooks/useOverflow.js +8 -6
- package/dist/bundled/v3/{OrSelect.vue_vue_type_script_lang-3c895f3a.js → OrSelect.vue_vue_type_script_lang-e11d6b35.js} +1 -1
- package/dist/bundled/v3/{OrTagInput.vue_vue_type_script_lang-cef895f1.js → OrTagInput.vue_vue_type_script_lang-049cd088.js} +1 -1
- package/dist/bundled/v3/{OrTags.vue_vue_type_script_lang-ab2ccd23.js → OrTags.vue_vue_type_script_lang-bce52bb6.js} +2 -1
- package/dist/bundled/v3/components/OrSelectV3/OrSelect.js +4 -3
- package/dist/bundled/v3/components/OrSelectV3/index.js +1 -1
- package/dist/bundled/v3/components/OrTagInputV3/OrTagInput.js +2 -2
- package/dist/bundled/v3/components/OrTagInputV3/index.js +1 -1
- package/dist/bundled/v3/components/OrTagsV3/OrTags.js +2 -2
- package/dist/bundled/v3/components/OrTagsV3/index.js +1 -1
- package/dist/bundled/v3/components/index.js +3 -3
- package/dist/bundled/v3/hooks/useOverflow.d.ts +1 -0
- package/dist/bundled/v3/hooks/useOverflow.js +8 -6
- package/dist/bundled/v3/index.js +3 -3
- package/dist/esm/v2/{OrSelect-578bcee2.js → OrSelect-07de6a73.js} +3 -2
- package/dist/esm/v2/{OrSelectMultipleControl-961d8d6a.js → OrSelectMultipleControl-e891fad1.js} +1 -1
- package/dist/esm/v2/{OrTagInput-7f917d41.js → OrTagInput-4c4d0714.js} +1 -1
- package/dist/esm/v2/{OrTags-ed4ddf4d.js → OrTags-a733e716.js} +3 -2
- package/dist/esm/v2/components/index.js +5 -5
- package/dist/esm/v2/components/or-select-v3/index.js +4 -4
- package/dist/esm/v2/components/or-select-v3/partials/index.js +3 -3
- package/dist/esm/v2/components/or-select-v3/partials/or-select-multiple-control/index.js +3 -3
- package/dist/esm/v2/components/or-tag-input-v3/index.js +3 -3
- package/dist/esm/v2/components/or-tags-v3/index.js +2 -2
- package/dist/esm/v2/hooks/index.js +1 -1
- package/dist/esm/v2/hooks/useOverflow.d.ts +1 -0
- package/dist/esm/v2/index.js +5 -5
- package/dist/esm/v2/{useOverflow-b482f3c9.js → useOverflow-e91d2314.js} +8 -6
- package/dist/esm/v3/{OrSelect-b359beb6.js → OrSelect-31442785.js} +4 -3
- package/dist/esm/v3/{OrSelectMultipleControl-3620b234.js → OrSelectMultipleControl-64bb859f.js} +1 -1
- package/dist/esm/v3/{OrTagInput-56ee7d0b.js → OrTagInput-d018033c.js} +1 -1
- package/dist/esm/v3/{OrTags-52da64cd.js → OrTags-ba8ef261.js} +3 -2
- package/dist/esm/v3/components/index.js +5 -5
- package/dist/esm/v3/components/or-select-v3/index.js +4 -4
- package/dist/esm/v3/components/or-select-v3/partials/index.js +3 -3
- package/dist/esm/v3/components/or-select-v3/partials/or-select-multiple-control/index.js +3 -3
- package/dist/esm/v3/components/or-tag-input-v3/index.js +3 -3
- package/dist/esm/v3/components/or-tags-v3/index.js +2 -2
- package/dist/esm/v3/hooks/index.js +1 -1
- package/dist/esm/v3/hooks/useOverflow.d.ts +1 -0
- package/dist/esm/v3/index.js +5 -5
- package/dist/esm/v3/{useOverflow-b482f3c9.js → useOverflow-e91d2314.js} +8 -6
- package/package.json +1 -1
- package/src/components/or-select-v3/OrSelect.vue +1 -0
- package/src/components/or-tags-v3/OrTags.vue +4 -1
- package/src/hooks/useOverflow.ts +6 -4
|
@@ -3,9 +3,11 @@ import { isRef, ref, watch } from 'vue-demi';
|
|
|
3
3
|
import { r as requestAF } from '../dom-cec392f3.js';
|
|
4
4
|
|
|
5
5
|
function useOverflow(container) {
|
|
6
|
-
let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
7
|
+
const {
|
|
8
|
+
hide = true,
|
|
9
|
+
threshold = 0
|
|
10
|
+
} = options;
|
|
9
11
|
const containerRef = isRef(container) ? container : ref(container);
|
|
10
12
|
// State
|
|
11
13
|
const innerItemsRef = ref([]);
|
|
@@ -28,8 +30,8 @@ function useOverflow(container) {
|
|
|
28
30
|
x: containerOffset,
|
|
29
31
|
width: containerWidth
|
|
30
32
|
} = container.getBoundingClientRect();
|
|
31
|
-
if (itemOffset + itemWidth > containerOffset + containerWidth) {
|
|
32
|
-
if (
|
|
33
|
+
if (itemOffset + itemWidth > containerOffset + containerWidth + threshold) {
|
|
34
|
+
if (hide) {
|
|
33
35
|
item.style.setProperty('visibility', 'hidden');
|
|
34
36
|
}
|
|
35
37
|
return {
|
|
@@ -37,7 +39,7 @@ function useOverflow(container) {
|
|
|
37
39
|
outerItems: [...outerItems, item]
|
|
38
40
|
};
|
|
39
41
|
} else {
|
|
40
|
-
if (
|
|
42
|
+
if (hide) {
|
|
41
43
|
item.style.removeProperty('visibility');
|
|
42
44
|
}
|
|
43
45
|
return {
|
|
@@ -5,7 +5,7 @@ import { isEmptyValue } from './utils/isEmptyValue.js';
|
|
|
5
5
|
import { f as useFocus } from './index-c5cda763.js';
|
|
6
6
|
import { useProxyModelValue } from './hooks/useProxyModelValue.js';
|
|
7
7
|
import './components/OrTagsV3/OrTags.js';
|
|
8
|
-
import { s as script$5 } from './OrTags.vue_vue_type_script_lang-
|
|
8
|
+
import { s as script$5 } from './OrTags.vue_vue_type_script_lang-bce52bb6.js';
|
|
9
9
|
import { TagsOverflow } from './components/OrTagsV3/props.js';
|
|
10
10
|
import './components/OrCheckboxV3/OrCheckbox.js';
|
|
11
11
|
import './components/OrErrorV3/OrError.js';
|
|
@@ -12,7 +12,7 @@ import { s as script$2 } from './OrHint.vue_vue_type_script_lang-0ab8b932.js';
|
|
|
12
12
|
import { s as script$3 } from './OrIconButton.vue_vue_type_script_lang-6a53a819.js';
|
|
13
13
|
import { s as script$4 } from './OrInputBox.vue_vue_type_script_lang-137cb650.js';
|
|
14
14
|
import { s as script$5 } from './OrLabel.vue_vue_type_script_lang-e2bcff17.js';
|
|
15
|
-
import { s as script$6 } from './OrTags.vue_vue_type_script_lang-
|
|
15
|
+
import { s as script$6 } from './OrTags.vue_vue_type_script_lang-bce52bb6.js';
|
|
16
16
|
import { TagsOverflow } from './components/OrTagsV3/props.js';
|
|
17
17
|
import { useIdAttribute } from './hooks/useIdAttribute.js';
|
|
18
18
|
import { useControlAttributes } from './hooks/useControlAttributes.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { s as script } from '../../OrSelect.vue_vue_type_script_lang-
|
|
2
|
-
export { s as default } from '../../OrSelect.vue_vue_type_script_lang-
|
|
1
|
+
import { s as script } from '../../OrSelect.vue_vue_type_script_lang-e11d6b35.js';
|
|
2
|
+
export { s as default } from '../../OrSelect.vue_vue_type_script_lang-e11d6b35.js';
|
|
3
3
|
import { resolveComponent, resolveDirective, openBlock, createElementBlock, normalizeClass, createBlock, withCtx, renderSlot, createTextVNode, toDisplayString, createCommentVNode, withDirectives, createElementVNode, withModifiers, createVNode, Fragment, renderList, vShow } from 'vue';
|
|
4
4
|
|
|
5
5
|
const _hoisted_1 = ["id", "tabindex", "disabled"];
|
|
@@ -81,10 +81,11 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
81
81
|
modelValue: _ctx.searchText,
|
|
82
82
|
"onUpdate:modelValue": _cache[1] || (_cache[1] = $event => _ctx.searchText = $event),
|
|
83
83
|
model: _ctx.proxyModelValue,
|
|
84
|
+
disabled: _ctx.disabled,
|
|
84
85
|
options: _ctx.options,
|
|
85
86
|
placeholder: _ctx.placeholder,
|
|
86
87
|
"enable-search": _ctx.enableSearch
|
|
87
|
-
}, null, 8 /* PROPS */, ["modelValue", "model", "options", "placeholder", "enable-search"]))])], 42 /* CLASS, PROPS, HYDRATE_EVENTS */, _hoisted_1), createElementVNode("div", _hoisted_2, [_ctx.showClear ? (openBlock(), createBlock(_component_OrIconButton, {
|
|
88
|
+
}, null, 8 /* PROPS */, ["modelValue", "model", "disabled", "options", "placeholder", "enable-search"]))])], 42 /* CLASS, PROPS, HYDRATE_EVENTS */, _hoisted_1), createElementVNode("div", _hoisted_2, [_ctx.showClear ? (openBlock(), createBlock(_component_OrIconButton, {
|
|
88
89
|
key: 0,
|
|
89
90
|
icon: 'close',
|
|
90
91
|
color: 'inherit',
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { s as OrSelectV3 } from '../../OrSelect.vue_vue_type_script_lang-
|
|
1
|
+
export { s as OrSelectV3 } from '../../OrSelect.vue_vue_type_script_lang-e11d6b35.js';
|
|
2
2
|
export { InputBoxSize as SelectSize } from '../OrInputBoxV3/props.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { s as script } from '../../OrTagInput.vue_vue_type_script_lang-
|
|
2
|
-
export { s as default } from '../../OrTagInput.vue_vue_type_script_lang-
|
|
1
|
+
import { s as script } from '../../OrTagInput.vue_vue_type_script_lang-049cd088.js';
|
|
2
|
+
export { s as default } from '../../OrTagInput.vue_vue_type_script_lang-049cd088.js';
|
|
3
3
|
import { resolveComponent, openBlock, createElementBlock, normalizeClass, createBlock, withCtx, renderSlot, createTextVNode, toDisplayString, createCommentVNode, createVNode, createSlots, createElementVNode, withDirectives, mergeProps, withKeys, vModelDynamic, vShow } from 'vue';
|
|
4
4
|
import { s as styleInject } from '../../style-inject.es-4c6f2515.js';
|
|
5
5
|
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { s as OrTagInputV3 } from '../../OrTagInput.vue_vue_type_script_lang-
|
|
1
|
+
export { s as OrTagInputV3 } from '../../OrTagInput.vue_vue_type_script_lang-049cd088.js';
|
|
2
2
|
export { InputBoxSize as TagInputSize } from '../OrInputBoxV3/props.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { s as script } from '../../OrTags.vue_vue_type_script_lang-
|
|
2
|
-
export { s as default } from '../../OrTags.vue_vue_type_script_lang-
|
|
1
|
+
import { s as script } from '../../OrTags.vue_vue_type_script_lang-bce52bb6.js';
|
|
2
|
+
export { s as default } from '../../OrTags.vue_vue_type_script_lang-bce52bb6.js';
|
|
3
3
|
import { resolveComponent, openBlock, createElementBlock, normalizeClass, Fragment, renderList, createBlock, mergeProps, withCtx, createTextVNode, toDisplayString, renderSlot, createCommentVNode, createVNode, withModifiers, createElementVNode } from 'vue';
|
|
4
4
|
|
|
5
5
|
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export { TagsOverflow } from './props.js';
|
|
2
|
-
export { s as OrTagsV3 } from '../../OrTags.vue_vue_type_script_lang-
|
|
2
|
+
export { s as OrTagsV3 } from '../../OrTags.vue_vue_type_script_lang-bce52bb6.js';
|
|
@@ -136,7 +136,7 @@ export { s as OrSearchV3 } from '../OrSearch.vue_vue_type_script_lang-e756d8a8.j
|
|
|
136
136
|
export { s as OrSegmentedControlV3 } from '../OrSegmentedControl.vue_vue_type_script_lang-10bd4ea8.js';
|
|
137
137
|
export { SegmentedControlSize } from './OrSegmentedControlV3/props.js';
|
|
138
138
|
export { s as OrSelect } from '../OrSelect.vue_vue_type_script_lang-a4d17559.js';
|
|
139
|
-
export { s as OrSelectV3 } from '../OrSelect.vue_vue_type_script_lang-
|
|
139
|
+
export { s as OrSelectV3 } from '../OrSelect.vue_vue_type_script_lang-e11d6b35.js';
|
|
140
140
|
export { s as OrSidebar } from '../OrSidebar.vue_vue_type_script_lang-f69f92ca.js';
|
|
141
141
|
export { OrSidebarSide } from './OrSidebar/constants.js';
|
|
142
142
|
export { s as OrSidebarV3 } from '../OrSidebar.vue_vue_type_script_lang-314721d5.js';
|
|
@@ -160,10 +160,10 @@ export { s as OrTabs } from '../OrTabs.vue_vue_type_script_lang-9129d34b.js';
|
|
|
160
160
|
export { s as OrTabsV3 } from '../OrTabs.vue_vue_type_script_lang-ddac6c54.js';
|
|
161
161
|
export { TabsVariant } from './OrTabsV3/props.js';
|
|
162
162
|
export { s as OrTag } from '../OrTag.vue_vue_type_script_lang-b62c0b79.js';
|
|
163
|
-
export { s as OrTagInputV3 } from '../OrTagInput.vue_vue_type_script_lang-
|
|
163
|
+
export { s as OrTagInputV3 } from '../OrTagInput.vue_vue_type_script_lang-049cd088.js';
|
|
164
164
|
export { s as OrTagV3 } from '../OrTag.vue_vue_type_script_lang-6c0094be.js';
|
|
165
165
|
export { TagColor, TagVariant } from './OrTagV3/props.js';
|
|
166
|
-
export { s as OrTagsV3 } from '../OrTags.vue_vue_type_script_lang-
|
|
166
|
+
export { s as OrTagsV3 } from '../OrTags.vue_vue_type_script_lang-bce52bb6.js';
|
|
167
167
|
export { TagsOverflow } from './OrTagsV3/props.js';
|
|
168
168
|
export { default as OrTeleport } from './OrTeleport/OrTeleport.js';
|
|
169
169
|
export { s as OrTeleportV3 } from '../OrTeleport.vue3.vue_vue_type_script_lang-a6ce162e.js';
|
|
@@ -3,9 +3,11 @@ import { isRef, ref, watch } from 'vue-demi';
|
|
|
3
3
|
import { r as requestAF } from '../dom-cec392f3.js';
|
|
4
4
|
|
|
5
5
|
function useOverflow(container) {
|
|
6
|
-
let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
7
|
+
const {
|
|
8
|
+
hide = true,
|
|
9
|
+
threshold = 0
|
|
10
|
+
} = options;
|
|
9
11
|
const containerRef = isRef(container) ? container : ref(container);
|
|
10
12
|
// State
|
|
11
13
|
const innerItemsRef = ref([]);
|
|
@@ -28,8 +30,8 @@ function useOverflow(container) {
|
|
|
28
30
|
x: containerOffset,
|
|
29
31
|
width: containerWidth
|
|
30
32
|
} = container.getBoundingClientRect();
|
|
31
|
-
if (itemOffset + itemWidth > containerOffset + containerWidth) {
|
|
32
|
-
if (
|
|
33
|
+
if (itemOffset + itemWidth > containerOffset + containerWidth + threshold) {
|
|
34
|
+
if (hide) {
|
|
33
35
|
item.style.setProperty('visibility', 'hidden');
|
|
34
36
|
}
|
|
35
37
|
return {
|
|
@@ -37,7 +39,7 @@ function useOverflow(container) {
|
|
|
37
39
|
outerItems: [...outerItems, item]
|
|
38
40
|
};
|
|
39
41
|
} else {
|
|
40
|
-
if (
|
|
42
|
+
if (hide) {
|
|
41
43
|
item.style.removeProperty('visibility');
|
|
42
44
|
}
|
|
43
45
|
return {
|
package/dist/bundled/v3/index.js
CHANGED
|
@@ -82,7 +82,7 @@ export { s as OrSegmentedControlV3 } from './OrSegmentedControl.vue_vue_type_scr
|
|
|
82
82
|
import './components/OrSelect/OrSelect.js';
|
|
83
83
|
export { s as OrSelect } from './OrSelect.vue_vue_type_script_lang-a4d17559.js';
|
|
84
84
|
import './components/OrSelectV3/OrSelect.js';
|
|
85
|
-
export { s as OrSelectV3 } from './OrSelect.vue_vue_type_script_lang-
|
|
85
|
+
export { s as OrSelectV3 } from './OrSelect.vue_vue_type_script_lang-e11d6b35.js';
|
|
86
86
|
import './components/OrSidebar/OrSidebar.js';
|
|
87
87
|
export { s as OrSidebar } from './OrSidebar.vue_vue_type_script_lang-f69f92ca.js';
|
|
88
88
|
import './components/OrSidebarV3/OrSidebar.js';
|
|
@@ -116,7 +116,7 @@ export { s as OrTabsV3 } from './OrTabs.vue_vue_type_script_lang-ddac6c54.js';
|
|
|
116
116
|
import './components/OrTag/OrTag.js';
|
|
117
117
|
export { s as OrTag } from './OrTag.vue_vue_type_script_lang-b62c0b79.js';
|
|
118
118
|
import './components/OrTagInputV3/OrTagInput.js';
|
|
119
|
-
export { s as OrTagInputV3 } from './OrTagInput.vue_vue_type_script_lang-
|
|
119
|
+
export { s as OrTagInputV3 } from './OrTagInput.vue_vue_type_script_lang-049cd088.js';
|
|
120
120
|
import './components/OrTextV3/OrText.js';
|
|
121
121
|
export { s as OrTextV3 } from './OrText.vue_vue_type_script_lang-6ce019db.js';
|
|
122
122
|
import './components/OrTextarea/OrTextarea.js';
|
|
@@ -243,7 +243,7 @@ export { s as OrTabV3 } from './OrTab.vue_vue_type_script_lang-a300956d.js';
|
|
|
243
243
|
export { TabsVariant } from './components/OrTabsV3/props.js';
|
|
244
244
|
export { s as OrTagV3 } from './OrTag.vue_vue_type_script_lang-6c0094be.js';
|
|
245
245
|
export { TagColor, TagVariant } from './components/OrTagV3/props.js';
|
|
246
|
-
export { s as OrTagsV3 } from './OrTags.vue_vue_type_script_lang-
|
|
246
|
+
export { s as OrTagsV3 } from './OrTags.vue_vue_type_script_lang-bce52bb6.js';
|
|
247
247
|
export { TagsOverflow } from './components/OrTagsV3/props.js';
|
|
248
248
|
export { default as OrTeleport } from './components/OrTeleport/OrTeleport.js';
|
|
249
249
|
export { s as OrTeleportV3 } from './OrTeleport.vue3.vue_vue_type_script_lang-a6ce162e.js';
|
|
@@ -18,8 +18,8 @@ import { _ as __vue_component__$9 } from './OrInput-e9e91885.js';
|
|
|
18
18
|
import { _ as __vue_component__$b } from './OrLabel-b465bc0b.js';
|
|
19
19
|
import { _ as __vue_component__$c } from './OrMenuItem-8d1c89f6.js';
|
|
20
20
|
import { _ as __vue_component__$d } from './OrPopover-2ced765c.js';
|
|
21
|
-
import { T as TagsOverflow } from './OrTags-
|
|
22
|
-
import { _ as __vue_component__$1 } from './OrSelectMultipleControl-
|
|
21
|
+
import { T as TagsOverflow } from './OrTags-a733e716.js';
|
|
22
|
+
import { _ as __vue_component__$1 } from './OrSelectMultipleControl-e891fad1.js';
|
|
23
23
|
import { _ as __vue_component__$2 } from './OrSelectSingleControl-76b29e0b.js';
|
|
24
24
|
import './OrSelectPlaceholder-f36f4e40.js';
|
|
25
25
|
import { n as normalizeComponent } from './normalize-component-6e8e3d80.js';
|
|
@@ -465,6 +465,7 @@ var __vue_render__ = function () {
|
|
|
465
465
|
ref: "singleControl",
|
|
466
466
|
attrs: {
|
|
467
467
|
"model": _vm.proxyModelValue,
|
|
468
|
+
"disabled": _vm.disabled,
|
|
468
469
|
"options": _vm.options,
|
|
469
470
|
"placeholder": _vm.placeholder,
|
|
470
471
|
"enable-search": _vm.enableSearch
|
package/dist/esm/v2/{OrSelectMultipleControl-961d8d6a.js → OrSelectMultipleControl-e891fad1.js}
RENAMED
|
@@ -4,7 +4,7 @@ import './dom-aecadd9a.js';
|
|
|
4
4
|
import { u as useProxyModelValue } from './useProxyModelValue-940010d2.js';
|
|
5
5
|
import '@onereach/styles/tailwind/plugins/core';
|
|
6
6
|
import '@onereach/styles/tailwind.config.json';
|
|
7
|
-
import { _ as __vue_component__$3, T as TagsOverflow } from './OrTags-
|
|
7
|
+
import { _ as __vue_component__$3, T as TagsOverflow } from './OrTags-a733e716.js';
|
|
8
8
|
import { _ as __vue_component__$1 } from './OrSelectPlaceholder-f36f4e40.js';
|
|
9
9
|
import { i as isEmptyValue } from './isEmptyValue-fd56a6e4.js';
|
|
10
10
|
import { _ as __vue_component__$2 } from './OrSelectControlInput-28c226f8.js';
|
|
@@ -12,7 +12,7 @@ import { _ as __vue_component__$3 } from './OrIconButton-07c0bd56.js';
|
|
|
12
12
|
import { _ as __vue_component__$4 } from './OrInputBox-7dc5b9e9.js';
|
|
13
13
|
import './OrInputBox.vue_rollup-plugin-vue_script-4fde9829.js';
|
|
14
14
|
import { _ as __vue_component__$5 } from './OrLabel-b465bc0b.js';
|
|
15
|
-
import { _ as __vue_component__$6, T as TagsOverflow } from './OrTags-
|
|
15
|
+
import { _ as __vue_component__$6, T as TagsOverflow } from './OrTags-a733e716.js';
|
|
16
16
|
import { s as styleInject } from './style-inject.es-4c6f2515.js';
|
|
17
17
|
import { n as normalizeComponent } from './normalize-component-6e8e3d80.js';
|
|
18
18
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent, ref, toRefs, computed, nextTick } from 'vue-demi';
|
|
2
|
-
import { u as useOverflow } from './useOverflow-
|
|
2
|
+
import { u as useOverflow } from './useOverflow-e91d2314.js';
|
|
3
3
|
import '@vueuse/core';
|
|
4
4
|
import '@onereach/styles/tailwind/plugins/core';
|
|
5
5
|
import '@onereach/styles/tailwind.config.json';
|
|
@@ -130,7 +130,8 @@ var script = defineComponent({
|
|
|
130
130
|
const {
|
|
131
131
|
innerItems
|
|
132
132
|
} = useOverflow(container, {
|
|
133
|
-
hide: false
|
|
133
|
+
hide: false,
|
|
134
|
+
threshold: 8
|
|
134
135
|
});
|
|
135
136
|
const localItems = computed(() => {
|
|
136
137
|
return items.value.map(castToTagObject);
|
|
@@ -93,7 +93,7 @@ export { _ as OrSearch } from '../OrSearch-ac542dd6.js';
|
|
|
93
93
|
export { _ as OrSearchV3 } from '../OrSearch-c5850ddd.js';
|
|
94
94
|
export { _ as OrSegmentedControlV3, S as SegmentedControlSize } from '../OrSegmentedControl-bba94cda.js';
|
|
95
95
|
export { _ as OrSelect } from '../OrSelect-c0d04cf6.js';
|
|
96
|
-
export { _ as OrSelectV3 } from '../OrSelect-
|
|
96
|
+
export { _ as OrSelectV3 } from '../OrSelect-07de6a73.js';
|
|
97
97
|
export { _ as OrSidebar, O as OrSidebarSide } from '../OrSidebar-c56a9221.js';
|
|
98
98
|
export { _ as OrSidebarV3 } from '../OrSidebar-d24100a9.js';
|
|
99
99
|
export { S as OrSidebarPlacement, S as SidebarPlacement } from '../props-cc0586c8.js';
|
|
@@ -115,9 +115,9 @@ export { _ as OrTabV3 } from '../OrTab-13db2e49.js';
|
|
|
115
115
|
export { _ as OrTabs } from '../OrTabs-62e7e478.js';
|
|
116
116
|
export { _ as OrTabsV3, T as TabsVariant } from '../OrTabs-71f4fc47.js';
|
|
117
117
|
export { _ as OrTag } from '../OrTag-b5803a20.js';
|
|
118
|
-
export { _ as OrTagInputV3 } from '../OrTagInput-
|
|
118
|
+
export { _ as OrTagInputV3 } from '../OrTagInput-4c4d0714.js';
|
|
119
119
|
export { _ as OrTagV3, a as TagColor, T as TagVariant } from '../OrTag-884d1994.js';
|
|
120
|
-
export { _ as OrTagsV3, T as TagsOverflow } from '../OrTags-
|
|
120
|
+
export { _ as OrTagsV3, T as TagsOverflow } from '../OrTags-a733e716.js';
|
|
121
121
|
export { _ as OrTeleport } from '../OrTeleport.vue2-f0c16c71.js';
|
|
122
122
|
export { _ as OrTeleportV3 } from '../OrTeleport.vue2-424c7f33.js';
|
|
123
123
|
export { _ as OrTextV3 } from '../OrText-44449e7b.js';
|
|
@@ -199,12 +199,12 @@ import '../codemirrorView-020fe885.js';
|
|
|
199
199
|
import 'prosemirror-state';
|
|
200
200
|
import 'prosemirror-commands';
|
|
201
201
|
import 'lodash/keyBy';
|
|
202
|
-
import '../OrSelectMultipleControl-
|
|
202
|
+
import '../OrSelectMultipleControl-e891fad1.js';
|
|
203
203
|
import '../OrSelectPlaceholder-f36f4e40.js';
|
|
204
204
|
import '../OrSelectControlInput-28c226f8.js';
|
|
205
205
|
import '../OrSelectSingleControl-76b29e0b.js';
|
|
206
206
|
import 'lodash/range';
|
|
207
207
|
import '../styles-ed564e39.js';
|
|
208
|
-
import '../useOverflow-
|
|
208
|
+
import '../useOverflow-e91d2314.js';
|
|
209
209
|
import 'portal-vue/dist/portal-vue.esm.js';
|
|
210
210
|
import 'portal-vue';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { _ as OrSelectV3 } from '../../OrSelect-
|
|
1
|
+
export { _ as OrSelectV3 } from '../../OrSelect-07de6a73.js';
|
|
2
2
|
export { I as SelectSize } from '../../OrInputBox.vue_rollup-plugin-vue_script-4fde9829.js';
|
|
3
3
|
import 'vue-demi';
|
|
4
4
|
import '../../dropdown-open-06d651cf.js';
|
|
@@ -36,11 +36,11 @@ import '../../OrInput-e9e91885.js';
|
|
|
36
36
|
import '../../useValidationAttributes-d1abbe34.js';
|
|
37
37
|
import '../../OrLoader-b0c381f9.js';
|
|
38
38
|
import '../../OrMenuItem-8d1c89f6.js';
|
|
39
|
-
import '../../OrTags-
|
|
40
|
-
import '../../useOverflow-
|
|
39
|
+
import '../../OrTags-a733e716.js';
|
|
40
|
+
import '../../useOverflow-e91d2314.js';
|
|
41
41
|
import '../../OrButton-78336f88.js';
|
|
42
42
|
import '../../OrTag-884d1994.js';
|
|
43
|
-
import '../../OrSelectMultipleControl-
|
|
43
|
+
import '../../OrSelectMultipleControl-e891fad1.js';
|
|
44
44
|
import '../../OrSelectPlaceholder-f36f4e40.js';
|
|
45
45
|
import '../../OrSelectControlInput-28c226f8.js';
|
|
46
46
|
import '../../OrSelectSingleControl-76b29e0b.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { _ as OrSelectMultipleControl } from '../../../OrSelectMultipleControl-
|
|
1
|
+
export { _ as OrSelectMultipleControl } from '../../../OrSelectMultipleControl-e891fad1.js';
|
|
2
2
|
export { _ as OrSelectSingleControl } from '../../../OrSelectSingleControl-76b29e0b.js';
|
|
3
3
|
export { _ as OrSelectPlaceholder } from '../../../OrSelectPlaceholder-f36f4e40.js';
|
|
4
4
|
import 'vue-demi';
|
|
@@ -9,8 +9,8 @@ import 'lodash/get';
|
|
|
9
9
|
import '../../../useProxyModelValue-940010d2.js';
|
|
10
10
|
import '@onereach/styles/tailwind/plugins/core';
|
|
11
11
|
import '@onereach/styles/tailwind.config.json';
|
|
12
|
-
import '../../../OrTags-
|
|
13
|
-
import '../../../useOverflow-
|
|
12
|
+
import '../../../OrTags-a733e716.js';
|
|
13
|
+
import '../../../useOverflow-e91d2314.js';
|
|
14
14
|
import '../../../OrButton-78336f88.js';
|
|
15
15
|
import '../../../OrLoader-b0c381f9.js';
|
|
16
16
|
import '../../../normalize-component-6e8e3d80.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { _ as OrSelectMultipleControl } from '../../../../OrSelectMultipleControl-
|
|
1
|
+
export { _ as OrSelectMultipleControl } from '../../../../OrSelectMultipleControl-e891fad1.js';
|
|
2
2
|
import 'vue-demi';
|
|
3
3
|
import '@vueuse/core';
|
|
4
4
|
import '../../../../dom-aecadd9a.js';
|
|
@@ -7,8 +7,8 @@ import 'lodash/get';
|
|
|
7
7
|
import '../../../../useProxyModelValue-940010d2.js';
|
|
8
8
|
import '@onereach/styles/tailwind/plugins/core';
|
|
9
9
|
import '@onereach/styles/tailwind.config.json';
|
|
10
|
-
import '../../../../OrTags-
|
|
11
|
-
import '../../../../useOverflow-
|
|
10
|
+
import '../../../../OrTags-a733e716.js';
|
|
11
|
+
import '../../../../useOverflow-e91d2314.js';
|
|
12
12
|
import '../../../../OrButton-78336f88.js';
|
|
13
13
|
import '../../../../OrLoader-b0c381f9.js';
|
|
14
14
|
import '../../../../normalize-component-6e8e3d80.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { _ as OrTagInputV3 } from '../../OrTagInput-
|
|
1
|
+
export { _ as OrTagInputV3 } from '../../OrTagInput-4c4d0714.js';
|
|
2
2
|
export { I as TagInputSize } from '../../OrInputBox.vue_rollup-plugin-vue_script-4fde9829.js';
|
|
3
3
|
import 'vue-demi';
|
|
4
4
|
import '@vueuse/core';
|
|
@@ -28,8 +28,8 @@ import 'portal-vue';
|
|
|
28
28
|
import '../../useTheme-0ef25778.js';
|
|
29
29
|
import '../../OrInputBox-7dc5b9e9.js';
|
|
30
30
|
import '../../OrLabel-b465bc0b.js';
|
|
31
|
-
import '../../OrTags-
|
|
32
|
-
import '../../useOverflow-
|
|
31
|
+
import '../../OrTags-a733e716.js';
|
|
32
|
+
import '../../useOverflow-e91d2314.js';
|
|
33
33
|
import '../../OrButton-78336f88.js';
|
|
34
34
|
import '../../OrLoader-b0c381f9.js';
|
|
35
35
|
import '../../OrTag-884d1994.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { _ as OrTagsV3, T as TagsOverflow } from '../../OrTags-
|
|
1
|
+
export { _ as OrTagsV3, T as TagsOverflow } from '../../OrTags-a733e716.js';
|
|
2
2
|
import 'vue-demi';
|
|
3
|
-
import '../../useOverflow-
|
|
3
|
+
import '../../useOverflow-e91d2314.js';
|
|
4
4
|
import '@vueuse/core';
|
|
5
5
|
import '../../dom-aecadd9a.js';
|
|
6
6
|
import 'lodash/isElement';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export { u as useControlAttributes, a as useIdAttribute } from '../useIdAttribute-859439f0.js';
|
|
2
2
|
export { u as useElevation } from '../useElevation-a50ec347.js';
|
|
3
|
-
export { u as useOverflow } from '../useOverflow-
|
|
3
|
+
export { u as useOverflow } from '../useOverflow-e91d2314.js';
|
|
4
4
|
export { u as usePopoverState } from '../usePopoverState-b92c698b.js';
|
|
5
5
|
export { u as useProxyModelValue } from '../useProxyModelValue-940010d2.js';
|
|
6
6
|
export { u as useResponsive } from '../useResponsive-5c8291da.js';
|
package/dist/esm/v2/index.js
CHANGED
|
@@ -93,7 +93,7 @@ export { _ as OrSearch } from './OrSearch-ac542dd6.js';
|
|
|
93
93
|
export { _ as OrSearchV3 } from './OrSearch-c5850ddd.js';
|
|
94
94
|
export { _ as OrSegmentedControlV3, S as SegmentedControlSize } from './OrSegmentedControl-bba94cda.js';
|
|
95
95
|
export { _ as OrSelect } from './OrSelect-c0d04cf6.js';
|
|
96
|
-
export { _ as OrSelectV3 } from './OrSelect-
|
|
96
|
+
export { _ as OrSelectV3 } from './OrSelect-07de6a73.js';
|
|
97
97
|
export { _ as OrSidebar, O as OrSidebarSide } from './OrSidebar-c56a9221.js';
|
|
98
98
|
export { _ as OrSidebarV3 } from './OrSidebar-d24100a9.js';
|
|
99
99
|
export { S as OrSidebarPlacement, S as SidebarPlacement } from './props-cc0586c8.js';
|
|
@@ -115,9 +115,9 @@ export { _ as OrTabV3 } from './OrTab-13db2e49.js';
|
|
|
115
115
|
export { _ as OrTabs } from './OrTabs-62e7e478.js';
|
|
116
116
|
export { _ as OrTabsV3, T as TabsVariant } from './OrTabs-71f4fc47.js';
|
|
117
117
|
export { _ as OrTag } from './OrTag-b5803a20.js';
|
|
118
|
-
export { _ as OrTagInputV3 } from './OrTagInput-
|
|
118
|
+
export { _ as OrTagInputV3 } from './OrTagInput-4c4d0714.js';
|
|
119
119
|
export { _ as OrTagV3, a as TagColor, T as TagVariant } from './OrTag-884d1994.js';
|
|
120
|
-
export { _ as OrTagsV3, T as TagsOverflow } from './OrTags-
|
|
120
|
+
export { _ as OrTagsV3, T as TagsOverflow } from './OrTags-a733e716.js';
|
|
121
121
|
export { _ as OrTeleport } from './OrTeleport.vue2-f0c16c71.js';
|
|
122
122
|
export { _ as OrTeleportV3 } from './OrTeleport.vue2-424c7f33.js';
|
|
123
123
|
export { _ as OrTextV3 } from './OrText-44449e7b.js';
|
|
@@ -137,7 +137,7 @@ export { _ as OrTreeV3, T as TreeNodeDropPosition } from './OrTree-943553c1.js';
|
|
|
137
137
|
export { D as DropdownClose, a as DropdownOpen } from './dropdown-open-06d651cf.js';
|
|
138
138
|
export { u as useControlAttributes, a as useIdAttribute } from './useIdAttribute-859439f0.js';
|
|
139
139
|
export { u as useElevation } from './useElevation-a50ec347.js';
|
|
140
|
-
export { u as useOverflow } from './useOverflow-
|
|
140
|
+
export { u as useOverflow } from './useOverflow-e91d2314.js';
|
|
141
141
|
export { u as usePopoverState } from './usePopoverState-b92c698b.js';
|
|
142
142
|
export { u as useProxyModelValue } from './useProxyModelValue-940010d2.js';
|
|
143
143
|
export { u as useResponsive } from './useResponsive-5c8291da.js';
|
|
@@ -200,7 +200,7 @@ import './codemirrorView-020fe885.js';
|
|
|
200
200
|
import 'prosemirror-state';
|
|
201
201
|
import 'prosemirror-commands';
|
|
202
202
|
import 'lodash/keyBy';
|
|
203
|
-
import './OrSelectMultipleControl-
|
|
203
|
+
import './OrSelectMultipleControl-e891fad1.js';
|
|
204
204
|
import './OrSelectPlaceholder-f36f4e40.js';
|
|
205
205
|
import './OrSelectControlInput-28c226f8.js';
|
|
206
206
|
import './OrSelectSingleControl-76b29e0b.js';
|
|
@@ -3,9 +3,11 @@ import { isRef, ref, watch } from 'vue-demi';
|
|
|
3
3
|
import { r as requestAF } from './dom-aecadd9a.js';
|
|
4
4
|
|
|
5
5
|
function useOverflow(container) {
|
|
6
|
-
let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
7
|
+
const {
|
|
8
|
+
hide = true,
|
|
9
|
+
threshold = 0
|
|
10
|
+
} = options;
|
|
9
11
|
const containerRef = isRef(container) ? container : ref(container);
|
|
10
12
|
// State
|
|
11
13
|
const innerItemsRef = ref([]);
|
|
@@ -28,8 +30,8 @@ function useOverflow(container) {
|
|
|
28
30
|
x: containerOffset,
|
|
29
31
|
width: containerWidth
|
|
30
32
|
} = container.getBoundingClientRect();
|
|
31
|
-
if (itemOffset + itemWidth > containerOffset + containerWidth) {
|
|
32
|
-
if (
|
|
33
|
+
if (itemOffset + itemWidth > containerOffset + containerWidth + threshold) {
|
|
34
|
+
if (hide) {
|
|
33
35
|
item.style.setProperty('visibility', 'hidden');
|
|
34
36
|
}
|
|
35
37
|
return {
|
|
@@ -37,7 +39,7 @@ function useOverflow(container) {
|
|
|
37
39
|
outerItems: [...outerItems, item]
|
|
38
40
|
};
|
|
39
41
|
} else {
|
|
40
|
-
if (
|
|
42
|
+
if (hide) {
|
|
41
43
|
item.style.removeProperty('visibility');
|
|
42
44
|
}
|
|
43
45
|
return {
|
|
@@ -17,8 +17,8 @@ import { s as script$9 } from './OrInput-0db1e05f.js';
|
|
|
17
17
|
import { s as script$b } from './OrLabel-b826da04.js';
|
|
18
18
|
import { s as script$c } from './OrMenuItem-fdc66517.js';
|
|
19
19
|
import { s as script$d } from './OrPopover-3b07d49e.js';
|
|
20
|
-
import { T as TagsOverflow } from './OrTags-
|
|
21
|
-
import { s as script$1 } from './OrSelectMultipleControl-
|
|
20
|
+
import { T as TagsOverflow } from './OrTags-ba8ef261.js';
|
|
21
|
+
import { s as script$1 } from './OrSelectMultipleControl-64bb859f.js';
|
|
22
22
|
import { s as script$2 } from './OrSelectSingleControl-f969c913.js';
|
|
23
23
|
import './OrSelectPlaceholder-10e3bf5e.js';
|
|
24
24
|
import { resolveComponent, resolveDirective, openBlock, createElementBlock, normalizeClass, createBlock, withCtx, renderSlot, createTextVNode, toDisplayString, createCommentVNode, withDirectives, createElementVNode, withModifiers, createVNode, Fragment, renderList, vShow } from 'vue';
|
|
@@ -455,10 +455,11 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
455
455
|
modelValue: _ctx.searchText,
|
|
456
456
|
"onUpdate:modelValue": _cache[1] || (_cache[1] = $event => _ctx.searchText = $event),
|
|
457
457
|
model: _ctx.proxyModelValue,
|
|
458
|
+
disabled: _ctx.disabled,
|
|
458
459
|
options: _ctx.options,
|
|
459
460
|
placeholder: _ctx.placeholder,
|
|
460
461
|
"enable-search": _ctx.enableSearch
|
|
461
|
-
}, null, 8 /* PROPS */, ["modelValue", "model", "options", "placeholder", "enable-search"]))])], 42 /* CLASS, PROPS, HYDRATE_EVENTS */, _hoisted_1), createElementVNode("div", _hoisted_2, [_ctx.showClear ? (openBlock(), createBlock(_component_OrIconButton, {
|
|
462
|
+
}, null, 8 /* PROPS */, ["modelValue", "model", "disabled", "options", "placeholder", "enable-search"]))])], 42 /* CLASS, PROPS, HYDRATE_EVENTS */, _hoisted_1), createElementVNode("div", _hoisted_2, [_ctx.showClear ? (openBlock(), createBlock(_component_OrIconButton, {
|
|
462
463
|
key: 0,
|
|
463
464
|
icon: 'close',
|
|
464
465
|
color: 'inherit',
|
package/dist/esm/v3/{OrSelectMultipleControl-3620b234.js → OrSelectMultipleControl-64bb859f.js}
RENAMED
|
@@ -4,7 +4,7 @@ import './dom-aecadd9a.js';
|
|
|
4
4
|
import { u as useProxyModelValue } from './useProxyModelValue-940010d2.js';
|
|
5
5
|
import '@onereach/styles/tailwind/plugins/core';
|
|
6
6
|
import '@onereach/styles/tailwind.config.json';
|
|
7
|
-
import { s as script$3, T as TagsOverflow } from './OrTags-
|
|
7
|
+
import { s as script$3, T as TagsOverflow } from './OrTags-ba8ef261.js';
|
|
8
8
|
import { s as script$1 } from './OrSelectPlaceholder-10e3bf5e.js';
|
|
9
9
|
import { i as isEmptyValue } from './isEmptyValue-fd56a6e4.js';
|
|
10
10
|
import { s as script$2 } from './OrSelectControlInput-3297e30d.js';
|
|
@@ -11,7 +11,7 @@ import { s as script$2 } from './OrHint-55d3de35.js';
|
|
|
11
11
|
import { s as script$3 } from './OrIconButton-c89f733b.js';
|
|
12
12
|
import { s as script$4 } from './OrInputBox-912a6254.js';
|
|
13
13
|
import { s as script$5 } from './OrLabel-b826da04.js';
|
|
14
|
-
import { s as script$6, T as TagsOverflow } from './OrTags-
|
|
14
|
+
import { s as script$6, T as TagsOverflow } from './OrTags-ba8ef261.js';
|
|
15
15
|
import { resolveComponent, openBlock, createElementBlock, normalizeClass, createBlock, withCtx, renderSlot, createTextVNode, toDisplayString, createCommentVNode, createVNode, createSlots, createElementVNode, withDirectives, mergeProps, withKeys, vModelDynamic, vShow } from 'vue';
|
|
16
16
|
import { s as styleInject } from './style-inject.es-4c6f2515.js';
|
|
17
17
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent, ref, toRefs, computed, nextTick } from 'vue-demi';
|
|
2
|
-
import { u as useOverflow } from './useOverflow-
|
|
2
|
+
import { u as useOverflow } from './useOverflow-e91d2314.js';
|
|
3
3
|
import '@vueuse/core';
|
|
4
4
|
import '@onereach/styles/tailwind/plugins/core';
|
|
5
5
|
import '@onereach/styles/tailwind.config.json';
|
|
@@ -130,7 +130,8 @@ var script = defineComponent({
|
|
|
130
130
|
const {
|
|
131
131
|
innerItems
|
|
132
132
|
} = useOverflow(container, {
|
|
133
|
-
hide: false
|
|
133
|
+
hide: false,
|
|
134
|
+
threshold: 8
|
|
134
135
|
});
|
|
135
136
|
const localItems = computed(() => {
|
|
136
137
|
return items.value.map(castToTagObject);
|
|
@@ -90,7 +90,7 @@ export { s as OrSearch } from '../OrSearch-2800e9bf.js';
|
|
|
90
90
|
export { s as OrSearchV3 } from '../OrSearch-602356a0.js';
|
|
91
91
|
export { s as OrSegmentedControlV3, S as SegmentedControlSize } from '../OrSegmentedControl-6be79b4e.js';
|
|
92
92
|
export { s as OrSelect } from '../OrSelect-9520d6e6.js';
|
|
93
|
-
export { s as OrSelectV3 } from '../OrSelect-
|
|
93
|
+
export { s as OrSelectV3 } from '../OrSelect-31442785.js';
|
|
94
94
|
export { s as OrSidebar, O as OrSidebarSide } from '../OrSidebar-aaf73310.js';
|
|
95
95
|
export { s as OrSidebarV3 } from '../OrSidebar-459ec28f.js';
|
|
96
96
|
export { S as OrSidebarPlacement, S as SidebarPlacement } from '../props-64389534.js';
|
|
@@ -112,9 +112,9 @@ export { s as OrTabV3 } from '../OrTab-db771526.js';
|
|
|
112
112
|
export { s as OrTabs } from '../OrTabs-3da3ea89.js';
|
|
113
113
|
export { s as OrTabsV3, T as TabsVariant } from '../OrTabs-f1773b57.js';
|
|
114
114
|
export { s as OrTag } from '../OrTag-1b3b1296.js';
|
|
115
|
-
export { s as OrTagInputV3 } from '../OrTagInput-
|
|
115
|
+
export { s as OrTagInputV3 } from '../OrTagInput-d018033c.js';
|
|
116
116
|
export { s as OrTagV3, a as TagColor, T as TagVariant } from '../OrTag-32739999.js';
|
|
117
|
-
export { s as OrTagsV3, T as TagsOverflow } from '../OrTags-
|
|
117
|
+
export { s as OrTagsV3, T as TagsOverflow } from '../OrTags-ba8ef261.js';
|
|
118
118
|
export { s as OrTeleport } from '../OrTeleport.vue3-9bce0c02.js';
|
|
119
119
|
export { s as OrTeleportV3 } from '../OrTeleport.vue3-8099178c.js';
|
|
120
120
|
export { s as OrTextV3 } from '../OrText-d54c951d.js';
|
|
@@ -191,11 +191,11 @@ import '../codemirrorView-020fe885.js';
|
|
|
191
191
|
import 'prosemirror-state';
|
|
192
192
|
import 'prosemirror-commands';
|
|
193
193
|
import 'lodash/keyBy';
|
|
194
|
-
import '../OrSelectMultipleControl-
|
|
194
|
+
import '../OrSelectMultipleControl-64bb859f.js';
|
|
195
195
|
import '../OrSelectPlaceholder-10e3bf5e.js';
|
|
196
196
|
import '../OrSelectControlInput-3297e30d.js';
|
|
197
197
|
import '../OrSelectSingleControl-f969c913.js';
|
|
198
198
|
import 'lodash/range';
|
|
199
199
|
import '../styles-ed564e39.js';
|
|
200
|
-
import '../useOverflow-
|
|
200
|
+
import '../useOverflow-e91d2314.js';
|
|
201
201
|
import 'lodash/isNil';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { s as OrSelectV3 } from '../../OrSelect-
|
|
1
|
+
export { s as OrSelectV3 } from '../../OrSelect-31442785.js';
|
|
2
2
|
export { I as SelectSize } from '../../OrInputBox-912a6254.js';
|
|
3
3
|
import 'vue-demi';
|
|
4
4
|
import '../../dropdown-open-06d651cf.js';
|
|
@@ -34,11 +34,11 @@ import '../../OrInput-0db1e05f.js';
|
|
|
34
34
|
import '../../useValidationAttributes-d1abbe34.js';
|
|
35
35
|
import '../../OrLoader-b79022da.js';
|
|
36
36
|
import '../../OrMenuItem-fdc66517.js';
|
|
37
|
-
import '../../OrTags-
|
|
38
|
-
import '../../useOverflow-
|
|
37
|
+
import '../../OrTags-ba8ef261.js';
|
|
38
|
+
import '../../useOverflow-e91d2314.js';
|
|
39
39
|
import '../../OrButton-2e3a73fb.js';
|
|
40
40
|
import '../../OrTag-32739999.js';
|
|
41
|
-
import '../../OrSelectMultipleControl-
|
|
41
|
+
import '../../OrSelectMultipleControl-64bb859f.js';
|
|
42
42
|
import '../../OrSelectPlaceholder-10e3bf5e.js';
|
|
43
43
|
import '../../OrSelectControlInput-3297e30d.js';
|
|
44
44
|
import '../../OrSelectSingleControl-f969c913.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { s as OrSelectMultipleControl } from '../../../OrSelectMultipleControl-
|
|
1
|
+
export { s as OrSelectMultipleControl } from '../../../OrSelectMultipleControl-64bb859f.js';
|
|
2
2
|
export { s as OrSelectSingleControl } from '../../../OrSelectSingleControl-f969c913.js';
|
|
3
3
|
export { s as OrSelectPlaceholder } from '../../../OrSelectPlaceholder-10e3bf5e.js';
|
|
4
4
|
import 'vue-demi';
|
|
@@ -9,8 +9,8 @@ import 'lodash/get';
|
|
|
9
9
|
import '../../../useProxyModelValue-940010d2.js';
|
|
10
10
|
import '@onereach/styles/tailwind/plugins/core';
|
|
11
11
|
import '@onereach/styles/tailwind.config.json';
|
|
12
|
-
import '../../../OrTags-
|
|
13
|
-
import '../../../useOverflow-
|
|
12
|
+
import '../../../OrTags-ba8ef261.js';
|
|
13
|
+
import '../../../useOverflow-e91d2314.js';
|
|
14
14
|
import '../../../OrButton-2e3a73fb.js';
|
|
15
15
|
import '../../../OrLoader-b79022da.js';
|
|
16
16
|
import 'vue';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { s as OrSelectMultipleControl } from '../../../../OrSelectMultipleControl-
|
|
1
|
+
export { s as OrSelectMultipleControl } from '../../../../OrSelectMultipleControl-64bb859f.js';
|
|
2
2
|
import 'vue-demi';
|
|
3
3
|
import '@vueuse/core';
|
|
4
4
|
import '../../../../dom-aecadd9a.js';
|
|
@@ -7,8 +7,8 @@ import 'lodash/get';
|
|
|
7
7
|
import '../../../../useProxyModelValue-940010d2.js';
|
|
8
8
|
import '@onereach/styles/tailwind/plugins/core';
|
|
9
9
|
import '@onereach/styles/tailwind.config.json';
|
|
10
|
-
import '../../../../OrTags-
|
|
11
|
-
import '../../../../useOverflow-
|
|
10
|
+
import '../../../../OrTags-ba8ef261.js';
|
|
11
|
+
import '../../../../useOverflow-e91d2314.js';
|
|
12
12
|
import '../../../../OrButton-2e3a73fb.js';
|
|
13
13
|
import '../../../../OrLoader-b79022da.js';
|
|
14
14
|
import 'vue';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { s as OrTagInputV3 } from '../../OrTagInput-
|
|
1
|
+
export { s as OrTagInputV3 } from '../../OrTagInput-d018033c.js';
|
|
2
2
|
export { I as TagInputSize } from '../../OrInputBox-912a6254.js';
|
|
3
3
|
import 'vue-demi';
|
|
4
4
|
import '@vueuse/core';
|
|
@@ -26,8 +26,8 @@ import '../../OrOverlay-6269c33a.js';
|
|
|
26
26
|
import '../../OrTeleport.vue3-8099178c.js';
|
|
27
27
|
import '../../useTheme-0ef25778.js';
|
|
28
28
|
import '../../OrLabel-b826da04.js';
|
|
29
|
-
import '../../OrTags-
|
|
30
|
-
import '../../useOverflow-
|
|
29
|
+
import '../../OrTags-ba8ef261.js';
|
|
30
|
+
import '../../useOverflow-e91d2314.js';
|
|
31
31
|
import '../../OrButton-2e3a73fb.js';
|
|
32
32
|
import '../../OrLoader-b79022da.js';
|
|
33
33
|
import '../../OrTag-32739999.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { s as OrTagsV3, T as TagsOverflow } from '../../OrTags-
|
|
1
|
+
export { s as OrTagsV3, T as TagsOverflow } from '../../OrTags-ba8ef261.js';
|
|
2
2
|
import 'vue-demi';
|
|
3
|
-
import '../../useOverflow-
|
|
3
|
+
import '../../useOverflow-e91d2314.js';
|
|
4
4
|
import '@vueuse/core';
|
|
5
5
|
import '../../dom-aecadd9a.js';
|
|
6
6
|
import 'lodash/isElement';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export { u as useControlAttributes, a as useIdAttribute } from '../useIdAttribute-859439f0.js';
|
|
2
2
|
export { u as useElevation } from '../useElevation-a50ec347.js';
|
|
3
|
-
export { u as useOverflow } from '../useOverflow-
|
|
3
|
+
export { u as useOverflow } from '../useOverflow-e91d2314.js';
|
|
4
4
|
export { u as usePopoverState } from '../usePopoverState-b92c698b.js';
|
|
5
5
|
export { u as useProxyModelValue } from '../useProxyModelValue-940010d2.js';
|
|
6
6
|
export { u as useResponsive } from '../useResponsive-5c8291da.js';
|
package/dist/esm/v3/index.js
CHANGED
|
@@ -90,7 +90,7 @@ export { s as OrSearch } from './OrSearch-2800e9bf.js';
|
|
|
90
90
|
export { s as OrSearchV3 } from './OrSearch-602356a0.js';
|
|
91
91
|
export { s as OrSegmentedControlV3, S as SegmentedControlSize } from './OrSegmentedControl-6be79b4e.js';
|
|
92
92
|
export { s as OrSelect } from './OrSelect-9520d6e6.js';
|
|
93
|
-
export { s as OrSelectV3 } from './OrSelect-
|
|
93
|
+
export { s as OrSelectV3 } from './OrSelect-31442785.js';
|
|
94
94
|
export { s as OrSidebar, O as OrSidebarSide } from './OrSidebar-aaf73310.js';
|
|
95
95
|
export { s as OrSidebarV3 } from './OrSidebar-459ec28f.js';
|
|
96
96
|
export { S as OrSidebarPlacement, S as SidebarPlacement } from './props-64389534.js';
|
|
@@ -112,9 +112,9 @@ export { s as OrTabV3 } from './OrTab-db771526.js';
|
|
|
112
112
|
export { s as OrTabs } from './OrTabs-3da3ea89.js';
|
|
113
113
|
export { s as OrTabsV3, T as TabsVariant } from './OrTabs-f1773b57.js';
|
|
114
114
|
export { s as OrTag } from './OrTag-1b3b1296.js';
|
|
115
|
-
export { s as OrTagInputV3 } from './OrTagInput-
|
|
115
|
+
export { s as OrTagInputV3 } from './OrTagInput-d018033c.js';
|
|
116
116
|
export { s as OrTagV3, a as TagColor, T as TagVariant } from './OrTag-32739999.js';
|
|
117
|
-
export { s as OrTagsV3, T as TagsOverflow } from './OrTags-
|
|
117
|
+
export { s as OrTagsV3, T as TagsOverflow } from './OrTags-ba8ef261.js';
|
|
118
118
|
export { s as OrTeleport } from './OrTeleport.vue3-9bce0c02.js';
|
|
119
119
|
export { s as OrTeleportV3 } from './OrTeleport.vue3-8099178c.js';
|
|
120
120
|
export { s as OrTextV3 } from './OrText-d54c951d.js';
|
|
@@ -134,7 +134,7 @@ export { s as OrTreeV3, T as TreeNodeDropPosition } from './OrTree-938aab61.js';
|
|
|
134
134
|
export { D as DropdownClose, a as DropdownOpen } from './dropdown-open-06d651cf.js';
|
|
135
135
|
export { u as useControlAttributes, a as useIdAttribute } from './useIdAttribute-859439f0.js';
|
|
136
136
|
export { u as useElevation } from './useElevation-a50ec347.js';
|
|
137
|
-
export { u as useOverflow } from './useOverflow-
|
|
137
|
+
export { u as useOverflow } from './useOverflow-e91d2314.js';
|
|
138
138
|
export { u as usePopoverState } from './usePopoverState-b92c698b.js';
|
|
139
139
|
export { u as useProxyModelValue } from './useProxyModelValue-940010d2.js';
|
|
140
140
|
export { u as useResponsive } from './useResponsive-5c8291da.js';
|
|
@@ -192,7 +192,7 @@ import './codemirrorView-020fe885.js';
|
|
|
192
192
|
import 'prosemirror-state';
|
|
193
193
|
import 'prosemirror-commands';
|
|
194
194
|
import 'lodash/keyBy';
|
|
195
|
-
import './OrSelectMultipleControl-
|
|
195
|
+
import './OrSelectMultipleControl-64bb859f.js';
|
|
196
196
|
import './OrSelectPlaceholder-10e3bf5e.js';
|
|
197
197
|
import './OrSelectControlInput-3297e30d.js';
|
|
198
198
|
import './OrSelectSingleControl-f969c913.js';
|
|
@@ -3,9 +3,11 @@ import { isRef, ref, watch } from 'vue-demi';
|
|
|
3
3
|
import { r as requestAF } from './dom-aecadd9a.js';
|
|
4
4
|
|
|
5
5
|
function useOverflow(container) {
|
|
6
|
-
let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
7
|
+
const {
|
|
8
|
+
hide = true,
|
|
9
|
+
threshold = 0
|
|
10
|
+
} = options;
|
|
9
11
|
const containerRef = isRef(container) ? container : ref(container);
|
|
10
12
|
// State
|
|
11
13
|
const innerItemsRef = ref([]);
|
|
@@ -28,8 +30,8 @@ function useOverflow(container) {
|
|
|
28
30
|
x: containerOffset,
|
|
29
31
|
width: containerWidth
|
|
30
32
|
} = container.getBoundingClientRect();
|
|
31
|
-
if (itemOffset + itemWidth > containerOffset + containerWidth) {
|
|
32
|
-
if (
|
|
33
|
+
if (itemOffset + itemWidth > containerOffset + containerWidth + threshold) {
|
|
34
|
+
if (hide) {
|
|
33
35
|
item.style.setProperty('visibility', 'hidden');
|
|
34
36
|
}
|
|
35
37
|
return {
|
|
@@ -37,7 +39,7 @@ function useOverflow(container) {
|
|
|
37
39
|
outerItems: [...outerItems, item]
|
|
38
40
|
};
|
|
39
41
|
} else {
|
|
40
|
-
if (
|
|
42
|
+
if (hide) {
|
|
41
43
|
item.style.removeProperty('visibility');
|
|
42
44
|
}
|
|
43
45
|
return {
|
package/package.json
CHANGED
|
@@ -156,7 +156,10 @@ export default defineComponent({
|
|
|
156
156
|
]);
|
|
157
157
|
|
|
158
158
|
// State
|
|
159
|
-
const { innerItems } = useOverflow(container, {
|
|
159
|
+
const { innerItems } = useOverflow(container, {
|
|
160
|
+
hide: false,
|
|
161
|
+
threshold: 8,
|
|
162
|
+
});
|
|
160
163
|
|
|
161
164
|
const localItems = computed(() => {
|
|
162
165
|
return items.value.map(castToTagObject);
|
package/src/hooks/useOverflow.ts
CHANGED
|
@@ -9,11 +9,13 @@ export interface Overflow {
|
|
|
9
9
|
|
|
10
10
|
export interface UseOverflowOptions {
|
|
11
11
|
hide?: boolean;
|
|
12
|
+
threshold?: number;
|
|
12
13
|
}
|
|
13
14
|
export function useOverflow(
|
|
14
15
|
container: MaybeElementRef<HTMLElement | undefined>,
|
|
15
|
-
options: UseOverflowOptions = {
|
|
16
|
+
options: UseOverflowOptions = {},
|
|
16
17
|
): Overflow {
|
|
18
|
+
const { hide = true, threshold = 0 } = options;
|
|
17
19
|
const containerRef = isRef(container) ? container : ref(container);
|
|
18
20
|
|
|
19
21
|
// State
|
|
@@ -31,8 +33,8 @@ export function useOverflow(
|
|
|
31
33
|
const { x: itemOffset, width: itemWidth } = item.getBoundingClientRect();
|
|
32
34
|
const { x: containerOffset, width: containerWidth } = container.getBoundingClientRect();
|
|
33
35
|
|
|
34
|
-
if (itemOffset + itemWidth > containerOffset + containerWidth) {
|
|
35
|
-
if (
|
|
36
|
+
if (itemOffset + itemWidth > containerOffset + containerWidth + threshold) {
|
|
37
|
+
if (hide) {
|
|
36
38
|
item.style.setProperty('visibility', 'hidden');
|
|
37
39
|
}
|
|
38
40
|
|
|
@@ -41,7 +43,7 @@ export function useOverflow(
|
|
|
41
43
|
outerItems: [...outerItems, item],
|
|
42
44
|
};
|
|
43
45
|
} else {
|
|
44
|
-
if (
|
|
46
|
+
if (hide) {
|
|
45
47
|
item.style.removeProperty('visibility');
|
|
46
48
|
}
|
|
47
49
|
|