Introduce a hand-rolled i18n layer across all three UIs, each reading its
text from per-language JSON files (English base + Polish + Danish). Nothing
in the converted screens hardcodes English any more.
- Web App (Vue): src/i18n/{en,pl,da}.json + index.js exposing t()/tSplit(),
reactive to the signed-in profile locale. Every view, component, form and
the status labels in lib/format.js go through t().
- API Server panel (Vue): src/i18n/ with its own localStorage-persisted
language (the panel has no user profile) and a header language picker.
Chrome, cards, login and API section titles translated; endpoint reference
descriptions intentionally kept in English. Rebuilt embedded dist.
- Phone App (Flutter): assets/i18n/ + lib/i18n.dart loaded at startup,
driven by AppSettings.locale. Nav, login, lock, dashboard, the full
Settings panel (incl. language picker) and format.dart status labels
translated; remaining detail screens fall back to English.
Language = the language half of the existing BCP-47 locale; the region half
still drives date/number/currency formatting. Missing keys fall back to
English, and plurals use Intl.PluralRules / Intl.plural so Polish gets the
correct one/few/many forms. Settings flags languages without a translation.
Tests updated to assert the localized (Polish) status wording; all pass.
See TRANSLATIONS.md for the format and how to add a language.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
47 lines
1.2 KiB
YAML
47 lines
1.2 KiB
YAML
name: carcontrol_phone
|
|
description: "DriverVault — car control & service-tracking phone app."
|
|
publish_to: "none"
|
|
version: 0.1.0+1
|
|
|
|
environment:
|
|
sdk: ">=3.4.0 <4.0.0"
|
|
|
|
dependencies:
|
|
flutter:
|
|
sdk: flutter
|
|
http: ^1.2.0
|
|
shared_preferences: ^2.2.0
|
|
intl: ^0.19.0
|
|
cupertino_icons: ^1.0.8
|
|
image_picker: ^1.1.2
|
|
# Attachments are PDFs as well as images, which image_picker cannot offer.
|
|
file_picker: ^10.1.2
|
|
# Opens a downloaded attachment with whatever viewer the phone has for it.
|
|
open_filex: ^4.5.0
|
|
path_provider: ^2.1.4
|
|
local_auth: ^2.3.0
|
|
local_auth_android: ^1.0.46
|
|
flutter_secure_storage: ^9.2.2
|
|
google_fonts: ^6.2.1
|
|
|
|
dev_dependencies:
|
|
flutter_test:
|
|
sdk: flutter
|
|
flutter_lints: ^4.0.0
|
|
flutter_launcher_icons: ^0.14.1
|
|
|
|
flutter:
|
|
uses-material-design: true
|
|
# Per-language UI translation files, read at runtime by lib/i18n.dart.
|
|
assets:
|
|
- assets/i18n/
|
|
|
|
# DriverVault launcher icon — regenerate with:
|
|
# flutter pub run flutter_launcher_icons
|
|
flutter_launcher_icons:
|
|
android: true
|
|
image_path: "assets/icon/drivervault.png"
|
|
min_sdk_android: 21
|
|
adaptive_icon_background: "#1E40AF"
|
|
adaptive_icon_foreground: "assets/icon/drivervault-fg.png"
|