plugin-ui-for-kzt 0.0.31 → 0.0.33

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 (36) hide show
  1. package/dist/components/BaseBadge/BaseBadge.vue.d.ts +1 -1
  2. package/dist/components/BaseButton/BaseButton.vue.d.ts +3 -3
  3. package/dist/components/BaseCalendar/BaseCalendar.vue.d.ts +45 -1
  4. package/dist/components/BaseCheckbox/BaseCheckbox.vue.d.ts +2 -2
  5. package/dist/components/BaseDropdown/BaseDropdown.vue.d.ts +2 -2
  6. package/dist/components/BaseField/BaseField.vue.d.ts +2 -2
  7. package/dist/components/BaseInput/BaseInput.vue.d.ts +4 -4
  8. package/dist/components/BaseInputCalendar/BaseInputCalendar.vue.d.ts +21 -12
  9. package/dist/components/BaseInputCurrency/BaseInputCurrency.vue.d.ts +11 -4
  10. package/dist/components/BaseInputEmail/BaseInputEmail.vue.d.ts +3 -3
  11. package/dist/components/BaseInputPhone/BaseInputPhone.vue.d.ts +3 -3
  12. package/dist/components/BaseOpenedListItem/BaseOpenedListItem.vue.d.ts +2 -2
  13. package/dist/components/BasePagination/BasePagination.vue.d.ts +1 -1
  14. package/dist/components/BaseRadio/BaseRadio.vue.d.ts +2 -2
  15. package/dist/components/BaseSegmentedButtons/BaseSegmentedButtons.vue.d.ts +3 -3
  16. package/dist/components/BaseSelect/BaseSelect.vue.d.ts +4 -4
  17. package/dist/components/BaseTag/BaseTag.vue.d.ts +1 -1
  18. package/dist/components/BaseTextarea/BaseTextarea.vue.d.ts +3 -3
  19. package/dist/components/BaseToast/BaseToast.vue.d.ts +1 -1
  20. package/dist/components/BaseToggle/BaseToggle.vue.d.ts +2 -2
  21. package/dist/components/BaseTooltip/BaseTooltip.vue.d.ts +1 -1
  22. package/dist/index.js +1 -1
  23. package/example/App.vue +70 -5
  24. package/example/MyCustomModal.vue +1 -0
  25. package/package.json +1 -1
  26. package/src/assets/icons/calendar.svg +2 -2
  27. package/src/components/BaseCalendar/BaseCalendar.vue +28 -3
  28. package/src/components/BaseIcon/BaseIcon.vue +1 -1
  29. package/src/components/BaseInputCalendar/BaseInputCalendar.vue +39 -4
  30. package/src/components/BaseInputCurrency/BaseInputCurrency.vue +21 -10
  31. package/src/components/BaseSelect/BaseSelect.vue +33 -6
  32. package/src/components/BaseSwiper/BaseSwiper.vue +9 -4
  33. package/src/components/BaseTextarea/BaseTextarea.vue +1 -0
  34. package/src/types/calendar.d.ts +5 -2
  35. package/src/types/input.d.ts +2 -2
  36. package/webpack.config.js +4 -0
package/example/App.vue CHANGED
@@ -1,16 +1,81 @@
1
1
  <template>
2
2
  <div class="demo-page">
3
3
  <h1>Plugin UI KZT - Компоненты</h1>
4
-
4
+ <div>
5
+ <base-icon
6
+ name="calendar"
7
+ size="small"
8
+ />
9
+ </div>
5
10
  <section>
6
- <h2>BaseUpload с drag & drop</h2>
7
- <BaseDefaultPages title="title" description="description" buttonText="buttonText" type="tech-work" imagePath="./tech-work.png" />
8
- <BaseDefaultPages title="title" description="description" buttonText="buttonText" type="404" imagePath="./404.png" />
11
+ <BaseInputCalendar
12
+ id="input-calendar"
13
+ v-model="demoValues.calendar"
14
+ placeholder="Доступно"
15
+ :min-date="new Date('2025-11-23')"
16
+ :max-date="new Date()"
17
+ />
18
+
19
+ <BaseTextarea
20
+ id="textarea"
21
+ v-model="demoValues.textarea"
22
+ placeholder="Введите текст..."
23
+ label="Текстовое поле"
24
+ readonly
25
+ />
9
26
  </section>
10
27
  </div>
11
28
  </template>
12
29
  <script setup lang="ts">
