New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@asphalt-react/badge

Package Overview
Dependencies
Maintainers
0
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@asphalt-react/badge

Badge

2.0.0-rc.0
npm
Version published
Weekly downloads
38
-24%
Maintainers
0
Weekly downloads
 
Created
Source

Badge

npm

A Badge nudges users to notify them of any action that took place or status of an element or feature. It accepts content to show a value, for example number of notifications, or text like "new" or "coming soon". You can choose to display text content in uppercase. Badges have different intents and defaults to "neutral".

Usage

import { Badge } from "@asphalt-react/badge"

<Badge />

<Badge>25</Badge>

Intents

Badge supports 6 intents:

  • neutral (default): demands less user attention
  • brand: brand related nudges
  • danger: denotes an element of risk like deletion
  • success: nudges to denote successful actions
  • info: an informative nudge
  • warning: demands more attention than info

Props

children

Content for Badge.

typerequireddefault
nodefalsenull

neutral

Applies neutral intent.

typerequireddefault
boolfalsefalse

brand

Applies brand intent.

typerequireddefault
boolfalsefalse

danger

Applies danger intent.

typerequireddefault
boolfalsefalse

warning

Applies warning intent.

typerequireddefault
boolfalsefalse

info

Applies info intent.

typerequireddefault
boolfalsefalse

success

Applies success intent.

typerequireddefault
boolfalsefalse

uppercase

Transforms the text to uppercase.

typerequireddefault
boolfalsefalse

Keywords

asphalt

FAQs

Package last updated on 10 Jul 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts