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.
Add RTL Support to Jekyll Theme Chirpy
Type of change
Description
This PR adds comprehensive Right-to-Left (RTL) language support to the Chirpy theme. It enables the theme to automatically detect RTL languages and apply appropriate styling, making it accessible to users of Arabic, Hebrew, Persian, Urdu, and other RTL languages.
The implementation:
langattributeKey components:
lang.htmlto detect RTL languagesrtl.scsswith comprehensive RTL stylingrtl-fonts.scssfor language-specific fontsNew Files
_sass/rtl.scss: Contains RTL-specific styles for layout and UI elements_sass/rtl-fonts.scss: Defines and applies language-specific fonts for RTL languages_includes/rtl-font-loader.html: HTML-based font loader for faster RTL font loading_data/locales/*: Locale files as reference implementationfa-IR.yml: Persian (Modified)ku-IQ.yml: Kurdish(Sorani)ur-PK.yml: Urdups-AF.yml: Pashtodv-MV.yml: Dhivehidocs/RTL-SUPPORT.md: Documentation for RTL supportModified Files
_sass/main.scss: Added import for rtl.scss_includes/lang.html: Added RTL detection logic_layouts/default.html: Added dir attribute to HTML tag_config.yml: Added RTL configuration optionsThis change enhances accessibility for millions of users worldwide who read and write in RTL languages without affecting any existing functionality.
Additional context
This implements a non-breaking enhancement that makes the theme more accessible to global users.
Note: The implementation requires a small addition to
head.htmlto include the RTL font loader, which I've documented in the PR.