@skyservice-developers/vue-dev-kit 1.1.2 → 1.2.1
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/vue2/style.css +1 -1
- package/dist/vue2/vue-dev-kit.cjs +1 -1
- package/dist/vue2/vue-dev-kit.js +680 -591
- package/dist/vue3/style.css +1 -1
- package/dist/vue3/vue-dev-kit.cjs +1 -1
- package/dist/vue3/vue-dev-kit.js +645 -575
- package/package.json +2 -1
- package/src/shared/types/index.d.ts +15 -0
- package/src/shared/utils/index.js +1 -1
- package/src/shared/utils/webviewCheck.js +8 -0
- package/src/vue2/components/Dialog.vue +1 -1
- package/src/vue2/components/DialogModal.vue +1 -1
- package/src/vue2/components/DialogNext.vue +36 -25
- package/src/vue2/components/Header.vue +280 -100
- package/src/vue2/components/Modal.vue +13 -5
- package/src/vue3/components/Dialog.vue +1 -1
- package/src/vue3/components/DialogModal.vue +1 -1
- package/src/vue3/components/DialogNext.vue +49 -38
- package/src/vue3/components/Header.vue +290 -94
- package/src/vue3/components/Modal.vue +15 -10
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@skyservice-developers/vue-dev-kit",
|
|
3
|
-
"version": "1.1
|
|
3
|
+
"version": "1.2.1",
|
|
4
4
|
"description": "Vue 2 and Vue 3 developer toolkit - components and helpers",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/vue3/vue-dev-kit.cjs",
|
|
@@ -31,6 +31,7 @@
|
|
|
31
31
|
],
|
|
32
32
|
"scripts": {
|
|
33
33
|
"dev": "vite",
|
|
34
|
+
"playground": "vite --config playground/vite.config.js playground",
|
|
34
35
|
"build:vue2": "vite build --config vite.vue2.config.js",
|
|
35
36
|
"build:vue3": "vite build --config vite.vue3.config.js",
|
|
36
37
|
"build": "npm run build:vue2 && npm run build:vue3",
|
|
@@ -2,11 +2,26 @@ import { DefineComponent } from 'vue'
|
|
|
2
2
|
|
|
3
3
|
// ============ Components ============
|
|
4
4
|
|
|
5
|
+
export interface HeaderDropdownItem {
|
|
6
|
+
name: string
|
|
7
|
+
path: string
|
|
8
|
+
lastVisit: number
|
|
9
|
+
}
|
|
10
|
+
|
|
5
11
|
export interface HeaderProps {
|
|
6
12
|
title?: string
|
|
7
13
|
subtitle?: string
|
|
8
14
|
showBackButton?: boolean
|
|
9
15
|
backButtonTitle?: string
|
|
16
|
+
backEvent?: (() => void) | null
|
|
17
|
+
dropdownItems?: HeaderDropdownItem[]
|
|
18
|
+
dropdownTitle?: string
|
|
19
|
+
visitLabel?: string
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export interface HeaderEmits {
|
|
23
|
+
'back': () => void
|
|
24
|
+
'navigate': (path: string) => void
|
|
10
25
|
}
|
|
11
26
|
|
|
12
27
|
export interface HeaderSlots {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { webviewCheck, isIosWebview, isAndroidWebview, isCefWebview, isWebview } from './webviewCheck'
|
|
1
|
+
export { webviewCheck, isIosWebview, isAndroidWebview, isCefWebview, isWebview, isInIframe } from './webviewCheck'
|
|
@@ -8,19 +8,18 @@
|
|
|
8
8
|
<div class="sky-dialog-overlay" :class="{ 'sky-dialog-animate': enableAnimation }">
|
|
9
9
|
<div ref="dialogContent" class="sky-dialog-content">
|
|
10
10
|
<!-- Header -->
|
|
11
|
-
<
|
|
12
|
-
<
|
|
13
|
-
<
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
11
|
+
<div class="sky-dialog-header">
|
|
12
|
+
<button class="sky-dialog-back" :title="closeText" @click="close">
|
|
13
|
+
<svg width="15" height="15" viewBox="0 0 451.847 451.847" style="transform: rotate(90deg)">
|
|
14
|
+
<path fill="currentColor" d="M225.923,354.706c-8.098,0-16.195-3.092-22.369-9.263L9.27,151.157c-12.359-12.359-12.359-32.397,0-44.751c12.354-12.354,32.388-12.354,44.748,0l171.905,171.915l171.906-171.909c12.359-12.354,32.391-12.354,44.744,0c12.365,12.354,12.365,32.392,0,44.751L248.292,345.449C242.115,351.621,234.018,354.706,225.923,354.706z"/>
|
|
15
|
+
</svg>
|
|
16
|
+
</button>
|
|
17
|
+
<div class="sky-dialog-title" :class="{ 'sky-dialog-title-with-subtitle': subtitle }">
|
|
18
|
+
{{ title }}
|
|
19
|
+
<span v-if="subtitle" class="sky-dialog-subtitle">{{ subtitle }}</span>
|
|
20
|
+
</div>
|
|
20
21
|
</div>
|
|
21
22
|
|
|
22
|
-
<div class="sky-dialog-clearfix" />
|
|
23
|
-
|
|
24
23
|
<!-- Body -->
|
|
25
24
|
<div
|
|
26
25
|
ref="dialogPaper"
|
|
@@ -72,7 +71,7 @@ export default {
|
|
|
72
71
|
},
|
|
73
72
|
enableAnimation: {
|
|
74
73
|
type: Boolean,
|
|
75
|
-
default:
|
|
74
|
+
default: false
|
|
76
75
|
},
|
|
77
76
|
closeOnEsc: {
|
|
78
77
|
type: Boolean,
|
|
@@ -220,37 +219,52 @@ export default {
|
|
|
220
219
|
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3), 0 1px 2px rgba(0, 0, 0, 0.24);
|
|
221
220
|
}
|
|
222
221
|
|
|
222
|
+
.sky-dialog-header {
|
|
223
|
+
display: flex;
|
|
224
|
+
align-items: center;
|
|
225
|
+
padding: 10px 14px;
|
|
226
|
+
}
|
|
227
|
+
|
|
223
228
|
.sky-dialog-back {
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
+
display: flex;
|
|
230
|
+
align-items: center;
|
|
231
|
+
justify-content: center;
|
|
232
|
+
width: 32px;
|
|
233
|
+
height: 32px;
|
|
234
|
+
padding: 0;
|
|
229
235
|
background: transparent;
|
|
230
236
|
border: none;
|
|
237
|
+
cursor: pointer;
|
|
231
238
|
border-radius: 6px;
|
|
232
239
|
color: var(--sky-dialog-back-color, #374151);
|
|
233
240
|
transition: background-color 0.2s;
|
|
241
|
+
margin-right: 12px;
|
|
242
|
+
flex-shrink: 0;
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
.sky-dialog-back svg {
|
|
246
|
+
display: block;
|
|
234
247
|
}
|
|
235
248
|
|
|
236
249
|
.sky-dialog-back:hover {
|
|
237
250
|
background-color: var(--sky-dialog-back-hover-bg, #f8f9fa);
|
|
238
251
|
}
|
|
239
252
|
|
|
253
|
+
.sky-dialog-back:active {
|
|
254
|
+
background-color: var(--sky-dialog-back-active-bg, #e9ecef);
|
|
255
|
+
}
|
|
256
|
+
|
|
240
257
|
.sky-dialog-title {
|
|
241
|
-
max-width: calc(100% - 80px);
|
|
242
258
|
font-size: var(--sky-dialog-title-size, 13pt);
|
|
243
|
-
padding: 21px 0;
|
|
244
|
-
padding-right: 0;
|
|
245
|
-
float: left;
|
|
246
259
|
white-space: nowrap;
|
|
247
260
|
overflow: hidden;
|
|
248
261
|
text-overflow: ellipsis;
|
|
249
262
|
color: var(--sky-dialog-title-color, #252525);
|
|
263
|
+
min-width: 0;
|
|
250
264
|
}
|
|
251
265
|
|
|
252
266
|
.sky-dialog-title-with-subtitle {
|
|
253
|
-
|
|
267
|
+
line-height: 1.2;
|
|
254
268
|
}
|
|
255
269
|
|
|
256
270
|
.sky-dialog-subtitle {
|
|
@@ -263,9 +277,6 @@ export default {
|
|
|
263
277
|
text-overflow: ellipsis;
|
|
264
278
|
}
|
|
265
279
|
|
|
266
|
-
.sky-dialog-clearfix {
|
|
267
|
-
clear: both;
|
|
268
|
-
}
|
|
269
280
|
|
|
270
281
|
.sky-dialog-paper {
|
|
271
282
|
height: 100%;
|
|
@@ -1,130 +1,324 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<header class="sky-header">
|
|
3
|
-
<div class="
|
|
4
|
-
<div class="header-
|
|
5
|
-
<
|
|
2
|
+
<header class="sky-header-container">
|
|
3
|
+
<div class="topmenubox">
|
|
4
|
+
<div class="header-left">
|
|
5
|
+
<button
|
|
6
|
+
v-if="shouldShowBackButton"
|
|
7
|
+
class="btn-back"
|
|
8
|
+
@click="handleBack"
|
|
9
|
+
:title="backButtonTitle"
|
|
10
|
+
>
|
|
11
|
+
<svg width="15" height="15" viewBox="0 0 451.847 451.847" style="transform: rotate(90deg)">
|
|
12
|
+
<path fill="currentColor" d="M225.923,354.706c-8.098,0-16.195-3.092-22.369-9.263L9.27,151.157c-12.359-12.359-12.359-32.397,0-44.751c12.354-12.354,32.388-12.354,44.748,0l171.905,171.915l171.906-171.909c12.359-12.354,32.391-12.354,44.744,0c12.365,12.354,12.365,32.392,0,44.751L248.292,345.449C242.115,351.621,234.018,354.706,225.923,354.706z"/>
|
|
13
|
+
</svg>
|
|
14
|
+
</button>
|
|
15
|
+
<div ref="dropdownRef" class="titleAndDesc">
|
|
6
16
|
<button
|
|
7
|
-
|
|
8
|
-
class="
|
|
9
|
-
@click="
|
|
10
|
-
:title="backButtonTitle"
|
|
17
|
+
class="title-dropdown-toggle"
|
|
18
|
+
:class="{ 'title-dropdown-toggle-active': sortedItems.length }"
|
|
19
|
+
@click="toggleDropdown"
|
|
11
20
|
>
|
|
12
|
-
<svg
|
|
13
|
-
width="15"
|
|
14
|
-
height="15"
|
|
15
|
-
viewBox="0 0 451.847 451.847"
|
|
16
|
-
style="transform: rotate(90deg)"
|
|
17
|
-
>
|
|
18
|
-
<path
|
|
19
|
-
fill="currentColor"
|
|
20
|
-
d="M225.923,354.706c-8.098,0-16.195-3.092-22.369-9.263L9.27,151.157c-12.359-12.359-12.359-32.397,0-44.751c12.354-12.354,32.388-12.354,44.748,0l171.905,171.915l171.906-171.909c12.359-12.354,32.391-12.354,44.744,0c12.365,12.354,12.365,32.392,0,44.751L248.292,345.449C242.115,351.621,234.018,354.706,225.923,354.706z"
|
|
21
|
-
/>
|
|
22
|
-
</svg>
|
|
23
|
-
</button>
|
|
24
|
-
<div class="header-title-content">
|
|
25
21
|
<slot name="title">
|
|
26
|
-
<h4 class="
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
22
|
+
<h4 class="notPadding" style="margin-bottom: 4px">
|
|
23
|
+
<span class="topmenu-title">{{ title }}</span>
|
|
24
|
+
<svg
|
|
25
|
+
v-if="sortedItems.length"
|
|
26
|
+
class="arrow"
|
|
27
|
+
:class="{ open: isDropdownOpen }"
|
|
28
|
+
width="12"
|
|
29
|
+
height="12"
|
|
30
|
+
viewBox="0 0 451.847 451.847"
|
|
31
|
+
style="flex-shrink: 0"
|
|
32
|
+
>
|
|
33
|
+
<path
|
|
34
|
+
fill="currentColor"
|
|
35
|
+
d="M225.923,354.706c-8.098,0-16.195-3.092-22.369-9.263L9.27,151.157c-12.359-12.359-12.359-32.397,0-44.751c12.354-12.354,32.388-12.354,44.748,0l171.905,171.915l171.906-171.909c12.359-12.354,32.391-12.354,44.744,0c12.365,12.354,12.365,32.392,0,44.751L248.292,345.449C242.115,351.621,234.018,354.706,225.923,354.706z"
|
|
36
|
+
/>
|
|
37
|
+
</svg>
|
|
38
|
+
</h4>
|
|
30
39
|
</slot>
|
|
40
|
+
</button>
|
|
41
|
+
<div v-if="isDropdownOpen && sortedItems.length" class="title-dropdown">
|
|
42
|
+
<div class="title-dropdown-header">{{ dropdownTitle }}</div>
|
|
43
|
+
<div class="title-dropdown-divider"></div>
|
|
44
|
+
<div
|
|
45
|
+
v-for="(item, index) in sortedItems"
|
|
46
|
+
:key="index"
|
|
47
|
+
class="title-dropdown-item"
|
|
48
|
+
@click="selectItem(item)"
|
|
49
|
+
>
|
|
50
|
+
<p class="pageName">{{ capitalize(item.name) }}</p>
|
|
51
|
+
<small class="pageVisit">
|
|
52
|
+
({{ visitLabel }} {{ getTimeAgo(item.lastVisit) }})
|
|
53
|
+
</small>
|
|
54
|
+
</div>
|
|
31
55
|
</div>
|
|
56
|
+
<slot name="subtitle">
|
|
57
|
+
<p v-if="subtitle" class="topmenu-description">{{ subtitle }}</p>
|
|
58
|
+
</slot>
|
|
32
59
|
</div>
|
|
60
|
+
</div>
|
|
33
61
|
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
62
|
+
<div class="topmenubox-button">
|
|
63
|
+
<!-- Порожні блоки ремонтують відображення на windows в додатку, не видаляти! -->
|
|
64
|
+
<div></div>
|
|
65
|
+
<slot></slot>
|
|
66
|
+
<div></div>
|
|
39
67
|
</div>
|
|
40
68
|
</div>
|
|
41
69
|
</header>
|
|
42
70
|
</template>
|
|
43
71
|
|
|
44
72
|
<script>
|
|
73
|
+
import { isInIframe } from '../../shared/utils/webviewCheck'
|
|
74
|
+
|
|
45
75
|
export default {
|
|
46
|
-
name:
|
|
76
|
+
name: 'Header',
|
|
47
77
|
props: {
|
|
48
78
|
title: {
|
|
49
79
|
type: String,
|
|
50
|
-
default:
|
|
80
|
+
default: ''
|
|
51
81
|
},
|
|
52
82
|
subtitle: {
|
|
53
83
|
type: String,
|
|
54
|
-
default:
|
|
84
|
+
default: ''
|
|
55
85
|
},
|
|
56
86
|
showBackButton: {
|
|
57
87
|
type: Boolean,
|
|
58
|
-
default: true
|
|
88
|
+
default: true
|
|
59
89
|
},
|
|
60
90
|
backButtonTitle: {
|
|
61
91
|
type: String,
|
|
62
|
-
default:
|
|
92
|
+
default: 'Назад'
|
|
63
93
|
},
|
|
64
94
|
backEvent: {
|
|
65
95
|
type: Function,
|
|
66
|
-
default: null
|
|
96
|
+
default: null
|
|
97
|
+
},
|
|
98
|
+
dropdownItems: {
|
|
99
|
+
type: Array,
|
|
100
|
+
default: () => []
|
|
101
|
+
},
|
|
102
|
+
dropdownTitle: {
|
|
103
|
+
type: String,
|
|
104
|
+
default: 'Останні відвідані розділи'
|
|
67
105
|
},
|
|
106
|
+
visitLabel: {
|
|
107
|
+
type: String,
|
|
108
|
+
default: 'Останнє відвідування'
|
|
109
|
+
}
|
|
110
|
+
},
|
|
111
|
+
data() {
|
|
112
|
+
return {
|
|
113
|
+
isDropdownOpen: false
|
|
114
|
+
}
|
|
68
115
|
},
|
|
69
116
|
computed: {
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
try {
|
|
73
|
-
return window.self !== window.top;
|
|
74
|
-
} catch (e) {
|
|
75
|
-
return true;
|
|
76
|
-
}
|
|
117
|
+
sortedItems() {
|
|
118
|
+
return [...this.dropdownItems].sort((a, b) => b.lastVisit - a.lastVisit)
|
|
77
119
|
},
|
|
78
|
-
// Показуємо кнопку якщо є backEvent АБО (showBackButton=true І сторінка в iframe)
|
|
79
120
|
shouldShowBackButton() {
|
|
80
|
-
return this.backEvent || (this.showBackButton &&
|
|
81
|
-
}
|
|
121
|
+
return this.backEvent || (this.showBackButton && isInIframe())
|
|
122
|
+
}
|
|
123
|
+
},
|
|
124
|
+
mounted() {
|
|
125
|
+
document.addEventListener('click', this.handleClickOutside, true)
|
|
126
|
+
},
|
|
127
|
+
beforeDestroy() {
|
|
128
|
+
document.removeEventListener('click', this.handleClickOutside, true)
|
|
82
129
|
},
|
|
83
130
|
methods: {
|
|
84
|
-
// Обробник кнопки "Назад" - викликає backEvent або відправляє повідомлення батьківському вікну
|
|
85
131
|
handleBack() {
|
|
86
|
-
if (this.backEvent)
|
|
87
|
-
|
|
88
|
-
}
|
|
89
|
-
|
|
132
|
+
if (this.backEvent) return this.backEvent()
|
|
133
|
+
|
|
134
|
+
window.parent.postMessage({ type: 'exit' }, '*')
|
|
135
|
+
},
|
|
136
|
+
toggleDropdown() {
|
|
137
|
+
if (this.sortedItems.length) {
|
|
138
|
+
this.isDropdownOpen = !this.isDropdownOpen
|
|
90
139
|
}
|
|
91
140
|
},
|
|
92
|
-
|
|
93
|
-
|
|
141
|
+
closeDropdown() {
|
|
142
|
+
this.isDropdownOpen = false
|
|
143
|
+
},
|
|
144
|
+
selectItem(item) {
|
|
145
|
+
this.$emit('navigate', item.path)
|
|
146
|
+
this.closeDropdown()
|
|
147
|
+
},
|
|
148
|
+
capitalize(str) {
|
|
149
|
+
if (!str) return ''
|
|
150
|
+
return str.charAt(0).toUpperCase() + str.slice(1)
|
|
151
|
+
},
|
|
152
|
+
getTimeAgo(lastVisit) {
|
|
153
|
+
const now = Date.now()
|
|
154
|
+
const diff = now - lastVisit
|
|
155
|
+
|
|
156
|
+
const seconds = Math.floor(diff / 1000)
|
|
157
|
+
const minutes = Math.floor(seconds / 60)
|
|
158
|
+
const hours = Math.floor(minutes / 60)
|
|
159
|
+
const days = Math.floor(hours / 24)
|
|
160
|
+
|
|
161
|
+
if (days > 0) return `${days}д тому`
|
|
162
|
+
if (hours > 0) return `${hours}год тому`
|
|
163
|
+
if (minutes > 0) return `${minutes}хв тому`
|
|
164
|
+
return `${seconds}с тому`
|
|
165
|
+
},
|
|
166
|
+
handleClickOutside(e) {
|
|
167
|
+
if (this.$refs.dropdownRef && !this.$refs.dropdownRef.contains(e.target)) {
|
|
168
|
+
this.closeDropdown()
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
}
|
|
94
173
|
</script>
|
|
95
174
|
|
|
96
175
|
<style scoped>
|
|
97
|
-
.sky-header {
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
176
|
+
.sky-header-container {
|
|
177
|
+
width: 100%;
|
|
178
|
+
min-height: var(--sky-header-min-height, 82px);
|
|
179
|
+
background-color: var(--sky-header-bg, transparent);
|
|
180
|
+
display: flex;
|
|
181
|
+
flex-direction: row;
|
|
182
|
+
padding: var(--sky-header-padding, 10px);
|
|
103
183
|
border-bottom: 1px solid var(--sky-header-border-color, #dee2e6);
|
|
104
|
-
z-index: var(--sky-header-z-index,
|
|
105
|
-
|
|
184
|
+
z-index: var(--sky-header-z-index, 4);
|
|
185
|
+
position: relative;
|
|
106
186
|
}
|
|
107
187
|
|
|
108
|
-
.
|
|
109
|
-
|
|
110
|
-
margin: 0 auto;
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
.header-top {
|
|
188
|
+
.topmenubox {
|
|
189
|
+
width: 100%;
|
|
114
190
|
display: flex;
|
|
191
|
+
padding: 4px;
|
|
115
192
|
justify-content: space-between;
|
|
116
193
|
align-items: center;
|
|
194
|
+
background-color: transparent;
|
|
117
195
|
}
|
|
118
196
|
|
|
119
|
-
.header-
|
|
197
|
+
.header-left {
|
|
120
198
|
display: flex;
|
|
121
199
|
align-items: center;
|
|
122
200
|
gap: 12px;
|
|
123
201
|
}
|
|
124
202
|
|
|
125
|
-
.
|
|
203
|
+
.titleAndDesc {
|
|
126
204
|
display: flex;
|
|
127
205
|
flex-direction: column;
|
|
206
|
+
position: relative;
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
.notPadding {
|
|
210
|
+
margin: 0;
|
|
211
|
+
padding: 0;
|
|
212
|
+
font-size: var(--sky-header-title-size, 18px);
|
|
213
|
+
font-weight: var(--sky-header-title-weight, 500);
|
|
214
|
+
color: var(--sky-header-title-color, #252525);
|
|
215
|
+
line-height: 1.5;
|
|
216
|
+
user-select: none;
|
|
217
|
+
display: flex;
|
|
218
|
+
align-items: center;
|
|
219
|
+
flex-wrap: nowrap;
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
.topmenu-title {
|
|
223
|
+
white-space: pre-line;
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
.title-dropdown-toggle {
|
|
227
|
+
display: flex;
|
|
228
|
+
flex-direction: row;
|
|
229
|
+
padding: 0;
|
|
230
|
+
margin: 0;
|
|
231
|
+
background: transparent;
|
|
232
|
+
border: none;
|
|
233
|
+
text-align: left;
|
|
234
|
+
font: inherit;
|
|
235
|
+
color: inherit;
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
.title-dropdown-toggle-active {
|
|
239
|
+
cursor: pointer;
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
.arrow {
|
|
243
|
+
width: 12px;
|
|
244
|
+
position: relative;
|
|
245
|
+
margin-left: 5px;
|
|
246
|
+
flex-shrink: 0;
|
|
247
|
+
transition: transform 0.25s ease;
|
|
248
|
+
color: var(--sky-header-title-color, #252525);
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
.arrow.open {
|
|
252
|
+
transform: rotate(180deg);
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
.title-dropdown {
|
|
256
|
+
position: absolute;
|
|
257
|
+
top: 100%;
|
|
258
|
+
left: 0;
|
|
259
|
+
min-width: 240px;
|
|
260
|
+
background: white;
|
|
261
|
+
border-radius: 5px;
|
|
262
|
+
box-shadow: 0 1px 12px rgba(0, 0, 0, 0.1);
|
|
263
|
+
border: none;
|
|
264
|
+
z-index: 10;
|
|
265
|
+
padding: 4px 0;
|
|
266
|
+
margin-top: 4px;
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
.title-dropdown-header {
|
|
270
|
+
padding: 4px 24px;
|
|
271
|
+
font-size: 13px;
|
|
272
|
+
color: #6c757d;
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
.title-dropdown-divider {
|
|
276
|
+
height: 0;
|
|
277
|
+
margin: 4px 0;
|
|
278
|
+
border-top: 1px solid #e9ecef;
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
.title-dropdown-item {
|
|
282
|
+
padding: 4px 24px;
|
|
283
|
+
cursor: pointer;
|
|
284
|
+
transition: background-color 0.1s;
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
.title-dropdown-item:hover {
|
|
288
|
+
background-color: #f8f9fa;
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
.title-dropdown-item:active {
|
|
292
|
+
background-color: #e9ecef;
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
.pageName {
|
|
296
|
+
padding-bottom: 0;
|
|
297
|
+
margin: 0;
|
|
298
|
+
font-weight: 500;
|
|
299
|
+
font-size: 14px;
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
.pageVisit {
|
|
303
|
+
color: gray;
|
|
304
|
+
font-weight: 400;
|
|
305
|
+
font-size: 11px;
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
.topmenu-description {
|
|
309
|
+
margin: 0;
|
|
310
|
+
margin-bottom: 5px;
|
|
311
|
+
color: var(--sky-header-subtitle-color, #5d5d5d);
|
|
312
|
+
font-size: 13px;
|
|
313
|
+
font-weight: 400;
|
|
314
|
+
line-height: 1.5;
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
.topmenubox-button {
|
|
318
|
+
display: flex;
|
|
319
|
+
flex-direction: row;
|
|
320
|
+
align-items: center;
|
|
321
|
+
justify-content: space-between;
|
|
128
322
|
}
|
|
129
323
|
|
|
130
324
|
.btn-back {
|
|
@@ -155,41 +349,27 @@ export default {
|
|
|
155
349
|
background-color: var(--sky-header-back-btn-active-bg, #e9ecef);
|
|
156
350
|
}
|
|
157
351
|
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
.header-subtitle {
|
|
168
|
-
font-size: var(--sky-header-subtitle-size, 14px);
|
|
169
|
-
color: var(--sky-header-subtitle-color, #6c757d);
|
|
170
|
-
font-weight: 400;
|
|
171
|
-
line-height: 1.5;
|
|
172
|
-
}
|
|
173
|
-
|
|
174
|
-
.header-actions {
|
|
175
|
-
display: flex;
|
|
176
|
-
gap: var(--sky-header-actions-gap, 12px);
|
|
352
|
+
/* Responsive: <500px — hide description, smaller title */
|
|
353
|
+
@media (max-width: 499px) {
|
|
354
|
+
.topmenu-description {
|
|
355
|
+
display: none;
|
|
356
|
+
}
|
|
357
|
+
.notPadding {
|
|
358
|
+
font-size: 13px;
|
|
359
|
+
}
|
|
177
360
|
}
|
|
178
361
|
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
.header-top {
|
|
185
|
-
flex-direction: column;
|
|
186
|
-
align-items: flex-start;
|
|
187
|
-
/* gap: 12px; */
|
|
362
|
+
/* Responsive: 500-1099px — smaller description */
|
|
363
|
+
@media (min-width: 500px) and (max-width: 1099px) {
|
|
364
|
+
.topmenu-description {
|
|
365
|
+
font-size: 11px;
|
|
188
366
|
}
|
|
367
|
+
}
|
|
189
368
|
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
369
|
+
/* iOS safe area */
|
|
370
|
+
@supports (padding-top: env(safe-area-inset-top)) {
|
|
371
|
+
.sky-header-container {
|
|
372
|
+
padding-top: calc(10px + env(safe-area-inset-top));
|
|
193
373
|
}
|
|
194
374
|
}
|
|
195
375
|
</style>
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<base-teleport to="body">
|
|
3
|
-
<transition
|
|
3
|
+
<transition>
|
|
4
4
|
<div v-if="isOpen" class="sky-modal-overlay" @click.self="handleOverlayClick">
|
|
5
5
|
<div class="sky-modal" :style="modalStyle">
|
|
6
6
|
<div class="sky-modal-header">
|
|
7
7
|
<button class="sky-modal-back" @click="close" :title="closeTitle">
|
|
8
|
-
<svg width="15" height="15" viewBox="0 0
|
|
9
|
-
<path d="
|
|
8
|
+
<svg width="15" height="15" viewBox="0 0 451.847 451.847" style="transform: rotate(90deg)">
|
|
9
|
+
<path fill="currentColor" d="M225.923,354.706c-8.098,0-16.195-3.092-22.369-9.263L9.27,151.157c-12.359-12.359-12.359-32.397,0-44.751c12.354-12.354,32.388-12.354,44.748,0l171.905,171.915l171.906-171.909c12.359-12.354,32.391-12.354,44.744,0c12.365,12.354,12.365,32.392,0,44.751L248.292,345.449C242.115,351.621,234.018,354.706,225.923,354.706z"/>
|
|
10
10
|
</svg>
|
|
11
11
|
</button>
|
|
12
12
|
<div class="sky-modal-title-wrapper">
|
|
@@ -165,8 +165,8 @@ export default {
|
|
|
165
165
|
display: flex;
|
|
166
166
|
align-items: center;
|
|
167
167
|
justify-content: center;
|
|
168
|
-
width:
|
|
169
|
-
height:
|
|
168
|
+
width: 32px;
|
|
169
|
+
height: 32px;
|
|
170
170
|
padding: 0;
|
|
171
171
|
background: transparent;
|
|
172
172
|
border: none;
|
|
@@ -177,10 +177,18 @@ export default {
|
|
|
177
177
|
margin-right: 12px;
|
|
178
178
|
}
|
|
179
179
|
|
|
180
|
+
.sky-modal-back svg {
|
|
181
|
+
display: block;
|
|
182
|
+
}
|
|
183
|
+
|
|
180
184
|
.sky-modal-back:hover {
|
|
181
185
|
background-color: var(--sky-modal-back-hover-bg, #f8f9fa);
|
|
182
186
|
}
|
|
183
187
|
|
|
188
|
+
.sky-modal-back:active {
|
|
189
|
+
background-color: var(--sky-modal-back-active-bg, #e9ecef);
|
|
190
|
+
}
|
|
191
|
+
|
|
184
192
|
.sky-modal-title-wrapper {
|
|
185
193
|
flex: 1;
|
|
186
194
|
min-width: 0;
|