@hagicode/hagilight-docusaurus 0.19.1-dev.185.1.a85e2a8 → 0.19.1-dev.189.1.6e24429
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/theme/Footer/FooterView.js +3 -3
- package/package.json +2 -2
- package/styles.css +178 -24
|
@@ -6,8 +6,8 @@ import { pickFooterBrandLinks, resolveFooterBrand } from '@hagicode/hagilight-co
|
|
|
6
6
|
import { footerAvatarImageAttributes } from '@hagicode/hagilight-core/footer-avatar';
|
|
7
7
|
import { randomPoolAttribute } from '@hagicode/hagilight-core/random-image';
|
|
8
8
|
import { withCampaignUtm } from '@hagicode/hagilight-core/links';
|
|
9
|
-
function
|
|
10
|
-
return (
|
|
9
|
+
function ColumnLink({ entry }) {
|
|
10
|
+
return (_jsx("a", { href: entry.href, target: entry.target, rel: entry.rel, "aria-label": entry.ariaLabel, ...(entry.source === 'link' ? siteLinkGaAttributes(entry, 'footer') : {}), children: entry.label }));
|
|
11
11
|
}
|
|
12
12
|
function FooterBrand({ locale, links, avatar, siteId, siteUrl }) {
|
|
13
13
|
const brand = resolveFooterBrand(locale);
|
|
@@ -33,5 +33,5 @@ function FooterBrand({ locale, links, avatar, siteId, siteUrl }) {
|
|
|
33
33
|
export function FooterView({ links, version, year, buildInfo, avatar, siteId, siteUrl, consentLabel }) {
|
|
34
34
|
const { labels } = links;
|
|
35
35
|
const buildItems = buildInfoItems(buildInfo);
|
|
36
|
-
return (_jsxs("footer", { className: "hagilight-footer", children: [_jsx(FooterBrand, { locale: links.locale, links: links.quick, avatar: avatar, siteId: siteId, siteUrl: siteUrl }),
|
|
36
|
+
return (_jsxs("footer", { className: "hagilight-footer", children: [_jsx(FooterBrand, { locale: links.locale, links: links.quick, avatar: avatar, siteId: siteId, siteUrl: siteUrl }), _jsx("div", { className: "hagilight-footer__sections", children: _jsx("div", { className: "hagilight-cols", children: links.columns.map((column, index) => (_jsxs("nav", { className: "hagilight-col", "data-column": column.id, style: { '--hagilight-col-i': index }, "aria-labelledby": `hagilight-col-${column.id}`, children: [_jsx("h2", { id: `hagilight-col-${column.id}`, children: labels.columns[column.id] }), _jsx("ul", { children: column.entries.map((entry) => (_jsx("li", { children: _jsx(ColumnLink, { entry: entry }) }, entry.id))) })] }, column.id))) }) }), _jsxs("div", { className: "hagilight-footer__base", children: [links.feeds.length > 0 && (_jsx("nav", { className: "hagilight-footer__feeds", "aria-label": labels.navigation.feeds, children: links.feeds.map((entry) => (_jsx(ColumnLink, { entry: entry }, entry.id))) })), (links.filings.length > 0 || consentLabel) && (_jsxs("nav", { className: "hagilight-footer__filings", "aria-label": labels.navigation.filings, children: [links.filings.map((link) => (_jsx("a", { href: link.href, target: link.target, rel: link.rel, "aria-label": link.ariaLabel, children: link.label }, link.id))), consentLabel && (_jsx("button", { type: "button", className: "hagilight-footer__consent", "data-consent-preferences": true, children: consentLabel }))] }))] }), _jsxs("p", { className: "hagilight-footer__copyright", children: [_jsxs("span", { children: ["\u00A9 ", year, " HagiCode"] }), ' | ', _jsxs("span", { className: "hagilight-footer__attribution", children: ["Powered By hagilight-docusaurus@", version] }), buildItems.map((item) => (_jsxs(Fragment, { children: [' | ', _jsxs("span", { className: "hagilight-footer__build", "data-build-field": item.field, title: item.title, "data-build-commit": item.title, children: [item.label, ": ", item.datetime ? _jsx("time", { dateTime: item.datetime, children: item.text }) : item.text] })] }, item.field)))] })] }));
|
|
37
37
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hagicode/hagilight-docusaurus",
|
|
3
|
-
"version": "0.19.1-dev.
|
|
3
|
+
"version": "0.19.1-dev.189.1.6e24429",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Docusaurus plugin for HagiCode site features: footer, analytics, promote card, locales, SEO, sitemap, robots.txt, and RSS",
|
|
6
6
|
"repository": {
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
],
|
|
40
40
|
"dependencies": {
|
|
41
41
|
"@docusaurus/types": "^3.9.2",
|
|
42
|
-
"@hagicode/hagilight-core": "0.19.1-dev.
|
|
42
|
+
"@hagicode/hagilight-core": "0.19.1-dev.189.1.6e24429"
|
|
43
43
|
},
|
|
44
44
|
"peerDependencies": {
|
|
45
45
|
"@docusaurus/core": "^3.9.2",
|
package/styles.css
CHANGED
|
@@ -7,19 +7,17 @@
|
|
|
7
7
|
}
|
|
8
8
|
|
|
9
9
|
.hagilight-footer__sections {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
gap: 1.5rem;
|
|
13
|
-
margin: 0 auto 1.5rem;
|
|
10
|
+
container: hagilight-cols / inline-size;
|
|
11
|
+
margin: 0 auto 1.75rem;
|
|
14
12
|
max-width: 72rem;
|
|
15
13
|
}
|
|
16
14
|
|
|
17
|
-
.hagilight-
|
|
18
|
-
|
|
15
|
+
.hagilight-footer__base {
|
|
16
|
+
margin: 0 auto;
|
|
17
|
+
max-width: 72rem;
|
|
19
18
|
}
|
|
20
19
|
|
|
21
20
|
.hagilight-footer h2 {
|
|
22
|
-
margin: 0 0 0.75rem;
|
|
23
21
|
font-size: 0.95rem;
|
|
24
22
|
font-weight: 650;
|
|
25
23
|
}
|
|
@@ -49,16 +47,6 @@
|
|
|
49
47
|
outline-offset: 0.2rem;
|
|
50
48
|
}
|
|
51
49
|
|
|
52
|
-
.hagilight-footer__filings {
|
|
53
|
-
display: flex;
|
|
54
|
-
flex-wrap: wrap;
|
|
55
|
-
justify-content: center;
|
|
56
|
-
gap: 0.75rem 1.5rem;
|
|
57
|
-
border-top: 1px solid var(--hagilight-footer-border);
|
|
58
|
-
padding-top: 1rem;
|
|
59
|
-
text-align: center;
|
|
60
|
-
}
|
|
61
|
-
|
|
62
50
|
.hagilight-footer__copyright {
|
|
63
51
|
color: var(--hagilight-footer-muted);
|
|
64
52
|
font-size: 0.8rem;
|
|
@@ -74,18 +62,184 @@
|
|
|
74
62
|
overflow-wrap: anywhere;
|
|
75
63
|
}
|
|
76
64
|
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
65
|
+
/* Footer columns: four level, purpose-based columns. Each column owns a rule that
|
|
66
|
+
draws in as it scrolls into view and runs the full width while the column is
|
|
67
|
+
used; the other columns' headings step back. */
|
|
68
|
+
.hagilight-cols,
|
|
69
|
+
.hagilight-footer__base {
|
|
70
|
+
--_accent: var(--hagilight-footer-accent, var(--ifm-color-primary, currentColor));
|
|
71
|
+
--_track: var(--hagilight-footer-border, color-mix(in srgb, currentColor 26%, transparent));
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.hagilight-cols {
|
|
75
|
+
--_ease: cubic-bezier(0.16, 1, 0.3, 1);
|
|
76
|
+
display: grid;
|
|
77
|
+
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
78
|
+
gap: 1.75rem 1.5rem;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
@container hagilight-cols (max-width: 19rem) {
|
|
82
|
+
.hagilight-cols { grid-template-columns: minmax(0, 1fr); }
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
@container hagilight-cols (min-width: 40rem) {
|
|
86
|
+
.hagilight-cols { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0 2.25rem; }
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.hagilight-col {
|
|
90
|
+
--_seg: 0.12;
|
|
91
|
+
position: relative;
|
|
92
|
+
min-width: 0;
|
|
93
|
+
padding-top: 1.125rem;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.hagilight-col::before,
|
|
97
|
+
.hagilight-col::after {
|
|
98
|
+
content: '';
|
|
99
|
+
position: absolute;
|
|
100
|
+
inset: 0 0 auto;
|
|
101
|
+
height: 1px;
|
|
102
|
+
pointer-events: none;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.hagilight-col::before { background: var(--_track); }
|
|
106
|
+
|
|
107
|
+
.hagilight-col::after {
|
|
108
|
+
height: 2px;
|
|
109
|
+
margin-top: -0.5px;
|
|
110
|
+
background: var(--_accent);
|
|
111
|
+
transform-origin: left center;
|
|
112
|
+
scale: var(--_seg) 1;
|
|
113
|
+
transition: scale 0.6s var(--_ease);
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.hagilight-col h2 {
|
|
117
|
+
margin: 0 0 0.875rem;
|
|
118
|
+
transition: opacity 0.3s ease-out;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
.hagilight-col ul { gap: 0.4rem; }
|
|
122
|
+
|
|
123
|
+
.hagilight-col a {
|
|
124
|
+
position: relative;
|
|
125
|
+
display: inline-block;
|
|
126
|
+
padding-block: 0.125rem;
|
|
127
|
+
text-decoration: underline;
|
|
128
|
+
text-decoration-color: transparent;
|
|
129
|
+
text-decoration-thickness: 1px;
|
|
130
|
+
text-underline-offset: 0.25em;
|
|
131
|
+
transition: text-decoration-color 0.25s ease-out;
|
|
132
|
+
-webkit-tap-highlight-color: transparent;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
/* The link's own rule draws in the gutter, so a hover never reflows the label. */
|
|
136
|
+
.hagilight-col a::before {
|
|
137
|
+
content: '';
|
|
138
|
+
position: absolute;
|
|
139
|
+
top: 0.82em;
|
|
140
|
+
left: -0.95rem;
|
|
141
|
+
width: 0.7rem;
|
|
142
|
+
height: 1px;
|
|
143
|
+
background: var(--_accent);
|
|
144
|
+
transform-origin: left center;
|
|
145
|
+
scale: 0 1;
|
|
146
|
+
transition: scale 0.35s var(--_ease);
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.hagilight-col a[target='_blank']::after {
|
|
150
|
+
/* Joined to the last word by no-break spaces, so the arrow never wraps onto a line of its own. */
|
|
151
|
+
content: '\00a0\00a0\00a0';
|
|
152
|
+
background: currentColor;
|
|
153
|
+
opacity: 0.5;
|
|
154
|
+
-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 11.5l7-7M5.5 4.5h6v6' fill='none' stroke='%23000' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") right center / 0.62em 0.62em no-repeat;
|
|
155
|
+
mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 11.5l7-7M5.5 4.5h6v6' fill='none' stroke='%23000' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") right center / 0.62em 0.62em no-repeat;
|
|
156
|
+
transition: mask-position 0.3s var(--_ease), opacity 0.3s ease-out;
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
.hagilight-col a:is(:hover, :focus-visible) { text-decoration-color: currentColor; }
|
|
160
|
+
.hagilight-col a:is(:hover, :focus-visible)::before { scale: 1 1; }
|
|
161
|
+
.hagilight-col a[target='_blank']:is(:hover, :focus-visible)::after {
|
|
162
|
+
opacity: 0.9;
|
|
163
|
+
-webkit-mask-position: calc(100% + 0.1em) calc(50% - 0.1em);
|
|
164
|
+
mask-position: calc(100% + 0.1em) calc(50% - 0.1em);
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
.hagilight-col:is(:hover, :focus-within) { --_seg: 1; }
|
|
168
|
+
|
|
169
|
+
@media (hover: hover) {
|
|
170
|
+
.hagilight-cols:has(.hagilight-col:is(:hover, :focus-within)) .hagilight-col:not(:hover, :focus-within) h2 {
|
|
171
|
+
opacity: 0.5;
|
|
81
172
|
}
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
.hagilight-cols ::selection,
|
|
176
|
+
.hagilight-footer__base ::selection {
|
|
177
|
+
background: color-mix(in srgb, var(--_accent) 34%, transparent);
|
|
178
|
+
color: inherit;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
/* The one authored moment: columns rise out of a blur, one after another, as the footer scrolls in.
|
|
182
|
+
Without scroll-driven animation support, or under reduced motion, the columns are simply there. */
|
|
183
|
+
@media (prefers-reduced-motion: no-preference) {
|
|
184
|
+
@supports (animation-timeline: view()) {
|
|
185
|
+
.hagilight-col {
|
|
186
|
+
animation-name: hagilight-col-in;
|
|
187
|
+
animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
|
|
188
|
+
animation-fill-mode: both;
|
|
189
|
+
animation-timeline: view();
|
|
190
|
+
animation-range: entry calc(var(--hagilight-col-i, 0) * 6%) entry calc(46% + var(--hagilight-col-i, 0) * 6%);
|
|
191
|
+
}
|
|
82
192
|
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
193
|
+
.hagilight-col::after {
|
|
194
|
+
animation-name: hagilight-col-rule;
|
|
195
|
+
animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
|
|
196
|
+
animation-fill-mode: both;
|
|
197
|
+
animation-timeline: view();
|
|
198
|
+
animation-range: entry calc(var(--hagilight-col-i, 0) * 6%) entry calc(60% + var(--hagilight-col-i, 0) * 6%);
|
|
199
|
+
}
|
|
86
200
|
}
|
|
87
201
|
}
|
|
88
202
|
|
|
203
|
+
@keyframes hagilight-col-in {
|
|
204
|
+
from { opacity: 0; translate: 0 1.25rem; filter: blur(6px); }
|
|
205
|
+
to { opacity: 1; translate: 0 0; filter: blur(0); }
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
@keyframes hagilight-col-rule {
|
|
209
|
+
from { clip-path: inset(0 100% 0 0); }
|
|
210
|
+
to { clip-path: inset(0 0 0 0); }
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
/* The bottom row: feeds on the start side, filings on the end side. */
|
|
214
|
+
.hagilight-footer__base {
|
|
215
|
+
display: flex;
|
|
216
|
+
flex-wrap: wrap;
|
|
217
|
+
align-items: baseline;
|
|
218
|
+
justify-content: space-between;
|
|
219
|
+
gap: 0.75rem 2rem;
|
|
220
|
+
border-top: 1px solid var(--_track);
|
|
221
|
+
padding-top: 1rem;
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
.hagilight-footer__feeds,
|
|
225
|
+
.hagilight-footer__filings {
|
|
226
|
+
display: flex;
|
|
227
|
+
flex-wrap: wrap;
|
|
228
|
+
gap: 0.5rem 1.25rem;
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
.hagilight-footer__feeds a,
|
|
232
|
+
.hagilight-footer__filings a {
|
|
233
|
+
text-decoration: underline;
|
|
234
|
+
text-decoration-color: transparent;
|
|
235
|
+
text-decoration-thickness: 1px;
|
|
236
|
+
text-underline-offset: 0.25em;
|
|
237
|
+
transition: text-decoration-color 0.25s ease-out;
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
.hagilight-footer__feeds a:is(:hover, :focus-visible),
|
|
241
|
+
.hagilight-footer__filings a:is(:hover, :focus-visible) { text-decoration-color: currentColor; }
|
|
242
|
+
|
|
89
243
|
/* Product statement: headline, summary, calls to action, and the three pillars. */
|
|
90
244
|
.hagilight-footer .hagilight-brand {
|
|
91
245
|
--_heading: var(--ifm-heading-color, currentColor);
|