shared-ritm 1.1.91 → 1.1.92
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/index.css +1 -1
- package/dist/shared-ritm.es.js +455 -472
- package/dist/shared-ritm.umd.js +2 -2
- package/package.json +1 -1
- package/src/common/app-dialogs/AppConfirmDialog.vue +100 -100
- package/src/common/app-sheet/AppSheet.vue +120 -149
package/package.json
CHANGED
|
@@ -1,100 +1,100 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<q-dialog ref="dialogRef" persistent transition-show="slide-up" transition-hide="slide-down" :class="$style.dialog">
|
|
3
|
-
<q-card :class="$style.modal">
|
|
4
|
-
<q-card-section :class="$style['modal__content']">
|
|
5
|
-
<div :class="$style['modal__content__header']">
|
|
6
|
-
<safety-icon v-if="type === 'edit'" />
|
|
7
|
-
<remove-icon v-if="type === 'delete'" />
|
|
8
|
-
<h4>Подтвердить ?</h4>
|
|
9
|
-
</div>
|
|
10
|
-
<p>{{ content }}</p>
|
|
11
|
-
</q-card-section>
|
|
12
|
-
<q-card-section :class="$style.footer">
|
|
13
|
-
<app-button :class="$style['footer__btn--ok']" label="Подтвердить" @click="onDialogOK" />
|
|
14
|
-
<app-button :class="$style['footer__btn--cancel']" label="Отменить" @click="onDialogHide" />
|
|
15
|
-
</q-card-section>
|
|
16
|
-
</q-card>
|
|
17
|
-
</q-dialog>
|
|
18
|
-
</template>
|
|
19
|
-
|
|
20
|
-
<script setup lang="ts">
|
|
21
|
-
import { useDialogPluginComponent } from 'quasar'
|
|
22
|
-
import AppButton from '@/common/app-button/AppButton.vue'
|
|
23
|
-
import SafetyIcon from '@/icons/dialogs/SafetyIcon.vue'
|
|
24
|
-
import RemoveIcon from '@/icons/dialogs/RemoveIcon.vue'
|
|
25
|
-
|
|
26
|
-
const { onDialogHide, onDialogOK, dialogRef } = useDialogPluginComponent()
|
|
27
|
-
|
|
28
|
-
interface Props {
|
|
29
|
-
content: string
|
|
30
|
-
type: 'delete' | 'edit'
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
const props = defineProps<Props>()
|
|
34
|
-
</script>
|
|
35
|
-
|
|
36
|
-
<style lang="scss" module>
|
|
37
|
-
.modal {
|
|
38
|
-
font-family: NunitoSansFont, sans-serif;
|
|
39
|
-
display: flex;
|
|
40
|
-
flex-direction: column;
|
|
41
|
-
width: 400px;
|
|
42
|
-
border-radius: 24px !important;
|
|
43
|
-
justify-content: space-between;
|
|
44
|
-
padding: 40px;
|
|
45
|
-
&__content {
|
|
46
|
-
margin: 0 auto;
|
|
47
|
-
padding: 0;
|
|
48
|
-
flex-grow: 1;
|
|
49
|
-
&__header {
|
|
50
|
-
width: 100%;
|
|
51
|
-
display: flex;
|
|
52
|
-
align-items: center;
|
|
53
|
-
justify-content: center;
|
|
54
|
-
flex-direction: column;
|
|
55
|
-
gap: 16px;
|
|
56
|
-
h4 {
|
|
57
|
-
font-size: 24px;
|
|
58
|
-
font-weight: 600;
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
p {
|
|
63
|
-
margin-top: 14px;
|
|
64
|
-
margin-bottom: 30px;
|
|
65
|
-
font-size: 16px;
|
|
66
|
-
text-align: center;
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
.footer {
|
|
71
|
-
display: flex;
|
|
72
|
-
flex-direction: column;
|
|
73
|
-
gap: 12px;
|
|
74
|
-
align-items: center;
|
|
75
|
-
justify-content: center;
|
|
76
|
-
//height: 146px;
|
|
77
|
-
padding: 0;
|
|
78
|
-
&__btn--ok,
|
|
79
|
-
&__btn--cancel {
|
|
80
|
-
background-color: #3f8cff;
|
|
81
|
-
border-radius: 9px;
|
|
82
|
-
color: white;
|
|
83
|
-
font-size: 16px;
|
|
84
|
-
font-weight: bold;
|
|
85
|
-
width: 300px;
|
|
86
|
-
height: 48px;
|
|
87
|
-
cursor: pointer;
|
|
88
|
-
span {
|
|
89
|
-
color: white;
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
&__btn--cancel {
|
|
93
|
-
background-color: white;
|
|
94
|
-
border: 1px solid #3f8cff;
|
|
95
|
-
span {
|
|
96
|
-
color: #3f8cff;
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<q-dialog ref="dialogRef" persistent transition-show="slide-up" transition-hide="slide-down" :class="$style.dialog">
|
|
3
|
+
<q-card :class="$style.modal">
|
|
4
|
+
<q-card-section :class="$style['modal__content']">
|
|
5
|
+
<div :class="$style['modal__content__header']">
|
|
6
|
+
<safety-icon v-if="type === 'edit'" />
|
|
7
|
+
<remove-icon v-if="type === 'delete'" />
|
|
8
|
+
<h4>Подтвердить ?</h4>
|
|
9
|
+
</div>
|
|
10
|
+
<p>{{ content }}</p>
|
|
11
|
+
</q-card-section>
|
|
12
|
+
<q-card-section :class="$style.footer">
|
|
13
|
+
<app-button :class="$style['footer__btn--ok']" label="Подтвердить" @click="onDialogOK" />
|
|
14
|
+
<app-button :class="$style['footer__btn--cancel']" label="Отменить" @click="onDialogHide" />
|
|
15
|
+
</q-card-section>
|
|
16
|
+
</q-card>
|
|
17
|
+
</q-dialog>
|
|
18
|
+
</template>
|
|
19
|
+
|
|
20
|
+
<script setup lang="ts">
|
|
21
|
+
import { useDialogPluginComponent } from 'quasar'
|
|
22
|
+
import AppButton from '@/common/app-button/AppButton.vue'
|
|
23
|
+
import SafetyIcon from '@/icons/dialogs/SafetyIcon.vue'
|
|
24
|
+
import RemoveIcon from '@/icons/dialogs/RemoveIcon.vue'
|
|
25
|
+
|
|
26
|
+
const { onDialogHide, onDialogOK, dialogRef } = useDialogPluginComponent()
|
|
27
|
+
|
|
28
|
+
interface Props {
|
|
29
|
+
content: string
|
|
30
|
+
type: 'delete' | 'edit'
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
const props = defineProps<Props>()
|
|
34
|
+
</script>
|
|
35
|
+
|
|
36
|
+
<style lang="scss" module>
|
|
37
|
+
.modal {
|
|
38
|
+
font-family: NunitoSansFont, sans-serif;
|
|
39
|
+
display: flex;
|
|
40
|
+
flex-direction: column;
|
|
41
|
+
width: 400px;
|
|
42
|
+
border-radius: 24px !important;
|
|
43
|
+
justify-content: space-between;
|
|
44
|
+
padding: 40px;
|
|
45
|
+
&__content {
|
|
46
|
+
margin: 0 auto;
|
|
47
|
+
padding: 0;
|
|
48
|
+
flex-grow: 1;
|
|
49
|
+
&__header {
|
|
50
|
+
width: 100%;
|
|
51
|
+
display: flex;
|
|
52
|
+
align-items: center;
|
|
53
|
+
justify-content: center;
|
|
54
|
+
flex-direction: column;
|
|
55
|
+
gap: 16px;
|
|
56
|
+
h4 {
|
|
57
|
+
font-size: 24px;
|
|
58
|
+
font-weight: 600;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
p {
|
|
63
|
+
margin-top: 14px;
|
|
64
|
+
margin-bottom: 30px;
|
|
65
|
+
font-size: 16px;
|
|
66
|
+
text-align: center;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.footer {
|
|
71
|
+
display: flex;
|
|
72
|
+
flex-direction: column;
|
|
73
|
+
gap: 12px;
|
|
74
|
+
align-items: center;
|
|
75
|
+
justify-content: center;
|
|
76
|
+
//height: 146px;
|
|
77
|
+
padding: 0;
|
|
78
|
+
&__btn--ok,
|
|
79
|
+
&__btn--cancel {
|
|
80
|
+
background-color: #3f8cff;
|
|
81
|
+
border-radius: 9px;
|
|
82
|
+
color: white;
|
|
83
|
+
font-size: 16px;
|
|
84
|
+
font-weight: bold;
|
|
85
|
+
width: 300px;
|
|
86
|
+
height: 48px;
|
|
87
|
+
cursor: pointer;
|
|
88
|
+
span {
|
|
89
|
+
color: white;
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
&__btn--cancel {
|
|
93
|
+
background-color: white;
|
|
94
|
+
border: 1px solid #3f8cff;
|
|
95
|
+
span {
|
|
96
|
+
color: #3f8cff;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
</style>
|
|
@@ -1,149 +1,120 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<q-dialog
|
|
3
|
-
|
|
4
|
-
:
|
|
5
|
-
:
|
|
6
|
-
:
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
full-
|
|
10
|
-
full-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
()
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
.sheet-header {
|
|
122
|
-
display: flex;
|
|
123
|
-
justify-content: space-between;
|
|
124
|
-
align-items: center;
|
|
125
|
-
|
|
126
|
-
h2 {
|
|
127
|
-
font-size: 36px;
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
.loader {
|
|
132
|
-
min-width: 976px;
|
|
133
|
-
|
|
134
|
-
&-spinner {
|
|
135
|
-
position: absolute;
|
|
136
|
-
top: 50%;
|
|
137
|
-
left: 50%;
|
|
138
|
-
z-index: 4;
|
|
139
|
-
}
|
|
140
|
-
}
|
|
141
|
-
</style>
|
|
142
|
-
|
|
143
|
-
<style lang="scss" module>
|
|
144
|
-
.sheet-dialog {
|
|
145
|
-
:global(.q-dialog__inner--minimized) {
|
|
146
|
-
padding: 0;
|
|
147
|
-
}
|
|
148
|
-
}
|
|
149
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<q-dialog
|
|
3
|
+
ref="DialogRef"
|
|
4
|
+
:model-value="true"
|
|
5
|
+
:position="'right'"
|
|
6
|
+
:class="$style['sheet-dialog']"
|
|
7
|
+
no-shake
|
|
8
|
+
no-esc-dismiss
|
|
9
|
+
full-height
|
|
10
|
+
full-width
|
|
11
|
+
>
|
|
12
|
+
<template v-if="type === 'details'">
|
|
13
|
+
<q-card>
|
|
14
|
+
<div class="wrapper">
|
|
15
|
+
<div class="sheet-header">
|
|
16
|
+
<h2>{{ title }}</h2>
|
|
17
|
+
<div class="close-button">
|
|
18
|
+
<q-btn v-close-popup dense flat icon="close" />
|
|
19
|
+
</div>
|
|
20
|
+
</div>
|
|
21
|
+
<div v-if="loading" class="loader">
|
|
22
|
+
<q-spinner-audio v-if="loading" class="loader-spinner" size="md" :thickness="3" color="primary" />
|
|
23
|
+
</div>
|
|
24
|
+
<slot v-else />
|
|
25
|
+
</div>
|
|
26
|
+
</q-card>
|
|
27
|
+
</template>
|
|
28
|
+
<template v-if="type === 'custom'">
|
|
29
|
+
<div v-if="loading" class="custom-wrapper">
|
|
30
|
+
<div class="loader">
|
|
31
|
+
<q-spinner-audio v-if="loading" class="loader-spinner" size="md" :thickness="3" color="primary" />
|
|
32
|
+
</div>
|
|
33
|
+
</div>
|
|
34
|
+
<slot v-else />
|
|
35
|
+
</template>
|
|
36
|
+
</q-dialog>
|
|
37
|
+
</template>
|
|
38
|
+
|
|
39
|
+
<script setup lang="ts">
|
|
40
|
+
import { computed, defineEmits, defineProps, withDefaults } from 'vue'
|
|
41
|
+
|
|
42
|
+
interface DialogProps {
|
|
43
|
+
dialogRef: any
|
|
44
|
+
loading?: boolean
|
|
45
|
+
title?: string
|
|
46
|
+
width?: string
|
|
47
|
+
type?: 'details' | 'custom'
|
|
48
|
+
tabs?: any[]
|
|
49
|
+
currentTabName?: string
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
const props = withDefaults(defineProps<DialogProps>(), {
|
|
53
|
+
title: '',
|
|
54
|
+
width: '976px',
|
|
55
|
+
type: 'details',
|
|
56
|
+
loading: false,
|
|
57
|
+
tabs: () => [],
|
|
58
|
+
currentTabName: '',
|
|
59
|
+
})
|
|
60
|
+
|
|
61
|
+
const emit = defineEmits(['update:dialogRef', 'update:currentTabName'])
|
|
62
|
+
|
|
63
|
+
const DialogRef = computed({
|
|
64
|
+
get() {
|
|
65
|
+
return props.dialogRef
|
|
66
|
+
},
|
|
67
|
+
set(value) {
|
|
68
|
+
emit('update:dialogRef', value)
|
|
69
|
+
},
|
|
70
|
+
})
|
|
71
|
+
</script>
|
|
72
|
+
|
|
73
|
+
<style lang="scss" scoped>
|
|
74
|
+
.custom-wrapper {
|
|
75
|
+
width: v-bind(width);
|
|
76
|
+
background-color: white;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.wrapper {
|
|
80
|
+
display: flex;
|
|
81
|
+
flex-direction: column;
|
|
82
|
+
gap: 1rem;
|
|
83
|
+
width: v-bind(width);
|
|
84
|
+
height: 100vh;
|
|
85
|
+
min-height: 100vh;
|
|
86
|
+
position: relative;
|
|
87
|
+
padding: 2rem 2rem 4rem 2rem;
|
|
88
|
+
background-color: #7991ad32;
|
|
89
|
+
font-family: 'NunitoSansFont', sans-serif;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.sheet-header {
|
|
93
|
+
display: flex;
|
|
94
|
+
justify-content: space-between;
|
|
95
|
+
align-items: center;
|
|
96
|
+
|
|
97
|
+
h2 {
|
|
98
|
+
font-size: 36px;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
.loader {
|
|
103
|
+
min-width: 976px;
|
|
104
|
+
|
|
105
|
+
&-spinner {
|
|
106
|
+
position: absolute;
|
|
107
|
+
top: 50%;
|
|
108
|
+
left: 50%;
|
|
109
|
+
z-index: 4;
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
</style>
|
|
113
|
+
|
|
114
|
+
<style lang="scss" module>
|
|
115
|
+
.sheet-dialog {
|
|
116
|
+
:global(.q-dialog__inner--minimized) {
|
|
117
|
+
padding: 0;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
</style>
|