@onereach/ui-components 4.15.3-beta.3053.0 → 4.15.3-beta.3054.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/OrInputV3/OrInput.js +2 -2
- package/dist/bundled/v2/components/OrSelectV3/OrSelect.js +33 -9
- package/dist/bundled/v2/components/OrSelectV3/OrSelect.vue.d.ts +2 -0
- package/dist/bundled/v2/components/OrSelectV3/styles.js +3 -3
- package/dist/bundled/v2/index.js +1 -1
- package/dist/bundled/v3/{OrSelect.vue_vue_type_script_lang-c70d3f4e.js → OrSelect.vue_vue_type_script_lang-674b6c3c.js} +8 -2
- package/dist/bundled/v3/components/OrSelectV3/OrSelect.js +30 -19
- package/dist/bundled/v3/components/OrSelectV3/OrSelect.vue.d.ts +1 -0
- package/dist/bundled/v3/components/OrSelectV3/index.js +1 -1
- package/dist/bundled/v3/components/OrSelectV3/styles.js +3 -3
- package/dist/bundled/v3/components/index.js +1 -1
- package/dist/bundled/v3/index.js +2 -2
- package/dist/esm/v2/{OrCardCollection-57e72b98.js → OrCardCollection-2c2712de.js} +1 -1
- package/dist/esm/v2/{OrConfirm-b6046cee.js → OrConfirm-c58778e3.js} +1 -1
- package/dist/esm/v2/{OrInput-e3154a47.js → OrInput-b151c894.js} +2 -2
- package/dist/esm/v2/{OrSearch-07d9774c.js → OrSearch-fb882165.js} +1 -1
- package/dist/esm/v2/{OrSelect-5b9b51e3.js → OrSelect-4101dab8.js} +37 -12
- package/dist/esm/v2/components/index.js +5 -5
- package/dist/esm/v2/components/or-card-collection-v3/index.js +3 -3
- package/dist/esm/v2/components/or-confirm-v3/index.js +2 -2
- package/dist/esm/v2/components/or-input-v3/index.js +1 -1
- package/dist/esm/v2/components/or-search-v3/index.js +2 -2
- package/dist/esm/v2/components/or-select-v3/OrSelect.vue.d.ts +2 -0
- package/dist/esm/v2/components/or-select-v3/index.js +3 -3
- package/dist/esm/v2/index.js +5 -5
- package/dist/esm/v3/{OrSelect-97cccfd0.js → OrSelect-da62ab4e.js} +39 -22
- package/dist/esm/v3/components/index.js +1 -1
- package/dist/esm/v3/components/or-select-v3/OrSelect.vue.d.ts +1 -0
- package/dist/esm/v3/components/or-select-v3/index.js +2 -2
- package/dist/esm/v3/index.js +1 -1
- package/package.json +1 -1
- package/src/components/or-input-v3/OrInput.vue +1 -0
- package/src/components/or-select-v3/OrSelect.vue +30 -5
- package/src/components/or-select-v3/styles.ts +4 -4
|
@@ -166,7 +166,7 @@ var script = defineComponent({
|
|
|
166
166
|
}
|
|
167
167
|
});
|
|
168
168
|
|
|
169
|
-
var css_248z = "input[data-v-
|
|
169
|
+
var css_248z = "input[data-v-fea72d76]{min-width:0;background:0 0;outline:0}input[type=number][data-v-fea72d76]::-webkit-inner-spin-button{display:none}input[type=search][data-v-fea72d76]::-webkit-search-cancel-button{display:none}";
|
|
170
170
|
styleInject(css_248z);
|
|
171
171
|
|
|
172
172
|
/* script */
|
|
@@ -426,7 +426,7 @@ var __vue_staticRenderFns__ = [];
|
|
|
426
426
|
/* style */
|
|
427
427
|
const __vue_inject_styles__ = undefined;
|
|
428
428
|
/* scoped */
|
|
429
|
-
const __vue_scope_id__ = "data-v-
|
|
429
|
+
const __vue_scope_id__ = "data-v-fea72d76";
|
|
430
430
|
/* module identifier */
|
|
431
431
|
const __vue_module_identifier__ = undefined;
|
|
432
432
|
/* functional template */
|
|
@@ -18,6 +18,7 @@ import { DropdownClose } from '../../directives/dropdown-close.js';
|
|
|
18
18
|
import { DropdownOpen } from '../../directives/dropdown-open.js';
|
|
19
19
|
import { InputBoxSize } from '../OrInputBoxV3/props.js';
|
|
20
20
|
import { useProxyModelValue } from '../../hooks/useProxyModelValue.js';
|
|
21
|
+
import useResponsive from '../../hooks/useResponsive/useResponsive.js';
|
|
21
22
|
import { n as normalizeComponent } from '../../normalize-component-6e8e3d80.js';
|
|
22
23
|
import '../OrCheckboxV3/styles.js';
|
|
23
24
|
import '../OrLabelV3/props.js';
|
|
@@ -44,7 +45,6 @@ import '../../index-760079e7.js';
|
|
|
44
45
|
import '../OrLoaderV3/props.js';
|
|
45
46
|
import '../OrLoaderV3/styles.js';
|
|
46
47
|
import '../../hooks/useValidationAttributes.js';
|
|
47
|
-
import '../../hooks/useResponsive/useResponsive.js';
|
|
48
48
|
import '../OrInputBoxV3/styles.js';
|
|
49
49
|
import '../OrLabelV3/styles.js';
|
|
50
50
|
import '../OrMenuItemV3/styles.js';
|
|
@@ -206,7 +206,7 @@ var script = defineComponent({
|
|
|
206
206
|
const selection = computed(() => {
|
|
207
207
|
const modelValue = proxyModelValue.value;
|
|
208
208
|
if (Array.isArray(modelValue)) {
|
|
209
|
-
return modelValue.map(value => props.options.find(option => option.value === value));
|
|
209
|
+
return modelValue.map(value => props.options.find(option => option.value === value)).filter(value => !!value);
|
|
210
210
|
}
|
|
211
211
|
return props.options.find(option => option.value === modelValue);
|
|
212
212
|
});
|
|
@@ -270,6 +270,10 @@ var script = defineComponent({
|
|
|
270
270
|
innerItems,
|
|
271
271
|
outerItems
|
|
272
272
|
} = useOverflow(control);
|
|
273
|
+
// Utils
|
|
274
|
+
const {
|
|
275
|
+
isMobile
|
|
276
|
+
} = useResponsive();
|
|
273
277
|
return {
|
|
274
278
|
root,
|
|
275
279
|
inputBox,
|
|
@@ -297,7 +301,8 @@ var script = defineComponent({
|
|
|
297
301
|
close,
|
|
298
302
|
deselect,
|
|
299
303
|
innerItems,
|
|
300
|
-
outerItems
|
|
304
|
+
outerItems,
|
|
305
|
+
isMobile
|
|
301
306
|
};
|
|
302
307
|
}
|
|
303
308
|
});
|
|
@@ -402,16 +407,22 @@ var __vue_render__ = function () {
|
|
|
402
407
|
}, {
|
|
403
408
|
"model": _vm.proxyModelValue
|
|
404
409
|
})] : [_c('span', {
|
|
405
|
-
class: _vm.placeholderStyles
|
|
406
|
-
|
|
410
|
+
class: _vm.placeholderStyles,
|
|
411
|
+
attrs: {
|
|
412
|
+
"disabled": _vm.disabled ? '' : null
|
|
413
|
+
}
|
|
414
|
+
}, [_vm._v("\n " + _vm._s(_vm.placeholder) + "\n ")])]] : [!_vm.isEmptyModelValue ? [_vm._t("valueTemplate", function () {
|
|
407
415
|
return [_c('span', {
|
|
408
416
|
staticClass: "truncate"
|
|
409
|
-
}, [_vm._v("\n " + _vm._s(_vm.selection.label) + "\n ")])];
|
|
417
|
+
}, [_vm._v("\n " + _vm._s(_vm.selection && _vm.selection.label) + "\n ")])];
|
|
410
418
|
}, {
|
|
411
419
|
"model": _vm.proxyModelValue
|
|
412
420
|
})] : [_c('span', {
|
|
413
|
-
class: _vm.placeholderStyles
|
|
414
|
-
|
|
421
|
+
class: _vm.placeholderStyles,
|
|
422
|
+
attrs: {
|
|
423
|
+
"disabled": _vm.disabled ? '' : null
|
|
424
|
+
}
|
|
425
|
+
}, [_vm._v("\n " + _vm._s(_vm.placeholder) + "\n ")])]]], 2), _vm._v(" "), _vm.multiple && _vm.outerItems.length > 0 ? [_vm._v("\n +" + _vm._s(_vm.outerItems.length) + "\n ")] : _vm._e(), _vm._v(" "), _c('div', {
|
|
415
426
|
class: ['layout-inline-row', 'gap-sm']
|
|
416
427
|
}, [!_vm.multiple && _vm.proxyModelValue ? [_c('OrIconButton', {
|
|
417
428
|
attrs: {
|
|
@@ -440,7 +451,20 @@ var __vue_render__ = function () {
|
|
|
440
451
|
"custom-styles": _vm.dropdownStyles,
|
|
441
452
|
"disable-default-styles": true
|
|
442
453
|
}
|
|
443
|
-
}, [_vm.
|
|
454
|
+
}, [_vm.isMobile ? [_c('OrInput', {
|
|
455
|
+
class: _vm.searchControlStyles,
|
|
456
|
+
attrs: {
|
|
457
|
+
"type": 'search',
|
|
458
|
+
"placeholder": 'Search'
|
|
459
|
+
},
|
|
460
|
+
model: {
|
|
461
|
+
value: _vm.searchText,
|
|
462
|
+
callback: function ($$v) {
|
|
463
|
+
_vm.searchText = $$v;
|
|
464
|
+
},
|
|
465
|
+
expression: "searchText"
|
|
466
|
+
}
|
|
467
|
+
})] : _vm._e(), _vm._v(" "), _vm.resolvedSearchOptions.length > 0 ? [_vm.groupByFunction ? _vm._l(_vm.groupedOptions, function (group, groupName) {
|
|
444
468
|
return _c('OrExpansionPanel', {
|
|
445
469
|
key: groupName,
|
|
446
470
|
attrs: {
|
|
@@ -40,6 +40,7 @@ declare const _default: import("vue").ComponentOptions<import("vue").default, im
|
|
|
40
40
|
deselect: (option: SelectOption) => void;
|
|
41
41
|
innerItems: import("@vue/composition-api").Ref<HTMLElement[]>;
|
|
42
42
|
outerItems: import("@vue/composition-api").Ref<HTMLElement[]>;
|
|
43
|
+
isMobile: import("@vue/composition-api").Ref<boolean>;
|
|
43
44
|
}> & import("@vue/composition-api").Data, {}, {}, {
|
|
44
45
|
options: {
|
|
45
46
|
type: PropType<SelectOption[]>;
|
|
@@ -228,6 +229,7 @@ declare const _default: import("vue").ComponentOptions<import("vue").default, im
|
|
|
228
229
|
deselect: (option: SelectOption) => void;
|
|
229
230
|
innerItems: import("@vue/composition-api").Ref<HTMLElement[]>;
|
|
230
231
|
outerItems: import("@vue/composition-api").Ref<HTMLElement[]>;
|
|
232
|
+
isMobile: import("@vue/composition-api").Ref<boolean>;
|
|
231
233
|
}>, import("@vue/composition-api").Data, {}, {}, {}, {}, string[], {
|
|
232
234
|
modelValue: string | number | object | string[] | object[] | number[];
|
|
233
235
|
label: string;
|
|
@@ -15,10 +15,10 @@ const SelectControl = [
|
|
|
15
15
|
// Typography
|
|
16
16
|
'typography-inherit'];
|
|
17
17
|
const SelectSearchControl = [
|
|
18
|
-
//
|
|
19
|
-
'
|
|
18
|
+
// Layout
|
|
19
|
+
'grow',
|
|
20
20
|
// Spacing
|
|
21
|
-
'!mx-none', '!my-none'];
|
|
21
|
+
'!mx-lg md:!mx-none', '!my-sm md:!my-none'];
|
|
22
22
|
const SelectPlaceholder = [
|
|
23
23
|
// Theme
|
|
24
24
|
'theme-foreground-outline', 'dark:theme-foreground-outline-dark',
|