shared-ritm 1.3.96 → 1.3.98

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.
Files changed (99) hide show
  1. package/README.md +103 -103
  2. package/dist/index.css +1 -1
  3. package/dist/shared-ritm.es.js +24 -23
  4. package/dist/shared-ritm.umd.js +3 -3
  5. package/dist/types/api/services/InstrumentsService.d.ts +5 -1
  6. package/dist/types/api/types/Api_Instruments.d.ts +4 -0
  7. package/package.json +1 -1
  8. package/src/api/services/BrigadesService.ts +32 -32
  9. package/src/api/services/CommentsService.ts +24 -24
  10. package/src/api/services/FileService.ts +17 -17
  11. package/src/api/services/GanttService.ts +47 -47
  12. package/src/api/services/InstrumentsService.ts +72 -68
  13. package/src/api/services/ModulesService.ts +27 -27
  14. package/src/api/services/ProjectsService.ts +83 -83
  15. package/src/api/services/ScheduleService.ts +69 -69
  16. package/src/api/services/SearchService.ts +22 -22
  17. package/src/api/services/TasksService.ts +157 -157
  18. package/src/api/settings/ApiService.ts +184 -185
  19. package/src/api/types/Api_Brigades.ts +36 -36
  20. package/src/api/types/Api_Comment.ts +40 -40
  21. package/src/api/types/Api_Files.ts +7 -7
  22. package/src/api/types/Api_Instruments.ts +161 -156
  23. package/src/api/types/Api_Modules.ts +21 -21
  24. package/src/api/types/Api_Projects.ts +62 -62
  25. package/src/api/types/Api_Schedule.ts +64 -64
  26. package/src/api/types/Api_Service.ts +9 -9
  27. package/src/common/app-button/AppButton.vue +173 -173
  28. package/src/common/app-date-picker/AppDatePicker.vue +81 -81
  29. package/src/common/app-datepicker/AppDatepicker.vue +218 -218
  30. package/src/common/app-dropdown/AppDropdown.vue +37 -37
  31. package/src/common/app-file/AppFile.vue +80 -80
  32. package/src/common/app-input/AppInput.vue +150 -150
  33. package/src/common/app-input-search/AppInputSearch.vue +174 -174
  34. package/src/common/app-layout/AppLayout.vue +84 -84
  35. package/src/common/app-layout/components/AppLayoutPage.vue +16 -16
  36. package/src/common/app-loader/index.vue +43 -43
  37. package/src/common/app-page-layout/AppPageLayout.vue +122 -122
  38. package/src/common/app-sheet/AppSheet.vue +120 -120
  39. package/src/common/app-sheet-new/AppSheetNew.vue +244 -244
  40. package/src/common/app-sidebar/components/SidebarMenu.vue +37 -37
  41. package/src/common/app-sidebar/components/SidebarMenuItem.vue +149 -149
  42. package/src/common/app-table/AppTableLayout.vue +137 -137
  43. package/src/common/app-table/components/TablePagination.vue +152 -152
  44. package/src/common/app-table/components/TableSearch.vue +76 -76
  45. package/src/common/app-table/controllers/useBaseTable.ts +45 -45
  46. package/src/global.d.ts +1 -1
  47. package/src/icons/components/arrow-down-icon.vue +25 -25
  48. package/src/icons/components/arrow-frame-icon.vue +19 -19
  49. package/src/icons/components/arrow-square.vue +22 -22
  50. package/src/icons/components/table-filter-icon.vue +30 -30
  51. package/src/icons/dialogs/RemoveIcon.vue +12 -12
  52. package/src/icons/dialogs/SafetyIcon.vue +12 -12
  53. package/src/icons/header/NotificationIcon.vue +18 -18
  54. package/src/icons/header/PersonIcon.vue +11 -11
  55. package/src/icons/header/SettingIcon.vue +14 -14
  56. package/src/icons/header/flashIcon.vue +24 -24
  57. package/src/icons/header/searchStatusIcon.vue +24 -24
  58. package/src/icons/header/smallCapsIcon.vue +34 -34
  59. package/src/icons/sidebar/assign-module-icon.vue +36 -36
  60. package/src/icons/sidebar/instrument-history-icon.vue +32 -32
  61. package/src/icons/sidebar/instrument-order-icon.vue +38 -38
  62. package/src/icons/sidebar/instrument-work-zone-icon.vue +18 -18
  63. package/src/icons/sidebar/instruments-icon.vue +45 -45
  64. package/src/icons/sidebar/logo-icon.vue +15 -15
  65. package/src/icons/sidebar/logout-icon.vue +13 -13
  66. package/src/icons/sidebar/modules-icon.vue +16 -16
  67. package/src/icons/sidebar/notifications-icon.vue +24 -24
  68. package/src/icons/sidebar/order-icon.vue +44 -44
  69. package/src/icons/sidebar/pass-icon.vue +38 -38
  70. package/src/icons/sidebar/positions-icon.vue +42 -42
  71. package/src/icons/sidebar/preorder-icon.vue +19 -19
  72. package/src/icons/sidebar/projects-icon.vue +31 -31
  73. package/src/icons/sidebar/repair-object-icon.vue +18 -18
  74. package/src/icons/sidebar/repairs-icon.vue +20 -20
  75. package/src/icons/sidebar/roles-icon.vue +26 -26
  76. package/src/icons/sidebar/status-history-icon.vue +24 -24
  77. package/src/icons/sidebar/tasks-icon.vue +28 -28
  78. package/src/icons/sidebar/tasks_tasks-icon.vue +39 -39
  79. package/src/icons/sidebar/tasks_today-icon.vue +27 -27
  80. package/src/icons/sidebar/teams-icon.vue +32 -32
  81. package/src/icons/sidebar/user-icon.vue +18 -18
  82. package/src/icons/sidebar/users-icon.vue +46 -46
  83. package/src/icons/sidebar/videosources-icon.vue +19 -19
  84. package/src/icons/sidebar/videowall-icon.vue +13 -13
  85. package/src/icons/sidebar/videozones-icon.vue +21 -21
  86. package/src/icons/sidebar/warehouses-icon.vue +43 -43
  87. package/src/icons/sidebar/workshop-icon.vue +100 -100
  88. package/src/icons/sidebar/workzones-icon.vue +22 -22
  89. package/src/icons/task/attention-icon.vue +13 -13
  90. package/src/icons/task/clock-icon.vue +10 -10
  91. package/src/icons/task/delete-icon.vue +10 -10
  92. package/src/icons/task/fire-icon.vue +16 -16
  93. package/src/main.ts +28 -28
  94. package/src/quasar-user-options.ts +17 -17
  95. package/src/router/index.ts +10 -10
  96. package/src/shims-vue.d.ts +5 -5
  97. package/src/utils/confirm.ts +12 -12
  98. package/src/utils/faceApiHelper.ts +132 -132
  99. package/src/utils/notification.ts +9 -9
