plugin-ui-for-kzt 0.0.22 → 0.0.25
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/assets/0e28e37419c99ac65b12.png +0 -0
- package/dist/assets/264165b2b0e8a6840eb0.png +0 -0
- package/dist/components/BaseBadge/BaseBadge.vue.d.ts +1 -1
- package/dist/components/BaseButton/BaseButton.vue.d.ts +3 -3
- package/dist/components/BaseCheckbox/BaseCheckbox.vue.d.ts +4 -4
- package/dist/components/{Spinner/Spinner.vue.d.ts → BaseDefaultPages/BaseDefaultPages.vue.d.ts} +9 -15
- package/dist/components/BaseDropdown/BaseDropdown.vue.d.ts +3 -3
- package/dist/components/BaseField/BaseField.vue.d.ts +2 -2
- package/dist/components/BaseInput/BaseInput.vue.d.ts +7 -7
- package/dist/components/BaseInputCalendar/BaseInputCalendar.vue.d.ts +5 -5
- package/dist/components/BaseInputCurrency/BaseInputCurrency.vue.d.ts +6 -6
- package/dist/components/BaseInputEmail/BaseInputEmail.vue.d.ts +5 -5
- package/dist/components/BaseInputPhone/BaseInputPhone.vue.d.ts +5 -5
- package/dist/components/BaseOpenedListItem/BaseOpenedListItem.vue.d.ts +3 -3
- package/dist/components/{Tooltip/Tooltip.vue.d.ts → BasePageLoader/BasePageLoader.vue.d.ts} +24 -11
- package/dist/components/BasePagination/BasePagination.vue.d.ts +1 -1
- package/dist/components/BaseRadio/BaseRadio.vue.d.ts +4 -4
- package/dist/components/BaseSegmentedButtons/BaseSegmentedButtons.vue.d.ts +3 -3
- package/dist/components/BaseSelect/BaseSelect.vue.d.ts +4 -4
- package/dist/components/BaseTable/BaseTable.vue.d.ts +44 -0
- package/dist/components/BaseTabs/BaseTabs.vue.d.ts +25 -0
- package/dist/components/BaseTag/BaseTag.vue.d.ts +1 -1
- package/dist/components/BaseTextarea/BaseTextarea.vue.d.ts +5 -5
- package/dist/components/BaseToast/BaseToast.vue.d.ts +69 -0
- package/dist/components/BaseToggle/BaseToggle.vue.d.ts +4 -4
- package/dist/components/BaseUpload/BaseUpload.vue.d.ts +11 -0
- package/dist/components/{DataTable/DataTable.vue.d.ts → BaseUpload/CropModal.vue.d.ts} +3 -6
- package/dist/composables/useToast.d.ts +2 -0
- package/dist/index.d.ts +7 -5
- package/dist/index.js +1 -1
- package/dist/index.js.LICENSE.txt +15 -0
- package/dist/plugins/toastPlugin.d.ts +4 -0
- package/dist/sprite.svg +1 -1
- package/dist/store/toast.d.ts +8 -0
- package/example/App.vue +201 -28
- package/example/TestImage.vue +6 -0
- package/package.json +2 -1
- package/src/assets/404.png +0 -0
- package/src/assets/icons/arrow-down-stick.svg +4 -0
- package/src/assets/icons/edit-table.svg +5 -0
- package/src/assets/icons/ellipsis.svg +5 -0
- package/src/assets/icons/loading-page-default.svg +4 -0
- package/src/assets/icons/loading-page-error.svg +6 -0
- package/src/assets/icons/loading-page-success.svg +5 -0
- package/src/assets/icons/loading-page-warning.svg +6 -0
- package/src/assets/icons/more-dots.svg +5 -0
- package/src/assets/icons/time-table.svg +7 -0
- package/src/assets/icons/toast-error.svg +3 -0
- package/src/assets/icons/toast-info.svg +3 -0
- package/src/assets/icons/toast-success.svg +3 -0
- package/src/assets/icons/toast-warning.svg +3 -0
- package/src/assets/icons/trash-table.svg +7 -0
- package/src/assets/tech-work.png +0 -0
- package/src/components/BaseCheckbox/BaseCheckbox.vue +76 -46
- package/src/components/BaseChips/BaseChips.vue +3 -1
- package/src/components/BaseDefaultPages/BaseDefaultPages.vue +140 -0
- package/src/components/BaseDefaultPages/README.md +128 -0
- package/src/components/BaseOpenedListItem/BaseOpenedListItem.vue +3 -3
- package/src/components/BasePageLoader/BasePageLoader.vue +211 -0
- package/src/components/BasePageLoader/README.md +80 -0
- package/src/components/BaseRadio/BaseRadio.vue +266 -233
- package/src/components/BaseSelect/BaseSelect.vue +7 -3
- package/src/components/BaseTable/BaseTable.vue +411 -0
- package/src/components/BaseTable/README.md +294 -0
- package/src/components/BaseTabs/BaseTabs.vue +193 -0
- package/src/components/BaseToast/BaseToast.vue +200 -0
- package/src/components/BaseToast/README.md +103 -0
- package/src/components/BaseTooltip/BaseTooltip.vue +1 -0
- package/src/components/BaseUpload/BaseUpload.vue +36 -2
- package/src/components/BaseUpload/CropModal.vue +210 -0
- package/src/composables/useToast.ts +10 -0
- package/src/index.ts +20 -13
- package/src/plugins/toastPlugin.ts +100 -0
- package/src/store/toast.ts +59 -0
- package/src/styles/root.scss +2 -0
- package/src/styles/toast.scss +36 -0
- package/src/types/default-pages.d.ts +6 -0
- package/src/types/loading-page.d.ts +12 -0
- package/src/types/pagination.d.ts +1 -0
- package/src/types/tab.d.ts +17 -0
- package/src/types/table.d.ts +33 -0
- package/src/types/toast.d.ts +25 -0
- package/src/types/uploadedFile.d.ts +7 -0
- package/webpack.config.js +12 -0
- package/dist/components/Toaster/Toaster.vue.d.ts +0 -80
- package/dist/components/Toaster/timer.d.ts +0 -12
- package/dist/plugins/toasterPlugin.d.ts +0 -26
- package/src/components/DataTable/DataTable.vue +0 -169
- package/src/components/DataTable/README.md +0 -57
- package/src/components/Spinner/README.md +0 -35
- package/src/components/Spinner/Spinner.vue +0 -60
- package/src/components/Toaster/README.md +0 -70
- package/src/components/Toaster/Toaster.vue +0 -235
- package/src/components/Toaster/timer.ts +0 -45
- package/src/components/Tooltip/README.md +0 -37
- package/src/components/Tooltip/Tooltip.vue +0 -96
- package/src/components/icons/CloseIcon.vue +0 -5
- package/src/components/icons/ErrorIcon.vue +0 -7
- package/src/components/icons/InfoIcon.vue +0 -7
- package/src/components/icons/SuccessIcon.vue +0 -6
- package/src/components/icons/WarningIcon.vue +0 -7
- package/src/plugins/toasterPlugin.ts +0 -179
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M17.0504 9.00018L10.2088 16.2418C9.95045 16.5168 9.70045 17.0585 9.65045 17.4335L9.34211 20.1335C9.23378 21.1085 9.93378 21.7752 10.9004 21.6085L13.5838 21.1502C13.9588 21.0835 14.4838 20.8085 14.7421 20.5252L21.5838 13.2835C22.7671 12.0335 23.3004 10.6085 21.4588 8.86685C19.6254 7.14185 18.2338 7.75018 17.0504 9.00018Z" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"/>
|
|
3
|
+
<path d="M15.9082 10.2082C16.2665 12.5082 18.1332 14.2665 20.4499 14.4998" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"/>
|
|
4
|
+
<path d="M8.5 24.3333H23.5" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"/>
|
|
5
|
+
</svg>
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M17.6665 10.1667C17.6665 9.25 16.9165 8.5 15.9998 8.5C15.0832 8.5 14.3332 9.25 14.3332 10.1667C14.3332 11.0833 15.0832 11.8333 15.9998 11.8333C16.9165 11.8333 17.6665 11.0833 17.6665 10.1667Z" fill="currentColor"/>
|
|
3
|
+
<path d="M17.6665 21.8334C17.6665 20.9167 16.9165 20.1667 15.9998 20.1667C15.0832 20.1667 14.3332 20.9167 14.3332 21.8334C14.3332 22.75 15.0832 23.5 15.9998 23.5C16.9165 23.5 17.6665 22.75 17.6665 21.8334Z" fill="currentColor"/>
|
|
4
|
+
<path d="M17.6665 16C17.6665 15.0833 16.9165 14.3333 15.9998 14.3333C15.0832 14.3333 14.3332 15.0833 14.3332 16C14.3332 16.9166 15.0832 17.6666 15.9998 17.6666C16.9165 17.6666 17.6665 16.9166 17.6665 16Z" fill="currentColor"/>
|
|
5
|
+
</svg>
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
<svg width="56" height="56" viewBox="0 0 56 56" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M53 28C53 31.283 52.3534 34.5339 51.097 37.5671C49.8406 40.6002 47.9991 43.3562 45.6777 45.6777C43.3562 47.9991 40.6002 49.8406 37.5671 51.097C34.5339 52.3534 31.283 53 28 53C24.7169 53 21.466 52.3534 18.4329 51.097C15.3998 49.8406 12.6438 47.9991 10.3223 45.6777C8.00086 43.3562 6.15938 40.6002 4.90301 37.5671C3.64664 34.5339 3 31.283 3 28C3 24.7169 3.64665 21.466 4.90302 18.4329C6.15938 15.3998 8.00087 12.6438 10.3223 10.3223C12.6438 8.00086 15.3998 6.15937 18.4329 4.90301C21.4661 3.64664 24.717 3 28 3C31.2831 3 34.534 3.64665 37.5671 4.90302C40.6002 6.15939 43.3562 8.00087 45.6777 10.3223C47.9991 12.6438 49.8406 15.3998 51.097 18.4329C52.3534 21.4661 53 24.717 53 28L53 28Z" stroke="#F2FAFD" stroke-width="6" stroke-linecap="round" stroke-linejoin="round"/>
|
|
3
|
+
<path d="M28 3C31.283 3 34.5339 3.64664 37.5671 4.90301C40.6002 6.15938 43.3562 8.00087 45.6777 10.3223C47.9991 12.6438 49.8406 15.3998 51.097 18.4329C52.3534 21.4661 53 24.717 53 28" stroke="#33ABDF" stroke-width="6" stroke-linecap="round" stroke-linejoin="round"/>
|
|
4
|
+
</svg>
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
<svg width="56" height="56" viewBox="0 0 56 56" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<rect width="56" height="56" rx="28" fill="#F04438"/>
|
|
3
|
+
<path d="M28 20.2084V29.8334" stroke="white" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"/>
|
|
4
|
+
<path d="M44.6467 21.73V34.27C44.6467 36.3233 43.5467 38.23 41.7684 39.275L30.8784 45.5634C29.1 46.59 26.9 46.59 25.1033 45.5634L14.2133 39.275C12.435 38.2484 11.335 36.3416 11.335 34.27V21.73C11.335 19.6767 12.435 17.7699 14.2133 16.7249L25.1033 10.4366C26.8816 9.40996 29.0817 9.40996 30.8784 10.4366L41.7684 16.7249C43.5467 17.7699 44.6467 19.6584 44.6467 21.73Z" stroke="white" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"/>
|
|
5
|
+
<path d="M28 35.7001V35.8834" stroke="white" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"/>
|
|
6
|
+
</svg>
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
<svg width="56" height="56" viewBox="0 0 56 56" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<rect width="56" height="56" rx="28" fill="#12B76A"/>
|
|
3
|
+
<path d="M28 46.3333C38.0833 46.3333 46.3333 38.0833 46.3333 28C46.3333 17.9166 38.0833 9.66663 28 9.66663C17.9166 9.66663 9.66663 17.9166 9.66663 28C9.66663 38.0833 17.9166 46.3333 28 46.3333Z" stroke="white" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"/>
|
|
4
|
+
<path d="M20.2084 28L25.3967 33.1883L35.7917 22.8116" stroke="white" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"/>
|
|
5
|
+
</svg>
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
<svg width="57" height="56" viewBox="0 0 57 56" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<rect x="0.5" width="56" height="56" rx="28" fill="#FC9700"/>
|
|
3
|
+
<path d="M28.5 46.3333C38.5833 46.3333 46.8333 38.0833 46.8333 28C46.8333 17.9166 38.5833 9.66663 28.5 9.66663C18.4166 9.66663 10.1666 17.9166 10.1666 28C10.1666 38.0833 18.4166 46.3333 28.5 46.3333Z" stroke="white" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"/>
|
|
4
|
+
<path d="M28.5 18.8334V28.9167" stroke="white" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"/>
|
|
5
|
+
<path d="M28.4893 37.1666H28.5057" stroke="white" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"/>
|
|
6
|
+
</svg>
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M17.6665 10.1667C17.6665 9.25 16.9165 8.5 15.9998 8.5C15.0832 8.5 14.3332 9.25 14.3332 10.1667C14.3332 11.0833 15.0832 11.8333 15.9998 11.8333C16.9165 11.8333 17.6665 11.0833 17.6665 10.1667Z" fill="currentColor"/>
|
|
3
|
+
<path d="M17.6665 21.8333C17.6665 20.9167 16.9165 20.1667 15.9998 20.1667C15.0832 20.1667 14.3332 20.9167 14.3332 21.8333C14.3332 22.75 15.0832 23.5 15.9998 23.5C16.9165 23.5 17.6665 22.75 17.6665 21.8333Z" fill="currentColor"/>
|
|
4
|
+
<path d="M17.6665 16C17.6665 15.0833 16.9165 14.3333 15.9998 14.3333C15.0832 14.3333 14.3332 15.0833 14.3332 16C14.3332 16.9167 15.0832 17.6667 15.9998 17.6667C16.9165 17.6667 17.6665 16.9167 17.6665 16Z" fill="currentColor"/>
|
|
5
|
+
</svg>
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M16.0002 24.3333C11.9752 24.3333 8.7085 21.0667 8.7085 17.0417C8.7085 13.0167 11.9752 9.75 16.0002 9.75C20.0252 9.75 23.2918 13.0167 23.2918 17.0417" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
|
|
3
|
+
<path d="M16 12.6667V16.8333" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
|
|
4
|
+
<path d="M13.5 7.66667H18.5" stroke="currentColor" stroke-width="1.5" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"/>
|
|
5
|
+
<path d="M21.8335 20.1667V23.5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
|
|
6
|
+
<path d="M19.3335 20.1667V23.5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
|
|
7
|
+
</svg>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M19.5099 5.85L13.5699 2.42C12.5999 1.86 11.3999 1.86 10.4199 2.42L4.48992 5.85C3.51992 6.41 2.91992 7.45 2.91992 8.58V15.42C2.91992 16.54 3.51992 17.58 4.48992 18.15L10.4299 21.58C11.3999 22.14 12.5999 22.14 13.5799 21.58L19.5199 18.15C20.4899 17.59 21.0899 16.55 21.0899 15.42V8.58C21.0799 7.45 20.4799 6.42 19.5099 5.85ZM11.2499 7.75C11.2499 7.34 11.5899 7 11.9999 7C12.4099 7 12.7499 7.34 12.7499 7.75V13C12.7499 13.41 12.4099 13.75 11.9999 13.75C11.5899 13.75 11.2499 13.41 11.2499 13V7.75ZM12.9199 16.63C12.8699 16.75 12.7999 16.86 12.7099 16.96C12.5199 17.15 12.2699 17.25 11.9999 17.25C11.8699 17.25 11.7399 17.22 11.6199 17.17C11.4899 17.12 11.3899 17.05 11.2899 16.96C11.1999 16.86 11.1299 16.75 11.0699 16.63C11.0199 16.51 10.9999 16.38 10.9999 16.25C10.9999 15.99 11.0999 15.73 11.2899 15.54C11.3899 15.45 11.4899 15.38 11.6199 15.33C11.9899 15.17 12.4299 15.26 12.7099 15.54C12.7999 15.64 12.8699 15.74 12.9199 15.87C12.9699 15.99 12.9999 16.12 12.9999 16.25C12.9999 16.38 12.9699 16.51 12.9199 16.63Z" fill="#F04438"/>
|
|
3
|
+
</svg>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M12 2C6.49 2 2 6.49 2 12C2 17.51 6.49 22 12 22C17.51 22 22 17.51 22 12C22 6.49 17.51 2 12 2ZM11.25 8C11.25 7.59 11.59 7.25 12 7.25C12.41 7.25 12.75 7.59 12.75 8V13C12.75 13.41 12.41 13.75 12 13.75C11.59 13.75 11.25 13.41 11.25 13V8ZM12.92 16.38C12.87 16.51 12.8 16.61 12.71 16.71C12.61 16.8 12.5 16.87 12.38 16.92C12.26 16.97 12.13 17 12 17C11.87 17 11.74 16.97 11.62 16.92C11.5 16.87 11.39 16.8 11.29 16.71C11.2 16.61 11.13 16.51 11.08 16.38C11.03 16.26 11 16.13 11 16C11 15.87 11.03 15.74 11.08 15.62C11.13 15.5 11.2 15.39 11.29 15.29C11.39 15.2 11.5 15.13 11.62 15.08C11.86 14.98 12.14 14.98 12.38 15.08C12.5 15.13 12.61 15.2 12.71 15.29C12.8 15.39 12.87 15.5 12.92 15.62C12.97 15.74 13 15.87 13 16C13 16.13 12.97 16.26 12.92 16.38Z" fill="#0096D7"/>
|
|
3
|
+
</svg>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M12 2C6.49 2 2 6.49 2 12C2 17.51 6.49 22 12 22C17.51 22 22 17.51 22 12C22 6.49 17.51 2 12 2ZM16.78 9.7L11.11 15.37C10.97 15.51 10.78 15.59 10.58 15.59C10.38 15.59 10.19 15.51 10.05 15.37L7.22 12.54C6.93 12.25 6.93 11.77 7.22 11.48C7.51 11.19 7.99 11.19 8.28 11.48L10.58 13.78L15.72 8.64C16.01 8.35 16.49 8.35 16.78 8.64C17.07 8.93 17.07 9.4 16.78 9.7Z" fill="#12B76A"/>
|
|
3
|
+
</svg>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M21.76 15.92L15.36 4.4C14.5 2.85 13.31 2 12 2C10.69 2 9.49998 2.85 8.63998 4.4L2.23998 15.92C1.42998 17.39 1.33998 18.8 1.98998 19.91C2.63998 21.02 3.91998 21.63 5.59998 21.63H18.4C20.08 21.63 21.36 21.02 22.01 19.91C22.66 18.8 22.57 17.38 21.76 15.92ZM11.25 9C11.25 8.59 11.59 8.25 12 8.25C12.41 8.25 12.75 8.59 12.75 9V14C12.75 14.41 12.41 14.75 12 14.75C11.59 14.75 11.25 14.41 11.25 14V9ZM12.71 17.71C12.66 17.75 12.61 17.79 12.56 17.83C12.5 17.87 12.44 17.9 12.38 17.92C12.32 17.95 12.26 17.97 12.19 17.98C12.13 17.99 12.06 18 12 18C11.94 18 11.87 17.99 11.8 17.98C11.74 17.97 11.68 17.95 11.62 17.92C11.56 17.9 11.5 17.87 11.44 17.83C11.39 17.79 11.34 17.75 11.29 17.71C11.11 17.52 11 17.26 11 17C11 16.74 11.11 16.48 11.29 16.29C11.34 16.25 11.39 16.21 11.44 16.17C11.5 16.13 11.56 16.1 11.62 16.08C11.68 16.05 11.74 16.03 11.8 16.02C11.93 15.99 12.07 15.99 12.19 16.02C12.26 16.03 12.32 16.05 12.38 16.08C12.44 16.1 12.5 16.13 12.56 16.17C12.61 16.21 12.66 16.25 12.71 16.29C12.89 16.48 13 16.74 13 17C13 17.26 12.89 17.52 12.71 17.71Z" fill="#FC9700"/>
|
|
3
|
+
</svg>
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M23.5 10.9833C20.725 10.7083 17.9333 10.5667 15.15 10.5667C13.5 10.5667 11.85 10.65 10.2 10.8167L8.5 10.9833" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
|
|
3
|
+
<path d="M13.0835 10.1417L13.2668 9.05C13.4002 8.25833 13.5002 7.66667 14.9085 7.66667H17.0918C18.5002 7.66667 18.6085 8.29167 18.7335 9.05833L18.9168 10.1417" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
|
|
4
|
+
<path d="M21.7087 13.6168L21.167 22.0084C21.0753 23.3168 21.0003 24.3334 18.6753 24.3334H13.3253C11.0003 24.3334 10.9253 23.3168 10.8337 22.0084L10.292 13.6168" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
|
|
5
|
+
<path d="M14.6084 19.75H17.3834" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
|
|
6
|
+
<path d="M13.9165 16.4167H18.0832" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
|
|
7
|
+
</svg>
|
|
Binary file
|
|
@@ -4,29 +4,25 @@
|
|
|
4
4
|
:class="classList"
|
|
5
5
|
>
|
|
6
6
|
<div class="base-checkbox__wrapper" @click="handleToggle">
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
class="base-checkbox__input"
|
|
14
|
-
/>
|
|
15
|
-
</div>
|
|
16
|
-
|
|
17
|
-
<div class="base-checkbox__icon-wrapper">
|
|
18
|
-
<base-icon
|
|
19
|
-
class="base-checkbox__icon"
|
|
20
|
-
name="checkbox"
|
|
21
|
-
:size="size"
|
|
7
|
+
<div class="base-checkbox__input-wrapper">
|
|
8
|
+
<input
|
|
9
|
+
v-model="model"
|
|
10
|
+
v-bind="inputAttrs"
|
|
11
|
+
type="checkbox"
|
|
12
|
+
class="base-checkbox__input"
|
|
22
13
|
/>
|
|
14
|
+
<div class="base-checkbox__icon-wrapper">
|
|
15
|
+
<base-icon
|
|
16
|
+
class="base-checkbox__icon"
|
|
17
|
+
name="checkbox"
|
|
18
|
+
size="custom"
|
|
19
|
+
/>
|
|
20
|
+
</div>
|
|
23
21
|
</div>
|
|
24
|
-
|
|
25
22
|
<div class="base-checkbox__label-wrapper">
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
</div>
|
|
23
|
+
<span v-if="label" class="base-checkbox__label">{{ label }}</span>
|
|
24
|
+
<span v-if="subLabel" class="base-checkbox__sublabel">{{ subLabel }}</span>
|
|
25
|
+
</div>
|
|
30
26
|
</div>
|
|
31
27
|
</div>
|
|
32
28
|
</template>
|
|
@@ -39,42 +35,42 @@ import { useAttrs, computed } from 'vue';
|
|
|
39
35
|
import BaseIcon from '../BaseIcon/BaseIcon.vue';
|
|
40
36
|
|
|
41
37
|
const props = withDefaults(defineProps<IBaseRadioProps>(), {
|
|
42
|
-
|
|
38
|
+
size: 'medium',
|
|
43
39
|
});
|
|
44
40
|
|
|
45
41
|
const emit = defineEmits<{
|
|
46
|
-
|
|
42
|
+
(e: 'update:modelValue', value: boolean): void;
|
|
47
43
|
}>();
|
|
48
44
|
|
|
49
45
|
const { sizeClassList } = useKitSize(props);
|
|
50
46
|
const { stateClassList, stateAttrs } = useKitState(props);
|
|
51
47
|
|
|
52
48
|
const model = computed({
|
|
53
|
-
|
|
54
|
-
|
|
49
|
+
get: () => props.modelValue,
|
|
50
|
+
set: (val) => emit('update:modelValue', val),
|
|
55
51
|
});
|
|
56
52
|
|
|
57
53
|
const attrs = useAttrs();
|
|
58
54
|
|
|
59
55
|
const inputAttrs = computed(() => {
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
56
|
+
return {
|
|
57
|
+
...attrs,
|
|
58
|
+
...stateAttrs.value,
|
|
59
|
+
id: props.id,
|
|
60
|
+
};
|
|
65
61
|
});
|
|
66
62
|
|
|
67
63
|
function handleToggle() {
|
|
68
|
-
|
|
64
|
+
model.value = !model.value;
|
|
69
65
|
}
|
|
70
66
|
|
|
71
67
|
const classList = computed(() => [
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
68
|
+
sizeClassList.value,
|
|
69
|
+
stateClassList.value,
|
|
70
|
+
{
|
|
71
|
+
'--is-active': model.value,
|
|
72
|
+
'--is-readonly': props.readonly,
|
|
73
|
+
},
|
|
78
74
|
]);
|
|
79
75
|
</script>
|
|
80
76
|
|
|
@@ -85,8 +81,6 @@ const classList = computed(() => [
|
|
|
85
81
|
.base-checkbox {
|
|
86
82
|
$item: &;
|
|
87
83
|
|
|
88
|
-
--icon-size: 18px;
|
|
89
|
-
|
|
90
84
|
&__wrapper {
|
|
91
85
|
display: flex;
|
|
92
86
|
column-gap: 10px;
|
|
@@ -99,31 +93,36 @@ const classList = computed(() => [
|
|
|
99
93
|
pointer-events: none;
|
|
100
94
|
}
|
|
101
95
|
|
|
102
|
-
&.--
|
|
96
|
+
&.--small-size {
|
|
103
97
|
#{$item} {
|
|
104
98
|
&__wrapper {
|
|
105
|
-
column-gap: var(--spacing-
|
|
99
|
+
column-gap: var(--spacing-s);
|
|
106
100
|
}
|
|
107
101
|
|
|
108
102
|
&__label {
|
|
109
|
-
font: var(--typography-text-
|
|
103
|
+
font: var(--typography-text-s-medium);
|
|
110
104
|
}
|
|
111
105
|
|
|
112
106
|
&__sublabel {
|
|
113
|
-
font: var(--typography-text-
|
|
107
|
+
font: var(--typography-text-xs-regular);
|
|
114
108
|
}
|
|
115
109
|
|
|
116
110
|
&__icon-wrapper {
|
|
117
|
-
width:
|
|
118
|
-
height:
|
|
111
|
+
width: 20px;
|
|
112
|
+
height: 20px;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
&__icon {
|
|
116
|
+
width: 15px;
|
|
117
|
+
height: 15px;
|
|
119
118
|
}
|
|
120
119
|
}
|
|
121
120
|
}
|
|
122
121
|
|
|
123
|
-
&.--
|
|
122
|
+
&.--medium-size {
|
|
124
123
|
#{$item} {
|
|
125
124
|
&__wrapper {
|
|
126
|
-
column-gap: var(--spacing-
|
|
125
|
+
column-gap: var(--spacing-m);
|
|
127
126
|
}
|
|
128
127
|
|
|
129
128
|
&__label {
|
|
@@ -138,6 +137,37 @@ const classList = computed(() => [
|
|
|
138
137
|
width: 24px;
|
|
139
138
|
height: 24px;
|
|
140
139
|
}
|
|
140
|
+
|
|
141
|
+
&__icon {
|
|
142
|
+
width: 18px;
|
|
143
|
+
height: 18px;
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
&.--large-size {
|
|
149
|
+
#{$item} {
|
|
150
|
+
&__wrapper {
|
|
151
|
+
column-gap: var(--spacing-l);
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
&__label {
|
|
155
|
+
font: var(--typography-text-m-medium);
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
&__sublabel {
|
|
159
|
+
font: var(--typography-text-s-regular);
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
&__icon-wrapper {
|
|
163
|
+
width: 32px;
|
|
164
|
+
height: 32px;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
&__icon {
|
|
168
|
+
width: 22.4px;
|
|
169
|
+
height: 22.4px;
|
|
170
|
+
}
|
|
141
171
|
}
|
|
142
172
|
}
|
|
143
173
|
|
|
@@ -52,7 +52,7 @@ const classList = computed(() => [
|
|
|
52
52
|
overflow: hidden;
|
|
53
53
|
cursor: pointer;
|
|
54
54
|
height: 100%;
|
|
55
|
-
width:
|
|
55
|
+
width: 100%;
|
|
56
56
|
background: var(--primary-black-200);
|
|
57
57
|
color: var(--primary-black-800);
|
|
58
58
|
transition: all var(--transition);
|
|
@@ -80,6 +80,8 @@ const classList = computed(() => [
|
|
|
80
80
|
display: flex;
|
|
81
81
|
align-items: center;
|
|
82
82
|
justify-content: center;
|
|
83
|
+
width: 100%;
|
|
84
|
+
height: 100%;
|
|
83
85
|
}
|
|
84
86
|
|
|
85
87
|
&.--is-active {
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="base-default-pages">
|
|
3
|
+
<div class="base-default-pages__wrapper">
|
|
4
|
+
<div
|
|
5
|
+
class="base-default-pages__image-container"
|
|
6
|
+
:class="imageContainer"
|
|
7
|
+
>
|
|
8
|
+
<img
|
|
9
|
+
:src="imagePath"
|
|
10
|
+
alt="image"
|
|
11
|
+
class="base-default-pages__image"
|
|
12
|
+
/>
|
|
13
|
+
</div>
|
|
14
|
+
<div class="base-default-pages__content">
|
|
15
|
+
<div class="base-default-pages__text-wrapper">
|
|
16
|
+
<h1 class="base-default-pages__title">{{ title }}</h1>
|
|
17
|
+
<p class="base-default-pages__description">{{ description }}</p>
|
|
18
|
+
</div>
|
|
19
|
+
<base-button
|
|
20
|
+
size="medium"
|
|
21
|
+
color="primary"
|
|
22
|
+
class="base-default-pages__button"
|
|
23
|
+
@click="$emit('click-button')"
|
|
24
|
+
>
|
|
25
|
+
{{ buttonText }}
|
|
26
|
+
</base-button>
|
|
27
|
+
</div>
|
|
28
|
+
</div>
|
|
29
|
+
</div>
|
|
30
|
+
</template>
|
|
31
|
+
|
|
32
|
+
<script setup lang="ts">
|
|
33
|
+
import { computed } from 'vue';
|
|
34
|
+
import BaseButton from '../BaseButton/BaseButton.vue';
|
|
35
|
+
import type { IDefaultPagesProps } from '../../types/default-pages';
|
|
36
|
+
|
|
37
|
+
const props = defineProps<IDefaultPagesProps>();
|
|
38
|
+
|
|
39
|
+
const imagePath = computed(()=> require(`@/assets/${props.type}.png`))
|
|
40
|
+
const imageContainer = computed<string[]>(()=> [
|
|
41
|
+
`base-default-pages__image-container--${props.type}`
|
|
42
|
+
])
|
|
43
|
+
</script>
|
|
44
|
+
|
|
45
|
+
<style scoped lang="scss">
|
|
46
|
+
@import '../../styles/variables';
|
|
47
|
+
@import '../../styles/root';
|
|
48
|
+
|
|
49
|
+
.base-default-pages {
|
|
50
|
+
&,
|
|
51
|
+
&__wrapper,
|
|
52
|
+
&__text-wrapper,
|
|
53
|
+
&__content {
|
|
54
|
+
display: flex;
|
|
55
|
+
flex-direction: column;
|
|
56
|
+
align-items: center;
|
|
57
|
+
text-align: center;
|
|
58
|
+
width: 100%;
|
|
59
|
+
height: 100%;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
&__wrapper {
|
|
63
|
+
align-items: center;
|
|
64
|
+
justify-content: center;
|
|
65
|
+
gap: var(--spacing-l);
|
|
66
|
+
max-width: 996px;
|
|
67
|
+
background: var(--bg-light);
|
|
68
|
+
padding: var(--spacing-l) 0;
|
|
69
|
+
|
|
70
|
+
@media #{$tablet} {
|
|
71
|
+
gap: 0;
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
&__title {
|
|
76
|
+
font: var(--typography-h3-medium);
|
|
77
|
+
color: var(--primary-text-primary);
|
|
78
|
+
|
|
79
|
+
@media #{$tablet} {
|
|
80
|
+
font: var(--typography-h1-medium);
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
&__description {
|
|
85
|
+
font: var(--typography-text-m-regular);
|
|
86
|
+
color: var(--primary-text-tertiary);
|
|
87
|
+
|
|
88
|
+
@media #{$tablet} {
|
|
89
|
+
font: var(--typography-h4-regular);
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
&__text-wrapper {
|
|
94
|
+
gap: var(--spacing-s);
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
&__content {
|
|
98
|
+
gap: var(--spacing-2xl);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
&__image {
|
|
102
|
+
width: 100%;
|
|
103
|
+
height: 100%;
|
|
104
|
+
object-fit: cover;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
&__image-container {
|
|
108
|
+
width: 100%;
|
|
109
|
+
height: 100%;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
&__image-container--tech-work {
|
|
113
|
+
max-width: 334px;
|
|
114
|
+
max-height: 345px;
|
|
115
|
+
|
|
116
|
+
@media #{$tablet} {
|
|
117
|
+
max-width: 595px;
|
|
118
|
+
max-height: 614px;
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
&__image-container--404 {
|
|
123
|
+
max-width: 335px;
|
|
124
|
+
max-height: 249px;
|
|
125
|
+
|
|
126
|
+
@media #{$tablet} {
|
|
127
|
+
max-width: 996px;
|
|
128
|
+
max-height: 614px;
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
&__button {
|
|
133
|
+
width: 100%;
|
|
134
|
+
|
|
135
|
+
@media #{$tablet} {
|
|
136
|
+
max-width: 335px;
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
</style>
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
# 📚 Документация компонента **BaseDefaultPages.vue**
|
|
2
|
+
|
|
3
|
+
> **Назначение** – единый «шаблон страниц» (404, технические работы и т.п.), который выводит заголовок, описание, кнопку и сопутствующую иллюстрацию.
|
|
4
|
+
> Компонент полностью стилизован через BEM‑классы, использует переменные CSS (см. `variables.scss` и `root.scss`) и поддерживает адаптивную разметку.
|
|
5
|
+
|
|
6
|
+
## <a name="api-компонента"></a>API компонента
|
|
7
|
+
|
|
8
|
+
### <a name="пропсы"></a>Пропсы
|
|
9
|
+
|
|
10
|
+
| Prop | Тип | Обязательность | Описание | Пример значения |
|
|
11
|
+
|--------------|--------------------------------------|----------------|------------------------------------------------------------------------------------------------|-----------------|
|
|
12
|
+
| `title` | `string` | **да** | Текст заголовка ( `<h1>` ). | `"Ошибка 404"` |
|
|
13
|
+
| `description`| `string` | **да** | Текст описания под заголовком ( `<p>` ). | `"Неправильно набранный адрес..."` |
|
|
14
|
+
| `buttonText` | `string` | **да** | Текст кнопки **BaseButton**. | `"На главную"` |
|
|
15
|
+
| `type` | `'tech-work' \| '404'` | **да** | Ключ, который определяет: <br>· Какой PNG‑файл будет подгружен (`tech-work.png` / `404.png`).<br>· Какой BEM‑модификатор будет добавлен к контейнеру изображения (`base-default-pages__image-container--tech-work` / `...--404`). | `'404'` |
|
|
16
|
+
|
|
17
|
+
> **Тип `type`** жестко ограничен перечислением. При добавлении нового типа необходимо расширить тип и добавить соответствующие стили/изображения (см. раздел **[Как добавить новый тип страницы]**).
|
|
18
|
+
|
|
19
|
+
### <a name="тип-iddefaultpagesprops"></a>Тип `IDefaultPagesProps`
|
|
20
|
+
|
|
21
|
+
```ts
|
|
22
|
+
/**
|
|
23
|
+
* Параметры компонента BaseDefaultPages.
|
|
24
|
+
*
|
|
25
|
+
* @property {string} title Заголовок страницы.
|
|
26
|
+
* @property {string} description Описание (подзаголовок).
|
|
27
|
+
* @property {string} buttonText Текст кнопки.
|
|
28
|
+
* @property {'tech-work'|'404'} type Тип страницы, определяющий изображение и размеры.
|
|
29
|
+
*/
|
|
30
|
+
export interface IDefaultPagesProps {
|
|
31
|
+
title: string;
|
|
32
|
+
description: string;
|
|
33
|
+
buttonText: string;
|
|
34
|
+
type: 'tech-work' | '404';
|
|
35
|
+
}
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
### <a name="вычисляемые-свойства"></a>Внутренние вычисляемые свойства
|
|
39
|
+
|
|
40
|
+
| Свойство | Тип | Описание |
|
|
41
|
+
|----------|------|----------|
|
|
42
|
+
| `imagePath` | `ComputedRef<string>` | Генерирует путь к изображению: `require('@/assets/${props.type}.png')`. При смене `type` автоматически меняет изображение. |
|
|
43
|
+
| `imageContainer` | `ComputedRef<string[]>` | Возвращает массив CSS‑классов, включающий модификатор: `['base-default-pages__image-container--${props.type}']`. Позволяет менять размеры контейнера в зависимости от типа. |
|
|
44
|
+
|
|
45
|
+
---
|
|
46
|
+
|
|
47
|
+
## <a name="пример-использования"></a>Пример использования
|
|
48
|
+
|
|
49
|
+
```vue
|
|
50
|
+
<!-- DemoPage.vue -->
|
|
51
|
+
<template>
|
|
52
|
+
<div class="demo-page">
|
|
53
|
+
<h1>Plugin UI KZT – Компоненты</h1>
|
|
54
|
+
|
|
55
|
+
<section class="pages-list">
|
|
56
|
+
<!-- 404 -->
|
|
57
|
+
<BaseDefaultPages v-bind="data404" @click-button="goHome" />
|
|
58
|
+
|
|
59
|
+
<!-- Технические работы -->
|
|
60
|
+
<BaseDefaultPages v-bind="dataTechWork" @click-button="goHome" />
|
|
61
|
+
</section>
|
|
62
|
+
</div>
|
|
63
|
+
</template>
|
|
64
|
+
|
|
65
|
+
<script setup lang="ts">
|
|
66
|
+
import { ref } from 'vue';
|
|
67
|
+
import BaseDefaultPages from '@/components/BaseDefaultPages/BaseDefaultPages.vue';
|
|
68
|
+
|
|
69
|
+
const data404 = ref({
|
|
70
|
+
title: 'Ошибка 404',
|
|
71
|
+
description:
|
|
72
|
+
'Неправильно набранный адрес, или такой страницы больше не существует',
|
|
73
|
+
buttonText: 'На главную',
|
|
74
|
+
type: '404',
|
|
75
|
+
});
|
|
76
|
+
|
|
77
|
+
const dataTechWork = ref({
|
|
78
|
+
title: 'Технические работы',
|
|
79
|
+
description: 'Приносим свои извинения, попробуйте зайти позже',
|
|
80
|
+
buttonText: 'На главную',
|
|
81
|
+
type: 'tech-work',
|
|
82
|
+
});
|
|
83
|
+
|
|
84
|
+
// Пример простого навигационного обратного вызова
|
|
85
|
+
const goHome = () => {
|
|
86
|
+
// например, router.push('/')
|
|
87
|
+
console.log('Перенаправление на главную');
|
|
88
|
+
};
|
|
89
|
+
</script>
|
|
90
|
+
|
|
91
|
+
<style scoped lang="scss">
|
|
92
|
+
.demo-page {
|
|
93
|
+
padding: var(--spacing-l);
|
|
94
|
+
}
|
|
95
|
+
.pages-list {
|
|
96
|
+
display: flex;
|
|
97
|
+
flex-direction: column;
|
|
98
|
+
gap: var(--spacing-2xl);
|
|
99
|
+
}
|
|
100
|
+
</style>
|
|
101
|
+
|
|
102
|
+
## <a name="как-добавить-новый-тип-страницы"></a>Как добавить новый тип страницы
|
|
103
|
+
|
|
104
|
+
1. **Добавьте PNG‑файл** в каталог `src/assets/` с именем `<new-type>.png` (например, `maintenance.png`).
|
|
105
|
+
2. **Обновите тип пропса** в `IDefaultPagesProps`:
|
|
106
|
+
|
|
107
|
+
```ts
|
|
108
|
+
export interface IDefaultPagesProps {
|
|
109
|
+
// …
|
|
110
|
+
type: 'tech-work' | '404' | 'maintenance';
|
|
111
|
+
}
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
3. **Создайте/добавьте модификатор** в SCSS:
|
|
115
|
+
|
|
116
|
+
```scss
|
|
117
|
+
.base-default-pages__image-container--maintenance {
|
|
118
|
+
max-width: 400px;
|
|
119
|
+
max-height: 300px;
|
|
120
|
+
|
|
121
|
+
@media #{$tablet} {
|
|
122
|
+
max-width: 800px;
|
|
123
|
+
max-height: 600px;
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
4. **(Опционально) Добавьте адаптивные стили** для заголовка/описания, если требуется особый дизайн.
|
|
@@ -157,7 +157,7 @@ const actualComponent = computed(() => {
|
|
|
157
157
|
#{$item} {
|
|
158
158
|
&__wrapper {
|
|
159
159
|
gap: var(--spacing-s);
|
|
160
|
-
height: 40px;
|
|
160
|
+
min-height: 40px;
|
|
161
161
|
padding: var(--spacing-s) var(--spacing-2l);
|
|
162
162
|
}
|
|
163
163
|
|
|
@@ -177,7 +177,7 @@ const actualComponent = computed(() => {
|
|
|
177
177
|
#{$item} {
|
|
178
178
|
&__wrapper {
|
|
179
179
|
gap: var(--spacing-m);
|
|
180
|
-
height: 48px;
|
|
180
|
+
min-height: 48px;
|
|
181
181
|
padding: var(--spacing-m) var(--spacing-2l);
|
|
182
182
|
}
|
|
183
183
|
|
|
@@ -197,7 +197,7 @@ const actualComponent = computed(() => {
|
|
|
197
197
|
#{$item} {
|
|
198
198
|
&__wrapper {
|
|
199
199
|
gap: var(--spacing-l);
|
|
200
|
-
height: 60px;
|
|
200
|
+
min-height: 60px;
|
|
201
201
|
padding: var(--spacing-2l) var(--spacing-l);
|
|
202
202
|
}
|
|
203
203
|
|