@mal-icons/solid
v0.7.11
Published
SolidJS components for mal-icons.
Downloads
1,336
Maintainers
Readme
@mal-icons/solid
SolidJS adapter for mal-icons — a high-performance, tree-shakeable icon SDK. Each icon is a pre-generated Solid component with fine-grained reactivity and no runtime parsing.
Highlights
- Fine-grained reactivity — built on Solid's
mergeProps/useContext. - Tree-shakeable — every icon is its own module.
- Themeable —
IconContextprovider with per-icon overrides. - Pure-CSS animations —
spin,pulse,beat,bounce,ping,shake,wiggle,float,heartbeat,flip,rotate,zoom,fade,slide,glow,swing,tada, with aprefers-reduced-motionguard. - Accessible — correct
role/aria-hiddenand optional<title>.
Installation
bun add @mal-icons/solid
# or
npm install @mal-icons/solidRequires
solid-js1.8 or newer (peer dependency).
Use with AI agents
AI coding agents can add and theme these icons for you via the
mal-icons agent skill. Install it with the
skills CLI:
npx skills add mal-icons/mal-iconsThen ask your agent to "add a trash icon" and it searches the catalog and writes
the correct @mal-icons/solid import. See the
Solid setup guide.
Quick start
import { FiActivity } from "@mal-icons/solid/fi";
export function Status() {
return <FiActivity size={24} title="Status" />;
}App-wide theming
import { IconContext } from "@mal-icons/solid";
<IconContext.Provider value={{ size: 20, color: "#3366ff" }}>
<App />
</IconContext.Provider>;Per-icon props always override context values.
Props
| Prop | Type | Description |
| ---------------- | ------------------------------------------------------------------------------ | ---------------------------------------------------- |
| size | number \| string | Width and height (defaults to 1em) |
| color | string | Overrides currentColor |
| multicolor | boolean | Keep the icon's own colors (omits the currentColor stroke/fill defaults) |
| weight | "thin" \| "light" \| "regular" \| "bold" | Stroke weight for stroke-based sets |
| animate | IconAnimation ("spin", "pulse", "bounce", "shake", "heartbeat", …) | CSS animation preset |
| secondaryColor | string | Multi-tone color, exposed as --mal-icons-secondary |
| title | string | Accessible label |
| class | string | Additional class names |
Animations
import { ICON_ANIMATIONS_CSS } from "@mal-icons/solid";
<style>{ICON_ANIMATIONS_CSS}</style>;
<FiLoader animate="spin" />;API
import {
IconBase,
createIcon,
IconContext,
DefaultIconContext,
ICON_ANIMATIONS_CSS,
WEIGHT_STROKE_WIDTH,
animationClass,
} from "@mal-icons/solid";Icons
The bundled icon sets, their upstream licenses, pinned versions, and counts:
| Icon Library | License | Version | Count | | ---------------------------------------- | --------------------------------------------------------------------------------- | ------- | ----: | | Ant Design Icons | MIT license | 4.0.0 | 420 | | Circum Icons | MPL-2.0 license | 2.0.2 | 288 | | Codicons | CC BY 4.0 license | 0.0.46 | 604 | | css.gg | MIT license | 2.1.1 | 704 | | Devicons | MIT license | 2.0.1 | 1725 | | Feather | MIT license | 4.29.0 | 287 | | Flat Color Icons | CC BY 4.0 license | 1.0.2 | 312 | | Font Awesome Free | CC BY 4.0 license | 6.7.2 | 1402 | | Font Awesome Free Brands | CC BY 4.0 license | 6.7.2 | 495 | | Font Awesome Free Regular | CC BY 4.0 license | 6.7.2 | 163 | | Grommet | Apache 2.0 license | 4.14.0 | 637 | | Heroicons | MIT license | 2.2.0 | 324 | | Ionicons | MIT license | 8.0.13 | 1357 | | Lucide | ISC license | 1.19.0 | 1727 | | Octicons | MIT license | 19.28.1 | 733 | | Radix Icons | MIT license | 0.0.17 | 318 | | Simple Line Icons | MIT license | 2.5.5 | 189 | | Themify | SIL OFL 1.1 license | 9600186 | 352 | | Typicons | CC BY-SA 4.0 license | 2.1.2 | 336 | | Weather Icons | SIL OFL 1.1 license | 2.0.12 | 219 |
Subpath exports
| Import | Contents |
| -------------------------------- | --------------------------------- |
| @mal-icons/solid | Adapter and context |
| @mal-icons/solid/ad | All Ant Design icons (named exports) |
| @mal-icons/solid/ci | All Circum icons (named exports) |
| @mal-icons/solid/dev | All Devicons icons (named exports) |
| @mal-icons/solid/ad/AdHome | A single Ant Design icon module |
| @mal-icons/solid/ci/CiHeart | A single Circum icon module |
| @mal-icons/solid/dev/DevDreamhost | A single Devicons icon module |
| @mal-icons/solid/fa | All Font Awesome icons (named exports) |
| @mal-icons/solid/fab | All Font Awesome Brands icons (named exports) |
| @mal-icons/solid/far | All Font Awesome Regular icons (named exports) |
| @mal-icons/solid/fc | All Flat Color icons (named exports) |
| @mal-icons/solid/fi | All Feather icons (named exports) |
| @mal-icons/solid/gr | All Grommet icons (named exports) |
| @mal-icons/solid/fa/FaHeart | A single icon module |
| @mal-icons/solid/fab/FabGithub | A single icon module |
| @mal-icons/solid/far/FarHeart | A single icon module |
| @mal-icons/solid/fc/FcAbout | A single icon module |
| @mal-icons/solid/fi/FiActivity | A single icon module |
| @mal-icons/solid/gr/GrHome | A single icon module |
| @mal-icons/solid/io | All Ionicons (named exports) |
| @mal-icons/solid/lu | All Lucide (named exports) |
| @mal-icons/solid/oc | All Octicons (named exports) |
| @mal-icons/solid/io/IoHeart | A single Ionicons icon module |
| @mal-icons/solid/lu/LuHeart | A single Lucide icon module |
| @mal-icons/solid/oc/OcHeart16 | A single Octicons icon module |
| @mal-icons/solid/ti | All Typicons (named exports) |
| @mal-icons/solid/wi | All Weather Icons (named exports) |
| @mal-icons/solid/ti/TiHeart | A single Typicons icon module |
| @mal-icons/solid/wi/WiDaySunny | A single Weather Icons icon module |
| @mal-icons/solid/hi | All Heroicons icons (named exports) |
| @mal-icons/solid/hi/HiAcademicCap | A single Heroicons icon module |
| @mal-icons/solid/sl | All Simple Line Icons icons (named exports) |
| @mal-icons/solid/sl/SlActionRedo | A single Simple Line Icons icon module |
| @mal-icons/solid/cg | All css.gg icons (named exports) |
| @mal-icons/solid/cg/CgAbstract | A single css.gg icon module |
| @mal-icons/solid/vsc | All Codicons icons (named exports) |
| @mal-icons/solid/vsc/VscAccount | A single Codicons icon module |
| @mal-icons/solid/tf | All Themify icons (named exports) |
| @mal-icons/solid/tf/TfAgenda | A single Themify icon module |
| @mal-icons/solid/rx | All Radix Icons icons (named exports) |
| @mal-icons/solid/rx/RxAccessibility | A single Radix Icons icon module |
Example
A Vite + SolidJS 1.9 gallery (signals + provider) lives in
examples/solid.
Repository
https://github.com/mal-icons/mal-icons · package directory
packages/solid.
License
MIT © MALDevs
