@agent-cms/agentcms 0.0.0-stage → 0.1.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/LICENSE +143 -0
- package/README.md +1119 -2
- package/changelog.json +31 -0
- package/dist/admin/admin-files.json +48 -0
- package/dist/admin/assets/CodeEditor-Wx1WlF3h.js +24 -0
- package/dist/admin/assets/flexweg-logo-CdtuqAFA.png +0 -0
- package/dist/admin/assets/index-DFVZw8E0.js +5460 -0
- package/dist/admin/assets/index-DMcGogR2.css +1 -0
- package/dist/admin/assets/sql-wasm-Bfkbn6Oa.js +2 -0
- package/dist/admin/assets/sql-wasm-C1U8OeUW.wasm +0 -0
- package/dist/admin/assets/sql-wasm-V5jTDcrT.js +1 -0
- package/dist/admin/config.js +11 -0
- package/dist/admin/external.default.json +72 -0
- package/dist/admin/index.html +116 -0
- package/dist/admin/plugins/core-seo/bundle.js +55 -0
- package/dist/admin/plugins/core-seo/manifest.json +7 -0
- package/dist/admin/plugins/flexweg-archives/bundle.js +1414 -0
- package/dist/admin/plugins/flexweg-archives/manifest.json +7 -0
- package/dist/admin/plugins/flexweg-multilang/bundle.js +1187 -0
- package/dist/admin/plugins/flexweg-multilang/manifest.json +7 -0
- package/dist/admin/plugins/flexweg-rss/bundle.js +1354 -0
- package/dist/admin/plugins/flexweg-rss/manifest.json +7 -0
- package/dist/admin/plugins/flexweg-search/bundle.js +1243 -0
- package/dist/admin/plugins/flexweg-search/manifest.json +7 -0
- package/dist/admin/plugins/flexweg-sitemaps/bundle.js +1293 -0
- package/dist/admin/plugins/flexweg-sitemaps/manifest.json +7 -0
- package/dist/admin/runtime/cms-runtime.js +164 -0
- package/dist/admin/runtime/react-dom-client.js +13 -0
- package/dist/admin/runtime/react-dom.js +16 -0
- package/dist/admin/runtime/react-i18next.js +21 -0
- package/dist/admin/runtime/react-jsx-runtime.js +17 -0
- package/dist/admin/runtime/react.js +55 -0
- package/dist/admin/themes/corporate/bundle.js +14465 -0
- package/dist/admin/themes/corporate/manifest.json +7 -0
- package/dist/admin/themes/corporate/theme.css +2 -0
- package/dist/admin/themes/magazine/bundle.js +10229 -0
- package/dist/admin/themes/magazine/manifest.json +7 -0
- package/dist/admin/themes/magazine/theme.css +2 -0
- package/dist/admin/themes/marketplace-core/bundle.js +11213 -0
- package/dist/admin/themes/marketplace-core/manifest.json +7 -0
- package/dist/admin/themes/marketplace-core/theme.css +1613 -0
- package/dist/admin/themes/portfolio/bundle.js +9195 -0
- package/dist/admin/themes/portfolio/manifest.json +7 -0
- package/dist/admin/themes/portfolio/theme.css +2 -0
- package/dist/admin/themes/storefront/bundle.js +13172 -0
- package/dist/admin/themes/storefront/manifest.json +7 -0
- package/dist/admin/themes/storefront/theme.css +2 -0
- package/dist/agent/agentcms.mjs +1711 -0
- package/dist/agent/chunks/hosting-BftlDdsL.mjs +117 -0
- package/dist/agent/chunks/index-BG05qslv.mjs +3608 -0
- package/dist/agent/chunks/install-DnmgOT3F.mjs +577 -0
- package/dist/agent/chunks/plan-BrM8ztEp.mjs +245 -0
- package/dist/agent/chunks/registry-C9TSnZ77.mjs +53517 -0
- package/dist/agent/chunks/siteAdd-BcXhN9fk.mjs +118 -0
- package/dist/agent/chunks/sql-wasm-GjJDiefO.mjs +10 -0
- package/dist/agent/chunks/sqljs-DjSCStJ0.mjs +20 -0
- package/dist/agent/vendor/sql-wasm.cjs +188 -0
- package/dist/theme-assets/corporate-menu.js +266 -0
- package/dist/theme-assets/corporate-posts.js +571 -0
- package/dist/theme-assets/corporate.css +2 -0
- package/dist/theme-assets/default-menu.js +266 -0
- package/dist/theme-assets/default-posts.js +378 -0
- package/dist/theme-assets/default.css +1 -0
- package/dist/theme-assets/magazine-menu.js +227 -0
- package/dist/theme-assets/magazine-posts.js +361 -0
- package/dist/theme-assets/magazine.css +2 -0
- package/dist/theme-assets/portfolio-filters.js +104 -0
- package/dist/theme-assets/portfolio-menu.js +240 -0
- package/dist/theme-assets/portfolio-posts.js +358 -0
- package/dist/theme-assets/portfolio.css +2 -0
- package/dist/theme-assets/storefront-catalog.js +504 -0
- package/dist/theme-assets/storefront-menu.js +239 -0
- package/dist/theme-assets/storefront-posts.js +404 -0
- package/dist/theme-assets/storefront.css +2 -0
- package/dist/version.json +9 -0
- package/package.json +101 -4
- package/plugin/.claude-plugin/plugin.json +16 -0
- package/plugin/skills/agentcms-install/SKILL.md +110 -0
- package/plugin/skills/agentcms-install/references/cloudflare.md +15 -0
- package/plugin/skills/agentcms-install/references/flexweg.md +11 -0
- package/plugin/skills/agentcms-install/references/github.md +67 -0
- package/plugin/skills/agentcms-install/references/gitlab.md +15 -0
- package/plugin/skills/agentcms-install/references/s3.md +81 -0
- package/plugin/skills/agentcms-manage/SKILL.md +92 -0
|
@@ -0,0 +1,1414 @@
|
|
|
1
|
+
import { buildPostUrl as he, deleteFolder as ge, uploadFile as T, deleteFile as pe, buildSiteContext as me, i18n as Y, pickPublicLocale as J, getActiveTheme as fe, renderPageToHtml as ye, useCmsData as ve, toast as P, fetchAllPosts as $ } from "@flexweg/cms-runtime";
|
|
2
|
+
import { jsxs as h, jsx as o } from "react/jsx-runtime";
|
|
3
|
+
import { forwardRef as E, createElement as M, useState as C, useEffect as be } from "react";
|
|
4
|
+
import { useTranslation as ke } from "react-i18next";
|
|
5
|
+
const we = {
|
|
6
|
+
title: "Archives",
|
|
7
|
+
description: "Generates static archive pages grouped by year (and optionally by month or ISO week) and adds a 'See full archives' link to home and category listings — a static-friendly alternative to pagination.",
|
|
8
|
+
regenerationTarget: {
|
|
9
|
+
label: "Archives",
|
|
10
|
+
description: "Wipe and rebuild every period page + the /archives/ index"
|
|
11
|
+
},
|
|
12
|
+
// ─── Admin / settings page ─────────────────────────────────────
|
|
13
|
+
settings: {
|
|
14
|
+
drillDown: "Drill-down",
|
|
15
|
+
drillDownHelp: "Sub-grouping inside each year. Years are always the top level.",
|
|
16
|
+
drillDownNone: "Year only",
|
|
17
|
+
drillDownMonth: "Year → month",
|
|
18
|
+
drillDownWeek: "Year → ISO week",
|
|
19
|
+
includePages: "Include static pages alongside posts",
|
|
20
|
+
includePagesHelp: "Off by default — pages are rarely chronological. Enable if you publish dated essays as pages instead of posts.",
|
|
21
|
+
addArchivesLinkToHome: "Show 'See full archives' link on the home page",
|
|
22
|
+
addArchivesLinkToCategory: "Show 'See full archives' link on category archives",
|
|
23
|
+
showCounts: "Show post counts next to each period",
|
|
24
|
+
save: "Save settings",
|
|
25
|
+
saving: "Saving…",
|
|
26
|
+
saved: "Settings saved.",
|
|
27
|
+
forceRegenerate: "Force regenerate archives",
|
|
28
|
+
forceRegenerating: "Regenerating…",
|
|
29
|
+
regenerated: "Archives regenerated ({{count}} files).",
|
|
30
|
+
regenerateFailed: "Archive regeneration failed.",
|
|
31
|
+
forceRegenerateHelp: "Wipes every file under /archives/ and rebuilds from scratch using all currently-online posts. Use after toggling drill-down or after a bulk import."
|
|
32
|
+
},
|
|
33
|
+
// ─── Public-baked strings (rendered into archive HTML) ────────
|
|
34
|
+
page: {
|
|
35
|
+
indexTitle: "Archives",
|
|
36
|
+
yearTitle: "Archives — {{year}}",
|
|
37
|
+
monthTitle: "{{month}} {{year}}",
|
|
38
|
+
weekTitle: "Week {{week}}, {{year}}",
|
|
39
|
+
indexSubtitle_one: "{{count}} article published.",
|
|
40
|
+
indexSubtitle_other: "{{count}} articles published.",
|
|
41
|
+
yearSubtitle_one: "{{count}} article published in {{year}}.",
|
|
42
|
+
yearSubtitle_other: "{{count}} articles published in {{year}}.",
|
|
43
|
+
monthSubtitle_one: "{{count}} article published in {{month}} {{year}}.",
|
|
44
|
+
monthSubtitle_other: "{{count}} articles published in {{month}} {{year}}.",
|
|
45
|
+
weekSubtitle_one: "{{count}} article published during week {{week}} of {{year}}.",
|
|
46
|
+
weekSubtitle_other: "{{count}} articles published during week {{week}} of {{year}}.",
|
|
47
|
+
empty: "No posts published yet.",
|
|
48
|
+
backToIndex: "← All archives",
|
|
49
|
+
backToYear: "← {{year}}",
|
|
50
|
+
seeFullArchives: "See full archives →",
|
|
51
|
+
months: {
|
|
52
|
+
1: "January",
|
|
53
|
+
2: "February",
|
|
54
|
+
3: "March",
|
|
55
|
+
4: "April",
|
|
56
|
+
5: "May",
|
|
57
|
+
6: "June",
|
|
58
|
+
7: "July",
|
|
59
|
+
8: "August",
|
|
60
|
+
9: "September",
|
|
61
|
+
10: "October",
|
|
62
|
+
11: "November",
|
|
63
|
+
12: "December"
|
|
64
|
+
},
|
|
65
|
+
weekShort: "W{{n}}",
|
|
66
|
+
countLabel_one: "{{count}} post",
|
|
67
|
+
countLabel_other: "{{count}} posts"
|
|
68
|
+
}
|
|
69
|
+
}, _e = {
|
|
70
|
+
title: "Archives",
|
|
71
|
+
description: "Génère des pages d'archives statiques groupées par année (et optionnellement par mois ou semaine ISO) et ajoute un lien « Voir toutes les archives » sur la home et les listings de catégorie — alternative compatible static à la pagination.",
|
|
72
|
+
regenerationTarget: {
|
|
73
|
+
label: "Archives",
|
|
74
|
+
description: "Vide et reconstruit toutes les pages période + l'index /archives/"
|
|
75
|
+
},
|
|
76
|
+
settings: {
|
|
77
|
+
drillDown: "Sous-groupement",
|
|
78
|
+
drillDownHelp: "Sous-groupement à l'intérieur de chaque année. L'année est toujours le niveau racine.",
|
|
79
|
+
drillDownNone: "Année seulement",
|
|
80
|
+
drillDownMonth: "Année → mois",
|
|
81
|
+
drillDownWeek: "Année → semaine ISO",
|
|
82
|
+
includePages: "Inclure les pages statiques en plus des articles",
|
|
83
|
+
includePagesHelp: "Désactivé par défaut — les pages sont rarement chronologiques. Activez si vous publiez des billets datés sous forme de pages.",
|
|
84
|
+
addArchivesLinkToHome: "Afficher « Voir toutes les archives » sur la home",
|
|
85
|
+
addArchivesLinkToCategory: "Afficher « Voir toutes les archives » sur les pages de catégorie",
|
|
86
|
+
showCounts: "Afficher le nombre d'articles à côté de chaque période",
|
|
87
|
+
save: "Enregistrer les réglages",
|
|
88
|
+
saving: "Enregistrement…",
|
|
89
|
+
saved: "Réglages enregistrés.",
|
|
90
|
+
forceRegenerate: "Forcer la régénération",
|
|
91
|
+
forceRegenerating: "Régénération…",
|
|
92
|
+
regenerated: "Archives régénérées ({{count}} fichiers).",
|
|
93
|
+
regenerateFailed: "Échec de la régénération.",
|
|
94
|
+
forceRegenerateHelp: "Supprime tous les fichiers sous /archives/ et reconstruit de zéro à partir des articles actuellement en ligne. Utile après changement de sous-groupement ou import en masse."
|
|
95
|
+
},
|
|
96
|
+
page: {
|
|
97
|
+
indexTitle: "Archives",
|
|
98
|
+
yearTitle: "Archives — {{year}}",
|
|
99
|
+
monthTitle: "{{month}} {{year}}",
|
|
100
|
+
weekTitle: "Semaine {{week}}, {{year}}",
|
|
101
|
+
indexSubtitle_one: "{{count}} article publié.",
|
|
102
|
+
indexSubtitle_other: "{{count}} articles publiés.",
|
|
103
|
+
yearSubtitle_one: "{{count}} article publié en {{year}}.",
|
|
104
|
+
yearSubtitle_other: "{{count}} articles publiés en {{year}}.",
|
|
105
|
+
monthSubtitle_one: "{{count}} article publié en {{month}} {{year}}.",
|
|
106
|
+
monthSubtitle_other: "{{count}} articles publiés en {{month}} {{year}}.",
|
|
107
|
+
weekSubtitle_one: "{{count}} article publié pendant la semaine {{week}} de {{year}}.",
|
|
108
|
+
weekSubtitle_other: "{{count}} articles publiés pendant la semaine {{week}} de {{year}}.",
|
|
109
|
+
empty: "Aucun article publié pour le moment.",
|
|
110
|
+
backToIndex: "← Toutes les archives",
|
|
111
|
+
backToYear: "← {{year}}",
|
|
112
|
+
seeFullArchives: "Voir toutes les archives →",
|
|
113
|
+
months: {
|
|
114
|
+
1: "Janvier",
|
|
115
|
+
2: "Février",
|
|
116
|
+
3: "Mars",
|
|
117
|
+
4: "Avril",
|
|
118
|
+
5: "Mai",
|
|
119
|
+
6: "Juin",
|
|
120
|
+
7: "Juillet",
|
|
121
|
+
8: "Août",
|
|
122
|
+
9: "Septembre",
|
|
123
|
+
10: "Octobre",
|
|
124
|
+
11: "Novembre",
|
|
125
|
+
12: "Décembre"
|
|
126
|
+
},
|
|
127
|
+
weekShort: "S{{n}}",
|
|
128
|
+
countLabel_one: "{{count}} article",
|
|
129
|
+
countLabel_other: "{{count}} articles"
|
|
130
|
+
}
|
|
131
|
+
}, Se = {
|
|
132
|
+
title: "Archive",
|
|
133
|
+
description: 'Erzeugt statische Archivseiten gruppiert nach Jahr (und optional nach Monat oder ISO-Woche) und fügt einen Link „Alle Archive ansehen" auf der Startseite und in Kategorie-Listings hinzu — eine static-freundliche Alternative zur Paginierung.',
|
|
134
|
+
regenerationTarget: {
|
|
135
|
+
label: "Archive",
|
|
136
|
+
description: "Löscht und erstellt jede Periodenseite + den /archives/-Index neu"
|
|
137
|
+
},
|
|
138
|
+
settings: {
|
|
139
|
+
drillDown: "Untergliederung",
|
|
140
|
+
drillDownHelp: "Untergruppierung innerhalb jedes Jahres. Jahre sind immer die oberste Ebene.",
|
|
141
|
+
drillDownNone: "Nur Jahr",
|
|
142
|
+
drillDownMonth: "Jahr → Monat",
|
|
143
|
+
drillDownWeek: "Jahr → ISO-Woche",
|
|
144
|
+
includePages: "Statische Seiten zusätzlich zu den Artikeln einbeziehen",
|
|
145
|
+
includePagesHelp: "Standardmäßig aus — Seiten sind selten chronologisch. Aktivieren, wenn Sie datierte Beiträge als Seiten veröffentlichen.",
|
|
146
|
+
addArchivesLinkToHome: 'Link „Alle Archive ansehen" auf der Startseite anzeigen',
|
|
147
|
+
addArchivesLinkToCategory: 'Link „Alle Archive ansehen" auf Kategorie-Archiven anzeigen',
|
|
148
|
+
showCounts: "Anzahl der Artikel neben jeder Periode anzeigen",
|
|
149
|
+
save: "Einstellungen speichern",
|
|
150
|
+
saving: "Speichert…",
|
|
151
|
+
saved: "Einstellungen gespeichert.",
|
|
152
|
+
forceRegenerate: "Archive zwangsweise neu erzeugen",
|
|
153
|
+
forceRegenerating: "Neu erzeugen…",
|
|
154
|
+
regenerated: "Archive neu erzeugt ({{count}} Dateien).",
|
|
155
|
+
regenerateFailed: "Archiv-Neuerzeugung fehlgeschlagen.",
|
|
156
|
+
forceRegenerateHelp: "Löscht alle Dateien unter /archives/ und baut sie von Grund auf neu mit allen aktuell online stehenden Artikeln. Nützlich nach Änderung der Untergliederung oder einem Massenimport."
|
|
157
|
+
},
|
|
158
|
+
page: {
|
|
159
|
+
indexTitle: "Archive",
|
|
160
|
+
yearTitle: "Archive — {{year}}",
|
|
161
|
+
monthTitle: "{{month}} {{year}}",
|
|
162
|
+
weekTitle: "Woche {{week}}, {{year}}",
|
|
163
|
+
indexSubtitle_one: "{{count}} Artikel veröffentlicht.",
|
|
164
|
+
indexSubtitle_other: "{{count}} Artikel veröffentlicht.",
|
|
165
|
+
yearSubtitle_one: "{{count}} Artikel veröffentlicht in {{year}}.",
|
|
166
|
+
yearSubtitle_other: "{{count}} Artikel veröffentlicht in {{year}}.",
|
|
167
|
+
monthSubtitle_one: "{{count}} Artikel veröffentlicht im {{month}} {{year}}.",
|
|
168
|
+
monthSubtitle_other: "{{count}} Artikel veröffentlicht im {{month}} {{year}}.",
|
|
169
|
+
weekSubtitle_one: "{{count}} Artikel veröffentlicht in Woche {{week}} {{year}}.",
|
|
170
|
+
weekSubtitle_other: "{{count}} Artikel veröffentlicht in Woche {{week}} {{year}}.",
|
|
171
|
+
empty: "Noch keine Artikel veröffentlicht.",
|
|
172
|
+
backToIndex: "← Alle Archive",
|
|
173
|
+
backToYear: "← {{year}}",
|
|
174
|
+
seeFullArchives: "Alle Archive ansehen →",
|
|
175
|
+
months: {
|
|
176
|
+
1: "Januar",
|
|
177
|
+
2: "Februar",
|
|
178
|
+
3: "März",
|
|
179
|
+
4: "April",
|
|
180
|
+
5: "Mai",
|
|
181
|
+
6: "Juni",
|
|
182
|
+
7: "Juli",
|
|
183
|
+
8: "August",
|
|
184
|
+
9: "September",
|
|
185
|
+
10: "Oktober",
|
|
186
|
+
11: "November",
|
|
187
|
+
12: "Dezember"
|
|
188
|
+
},
|
|
189
|
+
weekShort: "KW{{n}}",
|
|
190
|
+
countLabel_one: "{{count}} Artikel",
|
|
191
|
+
countLabel_other: "{{count}} Artikel"
|
|
192
|
+
}
|
|
193
|
+
}, Ae = {
|
|
194
|
+
title: "Archivos",
|
|
195
|
+
description: "Genera páginas de archivo estáticas agrupadas por año (y opcionalmente por mes o semana ISO) y añade un enlace «Ver archivo completo» en la home y en los listados de categoría — una alternativa compatible con hosting estático a la paginación.",
|
|
196
|
+
regenerationTarget: {
|
|
197
|
+
label: "Archivos",
|
|
198
|
+
description: "Borra y reconstruye cada página de período + el índice /archives/"
|
|
199
|
+
},
|
|
200
|
+
settings: {
|
|
201
|
+
drillDown: "Subagrupación",
|
|
202
|
+
drillDownHelp: "Subagrupación dentro de cada año. El año es siempre el nivel superior.",
|
|
203
|
+
drillDownNone: "Solo año",
|
|
204
|
+
drillDownMonth: "Año → mes",
|
|
205
|
+
drillDownWeek: "Año → semana ISO",
|
|
206
|
+
includePages: "Incluir páginas estáticas además de las entradas",
|
|
207
|
+
includePagesHelp: "Desactivado por defecto — las páginas raramente son cronológicas. Actívalo si publicas ensayos datados como páginas.",
|
|
208
|
+
addArchivesLinkToHome: "Mostrar «Ver archivo completo» en la home",
|
|
209
|
+
addArchivesLinkToCategory: "Mostrar «Ver archivo completo» en los archivos de categoría",
|
|
210
|
+
showCounts: "Mostrar el número de entradas junto a cada periodo",
|
|
211
|
+
save: "Guardar ajustes",
|
|
212
|
+
saving: "Guardando…",
|
|
213
|
+
saved: "Ajustes guardados.",
|
|
214
|
+
forceRegenerate: "Forzar regeneración",
|
|
215
|
+
forceRegenerating: "Regenerando…",
|
|
216
|
+
regenerated: "Archivos regenerados ({{count}} ficheros).",
|
|
217
|
+
regenerateFailed: "La regeneración falló.",
|
|
218
|
+
forceRegenerateHelp: "Borra todos los ficheros bajo /archives/ y los reconstruye desde cero con las entradas en línea actuales. Útil tras cambiar la subagrupación o tras una importación masiva."
|
|
219
|
+
},
|
|
220
|
+
page: {
|
|
221
|
+
indexTitle: "Archivos",
|
|
222
|
+
yearTitle: "Archivos — {{year}}",
|
|
223
|
+
monthTitle: "{{month}} {{year}}",
|
|
224
|
+
weekTitle: "Semana {{week}}, {{year}}",
|
|
225
|
+
indexSubtitle_one: "{{count}} entrada publicada.",
|
|
226
|
+
indexSubtitle_other: "{{count}} entradas publicadas.",
|
|
227
|
+
yearSubtitle_one: "{{count}} entrada publicada en {{year}}.",
|
|
228
|
+
yearSubtitle_other: "{{count}} entradas publicadas en {{year}}.",
|
|
229
|
+
monthSubtitle_one: "{{count}} entrada publicada en {{month}} {{year}}.",
|
|
230
|
+
monthSubtitle_other: "{{count}} entradas publicadas en {{month}} {{year}}.",
|
|
231
|
+
weekSubtitle_one: "{{count}} entrada publicada durante la semana {{week}} de {{year}}.",
|
|
232
|
+
weekSubtitle_other: "{{count}} entradas publicadas durante la semana {{week}} de {{year}}.",
|
|
233
|
+
empty: "Todavía no hay entradas publicadas.",
|
|
234
|
+
backToIndex: "← Todos los archivos",
|
|
235
|
+
backToYear: "← {{year}}",
|
|
236
|
+
seeFullArchives: "Ver archivo completo →",
|
|
237
|
+
months: {
|
|
238
|
+
1: "Enero",
|
|
239
|
+
2: "Febrero",
|
|
240
|
+
3: "Marzo",
|
|
241
|
+
4: "Abril",
|
|
242
|
+
5: "Mayo",
|
|
243
|
+
6: "Junio",
|
|
244
|
+
7: "Julio",
|
|
245
|
+
8: "Agosto",
|
|
246
|
+
9: "Septiembre",
|
|
247
|
+
10: "Octubre",
|
|
248
|
+
11: "Noviembre",
|
|
249
|
+
12: "Diciembre"
|
|
250
|
+
},
|
|
251
|
+
weekShort: "S{{n}}",
|
|
252
|
+
countLabel_one: "{{count}} entrada",
|
|
253
|
+
countLabel_other: "{{count}} entradas"
|
|
254
|
+
}
|
|
255
|
+
}, Te = {
|
|
256
|
+
title: "Archief",
|
|
257
|
+
description: "Genereert statische archiefpagina's gegroepeerd per jaar (en optioneel per maand of ISO-week) en voegt een link 'Volledige archief bekijken' toe aan de homepagina en categorie-overzichten — een static-vriendelijk alternatief voor paginatie.",
|
|
258
|
+
regenerationTarget: {
|
|
259
|
+
label: "Archief",
|
|
260
|
+
description: "Wist en bouwt elke periodepagina + de /archives/-index opnieuw"
|
|
261
|
+
},
|
|
262
|
+
settings: {
|
|
263
|
+
drillDown: "Sub-groepering",
|
|
264
|
+
drillDownHelp: "Subgroepering binnen elk jaar. Jaren zijn altijd het hoogste niveau.",
|
|
265
|
+
drillDownNone: "Alleen jaar",
|
|
266
|
+
drillDownMonth: "Jaar → maand",
|
|
267
|
+
drillDownWeek: "Jaar → ISO-week",
|
|
268
|
+
includePages: "Statische pagina's mee opnemen naast berichten",
|
|
269
|
+
includePagesHelp: "Standaard uit — pagina's zijn zelden chronologisch. Schakel in als je gedateerde stukken als pagina's publiceert.",
|
|
270
|
+
addArchivesLinkToHome: "Toon 'Volledige archief bekijken' op de homepagina",
|
|
271
|
+
addArchivesLinkToCategory: "Toon 'Volledige archief bekijken' op categoriearchieven",
|
|
272
|
+
showCounts: "Toon aantal berichten naast elke periode",
|
|
273
|
+
save: "Instellingen opslaan",
|
|
274
|
+
saving: "Opslaan…",
|
|
275
|
+
saved: "Instellingen opgeslagen.",
|
|
276
|
+
forceRegenerate: "Archief geforceerd regenereren",
|
|
277
|
+
forceRegenerating: "Regenereren…",
|
|
278
|
+
regenerated: "Archief geregenereerd ({{count}} bestanden).",
|
|
279
|
+
regenerateFailed: "Archief-regeneratie mislukt.",
|
|
280
|
+
forceRegenerateHelp: "Wist alle bestanden onder /archives/ en bouwt vanaf nul met de momenteel online berichten. Handig na het wijzigen van de subgroepering of na een bulkimport."
|
|
281
|
+
},
|
|
282
|
+
page: {
|
|
283
|
+
indexTitle: "Archief",
|
|
284
|
+
yearTitle: "Archief — {{year}}",
|
|
285
|
+
monthTitle: "{{month}} {{year}}",
|
|
286
|
+
weekTitle: "Week {{week}}, {{year}}",
|
|
287
|
+
indexSubtitle_one: "{{count}} bericht gepubliceerd.",
|
|
288
|
+
indexSubtitle_other: "{{count}} berichten gepubliceerd.",
|
|
289
|
+
yearSubtitle_one: "{{count}} bericht gepubliceerd in {{year}}.",
|
|
290
|
+
yearSubtitle_other: "{{count}} berichten gepubliceerd in {{year}}.",
|
|
291
|
+
monthSubtitle_one: "{{count}} bericht gepubliceerd in {{month}} {{year}}.",
|
|
292
|
+
monthSubtitle_other: "{{count}} berichten gepubliceerd in {{month}} {{year}}.",
|
|
293
|
+
weekSubtitle_one: "{{count}} bericht gepubliceerd in week {{week}} van {{year}}.",
|
|
294
|
+
weekSubtitle_other: "{{count}} berichten gepubliceerd in week {{week}} van {{year}}.",
|
|
295
|
+
empty: "Nog geen berichten gepubliceerd.",
|
|
296
|
+
backToIndex: "← Volledig archief",
|
|
297
|
+
backToYear: "← {{year}}",
|
|
298
|
+
seeFullArchives: "Volledige archief bekijken →",
|
|
299
|
+
months: {
|
|
300
|
+
1: "Januari",
|
|
301
|
+
2: "Februari",
|
|
302
|
+
3: "Maart",
|
|
303
|
+
4: "April",
|
|
304
|
+
5: "Mei",
|
|
305
|
+
6: "Juni",
|
|
306
|
+
7: "Juli",
|
|
307
|
+
8: "Augustus",
|
|
308
|
+
9: "September",
|
|
309
|
+
10: "Oktober",
|
|
310
|
+
11: "November",
|
|
311
|
+
12: "December"
|
|
312
|
+
},
|
|
313
|
+
weekShort: "W{{n}}",
|
|
314
|
+
countLabel_one: "{{count}} bericht",
|
|
315
|
+
countLabel_other: "{{count}} berichten"
|
|
316
|
+
}
|
|
317
|
+
}, xe = {
|
|
318
|
+
title: "Arquivos",
|
|
319
|
+
description: "Gera páginas de arquivo estáticas agrupadas por ano (e opcionalmente por mês ou semana ISO) e adiciona um link «Ver arquivo completo» na página inicial e nas listagens de categoria — uma alternativa compatível com alojamento estático à paginação.",
|
|
320
|
+
regenerationTarget: {
|
|
321
|
+
label: "Arquivos",
|
|
322
|
+
description: "Limpa e reconstrói cada página de período + o índice /archives/"
|
|
323
|
+
},
|
|
324
|
+
settings: {
|
|
325
|
+
drillDown: "Subagrupamento",
|
|
326
|
+
drillDownHelp: "Subagrupamento dentro de cada ano. O ano é sempre o nível superior.",
|
|
327
|
+
drillDownNone: "Apenas ano",
|
|
328
|
+
drillDownMonth: "Ano → mês",
|
|
329
|
+
drillDownWeek: "Ano → semana ISO",
|
|
330
|
+
includePages: "Incluir páginas estáticas além dos artigos",
|
|
331
|
+
includePagesHelp: "Desativado por defeito — as páginas raramente são cronológicas. Ativa se publicas ensaios datados como páginas.",
|
|
332
|
+
addArchivesLinkToHome: "Mostrar «Ver arquivo completo» na página inicial",
|
|
333
|
+
addArchivesLinkToCategory: "Mostrar «Ver arquivo completo» nos arquivos de categoria",
|
|
334
|
+
showCounts: "Mostrar contagem de artigos junto a cada período",
|
|
335
|
+
save: "Guardar definições",
|
|
336
|
+
saving: "A guardar…",
|
|
337
|
+
saved: "Definições guardadas.",
|
|
338
|
+
forceRegenerate: "Forçar regeneração",
|
|
339
|
+
forceRegenerating: "A regenerar…",
|
|
340
|
+
regenerated: "Arquivos regenerados ({{count}} ficheiros).",
|
|
341
|
+
regenerateFailed: "Falha na regeneração.",
|
|
342
|
+
forceRegenerateHelp: "Apaga todos os ficheiros em /archives/ e reconstrói de raiz a partir dos artigos atualmente online. Útil após mudar o subagrupamento ou após uma importação em massa."
|
|
343
|
+
},
|
|
344
|
+
page: {
|
|
345
|
+
indexTitle: "Arquivos",
|
|
346
|
+
yearTitle: "Arquivos — {{year}}",
|
|
347
|
+
monthTitle: "{{month}} {{year}}",
|
|
348
|
+
weekTitle: "Semana {{week}}, {{year}}",
|
|
349
|
+
indexSubtitle_one: "{{count}} artigo publicado.",
|
|
350
|
+
indexSubtitle_other: "{{count}} artigos publicados.",
|
|
351
|
+
yearSubtitle_one: "{{count}} artigo publicado em {{year}}.",
|
|
352
|
+
yearSubtitle_other: "{{count}} artigos publicados em {{year}}.",
|
|
353
|
+
monthSubtitle_one: "{{count}} artigo publicado em {{month}} {{year}}.",
|
|
354
|
+
monthSubtitle_other: "{{count}} artigos publicados em {{month}} {{year}}.",
|
|
355
|
+
weekSubtitle_one: "{{count}} artigo publicado durante a semana {{week}} de {{year}}.",
|
|
356
|
+
weekSubtitle_other: "{{count}} artigos publicados durante a semana {{week}} de {{year}}.",
|
|
357
|
+
empty: "Ainda sem artigos publicados.",
|
|
358
|
+
backToIndex: "← Todos os arquivos",
|
|
359
|
+
backToYear: "← {{year}}",
|
|
360
|
+
seeFullArchives: "Ver arquivo completo →",
|
|
361
|
+
months: {
|
|
362
|
+
1: "Janeiro",
|
|
363
|
+
2: "Fevereiro",
|
|
364
|
+
3: "Março",
|
|
365
|
+
4: "Abril",
|
|
366
|
+
5: "Maio",
|
|
367
|
+
6: "Junho",
|
|
368
|
+
7: "Julho",
|
|
369
|
+
8: "Agosto",
|
|
370
|
+
9: "Setembro",
|
|
371
|
+
10: "Outubro",
|
|
372
|
+
11: "Novembro",
|
|
373
|
+
12: "Dezembro"
|
|
374
|
+
},
|
|
375
|
+
weekShort: "S{{n}}",
|
|
376
|
+
countLabel_one: "{{count}} artigo",
|
|
377
|
+
countLabel_other: "{{count}} artigos"
|
|
378
|
+
}
|
|
379
|
+
}, De = {
|
|
380
|
+
title: "아카이브",
|
|
381
|
+
description: "연도별로 그룹화된 정적 아카이브 페이지를 생성하며 (선택적으로 월 또는 ISO 주별로 세분화) 홈과 카테고리 목록에 '전체 아카이브 보기' 링크를 추가합니다 — 페이지네이션의 정적 호스팅 친화적 대안입니다.",
|
|
382
|
+
regenerationTarget: {
|
|
383
|
+
label: "아카이브",
|
|
384
|
+
description: "모든 기간별 페이지 + /archives/ 인덱스를 지우고 다시 빌드"
|
|
385
|
+
},
|
|
386
|
+
settings: {
|
|
387
|
+
drillDown: "세부 분류",
|
|
388
|
+
drillDownHelp: "각 연도 내의 하위 그룹화. 연도는 항상 최상위 레벨입니다.",
|
|
389
|
+
drillDownNone: "연도만",
|
|
390
|
+
drillDownMonth: "연도 → 월",
|
|
391
|
+
drillDownWeek: "연도 → ISO 주",
|
|
392
|
+
includePages: "게시물 외에 정적 페이지도 포함",
|
|
393
|
+
includePagesHelp: "기본적으로 비활성화 — 페이지는 시간순인 경우가 드뭅니다. 날짜가 있는 글을 페이지로 게시하는 경우 활성화하세요.",
|
|
394
|
+
addArchivesLinkToHome: "홈 페이지에 '전체 아카이브 보기' 링크 표시",
|
|
395
|
+
addArchivesLinkToCategory: "카테고리 아카이브에 '전체 아카이브 보기' 링크 표시",
|
|
396
|
+
showCounts: "각 기간 옆에 게시물 수 표시",
|
|
397
|
+
save: "설정 저장",
|
|
398
|
+
saving: "저장 중…",
|
|
399
|
+
saved: "설정이 저장되었습니다.",
|
|
400
|
+
forceRegenerate: "아카이브 강제 재생성",
|
|
401
|
+
forceRegenerating: "재생성 중…",
|
|
402
|
+
regenerated: "아카이브가 재생성되었습니다 ({{count}}개 파일).",
|
|
403
|
+
regenerateFailed: "아카이브 재생성에 실패했습니다.",
|
|
404
|
+
forceRegenerateHelp: "/archives/ 아래의 모든 파일을 삭제하고 현재 온라인 상태인 모든 게시물로부터 처음부터 다시 빌드합니다. 세부 분류 변경 후 또는 대량 가져오기 후에 유용합니다."
|
|
405
|
+
},
|
|
406
|
+
page: {
|
|
407
|
+
indexTitle: "아카이브",
|
|
408
|
+
yearTitle: "아카이브 — {{year}}",
|
|
409
|
+
monthTitle: "{{year}}년 {{month}}",
|
|
410
|
+
weekTitle: "{{year}}년 {{week}}주",
|
|
411
|
+
indexSubtitle_one: "{{count}}개의 게시물이 게시되었습니다.",
|
|
412
|
+
indexSubtitle_other: "{{count}}개의 게시물이 게시되었습니다.",
|
|
413
|
+
yearSubtitle_one: "{{year}}년에 {{count}}개의 게시물이 게시되었습니다.",
|
|
414
|
+
yearSubtitle_other: "{{year}}년에 {{count}}개의 게시물이 게시되었습니다.",
|
|
415
|
+
monthSubtitle_one: "{{year}}년 {{month}}에 {{count}}개의 게시물이 게시되었습니다.",
|
|
416
|
+
monthSubtitle_other: "{{year}}년 {{month}}에 {{count}}개의 게시물이 게시되었습니다.",
|
|
417
|
+
weekSubtitle_one: "{{year}}년 {{week}}주에 {{count}}개의 게시물이 게시되었습니다.",
|
|
418
|
+
weekSubtitle_other: "{{year}}년 {{week}}주에 {{count}}개의 게시물이 게시되었습니다.",
|
|
419
|
+
empty: "아직 게시된 게시물이 없습니다.",
|
|
420
|
+
backToIndex: "← 전체 아카이브",
|
|
421
|
+
backToYear: "← {{year}}",
|
|
422
|
+
seeFullArchives: "전체 아카이브 보기 →",
|
|
423
|
+
months: {
|
|
424
|
+
1: "1월",
|
|
425
|
+
2: "2월",
|
|
426
|
+
3: "3월",
|
|
427
|
+
4: "4월",
|
|
428
|
+
5: "5월",
|
|
429
|
+
6: "6월",
|
|
430
|
+
7: "7월",
|
|
431
|
+
8: "8월",
|
|
432
|
+
9: "9월",
|
|
433
|
+
10: "10월",
|
|
434
|
+
11: "11월",
|
|
435
|
+
12: "12월"
|
|
436
|
+
},
|
|
437
|
+
weekShort: "W{{n}}",
|
|
438
|
+
countLabel_one: "{{count}}개의 게시물",
|
|
439
|
+
countLabel_other: "{{count}}개의 게시물"
|
|
440
|
+
}
|
|
441
|
+
};
|
|
442
|
+
function H(e) {
|
|
443
|
+
if (!e || typeof e != "object") return null;
|
|
444
|
+
const t = e;
|
|
445
|
+
if (typeof t.toDate == "function")
|
|
446
|
+
try {
|
|
447
|
+
return t.toDate();
|
|
448
|
+
} catch {
|
|
449
|
+
return null;
|
|
450
|
+
}
|
|
451
|
+
return typeof t.toMillis == "function" ? new Date(t.toMillis()) : null;
|
|
452
|
+
}
|
|
453
|
+
function x(e) {
|
|
454
|
+
return H(e.publishedAt) ?? H(e.updatedAt) ?? H(e.createdAt);
|
|
455
|
+
}
|
|
456
|
+
function Le(e) {
|
|
457
|
+
const t = new Date(Date.UTC(e.getUTCFullYear(), e.getUTCMonth(), e.getUTCDate())), n = t.getUTCDay() || 7;
|
|
458
|
+
t.setUTCDate(t.getUTCDate() + 4 - n);
|
|
459
|
+
const a = t.getUTCFullYear(), r = new Date(Date.UTC(a, 0, 1)), i = Math.ceil(((t.getTime() - r.getTime()) / 864e5 + 1) / 7);
|
|
460
|
+
return { year: a, week: i };
|
|
461
|
+
}
|
|
462
|
+
function L(e, t) {
|
|
463
|
+
const n = x(e);
|
|
464
|
+
if (!n) return null;
|
|
465
|
+
const a = { kind: "year", year: n.getUTCFullYear() };
|
|
466
|
+
if (t === "month")
|
|
467
|
+
return {
|
|
468
|
+
year: a,
|
|
469
|
+
drill: { kind: "month", year: a.year, month: n.getUTCMonth() + 1 }
|
|
470
|
+
};
|
|
471
|
+
if (t === "week") {
|
|
472
|
+
const r = Le(n);
|
|
473
|
+
return { year: a, drill: { kind: "week", year: r.year, week: r.week } };
|
|
474
|
+
}
|
|
475
|
+
return { year: a, drill: null };
|
|
476
|
+
}
|
|
477
|
+
const y = "archives", V = `${y}/index.html`;
|
|
478
|
+
function U(e, t = y) {
|
|
479
|
+
return `${t}/${e.year}/index.html`;
|
|
480
|
+
}
|
|
481
|
+
function q(e, t = y) {
|
|
482
|
+
const n = String(e.month).padStart(2, "0");
|
|
483
|
+
return `${t}/${e.year}/${n}/index.html`;
|
|
484
|
+
}
|
|
485
|
+
function G(e, t = y) {
|
|
486
|
+
const n = String(e.week).padStart(2, "0");
|
|
487
|
+
return `${t}/${e.year}/W${n}/index.html`;
|
|
488
|
+
}
|
|
489
|
+
function Ne(e, t = y) {
|
|
490
|
+
return e.kind === "year" ? U(e, t) : e.kind === "month" ? q(e, t) : G(e, t);
|
|
491
|
+
}
|
|
492
|
+
function D(e, t = y) {
|
|
493
|
+
return `/${Ne(e, t).replace(/index\.html$/, "")}`;
|
|
494
|
+
}
|
|
495
|
+
const Pe = `/${y}/`;
|
|
496
|
+
function N(e, t) {
|
|
497
|
+
return !e || e === t ? y : `${e}/${y}`;
|
|
498
|
+
}
|
|
499
|
+
function B(e, t) {
|
|
500
|
+
return `${N(e, t)}/index.html`;
|
|
501
|
+
}
|
|
502
|
+
function K(e, t) {
|
|
503
|
+
return `/${N(e, t)}/`;
|
|
504
|
+
}
|
|
505
|
+
function w(e) {
|
|
506
|
+
return e.kind === "year" ? `Y${e.year}` : e.kind === "month" ? `M${e.year}-${String(e.month).padStart(2, "0")}` : `W${e.year}-${String(e.week).padStart(2, "0")}`;
|
|
507
|
+
}
|
|
508
|
+
function _(e, t) {
|
|
509
|
+
return e.year !== t.year ? t.year - e.year : e.kind === "month" && t.kind === "month" ? t.month - e.month : e.kind === "week" && t.kind === "week" ? t.week - e.week : 0;
|
|
510
|
+
}
|
|
511
|
+
function F(e, t, n) {
|
|
512
|
+
const a = /* @__PURE__ */ new Map();
|
|
513
|
+
for (const r of e) {
|
|
514
|
+
const i = L(r, t);
|
|
515
|
+
if (!i) continue;
|
|
516
|
+
const l = n === "year" ? i.year : i.drill ?? i.year, c = w(l);
|
|
517
|
+
let s = a.get(c);
|
|
518
|
+
s || (s = { period: l, posts: [] }, a.set(c, s)), s.posts.push(r);
|
|
519
|
+
}
|
|
520
|
+
return a;
|
|
521
|
+
}
|
|
522
|
+
function W(e) {
|
|
523
|
+
return [...e].sort((t, n) => {
|
|
524
|
+
var i, l;
|
|
525
|
+
const a = ((i = x(t)) == null ? void 0 : i.getTime()) ?? 0, r = ((l = x(n)) == null ? void 0 : l.getTime()) ?? 0;
|
|
526
|
+
return r !== a ? r - a : t.id < n.id ? 1 : -1;
|
|
527
|
+
});
|
|
528
|
+
}
|
|
529
|
+
function Ce(e, t) {
|
|
530
|
+
const n = e.primaryTermId ? t.find((a) => a.id === e.primaryTermId) : void 0;
|
|
531
|
+
return `/${he({
|
|
532
|
+
post: e,
|
|
533
|
+
primaryTerm: n ? { ...n, type: "category" } : void 0
|
|
534
|
+
})}`;
|
|
535
|
+
}
|
|
536
|
+
function j({ post: e, language: t, terms: n }) {
|
|
537
|
+
const a = x(e), r = a ? new Intl.DateTimeFormat(t || "en", {
|
|
538
|
+
year: "numeric",
|
|
539
|
+
month: "long",
|
|
540
|
+
day: "numeric"
|
|
541
|
+
}).format(a) : "";
|
|
542
|
+
return /* @__PURE__ */ h("li", { className: "archives__item", children: [
|
|
543
|
+
/* @__PURE__ */ o("a", { className: "archives__item-link", href: Ce(e, n), children: e.title }),
|
|
544
|
+
r && /* @__PURE__ */ o("time", { className: "archives__item-date", dateTime: a == null ? void 0 : a.toISOString(), children: r })
|
|
545
|
+
] });
|
|
546
|
+
}
|
|
547
|
+
function X(e, t) {
|
|
548
|
+
return e.kind === "year" ? String(e.year) : e.kind === "month" ? `${t(`page.months.${e.month}`)} ${e.year}` : t("page.weekTitle", { week: e.week, year: e.year });
|
|
549
|
+
}
|
|
550
|
+
function He({
|
|
551
|
+
posts: e,
|
|
552
|
+
drillDown: t,
|
|
553
|
+
showCounts: n,
|
|
554
|
+
t: a,
|
|
555
|
+
root: r
|
|
556
|
+
}) {
|
|
557
|
+
const i = [...F(e, t, "year").values()].sort(
|
|
558
|
+
(c, s) => _(c.period, s.period)
|
|
559
|
+
), l = e.length;
|
|
560
|
+
return /* @__PURE__ */ h("main", { className: "archives archives--index", children: [
|
|
561
|
+
/* @__PURE__ */ h("header", { className: "archives__header", children: [
|
|
562
|
+
/* @__PURE__ */ o("h1", { className: "archives__title", children: a("page.indexTitle") }),
|
|
563
|
+
l > 0 && /* @__PURE__ */ o("p", { className: "archives__subtitle", children: a("page.indexSubtitle", { count: l }) })
|
|
564
|
+
] }),
|
|
565
|
+
l === 0 && /* @__PURE__ */ o("p", { className: "archives__empty", children: a("page.empty") }),
|
|
566
|
+
i.length > 0 && /* @__PURE__ */ o("ul", { className: "archives__years", children: i.map(({ period: c, posts: s }) => {
|
|
567
|
+
const d = c, g = t === "none" ? null : [
|
|
568
|
+
...F(s, t, "drill").values()
|
|
569
|
+
].sort((p, m) => _(p.period, m.period));
|
|
570
|
+
return /* @__PURE__ */ h("li", { className: "archives__year", children: [
|
|
571
|
+
/* @__PURE__ */ h("h2", { className: "archives__year-heading", children: [
|
|
572
|
+
/* @__PURE__ */ o("a", { className: "archives__year-link", href: D(d, r), children: d.year }),
|
|
573
|
+
n && /* @__PURE__ */ h("span", { className: "archives__count", children: [
|
|
574
|
+
"(",
|
|
575
|
+
s.length,
|
|
576
|
+
")"
|
|
577
|
+
] })
|
|
578
|
+
] }),
|
|
579
|
+
g && g.length > 0 && /* @__PURE__ */ o("ul", { className: "archives__drilldown", children: g.map(({ period: p, posts: m }) => /* @__PURE__ */ h(
|
|
580
|
+
"li",
|
|
581
|
+
{
|
|
582
|
+
className: "archives__drilldown-item",
|
|
583
|
+
children: [
|
|
584
|
+
/* @__PURE__ */ o(
|
|
585
|
+
"a",
|
|
586
|
+
{
|
|
587
|
+
className: "archives__drilldown-link",
|
|
588
|
+
href: D(p, r),
|
|
589
|
+
children: X(p, a)
|
|
590
|
+
}
|
|
591
|
+
),
|
|
592
|
+
n && /* @__PURE__ */ h("span", { className: "archives__count", children: [
|
|
593
|
+
"(",
|
|
594
|
+
m.length,
|
|
595
|
+
")"
|
|
596
|
+
] })
|
|
597
|
+
]
|
|
598
|
+
},
|
|
599
|
+
w(p)
|
|
600
|
+
)) })
|
|
601
|
+
] }, d.year);
|
|
602
|
+
}) })
|
|
603
|
+
] });
|
|
604
|
+
}
|
|
605
|
+
function Ie({
|
|
606
|
+
period: e,
|
|
607
|
+
posts: t,
|
|
608
|
+
drillDown: n,
|
|
609
|
+
showCounts: a,
|
|
610
|
+
language: r,
|
|
611
|
+
t: i,
|
|
612
|
+
terms: l,
|
|
613
|
+
root: c,
|
|
614
|
+
indexHref: s
|
|
615
|
+
}) {
|
|
616
|
+
const d = W(t);
|
|
617
|
+
let g, p;
|
|
618
|
+
if (e.kind === "year")
|
|
619
|
+
g = i("page.yearTitle", { year: e.year }), p = i("page.yearSubtitle", { count: t.length, year: e.year });
|
|
620
|
+
else if (e.kind === "month") {
|
|
621
|
+
const f = i(`page.months.${e.month}`);
|
|
622
|
+
g = i("page.monthTitle", { month: f, year: e.year }), p = i("page.monthSubtitle", {
|
|
623
|
+
count: t.length,
|
|
624
|
+
month: f,
|
|
625
|
+
year: e.year
|
|
626
|
+
});
|
|
627
|
+
} else
|
|
628
|
+
g = i("page.weekTitle", { week: e.week, year: e.year }), p = i("page.weekSubtitle", {
|
|
629
|
+
count: t.length,
|
|
630
|
+
week: e.week,
|
|
631
|
+
year: e.year
|
|
632
|
+
});
|
|
633
|
+
const m = e.kind === "year" && n !== "none", b = m ? [...F(d, n, "drill").values()].sort(
|
|
634
|
+
(f, k) => _(f.period, k.period)
|
|
635
|
+
) : null, u = e.kind === "year" ? s ?? Pe : D({ kind: "year", year: e.year }, c), v = e.kind === "year" ? i("page.backToIndex") : i("page.backToYear", { year: e.year });
|
|
636
|
+
return /* @__PURE__ */ h("main", { className: "archives archives--period", children: [
|
|
637
|
+
/* @__PURE__ */ h("header", { className: "archives__header", children: [
|
|
638
|
+
/* @__PURE__ */ o("p", { className: "archives__back", children: /* @__PURE__ */ o("a", { href: u, children: v }) }),
|
|
639
|
+
/* @__PURE__ */ o("h1", { className: "archives__title", children: g }),
|
|
640
|
+
t.length > 0 && /* @__PURE__ */ o("p", { className: "archives__subtitle", children: p })
|
|
641
|
+
] }),
|
|
642
|
+
t.length === 0 && /* @__PURE__ */ o("p", { className: "archives__empty", children: i("page.empty") }),
|
|
643
|
+
!m && t.length > 0 && /* @__PURE__ */ o("ul", { className: "archives__list", children: d.map((f) => /* @__PURE__ */ o(
|
|
644
|
+
j,
|
|
645
|
+
{
|
|
646
|
+
post: f,
|
|
647
|
+
language: r,
|
|
648
|
+
terms: l
|
|
649
|
+
},
|
|
650
|
+
f.id
|
|
651
|
+
)) }),
|
|
652
|
+
m && b && /* @__PURE__ */ o("div", { className: "archives__groups", children: b.map(({ period: f, posts: k }) => /* @__PURE__ */ h("section", { className: "archives__group", children: [
|
|
653
|
+
/* @__PURE__ */ h("h2", { className: "archives__group-heading", children: [
|
|
654
|
+
/* @__PURE__ */ o(
|
|
655
|
+
"a",
|
|
656
|
+
{
|
|
657
|
+
className: "archives__group-link",
|
|
658
|
+
href: D(f, c),
|
|
659
|
+
children: X(f, i)
|
|
660
|
+
}
|
|
661
|
+
),
|
|
662
|
+
a && /* @__PURE__ */ h("span", { className: "archives__count", children: [
|
|
663
|
+
"(",
|
|
664
|
+
k.length,
|
|
665
|
+
")"
|
|
666
|
+
] })
|
|
667
|
+
] }),
|
|
668
|
+
/* @__PURE__ */ o("ul", { className: "archives__list", children: W(k).map((A) => /* @__PURE__ */ o(
|
|
669
|
+
j,
|
|
670
|
+
{
|
|
671
|
+
post: A,
|
|
672
|
+
language: r,
|
|
673
|
+
terms: l
|
|
674
|
+
},
|
|
675
|
+
A.id
|
|
676
|
+
)) })
|
|
677
|
+
] }, w(f))) })
|
|
678
|
+
] });
|
|
679
|
+
}
|
|
680
|
+
function Z(e, t, n) {
|
|
681
|
+
if (e === "index")
|
|
682
|
+
return {
|
|
683
|
+
pageTitle: n("page.indexTitle"),
|
|
684
|
+
pageDescription: n("page.indexSubtitle", { count: t })
|
|
685
|
+
};
|
|
686
|
+
if (e.kind === "year")
|
|
687
|
+
return {
|
|
688
|
+
pageTitle: n("page.yearTitle", { year: e.year }),
|
|
689
|
+
pageDescription: n("page.yearSubtitle", { count: t, year: e.year })
|
|
690
|
+
};
|
|
691
|
+
if (e.kind === "month") {
|
|
692
|
+
const r = n(`page.months.${e.month}`);
|
|
693
|
+
return {
|
|
694
|
+
pageTitle: n("page.monthTitle", { month: r, year: e.year }),
|
|
695
|
+
pageDescription: n("page.monthSubtitle", {
|
|
696
|
+
count: t,
|
|
697
|
+
month: r,
|
|
698
|
+
year: e.year
|
|
699
|
+
})
|
|
700
|
+
};
|
|
701
|
+
}
|
|
702
|
+
const a = e;
|
|
703
|
+
return a.kind === "week" ? {
|
|
704
|
+
pageTitle: n("page.weekTitle", { week: a.week, year: a.year }),
|
|
705
|
+
pageDescription: n("page.weekSubtitle", {
|
|
706
|
+
count: t,
|
|
707
|
+
week: a.week,
|
|
708
|
+
year: a.year
|
|
709
|
+
})
|
|
710
|
+
} : { pageTitle: n("page.indexTitle"), pageDescription: "" };
|
|
711
|
+
}
|
|
712
|
+
const Q = {
|
|
713
|
+
drillDown: "month",
|
|
714
|
+
includePages: !1,
|
|
715
|
+
addArchivesLinkToHome: !0,
|
|
716
|
+
addArchivesLinkToCategory: !0,
|
|
717
|
+
showCounts: !0
|
|
718
|
+
}, S = "flexweg-archives";
|
|
719
|
+
function ee(e) {
|
|
720
|
+
var n;
|
|
721
|
+
const t = (n = e.pluginConfigs) == null ? void 0 : n[S];
|
|
722
|
+
return { ...Q, ...t ?? {} };
|
|
723
|
+
}
|
|
724
|
+
function te(e) {
|
|
725
|
+
return {
|
|
726
|
+
posts: e.posts,
|
|
727
|
+
pages: e.pages,
|
|
728
|
+
terms: e.terms,
|
|
729
|
+
media: /* @__PURE__ */ new Map(),
|
|
730
|
+
settings: e.settings,
|
|
731
|
+
users: [],
|
|
732
|
+
authorLookup: () => {
|
|
733
|
+
}
|
|
734
|
+
};
|
|
735
|
+
}
|
|
736
|
+
function ne(e, t) {
|
|
737
|
+
const n = e.posts.filter((r) => r.status === "online");
|
|
738
|
+
if (!t.includePages) return n;
|
|
739
|
+
const a = e.pages.filter((r) => r.status === "online");
|
|
740
|
+
return [...n, ...a];
|
|
741
|
+
}
|
|
742
|
+
function Me(e) {
|
|
743
|
+
return e.terms.map((t) => ({ id: t.id, slug: t.slug }));
|
|
744
|
+
}
|
|
745
|
+
function ae(e) {
|
|
746
|
+
const t = fe(e.data.settings.activeThemeId), n = {
|
|
747
|
+
site: e.site,
|
|
748
|
+
pageTitle: e.pageTitle,
|
|
749
|
+
pageDescription: e.pageDescription,
|
|
750
|
+
currentPath: e.currentPath,
|
|
751
|
+
currentLocale: e.currentLocale
|
|
752
|
+
};
|
|
753
|
+
return ye({
|
|
754
|
+
base: t.templates.base,
|
|
755
|
+
baseProps: n,
|
|
756
|
+
template: e.inner,
|
|
757
|
+
templateProps: e.innerProps
|
|
758
|
+
});
|
|
759
|
+
}
|
|
760
|
+
async function Fe(e) {
|
|
761
|
+
const { post: t, ...n } = e, a = ee(n.settings), r = { uploaded: [], deleted: [] };
|
|
762
|
+
for (const { language: i, isPrimary: l } of ie(n)) {
|
|
763
|
+
const c = re(n, i, l);
|
|
764
|
+
if (!c) continue;
|
|
765
|
+
const s = N(i, l ? i : "__primary__"), d = B(i, l ? i : "__primary__"), g = K(i, l ? i : "__primary__"), p = await Ye({
|
|
766
|
+
data: c,
|
|
767
|
+
config: a,
|
|
768
|
+
touchedPost: t,
|
|
769
|
+
root: s,
|
|
770
|
+
indexPath: d,
|
|
771
|
+
indexHref: g,
|
|
772
|
+
currentLocale: l ? void 0 : i
|
|
773
|
+
});
|
|
774
|
+
r.uploaded.push(...p.uploaded), r.deleted.push(...p.deleted);
|
|
775
|
+
}
|
|
776
|
+
return r;
|
|
777
|
+
}
|
|
778
|
+
function Re(e) {
|
|
779
|
+
var r, i;
|
|
780
|
+
if (((r = e.enabledPlugins) == null ? void 0 : r["flexweg-multilang"]) === !1) return null;
|
|
781
|
+
const t = (i = e.pluginConfigs) == null ? void 0 : i["flexweg-multilang"];
|
|
782
|
+
if (!t) return null;
|
|
783
|
+
const n = t.primaryLanguage || (e.language || "en").split("-")[0], a = Array.isArray(t.enabledLanguages) ? t.enabledLanguages : [];
|
|
784
|
+
return a.length === 0 ? null : { primaryLanguage: n, enabledLanguages: a };
|
|
785
|
+
}
|
|
786
|
+
function Oe(e, t) {
|
|
787
|
+
const n = e.translations, a = n == null ? void 0 : n[t];
|
|
788
|
+
return !a || !a.slug || !a.title ? null : a;
|
|
789
|
+
}
|
|
790
|
+
function $e(e, t) {
|
|
791
|
+
const n = e.translations, a = n == null ? void 0 : n[t];
|
|
792
|
+
return !a || !a.slug || !a.name ? null : a;
|
|
793
|
+
}
|
|
794
|
+
function re(e, t, n) {
|
|
795
|
+
if (n)
|
|
796
|
+
return { ...e, settings: { ...e.settings, language: t } };
|
|
797
|
+
const a = `${t}/`, r = e.terms.map((s) => {
|
|
798
|
+
if (s.type !== "category") return s;
|
|
799
|
+
const d = $e(s, t);
|
|
800
|
+
return d ? { ...s, name: d.name, slug: `${a}${d.slug}` } : s;
|
|
801
|
+
}), i = (s) => {
|
|
802
|
+
const d = Oe(s, t);
|
|
803
|
+
if (!d) return null;
|
|
804
|
+
const g = s.type !== "post" || !s.primaryTermId;
|
|
805
|
+
return {
|
|
806
|
+
...s,
|
|
807
|
+
title: d.title,
|
|
808
|
+
slug: g ? `${a}${d.slug}` : d.slug
|
|
809
|
+
};
|
|
810
|
+
}, l = e.posts.map(i).filter((s) => s !== null), c = e.pages.map(i).filter((s) => s !== null);
|
|
811
|
+
return l.length === 0 && c.length === 0 ? null : {
|
|
812
|
+
posts: l,
|
|
813
|
+
pages: c,
|
|
814
|
+
terms: r,
|
|
815
|
+
settings: { ...e.settings, language: t }
|
|
816
|
+
};
|
|
817
|
+
}
|
|
818
|
+
function ie(e) {
|
|
819
|
+
const t = Re(e.settings);
|
|
820
|
+
if (!t) return [{ language: e.settings.language || "en", isPrimary: !0 }];
|
|
821
|
+
const n = [
|
|
822
|
+
{ language: t.primaryLanguage, isPrimary: !0 }
|
|
823
|
+
];
|
|
824
|
+
for (const a of t.enabledLanguages)
|
|
825
|
+
a !== t.primaryLanguage && n.push({ language: a, isPrimary: !1 });
|
|
826
|
+
return n;
|
|
827
|
+
}
|
|
828
|
+
async function oe(e) {
|
|
829
|
+
const t = ee(e.settings), n = { uploaded: [], deleted: [] }, a = ie(e);
|
|
830
|
+
for (const { language: r, isPrimary: i } of a) {
|
|
831
|
+
const l = re(e, r, i);
|
|
832
|
+
if (!l) continue;
|
|
833
|
+
const c = N(r, i ? r : "__primary__"), s = B(r, i ? r : "__primary__"), d = K(r, i ? r : "__primary__");
|
|
834
|
+
await ge(c), n.deleted.push(`${c}/`);
|
|
835
|
+
const g = await We({
|
|
836
|
+
data: l,
|
|
837
|
+
config: t,
|
|
838
|
+
root: c,
|
|
839
|
+
indexPath: s,
|
|
840
|
+
indexHref: d,
|
|
841
|
+
currentLocale: i ? void 0 : r
|
|
842
|
+
});
|
|
843
|
+
n.uploaded.push(...g.uploaded), n.deleted.push(...g.deleted);
|
|
844
|
+
}
|
|
845
|
+
return n;
|
|
846
|
+
}
|
|
847
|
+
async function We(e) {
|
|
848
|
+
const { data: t, config: n, root: a, indexPath: r, indexHref: i, currentLocale: l } = e, c = { uploaded: [], deleted: [] }, s = ne(t, n), d = te(t), g = se(d, l), p = ze(s, n.drillDown), m = [];
|
|
849
|
+
for (const u of p.years) m.push(u);
|
|
850
|
+
for (const u of p.drills) m.push(u);
|
|
851
|
+
for (const u of m) {
|
|
852
|
+
const v = R(u, a), f = ce({
|
|
853
|
+
data: t,
|
|
854
|
+
config: n,
|
|
855
|
+
site: g,
|
|
856
|
+
period: u,
|
|
857
|
+
entities: s,
|
|
858
|
+
root: a,
|
|
859
|
+
indexHref: i,
|
|
860
|
+
currentLocale: l
|
|
861
|
+
});
|
|
862
|
+
await T({ path: v, content: f }), c.uploaded.push(v), await je(75);
|
|
863
|
+
}
|
|
864
|
+
const b = de({
|
|
865
|
+
data: t,
|
|
866
|
+
config: n,
|
|
867
|
+
site: g,
|
|
868
|
+
entities: s,
|
|
869
|
+
root: a,
|
|
870
|
+
indexPath: r,
|
|
871
|
+
currentLocale: l
|
|
872
|
+
});
|
|
873
|
+
return await T({ path: r, content: b }), c.uploaded.push(r), c;
|
|
874
|
+
}
|
|
875
|
+
function se(e, t) {
|
|
876
|
+
const n = me(e);
|
|
877
|
+
return t ? { ...n, homePath: `/${t}/index.html` } : n;
|
|
878
|
+
}
|
|
879
|
+
function R(e, t = y) {
|
|
880
|
+
return e.kind === "year" ? U(e, t) : e.kind === "month" ? q(e, t) : G(e, t);
|
|
881
|
+
}
|
|
882
|
+
function je(e) {
|
|
883
|
+
return new Promise((t) => setTimeout(t, e));
|
|
884
|
+
}
|
|
885
|
+
function ze(e, t) {
|
|
886
|
+
const n = /* @__PURE__ */ new Map(), a = /* @__PURE__ */ new Map();
|
|
887
|
+
for (const l of e) {
|
|
888
|
+
const c = L(l, t);
|
|
889
|
+
c && (n.set(w(c.year), c.year), c.drill && a.set(w(c.drill), c.drill));
|
|
890
|
+
}
|
|
891
|
+
const r = [...n.values()].sort(_), i = [...a.values()].sort(_);
|
|
892
|
+
return { years: r, drills: i };
|
|
893
|
+
}
|
|
894
|
+
function le(e, t, n) {
|
|
895
|
+
return e.filter((a) => {
|
|
896
|
+
var i, l;
|
|
897
|
+
const r = L(a, n);
|
|
898
|
+
return r ? t.kind === "year" ? r.year.year === t.year : t.kind === "month" ? ((i = r.drill) == null ? void 0 : i.kind) === "month" && r.drill.year === t.year && r.drill.month === t.month : ((l = r.drill) == null ? void 0 : l.kind) === "week" && r.drill.year === t.year && r.drill.week === t.week : !1;
|
|
899
|
+
});
|
|
900
|
+
}
|
|
901
|
+
function ce(e) {
|
|
902
|
+
const t = Y.getFixedT(
|
|
903
|
+
J(e.data.settings.language),
|
|
904
|
+
S
|
|
905
|
+
), n = le(e.entities, e.period, e.config.drillDown), a = Z(e.period, n.length, t), r = e.root ?? y;
|
|
906
|
+
return ae({
|
|
907
|
+
data: e.data,
|
|
908
|
+
config: e.config,
|
|
909
|
+
site: e.site,
|
|
910
|
+
inner: Ie,
|
|
911
|
+
innerProps: {
|
|
912
|
+
period: e.period,
|
|
913
|
+
posts: n,
|
|
914
|
+
drillDown: e.config.drillDown,
|
|
915
|
+
showCounts: e.config.showCounts,
|
|
916
|
+
language: e.data.settings.language,
|
|
917
|
+
t,
|
|
918
|
+
terms: Me(e.data),
|
|
919
|
+
root: r,
|
|
920
|
+
indexHref: e.indexHref
|
|
921
|
+
},
|
|
922
|
+
pageTitle: a.pageTitle,
|
|
923
|
+
pageDescription: a.pageDescription,
|
|
924
|
+
currentPath: R(e.period, r),
|
|
925
|
+
currentLocale: e.currentLocale
|
|
926
|
+
});
|
|
927
|
+
}
|
|
928
|
+
function de(e) {
|
|
929
|
+
const t = Y.getFixedT(
|
|
930
|
+
J(e.data.settings.language),
|
|
931
|
+
S
|
|
932
|
+
), n = Z("index", e.entities.length, t);
|
|
933
|
+
return ae({
|
|
934
|
+
data: e.data,
|
|
935
|
+
config: e.config,
|
|
936
|
+
site: e.site,
|
|
937
|
+
inner: He,
|
|
938
|
+
innerProps: {
|
|
939
|
+
posts: e.entities,
|
|
940
|
+
drillDown: e.config.drillDown,
|
|
941
|
+
showCounts: e.config.showCounts,
|
|
942
|
+
t,
|
|
943
|
+
root: e.root ?? y
|
|
944
|
+
},
|
|
945
|
+
pageTitle: n.pageTitle,
|
|
946
|
+
pageDescription: n.pageDescription,
|
|
947
|
+
currentPath: e.indexPath ?? V,
|
|
948
|
+
currentLocale: e.currentLocale
|
|
949
|
+
});
|
|
950
|
+
}
|
|
951
|
+
async function Ye(e) {
|
|
952
|
+
const { data: t, config: n, touchedPost: a, currentLocale: r } = e, i = e.root ?? y, l = e.indexPath ?? V, c = e.indexHref, s = { uploaded: [], deleted: [] }, d = ne(t, n), g = te(t), p = se(g, r), m = L(a, n.drillDown), b = [];
|
|
953
|
+
m && (b.push(m.year), m.drill && b.push(m.drill));
|
|
954
|
+
for (const v of b) {
|
|
955
|
+
const f = le(d, v, n.drillDown), k = R(v, i);
|
|
956
|
+
if (f.length === 0) {
|
|
957
|
+
try {
|
|
958
|
+
await pe(k), s.deleted.push(k);
|
|
959
|
+
} catch {
|
|
960
|
+
}
|
|
961
|
+
continue;
|
|
962
|
+
}
|
|
963
|
+
const A = ce({
|
|
964
|
+
data: t,
|
|
965
|
+
config: n,
|
|
966
|
+
site: p,
|
|
967
|
+
period: v,
|
|
968
|
+
entities: d,
|
|
969
|
+
root: i,
|
|
970
|
+
indexHref: c,
|
|
971
|
+
currentLocale: r
|
|
972
|
+
});
|
|
973
|
+
await T({ path: k, content: A }), s.uploaded.push(k);
|
|
974
|
+
}
|
|
975
|
+
const u = de({
|
|
976
|
+
data: t,
|
|
977
|
+
config: n,
|
|
978
|
+
site: p,
|
|
979
|
+
entities: d,
|
|
980
|
+
root: i,
|
|
981
|
+
indexPath: l,
|
|
982
|
+
currentLocale: r
|
|
983
|
+
});
|
|
984
|
+
return await T({ path: l, content: u }), s.uploaded.push(l), s;
|
|
985
|
+
}
|
|
986
|
+
/**
|
|
987
|
+
* @license lucide-react v0.460.0 - ISC
|
|
988
|
+
*
|
|
989
|
+
* This source code is licensed under the ISC license.
|
|
990
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
991
|
+
*/
|
|
992
|
+
const Je = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), ue = (...e) => e.filter((t, n, a) => !!t && t.trim() !== "" && a.indexOf(t) === n).join(" ").trim();
|
|
993
|
+
/**
|
|
994
|
+
* @license lucide-react v0.460.0 - ISC
|
|
995
|
+
*
|
|
996
|
+
* This source code is licensed under the ISC license.
|
|
997
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
998
|
+
*/
|
|
999
|
+
var Ee = {
|
|
1000
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1001
|
+
width: 24,
|
|
1002
|
+
height: 24,
|
|
1003
|
+
viewBox: "0 0 24 24",
|
|
1004
|
+
fill: "none",
|
|
1005
|
+
stroke: "currentColor",
|
|
1006
|
+
strokeWidth: 2,
|
|
1007
|
+
strokeLinecap: "round",
|
|
1008
|
+
strokeLinejoin: "round"
|
|
1009
|
+
};
|
|
1010
|
+
/**
|
|
1011
|
+
* @license lucide-react v0.460.0 - ISC
|
|
1012
|
+
*
|
|
1013
|
+
* This source code is licensed under the ISC license.
|
|
1014
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1015
|
+
*/
|
|
1016
|
+
const Ve = E(
|
|
1017
|
+
({
|
|
1018
|
+
color: e = "currentColor",
|
|
1019
|
+
size: t = 24,
|
|
1020
|
+
strokeWidth: n = 2,
|
|
1021
|
+
absoluteStrokeWidth: a,
|
|
1022
|
+
className: r = "",
|
|
1023
|
+
children: i,
|
|
1024
|
+
iconNode: l,
|
|
1025
|
+
...c
|
|
1026
|
+
}, s) => M(
|
|
1027
|
+
"svg",
|
|
1028
|
+
{
|
|
1029
|
+
ref: s,
|
|
1030
|
+
...Ee,
|
|
1031
|
+
width: t,
|
|
1032
|
+
height: t,
|
|
1033
|
+
stroke: e,
|
|
1034
|
+
strokeWidth: a ? Number(n) * 24 / Number(t) : n,
|
|
1035
|
+
className: ue("lucide", r),
|
|
1036
|
+
...c
|
|
1037
|
+
},
|
|
1038
|
+
[
|
|
1039
|
+
...l.map(([d, g]) => M(d, g)),
|
|
1040
|
+
...Array.isArray(i) ? i : [i]
|
|
1041
|
+
]
|
|
1042
|
+
)
|
|
1043
|
+
);
|
|
1044
|
+
/**
|
|
1045
|
+
* @license lucide-react v0.460.0 - ISC
|
|
1046
|
+
*
|
|
1047
|
+
* This source code is licensed under the ISC license.
|
|
1048
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1049
|
+
*/
|
|
1050
|
+
const O = (e, t) => {
|
|
1051
|
+
const n = E(
|
|
1052
|
+
({ className: a, ...r }, i) => M(Ve, {
|
|
1053
|
+
ref: i,
|
|
1054
|
+
iconNode: t,
|
|
1055
|
+
className: ue(`lucide-${Je(e)}`, a),
|
|
1056
|
+
...r
|
|
1057
|
+
})
|
|
1058
|
+
);
|
|
1059
|
+
return n.displayName = `${e}`, n;
|
|
1060
|
+
};
|
|
1061
|
+
/**
|
|
1062
|
+
* @license lucide-react v0.460.0 - ISC
|
|
1063
|
+
*
|
|
1064
|
+
* This source code is licensed under the ISC license.
|
|
1065
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1066
|
+
*/
|
|
1067
|
+
const z = O("LoaderCircle", [
|
|
1068
|
+
["path", { d: "M21 12a9 9 0 1 1-6.219-8.56", key: "13zald" }]
|
|
1069
|
+
]);
|
|
1070
|
+
/**
|
|
1071
|
+
* @license lucide-react v0.460.0 - ISC
|
|
1072
|
+
*
|
|
1073
|
+
* This source code is licensed under the ISC license.
|
|
1074
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1075
|
+
*/
|
|
1076
|
+
const Ue = O("RefreshCw", [
|
|
1077
|
+
["path", { d: "M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8", key: "v9h5vc" }],
|
|
1078
|
+
["path", { d: "M21 3v5h-5", key: "1q7to0" }],
|
|
1079
|
+
["path", { d: "M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16", key: "3uifl3" }],
|
|
1080
|
+
["path", { d: "M8 16H3v5", key: "1cv678" }]
|
|
1081
|
+
]);
|
|
1082
|
+
/**
|
|
1083
|
+
* @license lucide-react v0.460.0 - ISC
|
|
1084
|
+
*
|
|
1085
|
+
* This source code is licensed under the ISC license.
|
|
1086
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
1087
|
+
*/
|
|
1088
|
+
const qe = O("Save", [
|
|
1089
|
+
[
|
|
1090
|
+
"path",
|
|
1091
|
+
{
|
|
1092
|
+
d: "M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",
|
|
1093
|
+
key: "1c8476"
|
|
1094
|
+
}
|
|
1095
|
+
],
|
|
1096
|
+
["path", { d: "M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7", key: "1ydtos" }],
|
|
1097
|
+
["path", { d: "M7 3v4a1 1 0 0 0 1 1h7", key: "t51u73" }]
|
|
1098
|
+
]);
|
|
1099
|
+
function Ge({
|
|
1100
|
+
config: e,
|
|
1101
|
+
save: t
|
|
1102
|
+
}) {
|
|
1103
|
+
const { t: n } = ke("flexweg-archives"), { terms: a, settings: r } = ve(), [i, l] = C(e);
|
|
1104
|
+
be(() => l(e), [e]);
|
|
1105
|
+
const [c, s] = C(!1), [d, g] = C(!1);
|
|
1106
|
+
function p(u) {
|
|
1107
|
+
l((v) => ({ ...v, ...u }));
|
|
1108
|
+
}
|
|
1109
|
+
async function m() {
|
|
1110
|
+
s(!0);
|
|
1111
|
+
try {
|
|
1112
|
+
await t(i), P.success(n("settings.saved"));
|
|
1113
|
+
} finally {
|
|
1114
|
+
s(!1);
|
|
1115
|
+
}
|
|
1116
|
+
}
|
|
1117
|
+
async function b() {
|
|
1118
|
+
g(!0);
|
|
1119
|
+
try {
|
|
1120
|
+
await t(i);
|
|
1121
|
+
const [u, v] = await Promise.all([
|
|
1122
|
+
$({ type: "post" }),
|
|
1123
|
+
$({ type: "page" })
|
|
1124
|
+
]), f = await oe({ posts: u, pages: v, terms: a, settings: r });
|
|
1125
|
+
P.success(n("settings.regenerated", { count: f.uploaded.length }));
|
|
1126
|
+
} catch (u) {
|
|
1127
|
+
console.error("[flexweg-archives] regeneration failed:", u), P.error(n("settings.regenerateFailed"));
|
|
1128
|
+
} finally {
|
|
1129
|
+
g(!1);
|
|
1130
|
+
}
|
|
1131
|
+
}
|
|
1132
|
+
return /* @__PURE__ */ h("div", { className: "space-y-4", children: [
|
|
1133
|
+
/* @__PURE__ */ h("section", { className: "card p-4 space-y-4", children: [
|
|
1134
|
+
/* @__PURE__ */ h("header", { className: "space-y-1", children: [
|
|
1135
|
+
/* @__PURE__ */ o("h2", { className: "font-semibold", children: n("title") }),
|
|
1136
|
+
/* @__PURE__ */ o("p", { className: "text-sm text-surface-600 dark:text-surface-300", children: n("description") })
|
|
1137
|
+
] }),
|
|
1138
|
+
/* @__PURE__ */ h("div", { className: "space-y-2", children: [
|
|
1139
|
+
/* @__PURE__ */ o("label", { className: "label", children: n("settings.drillDown") }),
|
|
1140
|
+
/* @__PURE__ */ o("div", { className: "flex flex-col gap-1", children: ["none", "month", "week"].map((u) => /* @__PURE__ */ h("label", { className: "inline-flex items-center gap-2 text-sm", children: [
|
|
1141
|
+
/* @__PURE__ */ o(
|
|
1142
|
+
"input",
|
|
1143
|
+
{
|
|
1144
|
+
type: "radio",
|
|
1145
|
+
name: "drillDown",
|
|
1146
|
+
value: u,
|
|
1147
|
+
checked: i.drillDown === u,
|
|
1148
|
+
onChange: () => p({ drillDown: u })
|
|
1149
|
+
}
|
|
1150
|
+
),
|
|
1151
|
+
/* @__PURE__ */ o("span", { children: n(
|
|
1152
|
+
u === "none" ? "settings.drillDownNone" : u === "month" ? "settings.drillDownMonth" : "settings.drillDownWeek"
|
|
1153
|
+
) })
|
|
1154
|
+
] }, u)) }),
|
|
1155
|
+
/* @__PURE__ */ o("p", { className: "text-xs text-surface-500 dark:text-surface-400", children: n("settings.drillDownHelp") })
|
|
1156
|
+
] }),
|
|
1157
|
+
/* @__PURE__ */ h("div", { children: [
|
|
1158
|
+
/* @__PURE__ */ h("label", { className: "inline-flex items-center gap-2 text-sm", children: [
|
|
1159
|
+
/* @__PURE__ */ o(
|
|
1160
|
+
"input",
|
|
1161
|
+
{
|
|
1162
|
+
type: "checkbox",
|
|
1163
|
+
checked: i.includePages,
|
|
1164
|
+
onChange: (u) => p({ includePages: u.target.checked })
|
|
1165
|
+
}
|
|
1166
|
+
),
|
|
1167
|
+
/* @__PURE__ */ o("span", { children: n("settings.includePages") })
|
|
1168
|
+
] }),
|
|
1169
|
+
/* @__PURE__ */ o("p", { className: "text-xs text-surface-500 mt-1 dark:text-surface-400", children: n("settings.includePagesHelp") })
|
|
1170
|
+
] }),
|
|
1171
|
+
/* @__PURE__ */ o("div", { children: /* @__PURE__ */ h("label", { className: "inline-flex items-center gap-2 text-sm", children: [
|
|
1172
|
+
/* @__PURE__ */ o(
|
|
1173
|
+
"input",
|
|
1174
|
+
{
|
|
1175
|
+
type: "checkbox",
|
|
1176
|
+
checked: i.showCounts,
|
|
1177
|
+
onChange: (u) => p({ showCounts: u.target.checked })
|
|
1178
|
+
}
|
|
1179
|
+
),
|
|
1180
|
+
/* @__PURE__ */ o("span", { children: n("settings.showCounts") })
|
|
1181
|
+
] }) }),
|
|
1182
|
+
/* @__PURE__ */ o("div", { children: /* @__PURE__ */ h("label", { className: "inline-flex items-center gap-2 text-sm", children: [
|
|
1183
|
+
/* @__PURE__ */ o(
|
|
1184
|
+
"input",
|
|
1185
|
+
{
|
|
1186
|
+
type: "checkbox",
|
|
1187
|
+
checked: i.addArchivesLinkToHome,
|
|
1188
|
+
onChange: (u) => p({ addArchivesLinkToHome: u.target.checked })
|
|
1189
|
+
}
|
|
1190
|
+
),
|
|
1191
|
+
/* @__PURE__ */ o("span", { children: n("settings.addArchivesLinkToHome") })
|
|
1192
|
+
] }) }),
|
|
1193
|
+
/* @__PURE__ */ o("div", { children: /* @__PURE__ */ h("label", { className: "inline-flex items-center gap-2 text-sm", children: [
|
|
1194
|
+
/* @__PURE__ */ o(
|
|
1195
|
+
"input",
|
|
1196
|
+
{
|
|
1197
|
+
type: "checkbox",
|
|
1198
|
+
checked: i.addArchivesLinkToCategory,
|
|
1199
|
+
onChange: (u) => p({ addArchivesLinkToCategory: u.target.checked })
|
|
1200
|
+
}
|
|
1201
|
+
),
|
|
1202
|
+
/* @__PURE__ */ o("span", { children: n("settings.addArchivesLinkToCategory") })
|
|
1203
|
+
] }) }),
|
|
1204
|
+
/* @__PURE__ */ o("div", { className: "pt-2", children: /* @__PURE__ */ o(
|
|
1205
|
+
"button",
|
|
1206
|
+
{
|
|
1207
|
+
type: "button",
|
|
1208
|
+
className: "btn-primary",
|
|
1209
|
+
onClick: m,
|
|
1210
|
+
disabled: c,
|
|
1211
|
+
children: /* @__PURE__ */ h("span", { className: "inline-flex items-center justify-center gap-1.5", children: [
|
|
1212
|
+
/* @__PURE__ */ o(z, { className: "h-4 w-4 animate-spin " + (c ? "" : "hidden") }),
|
|
1213
|
+
/* @__PURE__ */ o(qe, { className: "h-4 w-4 " + (c ? "hidden" : "") }),
|
|
1214
|
+
/* @__PURE__ */ o("span", { children: n(c ? "settings.saving" : "settings.save") })
|
|
1215
|
+
] })
|
|
1216
|
+
}
|
|
1217
|
+
) })
|
|
1218
|
+
] }),
|
|
1219
|
+
/* @__PURE__ */ h("section", { className: "card p-4 space-y-3", children: [
|
|
1220
|
+
/* @__PURE__ */ h("header", { children: [
|
|
1221
|
+
/* @__PURE__ */ o("h2", { className: "font-semibold", children: n("settings.forceRegenerate") }),
|
|
1222
|
+
/* @__PURE__ */ o("p", { className: "text-sm text-surface-600 dark:text-surface-300 mt-1", children: n("settings.forceRegenerateHelp") })
|
|
1223
|
+
] }),
|
|
1224
|
+
/* @__PURE__ */ o("div", { children: /* @__PURE__ */ o(
|
|
1225
|
+
"button",
|
|
1226
|
+
{
|
|
1227
|
+
type: "button",
|
|
1228
|
+
className: "btn-secondary",
|
|
1229
|
+
onClick: b,
|
|
1230
|
+
disabled: d,
|
|
1231
|
+
children: /* @__PURE__ */ h("span", { className: "inline-flex items-center justify-center gap-1.5", children: [
|
|
1232
|
+
/* @__PURE__ */ o(z, { className: "h-4 w-4 animate-spin " + (d ? "" : "hidden") }),
|
|
1233
|
+
/* @__PURE__ */ o(Ue, { className: "h-4 w-4 " + (d ? "hidden" : "") }),
|
|
1234
|
+
/* @__PURE__ */ o("span", { children: n(d ? "settings.forceRegenerating" : "settings.forceRegenerate") })
|
|
1235
|
+
] })
|
|
1236
|
+
}
|
|
1237
|
+
) })
|
|
1238
|
+
] })
|
|
1239
|
+
] });
|
|
1240
|
+
}
|
|
1241
|
+
const Be = `# Flexweg Archives
|
|
1242
|
+
|
|
1243
|
+
Static archive pages — a search-engine-friendly, static-hosting-friendly alternative to pagination.
|
|
1244
|
+
|
|
1245
|
+
## What it does
|
|
1246
|
+
|
|
1247
|
+
When enabled, this plugin produces a tree of HTML pages under \`/archives/\` on your public site:
|
|
1248
|
+
|
|
1249
|
+
\`\`\`
|
|
1250
|
+
/archives/ → top-level table of contents
|
|
1251
|
+
/archives/2026/ → all posts published in 2026
|
|
1252
|
+
/archives/2026/01/ (optional) → posts of January 2026
|
|
1253
|
+
/archives/2026/W23/ (optional) → posts of ISO week 23, 2026
|
|
1254
|
+
\`\`\`
|
|
1255
|
+
|
|
1256
|
+
Each page lists post titles + dates, all linking to the live post URL. The pages live in the active theme's \`BaseLayout\`, so header / footer / branding stay consistent with the rest of the site.
|
|
1257
|
+
|
|
1258
|
+
It also injects a **"See full archives →"** link below the home page and category archive listings (toggleable per destination), letting visitors browse older posts without paginating — the entire archive is one click away from any landing page.
|
|
1259
|
+
|
|
1260
|
+
## Why archives, not pagination
|
|
1261
|
+
|
|
1262
|
+
Static hosting (no server, no JS reads) makes pagination expensive: every paginated page must be pre-generated, every link must be a real file, and any post added forces every page after that to shift. Archives are O(1) per write — adding a post touches at most three files (the year page, the optional drill-down page, the index) regardless of how many posts exist on the site.
|
|
1263
|
+
|
|
1264
|
+
## Settings
|
|
1265
|
+
|
|
1266
|
+
Reachable from **Plugins → Configure** or directly at \`/admin/#/settings/plugin/flexweg-archives\`.
|
|
1267
|
+
|
|
1268
|
+
| Setting | Default | Effect |
|
|
1269
|
+
|---|---|---|
|
|
1270
|
+
| Drill-down | \`Year → month\` | Sub-grouping inside each year. Years are always the top level. Pick \`none\` for one big year-list page, \`month\` for \`/archives/2026/01/\` sub-pages, or \`week\` for \`/archives/2026/W23/\` sub-pages. |
|
|
1271
|
+
| Include static pages | Off | When on, static pages (type \`page\`) appear in the archives alongside posts. Most sites keep this off — pages are rarely chronological. |
|
|
1272
|
+
| Show counts | On | Whether to append \`(N)\` to each period entry in the index. |
|
|
1273
|
+
| Show "See full archives" on home | On | Renders a footer link below the home page listing. Hidden when no posts exist yet. |
|
|
1274
|
+
| Show "See full archives" on category | On | Same, on category archive pages. |
|
|
1275
|
+
|
|
1276
|
+
There's also a **Force regenerate** button that wipes \`/archives/\` on Flexweg and rebuilds every file from scratch using the currently-online post set. Use it after switching drill-down (so old \`/2025/01/\` pages stop existing if you switched to weekly) or after a bulk import.
|
|
1277
|
+
|
|
1278
|
+
## How regeneration works
|
|
1279
|
+
|
|
1280
|
+
The plugin subscribes to three lifecycle hooks: \`publish.complete\`, \`post.unpublished\`, \`post.deleted\`. On every event:
|
|
1281
|
+
|
|
1282
|
+
1. It computes the periods the touched post belongs to (year + drill-down).
|
|
1283
|
+
2. For each, it re-renders the corresponding archive page if any post still belongs there, or **deletes** the file if the period just emptied out.
|
|
1284
|
+
3. It always re-renders \`/archives/index.html\` to keep the counts and period list honest.
|
|
1285
|
+
|
|
1286
|
+
So changing a post's status or deleting it never leaves a dangling reference, and never regenerates files that didn't change.
|
|
1287
|
+
|
|
1288
|
+
## URL strategy
|
|
1289
|
+
|
|
1290
|
+
| Period | Path | Example |
|
|
1291
|
+
|---|---|---|
|
|
1292
|
+
| Index | \`/archives/\` | \`/archives/\` |
|
|
1293
|
+
| Year | \`/archives/<YYYY>/\` | \`/archives/2026/\` |
|
|
1294
|
+
| Month | \`/archives/<YYYY>/<MM>/\` | \`/archives/2026/01/\` |
|
|
1295
|
+
| Week | \`/archives/<YYYY>/W<NN>/\` | \`/archives/2026/W23/\` |
|
|
1296
|
+
|
|
1297
|
+
ISO 8601 weeks are used for the week drill-down, so dates near year boundaries (e.g. Dec 31 2024 → ISO 2025-W01) land in the correct week. The year shown for a week page is the **ISO week-numbering year**, not the calendar year of the underlying date.
|
|
1298
|
+
|
|
1299
|
+
## Date used to bucket a post
|
|
1300
|
+
|
|
1301
|
+
\`publishedAt\` is the source of truth. When missing (rare — predates the field, or the post was online before \`publishedAt\` was tracked), the plugin falls back to \`updatedAt\`, then \`createdAt\`. The same chain RSS and sitemaps use, so a post lands in the same period across all three plugins.
|
|
1302
|
+
|
|
1303
|
+
## Customising the look
|
|
1304
|
+
|
|
1305
|
+
The plugin renders archive HTML wrapped in the active theme's \`BaseLayout\`, with the inner content using these BEM-style classes:
|
|
1306
|
+
|
|
1307
|
+
\`\`\`
|
|
1308
|
+
.archives wrapper
|
|
1309
|
+
.archives__header page heading + subtitle
|
|
1310
|
+
.archives__title
|
|
1311
|
+
.archives__subtitle
|
|
1312
|
+
.archives__back "← All archives" / "← <year>" link
|
|
1313
|
+
.archives__empty empty-state message
|
|
1314
|
+
|
|
1315
|
+
.archives__years <ul> of years on the index
|
|
1316
|
+
.archives__year one year on the index
|
|
1317
|
+
.archives__year-heading
|
|
1318
|
+
.archives__year-link
|
|
1319
|
+
.archives__drilldown <ul> of months/weeks under a year (drill-down on)
|
|
1320
|
+
.archives__drilldown-item
|
|
1321
|
+
.archives__drilldown-link
|
|
1322
|
+
.archives__count "(12)" after period names
|
|
1323
|
+
|
|
1324
|
+
.archives__list <ul> of posts on a period page
|
|
1325
|
+
.archives__item single post entry
|
|
1326
|
+
.archives__item-link
|
|
1327
|
+
.archives__item-date
|
|
1328
|
+
|
|
1329
|
+
.archives__groups year page split by month/week (drill-down on)
|
|
1330
|
+
.archives__group
|
|
1331
|
+
.archives__group-heading
|
|
1332
|
+
.archives__group-link
|
|
1333
|
+
|
|
1334
|
+
.archives-link the "See full archives →" link inserted on home/cat
|
|
1335
|
+
\`\`\`
|
|
1336
|
+
|
|
1337
|
+
The default theme ships baseline styles in \`themes/default/theme.scss\` (under \`// Archives plugin styles\`). Custom themes override or replace as needed — the markup stays the same, only CSS changes.
|
|
1338
|
+
|
|
1339
|
+
## Translations
|
|
1340
|
+
|
|
1341
|
+
Bundled translations cover all seven admin locales (\`en\`, \`fr\`, \`de\`, \`es\`, \`nl\`, \`pt\`, \`ko\`). The settings page is rendered in the admin's locale (via \`useTranslation("flexweg-archives")\`); the public-facing strings (page titles, "See full archives →", month names) are baked into HTML at publish time, resolved against the **public site language** (\`settings.language\`) via prefix match — so a site with \`language: "fr-CA"\` gets French archives pages.
|
|
1342
|
+
|
|
1343
|
+
For a locale outside the supported set, the plugin falls back to English on the public side. The \`<html lang>\` attribute keeps the original BCP-47 tag intact.
|
|
1344
|
+
|
|
1345
|
+
## Overriding the markup
|
|
1346
|
+
|
|
1347
|
+
The current implementation does not expose the archive templates as a hook surface — if you want a fundamentally different layout (e.g. a calendar grid instead of a list), the practical path is to fork \`src/plugins/flexweg-archives/render.tsx\` in your project. The data shape (\`ArchivePeriod\`, \`Post[]\`, \`t\` function for translations) is stable enough to swap the inner JSX without touching the generator.
|
|
1348
|
+
|
|
1349
|
+
## Disabling the plugin
|
|
1350
|
+
|
|
1351
|
+
Toggling the plugin off in **Plugins** stops:
|
|
1352
|
+
|
|
1353
|
+
- The lifecycle hooks (existing archive files stay where they are — they just no longer auto-update).
|
|
1354
|
+
- The \`addArchivesLinkToHome\` / \`addArchivesLinkToCategory\` link injection on the next home / category re-publish.
|
|
1355
|
+
|
|
1356
|
+
To clean up the stale archive files after disabling, click **Force regenerate** once **before** disabling (it'll wipe and rebuild — leaving an up-to-date snapshot), or manually delete the \`/archives/\` folder on Flexweg via the dashboard.
|
|
1357
|
+
`;
|
|
1358
|
+
async function I(e, t) {
|
|
1359
|
+
try {
|
|
1360
|
+
await Fe({
|
|
1361
|
+
post: e,
|
|
1362
|
+
posts: t.posts,
|
|
1363
|
+
pages: t.pages,
|
|
1364
|
+
terms: t.terms,
|
|
1365
|
+
settings: t.settings
|
|
1366
|
+
});
|
|
1367
|
+
} catch (n) {
|
|
1368
|
+
console.error("[flexweg-archives] regeneration failed:", n);
|
|
1369
|
+
}
|
|
1370
|
+
}
|
|
1371
|
+
const et = {
|
|
1372
|
+
id: S,
|
|
1373
|
+
name: "Flexweg Archives",
|
|
1374
|
+
version: "1.0.0",
|
|
1375
|
+
author: "Flexweg",
|
|
1376
|
+
description: "Generates static archive pages grouped by year (and optionally month or ISO week) and adds a 'See full archives' link to home / category listings — a static-friendly alternative to pagination.",
|
|
1377
|
+
readme: Be,
|
|
1378
|
+
i18n: { en: we, fr: _e, de: Se, es: Ae, nl: Te, pt: xe, ko: De },
|
|
1379
|
+
settings: {
|
|
1380
|
+
navLabelKey: "title",
|
|
1381
|
+
defaultConfig: Q,
|
|
1382
|
+
component: Ge
|
|
1383
|
+
},
|
|
1384
|
+
register(e) {
|
|
1385
|
+
e.addAction("publish.complete", async (t, n) => {
|
|
1386
|
+
await I(t, n);
|
|
1387
|
+
}), e.addAction("post.unpublished", async (t, n) => {
|
|
1388
|
+
await I(t, n);
|
|
1389
|
+
}), e.addAction("post.deleted", async (t, n) => {
|
|
1390
|
+
await I(t, n);
|
|
1391
|
+
}), e.registerRegenerationTarget({
|
|
1392
|
+
id: S,
|
|
1393
|
+
labelKey: "regenerationTarget.label",
|
|
1394
|
+
descriptionKey: "regenerationTarget.description",
|
|
1395
|
+
priority: 230,
|
|
1396
|
+
run: async (t, n) => {
|
|
1397
|
+
n({ level: "info", message: "Regenerating archive pages…" });
|
|
1398
|
+
const a = await oe({
|
|
1399
|
+
posts: t.posts,
|
|
1400
|
+
pages: t.pages,
|
|
1401
|
+
terms: t.terms,
|
|
1402
|
+
settings: t.settings
|
|
1403
|
+
});
|
|
1404
|
+
n({
|
|
1405
|
+
level: "success",
|
|
1406
|
+
message: `Archives: ${a.uploaded.length} uploaded, ${a.deleted.length} removed.`
|
|
1407
|
+
});
|
|
1408
|
+
}
|
|
1409
|
+
});
|
|
1410
|
+
}
|
|
1411
|
+
};
|
|
1412
|
+
export {
|
|
1413
|
+
et as manifest
|
|
1414
|
+
};
|