Merged in feat/syncDefaultMessage (pull request #3022)

Sync defaultMessage from lokalise

* Enhance translation sync functionality and tests

- Added logging for found component files during sync.
- Introduced tests for handling complex components with replacements.
- Updated regex in syncIntlFormatMessage to support optional second arguments.
- Removed unused test files.

* feat(syncDefaultMessage): add script for syncing default message with lokalise

* feat(syncDefaultMessage): add script for syncing default message with lokalise


Approved-by: Matilda Landström
This commit is contained in:
Joakim Jäderberg
2025-10-30 08:38:50 +00:00
parent 3962ecd858
commit bf6ed7778e
48 changed files with 316 additions and 197 deletions

View File

@@ -38,7 +38,7 @@ export function Promos({ booking }: PromosProps) {
<Promo
buttonText={intl.formatMessage({
id: "bookingConfirmation.promos.buyAddonsButtonText",
defaultMessage: "View and buy add-ons",
defaultMessage: "View and buy extras",
})}
href={myStayURL}
text={intl.formatMessage({

View File

@@ -96,7 +96,7 @@ export default function FilterAndSortModal({
{
label: intl.formatMessage({
id: "common.tripAdvisorRating",
defaultMessage: "TripAdvisor rating",
defaultMessage: "Tripadvisor rating",
}),
value: SortOrder.TripAdvisorRating,
},

View File

@@ -78,7 +78,7 @@ export default function HotelSorter({ discreet }: HotelSorterProps) {
{
label: intl.formatMessage({
id: "common.tripAdvisorRating",
defaultMessage: "TripAdvisor rating",
defaultMessage: "Tripadvisor rating",
}),
value: SortOrder.TripAdvisorRating,
},

View File

@@ -63,7 +63,8 @@ export default function BreakfastAccordionItem({
<p>
{intl.formatMessage({
id: "breakfastAccordion.allDayBreakfast",
defaultMessage: "All-day breakfast",
defaultMessage:
"Grab our Brekkie Deal for 69 SEK coffee & sandwich, available 6 AMnoon.",
})}
</p>
</Typography>

View File

@@ -8,7 +8,8 @@
"lint": "eslint . --max-warnings 0 && tsc --noEmit",
"lint:fix": "eslint . --fix && tsc --noEmit",
"test": "vitest run --passWithNoTests",
"test:watch": "vitest"
"test:watch": "vitest",
"format": "prettier --write ."
},
"exports": {
"./BookingFlowConfig": "./lib/bookingFlowConfig/bookingFlowConfig.tsx",

View File

@@ -1,8 +0,0 @@
module.exports = {
semi: false,
trailingComma: "es5",
singleQuote: false,
printWidth: 80,
tabWidth: 2,
endOfLine: "lf",
}

View File

@@ -0,0 +1,14 @@
/**
* @see https://prettier.io/docs/configuration
* @type {import("prettier").Config}
*/
const config = {
semi: false,
trailingComma: "es5",
singleQuote: false,
printWidth: 80,
tabWidth: 2,
endOfLine: "lf",
}
export default config