@autoafleveren/ui 1.4.9 → 1.4.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@autoafleveren/ui",
3
- "version": "1.4.9",
3
+ "version": "1.4.11",
4
4
  "type": "module",
5
5
  "files": [
6
6
  "dist/*",
@@ -70,7 +70,7 @@
70
70
  },
71
71
  "packageManager": "yarn@4.6.0",
72
72
  "dependencies": {
73
- "@awesome.me/kit-6a64244790": "^1.0.247",
73
+ "@awesome.me/kit-6a64244790": "^1.0.248",
74
74
  "@floating-ui/vue": "^1.1.7",
75
75
  "@fortawesome/fontawesome-svg-core": "^7.0.0",
76
76
  "@fortawesome/vue-fontawesome": "^3.1.1",
@@ -184,6 +184,7 @@
184
184
  :tabindex="props.tabindex"
185
185
  :class="getInputDomClasses(type, disabled, readonly, loading, hasError, isOpen, plain, $slots, $attrs)"
186
186
  :data-error="hasError ? 'input' : undefined"
187
+ :native="native"
187
188
  @open="() => isOpen = true"
188
189
  @blur="onBlur"
189
190
  @focus="onFocus"
@@ -23,7 +23,7 @@
23
23
  set: (value: ModelValue): void => emit('update:modelValue', value),
24
24
  });
25
25
  const inputComponent = computed((): string | Component => {
26
- return getInputComponent(props.type);
26
+ return getInputComponent(props.type, props.native);
27
27
  });
28
28
 
29
29
  function onInputTextarea(event: Event): void {
@@ -25,6 +25,7 @@ export interface AppInputProps<ModelValue> {
25
25
  custom?: boolean;
26
26
  required?: boolean;
27
27
  hasError?: boolean;
28
+ native?: boolean;
28
29
  plain?: boolean;
29
30
  errorMessage?: string;
30
31
  label?: string;
@@ -37,7 +38,7 @@ export interface AppInputProps<ModelValue> {
37
38
  init?: Partial<IPropTypes & Record<string, unknown>>;
38
39
  }
39
40
 
40
- export type InputProps<ModelValue> = Pick<AppInputProps<ModelValue>, 'modelValue' | 'tabindex' | 'type' | 'custom'>;
41
+ export type InputProps<ModelValue> = Pick<AppInputProps<ModelValue>, 'modelValue' | 'tabindex' | 'type' | 'custom' | 'native'>;
41
42
 
42
43
  export interface LocationModelValue {
43
44
  postcode?: string;
@@ -20,6 +20,7 @@ export const appInputPropDefaults = {
20
20
  required: false,
21
21
  multiple: false,
22
22
  hasError: false,
23
+ native: false,
23
24
  label: undefined,
24
25
  plain: false,
25
26
  custom: false,
@@ -27,7 +28,11 @@ export const appInputPropDefaults = {
27
28
  modelModifiers: () => ({}),
28
29
  } as const;
29
30
 
30
- export function getInputComponent(inputType: InputType): string | Component {
31
+ export function getInputComponent(inputType: InputType, native: boolean = false): string | Component {
32
+ if (native) {
33
+ return 'input';
34
+ }
35
+
31
36
  if (isDatePickerCheck(inputType)) {
32
37
  return VueDatePicker;
33
38
  }