mypgs 1.5.0 → 1.6.0
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/AGENTS.md +6 -3
- package/README.md +22 -373
- package/assets/javascript/_imports.js +4 -0
- package/assets/javascript/_pgs.js +58 -0
- package/assets/javascript/base/_darkmode.js +27 -105
- package/assets/javascript/base/_svg.js +103 -0
- package/assets/javascript/components/_menu.js +1 -3
- package/assets/javascript/components/_search.js +391 -0
- package/assets/javascript/index.js +2 -0
- package/assets/javascript/layout/_header.js +26 -7
- package/assets/scss/base/_color.scss +8 -15
- package/assets/scss/base/_general.scss +36 -48
- package/assets/scss/base/_heading.scss +14 -16
- package/assets/scss/base/_variables.scss +4 -2
- package/assets/scss/components/_card.scss +10 -0
- package/assets/scss/components/_dropdown.scss +2 -1
- package/assets/scss/components/_logo.scss +2 -2
- package/assets/scss/components/_menu.scss +20 -27
- package/assets/scss/components/_modals.scss +11 -1
- package/assets/scss/components/_search.scss +134 -0
- package/assets/scss/index.scss +8 -4
- package/assets/scss/layout/_header.scss +1 -1
- package/assets/scss/layout/_pageShell.scss +1 -0
- package/dist/css/index.css +658 -620
- package/dist/css/index.css.map +1 -1
- package/dist/css/index.min.css +1 -1
- package/dist/index.d.ts +78 -0
- package/dist/javascript/index.js +904 -370
- package/dist/javascript/index.js.map +1 -1
- package/dist/javascript/index.min.js +1 -1
- package/docs/componenti-e-markup.md +90 -0
- package/docs/convenzioni.md +12 -0
- package/docs/export-e-sviluppo.md +109 -0
- package/docs/helper-javascript.md +127 -0
- package/docs/utilizzo-css-scss.md +36 -0
- package/package.json +1 -6
- package/plugins/vite-plugin-pgs.d.ts +10 -0
- package/templates/html/components/logo.html +1 -1
- package/templates/html/components/menu.html +13 -1
- package/templates/html/components/{searchbar.html → search.html} +7 -5
- package/templates/html/demo.js +1 -8
- package/templates/html/layout/header.html +11 -5
- package/templates/react/components/logo.jsx +1 -1
- package/templates/react/components/{searchbar.jsx → search.jsx} +9 -7
- package/templates/react/patterns/header.jsx +16 -10
- package/assets/scss/components/_searchbar.scss +0 -70
- package/react.d.ts +0 -11
- package/react.js +0 -1
|
@@ -93,9 +93,32 @@ function headerHeight() {
|
|
|
93
93
|
document.documentElement.style.setProperty("--heightOfHeader", `${height}px`);
|
|
94
94
|
document.documentElement.style.setProperty("--heightOfHeaderScroll", `${scrollHeight}px`);
|
|
95
95
|
}
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
96
|
+
|
|
97
|
+
// Il modulo può essere caricato nel footer: rimanda il primo calcolo al frame
|
|
98
|
+
// successivo, quando il browser ha già composto l'header, senza aspettare il
|
|
99
|
+
// caricamento completo della pagina.
|
|
100
|
+
let headerHeightRafId = 0;
|
|
101
|
+
function scheduleHeaderHeight() {
|
|
102
|
+
if (headerHeightRafId) return;
|
|
103
|
+
|
|
104
|
+
headerHeightRafId = requestAnimationFrame(() => {
|
|
105
|
+
headerHeightRafId = 0;
|
|
106
|
+
headerHeight();
|
|
107
|
+
});
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
if (header) {
|
|
111
|
+
const headerHeightObserver = new ResizeObserver(scheduleHeaderHeight);
|
|
112
|
+
headerHeightObserver.observe(header);
|
|
113
|
+
|
|
114
|
+
// Un font web può modificare la larghezza del menu e quindi l'altezza
|
|
115
|
+
// dell'header, anche dopo il primo frame.
|
|
116
|
+
document.fonts?.ready?.then(scheduleHeaderHeight);
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
scheduleHeaderHeight();
|
|
120
|
+
window.addEventListener("resize", scheduleHeaderHeight);
|
|
121
|
+
window.addEventListener("scroll", scheduleHeaderHeight, { passive: true });
|
|
99
122
|
|
|
100
123
|
|
|
101
124
|
|
|
@@ -125,7 +148,3 @@ window.addEventListener("scroll", () => {
|
|
|
125
148
|
|
|
126
149
|
});
|
|
127
150
|
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
@@ -5,33 +5,26 @@
|
|
|
5
5
|
:root {
|
|
6
6
|
color-scheme: light;
|
|
7
7
|
|
|
8
|
-
&[
|
|
8
|
+
&[pgs-state~=darkmode] {
|
|
9
9
|
color-scheme: dark;
|
|
10
10
|
}
|
|
11
|
-
}
|
|
12
11
|
|
|
13
|
-
// == Primary colors
|
|
14
|
-
:root {
|
|
12
|
+
// == Primary colors
|
|
15
13
|
--color-primary: #5c7d6f;
|
|
16
14
|
--color-secondary: #3d5f4f;
|
|
17
15
|
--color-tertiary: #8fb082;
|
|
18
16
|
--color-quaternary: #10201c;
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
// == Base colors
|
|
22
|
-
:root {
|
|
17
|
+
|
|
18
|
+
// == Base colors
|
|
23
19
|
--color-white: light-dark(#FFFFFF, #000000);
|
|
24
20
|
--color-black: light-dark(#000000, #FFFFFF);
|
|
25
21
|
--color-white-transparent: color-mix(in srgb, var(--color-white) 50%, transparent 100%);
|
|
26
22
|
--color-black-transparent: color-mix(in srgb, var(--color-black) 50%, transparent 100%);
|
|
27
|
-
|
|
28
23
|
--color-text: light-dark(#4a4a4a, #e3e3e3);
|
|
29
|
-
|
|
30
|
-
--color-
|
|
31
|
-
--color-
|
|
32
|
-
--color-
|
|
33
|
-
--color-boxDark-transparent: light-dark(color-mix(in srgb, #3A3A3A 50%, transparent 50%), color-mix(in srgb, #eeeeee 50%, transparent 50%));
|
|
34
|
-
|
|
24
|
+
--color-box: light-dark(#F8F8F8, #222121);
|
|
25
|
+
--color-boxDark: light-dark(#222121, #F8F8F8);
|
|
26
|
+
--color-box-transparent: light-dark(color-mix(in srgb, #eeeeee 50%, transparent 50%), color-mix(in srgb, #222121 50%, transparent 50%));
|
|
27
|
+
--color-boxDark-transparent: light-dark(color-mix(in srgb, #222121 50%, transparent 50%), color-mix(in srgb, #eeeeee 50%, transparent 50%));
|
|
35
28
|
--color-linkBackgorud: light-dark(#a0dbff, #002a44);
|
|
36
29
|
--color-background: light-dark(#ffffff, #080808);
|
|
37
30
|
--color-whiteFixed: #FFFFFF;
|
|
@@ -1,63 +1,51 @@
|
|
|
1
1
|
@use "../mixin/mixin" as *;
|
|
2
2
|
|
|
3
3
|
//# GENERAL
|
|
4
|
-
[pgs~=
|
|
4
|
+
[pgs~=boxtext] {
|
|
5
|
+
@include boxtext();
|
|
6
|
+
}
|
|
5
7
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
8
|
+
[pgs~=darkmode] {
|
|
9
|
+
color-scheme: dark;
|
|
10
|
+
}
|
|
9
11
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
}
|
|
12
|
+
[pgs~=lightmode] {
|
|
13
|
+
color-scheme: light;
|
|
14
|
+
}
|
|
14
15
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
16
|
+
[pgs~=imgCover] {
|
|
17
|
+
object-fit: cover;
|
|
18
|
+
}
|
|
18
19
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
[pgs~=imgContain] {
|
|
21
|
+
object-fit: contain;
|
|
22
|
+
}
|
|
22
23
|
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
24
|
+
[pgs~=borderRadius] {
|
|
25
|
+
border-radius: var(--border-radius);
|
|
26
|
+
}
|
|
26
27
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
28
|
+
[pgs~=borderRadiusInput] {
|
|
29
|
+
border-radius: var(--border-radius-input);
|
|
30
|
+
}
|
|
30
31
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
32
|
+
[pgs~=borderRadiusExternal] {
|
|
33
|
+
border-radius: var(--border-radius-external);
|
|
34
|
+
}
|
|
34
35
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
36
|
+
[pgs~=blur] {
|
|
37
|
+
backdrop-filter: var(--blur);
|
|
38
|
+
}
|
|
38
39
|
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
40
|
+
[pgs~=appearanceNone] {
|
|
41
|
+
all: unset;
|
|
42
|
+
appearance: none;
|
|
43
|
+
}
|
|
42
44
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
45
|
+
[pgs~=pointer] {
|
|
46
|
+
cursor: pointer;
|
|
47
|
+
}
|
|
46
48
|
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
[pgs~=appearanceNone] {
|
|
52
|
-
all: unset;
|
|
53
|
-
appearance: none;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
[pgs~=pointer] {
|
|
57
|
-
cursor: pointer;
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
[pgs~=hidden] {
|
|
61
|
-
display: none !important;
|
|
62
|
-
}
|
|
49
|
+
[pgs~=hidden] {
|
|
50
|
+
display: none !important;
|
|
63
51
|
}
|
|
@@ -1,24 +1,22 @@
|
|
|
1
1
|
@use "../mixin/mixin" as *;
|
|
2
2
|
|
|
3
3
|
//# HEADING
|
|
4
|
-
[pgs~=
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
}
|
|
4
|
+
[pgs~=h1] {
|
|
5
|
+
@include h1();
|
|
6
|
+
}
|
|
8
7
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
[pgs~=h2] {
|
|
9
|
+
@include h2();
|
|
10
|
+
}
|
|
12
11
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
12
|
+
[pgs~=h3] {
|
|
13
|
+
@include h3();
|
|
14
|
+
}
|
|
16
15
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
16
|
+
[pgs~=h4] {
|
|
17
|
+
@include h4();
|
|
18
|
+
}
|
|
20
19
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
}
|
|
20
|
+
[pgs~=h5] {
|
|
21
|
+
@include h5();
|
|
24
22
|
}
|
|
@@ -19,7 +19,8 @@
|
|
|
19
19
|
--text-shadow: 0px 0px 50px #000000;
|
|
20
20
|
--backdrop: #0000003e;
|
|
21
21
|
--blur: blur(20px);
|
|
22
|
-
--page-top: calc(var(--
|
|
22
|
+
--page-top: calc(var(--heightOfHeader) + (var(--gap-elements)*2));
|
|
23
|
+
--page-topScroll: calc(var(--heightOfHeaderScroll) + (var(--gap-elements)*2));
|
|
23
24
|
--page-width: 1280px;
|
|
24
25
|
--page-space: clamp(var(--padding-page), calc((100% - var(--section-width)) / 2 + var(--padding-page)), 100%);
|
|
25
26
|
--gap-texts: 1.0rem;
|
|
@@ -32,7 +33,8 @@
|
|
|
32
33
|
--fa-size: inherit;
|
|
33
34
|
--focus-visible: 3px solid var(--color-link);
|
|
34
35
|
|
|
35
|
-
--heightOfHeader:
|
|
36
|
+
--heightOfHeader: 6.8rem; ///preload fittizio
|
|
37
|
+
--heightOfHeaderScroll: 6.8rem; ///preload fittizio
|
|
36
38
|
|
|
37
39
|
//- mobile
|
|
38
40
|
@media (max-width: $mobile) {
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
--dropdown-background: var(--color-box);
|
|
4
4
|
--dropdown-color: var(--color-black);
|
|
5
5
|
--dropdown-border: var(--border-complete);
|
|
6
|
+
--dropdown-borderRadius: var(--dropdown-padding);
|
|
6
7
|
--dropdown-padding: 1rem;
|
|
7
8
|
--dropdown-inline-size: max-content;
|
|
8
9
|
--dropdown-max-inline-size: min(400px, calc(100vw - 16px));
|
|
@@ -28,7 +29,7 @@
|
|
|
28
29
|
overflow: auto;
|
|
29
30
|
padding: var(--dropdown-padding);
|
|
30
31
|
border: var(--dropdown-border);
|
|
31
|
-
border-radius:
|
|
32
|
+
border-radius: var(--dropdown-borderRadius);
|
|
32
33
|
background: var(--dropdown-background);
|
|
33
34
|
color: var(--dropdown-color);
|
|
34
35
|
}
|
|
@@ -8,12 +8,12 @@
|
|
|
8
8
|
--logo-finter: invert(1) hue-rotate(180deg) brightness(1.5);
|
|
9
9
|
|
|
10
10
|
//== DARKMODE
|
|
11
|
-
@at-root [
|
|
11
|
+
@at-root [pgs-state~=darkmode] #{&}[pgs-option~="logoDarkmode"] [pgs~="logo-image"] {
|
|
12
12
|
filter: var(--logo-finter);
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
//== FIXED DARKMODE
|
|
16
|
-
&[pgs
|
|
16
|
+
&[pgs-option~="logoDarkmodeFixed"] [pgs~="logo-image"] {
|
|
17
17
|
filter: var(--logo-finter);
|
|
18
18
|
}
|
|
19
19
|
|
|
@@ -10,10 +10,6 @@
|
|
|
10
10
|
row-gap: 1.0rem;
|
|
11
11
|
flex-wrap: nowrap;
|
|
12
12
|
|
|
13
|
-
ul {
|
|
14
|
-
display: none;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
13
|
//== Content
|
|
18
14
|
>li {
|
|
19
15
|
>a {
|
|
@@ -30,6 +26,20 @@
|
|
|
30
26
|
li {
|
|
31
27
|
width: -webkit-fill-available;
|
|
32
28
|
}
|
|
29
|
+
|
|
30
|
+
&[pgs-state~=open]>ul {
|
|
31
|
+
display: flex;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
//== submenu
|
|
36
|
+
ul {
|
|
37
|
+
display: none;
|
|
38
|
+
flex-direction: column;
|
|
39
|
+
gap: var(--gap-texts);
|
|
40
|
+
--dropdown-borderRadius: calc(var(--border-radius-input) + var(--dropdown-padding));
|
|
41
|
+
--dropdown-background: var(--color-box-transparent);
|
|
42
|
+
--dropdown-display: flex;
|
|
33
43
|
}
|
|
34
44
|
}
|
|
35
45
|
|
|
@@ -45,8 +55,12 @@
|
|
|
45
55
|
cursor: pointer;
|
|
46
56
|
translate: -15px;
|
|
47
57
|
|
|
48
|
-
&[aria-expanded="true"]
|
|
49
|
-
|
|
58
|
+
&[aria-expanded="true"] {
|
|
59
|
+
--button-background: var(--color-primary);
|
|
60
|
+
|
|
61
|
+
span {
|
|
62
|
+
rotate: 180deg;
|
|
63
|
+
}
|
|
50
64
|
}
|
|
51
65
|
|
|
52
66
|
span {
|
|
@@ -67,25 +81,9 @@
|
|
|
67
81
|
|
|
68
82
|
//=== Sub menu
|
|
69
83
|
>li:has(ul) {
|
|
70
|
-
--dropdown-display: flex;
|
|
71
84
|
display: flex;
|
|
72
85
|
gap: 0.2rem;
|
|
73
86
|
flex-wrap: nowrap;
|
|
74
|
-
|
|
75
|
-
>a {
|
|
76
|
-
border-radius: var(--border-radius-input);
|
|
77
|
-
// box-shadow: var(--box-shadow);
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
ul {
|
|
81
|
-
li a {
|
|
82
|
-
min-width: 100% !important;
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
&[pgs-state~=open]>ul {
|
|
87
|
-
display: flex;
|
|
88
|
-
}
|
|
89
87
|
}
|
|
90
88
|
}
|
|
91
89
|
}
|
|
@@ -112,13 +110,8 @@
|
|
|
112
110
|
align-items: center;
|
|
113
111
|
position: relative;
|
|
114
112
|
|
|
115
|
-
>a {
|
|
116
|
-
max-width: calc(100% - var(--gap-texts) - 40px);
|
|
117
|
-
}
|
|
118
|
-
|
|
119
113
|
>ul {
|
|
120
114
|
flex-basis: 100%;
|
|
121
|
-
// --dropdown-maxwidth: 100%;
|
|
122
115
|
}
|
|
123
116
|
|
|
124
117
|
&:not([pgs-state~=open]) ul {
|
|
@@ -79,7 +79,7 @@ dialog[pgs~="modal-dialog"] {
|
|
|
79
79
|
&:has([pgs~="modal-dialog-content-scroll"]) {
|
|
80
80
|
max-height: calc(90svh - var(--heightOfHeader));
|
|
81
81
|
overflow: hidden;
|
|
82
|
-
|
|
82
|
+
|
|
83
83
|
[pgs~="modal-dialog-content-scroll"] {
|
|
84
84
|
padding-top: calc(var(--padding) / 2);
|
|
85
85
|
overflow: auto;
|
|
@@ -101,6 +101,16 @@ dialog[pgs~="modal-dialog"] {
|
|
|
101
101
|
}
|
|
102
102
|
|
|
103
103
|
//#OPTION
|
|
104
|
+
//== topLevel
|
|
105
|
+
&[pgs-option~="topLevel"] {
|
|
106
|
+
align-items: center;
|
|
107
|
+
padding-inline: 1rem;
|
|
108
|
+
|
|
109
|
+
[pgs~="modal-dialog-content"] {
|
|
110
|
+
width: min(600px, 100%);
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
|
|
104
114
|
//== LEFT
|
|
105
115
|
&[pgs-option~="left"] {
|
|
106
116
|
[pgs~="modal-dialog-content"] {
|
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
@use "../mixin/mixin" as *;
|
|
2
|
+
|
|
3
|
+
[pgs~="search"] {
|
|
4
|
+
--search-suggestions-background: var(--color-box);
|
|
5
|
+
--search-suggestions-color: var(--color-text);
|
|
6
|
+
--search-suggestions-border: var(--border-complete);
|
|
7
|
+
--search-suggestions-borderRadius: var(--border-radius-input);
|
|
8
|
+
--search-suggestions-box-shadow: var(--box-shadow);
|
|
9
|
+
--search-suggestions-gap: 0;
|
|
10
|
+
--search-suggestions-max-height: 32rem;
|
|
11
|
+
--search-suggestions-offset: .5rem;
|
|
12
|
+
--search-suggestions-padding: .5rem;
|
|
13
|
+
--search-suggestions-item-padding: 1rem;
|
|
14
|
+
--search-suggestions-item-selected-background: var(--color-primary);
|
|
15
|
+
--search-suggestions-item-selected-color: var(--color-whiteFixed);
|
|
16
|
+
position: relative;
|
|
17
|
+
@include flexRow(nowrap);
|
|
18
|
+
flex: 1;
|
|
19
|
+
width: 100%;
|
|
20
|
+
overflow: visible;
|
|
21
|
+
margin-inline: auto;
|
|
22
|
+
padding: 0;
|
|
23
|
+
@include button_header();
|
|
24
|
+
|
|
25
|
+
@media (min-width: $mobile) {
|
|
26
|
+
min-width: 21.4rem;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
button {
|
|
30
|
+
height: 100%;
|
|
31
|
+
padding-left: var(--button-size);
|
|
32
|
+
border: none;
|
|
33
|
+
border-radius: var(--border-radius-input);
|
|
34
|
+
outline: none;
|
|
35
|
+
background: none;
|
|
36
|
+
cursor: pointer;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
input {
|
|
40
|
+
width: 100%;
|
|
41
|
+
min-width: 21.4rem;
|
|
42
|
+
height: 100%;
|
|
43
|
+
padding: var(--button-size);
|
|
44
|
+
padding-left: 0;
|
|
45
|
+
margin: 2px;
|
|
46
|
+
margin-left: 0;
|
|
47
|
+
border: 0;
|
|
48
|
+
border-radius: var(--border-radius-input);
|
|
49
|
+
background-color: transparent;
|
|
50
|
+
color: contrast-color(color-mix(in srgb, var(--button-background) 77%, black));
|
|
51
|
+
font-family: var(--font);
|
|
52
|
+
font-size: 1.6rem;
|
|
53
|
+
font-weight: 600;
|
|
54
|
+
cursor: text !important;
|
|
55
|
+
|
|
56
|
+
&::placeholder {
|
|
57
|
+
color: contrast-color(color-mix(in srgb, var(--button-background) 77%, black));
|
|
58
|
+
opacity: .6;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
&:focus-visible {
|
|
62
|
+
outline: unset;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
&:has(input:focus-visible) {
|
|
67
|
+
outline: var(--focus-visible);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
&:not([pgs-state~="open"])>[pgs~="search-suggestions"] {
|
|
71
|
+
display: none;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
&[pgs-state~="open"]>[pgs~="search-suggestions"] {
|
|
75
|
+
display: flex;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
>[pgs~="search-suggestions"] {
|
|
79
|
+
position: absolute;
|
|
80
|
+
inset: calc(100% + var(--search-suggestions-offset)) 0 auto;
|
|
81
|
+
z-index: 1000;
|
|
82
|
+
flex-direction: column;
|
|
83
|
+
gap: var(--search-suggestions-gap);
|
|
84
|
+
max-height: var(--search-suggestions-max-height);
|
|
85
|
+
overflow-y: auto;
|
|
86
|
+
padding: var(--search-suggestions-padding);
|
|
87
|
+
margin: 0;
|
|
88
|
+
list-style: none;
|
|
89
|
+
border: var(--search-suggestions-border);
|
|
90
|
+
border-radius: calc(var(--search-suggestions-borderRadius) + var(--search-suggestions-padding));
|
|
91
|
+
background: var(--search-suggestions-background);
|
|
92
|
+
color: var(--search-suggestions-color);
|
|
93
|
+
box-shadow: var(--search-suggestions-box-shadow);
|
|
94
|
+
|
|
95
|
+
[pgs~="search-suggestions-item"] {
|
|
96
|
+
padding: var(--search-suggestions-item-padding);
|
|
97
|
+
border-radius: var(--search-suggestions-borderRadius);
|
|
98
|
+
cursor: pointer;
|
|
99
|
+
flex-wrap: nowrap;
|
|
100
|
+
|
|
101
|
+
&[aria-selected="true"],
|
|
102
|
+
&:hover {
|
|
103
|
+
background: var(--search-suggestions-item-selected-background);
|
|
104
|
+
color: var(--search-suggestions-item-selected-color);
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
&[aria-disabled="true"] {
|
|
108
|
+
cursor: not-allowed;
|
|
109
|
+
opacity: .5;
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
&:has([pgs~="search-suggestions-item"]:hover) [pgs~="search-suggestions-item"][aria-selected="true"] {
|
|
114
|
+
background: var(--search-suggestions-background);
|
|
115
|
+
color: var(--search-suggestions-color);
|
|
116
|
+
|
|
117
|
+
&:hover {
|
|
118
|
+
background: var(--search-suggestions-item-selected-background);
|
|
119
|
+
color: var(--search-suggestions-item-selected-color);
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
@at-root dialog #{&} {
|
|
125
|
+
max-width: calc(100% - var(--padding-page) * 2);
|
|
126
|
+
height: max-content;
|
|
127
|
+
margin-inline: auto;
|
|
128
|
+
background-color: var(--color-white);
|
|
129
|
+
|
|
130
|
+
input {
|
|
131
|
+
padding-block: 20px;
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
}
|
package/assets/scss/index.scss
CHANGED
|
@@ -9,8 +9,11 @@
|
|
|
9
9
|
@include meta.load-css("base/color");
|
|
10
10
|
@include meta.load-css("base/html");
|
|
11
11
|
@include meta.load-css("base/body");
|
|
12
|
-
|
|
13
|
-
|
|
12
|
+
|
|
13
|
+
[pgs~=initP] {
|
|
14
|
+
@include meta.load-css("base/heading");
|
|
15
|
+
@include meta.load-css("base/general");
|
|
16
|
+
}
|
|
14
17
|
|
|
15
18
|
/*
|
|
16
19
|
|--------------------------------------------------------------------------
|
|
@@ -33,6 +36,7 @@
|
|
|
33
36
|
|--------------------------------------------------------------------------
|
|
34
37
|
*/
|
|
35
38
|
[pgs~=initP] {
|
|
39
|
+
@include meta.load-css("components/card");
|
|
36
40
|
@include meta.load-css("components/button");
|
|
37
41
|
@include meta.load-css("components/form");
|
|
38
42
|
@include meta.load-css("components/menu");
|
|
@@ -48,7 +52,7 @@
|
|
|
48
52
|
@include meta.load-css("components/badges");
|
|
49
53
|
@include meta.load-css("components/notification");
|
|
50
54
|
@include meta.load-css("components/tooltip");
|
|
51
|
-
@include meta.load-css("components/
|
|
55
|
+
@include meta.load-css("components/search");
|
|
52
56
|
@include meta.load-css("components/logo");
|
|
53
57
|
}
|
|
54
58
|
|
|
@@ -59,4 +63,4 @@
|
|
|
59
63
|
*/
|
|
60
64
|
[pgs~=initP] {
|
|
61
65
|
@include meta.load-css("patterns/cookieConsent");
|
|
62
|
-
}
|
|
66
|
+
}
|