pixi-effects 0.30.0 → 0.31.0

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.
Files changed (63) hide show
  1. package/CHANGELOG.md +25 -0
  2. package/README.md +6 -5
  3. package/ai/chat-template.html +3 -3
  4. package/ai/tools/check.mjs +42 -2
  5. package/ai/tools/lookup.mjs +12 -6
  6. package/ai/tools/render.mjs +15 -2
  7. package/ai/tools/varArgs.mjs +75 -0
  8. package/dist/{Base-CB1_FPZD.d.cts → Base-BKagtWc0.d.cts} +1 -1
  9. package/dist/{Base-Ne74ztNl.d.ts → Base-jRiMHcWT.d.ts} +1 -1
  10. package/dist/Composition-DQCPJPFE.js +7 -0
  11. package/dist/{Composition-RJGA7KDU.js.map → Composition-DQCPJPFE.js.map} +1 -1
  12. package/dist/Composition-V2XYSW6P.cjs +16 -0
  13. package/dist/{Composition-MUKR3FYD.cjs.map → Composition-V2XYSW6P.cjs.map} +1 -1
  14. package/dist/Controller.cjs +42 -1
  15. package/dist/Controller.cjs.map +1 -1
  16. package/dist/Controller.d.cts +10 -2
  17. package/dist/Controller.d.ts +10 -2
  18. package/dist/Controller.js +42 -1
  19. package/dist/Controller.js.map +1 -1
  20. package/dist/{Movie-DdnpLpw1.d.cts → Movie-BH81stkb.d.cts} +90 -3
  21. package/dist/{Movie-C2rZFkrO.d.ts → Movie-CfFPItoL.d.ts} +90 -3
  22. package/dist/{chunk-A3Q3SDSH.js → chunk-BGMCZA36.js} +3 -3
  23. package/dist/{chunk-A3Q3SDSH.js.map → chunk-BGMCZA36.js.map} +1 -1
  24. package/dist/{chunk-ZVUO325O.cjs → chunk-DJ5B7IKT.cjs} +9 -3
  25. package/dist/chunk-DJ5B7IKT.cjs.map +1 -0
  26. package/dist/{chunk-WHNADXXG.cjs → chunk-L73KRFXI.cjs} +61 -61
  27. package/dist/{chunk-WHNADXXG.cjs.map → chunk-L73KRFXI.cjs.map} +1 -1
  28. package/dist/{chunk-ZAXYPXKW.js → chunk-MMTESMJ5.js} +9 -4
  29. package/dist/chunk-MMTESMJ5.js.map +1 -0
  30. package/dist/{chunk-CRQFDY7E.js → chunk-UTIBYMIO.js} +461 -56
  31. package/dist/chunk-UTIBYMIO.js.map +1 -0
  32. package/dist/{chunk-HREBQAY4.cjs → chunk-X3WHETQ3.cjs} +485 -80
  33. package/dist/chunk-X3WHETQ3.cjs.map +1 -0
  34. package/dist/index.cjs +31 -31
  35. package/dist/index.d.cts +5 -5
  36. package/dist/index.d.ts +5 -5
  37. package/dist/index.js +3 -3
  38. package/dist/loader.css +1 -1
  39. package/dist/present.cjs +3 -3
  40. package/dist/present.d.cts +2 -2
  41. package/dist/present.d.ts +2 -2
  42. package/dist/present.js +3 -3
  43. package/dist/three.cjs +5 -5
  44. package/dist/three.d.cts +2 -2
  45. package/dist/three.d.ts +2 -2
  46. package/dist/three.js +1 -1
  47. package/dist/{types-BzIB65Vk.d.cts → types-CK_crNAI.d.cts} +2 -0
  48. package/dist/{types-BzIB65Vk.d.ts → types-CK_crNAI.d.ts} +2 -0
  49. package/docs/api.md +28 -1
  50. package/docs/dsl.md +32 -1
  51. package/llms-full.txt +145 -11
  52. package/package.json +83 -20
  53. package/skills/pixi-effects/SKILL.md +1 -1
  54. package/skills/pixi-effects/reference/cheatsheet.md +3 -0
  55. package/skills/pixi-effects/reference/pitfalls.md +4 -0
  56. package/skills/pixi-effects/reference/recipes.md +79 -8
  57. package/skills/pixi-effects/template.html +6 -6
  58. package/dist/Composition-MUKR3FYD.cjs +0 -16
  59. package/dist/Composition-RJGA7KDU.js +0 -7
  60. package/dist/chunk-CRQFDY7E.js.map +0 -1
  61. package/dist/chunk-HREBQAY4.cjs.map +0 -1
  62. package/dist/chunk-ZAXYPXKW.js.map +0 -1
  63. package/dist/chunk-ZVUO325O.cjs.map +0 -1
