react-x11 2.11.0 → 2.12.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 (96) hide show
  1. package/README.md +278 -129
  2. package/package.json +10 -3
  3. package/src/Reconciler.js +15 -17
  4. package/src/a11y.js +2 -2
  5. package/src/anchor.js +7 -5
  6. package/src/bootstrap.js +14 -0
  7. package/src/clientmessage.js +1 -1
  8. package/src/cocoa/app.js +292 -49
  9. package/src/cocoa/bezels.js +175 -30
  10. package/src/cocoa/dnd.js +27 -13
  11. package/src/cocoa/fonts.js +3 -3
  12. package/src/cocoa/glarea.js +20 -3
  13. package/src/cocoa/main.d.ts +8 -0
  14. package/src/cocoa/main.js +43 -0
  15. package/src/cocoa/panehost.js +15 -5
  16. package/src/cocoa/presenter.js +13 -9
  17. package/src/cocoa/promotion.js +4 -7
  18. package/src/cocoa/relaunch.js +207 -0
  19. package/src/cocoa/threaded.js +246 -0
  20. package/src/cocoa/window.js +256 -42
  21. package/src/components/Select.js +2 -2
  22. package/src/components/anchor.js +3 -3
  23. package/src/components/native.js +12 -7
  24. package/src/components/theme.js +2 -2
  25. package/src/debug.js +1 -1
  26. package/src/decorations.js +1 -1
  27. package/src/editmenu.js +2 -2
  28. package/src/errors.js +46 -0
  29. package/src/events.js +6 -6
  30. package/src/foreignnodes.js +3 -2
  31. package/src/frames.js +2 -2
  32. package/src/glnodes.js +1 -1
  33. package/src/grid.js +1653 -0
  34. package/src/host.d.ts +230 -0
  35. package/src/host.js +11 -3
  36. package/src/imagesource.js +1 -1
  37. package/src/index.d.ts +21 -4
  38. package/src/index.js +9 -1
  39. package/src/layouts.js +721 -0
  40. package/src/node.d.ts +4 -2
  41. package/src/node.js +19 -21
  42. package/src/nodes/animation.js +644 -0
  43. package/src/nodes/box.js +21 -0
  44. package/src/nodes/boxpaint.js +473 -0
  45. package/src/nodes/canvas.js +269 -0
  46. package/src/nodes/cascade.js +600 -0
  47. package/src/nodes/damage.js +183 -0
  48. package/src/nodes/edithistory.js +124 -0
  49. package/src/nodes/editmenupopup.js +260 -0
  50. package/src/nodes/hittest.js +185 -0
  51. package/src/nodes/image.js +266 -0
  52. package/src/nodes/install.js +75 -0
  53. package/src/nodes/invalidate.js +465 -0
  54. package/src/nodes/kinds.js +31 -0
  55. package/src/nodes/layout.js +439 -0
  56. package/src/nodes/layouthost.js +949 -0
  57. package/src/nodes/node.js +868 -0
  58. package/src/nodes/paint.js +466 -0
  59. package/src/nodes/position.js +366 -0
  60. package/src/nodes/preedit.js +127 -0
  61. package/src/nodes/queries.js +330 -0
  62. package/src/nodes/rects.js +102 -0
  63. package/src/nodes/scrollable.js +891 -0
  64. package/src/nodes/scrollbars.js +138 -0
  65. package/src/nodes/scrollblit.js +1034 -0
  66. package/src/nodes/selectable.js +142 -0
  67. package/src/nodes/styling.js +225 -0
  68. package/src/nodes/text.js +649 -0
  69. package/src/nodes/textarea.js +391 -0
  70. package/src/nodes/textinput.js +1146 -0
  71. package/src/nodes/util.js +17 -0
  72. package/src/nodes/window/anchoring.js +161 -0
  73. package/src/nodes/window/capabilities.js +190 -0
  74. package/src/nodes/window/debugpaint.js +83 -0
  75. package/src/nodes/window/droptarget.js +145 -0
  76. package/src/nodes/window/floors.js +577 -0
  77. package/src/nodes/window/flush.js +334 -0
  78. package/src/nodes/window/hints.js +482 -0
  79. package/src/nodes/window/listeners.js +222 -0
  80. package/src/nodes/window/popup.js +71 -0
  81. package/src/nodes/window/size.js +591 -0
  82. package/src/nodes/window/window.js +945 -0
  83. package/src/palette.js +1 -1
  84. package/src/registry.js +7 -3
  85. package/src/styles.js +137 -15
  86. package/src/svgnodes.js +2 -1
  87. package/src/testing/harness.js +2 -2
  88. package/src/textselection.js +5 -3
  89. package/src/trace-registry.js +1 -1
  90. package/src/types/components.d.ts +38 -6
  91. package/src/types/elements.d.ts +11 -1
  92. package/src/types/nodes.d.ts +17 -2
  93. package/src/types/style.d.ts +94 -3
  94. package/src/windowstate.js +1 -1
  95. package/src/yoga.js +1 -1
  96. package/src/nodes.js +0 -13120