13
- import BaseDefaultPages from '../src/components/BaseDefaultPages/BaseDefaultPages.vue'
30
+ import { ref } from 'vue';
31
+ import { useModal } from '../src/composables/useModal';
32
+ import BaseTextarea from '../src/components/BaseTextarea/BaseTextarea.vue';
33
+ import BaseSwiper from '../src/components/BaseSwiper/BaseSwiper.vue';
34
+ import BaseInputCalendar from '../src/components/BaseInputCalendar/BaseInputCalendar.vue';
35
+ import BaseInputCurrency from '../src/components/BaseInputCurrency/BaseInputCurrency.vue';
36
+ import BaseButton from '../src/components/BaseButton/BaseButton.vue';
37
+ import MyCustomModal from './MyCustomModal.vue';
38
+ import BaseIcon from "../src/components/BaseIcon/BaseIcon.vue";
39
+
40
+ const { open } = useModal();
41
+
42
+ const openModal = () => {
43
+ open('modal-example', {
44
+ closable: true,
45
+ }, MyCustomModal);
46
+ };
47
+ const currencyOptions = [
48
+ { id: '1', name: 'USD', value: 'USD' as const, mask: '# #### ### 0.##', symbol: '$' },
49
+ { id: '2', name: 'RUB', value: 'RUB' as const, mask: '# ##0.##', symbol: '₽' },
50
+ { id: '3', name: 'KGS', value: 'KGS' as const, mask: '# ##0.##', symbol: '⃀' },
51
+ { id: '4', name: 'UZS', value: 'UZS' as const, mask: '# ##0.##', symbol: 'сў' },
52
+ ];
53
+
54
+ const iconOptions = [
55
+ { id: 1, name: 'Пользователь', icon: 'email-sms' },
56
+ { id: 2, name: 'Настройки', icon: 'document-text' },
57
+ { id: 3, name: 'Файлы', icon: 'gallery' },
58
+ { id: 4, name: 'Сообщения', icon: 'email-sms' },
59
+ ];
60
+
61
+ const demoValues = ref({
62
+ icons: iconOptions[0].id,
63
+ textarea: 'Тестовый текст',
64
+ calendar: new Date(),
65
+ calendarDisabled: new Date(),
66
+ calendarReadonly: new Date(),
67
+ currency: '0.00',
68
+ currency2: '0.00',
69
+ phone: '0777777777',
70
+ });
71
+
72
+
73
+
74
+ const images = ref<string[]>([
75
+ 'https://picsum.photos/seed/1/800/400',
76
+ 'https://picsum.photos/seed/2/800/400',
77
+ 'https://picsum.photos/seed/3/800/400',
78
+ ]);
14
79
  </script>
15
80
 
16
81
  <style lang="scss" scoped>
@@ -25,6 +25,7 @@ import type { ICoreModalProps } from '../src/types/modal';
25
25
  const props = defineProps<{
26
26
  modalProps: ICoreModalProps;
27
27
  }>();
28
+ console.log("🚀 ~ props:", props)
28
29
 
29
30
  const emit = defineEmits(['close']);
30
31
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "plugin-ui-for-kzt",
3
- "version": "0.0.31",
3
+ "version": "0.0.33",
4
4
  "description": "plugin-ui for kazaktelekom",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -1,4 +1,4 @@
1
- <svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none">
2
2
  <path d="M8 2V5" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"/>
3
3
  <path d="M16 2V5" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"/>
4
4
  <path d="M3.5 9.08984H20.5" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"/>
@@ -9,4 +9,4 @@
9
9
  <path d="M11.9955 16.7002H12.0045" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
10
10
  <path d="M8.29431 13.7002H8.30329" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
11
11
  <path d="M8.29431 16.7002H8.30329" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
12
- </svg>
12
+ </svg>
@@ -1,6 +1,7 @@
1
1
  <template>
2
2
  <div class="base-calendar" :class="classList">
3
- <vue-date-picker
3
+ <vue-date-picker
4
+ :disabled="disabled || readonly"
4
5
  v-model="computedModelValue"
5
6
  :range="range"
6
7
  locale="ru"
@@ -8,7 +9,8 @@
8
9
  :inline="inline"
9
10
  :text-input="textInputOptions"
10
11
  :hide-navigation="['time']"
11
- :min-date="minDate || undefined"
12
+ :min-date="minDateComputed"
13
+ :max-date="maxDateComputed"
12
14
  :enable-time-picker="false"
