Three sizes only
Pixel-perfect renders at 16, 24, 32. No fluid sizing, no surprises.
SenIcon renders a single SVG file from /public via next/image. Three fixed sizes — 16, 24, 32 — keep the iconography crisp without inviting freelance scaling.
Same shape, three sizes, no fluid scaling.
Each row is one icon at 16, 24, and 32 — pick the size that suits the surrounding density.
check
/icons/check.svg
close
/icons/close.svg
info
/icons/info.svg
warning
/icons/warning.svg
search
/icons/search.svg
github
/icons/github.svg
portfolio
/icons/portfolio.svg
Pixel-perfect renders at 16, 24, 32. No fluid sizing, no surprises.
Drop SVG files into /public/icons. Reference by path. No icon font, no sprite.
Tailwind dark:invert flips solid icons so they read on either ground.
An icon button — the most common shape, with proper aria-label.
import { SenIcon } from 'sen-ui'
export function CloseButton() {
return (
<button aria-label="Close" className="rounded-full p-2 hover:bg-gray-100">
<SenIcon src="/icons/close.svg" size={24} />
</button>
)
}'use client'
import Image from 'next/image'
import type { ComponentPropsWithoutRef } from 'react'
export interface SenIconProps extends ComponentPropsWithoutRef<'span'> {
src: string
size?: 16 | 24 | 32
}
export function SenIcon({ src, size = 24, className, ...props }: SenIconProps) {
return (
<span
className={['inline-flex items-center justify-center', className]
.filter(Boolean)
.join(' ')}
style={{ width: size, height: size }}
{...props}
>
<Image
src={src}
alt=""
width={size}
height={size}
className="object-contain invert-0 filter dark:invert"
/>
</span>
)
}