From c2a2138b5a67cc1e8fc4ebd852f67353ec516975 Mon Sep 17 00:00:00 2001 From: Mohammad Younes Date: Sat, 1 Feb 2014 01:47:29 +0200 Subject: [PATCH 1/4] rtl hints --- server/files/stylesheets/semantic.css | 8 ++++++-- src/elements/basic.icon.less | 8 ++++++-- src/elements/icon.less | 25 ++++++++++++++++++++++++- src/modules/accordion.less | 2 +- src/modules/dropdown.less | 4 ++-- 5 files changed, 39 insertions(+), 8 deletions(-) diff --git a/server/files/stylesheets/semantic.css b/server/files/stylesheets/semantic.css index 805ffb86d..8f8702b29 100755 --- a/server/files/stylesheets/semantic.css +++ b/server/files/stylesheets/semantic.css @@ -44,7 +44,7 @@ body { } body#example { - font-family: "Open Sans", "Helvetica Neue", "Helvetica", "Arial", sans-serif; + font-family: "Open Sans", "Helvetica Neue", "Helvetica", "Arial", sans-serif/*rtl:"Droid Arabic Kufi", "Open Sans", "Helvetica Neue", "Helvetica", "Arial", sans-serif */; background: #FCFCFC url(../images/bg.jpg) repeat; margin: 0px; padding: 0px; @@ -60,7 +60,7 @@ h2, h3, h4, h5 { - font-family: "Source Sans Pro", "Helvetica Neue", "Helvetica", "Arial", sans-serif; + font-family: "Source Sans Pro", "Helvetica Neue", "Helvetica", "Arial", sans-serif/*rtl:"Droid Arabic Kufi", "Source Sans Pro", "Helvetica Neue", "Helvetica", "Arial", sans-serif */;; } /* @@ -93,12 +93,14 @@ h4 + p { pre { background-color: #F0F0F0; } +/*rtl:ignore*/ pre.console { background-color: transparent; line-height: 1.6; font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'source-code-pro', monospace; height: 300px; overflow: auto; + direction:ltr; } code { background-color: rgba(0, 0, 0, 0.02); @@ -863,11 +865,13 @@ body.guide .main.container > * { #example div.code.hide { display: none; } +/*rtl:ignore*/ #example div.code { position: relative; width: 100%; height: 200px; text-align: left; + direction:ltr; } #example div.code { margin: -1em; diff --git a/src/elements/basic.icon.less b/src/elements/basic.icon.less index 37d39f390..61ab1f3b8 100755 --- a/src/elements/basic.icon.less +++ b/src/elements/basic.icon.less @@ -77,13 +77,17 @@ i.basic.icon.resize.vertical:before { content: '\2b0c'; } /* '⬌' */ i.basic.icon.down:before { content: '\2193'; } /* '↓' */ i.basic.icon.down.triangle:before { content: '\25be'; } /* '▾' */ i.basic.icon.down.arrow:before { content: '\e75c'; } /* '' */ - +/*rtl:rename*/ i.basic.icon.left:before { content: '\2190'; } /* '←' */ +/*rtl:rename*/ i.basic.icon.left.triangle:before { content: '\25c2'; } /* '◂' */ +/*rtl:rename*/ i.basic.icon.left.arrow:before { content: '\e75d'; } /* '' */ - +/*rtl:rename*/ i.basic.icon.right:before { content: '\2192'; } /* '→' */ +/*rtl:rename*/ i.basic.icon.right.triangle:before { content: '\25b8'; } /* '▸' */ +/*rtl:rename*/ i.basic.icon.right.arrow:before { content: '\e75e'; } /* '' */ i.basic.icon.up:before { content: '\2191'; } /* '↑' */ diff --git a/src/elements/icon.less b/src/elements/icon.less index 376e4d163..d1f1c8863 100755 --- a/src/elements/icon.less +++ b/src/elements/icon.less @@ -70,8 +70,9 @@ i.icon { -moz-font-smoothing: antialiased; font-smoothing: antialiased; } - +/*rtl:rename*/ i.icon.left:before { content: "\f060"; } +/*rtl:rename*/ i.icon.right:before { content: "\f061"; } i.icon.add.sign.box:before { content: "\f0fe"; } @@ -81,22 +82,30 @@ i.icon.adjust:before { content: "\f042"; } i.icon.adn:before { content: "\f170"; } i.icon.align.center:before { content: "\f037"; } i.icon.align.justify:before { content: "\f039"; } +/*rtl:rename*/ i.icon.align.left:before { content: "\f036"; } +/*rtl:rename*/ i.icon.align.right:before { content: "\f038"; } i.icon.ambulance:before { content: "\f0f9"; } i.icon.anchor:before { content: "\f13d"; } i.icon.android:before { content: "\f17b"; } i.icon.angle.down:before { content: "\f107"; } +/*rtl:rename*/ i.icon.angle.left:before { content: "\f104"; } +/*rtl:rename*/ i.icon.angle.right:before { content: "\f105"; } i.icon.angle.up:before { content: "\f106"; } i.icon.apple:before { content: "\f179"; } i.icon.archive:before { content: "\f187"; } i.icon.arrow.down:before { content: "\f078"; } +/*rtl:rename*/ i.icon.arrow.left:before { content: "\f053"; } +/*rtl:rename*/ i.icon.arrow.right:before { content: "\f054"; } i.icon.arrow.sign.down:before { content: "\f13a"; } +/*rtl:rename*/ i.icon.arrow.sign.left:before { content: "\f137"; } +/*rtl:rename*/ i.icon.arrow.sign.right:before { content: "\f138"; } i.icon.arrow.sign.up:before { content: "\f139"; } i.icon.arrow.up:before { content: "\f077"; } @@ -132,7 +141,9 @@ i.icon.calendar:before { content: "\f073"; } i.icon.camera.retro:before { content: "\f083"; } i.icon.camera:before { content: "\f030"; } i.icon.triangle.down:before { content: "\f0d7"; } +/*rtl:rename*/ i.icon.triangle.left:before { content: "\f0d9"; } +/*rtl:rename*/ i.icon.triangle.right:before { content: "\f0da"; } i.icon.triangle.up:before { content: "\f0d8"; } i.icon.cart:before { content: "\f07a"; } @@ -146,7 +157,9 @@ i.icon.checkmark.sign:before { content: "\f14a"; } i.icon.checkmark:before { content: "\f00c"; } i.icon.circle.blank:before { content: "\f10c"; } i.icon.circle.down:before { content: "\f0ab"; } +/*rtl:rename*/ i.icon.circle.left:before { content: "\f0a8"; } +/*rtl:rename*/ i.icon.circle.right:before { content: "\f0a9"; } i.icon.circle.up:before { content: "\f0aa"; } i.icon.circle:before { content: "\f111"; } @@ -168,7 +181,9 @@ i.icon.desktop:before { content: "\f108"; } i.icon.doctor:before { content: "\f0f0"; } i.icon.dollar:before { content: "\f155"; } i.icon.double.angle.down:before { content: "\f103"; } +/*rtl:rename*/ i.icon.double.angle.left:before { content: "\f100"; } +/*rtl:rename*/ i.icon.double.angle.right:before { content: "\f101"; } i.icon.double.angle.up:before { content: "\f102"; } i.icon.down:before { content: "\f063"; } @@ -229,7 +244,9 @@ i.icon.google.plus.sign:before { content: "\f0d4"; } i.icon.google.plus:before { content: "\f0d5"; } i.icon.h.sign:before { content: "\f0fd"; } i.icon.hand.down:before { content: "\f0a7"; } +/*rtl:rename*/ i.icon.hand.left:before { content: "\f0a5"; } +/*rtl:rename*/ i.icon.hand.right:before { content: "\f0a4"; } i.icon.hand.up:before { content: "\f0a6"; } i.icon.hdd:before { content: "\f0a0"; } @@ -242,7 +259,9 @@ i.icon.home:before { content: "\f015"; } i.icon.hospital:before { content: "\f0f8"; } i.icon.html5:before { content: "\f13b"; } i.icon.inbox:before { content: "\f01c"; } +/*rtl:rename*/ i.icon.indent.left:before { content: "\f03b"; } +/*rtl:rename*/ i.icon.indent.right:before { content: "\f03c"; } i.icon.info.letter:before { content: "\f129"; } i.icon.info:before { content: "\f05a"; } @@ -272,7 +291,9 @@ i.icon.loading:before { content: "\f110"; } i.icon.location:before { content: "\f124"; } i.icon.lock:before { content: "\f023"; } i.icon.long.arrow.down:before { content: "\f175"; } +/*rtl:rename*/ i.icon.long.arrow.left:before { content: "\f177"; } +/*rtl:rename*/ i.icon.long.arrow.right:before { content: "\f178"; } i.icon.long.arrow.up:before { content: "\f176"; } i.icon.magic:before { content: "\f0d0"; } @@ -317,7 +338,9 @@ i.icon.print:before { content: "\f02f"; } i.icon.puzzle.piece:before { content: "\f12e"; } i.icon.qr.code:before { content: "\f029"; } i.icon.question:before { content: "\f128"; } +/*rtl:rename*/ i.icon.quote.left:before { content: "\f10d"; } +/*rtl:rename*/ i.icon.quote.right:before { content: "\f10e"; } i.icon.refresh:before { content: "\f021"; } i.icon.remove.circle:before { content: "\f05c"; } diff --git a/src/modules/accordion.less b/src/modules/accordion.less index 7be100169..e405d32a2 100755 --- a/src/modules/accordion.less +++ b/src/modules/accordion.less @@ -99,7 +99,7 @@ transform: rotate(0deg); } .ui.accordion .title .dropdown.icon:before { - content: '\f0da'; + content: '\f0da'/*rtl:'\f0d9'*/; } /*-------------- diff --git a/src/modules/dropdown.less b/src/modules/dropdown.less index a5446eae0..c94425d9a 100755 --- a/src/modules/dropdown.less +++ b/src/modules/dropdown.less @@ -103,7 +103,7 @@ margin: 0em 0em 0em 0.5em; } .ui.dropdown .menu .item .dropdown.icon:before { - content: "\f0da"; + content: "\f0da"/*rtl:"\f0d9"*/; } @@ -181,7 +181,7 @@ right: 0px; } .ui.vertical.menu .dropdown.item > .dropdown.icon:before { - content: "\f0da"; + content: "\f0da"/*rtl:"\f0d9"*/; } .ui.dropdown.icon.button > .dropdown.icon { margin: 0em; From 5c4a75ad95b9693c9f0bcf20bbd119472b06ce65 Mon Sep 17 00:00:00 2001 From: Mohammad Younes Date: Sat, 8 Feb 2014 23:04:20 +0200 Subject: [PATCH 2/4] Fewer hints the better The parser default now is to rename all classes having no bidirectional declarations unless ignored. --- server/files/stylesheets/semantic.css | 2 +- src/elements/basic.icon.less | 6 ------ src/elements/icon.less | 25 +------------------------ src/modules/modal.less | 3 +++ 4 files changed, 5 insertions(+), 31 deletions(-) diff --git a/server/files/stylesheets/semantic.css b/server/files/stylesheets/semantic.css index 8f8702b29..8f626fe4e 100755 --- a/server/files/stylesheets/semantic.css +++ b/server/files/stylesheets/semantic.css @@ -1327,7 +1327,7 @@ body.progress .ui.progress .bar { width: auto; margin: 0% 30px 0px; } - #example + /*rtl:ignore*/ #example .right.attached.launch { display: none; } diff --git a/src/elements/basic.icon.less b/src/elements/basic.icon.less index 61ab1f3b8..805f9861c 100755 --- a/src/elements/basic.icon.less +++ b/src/elements/basic.icon.less @@ -77,17 +77,11 @@ i.basic.icon.resize.vertical:before { content: '\2b0c'; } /* '⬌' */ i.basic.icon.down:before { content: '\2193'; } /* '↓' */ i.basic.icon.down.triangle:before { content: '\25be'; } /* '▾' */ i.basic.icon.down.arrow:before { content: '\e75c'; } /* '' */ -/*rtl:rename*/ i.basic.icon.left:before { content: '\2190'; } /* '←' */ -/*rtl:rename*/ i.basic.icon.left.triangle:before { content: '\25c2'; } /* '◂' */ -/*rtl:rename*/ i.basic.icon.left.arrow:before { content: '\e75d'; } /* '' */ -/*rtl:rename*/ i.basic.icon.right:before { content: '\2192'; } /* '→' */ -/*rtl:rename*/ i.basic.icon.right.triangle:before { content: '\25b8'; } /* '▸' */ -/*rtl:rename*/ i.basic.icon.right.arrow:before { content: '\e75e'; } /* '' */ i.basic.icon.up:before { content: '\2191'; } /* '↑' */ diff --git a/src/elements/icon.less b/src/elements/icon.less index d1f1c8863..44b2fc3e0 100755 --- a/src/elements/icon.less +++ b/src/elements/icon.less @@ -70,9 +70,7 @@ i.icon { -moz-font-smoothing: antialiased; font-smoothing: antialiased; } -/*rtl:rename*/ i.icon.left:before { content: "\f060"; } -/*rtl:rename*/ i.icon.right:before { content: "\f061"; } i.icon.add.sign.box:before { content: "\f0fe"; } @@ -82,30 +80,22 @@ i.icon.adjust:before { content: "\f042"; } i.icon.adn:before { content: "\f170"; } i.icon.align.center:before { content: "\f037"; } i.icon.align.justify:before { content: "\f039"; } -/*rtl:rename*/ i.icon.align.left:before { content: "\f036"; } -/*rtl:rename*/ i.icon.align.right:before { content: "\f038"; } i.icon.ambulance:before { content: "\f0f9"; } i.icon.anchor:before { content: "\f13d"; } i.icon.android:before { content: "\f17b"; } i.icon.angle.down:before { content: "\f107"; } -/*rtl:rename*/ i.icon.angle.left:before { content: "\f104"; } -/*rtl:rename*/ i.icon.angle.right:before { content: "\f105"; } i.icon.angle.up:before { content: "\f106"; } i.icon.apple:before { content: "\f179"; } i.icon.archive:before { content: "\f187"; } i.icon.arrow.down:before { content: "\f078"; } -/*rtl:rename*/ i.icon.arrow.left:before { content: "\f053"; } -/*rtl:rename*/ i.icon.arrow.right:before { content: "\f054"; } i.icon.arrow.sign.down:before { content: "\f13a"; } -/*rtl:rename*/ i.icon.arrow.sign.left:before { content: "\f137"; } -/*rtl:rename*/ i.icon.arrow.sign.right:before { content: "\f138"; } i.icon.arrow.sign.up:before { content: "\f139"; } i.icon.arrow.up:before { content: "\f077"; } @@ -128,6 +118,7 @@ i.icon.book:before { content: "\f02d"; } i.icon.bookmark.empty:before { content: "\f097"; } i.icon.bookmark:before { content: "\f02e"; } i.icon.box.arrow.down:before { content: "\f150"; } +/*rtl:ignore*/ i.icon.box.arrow.right:before { content: "\f152"; } i.icon.box.arrow.up:before { content: "\f151"; } i.icon.briefcase:before { content: "\f0b1"; } @@ -141,9 +132,7 @@ i.icon.calendar:before { content: "\f073"; } i.icon.camera.retro:before { content: "\f083"; } i.icon.camera:before { content: "\f030"; } i.icon.triangle.down:before { content: "\f0d7"; } -/*rtl:rename*/ i.icon.triangle.left:before { content: "\f0d9"; } -/*rtl:rename*/ i.icon.triangle.right:before { content: "\f0da"; } i.icon.triangle.up:before { content: "\f0d8"; } i.icon.cart:before { content: "\f07a"; } @@ -157,9 +146,7 @@ i.icon.checkmark.sign:before { content: "\f14a"; } i.icon.checkmark:before { content: "\f00c"; } i.icon.circle.blank:before { content: "\f10c"; } i.icon.circle.down:before { content: "\f0ab"; } -/*rtl:rename*/ i.icon.circle.left:before { content: "\f0a8"; } -/*rtl:rename*/ i.icon.circle.right:before { content: "\f0a9"; } i.icon.circle.up:before { content: "\f0aa"; } i.icon.circle:before { content: "\f111"; } @@ -181,9 +168,7 @@ i.icon.desktop:before { content: "\f108"; } i.icon.doctor:before { content: "\f0f0"; } i.icon.dollar:before { content: "\f155"; } i.icon.double.angle.down:before { content: "\f103"; } -/*rtl:rename*/ i.icon.double.angle.left:before { content: "\f100"; } -/*rtl:rename*/ i.icon.double.angle.right:before { content: "\f101"; } i.icon.double.angle.up:before { content: "\f102"; } i.icon.down:before { content: "\f063"; } @@ -244,9 +229,7 @@ i.icon.google.plus.sign:before { content: "\f0d4"; } i.icon.google.plus:before { content: "\f0d5"; } i.icon.h.sign:before { content: "\f0fd"; } i.icon.hand.down:before { content: "\f0a7"; } -/*rtl:rename*/ i.icon.hand.left:before { content: "\f0a5"; } -/*rtl:rename*/ i.icon.hand.right:before { content: "\f0a4"; } i.icon.hand.up:before { content: "\f0a6"; } i.icon.hdd:before { content: "\f0a0"; } @@ -259,9 +242,7 @@ i.icon.home:before { content: "\f015"; } i.icon.hospital:before { content: "\f0f8"; } i.icon.html5:before { content: "\f13b"; } i.icon.inbox:before { content: "\f01c"; } -/*rtl:rename*/ i.icon.indent.left:before { content: "\f03b"; } -/*rtl:rename*/ i.icon.indent.right:before { content: "\f03c"; } i.icon.info.letter:before { content: "\f129"; } i.icon.info:before { content: "\f05a"; } @@ -291,9 +272,7 @@ i.icon.loading:before { content: "\f110"; } i.icon.location:before { content: "\f124"; } i.icon.lock:before { content: "\f023"; } i.icon.long.arrow.down:before { content: "\f175"; } -/*rtl:rename*/ i.icon.long.arrow.left:before { content: "\f177"; } -/*rtl:rename*/ i.icon.long.arrow.right:before { content: "\f178"; } i.icon.long.arrow.up:before { content: "\f176"; } i.icon.magic:before { content: "\f0d0"; } @@ -338,9 +317,7 @@ i.icon.print:before { content: "\f02f"; } i.icon.puzzle.piece:before { content: "\f12e"; } i.icon.qr.code:before { content: "\f029"; } i.icon.question:before { content: "\f128"; } -/*rtl:rename*/ i.icon.quote.left:before { content: "\f10d"; } -/*rtl:rename*/ i.icon.quote.right:before { content: "\f10e"; } i.icon.refresh:before { content: "\f021"; } i.icon.remove.circle:before { content: "\f05c"; } diff --git a/src/modules/modal.less b/src/modules/modal.less index 6de4ed902..1c44d2ecc 100755 --- a/src/modules/modal.less +++ b/src/modules/modal.less @@ -105,6 +105,7 @@ padding-left: 1.5%; vertical-align: top; } +/*rtl:ignore*/ .ui.modal > .content > .left:not(.ui) > i.icon { font-size: 8em; margin: 0em; @@ -131,10 +132,12 @@ /* Mobile Only */ @media only screen and (max-width : 768px) { + /*rtl:ignore*/ .ui.modal .content > .left:not(.ui) { display: block; padding: 0em 0em 1em; } + /*rtl:ignore*/ .ui.modal .content > .right:not(.ui) { display: block; padding: 1em 0em 0em; From 702052e254f709b5627bf98ec5fc4e512a542ec1 Mon Sep 17 00:00:00 2001 From: Mohammad Younes Date: Sun, 9 Feb 2014 10:50:51 +0200 Subject: [PATCH 3/4] Preserve new lines from original src --- src/elements/basic.icon.less | 2 ++ src/elements/icon.less | 1 + 2 files changed, 3 insertions(+) diff --git a/src/elements/basic.icon.less b/src/elements/basic.icon.less index 805f9861c..37d39f390 100755 --- a/src/elements/basic.icon.less +++ b/src/elements/basic.icon.less @@ -77,9 +77,11 @@ i.basic.icon.resize.vertical:before { content: '\2b0c'; } /* '⬌' */ i.basic.icon.down:before { content: '\2193'; } /* '↓' */ i.basic.icon.down.triangle:before { content: '\25be'; } /* '▾' */ i.basic.icon.down.arrow:before { content: '\e75c'; } /* '' */ + i.basic.icon.left:before { content: '\2190'; } /* '←' */ i.basic.icon.left.triangle:before { content: '\25c2'; } /* '◂' */ i.basic.icon.left.arrow:before { content: '\e75d'; } /* '' */ + i.basic.icon.right:before { content: '\2192'; } /* '→' */ i.basic.icon.right.triangle:before { content: '\25b8'; } /* '▸' */ i.basic.icon.right.arrow:before { content: '\e75e'; } /* '' */ diff --git a/src/elements/icon.less b/src/elements/icon.less index 44b2fc3e0..d905aead8 100755 --- a/src/elements/icon.less +++ b/src/elements/icon.less @@ -70,6 +70,7 @@ i.icon { -moz-font-smoothing: antialiased; font-smoothing: antialiased; } + i.icon.left:before { content: "\f060"; } i.icon.right:before { content: "\f061"; } From 2b2abebc5d20c3f7bb70e9fbaa758070821eb0e4 Mon Sep 17 00:00:00 2001 From: Mohammad Younes Date: Sun, 9 Feb 2014 18:25:51 +0200 Subject: [PATCH 4/4] possible typo --- server/files/stylesheets/semantic.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/files/stylesheets/semantic.css b/server/files/stylesheets/semantic.css index 8f626fe4e..8f8702b29 100755 --- a/server/files/stylesheets/semantic.css +++ b/server/files/stylesheets/semantic.css @@ -1327,7 +1327,7 @@ body.progress .ui.progress .bar { width: auto; margin: 0% 30px 0px; } - /*rtl:ignore*/ + #example #example .right.attached.launch { display: none; }