0.5.30 • Published 4 years ago

dheader v0.5.30

Weekly downloads
3
License
MIT
Repository
github
Last release
4 years ago

Table of Contents

DynamicHeader

DynamicHeader

A dynamic header for web pages.

Please download the repo and open the file index.html to see the usage.

Install DynamicHeader in your Node project with

and use it inside your code via

or, alternatively

You can also use it without node, by embedding the script dynamic-header.min.js in your web page.

Without any arguments, DynamicHeader.init() will search for a container with id="header" or a tag header and will make that container the dynamic header.

init

Parameters

  • settings any?
    • settings.headerId String? Specify the id of the container you want to make the dynamic header. Default is 'header'. If not specified will search for the html header tag.
    • settings.delta Number? The number of pixels a user need to scroll at least in order to make DynamicHeader react on scrolling. Default is 25.
    • settings.fixed Boolean? If set to true, the header will never slide out of the way. Default is false.
    • settings.hideOnClick Boolean? If set to true, the header will slide out of the way when a click occurred inside the header. Default is true. Will be ignored when config.fixed is true.
    • settings.pauseDuration Number? When the header is hidden away after a click, the sliding mechanism is paused for a duration of 250 milliseconds to avoid interference with scrolling. Change the default here in terms of milliseconds.
    • settings.slideIn String? Provide a CSS class name to be applied to the header whenever the header is sliding into the page (which is the case when the user is scrolling up). The class will only be applied as long as the user is able to scroll up. Once the top of the page is reached, the class will be removed from the header. Default class name is slide-in. The header will have the CSS class is-dynamic when activated.
    • settings.callback Object? A callback function to be called whenever the header changes. The header is given as an argument into the callback.

destroy

Revert all changes that have been made by DynamicHeader;

0.5.30

4 years ago

0.5.29

4 years ago

0.5.28

4 years ago

0.5.27

4 years ago

0.5.22

4 years ago

0.5.25

4 years ago

0.5.26

4 years ago

0.5.23

4 years ago

0.5.24

4 years ago

0.5.21

4 years ago

0.5.20

4 years ago

0.5.18

4 years ago

0.5.19

4 years ago

0.5.17

4 years ago

0.5.16

4 years ago

0.5.15

4 years ago

0.5.14

4 years ago

0.5.13

4 years ago

0.5.11

4 years ago

0.5.12

4 years ago

0.5.10

4 years ago

0.5.6

4 years ago

0.5.8

4 years ago

0.5.7

4 years ago

0.5.9

4 years ago

0.5.5

4 years ago

0.5.4

4 years ago

0.5.3

4 years ago

0.5.0

4 years ago

0.5.1

4 years ago

0.3.19

4 years ago

0.3.18

4 years ago

0.3.17

4 years ago

0.3.16

4 years ago

0.3.15

4 years ago

0.3.14

4 years ago

0.3.13

4 years ago

0.3.12

4 years ago

0.3.11

4 years ago

0.3.10

4 years ago

0.3.9

4 years ago

0.3.8

4 years ago

0.3.6

4 years ago

0.3.5

4 years ago

0.3.7

4 years ago

0.3.2

4 years ago

0.3.4

4 years ago

0.3.3

4 years ago

0.3.1

4 years ago

0.3.0

4 years ago

0.2.1

4 years ago

0.2.0

4 years ago

0.1.1

5 years ago

0.1.0

5 years ago

0.0.19

5 years ago

0.0.18

5 years ago

0.0.16

5 years ago

0.0.15

5 years ago

0.0.14

5 years ago

0.0.13

5 years ago

0.0.12

5 years ago

0.0.11

5 years ago

0.0.10

5 years ago

0.0.9

5 years ago

0.0.8

5 years ago

0.0.7

5 years ago

0.0.6

5 years ago

0.0.5

5 years ago

0.0.4

5 years ago

0.0.3

5 years ago

0.0.2

5 years ago

0.0.1

5 years ago