Skip to content

Commit

Permalink
add some description of the dir mixin
Browse files Browse the repository at this point in the history
  • Loading branch information
dfreedm committed Oct 11, 2017
1 parent 624189a commit f98ad11
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion lib/mixins/dir-mixin.html
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,19 @@
}

/**
* Some stuff about :dir
* Element class mixin that allows elements to use the `:dir` CSS Selector to have
* text direction specific styling.
*
* With this mixin, any stylesheet provided in the template will be transform `:dir` into
* `:host([dir])` and sync direction with the page via the element's `dir` attribute.
*
* Elements can opt out of the global page text direction by setting the `dir` attribute
* directly in `ready()`.
*
* Caveats:
* - Automatic left-to-right or right-to-left styling is sync'd with the `<html>` element
* - Applications must set `<html dir="ltr">` or `<html dir="rtl">` to sync direction
* - Opting out of the global direction styling is permanent
*
* @mixinFunction
* @polymer
Expand Down

0 comments on commit f98ad11

Please sign in to comment.