srcdev-nuxt-forms 2.1.22 → 2.1.23

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.
@@ -7,6 +7,7 @@
7
7
  v-model:isDirty="isDirty"
8
8
  v-model:isActive="isActive"
9
9
  :type
10
+ :inputmode
10
11
  :maxlength
11
12
  :id
12
13
  :name
@@ -31,7 +32,7 @@
31
32
 
32
33
  <script setup lang="ts">
33
34
  import propValidators from '../../c12/prop-validators';
34
- const { type, maxlength, id, name, placeholder, label, errorMessage, fieldHasError, required, styleClassPassthrough, theme } = defineProps({
35
+ const { type, inputmode, maxlength, id, name, placeholder, label, errorMessage, fieldHasError, required, styleClassPassthrough, theme } = defineProps({
35
36
  maxlength: {
36
37
  type: Number,
37
38
  default: 255,
@@ -40,6 +41,13 @@ const { type, maxlength, id, name, placeholder, label, errorMessage, fieldHasErr
40
41
  type: String,
41
42
  required: true,
42
43
  },
44
+ inputmode: {
45
+ type: String as PropType<'text' | 'email' | 'tel' | 'url' | 'search' | 'numeric' | 'none' | 'decimal'>,
46
+ default: 'text',
47
+ validator(value: string) {
48
+ return propValidators.inputMode.includes(value);
49
+ },
50
+ },
43
51
  id: {
44
52
  type: String,
45
53
  required: true,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "srcdev-nuxt-forms",
3
3
  "type": "module",
4
- "version": "2.1.22",
4
+ "version": "2.1.23",
5
5
  "main": "nuxt.config.ts",
6
6
  "scripts": {
7
7
  "clean": "rm -rf .nuxt && rm -rf .output && rm -rf .playground/.nuxt && rm -rf .playground/.output",