From: Will Budic Date: Tue, 3 Oct 2023 09:40:38 +0000 (+1100) Subject: Fix. tooltips. X-Git-Url: https://lifelog.hopto.org/gitweb/?a=commitdiff_plain;h=ac68a15d28354180a0eecc900e456ca3c2b4c717;p=LifeLog.git Fix. tooltips. --- diff --git a/htdocs/cgi-bin/main.cgi b/htdocs/cgi-bin/main.cgi index 4ddb1fe..8796953 100755 --- a/htdocs/cgi-bin/main.cgi +++ b/htdocs/cgi-bin/main.cgi @@ -300,7 +300,7 @@ my $currsymb = &Settings::currenySymbol; if($isPUBViewMode){$eh = ""} else{$eh='Edit'} my $log_output =qq(
- +
@@ -850,7 +850,7 @@ my $frm = qq(     - Enter log... + Please Wait...    Category:  @@ -865,7 +865,7 @@ my $frm = qq( @@ -1073,7 +1073,7 @@ else{
- Log
+ Log
diff --git a/htdocs/cgi-bin/wsrc/main.js b/htdocs/cgi-bin/wsrc/main.js index c7c41d6..5c75218 100644 --- a/htdocs/cgi-bin/wsrc/main.js +++ b/htdocs/cgi-bin/wsrc/main.js @@ -93,11 +93,8 @@ function onBodyLoad(toggle, locale, tz, today, expires, rs_cur, log_limit) { className: 'tip-yellowsimple', showOn: 'focus', alignTo: 'target', - alignX: 'left', - alignY: 'center', - offsetX: 5, - showTimeout: 50, - allowTipHover: true + alignX: 'center', + alignY: 'bottom' }); $('#am').poshytip({ content: "Symbolic amount in your local or preferred currency. Can be left empty.", @@ -109,6 +106,19 @@ function onBodyLoad(toggle, locale, tz, today, expires, rs_cur, log_limit) { offsetX: 5, showTimeout: 100 }); + + $('#Log_btn').poshytip({ + content: "Clicking the Log button is naturally the next move.", + className: 'tip-yellowsimple', + showOn: 'none', + alignTo: 'target', + alignX: 'left', + alignY: 'center', + offsetX: 15 + }); + $('#Log_btn').poshytip('show'); + setTimeout(function() { $('#Log_btn').poshytip('hide'); }, 5000); + $('#am').click(function(e){ e.preventDefault(); let v = $('#am').val(); @@ -365,12 +375,11 @@ function onBodyLoad(toggle, locale, tz, today, expires, rs_cur, log_limit) { if(event.which === 13) { $(this).next().focus(); } - }); + }); setPageSessionTimer(expires); - $(function() { $( "#rs_keys, #rs_keys2" ).autocomplete({ source: AUTOWORDS @@ -409,7 +418,7 @@ function onBodyLoad(toggle, locale, tz, today, expires, rs_cur, log_limit) { source: AUTOWORDS }); }); - + $('#main_table').css('visibility', 'visible'); display("Log page is ready!", 5); } @@ -828,7 +837,7 @@ function show(id) { return false; } -function toggle(id, mtoggle) { +function toggle(id, mtoggle, focus_point) { //Menu button untoggle it up first. Complex interaction situation. if(mtoggle){ if(!$(id+" .collpsd").is(":visible")){ @@ -846,6 +855,9 @@ function toggle(id, mtoggle) { $(id).toggle(); } $("html, body").animate({ scrollTop: 0 }, "fast"); + if(focus_point){ + setTimeout(function(){$(focus_point).focus()}, 100); + } return false; }