Skip to content

Reading Meter Progress bar

Locked Solved Customisation
15 3 6.5k 1
  • wrote on last edited by
    #1

    Hello @phenomlab

    How do you do this reading-meter-progress bar ?

    e2756c2e-4771-46d4-a337-10bbe9c98b0a-image.png

    Thanks

    😉

  • Hello @phenomlab

    How do you do this reading-meter-progress bar ?

    e2756c2e-4771-46d4-a337-10bbe9c98b0a-image.png

    Thanks

    😉

    wrote on last edited by phenomlab
    #2

    @downpw Add this to your custom JS

    $(window).on('action:ajaxify.end', function (data) {
        // Main progressbar function
        window.onscroll = function () { myFunction() };
        function myFunction() {
            var winScroll = document.body.scrollTop || document.documentElement.scrollTop;
            var height = document.documentElement.scrollHeight - document.documentElement.clientHeight;
            var scrolled = (winScroll / height) * 100;
            document.getElementById("myBar").style.width = scrolled + "%";
        }
    });
    

    Add this into Custom Header

    <div class="reading-meter">
      <div class="reading-meter-progress">
        <div class="reading-meter-progress-bar" id="myBar"></div>
      </div> 
    </div>
    

    Sample CSS

    .reading-meter {
      position: fixed;
      top: 0px !important;
      z-index: 1111;
      width: 100%;
      background-color: #000000;
    }
    
    .reading-meter-progress {
    width: 100%;
    height: 3px;  z-index: 1111;
    background: #ffffff;
    }
    
    .reading-meter-progress-bar {
    height: 3px;
    background-color:#dddddd;
    width: 0%;
    }
    
  • phenomlab phenomlab has marked this topic as solved on
  • wrote on last edited by phenomlab
    #3

    @phenomlab said in Reading Meter Progress bar:

    Add this into Custom Header
    <div class=“reading-meter”>
    <div class=“reading-meter-progress”>
    <div class=“reading-meter-progress-bar” id=“myBar”></div>
    </div>

    Sample CSS
    .reading-meter {
    position: fixed;
    top: 0px !important;
    z-index: 1111;
    width: 100%;
    background-color: #000000;
    }

    .reading-meter-progress {
    width: 100%;
    height: 3px; z-index: 1111;
    background: #ffffff;
    }

    .reading-meter-progress-bar {
    height: 3px;
    background-color:#dddddd;
    width: 0%;
    }

    .reading-meter {
    visibility: hidden;
    }

    .reading-meter.show {
    visibility: visible;
    }

    I allow myself a correction:

    Add this into Custom Header

    <div class="reading-meter">
      <div class="reading-meter-progress">
        <div class="reading-meter-progress-bar" id="myBar"></div>
      </div> 
    </div>
    

    Sample CSS

    .reading-meter {
      position: fixed;
      top: 0px !important;
      z-index: 1111;
      width: 100%;
      background-color: #000000;
    }
    
    .reading-meter-progress {
    width: 100%;
    height: 3px;  z-index: 1111;
    background: #ffffff;
    }
    
    .reading-meter-progress-bar {
    height: 3px;
    background-color:#dddddd;
    width: 0%;
    }
    
  • @phenomlab said in Reading Meter Progress bar:

    Add this into Custom Header
    <div class=“reading-meter”>
    <div class=“reading-meter-progress”>
    <div class=“reading-meter-progress-bar” id=“myBar”></div>
    </div>

    Sample CSS
    .reading-meter {
    position: fixed;
    top: 0px !important;
    z-index: 1111;
    width: 100%;
    background-color: #000000;
    }

    .reading-meter-progress {
    width: 100%;
    height: 3px; z-index: 1111;
    background: #ffffff;
    }

    .reading-meter-progress-bar {
    height: 3px;
    background-color:#dddddd;
    width: 0%;
    }

    .reading-meter {
    visibility: hidden;
    }

    .reading-meter.show {
    visibility: visible;
    }

    I allow myself a correction:

    Add this into Custom Header

    <div class="reading-meter">
      <div class="reading-meter-progress">
        <div class="reading-meter-progress-bar" id="myBar"></div>
      </div> 
    </div>
    

    Sample CSS

    .reading-meter {
      position: fixed;
      top: 0px !important;
      z-index: 1111;
      width: 100%;
      background-color: #000000;
    }
    
    .reading-meter-progress {
    width: 100%;
    height: 3px;  z-index: 1111;
    background: #ffffff;
    }
    
    .reading-meter-progress-bar {
    height: 3px;
    background-color:#dddddd;
    width: 0%;
    }
    
    wrote on last edited by
    #4

    @downpw good spot. Thanks. Amended original post

  • Hello @phenomlab

    How do you do this reading-meter-progress bar ?

    e2756c2e-4771-46d4-a337-10bbe9c98b0a-image.png

    Thanks

    😉

    wrote on last edited by
    #5

    @downpw said in Reading Meter Progress bar:

    Hello @phenomlab

    How do you do this reading-meter-progress bar ?

    e2756c2e-4771-46d4-a337-10bbe9c98b0a-image.png

    Thanks

    😉

    I do like the look of this 👍🏻🤝

  • JAC JAC

    @downpw said in Reading Meter Progress bar:

    Hello @phenomlab

    How do you do this reading-meter-progress bar ?

    e2756c2e-4771-46d4-a337-10bbe9c98b0a-image.png

    Thanks

    😉

    I do like the look of this 👍🏻🤝

    wrote on last edited by
    #6

    @jac thanks !

  • wrote on last edited by
    #7

    @phenomlab

    it’s very great for continuous reading without pagination

  • @phenomlab

    it’s very great for continuous reading without pagination

    wrote on last edited by
    #8

    @downpw yes, it should auto update the progress based on the page length.

  • @downpw yes, it should auto update the progress based on the page length.

    wrote on last edited by
    #9

    @phenomlab liking the look of this although unsure if it was in blue if it would clash with the nav bar, although may fit in well on top of the yellow title block.

  • JAC JAC

    @phenomlab liking the look of this although unsure if it was in blue if it would clash with the nav bar, although may fit in well on top of the yellow title block.

    wrote on last edited by
    #10

    @jac you could use the yellow I suppose ?

  • @jac you could use the yellow I suppose ?

    wrote on last edited by
    #11

    @phenomlab very true, I don’t suppose white would really work out so yellow could be used yes 😁.

  • JAC JAC

    @phenomlab very true, I don’t suppose white would really work out so yellow could be used yes 😁.

    wrote on last edited by
    #12

    @jac said in Reading Meter Progress bar:

    @phenomlab very true, I don’t suppose white would really work out so yellow could be used yes 😁.

    I’m still not at home to do this, I wouldn’t even know the steps to do it I’m afraid 😆.

  • JAC JAC

    @jac said in Reading Meter Progress bar:

    @phenomlab very true, I don’t suppose white would really work out so yellow could be used yes 😁.

    I’m still not at home to do this, I wouldn’t even know the steps to do it I’m afraid 😆.

    wrote on last edited by
    #13

    @jac Steps are here 🙂

  • @jac Steps are here 🙂

    wrote on last edited by
    #14

    @phenomlab said in Reading Meter Progress bar:

    @jac Steps are here 🙂

    Many thanks will hopefully be able to achieve this once home tomorrow!

  • phenomlab phenomlab referenced this topic on
  • phenomlab phenomlab forked this topic on
  • wrote on last edited by
    #15

    For anyone else following this thread, please see
    https://sudonix.com/topic/467/issues-with-progress-bar-on-v3

  • phenomlab phenomlab has marked this topic as solved on
  • phenomlab phenomlab locked this topic on
  • phenomlab phenomlab referenced this topic on

