@geekron/hono 0.1.0 → 0.1.2

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.
Files changed (180) hide show
  1. package/dist/contract.d.ts +9 -1
  2. package/dist/contract.d.ts.map +1 -1
  3. package/dist/contract.js +14 -3
  4. package/dist/core/api/common.d.ts +2 -0
  5. package/dist/core/api/common.d.ts.map +1 -0
  6. package/dist/core/api/common.js +38 -0
  7. package/dist/core/api/inquiries.d.ts +2 -0
  8. package/dist/core/api/inquiries.d.ts.map +1 -0
  9. package/dist/core/api/inquiries.js +116 -0
  10. package/dist/core/api/inquiry.d.ts +2 -0
  11. package/dist/core/api/inquiry.d.ts.map +1 -0
  12. package/dist/core/api/inquiry.js +33 -0
  13. package/dist/core/api/visitor.d.ts +2 -0
  14. package/dist/core/api/visitor.d.ts.map +1 -0
  15. package/dist/core/api/visitor.js +152 -0
  16. package/dist/core/components/InquiryEmailTemplate.d.ts +30 -0
  17. package/dist/core/components/InquiryEmailTemplate.d.ts.map +1 -0
  18. package/dist/core/components/InquiryEmailTemplate.js +13 -0
  19. package/dist/core/components/Seo.d.ts +97 -0
  20. package/dist/core/components/Seo.d.ts.map +1 -0
  21. package/dist/core/components/Seo.js +365 -0
  22. package/dist/core/components/index.d.ts +3 -0
  23. package/dist/core/components/index.d.ts.map +1 -0
  24. package/dist/core/components/index.js +2 -0
  25. package/dist/core/index.d.ts +4 -0
  26. package/dist/core/index.d.ts.map +1 -0
  27. package/dist/core/index.js +3 -0
  28. package/dist/core/lib/constants/inquiry.d.ts +52 -0
  29. package/dist/core/lib/constants/inquiry.d.ts.map +1 -0
  30. package/dist/core/lib/constants/inquiry.js +51 -0
  31. package/dist/core/lib/constants/visitor.d.ts +29 -0
  32. package/dist/core/lib/constants/visitor.d.ts.map +1 -0
  33. package/dist/core/lib/constants/visitor.js +28 -0
  34. package/dist/core/lib/database/constants/database.d.ts +15 -0
  35. package/dist/core/lib/database/constants/database.d.ts.map +1 -0
  36. package/dist/core/lib/database/constants/database.js +14 -0
  37. package/dist/core/lib/database/database.service.d.ts +63 -0
  38. package/dist/core/lib/database/database.service.d.ts.map +1 -0
  39. package/dist/core/lib/database/database.service.js +108 -0
  40. package/dist/core/lib/database/index.d.ts +8 -0
  41. package/dist/core/lib/database/index.d.ts.map +1 -0
  42. package/dist/core/lib/database/index.js +7 -0
  43. package/dist/core/lib/database/managers/sqlite.d.ts +29 -0
  44. package/dist/core/lib/database/managers/sqlite.d.ts.map +1 -0
  45. package/dist/core/lib/database/managers/sqlite.js +55 -0
  46. package/dist/core/lib/database/managers/visitor-shard.d.ts +29 -0
  47. package/dist/core/lib/database/managers/visitor-shard.d.ts.map +1 -0
  48. package/dist/core/lib/database/managers/visitor-shard.js +83 -0
  49. package/dist/core/lib/database/repositories/inquiry.repository.d.ts +33 -0
  50. package/dist/core/lib/database/repositories/inquiry.repository.d.ts.map +1 -0
  51. package/dist/core/lib/database/repositories/inquiry.repository.js +173 -0
  52. package/dist/core/lib/database/repositories/visitor.repository.d.ts +51 -0
  53. package/dist/core/lib/database/repositories/visitor.repository.d.ts.map +1 -0
  54. package/dist/core/lib/database/repositories/visitor.repository.js +559 -0
  55. package/dist/core/lib/database/schemas/inquiry.schema.d.ts +323 -0
  56. package/dist/core/lib/database/schemas/inquiry.schema.d.ts.map +1 -0
  57. package/dist/core/lib/database/schemas/inquiry.schema.js +52 -0
  58. package/dist/core/lib/database/schemas/visitor.schema.d.ts +623 -0
  59. package/dist/core/lib/database/schemas/visitor.schema.d.ts.map +1 -0
  60. package/dist/core/lib/database/schemas/visitor.schema.js +162 -0
  61. package/dist/core/lib/services/captcha.service.d.ts +13 -0
  62. package/dist/core/lib/services/captcha.service.d.ts.map +1 -0
  63. package/dist/core/lib/services/captcha.service.js +40 -0
  64. package/dist/core/lib/services/geoip.service.d.ts +79 -0
  65. package/dist/core/lib/services/geoip.service.d.ts.map +1 -0
  66. package/dist/core/lib/services/geoip.service.js +144 -0
  67. package/dist/core/lib/services/index.d.ts +9 -0
  68. package/dist/core/lib/services/index.d.ts.map +1 -0
  69. package/dist/core/lib/services/index.js +8 -0
  70. package/dist/core/lib/services/inquiry.service.d.ts +56 -0
  71. package/dist/core/lib/services/inquiry.service.d.ts.map +1 -0
  72. package/dist/core/lib/services/inquiry.service.js +129 -0
  73. package/dist/core/lib/services/mailer.service.d.ts +23 -0
  74. package/dist/core/lib/services/mailer.service.d.ts.map +1 -0
  75. package/dist/core/lib/services/mailer.service.js +96 -0
  76. package/dist/core/lib/types/inquiry.d.ts +95 -0
  77. package/dist/core/lib/types/inquiry.d.ts.map +1 -0
  78. package/dist/core/lib/types/inquiry.js +1 -0
  79. package/dist/core/lib/types/visitor.d.ts +135 -0
  80. package/dist/core/lib/types/visitor.d.ts.map +1 -0
  81. package/dist/core/lib/types/visitor.js +1 -0
  82. package/dist/core/lib/utils/api.d.ts +25 -0
  83. package/dist/core/lib/utils/api.d.ts.map +1 -0
  84. package/dist/core/lib/utils/api.js +48 -0
  85. package/dist/core/lib/utils/request.d.ts +18 -0
  86. package/dist/core/lib/utils/request.d.ts.map +1 -0
  87. package/dist/core/lib/utils/request.js +25 -0
  88. package/dist/core/middlewares/api-guard.d.ts +39 -0
  89. package/dist/core/middlewares/api-guard.d.ts.map +1 -0
  90. package/dist/core/middlewares/api-guard.js +154 -0
  91. package/dist/core/middlewares/html-minifier.d.ts +55 -0
  92. package/dist/core/middlewares/html-minifier.d.ts.map +1 -0
  93. package/dist/core/middlewares/html-minifier.js +140 -0
  94. package/dist/core/middlewares/index.d.ts +5 -0
  95. package/dist/core/middlewares/index.d.ts.map +1 -0
  96. package/dist/core/middlewares/index.js +4 -0
  97. package/dist/core/middlewares/initializer.d.ts +11 -0
  98. package/dist/core/middlewares/initializer.d.ts.map +1 -0
  99. package/dist/core/middlewares/initializer.js +13 -0
  100. package/dist/core/middlewares/visitor-tracker.d.ts +85 -0
  101. package/dist/core/middlewares/visitor-tracker.d.ts.map +1 -0
  102. package/dist/core/middlewares/visitor-tracker.js +253 -0
  103. package/dist/core/template.d.ts +4 -0
  104. package/dist/core/template.d.ts.map +1 -0
  105. package/dist/core/template.js +7 -0
  106. package/dist/core/utils/formatDate.d.ts +3 -0
  107. package/dist/core/utils/formatDate.d.ts.map +1 -0
  108. package/dist/core/utils/formatDate.js +2 -0
  109. package/dist/core/utils/fullUrl.d.ts +2 -0
  110. package/dist/core/utils/fullUrl.d.ts.map +1 -0
  111. package/dist/core/utils/fullUrl.js +9 -0
  112. package/dist/core/utils/index.d.ts +6 -0
  113. package/dist/core/utils/index.d.ts.map +1 -0
  114. package/dist/core/utils/index.js +5 -0
  115. package/dist/core/utils/markdownify.d.ts +2 -0
  116. package/dist/core/utils/markdownify.d.ts.map +1 -0
  117. package/dist/core/utils/markdownify.js +4 -0
  118. package/dist/core/utils/params.d.ts +5 -0
  119. package/dist/core/utils/params.d.ts.map +1 -0
  120. package/dist/core/utils/params.js +14 -0
  121. package/dist/core/utils/routeUrl.d.ts +20 -0
  122. package/dist/core/utils/routeUrl.d.ts.map +1 -0
  123. package/dist/core/utils/routeUrl.js +111 -0
  124. package/dist/route/methods.d.ts +15 -0
  125. package/dist/route/methods.d.ts.map +1 -1
  126. package/dist/route/methods.js +45 -18
  127. package/dist/route/setup.d.ts +11 -12
  128. package/dist/route/setup.d.ts.map +1 -1
  129. package/dist/route/setup.js +26 -16
  130. package/dist/strapi/api/site.d.ts +2 -0
  131. package/dist/strapi/api/site.d.ts.map +1 -0
  132. package/dist/strapi/api/site.js +153 -0
  133. package/dist/strapi/cms/cms.js +1 -1
  134. package/dist/strapi/cms/common.d.ts.map +1 -1
  135. package/dist/strapi/cms/common.js +3 -1
  136. package/dist/strapi/cms/menu.d.ts +0 -9
  137. package/dist/strapi/cms/menu.d.ts.map +1 -1
  138. package/dist/strapi/cms/menu.js +3 -62
  139. package/dist/strapi/cms/setup.d.ts +2 -1
  140. package/dist/strapi/cms/setup.d.ts.map +1 -1
  141. package/dist/strapi/cms/setup.js +5 -0
  142. package/dist/strapi/cms/site.d.ts.map +1 -1
  143. package/dist/strapi/cms/site.js +3 -1
  144. package/dist/strapi/cms/translations.d.ts.map +1 -1
  145. package/dist/strapi/cms/translations.js +6 -2
  146. package/dist/strapi/i18n.d.ts +3 -0
  147. package/dist/strapi/i18n.d.ts.map +1 -0
  148. package/dist/strapi/i18n.js +27 -0
  149. package/dist/strapi/index.d.ts +1 -0
  150. package/dist/strapi/index.d.ts.map +1 -1
  151. package/dist/strapi/index.js +1 -0
  152. package/dist/strapi/interfaces/index.d.ts +1 -0
  153. package/dist/strapi/interfaces/index.d.ts.map +1 -1
  154. package/dist/strapi/interfaces/index.js +1 -0
  155. package/dist/strapi/interfaces/sitemap.d.ts +19 -0
  156. package/dist/strapi/interfaces/sitemap.d.ts.map +1 -0
  157. package/dist/strapi/interfaces/sitemap.js +1 -0
  158. package/dist/strapi/pages/sitemap/index.d.ts +2 -0
  159. package/dist/strapi/pages/sitemap/index.d.ts.map +1 -0
  160. package/dist/strapi/pages/sitemap/index.js +50 -0
  161. package/dist/strapi/pages/sitemap/index.xml +11 -0
  162. package/dist/strapi/pages/sitemap/list.d.ts +2 -0
  163. package/dist/strapi/pages/sitemap/list.d.ts.map +1 -0
  164. package/dist/strapi/pages/sitemap/list.js +123 -0
  165. package/dist/strapi/pages/sitemap/list.xml +28 -0
  166. package/dist/strapi/pages/sitemap/robots.d.ts +2 -0
  167. package/dist/strapi/pages/sitemap/robots.d.ts.map +1 -0
  168. package/dist/strapi/pages/sitemap/robots.js +19 -0
  169. package/dist/strapi/pages/sitemap/robots.txt +7 -0
  170. package/dist/strapi/pages/sitemap/style.d.ts +2 -0
  171. package/dist/strapi/pages/sitemap/style.d.ts.map +1 -0
  172. package/dist/strapi/pages/sitemap/style.js +17 -0
  173. package/dist/strapi/pages/sitemap/style.xsl +602 -0
  174. package/dist/strapi/utils/index.d.ts +1 -0
  175. package/dist/strapi/utils/index.d.ts.map +1 -1
  176. package/dist/strapi/utils/index.js +1 -0
  177. package/dist/strapi/utils/trans.d.ts +5 -0
  178. package/dist/strapi/utils/trans.d.ts.map +1 -0
  179. package/dist/strapi/utils/trans.js +7 -0
  180. package/package.json +20 -2
