@jjlmoya/utils-babies 1.9.0 → 1.12.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,12 +1,13 @@
1
1
  {
2
2
  "name": "@jjlmoya/utils-babies",
3
- "version": "1.9.0",
3
+ "version": "1.12.0",
4
4
  "type": "module",
5
5
  "main": "./src/index.ts",
6
6
  "types": "./src/index.ts",
7
7
  "exports": {
8
8
  ".": "./src/index.ts",
9
- "./data": "./src/data.ts"
9
+ "./data": "./src/data.ts",
10
+ "./entries": "./src/entries.ts"
10
11
  },
11
12
  "files": [
12
13
  "src"
@@ -1,10 +1,10 @@
1
1
  import type { BabiesCategoryEntry } from '../types';
2
- import { babyFeedingCalculator } from '../tool/baby-feeding-calculator';
3
- import { babySizeConverter } from '../tool/baby-size-converter';
4
- import { vaccinationCalendar } from '../tool/vaccination-calendar';
5
- import { fertileDaysEstimator } from '../tool/fertile-days-estimator';
6
- import { babyPercentileCalculator } from '../tool/baby-percentile-calculator';
7
- import { pregnancyCalculator } from '../tool/pregnancy-calculator';
2
+ import { babyFeedingCalculator } from '../tool/baby-feeding-calculator/entry';
3
+ import { babySizeConverter } from '../tool/baby-size-converter/entry';
4
+ import { vaccinationCalendar } from '../tool/vaccination-calendar/entry';
5
+ import { fertileDaysEstimator } from '../tool/fertile-days-estimator/entry';
6
+ import { babyPercentileCalculator } from '../tool/baby-percentile-calculator/entry';
7
+ import { pregnancyCalculator } from '../tool/pregnancy-calculator/entry';
8
8
 
9
9
  export const babiesCategory: BabiesCategoryEntry = {
10
10
  icon: 'mdi:baby-carriage',
package/src/entries.ts ADDED
@@ -0,0 +1,20 @@
1
+ export { babyFeedingCalculator } from './tool/baby-feeding-calculator/entry';
2
+ export type { BabyFeedingCalculatorUI, BabyFeedingCalculatorLocaleContent } from './tool/baby-feeding-calculator/entry';
3
+ export { babyPercentileCalculator } from './tool/baby-percentile-calculator/entry';
4
+ export type { BabyPercentileCalculatorUI, BabyPercentileCalculatorLocaleContent } from './tool/baby-percentile-calculator/entry';
5
+ export { babySizeConverter } from './tool/baby-size-converter/entry';
6
+ export type { BabySizeConverterUI, BabySizeConverterLocaleContent } from './tool/baby-size-converter/entry';
7
+ export { fertileDaysEstimator } from './tool/fertile-days-estimator/entry';
8
+ export type { FertileDaysEstimatorUI, FertileDaysEstimatorLocaleContent } from './tool/fertile-days-estimator/entry';
9
+ export { pregnancyCalculator } from './tool/pregnancy-calculator/entry';
10
+ export type { MilestoneI18n, PregnancyCalculatorUI, PregnancyCalculatorLocaleContent } from './tool/pregnancy-calculator/entry';
11
+ export { vaccinationCalendar } from './tool/vaccination-calendar/entry';
12
+ export type { VaccinationCalendarUI, VaccinationCalendarLocaleContent } from './tool/vaccination-calendar/entry';
13
+ export { babiesCategory } from './category';
14
+ import { babyFeedingCalculator } from './tool/baby-feeding-calculator/entry';
15
+ import { babyPercentileCalculator } from './tool/baby-percentile-calculator/entry';
16
+ import { babySizeConverter } from './tool/baby-size-converter/entry';
17
+ import { fertileDaysEstimator } from './tool/fertile-days-estimator/entry';
18
+ import { pregnancyCalculator } from './tool/pregnancy-calculator/entry';
19
+ import { vaccinationCalendar } from './tool/vaccination-calendar/entry';
20
+ export const ALL_ENTRIES = [babyFeedingCalculator, babyPercentileCalculator, babySizeConverter, fertileDaysEstimator, pregnancyCalculator, vaccinationCalendar];
package/src/index.ts CHANGED
@@ -6,7 +6,7 @@ export * from './tool/baby-percentile-calculator';
6
6
  export * from './tool/fertile-days-estimator';
7
7
  export * from './tool/pregnancy-calculator';
8
8
  export * from './tool/vaccination-calendar';
9
- export { default as babiesCategorySEO } from './category/seo.astro';
9
+ export const babiesCategorySEO = () => import('./category/seo.astro').then((m) => m.default);
10
10
 
11
11
  export type {
12
12
  KnownLocale,
@@ -14,7 +14,8 @@ import type { UtilitySEOContent } from "@jjlmoya/utils-shared";
14
14
  export async function getStaticPaths() {
15
15
  const paths = [];
16
16
 
17
- for (const { entry, Component } of ALL_TOOLS) {
17
+ for (const { entry, Component: lazyComp } of ALL_TOOLS) {
18
+ const { default: Component } = await lazyComp();
18
19
  const localeEntries = Object.entries(entry.i18n) as [
19
20
  KnownLocale,
20
21
  () => Promise<ToolLocaleContent>,
@@ -52,8 +53,6 @@ export async function getStaticPaths() {
52
53
  return paths;
53
54
  }
54
55
 
55
- type ToolComponent = (props: { ui: Record<string, string> }) => unknown;
56
-
57
56
  interface NavItem {
58
57
  id: string;
59
58
  title: string;
@@ -62,7 +61,7 @@ interface NavItem {
62
61
  }
63
62
 
64
63
  interface Props {
65
- Component: ToolComponent;
64
+ Component: unknown;
66
65
  locale: KnownLocale;
67
66
  content: ToolLocaleContent;
68
67
  localeUrls: Partial<Record<KnownLocale, string>>;
@@ -0,0 +1,47 @@
1
+ import type { BabiesToolEntry, ToolLocaleContent } from '../../types';
2
+
3
+ export interface BabyFeedingCalculatorUI {
4
+ [key: string]: string;
5
+ labelConfig: string;
6
+ labelPlan: string;
7
+ unitDays: string;
8
+ unitWeeks: string;
9
+ unitMonths: string;
10
+ labelWeight: string;
11
+ labelFeedType: string;
12
+ feedBreast: string;
13
+ feedMixed: string;
14
+ feedFormula: string;
15
+ labelFreeDemand: string;
16
+ labelMlPerFeed: string;
17
+ labelFeedsCount: string;
18
+ labelDailyTotal: string;
19
+ labelHunger: string;
20
+ labelFullness: string;
21
+ faqTitle: string;
22
+ bibliographyTitle: string;
23
+ }
24
+
25
+ export type BabyFeedingCalculatorLocaleContent = ToolLocaleContent<BabyFeedingCalculatorUI>;
26
+
27
+ export const babyFeedingCalculator: BabiesToolEntry<BabyFeedingCalculatorUI> = {
28
+ id: 'baby-feeding-calculator',
29
+ icons: { bg: 'mdi:baby-bottle', fg: 'mdi:baby-bottle-outline' },
30
+ i18n: {
31
+ es: () => import('./i18n/es').then((m) => m.content),
32
+ en: () => import('./i18n/en').then((m) => m.content),
33
+ de: () => import('./i18n/de').then((m) => m.content),
34
+ fr: () => import('./i18n/fr').then((m) => m.content),
35
+ it: () => import('./i18n/it').then((m) => m.content),
36
+ pt: () => import('./i18n/pt').then((m) => m.content),
37
+ nl: () => import('./i18n/nl').then((m) => m.content),
38
+ pl: () => import('./i18n/pl').then((m) => m.content),
39
+ ru: () => import('./i18n/ru').then((m) => m.content),
40
+ tr: () => import('./i18n/tr').then((m) => m.content),
41
+ sv: () => import('./i18n/sv').then((m) => m.content),
42
+ id: () => import('./i18n/id').then((m) => m.content),
43
+ ja: () => import('./i18n/ja').then((m) => m.content),
44
+ ko: () => import('./i18n/ko').then((m) => m.content),
45
+ zh: () => import('./i18n/zh').then((m) => m.content),
46
+ },
47
+ };
@@ -1,59 +1,8 @@
1
- import type { BabiesToolEntry, ToolDefinition, ToolLocaleContent } from '../../types';
2
- import BabyFeedingCalculatorComponent from './component.astro';
3
- import BabyFeedingCalculatorSEO from './seo.astro';
4
- import BabyFeedingCalculatorBibliography from './bibliography.astro';
5
-
6
- export interface BabyFeedingCalculatorUI {
7
- [key: string]: string;
8
- labelConfig: string;
9
- labelPlan: string;
10
- unitDays: string;
11
- unitWeeks: string;
12
- unitMonths: string;
13
- labelWeight: string;
14
- labelFeedType: string;
15
- feedBreast: string;
16
- feedMixed: string;
17
- feedFormula: string;
18
- labelFreeDemand: string;
19
- labelMlPerFeed: string;
20
- labelFeedsCount: string;
21
- labelDailyTotal: string;
22
- labelHunger: string;
23
- labelFullness: string;
24
- faqTitle: string;
25
- bibliographyTitle: string;
26
- }
27
-
28
- export type BabyFeedingCalculatorLocaleContent = ToolLocaleContent<BabyFeedingCalculatorUI>;
29
-
30
- export const babyFeedingCalculator: BabiesToolEntry<BabyFeedingCalculatorUI> = {
31
- id: 'baby-feeding-calculator',
32
- icons: { bg: 'mdi:baby-bottle', fg: 'mdi:baby-bottle-outline' },
33
- i18n: {
34
- es: () => import('./i18n/es').then((m) => m.content),
35
- en: () => import('./i18n/en').then((m) => m.content),
36
- de: () => import('./i18n/de').then((m) => m.content),
37
- fr: () => import('./i18n/fr').then((m) => m.content),
38
- it: () => import('./i18n/it').then((m) => m.content),
39
- pt: () => import('./i18n/pt').then((m) => m.content),
40
- nl: () => import('./i18n/nl').then((m) => m.content),
41
- pl: () => import('./i18n/pl').then((m) => m.content),
42
- ru: () => import('./i18n/ru').then((m) => m.content),
43
- tr: () => import('./i18n/tr').then((m) => m.content),
44
- sv: () => import('./i18n/sv').then((m) => m.content),
45
- id: () => import('./i18n/id').then((m) => m.content),
46
- ja: () => import('./i18n/ja').then((m) => m.content),
47
- ko: () => import('./i18n/ko').then((m) => m.content),
48
- zh: () => import('./i18n/zh').then((m) => m.content),
49
- },
50
- };
51
-
52
- export { BabyFeedingCalculatorComponent, BabyFeedingCalculatorSEO, BabyFeedingCalculatorBibliography };
53
-
1
+ import { babyFeedingCalculator } from './entry';
2
+ export * from './entry';
54
3
  export const BABY_FEEDING_CALCULATOR_TOOL: ToolDefinition = {
55
4
  entry: babyFeedingCalculator,
56
- Component: BabyFeedingCalculatorComponent,
57
- SEOComponent: BabyFeedingCalculatorSEO,
58
- BibliographyComponent: BabyFeedingCalculatorBibliography,
5
+ Component: () => import('./component.astro'),
6
+ SEOComponent: () => import('./seo.astro'),
7
+ BibliographyComponent: () => import('./bibliography.astro'),
59
8
  };
@@ -0,0 +1,55 @@
1
+ import type { BabiesToolEntry, ToolLocaleContent } from '../../types';
2
+
3
+ export interface BabyPercentileCalculatorUI {
4
+ [key: string]: string;
5
+ labelMeasurements: string;
6
+ labelSex: string;
7
+ sexBoy: string;
8
+ sexGirl: string;
9
+ unitMonths: string;
10
+ unitYearsMonths: string;
11
+ labelWeight: string;
12
+ labelHeight: string;
13
+ btnAddHistory: string;
14
+ btnClearHistory: string;
15
+ labelDashboard: string;
16
+ labelWeight2: string;
17
+ labelHeight2: string;
18
+ labelBMI: string;
19
+ labelCalculating: string;
20
+ disclaimer: string;
21
+ labelLowRange: string;
22
+ labelLowNormal: string;
23
+ labelNormal: string;
24
+ labelHighNormal: string;
25
+ labelHighRange: string;
26
+ alertOutOfRange: string;
27
+ labelMonths: string;
28
+ labelYears: string;
29
+ faqTitle: string;
30
+ bibliographyTitle: string;
31
+ }
32
+
33
+ export type BabyPercentileCalculatorLocaleContent = ToolLocaleContent<BabyPercentileCalculatorUI>;
34
+
35
+ export const babyPercentileCalculator: BabiesToolEntry<BabyPercentileCalculatorUI> = {
36
+ id: 'baby-percentile-calculator',
37
+ icons: { bg: 'mdi:chart-bell-curve', fg: 'mdi:chart-bell-curve-cumulative' },
38
+ i18n: {
39
+ es: () => import('./i18n/es').then((m) => m.content),
40
+ en: () => import('./i18n/en').then((m) => m.content),
41
+ de: () => import('./i18n/de').then((m) => m.content),
42
+ fr: () => import('./i18n/fr').then((m) => m.content),
43
+ it: () => import('./i18n/it').then((m) => m.content),
44
+ pt: () => import('./i18n/pt').then((m) => m.content),
45
+ nl: () => import('./i18n/nl').then((m) => m.content),
46
+ pl: () => import('./i18n/pl').then((m) => m.content),
47
+ ru: () => import('./i18n/ru').then((m) => m.content),
48
+ tr: () => import('./i18n/tr').then((m) => m.content),
49
+ sv: () => import('./i18n/sv').then((m) => m.content),
50
+ id: () => import('./i18n/id').then((m) => m.content),
51
+ ja: () => import('./i18n/ja').then((m) => m.content),
52
+ ko: () => import('./i18n/ko').then((m) => m.content),
53
+ zh: () => import('./i18n/zh').then((m) => m.content),
54
+ },
55
+ };
@@ -1,67 +1,8 @@
1
- import type { BabiesToolEntry, ToolDefinition, ToolLocaleContent } from '../../types';
2
- import BabyPercentileCalculatorComponent from './component.astro';
3
- import BabyPercentileCalculatorSEO from './seo.astro';
4
- import BabyPercentileCalculatorBibliography from './bibliography.astro';
5
-
6
- export interface BabyPercentileCalculatorUI {
7
- [key: string]: string;
8
- labelMeasurements: string;
9
- labelSex: string;
10
- sexBoy: string;
11
- sexGirl: string;
12
- unitMonths: string;
13
- unitYearsMonths: string;
14
- labelWeight: string;
15
- labelHeight: string;
16
- btnAddHistory: string;
17
- btnClearHistory: string;
18
- labelDashboard: string;
19
- labelWeight2: string;
20
- labelHeight2: string;
21
- labelBMI: string;
22
- labelCalculating: string;
23
- disclaimer: string;
24
- labelLowRange: string;
25
- labelLowNormal: string;
26
- labelNormal: string;
27
- labelHighNormal: string;
28
- labelHighRange: string;
29
- alertOutOfRange: string;
30
- labelMonths: string;
31
- labelYears: string;
32
- faqTitle: string;
33
- bibliographyTitle: string;
34
- }
35
-
36
- export type BabyPercentileCalculatorLocaleContent = ToolLocaleContent<BabyPercentileCalculatorUI>;
37
-
38
- export const babyPercentileCalculator: BabiesToolEntry<BabyPercentileCalculatorUI> = {
39
- id: 'baby-percentile-calculator',
40
- icons: { bg: 'mdi:chart-bell-curve', fg: 'mdi:chart-bell-curve-cumulative' },
41
- i18n: {
42
- es: () => import('./i18n/es').then((m) => m.content),
43
- en: () => import('./i18n/en').then((m) => m.content),
44
- de: () => import('./i18n/de').then((m) => m.content),
45
- fr: () => import('./i18n/fr').then((m) => m.content),
46
- it: () => import('./i18n/it').then((m) => m.content),
47
- pt: () => import('./i18n/pt').then((m) => m.content),
48
- nl: () => import('./i18n/nl').then((m) => m.content),
49
- pl: () => import('./i18n/pl').then((m) => m.content),
50
- ru: () => import('./i18n/ru').then((m) => m.content),
51
- tr: () => import('./i18n/tr').then((m) => m.content),
52
- sv: () => import('./i18n/sv').then((m) => m.content),
53
- id: () => import('./i18n/id').then((m) => m.content),
54
- ja: () => import('./i18n/ja').then((m) => m.content),
55
- ko: () => import('./i18n/ko').then((m) => m.content),
56
- zh: () => import('./i18n/zh').then((m) => m.content),
57
- },
58
- };
59
-
60
- export { BabyPercentileCalculatorComponent, BabyPercentileCalculatorSEO, BabyPercentileCalculatorBibliography };
61
-
1
+ import { babyPercentileCalculator } from './entry';
2
+ export * from './entry';
62
3
  export const BABY_PERCENTILE_CALCULATOR_TOOL: ToolDefinition = {
63
4
  entry: babyPercentileCalculator,
64
- Component: BabyPercentileCalculatorComponent,
65
- SEOComponent: BabyPercentileCalculatorSEO,
66
- BibliographyComponent: BabyPercentileCalculatorBibliography,
5
+ Component: () => import('./component.astro'),
6
+ SEOComponent: () => import('./seo.astro'),
7
+ BibliographyComponent: () => import('./bibliography.astro'),
67
8
  };
@@ -0,0 +1,53 @@
1
+ import type { BabiesToolEntry, ToolLocaleContent } from '../../types';
2
+
3
+ export interface BabySizeConverterUI {
4
+ [key: string]: string;
5
+ labelInput: string;
6
+ labelResults: string;
7
+ labelHeight: string;
8
+ labelWeight: string;
9
+ labelPresets: string;
10
+ unitMetric: string;
11
+ unitImperial: string;
12
+ labelCm: string;
13
+ labelKg: string;
14
+ labelIn: string;
15
+ labelLb: string;
16
+ labelBrandFit: string;
17
+ labelSuggested: string;
18
+ labelChest: string;
19
+ labelWaist: string;
20
+ labelGarmentMeasures: string;
21
+ fitRegular: string;
22
+ fitLarge: string;
23
+ fitSmall: string;
24
+ tipTitle: string;
25
+ tipText: string;
26
+ shareAriaLabel: string;
27
+ faqTitle: string;
28
+ bibliographyTitle: string;
29
+ }
30
+
31
+ export type BabySizeConverterLocaleContent = ToolLocaleContent<BabySizeConverterUI>;
32
+
33
+ export const babySizeConverter: BabiesToolEntry<BabySizeConverterUI> = {
34
+ id: 'baby-size-converter',
35
+ icons: { bg: 'mdi:tshirt-crew', fg: 'mdi:tshirt-crew-outline' },
36
+ i18n: {
37
+ es: () => import('./i18n/es').then((m) => m.content),
38
+ en: () => import('./i18n/en').then((m) => m.content),
39
+ de: () => import('./i18n/de').then((m) => m.content),
40
+ fr: () => import('./i18n/fr').then((m) => m.content),
41
+ it: () => import('./i18n/it').then((m) => m.content),
42
+ pt: () => import('./i18n/pt').then((m) => m.content),
43
+ nl: () => import('./i18n/nl').then((m) => m.content),
44
+ pl: () => import('./i18n/pl').then((m) => m.content),
45
+ ru: () => import('./i18n/ru').then((m) => m.content),
46
+ tr: () => import('./i18n/tr').then((m) => m.content),
47
+ sv: () => import('./i18n/sv').then((m) => m.content),
48
+ id: () => import('./i18n/id').then((m) => m.content),
49
+ ja: () => import('./i18n/ja').then((m) => m.content),
50
+ ko: () => import('./i18n/ko').then((m) => m.content),
51
+ zh: () => import('./i18n/zh').then((m) => m.content),
52
+ },
53
+ };
@@ -1,65 +1,8 @@
1
- import type { BabiesToolEntry, ToolDefinition, ToolLocaleContent } from '../../types';
2
- import BabySizeConverterComponent from './component.astro';
3
- import BabySizeConverterSEO from './seo.astro';
4
- import BabySizeConverterBibliography from './bibliography.astro';
5
-
6
- export interface BabySizeConverterUI {
7
- [key: string]: string;
8
- labelInput: string;
9
- labelResults: string;
10
- labelHeight: string;
11
- labelWeight: string;
12
- labelPresets: string;
13
- unitMetric: string;
14
- unitImperial: string;
15
- labelCm: string;
16
- labelKg: string;
17
- labelIn: string;
18
- labelLb: string;
19
- labelBrandFit: string;
20
- labelSuggested: string;
21
- labelChest: string;
22
- labelWaist: string;
23
- labelGarmentMeasures: string;
24
- fitRegular: string;
25
- fitLarge: string;
26
- fitSmall: string;
27
- tipTitle: string;
28
- tipText: string;
29
- shareAriaLabel: string;
30
- faqTitle: string;
31
- bibliographyTitle: string;
32
- }
33
-
34
- export type BabySizeConverterLocaleContent = ToolLocaleContent<BabySizeConverterUI>;
35
-
36
- export const babySizeConverter: BabiesToolEntry<BabySizeConverterUI> = {
37
- id: 'baby-size-converter',
38
- icons: { bg: 'mdi:tshirt-crew', fg: 'mdi:tshirt-crew-outline' },
39
- i18n: {
40
- es: () => import('./i18n/es').then((m) => m.content),
41
- en: () => import('./i18n/en').then((m) => m.content),
42
- de: () => import('./i18n/de').then((m) => m.content),
43
- fr: () => import('./i18n/fr').then((m) => m.content),
44
- it: () => import('./i18n/it').then((m) => m.content),
45
- pt: () => import('./i18n/pt').then((m) => m.content),
46
- nl: () => import('./i18n/nl').then((m) => m.content),
47
- pl: () => import('./i18n/pl').then((m) => m.content),
48
- ru: () => import('./i18n/ru').then((m) => m.content),
49
- tr: () => import('./i18n/tr').then((m) => m.content),
50
- sv: () => import('./i18n/sv').then((m) => m.content),
51
- id: () => import('./i18n/id').then((m) => m.content),
52
- ja: () => import('./i18n/ja').then((m) => m.content),
53
- ko: () => import('./i18n/ko').then((m) => m.content),
54
- zh: () => import('./i18n/zh').then((m) => m.content),
55
- },
56
- };
57
-
58
- export { BabySizeConverterComponent, BabySizeConverterSEO, BabySizeConverterBibliography };
59
-
1
+ import { babySizeConverter } from './entry';
2
+ export * from './entry';
60
3
  export const BABY_SIZE_CONVERTER_TOOL: ToolDefinition = {
61
4
  entry: babySizeConverter,
62
- Component: BabySizeConverterComponent,
63
- SEOComponent: BabySizeConverterSEO,
64
- BibliographyComponent: BabySizeConverterBibliography,
5
+ Component: () => import('./component.astro'),
6
+ SEOComponent: () => import('./seo.astro'),
7
+ BibliographyComponent: () => import('./bibliography.astro'),
65
8
  };
@@ -0,0 +1,47 @@
1
+ import type { BabiesToolEntry, ToolLocaleContent } from '../../types';
2
+
3
+ export interface FertileDaysEstimatorUI {
4
+ [key: string]: string;
5
+ step1Title: string;
6
+ step1Desc: string;
7
+ pulseHint: string;
8
+ step1Indicator: string;
9
+ step2Indicator: string;
10
+ sidebarTitle: string;
11
+ sidebarDesc: string;
12
+ labelCycleLength: string;
13
+ unitDays: string;
14
+ labelOvulation: string;
15
+ labelFertileWindow: string;
16
+ labelNextPeriod: string;
17
+ legendSelection: string;
18
+ legendPeriod: string;
19
+ legendFertile: string;
20
+ legendOvulation: string;
21
+ faqTitle: string;
22
+ bibliographyTitle: string;
23
+ }
24
+
25
+ export type FertileDaysEstimatorLocaleContent = ToolLocaleContent<FertileDaysEstimatorUI>;
26
+
27
+ export const fertileDaysEstimator: BabiesToolEntry<FertileDaysEstimatorUI> = {
28
+ id: 'fertile-days-estimator',
29
+ icons: { bg: 'mdi:calendar-heart', fg: 'mdi:calendar-heart' },
30
+ i18n: {
31
+ es: () => import('./i18n/es').then((m) => m.content),
32
+ en: () => import('./i18n/en').then((m) => m.content),
33
+ de: () => import('./i18n/de').then((m) => m.content),
34
+ fr: () => import('./i18n/fr').then((m) => m.content),
35
+ it: () => import('./i18n/it').then((m) => m.content),
36
+ pt: () => import('./i18n/pt').then((m) => m.content),
37
+ nl: () => import('./i18n/nl').then((m) => m.content),
38
+ pl: () => import('./i18n/pl').then((m) => m.content),
39
+ ru: () => import('./i18n/ru').then((m) => m.content),
40
+ tr: () => import('./i18n/tr').then((m) => m.content),
41
+ sv: () => import('./i18n/sv').then((m) => m.content),
42
+ id: () => import('./i18n/id').then((m) => m.content),
43
+ ja: () => import('./i18n/ja').then((m) => m.content),
44
+ ko: () => import('./i18n/ko').then((m) => m.content),
45
+ zh: () => import('./i18n/zh').then((m) => m.content),
46
+ },
47
+ };
@@ -1,59 +1,8 @@
1
- import type { BabiesToolEntry, ToolDefinition, ToolLocaleContent } from '../../types';
2
- import FertileDaysEstimatorComponent from './component.astro';
3
- import FertileDaysEstimatorSEO from './seo.astro';
4
- import FertileDaysEstimatorBibliography from './bibliography.astro';
5
-
6
- export interface FertileDaysEstimatorUI {
7
- [key: string]: string;
8
- step1Title: string;
9
- step1Desc: string;
10
- pulseHint: string;
11
- step1Indicator: string;
12
- step2Indicator: string;
13
- sidebarTitle: string;
14
- sidebarDesc: string;
15
- labelCycleLength: string;
16
- unitDays: string;
17
- labelOvulation: string;
18
- labelFertileWindow: string;
19
- labelNextPeriod: string;
20
- legendSelection: string;
21
- legendPeriod: string;
22
- legendFertile: string;
23
- legendOvulation: string;
24
- faqTitle: string;
25
- bibliographyTitle: string;
26
- }
27
-
28
- export type FertileDaysEstimatorLocaleContent = ToolLocaleContent<FertileDaysEstimatorUI>;
29
-
30
- export const fertileDaysEstimator: BabiesToolEntry<FertileDaysEstimatorUI> = {
31
- id: 'fertile-days-estimator',
32
- icons: { bg: 'mdi:calendar-heart', fg: 'mdi:calendar-heart' },
33
- i18n: {
34
- es: () => import('./i18n/es').then((m) => m.content),
35
- en: () => import('./i18n/en').then((m) => m.content),
36
- de: () => import('./i18n/de').then((m) => m.content),
37
- fr: () => import('./i18n/fr').then((m) => m.content),
38
- it: () => import('./i18n/it').then((m) => m.content),
39
- pt: () => import('./i18n/pt').then((m) => m.content),
40
- nl: () => import('./i18n/nl').then((m) => m.content),
41
- pl: () => import('./i18n/pl').then((m) => m.content),
42
- ru: () => import('./i18n/ru').then((m) => m.content),
43
- tr: () => import('./i18n/tr').then((m) => m.content),
44
- sv: () => import('./i18n/sv').then((m) => m.content),
45
- id: () => import('./i18n/id').then((m) => m.content),
46
- ja: () => import('./i18n/ja').then((m) => m.content),
47
- ko: () => import('./i18n/ko').then((m) => m.content),
48
- zh: () => import('./i18n/zh').then((m) => m.content),
49
- },
50
- };
51
-
52
- export { FertileDaysEstimatorComponent, FertileDaysEstimatorSEO, FertileDaysEstimatorBibliography };
53
-
1
+ import { fertileDaysEstimator } from './entry';
2
+ export * from './entry';
54
3
  export const FERTILE_DAYS_ESTIMATOR_TOOL: ToolDefinition = {
55
4
  entry: fertileDaysEstimator,
56
- Component: FertileDaysEstimatorComponent,
57
- SEOComponent: FertileDaysEstimatorSEO,
58
- BibliographyComponent: FertileDaysEstimatorBibliography,
5
+ Component: () => import('./component.astro'),
6
+ SEOComponent: () => import('./seo.astro'),
7
+ BibliographyComponent: () => import('./bibliography.astro'),
59
8
  };
@@ -0,0 +1,87 @@
1
+ import type { BabiesToolEntry, ToolLocaleContent } from '../../types';
2
+
3
+ export interface MilestoneI18n {
4
+ analogies: { fruits: string; geek: string; sweets: string };
5
+ size: string;
6
+ biolook: string;
7
+ mom: string;
8
+ partner: string;
9
+ symptoms: string[];
10
+ alerts: string[];
11
+ wonder: string;
12
+ }
13
+
14
+ export interface PregnancyCalculatorUI {
15
+ [key: string]: string;
16
+ btnFUR: string;
17
+ btnConception: string;
18
+ labelPartnerMode: string;
19
+ labelFUR: string;
20
+ labelConception: string;
21
+ labelCycleLength: string;
22
+ unitDays: string;
23
+ labelWeeks: string;
24
+ labelTrimester: string;
25
+ labelEDD: string;
26
+ eddPlaceholder: string;
27
+ eddNote: string;
28
+ btnCalendar: string;
29
+ labelFruits: string;
30
+ labelGeek: string;
31
+ labelSweets: string;
32
+ labelBioLabel: string;
33
+ labelMomKey: string;
34
+ labelPartnerKey: string;
35
+ labelNormalMolestias: string;
36
+ labelAlert: string;
37
+ labelTimeline: string;
38
+ labelStartHere: string;
39
+ labelStartBody: string;
40
+ labelSem: string;
41
+ labelWeekBadge: string;
42
+ weeksFormat: string;
43
+ trimesterSuffix: string;
44
+ eggFutureTitle: string;
45
+ eggFutureBody: string;
46
+ eggTooOldTitle: string;
47
+ eggTooOldBody: string;
48
+ faqTitle: string;
49
+ bibliographyTitle: string;
50
+ dayLabel: string;
51
+ monthLabel: string;
52
+ yearLabel: string;
53
+ icsSummary: string;
54
+ icsDescription: string;
55
+ icsFilename: string;
56
+ monthsData: string;
57
+ milestonesData: string;
58
+ timelineLabelsData: string;
59
+ }
60
+
61
+ export type PregnancyCalculatorLocaleContent = ToolLocaleContent<PregnancyCalculatorUI>;
62
+
63
+
64
+
65
+
66
+
67
+ export const pregnancyCalculator: BabiesToolEntry<PregnancyCalculatorUI> = {
68
+ id: 'pregnancy-calculator',
69
+ icons: { bg: 'mdi:human-pregnant', fg: 'mdi:calendar-heart' },
70
+ i18n: {
71
+ de: () => import('./i18n/de').then((m) => m.content),
72
+ en: () => import('./i18n/en').then((m) => m.content),
73
+ es: () => import('./i18n/es').then((m) => m.content),
74
+ fr: () => import('./i18n/fr').then((m) => m.content),
75
+ id: () => import('./i18n/id').then((m) => m.content),
76
+ it: () => import('./i18n/it').then((m) => m.content),
77
+ ja: () => import('./i18n/ja').then((m) => m.content),
78
+ ko: () => import('./i18n/ko').then((m) => m.content),
79
+ nl: () => import('./i18n/nl').then((m) => m.content),
80
+ pl: () => import('./i18n/pl').then((m) => m.content),
81
+ pt: () => import('./i18n/pt').then((m) => m.content),
82
+ ru: () => import('./i18n/ru').then((m) => m.content),
83
+ sv: () => import('./i18n/sv').then((m) => m.content),
84
+ tr: () => import('./i18n/tr').then((m) => m.content),
85
+ zh: () => import('./i18n/zh').then((m) => m.content),
86
+ },
87
+ };
@@ -1,99 +1,8 @@
1
- import type { BabiesToolEntry, ToolDefinition, ToolLocaleContent } from '../../types';
2
- import PregnancyCalculatorComponent from './component.astro';
3
- import PregnancyCalculatorSEO from './seo.astro';
4
- import PregnancyCalculatorBibliography from './bibliography.astro';
5
-
6
- export interface MilestoneI18n {
7
- analogies: { fruits: string; geek: string; sweets: string };
8
- size: string;
9
- biolook: string;
10
- mom: string;
11
- partner: string;
12
- symptoms: string[];
13
- alerts: string[];
14
- wonder: string;
15
- }
16
-
17
- export interface PregnancyCalculatorUI {
18
- [key: string]: string;
19
- btnFUR: string;
20
- btnConception: string;
21
- labelPartnerMode: string;
22
- labelFUR: string;
23
- labelConception: string;
24
- labelCycleLength: string;
25
- unitDays: string;
26
- labelWeeks: string;
27
- labelTrimester: string;
28
- labelEDD: string;
29
- eddPlaceholder: string;
30
- eddNote: string;
31
- btnCalendar: string;
32
- labelFruits: string;
33
- labelGeek: string;
34
- labelSweets: string;
35
- labelBioLabel: string;
36
- labelMomKey: string;
37
- labelPartnerKey: string;
38
- labelNormalMolestias: string;
39
- labelAlert: string;
40
- labelTimeline: string;
41
- labelStartHere: string;
42
- labelStartBody: string;
43
- labelSem: string;
44
- labelWeekBadge: string;
45
- weeksFormat: string;
46
- trimesterSuffix: string;
47
- eggFutureTitle: string;
48
- eggFutureBody: string;
49
- eggTooOldTitle: string;
50
- eggTooOldBody: string;
51
- faqTitle: string;
52
- bibliographyTitle: string;
53
- dayLabel: string;
54
- monthLabel: string;
55
- yearLabel: string;
56
- icsSummary: string;
57
- icsDescription: string;
58
- icsFilename: string;
59
- monthsData: string;
60
- milestonesData: string;
61
- timelineLabelsData: string;
62
- }
63
-
64
- export type PregnancyCalculatorLocaleContent = ToolLocaleContent<PregnancyCalculatorUI>;
65
-
66
-
67
-
68
-
69
-
70
- export const pregnancyCalculator: BabiesToolEntry<PregnancyCalculatorUI> = {
71
- id: 'pregnancy-calculator',
72
- icons: { bg: 'mdi:human-pregnant', fg: 'mdi:calendar-heart' },
73
- i18n: {
74
- de: () => import('./i18n/de').then((m) => m.content),
75
- en: () => import('./i18n/en').then((m) => m.content),
76
- es: () => import('./i18n/es').then((m) => m.content),
77
- fr: () => import('./i18n/fr').then((m) => m.content),
78
- id: () => import('./i18n/id').then((m) => m.content),
79
- it: () => import('./i18n/it').then((m) => m.content),
80
- ja: () => import('./i18n/ja').then((m) => m.content),
81
- ko: () => import('./i18n/ko').then((m) => m.content),
82
- nl: () => import('./i18n/nl').then((m) => m.content),
83
- pl: () => import('./i18n/pl').then((m) => m.content),
84
- pt: () => import('./i18n/pt').then((m) => m.content),
85
- ru: () => import('./i18n/ru').then((m) => m.content),
86
- sv: () => import('./i18n/sv').then((m) => m.content),
87
- tr: () => import('./i18n/tr').then((m) => m.content),
88
- zh: () => import('./i18n/zh').then((m) => m.content),
89
- },
90
- };
91
-
92
- export { PregnancyCalculatorComponent, PregnancyCalculatorSEO, PregnancyCalculatorBibliography };
93
-
1
+ import { pregnancyCalculator } from './entry';
2
+ export * from './entry';
94
3
  export const PREGNANCY_CALCULATOR_TOOL: ToolDefinition = {
95
4
  entry: pregnancyCalculator,
96
- Component: PregnancyCalculatorComponent,
97
- SEOComponent: PregnancyCalculatorSEO,
98
- BibliographyComponent: PregnancyCalculatorBibliography,
5
+ Component: () => import('./component.astro'),
6
+ SEOComponent: () => import('./seo.astro'),
7
+ BibliographyComponent: () => import('./bibliography.astro'),
99
8
  };
@@ -0,0 +1,67 @@
1
+ import type { BabiesToolEntry, ToolLocaleContent } from '../../types';
2
+
3
+ export interface VaccinationCalendarUI {
4
+ [key: string]: string;
5
+ labelBirthDate: string;
6
+ placeholderDD: string;
7
+ placeholderMM: string;
8
+ placeholderAAAA: string;
9
+ emptyMsg: string;
10
+ invalidMsg: string;
11
+ futureMsg: string;
12
+ labelNextAppointment: string;
13
+ btnAddReminder: string;
14
+ btnToday: string;
15
+ labelPassed: string;
16
+ labelFuture: string;
17
+ labelStatusOk: string;
18
+ labelStatusPending: string;
19
+ labelSource: string;
20
+ labelShare: string;
21
+ faqTitle: string;
22
+ bibliographyTitle: string;
23
+ labelMonth: string;
24
+ labelMonths: string;
25
+ labelYear: string;
26
+ labelYears: string;
27
+ labelDay: string;
28
+ labelDays: string;
29
+ labelAnd: string;
30
+ labelVaccination: string;
31
+ labelAppointment: string;
32
+ vac_hexavalente: string;
33
+ vac_neumococo: string;
34
+ vac_meningococo_b: string;
35
+ vac_rotavirus: string;
36
+ vac_meningococo_acwy: string;
37
+ vac_triple_virica: string;
38
+ vac_varicela: string;
39
+ vac_gripe: string;
40
+ vac_vph: string;
41
+ vac_tdpa: string;
42
+ vac_polio_booster: string;
43
+ }
44
+
45
+ export type VaccinationCalendarLocaleContent = ToolLocaleContent<VaccinationCalendarUI>;
46
+
47
+ export const vaccinationCalendar: BabiesToolEntry<VaccinationCalendarUI> = {
48
+ id: 'vaccination-calendar',
49
+ icons: { bg: 'mdi:needle', fg: 'mdi:needle' },
50
+ i18n: {
51
+ de: () => import('./i18n/de').then((m) => m.content),
52
+ en: () => import('./i18n/en').then((m) => m.content),
53
+ es: () => import('./i18n/es').then((m) => m.content),
54
+ fr: () => import('./i18n/fr').then((m) => m.content),
55
+ id: () => import('./i18n/id').then((m) => m.content),
56
+ it: () => import('./i18n/it').then((m) => m.content),
57
+ ja: () => import('./i18n/ja').then((m) => m.content),
58
+ ko: () => import('./i18n/ko').then((m) => m.content),
59
+ nl: () => import('./i18n/nl').then((m) => m.content),
60
+ pl: () => import('./i18n/pl').then((m) => m.content),
61
+ pt: () => import('./i18n/pt').then((m) => m.content),
62
+ ru: () => import('./i18n/ru').then((m) => m.content),
63
+ sv: () => import('./i18n/sv').then((m) => m.content),
64
+ tr: () => import('./i18n/tr').then((m) => m.content),
65
+ zh: () => import('./i18n/zh').then((m) => m.content),
66
+ },
67
+ };
@@ -1,79 +1,8 @@
1
- import type { BabiesToolEntry, ToolDefinition, ToolLocaleContent } from '../../types';
2
- import VaccinationCalendarComponent from './component.astro';
3
- import VaccinationCalendarSEO from './seo.astro';
4
- import VaccinationCalendarBibliography from './bibliography.astro';
5
-
6
- export interface VaccinationCalendarUI {
7
- [key: string]: string;
8
- labelBirthDate: string;
9
- placeholderDD: string;
10
- placeholderMM: string;
11
- placeholderAAAA: string;
12
- emptyMsg: string;
13
- invalidMsg: string;
14
- futureMsg: string;
15
- labelNextAppointment: string;
16
- btnAddReminder: string;
17
- btnToday: string;
18
- labelPassed: string;
19
- labelFuture: string;
20
- labelStatusOk: string;
21
- labelStatusPending: string;
22
- labelSource: string;
23
- labelShare: string;
24
- faqTitle: string;
25
- bibliographyTitle: string;
26
- labelMonth: string;
27
- labelMonths: string;
28
- labelYear: string;
29
- labelYears: string;
30
- labelDay: string;
31
- labelDays: string;
32
- labelAnd: string;
33
- labelVaccination: string;
34
- labelAppointment: string;
35
- vac_hexavalente: string;
36
- vac_neumococo: string;
37
- vac_meningococo_b: string;
38
- vac_rotavirus: string;
39
- vac_meningococo_acwy: string;
40
- vac_triple_virica: string;
41
- vac_varicela: string;
42
- vac_gripe: string;
43
- vac_vph: string;
44
- vac_tdpa: string;
45
- vac_polio_booster: string;
46
- }
47
-
48
- export type VaccinationCalendarLocaleContent = ToolLocaleContent<VaccinationCalendarUI>;
49
-
50
- export const vaccinationCalendar: BabiesToolEntry<VaccinationCalendarUI> = {
51
- id: 'vaccination-calendar',
52
- icons: { bg: 'mdi:needle', fg: 'mdi:needle' },
53
- i18n: {
54
- de: () => import('./i18n/de').then((m) => m.content),
55
- en: () => import('./i18n/en').then((m) => m.content),
56
- es: () => import('./i18n/es').then((m) => m.content),
57
- fr: () => import('./i18n/fr').then((m) => m.content),
58
- id: () => import('./i18n/id').then((m) => m.content),
59
- it: () => import('./i18n/it').then((m) => m.content),
60
- ja: () => import('./i18n/ja').then((m) => m.content),
61
- ko: () => import('./i18n/ko').then((m) => m.content),
62
- nl: () => import('./i18n/nl').then((m) => m.content),
63
- pl: () => import('./i18n/pl').then((m) => m.content),
64
- pt: () => import('./i18n/pt').then((m) => m.content),
65
- ru: () => import('./i18n/ru').then((m) => m.content),
66
- sv: () => import('./i18n/sv').then((m) => m.content),
67
- tr: () => import('./i18n/tr').then((m) => m.content),
68
- zh: () => import('./i18n/zh').then((m) => m.content),
69
- },
70
- };
71
-
72
- export { VaccinationCalendarComponent, VaccinationCalendarSEO, VaccinationCalendarBibliography };
73
-
1
+ import { vaccinationCalendar } from './entry';
2
+ export * from './entry';
74
3
  export const VACCINATION_CALENDAR_TOOL: ToolDefinition = {
75
4
  entry: vaccinationCalendar,
76
- Component: VaccinationCalendarComponent,
77
- SEOComponent: VaccinationCalendarSEO,
78
- BibliographyComponent: VaccinationCalendarBibliography,
5
+ Component: () => import('./component.astro'),
6
+ SEOComponent: () => import('./seo.astro'),
7
+ BibliographyComponent: () => import('./bibliography.astro'),
79
8
  };
package/src/tools.ts CHANGED
@@ -1,3 +1,4 @@
1
+ export { ALL_ENTRIES } from './entries';
1
2
  import type { ToolDefinition } from './types';
2
3
  import { BABY_FEEDING_CALCULATOR_TOOL } from './tool/baby-feeding-calculator/index';
3
4
  import { BABY_SIZE_CONVERTER_TOOL } from './tool/baby-size-converter/index';
@@ -16,4 +17,3 @@ export const ALL_TOOLS: ToolDefinition[] = [
16
17
  ];
17
18
 
18
19
 
19
- export const ALL_ENTRIES = ALL_TOOLS.map(t => t.entry);