Did this solution help you?
Did you find the suggested solution useful? Support 💗 Sudonix with a coffee ☕
If your organisation needs deeper expertise around infrastructure, security, or technology leadership, learn more about Phenomlab Ltd. Many of the deeper technical guides behind Sudonix are published there.

Related Topics
  • CSS code customization for the link preview plugin

    Solved Customisation css nodebb
    6
    2
    3 Votes
    6 Posts
    3k Views
    phenomlab
    @kadir-ay-0 marking as resolved based on https://community.nodebb.org/topic/17109/manual-build-a-night-mode-for-harmony/5 Please do not raise requests in two places - here and the NodeBB forums. All this does is create unnecessary load for both parties.
  • Material View Support for Stock NodeBB

    Unsolved Let's Build It material view javascript css
    51
    4
    15 Votes
    51 Posts
    27k Views
    DownPW
    Oh yes, that’s what’s super cool, I learn something every day. Afterwards I start from so low in JS
  • Rotating Star Effect

    Solved Let's Build It wordpress css
    17
    12 Votes
    17 Posts
    5k Views
    Hari
    @phenomlab thanks a lot for these, both of the below are awesome! https://codepen.io/bennettfeely/pen/vYLmYJz https://codepen.io/C-L-the-selector/pen/MWZbWBo
  • nodebb-user-level customisation : popover element

    Solved Customisation css user level plugin custom
    15
    6 Votes
    15 Posts
    5k Views
    DownPW
    No no, I said that in the sense that he told me it was simple ^^ I was able to see that this was not the case by targeting the elements he had advised me.
  • Footer bar add center text

    Solved Customisation css
    41
    1
    8 Votes
    41 Posts
    19k Views
    DownPW
    @phenomlab said in Footer bar add center text: div#console-nav-tab Ah ok test with bottom: 0px !important; idem
  • navigation bar is misplaced when the window gets smaller

    Solved Customisation bugs
    23
    1
    10 Votes
    23 Posts
    8k Views
    phenomlab
    @DownPW sounds good.
  • [NODEBB] Welcome Message

    Solved Customisation css html nodebb
    20
    2
    13 Votes
    20 Posts
    9k Views
    phenomlab
    @DownPW the ‘js’ code for the banner takes the time from the client, so what it displays really depends on the regional settings for the operating system. I’ve not seen this issue myself but would like to see some examples of screenshots if possible.
  • NodeBB Design help

    Solved Customisation
    8
    3
    2 Votes
    8 Posts
    4k Views
    phenomlab
    @riekmedia I’ve applied some new CSS to your site. Can you reload the page and try again ? For the record, this is what I added #footer { background: #2d343e; border-top: 4px solid #2d343e; font-size: 0.9em; margin-top: 70px; padding: 80px 0 0; position: relative; clear: both; bottom: 0; left: 0; right: 0; z-index: 1000; margin-left: -15px; margin-right: -338px; } The /categories page seems a bit messed up, so looking at that currently EDIT - issued some override CSS in the CATEGORIES widget <!--- CSS fix for overspill on /categories page - DO NOT DELETE --> <style> #footer { margin-right: -45px; } </style> That should resolve the /categories issue.