View | Details | Raw Unified | Return to bug 20554
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/about.tt (+6 lines)
Lines 999-1004 Link Here
999
999
1000
            <h2>JSZip</h2>
1000
            <h2>JSZip</h2>
1001
            <p>The <a href="https://stuk.github.io/jszip/">JSZip</a> JavaScript library is licensed under both the <a href="https://github.com/Stuk/jszip/blob/master/LICENSE.markdown">MIT and GPLv3 Licenses</a>.</p>
1001
            <p>The <a href="https://stuk.github.io/jszip/">JSZip</a> JavaScript library is licensed under both the <a href="https://github.com/Stuk/jszip/blob/master/LICENSE.markdown">MIT and GPLv3 Licenses</a>.</p>
1002
1003
            <h2>Font Face Observer</h2>
1004
            <p><a href="https://github.com/bramstein/fontfaceobserver">Font Face Observer</a> is a JavaScript library by Bram Stein licensed under the <a href="https://github.com/bramstein/fontfaceobserver/blob/master/LICENSE">BSD License</a>.</p>
1005
1006
            <h2>Noto fonts</h2>
1007
            <p><a href="https://github.com/googlei18n/noto-fonts">Noto</a> by Google is a family of fonts licensed under the <a href="http://scripts.sil.org/OFL">SIL Open Font License (OFL) v1.1</a>.</p>
1002
        </div>
1008
        </div>
1003
1009
1004
        <div id="translations">
1010
        <div id="translations">
