Skip to content

Commit bf61d4d

Browse files
heiskrCopilot
andauthored
Fix admin landing page scrape failures for ja, ru, zh (#62356)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: c3853c47-4ddf-4c80-bca4-bdd2c865aaf4
1 parent df5f56a commit bf61d4d

1 file changed

Lines changed: 37 additions & 0 deletions

File tree

src/languages/lib/correct-translation-content.ts

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -526,6 +526,18 @@ export function correctTranslatedContentStrings(
526526
'{% endif %} 上で{% endif %}エンタープライズとの通信を実行できるように Okta を構成する方法を学習します。',
527527
'{% endif %} 上でエンタープライズとの通信を実行できるように Okta を構成する方法を学習します。',
528528
)
529+
530+
// [SCRAPE-6759] admin/managing-iam/iam-configuration-reference/username-considerations-for-external-authentication.md
531+
// (intro): the second conditional block was scrambled — `{% endif %}`,
532+
// `{% elsif ghes %}` and `{% ifversion ghec %}` ended up out of order, leaving
533+
// an orphan `endif` and a never-closed `ifversion`. This breaks the admin
534+
// landing page render (`tag "endif" not found`). Reconstruct to match English:
535+
// determine the username for each user account {% ifversion ghec %}in your
536+
// enterprise{% elsif ghes %}on your instance{% endif %}. Prose preserved.
537+
content = content.replaceAll(
538+
'は一定のルールに従って、インスタンス{% endif %}上のエンタープライズ{% elsif ghes %}内の各ユーザーアカウント{% ifversion ghec %}のユーザー名を決定します。',
539+
'は一定のルールに従って、{% ifversion ghec %}エンタープライズ内{% elsif ghes %}インスタンス上{% endif %}の各ユーザーアカウントのユーザー名を決定します。',
540+
)
529541
}
530542

531543
if (context.code === 'pt') {
@@ -918,6 +930,18 @@ export function correctTranslatedContentStrings(
918930
'企业中 {% data variables.product.github %}{% elsif ghes %} 上 {% data variables.location.product_location %}{% endif %} 上每个新个人帐户 {% ifversion ghec %} 的用户名。',
919931
'{% ifversion ghec %}企业中 {% data variables.product.github %}{% elsif ghes %} 上 {% data variables.location.product_location %}{% endif %} 上每个新个人帐户的用户名。',
920932
)
933+
934+
// [SCRAPE-6759] admin/managing-iam/iam-configuration-reference/username-considerations-for-external-authentication.md
935+
// (intro): the second conditional block was scrambled — `{% endif %}`,
936+
// `{% elsif ghes %}` and `{% ifversion ghec %}` ended up out of order, leaving
937+
// an orphan `endif` and a never-closed `ifversion`. This breaks the admin
938+
// landing page render (`tag "endif" not found`). Reconstruct to match English:
939+
// determine the username for each user account {% ifversion ghec %}in your
940+
// enterprise{% elsif ghes %}on your instance{% endif %}. Prose preserved.
941+
content = content.replaceAll(
942+
'会按照特定规则确定您实例{% endif %}上您企业{% elsif ghes %}中各个用户帐户{% ifversion ghec %}的用户名。',
943+
'会按照特定规则确定{% ifversion ghec %}您企业中{% elsif ghes %}您实例上{% endif %}各个用户帐户的用户名。',
944+
)
921945
}
922946

923947
if (context.code === 'ru') {
@@ -1274,6 +1298,19 @@ export function correctTranslatedContentStrings(
12741298
'связанную личность, активные сессии и авторизованные учетные{% else %}данные {% ifversion ghec %}SAML{% endif %}',
12751299
'{% ifversion ghec %}связанную личность, активные сессии и авторизованные учетные данные{% else %}активные сессии SAML{% endif %}',
12761300
)
1301+
1302+
// [SCRAPE-6759] admin/managing-iam/understanding-iam-for-enterprises/about-saml-for-enterprise-iam.md
1303+
// (intro): the `{% ifversion ghec %}...{% elsif ghes %}...{% endif %}` block was
1304+
// scrambled — `{% endif %}` was placed before `{% elsif ghes %}` and the final
1305+
// `{% endif %}` was dropped, leaving an orphan `elsif`. This breaks the admin
1306+
// landing page render (`tag "elsif" not found`). Reconstruct to match English:
1307+
// centrally manage access {% ifversion ghec %}to organizations owned by your
1308+
// enterprise on {% data ...dotcom_the_website %}{% elsif ghes %}to
1309+
// {% data ...product_location %}{% endif %}. Prose preserved.
1310+
content = content.replaceAll(
1311+
'доступом {% ifversion ghec %}к организациям, принадлежащим вашей организации{% endif %}{% data variables.product.prodname_dotcom_the_website %}{% elsif ghes %}{% data variables.location.product_location %}.',
1312+
'доступом {% ifversion ghec %}к организациям, принадлежащим вашей организации на {% data variables.product.prodname_dotcom_the_website %}{% elsif ghes %}к {% data variables.location.product_location %}{% endif %}.',
1313+
)
12771314
}
12781315

12791316
if (context.code === 'fr') {

0 commit comments

Comments
 (0)