SkillAgentSearch skills...

refract-liquid-glass

Build sharp, draggable liquid-glass panels that bend a live backdrop through a rounded glass lip. Use for scene-aware refraction, responsive rim reflections, and elastic panel motion.

Install / Use

npx skills add MengTo/Skills --skill refract-liquid-glass

Installs into whichever agent you are using.

About this skill
📄

SKILL.md

Installable skill definition

Quality Score

88/100

Supported Platforms

Universal

Tags

Our assessment of refract-liquid-glass

refract-liquid-glass scores 88/100 on our quality scale, 1744th of 4,719 Development & Engineering skills we index (top 37%).

Its SKILL.md is 2.9 KB long, split into 3 sections and no code examples: a solid amount of guidance for an agent.

With 6,252 GitHub stars, it is one of the more widely adopted skills in the catalogue.

Substance
26/30
Structure
8/20
Description
15/15
Adoption
16/20
Freshness
15/15

Maintenance, license and trust

  • The repository was last updated about 2 months ago, so refract-liquid-glass is actively maintained.
  • It is released under the MIT license, a permissive license that allows use, modification and commercial use with attribution.
  • Its trust signals score 100/100, with no cautions. These come from repository metadata, not a code audit — read the skill file before letting an agent act on it.

refract-liquid-glass compared with similar skills

All 4 of these similar skills score higher than refract-liquid-glass; compare them before choosing.

SkillScoreStarsUpdatedFormat
refract-liquid-glass (this skill)by MengTo886.3k2mo agoSKILL.md
taste-skillby Leonxlnx100121.6ktodayCLAUDE.md
hyperframesby heygen-com10090.2ktodayCLAUDE.md
ai-job-searchby ai-job-search-dev10073.5ktodayCLAUDE.md
claude-howtoby luongnv8910047.6k5d agoCLAUDE.md

Frequently asked questions

How do I install refract-liquid-glass?
Run npx skills add MengTo/Skills --skill refract-liquid-glass. The install tabs above show the steps for each supported agent.
Which AI agents does refract-liquid-glass work with?
It is written for Universal, as a SKILL.md file. Other agents that read the same format can often use it too.
Is refract-liquid-glass safe to use?
It is MIT-licensed and scores 100/100 on trust signals. Skills are instructions an agent will follow, so read the file before installing it and do not approve commands you do not understand.
Is refract-liquid-glass still maintained?
The repository was last updated about 2 months ago, so refract-liquid-glass is actively maintained.

name: refract-liquid-glass description: Build sharp, draggable liquid-glass panels that bend a live backdrop through a rounded glass lip. Use for scene-aware refraction, responsive rim reflections, and elastic panel motion.

Refract liquid glass

Start with a visual test target. Place the panel across a thin diagonal, a bright window frame, and a dark surface. The line should stay recognizable through the face, curve inside the shoulder, and meet the undisturbed scene outside the rim.

Render the lens

  1. Render the backdrop once to a texture before drawing glass. A Three.js scene can share its linear-color render target with the glass pass. For a DOM-only surface, use an accessible backdrop treatment unless the application controls a texture that represents the backdrop. Align the texture to the actual viewport and scroll offset.

  2. Measure the DOM rect in CSS pixels. Convert fragment coordinates once to the same space, including the vertical axis. Evaluate a rounded-box signed distance and use its screen derivative for coverage. Reserve the high-curvature profile for the shoulder. A flat face preserves the detail inside a large tile.

  3. Build a unit entrance normal from the rounded-box gradient and a smoothly varying tilt. Trace toward a backing plane with a modest glass index. These expressions assume an eye-facing normal, an incident ray along negative Z, and a thickness expressed in CSS pixels.

    vec3 ray = refract(vec3(0., 0., -1.), normal, 1. / 1.46);
    vec2 offsetPx = thicknessPx * ray.xy / max(-ray.z, 0.15);
    vec2 sampleUV = (fragmentPx + offsetPx) / viewportPx;
    
  4. Use the displaced UV for transmission. Sample the surroundings farther along the rim normal for reflected color and increase its contribution toward grazing angles. Let hover shift the reflection and the apparent thickness locally. Inspect a dark and a bright background before tuning the rim intensity.

  5. Render typography and focus indicators at display density. Size the drawing buffer to the CSS rectangle times the chosen device scale. Use linear filtering, derivative-based edge coverage and a filtered source for minified samples. If the room is expensive, reduce the atmospheric pass first. Increasing the final framebuffer cannot restore detail lost in the input texture.

Drag and settle

Give a title or grip pointer capture. Translate the panel with the pointer, then drive a separate damped spring with movement impulses. Anchor shear near the grip so the far edge lags on reversal. Apply the same displayed transform to the glass, icons, text and hit coordinates. In a worker renderer, present the DOM transform when its matching rendered frame is acknowledged. Release capture on cancel. Offer a keyboard move or reset and suppress oscillation under reduced motion.

Open the live loupe. Drag it across the shoreline, reverse direction, and release. Check the text, rim, backdrop alignment and stationary end state at 1× and 2×.

Related Skills

View on GitHub
GitHub Stars6.3k
CategoryDevelopment
Updated2mo ago
Forks741

Languages

HTML

Trust signals

100/100

From repository metadata: license, adoption, age and documentation. Not a code audit — see the Safety scan above for what the skill file itself contains.

No cautions