feat(i18n): localize inventory assets UI
This commit is contained in:
@@ -408,6 +408,110 @@ describe("i18n dictionaries", () => {
|
||||
})
|
||||
})
|
||||
|
||||
it("provides localized inventory asset UI copy for English and Spanish", () => {
|
||||
expect(getDictionary("en").inventory.assets).toEqual({
|
||||
list: {
|
||||
title: "Assets",
|
||||
addLabel: "Add Asset",
|
||||
empty: "No assets found.",
|
||||
columns: {
|
||||
item: "Item",
|
||||
category: "Category",
|
||||
serialNumber: "Serial Number",
|
||||
status: "Status",
|
||||
actions: "Actions",
|
||||
},
|
||||
actions: {
|
||||
edit: "Edit asset",
|
||||
},
|
||||
},
|
||||
new: {
|
||||
title: "New Asset",
|
||||
},
|
||||
edit: {
|
||||
title: "Edit Asset",
|
||||
notFound: "Asset not found",
|
||||
},
|
||||
form: {
|
||||
itemLabel: "Item",
|
||||
itemPlaceholder: "Select an item",
|
||||
serialNumberLabel: "Serial Number",
|
||||
serialNumberPlaceholder: "Serial number",
|
||||
deliveryNoteLabel: "Delivery Note",
|
||||
deliveryNotePlaceholder: "Delivery note",
|
||||
statusLabel: "Status",
|
||||
statusPlaceholder: "Select a status",
|
||||
recipientLabel: "Recipient",
|
||||
recipientPlaceholder: "Select a recipient",
|
||||
createSubmit: "Create Asset",
|
||||
updateSubmit: "Update Asset",
|
||||
},
|
||||
status: {
|
||||
AVAILABLE: "Available",
|
||||
ASSIGNED: "Assigned",
|
||||
RESERVED: "Reserved",
|
||||
IN_REPAIR: "In repair",
|
||||
BROKEN: "Broken",
|
||||
STOLEN: "Stolen",
|
||||
DISPOSED: "Disposed",
|
||||
},
|
||||
fallback: {
|
||||
unknownStatus: "Unknown status",
|
||||
},
|
||||
})
|
||||
|
||||
expect(getDictionary("es").inventory.assets).toEqual({
|
||||
list: {
|
||||
title: "Activos",
|
||||
addLabel: "Agregar activo",
|
||||
empty: "No se encontraron activos.",
|
||||
columns: {
|
||||
item: "Artículo",
|
||||
category: "Categoría",
|
||||
serialNumber: "Número de serie",
|
||||
status: "Estado",
|
||||
actions: "Acciones",
|
||||
},
|
||||
actions: {
|
||||
edit: "Editar activo",
|
||||
},
|
||||
},
|
||||
new: {
|
||||
title: "Nuevo activo",
|
||||
},
|
||||
edit: {
|
||||
title: "Editar activo",
|
||||
notFound: "Activo no encontrado",
|
||||
},
|
||||
form: {
|
||||
itemLabel: "Artículo",
|
||||
itemPlaceholder: "Selecciona un artículo",
|
||||
serialNumberLabel: "Número de serie",
|
||||
serialNumberPlaceholder: "Número de serie",
|
||||
deliveryNoteLabel: "Remito",
|
||||
deliveryNotePlaceholder: "Remito",
|
||||
statusLabel: "Estado",
|
||||
statusPlaceholder: "Selecciona un estado",
|
||||
recipientLabel: "Destinatario",
|
||||
recipientPlaceholder: "Selecciona un destinatario",
|
||||
createSubmit: "Crear activo",
|
||||
updateSubmit: "Actualizar activo",
|
||||
},
|
||||
status: {
|
||||
AVAILABLE: "Disponible",
|
||||
ASSIGNED: "Asignado",
|
||||
RESERVED: "Reservado",
|
||||
IN_REPAIR: "En reparación",
|
||||
BROKEN: "Roto",
|
||||
STOLEN: "Robado",
|
||||
DISPOSED: "Dado de baja",
|
||||
},
|
||||
fallback: {
|
||||
unknownStatus: "Estado desconocido",
|
||||
},
|
||||
})
|
||||
})
|
||||
|
||||
it("keeps dashboard home dictionary keys aligned across locales", () => {
|
||||
expect(getDictionary("en").dashboardHome).toEqual({
|
||||
heading: "Dashboard",
|
||||
|
||||
Reference in New Issue
Block a user