Socket
Book a DemoInstallSign in
Socket

dusk-react

Package Overview
Dependencies
Maintainers
1
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dusk-react

react components for dusk icons

latest
Source
npmnpm
Version
1.1.3
Version published
Maintainers
1
Created
Source

dusk-react npm version

React components for Dusk icons.

Install

# npm
$ npm install dusk-react

# yarn
$ yarn add dusk-react

Usage

Import using object destructuring:

import { Safari } from 'dusk-react';

const Component = () => (
  <Safari />
);

Import an icon directly:

import Safari from 'dusk-react/dist/icons/safari';

const Component = () => (
  <Safari />
);

Import all of the icons:

import * dusk from 'dusk-react';

const Component = () => (
  <dusk.Safari />
);

Props

size(number)

The size, in pixels, of the icon. Applies to both the width and the height.

bg(string)

Background color of the icon.

fg(string)

Foreground color of the icon.

fg2(string)

Secondary foreground color of the icon, if applicable.

Example

import { Safari } from 'dusk-react';

const Component = () => (
  <Safari
    size={300}
    bg="blue"
    fg="#FFEFD5"
  />
);

Note

The 1Password icon is exported as Password, because Javascript variable names cannot begin with a number.

  • Dusk: simple, customizable macOS application icons

FAQs

Package last updated on 28 Nov 2019

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