2.0.8 • Published 6 years ago

@storybynumbers/jck-navigation v2.0.8

Weekly downloads
-
License
MIT
Repository
bitbucket
Last release
6 years ago

JCK Navigation

Usage

const languageLinks = {
    en: '/en',
    nl: '/'
};
<Navigation absoluteDomain="//jck.nl"
            langLinks={languageLinks}
            language={this.state.language}
            pages={p.pages}
            menuShown={this.state.menuShown}
            toggle={this._toggleMenu}
            hide={this._hideMenu} />

Options

PropertyTypeDescription
absoluteDomainStringWebsites other than jck.nl should set this to "//jck.nl"
hideFunctionCallback function to set the menuShown property to false
languageStringLanguage (eg: 'en')
languageSelectorOptionsObjectOptions to pass to LanguageSelector
menuShownBooleanIf true, the menu will expand outwards.
pagesArrayMenu structure. Should be result from menu API endpoint. DEPRECIATED.
toggleFunctionCallback function to toggle the menuShown property

Building the library

This library component is based off the create-react-library starter kit. The build asset is an exportable module:

npm run build or yarn run build

This can be published to npm by bumping up the version number in package.json and running:

npm publish

Developing the library

Fire up a development environment based off src/demo/index.js:

HTTPS=true yarn start

2.0.8

6 years ago

2.0.7

6 years ago

2.0.6

6 years ago

2.0.5

6 years ago

2.0.4

6 years ago

2.0.3

6 years ago

2.0.2

6 years ago

2.0.1

6 years ago

2.0.0

7 years ago

0.1.3

7 years ago

0.1.2

7 years ago

0.1.1

7 years ago

0.1.0

7 years ago