@ai-matrx/summon 0.1.7 → 0.1.8

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 (50) hide show
  1. package/CHANGELOG.md +15 -2
  2. package/dist/gate-DUvE-Cc1.d.cts +399 -0
  3. package/dist/gate-DUvE-Cc1.d.ts +399 -0
  4. package/dist/handles.cjs +1 -0
  5. package/dist/handles.cjs.map +1 -1
  6. package/dist/handles.d.cts +3 -61
  7. package/dist/handles.d.ts +3 -61
  8. package/dist/handles.js +1 -0
  9. package/dist/handles.js.map +1 -1
  10. package/dist/helpers-2NY1ha0V.d.cts +63 -0
  11. package/dist/helpers-2NY1ha0V.d.ts +63 -0
  12. package/dist/index.cjs +194 -159
  13. package/dist/index.cjs.map +1 -1
  14. package/dist/index.d.cts +9 -355
  15. package/dist/index.d.ts +9 -355
  16. package/dist/index.js +200 -165
  17. package/dist/index.js.map +1 -1
  18. package/dist/instanceBody-CgZAFnic.d.cts +23 -0
  19. package/dist/instanceBody-CgZAFnic.d.ts +23 -0
  20. package/dist/open.cjs +408 -0
  21. package/dist/open.cjs.map +1 -0
  22. package/dist/open.d.cts +22 -0
  23. package/dist/open.d.ts +22 -0
  24. package/dist/open.js +375 -0
  25. package/dist/open.js.map +1 -0
  26. package/dist/react.cjs +249 -352
  27. package/dist/react.cjs.map +1 -1
  28. package/dist/react.d.cts +11 -151
  29. package/dist/react.d.ts +11 -151
  30. package/dist/react.js +210 -306
  31. package/dist/react.js.map +1 -1
  32. package/dist/root.cjs +277 -0
  33. package/dist/root.cjs.map +1 -0
  34. package/dist/root.d.cts +175 -0
  35. package/dist/root.d.ts +175 -0
  36. package/dist/root.js +254 -0
  37. package/dist/root.js.map +1 -0
  38. package/dist/window-host.cjs +11 -2
  39. package/dist/window-host.cjs.map +1 -1
  40. package/dist/window-host.d.cts +1 -0
  41. package/dist/window-host.d.ts +1 -0
  42. package/dist/window-host.js +11 -2
  43. package/dist/window-host.js.map +1 -1
  44. package/dist/window.cjs +2 -1
  45. package/dist/window.cjs.map +1 -1
  46. package/dist/window.d.cts +3 -2
  47. package/dist/window.d.ts +3 -2
  48. package/dist/window.js +2 -1
  49. package/dist/window.js.map +1 -1
  50. package/package.json +28 -5
package/dist/window.d.cts CHANGED
@@ -47,8 +47,9 @@ interface UseWindowPanelOptions {
47
47
  */
48
48
  onAutoNoRoom?: (() => void) | undefined;
49
49
  /**
50
- * @deprecated Pass `width`, `height`, and `position` instead.
51
- * Low-level initial rect — overrides width/height/position when provided.
50
+ * Explicit placement: open at exactly this rect (any of x, y, width, height). Overrides
51
+ * width/height/position and is never auto-placed — for hosts that place windows themselves,
52
+ * e.g. a canvas full of controls where auto-placement finds no free gutter.
52
53
  */
53
54
  initialRect?: Partial<WindowRect> | undefined;
54
55
  /** Maximum width the user can resize to. */
package/dist/window.d.ts CHANGED
@@ -47,8 +47,9 @@ interface UseWindowPanelOptions {
47
47
  */
48
48
  onAutoNoRoom?: (() => void) | undefined;
49
49
  /**
50
- * @deprecated Pass `width`, `height`, and `position` instead.
51
- * Low-level initial rect — overrides width/height/position when provided.
50
+ * Explicit placement: open at exactly this rect (any of x, y, width, height). Overrides
51
+ * width/height/position and is never auto-placed — for hosts that place windows themselves,
52
+ * e.g. a canvas full of controls where auto-placement finds no free gutter.
52
53
  */
53
54
  initialRect?: Partial<WindowRect> | undefined;
54
55
  /** Maximum width the user can resize to. */
package/dist/window.js CHANGED
@@ -496,7 +496,8 @@ function useWindowPanel(opts = {}) {
496
496
  const h = opts.initialRect?.height ?? resolveSize(opts.height, DEFAULT_HEIGHT);
497
497
  const { vw, vh } = safeViewportDims();
498
498
  let autoPlaced = null;
499
- if (opts.autoOpened && vw >= NARROW_VIEWPORT) {
499
+ const explicitlyPlaced = opts.initialRect?.x !== void 0 || opts.initialRect?.y !== void 0;
500
+ if (opts.autoOpened && !explicitlyPlaced && vw >= NARROW_VIEWPORT) {
500
501
  {
501
502
  const ap = autoPlacement();
502
503
  if (!ap.order.has(id)) ap.order.set(id, ap.next++);