Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
carbon-pictograms-svelte
Advanced tools
Carbon Design System SVG pictograms as Svelte components
Carbon Design System SVG pictograms as Svelte components.
This zero dependency library builds Carbon Design System pictograms as Svelte components. Although best paired with carbon-components-svelte, this library can be consumed standalone.
Try it in the Svelte REPL.
# npm
npm i carbon-pictograms-svelte
# pnpm
pnpm i carbon-pictograms-svelte
# Yarn
yarn add carbon-pictograms-svelte
# Bun
bun add carbon-pictograms-svelte
<script>
import { Airplane } from "carbon-pictograms-svelte";
</script>
<Airplane />
Import pictograms directly for faster compiling.
import Airplane from "carbon-pictograms-svelte/lib/Airplane.svelte";
Note: Even if using the base import method, an application bundler like Rollup or webpack should tree shake unused imports.
import Pictogram from "carbon-pictograms-svelte/lib/<ModuleName>.svelte";
Refer to PICTOGRAM_INDEX.md for a list of available pictograms.
$$restProps
are forwarded to the svg
element.
Name | Value |
---|---|
tabindex | string (default: undefined ) |
fill | string (default: currentColor |
Customize the fill color using the fill
prop or by defining a global class.
fill
prop<Airplane fill="blue" />
<Airplane class="custom-class" />
<style>
:global(svg.custom-class) {
fill: blue;
}
</style>
<Airplane aria-label="Airplane" />
<Airplane aria-label="Airplane" tabindex="0" />
<label id="transportation">Transportation</label>
<Airplane aria-labelledby="transportation" />
Svelte version 3.31 or greater is required to use this library with TypeScript.
FAQs
Carbon Design System SVG pictograms as Svelte components
The npm package carbon-pictograms-svelte receives a total of 547 weekly downloads. As such, carbon-pictograms-svelte popularity was classified as not popular.
We found that carbon-pictograms-svelte demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
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.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.