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

indreka-primary-button

v1.1.4

Published

The primary button is a fundamental component of our design system. It is a prominent call-to-action button that is used to initiate an action or progress through a workflow.

Downloads

4

Readme

Introduction

The primary button is a fundamental component of our design system. It is a prominent call-to-action button that is used to initiate an action or progress through a workflow.

Anatomy

The primary button is composed of the following elements: The text displayed on the button, an icon (optional) that accompanies the label and the background color of the button.

Usage

The primary button is used to provide users with select/deselect option, and they can chose it like yes/no. It is typically used in forms, questionnaires, and surveys. The Checkbox is also used in filters, search options, and settings where users need to select/deselect some options. When designing a Checkbox, it is important to consider their accessibility, usability, and visual design.

Differences from Other Button Types

The primary button is different from other types of buttons in the following ways:

Secondary Button: The secondary button is a less prominent button that is typically used for secondary actions or to provide additional options. It has a lower visual weight and is often used in combination with the primary button.

Text Button: The text button is a button with no background or border that is used to emphasize text. It has a low visual weight and is used in combination with other buttons or as a standalone element.

Icon Button: The icon button is a button that displays an icon without any label or background. It has a low visual weight and is used in combination with other buttons or as a standalone element.

Primary Button Sizes

The table below provides the size specifications: | Size | Height | | ------------- | ------ | | Mobile | 40 px | | Tablet | 42 px | | Web/Desktop | 44 px |

Primary Button Colors

The table below provides the color specifications: | Color | Hex code | | --------- | ------- | | Primary-1 | #FFB42A | | Neutral-1 | #262626 | | Neutral-2 | #6C6969 | | Neutral-3 | #FFFFFF |

Primary Button States

The Primary Button component has several states, depending on the user's interaction with it | Color | Description | | -------- | ---------------------------------------------------------------------- | | Default | The initial state of the Primary Button component | | Hover | When the user hovers the mouse pointer over the Primary Button | | Pressed | When the user clicks on the Primary Button component | | Disabled | When the Primary Button is not available for interaction |

indreka-primary-button component

The <indreka-primary-button></indreka-primary-button> component having the following attributes:

  1. type having type of string.
  2. label having type of string.
  3. disabled having type of boolean.
  4. describerId having type of string.

Attributes and usage

we can pass attributes inside like:

  1. disabled <indreka-primary-button disabled>Text</indreka-primary-button>

-- This will disable the button preventing the user to perform any mouse events on button and also update the aria-disabled.

  1. type <indreka-primary-button type="submit">Text</indreka-primary-button> <indreka-primary-button type="reset">Text</indreka-primary-button>

    -- type has two values: submit and reset, submit will enable form submission and reset will reset the form fields.

  2. label <indreka-primary-button label="labelName">Text</indreka-primary-button>

    -- This will add a label which will be shown for aria-label property.

  3. describerId <indreka-primary-button describerId="describerElement">Text</indreka-primary-button>

    -- Describer id will require the name of an element that is describing the button/any information about button. will update aria-describedby.

Angular Usage

In the module.ts, import the component after installing from NPM.

import 'indreka-primary-button';

Now, we can use the component in template as:

<indreka-primary-button>ButtonName</indreka-primary-button>