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

@ifsworld/granite-icons

v1.5.2

Published

This package includes icon font files and related css files for granite icons. Currently two types of icon fonts are supported.

Downloads

1,849

Readme

granite-icons

This package includes icon font files and related css files for granite icons. Currently two types of icon fonts are supported.

  • Ligature based
  • Glyph based

How to import

// For ligature based icons
@import '@ifsworld/granite-icons/assets/fonts/ligature/granite-iconfont-liga.css';

// For legacy glyph based icons
@import '@ifsworld/granite-icons/assets/fonts/glyph/granite-iconfont-glyph.css';

General Usage

<!-- For ligature based icons -->
<div class="granite-icon">alert</div>

<!-- For legacy glyph based icons -->
<div class="granite-icon icon-phone"></div>

Usage with granite-icon

<!-- For ligature based icons -->
<granite-icon>alert</granite-icon>

<!-- For legacy glyph based icons -->
<granite-icon fontIcon="icon-phone"></granite-icon>

All Icons

For a list of all icons, refer the storybook static build.

Adding icons to granite-icons

In order to add new icons or to change existing icons in granite-icons packages (both npm and nuget), the related svg files should be added to /assets/icons folder. However, to maintain a single source of truth for granite-icons, the process of adding the svgs to /assets/icons folder is also automated. Granite-Icons figma file will act as the single source of truth. Once you add a new icon to this file (of course with a help of a ux-designer), all you have to do is fetch the icons with npm run fetch-icons and commit the changes.

If you follow semantic-versioning guidelines when committing, the packages will be automatically published in the bitbucket pipelines.

Quality assuring the granite-icons generation process

Since most of the icon font generation process is automated, we need to make sure that the granite-icons packages keep working as expected. We run cypress snapshot testing to verify the changes that we make doesn't break the existing behavior. Therefore, ideally when you add/change an icon, the automated e2e tests in the pipeline should fail.

To avoid these failures, image snapshots should be updated locally and it should be verified manually that the diff you see represents only the change you have made. To run the tests locally run cypress:granite-icons-demo:snapshots command and if there is a diff, it will be shown in the cypress/snapshots/__diff_output__ folder. If this diff makes sense, update the snapshots with cypress:granite-icons-demo:snapshots:update command and commit the snapshot changes along with the icons.