(-)a/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss (-1 / +43 lines)
Lines 1-11 Link Here
1
@import "mixins";
1
@import "mixins";
2
2
3
@font-face {
4
    font-family: 'NotoSans';
5
    font-style: normal;
6
    font-weight: 400;
7
    src: local('Noto Sans Regular'),
8
        url('fonts/NotoSans-Regular-webfont.woff2') format('woff2'),
9
        url('fonts/NotoSans-Regular-webfont.woff') format('woff');
10
}
11
12
@font-face {
13
    font-family: 'NotoSans';
14
    font-style: bold;
15
    font-weight: 700;
16
    src: local('Noto Sans Bold'),
17
        url('fonts/NotoSans-Bold-webfont.woff2') format('woff2'),
18
        url('fonts/NotoSans-Bold-webfont.woff') format('woff');
19
}
20
21
@font-face {
22
    font-family: 'NotoSans';
23
    font-style: italic;
24
    font-weight: 400;
25
    src: local('Noto Sans Italic'),
26
        url('fonts/NotoSans-Italic-webfont.woff2') format('woff2'),
27
        url('fonts/NotoSans-Italic-webfont.woff') format('woff');
28
}
29
30
@font-face {
31
    font-family: 'NotoSans';
32
    font-style: italic;
33
    font-weight: 700;
34
    src: local('Noto Sans Bold Italic'),
35
        url('fonts/NotoSans-BoldItalic-webfont.woff2') format('woff2'),
36
        url('fonts/NotoSans-BoldItalic-webfont.woff') format('woff');
37
}
38
39
3
body {
40
body {
4
    background: #FCF9FC none;
41
    background: #FCF9FC none;
5
    font-family: 'NotoSansRegular';
42
    font-family: sans-serif;
6
    font-size: 16px;
43
    font-size: 16px;
7
}
44
}
8
45
46
.fonts-loaded body {
47
    font-family: 'NotoSans';
48
}
49
9
/* Sticky footer styles */
50
/* Sticky footer styles */
10
html,
51
html,
11
body {
52
body {
Lines 712-717 input[type="text"]:focus { Link Here
712
            > a {
753
            > a {
713
                color: #727272;
754
                color: #727272;
714
                font-weight: bold;
755
                font-weight: bold;
756
                text-shadow: none;
715
                &:hover {
757
                &:hover {
716
                    color: #85ca11;
758
                    color: #85ca11;
717
                }
759
                }
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/doc-head-close.inc (-3 lines)
Lines 17-25 Link Here
17
[% END %]
17
[% END %]
18
18
19
[% SET opaclayoutstylesheet='opac.css' UNLESS opaclayoutstylesheet %]
19
[% SET opaclayoutstylesheet='opac.css' UNLESS opaclayoutstylesheet %]
20
<!--Fonts -->
21
<link rel="stylesheet" media="screen" href="https://fontlibrary.org/face/noto-sans-condensed" type="text/css"/>
22
<link rel="stylesheet" media="screen" href="https://fontlibrary.org/face/noto-sans-normal" type="text/css"/>
23
20
24
[% IF (opaclayoutstylesheet.match('^https?:|^\/')) %]
21
[% IF (opaclayoutstylesheet.match('^https?:|^\/')) %]
25
    <link rel="stylesheet" type="text/css" href="[% opaclayoutstylesheet %]" />
22
    <link rel="stylesheet" type="text/css" href="[% opaclayoutstylesheet %]" />
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-bottom.inc (+1 lines)
Lines 86-91 Link Here
86
$.widget.bridge('uitooltip', $.ui.tooltip);
86
$.widget.bridge('uitooltip', $.ui.tooltip);
87
</script>
87
</script>
88
[% Asset.js("lib/bootstrap/js/bootstrap.min.js") %]
88
[% Asset.js("lib/bootstrap/js/bootstrap.min.js") %]
89
[% Asset.js("lib/fontfaceobserver.min.js") %]
89
[% Asset.js("js/global.js") %]
90
[% Asset.js("js/global.js") %]
90
<script type="text/javascript">
91
<script type="text/javascript">
91
    Modernizr.load([
92
    Modernizr.load([
(-)a/koha-tmpl/opac-tmpl/bootstrap/js/global.js (+16 lines)
Lines 1-3 Link Here
1
(function( w ){
2
    // if the class is already set, the font has already been loaded
3
    if( w.document.documentElement.className.indexOf( "fonts-loaded" ) > -1 ){
4
        return;
5
    }
6
    var PrimaryFont = new w.FontFaceObserver( "NotoSans", {
7
        weight: 400
8
    });
9
10
    PrimaryFont.load(null, 5000).then(function(){
11
        w.document.documentElement.className += " fonts-loaded";
12
    }, function(){
13
        console.log("Failed");
14
    });
15
}( this ));
16
1
// http://stackoverflow.com/questions/1038746/equivalent-of-string-format-in-jquery/5341855#5341855
17
// http://stackoverflow.com/questions/1038746/equivalent-of-string-format-in-jquery/5341855#5341855
2
String.prototype.format = function() { return formatstr(this, arguments) }
18
String.prototype.format = function() { return formatstr(this, arguments) }
3
function formatstr(str, col) {
19
function formatstr(str, col) {
(-)a/koha-tmpl/opac-tmpl/bootstrap/lib/fontfaceobserver.min.js (-1 / +12 lines)
Line 0 Link Here
0
- 
1
/* Font Face Observer v2.0.13 - © Bram Stein. License: BSD-3-Clause */(function(){'use strict';var f,g=[];function l(a){g.push(a);1==g.length&&f()}function m(){for(;g.length;)g[0](),g.shift()}f=function(){setTimeout(m)};function n(a){this.a=p;this.b=void 0;this.f=[];var b=this;try{a(function(a){q(b,a)},function(a){r(b,a)})}catch(c){r(b,c)}}var p=2;function t(a){return new n(function(b,c){c(a)})}function u(a){return new n(function(b){b(a)})}function q(a,b){if(a.a==p){if(b==a)throw new TypeError;var c=!1;try{var d=b&&b.then;if(null!=b&&"object"==typeof b&&"function"==typeof d){d.call(b,function(b){c||q(a,b);c=!0},function(b){c||r(a,b);c=!0});return}}catch(e){c||r(a,e);return}a.a=0;a.b=b;v(a)}}
2
function r(a,b){if(a.a==p){if(b==a)throw new TypeError;a.a=1;a.b=b;v(a)}}function v(a){l(function(){if(a.a!=p)for(;a.f.length;){var b=a.f.shift(),c=b[0],d=b[1],e=b[2],b=b[3];try{0==a.a?"function"==typeof c?e(c.call(void 0,a.b)):e(a.b):1==a.a&&("function"==typeof d?e(d.call(void 0,a.b)):b(a.b))}catch(h){b(h)}}})}n.prototype.g=function(a){return this.c(void 0,a)};n.prototype.c=function(a,b){var c=this;return new n(function(d,e){c.f.push([a,b,d,e]);v(c)})};
3
function w(a){return new n(function(b,c){function d(c){return function(d){h[c]=d;e+=1;e==a.length&&b(h)}}var e=0,h=[];0==a.length&&b(h);for(var k=0;k<a.length;k+=1)u(a[k]).c(d(k),c)})}function x(a){return new n(function(b,c){for(var d=0;d<a.length;d+=1)u(a[d]).c(b,c)})};window.Promise||(window.Promise=n,window.Promise.resolve=u,window.Promise.reject=t,window.Promise.race=x,window.Promise.all=w,window.Promise.prototype.then=n.prototype.c,window.Promise.prototype["catch"]=n.prototype.g);}());
4
5
(function(){function l(a,b){document.addEventListener?a.addEventListener("scroll",b,!1):a.attachEvent("scroll",b)}function m(a){document.body?a():document.addEventListener?document.addEventListener("DOMContentLoaded",function c(){document.removeEventListener("DOMContentLoaded",c);a()}):document.attachEvent("onreadystatechange",function k(){if("interactive"==document.readyState||"complete"==document.readyState)document.detachEvent("onreadystatechange",k),a()})};function r(a){this.a=document.createElement("div");this.a.setAttribute("aria-hidden","true");this.a.appendChild(document.createTextNode(a));this.b=document.createElement("span");this.c=document.createElement("span");this.h=document.createElement("span");this.f=document.createElement("span");this.g=-1;this.b.style.cssText="max-width:none;display:inline-block;position:absolute;height:100%;width:100%;overflow:scroll;font-size:16px;";this.c.style.cssText="max-width:none;display:inline-block;position:absolute;height:100%;width:100%;overflow:scroll;font-size:16px;";
6
this.f.style.cssText="max-width:none;display:inline-block;position:absolute;height:100%;width:100%;overflow:scroll;font-size:16px;";this.h.style.cssText="display:inline-block;width:200%;height:200%;font-size:16px;max-width:none;";this.b.appendChild(this.h);this.c.appendChild(this.f);this.a.appendChild(this.b);this.a.appendChild(this.c)}
7
function t(a,b){a.a.style.cssText="max-width:none;min-width:20px;min-height:20px;display:inline-block;overflow:hidden;position:absolute;width:auto;margin:0;padding:0;top:-999px;white-space:nowrap;font-synthesis:none;font:"+b+";"}function y(a){var b=a.a.offsetWidth,c=b+100;a.f.style.width=c+"px";a.c.scrollLeft=c;a.b.scrollLeft=a.b.scrollWidth+100;return a.g!==b?(a.g=b,!0):!1}function z(a,b){function c(){var a=k;y(a)&&a.a.parentNode&&b(a.g)}var k=a;l(a.b,c);l(a.c,c);y(a)};function A(a,b){var c=b||{};this.family=a;this.style=c.style||"normal";this.weight=c.weight||"normal";this.stretch=c.stretch||"normal"}var B=null,C=null,E=null,F=null;function G(){if(null===C)if(J()&&/Apple/.test(window.navigator.vendor)){var a=/AppleWebKit\/([0-9]+)(?:\.([0-9]+))(?:\.([0-9]+))/.exec(window.navigator.userAgent);C=!!a&&603>parseInt(a[1],10)}else C=!1;return C}function J(){null===F&&(F=!!document.fonts);return F}
8
function K(){if(null===E){var a=document.createElement("div");try{a.style.font="condensed 100px sans-serif"}catch(b){}E=""!==a.style.font}return E}function L(a,b){return[a.style,a.weight,K()?a.stretch:"","100px",b].join(" ")}
9
A.prototype.load=function(a,b){var c=this,k=a||"BESbswy",q=0,D=b||3E3,H=(new Date).getTime();return new Promise(function(a,b){if(J()&&!G()){var M=new Promise(function(a,b){function e(){(new Date).getTime()-H>=D?b():document.fonts.load(L(c,'"'+c.family+'"'),k).then(function(c){1<=c.length?a():setTimeout(e,25)},function(){b()})}e()}),N=new Promise(function(a,c){q=setTimeout(c,D)});Promise.race([N,M]).then(function(){clearTimeout(q);a(c)},function(){b(c)})}else m(function(){function u(){var b;if(b=-1!=
10
f&&-1!=g||-1!=f&&-1!=h||-1!=g&&-1!=h)(b=f!=g&&f!=h&&g!=h)||(null===B&&(b=/AppleWebKit\/([0-9]+)(?:\.([0-9]+))/.exec(window.navigator.userAgent),B=!!b&&(536>parseInt(b[1],10)||536===parseInt(b[1],10)&&11>=parseInt(b[2],10))),b=B&&(f==v&&g==v&&h==v||f==w&&g==w&&h==w||f==x&&g==x&&h==x)),b=!b;b&&(d.parentNode&&d.parentNode.removeChild(d),clearTimeout(q),a(c))}function I(){if((new Date).getTime()-H>=D)d.parentNode&&d.parentNode.removeChild(d),b(c);else{var a=document.hidden;if(!0===a||void 0===a)f=e.a.offsetWidth,
11
g=n.a.offsetWidth,h=p.a.offsetWidth,u();q=setTimeout(I,50)}}var e=new r(k),n=new r(k),p=new r(k),f=-1,g=-1,h=-1,v=-1,w=-1,x=-1,d=document.createElement("div");d.dir="ltr";t(e,L(c,"sans-serif"));t(n,L(c,"serif"));t(p,L(c,"monospace"));d.appendChild(e.a);d.appendChild(n.a);d.appendChild(p.a);document.body.appendChild(d);v=e.a.offsetWidth;w=n.a.offsetWidth;x=p.a.offsetWidth;I();z(e,function(a){f=a;u()});t(e,L(c,'"'+c.family+'",sans-serif'));z(n,function(a){g=a;u()});t(n,L(c,'"'+c.family+'",serif'));
12
z(p,function(a){h=a;u()});t(p,L(c,'"'+c.family+'",monospace'))})})};"object"===typeof module?module.exports=A:(window.FontFaceObserver=A,window.FontFaceObserver.prototype.load=A.prototype.load);}());

Return to bug 20554