@onereach/ui-components 2.71.2-beta.2241.0 → 2.71.2
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/{OrCardCollection-c1ccde63.js → OrCardCollection-091e2193.js} +1 -1
- package/dist/bundled/v2/{OrCardCollection-89428bbf.js → OrCardCollection-166cfcc6.js} +5 -5
- package/dist/bundled/v2/{OrConfirm-56d01cff.js → OrConfirm-55b89b17.js} +4 -4
- package/dist/bundled/v2/{OrConfirm-cc8b767f.js → OrConfirm-bb2df177.js} +1 -1
- package/dist/bundled/v2/{OrInput-c539e47c.js → OrInput-5404a234.js} +6 -23
- package/dist/bundled/v2/{OrListOfInputs-8f076650.js → OrListOfInputs-ab7f9d97.js} +4 -4
- package/dist/bundled/v2/OrNumberInput-face8ccc.js +227 -0
- package/dist/bundled/v2/OrPassword-a818e7b5.js +227 -0
- package/dist/bundled/v2/{OrSearch-f7cfa52f.js → OrSearch-832d7978.js} +4 -4
- package/dist/bundled/v2/{OrSearch-d7326373.js → OrSearch-d1169241.js} +1 -1
- package/dist/bundled/v2/{OrSelect-8802f330.js → OrSelect-5634790b.js} +1 -1
- package/dist/bundled/v2/{OrPassword-7da938aa.js → OrTextarea-71ff236d.js} +7 -449
- package/dist/bundled/v2/components/index.d.ts +5 -1
- package/dist/bundled/v2/components/index.js +15 -13
- package/dist/bundled/v2/components/or-card-collection/index.js +4 -4
- package/dist/bundled/v2/components/or-card-collection-v3/index.js +3 -3
- package/dist/bundled/v2/components/or-confirm/index.js +2 -2
- package/dist/bundled/v2/components/or-confirm-v3/index.js +2 -2
- package/dist/bundled/v2/components/or-input/index.d.ts +1 -0
- package/dist/bundled/v2/components/or-input/index.js +13 -0
- package/dist/bundled/v2/components/or-input-v3/OrInput.vue.d.ts +0 -13
- package/dist/bundled/v2/components/or-input-v3/index.js +1 -2
- package/dist/bundled/v2/components/or-list-of-inputs/index.js +2 -2
- package/dist/bundled/v2/components/or-number-input/index.d.ts +1 -0
- package/dist/bundled/v2/components/or-number-input/index.js +14 -0
- package/dist/bundled/v2/components/or-password/index.d.ts +1 -0
- package/dist/bundled/v2/components/{or-inputs → or-password}/index.js +3 -4
- package/dist/bundled/v2/components/or-search/index.d.ts +1 -0
- package/dist/bundled/v2/components/or-search/index.js +25 -0
- package/dist/bundled/v2/components/or-search-v3/index.js +2 -3
- package/dist/bundled/v2/components/or-select-v3/index.js +2 -3
- package/dist/bundled/v2/components/or-textarea/index.d.ts +1 -0
- package/dist/bundled/v2/components/or-textarea/index.js +13 -0
- package/dist/bundled/v2/index.js +13 -11
- package/dist/bundled/v3/{OrCardCollection.vue_vue_type_script_lang-f9897e01.js → OrCardCollection.vue_vue_type_script_lang-60403ae6.js} +1 -1
- package/dist/bundled/v3/{OrCardCollection.vue_vue_type_script_lang-d8124dda.js → OrCardCollection.vue_vue_type_script_lang-cd84f344.js} +4 -4
- package/dist/bundled/v3/{OrConfirm.vue_vue_type_script_lang-0f16fc67.js → OrConfirm.vue_vue_type_script_lang-41b4d791.js} +2 -1
- package/dist/bundled/v3/{OrConfirm.vue_vue_type_script_lang-e9ba9909.js → OrConfirm.vue_vue_type_script_lang-9231d51e.js} +2 -2
- package/dist/bundled/v3/{OrInput-41f8351a.js → OrInput-2a7c6b57.js} +4 -13
- package/dist/bundled/v3/{OrInput-7d4b571a.js → OrInput-704e72ba.js} +5 -193
- package/dist/bundled/v3/OrInput.vue_vue_type_script_lang-409235cc.js +190 -0
- package/dist/bundled/v3/{OrInput.vue_vue_type_script_lang-b88324b6.js → OrInput.vue_vue_type_script_lang-509de504.js} +1 -13
- package/dist/bundled/v3/{OrListOfInputs.vue_vue_type_script_lang-62dbf1e7.js → OrListOfInputs.vue_vue_type_script_lang-6c5cf7a5.js} +2 -1
- package/dist/bundled/v3/OrNumberInput.vue_vue_type_script_lang-f061d829.js +113 -0
- package/dist/bundled/v3/OrPassword.vue_vue_type_script_lang-b75f6543.js +99 -0
- package/dist/bundled/v3/{OrSearch.vue_vue_type_script_lang-16fbccc0.js → OrSearch.vue_vue_type_script_lang-5356fa79.js} +2 -1
- package/dist/bundled/v3/{OrSearch.vue_vue_type_script_lang-56eb4e93.js → OrSearch.vue_vue_type_script_lang-ab2ef22c.js} +2 -2
- package/dist/bundled/v3/{OrSelect.vue_vue_type_script_lang-ee433d47.js → OrSelect.vue_vue_type_script_lang-54f683a2.js} +2 -2
- package/dist/bundled/v3/OrTextarea.vue_vue_type_script_lang-69ea22e9.js +187 -0
- package/dist/bundled/v3/components/index.d.ts +5 -1
- package/dist/bundled/v3/components/index.js +17 -14
- package/dist/bundled/v3/components/or-card-collection/index.js +5 -4
- package/dist/bundled/v3/components/or-card-collection-v3/index.js +4 -4
- package/dist/bundled/v3/components/or-confirm/index.js +3 -2
- package/dist/bundled/v3/components/or-confirm-v3/index.js +3 -3
- package/dist/bundled/v3/components/or-input/index.d.ts +1 -0
- package/dist/bundled/v3/components/or-input/index.js +14 -0
- package/dist/bundled/v3/components/or-input-v3/OrInput.vue.d.ts +0 -13
- package/dist/bundled/v3/components/or-input-v3/index.js +1 -3
- package/dist/bundled/v3/components/or-list-of-inputs/index.js +3 -2
- package/dist/bundled/v3/components/or-number-input/index.d.ts +1 -0
- package/dist/bundled/v3/components/or-number-input/index.js +16 -0
- package/dist/bundled/v3/components/or-password/index.d.ts +1 -0
- package/dist/bundled/v3/components/or-password/index.js +31 -0
- package/dist/bundled/v3/components/or-search/index.d.ts +1 -0
- package/dist/bundled/v3/components/{or-inputs → or-search}/index.js +4 -5
- package/dist/bundled/v3/components/or-search-v3/index.js +3 -5
- package/dist/bundled/v3/components/or-select-v3/index.js +3 -5
- package/dist/bundled/v3/components/or-textarea/index.d.ts +1 -0
- package/dist/bundled/v3/components/or-textarea/index.js +14 -0
- package/dist/bundled/v3/index.js +664 -659
- package/dist/esm/v2/{OrCardCollection-f6b07557.js → OrCardCollection-19582949.js} +6 -7
- package/dist/esm/v2/{OrCardCollection-ff1e9819.js → OrCardCollection-bbdb6159.js} +1 -1
- package/dist/esm/v2/{OrConfirm-ec81498e.js → OrConfirm-cfaf4266.js} +1 -1
- package/dist/esm/v2/{OrConfirm-d7112dd3.js → OrConfirm-ede619eb.js} +4 -4
- package/dist/esm/v2/{OrSearch.vue_rollup-plugin-vue_script-197d77fc.js → OrInput-6e6cfd11.js} +4 -492
- package/dist/esm/v2/{OrInput-b029d058.js → OrInput-e8fe9102.js} +6 -23
- package/dist/esm/v2/{OrListOfInputs-50aa1ef1.js → OrListOfInputs-4298fa2c.js} +5 -5
- package/dist/esm/v2/OrNumberInput-b20d75d2.js +225 -0
- package/dist/esm/v2/OrPassword-e6d5e968.js +225 -0
- package/dist/esm/v2/{OrSearch-1c934f72.js → OrSearch-4b774707.js} +1 -1
- package/dist/esm/v2/{OrSearch-0589d17d.js → OrSearch-b4f4d59b.js} +122 -5
- package/dist/esm/v2/{OrSelect-cfcb233a.js → OrSelect-d7016575.js} +1 -1
- package/dist/esm/v2/{OrPassword-1fa97156.js → OrTextarea-91a95068.js} +187 -245
- package/dist/esm/v2/components/index.d.ts +5 -1
- package/dist/esm/v2/components/index.js +15 -13
- package/dist/esm/v2/components/or-card-collection/index.js +3 -4
- package/dist/esm/v2/components/or-card-collection-v3/index.js +3 -3
- package/dist/esm/v2/components/or-confirm/index.js +2 -3
- package/dist/esm/v2/components/or-confirm-v3/index.js +3 -3
- package/dist/esm/v2/components/or-input/index.d.ts +1 -0
- package/dist/esm/v2/components/or-input/index.js +11 -0
- package/dist/esm/v2/components/or-input-v3/OrInput.vue.d.ts +0 -13
- package/dist/esm/v2/components/or-input-v3/index.js +2 -3
- package/dist/esm/v2/components/or-list-of-inputs/index.js +2 -4
- package/dist/esm/v2/components/or-number-input/index.d.ts +1 -0
- package/dist/esm/v2/components/or-number-input/index.js +12 -0
- package/dist/esm/v2/components/or-password/index.d.ts +1 -0
- package/dist/esm/v2/components/{or-inputs → or-password}/index.js +5 -6
- package/dist/esm/v2/components/or-search/index.d.ts +1 -0
- package/dist/esm/v2/components/or-search/index.js +23 -0
- package/dist/esm/v2/components/or-search-v3/index.js +3 -4
- package/dist/esm/v2/components/or-select-v3/index.js +3 -4
- package/dist/esm/v2/components/or-textarea/index.d.ts +1 -0
- package/dist/esm/v2/components/or-textarea/index.js +11 -0
- package/dist/esm/v2/index.js +13 -11
- package/dist/esm/v3/{OrCardCollection-a5e326ef.js → OrCardCollection-1e44c758.js} +2 -2
- package/dist/esm/v3/{OrCardCollection-5ecdcbaf.js → OrCardCollection-47f61c40.js} +1 -1
- package/dist/esm/v3/{OrConfirm-f39bd784.js → OrConfirm-c11ee2ec.js} +1 -1
- package/dist/esm/v3/{OrConfirm-beeb74d6.js → OrConfirm-e7cbf54c.js} +1 -1
- package/dist/esm/v3/{OrInput-8a4573cd.js → OrInput-6fb81556.js} +4 -24
- package/dist/esm/v3/OrInput-81125804.js +295 -0
- package/dist/esm/v3/{OrListOfInputs-7a67440f.js → OrListOfInputs-508e056f.js} +1 -1
- package/dist/esm/v3/OrNumberInput-b32b5ce3.js +170 -0
- package/dist/esm/v3/OrPassword-b0cbb578.js +162 -0
- package/dist/esm/v3/OrSearch-11fdf667.js +188 -0
- package/dist/esm/v3/{OrSearch-10d09806.js → OrSearch-e15955a7.js} +1 -1
- package/dist/esm/v3/{OrSelect-1e4c6062.js → OrSelect-027b5e8f.js} +1 -1
- package/dist/esm/v3/OrTextarea-1f5c3be1.js +290 -0
- package/dist/esm/v3/components/index.d.ts +5 -1
- package/dist/esm/v3/components/index.js +15 -11
- package/dist/esm/v3/components/or-card-collection/index.js +3 -3
- package/dist/esm/v3/components/or-card-collection-v3/index.js +3 -3
- package/dist/esm/v3/components/or-confirm/index.js +2 -3
- package/dist/esm/v3/components/or-confirm-v3/index.js +3 -3
- package/dist/esm/v3/components/or-input/index.d.ts +1 -0
- package/dist/esm/v3/components/or-input/index.js +11 -0
- package/dist/esm/v3/components/or-input-v3/OrInput.vue.d.ts +0 -13
- package/dist/esm/v3/components/or-input-v3/index.js +2 -3
- package/dist/esm/v3/components/or-list-of-inputs/index.js +2 -4
- package/dist/esm/v3/components/or-number-input/index.d.ts +1 -0
- package/dist/esm/v3/components/or-number-input/index.js +12 -0
- package/dist/esm/v3/components/or-password/index.d.ts +1 -0
- package/dist/esm/v3/components/{or-inputs → or-password}/index.js +3 -2
- package/dist/esm/v3/components/or-search/index.d.ts +1 -0
- package/dist/esm/v3/components/or-search/index.js +20 -0
- package/dist/esm/v3/components/or-search-v3/index.js +3 -4
- package/dist/esm/v3/components/or-select-v3/index.js +3 -4
- package/dist/esm/v3/components/or-textarea/index.d.ts +1 -0
- package/dist/esm/v3/components/or-textarea/index.js +11 -0
- package/dist/esm/v3/index.js +13 -9
- package/package.json +3 -2
- package/src/components/index.ts +5 -1
- package/src/components/or-card-collection/OrCardCollection.vue +8 -8
- package/src/components/or-confirm/OrConfirm.vue +1 -1
- package/src/components/or-input/index.ts +1 -0
- package/src/components/or-input-v3/OrInput.stories3.ts +0 -4
- package/src/components/or-input-v3/OrInput.vue +17 -37
- package/src/components/or-list/OrList.stories.ts +1 -1
- package/src/components/or-list-of-inputs/OrListOfInputs.vue +1 -1
- package/src/components/or-modal/OrModal.stories.ts +1 -1
- package/src/components/{or-inputs → or-number-input}/OrNumberInput.vue +1 -1
- package/src/components/or-number-input/index.ts +1 -0
- package/src/components/{or-inputs → or-password}/OrPassword.vue +1 -1
- package/src/components/or-password/index.ts +1 -0
- package/src/components/{or-inputs → or-search}/OrSearch.vue +1 -1
- package/src/components/or-search/index.ts +1 -0
- package/src/components/{or-inputs → or-textarea}/OrTextarea.vue +225 -6
- package/src/components/or-textarea/index.ts +1 -0
- package/dist/bundled/v2/components/or-inputs/index.d.ts +0 -5
- package/dist/bundled/v3/OrPassword.vue_vue_type_script_lang-13bc5b00.js +0 -390
- package/dist/bundled/v3/components/or-inputs/index.d.ts +0 -5
- package/dist/esm/v2/components/or-inputs/index.d.ts +0 -5
- package/dist/esm/v3/OrSearch-7cb2c91c.js +0 -1075
- package/dist/esm/v3/components/or-inputs/index.d.ts +0 -5
- package/src/components/or-inputs/index.ts +0 -5
- /package/dist/bundled/v2/{OrInput-08f2f666.js → OrInput-df1a14fa.js} +0 -0
- /package/dist/bundled/v2/components/{or-inputs → or-input}/OrInput.vue.d.ts +0 -0
- /package/dist/bundled/v2/components/{or-inputs → or-number-input}/OrNumberInput.vue.d.ts +0 -0
- /package/dist/bundled/v2/components/{or-inputs → or-password}/OrPassword.vue.d.ts +0 -0
- /package/dist/bundled/v2/components/{or-inputs → or-search}/OrSearch.vue.d.ts +0 -0
- /package/dist/bundled/v2/components/{or-inputs → or-textarea}/OrTextarea.vue.d.ts +0 -0
- /package/dist/bundled/v3/components/{or-inputs → or-input}/OrInput.vue.d.ts +0 -0
- /package/dist/bundled/v3/components/{or-inputs → or-number-input}/OrNumberInput.vue.d.ts +0 -0
- /package/dist/bundled/v3/components/{or-inputs → or-password}/OrPassword.vue.d.ts +0 -0
- /package/dist/bundled/v3/components/{or-inputs → or-search}/OrSearch.vue.d.ts +0 -0
- /package/dist/bundled/v3/components/{or-inputs → or-textarea}/OrTextarea.vue.d.ts +0 -0
- /package/dist/esm/v2/components/{or-inputs → or-input}/OrInput.vue.d.ts +0 -0
- /package/dist/esm/v2/components/{or-inputs → or-number-input}/OrNumberInput.vue.d.ts +0 -0
- /package/dist/esm/v2/components/{or-inputs → or-password}/OrPassword.vue.d.ts +0 -0
- /package/dist/esm/v2/components/{or-inputs → or-search}/OrSearch.vue.d.ts +0 -0
- /package/dist/esm/v2/components/{or-inputs → or-textarea}/OrTextarea.vue.d.ts +0 -0
- /package/dist/esm/v3/components/{or-inputs → or-input}/OrInput.vue.d.ts +0 -0
- /package/dist/esm/v3/components/{or-inputs → or-number-input}/OrNumberInput.vue.d.ts +0 -0
- /package/dist/esm/v3/components/{or-inputs → or-password}/OrPassword.vue.d.ts +0 -0
- /package/dist/esm/v3/components/{or-inputs → or-search}/OrSearch.vue.d.ts +0 -0
- /package/dist/esm/v3/components/{or-inputs → or-textarea}/OrTextarea.vue.d.ts +0 -0
- /package/src/components/{or-inputs → or-input}/OrInput.stories.ts +0 -0
- /package/src/components/{or-inputs → or-input}/OrInput.vue +0 -0
- /package/src/components/{or-inputs → or-input}/or-textbox-migration.stories.mdx +0 -0
- /package/src/components/{or-inputs → or-input}/styles.scss +0 -0
- /package/src/components/{or-inputs → or-number-input}/OrNumberInput.stories.ts +0 -0
- /package/src/components/{or-inputs → or-password}/OrPassword.stories.ts +0 -0
- /package/src/components/{or-inputs → or-search}/OrSearch.stories.ts +0 -0
- /package/src/components/{or-inputs → or-textarea}/OrTextarea.stories.ts +0 -0
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { defineComponent, ref, computed, reactive } from 'vue-demi';
|
|
2
2
|
import { a as useIdAttribute, u as useControlAttributes } from './useIdAttribute-859439f0.js';
|
|
3
3
|
import '@vueuse/core';
|
|
4
|
-
import { u as useResponsive } from './useResponsive-a02e95b7.js';
|
|
5
4
|
import { u as useValidationAttributes } from './useValidationAttributes-d1abbe34.js';
|
|
6
5
|
import { s as script$1 } from './OrError-19198748.js';
|
|
7
6
|
import { s as script$2 } from './OrHint-6863124f.js';
|
|
@@ -9,8 +8,7 @@ import { s as script$4 } from './OrIconButton-e5781317.js';
|
|
|
9
8
|
import { s as script$3 } from './OrIcon-34f59f73.js';
|
|
10
9
|
import { s as script$5, a as InputBoxSize } from './OrInputBox-e16ade90.js';
|
|
11
10
|
import { s as script$6 } from './OrLabel-f700f9fb.js';
|
|
12
|
-
import {
|
|
13
|
-
import { resolveComponent, openBlock, createElementBlock, normalizeClass, createBlock, withCtx, renderSlot, createTextVNode, toDisplayString, createCommentVNode, createVNode, withDirectives, createElementVNode, mergeProps, vModelDynamic, Fragment, withModifiers, createSlots } from 'vue';
|
|
11
|
+
import { resolveComponent, openBlock, createElementBlock, normalizeClass, createBlock, withCtx, renderSlot, createTextVNode, toDisplayString, createCommentVNode, createVNode, withDirectives, createElementVNode, mergeProps, vModelDynamic, withModifiers, Fragment, createSlots } from 'vue';
|
|
14
12
|
import { s as styleInject } from './style-inject.es-4c6f2515.js';
|
|
15
13
|
|
|
16
14
|
var InputType;
|
|
@@ -42,8 +40,7 @@ var script = defineComponent({
|
|
|
42
40
|
OrIcon: script$3,
|
|
43
41
|
OrIconButton: script$4,
|
|
44
42
|
OrInputBox: script$5,
|
|
45
|
-
OrLabel: script$6
|
|
46
|
-
OrLoader: script$7
|
|
43
|
+
OrLabel: script$6
|
|
47
44
|
},
|
|
48
45
|
model: {
|
|
49
46
|
prop: 'modelValue',
|
|
@@ -78,10 +75,6 @@ var script = defineComponent({
|
|
|
78
75
|
type: String,
|
|
79
76
|
default: undefined
|
|
80
77
|
},
|
|
81
|
-
loading: {
|
|
82
|
-
type: Boolean,
|
|
83
|
-
default: false
|
|
84
|
-
},
|
|
85
78
|
required: {
|
|
86
79
|
type: Boolean,
|
|
87
80
|
default: false
|
|
@@ -127,9 +120,6 @@ var script = defineComponent({
|
|
|
127
120
|
const maxLength = computed(() => controlAttributes.maxlength);
|
|
128
121
|
const invalid = computed(() => !!props.error);
|
|
129
122
|
const disclosed = ref(false);
|
|
130
|
-
const {
|
|
131
|
-
isMobile
|
|
132
|
-
} = useResponsive();
|
|
133
123
|
// Methods
|
|
134
124
|
function focus() {
|
|
135
125
|
var _a;
|
|
@@ -150,7 +140,6 @@ var script = defineComponent({
|
|
|
150
140
|
maxLength,
|
|
151
141
|
invalid,
|
|
152
142
|
disclosed,
|
|
153
|
-
isMobile,
|
|
154
143
|
focus,
|
|
155
144
|
blur
|
|
156
145
|
};
|
|
@@ -163,7 +152,6 @@ const _hoisted_2 = {
|
|
|
163
152
|
};
|
|
164
153
|
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
165
154
|
const _component_OrLabel = resolveComponent("OrLabel");
|
|
166
|
-
const _component_OrLoader = resolveComponent("OrLoader");
|
|
167
155
|
const _component_OrIconButton = resolveComponent("OrIconButton");
|
|
168
156
|
const _component_OrIcon = resolveComponent("OrIcon");
|
|
169
157
|
const _component_OrInputBox = resolveComponent("OrInputBox");
|
|
@@ -204,14 +192,7 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
204
192
|
onKeyup: _cache[2] || (_cache[2] = $event => _ctx.$emit('keyup', $event)),
|
|
205
193
|
onFocus: _cache[3] || (_cache[3] = $event => _ctx.$emit('focus', $event)),
|
|
206
194
|
onBlur: _cache[4] || (_cache[4] = $event => _ctx.$emit('blur', $event))
|
|
207
|
-
}), null, 16 /* FULL_PROPS */, _hoisted_1), [[vModelDynamic, _ctx.proxyModelValue]]), createElementVNode("div", _hoisted_2, [_ctx.
|
|
208
|
-
key: 0,
|
|
209
|
-
variant: 'circular',
|
|
210
|
-
color: 'primary',
|
|
211
|
-
size: _ctx.isMobile ? 'm' : 's'
|
|
212
|
-
}, null, 8 /* PROPS */, ["size"])) : (openBlock(), createElementBlock(Fragment, {
|
|
213
|
-
key: 1
|
|
214
|
-
}, [_ctx.type === 'password' ? (openBlock(), createBlock(_component_OrIconButton, {
|
|
195
|
+
}), null, 16 /* FULL_PROPS */, _hoisted_1), [[vModelDynamic, _ctx.proxyModelValue]]), createElementVNode("div", _hoisted_2, [_ctx.type === 'password' ? (openBlock(), createBlock(_component_OrIconButton, {
|
|
215
196
|
key: 0,
|
|
216
197
|
icon: {
|
|
217
198
|
icon: _ctx.disclosed ? 'visibility_off' : 'visibility',
|
|
@@ -232,8 +213,7 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
232
213
|
key: 1,
|
|
233
214
|
icon: 'search',
|
|
234
215
|
variant: 'outlined'
|
|
235
|
-
}))], 64 /* STABLE_FRAGMENT */)) : createCommentVNode("v-if", true)]
|
|
236
|
-
|
|
216
|
+
}))], 64 /* STABLE_FRAGMENT */)) : createCommentVNode("v-if", true)])]),
|
|
237
217
|
_: 1 /* STABLE */
|
|
238
218
|
}, 8 /* PROPS */, ["variant", "size", "invalid", "readonly", "disabled"]), !_ctx.invalid ? (openBlock(), createElementBlock(Fragment, {
|
|
239
219
|
key: 1
|
|
@@ -0,0 +1,295 @@
|
|
|
1
|
+
import { defineComponent, ref, getCurrentInstance } from 'vue-demi';
|
|
2
|
+
import { p as pxToRem } from './px-to-rem-0b26b83e.js';
|
|
3
|
+
import { s as setStyle, r as requestAF, d as getCS, a as reflow, c as cancelAF } from './dom-3a15d036.js';
|
|
4
|
+
import { s as script$1 } from './OrLabel-876f8729.js';
|
|
5
|
+
import { s as script$2 } from './OrHint-1414c530.js';
|
|
6
|
+
import { s as script$3 } from './OrError-f90296db.js';
|
|
7
|
+
import { s as script$4 } from './OrCollapse-445141ab.js';
|
|
8
|
+
import { resolveComponent, openBlock, createElementBlock, normalizeClass, createCommentVNode, renderSlot, createElementVNode, createBlock, withCtx, createTextVNode, toDisplayString, mergeProps, createVNode, Transition } from 'vue';
|
|
9
|
+
import { s as styleInject } from './style-inject.es-4c6f2515.js';
|
|
10
|
+
|
|
11
|
+
var script = defineComponent({
|
|
12
|
+
name: 'OrInput',
|
|
13
|
+
components: {
|
|
14
|
+
OrLabel: script$1,
|
|
15
|
+
OrHint: script$2,
|
|
16
|
+
OrError: script$3,
|
|
17
|
+
OrCollapse: script$4
|
|
18
|
+
},
|
|
19
|
+
model: {
|
|
20
|
+
prop: 'modelValue',
|
|
21
|
+
event: 'update:modelValue'
|
|
22
|
+
},
|
|
23
|
+
props: {
|
|
24
|
+
modelValue: {
|
|
25
|
+
type: String,
|
|
26
|
+
default: '',
|
|
27
|
+
required: false
|
|
28
|
+
},
|
|
29
|
+
htmlId: {
|
|
30
|
+
type: String,
|
|
31
|
+
default: '',
|
|
32
|
+
required: false
|
|
33
|
+
},
|
|
34
|
+
placeholder: {
|
|
35
|
+
type: String,
|
|
36
|
+
default: '',
|
|
37
|
+
required: false
|
|
38
|
+
},
|
|
39
|
+
htmlType: {
|
|
40
|
+
type: String,
|
|
41
|
+
default: 'text',
|
|
42
|
+
required: false
|
|
43
|
+
},
|
|
44
|
+
htmlInputAttrs: {
|
|
45
|
+
type: Object,
|
|
46
|
+
default: undefined,
|
|
47
|
+
required: false
|
|
48
|
+
},
|
|
49
|
+
label: {
|
|
50
|
+
type: String,
|
|
51
|
+
default: '',
|
|
52
|
+
required: false
|
|
53
|
+
},
|
|
54
|
+
error: {
|
|
55
|
+
type: String,
|
|
56
|
+
default: '',
|
|
57
|
+
required: false
|
|
58
|
+
},
|
|
59
|
+
hint: {
|
|
60
|
+
type: String,
|
|
61
|
+
default: '',
|
|
62
|
+
required: false
|
|
63
|
+
},
|
|
64
|
+
maxLength: {
|
|
65
|
+
type: Number,
|
|
66
|
+
default: undefined,
|
|
67
|
+
required: false
|
|
68
|
+
},
|
|
69
|
+
isSmall: Boolean,
|
|
70
|
+
isRequired: Boolean,
|
|
71
|
+
isDisabled: Boolean,
|
|
72
|
+
isReadonly: Boolean,
|
|
73
|
+
isInvalid: Boolean
|
|
74
|
+
},
|
|
75
|
+
emits: ['focus', 'blur', 'update:modelValue', 'input', 'keypress', 'keyup', 'keydown'],
|
|
76
|
+
setup() {
|
|
77
|
+
const inputRef = ref();
|
|
78
|
+
return {
|
|
79
|
+
inputRef
|
|
80
|
+
};
|
|
81
|
+
},
|
|
82
|
+
data() {
|
|
83
|
+
return {
|
|
84
|
+
reqAF: null,
|
|
85
|
+
isFocused: false
|
|
86
|
+
};
|
|
87
|
+
},
|
|
88
|
+
computed: {
|
|
89
|
+
localValue() {
|
|
90
|
+
if (this.maxLength && this.modelValue.length > this.maxLength) {
|
|
91
|
+
return this.modelValue.slice(0, -(this.modelValue.length - this.maxLength));
|
|
92
|
+
}
|
|
93
|
+
return this.modelValue;
|
|
94
|
+
},
|
|
95
|
+
localId() {
|
|
96
|
+
var _a;
|
|
97
|
+
return this.htmlId || `input-${(_a = getCurrentInstance()) === null || _a === void 0 ? void 0 : _a.uid}`;
|
|
98
|
+
},
|
|
99
|
+
hasValue() {
|
|
100
|
+
var _a;
|
|
101
|
+
return !!((_a = this.localValue) === null || _a === void 0 ? void 0 : _a.length);
|
|
102
|
+
},
|
|
103
|
+
counterString() {
|
|
104
|
+
return this.maxLength && this.maxLength > 0 ? `${this.localValue.length} / ${this.maxLength}` : '';
|
|
105
|
+
},
|
|
106
|
+
isInactive() {
|
|
107
|
+
return this.isDisabled || this.isReadonly;
|
|
108
|
+
},
|
|
109
|
+
isShowError() {
|
|
110
|
+
return !!this.error && this.isInvalid;
|
|
111
|
+
},
|
|
112
|
+
isShowHint() {
|
|
113
|
+
return !!this.hint && !this.isShowError;
|
|
114
|
+
},
|
|
115
|
+
isShowInfo() {
|
|
116
|
+
return this.isShowError || this.isShowHint || !!this.maxLength;
|
|
117
|
+
},
|
|
118
|
+
rootClasses() {
|
|
119
|
+
return ['or-textbox', {
|
|
120
|
+
'is-show-info': this.isShowInfo,
|
|
121
|
+
'is-small': this.isSmall,
|
|
122
|
+
'has-counter': !!this.maxLength,
|
|
123
|
+
'has-label': !!this.label || !!this.$slots['label-default']
|
|
124
|
+
}];
|
|
125
|
+
},
|
|
126
|
+
inputClasses() {
|
|
127
|
+
return ['or-textbox--input', {
|
|
128
|
+
'is-disabled': this.isDisabled,
|
|
129
|
+
'is-readonly': this.isReadonly,
|
|
130
|
+
'is-focused': this.isFocused,
|
|
131
|
+
'is-required': this.isRequired,
|
|
132
|
+
'has-error': this.isInvalid
|
|
133
|
+
}];
|
|
134
|
+
}
|
|
135
|
+
},
|
|
136
|
+
methods: {
|
|
137
|
+
focus() {
|
|
138
|
+
var _a;
|
|
139
|
+
(_a = this.inputRef) === null || _a === void 0 ? void 0 : _a.focus();
|
|
140
|
+
},
|
|
141
|
+
onInput(event) {
|
|
142
|
+
if (this.isInactive) return;
|
|
143
|
+
this.$emit('update:modelValue', event.target.value);
|
|
144
|
+
this.$emit('input', event.target.value);
|
|
145
|
+
},
|
|
146
|
+
onFocus(event) {
|
|
147
|
+
var _a;
|
|
148
|
+
this.isFocused = true;
|
|
149
|
+
(_a = this.inputRef) === null || _a === void 0 ? void 0 : _a.focus();
|
|
150
|
+
this.$emit('focus', event);
|
|
151
|
+
},
|
|
152
|
+
onBlur(event) {
|
|
153
|
+
var _a;
|
|
154
|
+
this.isFocused = false;
|
|
155
|
+
(_a = this.inputRef) === null || _a === void 0 ? void 0 : _a.blur();
|
|
156
|
+
this.$emit('blur', event);
|
|
157
|
+
},
|
|
158
|
+
beforeEnter(el) {
|
|
159
|
+
setStyle(el, 'opacity', 0);
|
|
160
|
+
},
|
|
161
|
+
enter(el) {
|
|
162
|
+
const {
|
|
163
|
+
scrollHeight,
|
|
164
|
+
parentElement
|
|
165
|
+
} = el;
|
|
166
|
+
this.reqAF = requestAF(() => {
|
|
167
|
+
const pt = parseFloat(getCS(parentElement).paddingTop);
|
|
168
|
+
const pb = parseFloat(getCS(parentElement).paddingBottom);
|
|
169
|
+
const height = scrollHeight + pt + pb;
|
|
170
|
+
if (parentElement) {
|
|
171
|
+
reflow(parentElement);
|
|
172
|
+
setStyle(parentElement, 'height', pxToRem(height));
|
|
173
|
+
}
|
|
174
|
+
setStyle(el, 'opacity', 1);
|
|
175
|
+
});
|
|
176
|
+
},
|
|
177
|
+
leave(el) {
|
|
178
|
+
this.reqAF = requestAF(() => {
|
|
179
|
+
el.style.opacity = '0';
|
|
180
|
+
});
|
|
181
|
+
},
|
|
182
|
+
cancelRequestAF() {
|
|
183
|
+
cancelAF(this.reqAF);
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
});
|
|
187
|
+
|
|
188
|
+
const _hoisted_1 = {
|
|
189
|
+
key: 0,
|
|
190
|
+
ref: "prependRef",
|
|
191
|
+
class: "or-textbox--prepend"
|
|
192
|
+
};
|
|
193
|
+
const _hoisted_2 = {
|
|
194
|
+
class: "or-textbox--wrapper"
|
|
195
|
+
};
|
|
196
|
+
const _hoisted_3 = {
|
|
197
|
+
class: "or-textbox--input-wrapper"
|
|
198
|
+
};
|
|
199
|
+
const _hoisted_4 = ["id", "value", "type", "disabled", "maxlength", "readonly", "placeholder"];
|
|
200
|
+
const _hoisted_5 = {
|
|
201
|
+
key: 0,
|
|
202
|
+
class: "or-textbox--input-end"
|
|
203
|
+
};
|
|
204
|
+
const _hoisted_6 = {
|
|
205
|
+
ref: "infoRef",
|
|
206
|
+
class: "or-textbox--info"
|
|
207
|
+
};
|
|
208
|
+
const _hoisted_7 = ["textContent"];
|
|
209
|
+
const _hoisted_8 = {
|
|
210
|
+
key: 1,
|
|
211
|
+
ref: "appendRef",
|
|
212
|
+
class: "or-textbox--append"
|
|
213
|
+
};
|
|
214
|
+
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
215
|
+
const _component_or_label = resolveComponent("or-label");
|
|
216
|
+
const _component_or_hint = resolveComponent("or-hint");
|
|
217
|
+
const _component_or_error = resolveComponent("or-error");
|
|
218
|
+
const _component_or_collapse = resolveComponent("or-collapse");
|
|
219
|
+
return openBlock(), createElementBlock("div", {
|
|
220
|
+
class: normalizeClass(_ctx.rootClasses)
|
|
221
|
+
}, [createCommentVNode(" Prepend Slot "), _ctx.$slots.prepend ? (openBlock(), createElementBlock("div", _hoisted_1, [renderSlot(_ctx.$slots, "prepend")], 512 /* NEED_PATCH */)) : createCommentVNode("v-if", true), createCommentVNode(" Input "), createElementVNode("div", _hoisted_2, [createCommentVNode(" Label "), _ctx.$slots['label-default'] || _ctx.label ? (openBlock(), createBlock(_component_or_label, {
|
|
222
|
+
key: 0,
|
|
223
|
+
"is-required": _ctx.isRequired,
|
|
224
|
+
for: _ctx.localId
|
|
225
|
+
}, {
|
|
226
|
+
default: withCtx(() => [renderSlot(_ctx.$slots, "label-default", {}, () => [createTextVNode(toDisplayString(_ctx.label), 1 /* TEXT */)])]),
|
|
227
|
+
|
|
228
|
+
append: withCtx(() => [renderSlot(_ctx.$slots, "label-append")]),
|
|
229
|
+
_: 3 /* FORWARDED */
|
|
230
|
+
}, 8 /* PROPS */, ["is-required", "for"])) : createCommentVNode("v-if", true), createElementVNode("div", _hoisted_3, [createElementVNode("input", mergeProps({
|
|
231
|
+
id: _ctx.localId,
|
|
232
|
+
ref: "inputRef",
|
|
233
|
+
value: _ctx.localValue
|
|
234
|
+
}, _ctx.htmlInputAttrs, {
|
|
235
|
+
type: _ctx.htmlType,
|
|
236
|
+
disabled: _ctx.isDisabled,
|
|
237
|
+
maxlength: _ctx.maxLength,
|
|
238
|
+
readonly: _ctx.isReadonly,
|
|
239
|
+
class: _ctx.inputClasses,
|
|
240
|
+
placeholder: _ctx.placeholder,
|
|
241
|
+
onInput: _cache[0] || (_cache[0] = (...args) => _ctx.onInput && _ctx.onInput(...args)),
|
|
242
|
+
onFocus: _cache[1] || (_cache[1] = (...args) => _ctx.onFocus && _ctx.onFocus(...args)),
|
|
243
|
+
onBlur: _cache[2] || (_cache[2] = (...args) => _ctx.onBlur && _ctx.onBlur(...args)),
|
|
244
|
+
onKeypress: _cache[3] || (_cache[3] = $event => _ctx.$emit('keypress', $event)),
|
|
245
|
+
onKeyup: _cache[4] || (_cache[4] = $event => _ctx.$emit('keyup', $event)),
|
|
246
|
+
onKeydown: _cache[5] || (_cache[5] = $event => _ctx.$emit('keydown', $event))
|
|
247
|
+
}), null, 16 /* FULL_PROPS */, _hoisted_4), renderSlot(_ctx.$slots, "wrapper-end"), _ctx.$slots['input-end'] ? (openBlock(), createElementBlock("div", _hoisted_5, [renderSlot(_ctx.$slots, "input-end")])) : createCommentVNode("v-if", true)]), createCommentVNode(" Info "), createVNode(_component_or_collapse, {
|
|
248
|
+
"is-visible": _ctx.isShowInfo
|
|
249
|
+
}, {
|
|
250
|
+
default: withCtx(() => [createElementVNode("div", _hoisted_6, [createVNode(Transition, {
|
|
251
|
+
mode: "out-in",
|
|
252
|
+
onBeforeEnter: _ctx.beforeEnter,
|
|
253
|
+
onEnter: _ctx.enter,
|
|
254
|
+
onAfterEnter: _ctx.cancelRequestAF,
|
|
255
|
+
onLeave: _ctx.leave,
|
|
256
|
+
onAfterLeave: _ctx.cancelRequestAF
|
|
257
|
+
}, {
|
|
258
|
+
default: withCtx(() => [_ctx.isShowHint ? (openBlock(), createBlock(_component_or_hint, {
|
|
259
|
+
key: _ctx.hint,
|
|
260
|
+
hint: _ctx.hint,
|
|
261
|
+
class: "or-textbox--hint"
|
|
262
|
+
}, null, 8 /* PROPS */, ["hint"])) : createCommentVNode("v-if", true)]),
|
|
263
|
+
_: 1 /* STABLE */
|
|
264
|
+
}, 8 /* PROPS */, ["onBeforeEnter", "onEnter", "onAfterEnter", "onLeave", "onAfterLeave"]), createVNode(Transition, {
|
|
265
|
+
mode: "out-in",
|
|
266
|
+
onBeforeEnter: _ctx.beforeEnter,
|
|
267
|
+
onEnter: _ctx.enter,
|
|
268
|
+
onAfterEnter: _ctx.cancelRequestAF,
|
|
269
|
+
onLeave: _ctx.leave,
|
|
270
|
+
onAfterLeave: _ctx.cancelRequestAF
|
|
271
|
+
}, {
|
|
272
|
+
default: withCtx(() => [_ctx.isShowError ? (openBlock(), createBlock(_component_or_error, {
|
|
273
|
+
key: _ctx.error,
|
|
274
|
+
error: _ctx.error,
|
|
275
|
+
class: "or-textbox--error"
|
|
276
|
+
}, null, 8 /* PROPS */, ["error"])) : createCommentVNode("v-if", true)]),
|
|
277
|
+
_: 1 /* STABLE */
|
|
278
|
+
}, 8 /* PROPS */, ["onBeforeEnter", "onEnter", "onAfterEnter", "onLeave", "onAfterLeave"]), createCommentVNode(" Counter "), _ctx.counterString ? (openBlock(), createElementBlock("div", {
|
|
279
|
+
key: 0,
|
|
280
|
+
class: "or-textbox--counter",
|
|
281
|
+
textContent: toDisplayString(_ctx.counterString)
|
|
282
|
+
}, null, 8 /* PROPS */, _hoisted_7)) : createCommentVNode("v-if", true)], 512 /* NEED_PATCH */)]),
|
|
283
|
+
|
|
284
|
+
_: 1 /* STABLE */
|
|
285
|
+
}, 8 /* PROPS */, ["is-visible"])]), createCommentVNode(" Append Slot "), _ctx.$slots.append ? (openBlock(), createElementBlock("div", _hoisted_8, [renderSlot(_ctx.$slots, "append")], 512 /* NEED_PATCH */)) : createCommentVNode("v-if", true)], 2 /* CLASS */);
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
var css_248z = "/**\n * A simple way to manage mobile breakpoints described in https://davidwalsh.name/write-media-queries-sass.\n * Can be further extended using following approach https://rimdev.io/making-media-query-mixins-with-sass/\n */\n@keyframes spinAround-0bc96fe8 {\nfrom {\n transform: rotate(0);\n}\nto {\n transform: rotate(359deg);\n}\n}\n@keyframes fade-0bc96fe8 {\nfrom {\n opacity: 1;\n}\nto {\n opacity: 0;\n}\n}\n.or-textbox[data-v-0bc96fe8] {\n display: flex;\n align-items: flex-start;\n justify-content: flex-start;\n width: 100%;\n}\n.or-textbox.is-show-info.has-label[data-v-0bc96fe8] {\n align-items: center;\n}\n.or-textbox.has-label[data-v-0bc96fe8] {\n align-items: flex-end;\n}\n.or-textbox .or-label[data-v-0bc96fe8] {\n margin-bottom: var(--s-1);\n}\n.or-textbox--append[data-v-0bc96fe8], .or-textbox--prepend[data-v-0bc96fe8] {\n position: relative;\n display: flex;\n align-items: center;\n height: 2.25rem;\n}\n.or-textbox--append[data-v-0bc96fe8] {\n margin-left: 0.625rem;\n}\n.or-textbox--prepend[data-v-0bc96fe8] {\n margin-right: 0.625rem;\n}\n.or-textbox--wrapper[data-v-0bc96fe8] {\n width: 100%;\n}\n.or-textbox--input[data-v-0bc96fe8], .or-textbox--textarea[data-v-0bc96fe8], .or-textbox--input-textarea[data-v-0bc96fe8] {\n width: 100%;\n min-width: 7.125rem;\n height: 2.25rem;\n padding: 0.625rem;\n font-family: inherit;\n font-size: var(--fs-1);\n background-color: var(--c-neutral-1);\n border: 1px solid var(--c-neutral-2);\n border-radius: var(--s-2);\n outline: none;\n transition-timing-function: var(--t-func);\n transition-duration: var(--t-duration);\n transition-property: border-color, background-color, -webkit-box-shadow;\n}\n.or-textbox--input-textarea[data-v-0bc96fe8] {\n /* stylelint-disable-next-line scss/at-extend-no-missing-placeholder */\n min-height: 4.9375rem;\n max-height: 8.875rem;\n overflow-x: hidden;\n overflow-y: auto;\n resize: none;\n}\n.or-textbox--input-wrapper[data-v-0bc96fe8] {\n position: relative;\n width: 100%;\n}\n.or-textbox--input[data-v-0bc96fe8]::placeholder, .or-textbox--textarea[data-v-0bc96fe8]::placeholder, .or-textbox--input-textarea[data-v-0bc96fe8]::placeholder {\n color: var(--c-neutral-4);\n transition-timing-function: var(--t-func);\n transition-duration: var(--t-duration);\n transition-property: opacity;\n}\n.or-textbox--input[data-v-0bc96fe8]:-webkit-autofill, .or-textbox--textarea[data-v-0bc96fe8]:-webkit-autofill, .or-textbox--input-textarea[data-v-0bc96fe8]:-webkit-autofill {\n -webkit-box-shadow: inset 0 0 0 50px var(--c-neutral-1);\n}\n.or-textbox--input[data-v-0bc96fe8]:-webkit-autofill:not(:disabled):not(.is-readonly):not(.is-loading):focus, .or-textbox--textarea[data-v-0bc96fe8]:-webkit-autofill:not(:disabled):not(.is-readonly):not(.is-loading):focus, .or-textbox--input-textarea[data-v-0bc96fe8]:-webkit-autofill:not(:disabled):not(.is-readonly):not(.is-loading):focus {\n -webkit-box-shadow: inset 0 0 0 50px var(--c-white);\n}\n@media (hover: hover) and (pointer: fine) {\n.or-textbox--input[data-v-0bc96fe8]:not(.or-textbox--input.is-loading):not(.is-loading.or-textbox--textarea):not(.is-loading.or-textbox--input-textarea):not(.or-textbox--input.is-disabled):not(.is-disabled.or-textbox--textarea):not(.is-disabled.or-textbox--input-textarea):not(.or-textbox--input.is-readonly):not(.is-readonly.or-textbox--textarea):not(.is-readonly.or-textbox--input-textarea):not(.or-textbox--input:disabled):not(.or-textbox--textarea:disabled):not(.or-textbox--input-textarea:disabled):not(.or-textbox--input.is-focused):not(.is-focused.or-textbox--textarea):not(.is-focused.or-textbox--input-textarea):not(.or-textbox--input:active):not(.or-textbox--textarea:active):not(.or-textbox--input-textarea:active):hover, .or-textbox--textarea[data-v-0bc96fe8]:not(.or-textbox--input.is-loading):not(.is-loading.or-textbox--textarea):not(.is-loading.or-textbox--input-textarea):not(.or-textbox--input.is-disabled):not(.is-disabled.or-textbox--textarea):not(.is-disabled.or-textbox--input-textarea):not(.or-textbox--input.is-readonly):not(.is-readonly.or-textbox--textarea):not(.is-readonly.or-textbox--input-textarea):not(.or-textbox--input:disabled):not(.or-textbox--textarea:disabled):not(.or-textbox--input-textarea:disabled):not(.or-textbox--input.is-focused):not(.is-focused.or-textbox--textarea):not(.is-focused.or-textbox--input-textarea):not(.or-textbox--input:active):not(.or-textbox--textarea:active):not(.or-textbox--input-textarea:active):hover, .or-textbox--input-textarea[data-v-0bc96fe8]:not(.or-textbox--input.is-loading):not(.is-loading.or-textbox--textarea):not(.is-loading.or-textbox--input-textarea):not(.or-textbox--input.is-disabled):not(.is-disabled.or-textbox--textarea):not(.is-disabled.or-textbox--input-textarea):not(.or-textbox--input.is-readonly):not(.is-readonly.or-textbox--textarea):not(.is-readonly.or-textbox--input-textarea):not(.or-textbox--input:disabled):not(.or-textbox--textarea:disabled):not(.or-textbox--input-textarea:disabled):not(.or-textbox--input.is-focused):not(.is-focused.or-textbox--textarea):not(.is-focused.or-textbox--input-textarea):not(.or-textbox--input:active):not(.or-textbox--textarea:active):not(.or-textbox--input-textarea:active):hover {\n background-color: var(--c-white);\n border-color: var(--c-neutral-2-darken-3);\n -webkit-box-shadow: inset 0 0 0 50px var(--c-white);\n}\n}\n@media all and (-ms-high-contrast: none), (-ms-high-contrast: active) {\n.or-textbox--input[data-v-0bc96fe8]:not(.or-textbox--input.is-loading):not(.is-loading.or-textbox--textarea):not(.is-loading.or-textbox--input-textarea):not(.or-textbox--input.is-disabled):not(.is-disabled.or-textbox--textarea):not(.is-disabled.or-textbox--input-textarea):not(.or-textbox--input.is-readonly):not(.is-readonly.or-textbox--textarea):not(.is-readonly.or-textbox--input-textarea):not(.or-textbox--input:disabled):not(.or-textbox--textarea:disabled):not(.or-textbox--input-textarea:disabled):not(.or-textbox--input.is-focused):not(.is-focused.or-textbox--textarea):not(.is-focused.or-textbox--input-textarea):not(.or-textbox--input:active):not(.or-textbox--textarea:active):not(.or-textbox--input-textarea:active):hover, .or-textbox--textarea[data-v-0bc96fe8]:not(.or-textbox--input.is-loading):not(.is-loading.or-textbox--textarea):not(.is-loading.or-textbox--input-textarea):not(.or-textbox--input.is-disabled):not(.is-disabled.or-textbox--textarea):not(.is-disabled.or-textbox--input-textarea):not(.or-textbox--input.is-readonly):not(.is-readonly.or-textbox--textarea):not(.is-readonly.or-textbox--input-textarea):not(.or-textbox--input:disabled):not(.or-textbox--textarea:disabled):not(.or-textbox--input-textarea:disabled):not(.or-textbox--input.is-focused):not(.is-focused.or-textbox--textarea):not(.is-focused.or-textbox--input-textarea):not(.or-textbox--input:active):not(.or-textbox--textarea:active):not(.or-textbox--input-textarea:active):hover, .or-textbox--input-textarea[data-v-0bc96fe8]:not(.or-textbox--input.is-loading):not(.is-loading.or-textbox--textarea):not(.is-loading.or-textbox--input-textarea):not(.or-textbox--input.is-disabled):not(.is-disabled.or-textbox--textarea):not(.is-disabled.or-textbox--input-textarea):not(.or-textbox--input.is-readonly):not(.is-readonly.or-textbox--textarea):not(.is-readonly.or-textbox--input-textarea):not(.or-textbox--input:disabled):not(.or-textbox--textarea:disabled):not(.or-textbox--input-textarea:disabled):not(.or-textbox--input.is-focused):not(.is-focused.or-textbox--textarea):not(.is-focused.or-textbox--input-textarea):not(.or-textbox--input:active):not(.or-textbox--textarea:active):not(.or-textbox--input-textarea:active):hover {\n background-color: var(--c-white);\n border-color: var(--c-neutral-2-darken-3);\n -webkit-box-shadow: inset 0 0 0 50px var(--c-white);\n}\n}\n.or-textbox--input[data-v-0bc96fe8]:not(:disabled):not(.is-loading):not(.is-disabled):not(.is-readonly):active:not(:focus), .or-textbox--textarea[data-v-0bc96fe8]:not(:disabled):not(.is-loading):not(.is-disabled):not(.is-readonly):active:not(:focus), .or-textbox--input-textarea[data-v-0bc96fe8]:not(:disabled):not(.is-loading):not(.is-disabled):not(.is-readonly):active:not(:focus) {\n border-color: var(--c-neutral-2-darken-5);\n}\n.or-textbox--input[data-v-0bc96fe8]:not(:disabled):not(.is-readonly):not(.is-loading):focus, .or-textbox--textarea[data-v-0bc96fe8]:not(:disabled):not(.is-readonly):not(.is-loading):focus, .or-textbox--input-textarea[data-v-0bc96fe8]:not(:disabled):not(.is-readonly):not(.is-loading):focus {\n background-color: var(--c-white);\n border-color: var(--c-primary);\n}\n.or-textbox--input[data-v-0bc96fe8]:not(:disabled):not(.is-readonly):not(.is-loading):focus::placeholder, .or-textbox--textarea[data-v-0bc96fe8]:not(:disabled):not(.is-readonly):not(.is-loading):focus::placeholder, .or-textbox--input-textarea[data-v-0bc96fe8]:not(:disabled):not(.is-readonly):not(.is-loading):focus::placeholder {\n opacity: 0;\n}\n.or-textbox--input[data-v-0bc96fe8]:disabled, .or-textbox--textarea[data-v-0bc96fe8]:disabled, .or-textbox--input-textarea[data-v-0bc96fe8]:disabled, .or-textbox--input.is-disabled[data-v-0bc96fe8], .is-disabled.or-textbox--textarea[data-v-0bc96fe8], .is-disabled.or-textbox--input-textarea[data-v-0bc96fe8] {\n cursor: not-allowed;\n background-color: var(--c-neutral-2);\n border-color: var(--c-neutral-2);\n}\n.or-textbox--input.has-error[data-v-0bc96fe8], .has-error.or-textbox--textarea[data-v-0bc96fe8], .has-error.or-textbox--input-textarea[data-v-0bc96fe8] {\n border-color: var(--c-error);\n}\n@media (hover: hover) and (pointer: fine) {\n.or-textbox--input.has-error[data-v-0bc96fe8]:not(.or-textbox--input.has-error.is-loading):not(.has-error.is-loading.or-textbox--textarea):not(.has-error.is-loading.or-textbox--input-textarea):not(.or-textbox--input.has-error.is-disabled):not(.has-error.is-disabled.or-textbox--textarea):not(.has-error.is-disabled.or-textbox--input-textarea):not(.or-textbox--input.has-error.is-readonly):not(.has-error.is-readonly.or-textbox--textarea):not(.has-error.is-readonly.or-textbox--input-textarea):not(.or-textbox--input.has-error:disabled):not(.has-error.or-textbox--textarea:disabled):not(.has-error.or-textbox--input-textarea:disabled):not(.or-textbox--input.has-error.is-focused):not(.has-error.is-focused.or-textbox--textarea):not(.has-error.is-focused.or-textbox--input-textarea):not(.or-textbox--input.has-error:active):not(.has-error.or-textbox--textarea:active):not(.has-error.or-textbox--input-textarea:active):hover, .has-error.or-textbox--textarea[data-v-0bc96fe8]:not(.or-textbox--input.has-error.is-loading):not(.has-error.is-loading.or-textbox--textarea):not(.has-error.is-loading.or-textbox--input-textarea):not(.or-textbox--input.has-error.is-disabled):not(.has-error.is-disabled.or-textbox--textarea):not(.has-error.is-disabled.or-textbox--input-textarea):not(.or-textbox--input.has-error.is-readonly):not(.has-error.is-readonly.or-textbox--textarea):not(.has-error.is-readonly.or-textbox--input-textarea):not(.or-textbox--input.has-error:disabled):not(.has-error.or-textbox--textarea:disabled):not(.has-error.or-textbox--input-textarea:disabled):not(.or-textbox--input.has-error.is-focused):not(.has-error.is-focused.or-textbox--textarea):not(.has-error.is-focused.or-textbox--input-textarea):not(.or-textbox--input.has-error:active):not(.has-error.or-textbox--textarea:active):not(.has-error.or-textbox--input-textarea:active):hover, .has-error.or-textbox--input-textarea[data-v-0bc96fe8]:not(.or-textbox--input.has-error.is-loading):not(.has-error.is-loading.or-textbox--textarea):not(.has-error.is-loading.or-textbox--input-textarea):not(.or-textbox--input.has-error.is-disabled):not(.has-error.is-disabled.or-textbox--textarea):not(.has-error.is-disabled.or-textbox--input-textarea):not(.or-textbox--input.has-error.is-readonly):not(.has-error.is-readonly.or-textbox--textarea):not(.has-error.is-readonly.or-textbox--input-textarea):not(.or-textbox--input.has-error:disabled):not(.has-error.or-textbox--textarea:disabled):not(.has-error.or-textbox--input-textarea:disabled):not(.or-textbox--input.has-error.is-focused):not(.has-error.is-focused.or-textbox--textarea):not(.has-error.is-focused.or-textbox--input-textarea):not(.or-textbox--input.has-error:active):not(.has-error.or-textbox--textarea:active):not(.has-error.or-textbox--input-textarea:active):hover {\n border-color: var(--c-error-darken-3);\n}\n}\n@media all and (-ms-high-contrast: none), (-ms-high-contrast: active) {\n.or-textbox--input.has-error[data-v-0bc96fe8]:not(.or-textbox--input.has-error.is-loading):not(.has-error.is-loading.or-textbox--textarea):not(.has-error.is-loading.or-textbox--input-textarea):not(.or-textbox--input.has-error.is-disabled):not(.has-error.is-disabled.or-textbox--textarea):not(.has-error.is-disabled.or-textbox--input-textarea):not(.or-textbox--input.has-error.is-readonly):not(.has-error.is-readonly.or-textbox--textarea):not(.has-error.is-readonly.or-textbox--input-textarea):not(.or-textbox--input.has-error:disabled):not(.has-error.or-textbox--textarea:disabled):not(.has-error.or-textbox--input-textarea:disabled):not(.or-textbox--input.has-error.is-focused):not(.has-error.is-focused.or-textbox--textarea):not(.has-error.is-focused.or-textbox--input-textarea):not(.or-textbox--input.has-error:active):not(.has-error.or-textbox--textarea:active):not(.has-error.or-textbox--input-textarea:active):hover, .has-error.or-textbox--textarea[data-v-0bc96fe8]:not(.or-textbox--input.has-error.is-loading):not(.has-error.is-loading.or-textbox--textarea):not(.has-error.is-loading.or-textbox--input-textarea):not(.or-textbox--input.has-error.is-disabled):not(.has-error.is-disabled.or-textbox--textarea):not(.has-error.is-disabled.or-textbox--input-textarea):not(.or-textbox--input.has-error.is-readonly):not(.has-error.is-readonly.or-textbox--textarea):not(.has-error.is-readonly.or-textbox--input-textarea):not(.or-textbox--input.has-error:disabled):not(.has-error.or-textbox--textarea:disabled):not(.has-error.or-textbox--input-textarea:disabled):not(.or-textbox--input.has-error.is-focused):not(.has-error.is-focused.or-textbox--textarea):not(.has-error.is-focused.or-textbox--input-textarea):not(.or-textbox--input.has-error:active):not(.has-error.or-textbox--textarea:active):not(.has-error.or-textbox--input-textarea:active):hover, .has-error.or-textbox--input-textarea[data-v-0bc96fe8]:not(.or-textbox--input.has-error.is-loading):not(.has-error.is-loading.or-textbox--textarea):not(.has-error.is-loading.or-textbox--input-textarea):not(.or-textbox--input.has-error.is-disabled):not(.has-error.is-disabled.or-textbox--textarea):not(.has-error.is-disabled.or-textbox--input-textarea):not(.or-textbox--input.has-error.is-readonly):not(.has-error.is-readonly.or-textbox--textarea):not(.has-error.is-readonly.or-textbox--input-textarea):not(.or-textbox--input.has-error:disabled):not(.has-error.or-textbox--textarea:disabled):not(.has-error.or-textbox--input-textarea:disabled):not(.or-textbox--input.has-error.is-focused):not(.has-error.is-focused.or-textbox--textarea):not(.has-error.is-focused.or-textbox--input-textarea):not(.or-textbox--input.has-error:active):not(.has-error.or-textbox--textarea:active):not(.has-error.or-textbox--input-textarea:active):hover {\n border-color: var(--c-error-darken-3);\n}\n}\n.or-textbox--input.has-error[data-v-0bc96fe8]:not(:disabled):not(.is-readonly):not(.is-loading):focus, .has-error.or-textbox--textarea[data-v-0bc96fe8]:not(:disabled):not(.is-readonly):not(.is-loading):focus, .has-error.or-textbox--input-textarea[data-v-0bc96fe8]:not(:disabled):not(.is-readonly):not(.is-loading):focus {\n border-color: var(--c-error-darken-5);\n}\n.or-textbox--input.has-error[data-v-0bc96fe8]:disabled, .has-error.or-textbox--textarea[data-v-0bc96fe8]:disabled, .has-error.or-textbox--input-textarea[data-v-0bc96fe8]:disabled, .or-textbox--input.has-error.is-disabled[data-v-0bc96fe8], .has-error.is-disabled.or-textbox--textarea[data-v-0bc96fe8], .has-error.is-disabled.or-textbox--input-textarea[data-v-0bc96fe8] {\n cursor: not-allowed;\n border-color: var(--c-error-lighten-20);\n}\n.or-textbox--textarea[data-v-0bc96fe8] {\n /* stylelint-disable-next-line scss/at-extend-no-missing-placeholder */\n min-height: 4.9375rem;\n max-height: 8.875rem;\n overflow-x: hidden;\n overflow-y: auto;\n resize: none;\n}\n.or-textbox--info[data-v-0bc96fe8] {\n width: 100%;\n margin: 0;\n transition-timing-function: var(--t-func);\n transition-duration: var(--t-duration);\n transition-property: height, opacity;\n}\n.or-textbox--counter[data-v-0bc96fe8] {\n flex-shrink: 0;\n margin-left: auto;\n font-size: var(--fs-0);\n line-height: 0.875rem;\n color: var(--c-neutral-4);\n}\n.or-textbox--hint[data-v-0bc96fe8], .or-textbox-error[data-v-0bc96fe8] {\n flex-shrink: 1;\n transition-timing-function: var(--t-func);\n transition-duration: var(--t-duration);\n transition-property: height, opacity;\n}\n.or-textbox.is-small .or-textbox--input[data-v-0bc96fe8], .or-textbox.is-small .or-textbox--input-textarea[data-v-0bc96fe8], .or-textbox.is-small .or-textbox--textarea[data-v-0bc96fe8] {\n height: 1.875rem;\n padding: 0.5rem 0.625rem;\n font-size: var(--fs-0);\n}\n.or-textbox.is-small .or-textbox--input-toggle-btn .material-icons[data-v-0bc96fe8] {\n font-size: var(--fs-1);\n}\n.or-textbox.has-counter .or-textbox--hint[data-v-0bc96fe8], .or-textbox.has-counter .or-textbox--error[data-v-0bc96fe8] {\n padding-right: 0.9375rem;\n}\n.or-textbox.is-show-info .or-textbox--info[data-v-0bc96fe8] {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n padding-top: 0.25rem;\n}\n.or-textbox[data-v-0bc96fe8]:disabled, .or-textbox.is-disabled[data-v-0bc96fe8] {\n cursor: not-allowed;\n}\n.or-textbox:disabled .or-textbox--input-toggle-btn[data-v-0bc96fe8], .or-textbox.is-disabled .or-textbox--input-toggle-btn[data-v-0bc96fe8] {\n pointer-events: none;\n}\n.or-textbox.has-error .or-textbox--input[data-v-0bc96fe8], .or-textbox.has-error .or-textbox--input-textarea[data-v-0bc96fe8], .or-textbox.has-error .or-textbox--textarea[data-v-0bc96fe8] {\n border-color: var(--c-error);\n}\n@media (hover: hover) and (pointer: fine) {\n.or-textbox.has-error .or-textbox--input[data-v-0bc96fe8]:not(.or-textbox.has-error .or-textbox--input.is-loading):not(.or-textbox.has-error .is-loading.or-textbox--input-textarea):not(.or-textbox.has-error .is-loading.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input.is-disabled):not(.or-textbox.has-error .is-disabled.or-textbox--input-textarea):not(.or-textbox.has-error .is-disabled.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input.is-readonly):not(.or-textbox.has-error .is-readonly.or-textbox--input-textarea):not(.or-textbox.has-error .is-readonly.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input:disabled):not(.or-textbox.has-error .or-textbox--input-textarea:disabled):not(.or-textbox.has-error .or-textbox--textarea:disabled):not(.or-textbox.has-error .or-textbox--input.is-focused):not(.or-textbox.has-error .is-focused.or-textbox--input-textarea):not(.or-textbox.has-error .is-focused.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input:active):not(.or-textbox.has-error .or-textbox--input-textarea:active):not(.or-textbox.has-error .or-textbox--textarea:active):hover, .or-textbox.has-error .or-textbox--input-textarea[data-v-0bc96fe8]:not(.or-textbox.has-error .or-textbox--input.is-loading):not(.or-textbox.has-error .is-loading.or-textbox--input-textarea):not(.or-textbox.has-error .is-loading.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input.is-disabled):not(.or-textbox.has-error .is-disabled.or-textbox--input-textarea):not(.or-textbox.has-error .is-disabled.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input.is-readonly):not(.or-textbox.has-error .is-readonly.or-textbox--input-textarea):not(.or-textbox.has-error .is-readonly.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input:disabled):not(.or-textbox.has-error .or-textbox--input-textarea:disabled):not(.or-textbox.has-error .or-textbox--textarea:disabled):not(.or-textbox.has-error .or-textbox--input.is-focused):not(.or-textbox.has-error .is-focused.or-textbox--input-textarea):not(.or-textbox.has-error .is-focused.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input:active):not(.or-textbox.has-error .or-textbox--input-textarea:active):not(.or-textbox.has-error .or-textbox--textarea:active):hover, .or-textbox.has-error .or-textbox--textarea[data-v-0bc96fe8]:not(.or-textbox.has-error .or-textbox--input.is-loading):not(.or-textbox.has-error .is-loading.or-textbox--input-textarea):not(.or-textbox.has-error .is-loading.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input.is-disabled):not(.or-textbox.has-error .is-disabled.or-textbox--input-textarea):not(.or-textbox.has-error .is-disabled.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input.is-readonly):not(.or-textbox.has-error .is-readonly.or-textbox--input-textarea):not(.or-textbox.has-error .is-readonly.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input:disabled):not(.or-textbox.has-error .or-textbox--input-textarea:disabled):not(.or-textbox.has-error .or-textbox--textarea:disabled):not(.or-textbox.has-error .or-textbox--input.is-focused):not(.or-textbox.has-error .is-focused.or-textbox--input-textarea):not(.or-textbox.has-error .is-focused.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input:active):not(.or-textbox.has-error .or-textbox--input-textarea:active):not(.or-textbox.has-error .or-textbox--textarea:active):hover {\n border-color: var(--c-error-darken-3);\n}\n}\n@media all and (-ms-high-contrast: none), (-ms-high-contrast: active) {\n.or-textbox.has-error .or-textbox--input[data-v-0bc96fe8]:not(.or-textbox.has-error .or-textbox--input.is-loading):not(.or-textbox.has-error .is-loading.or-textbox--input-textarea):not(.or-textbox.has-error .is-loading.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input.is-disabled):not(.or-textbox.has-error .is-disabled.or-textbox--input-textarea):not(.or-textbox.has-error .is-disabled.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input.is-readonly):not(.or-textbox.has-error .is-readonly.or-textbox--input-textarea):not(.or-textbox.has-error .is-readonly.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input:disabled):not(.or-textbox.has-error .or-textbox--input-textarea:disabled):not(.or-textbox.has-error .or-textbox--textarea:disabled):not(.or-textbox.has-error .or-textbox--input.is-focused):not(.or-textbox.has-error .is-focused.or-textbox--input-textarea):not(.or-textbox.has-error .is-focused.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input:active):not(.or-textbox.has-error .or-textbox--input-textarea:active):not(.or-textbox.has-error .or-textbox--textarea:active):hover, .or-textbox.has-error .or-textbox--input-textarea[data-v-0bc96fe8]:not(.or-textbox.has-error .or-textbox--input.is-loading):not(.or-textbox.has-error .is-loading.or-textbox--input-textarea):not(.or-textbox.has-error .is-loading.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input.is-disabled):not(.or-textbox.has-error .is-disabled.or-textbox--input-textarea):not(.or-textbox.has-error .is-disabled.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input.is-readonly):not(.or-textbox.has-error .is-readonly.or-textbox--input-textarea):not(.or-textbox.has-error .is-readonly.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input:disabled):not(.or-textbox.has-error .or-textbox--input-textarea:disabled):not(.or-textbox.has-error .or-textbox--textarea:disabled):not(.or-textbox.has-error .or-textbox--input.is-focused):not(.or-textbox.has-error .is-focused.or-textbox--input-textarea):not(.or-textbox.has-error .is-focused.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input:active):not(.or-textbox.has-error .or-textbox--input-textarea:active):not(.or-textbox.has-error .or-textbox--textarea:active):hover, .or-textbox.has-error .or-textbox--textarea[data-v-0bc96fe8]:not(.or-textbox.has-error .or-textbox--input.is-loading):not(.or-textbox.has-error .is-loading.or-textbox--input-textarea):not(.or-textbox.has-error .is-loading.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input.is-disabled):not(.or-textbox.has-error .is-disabled.or-textbox--input-textarea):not(.or-textbox.has-error .is-disabled.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input.is-readonly):not(.or-textbox.has-error .is-readonly.or-textbox--input-textarea):not(.or-textbox.has-error .is-readonly.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input:disabled):not(.or-textbox.has-error .or-textbox--input-textarea:disabled):not(.or-textbox.has-error .or-textbox--textarea:disabled):not(.or-textbox.has-error .or-textbox--input.is-focused):not(.or-textbox.has-error .is-focused.or-textbox--input-textarea):not(.or-textbox.has-error .is-focused.or-textbox--textarea):not(.or-textbox.has-error .or-textbox--input:active):not(.or-textbox.has-error .or-textbox--input-textarea:active):not(.or-textbox.has-error .or-textbox--textarea:active):hover {\n border-color: var(--c-error-darken-3);\n}\n}\n.or-textbox.has-error .or-textbox--input[data-v-0bc96fe8]:not(:disabled):not(.is-readonly):not(.is-loading):focus, .or-textbox.has-error .or-textbox--input-textarea[data-v-0bc96fe8]:not(:disabled):not(.is-readonly):not(.is-loading):focus, .or-textbox.has-error .or-textbox--textarea[data-v-0bc96fe8]:not(:disabled):not(.is-readonly):not(.is-loading):focus {\n border-color: var(--c-error-darken-5);\n}\n.or-textbox.has-error .or-textbox--input[data-v-0bc96fe8]:disabled, .or-textbox.has-error .or-textbox--input-textarea[data-v-0bc96fe8]:disabled, .or-textbox.has-error .or-textbox--textarea[data-v-0bc96fe8]:disabled, .or-textbox.has-error .or-textbox--input.is-disabled[data-v-0bc96fe8], .or-textbox.has-error .is-disabled.or-textbox--input-textarea[data-v-0bc96fe8], .or-textbox.has-error .is-disabled.or-textbox--textarea[data-v-0bc96fe8] {\n cursor: not-allowed;\n border-color: var(--c-error);\n}\ninput[type=search][data-v-0bc96fe8]::-webkit-search-decoration,\ninput[type=search][data-v-0bc96fe8]::-webkit-search-cancel-button,\ninput[type=search][data-v-0bc96fe8]::-webkit-search-results-button,\ninput[type=search][data-v-0bc96fe8]::-webkit-search-results-decoration {\n display: none;\n}";
|
|
289
|
+
styleInject(css_248z);
|
|
290
|
+
|
|
291
|
+
script.render = render;
|
|
292
|
+
script.__scopeId = "data-v-0bc96fe8";
|
|
293
|
+
script.__file = "src/components/or-input/OrInput.vue";
|
|
294
|
+
|
|
295
|
+
export { script as s };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineComponent } from 'vue-demi';
|
|
2
2
|
import _ from 'lodash';
|
|
3
3
|
import { s as script$1 } from './OrList-b740d13e.js';
|
|
4
|
-
import {
|
|
4
|
+
import { s as script$2 } from './OrInput-81125804.js';
|
|
5
5
|
import { s as script$3 } from './OrIcon-669503c3.js';
|
|
6
6
|
import { a as script$4 } from './OrIconButton-8be9c89f.js';
|
|
7
7
|
import { resolveComponent, openBlock, createBlock, withCtx, renderSlot, normalizeProps, guardReactiveProps, createVNode, mergeProps, createSlots, normalizeStyle } from 'vue';
|
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
import { defineComponent, ref } from 'vue-demi';
|
|
2
|
+
import { s as script$1 } from './OrInput-81125804.js';
|
|
3
|
+
import { resolveComponent, openBlock, createBlock, createSlots, withCtx, renderSlot } from 'vue';
|
|
4
|
+
|
|
5
|
+
var script = defineComponent({
|
|
6
|
+
name: 'OrNumberInput',
|
|
7
|
+
components: {
|
|
8
|
+
OrInput: script$1
|
|
9
|
+
},
|
|
10
|
+
model: {
|
|
11
|
+
prop: 'modelValue',
|
|
12
|
+
event: 'update:modelValue'
|
|
13
|
+
},
|
|
14
|
+
props: {
|
|
15
|
+
modelValue: {
|
|
16
|
+
type: Number,
|
|
17
|
+
default: undefined,
|
|
18
|
+
required: false
|
|
19
|
+
},
|
|
20
|
+
htmlId: {
|
|
21
|
+
type: String,
|
|
22
|
+
default: '',
|
|
23
|
+
required: false
|
|
24
|
+
},
|
|
25
|
+
placeholder: {
|
|
26
|
+
type: String,
|
|
27
|
+
default: '',
|
|
28
|
+
required: false
|
|
29
|
+
},
|
|
30
|
+
label: {
|
|
31
|
+
type: String,
|
|
32
|
+
default: '',
|
|
33
|
+
required: false
|
|
34
|
+
},
|
|
35
|
+
error: {
|
|
36
|
+
type: String,
|
|
37
|
+
default: '',
|
|
38
|
+
required: false
|
|
39
|
+
},
|
|
40
|
+
hint: {
|
|
41
|
+
type: String,
|
|
42
|
+
default: '',
|
|
43
|
+
required: false
|
|
44
|
+
},
|
|
45
|
+
minValue: {
|
|
46
|
+
type: Number,
|
|
47
|
+
default: undefined,
|
|
48
|
+
required: false
|
|
49
|
+
},
|
|
50
|
+
maxValue: {
|
|
51
|
+
type: Number,
|
|
52
|
+
default: undefined,
|
|
53
|
+
required: false
|
|
54
|
+
},
|
|
55
|
+
stepValue: {
|
|
56
|
+
type: Number,
|
|
57
|
+
default: undefined,
|
|
58
|
+
required: false
|
|
59
|
+
},
|
|
60
|
+
isSmall: Boolean,
|
|
61
|
+
isRequired: Boolean,
|
|
62
|
+
isDisabled: Boolean,
|
|
63
|
+
isReadonly: Boolean,
|
|
64
|
+
isInvalid: Boolean
|
|
65
|
+
},
|
|
66
|
+
emits: ['focus', 'blur', 'update:modelValue', 'input', 'keypress', 'keyup', 'keydown'],
|
|
67
|
+
setup(props, {
|
|
68
|
+
emit
|
|
69
|
+
}) {
|
|
70
|
+
const inputRef = ref();
|
|
71
|
+
if (props.modelValue) {
|
|
72
|
+
if (props.minValue !== undefined && props.modelValue < props.minValue) {
|
|
73
|
+
emit('update:modelValue', props.minValue);
|
|
74
|
+
} else if (props.maxValue !== undefined && props.modelValue > props.maxValue) {
|
|
75
|
+
emit('update:modelValue', props.maxValue);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
return {
|
|
79
|
+
inputRef
|
|
80
|
+
};
|
|
81
|
+
},
|
|
82
|
+
computed: {
|
|
83
|
+
htmlInputAttrs() {
|
|
84
|
+
return {
|
|
85
|
+
min: this.minValue,
|
|
86
|
+
max: this.maxValue,
|
|
87
|
+
step: this.stepValue
|
|
88
|
+
};
|
|
89
|
+
},
|
|
90
|
+
localValue: {
|
|
91
|
+
get() {
|
|
92
|
+
var _a;
|
|
93
|
+
return ((_a = this.modelValue) !== null && _a !== void 0 ? _a : '') + '';
|
|
94
|
+
},
|
|
95
|
+
set(val) {
|
|
96
|
+
if (val === undefined || val === '') {
|
|
97
|
+
this.$emit('update:modelValue', undefined);
|
|
98
|
+
return;
|
|
99
|
+
}
|
|
100
|
+
const numVal = +val;
|
|
101
|
+
if (this.minValue !== undefined && numVal < this.minValue) {
|
|
102
|
+
this.$emit('update:modelValue', this.minValue);
|
|
103
|
+
} else if (this.maxValue !== undefined && numVal > this.maxValue) {
|
|
104
|
+
this.$emit('update:modelValue', this.maxValue);
|
|
105
|
+
} else {
|
|
106
|
+
this.$emit('update:modelValue', numVal);
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
});
|
|
112
|
+
|
|
113
|
+
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
114
|
+
const _component_or_input = resolveComponent("or-input");
|
|
115
|
+
return openBlock(), createBlock(_component_or_input, {
|
|
116
|
+
ref: "inputRef",
|
|
117
|
+
modelValue: _ctx.localValue,
|
|
118
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = $event => _ctx.localValue = $event),
|
|
119
|
+
class: "or-password",
|
|
120
|
+
"html-id": _ctx.htmlId,
|
|
121
|
+
placeholder: _ctx.placeholder,
|
|
122
|
+
"html-type": "number",
|
|
123
|
+
"html-input-attrs": _ctx.htmlInputAttrs,
|
|
124
|
+
label: _ctx.label,
|
|
125
|
+
error: _ctx.error,
|
|
126
|
+
hint: _ctx.hint,
|
|
127
|
+
"is-small": _ctx.isSmall,
|
|
128
|
+
"is-required": _ctx.isRequired,
|
|
129
|
+
"is-disabled": _ctx.isDisabled,
|
|
130
|
+
"is-readonly": _ctx.isReadonly,
|
|
131
|
+
"is-invalid": _ctx.isInvalid,
|
|
132
|
+
onFocus: _cache[1] || (_cache[1] = $event => _ctx.$emit('focus', $event)),
|
|
133
|
+
onBlur: _cache[2] || (_cache[2] = $event => _ctx.$emit('blur', $event)),
|
|
134
|
+
onInput: _cache[3] || (_cache[3] = $event => _ctx.$emit('input', $event)),
|
|
135
|
+
onKeypress: _cache[4] || (_cache[4] = $event => _ctx.$emit('keypress', $event)),
|
|
136
|
+
onKeyup: _cache[5] || (_cache[5] = $event => _ctx.$emit('keyup', $event)),
|
|
137
|
+
onKeydown: _cache[6] || (_cache[6] = $event => _ctx.$emit('keydown', $event))
|
|
138
|
+
}, createSlots({
|
|
139
|
+
_: 2 /* DYNAMIC */
|
|
140
|
+
}, [_ctx.$slots.prepend ? {
|
|
141
|
+
name: "prepend",
|
|
142
|
+
fn: withCtx(() => [renderSlot(_ctx.$slots, "prepend")]),
|
|
143
|
+
key: "0"
|
|
144
|
+
} : undefined, _ctx.$slots['label-default'] ? {
|
|
145
|
+
name: "label-default",
|
|
146
|
+
fn: withCtx(() => [renderSlot(_ctx.$slots, "label-default")]),
|
|
147
|
+
key: "1"
|
|
148
|
+
} : undefined, _ctx.$slots['label-append'] ? {
|
|
149
|
+
name: "label-append",
|
|
150
|
+
fn: withCtx(() => [renderSlot(_ctx.$slots, "label-append")]),
|
|
151
|
+
key: "2"
|
|
152
|
+
} : undefined, _ctx.$slots['wrapper-end'] ? {
|
|
153
|
+
name: "wrapper-end",
|
|
154
|
+
fn: withCtx(() => [renderSlot(_ctx.$slots, "wrapper-end")]),
|
|
155
|
+
key: "3"
|
|
156
|
+
} : undefined, _ctx.$slots['input-end'] ? {
|
|
157
|
+
name: "input-end",
|
|
158
|
+
fn: withCtx(() => [renderSlot(_ctx.$slots, "input-end")]),
|
|
159
|
+
key: "4"
|
|
160
|
+
} : undefined, _ctx.$slots.append ? {
|
|
161
|
+
name: "append",
|
|
162
|
+
fn: withCtx(() => [renderSlot(_ctx.$slots, "append")]),
|
|
163
|
+
key: "5"
|
|
164
|
+
} : undefined]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["modelValue", "html-id", "placeholder", "html-input-attrs", "label", "error", "hint", "is-small", "is-required", "is-disabled", "is-readonly", "is-invalid"]);
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
script.render = render;
|
|
168
|
+
script.__file = "src/components/or-number-input/OrNumberInput.vue";
|
|
169
|
+
|
|
170
|
+
export { script as s };
|