commit fd642acdd2b979336044688af20c25ff7ce98ee8
parent 4e397be8d9358c226c70f89647ce59d6b755b6e0
Author: triesap <137732411+triesap@users.noreply.github.com>
Date: Wed, 13 Nov 2024 09:03:38 +0000
apps-lib: add/edit locales, fix i18n locales files
Diffstat:
3 files changed, 107 insertions(+), 108 deletions(-)
diff --git a/apps-lib/src/lib/locales/en/icu.json b/apps-lib/src/lib/locales/en/icu.json
@@ -59,10 +59,10 @@
"show_*": "Show {value}",
"the_*": "The {value}",
"the_*_is_available": "The {value} is available",
- "the_*_is_missing": "The {value} is missing",
- "the_*_is_required": "The {value} is missing",
"the_*_is_incomplete": "The {value} is incomplete",
+ "the_*_is_missing": "The {value} is missing",
"the_*_is_registered": "The {value} is registered",
+ "the_*_is_required": "The {value} is missing",
"the_current_entry_*_will_be_deleted": "The current entry \"{value}\" will be deleted",
"this_*": "This {value}",
"total_*": "Total {value}",
diff --git a/apps-lib/src/lib/locales/en/models.json b/apps-lib/src/lib/locales/en/models.json
@@ -1,17 +1,17 @@
{
"location_gcs": {
"fields": {
- "lat": {
- "label": "Location Latitude"
+ "gc_admin1_id": {
+ "label": "Location Gc Admin1 Id"
},
- "lng": {
- "label": "Location Latitude"
+ "gc_admin1_name": {
+ "label": "Location Gc Admin1 Name"
},
- "geohash": {
- "label": "Location Geohash"
+ "gc_country_id": {
+ "label": "Location Gc Country Id"
},
- "label": {
- "label": "Location Label"
+ "gc_country_name": {
+ "label": "Location Gc Country Name"
},
"gc_id": {
"label": "Location Gc Id"
@@ -19,110 +19,109 @@
"gc_name": {
"label": "Location Gc Name"
},
- "gc_admin1_id": {
- "label": "Location Gc Admin1 Id"
+ "geohash": {
+ "label": "Location Geohash"
},
- "gc_admin1_name": {
- "label": "Location Gc Admin1 Name"
+ "label": {
+ "label": "Location Label"
},
- "gc_country_id": {
- "label": "Location Gc Country Id"
+ "lat": {
+ "label": "Location Latitude"
},
- "gc_country_name": {
- "label": "Location Gc Country Name"
+ "lng": {
+ "label": "Location Latitude"
}
},
"schema": {
- "lat.required": "The location latitude is required",
- "lat.min": "The location latitude must be greater than -90",
+ "geohash.length": "The location geohash must be 12 characters",
+ "geohash.required": "The location geohash is required",
"lat.max": "The location latitude must be less than 90",
- "lng.required": "The location latitude is required",
- "lng.min": "The location latitude must be greater than -180",
+ "lat.min": "The location latitude must be greater than -90",
+ "lat.required": "The location latitude is required",
"lng.max": "The location latitude must be less than 180",
- "geohash.required": "The location geohash is required",
- "geohash.min": "The location geohash must be more than 7 characters",
- "geohash.max": "The location geohash must be less than 12 characters"
+ "lng.min": "The location latitude must be greater than -180",
+ "lng.required": "The location latitude is required"
}
},
"nostr_profile": {
"fields": {
- "public_key": {
- "label": "Profile Public Key"
- },
- "name": {
- "label": "Profile Name"
- },
- "display_name": {
- "label": "Profile Display Name"
- },
"about": {
"label": "Profile About"
},
- "website": {
- "label": "Profile Website"
- },
- "picture": {
- "label": "Profile Picture"
- },
"banner": {
"label": "Profile Banner"
},
- "nip05": {
- "label": "Profile Nip-05"
+ "display_name": {
+ "label": "Profile Display Name"
},
"lud06": {
"label": "Profile Lud-06"
},
"lud16": {
"label": "Profile Lud-16"
+ },
+ "name": {
+ "label": "Profile Name"
+ },
+ "nip05": {
+ "label": "Profile Nip-05"
+ },
+ "picture": {
+ "label": "Profile Picture"
+ },
+ "public_key": {
+ "label": "Profile Public Key"
+ },
+ "website": {
+ "label": "Profile Website"
}
},
"schema": {
- "public_key.required": "The profile public key is required",
- "public_key.length": "The profile public key must be 64 characters",
- "website.url": "The profile website url is incomplete",
- "picture.url": "The profile picture url is incomplete",
"banner.url": "The profile banner url is incomplete",
- "nip05.email": "The profile nip-05 is incorrectly formatted"
+ "nip05.email": "The profile nip-05 is incorrectly formatted",
+ "picture.url": "The profile picture url is incomplete",
+ "public_key.length": "The profile public key must be 64 characters",
+ "public_key.required": "The profile public key is required",
+ "website.url": "The profile website url is incomplete"
}
},
"nostr_relay": {
"fields": {
- "url": {
- "label": "Relay Endpoint"
- },
- "relay_id": {
- "label": "Relay Id"
+ "contact": {
+ "label": "Administrator Contact"
},
- "name": {
- "label": "Relay Name"
+ "data": {
+ "label": "Additional Information"
},
"description": {
"label": "Relay Description"
},
+ "name": {
+ "label": "Relay Name"
+ },
"pubkey": {
"label": "Administrator"
},
- "contact": {
- "label": "Administrator Contact"
+ "relay_id": {
+ "label": "Relay Id"
+ },
+ "software": {
+ "label": "Software"
},
"supported_nips": {
"label": "Supported Nips"
},
- "software": {
- "label": "Software"
+ "url": {
+ "label": "Relay Endpoint"
},
"version": {
"label": "Software Version"
- },
- "data": {
- "label": "Additional Information"
}
},
"schema": {
+ "url.regex": "The relay relay endpoint requires a websocket protocol",
"url.required": "The relay relay endpoint is required",
- "url.url": "The relay relay endpoint is incorrectly formatted",
- "url.regex": "The relay relay endpoint requires a websocket protocol"
+ "url.url": "The relay relay endpoint is incorrectly formatted"
}
},
"trade_product": {
@@ -130,78 +129,78 @@
"key": {
"label": "Product Kind"
},
- "title": {
- "label": "Product Title"
+ "lot": {
+ "label": "Product Lot"
},
- "summary": {
- "label": "Product Description"
+ "notes": {
+ "label": "Notes"
+ },
+ "price_amt": {
+ "label": "Price Amount"
+ },
+ "price_currency": {
+ "label": "Price Currency"
+ },
+ "price_qty_amt": {
+ "label": "Price Quantity"
+ },
+ "price_qty_unit": {
+ "label": "Price Quantity Unit"
},
"process": {
"label": "Processing Method"
},
- "lot": {
- "label": "Product Lot"
- },
"profile": {
"label": "Flavor Profile"
},
- "year": {
- "label": "Production Year"
- },
"qty_amt": {
"label": "Quantity Amount"
},
- "qty_unit": {
- "label": "Quantity Unit"
- },
- "qty_label": {
- "label": "Quantity Name"
- },
"qty_avail": {
"label": "Quantity Available"
},
- "price_amt": {
- "label": "Price Amount"
+ "qty_label": {
+ "label": "Quantity Name"
},
- "price_currency": {
- "label": "Price Currency"
+ "qty_unit": {
+ "label": "Quantity Unit"
},
- "price_qty_amt": {
- "label": "Price Quantity"
+ "summary": {
+ "label": "Product Description"
},
- "price_qty_unit": {
- "label": "Price Quantity Unit"
+ "title": {
+ "label": "Product Title"
},
- "notes": {
- "label": "Notes"
+ "year": {
+ "label": "Production Year"
}
},
"schema": {
"key.required": "The product kind is required",
- "title.required": "The product title is required",
- "summary.required": "The product description is required",
- "process.required": "The product processing method is required",
- "lot.required": "The product lot is required",
- "lot.min": "The product lot must be more than 1 character",
"lot.max": "The product lot must be less than 120 characters",
+ "lot.min": "The product lot must be more than 1 character",
+ "lot.required": "The product lot is required",
+ "price_amt.positive": "The product price amount must be positive",
+ "price_amt.required": "The product price amount is required",
+ "price_currency.length": "The product price currency must be 3 characters",
+ "price_currency.required": "The product price currency is required",
+ "price_qty_amt.int": "The product price quantity must be an integer",
+ "price_qty_amt.positive": "The product price quantity must be positive",
+ "price_qty_amt.required": "The product price quantity is required",
+ "price_qty_unit.required": "The product price quantity unit is required",
+ "process.required": "The product processing method is required",
"profile.required": "The product flavor profile is required",
- "year.required": "The product production year is required",
- "year.int": "The product production year must be an integer",
- "year.positive": "The product production year must be positive",
- "qty_amt.required": "The product quantity amount is required",
"qty_amt.int": "The product quantity amount must be an integer",
"qty_amt.positive": "The product quantity amount must be positive",
- "qty_unit.required": "The product quantity unit is required",
+ "qty_amt.required": "The product quantity amount is required",
"qty_avail.int": "The product quantity available must be an integer",
"qty_avail.positive": "The product quantity available must be positive",
- "price_amt.required": "The product price amount is required",
- "price_amt.positive": "The product price amount must be positive",
- "price_currency.required": "The product price currency is required",
- "price_currency.length": "The product price currency must be 3 characters",
- "price_qty_amt.required": "The product price quantity is required",
- "price_qty_amt.int": "The product price quantity must be an integer",
- "price_qty_amt.positive": "The product price quantity must be positive",
- "price_qty_unit.required": "The product price quantity unit is required"
+ "qty_unit.required": "The product quantity unit is required",
+ "summary.required": "The product description is required",
+ "title.required": "The product title is required",
+ "year.int": "The product production year must be an integer",
+ "year.positive": "The product production year must be positive",
+ "year.required": "The product production year is required"
}
}
}
\ No newline at end of file
diff --git a/apps-lib/src/lib/locales/i18n.ts b/apps-lib/src/lib/locales/i18n.ts
@@ -10,7 +10,7 @@ type LanguageConfig = {
value?: string;
};
-const locales_files = [`app`, `common`, `currency`, `error`, `eula`, `icu`, `measurement`, `model`, `radroots-org`, `trade`] as const;
+const locales_files = [`app`, `common`, `currency`, `error`, `eula`, `icu`, `measurement`, `models`, `radroots-org`, `trade`] as const;
const translations_keys: Record<Locale, any> = {
en: { locales_keys },
};