Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add RTL support #4

Open
cdils opened this issue Jul 3, 2014 · 4 comments
Open

Add RTL support #4

cdils opened this issue Jul 3, 2014 · 4 comments

Comments

@cdils
Copy link
Owner

cdils commented Jul 3, 2014

No description provided.

@nirrosenbaum
Copy link

Just added an rtl.css file to the in-the-beginning theme.
It should be included in the same location of the theme style.css file and its name must be rtl.css.
Wordpress loads this file automatically when an RTL language is detected.

@cdils
Copy link
Owner Author

cdils commented Aug 29, 2014

Leaving this issue open - see comments on this pull request.

@nirrosenbaum
Copy link

I am familiar with CSSJanus (and I know Yoav, the developer) but this tool does 80% of the job (at least for Genesis style sheets).
I am reading the article that you sent and maybe there is a way to increase the accuracy of the output of this tool but there is no way as far as I can tell that it is going to be 100% accurate.

Some of the issues that require special attention (and probably need to do them manually):

  1. Rules that you do not want to convert. For example, in Genesis, there are rules for the containers (i.e. .content, .content_sidebar_wrap etc') with float: right/left. I realized (and talked about it with Nick (the geek) a long time ago) that since that the layout can be set in the admin area (Genesis -> Theme Settings), it is better to leave the css rules the same for LTR/RTL sites.
    As I am reading the article that you sent, perhaps it is just a matter of adding specific comments above these classes in order to direct the cssjanus plugin to not convert them (?)

2.Rules that in the rtl version are composed from different classes - for example -
.genesis-nav-menu > .last > a
in the ltr version:
.genesis-nav-menu > .last > a {
padding-right: 0;
}
in the rtl version:
.genesis-nav-menu > .last > a {
padding-left: 0;
padding-right: 24px;
}
The padding-right: 24px; is taken from a different class....

This is not an issue if you are replacing the style.css with a RTLed css but it is an issue if you have the original ltr style sheet and the rtl style sheet (with just the required overrides).

  1. There is a problem with trying to use just one css for your style (if I understand what the suggestions are in the article) - I have many multi language sites - I need both the ltr and the rtl support..
    Maybe I am not familiar enough with Grunt and its capabilities, but there should be a way to maintain the theme styles for multi language sites...

Next week, I am going to have a Skype call with Gary Jones about adding RTL support to genesis, If you wish to join it would be great...

Meanwhile, If you know what I should do (instead of what I have done), please advice.

Thanks much :)
Nir

@cdils
Copy link
Owner Author

cdils commented Aug 29, 2014

Thanks, Nir. I would love to be a fly one the wall for that Skype session.

You have a ton more practical experience where RTL is concerned. My hope is to automate where possible so that every LTR-related CSS change doesn't result in a manual update of the RTL styles.

Good point also about certain elements pulling styles from multiple classes. If we can improve the original styes to avoid this, by all means, I am open.

cdils pushed a commit that referenced this issue Oct 30, 2014
References #4
Added CSSJanus and GruntCSSJanus to auto-update style-rtl.css any time
style.css is compiled.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants