Check-in [c6735b38b4]
Not logged in

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Read the CSS transition style to be restored later directly from the (previously initialized) style property, as window.getComputedStyle() seems to return null with Firefox, in this specific case. This fixes a problem introduced with the previous check-in.
Timelines: family | ancestors | descendants | both | js-hamburger-menu
Files: files | file ages | folders
SHA1:c6735b38b48b5546ca20c50df3ee97bde07762f5
User & Date: florian 2018-10-11 16:36:01
Context
2018-10-11
16:36
Extend the CSS fixes to avoid column breaks inside list items, [dc5e06ff71] and [51da396650], as Firefox classifies 'break-inside' as an 'invalid property name'. This affects the sitemap and the hamburger drop-down menu. check-in: 5bd8d6fe86 user: florian tags: js-hamburger-menu
16:36
Read the CSS transition style to be restored later directly from the (previously initialized) style property, as window.getComputedStyle() seems to return null with Firefox, in this specific case. This fixes a problem introduced with the previous check-in. check-in: c6735b38b4 user: florian tags: js-hamburger-menu
16:36
Allow the hamburger menu to be closed instantly by pressing ESC or by clicking outside. This is the patch initially submitted to https://fossil-scm.org/forum/forumpost/2abe305c2d, with the interim changes incorporated. check-in: a44fdd17de user: florian tags: js-hamburger-menu
Changes

Changes to skins/default/js.txt.

117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
  function panelToggle(suppressAnimation) {
    if (panelShowing()) {
      document.onkeydown = originalEventHandlers.onkeydown;
      document.onclick = originalEventHandlers.onclick;
      // Transition back to hidden state.
      if (animate) {
        if (suppressAnimation) {
          var transition = window.getComputedStyle(panel).transition;
          panel.style.transition = '';
          panel.style.maxHeight = '0';
          panel.style.border = 'none';
          setTimeout(function() {
            // Make sure CSS transition won't take effect now, so restore it
            // asynchronously. Outer variable 'transition' still valid here.
            panel.style.transition = transition;







|







117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
  function panelToggle(suppressAnimation) {
    if (panelShowing()) {
      document.onkeydown = originalEventHandlers.onkeydown;
      document.onclick = originalEventHandlers.onclick;
      // Transition back to hidden state.
      if (animate) {
        if (suppressAnimation) {
          var transition = panel.style.transition;
          panel.style.transition = '';
          panel.style.maxHeight = '0';
          panel.style.border = 'none';
          setTimeout(function() {
            // Make sure CSS transition won't take effect now, so restore it
            // asynchronously. Outer variable 'transition' still valid here.
            panel.style.transition = transition;