docs(site): add i18n concept, guides, and API reference#1600
Open
sampotts wants to merge 6 commits into
Open
Conversation
Documents opaque keys, registry APIs, React/HTML providers, and locale workflows for #1373. Extends api-docs-builder discovery for core/react i18n exports and adds matching reference MDX pages. Co-authored-by: Cursor <cursoragent@cursor.com>
Add Locale, BuiltInLocale, TranslationParams, Translations, and Translator reference pages plus createTranslator. Cross-link types from concept and guides; fix React examples and register-locale satisfies pattern. Co-authored-by: Cursor <cursoragent@cursor.com>
Document registerI18n pre-caching at bootstrap and before switch, compare with I18nProvider translations prop, and note global merge behavior. Co-authored-by: Cursor <cursoragent@cursor.com>
Remove frameworkTitle overrides so the i18n concept page matches other concept pages with one title across HTML and React modes. Co-authored-by: Cursor <cursoragent@cursor.com>
Group I18nProvider with Player.Provider and Player.Container as infrastructure providers; keep createI18n and hooks under Hooks & Utilities. Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This was referenced May 26, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #1373
Summary
Adds site documentation for the Video.js 10 i18n system: concept page, how-to guides, API/util reference pages, and sidebar wiring. Stacks on the i18n implementation branch (
feat/i18n-sandbox).Changes
registerI18npre-cache patterns), SSR, and contributor built-in locale workflowI18nProvider, hooks, HTML elements,createI18n, and core types (Locale,Translations,Translator, etc.)I18nProviderlisted under Components (alongsidePlayer.Provider); hooks and factories stay under Hooks & UtilitiesStack info
Docs PR — targets
feat/i18n-sandbox(#1593). Merge after the i18n implementation stack lands, or merge into the stack before the sandbox PR if preferred.Testing
Verify pages under Concepts → Internationalization, How to → i18n guides, and Features / Components / Hooks reference sections.
Made with Cursor
Note
Low Risk
Documentation and doc-generation/export surface only; no changes to i18n resolution, registry merge, or provider runtime logic.
Overview
This PR adds site documentation for Video.js 10 internationalization: a Concepts → Internationalization page, five how-to guides (register locale, overrides, runtime switch, SSR, contributor built-in locales), and reference pages for registry APIs, React
I18nProvider/hooks, HTMLmedia-i18n-provider/media-text, and core types.Sidebar entries in
docs.config.tswire those pages under Concepts, How to, Components, Hooks & Utilities, Controllers & Mixins, and Features (including a Types subsection).Supporting code (not new i18n behavior):
@publicJSDoc on core registry/translator exports; React defaultI18nProvider/ hooks exported fromcreate-i18n.tsxwith a slimmeri18n/index.tsre-export; api-docs-builder scans@videojs/react/i18nand@videojs/core/i18n, fixes kebab slugs forI18n*names, and normalizes multi-part JSDoc descriptions for generated util reference JSON.Reviewed by Cursor Bugbot for commit e2d03df. Bugbot is set up for automated code reviews on this repo. Configure here.