logical-properties
What it does
This skill updates CSS that uses fixed directions, such as left and right, to logical properties that follow the reading direction. It is for developers who want their sites to support more than one language.
When to use it
- ✓When you ask the agent to prepare a stylesheet for right-to-left languages.
- ✓When you are adding support for Arabic, Hebrew, or Persian and the layout looks wrong in those languages.
- ✓When you review CSS and want to replace margin-left and similar properties with versions that adapt automatically.
Skill link
https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/logical-properties/SKILL.mdCopy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.
How to use
The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.
Ready-to-paste message
For Claude Code, Codex or Cursor: run it in your project folder and the skill gets installed.
Download the SKILL.md and drop it into your agent’s skills folder.
Example of what to ask your AI
“Can you update my CSS so the layout works properly for Arabic and Hebrew readers?”
5 new skills a week. 1 minute to read.
How it works
The agent finds spacing and positioning rules that use fixed directions and swaps them for inline and block equivalents. The layout then flips automatically when the text direction changes.
Technical content (original SKILL.md)
Original text by the author, straight from GitHub.
Use CSS logical properties for i18n and RTL support
Physical CSS properties (margin-left, padding-right) are hardcoded to screen directions. In right-to-left languages (Arabic, Hebrew, Persian), what should be margin-left becomes margin-right. Without logical properties, supporting RTL requires maintaining duplicate stylesheets or complex overrides with [dir=rtl] selectors. Logical properties handle this automatically.
Quick Reference
- Logical properties adapt to writing direction — margin-inline-start is left in LTR, right in RTL
- Replace left/right margin and padding with inline-start/inline-end equivalents
- Replace top/bottom with block-start/block-end equivalents
- Logical properties also work correctly for vertical writing modes
Check
Find all uses of margin-left, margin-right, padding-left, padding-right, border-left, border-right, left, right (as positioning) that should be converted to logical equivalents.
Fix
Convert physical direction properties to their CSS logical property equivalents for RTL and internationalization support.
Explain
Explain CSS logical properties, the difference between physical and logical directions, and how they enable RTL language support.
Code Review
Review stylesheets, component styles, and responsive states related to Use CSS logical properties for i18n and RTL support. Flag exact selectors, declarations, or breakpoints that violate the rule in the rendered UI.
For full implementation details, code examples, and framework-specific guidance,
see references/rule.md.
Rule page: https://frontendchecklist.io/rules/css/logical-properties
FAQ
Do I still need separate styles for right-to-left?
Usually not. Logical properties handle the direction automatically, so duplicate stylesheets or extra overrides can often be avoided.
Do logical properties help with vertical text?
Yes. The skill notes that they also work correctly for vertical writing modes.
Should I check the layout after the change?
Yes. The skill advises checking the rendered layout across screen sizes and interaction states.
Details
Original description by the author
Use when reviewing stylesheets, component styles, and responsive behavior related to Use CSS logical properties for i18n and RTL support. Check the rendered layout across breakpoints and interaction states before proposing a fix.
Popularity
- GitHub stars
- 75k
- Ranking position
- #2931
- License
- MIT
- Updated
- 10/31/2026
Comments
- …
More skills from this repository
frontendchecklist
75kChecks frontend code and live pages against 380+ rules for accessibility, speed, SEO and security, using a command-line tool.
frontend-checklist-global
75kAudits a frontend project against all 386 Front-End Checklist rules, and gives a specific fix for each issue found.
404-page
75kChecks that your missing-page screen offers helpful links and returns a real 404 status, to help lost visitors find their way.
about-page
75kReviews whether your site has a clear About page that explains who runs it, to build trust with visitors and search engines.
Similar skills
angular-developer
280kHelps your agent create Angular code and give project structure advice. Useful for starting new projects, creating code parts, or improving performance and accessibility.
frontend-a11y
280kHelps your agent make web interfaces accessible to everyone. It ensures websites and apps work well with screen readers and keyboard navigation.
frontend-patterns
280kHas your agent apply modern patterns in frontend development. It optimizes performance, manages state, and follows best practices in React and Next.js.