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

pu-flickity-fullscreen

v1.1.2

Published

Enable fullscreen view of Flickity carousels

Downloads

8

Readme

Flickity fullscreen

Enable fullscreen view for Flickity carousels

Install

Add fullscreen.css to your stylesheets and fullscreen.js to your scripts.

Download

CDN

<link rel="stylesheet" href="https://unpkg.com/pu-flickity-fullscreen@1/fullscreen.css">
<script src="https://unpkg.com/pu-flickity-fullscreen@1/fullscreen.js"></script>

Package managers

npm: npm install pu-flickity-fullscreen

Bower: bower install pu-flickity-fullscreen

Usage

Enable fullscreen behavior by setting fullscreen: true in Flickity options.

// jQuery
var $carousel = $('.carousel').flickity({
  fullscreen: true,
});
// vanilla JS
var flkty = $('.carousel').flickity({
  fullscreen: true,
});
<!-- HTML -->
<div class="carousel" data-flickity='{ "fullscreen": true }'>
  ...
</div>

Webpack & Browserify

var Flickity = require('flickity-fullscreen');

var flkty = new Flickity( '.carousel', {
  fullscreen: true,
});

RequireJS

requirejs( [ 'path/to/flickity-fullscreen' ], function( Flickity ) {
  var flkty = new Flickity( '.carousel', {
    fullscreen: true,
  });
});

Style

.is-fullscreen is added to the carousel when fullscreen.

Size cells to take up full height with CSS.

/* normal */
.carousel-cell {
  height: 200px;
}

/* fullscreen */
.carousel.is-fullscreen .carousel-cell {
  height: 100%;
}

Methods

viewFullscreen

Expand carousel to fullscreen.

// jQuery
$carousel.flickity('viewFullscreen');

// vanilla JS
flkty.viewFullscreen();

exitFullscreen

Collapse carousel from fullscreen back to normal size & position.

// jQuery
$carousel.flickity('exitFullscreen');

// vanilla JS
flkty.exitFullscreen();

toggleFullscreen

Expand or collapse carousel fullscreen view.

// jQuery
$carousel.flickity('toggleFullscreen');

// vanilla JS
flkty.toggleFullscreen();

Events

fullscreenChange

Triggered after entering or exiting the fullscreen view.

// jQuery
$carousel.on( 'fullscreenChange.flickity', function( event, isFullscreen ) {...} );

// vanilla JS
flkty.on( 'fullscreenChange', function( isFullscreen ) {...} );
  • event · Event · jQuery event object
  • isFullscreen · Boolean · true if viewing fullscreen, false if exiting fullscreen

By Metafizzy 🌈🐻