@@ -702,7 +702,7 @@ return
-
+
diff --git a/static/abaev-global.js b/static/abaev-global.js new file mode 100644 index 0000000..8e9071a --- /dev/null +++ b/static/abaev-global.js @@ -0,0 +1,12 @@ +$( document ).ready(function() { + // GLOBALS; + + // Link elements that do not have href out of the box + $('.link').on("click", function () { + window.location=$(this)[0].dataset.href+window.location.search+window.location.hash; + }); + + $('#abv-search').on("submit", function () { + $('#abv-search-icon').replaceWith('
'); + }); +}); diff --git a/static/abaev-html.css b/static/abaev-html.css index 034d3b9..837dfe6 100644 --- a/static/abaev-html.css +++ b/static/abaev-html.css @@ -216,7 +216,7 @@ a.abv-map img { height: 2ex; } -a.abv-map:hover { +a.link:hover { cursor: pointer; } diff --git a/static/abaev.js b/static/abaev.js index 588ab7e..6409e8b 100644 --- a/static/abaev.js +++ b/static/abaev.js @@ -10,6 +10,8 @@ $( document ).ready(function() { $('#abv-search-icon').replaceWith(''); }); + // INFINITE SCROLL + // init Infinite Scroll $('main').infiniteScroll({ path: '.pagination__next', diff --git a/xq/restx_dict_cached.xq b/xq/restx_dict_cached.xq index 92987b8..22d02d1 100644 --- a/xq/restx_dict_cached.xq +++ b/xq/restx_dict_cached.xq @@ -30,6 +30,8 @@ declare function page:head($title as xs:string, $script as node()* := ()) { + @@ -56,15 +58,13 @@ declare function page:header($lang as xs:string, $href-other as xs:string) { (element {if ($lang = 'ru') then 'mark' else 'a'}{ if ($lang != 'ru') then (attribute class {'link'}, - attribute data-href {`{$href-other}`}, - attribute href {'#'}) else (), + attribute data-href {`{$href-other}`}) else (), 'ru' }, ' / ', element {if ($lang = 'ru') then 'a' else 'mark'}{ if ($lang = 'ru') then (attribute class {'link'}, - attribute data-href {`{$href-other}`}, - attribute href {'#'}) else (), + attribute data-href {`{$href-other}`}) else (), 'en' }) } @@ -669,7 +669,7 @@ return {page:head('HEDO – Index', )} -{page:header($lang,`../{page:invert-lang($lang)}/index`)} +{page:header($lang, `../{page:invert-lang($lang)}/index`)}