A light-weight, responsive, mobile-like navigation menu plugin
Clone or download
Latest commit 1ccd449 Jul 12, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
dist Dependencies upgraded Jul 12, 2018
docs Dependencies upgraded Jul 12, 2018
src Set initial height on the menu Jan 8, 2018
.babelrc Dependencies upgraded Jul 12, 2018
.gitignore Version 4 Oct 24, 2017
bower.json Dependencies upgraded Jul 12, 2018
gulpfile.js Dependencies upgraded Jul 12, 2018
license License added Jul 12, 2018
package.json Dependencies upgraded Jul 12, 2018
readme.md Readme updated Jan 8, 2018
slinky.png Artwork updated Jul 12, 2018
yarn.lock Dependencies upgraded Jul 12, 2018

readme.md

Slinky

Rather sweet menus

A light-weight, responsive, mobile-like navigation menu plugin

Demo

Installation

Download the latest version. The files you need are

Bower

bower install jquery-slinky

Include these files

<script src="bower_components/slinky/dist/slinky.min.js"></script>

<link rel="stylesheet" src="bower_components/slinky/dist/slinky.min.css">

NPM

npm install jquery-slinky

Include these files

<script src="node_modules/slinky/dist/slinky.min.js"></script>

<link rel="stylesheet" src="node_modules/slinky/dist/slinky.min.css">

Usage

const slinky = $('.menu').slinky(options)

Options

Option Default Description
resize true Resize menu height to match content on navigation
speed 300 Animation speed in milliseconds
theme slinky-theme-default Slinky theme
title false Show title of sub menu

API

.home(animate)

Navigate back to the root menu

Option Default value Description
animate true Pass false to skip animation

.jump(target, animate)

Navigate to a sub menu

Option Default value Description
to Selector for ul target to jump to
animate true Pass false to skip animation

.destroy()

Remove Slinky

Tips

  • Set .active on a ul element to jump there on init