Skip to content

Commit e5910c3

Browse files
authored
Add ActionMenu translations to Storybook (#1127)
* port changes from the other branch * regen snapshots * revert some debugging * add snapshots * update snapshots again * increased timeout on the stories * remove vrt on open menu action menu stories * remove redundant snapshots * remove another story
1 parent e8aa805 commit e5910c3

File tree

115 files changed

+290
-421
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

115 files changed

+290
-421
lines changed
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"select_github_feature": "Eine GitHub-Funktion auswählen",
3+
"github_features": "GitHub-Funktionen",
4+
"select_country": "Ein Land auswählen",
5+
"countries": "Länder",
6+
"select_location": "Einen Standort auswählen",
7+
"locations": "Standorte",
8+
"select_size": "Eine Größe auswählen",
9+
"advanced_security": "Erweiterte Sicherheit",
10+
"open_menu": "Menü öffnen",
11+
"install_copilot_vscode": "Copilot in Visual Studio Code installieren",
12+
"alternative_options": "Alternative Optionen",
13+
"alternative_editors": "Alternative Editoren",
14+
"see_plans_pricing": "Pläne und Preise anzeigen",
15+
"label": "Bezeichnung",
16+
"actions": "Aktionen",
17+
"copy_link": "Link kopieren",
18+
"quote_reply": "Antwort zitieren",
19+
"edit_comment": "Kommentar bearbeiten",
20+
"europe_middle_east_africa": "Europa, Naher Osten und Afrika",
21+
"americas": "Amerika",
22+
"asia_pacific": "Asien-Pazifik",
23+
"hero_heading": "Das ist meine super süße Hero-Überschrift"
24+
}
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"select_github_feature": "Select a GitHub feature",
3+
"github_features": "GitHub features",
4+
"select_country": "Select a country",
5+
"countries": "Countries",
6+
"select_location": "Select a location",
7+
"locations": "Locations",
8+
"select_size": "Select a size",
9+
"advanced_security": "Advanced Security",
10+
"open_menu": "Open menu",
11+
"install_copilot_vscode": "Install Copilot in Visual Studio Code",
12+
"alternative_options": "Alternative options",
13+
"alternative_editors": "Alternative editors",
14+
"see_plans_pricing": "See plans & pricing",
15+
"label": "Label",
16+
"actions": "Actions",
17+
"copy_link": "Copy link",
18+
"quote_reply": "Quote reply",
19+
"edit_comment": "Edit comment",
20+
"europe_middle_east_africa": "Europe, Middle East and Africa",
21+
"americas": "Americas",
22+
"asia_pacific": "Asia Pacific",
23+
"hero_heading": "This is my super sweet hero heading"
24+
}
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"select_github_feature": "Seleccionar una función de GitHub",
3+
"github_features": "Funciones de GitHub",
4+
"select_country": "Seleccionar un país",
5+
"countries": "Países",
6+
"select_location": "Seleccionar una ubicación",
7+
"locations": "Ubicaciones",
8+
"select_size": "Seleccionar un tamaño",
9+
"advanced_security": "Seguridad Avanzada",
10+
"open_menu": "Abrir menú",
11+
"install_copilot_vscode": "Instalar Copilot en Visual Studio Code",
12+
"alternative_options": "Opciones alternativas",
13+
"alternative_editors": "Editores alternativos",
14+
"see_plans_pricing": "Ver planes y precios",
15+
"label": "Etiqueta",
16+
"actions": "Acciones",
17+
"copy_link": "Copiar enlace",
18+
"quote_reply": "Citar respuesta",
19+
"edit_comment": "Editar comentario",
20+
"europe_middle_east_africa": "Europa, Medio Oriente y África",
21+
"americas": "Américas",
22+
"asia_pacific": "Asia Pacífico",
23+
"hero_heading": "Este es mi increíble encabezado de héroe"
24+
}
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"select_github_feature": "Sélectionner une fonctionnalité GitHub",
3+
"github_features": "Fonctionnalités GitHub",
4+
"select_country": "Sélectionner un pays",
5+
"countries": "Pays",
6+
"select_location": "Sélectionner un emplacement",
7+
"locations": "Emplacements",
8+
"select_size": "Sélectionner une taille",
9+
"advanced_security": "Sécurité Avancée",
10+
"open_menu": "Ouvrir le menu",
11+
"install_copilot_vscode": "Installer Copilot dans Visual Studio Code",
12+
"alternative_options": "Options alternatives",
13+
"alternative_editors": "Éditeurs alternatifs",
14+
"see_plans_pricing": "Voir les plans et tarifs",
15+
"label": "Étiquette",
16+
"actions": "Actions",
17+
"copy_link": "Copier le lien",
18+
"quote_reply": "Citer la réponse",
19+
"edit_comment": "Modifier le commentaire",
20+
"europe_middle_east_africa": "Europe, Moyen-Orient et Afrique",
21+
"americas": "Amériques",
22+
"asia_pacific": "Asie-Pacifique",
23+
"hero_heading": "Voici mon formidable titre de héros"
24+
}
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"select_github_feature": "GitHub機能を選択",
3+
"github_features": "GitHub機能",
4+
"select_country": "国を選択",
5+
"countries": "",
6+
"select_location": "場所を選択",
7+
"locations": "場所",
8+
"select_size": "サイズを選択",
9+
"advanced_security": "アドバンスドセキュリティ",
10+
"open_menu": "メニューを開く",
11+
"install_copilot_vscode": "Visual Studio CodeにCopilotをインストール",
12+
"alternative_options": "代替オプション",
13+
"alternative_editors": "代替エディタ",
14+
"see_plans_pricing": "プランと料金を見る",
15+
"label": "ラベル",
16+
"actions": "アクション",
17+
"copy_link": "リンクをコピー",
18+
"quote_reply": "返信を引用",
19+
"edit_comment": "コメントを編集",
20+
"europe_middle_east_africa": "ヨーロッパ、中東、アフリカ",
21+
"americas": "アメリカ大陸",
22+
"asia_pacific": "アジア太平洋",
23+
"hero_heading": "これは私の素晴らしいヒーロー見出しです"
24+
}
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"select_github_feature": "Selecionar um recurso do GitHub",
3+
"github_features": "Recursos do GitHub",
4+
"select_country": "Selecionar um país",
5+
"countries": "Países",
6+
"select_location": "Selecionar uma localização",
7+
"locations": "Localizações",
8+
"select_size": "Selecionar um tamanho",
9+
"advanced_security": "Segurança Avançada",
10+
"open_menu": "Abrir menu",
11+
"install_copilot_vscode": "Instalar Copilot no Visual Studio Code",
12+
"alternative_options": "Opções alternativas",
13+
"alternative_editors": "Editores alternativos",
14+
"see_plans_pricing": "Ver planos e preços",
15+
"label": "Rótulo",
16+
"actions": "Ações",
17+
"copy_link": "Copiar link",
18+
"quote_reply": "Citar resposta",
19+
"edit_comment": "Editar comentário",
20+
"europe_middle_east_africa": "Europa, Oriente Médio e África",
21+
"americas": "Américas",
22+
"asia_pacific": "Ásia-Pacífico",
23+
"hero_heading": "Este é meu incrível título de herói"
24+
}

