diff options
author | Andreas Gohr <andi@splitbrain.org> | 2014-02-02 12:38:22 -0800 |
---|---|---|
committer | Andreas Gohr <andi@splitbrain.org> | 2014-02-02 12:38:22 -0800 |
commit | 69736a139a14ee8cb2a439b34d64f964a0519a03 (patch) | |
tree | 1ea14bc2aeae52c2fea54adde609806f89bfc7ac /lib/scripts | |
parent | 8f8f057a71acccc5537691d6437a3651e68a2ebc (diff) | |
parent | 4d4058eec6b089a303975dfd71f16fd42f55f11b (diff) | |
download | rpg-69736a139a14ee8cb2a439b34d64f964a0519a03.tar.gz rpg-69736a139a14ee8cb2a439b34d64f964a0519a03.tar.bz2 |
Merge pull request #503 from splitbrain/datepickerlocale
localize jQuery UI date picker FS#2912
Diffstat (limited to 'lib/scripts')
-rwxr-xr-x | lib/scripts/jquery/update.sh | 25 |
1 files changed, 21 insertions, 4 deletions
diff --git a/lib/scripts/jquery/update.sh b/lib/scripts/jquery/update.sh index 749b0f4e2..b0de441f9 100755 --- a/lib/scripts/jquery/update.sh +++ b/lib/scripts/jquery/update.sh @@ -7,15 +7,15 @@ # @author Andreas Gohr <andi@splitbrain.org> # @author Stefan Grönke <stefan@gronke.net> # @link https://code.google.com/apis/libraries/devguide.html#jquery - + # load jQuery wget -nv https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js -O jquery.min.js wget -nv https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.js -O jquery.js - + # load jQuery-UI wget -nv https://ajax.googleapis.com/ajax/libs/jqueryui/1/jquery-ui.min.js -O jquery-ui.min.js wget -nv https://ajax.googleapis.com/ajax/libs/jqueryui/1/jquery-ui.js -O jquery-ui.js - + # load the smoothness theme mkdir -p jquery-ui-theme/images wget -nv -qO- https://ajax.googleapis.com/ajax/libs/jqueryui/1/themes/smoothness/jquery-ui.css | sed "s/font-family:[^;]*;//" > jquery-ui-theme/smoothness.css @@ -23,4 +23,21 @@ images=`gawk 'match($0, /url\("?(images\/[^\)"]+)"?\)/, m) { print m[1] }' jquer for img in $images do wget -nv https://ajax.googleapis.com/ajax/libs/jqueryui/1/themes/smoothness/$img -O jquery-ui-theme/$img -done
\ No newline at end of file +done + +# load the localization data for jquery ui +for LNG in ../../../inc/lang/* +do + CODE=`basename $LNG` + wget -nv https://raw2.github.com/jquery/jquery-ui/master/ui/i18n/jquery.ui.datepicker-$CODE.js -O $LNG/jquery.ui.datepicker.js + if [ ! -s "$LNG/jquery.ui.datepicker.js" ]; then + rm -f $LNG/jquery.ui.datepicker.js + fi +done + +# some custom language codes +wget -nv https://raw2.github.com/jquery/jquery-ui/master/ui/i18n/jquery.ui.datepicker-de.js -O ../../../inc/lang/de-informal/jquery.ui.datepicker.js +wget -nv https://raw2.github.com/jquery/jquery-ui/master/ui/i18n/jquery.ui.datepicker-pt-BR.js -O ../../../inc/lang/pt-br/jquery.ui.datepicker.js +wget -nv https://raw2.github.com/jquery/jquery-ui/master/ui/i18n/jquery.ui.datepicker-zh-CN.js -O ../../../inc/lang/zh/jquery.ui.datepicker.js +wget -nv https://raw2.github.com/jquery/jquery-ui/master/ui/i18n/jquery.ui.datepicker-zh-TW.js -O ../../../inc/lang/zh-tw/jquery.ui.datepicker.js + |