Spree extension for rtl layout
Last updated on: June 05 at 09:46 AM
source code bug trackerThis is a Spree extension to provide Right to left layout for rtl languages such as Arabic, Persian, Urdu, and others.
Add spree_rtl to your Gemfile:
gem 'spree_rtl'
Bundle your dependencies and run the installation generator:
bundle
bundle exec rails g spree_rtl:install
add the folowing to every locale you want to be directed left to right:
Assuming locale is Arabic, open the /config/locales/ar.yml or created if it does not exist and add dir: "rtl"
Please note that if you just created an empty file, you need to add ar: at the very top of the file.
First bundle your dependencies, then run rake. rake will default to building the dummy app if it does not exist, then it will run specs. The dummy app can be regenerated by using rake test_app.
bundle
bundle exec rake
When testing your applications integration with this extension you may use it's factories. Simply add this require statement to your spec_helper:
require 'spree_rtl/factories'
ltrwhen not being defined in locale.
Copyright (c) 2014 Aman Alshurafa, released under the New BSD License