2.0.1 • Published 7 days ago

@warp-ds/icons v2.0.1

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
7 days ago

WARP icons

The icon set for WARP, imported from (Figma project)!https://www.figma.com/file/yEx16ew6S0Xgd579dN4hsM/Warp---Icons?type=design&node-id=150-113&mode=design&t=TRtIuPlsDoYlbuqd-0.

Note that the icons in the "src/raw" folder in this repository should never be used directly, as they aren't optimized.

How to use

React

Install dependencies

npm install @warp-ds/icons

Import React icons

import { IconBag16 } from '@warp-ds/icons/react';
<IconBag16 />

Vue

Install dependencies

npm install @warp-ds/icons

Import Vue icons

import { IconChevronRight16 } from '@warp-ds/icons/vue';
<icon-chevron-right16 />

Elements

Install dependencies

You will need to install both Warp Elements and Lit Element which is the library we use for custom elements

npm install lit @warp-ds/icons

Import elements

Import the individual element file, importing will load the component. Once imported, run your script through whatever bundling process your app uses (Rollup, Esbuild, etc) after which the component can be used in the page.

import '@warp-ds/icons/elements/attachment-16';
import '@warp-ds/icons/elements/attachment-24';
<w-icon-attachment16></w-icon-attachment16>
<w-icon-attachment24></w-icon-attachment24>

Development

Updating the icons

Icons should never be added or edited manually in this repository, as the source of truth is in Figma.

Figma access token

If you are running the import script for the first time, it will prompt your for a Figma access token. The token is is required to access Figma's API. It can be generated on your Figma account settings page.

The import script may store the token to a local file, so you won't have to supply the token again on subsequent runs.

Import script

To update the icons, run the following script. If it has a valid Figma access token (see previous section), it will proceed to download all the icons as SVG files.

./scripts/import.js

or

pnpm import

Local preview

You can open a local preview of the icons. Use this to verify that the icons looks as they should. Run the following command.

pnpm dev

Releases

This project is continuously published to NPM and Eik using an alpha tag (e.g. 1.1.0-alpha.1). Anyone needing to use the latest changes of this package can point to the alpha version while waiting for the stable release.

Eik versions for each of Vue, Elements and React icons that are built to the ./dist folder are automatically published to Eik under the path https://assets.finn.no/pkg/{name}/{version}/.

Example Paths:

  • React: https://assets.finn.no/pkg/@warp-ds/icons/v1/react/icons.min.js
  • Vue: https://assets.finn.no/pkg/@warp-ds/icons/v1/vue/icons.min.js
  • Custom Elements: https://assets.finn.no/pkg/@warp-ds/icons/v1/elements/icons.min.js
  • Raw ads svg at size 16: https://assets.finn.no/pkg/@warp-ds/icons/v1/16/ads.svg
  • Raw air con svg at size 24: https://assets.finn.no/pkg/@warp-ds/icons/v1/24/air-con.svg

Changelog

Detailed changes for each release can be found in the CHANGELOG file.

License

@warp-ds/icons is available under the Apache-2.0 software license.

2.0.2-next.1

7 days ago

2.0.1

1 month ago

2.0.1-next.1

1 month ago

2.0.0-next.1

4 months ago

2.0.0

4 months ago

1.6.0-next.2

4 months ago

1.6.0-next.1

4 months ago

1.5.0-next.4

4 months ago

1.5.1

4 months ago

1.5.0

4 months ago

1.5.1-next.1

4 months ago

1.5.0-next.3

4 months ago

1.5.0-next.2

4 months ago

1.5.0-next.1

4 months ago

1.4.1-next.2

4 months ago

1.4.1-next.1

4 months ago

1.4.0

5 months ago

1.4.0-next.4

5 months ago

1.4.0-next.3

6 months ago

1.4.0-next.1

6 months ago

1.4.0-next.2

6 months ago

1.3.0

6 months ago

1.3.0-next.2

6 months ago

1.3.0-next.1

6 months ago

1.2.1-next.1

6 months ago

1.2.0

6 months ago

1.2.0-next.1

6 months ago

1.1.2-next.2

7 months ago

1.1.2-next.1

7 months ago

1.1.1

7 months ago

1.1.1-next.2

7 months ago

1.1.1-next.1

7 months ago

1.1.0

7 months ago

1.1.0-next.14

7 months ago

1.1.0-next.13

7 months ago

1.1.0-next.12

7 months ago

1.1.0-next.11

7 months ago

1.1.0-next.10

8 months ago

1.1.0-next.9

8 months ago

1.1.0-next.8

8 months ago

1.1.0-next.7

8 months ago

1.1.0-alpha.3

8 months ago

1.1.0-alpha.2

8 months ago

1.1.0-alpha.1

8 months ago

1.1.0-alpha.0

8 months ago

1.1.0-next.6

8 months ago

1.1.0-next.5

8 months ago

1.1.0-next.4

8 months ago

1.1.0-next.3

8 months ago

1.1.0-next.2

8 months ago

1.1.0-next.1

8 months ago

1.0.1-next.1

8 months ago

1.0.0-next.1

8 months ago

1.0.0

8 months ago

1.0.0-alpha.1

8 months ago