package/src/node.d.ts CHANGED
@@ -504,8 +504,10 @@ export declare class Node {
504
504
  * An element whose node is one node never needs it; being painted at all
505
505
  * means it is inside the pass. An element that draws a **scene** into one
506
506
  * node culls against it the way core culls the tree, instead of redrawing
507
- * the scene into a clip that throws most of it away. Window coordinates,
508
- * the same space as `abs`; read-only.
507
+ * the scene into a clip that throws most of it away. Core counts a pixel
508
+ * short of the rect as inside it, for the antialiasing that inks just
509
+ * past a shape's bounds. Window coordinates, the same space as `abs`;
510
+ * read-only.
509
511
  */
510
512
  paintDamage(): Rect | null;
511
513
  /**
package/src/node.js CHANGED
@@ -13,27 +13,25 @@
13
13
  // they run after the application's own handlers and not at all if one of
14
14
  // those called `preventDefault`, which is the ordering that makes an
15
15
  // interactive element composable rather than something to work around.
16
- export {
17
- Node,
18
- // `class MyPane extends Scrollable(Node)` the same mixin <box> and
19
- // <window> use, so a registered element can honour `overflow: 'scroll'`
20
- // with the wheel, the keys, the bars and the a11y role already wired.
21
- Scrollable,
22
- // The `measureContent` body of an element whose content has a size of its
23
- // own and an aspect ratio to keep — what <image> and <svg> answer with.
24
- intrinsicSize,
25
- // The cadence a caret blinks at, so an element that draws one is in step
26
- // with `<textinput>` rather than a few tens of milliseconds beside it.
27
- CARET_BLINK_MS,
28
- BoxNode,
29
- TextNode,
30
- ImageNode,
31
- CanvasNode,
32
- TextInputNode,
33
- TextAreaNode,
34
- WindowNode,
35
- PopupNode,
36
- } from './nodes.js';
16
+ export { Node } from './nodes/node.js';
17
+ // `class MyPane extends Scrollable(Node)` — the same mixin <box> and
18
+ // <window> use, so a registered element can honour `overflow: 'scroll'`
19
+ // with the wheel, the keys, the bars and the a11y role already wired.
20
+ export { Scrollable } from './nodes/scrollable.js';
21
+ // The `measureContent` body of an element whose content has a size of its
22
+ // own and an aspect ratio to keep what <image> and <svg> answer with.
23
+ export { intrinsicSize } from './nodes/layout.js';
24
+ // The cadence a caret blinks at, so an element that draws one is in step
25
+ // with `<textinput>` rather than a few tens of milliseconds beside it.
26
+ export { CARET_BLINK_MS } from './nodes/textinput.js';
27
+ export { BoxNode } from './nodes/box.js';
28
+ export { TextNode } from './nodes/text.js';
29
+ export { ImageNode } from './nodes/image.js';
30
+ export { CanvasNode } from './nodes/canvas.js';
31
+ export { TextInputNode } from './nodes/textinput.js';
32
+ export { TextAreaNode } from './nodes/textarea.js';
33
+ export { WindowNode } from './nodes/window/window.js';
34
+ export { PopupNode } from './nodes/window/popup.js';
37
35
 
38
36
  // The two precedents for an element that owns a real child X window rather
39
37
  // than painting into its parent's: registered with `drawn: false`, realized