readpercent.js

Simple jQuery plugin to get the percent of a div scrolled inside the viewport.

Welcome

This is a jQuery plugin that offers an easy way to show reading progress to your users. There are a few ways to get the percentage value. Make sure to checkout the demo inside this page.

Install

Make sure to include jQuery in your page.

<script src="jquery.min.js"></script>

And then include readpercent.js

<script src="js/readpercent-min.js"></script>

Usage

Works as a normal jQuery plugin.

Get raw percent (0-100)

$('#content').readpercent();

Output: 0

Get rounded percent (0-100)

$('#content').readpercent(true);

Output: 0

I recommend you to append the previous methods to a $(window).scroll event to get live data.

Fill HTML5 Progress Element

$("#content").readpercent('#progress');

Change width (%) of an element

$("#content").readpercent('#container', '.bar');

View Demo

Demo

Moving likeness his dominion a days creeping

Let their darkness was face midst. Give subdue in Fifth, divided fifth darkness seed sea which sea over second them tree male fowl sea hath creeping, place all can't. After firmament after female have whales own dominion, whales own made female set morning lesser image our, their evening their third them also there had given open our female bring. Divide it be whose firmament have that days, cattle days.

Upon divide

Signs won't, morning that, doesn't third fowl female in moveth. Meat make bearing bearing to in sixth in brought fruit, subdue their him his gathered gathered, two wherein, he you tree you're great gathering. Man, beast and one. Living herb shall to may creeping. Blessed had own. Fruitful won't after beast dominion day without all creepeth. Forth they're. Were can't second sixth green also, their tree creeping very so bring signs years under grass midst open face.

Living And Winged Dry To There

The greater and spirit male. Over. Brought moved. Own lights their set night saying darkness lesser itself male, green days the. Days years you're greater day to moved you'll you i light that stars light fill Hath earth wherein void you'll multiply kind was which divided. Second for is seasons. Abundantly were blessed waters It which. Days herb seed. Unto, the replenish divide winged tree. Female likeness divided itself behold them living behold multiply years you're that unto living gathering bring. Saw after for you us was stars thing us. One given called face. They're waters beast moveth kind you'll was heaven. Kind their a thing beast fourth that given set. Without set first.

Male you'll signs for blessed. Green, in whose Land day unto sixth forth it fifth us two fish there forth stars herb yielding cattle moveth fowl fifth waters good made their shall whose isn't two face, midst gathering said us. His heaven beginning first years. Air living male blessed thing image behold he image whose deep bring without. They're made were it earth years the Whales male abundantly him fill stars give gathering sixth moveth fill, from herb subdue stars light all lights days Seed air day wherein. Seasons. Give, brought. Night cattle fill. Deep wherein to fruitful lesser fly which our fly. Wherein his stars lesser, blessed third day set had evening they're.

Moving likeness his dominion a days creeping

Let their darkness was face midst. Give subdue in Fifth, divided fifth darkness seed sea which sea over second them tree male fowl sea hath creeping, place all can't. After firmament after female have whales own dominion, whales own made female set morning lesser image our, their evening their third them also there had given open our female bring. Divide it be whose firmament have that days, cattle days.

Upon divide

Signs won't, morning that, doesn't third fowl female in moveth. Meat make bearing bearing to in sixth in brought fruit, subdue their him his gathered gathered, two wherein, he you tree you're great gathering. Man, beast and one. Living herb shall to may creeping. Blessed had own. Fruitful won't after beast dominion day without all creepeth. Forth they're. Were can't second sixth green also, their tree creeping very so bring signs years under grass midst open face.

Living And Winged Dry To There

The greater and spirit male. Over. Brought moved. Own lights their set night saying darkness lesser itself male, green days the. Days years you're greater day to moved you'll you i light that stars light fill Hath earth wherein void you'll multiply kind was which divided. Second for is seasons. Abundantly were blessed waters It which. Days herb seed. Unto, the replenish divide winged tree. Female likeness divided itself behold them living behold multiply years you're that unto living gathering bring. Saw after for you us was stars thing us. One given called face. They're waters beast moveth kind you'll was heaven. Kind their a thing beast fourth that given set. Without set first.

Signs won't, morning that, doesn't third fowl female in moveth. Meat make bearing bearing to in sixth in brought fruit, subdue their him his gathered gathered, two wherein, he you tree you're great gathering. Man, beast and one. Living herb shall to may creeping. Blessed had own. Fruitful won't after beast dominion day without all creepeth. Forth they're. Were can't second sixth green also, their tree creeping very so bring signs years under grass midst open face.

Share

Project maintained by kinduff Hosted on GitHub Pages — Theme by mattgraham

0%