@winchsa/ui 0.1.31 → 0.1.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.
- package/package.json +1 -1
- package/dist/components/Breadcrumbs.d.vue.ts +0 -7
- package/dist/components/Breadcrumbs.vue +0 -46
- package/dist/components/Breadcrumbs.vue.d.ts +0 -7
- package/dist/components/CustomizerSection.d.vue.ts +0 -17
- package/dist/components/CustomizerSection.vue +0 -19
- package/dist/components/CustomizerSection.vue.d.ts +0 -17
- package/dist/components/DialogCloseBtn.d.vue.ts +0 -7
- package/dist/components/DialogCloseBtn.vue +0 -20
- package/dist/components/DialogCloseBtn.vue.d.ts +0 -7
- package/dist/components/Drawer.d.vue.ts +0 -28
- package/dist/components/Drawer.vue +0 -60
- package/dist/components/Drawer.vue.d.ts +0 -28
- package/dist/components/IconBtn.d.vue.ts +0 -18
- package/dist/components/IconBtn.vue +0 -24
- package/dist/components/IconBtn.vue.d.ts +0 -18
- package/dist/components/LoadingBar.d.vue.ts +0 -6
- package/dist/components/LoadingBar.vue +0 -31
- package/dist/components/LoadingBar.vue.d.ts +0 -6
- package/dist/components/LoadingDialog.d.vue.ts +0 -12
- package/dist/components/LoadingDialog.vue +0 -41
- package/dist/components/LoadingDialog.vue.d.ts +0 -12
- package/dist/components/LoadingItem.d.vue.ts +0 -25
- package/dist/components/LoadingItem.vue +0 -66
- package/dist/components/LoadingItem.vue.d.ts +0 -25
- package/dist/components/Modal.d.vue.ts +0 -50
- package/dist/components/Modal.vue +0 -155
- package/dist/components/Modal.vue.d.ts +0 -50
- package/dist/components/MoreBtn.d.vue.ts +0 -17
- package/dist/components/MoreBtn.vue +0 -28
- package/dist/components/MoreBtn.vue.d.ts +0 -17
- package/dist/components/ScrollToTop.d.vue.ts +0 -3
- package/dist/components/ScrollToTop.vue +0 -39
- package/dist/components/ScrollToTop.vue.d.ts +0 -3
- package/dist/components/SiteTitle.d.vue.ts +0 -3
- package/dist/components/SiteTitle.vue +0 -14
- package/dist/components/SiteTitle.vue.d.ts +0 -3
- package/dist/components/Toaster.d.vue.ts +0 -6
- package/dist/components/Toaster.vue +0 -19
- package/dist/components/Toaster.vue.d.ts +0 -6
- package/dist/components/cards/AppCard.d.vue.ts +0 -18
- package/dist/components/cards/AppCard.vue +0 -45
- package/dist/components/cards/AppCard.vue.d.ts +0 -18
- package/dist/components/cards/AppCardActions.d.vue.ts +0 -33
- package/dist/components/cards/AppCardActions.vue +0 -126
- package/dist/components/cards/AppCardActions.vue.d.ts +0 -33
- package/dist/components/cards/CardStatisticsHorizontal.d.vue.ts +0 -9
- package/dist/components/cards/CardStatisticsHorizontal.vue +0 -29
- package/dist/components/cards/CardStatisticsHorizontal.vue.d.ts +0 -9
- package/dist/components/cards/CheckboxesCard.d.vue.ts +0 -18
- package/dist/components/cards/CheckboxesCard.vue +0 -108
- package/dist/components/cards/CheckboxesCard.vue.d.ts +0 -18
- package/dist/components/cards/HeaderCard.d.vue.ts +0 -9
- package/dist/components/cards/HeaderCard.vue +0 -31
- package/dist/components/cards/HeaderCard.vue.d.ts +0 -9
- package/dist/components/cards/ImageCard.d.vue.ts +0 -33
- package/dist/components/cards/ImageCard.vue +0 -73
- package/dist/components/cards/ImageCard.vue.d.ts +0 -33
- package/dist/components/cards/InputCard.d.vue.ts +0 -21
- package/dist/components/cards/InputCard.vue +0 -60
- package/dist/components/cards/InputCard.vue.d.ts +0 -21
- package/dist/components/cards/StaticCard.d.vue.ts +0 -21
- package/dist/components/cards/StaticCard.vue +0 -37
- package/dist/components/cards/StaticCard.vue.d.ts +0 -21
- package/dist/components/forms/Accordion.d.vue.ts +0 -19
- package/dist/components/forms/Accordion.vue +0 -43
- package/dist/components/forms/Accordion.vue.d.ts +0 -19
- package/dist/components/forms/AppBarSearch.d.vue.ts +0 -43
- package/dist/components/forms/AppBarSearch.vue +0 -345
- package/dist/components/forms/AppBarSearch.vue.d.ts +0 -43
- package/dist/components/forms/AppCombobox.d.vue.ts +0 -13
- package/dist/components/forms/AppCombobox.vue +0 -67
- package/dist/components/forms/AppCombobox.vue.d.ts +0 -13
- package/dist/components/forms/AppDrawerHeaderSection.d.vue.ts +0 -20
- package/dist/components/forms/AppDrawerHeaderSection.vue +0 -21
- package/dist/components/forms/AppDrawerHeaderSection.vue.d.ts +0 -20
- package/dist/components/forms/AppLabel.d.vue.ts +0 -24
- package/dist/components/forms/AppLabel.vue +0 -47
- package/dist/components/forms/AppLabel.vue.d.ts +0 -24
- package/dist/components/forms/AppLink.d.vue.ts +0 -19
- package/dist/components/forms/AppLink.vue +0 -50
- package/dist/components/forms/AppLink.vue.d.ts +0 -19
- package/dist/components/forms/AppNumberField.d.vue.ts +0 -20
- package/dist/components/forms/AppNumberField.vue +0 -85
- package/dist/components/forms/AppNumberField.vue.d.ts +0 -20
- package/dist/components/forms/AppOtpInput.d.vue.ts +0 -13
- package/dist/components/forms/AppOtpInput.vue +0 -84
- package/dist/components/forms/AppOtpInput.vue.d.ts +0 -13
- package/dist/components/forms/AppSearchHeader.d.vue.ts +0 -8
- package/dist/components/forms/AppSearchHeader.vue +0 -72
- package/dist/components/forms/AppSearchHeader.vue.d.ts +0 -8
- package/dist/components/forms/AppSelect.d.vue.ts +0 -17
- package/dist/components/forms/AppSelect.vue +0 -98
- package/dist/components/forms/AppSelect.vue.d.ts +0 -17
- package/dist/components/forms/AppStepper.d.vue.ts +0 -21
- package/dist/components/forms/AppStepper.vue +0 -232
- package/dist/components/forms/AppStepper.vue.d.ts +0 -21
- package/dist/components/forms/AppSwitch.d.vue.ts +0 -16
- package/dist/components/forms/AppSwitch.vue +0 -59
- package/dist/components/forms/AppSwitch.vue.d.ts +0 -16
- package/dist/components/forms/AppTextField.d.vue.ts +0 -13
- package/dist/components/forms/AppTextField.vue +0 -66
- package/dist/components/forms/AppTextField.vue.d.ts +0 -13
- package/dist/components/forms/AppTextarea.d.vue.ts +0 -13
- package/dist/components/forms/AppTextarea.vue +0 -69
- package/dist/components/forms/AppTextarea.vue.d.ts +0 -13
- package/dist/components/forms/AttachmentCropperInput.d.vue.ts +0 -18
- package/dist/components/forms/AttachmentCropperInput.vue +0 -227
- package/dist/components/forms/AttachmentCropperInput.vue.d.ts +0 -18
- package/dist/components/forms/AttachmentInput.d.vue.ts +0 -16
- package/dist/components/forms/AttachmentInput.vue +0 -116
- package/dist/components/forms/AttachmentInput.vue.d.ts +0 -16
- package/dist/components/forms/AutocompleteInput.d.vue.ts +0 -84
- package/dist/components/forms/AutocompleteInput.vue +0 -760
- package/dist/components/forms/AutocompleteInput.vue.d.ts +0 -84
- package/dist/components/forms/BankSelect.d.vue.ts +0 -21
- package/dist/components/forms/BankSelect.vue +0 -43
- package/dist/components/forms/BankSelect.vue.d.ts +0 -21
- package/dist/components/forms/BaseButton.d.vue.ts +0 -20
- package/dist/components/forms/BaseButton.vue +0 -42
- package/dist/components/forms/BaseButton.vue.d.ts +0 -20
- package/dist/components/forms/CounterInput.d.vue.ts +0 -13
- package/dist/components/forms/CounterInput.vue +0 -71
- package/dist/components/forms/CounterInput.vue.d.ts +0 -13
- package/dist/components/forms/CustomCheckboxes.d.vue.ts +0 -25
- package/dist/components/forms/CustomCheckboxes.vue +0 -69
- package/dist/components/forms/CustomCheckboxes.vue.d.ts +0 -25
- package/dist/components/forms/CustomCheckboxesWithIcon.d.vue.ts +0 -25
- package/dist/components/forms/CustomCheckboxesWithIcon.vue +0 -80
- package/dist/components/forms/CustomCheckboxesWithIcon.vue.d.ts +0 -25
- package/dist/components/forms/CustomCheckboxesWithImage.d.vue.ts +0 -16
- package/dist/components/forms/CustomCheckboxesWithImage.vue +0 -67
- package/dist/components/forms/CustomCheckboxesWithImage.vue.d.ts +0 -16
- package/dist/components/forms/CustomRadios.d.vue.ts +0 -25
- package/dist/components/forms/CustomRadios.vue +0 -69
- package/dist/components/forms/CustomRadios.vue.d.ts +0 -25
- package/dist/components/forms/CustomRadiosWithIcon.d.vue.ts +0 -28
- package/dist/components/forms/CustomRadiosWithIcon.vue +0 -98
- package/dist/components/forms/CustomRadiosWithIcon.vue.d.ts +0 -28
- package/dist/components/forms/CustomRadiosWithImage.d.vue.ts +0 -35
- package/dist/components/forms/CustomRadiosWithImage.vue +0 -69
- package/dist/components/forms/CustomRadiosWithImage.vue.d.ts +0 -35
- package/dist/components/forms/DatePicker.d.vue.ts +0 -29
- package/dist/components/forms/DatePicker.vue +0 -400
- package/dist/components/forms/DatePicker.vue.d.ts +0 -29
- package/dist/components/forms/DatePickerRange.d.vue.ts +0 -24
- package/dist/components/forms/DatePickerRange.vue +0 -127
- package/dist/components/forms/DatePickerRange.vue.d.ts +0 -24
- package/dist/components/forms/DraggedUploadFile.d.vue.ts +0 -11
- package/dist/components/forms/DraggedUploadFile.vue +0 -120
- package/dist/components/forms/DraggedUploadFile.vue.d.ts +0 -11
- package/dist/components/forms/ImageCardInput.d.vue.ts +0 -35
- package/dist/components/forms/ImageCardInput.vue +0 -234
- package/dist/components/forms/ImageCardInput.vue.d.ts +0 -35
- package/dist/components/forms/InputValidationWrapper.d.vue.ts +0 -26
- package/dist/components/forms/InputValidationWrapper.vue +0 -24
- package/dist/components/forms/InputValidationWrapper.vue.d.ts +0 -26
- package/dist/components/forms/LicensePlateInput.d.vue.ts +0 -21
- package/dist/components/forms/LicensePlateInput.vue +0 -175
- package/dist/components/forms/LicensePlateInput.vue.d.ts +0 -21
- package/dist/components/forms/ManualDate.d.vue.ts +0 -20
- package/dist/components/forms/ManualDate.vue +0 -264
- package/dist/components/forms/ManualDate.vue.d.ts +0 -20
- package/dist/components/forms/MobileInput.d.vue.ts +0 -25
- package/dist/components/forms/MobileInput.vue +0 -118
- package/dist/components/forms/MobileInput.vue.d.ts +0 -25
- package/dist/components/forms/PasswordInput.d.vue.ts +0 -11
- package/dist/components/forms/PasswordInput.vue +0 -29
- package/dist/components/forms/PasswordInput.vue.d.ts +0 -11
- package/dist/components/forms/RangeInput.d.vue.ts +0 -10
- package/dist/components/forms/RangeInput.vue +0 -48
- package/dist/components/forms/RangeInput.vue.d.ts +0 -10
- package/dist/components/forms/Tabs.d.vue.ts +0 -23
- package/dist/components/forms/Tabs.vue +0 -35
- package/dist/components/forms/Tabs.vue.d.ts +0 -23
- package/dist/components/forms/TimePicker.d.vue.ts +0 -18
- package/dist/components/forms/TimePicker.vue +0 -370
- package/dist/components/forms/TimePicker.vue.d.ts +0 -18
- package/dist/components/table/DataTable.d.vue.ts +0 -70
- package/dist/components/table/DataTable.vue +0 -361
- package/dist/components/table/DataTable.vue.d.ts +0 -70
- package/dist/components/table/EditableDataTable.d.vue.ts +0 -21
- package/dist/components/table/EditableDataTable.vue +0 -330
- package/dist/components/table/EditableDataTable.vue.d.ts +0 -21
- package/dist/components/table/EditableDataTableRow.d.vue.ts +0 -20
- package/dist/components/table/EditableDataTableRow.vue +0 -253
- package/dist/components/table/EditableDataTableRow.vue.d.ts +0 -20
- package/dist/components/table/FilterGenerator.d.vue.ts +0 -13
- package/dist/components/table/FilterGenerator.vue +0 -231
- package/dist/components/table/FilterGenerator.vue.d.ts +0 -13
- package/dist/components/table/StaticTable.d.vue.ts +0 -34
- package/dist/components/table/StaticTable.vue +0 -152
- package/dist/components/table/StaticTable.vue.d.ts +0 -34
- package/dist/components/table/TablePagination.d.vue.ts +0 -15
- package/dist/components/table/TablePagination.vue +0 -73
- package/dist/components/table/TablePagination.vue.d.ts +0 -15
- package/dist/composables/useIsMobile.d.ts +0 -1
- package/dist/composables/useIsMobile.js +0 -10
- package/dist/composables/useIsMobile.mjs +0 -4
- package/dist/composables/useTableFilters.d.ts +0 -23
- package/dist/composables/useTableFilters.js +0 -197
- package/dist/composables/useTableFilters.mjs +0 -184
- package/dist/images/avatar.png +0 -0
- package/dist/images/sa.svg +0 -1
- package/dist/index.d.ts +0 -65
- package/dist/index.js +0 -454
- package/dist/index.mjs +0 -130
- package/dist/lang/ar.json +0 -54
- package/dist/lang/en.json +0 -54
- package/dist/styles/assets/scss/variables/_template.scss +0 -1
- package/dist/styles/assets/scss/variables/_vuetify.scss +0 -1
- package/dist/styles/core/base/_components.scss +0 -164
- package/dist/styles/core/base/_dark.scss +0 -16
- package/dist/styles/core/base/_default-layout-w-vertical-nav.scss +0 -106
- package/dist/styles/core/base/_default-layout.scss +0 -16
- package/dist/styles/core/base/_index.scss +0 -47
- package/dist/styles/core/base/_layouts.scss +0 -63
- package/dist/styles/core/base/_misc.scss +0 -20
- package/dist/styles/core/base/_mixins.scss +0 -84
- package/dist/styles/core/base/_route-transitions.scss +0 -70
- package/dist/styles/core/base/_utilities.scss +0 -418
- package/dist/styles/core/base/_utils.scss +0 -100
- package/dist/styles/core/base/_variables.scss +0 -190
- package/dist/styles/core/base/_vertical-nav.scss +0 -264
- package/dist/styles/core/base/libs/_perfect-scrollbar.scss +0 -35
- package/dist/styles/core/base/libs/vuetify/_index.scss +0 -1
- package/dist/styles/core/base/libs/vuetify/_overrides.scss +0 -380
- package/dist/styles/core/base/libs/vuetify/_variables.scss +0 -48
- package/dist/styles/core/base/placeholders/_default-layout-vertical-nav.scss +0 -48
- package/dist/styles/core/base/placeholders/_default-layout.scss +0 -3
- package/dist/styles/core/base/placeholders/_index.scss +0 -5
- package/dist/styles/core/base/placeholders/_misc.scss +0 -7
- package/dist/styles/core/base/placeholders/_nav.scss +0 -26
- package/dist/styles/core/base/placeholders/_vertical-nav.scss +0 -84
- package/dist/styles/core/base/skins/_bordered.scss +0 -60
- package/dist/styles/core/base/skins/_index.scss +0 -1
- package/dist/styles/core/template/_components.scss +0 -1035
- package/dist/styles/core/template/_default-layout-w-vertical-nav.scss +0 -20
- package/dist/styles/core/template/_utilities.scss +0 -20
- package/dist/styles/core/template/_variables.scss +0 -67
- package/dist/styles/core/template/_vertical-nav.scss +0 -41
- package/dist/styles/core/template/index.css +0 -18779
- package/dist/styles/core/template/index.scss +0 -15
- package/dist/styles/core/template/libs/vuetify/_variables.scss +0 -464
- package/dist/styles/core/template/libs/vuetify/index.css +0 -739
- package/dist/styles/core/template/libs/vuetify/index.scss +0 -1
- package/dist/styles/core/template/pages/misc.css +0 -16
- package/dist/styles/core/template/pages/misc.scss +0 -20
- package/dist/styles/core/template/placeholders/_default-layout-vertical-nav.scss +0 -9
- package/dist/styles/core/template/placeholders/_index.scss +0 -3
- package/dist/styles/core/template/placeholders/_nav.scss +0 -15
- package/dist/styles/core/template/placeholders/_vertical-nav.scss +0 -18
- package/dist/styles/core/template/skins/_bordered.scss +0 -36
- package/dist/styles/core/template/skins/_index.scss +0 -1
- package/dist/styles/layouts/_classes.scss +0 -3
- package/dist/styles/layouts/_dashboard-layout.scss +0 -43
- package/dist/styles/layouts/_global.scss +0 -10
- package/dist/styles/layouts/_mixins.scss +0 -28
- package/dist/styles/layouts/_placeholders.scss +0 -53
- package/dist/styles/layouts/_rtl.scss +0 -7
- package/dist/styles/layouts/_variables.scss +0 -22
- package/dist/styles/layouts/index.css +0 -14
- package/dist/styles/layouts/index.scss +0 -2
- package/dist/types.d.ts +0 -218
- package/dist/utils/apiUrl.d.ts +0 -1
- package/dist/utils/apiUrl.js +0 -15
- package/dist/utils/apiUrl.mjs +0 -8
- package/dist/utils/client.d.ts +0 -9
- package/dist/utils/client.js +0 -53
- package/dist/utils/client.mjs +0 -39
- package/dist/utils/files.d.ts +0 -2
- package/dist/utils/files.js +0 -35
- package/dist/utils/files.mjs +0 -22
- package/dist/utils/formValidation.d.ts +0 -7
- package/dist/utils/formValidation.js +0 -20
- package/dist/utils/formValidation.mjs +0 -13
- package/dist/utils/formatters.d.ts +0 -12
- package/dist/utils/formatters.js +0 -84
- package/dist/utils/formatters.mjs +0 -56
- package/dist/utils/hijriDate.d.ts +0 -58
- package/dist/utils/hijriDate.js +0 -168
- package/dist/utils/hijriDate.mjs +0 -1951
- package/dist/utils/i18n.d.ts +0 -8
- package/dist/utils/i18n.js +0 -36
- package/dist/utils/i18n.mjs +0 -27
- package/dist/utils/index.d.ts +0 -10
- package/dist/utils/index.js +0 -115
- package/dist/utils/index.mjs +0 -10
- package/dist/utils/queryParams.d.ts +0 -4
- package/dist/utils/queryParams.js +0 -26
- package/dist/utils/queryParams.mjs +0 -18
- package/dist/utils/ruleValidator.d.ts +0 -41
- package/dist/utils/ruleValidator.js +0 -210
- package/dist/utils/ruleValidator.mjs +0 -195
- package/dist/utils/toaster.d.ts +0 -12
- package/dist/utils/toaster.js +0 -68
- package/dist/utils/toaster.mjs +0 -58
- package/dist/utils/utils.d.ts +0 -9
- package/dist/utils/utils.js +0 -84
- package/dist/utils/utils.mjs +0 -67
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
.layout-blank .misc-wrapper {
|
|
2
|
-
display: flex;
|
|
3
|
-
flex-direction: column;
|
|
4
|
-
align-items: center;
|
|
5
|
-
justify-content: center;
|
|
6
|
-
padding: 1.25rem;
|
|
7
|
-
min-block-size: calc(var(--vh, 1vh) * 100);
|
|
8
|
-
}
|
|
9
|
-
.layout-blank .misc-avatar {
|
|
10
|
-
z-index: 1;
|
|
11
|
-
}
|
|
12
|
-
.layout-blank .misc-footer-img {
|
|
13
|
-
position: absolute;
|
|
14
|
-
inline-size: 100%;
|
|
15
|
-
inset-block-end: 0;
|
|
16
|
-
}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
.layout-blank {
|
|
2
|
-
.misc-wrapper {
|
|
3
|
-
display: flex;
|
|
4
|
-
flex-direction: column;
|
|
5
|
-
align-items: center;
|
|
6
|
-
justify-content: center;
|
|
7
|
-
padding: 1.25rem;
|
|
8
|
-
min-block-size: calc(var(--vh, 1vh) * 100);
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
.misc-avatar {
|
|
12
|
-
z-index: 1;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
.misc-footer-img {
|
|
16
|
-
position: absolute;
|
|
17
|
-
inline-size: 100%;
|
|
18
|
-
inset-block-end: 0;
|
|
19
|
-
}
|
|
20
|
-
}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
@use '../../../core/template/variables' as variables;
|
|
2
|
-
|
|
3
|
-
%default-layout-vertical-nav-floating-navbar-and-sticky-elevated-navbar-scrolled {
|
|
4
|
-
// If navbar is contained => Squeeze navbar content on scroll
|
|
5
|
-
@if variables.$layout-vertical-nav-navbar-is-contained {
|
|
6
|
-
padding-inline-start: 12px;
|
|
7
|
-
padding-inline-end: 24px;
|
|
8
|
-
}
|
|
9
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
// ℹ️ This is common style that needs to be applied to both navs
|
|
2
|
-
%nav {
|
|
3
|
-
color: rgba(var(--v-theme-on-surface), var(--v-medium-emphasis-opacity));
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
/*
|
|
7
|
-
Active nav link styles for horizontal & vertical nav
|
|
8
|
-
|
|
9
|
-
For horizontal nav it will be only applied to top level nav items
|
|
10
|
-
For vertical nav it will be only applied to nav links (not nav groups)
|
|
11
|
-
*/
|
|
12
|
-
%nav-link-active {
|
|
13
|
-
background: rgb(var(--v-nav-background)) !important;
|
|
14
|
-
font-weight: 500;
|
|
15
|
-
}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
// Common styles for nav item icon styles
|
|
2
|
-
// ℹ️ Nav group's children icon styles are not here (Adjusts height, width & margin)
|
|
3
|
-
%vertical-nav-items-icon {
|
|
4
|
-
font-size: 1.375rem;
|
|
5
|
-
margin-inline-start: 0.3rem;
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
// Vertical nav item badge styles
|
|
9
|
-
%vertical-nav-item-badge {
|
|
10
|
-
line-height: 1rem;
|
|
11
|
-
margin-inline-end: 0.5rem;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
// This is same as `%vertical-nav-item` except section title is excluded
|
|
15
|
-
%vertical-nav-item-interactive {
|
|
16
|
-
block-size: 2.375rem;
|
|
17
|
-
margin-block-end: 0.25rem;
|
|
18
|
-
}
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
@use 'sass:map';
|
|
2
|
-
@use '../../base/mixins';
|
|
3
|
-
@use '../../../core/template/variables' as variables;
|
|
4
|
-
|
|
5
|
-
$header: '.layout-navbar';
|
|
6
|
-
|
|
7
|
-
@if variables.$layout-vertical-nav-navbar-is-contained {
|
|
8
|
-
$header: '.layout-navbar .navbar-content-container';
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
.skin--bordered {
|
|
12
|
-
// Expansion Panels
|
|
13
|
-
@include mixins.bordered-skin(
|
|
14
|
-
'.v-expansion-panels:not(.expansion-panels-width-border) .v-expansion-panel, .v-expansion-panel__shadow'
|
|
15
|
-
);
|
|
16
|
-
|
|
17
|
-
// Navbar
|
|
18
|
-
|
|
19
|
-
// -- Vertical
|
|
20
|
-
@if variables.$layout-vertical-nav-navbar-is-contained {
|
|
21
|
-
@include mixins.bordered-skin('.layout-nav-type-vertical #{$header}');
|
|
22
|
-
.layout-nav-type-vertical.window-scrolled #{$header} {
|
|
23
|
-
border-block-start: 1px solid rgba(var(--v-border-color), var(--v-border-opacity)) !important;
|
|
24
|
-
}
|
|
25
|
-
} @else {
|
|
26
|
-
@include mixins.bordered-skin('.layout-nav-type-vertical #{$header}', 'border-bottom');
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
// Dialog close button
|
|
30
|
-
@include mixins.bordered-skin('.v-dialog-close-btn');
|
|
31
|
-
|
|
32
|
-
// Vertical Nav
|
|
33
|
-
.layout-vertical-nav {
|
|
34
|
-
box-shadow: none;
|
|
35
|
-
}
|
|
36
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
@use 'bordered';
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
// These are styles which are both common in layout w/ vertical nav & horizontal nav
|
|
2
|
-
@use 'rtl';
|
|
3
|
-
@use 'placeholders';
|
|
4
|
-
@use 'mixins';
|
|
5
|
-
@use '../assets/scss/variables/template' as variables;
|
|
6
|
-
|
|
7
|
-
html,
|
|
8
|
-
body {
|
|
9
|
-
min-block-size: 100%;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.layout-page-content {
|
|
13
|
-
@include mixins.boxed-content(true);
|
|
14
|
-
|
|
15
|
-
flex-grow: 1;
|
|
16
|
-
|
|
17
|
-
// TODO: Use grid gutter variable here
|
|
18
|
-
padding-block: 1.5rem;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
.layout-footer {
|
|
22
|
-
.footer-content-container {
|
|
23
|
-
block-size: variables.$layout-vertical-nav-footer-height;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
.layout-footer-sticky & {
|
|
27
|
-
position: sticky;
|
|
28
|
-
inset-block-end: 0;
|
|
29
|
-
will-change: transform;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
.layout-footer-hidden & {
|
|
33
|
-
display: none;
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
[dir='ltr'] [data-sonner-toaster][data-x-position='center'] {
|
|
38
|
-
left: calc(50%) !important;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
[dir='rtl'] [data-sonner-toaster][data-x-position='center'] {
|
|
42
|
-
left: calc(50%) !important;
|
|
43
|
-
}
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
@use 'placeholders';
|
|
2
|
-
@use '../assets/scss/variables/template' as variables;
|
|
3
|
-
|
|
4
|
-
@mixin rtl {
|
|
5
|
-
@if variables.$enable-rtl-styles {
|
|
6
|
-
[dir='rtl'] & {
|
|
7
|
-
@content;
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
@mixin boxed-content($nest-selector: false) {
|
|
13
|
-
& {
|
|
14
|
-
@extend %boxed-content-spacing;
|
|
15
|
-
|
|
16
|
-
@at-root {
|
|
17
|
-
@if $nest-selector == false {
|
|
18
|
-
.layout-content-width-boxed#{&} {
|
|
19
|
-
@extend %boxed-content;
|
|
20
|
-
}
|
|
21
|
-
} @else {
|
|
22
|
-
.layout-content-width-boxed & {
|
|
23
|
-
@extend %boxed-content;
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
}
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
// placeholders
|
|
2
|
-
@use '../assets/scss/variables/template' as variables;
|
|
3
|
-
|
|
4
|
-
%boxed-content {
|
|
5
|
-
@at-root #{&}-spacing {
|
|
6
|
-
// TODO: Use grid gutter variable here
|
|
7
|
-
padding-inline: 1.5rem;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
inline-size: 100%;
|
|
11
|
-
margin-inline: auto;
|
|
12
|
-
max-inline-size: variables.$layout-boxed-content-width;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
%layout-navbar-hidden {
|
|
16
|
-
display: none;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
// ℹ️ We created this placeholder even it is being used in just layout w/ vertical nav because in future we might apply style to both navbar & horizontal nav separately
|
|
20
|
-
%layout-navbar-sticky {
|
|
21
|
-
position: sticky;
|
|
22
|
-
inset-block-start: 0;
|
|
23
|
-
|
|
24
|
-
// will-change: transform;
|
|
25
|
-
// inline-size: 100%;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
%style-scroll-bar {
|
|
29
|
-
/* width */
|
|
30
|
-
|
|
31
|
-
&::-webkit-scrollbar {
|
|
32
|
-
background: rgb(var(--v-theme-surface));
|
|
33
|
-
block-size: 8px;
|
|
34
|
-
border-end-end-radius: 14px;
|
|
35
|
-
border-start-end-radius: 14px;
|
|
36
|
-
inline-size: 4px;
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
/* Track */
|
|
40
|
-
&::-webkit-scrollbar-track {
|
|
41
|
-
background: transparent;
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
/* Handle */
|
|
45
|
-
&::-webkit-scrollbar-thumb {
|
|
46
|
-
border-radius: 0.5rem;
|
|
47
|
-
background: rgb(var(--v-theme-silver));
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
&::-webkit-scrollbar-corner {
|
|
51
|
-
display: none;
|
|
52
|
-
}
|
|
53
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
// Vertical nav
|
|
2
|
-
$layout-vertical-nav-z-index: 12 !default;
|
|
3
|
-
$layout-vertical-nav-width: 260px !default;
|
|
4
|
-
$layout-vertical-nav-collapsed-width: 84px !default;
|
|
5
|
-
|
|
6
|
-
// Navbar
|
|
7
|
-
$layout-vertical-nav-navbar-height: 64px !default;
|
|
8
|
-
$layout-vertical-nav-navbar-is-contained: true !default;
|
|
9
|
-
$layout-vertical-nav-layout-navbar-z-index: 11 !default;
|
|
10
|
-
$layout-horizontal-nav-layout-navbar-z-index: 11 !default;
|
|
11
|
-
|
|
12
|
-
// Main content
|
|
13
|
-
$layout-boxed-content-width: 1440px !default;
|
|
14
|
-
|
|
15
|
-
// Footer
|
|
16
|
-
$layout-vertical-nav-footer-height: 56px !default;
|
|
17
|
-
|
|
18
|
-
// Layout overlay
|
|
19
|
-
$layout-overlay-z-index: 11 !default;
|
|
20
|
-
|
|
21
|
-
// RTL
|
|
22
|
-
$enable-rtl-styles: true !default;
|
package/dist/types.d.ts
DELETED
|
@@ -1,218 +0,0 @@
|
|
|
1
|
-
import type { Ref } from 'vue'
|
|
2
|
-
|
|
3
|
-
export type SortItem = { key: string; order?: boolean | 'asc' | 'desc' }
|
|
4
|
-
|
|
5
|
-
export type ReplaceableItem = Record<string, string | number | null> |
|
|
6
|
-
Array<ReplaceableItem> |
|
|
7
|
-
string |
|
|
8
|
-
number |
|
|
9
|
-
null
|
|
10
|
-
|
|
11
|
-
export type ValidateOn = "submit lazy" | "lazy" | "blur" | "input" | "submit" | "input lazy" | "blur lazy" | "lazy input" | "lazy blur" | "lazy submit" | undefined
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
export type ItemData = Record<string, string | number | null>
|
|
15
|
-
export type Params = Record<string, string | number | null | undefined | string[] | Date[] | number[] | (string | number)[] | boolean>
|
|
16
|
-
|
|
17
|
-
export type ApiResponse<T> = {
|
|
18
|
-
data: T
|
|
19
|
-
status: {
|
|
20
|
-
success: boolean
|
|
21
|
-
code: number
|
|
22
|
-
message: string
|
|
23
|
-
error_key: string
|
|
24
|
-
errors_list?: ErrorResponseFiled[]
|
|
25
|
-
}
|
|
26
|
-
totals?: { [key: string]: number }
|
|
27
|
-
pagination: Pagination
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
export type ErrorResponse<T = null> = {
|
|
31
|
-
data: T
|
|
32
|
-
status: {
|
|
33
|
-
success: boolean
|
|
34
|
-
code: number
|
|
35
|
-
message: string
|
|
36
|
-
error_key: string
|
|
37
|
-
errors_list?: ErrorResponseFiled[]
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
export type ErrorResponseFiled = {
|
|
42
|
-
field: string
|
|
43
|
-
message: string
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
export type Breadcrumb = {
|
|
47
|
-
title: string
|
|
48
|
-
params?: Record<string, string>
|
|
49
|
-
to?: string
|
|
50
|
-
disabled?: boolean
|
|
51
|
-
hasLang?: boolean
|
|
52
|
-
onClick?: () => void
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
export type Header = {
|
|
56
|
-
key: string
|
|
57
|
-
title: string
|
|
58
|
-
sortable?: boolean
|
|
59
|
-
width?: string
|
|
60
|
-
maxWidth?: string
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
export type FormFilterType = 'text' | 'range' | 'radio' | 'select' | 'datepicker' | 'datepickerRange' | 'autocomplete' | 'autocompleteGroups' | 'mobile' | 'bankSelect' | 'licensePlate'
|
|
64
|
-
|
|
65
|
-
export type FormFilter = {
|
|
66
|
-
name: string
|
|
67
|
-
keys?: string[]
|
|
68
|
-
label: string
|
|
69
|
-
placeholder?: string
|
|
70
|
-
type?: FormFilterType
|
|
71
|
-
hasLang?: boolean
|
|
72
|
-
options?: OptionItem[]
|
|
73
|
-
itemLabel?: string
|
|
74
|
-
urlSearch?: string
|
|
75
|
-
multiple?: boolean
|
|
76
|
-
trackBy?: string
|
|
77
|
-
trackByValue?: string | number | string[]
|
|
78
|
-
searchInternally?: boolean
|
|
79
|
-
params?: Record<string, string | number | null>
|
|
80
|
-
class?: string
|
|
81
|
-
clearable?: boolean
|
|
82
|
-
showDescription?: boolean
|
|
83
|
-
closableChips?: boolean
|
|
84
|
-
invisible?: boolean
|
|
85
|
-
value?: string | number | [] | object[] | string[] | number[] | null | (string | number | null)[]
|
|
86
|
-
rules?: []
|
|
87
|
-
fromMinDate?: Date | null
|
|
88
|
-
toMinDate?: Date | null
|
|
89
|
-
fromMaxDate?: Date | null
|
|
90
|
-
toMaxDate?: Date | null
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
export type Options = {
|
|
94
|
-
page: number
|
|
95
|
-
itemsPerPage: number
|
|
96
|
-
sortBy: readonly SortItem[]
|
|
97
|
-
groupBy: readonly SortItem[]
|
|
98
|
-
search: string | undefined
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
export type Pagination = {
|
|
102
|
-
to: number
|
|
103
|
-
from: number
|
|
104
|
-
total: number
|
|
105
|
-
count: number
|
|
106
|
-
per_page: number
|
|
107
|
-
current_page: number
|
|
108
|
-
last_page: number
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
export type EditableDataTableItemType = 'text' | 'datepicker' | 'timepicker' | 'autocomplete' | 'autocompleteGroups' | 'select' | 'number' | 'display' | 'license_plate' | 'manual_date'
|
|
112
|
-
|
|
113
|
-
export type EditableDataTableItem = {
|
|
114
|
-
internalIndex?: number
|
|
115
|
-
key: string
|
|
116
|
-
width?: string
|
|
117
|
-
title?: string
|
|
118
|
-
text?: string | undefined
|
|
119
|
-
placeholder?: string
|
|
120
|
-
type?: EditableDataTableItemType
|
|
121
|
-
required?: boolean
|
|
122
|
-
rules?: ((value: unknown) => string)[];
|
|
123
|
-
renderDataOnMounted?: boolean
|
|
124
|
-
renderDataOnBeforeMount?: boolean
|
|
125
|
-
showDescription?: boolean
|
|
126
|
-
tooltip?: string
|
|
127
|
-
clearable?: boolean
|
|
128
|
-
disabled?: boolean
|
|
129
|
-
maxlength?: number
|
|
130
|
-
dependsOn?: string
|
|
131
|
-
nestedDependsOnKey?: string
|
|
132
|
-
fields?: EditableDataTableItem[]
|
|
133
|
-
errorKey?: string | string[]
|
|
134
|
-
useDependsOnAsParams?: boolean
|
|
135
|
-
dependsOnFunction?: (...args: unknown[]) => boolean
|
|
136
|
-
closableChips?: boolean
|
|
137
|
-
urlSearch?: string | ((...args: unknown[]) => string)
|
|
138
|
-
params?: Record<string, string | number | null>
|
|
139
|
-
menuIcon?: string
|
|
140
|
-
searchable?: boolean
|
|
141
|
-
searchInternally?: boolean
|
|
142
|
-
trackBy?: string
|
|
143
|
-
itemLabel?: string
|
|
144
|
-
multiple?: boolean
|
|
145
|
-
groupLabel?: string
|
|
146
|
-
groupValues?: string
|
|
147
|
-
options?: Record<string, unknown>[] | OptionItem[] | Ref<OptionItem[]>
|
|
148
|
-
disableIfEmpty?: boolean
|
|
149
|
-
maxDate?: Date | null
|
|
150
|
-
validateOn?: ValidateOn
|
|
151
|
-
isAppRtl?: boolean
|
|
152
|
-
}
|
|
153
|
-
|
|
154
|
-
export type OptionItem = {
|
|
155
|
-
id?: string | number | boolean
|
|
156
|
-
name?: string | number
|
|
157
|
-
value?: string | number | boolean
|
|
158
|
-
allowTranslate?: boolean
|
|
159
|
-
svg_icon_url?: string
|
|
160
|
-
png_icon_url?: string
|
|
161
|
-
children?: OptionItem[]
|
|
162
|
-
}
|
|
163
|
-
|
|
164
|
-
export type Item = {
|
|
165
|
-
id: number | string
|
|
166
|
-
name: string
|
|
167
|
-
}
|
|
168
|
-
|
|
169
|
-
export type Attachment = {
|
|
170
|
-
id?: string | number
|
|
171
|
-
src: string
|
|
172
|
-
file?: File
|
|
173
|
-
}
|
|
174
|
-
|
|
175
|
-
export type City = {
|
|
176
|
-
id: string
|
|
177
|
-
name: string
|
|
178
|
-
lat: number
|
|
179
|
-
lng: number
|
|
180
|
-
is_winch_city: boolean
|
|
181
|
-
coordinates: [[number, number]] | []
|
|
182
|
-
}
|
|
183
|
-
|
|
184
|
-
export type Bank = {
|
|
185
|
-
id: number
|
|
186
|
-
name: string
|
|
187
|
-
account_number: string
|
|
188
|
-
iban: string
|
|
189
|
-
bank_code: string
|
|
190
|
-
created_at: string
|
|
191
|
-
updated_at: string
|
|
192
|
-
}
|
|
193
|
-
|
|
194
|
-
export type CustomInputContent = {
|
|
195
|
-
title: string
|
|
196
|
-
desc?: string
|
|
197
|
-
value: string | number
|
|
198
|
-
subtitle?: string
|
|
199
|
-
icon?: { icon: string; size?: string; color?: string }
|
|
200
|
-
images?: string
|
|
201
|
-
image?: string
|
|
202
|
-
}
|
|
203
|
-
|
|
204
|
-
export type GridColumn = {
|
|
205
|
-
cols?: string
|
|
206
|
-
sm?: string
|
|
207
|
-
md?: string
|
|
208
|
-
lg?: string
|
|
209
|
-
xl?: string
|
|
210
|
-
xxl?: string
|
|
211
|
-
}
|
|
212
|
-
|
|
213
|
-
declare global {
|
|
214
|
-
interface Window {
|
|
215
|
-
i18n?: any;
|
|
216
|
-
}
|
|
217
|
-
}
|
|
218
|
-
|
package/dist/utils/apiUrl.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const buildApiUrl: (relativePath?: string) => string;
|
package/dist/utils/apiUrl.js
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.buildApiUrl = void 0;
|
|
7
|
-
const buildApiUrl = relativePath => {
|
|
8
|
-
const baseUrl = process.env.VITE_BASE_API;
|
|
9
|
-
if (!relativePath) {
|
|
10
|
-
return baseUrl;
|
|
11
|
-
}
|
|
12
|
-
const normalizedPath = relativePath.startsWith("/") ? relativePath.slice(1) : relativePath;
|
|
13
|
-
return `${baseUrl}/${normalizedPath}`;
|
|
14
|
-
};
|
|
15
|
-
exports.buildApiUrl = buildApiUrl;
|
package/dist/utils/apiUrl.mjs
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
export const buildApiUrl = (relativePath) => {
|
|
2
|
-
const baseUrl = import.meta.env.VITE_BASE_API;
|
|
3
|
-
if (!relativePath) {
|
|
4
|
-
return baseUrl;
|
|
5
|
-
}
|
|
6
|
-
const normalizedPath = relativePath.startsWith("/") ? relativePath.slice(1) : relativePath;
|
|
7
|
-
return `${baseUrl}/${normalizedPath}`;
|
|
8
|
-
};
|
package/dist/utils/client.d.ts
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { type FetchOptions } from 'ofetch';
|
|
2
|
-
import type { ApiResponse } from '../types';
|
|
3
|
-
type RequestOptions = Omit<FetchOptions<'json'>, 'method'> & {
|
|
4
|
-
ignoreUrlPrefix?: boolean;
|
|
5
|
-
};
|
|
6
|
-
export declare const client: {
|
|
7
|
-
get: <T>(path: string, options?: RequestOptions) => Promise<ApiResponse<T>>;
|
|
8
|
-
};
|
|
9
|
-
export {};
|
package/dist/utils/client.js
DELETED
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.client = void 0;
|
|
7
|
-
var _ofetch = require("ofetch");
|
|
8
|
-
var _toaster = require("./toaster");
|
|
9
|
-
var _i18n = require("./i18n");
|
|
10
|
-
const clientInstance = _ofetch.ofetch.create({
|
|
11
|
-
credentials: "include"
|
|
12
|
-
});
|
|
13
|
-
async function apiRequest(method, path, options) {
|
|
14
|
-
const baseUrl = process.env.VITE_BASE_API;
|
|
15
|
-
const prefix = process.env.VITE_APP_TYPE;
|
|
16
|
-
const token = localStorage.getItem("token");
|
|
17
|
-
const {
|
|
18
|
-
ignoreUrlPrefix,
|
|
19
|
-
headers,
|
|
20
|
-
...restOptions
|
|
21
|
-
} = options || {};
|
|
22
|
-
return clientInstance(path, {
|
|
23
|
-
method,
|
|
24
|
-
baseURL: ignoreUrlPrefix ? baseUrl : `${baseUrl}/${prefix}`,
|
|
25
|
-
credentials: "include",
|
|
26
|
-
headers: {
|
|
27
|
-
"Accept": "application/json",
|
|
28
|
-
"X-Requested-With": "XMLHttpRequest",
|
|
29
|
-
"Accept-Language": localStorage.getItem("winch-lang"),
|
|
30
|
-
"User-Platform": "web",
|
|
31
|
-
...(token && {
|
|
32
|
-
Authorization: `Bearer ${token}`
|
|
33
|
-
}),
|
|
34
|
-
...headers
|
|
35
|
-
},
|
|
36
|
-
onResponseError: error => {
|
|
37
|
-
if (error.response.status === 401) {
|
|
38
|
-
localStorage.clear();
|
|
39
|
-
window.location.href = "/login";
|
|
40
|
-
}
|
|
41
|
-
if (error.response.status === 500) {
|
|
42
|
-
(0, _toaster.toaster)().error((0, _i18n.i18n)().global.t("http.500"));
|
|
43
|
-
}
|
|
44
|
-
if (error.response.status === 429) {
|
|
45
|
-
(0, _toaster.toaster)().error((0, _i18n.i18n)().global.t("http.429"));
|
|
46
|
-
}
|
|
47
|
-
},
|
|
48
|
-
...restOptions
|
|
49
|
-
});
|
|
50
|
-
}
|
|
51
|
-
const client = exports.client = {
|
|
52
|
-
get: async (path, options) => apiRequest("GET", path, options)
|
|
53
|
-
};
|
package/dist/utils/client.mjs
DELETED
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import { ofetch } from "ofetch";
|
|
2
|
-
import { toaster } from "./toaster.mjs";
|
|
3
|
-
import { i18n } from "./i18n.mjs";
|
|
4
|
-
const clientInstance = ofetch.create({ credentials: "include" });
|
|
5
|
-
async function apiRequest(method, path, options) {
|
|
6
|
-
const baseUrl = import.meta.env.VITE_BASE_API;
|
|
7
|
-
const prefix = import.meta.env.VITE_APP_TYPE;
|
|
8
|
-
const token = localStorage.getItem("token");
|
|
9
|
-
const { ignoreUrlPrefix, headers, ...restOptions } = options || {};
|
|
10
|
-
return clientInstance(path, {
|
|
11
|
-
method,
|
|
12
|
-
baseURL: ignoreUrlPrefix ? baseUrl : `${baseUrl}/${prefix}`,
|
|
13
|
-
credentials: "include",
|
|
14
|
-
headers: {
|
|
15
|
-
"Accept": "application/json",
|
|
16
|
-
"X-Requested-With": "XMLHttpRequest",
|
|
17
|
-
"Accept-Language": localStorage.getItem("winch-lang"),
|
|
18
|
-
"User-Platform": "web",
|
|
19
|
-
...token && { Authorization: `Bearer ${token}` },
|
|
20
|
-
...headers
|
|
21
|
-
},
|
|
22
|
-
onResponseError: (error) => {
|
|
23
|
-
if (error.response.status === 401) {
|
|
24
|
-
localStorage.clear();
|
|
25
|
-
window.location.href = "/login";
|
|
26
|
-
}
|
|
27
|
-
if (error.response.status === 500) {
|
|
28
|
-
toaster().error(i18n().global.t("http.500"));
|
|
29
|
-
}
|
|
30
|
-
if (error.response.status === 429) {
|
|
31
|
-
toaster().error(i18n().global.t("http.429"));
|
|
32
|
-
}
|
|
33
|
-
},
|
|
34
|
-
...restOptions
|
|
35
|
-
});
|
|
36
|
-
}
|
|
37
|
-
export const client = {
|
|
38
|
-
get: async (path, options) => apiRequest("GET", path, options)
|
|
39
|
-
};
|
package/dist/utils/files.d.ts
DELETED