Skip to content

Commit

Permalink
Published package to NPM, removed bower support
Browse files Browse the repository at this point in the history
  • Loading branch information
christophery committed Aug 29, 2017
1 parent f7d99ca commit ed02662
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 38 deletions.
2 changes: 1 addition & 1 deletion LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
The MIT License (MIT)

Copyright (c) 2017 Christopher Yee
http://www.christopheryee.ca
https://chrisyee.ca

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
Expand Down
57 changes: 26 additions & 31 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# Pushy
#Pushy

Pushy is a responsive off-canvas navigation menu using CSS transforms & transitions. This project was inspired by the off-canvas navigation menu seen on [Medium](https://medium.com/).

Pushy has been implemented on many sites, [check them out!](https://github.com/christophery/pushy#sites-using-pushy) Feel free to [let me know](https://www.twitter.com/cmyee) if you use Pushy in one of your websites.
Pushy has been implemented on many sites, [check them out!](https://github.com/christophery/pushy#sites-using-pushy) Feel free to [let me know](http://www.twitter.com/cmyee) if you use Pushy in one of your websites.

[View Demo](https://chrisyee.ca/pushy) | [Sites using Pushy](https://github.com/christophery/pushy#sites-using-pushy)

## Features
##Features

- Uses CSS transforms & transitions.
- Smooth performance on mobile devices.
Expand All @@ -17,11 +17,11 @@ Pushy has been implemented on many sites, [check them out!](https://github.com/c
- Left or right menu position.
- It's responsive!

## Requirements
##Requirements

- [jQuery 1.9+](http://jquery.com/)

## Install
##Install

Download the [packaged source file](https://github.com/christophery/pushy/archive/master.zip), this includes everything you need to get Pushy running on your site.

Expand Down Expand Up @@ -61,26 +61,15 @@ Download the [packaged source file](https://github.com/christophery/pushy/archiv
</div>
```

## Bower
##NPM

If your are comfortable with command line, you can install Pushy as a [Bower](http://bower.io/) package:
If your are comfortable with command line, you can install Pushy as a [NPM package](https://www.npmjs.com/package/@cmyee/pushy):

```
bower install pushy
npm install @cmyee/pushy
```

## WordPress

Pushy works great with WordPress, here are some general tips to get it working with your theme:

- Use the **console in your browser** to troubleshoot errors in your theme.
- Make sure you are [enqueuing](https://developer.wordpress.org/reference/functions/wp_enqueue_script/) the scripts correctly in your theme.
- Pushy requires **jQuery**, so be sure to load it as a [dependancy](https://developer.wordpress.org/reference/functions/wp_enqueue_script/).
- If you are using [wp_nav_menu](https://developer.wordpress.org/reference/functions/wp_nav_menu/) with Pushy, you will need to use a [Walker](https://codex.wordpress.org/Class_Reference/Walker) to add the CSS classes Pushy requires.

**NOTE: This is not a WordPress plugin.**

## Tips
##Tips

- Use the ```.pushy-left``` or ```.pushy-right``` CSS class to specify the menu position.

Expand Down Expand Up @@ -194,7 +183,7 @@ html, body{
</nav>
```

## Browser Compatibility
##Browser Compatibility

| Desktop | Mobile |
| ------------- | -------------------------------------------|
Expand All @@ -204,17 +193,23 @@ html, body{
| Firefox |
| Safari (Mac) |

## Version History
##Version History

1.1.1

- Published package to NPM.
- Removed Bower support.
- Updated demo & personal site links.

1.1.0

- Accessibility (a11y) enhancements:
* Can access and use menu with keyboard navigation.
* Can use the escape key to close the menu when opened.
* Changed the empty submenu links to buttons.
* Added `data-focus` attribute to allow user to specify a link to focus on when menu is opened.
* Added `.pushy-content` element to menu structure (fixes visibility flickering).
* Changed `.menu-btn` div to button.
- Accessiblity (a11y) enhancements:
a) Can access and use menu with keyboard navigation.
b) Can use the escape key to close the menu when opened.
c) Changed the empty submenu links to buttons.
d) Added `data-focus` attribute to allow user to specify a link to focus on when menu is opened.
e) Added `.pushy-content` element to menu structure (fixes visibility flickering).
f) Changed `.menu-btn` div to button.

- Removed some redundant CSS classes from `pushy.css`.
- Removed `toggleSubmenuFallback` function, older browsers will use `toggleSubmenu` instead.
Expand Down Expand Up @@ -264,7 +259,7 @@ html, body{
- Updated the demo file
- Updated the read me

## Sites using Pushy
##Sites using Pushy

Pushy has been implemented on many sites in the wild, check them out:

Expand All @@ -285,7 +280,7 @@ Pushy has been implemented on many sites in the wild, check them out:

To add your site, tweet to me [@cmyee](https://twitter.com/cmyee).

## Thanks to
##Thanks to

- [HTML5 Boilerplate](http://html5boilerplate.com/)
- [jQuery](http://jquery.com/)
2 changes: 1 addition & 1 deletion demo.html
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@

<p>Praesent id metus imperdiet, congue leo sed, eleifend purus. Donec congue scelerisque tempus. Maecenas eget nunc pharetra, laoreet enim sed, dictum odio. Sed non mollis purus. Aliquam aliquet, risus eget dictum commodo, neque mi dapibus ipsum, tempus iaculis elit lorem pharetra mauris. Vivamus pulvinar scelerisque lectus a congue. Sed vitae odio massa. Pellentesque condimentum sit amet arcu in convallis.</p>

<p>Etiam dapibus nisl nibh, et <a href="https://christopheryee.ca">commodo nisi</a> euismod vehicula. In consectetur eleifend felis, eget iaculis lectus scelerisque vel. Mauris non nibh nec sem consequat dapibus sed at tellus. Nunc egestas ac diam sed pretium. Praesent ultrices malesuada nisi at ornare. Aliquam arcu eros, pellentesque vitae fringilla ac, rhoncus id urna. Curabitur sit amet tortor eu neque sollicitudin congue. Proin mattis, diam quis ullamcorper iaculis, metus lectus vulputate tellus, id imperdiet nibh ante vel risus. Nam ut mi libero. Suspendisse auctor neque at pulvinar vestibulum. Suspendisse potenti. Cras molestie eros at feugiat gravida.</p>
<p>Etiam dapibus nisl nibh, et <a href="https://chrisyee.ca">commodo nisi</a> euismod vehicula. In consectetur eleifend felis, eget iaculis lectus scelerisque vel. Mauris non nibh nec sem consequat dapibus sed at tellus. Nunc egestas ac diam sed pretium. Praesent ultrices malesuada nisi at ornare. Aliquam arcu eros, pellentesque vitae fringilla ac, rhoncus id urna. Curabitur sit amet tortor eu neque sollicitudin congue. Proin mattis, diam quis ullamcorper iaculis, metus lectus vulputate tellus, id imperdiet nibh ante vel risus. Nam ut mi libero. Suspendisse auctor neque at pulvinar vestibulum. Suspendisse potenti. Cras molestie eros at feugiat gravida.</p>

<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer pharetra neque a diam cursus pulvinar. Suspendisse faucibus mi id accumsan lobortis. Pellentesque consectetur varius turpis, nec viverra justo pellentesque sit amet. Vestibulum convallis leo non purus vehicula, non faucibus libero rhoncus. Morbi aliquam tincidunt facilisis. Aenean sodales nulla ac semper consectetur. Vivamus commodo massa convallis justo posuere vestibulum. Aenean congue non mauris ac auctor. Ut suscipit et eros nec suscipit. Nulla congue, mauris nec bibendum sagittis, urna orci tincidunt massa, in vulputate velit nulla vitae nunc. Etiam urna justo, imperdiet nec orci sollicitudin, tempus feugiat erat. Vivamus id lectus nulla. Vestibulum sagittis cursus metus vel ultricies. Suspendisse viverra interdum metus eu placerat. Quisque tristique velit nisi, scelerisque consectetur tortor vehicula ut. Donec id fermentum mi, nec <a href="https://google.ca">venenatis felis.</a></p>

Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"name": "Pushy",
"name": "@cmyee/pushy",
"description": "Pushy is a responsive off-canvas navigation menu using CSS transforms & transitions",
"version": "1.1.0",
"homepage": "https://chrisyee.ca/pushy",
"version": "1.1.1",
"homepage": "https://chrisyee.ca/pushy/",
"author": {
"name": "Christopher Yee",
"name": "Chris Yee",
"url": "https://chrisyee.ca/"
},
"devDependencies": {
Expand All @@ -14,4 +14,4 @@
"grunt-contrib-concat": "~0.4.0",
"grunt-contrib-uglify": "~0.4.0"
}
}
}

0 comments on commit ed02662

Please sign in to comment.