@@ -954,6 +954,7 @@ var FUNCS = {
954
954
  step: (edge, x) => x >= edge ? 1 : 0
955
955
  };
956
956
  var CONSTS = { PI: Math.PI };
957
+ var EXPRESSION_NAMES = [...Object.keys(FUNCS), ...Object.keys(CONSTS)];
957
958
  function isDigit(c) {
958
959
  return c >= "0" && c <= "9";
959
960
  }
@@ -1460,6 +1461,8 @@ function buildScope(sequence, parent, root) {
1460
1461
  const contain = w === 0 || h === 0 ? 1 : Math.min(W / w, H / h);
1461
1462
  const cover = w === 0 || h === 0 ? 1 : Math.max(W / w, H / h);
1462
1463
  return {
1464
+ ...root.vars ?? {},
1465
+ // the declared numbers first: the built-in words below win
1463
1466
  w,
1464
1467
  h,
1465
1468
  W,
@@ -3479,6 +3482,8 @@ var TextSequence = class extends Sequence {
3479
3482
  );
3480
3483
  const unset = Object.keys(resolved).filter((k) => resolved[k] === void 0);
3481
3484
  if (unset.length) console.warn(`pixi-effects: ${describeLayer(this.spec)}: ${unset.map((k) => `style.${k}`).join(", ")} ${unset.length > 1 ? "are" : "is"} undefined (a variable that was never set?), so ${unset.length > 1 ? "they are" : "it is"} ignored and the default is used: omit the key instead`);
3485
+ const outline = resolved.stroke;
3486
+ if (outline && typeof outline === "object" && !("join" in outline) && !("lineJoin" in outline)) resolved.stroke = { ...outline, join: "round" };
3482
3487
  for (const k of Object.keys(resolved)) {
3483
3488
  if (unset.includes(k)) continue;
3484
3489
  text.style[k] = resolved[k];
@@ -5398,7 +5403,7 @@ function resolveDim(v, scope) {
5398
5403
  var _CompositionSequence = null;
5399
5404
  async function getCompositionSequence() {
5400
5405
  if (!_CompositionSequence) {
5401
- _CompositionSequence = (await import('./Composition-RJGA7KDU.js')).CompositionSequence;
5406
+ _CompositionSequence = (await import('./Composition-DQCPJPFE.js')).CompositionSequence;
5402
5407
  }
5403
5408
  return _CompositionSequence;
5404
5409
  }
@@ -5440,6 +5445,6 @@ async function buildSequenceTree(specs, parent, root) {
5440
5445
  return out;
5441
5446
  }
5442
5447
 
5443
- export { CameraSequence, DEFAULT_FOV, DEG3 as DEG, FALLOFFS, LIGHT_KINDS, LIGHT_PROPS, LightSequence, MANY_BLURRED, MAX_BLUR, MAX_CASTERS, MAX_LIGHTS, MIN_BLUR, NEAR, NullSequence, SHADOW_TAPS, Sequence, bindClock, blurRadius, buildScope, buildSequenceTree, cameraBasis, checkEase, clockTable, contentLength, createTimeline, ensureFilterLibrary, evaluateExpr, flattenSvgPath, focusProblems, homeCamera, homeDistance, layerInitialZ, layerToWorld, lengthen, lightLevel, noise, packLights, parseEase, projectLayer, projectPoint, rand, random, registerSequenceType, remapOf, resolveAt, timeRemapOf };
5444
- //# sourceMappingURL=chunk-ZAXYPXKW.js.map
5445
- //# sourceMappingURL=chunk-ZAXYPXKW.js.map
5448
+ export { CameraSequence, DEFAULT_FOV, DEG3 as DEG, EXPRESSION_NAMES, FALLOFFS, LIGHT_KINDS, LIGHT_PROPS, LightSequence, MANY_BLURRED, MAX_BLUR, MAX_CASTERS, MAX_LIGHTS, MIN_BLUR, NEAR, NullSequence, SHADOW_TAPS, Sequence, bindClock, blurRadius, buildScope, buildSequenceTree, cameraBasis, checkEase, clockTable, contentLength, createTimeline, ensureFilterLibrary, evaluateExpr, flattenSvgPath, focusProblems, homeCamera, homeDistance, layerInitialZ, layerToWorld, lengthen, lightLevel, noise, packLights, parseEase, projectLayer, projectPoint, rand, random, registerSequenceType, remapOf, resolveAt, timeRemapOf };
5449
+ //# sourceMappingURL=chunk-MMTESMJ5.js.map
5450
+ //# sourceMappingURL=chunk-MMTESMJ5.js.map