Skip to content

Commit

Permalink
Merge pull request #17 from OriHoch/more-rtl-fixes
Browse files Browse the repository at this point in the history
more rtl fixes
  • Loading branch information
OriHoch authored Aug 17, 2017
2 parents 8c059e9 + 45b6712 commit d2a9856
Show file tree
Hide file tree
Showing 6 changed files with 258 additions and 269 deletions.
8 changes: 8 additions & 0 deletions bin/poedit.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/usr/bin/env bash

if ! which poedit; then
sudo apt-get install poedit
fi

poedit ckan/ckanext-odata_org_il/ckanext/odata_org_il/i18n/he/LC_MESSAGES/ckan.po

11 changes: 10 additions & 1 deletion ckan/ckanext-odata_org_il/ckanext/odata_org_il/fanstatic/rtl.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
.heading, .module-heading, a, p, .dataset-list, .search-form, h1,
#dataset-resources, .additional-info, .tags, td.dataset-details, th.dataset-label,
.context-info, .flash-messages, .page_primary_action, .breadcrumb
.context-info, .flash-messages, .page_primary_action, .breadcrumb,
.media-item, .nav-item
{
direction: rtl;
text-align: right;
Expand Down Expand Up @@ -28,3 +29,11 @@
.resource-item {
padding: 10px 60px 10px 10px;
}

.homepage .module-search .tags h3, .homepage .module-search .tags .tag {
float: right;
}

.nav-facet .nav-item a span {
padding-right: 15px;
}
13 changes: 13 additions & 0 deletions ckan/ckanext-odata_org_il/ckanext/odata_org_il/fanstatic/rtl.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
$(function() {
$('.nav-facet .nav-item a span').each(function(i, elt) {
var $elt = $(elt);
var txt = $elt.text();
var tmp = txt.split(" ");
if (tmp.length > 1 && tmp[tmp.length-1].length > 1 && tmp[tmp.length-1][0] == "(") {
txt = tmp.slice(0, tmp.length-1).join(" ");
var mark = (CKAN_LANG=="he") ? " ‏" : " ‎";
txt += mark + tmp[tmp.length-1];
$elt.html(txt);
}
});
});
Binary file not shown.
Loading

0 comments on commit d2a9856

Please sign in to comment.