soidesmax
START HERE

Installation & setup

Requirements, commands and the first steps for this template.

Version 1.0.0

Unzip, then open demo/index.html in a browser to see both orbs side by side, switch finishes and themes. The demos work offline, straight from your disk.

Copy vendor/three.min.js and one orb script from dist/ into your project. Add a sized container with a canvas inside it, load Three.js BEFORE the orb script, then call the start function:

              For the monochrome edition, load dist/crystal-orb.min.js and call crystalOrbStart(...) instead, with finish silver, pearl, steel or onyx. You can load both scripts on the same page. The stage is the element the canvas fills: its size controls the size of the canvas, and it receives the pointer events. A square stage looks best.

              Options: finish, theme ('auto', 'dark' or 'light'), interactive (tilt on hover, pulse on click), speed (animation speed multiplier) and maxPixelRatio (default 1.75 - use 1.25 on weak devices or for very large orbs).

              React - see examples/react/OrbHero.jsx: it mounts the orb in useEffect and calls the cleanup function on unmount. Vue - mount in onMounted and call the cleanup in onBeforeUnmount. Bundlers - each script also sets module.exports, but it expects THREE to be a global: import [email protected] and assign window.THREE = THREE before you import the orb script, or simply load the included vendor/three.min.js with a script tag. Webflow and WordPress - upload three.min.js and the orb script as assets and paste the quick-start snippet into an Embed or Custom HTML block with your asset URLs.

              No, you do not need to install Three.js: Three.js r128 is included in vendor/three.min.js. Copy that file with the orb script and load it first. If WebGL or Three.js is unavailable, the start function returns null - check for that and show a static image instead.
USE IT IN YOUR PROJECTIncluded stack: JavaScript + WebGL (Three.js)

Follow the included README first. These steps apply to the technologies listed for this product.

  1. Find the supplied JavaScript modules and their entry point in the included README.
  2. Load them in the documented order and preserve their selectors and asset paths.
  3. Replace sample data and test browser interactions in your own project.
A CLOSER LOOK

About this product

Orb Collection is a pair of ambient WebGL orbs for heroes and backgrounds: Crystal Orb and Prism Orb, each as a compiled script plus a minified build. Each orb is a glass sphere with a glowing core inside, light streaks racing through the core and a small moon in orbit. It tilts toward the pointer and pulses when clicked.

Crystal Orb is the monochrome edition, with 4 finishes: silver, pearl, steel and onyx. Prism Orb is the iridescent edition, with 4 finishes: aurora, opal, sunset and lagoon. Both render as a ray-marched volume in a fragment shader (Three.js r128) on a fully transparent canvas, so your page background shows through the glass.

Dark and light themes are built in. In auto mode the orb follows your site: it reads data-theme="dark" or "light" on your html element and switches live when that attribute changes, and otherwise follows the visitor's OS setting. Dark mode adds light on top of the page, so use it on dark backgrounds; light mode draws a dark core with a metal outline, so use it on light backgrounds.

Control it from code: setFinish() for a smooth colour transition, setTheme() to switch themes, pulse() to trigger the click pulse, and a cleanup function to stop the orb and free GPU memory. Options cover finish, theme, interactivity, animation speed and a pixel-ratio cap. If WebGL or Three.js is unavailable the start function returns null, so you can show a static image instead.

Performance is handled for you: rendering pauses automatically while the orb is scrolled off-screen, prefers-reduced-motion slows the animation to 20% speed, and the pixel ratio is capped at 1.75 by default. Use one or two orbs per page - each orb is a full ray-marched shader. About 11 KB minified per orb, plus Three.js.

Works with plain HTML, React, Vue, Svelte, Webflow (custom code), WordPress and others, in any browser with WebGL 1 or 2. What is inside: dist/crystal-orb.js and .min.js, dist/prism-orb.js and .min.js, vendor/three.min.js (Three.js r128, MIT, included - nothing loads from a CDN), demo/index.html (both orbs side by side with finish and theme switches), demo/crystal.html, demo/prism.html and demo/hero-example.html (a ready-made responsive hero section), examples/vanilla/minimal.html and examples/react/OrbHero.jsx, and 6 preview images (hero dark, hero mobile, crystal, prism light, index light, index dark).

Included screens / pages

  • Orb previews (previews folder)

UI interactions

  • Crystal Orb WebGL render
  • Prism Orb WebGL render

What you get

  • dist/crystal-orb.js
  • dist/crystal-orb.min.js
  • dist/prism-orb.js
  • dist/prism-orb.min.js
  • previews (6 images)
  • README.md
  • LICENSE.txt (v2)
  • examples/vanilla/minimal.html
  • examples/react/OrbHero.jsx

Integrations

Frontend visual only. Include one orb script per page; no backend.

FAQ

Do I need Three.js installed?

No. The orb scripts bundle what they need; the Three.js license file is included for attribution.

What does the license allow?

License v2: buy once, use for unlimited end products - your own projects and projects you build for clients. No distribution, resale, source sharing, or use as a competing template/UI kit. Full v2 text is included as LICENSE.txt in the sold ZIP.

Version 1.0.0 · Updated

BEFORE YOU GET STARTED

License & Support

One license. Unlimited projects.

One purchase covers unlimited end products for you and your clients. Customize the design and code, and use it in commercial projects.

You may not share, resell or redistribute the template or its source.

Updates
All v1.x updates included.
Support
Bugs and setup, within 2 business days.
Full license terms
**License** One purchase of this template covers **unlimited end products** — your own projects and projects you build for clients. You may use it in commercial client work, change the design and code, and ship it as part of your products, as many times as you like. The license belongs to the buyer (one person or one company). People working for the buyer on the buyer's projects may use it under the same license. You may not redistribute, resell, share, or sublicense the template itself or its source files, in whole or in part — whether standalone, bundled with other files, free, or paid. You may not use it to create a template, UI kit, or component library that competes with this product. **Updates:** all v1.x updates are free — re-download the latest files from your purchase email whenever a new version is released. **Support:** bug fixes and setup help within 2 business days, via [email protected]. The terms above are the terms in force at the time of your purchase and stay valid for that purchase, even if the license terms change later.
Read Template License v2