@jjlmoya/utils-nautical 1.3.0 → 1.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jjlmoya/utils-nautical",
3
- "version": "1.3.0",
3
+ "version": "1.4.0",
4
4
  "type": "module",
5
5
  "main": "./src/index.ts",
6
6
  "types": "./src/index.ts",
@@ -0,0 +1,37 @@
1
+ ---
2
+ import {
3
+ SEOTitle,
4
+ SEOTip,
5
+ SEOArticle,
6
+ SEOList,
7
+ } from '@jjlmoya/utils-shared';
8
+ import { nauticalCategory } from './index';
9
+ import type { KnownLocale } from '../types';
10
+
11
+ interface Props {
12
+ locale?: KnownLocale;
13
+ }
14
+
15
+ const { locale = 'es' } = Astro.props;
16
+ const content = await nauticalCategory.i18n[locale]?.();
17
+ if (!content) return null;
18
+
19
+ const { seo } = content;
20
+ ---
21
+
22
+ <SEOArticle>
23
+ {seo.map((section: any) => {
24
+ switch (section.type) {
25
+ case 'title':
26
+ return <SEOTitle title={section.text} level={section.level || 2} />;
27
+ case 'paragraph':
28
+ return <p set:html={section.html} />;
29
+ case 'list':
30
+ return <SEOList items={section.items} />;
31
+ case 'tip':
32
+ return <SEOTip title={section.title}><Fragment set:html={section.html} /></SEOTip>;
33
+ default:
34
+ return null;
35
+ }
36
+ })}
37
+ </SEOArticle>
package/src/index.ts CHANGED
@@ -5,6 +5,7 @@ export * from './tool/sailArea';
5
5
  export * from './tool/speedConverter';
6
6
  export * from './tool/endurance';
7
7
  export * from './category';
8
+ export { default as NauticalCategorySEO } from './category/seo.astro';
8
9
 
9
10
  export type {
10
11
  KnownLocale,
@@ -13,6 +13,8 @@
13
13
  --n-success: #10b981;
14
14
  --n-warning: #f59e0b;
15
15
  --n-error: #f43f5e;
16
+ --ec-hero-bg: #0f172a;
17
+ --ec-hero-label: #22d3ee;
16
18
 
17
19
  max-width: 1000px;
18
20
  margin: 0 auto;
@@ -33,6 +35,8 @@
33
35
  --n-success: #34d399;
34
36
  --n-warning: #fbbf24;
35
37
  --n-error: #fb7185;
38
+ --ec-hero-bg: #020617;
39
+ --ec-hero-label: #22d3ee;
36
40
  }
37
41
 
38
42
  .ec-main-container {
@@ -137,7 +141,7 @@
137
141
  }
138
142
 
139
143
  .ec-hero-display {
140
- background: var(--n-primary);
144
+ background: var(--ec-hero-bg);
141
145
  border-radius: 1rem;
142
146
  padding: 2rem;
143
147
  color: var(--n-primary-on);
@@ -156,7 +160,7 @@
156
160
  font-size: 0.65rem;
157
161
  font-weight: 900;
158
162
  text-transform: uppercase;
159
- color: var(--n-cyan);
163
+ color: var(--ec-hero-label);
160
164
  letter-spacing: 0.1em;
161
165
  }
162
166
 
@@ -167,7 +171,7 @@
167
171
  }
168
172
 
169
173
  .ec-main-value {
170
- font-size: 4rem;
174
+ font-size: 5rem;
171
175
  font-weight: 900;
172
176
  color: var(--n-primary-on);
173
177
  line-height: 1;
@@ -181,10 +185,10 @@
181
185
  }
182
186
 
183
187
  .ec-fuel-badge {
184
- font-size: 1.5rem;
188
+ font-size: 0.85rem;
185
189
  font-weight: 900;
186
- color: var(--n-primary-on);
187
- opacity: 0.7;
190
+ color: var(--ec-hero-label);
191
+ letter-spacing: 0.05em;
188
192
  }
189
193
 
190
194
  .ec-progress-track {
@@ -13,6 +13,9 @@
13
13
  --n-success: #10b981;
14
14
  --n-warning: #f59e0b;
15
15
  --n-error: #f43f5e;
16
+ --ukc-label-size: 0.75rem;
17
+ --ukc-label-weight: 800;
18
+ --ukc-label-spacing: 0.06em;
16
19
 
17
20
  display: flex;
18
21
  flex-direction: column;
@@ -85,9 +88,12 @@
85
88
  }
86
89
 
87
90
  .ukc-input-block label {
88
- font-size: 0.8rem;
89
- font-weight: 600;
90
- opacity: 0.7;
91
+ font-size: var(--ukc-label-size);
92
+ font-weight: var(--ukc-label-weight);
93
+ color: var(--n-primary-on);
94
+ opacity: 0.9;
95
+ text-transform: uppercase;
96
+ letter-spacing: var(--ukc-label-spacing);
91
97
  }
92
98
 
93
99
  .ukc-unit-input {
@@ -112,7 +118,7 @@
112
118
  right: 12px;
113
119
  font-size: 0.85rem;
114
120
  font-weight: 700;
115
- opacity: 0.4;
121
+ opacity: 0.6;
116
122
  }
117
123
 
118
124
  .ukc-hr-divider {