npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@taehalim/liquid-glass

v0.1.5

Published

Liquid Glass effect using SVG displacement filters and backdrop-filter.

Readme

@taehalim/liquid-glass

Liquid Glass effect using SVG displacement filters and backdrop-filter.

Liquid Glass scroll demo

Inspired by Inspira UI's Liquid Glass component, this package exists for projects that want a similar SVG-displacement effect outside a Nuxt/Vue component stack.

Demo

The demo above is captured from the package runtime. It shows the intended effect while content scrolls behind the glass: background text is refracted through separate color channels, then softened by a frosted overlay.

Install

npm install @taehalim/liquid-glass
bun add @taehalim/liquid-glass

Vanilla / Bundler

Use this shape when your project has a bundler such as Vite, Astro, Next.js, or similar.

<div
  class="liquid-glass-effect"
  data-liquid-glass
  data-filter-id="liquid-glass-demo"
  style="--liquid-glass-frost:0.32;border-radius:24px;"
>
  <div class="liquid-glass-slot">Content</div>

  <svg class="liquid-glass-filter" xmlns="http://www.w3.org/2000/svg">
    <defs>
      <filter
        id="liquid-glass-demo"
        color-interpolation-filters="sRGB"
      ></filter>
    </defs>
  </svg>
</div>
import "@taehalim/liquid-glass/styles.css";

if (typeof window !== "undefined") {
  import("@taehalim/liquid-glass/auto");
}

Use the data-* attributes from the options table when you need to tune the displacement map.

CDN / No Build

Use this shape for plain HTML without npm, Vite, or another bundler.

<link
  rel="stylesheet"
  href="https://cdn.jsdelivr.net/npm/@taehalim/liquid-glass@latest/dist/styles.css"
/>

<div
  class="liquid-glass-effect"
  data-liquid-glass
  data-filter-id="liquid-glass-demo"
  style="--liquid-glass-frost:0.32;border-radius:24px;"
>
  <div class="liquid-glass-slot">Content</div>

  <svg class="liquid-glass-filter" xmlns="http://www.w3.org/2000/svg">
    <defs>
      <filter
        id="liquid-glass-demo"
        color-interpolation-filters="sRGB"
      ></filter>
    </defs>
  </svg>
</div>

<script type="module">
  import "https://esm.sh/@taehalim/liquid-glass@latest/auto";
</script>

Astro Adapter

---
import LiquidGlass from "@taehalim/liquid-glass/astro";
import "@taehalim/liquid-glass/styles.css";
---

<LiquidGlass id="site-nav" radius={22} frost={0.32}>
  <div>Content</div>
</LiquidGlass>

<script>
  import "@taehalim/liquid-glass/auto";
</script>

Core API

import { mountLiquidGlass, setupLiquidGlass } from "@taehalim/liquid-glass";
import "@taehalim/liquid-glass/styles.css";

setupLiquidGlass();

const element = document.querySelector<HTMLElement>("[data-liquid-glass]");
if (element) {
  mountLiquidGlass(element);
}

Integration Notes

For both humans and coding agents, the effect has three required pieces:

  • the CSS classes from styles.css
  • a matching data-filter-id and SVG <filter id="...">
  • either @taehalim/liquid-glass/auto or a direct mountLiquidGlass(...) call

The color separation should come from displaced backdrop content. Avoid replacing it with static rainbow overlays; that produces a different effect.

Options

The numeric effect options map to data-* attributes in vanilla markup. as, class, and containerClass are Astro adapter props.

| Prop | Type | Default | | ---------------- | ---------------------------------------------------------------- | -------------- | | id | string | generated | | as | "div" \| "nav" \| "header" \| "footer" \| "section" \| "aside" | "div" | | radius | number | 16 | | border | number | 0.07 | | lightness | number | 50 | | blend | string | "difference" | | xChannel | "R" \| "G" \| "B" | "R" | | yChannel | "R" \| "G" \| "B" | "B" | | alpha | number | 0.93 | | blur | number | 11 | | rOffset | number | 0 | | gOffset | number | 10 | | bOffset | number | 20 | | scale | number | -180 | | frost | number | 0.05 | | class | string | undefined | | containerClass | string | undefined |

Browser Support

The full SVG displacement backdrop effect is most reliable in Chromium-based browsers. Safari and Firefox use the CSS fallback defined in styles.css.

Changelog

See CHANGELOG.md.

Development

npm install
npm run build
npm pack --dry-run

Maintainers

npm run build
npm publish --access public