@@ -1,150 +1,150 @@
1
- <template>
2
- <q-input
3
- v-model="value"
4
- :class="[inputClasses, $style['app-input']]"
5
- standout
6
- outlined
7
- :clearable="clearable"
8
- dense
9
- :rules="rules"
10
- :type="inputType"
11
- autocomplete="h87h58g7h8hd"
12
- :readonly="readonly || field"
13
- :disable="disabled"
14
- :placeholder="placeholder"
15
- >
16
- </q-input>
17
- </template>
18
-
19
- <script lang="ts" setup>
20
- import { defineProps, defineEmits, computed, ref, withDefaults } from 'vue'
21
-
22
- interface AppQInputProps {
23
- name?: string | undefined
24
- mask?: string | undefined
25
- fillMask?: boolean | string | undefined
26
- reverseFillMask?: boolean | undefined
27
- unmaskedValue?: boolean | undefined
28
- modelValue: string | number | null | undefined
29
- error?: boolean | undefined
30
- errorMessage?: string | undefined
31
- noErrorIcon?: boolean | undefined
32
- rules?: any | undefined
33
- reactiveRules?: boolean | undefined
34
- lazyRules?: boolean | 'ondemand' | undefined
35
- label?: string | undefined
36
- stackLabel?: boolean | undefined
37
- hint?: string | undefined
38
- hideHint?: boolean | undefined
39
- prefix?: string | undefined
40
- suffix?: string | undefined
41
- labelColor?: string | undefined
42
- color?: string | undefined
43
- bgColor?: string | undefined
44
- dark?: boolean | undefined
45
- loading?: boolean | undefined
46
- clearable?: boolean | undefined
47
- clearIcon?: string | undefined
48
- filled?: boolean | undefined
49
- outlined?: boolean | undefined
50
- borderless?: boolean | undefined
51
- standout?: boolean | string | undefined
52
- labelSlot?: boolean | undefined
53
- bottomSlots?: boolean | undefined
54
- hideBottomSpace?: boolean | undefined
55
- counter?: boolean | undefined
56
- rounded?: boolean | undefined
57
- square?: boolean | undefined
58
- dense?: boolean | undefined
59
- itemAligned?: boolean | undefined
60
- disable?: boolean | undefined
61
- readonly?: boolean | undefined
62
- autofocus?: boolean | undefined
63
- for?: string | undefined
64
- shadowText?: string | undefined
65
- type?:
66
- | 'text'
67
- | 'password'
68
- | 'textarea'
69
- | 'email'
70
- | 'search'
71
- | 'tel'
72
- | 'file'
73
- | 'number'
74
- | 'url'
75
- | 'time'
76
- | 'date'
77
- | undefined
78
- debounce?: string | number | undefined
79
- disabled?: boolean | undefined
80
- maxlength?: string | number | undefined
81
- autogrow?: boolean | undefined
82
- inputClass?: any | undefined
83
- inputStyle?: any | undefined
84
- onClear?: (value: any) => void
85
- 'onUpdate:modelValue'?: (value: string | number | null) => void
86
- onFocus?: (evt: Event) => void
87
- onBlur?: (evt: Event) => void
88
- onClick?: (evt: Event) => void
89
- placeholder?: string | undefined
90
- }
91
-
92
- interface AppInputProps extends AppQInputProps {
93
- field?: boolean
94
- required?: boolean
95
- datePicker?: boolean
96
- timePicker?: boolean
97
- withIcon?: boolean
98
- withButton?: boolean
99
- withArrow?: boolean
100
- borderColor?: string
101
- borderRadius?: string
102
- borderWidth?: string
103
- width?: string
104
- height?: string
105
- clearable?: boolean
106
- }
107
-
108
- const props = withDefaults(defineProps<AppInputProps>(), {
109
- dense: true,
110
- outlined: true,
111
- error: undefined,
112
- modelValue: '',
113
- borderRadius: '8px',
114
- borderWidth: '1px',
115
- width: 'auto',
116
- height: 'auto',
117
- })
118
-
119
- const emit = defineEmits(['update:modelValue', 'button-click', 'clear', 'focus', 'blur', 'click'])
120
- const passwordVisibility = ref(false)
121
- const inputType = computed(() => {
122
- if (props.type === 'password') return passwordVisibility.value ? 'text' : 'password'
123
- return props.type || 'text'
124
- })
125
-
126
- const value = computed({
127
- get: () =>
128
- props.modelValue !== null && props.modelValue !== undefined && props.type === 'number'
129
- ? +props.modelValue
130
- : props.modelValue,
131
- set: (newValue: any) => emit('update:modelValue', props.type === 'number' ? +newValue : newValue),
132
- })
133
-
134
- const inputClasses = computed(() => {
135
- return {
136
- 'app-input': true,
137
- '--required': props.required,
138
- '--field': props.field,
139
- 'input-number-without-arrow': inputType.value === 'number' && !props.withArrow,
140
- }
141
- })
142
- </script>
143
-
144
- <style module lang="scss">
145
- .app-input {
146
- &:global(.q-field--dense .q-field__control) {
147
- height: v-bind(height);
148
- }
149
- }
150
- </style>
1
+ <template>
2
+ <q-input
3
+ v-model="value"
4
+ :class="[inputClasses, $style['app-input']]"
5
+ standout
6
+ outlined
7
+ :clearable="clearable"
8
+ dense
9
+ :rules="rules"
10
+ :type="inputType"
11
+ autocomplete="h87h58g7h8hd"
12
+ :readonly="readonly || field"
13
+ :disable="disabled"
14
+ :placeholder="placeholder"
15
+ >
16
+ </q-input>
17
+ </template>
18
+
19
+ <script lang="ts" setup>
20
+ import { defineProps, defineEmits, computed, ref, withDefaults } from 'vue'
21
+
22
+ interface AppQInputProps {
23
+ name?: string | undefined
24
+ mask?: string | undefined
25
+ fillMask?: boolean | string | undefined
26
+ reverseFillMask?: boolean | undefined
27
+ unmaskedValue?: boolean | undefined
28
+ modelValue: string | number | null | undefined
29
+ error?: boolean | undefined
30
+ errorMessage?: string | undefined
31
+ noErrorIcon?: boolean | undefined
32
+ rules?: any | undefined
33
+ reactiveRules?: boolean | undefined
34
+ lazyRules?: boolean | 'ondemand' | undefined
35
+ label?: string | undefined
36
+ stackLabel?: boolean | undefined
37
+ hint?: string | undefined
38
+ hideHint?: boolean | undefined
39
+ prefix?: string | undefined
40
+ suffix?: string | undefined
41
+ labelColor?: string | undefined
42
+ color?: string | undefined
43
+ bgColor?: string | undefined
44
+ dark?: boolean | undefined
45
+ loading?: boolean | undefined
46
+ clearable?: boolean | undefined
47
+ clearIcon?: string | undefined
48
+ filled?: boolean | undefined
49
+ outlined?: boolean | undefined
50
+ borderless?: boolean | undefined
51
+ standout?: boolean | string | undefined
52
+ labelSlot?: boolean | undefined
53
+ bottomSlots?: boolean | undefined
54
+ hideBottomSpace?: boolean | undefined
55
+ counter?: boolean | undefined
56
+ rounded?: boolean | undefined
57
+ square?: boolean | undefined
58
+ dense?: boolean | undefined
59
+ itemAligned?: boolean | undefined
60
+ disable?: boolean | undefined
61
+ readonly?: boolean | undefined
62
+ autofocus?: boolean | undefined
63
+ for?: string | undefined
64
+ shadowText?: string | undefined
65
+ type?:
66
+ | 'text'
67
+ | 'password'
68
+ | 'textarea'
69
+ | 'email'
70
+ | 'search'
71
+ | 'tel'
72
+ | 'file'
73
+ | 'number'
74
+ | 'url'
75
+ | 'time'
76
+ | 'date'
77
+ | undefined
78
+ debounce?: string | number | undefined
79
+ disabled?: boolean | undefined
80
+ maxlength?: string | number | undefined
81
+ autogrow?: boolean | undefined
82
+ inputClass?: any | undefined
83
+ inputStyle?: any | undefined
84
+ onClear?: (value: any) => void
85
+ 'onUpdate:modelValue'?: (value: string | number | null) => void
86
+ onFocus?: (evt: Event) => void
87
+ onBlur?: (evt: Event) => void
88
+ onClick?: (evt: Event) => void
89
+ placeholder?: string | undefined
90
+ }
91
+
92
+ interface AppInputProps extends AppQInputProps {
93
+ field?: boolean
94
+ required?: boolean
95
+ datePicker?: boolean
96
+ timePicker?: boolean
97
+ withIcon?: boolean
98
+ withButton?: boolean
99
+ withArrow?: boolean
100
+ borderColor?: string
101
+ borderRadius?: string
102
+ borderWidth?: string
103
+ width?: string
104
+ height?: string
105
+ clearable?: boolean
106
+ }
107
+
108
+ const props = withDefaults(defineProps<AppInputProps>(), {
109
+ dense: true,
110
+ outlined: true,
111
+ error: undefined,
112
+ modelValue: '',
113
+ borderRadius: '8px',
114
+ borderWidth: '1px',
115
+ width: 'auto',
116
+ height: 'auto',
117
+ })
118
+
119
+ const emit = defineEmits(['update:modelValue', 'button-click', 'clear', 'focus', 'blur', 'click'])
120
+ const passwordVisibility = ref(false)
121
+ const inputType = computed(() => {
122
+ if (props.type === 'password') return passwordVisibility.value ? 'text' : 'password'
123
+ return props.type || 'text'
124
+ })
125
+
126
+ const value = computed({
127
+ get: () =>
128
+ props.modelValue !== null && props.modelValue !== undefined && props.type === 'number'
129
+ ? +props.modelValue
130
+ : props.modelValue,
131
+ set: (newValue: any) => emit('update:modelValue', props.type === 'number' ? +newValue : newValue),
132
+ })
133
+
134
+ const inputClasses = computed(() => {
135
+ return {
136
+ 'app-input': true,
137
+ '--required': props.required,
138
+ '--field': props.field,
139
+ 'input-number-without-arrow': inputType.value === 'number' && !props.withArrow,
140
+ }
141
+ })
142
+ </script>
143
+
144
+ <style module lang="scss">
145
+ .app-input {
146
+ &:global(.q-field--dense .q-field__control) {
147
+ height: v-bind(height);
148
+ }
149
+ }
150
+ </style>
@@ -1,174 +1,174 @@
1
- <template>
2
- <q-input
3
- v-model="value"
4
- standout
5
- outlined
6
- clearable
7
- dense
8
- bg-color="white"
9
- :class="[$style['app-input'], itemClasses]"
10
- :type="type"
11
- :readonly="readonly || field"
12
- :placeholder="label"
13
- >
14
- <template v-if="searchIcon" #prepend>
15
- <q-icon>
16
- <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none">
17
- <path
18
- d="M11.5 21C16.7467 21 21 16.7467 21 11.5C21 6.25329 16.7467 2 11.5 2C6.25329 2 2 6.25329 2 11.5C2 16.7467 6.25329 21 11.5 21Z"
19
- stroke="#404650"
20
- stroke-width="1.5"
21
- stroke-linecap="round"
22
- stroke-linejoin="round"
23
- />
24
- <path d="M22 22L20 20" stroke="#3F8CFF" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" />
25
- </svg>
26
- </q-icon>
27
- </template>
28
- </q-input>
29
- </template>
30
-
31
- <script lang="ts" setup>
32
- import { defineProps, defineEmits, computed, withDefaults } from 'vue'
33
-
34
- import { ValidationRule, VueClassProp, VueStyleProp } from 'quasar/dist/types/api'
35
-
36
- interface AppQInputProps {
37
- height?: string
38
- name?: string | undefined
39
- mask?: string | undefined
40
- fillMask?: boolean | string | undefined
41
- reverseFillMask?: boolean | undefined
42
- unmaskedValue?: boolean | undefined
43
- modelValue: string | number | null | undefined
44
- error?: boolean | undefined
45
- errorMessage?: string | undefined
46
- noErrorIcon?: boolean | undefined
47
- rules?: ValidationRule[] | undefined
48
- reactiveRules?: boolean | undefined
49
- lazyRules?: boolean | 'ondemand' | undefined
50
- label?: string | undefined
51
- stackLabel?: boolean | undefined
52
- hint?: string | undefined
53
- hideHint?: boolean | undefined
54
- prefix?: string | undefined
55
- suffix?: string | undefined
56
- labelColor?: string | undefined
57
- color?: string | undefined
58
- bgColor?: string | undefined
59
- dark?: boolean | undefined
60
- loading?: boolean | undefined
61
- clearable?: boolean | undefined
62
- clearIcon?: string | undefined
63
- filled?: boolean | undefined
64
- outlined?: boolean | undefined
65
- borderless?: boolean | undefined
66
- bordered?: boolean | undefined
67
- borderRadius?: string | undefined
68
- standout?: boolean | string | undefined
69
- searchIcon?: boolean | undefined
70
- labelSlot?: boolean | undefined
71
- bottomSlots?: boolean | undefined
72
- hideBottomSpace?: boolean | undefined
73
- counter?: boolean | undefined
74
- rounded?: boolean | undefined
75
- square?: boolean | undefined
76
- dense?: boolean | undefined
77
- itemAligned?: boolean | undefined
78
- disable?: boolean | undefined
79
- readonly?: boolean | undefined
80
- autofocus?: boolean | undefined
81
- for?: string | undefined
82
- shadowText?: string | undefined
83
- type?:
84
- | 'text'
85
- | 'password'
86
- | 'textarea'
87
- | 'email'
88
- | 'search'
89
- | 'tel'
90
- | 'file'
91
- | 'number'
92
- | 'url'
93
- | 'time'
94
- | 'date'
95
- | undefined
96
- debounce?: string | number | undefined
97
- maxlength?: string | number | undefined
98
- autogrow?: boolean | undefined
99
- inputClass?: VueClassProp | undefined
100
- inputStyle?: VueStyleProp | undefined
101
- onClear?: (value: any) => void
102
- 'onUpdate:modelValue'?: (value: string | number | null) => void
103
- onFocus?: (evt: Event) => void
104
- onBlur?: (evt: Event) => void
105
- onClick?: (evt: Event) => void
106
- }
107
-
108
- interface AppInputProps extends AppQInputProps {
109
- field?: boolean
110
- required?: boolean
111
- datePicker?: boolean
112
- timePicker?: boolean
113
- dateLocale?: any
114
- withIcon?: boolean
115
- iconName?: string
116
- iconColor?: string
117
- withButton?: boolean
118
- buttonIcon?: string
119
- buttonTooltip?: string
120
- clearTooltip?: string
121
- withArrow?: boolean
122
- }
123
-
124
- const props = withDefaults(defineProps<AppInputProps>(), {
125
- dense: true,
126
- height: '48px',
127
- outlined: true,
128
- error: undefined,
129
- modelValue: '',
130
- borderRadius: '14px',
131
- searchIcon: true,
132
- })
133
-
134
- const emit = defineEmits(['update:modelValue', 'button-click', 'clear', 'focus', 'blur', 'click'])
135
-
136
- const value = computed({
137
- get: () =>
138
- props.modelValue !== null && props.modelValue !== undefined && props.type === 'number'
139
- ? +props.modelValue
140
- : props.modelValue,
141
- set: (newValue: any) => emit('update:modelValue', props.type === 'number' ? +newValue : newValue),
142
- })
143
-
144
- const itemClasses = computed(() => ({
145
- '--dense': props.dense,
146
- '--bordered': props.bordered,
147
- }))
148
- </script>
149
-
150
- <style lang="scss" module>
151
- .app-input {
152
- &:global(.q-field--outlined .q-field__control) {
153
- border-radius: v-bind(borderRadius);
154
- height: v-bind(height);
155
- align-items: center;
156
- padding: 0 12px;
157
- color: #87caff;
158
- }
159
- :global(.q-field__control-container) {
160
- margin-left: 8px;
161
- }
162
- }
163
- @media (max-width: 1440px) {
164
- .app-input {
165
- &:global(.q-field--outlined .q-field__control) {
166
- height: 40px;
167
- padding: 0 12px;
168
- }
169
- :global(.q-field__control-container) {
170
- margin-left: 6px;
171
- }
172
- }
173
- }
174
- </style>
1
+ <template>
2
+ <q-input
3
+ v-model="value"
4
+ standout
5
+ outlined
6
+ clearable
7
+ dense
8
+ bg-color="white"
9
+ :class="[$style['app-input'], itemClasses]"
10
+ :type="type"
11
+ :readonly="readonly || field"
12
+ :placeholder="label"
13
+ >
14
+ <template v-if="searchIcon" #prepend>
15
+ <q-icon>
16
+ <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none">
17
+ <path
18
+ d="M11.5 21C16.7467 21 21 16.7467 21 11.5C21 6.25329 16.7467 2 11.5 2C6.25329 2 2 6.25329 2 11.5C2 16.7467 6.25329 21 11.5 21Z"
19
+ stroke="#404650"
20
+ stroke-width="1.5"
21
+ stroke-linecap="round"
22
+ stroke-linejoin="round"
23
+ />
24
+ <path d="M22 22L20 20" stroke="#3F8CFF" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" />
25
+ </svg>
26
+ </q-icon>
27
+ </template>
28
+ </q-input>
29
+ </template>
30
+
31
+ <script lang="ts" setup>
32
+ import { defineProps, defineEmits, computed, withDefaults } from 'vue'
33
+
34
+ import { ValidationRule, VueClassProp, VueStyleProp } from 'quasar/dist/types/api'
35
+
36
+ interface AppQInputProps {
37
+ height?: string
38
+ name?: string | undefined
39
+ mask?: string | undefined
40
+ fillMask?: boolean | string | undefined
41
+ reverseFillMask?: boolean | undefined
42
+ unmaskedValue?: boolean | undefined
43
+ modelValue: string | number | null | undefined
44
+ error?: boolean | undefined
45
+ errorMessage?: string | undefined
46
+ noErrorIcon?: boolean | undefined
47
+ rules?: ValidationRule[] | undefined
48
+ reactiveRules?: boolean | undefined
49
+ lazyRules?: boolean | 'ondemand' | undefined
50
+ label?: string | undefined
51
+ stackLabel?: boolean | undefined
52
+ hint?: string | undefined
53
+ hideHint?: boolean | undefined
54
+ prefix?: string | undefined
55
+ suffix?: string | undefined
56
+ labelColor?: string | undefined
57
+ color?: string | undefined
58
+ bgColor?: string | undefined
59
+ dark?: boolean | undefined
60
+ loading?: boolean | undefined
61
+ clearable?: boolean | undefined
62
+ clearIcon?: string | undefined
63
+ filled?: boolean | undefined
64
+ outlined?: boolean | undefined
65
+ borderless?: boolean | undefined
66
+ bordered?: boolean | undefined
67
+ borderRadius?: string | undefined
68
+ standout?: boolean | string | undefined
69
+ searchIcon?: boolean | undefined
70
+ labelSlot?: boolean | undefined
71
+ bottomSlots?: boolean | undefined
72
+ hideBottomSpace?: boolean | undefined
73
+ counter?: boolean | undefined
74
+ rounded?: boolean | undefined
75
+ square?: boolean | undefined
76
+ dense?: boolean | undefined
77
+ itemAligned?: boolean | undefined
78
+ disable?: boolean | undefined
79
+ readonly?: boolean | undefined
80
+ autofocus?: boolean | undefined
81
+ for?: string | undefined
82
+ shadowText?: string | undefined
83
+ type?:
84
+ | 'text'
85
+ | 'password'
86
+ | 'textarea'
87
+ | 'email'
88
+ | 'search'
89
+ | 'tel'
90
+ | 'file'
91
+ | 'number'
92
+ | 'url'
93
+ | 'time'
94
+ | 'date'
95
+ | undefined
96
+ debounce?: string | number | undefined
97
+ maxlength?: string | number | undefined
98
+ autogrow?: boolean | undefined
99
+ inputClass?: VueClassProp | undefined
100
+ inputStyle?: VueStyleProp | undefined
101
+ onClear?: (value: any) => void
102
+ 'onUpdate:modelValue'?: (value: string | number | null) => void
103
+ onFocus?: (evt: Event) => void
104
+ onBlur?: (evt: Event) => void
105
+ onClick?: (evt: Event) => void
106
+ }
107
+
108
+ interface AppInputProps extends AppQInputProps {
109
+ field?: boolean
110
+ required?: boolean
111
+ datePicker?: boolean
112
+ timePicker?: boolean
113
+ dateLocale?: any
114
+ withIcon?: boolean
115
+ iconName?: string
116
+ iconColor?: string
117
+ withButton?: boolean
118
+ buttonIcon?: string
119
+ buttonTooltip?: string
120
+ clearTooltip?: string
121
+ withArrow?: boolean
122
+ }
123
+
124
+ const props = withDefaults(defineProps<AppInputProps>(), {
125
+ dense: true,
126
+ height: '48px',
127
+ outlined: true,
128
+ error: undefined,
129
+ modelValue: '',
130
+ borderRadius: '14px',
131
+ searchIcon: true,
132
+ })
133
+
134
+ const emit = defineEmits(['update:modelValue', 'button-click', 'clear', 'focus', 'blur', 'click'])
135
+
136
+ const value = computed({
137
+ get: () =>
138
+ props.modelValue !== null && props.modelValue !== undefined && props.type === 'number'
139
+ ? +props.modelValue
140
+ : props.modelValue,
141
+ set: (newValue: any) => emit('update:modelValue', props.type === 'number' ? +newValue : newValue),
142
+ })
143
+
144
+ const itemClasses = computed(() => ({
145
+ '--dense': props.dense,
146
+ '--bordered': props.bordered,
147
+ }))
148
+ </script>
149
+
150
+ <style lang="scss" module>
151
+ .app-input {
152
+ &:global(.q-field--outlined .q-field__control) {
153
+ border-radius: v-bind(borderRadius);
154
+ height: v-bind(height);
155
+ align-items: center;
156
+ padding: 0 12px;
157
+ color: #87caff;
158
+ }
159
+ :global(.q-field__control-container) {
160
+ margin-left: 8px;
161
+ }
162
+ }
163
+ @media (max-width: 1440px) {
164
+ .app-input {
165
+ &:global(.q-field--outlined .q-field__control) {
166
+ height: 40px;
167
+ padding: 0 12px;
168
+ }
169
+ :global(.q-field__control-container) {
170
+ margin-left: 6px;
171
+ }
172
+ }
173
+ }
174
+ </style>