Components / Direction

Direction

An LTR and RTL context directive for directional components.

واجهة من اليمين إلى اليسار
example.component.html
html
<section aevkoDirection="rtl">
  ...
</section>

Installation

npx aevko-ui@latest add direction --yes

Source ownership

Customization

Apply the directive at the narrowest shared boundary. Descendants inherit the native dir attribute and can still use logical CSS properties.

Edit locallyThe installed template and stylesheet are application code, not a black box.
Theme semanticallyOverride --aevko-* tokens or ordinary classes without !important.

API reference

Property or slotTypeDefaultDescription
aevkoDirection'ltr' | 'rtl''ltr'Writes the native dir attribute on the host.
AEVKO_DIRECTIONInjectionToken<Signal>'ltr'Exposes the inherited direction to descendants.

Accessibility contract

Accessibility

Included behavior

  • The directive writes the native dir attribute so browser text and keyboard behavior inherit correctly.

Your responsibility

Set direction from actual language/content context rather than using RTL as a visual mirroring shortcut.

Back to all components