package-lock.json

Lines changed: 10 additions & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/e2e/scripts/playwright/playwright.generate-tests.ts

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,9 @@
5959
'components-actionmenu-features--longer-lists-open': 1000, // for the menu to open
6060
'components-actionmenu-features--menu-alignment': 1000, // for the menu to open
6161
'components-actionmenu-features--disabled-item': 1000, // flakey test,
62+
'components-actionmenu-features--single-selection-small-open': 1000, // for the menu to open
63+
'components-actionmenu-features--split-button-alternative-menu-alignment': 1000, // for the menu to open
64+
'components-actionmenu-features--anchored-positioning': 1000, // for the menu to open
6265
'components-box-features--animation': 6000, // for the animation
6366
'components-ide--playground': 2000, // for the animation
6467
'components-ide--default': 2000, // for the animation
@@ -110,6 +113,15 @@
110113
'components-subnav-features--anchor-nav-variant': 1000, // for being flakey across translations
111114
}
112115

116+
const skipLocalizationsTestsFor = [
117+
'components-actionmenu-features--open-by-default', // for the menu to open
118+
'components-actionmenu-features--menu-alignment', // for the menu to open
119+
'components-actionmenu-features--disabled-item', // for the menu to open
120+
'components-actionmenu-features--single-selection-small-open', // for the menu to open
121+
'components-actionmenu-features--split-button-alternative-menu-alignment', // for the menu to open
122+
'components-actionmenu-features--anchored-positioning', // for the menu to open
123+
]
124+
113125
/**
114126
* Manual lookup for tests that we want to skip
115127
* Only add tests here that aren't suitable for visual regression testing
@@ -119,6 +131,7 @@
119131
'components-river--custom-logos', // for external social imagery to load
120132
'components-actionmenu-features--keyboard-navigation', // interaction test
121133
'components-actionmenu-examples--keyboard-navigation', // for the interaction test
134+
'components-actionmenu-features--split-button-mode-open', // for the translations causing layout shift
122135
'components-animations-examples--discussions-hero', // animation only
123136
'components-animations-examples--progress-bars', // animation only
124137
'components-animations-examples--logo-bar', // animation only
@@ -220,7 +233,9 @@
220233
`
221234
}
222235
223-
const allLanguageTests = languages.map(language => generateTestForLanguage(language)).join('')
236+
const shouldSkipLocalizations = skipLocalizationsTestsFor.includes(id)
237+
const languagesToTest = shouldSkipLocalizations ? ['en'] : languages
238+
const allLanguageTests = languagesToTest.map(language => generateTestForLanguage(language)).join('')
224239
225240
if (requiresMobileViewport) {
226241
return (acc += `

0 commit comments

Comments
 (0)