npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

panelify

v1.1.0

Published

smooth vertical panel sliding using waypoints

Downloads

17

Readme

logo

Build Status

Smooth vertical sliding panels using Waypoints.

Installation

npm i panelify --save

Basic Usage

Quickstart: see the demo

HTML

Panelify requires markup similar to the following (a transparent-padder element is needed to fill the space when overlaying panels):

<div id="transparent-padder"></div>

<div class="panelify">
    Panel 1 content... 
</div>
<div class="panelify">
    Panel 2 content...
</div>
<div class="panelify">
    Panel 3 content...
</div>

CSS

Customise as necessary, but a nice and simple example can be found in the demo css.

JavaScript

This is a front end package; the current easiest way to implement it is:

<script src="[Path to node_modules goes here]/panelify/dist/panelify.js"></script>

Then you can call it in your own script like:

// grab and initialise the waypoint offset to bottom-in-view (bottom of each panel)
var panelify = new Panelify();

Options

offset: either 0% or bottom-in-view (default: bottom-in-view)

  • 0%: this triggers the panelify event as soon as the top of the panel is in the viewport (nicer for short content that fits in one 'screen')

    1. Example: var panelify = new Panelify('0%');
  • bottom-in-view (default): this triggers the panelify event when the bottom of the current panel comes into the viewport (better for longer content).

    1. Example: let panelify = new Panelify();
    2. Example: let panelify = new Panelify('bottom-in-view');

minScreenWidth: the minimum screen width (in pixels) where panelify will be triggered and non static (default: 1068)

  • NOTE: anything less than 1068 is not officially supported and shouldn't be used in production.

    1. It will still work on all desktop browsers if decreased (e.g. if a browser is resized)

    2. Phones/Tablets bug out to various degrees (Safari iOS on iPhone/iPad handle it well, except for when the popup menus appear if overscrolled. Android phones bug out for more complicated reasons).

Build

src/panelify.js transpiles, minifies and is copied to dist/panelify.js.

Basic

  • Clone/download repo
  • cd to the panelify/ directory
  • npm install

Development

  • webpack - for building once for development
  • webpack --watch - for continuous incremental build in development

Production

  • webpack -p - for building for production (minification)

Browser Support

Desktop: Chrome, Firefox, Safari, Edge, IE9+

Tablet/Mobile: None yet. Falls back to static panels (unless defaults are overridden). This is due to issues with the built-in URL/Navigation bars have meant this is still under development.

Contributing

See issues; general feature improvements are also welcome!

License

Panelify is licensed under the MIT License.