@@ -0,0 +1,602 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <xsl:stylesheet
3
+ version="2.0"
4
+ xmlns:html="http://www.w3.org/TR/REC-html40"
5
+ xmlns:image="http://www.google.com/schemas/sitemap-image/1.1"
6
+ xmlns:sitemap="http://www.sitemaps.org/schemas/sitemap/0.9"
7
+ xmlns:kml="http://www.opengis.net/kml/2.2"
8
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
9
+ xmlns:atom="http://www.w3.org/2005/Atom"
10
+ xmlns:xhtml="http://www.w3.org/1999/xhtml"
11
+ >
12
+ <xsl:output method="html" version="1.0" encoding="UTF-8" indent="yes" />
13
+ <xsl:template match="/">
14
+ <html xmlns="http://www.w3.org/1999/xhtml">
15
+ <head>
16
+ <xsl:choose>
17
+ <xsl:when test="kml:kml">
18
+ <title>Locations Sitemap - {{siteTitle}}</title>
19
+ </xsl:when>
20
+ <xsl:otherwise>
21
+ <title>XML Sitemap - {{siteTitle}}</title>
22
+ </xsl:otherwise>
23
+ </xsl:choose>
24
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
25
+ <style type="text/css">
26
+ :root {
27
+ --bg: #f8fafc;
28
+ --text: #1e293b;
29
+ --muted: #64748b;
30
+ --border: #e2e8f0;
31
+ --card: #ffffff;
32
+ --accent: #3b82f6;
33
+ --accent-2: #2563eb;
34
+ --accent-light: #dbeafe;
35
+ --accent-contrast: #ffffff;
36
+ --row: #f8fafc;
37
+ --row-hover: #f1f5f9;
38
+ --success: #10b981;
39
+ --warning: #f59e0b;
40
+ --info: #06b6d4;
41
+ --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
42
+ --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
43
+ --radius: 8px;
44
+ --radius-lg: 12px;
45
+ }
46
+
47
+ @media (prefers-color-scheme: dark) {
48
+ :root {
49
+ --bg: #0f172a;
50
+ --text: #f1f5f9;
51
+ --muted: #94a3b8;
52
+ --border: #1e293b;
53
+ --card: #1e293b;
54
+ --accent: #60a5fa;
55
+ --accent-2: #3b82f6;
56
+ --accent-light: #1e3a8a;
57
+ --accent-contrast: #ffffff;
58
+ --row: #121e30;
59
+ --row-hover: #334155;
60
+ --success: #34d399;
61
+ --warning: #fbbf24;
62
+ --info: #22d3ee;
63
+ --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.3), 0 1px 2px -1px rgba(0, 0, 0, 0.3);
64
+ --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -4px rgba(0, 0, 0, 0.4);
65
+ }
66
+ }
67
+
68
+ html,
69
+ body {
70
+ background: var(--bg);
71
+ }
72
+
73
+ body {
74
+ font-size: 15px;
75
+ line-height: 1.6;
76
+ font-family:
77
+ -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
78
+ Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
79
+ margin: 0;
80
+ color: var(--text);
81
+ min-height: 100vh;
82
+ }
83
+
84
+ a {
85
+ color: var(--accent);
86
+ text-decoration: none;
87
+ transition: color 160ms ease, opacity 160ms ease;
88
+ }
89
+ a:hover {
90
+ color: var(--accent-2);
91
+ opacity: 0.95;
92
+ }
93
+
94
+ h1 {
95
+ font-size: 32px;
96
+ font-weight: 700;
97
+ margin: 0;
98
+ letter-spacing: -0.02em;
99
+ }
100
+
101
+ .badge {
102
+ display: inline-flex;
103
+ align-items: center;
104
+ padding: 4px 10px;
105
+ border-radius: 6px;
106
+ font-size: 12px;
107
+ font-weight: 600;
108
+ text-transform: uppercase;
109
+ letter-spacing: 0.05em;
110
+ }
111
+
112
+ .badge-success {
113
+ background: rgba(16, 185, 129, 0.1);
114
+ color: var(--success);
115
+ }
116
+
117
+ .badge-info {
118
+ background: rgba(59, 130, 246, 0.1);
119
+ color: var(--accent);
120
+ }
121
+
122
+ .badge-warning {
123
+ background: rgba(245, 158, 11, 0.1);
124
+ color: var(--warning);
125
+ }
126
+
127
+ /* Header description */
128
+ #description {
129
+ background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
130
+ color: var(--accent-contrast);
131
+ padding: 48px 40px;
132
+ position: relative;
133
+ overflow: hidden;
134
+ }
135
+ #description::before {
136
+ content: '';
137
+ position: absolute;
138
+ top: 0;
139
+ left: 0;
140
+ right: 0;
141
+ bottom: 0;
142
+ background: radial-gradient(circle at top right, rgba(255, 255, 255, 0.1) 0%, transparent 60%);
143
+ pointer-events: none;
144
+ }
145
+ #description > * {
146
+ position: relative;
147
+ z-index: 1;
148
+ }
149
+ #description h1,
150
+ #description p,
151
+ #description a {
152
+ color: var(--accent-contrast);
153
+ margin: 0;
154
+ }
155
+ #description h1 {
156
+ font-size: 2.25rem;
157
+ margin-bottom: 12px;
158
+ font-weight: 700;
159
+ letter-spacing: -0.02em;
160
+ }
161
+ #description p {
162
+ margin-top: 8px;
163
+ opacity: 0.95;
164
+ font-size: 1.05em;
165
+ line-height: 1.7;
166
+ }
167
+ #description a {
168
+ border-bottom: 1px solid rgba(255, 255, 255, 0.4);
169
+ transition: border-color 0.2s ease;
170
+ }
171
+ #description a:hover {
172
+ border-bottom-color: rgba(255, 255, 255, 0.8);
173
+ }
174
+
175
+ /* Container */
176
+ #content {
177
+ padding: 32px 40px 48px;
178
+ background: var(--bg);
179
+ max-width: 1200px;
180
+ margin: 0 auto;
181
+ }
182
+
183
+ /* Table */
184
+ table {
185
+ width: 100%;
186
+ border-collapse: separate;
187
+ border-spacing: 0;
188
+ font-size: 0.94em;
189
+ background: var(--card);
190
+ border: 1px solid var(--border);
191
+ border-radius: var(--radius-lg);
192
+ box-shadow: var(--shadow-lg);
193
+ overflow: hidden;
194
+ margin-top: 20px;
195
+ }
196
+
197
+ thead th {
198
+ position: sticky;
199
+ top: 0;
200
+ background: linear-gradient(180deg, var(--accent) 0%, var(--accent-2) 100%);
201
+ color: var(--accent-contrast);
202
+ text-align: left;
203
+ padding: 16px 14px;
204
+ font-size: 12px;
205
+ font-weight: 700;
206
+ text-transform: uppercase;
207
+ letter-spacing: 0.06em;
208
+ white-space: nowrap;
209
+ z-index: 10;
210
+ }
211
+
212
+ tbody td {
213
+ padding: 14px 14px;
214
+ border-bottom: 1px solid var(--border);
215
+ vertical-align: middle;
216
+ transition: background-color 0.15s ease;
217
+ }
218
+
219
+ tbody tr:last-child td {
220
+ border-bottom: none;
221
+ }
222
+
223
+ tbody tr:hover {
224
+ background-color: var(--row-hover);
225
+ }
226
+
227
+ table td a {
228
+ display: inline-block;
229
+ color: var(--accent);
230
+ font-weight: 500;
231
+ word-break: break-all;
232
+ }
233
+
234
+ table td a img {
235
+ max-height: 28px;
236
+ margin: 6px 3px;
237
+ }
238
+
239
+ .expl {
240
+ color: var(--muted);
241
+ margin-bottom: 16px;
242
+ font-size: 0.95em;
243
+ line-height: 1.6;
244
+ }
245
+
246
+ .expl strong {
247
+ color: var(--accent);
248
+ font-weight: 600;
249
+ }
250
+
251
+ .stats-card {
252
+ background: var(--card);
253
+ border: 1px solid var(--border);
254
+ border-radius: var(--radius);
255
+ padding: 16px 20px;
256
+ margin-bottom: 20px;
257
+ display: flex;
258
+ align-items: center;
259
+ gap: 12px;
260
+ box-shadow: var(--shadow);
261
+ }
262
+
263
+ .stats-card .icon {
264
+ font-size: 24px;
265
+ opacity: 0.8;
266
+ }
267
+
268
+ .back-link {
269
+ display: inline-flex;
270
+ align-items: center;
271
+ gap: 6px;
272
+ padding: 8px 16px;
273
+ background: var(--card);
274
+ border: 1px solid var(--border);
275
+ border-radius: var(--radius);
276
+ color: var(--accent);
277
+ font-weight: 500;
278
+ transition: all 0.2s ease;
279
+ text-decoration: none;
280
+ margin-bottom: 20px;
281
+ }
282
+
283
+ .back-link:hover {
284
+ background: var(--accent-light);
285
+ border-color: var(--accent);
286
+ transform: translateX(-2px);
287
+ }
288
+
289
+ /* Responsive tweaks */
290
+ @media (max-width: 1024px) {
291
+ #content {
292
+ padding: 24px 20px 32px;
293
+ }
294
+ }
295
+
296
+ @media (max-width: 768px) {
297
+ #description {
298
+ padding: 32px 24px;
299
+ }
300
+ #description h1 {
301
+ font-size: 1.75rem;
302
+ }
303
+ #content {
304
+ padding: 20px 16px 32px;
305
+ }
306
+ h1 {
307
+ font-size: 24px;
308
+ }
309
+ thead th {
310
+ font-size: 11px;
311
+ padding: 12px 8px;
312
+ }
313
+ tbody td {
314
+ padding: 12px 8px;
315
+ }
316
+ table {
317
+ font-size: 0.88em;
318
+ }
319
+ .stats-card {
320
+ padding: 12px 16px;
321
+ }
322
+ }
323
+ </style>
324
+ </head>
325
+ <body>
326
+ <xsl:choose>
327
+ <xsl:when test="kml:kml">
328
+ <div id="description">
329
+ <h1>KML File</h1>
330
+
331
+ <p>
332
+ This KML File is generated by
333
+ <a href="https://www.geekron.com" target="_blank">Geekron</a>. It is
334
+ used to provide location information to Google.
335
+ </p>
336
+
337
+ <p>
338
+ Learn more about
339
+ <a href="https://developers.google.com/kml/documentation/" target="_blank">KML File</a>.
340
+ </p>
341
+ </div>
342
+
343
+ <div id="content">
344
+ <p class="expl">
345
+ This KML file contains
346
+ <xsl:value-of select="count(kml:kml/kml:Document/kml:Folder/kml:Placemark)" />
347
+ Locations.
348
+ </p>
349
+ <a href="{{sitemapIndexUrl}}" class="back-link">
350
+ <span>←</span> Back to Sitemap Index
351
+ </a>
352
+ <table id="sitemap" cellpadding="3">
353
+ <thead>
354
+ <tr>
355
+ <th width="25%">Name</th>
356
+ <th width="40%">Address</th>
357
+ <th width="15%">Phone number</th>
358
+ <th width="10%">Latitude</th>
359
+ <th width="10%">Longitude</th>
360
+ </tr>
361
+ </thead>
362
+ <tbody>
363
+ <xsl:variable
364
+ name="lower"
365
+ select="'abcdefghijklmnopqrstuvwxyz'"
366
+ />
367
+ <xsl:variable
368
+ name="upper"
369
+ select="'ABCDEFGHIJKLMNOPQRSTUVWXYZ'"
370
+ />
371
+ <xsl:for-each select="kml:kml/kml:Document/kml:Folder/kml:Placemark">
372
+ <tr>
373
+ <td>
374
+ <xsl:variable name="itemURL">
375
+ <xsl:value-of select="atom:link/@href" />
376
+ </xsl:variable>
377
+ <a href="{$itemURL}">
378
+ <xsl:value-of select="kml:name" />
379
+ </a>
380
+ </td>
381
+ <td>
382
+ <xsl:value-of select="kml:address" />
383
+ </td>
384
+ <td>
385
+ <xsl:value-of select="kml:phoneNumber" />
386
+ </td>
387
+ <td>
388
+ <xsl:value-of select="kml:LookAt/kml:latitude" />
389
+ </td>
390
+ <td>
391
+ <xsl:value-of select="kml:LookAt/kml:longitude" />
392
+ </td>
393
+ </tr>
394
+ </xsl:for-each>
395
+ </tbody>
396
+ </table>
397
+ </div>
398
+ </xsl:when>
399
+ <xsl:otherwise>
400
+ <div id="description">
401
+ <h1>XML Sitemap</h1>
402
+ <p>
403
+ This XML Sitemap is generated by
404
+ <a href="https://www.geekron.com" target="_blank">Geekron</a>.
405
+ It is what search engines like Google use to crawl and
406
+ re-crawl pages on your website.
407
+ </p>
408
+
409
+ <p>
410
+ Learn more about
411
+ <a href="http://sitemaps.org" target="_blank">XML Sitemaps</a>.
412
+ </p>
413
+ </div>
414
+
415
+ <div id="content">
416
+ <xsl:if test="count(sitemap:sitemapindex/sitemap:sitemap) &gt; 0">
417
+ <div class="stats-card">
418
+ <span class="icon">📋</span>
419
+ <p class="expl" style="margin: 0;">
420
+ This XML Sitemap Index file contains
421
+ <strong>
422
+ <xsl:value-of select="count(sitemap:sitemapindex/sitemap:sitemap)" />
423
+ </strong>
424
+ sitemaps.
425
+ </p>
426
+ </div>
427
+
428
+ <table id="sitemap" cellpadding="3">
429
+ <thead>
430
+ <tr>
431
+ <th width="75%">Sitemap</th>
432
+ <th width="25%">Last Modified</th>
433
+ </tr>
434
+ </thead>
435
+
436
+ <tbody>
437
+ <xsl:for-each select="sitemap:sitemapindex/sitemap:sitemap">
438
+ <xsl:variable name="sitemapURL">
439
+ <xsl:value-of select="sitemap:loc" />
440
+ </xsl:variable>
441
+ <tr>
442
+ <td>
443
+ <a href="{$sitemapURL}">
444
+ <xsl:value-of select="sitemap:loc"/>
445
+ </a>
446
+ </td>
447
+ <td>
448
+ <xsl:value-of select="concat(substring(sitemap:lastmod,0,11),concat(' ', substring(sitemap:lastmod,12,5)),concat(' ', substring(sitemap:lastmod,20,6)))"/>
449
+ </td>
450
+ </tr>
451
+ </xsl:for-each>
452
+ </tbody>
453
+ </table>
454
+ </xsl:if>
455
+ <xsl:if test="count(sitemap:sitemapindex/sitemap:sitemap) &lt; 1">
456
+ <div class="stats-card">
457
+ <span class="icon">🔗</span>
458
+ <p class="expl" style="margin: 0;">
459
+ This XML Sitemap contains
460
+ <strong>
461
+ <xsl:value-of select="count(sitemap:urlset/sitemap:url)"/>
462
+ </strong>
463
+ URLs.
464
+ </p>
465
+ </div>
466
+
467
+ <a href="{{sitemapIndexUrl}}" class="back-link">
468
+ <span>←</span> Back to Sitemap Index
469
+ </a>
470
+
471
+ <table id="sitemap" cellpadding="3">
472
+ <thead>
473
+ <tr>
474
+ <th width="60%">URL</th>
475
+ <th width="12%" title="Change Frequency">Freq.</th>
476
+ <th width="10%" title="Priority">Priority</th>
477
+ <th title="Last Modification Time" width="18%">
478
+ Last Mod.
479
+ </th>
480
+ </tr>
481
+ </thead>
482
+
483
+ <tbody>
484
+ <xsl:variable name="lower" select="'abcdefghijklmnopqrstuvwxyz'"/>
485
+ <xsl:variable name="upper" select="'ABCDEFGHIJKLMNOPQRSTUVWXYZ'"/>
486
+ <xsl:for-each select="sitemap:urlset/sitemap:url">
487
+ <tr>
488
+ <td>
489
+ <xsl:variable name="itemURL">
490
+ <xsl:value-of select="sitemap:loc" />
491
+ </xsl:variable>
492
+ <a href="{$itemURL}">
493
+ <xsl:value-of select="sitemap:loc" />
494
+ </a>
495
+ </td>
496
+ <td style="text-align: center;">
497
+ <xsl:choose>
498
+ <xsl:when test="sitemap:changefreq">
499
+ <xsl:variable name="freq" select="sitemap:changefreq" />
500
+ <span>
501
+ <xsl:attribute name="class">
502
+ badge
503
+ <xsl:choose>
504
+ <xsl:when test="$freq = 'always' or $freq = 'hourly' or $freq = 'daily'">badge-success</xsl:when>
505
+ <xsl:when test="$freq = 'weekly' or $freq = 'monthly'">badge-info</xsl:when>
506
+ <xsl:otherwise>badge-warning</xsl:otherwise>
507
+ </xsl:choose>
508
+ </xsl:attribute>
509
+ <xsl:value-of select="$freq" />
510
+ </span>
511
+ </xsl:when>
512
+ <xsl:otherwise>
513
+ <span style="color: var(--muted); font-size: 0.9em;">-</span>
514
+ </xsl:otherwise>
515
+ </xsl:choose>
516
+ </td>
517
+ <td style="text-align: center;">
518
+ <xsl:choose>
519
+ <xsl:when test="sitemap:priority">
520
+ <xsl:variable name="priority" select="sitemap:priority" />
521
+ <span style="font-weight: 600; font-size: 0.95em;">
522
+ <xsl:attribute name="style">
523
+ font-weight: 600;
524
+ font-size: 0.95em;
525
+ <xsl:choose>
526
+ <xsl:when test="$priority &gt;= 0.8">color: var(--success);</xsl:when>
527
+ <xsl:when test="$priority &gt;= 0.5">color: var(--accent);</xsl:when>
528
+ <xsl:otherwise>color: var(--muted);</xsl:otherwise>
529
+ </xsl:choose>
530
+ </xsl:attribute>
531
+ <xsl:value-of select="$priority" />
532
+ </span>
533
+ </xsl:when>
534
+ <xsl:otherwise>
535
+ <span style="color: var(--muted); font-size: 0.9em;">-</span>
536
+ </xsl:otherwise>
537
+ </xsl:choose>
538
+ </td>
539
+ <td>
540
+ <xsl:value-of
541
+ select="concat(substring(sitemap:lastmod,0,11),concat(' ', substring(sitemap:lastmod,12,5)),concat(' ', substring(sitemap:lastmod,20,6)))"
542
+ />
543
+ </td>
544
+ </tr>
545
+ <xsl:if test="count(image:image) &gt; 0 or count(xhtml:link) &gt; 0">
546
+ <tr style="background: var(--row);">
547
+ <td colspan="4" style="padding: 0; border-bottom: 1px solid var(--border);">
548
+ <table style="width: 100%; border: none; box-shadow: none; margin: 0; background: transparent;">
549
+ <xsl:if test="count(image:image) &gt; 0">
550
+ <tr style="background: transparent;">
551
+ <th style="width: 120px; padding: 6px 14px; text-align: left; background: transparent; color: var(--muted); font-weight: 600; font-size: 0.85em; vertical-align: middle; border: none;">
552
+ <span style="margin-right: 6px;">🖼️</span>Images
553
+ </th>
554
+ <td style="padding: 6px 14px; background: transparent; border: none;">
555
+ <div style="display: flex; flex-wrap: wrap; gap: 6px;">
556
+ <xsl:for-each select="image:image">
557
+ <div style="flex: 1; min-width: 250px;">
558
+ <a href="{image:loc}" style="word-break: break-all; font-size: 0.9em;">
559
+ <xsl:value-of select="image:loc" />
560
+ </a>
561
+ <xsl:if test="image:caption">
562
+ <div style="margin-top: 4px; font-size: 0.85em; color: var(--muted); font-style: italic;">
563
+ <xsl:value-of select="image:caption" />
564
+ </div>
565
+ </xsl:if>
566
+ </div>
567
+ </xsl:for-each>
568
+ </div>
569
+ </td>
570
+ </tr>
571
+ </xsl:if>
572
+ <xsl:if test="count(xhtml:link) &gt; 0">
573
+ <tr style="background: transparent;">
574
+ <th style="width: 120px; padding: 6px 14px; text-align: left; background: transparent; color: var(--muted); font-weight: 600; font-size: 0.85em; vertical-align: middle; border: none;">
575
+ <span style="margin-right: 6px;">🌐</span>Languages
576
+ </th>
577
+ <td style="padding: 6px 14px; background: transparent; border: none;">
578
+ <div style="display: flex; flex-wrap: wrap; gap: 12px;">
579
+ <xsl:for-each select="xhtml:link">
580
+ <a href="{@href}" style="text-transform: uppercase; font-weight: 500; padding: 4px 10px; background: var(--accent-light); color: var(--accent); border-radius: 4px; font-size: 0.85em;">
581
+ <xsl:value-of select="@hreflang" />
582
+ </a>
583
+ </xsl:for-each>
584
+ </div>
585
+ </td>
586
+ </tr>
587
+ </xsl:if>
588
+ </table>
589
+ </td>
590
+ </tr>
591
+ </xsl:if>
592
+ </xsl:for-each>
593
+ </tbody>
594
+ </table>
595
+ </xsl:if>
596
+ </div>
597
+ </xsl:otherwise>
598
+ </xsl:choose>
599
+ </body>
600
+ </html>
601
+ </xsl:template>
602
+ </xsl:stylesheet>
@@ -4,4 +4,5 @@ export * from './imgAlt';
4
4
  export * from './imgInfo';