13
15
  :format="format"
14
16
  month-name-format="long"
@@ -29,6 +31,7 @@ import VueDatePicker from '@vuepic/vue-datepicker';
29
31
  import '@vuepic/vue-datepicker/dist/main.css';
30
32
  import type { DateRange, TCoreCalendarProps } from '../../types/calendar';
31
33
  import { useKitSize } from '../../composables/kit/size'
34
+ import { useKitState } from '../../composables/kit/state'
32
35
 
33
36
  interface DpInputSlotProps {
34
37
  value: string
@@ -37,8 +40,10 @@ interface DpInputSlotProps {
37
40
  const props = withDefaults(defineProps<TCoreCalendarProps>(), {
38
41
  range: false,
39
42
  minDate: null,
43
+ maxDate: null,
40
44
  size: 'medium',
41
45
  inline: false,
46
+ disabled: false,
42
47
  });
43
48
 
44
49
  const emit: (event: 'update:modelValue', value: DateRange) => void = defineEmits();
@@ -46,8 +51,8 @@ const emit: (event: 'update:modelValue', value: DateRange) => void = defineEmits
46
51
  const computedModelValue = computed<DateRange>({
47
52
  get: () => props.modelValue ?? null,
48
53
  set: (value: DateRange) => {
54
+ if (props.disabled || props.readonly) return;
49
55
  emit('update:modelValue', value);
50
- console.log(value);
51
56
  },
52
57
  });
53
58
 
@@ -58,14 +63,19 @@ const textInputOptions: { format: string } = {
58
63
  const dayNames: string[] = ['П', 'В', 'С', 'Ч', 'П', 'С', 'В'];
59
64
 
60
65
  const { sizeClassList } = useKitSize(props);
66
+ const { stateClassList } = useKitState(props);
61
67
 
62
68
  const classList = computed(() => [
63
69
  sizeClassList.value,
70
+ stateClassList.value,
64
71
  {
65
72
  '--is-readonly': props.readonly,
66
73
  },
67
74
  ]);
68
75
 
76
+ const minDateComputed = computed(() => props.minDate || undefined);
77
+ const maxDateComputed = computed(() => props.maxDate || undefined);
78
+
69
79
  function format(date: Date | string | (Date | string)[] | null): string {
70
80
  if (!date) return '';
71
81
 
@@ -230,5 +240,20 @@ function getDayClass(date: Date): string {
230
240
  color: var(--error-red);
231
241
  }
232
242
  }
243
+
244
+ &.--is-disabled,
245
+ &.--is-readonly {
246
+ pointer-events: none;
247
+ opacity: 0.6;
248
+
249
+ :deep(.dp__input) {
250
+ pointer-events: none;
251
+ cursor: not-allowed;
252
+ }
253
+
254
+ :deep(.dp--menu-wrapper) {
255
+ pointer-events: none;
256
+ }
257
+ }
233
258
  }
234
259
  </style>
@@ -1,6 +1,6 @@
1
1
  <template>
2
2
  <svg class="base-icon" :class="sizeClassList" aria-hidden="true">
3
- <use :xlink:href="`#${name}`" />
3
+ <use :href="`#${name}`" />
4
4
  </svg>
5
5
  </template>
6
6
 
@@ -6,14 +6,18 @@
6
6
  :range="range"
7
7
  :size="size"
8
8
  :min-date="minDate"
9
+ :max-date="maxDate"
9
10
  :id="id"
11
+ :disabled="disabled"
12
+ :readonly="readonly"
10
13
  >
11
14
  <base-input
12
15
  v-bind="{ ...$props }"
13
16
  :model-value="formattedValue"
17
+ :disabled="disabled"
14
18
  @update:model-value="handleInputUpdate"
15
19
  >
16
- <template #['left-icon']>
20
+ <template #left-icon>
17
21
  <base-icon
18
22
  name="calendar"
19
23
  :size="size"
@@ -30,6 +34,7 @@
30
34
  import { computed, ref, watch } from 'vue';
31
35
  import BaseInput from '../BaseInput/BaseInput.vue';
32
36
  import BaseCalendar from '../BaseCalendar/BaseCalendar.vue';
37
+ import BaseIcon from '../BaseIcon/BaseIcon.vue';
33
38
  import type { DateRange, TCoreInputCalendarProps } from '../../types/calendar';
34
39
 
35
40
  const props = withDefaults(defineProps<TCoreInputCalendarProps>(), {
@@ -39,6 +44,8 @@ const props = withDefaults(defineProps<TCoreInputCalendarProps>(), {
39
44
  placeholder: '',
40
45
  range: false,
41
46
  minDate: null,
47
+ maxDate: null,
48
+ disabled: false,
42
49
  });
43
50
 
44
51
  const emit = defineEmits<{
@@ -50,8 +57,18 @@ const inputValue = ref<string>('');
50
57
 
51
58
  watch(
52
59
  () => props.modelValue,
53
- (newValue) => {
54
- inputValue.value = typeof newValue === 'string' ? newValue : '';
60
+ (newValue: string | DateRange | undefined) => {
61
+ if (typeof newValue === 'string') {
62
+ inputValue.value = newValue;
63
+ } else if (newValue instanceof Date) {
64
+ const formatted = formatDateRange(newValue);
65
+ inputValue.value = formatted;
66
+ } else if (Array.isArray(newValue) && newValue.length === 2) {
67
+ const formatted = formatDateRange(newValue);
68
+ inputValue.value = formatted;
69
+ } else {
70
+ inputValue.value = '';
71
+ }
55
72
  },
56
73
  { immediate: true },
57
74
  );
@@ -144,9 +161,23 @@ function formatDateRange(value: DateRange | (string | Date)[]): string {
144
161
 
145
162
  const calendarModelValue = computed<DateRange>({
146
163
  get: () => {
147
- return parseDateString(props.modelValue);
164
+ const value = props.modelValue;
165
+ if (typeof value === 'string') {
166
+ return parseDateString(value);
167
+ }
168
+
169
+ if (value instanceof Date) {
170
+ return value;
171
+ }
172
+ if (Array.isArray(value) && value.length === 2) {
173
+ return value as [Date, Date];
174
+ }
175
+ return null;
148
176
  },
149
177
  set: (value: DateRange) => {
178
+ if (props.disabled || props.readonly) {
179
+ return;
180
+ }
150
181
  const formatted = formatDateRange(value);
151
182
  inputValue.value = formatted;
152
183
  emit('update:modelValue', formatted);
@@ -158,6 +189,10 @@ const formattedValue = computed<string>(() => {
158
189
  });
159
190
 
160
191
  function handleInputUpdate(value: string) {
192
+ if (props.disabled || props.readonly) {
193
+ return;
194
+ }
195
+
161
196
  let filteredValue = value.replace(/[^0-9.\s-]/g, '');
162
197
 
163
198
  if (props.range) {
@@ -39,33 +39,44 @@ import { useKitState } from '../../composables/kit/state';
39
39
  import { useKitSize } from '../../composables/kit/size';
40
40
  import type { ICoreInputProps, IOptionsCurrency } from '../../types/input';
41
41
 
42
- const props = withDefaults(defineProps<ICoreInputProps>(), {
42
+ const props = withDefaults(defineProps<ICoreInputProps & {
43
+ options?: IOptionsCurrency[];
44
+ }>(), {
43
45
  size: 'medium',
44
46
  type: 'text',
45
47
  modelValue: '',
46
48
  placeholder: '0.00',
47
49
  error: '',
50
+ options: undefined,
48
51
  });
49
52
 
50
53
  const emit: (event: 'update:modelValue', value: string) => void = defineEmits();
51
54
 
52
- const optionsCurrency = ref<IOptionsCurrency[]>([
55
+ const defaultOptions: IOptionsCurrency[] = [
53
56
  { id: '1', name: 'KZT', value: 'KZT', mask: '# ##0.##', symbol: '₸' },
54
57
  { id: '2', name: 'RUB', value: 'RUB', mask: '# ##0.##', symbol: '₽' },
55
58
  { id: '3', name: 'KGS', value: 'KGS', mask: '# ##0.##', symbol: '⃀' },
56
59
  { id: '4', name: 'UZS', value: 'UZS', mask: '# ##0.##', symbol: 'сў' },
57
- ]);
60
+ ];
61
+
62
+ const optionsCurrency = computed<IOptionsCurrency[]>(() => {
63
+ return props.options || defaultOptions;
64
+ });
58
65
 
59
- const selectedOption = ref<IOptionsCurrency>(optionsCurrency.value[0]);
66
+ const selectedOption = computed<IOptionsCurrency>(() => {
67
+ const option = optionsCurrency.value.find(opt => opt.id === selectedOptionId.value);
68
+ return option || optionsCurrency.value[0];
69
+ });
60
70
 
61
- const selectedOptionId = ref<IOptionsCurrency['id']>(selectedOption.value.id);
71
+ const selectedOptionId = ref<IOptionsCurrency['id']>(optionsCurrency.value[0]?.id || '');
62
72
 
63
- watch(selectedOptionId, (newId: IOptionsCurrency['id']) => {
64
- const newOption = optionsCurrency.value.find((option: IOptionsCurrency) => option.id === newId);
65
- if (newOption) {
66
- selectedOption.value = newOption;
73
+ watch(optionsCurrency, (newOptions) => {
74
+ if (newOptions.length > 0) {
75
+ if (!newOptions.find(opt => opt.id === selectedOptionId.value)) {
76
+ selectedOptionId.value = newOptions[0].id;
77
+ }
67
78
  }
68
- });
79
+ }, { immediate: true });
69
80
 
70
81
  const { stateClassList, stateAttrs } = useKitState(props);
71
82
  const { sizeClassList } = useKitSize(props);
@@ -8,7 +8,6 @@
8
8
  :disabled="actualDisabled"
9
9
  >
10
10
  <template #top>
11
- <!-- Старый header для дефолтного поведения -->
12
11
  <div
13
12
  v-if="!searchable"
14
13
  :data-error="Boolean(error)"
@@ -19,7 +18,16 @@
19
18
  name="header"
20
19
  :value="actualOption ? [actualOption] : undefined"
21
20
  >
22
- <div v-if="$slots.headerIcon" class="base-select__header_prefix_icon">
21
+ <div
22
+ v-if="actualOption?.icon && $slots.iconItem"
23
+ class="base-select__header_prefix_icon"
24
+ >
25
+ <slot name="iconItem" :item="actualOption" />
26
+ </div>
27
+ <div
28
+ v-else-if="$slots.headerIcon"
29
+ class="base-select__header_prefix_icon"
30
+ >
23
31
  <slot name="headerIcon" />
24
32
  </div>
25
33
 
@@ -100,7 +108,7 @@
100
108
  <div class="base-select__item-wrapper">
101
109
  <base-opened-list-item
102
110
  v-bind="listItemAttrs(item)"
103
- :key="item.id"
111
+ :key="String(item.id ?? '')"
104
112
  :size="size"
105
113
  >
106
114
  <template #icon>
@@ -168,10 +176,17 @@ const displayValue = computed(() => {
168
176
  });
169
177
 
170
178
  watch(() => props.modelValue, (val) => {
171
- actualValue.value = val ?? '';
179
+ if (val && typeof val === 'object' && 'id' in val) {
180
+ actualValue.value = (val as ICoreSelectOption).id as TSelectValue;
181
+ } else {
182
+ actualValue.value = val ?? '';
183
+ }
172
184
  }, { immediate: true });
173
185
 
174
186
  function handleInput(value: TSelectValue) {
187
+ if (props.readonly || props.disabled) {
188
+ return;
189
+ }
175
190
  actualValue.value = value;
176
191
  emit('update:modelValue', value);
177
192
  emit('change', value);
@@ -180,6 +195,9 @@ function handleInput(value: TSelectValue) {
180
195
  }
181
196
 
182
197
  function handleInputChange(event: Event) {
198
+ if (props.readonly || props.disabled) {
199
+ return;
200
+ }
183
201
  const target = event.target as HTMLInputElement;
184
202
  const inputValue = target.value;
185
203
  searchQuery.value = inputValue;
@@ -203,6 +221,9 @@ function handleInputChange(event: Event) {
203
221
  }
204
222
 
205
223
  function handleIconClick(event: Event) {
224
+ if (props.readonly || props.disabled) {
225
+ return;
226
+ }
206
227
  event.stopPropagation();
207
228
  if (actualOption.value) {
208
229
  handleInput('');
@@ -245,7 +266,7 @@ const { sizeClassList } = useKitSize(props);
245
266
  const { stateClassList } = useKitState(props);
246
267
  const { styleClassList } = useKitStyle(props);
247
268
 
248
- const listItemAttrs = computed(() => (item: ICoreSelectBaseProps) => ({
269
+ const listItemAttrs = computed(() => (item: ICoreSelectOption) => ({
249
270
  icon: item.icon,
250
271
  active: actualValue.value === item.id,
251
272
  title: item.name || '',
@@ -267,7 +288,7 @@ const classList = computed(() => [
267
288
 
268
289
  defineSlots<{
269
290
  default(props: ISelectSlotProps): any;
270
- iconItem(props: { item: ICoreSelectBaseProps }): any;
291
+ iconItem(props: { item: ICoreSelectOption }): any;
271
292
  header(props: { value: ICoreSelectProps['options'] }): any;
272
293
  headerIcon(): any;
273
294
  empty(): any;
@@ -485,10 +506,16 @@ defineSlots<{
485
506
  #{$select} {
486
507
  &__header {
487
508
  pointer-events: none;
509
+ cursor: default;
488
510
  }
489
511
 
490
512
  &__input {
491
513
  pointer-events: none;
514
+ cursor: default;
515
+ }
516
+
517
+ &__arrow-wrapper {
518
+ display: none;
492
519
  }
493
520
  }
494
521
  }
@@ -100,15 +100,20 @@ const nextSlide = () => {
100
100
  }
101
101
  };
102
102
 
103
+ const nextSlideCyclic = () => {
104
+ if (currentSlide.value >= props.images.length - 1) {
105
+ currentSlide.value = 0;
106
+ } else {
107
+ currentSlide.value += 1;
108
+ }
109
+ };
110
+
103
111
  let autoplayIntervalId: ReturnType<typeof setInterval> | null = null;
104
112
 
105
113
  const startAutoplay = () => {
106
114
  if (props.autoplay && !autoplayIntervalId) {
107
115
  autoplayIntervalId = setInterval(() => {
108
- nextSlide();
109
- if (currentSlide.value >= props.images.length - 1) {
110
- currentSlide.value = 0; // Возвращаемся к первому слайду
111
- }
116
+ nextSlideCyclic();
112
117
  }, props.autoplayInterval);
113
118
  }
114
119
  };
@@ -8,6 +8,7 @@
8
8
  v-bind="stateAttrs"
9
9
  :placeholder="placeholder || ''"
10
10
  :maxlength="maxLength"
11
+ :readonly="readonly"
11
12
  class="base-textarea__field"
12
13
  @input="handleInput"
13
14
  />
@@ -9,11 +9,14 @@ export interface IBaseCalendarProps {
9
9
  modelValue?: DateRange
10
10
  range?: boolean | RangeConfig | undefined
11
11
  minDate?: Date | null
12
+ maxDate?: Date | null
12
13
  readonly?: boolean
13
14
  error?: string | boolean
14
15
  inline?: boolean;
15
16
  }
16
17
 
17
- export type TCoreCalendarProps = IBaseCalendarProps & ICoreSize;
18
+ export type TCoreCalendarProps = IBaseCalendarProps & ICoreSize & ICoreState;
18
19
 
19
- export type TCoreInputCalendarProps = InputProps & ICoreSize & ICoreState & IBaseCalendarProps;
20
+ export type TCoreInputCalendarProps = Omit<InputProps, 'modelValue'> & ICoreSize & ICoreState & IBaseCalendarProps & {
21
+ modelValue?: string | DateRange;
22
+ };
@@ -26,7 +26,7 @@ export type ICoreTextareaProps = ICoreState & TTextareaProps & ICoreSize;
26
26
  export type TSelectValue = Nullable<string | number | boolean>;
27
27
 
28
28
  type TOptionPhoneCountry = 'KZ' | 'RU' | 'KG' | 'UZ';
29
- type TOptionCurrency = 'KZT' | 'RUB' | 'KGS' | 'UZS';
29
+ type TOptionCurrency = 'KZT' | 'RUB' | 'KGS' | 'UZS' | string;
30
30
  export interface IOptionsSelect<T extends string> {
31
31
  id: string;
32
32
  name: string;
@@ -67,7 +67,7 @@ export interface ICoreSelectBaseProps {
67
67
  }
68
68
 
69
69
  export interface ISelectSlotProps {
70
- item: ICoreSelectBaseProps;
70
+ item: ICoreSelectOption;
71
71
  index: number;
72
72
  active: boolean;
73
73
  }
package/webpack.config.js CHANGED
@@ -61,6 +61,10 @@ module.exports = (env, argv) => {
61
61
  extract: true,
62
62
  spriteFilename: "sprite.svg",
63
63
  publicPath: isProduction ? "./" : "/",
64
+ symbolId: (filePath) => {
65
+ const fileName = path.basename(filePath, ".svg");
66
+ return fileName;
67
+ },
64
68
  },
65
69
  },
66
70
  {