mirror of
https://github.com/Rezmason/matrix.git
synced 2026-04-21 07:19:30 -07:00
Massive overhaul: the renderers are now classes that implement Renderer; replaced webpack and rollup with vite; converted bundle-contents to "core" and "full" bundle profiles; renamed "inclusions" to "staticAssets", which are "url" base64-encoded images and "raw" text strings; renamed the Matrix component module to the JSX extension; built out a test scaffold at tools/test/index.html to manually test the various deploy options.
This commit is contained in:
@@ -249,7 +249,6 @@ const versions = {
|
||||
baseContrast: 1.5,
|
||||
highPassThreshold: 0,
|
||||
numColumns: 60,
|
||||
cycleSpeed: 0.03,
|
||||
bloomStrength: 0.7,
|
||||
fallSpeed: 0.3,
|
||||
palette: [
|
||||
@@ -278,7 +277,6 @@ const versions = {
|
||||
baseContrast: 1.5,
|
||||
highPassThreshold: 0,
|
||||
numColumns: 60,
|
||||
cycleSpeed: 0.03,
|
||||
bloomStrength: 0.7,
|
||||
fallSpeed: 0.3,
|
||||
palette: [
|
||||
@@ -307,7 +305,6 @@ const versions = {
|
||||
baseContrast: 1.5,
|
||||
highPassThreshold: 0,
|
||||
numColumns: 60,
|
||||
cycleSpeed: 0.03,
|
||||
bloomStrength: 0.7,
|
||||
fallSpeed: 0.3,
|
||||
palette: [
|
||||
@@ -368,7 +365,7 @@ versions["2021"] = versions.resurrections;
|
||||
|
||||
const range = (f, min = -Infinity, max = Infinity) => Math.max(min, Math.min(max, f));
|
||||
const nullNaN = (f) => (isNaN(f) ? null : f);
|
||||
const isTrue = (s) => s.toLowerCase().includes("true");
|
||||
const isTrue = (v) => (typeof v === "string" && v.toLowerCase().includes("true")) || v;
|
||||
|
||||
const parseColor = (isHSL) => (s) => ({
|
||||
space: isHSL ? "hsl" : "rgb",
|
||||
@@ -491,7 +488,7 @@ paramMapping.dropLength = paramMapping.raindropLength;
|
||||
paramMapping.angle = paramMapping.slant;
|
||||
paramMapping.colors = paramMapping.stripeColors;
|
||||
|
||||
export default (urlParams) => {
|
||||
export default (urlParams = {}) => {
|
||||
const validParams = Object.fromEntries(
|
||||
Object.entries(urlParams)
|
||||
.filter(([key]) => key in paramMapping)
|
||||
|
||||
Reference in New Issue
Block a user