mirror of
https://github.com/morluto/rea
synced 2026-10-26 06:16:17 -04:00
docs(readme): add Roman Urdu edition (#6499)
* docs(readme): add Roman Urdu edition
Register ur-Latn with a pending website catalog and preserve English command examples.
Script-tag handling follows morluto's shared helper proposed in PR #2043 (c46f606c89).
* test(website): cover completed script-tag page metadata
This commit is contained in:
@@ -11,6 +11,7 @@ import xml.etree.ElementTree as ET
|
||||
from zipfile import BadZipFile, ZipFile
|
||||
|
||||
from website import NOTES_FIXTURES, SITE_ORIGIN, authored_markdown, page_url, sync_pages
|
||||
from website_i18n import is_language_code
|
||||
|
||||
LEGACY_ORIGIN = "morluto.github.io"
|
||||
SITE_TEXT_URL = re.compile(
|
||||
@@ -179,7 +180,7 @@ def check_search_metadata(site, pages):
|
||||
if not title:
|
||||
errors.append(f"{label}: needs exactly one nonempty head title")
|
||||
first = path.relative_to(site).parts[0]
|
||||
expected_language = first if re.fullmatch(r"[a-z]{2}(?:-[A-Z]{2})?", first) else "en"
|
||||
expected_language = first if is_language_code(first) else "en"
|
||||
if page.translation_fallback:
|
||||
if page.lang != "en" or not page.noindex():
|
||||
errors.append(f"{label}: English translation fallback needs lang=en and noindex")
|
||||
|
||||
Reference in New Issue
Block a user