diff --git a/_hippie.scss b/_hippie.scss index ad01369..d265a47 100644 --- a/_hippie.scss +++ b/_hippie.scss @@ -47,8 +47,8 @@ // Adjustments can be made by copying values from _config.scss to _override.scss // Be careful though changes will get lost if hippie gets updated // ----------------------------------------------------------------------------- -@import "global/default"; // DO NOT EDIT -@import "override"; // EDIT +// @import "global/default"; // DO NOT EDIT +@import "settings"; // EDIT @import "global/config"; // DO NOT EDIT diff --git a/_override.scss b/_settings.scss similarity index 79% rename from _override.scss rename to _settings.scss index e4b3c48..6239a8e 100644 --- a/_override.scss +++ b/_settings.scss @@ -1,4 +1,4 @@ // Override for configuration file // ------------------------------------------------------------------------------ -// $default_font_size: 10px; +// $basic_link_color: magenta; diff --git a/code/global.js b/code/global.js new file mode 100644 index 0000000..4275707 --- /dev/null +++ b/code/global.js @@ -0,0 +1,150 @@ +// DOM ready +// ------------------------------------------------------------------------------ +$( document ).ready(function() { + + // Setup + // ------------------------------------------------------------------------------ + + setup(); + + + + // Modules + // ------------------------------------------------------------------------------ + + // Explanation module scripts + var exp_mode = false; + + // Displays explanation popup + $(".js_pop").hover( + function() { + var $this = $(this); + + if($(this).attr("emmet")){ + + } + + $(this).next(".exp_pop").show(); + }, function() { + $(this).next(".exp_pop").hide(); + } + ).mousemove( + function(ev) { + $(this).next(".exp_pop").css({ + "top": ev.pageY - $(this).next(".exp_pop").outerHeight() - 4, + "left": ev.pageX + 8 + }); + } + ); + + // WIP Activates layer with explanation elements + // Besser ::after oder ::before benutzen + $(".exp_help_btn").click(function(e){ + var $wrap, $pop; + + if(exp_mode != true){ + exp_mode = true; + + $(".js_pop").each(function(i, e){ + if($(this).css("position") == "static") { + $(this).addClass("js_changed_pos"); + $(this).css("position", "relative"); + } + + $pop = $(this).next(".exp_pop").detach(); + $wrap = $(this).wrap("").parent().prepend(""); + $wrap.after($pop); + }); + + } else { + $(".js_pop").each(function(i, e){ + $wrap = $(this).parent(".exp_wrap"); + $pop = $wrap.next(".exp_pop").detach(); + $wrap.find(".exp_marker_pop").remove(); + $(this).unwrap(".exp_wrap"); + $(this).after($pop); + if($(this).hasClass("js_changed_pos")){ + $(this).css("position", ""); + if($(this).attr("style") == "") { + $(this).removeAttr("style"); + } + $(this).removeClass("js_changed_pos"); + } + }); + + exp_mode = false; + + } + console.log("Explanation mode: "+ exp_mode); + }); + + // WIP Scroll to top + $('#js_scrolltop').click(function(event) { + console.log('scroll to the top'); + event.preventDefault(); + // $('body').scrollTop(); + $('body').animate({scrollTop: 0}, basic_ease, function() { + console.log('arrived at top'); + }); + }); + $('#js_scrolldown').click(function(event) { + console.log('scroll down'); + event.preventDefault(); + $('body').animate({scrollTop: $(document).height()}, basic_ease * 2, function() { + console.log('arrived at bottom'); + }); + }); + + + + $( "#gameIcon" ).click(function(event) { + event.preventDefault(); + $( this ).clone().appendTo( "#gameDetail" ); + $( this ).siblings().clone().appendTo( "#gameDetail" ); + $( "#gameDetail" ).removeClass( "magic" ); + }); + + var i = 0; + $( ".pass-def dd" ).each(function() { + $( this ).find( "li" ).each(function( index ) { + if ( 0 == $( this ).children( "ul" ).length ) { + //console.log( index + ": " + $( this ).text() ); + var tempContent = $( this ).html(); + //$( this ).html( "" ); + $( this ).html( tempContent +""+ i +"" ); + i++; + } + }) + }); + + + + // jq-sticky-anything + $('#js_demo_fix').stickThis({ + pushup: '#js_demo_stop' + }); + + + +}); + + + +// Scroll +// ------------------------------------------------------------------------------ +$( document ).scroll(function() { + + // Toggle navigation elements + doc_pos_y = $( document ).scrollTop(); + // console.log(doc_pos_y); + var h = scroll_y_margin; + // var demo_margin = $('.header__fix'); + if (doc_pos_y > h) { + $('#js_scrolltop').parent().removeClass('magic'); + } else { + $('#js_scrolltop').parent().addClass('magic'); + } + + + +}); diff --git a/demo-explorer.html b/demo-explorer.html new file mode 100644 index 0000000..5b1f6bd --- /dev/null +++ b/demo-explorer.html @@ -0,0 +1,156 @@ + + +
+ + +Dateiname 1
+Auszeichnung 1
+Dateiname 2
+Auszeichnung 2
+Dateiname 3
+Auszeichnung 3
+Dateiname 4
+Auszeichnung 4
+| Objektname 1 | +Objektpfad 1 | +|
| Objektname 2 | +Objektpfad 2 | +
Status
+table>tbody>tr>td*2^tr>td[colspan=2]| Mit | @@ -197,10 +197,10 @@
table.table_blank>tbody>tr>td*2^tr>td[colspan=2]table.table__blank>tbody>tr>td*2^tr>td[colspan=2]Die nächste Tabelle verwendet alle zur Auszeichnung verfügbaren Elemente und hat eine starre Zellverteilung:
-table.width_full.table_fix>caption+thead>tr>th*3^^tfoot>tr>td*3^^tbody>(tr>td*3)*3table.width_full.table__fix>caption+thead>tr>th*3^^tfoot>tr>td*3^^tbody>(tr>td*3)*3Viele weitere Formate sind möglich ...
table.width_full>thead>tr>th.precol+th[colspan=2]^^tbody>tr>td.precol+td*2^tr>td.precol+td[colspan=2]| Kopfzeile | @@ -304,7 +304,7 @@
|---|