@webmate-studio/builder 0.2.142 → 0.2.143

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webmate-studio/builder",
3
- "version": "0.2.142",
3
+ "version": "0.2.143",
4
4
  "type": "module",
5
5
  "description": "Webmate Studio Component Builder",
6
6
  "keywords": [
@@ -360,13 +360,18 @@ function computeChroma(stepL, baseL, baseC, stdDev, chromaScale) {
360
360
  gaussian = 0.97 * Math.exp((-12 / stdDev) * edgeDiff * edgeDiff);
361
361
  }
362
362
 
363
- // Lightness-Begrenzung: Asymmetrisch
364
- // Helle Seite (L > 0.85): Chroma fällt steil auf 0 → Steps 1-2 bleiben fast weiß
365
- // Dunkle Seite (L < 0.3): Chroma fällt moderat Steps 11-12 behalten Farbton
366
- // Mitte (0.3-0.85): Nahezu volle Chroma möglich
363
+ // Lightness-Begrenzung: Asymmetrisch + Chroma-abhängig
364
+ // Bei hochgesättigten Farben (Grün, Cyan) wirken schon kleine Chroma-Werte
365
+ // bei hoher Lightness "neonig". Der Einsatzpunkt wird daher bei hoher
366
+ // Base-Chroma nach unten verschoben.
367
+ // Helle Seite: Einsatz ab threshold (0.85 bei C=0, 0.75 bei C≥0.17)
368
+ // Dunkle Seite (L < 0.3): Chroma fällt moderat
369
+ // Mitte: volle Chroma möglich
370
+ const chromaFactor = Math.min(baseC / 0.17, 1.0); // 0 bei grau, 1 bei gesättigtem Grün
371
+ const lightThreshold = 0.85 - chromaFactor * 0.10; // 0.85 → 0.75
367
372
  let lightnessLimit;
368
- if (stepL > 0.85) {
369
- const t = (stepL - 0.85) / 0.15;
373
+ if (stepL > lightThreshold) {
374
+ const t = (stepL - lightThreshold) / (1.0 - lightThreshold);
370
375
  lightnessLimit = 1.0 - t * t;
371
376
  } else if (stepL < 0.3) {
372
377
  const t = stepL / 0.3;