coily 0.8.2 → 0.9.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.
package/dist/api.cjs CHANGED
@@ -576,6 +576,12 @@ class Spring {
576
576
  onStop(callback) {
577
577
  return __privateGet$1(this, _solver).onStop(callback);
578
578
  }
579
+ jumpTo(value) {
580
+ __privateSet$1(this, _target, value);
581
+ __privateGet$1(this, _solver).position = 0;
582
+ __privateGet$1(this, _solver).velocity = 0;
583
+ __privateGet$1(this, _solver).tick(0);
584
+ }
579
585
  }
580
586
  _target = new WeakMap();
581
587
  _solver = new WeakMap();
package/dist/api.d.cts CHANGED
@@ -1,5 +1,5 @@
1
- import { S as SpringSystem } from './shared/coily.fc8a32a3.cjs';
2
- export { a as Spring } from './shared/coily.fc8a32a3.cjs';
1
+ import { S as SpringSystem } from './shared/coily.0b4474af.cjs';
2
+ export { a as Spring } from './shared/coily.0b4474af.cjs';
3
3
 
4
4
  declare function createSpringSystem(): SpringSystem;
5
5
 
package/dist/api.d.mts CHANGED
@@ -1,5 +1,5 @@
1
- import { S as SpringSystem } from './shared/coily.fc8a32a3.mjs';
2
- export { a as Spring } from './shared/coily.fc8a32a3.mjs';
1
+ import { S as SpringSystem } from './shared/coily.0b4474af.mjs';
2
+ export { a as Spring } from './shared/coily.0b4474af.mjs';
3
3
 
4
4
  declare function createSpringSystem(): SpringSystem;
5
5
 
package/dist/api.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { S as SpringSystem } from './shared/coily.fc8a32a3.js';
2
- export { a as Spring } from './shared/coily.fc8a32a3.js';
1
+ import { S as SpringSystem } from './shared/coily.0b4474af.js';
2
+ export { a as Spring } from './shared/coily.0b4474af.js';
3
3
 
4
4
  declare function createSpringSystem(): SpringSystem;
5
5
 
package/dist/api.mjs CHANGED
@@ -574,6 +574,12 @@ class Spring {
574
574
  onStop(callback) {
575
575
  return __privateGet$1(this, _solver).onStop(callback);
576
576
  }
577
+ jumpTo(value) {
578
+ __privateSet$1(this, _target, value);
579
+ __privateGet$1(this, _solver).position = 0;
580
+ __privateGet$1(this, _solver).velocity = 0;
581
+ __privateGet$1(this, _solver).tick(0);
582
+ }
577
583
  }
578
584
  _target = new WeakMap();
579
585
  _solver = new WeakMap();
package/dist/loop.d.cts CHANGED
@@ -1,4 +1,4 @@
1
- import { S as SpringSystem } from './shared/coily.fc8a32a3.cjs';
1
+ import { S as SpringSystem } from './shared/coily.0b4474af.cjs';
2
2
 
3
3
  declare function start(system: SpringSystem): () => void;
4
4
 
package/dist/loop.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- import { S as SpringSystem } from './shared/coily.fc8a32a3.mjs';
1
+ import { S as SpringSystem } from './shared/coily.0b4474af.mjs';
2
2
 
3
3
  declare function start(system: SpringSystem): () => void;
4
4
 
package/dist/loop.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { S as SpringSystem } from './shared/coily.fc8a32a3.js';
1
+ import { S as SpringSystem } from './shared/coily.0b4474af.js';
2
2
 
3
3
  declare function start(system: SpringSystem): () => void;
4
4
 
@@ -69,6 +69,7 @@ declare class Spring {
69
69
  onUpdate(callback: () => void): () => void;
70
70
  onStart(callback: () => void): () => void;
71
71
  onStop(callback: () => void): () => void;
72
+ jumpTo(value: number): void;
72
73
  }
73
74
 
74
75
  interface SpringOptions {
@@ -69,6 +69,7 @@ declare class Spring {
69
69
  onUpdate(callback: () => void): () => void;
70
70
  onStart(callback: () => void): () => void;
71
71
  onStop(callback: () => void): () => void;
72
+ jumpTo(value: number): void;
72
73
  }
73
74
 
74
75
  interface SpringOptions {
@@ -69,6 +69,7 @@ declare class Spring {
69
69
  onUpdate(callback: () => void): () => void;
70
70
  onStart(callback: () => void): () => void;
71
71
  onStop(callback: () => void): () => void;
72
+ jumpTo(value: number): void;
72
73
  }
73
74
 
74
75
  interface SpringOptions {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "coily",
3
- "version": "0.8.2",
3
+ "version": "0.9.0",
4
4
  "description": "Simulate values using spring physics",
5
5
  "author": "Tim Morris <timthewebguy@gmail.com>",
6
6
  "homepage": "https://github.com/tkofh/coily#readme",