5
5
  export * from './imgSrc';
6
6
  export * from './resource';
7
+ export * from './trans';
7
8
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/strapi/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAA;AAC3B,cAAc,WAAW,CAAA;AACzB,cAAc,UAAU,CAAA;AACxB,cAAc,WAAW,CAAA;AACzB,cAAc,UAAU,CAAA;AACxB,cAAc,YAAY,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/strapi/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAA;AAC3B,cAAc,WAAW,CAAA;AACzB,cAAc,UAAU,CAAA;AACxB,cAAc,WAAW,CAAA;AACzB,cAAc,UAAU,CAAA;AACxB,cAAc,YAAY,CAAA;AAC1B,cAAc,SAAS,CAAA"}
@@ -4,3 +4,4 @@ export * from './imgAlt';
4
4
  export * from './imgInfo';
5
5
  export * from './imgSrc';
6
6
  export * from './resource';
7
+ export * from './trans';
@@ -0,0 +1,5 @@
1
+ export declare const trans: (key: string, options?: {
2
+ defaultValue?: string;
3
+ [key: string]: any;
4
+ }) => string;
5
+ //# sourceMappingURL=trans.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"trans.d.ts","sourceRoot":"","sources":["../../../src/strapi/utils/trans.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,KAAK,GACjB,KAAK,MAAM,EACX,UAAU;IACT,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;CAClB,WAKD,CAAA"}
@@ -0,0 +1,7 @@
1
+ import { getI18n } from '../../strapi/i18n';
2
+ export const trans = (key, options) => {
3
+ const i18n = getI18n();
4
+ if (!i18n)
5
+ return key;
6
+ return i18n.t(key, options);
7
+ };
package/package.json CHANGED
@@ -1,8 +1,9 @@
1
1
  {
2
2
  "name": "@geekron/hono",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "type": "module",
5
5
  "scripts": {
6
+ "dev": "./shell/build.sh watch",
6
7
  "format": "bunx biome format --write",
7
8
  "lint": "bunx biome lint --write",
8
9
  "check": "bunx biome check --write",
@@ -19,19 +20,36 @@
19
20
  "types": "./dist/route/index.d.ts",
20
21
  "import": "./dist/route/index.js",
21
22
  "require": "./dist/route/index.js"
23
+ },
24
+ "./core": {
25
+ "types": "./dist/core/index.d.ts",
26
+ "import": "./dist/core/index.js",
27
+ "require": "./dist/core/index.js"
22
28
  }
23
29
  },
24
30
  "files": [
25
31
  "dist"
26
32
  ],
33
+ "peerDependencies": {
34
+ "hono": "4.11.3"
35
+ },
27
36
  "dependencies": {
28
37
  "@strapi/client": "^1.6.0",
29
- "hono": "^4.11.1",
38
+ "dayjs": "^1.11.19",
39
+ "drizzle-orm": "^0.45.1",
40
+ "html-minifier-next": "^4.16.3",
41
+ "i18next": "^25.7.3",
42
+ "liquidjs": "^10.24.0",
43
+ "marked": "^17.0.1",
44
+ "maxmind": "^5.0.1",
45
+ "nodemailer": "^7.0.12",
46
+ "radash": "^12.1.1",
30
47
  "voca": "^1.4.1"
31
48
  },
32
49
  "devDependencies": {
33
50
  "@biomejs/biome": "^2.3.10",
34
51
  "@types/bun": "latest",
52
+ "@types/nodemailer": "^7.0.4",
35
53
  "@types/voca": "^1.4.6",
36
54
  "tsc-alias": "^1.8.16",
37
55
  "typescript": "^5.9.3"