@wordpress/editor 14.42.0 → 14.43.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 (199) hide show
  1. package/CHANGELOG.md +2 -0
  2. package/build/components/collaborators-overlay/cursor-registry.cjs +86 -0
  3. package/build/components/collaborators-overlay/cursor-registry.cjs.map +7 -0
  4. package/build/components/collaborators-overlay/index.cjs +7 -2
  5. package/build/components/collaborators-overlay/index.cjs.map +2 -2
  6. package/build/components/collaborators-overlay/overlay-iframe-styles.cjs +1 -1
  7. package/build/components/collaborators-overlay/overlay-iframe-styles.cjs.map +2 -2
  8. package/build/components/collaborators-overlay/overlay.cjs +31 -1
  9. package/build/components/collaborators-overlay/overlay.cjs.map +2 -2
  10. package/build/components/collaborators-presence/index.cjs +14 -4
  11. package/build/components/collaborators-presence/index.cjs.map +2 -2
  12. package/build/components/collaborators-presence/list.cjs +20 -4
  13. package/build/components/collaborators-presence/list.cjs.map +2 -2
  14. package/build/components/post-card-panel/index.cjs +4 -15
  15. package/build/components/post-card-panel/index.cjs.map +2 -2
  16. package/build/components/post-content-information/index.cjs +10 -13
  17. package/build/components/post-content-information/index.cjs.map +2 -2
  18. package/build/components/post-revisions-panel/index.cjs +164 -0
  19. package/build/components/post-revisions-panel/index.cjs.map +7 -0
  20. package/build/components/post-revisions-preview/revisions-slider.cjs +24 -5
  21. package/build/components/post-revisions-preview/revisions-slider.cjs.map +2 -2
  22. package/build/components/post-template/create-new-template-modal.cjs +39 -46
  23. package/build/components/post-template/create-new-template-modal.cjs.map +2 -2
  24. package/build/components/post-template/hooks.cjs +52 -6
  25. package/build/components/post-template/hooks.cjs.map +2 -2
  26. package/build/components/post-template/swap-template-button.cjs +31 -20
  27. package/build/components/post-template/swap-template-button.cjs.map +2 -2
  28. package/build/components/preferences-modal/index.cjs +35 -27
  29. package/build/components/preferences-modal/index.cjs.map +2 -2
  30. package/build/components/revision-block-diff/index.cjs +9 -32
  31. package/build/components/revision-block-diff/index.cjs.map +3 -3
  32. package/build/components/revision-diff-panel/index.cjs +68 -0
  33. package/build/components/revision-diff-panel/index.cjs.map +7 -0
  34. package/build/components/revision-fields-diff/index.cjs +96 -0
  35. package/build/components/revision-fields-diff/index.cjs.map +7 -0
  36. package/build/components/sidebar/dataform-post-summary.cjs +8 -53
  37. package/build/components/sidebar/dataform-post-summary.cjs.map +2 -2
  38. package/build/components/sidebar/index.cjs +25 -22
  39. package/build/components/sidebar/index.cjs.map +3 -3
  40. package/build/components/sidebar/post-revision-summary.cjs +74 -0
  41. package/build/components/sidebar/post-revision-summary.cjs.map +7 -0
  42. package/build/components/sidebar/post-summary.cjs +35 -42
  43. package/build/components/sidebar/post-summary.cjs.map +3 -3
  44. package/build/components/style-book/index.cjs +4 -3
  45. package/build/components/style-book/index.cjs.map +2 -2
  46. package/build/components/sync-connection-error-modal/index.cjs +2 -2
  47. package/build/components/sync-connection-error-modal/index.cjs.map +1 -1
  48. package/build/components/template-actions-panel/block-theme-content.cjs +188 -0
  49. package/build/components/template-actions-panel/block-theme-content.cjs.map +7 -0
  50. package/build/components/template-actions-panel/classic-theme-content.cjs +159 -0
  51. package/build/components/template-actions-panel/classic-theme-content.cjs.map +7 -0
  52. package/build/components/template-actions-panel/index.cjs +59 -0
  53. package/build/components/template-actions-panel/index.cjs.map +7 -0
  54. package/build/dataviews/store/private-actions.cjs +2 -0
  55. package/build/dataviews/store/private-actions.cjs.map +2 -2
  56. package/build/store/private-actions.cjs +21 -2
  57. package/build/store/private-actions.cjs.map +2 -2
  58. package/build/store/private-selectors.cjs +40 -15
  59. package/build/store/private-selectors.cjs.map +2 -2
  60. package/build-module/components/collaborators-overlay/cursor-registry.mjs +61 -0
  61. package/build-module/components/collaborators-overlay/cursor-registry.mjs.map +7 -0
  62. package/build-module/components/collaborators-overlay/index.mjs +7 -2
  63. package/build-module/components/collaborators-overlay/index.mjs.map +2 -2
  64. package/build-module/components/collaborators-overlay/overlay-iframe-styles.mjs +1 -1
  65. package/build-module/components/collaborators-overlay/overlay-iframe-styles.mjs.map +2 -2
  66. package/build-module/components/collaborators-overlay/overlay.mjs +32 -2
  67. package/build-module/components/collaborators-overlay/overlay.mjs.map +2 -2
  68. package/build-module/components/collaborators-presence/index.mjs +14 -4
  69. package/build-module/components/collaborators-presence/index.mjs.map +2 -2
  70. package/build-module/components/collaborators-presence/list.mjs +20 -4
  71. package/build-module/components/collaborators-presence/list.mjs.map +2 -2
  72. package/build-module/components/post-card-panel/index.mjs +6 -17
  73. package/build-module/components/post-card-panel/index.mjs.map +2 -2
  74. package/build-module/components/post-content-information/index.mjs +6 -13
  75. package/build-module/components/post-content-information/index.mjs.map +2 -2
  76. package/build-module/components/post-revisions-panel/index.mjs +139 -0
  77. package/build-module/components/post-revisions-panel/index.mjs.map +7 -0
  78. package/build-module/components/post-revisions-preview/revisions-slider.mjs +24 -5
  79. package/build-module/components/post-revisions-preview/revisions-slider.mjs.map +2 -2
  80. package/build-module/components/post-template/create-new-template-modal.mjs +39 -46
  81. package/build-module/components/post-template/create-new-template-modal.mjs.map +2 -2
  82. package/build-module/components/post-template/hooks.mjs +53 -7
  83. package/build-module/components/post-template/hooks.mjs.map +2 -2
  84. package/build-module/components/post-template/swap-template-button.mjs +27 -20
  85. package/build-module/components/post-template/swap-template-button.mjs.map +2 -2
  86. package/build-module/components/preferences-modal/index.mjs +35 -27
  87. package/build-module/components/preferences-modal/index.mjs.map +2 -2
  88. package/build-module/components/revision-block-diff/index.mjs +9 -32
  89. package/build-module/components/revision-block-diff/index.mjs.map +2 -2
  90. package/build-module/components/revision-diff-panel/index.mjs +37 -0
  91. package/build-module/components/revision-diff-panel/index.mjs.map +7 -0
  92. package/build-module/components/revision-fields-diff/index.mjs +65 -0
  93. package/build-module/components/revision-fields-diff/index.mjs.map +7 -0
  94. package/build-module/components/sidebar/dataform-post-summary.mjs +8 -53
  95. package/build-module/components/sidebar/dataform-post-summary.mjs.map +2 -2
  96. package/build-module/components/sidebar/index.mjs +25 -22
  97. package/build-module/components/sidebar/index.mjs.map +2 -2
  98. package/build-module/components/sidebar/post-revision-summary.mjs +43 -0
  99. package/build-module/components/sidebar/post-revision-summary.mjs.map +7 -0
  100. package/build-module/components/sidebar/post-summary.mjs +31 -42
  101. package/build-module/components/sidebar/post-summary.mjs.map +2 -2
  102. package/build-module/components/style-book/index.mjs +4 -3
  103. package/build-module/components/style-book/index.mjs.map +2 -2
  104. package/build-module/components/sync-connection-error-modal/index.mjs +2 -2
  105. package/build-module/components/sync-connection-error-modal/index.mjs.map +1 -1
  106. package/build-module/components/template-actions-panel/block-theme-content.mjs +167 -0
  107. package/build-module/components/template-actions-panel/block-theme-content.mjs.map +7 -0
  108. package/build-module/components/template-actions-panel/classic-theme-content.mjs +138 -0
  109. package/build-module/components/template-actions-panel/classic-theme-content.mjs.map +7 -0
  110. package/build-module/components/template-actions-panel/index.mjs +28 -0
  111. package/build-module/components/template-actions-panel/index.mjs.map +7 -0
  112. package/build-module/dataviews/store/private-actions.mjs +5 -1
  113. package/build-module/dataviews/store/private-actions.mjs.map +2 -2
  114. package/build-module/store/private-actions.mjs +21 -2
  115. package/build-module/store/private-actions.mjs.map +2 -2
  116. package/build-module/store/private-selectors.mjs +40 -15
  117. package/build-module/store/private-selectors.mjs.map +2 -2
  118. package/build-style/style-rtl.css +111 -42
  119. package/build-style/style.css +111 -42
  120. package/build-types/components/collaborators-overlay/cursor-registry.d.ts +36 -0
  121. package/build-types/components/collaborators-overlay/cursor-registry.d.ts.map +1 -0
  122. package/build-types/components/collaborators-overlay/index.d.ts +7 -4
  123. package/build-types/components/collaborators-overlay/index.d.ts.map +1 -1
  124. package/build-types/components/collaborators-overlay/overlay-iframe-styles.d.ts +1 -1
  125. package/build-types/components/collaborators-overlay/overlay-iframe-styles.d.ts.map +1 -1
  126. package/build-types/components/collaborators-overlay/overlay.d.ts +4 -1
  127. package/build-types/components/collaborators-overlay/overlay.d.ts.map +1 -1
  128. package/build-types/components/collaborators-presence/index.d.ts.map +1 -1
  129. package/build-types/components/collaborators-presence/list.d.ts +4 -1
  130. package/build-types/components/collaborators-presence/list.d.ts.map +1 -1
  131. package/build-types/components/post-card-panel/index.d.ts.map +1 -1
  132. package/build-types/components/post-content-information/index.d.ts +4 -1
  133. package/build-types/components/post-content-information/index.d.ts.map +1 -1
  134. package/build-types/components/post-revisions-panel/index.d.ts +2 -0
  135. package/build-types/components/post-revisions-panel/index.d.ts.map +1 -0
  136. package/build-types/components/post-revisions-preview/revisions-slider.d.ts.map +1 -1
  137. package/build-types/components/post-template/create-new-template-modal.d.ts.map +1 -1
  138. package/build-types/components/post-template/hooks.d.ts +1 -1
  139. package/build-types/components/post-template/hooks.d.ts.map +1 -1
  140. package/build-types/components/post-template/swap-template-button.d.ts +4 -0
  141. package/build-types/components/post-template/swap-template-button.d.ts.map +1 -1
  142. package/build-types/components/revision-block-diff/index.d.ts.map +1 -1
  143. package/build-types/components/revision-diff-panel/index.d.ts +14 -0
  144. package/build-types/components/revision-diff-panel/index.d.ts.map +1 -0
  145. package/build-types/components/revision-fields-diff/index.d.ts +6 -0
  146. package/build-types/components/revision-fields-diff/index.d.ts.map +1 -0
  147. package/build-types/components/sidebar/dataform-post-summary.d.ts.map +1 -1
  148. package/build-types/components/sidebar/index.d.ts.map +1 -1
  149. package/build-types/components/sidebar/post-revision-summary.d.ts +2 -0
  150. package/build-types/components/sidebar/post-revision-summary.d.ts.map +1 -0
  151. package/build-types/components/sidebar/post-summary.d.ts +3 -0
  152. package/build-types/components/sidebar/post-summary.d.ts.map +1 -1
  153. package/build-types/components/style-book/index.d.ts +2 -1
  154. package/build-types/components/style-book/index.d.ts.map +1 -1
  155. package/build-types/components/template-actions-panel/block-theme-content.d.ts +2 -0
  156. package/build-types/components/template-actions-panel/block-theme-content.d.ts.map +1 -0
  157. package/build-types/components/template-actions-panel/classic-theme-content.d.ts +2 -0
  158. package/build-types/components/template-actions-panel/classic-theme-content.d.ts.map +1 -0
  159. package/build-types/components/template-actions-panel/index.d.ts +2 -0
  160. package/build-types/components/template-actions-panel/index.d.ts.map +1 -0
  161. package/build-types/dataviews/store/private-actions.d.ts.map +1 -1
  162. package/build-types/store/private-actions.d.ts.map +1 -1
  163. package/build-types/store/private-selectors.d.ts.map +1 -1
  164. package/package.json +45 -44
  165. package/src/components/collaborators-overlay/cursor-registry.ts +96 -0
  166. package/src/components/collaborators-overlay/index.tsx +12 -4
  167. package/src/components/collaborators-overlay/overlay-iframe-styles.ts +1 -1
  168. package/src/components/collaborators-overlay/overlay.tsx +45 -1
  169. package/src/components/collaborators-presence/index.tsx +9 -1
  170. package/src/components/collaborators-presence/list.tsx +25 -1
  171. package/src/components/post-card-panel/index.js +7 -21
  172. package/src/components/post-content-information/index.js +5 -16
  173. package/src/components/post-revisions-panel/index.js +151 -0
  174. package/src/components/post-revisions-panel/style.scss +16 -0
  175. package/src/components/post-revisions-preview/revisions-slider.js +29 -7
  176. package/src/components/post-template/create-new-template-modal.js +1 -4
  177. package/src/components/post-template/hooks.js +65 -9
  178. package/src/components/post-template/style.scss +0 -6
  179. package/src/components/post-template/swap-template-button.js +30 -21
  180. package/src/components/preferences-modal/index.js +37 -25
  181. package/src/components/revision-block-diff/index.js +8 -43
  182. package/src/components/revision-diff-panel/index.js +59 -0
  183. package/src/components/revision-fields-diff/index.js +91 -0
  184. package/src/components/sidebar/dataform-post-summary.js +8 -55
  185. package/src/components/sidebar/index.js +33 -22
  186. package/src/components/sidebar/post-revision-summary.js +50 -0
  187. package/src/components/sidebar/post-summary.js +22 -40
  188. package/src/components/sidebar/style.scss +7 -0
  189. package/src/components/style-book/index.js +4 -2
  190. package/src/components/sync-connection-error-modal/index.tsx +2 -2
  191. package/src/components/template-actions-panel/block-theme-content.js +196 -0
  192. package/src/components/template-actions-panel/classic-theme-content.js +170 -0
  193. package/src/components/template-actions-panel/index.js +32 -0
  194. package/src/components/template-actions-panel/style.scss +39 -0
  195. package/src/dataviews/store/private-actions.ts +6 -0
  196. package/src/store/private-actions.js +24 -3
  197. package/src/store/private-selectors.js +46 -16
  198. package/src/style.scss +3 -1
  199. /package/src/components/{revision-block-diff → revision-diff-panel}/style.scss +0 -0
@@ -2,5 +2,5 @@
2
2
  * CSS for the collaborators overlay — cursor indicators, block highlights,
3
3
  * and positioning of Avatar labels inside the editor canvas iframe.
4
4
  */
5
- export declare const OVERLAY_IFRAME_STYLES = "\n.block-canvas-cover {\n\tposition: absolute;\n\ttop: 0;\n\tleft: 0;\n\twidth: 100%;\n\theight: 100%;\n\tpointer-events: none;\n\tz-index: 20000;\n}\n.block-canvas-cover .collaborators-overlay-full {\n\tposition: absolute;\n\ttop: 0;\n\tleft: 0;\n\twidth: 100%;\n\theight: 100%;\n}\n.block-canvas-cover .collaborators-overlay-fixed {\n\tposition: fixed;\n\twidth: 100%;\n\theight: 100%;\n}\n.collaborators-overlay-user {\n\tposition: absolute;\n}\n/* Cursor lines render below avatar labels across all users. The parent\n .collaborators-overlay-user has no z-index so it does not create a\n stacking context \u2014 children participate in the shared overlay context. */\n.collaborators-overlay-user-cursor {\n\tposition: absolute;\n\tz-index: 0;\n\twidth: 2px;\n\tborder-radius: 1px;\n\toutline: 1px solid #fff;\n\tbox-shadow: 0 1px 1px rgba(0, 0, 0, 0.03), 0 1px 2px rgba(0, 0, 0, 0.02), 0 3px 3px rgba(0, 0, 0, 0.02), 0 4px 4px rgba(0, 0, 0, 0.01);\n\tanimation: collaborators-overlay-cursor-blink 1s infinite;\n}\n.collaborators-overlay-selection-rect {\n\tposition: absolute;\n\topacity: 0.15;\n\tpointer-events: none;\n\tborder-radius: 2px;\n}\n\n/* Overlay-specific positioning applied to the Avatar cursor label. */\n.collaborators-overlay-user-label.editor-avatar {\n\tposition: absolute;\n\tz-index: 1;\n\ttransform: translate(-11px, -100%);\n\tmargin-top: -4px;\n\tpointer-events: auto;\n\toverflow: visible;\n\twidth: max-content;\n}\n/* Avatar positioned above a highlighted block as a label. */\n.collaborators-overlay-block-label.editor-avatar {\n\tposition: absolute;\n\tz-index: 1;\n\ttransform: translateY(calc(-100% - 8px));\n\tpointer-events: auto;\n\toverflow: visible;\n\twidth: max-content;\n}\n\n@keyframes collaborators-overlay-cursor-blink {\n\t0%, 45% { opacity: 1; }\n\t55%, 95% { opacity: 0; }\n\t100% { opacity: 1; }\n}\n.collaborators-overlay-cursor-highlighted .collaborators-overlay-user-cursor {\n\tanimation: collaborators-overlay-cursor-highlight 0.6s ease-in-out 3;\n}\n.collaborators-overlay-cursor-highlighted .collaborators-overlay-user-label {\n\tanimation: collaborators-overlay-label-highlight 0.6s ease-in-out 3;\n}\n@keyframes collaborators-overlay-cursor-highlight {\n\t0%, 100% {\n\t\ttransform: scale(1);\n\t\tfilter: drop-shadow(0 0 0 transparent);\n\t}\n\t50% {\n\t\ttransform: scale(1.2);\n\t\tfilter: drop-shadow(0 0 8px currentColor);\n\t}\n}\n@keyframes collaborators-overlay-label-highlight {\n\t0%, 100% {\n\t\ttransform: translate(-11px, -100%) scale(1);\n\t\tfilter: drop-shadow(0 0 0 transparent);\n\t}\n\t50% {\n\t\ttransform: translate(-11px, -100%) scale(1.1);\n\t\tfilter: drop-shadow(0 0 6px currentColor);\n\t}\n}\n.block-editor-block-list__block.is-collaborator-selected:not(:focus)::after {\n\tcontent: \"\";\n\tposition: absolute;\n\tpointer-events: none;\n\ttop: 0;\n\tright: 0;\n\tbottom: 0;\n\tleft: 0;\n\toutline-color: var(--collaborator-outline-color);\n\toutline-style: solid;\n\toutline-width: calc(var(--wp-admin-border-width-focus) / var(--wp-block-editor-iframe-zoom-out-scale, 1));\n\toutline-offset: calc(-1 * var(--wp-admin-border-width-focus) / var(--wp-block-editor-iframe-zoom-out-scale, 1));\n\tbox-shadow: inset 0 0 0 calc(var(--wp-admin-border-width-focus, 2px) + 1px) #fff, 0 0 0 1px #fff, 0 1px 1px rgba(0, 0, 0, 0.03), 0 1px 2px rgba(0, 0, 0, 0.02), 0 3px 3px rgba(0, 0, 0, 0.02), 0 4px 4px rgba(0, 0, 0, 0.01);\n\tz-index: 1;\n}\n@media (prefers-reduced-motion: reduce) {\n\t.collaborators-overlay-user-label,\n\t.collaborators-overlay-user-cursor {\n\t\tanimation: none;\n\t}\n}\n";
5
+ export declare const OVERLAY_IFRAME_STYLES = "\n.block-canvas-cover {\n\tposition: absolute;\n\ttop: 0;\n\tleft: 0;\n\twidth: 100%;\n\theight: 100%;\n\tpointer-events: none;\n\tz-index: 20000;\n}\n.block-canvas-cover .collaborators-overlay-full {\n\tposition: absolute;\n\ttop: 0;\n\tleft: 0;\n\twidth: 100%;\n\theight: 100%;\n}\n.block-canvas-cover .collaborators-overlay-fixed {\n\tposition: fixed;\n\twidth: 100%;\n\theight: 100%;\n}\n.collaborators-overlay-user {\n\tposition: absolute;\n}\n/* Cursor lines render below avatar labels across all users. The parent\n .collaborators-overlay-user has no z-index so it does not create a\n stacking context \u2014 children participate in the shared overlay context. */\n.collaborators-overlay-user-cursor {\n\tposition: absolute;\n\tz-index: 0;\n\twidth: 2px;\n\tborder-radius: 1px;\n\toutline: 1px solid #fff;\n\tbox-shadow: 0 1px 1px rgba(0, 0, 0, 0.03), 0 1px 2px rgba(0, 0, 0, 0.02), 0 3px 3px rgba(0, 0, 0, 0.02), 0 4px 4px rgba(0, 0, 0, 0.01);\n\tanimation: collaborators-overlay-cursor-blink 1s infinite;\n}\n.collaborators-overlay-selection-rect {\n\tposition: absolute;\n\topacity: 0.15;\n\tpointer-events: none;\n\tborder-radius: 2px;\n}\n\n/* Overlay-specific positioning applied to the Avatar cursor label. */\n.collaborators-overlay-user-label.editor-avatar {\n\tposition: absolute;\n\tz-index: 1;\n\ttransform: translate(-11px, -100%);\n\tmargin-top: -4px;\n\tpointer-events: auto;\n\toverflow: visible;\n\twidth: max-content;\n}\n/* Avatar positioned above a highlighted block as a label. */\n.collaborators-overlay-block-label.editor-avatar {\n\tposition: absolute;\n\tz-index: 1;\n\ttransform: translateY(calc(-100% - 8px));\n\tpointer-events: auto;\n\toverflow: visible;\n\twidth: max-content;\n}\n\n@keyframes collaborators-overlay-cursor-blink {\n\t0%, 45% { opacity: 1; }\n\t55%, 95% { opacity: 0; }\n\t100% { opacity: 1; }\n}\n.collaborators-overlay-cursor-highlighted .collaborators-overlay-user-cursor {\n\tanimation: collaborators-overlay-cursor-highlight 0.6s ease-in-out 3;\n}\n.collaborators-overlay-cursor-highlighted .collaborators-overlay-user-label {\n\tanimation: collaborators-overlay-label-highlight 0.6s ease-in-out 3;\n}\n@keyframes collaborators-overlay-cursor-highlight {\n\t0%, 100% {\n\t\ttransform: scale(1);\n\t\tfilter: drop-shadow(0 0 0 transparent);\n\t}\n\t50% {\n\t\ttransform: scale(1.2);\n\t\tfilter: drop-shadow(0 0 8px currentColor);\n\t}\n}\n@keyframes collaborators-overlay-label-highlight {\n\t0%, 100% {\n\t\ttransform: translate(-11px, -100%) scale(1);\n\t\tfilter: drop-shadow(0 0 0 transparent);\n\t}\n\t50% {\n\t\ttransform: translate(-11px, -100%) scale(1.1);\n\t\tfilter: drop-shadow(0 0 6px currentColor);\n\t}\n}\n.block-editor-block-list__block.is-collaborator-selected:not(:focus)::after {\n\tcontent: \"\";\n\tposition: absolute;\n\tpointer-events: none;\n\ttop: 0;\n\tright: 0;\n\tbottom: 0;\n\tleft: 0;\n\toutline-color: var(--collaborator-outline-color);\n\toutline-style: solid;\n\toutline-width: calc(var(--wp-admin-border-width-focus) / var(--wp-block-editor-iframe-zoom-out-scale, 1));\n\toutline-offset: calc(-1 * var(--wp-admin-border-width-focus) / var(--wp-block-editor-iframe-zoom-out-scale, 1));\n\tbox-shadow: inset 0 0 0 calc((var(--wp-admin-border-width-focus) / var(--wp-block-editor-iframe-zoom-out-scale, 1)) + 0.5px) rgba(#fff, 0.7);\n\tz-index: 1;\n}\n@media (prefers-reduced-motion: reduce) {\n\t.collaborators-overlay-user-label,\n\t.collaborators-overlay-user-cursor {\n\t\tanimation: none;\n\t}\n}\n";
6
6
  //# sourceMappingURL=overlay-iframe-styles.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"overlay-iframe-styles.d.ts","sourceRoot":"","sources":["../../../src/components/collaborators-overlay/overlay-iframe-styles.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAWH,eAAO,MAAM,qBAAqB,8/GAoHjC,CAAC"}
1
+ {"version":3,"file":"overlay-iframe-styles.d.ts","sourceRoot":"","sources":["../../../src/components/collaborators-overlay/overlay-iframe-styles.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAWH,eAAO,MAAM,qBAAqB,86GAoHjC,CAAC"}
@@ -1,7 +1,9 @@
1
+ import { type CursorRegistry } from './cursor-registry';
1
2
  interface OverlayProps {
2
3
  blockEditorDocument?: Document;
3
4
  postId: number | null;
4
5
  postType: string | null;
6
+ cursorRegistry?: CursorRegistry;
5
7
  }
6
8
  /**
7
9
  * This component is responsible for rendering the overlay components within the editor iframe.
@@ -10,8 +12,9 @@ interface OverlayProps {
10
12
  * @param props.blockEditorDocument - The block editor document.
11
13
  * @param props.postId - The ID of the post.
12
14
  * @param props.postType - The type of the post.
15
+ * @param props.cursorRegistry - The shared cursor registry.
13
16
  * @return The Overlay component.
14
17
  */
15
- export declare function Overlay({ blockEditorDocument, postId, postType, }: OverlayProps): import("react").JSX.Element;
18
+ export declare function Overlay({ blockEditorDocument, postId, postType, cursorRegistry, }: OverlayProps): import("react").JSX.Element;
16
19
  export {};
17
20
  //# sourceMappingURL=overlay.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"overlay.d.ts","sourceRoot":"","sources":["../../../src/components/collaborators-overlay/overlay.tsx"],"names":[],"mappings":"AAoBA,UAAU,YAAY;IACrB,mBAAmB,CAAC,EAAE,QAAQ,CAAC;IAC/B,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;CACxB;AAED;;;;;;;;GAQG;AACH,wBAAgB,OAAO,CAAE,EACxB,mBAAmB,EACnB,MAAM,EACN,QAAQ,GACR,EAAE,YAAY,+BA0Hd"}
1
+ {"version":3,"file":"overlay.d.ts","sourceRoot":"","sources":["../../../src/components/collaborators-overlay/overlay.tsx"],"names":[],"mappings":"AAUA,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAWxD,UAAU,YAAY;IACrB,mBAAmB,CAAC,EAAE,QAAQ,CAAC;IAC/B,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,cAAc,CAAC,EAAE,cAAc,CAAC;CAChC;AAED;;;;;;;;;GASG;AACH,wBAAgB,OAAO,CAAE,EACxB,mBAAmB,EACnB,MAAM,EACN,QAAQ,EACR,cAAc,GACd,EAAE,YAAY,+BAkKd"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/collaborators-presence/index.tsx"],"names":[],"mappings":"AAeA,OAAO,sCAAsC,CAAC;AAK9C,UAAU,0BAA0B;IACnC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;CACxB;AAED;;;;;;;GAOG;AACH,wBAAgB,qBAAqB,CAAE,EACtC,MAAM,EACN,QAAQ,GACR,EAAE,0BAA0B,sCA+F5B"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/collaborators-presence/index.tsx"],"names":[],"mappings":"AAgBA,OAAO,sCAAsC,CAAC;AAK9C,UAAU,0BAA0B;IACnC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;CACxB;AAED;;;;;;;GAOG;AACH,wBAAgB,qBAAqB,CAAE,EACtC,MAAM,EACN,QAAQ,GACR,EAAE,0BAA0B,sCAsG5B"}
@@ -1,9 +1,11 @@
1
1
  import { type PostEditorAwarenessState } from '@wordpress/core-data';
2
+ import { type CursorRegistry } from '../collaborators-overlay/cursor-registry';
2
3
  import './styles/collaborators-list.scss';
3
4
  interface CollaboratorsListProps {
4
5
  activeCollaborators: PostEditorAwarenessState[];
5
6
  popoverAnchor?: HTMLElement | null;
6
7
  setIsPopoverVisible: (isVisible: boolean) => void;
8
+ cursorRegistry: CursorRegistry;
7
9
  }
8
10
  /**
9
11
  * Renders a list showing all active collaborators with their details.
@@ -13,7 +15,8 @@ interface CollaboratorsListProps {
13
15
  * @param props.activeCollaborators List of active collaborators
14
16
  * @param props.popoverAnchor Anchor element for the popover
15
17
  * @param props.setIsPopoverVisible Callback to set the visibility of the popover
18
+ * @param props.cursorRegistry Shared registry for scroll-to-cursor support
16
19
  */
17
- export declare function CollaboratorsList({ activeCollaborators, popoverAnchor, setIsPopoverVisible, }: CollaboratorsListProps): import("react").JSX.Element;
20
+ export declare function CollaboratorsList({ activeCollaborators, popoverAnchor, setIsPopoverVisible, cursorRegistry, }: CollaboratorsListProps): import("react").JSX.Element;
18
21
  export {};
19
22
  //# sourceMappingURL=list.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"list.d.ts","sourceRoot":"","sources":["../../../src/components/collaborators-presence/list.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,sBAAsB,CAAC;AAMrE,OAAO,kCAAkC,CAAC;AAE1C,UAAU,sBAAsB;IAC/B,mBAAmB,EAAE,wBAAwB,EAAE,CAAC;IAChD,aAAa,CAAC,EAAE,WAAW,GAAG,IAAI,CAAC;IACnC,mBAAmB,EAAE,CAAE,SAAS,EAAE,OAAO,KAAM,IAAI,CAAC;CACpD;AAED;;;;;;;;GAQG;AACH,wBAAgB,iBAAiB,CAAE,EAClC,mBAAmB,EACnB,aAAa,EACb,mBAAmB,GACnB,EAAE,sBAAsB,+BAmExB"}
1
+ {"version":3,"file":"list.d.ts","sourceRoot":"","sources":["../../../src/components/collaborators-presence/list.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,sBAAsB,CAAC;AAMrE,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,0CAA0C,CAAC;AAE/E,OAAO,kCAAkC,CAAC;AAE1C,UAAU,sBAAsB;IAC/B,mBAAmB,EAAE,wBAAwB,EAAE,CAAC;IAChD,aAAa,CAAC,EAAE,WAAW,GAAG,IAAI,CAAC;IACnC,mBAAmB,EAAE,CAAE,SAAS,EAAE,OAAO,KAAM,IAAI,CAAC;IACpD,cAAc,EAAE,cAAc,CAAC;CAC/B;AAED;;;;;;;;;GASG;AACH,wBAAgB,iBAAiB,CAAE,EAClC,mBAAmB,EACnB,aAAa,EACb,mBAAmB,EACnB,cAAc,GACd,EAAE,sBAAsB,+BAsFxB"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/post-card-panel/index.js"],"names":[],"mappings":"AAgCA;;;;;;;;;;GAUG;AACH,sGAPG;IAAgC,QAAQ;IACR,MAAM;IACN,WAAW;IACX,iBAAiB;IACjB,OAAO;CACvC,GAAS,KAAK,CAAC,SAAS,CAkJ1B"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/post-card-panel/index.js"],"names":[],"mappings":"AAgCA;;;;;;;;;;GAUG;AACH,sGAPG;IAAgC,QAAQ;IACR,MAAM;IACN,WAAW;IACX,iBAAiB;IACjB,OAAO;CACvC,GAAS,KAAK,CAAC,SAAS,CAoI1B"}
@@ -1,2 +1,5 @@
1
- export default function PostContentInformation(): import("react").JSX.Element | null;
1
+ export default function PostContentInformation(): import("react").JSX.Element;
2
+ export function PostContentInformationUI({ postContent }: {
3
+ postContent: any;
4
+ }): import("react").JSX.Element | null;
2
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/post-content-information/index.js"],"names":[],"mappings":"AAwBA,qFA2EC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/post-content-information/index.js"],"names":[],"mappings":"AAuBA,8EAuBC;AAED;;uCAwCC"}
@@ -0,0 +1,2 @@
1
+ export default function PostRevisionsPanel(): import("react").JSX.Element;
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/post-revisions-panel/index.js"],"names":[],"mappings":"AAgJA,0EAMC"}
@@ -1 +1 @@
1
- {"version":3,"file":"revisions-slider.d.ts","sourceRoot":"","sources":["../../../src/components/post-revisions-preview/revisions-slider.js"],"names":[],"mappings":";AAgBA;;;;GAIG;AACH,oCAFY,KAAK,CAAC,GAAG,CAAC,OAAO,CA4G5B"}
1
+ {"version":3,"file":"revisions-slider.d.ts","sourceRoot":"","sources":["../../../src/components/post-revisions-preview/revisions-slider.js"],"names":[],"mappings":";AAgBA;;;;GAIG;AACH,oCAFY,KAAK,CAAC,GAAG,CAAC,OAAO,CAkI5B"}
@@ -1 +1 @@
1
- {"version":3,"file":"create-new-template-modal.d.ts","sourceRoot":"","sources":["../../../src/components/post-template/create-new-template-modal.js"],"names":[],"mappings":"AA4BA;;gCAoIC"}
1
+ {"version":3,"file":"create-new-template-modal.d.ts","sourceRoot":"","sources":["../../../src/components/post-template/create-new-template-modal.js"],"names":[],"mappings":"AA4BA;;gCAiIC"}
@@ -3,7 +3,7 @@ export function useEditedPostContext(): {
3
3
  postType: string;
4
4
  };
5
5
  export function useAllowSwitchingTemplates(): boolean;
6
- export function useAvailableTemplates(postType: any): false | (import("@wordpress/core-data").UnstableBase<any> | import("@wordpress/core-data").Attachment<any> | import("@wordpress/core-data").Comment<any> | import("@wordpress/core-data").FontCollection<any> | import("@wordpress/core-data").GlobalStylesRevision<any> | import("@wordpress/core-data").Icon<any> | import("@wordpress/core-data").MenuLocation<any> | import("@wordpress/core-data").NavMenu<any> | import("@wordpress/core-data").NavMenuItem<any> | import("@wordpress/core-data").Page<any> | import("@wordpress/core-data").Plugin<any> | import("@wordpress/core-data").Post<any> | import("@wordpress/core-data").PostStatusObject<any> | import("@wordpress/core-data").PostRevision<any> | import("@wordpress/core-data").Settings<any> | import("@wordpress/core-data").Sidebar<any> | import("@wordpress/core-data").Taxonomy<any> | import("@wordpress/core-data").Term<any> | import("@wordpress/core-data").Theme<any> | import("@wordpress/core-data").User<any> | import("@wordpress/core-data").Type<any> | import("@wordpress/core-data").Widget<any> | import("@wordpress/core-data").WidgetType<any> | import("@wordpress/core-data").WpFontFamily<any> | import("@wordpress/core-data").WpTemplate<any> | import("@wordpress/core-data").WpTemplatePart<any> | Partial<import("@wordpress/core-data").UnstableBase<any> | import("@wordpress/core-data").Attachment<any> | import("@wordpress/core-data").Comment<any> | import("@wordpress/core-data").FontCollection<any> | import("@wordpress/core-data").GlobalStylesRevision<any> | import("@wordpress/core-data").Icon<any> | import("@wordpress/core-data").MenuLocation<any> | import("@wordpress/core-data").NavMenu<any> | import("@wordpress/core-data").NavMenuItem<any> | import("@wordpress/core-data").Page<any> | import("@wordpress/core-data").Plugin<any> | import("@wordpress/core-data").Post<any> | import("@wordpress/core-data").PostStatusObject<any> | import("@wordpress/core-data").PostRevision<any> | import("@wordpress/core-data").Settings<any> | import("@wordpress/core-data").Sidebar<any> | import("@wordpress/core-data").Taxonomy<any> | import("@wordpress/core-data").Term<any> | import("@wordpress/core-data").Theme<any> | import("@wordpress/core-data").User<any> | import("@wordpress/core-data").Type<any> | import("@wordpress/core-data").Widget<any> | import("@wordpress/core-data").WidgetType<any> | import("@wordpress/core-data").WpFontFamily<any> | import("@wordpress/core-data").WpTemplate<any> | import("@wordpress/core-data").WpTemplatePart<any>>)[] | undefined;
6
+ export function useAvailableTemplates(): false | any[];
7
7
  export function usePostTemplatePanelMode(): "classic" | "block-theme" | null;
8
8
  export function useCurrentTemplateSlug(): any;
9
9
  //# sourceMappingURL=hooks.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"hooks.d.ts","sourceRoot":"","sources":["../../../src/components/post-template/hooks.js"],"names":[],"mappings":"AAYA;;;EAQC;AACD,sDA8BC;AAeD,+gFAeC;AAED,6EAwCC;AAED,8CAuBC"}
1
+ {"version":3,"file":"hooks.d.ts","sourceRoot":"","sources":["../../../src/components/post-template/hooks.js"],"names":[],"mappings":"AAaA;;;EAQC;AACD,sDA8BC;AAeD,uDAsEC;AAED,6EAwCC;AAED,8CAuBC"}
@@ -1,3 +1,7 @@
1
+ export function SwapTemplateModal({ onRequestClose, onSelect }: {
2
+ onRequestClose: any;
3
+ onSelect: any;
4
+ }): import("react").JSX.Element;
1
5
  export default function SwapTemplateButton({ onClick }: {
2
6
  onClick: any;
3
7
  }): import("react").JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"swap-template-button.d.ts","sourceRoot":"","sources":["../../../src/components/post-template/swap-template-button.js"],"names":[],"mappings":"AAkBA;;gCA2CC"}
1
+ {"version":3,"file":"swap-template-button.d.ts","sourceRoot":"","sources":["../../../src/components/post-template/swap-template-button.js"],"names":[],"mappings":"AAkBA;;;gCA4BC;AAED;;gCAqBC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/revision-block-diff/index.js"],"names":[],"mappings":"AAaA;;;GAGG;AACH,qFAwDC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/revision-block-diff/index.js"],"names":[],"mappings":"AAYA;;;GAGG;AACH,qFAsBC"}
@@ -0,0 +1,14 @@
1
+ /**
2
+ * Renders a panel of word-level diffs.
3
+ *
4
+ * @param {Object} props
5
+ * @param {string} props.title Panel title.
6
+ * @param {Object} props.entries Map of key → diffWords parts arrays.
7
+ * @param {boolean} props.initialOpen Whether the panel starts open.
8
+ */
9
+ export default function RevisionDiffPanel({ title, entries, initialOpen }: {
10
+ title: string;
11
+ entries: Object;
12
+ initialOpen: boolean;
13
+ }): import("react").JSX.Element | null;
14
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/revision-diff-panel/index.js"],"names":[],"mappings":"AAUA;;;;;;;GAOG;AACH,2EAJG;IAAuB,KAAK,EAApB,MAAM;IACS,OAAO,EAAtB,MAAM;IACS,WAAW,EAA1B,OAAO;CACjB,sCAyCA"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Panel that shows meta field diffs between the current revision and
3
+ * the previous revision in the document sidebar during revision mode.
4
+ */
5
+ export default function RevisionFieldsDiffPanel(): import("react").JSX.Element;
6
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/revision-fields-diff/index.js"],"names":[],"mappings":"AAmCA;;;GAGG;AACH,+EAmDC"}
@@ -1 +1 @@
1
- {"version":3,"file":"dataform-post-summary.d.ts","sourceRoot":"","sources":["../../../src/components/sidebar/dataform-post-summary.js"],"names":[],"mappings":"AAuEA;;gCA0HC"}
1
+ {"version":3,"file":"dataform-post-summary.d.ts","sourceRoot":"","sources":["../../../src/components/sidebar/dataform-post-summary.js"],"names":[],"mappings":"AAuBA;;gCA2HC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/sidebar/index.js"],"names":[],"mappings":";AA2JA;;;gCAkEC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/sidebar/index.js"],"names":[],"mappings":";AAsKA;;;gCAkEC"}
@@ -0,0 +1,2 @@
1
+ export default function PostRevisionSummary(): import("react").JSX.Element | null;
2
+ //# sourceMappingURL=post-revision-summary.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"post-revision-summary.d.ts","sourceRoot":"","sources":["../../../src/components/sidebar/post-revision-summary.js"],"names":[],"mappings":"AAmBA,kFA8BC"}
@@ -1,3 +1,6 @@
1
+ export function OpenRevisionsClassicScreen({ revisionId }: {
2
+ revisionId: any;
3
+ }): import("react").JSX.Element;
1
4
  export default function PostSummary({ onActionPerformed }: {
2
5
  onActionPerformed: any;
3
6
  }): import("react").JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"post-summary.d.ts","sourceRoot":"","sources":["../../../src/components/sidebar/post-summary.js"],"names":[],"mappings":"AA8CA;;gCAYC"}
1
+ {"version":3,"file":"post-summary.d.ts","sourceRoot":"","sources":["../../../src/components/sidebar/post-summary.js"],"names":[],"mappings":"AA2CA;;gCAUC;AAED;;gCAYC"}
@@ -4,11 +4,12 @@
4
4
  * @return {Array} Deduped examples.
5
5
  */
6
6
  export function getExamplesForSinglePageUse(examples: any[]): any[];
7
- export function StyleBookPreview({ userConfig, isStatic, path, onPathChange, }: {
7
+ export function StyleBookPreview({ userConfig, isStatic, path, onPathChange, settings: settingsProp, }: {
8
8
  path: string;
9
9
  onPathChange: Function;
10
10
  userConfig: Object;
11
11
  isStatic: boolean;
12
+ settings: Object;
12
13
  }): Object;
13
14
  export function StyleBookBody({ examples, isSelected, onClick, onSelect, settings, title, goTo, }: {
14
15
  examples: any;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/style-book/index.js"],"names":[],"mappings":"AAyLA;;;;GAIG;AACH,oEAkBC;AA2KM,gFANJ;IAAwB,IAAI,EAApB,MAAM;IACU,YAAY;IACZ,UAAU,EAA1B,MAAM;IACU,QAAQ,EAAxB,OAAO;CACf,GAAS,MAAM,CAkLjB;AAEM;;;;;;;;gCAmFN"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/style-book/index.js"],"names":[],"mappings":"AAyLA;;;;GAIG;AACH,oEAkBC;AA4KM,wGAPJ;IAAwB,IAAI,EAApB,MAAM;IACU,YAAY;IACZ,UAAU,EAA1B,MAAM;IACU,QAAQ,EAAxB,OAAO;IACS,QAAQ,EAAxB,MAAM;CACd,GAAS,MAAM,CAmLjB;AAEM;;;;;;;;gCAmFN"}
@@ -0,0 +1,2 @@
1
+ export default function TemplateActionsPanelContent(): import("react").JSX.Element | null;
2
+ //# sourceMappingURL=block-theme-content.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"block-theme-content.d.ts","sourceRoot":"","sources":["../../../src/components/template-actions-panel/block-theme-content.js"],"names":[],"mappings":"AA+BA,0FAoKC"}
@@ -0,0 +1,2 @@
1
+ export default function ClassicThemeContent(): import("react").JSX.Element | null;
2
+ //# sourceMappingURL=classic-theme-content.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"classic-theme-content.d.ts","sourceRoot":"","sources":["../../../src/components/template-actions-panel/classic-theme-content.js"],"names":[],"mappings":"AA6BA,kFA4IC"}
@@ -0,0 +1,2 @@
1
+ export default function TemplateActionsPanel(): import("react").JSX.Element | null;
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/template-actions-panel/index.js"],"names":[],"mappings":"AAaA,mFAkBC"}
@@ -1 +1 @@
1
- {"version":3,"file":"private-actions.d.ts","sourceRoot":"","sources":["../../../src/dataviews/store/private-actions.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,sBAAsB,CAAC;AA0D1D,OAAO,CAAC,MAAM,CAAC;IACd,UAAU,MAAM;QACf,8BAA8B,CAAC,EAAE,OAAO,CAAC;QACzC,yBAAyB,CAAC,EAAE,OAAO,CAAC;KACpC;CACD;AAgBD,wBAAgB,oBAAoB,CAAE,IAAI,EACzC,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,MAAM,CAAE,IAAI,CAAE;;;;;EAQtB;AAED,wBAAgB,sBAAsB,CACrC,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,MAAM;;;;;EAQhB;AAED,wBAAgB,mBAAmB,CAAE,IAAI,EACxC,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,KAAK,CAAE,IAAI,CAAE;;;;;EAQrB;AAED,wBAAgB,qBAAqB,CACpC,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,MAAM;;;;;EAQf;AAED,wBAAgB,UAAU,CAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM;;;;EAMrD;AA2BD,eAAO,MAAM,sBAAsB,GAChC,UAAU,MAAM,MACV,cAAc;IAAE,QAAQ,EAAE,GAAG,CAAA;CAAE,kBAuJtC,CAAC"}
1
+ {"version":3,"file":"private-actions.d.ts","sourceRoot":"","sources":["../../../src/dataviews/store/private-actions.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,sBAAsB,CAAC;AA4D1D,OAAO,CAAC,MAAM,CAAC;IACd,UAAU,MAAM;QACf,8BAA8B,CAAC,EAAE,OAAO,CAAC;QACzC,yBAAyB,CAAC,EAAE,OAAO,CAAC;KACpC;CACD;AAgBD,wBAAgB,oBAAoB,CAAE,IAAI,EACzC,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,MAAM,CAAE,IAAI,CAAE;;;;;EAQtB;AAED,wBAAgB,sBAAsB,CACrC,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,MAAM;;;;;EAQhB;AAED,wBAAgB,mBAAmB,CAAE,IAAI,EACxC,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,KAAK,CAAE,IAAI,CAAE;;;;;EAQrB;AAED,wBAAgB,qBAAqB,CACpC,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,MAAM;;;;;EAQf;AAED,wBAAgB,UAAU,CAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM;;;;EAMrD;AA2BD,eAAO,MAAM,sBAAsB,GAChC,UAAU,MAAM,MACV,cAAc;IAAE,QAAQ,EAAE,GAAG,CAAA;CAAE,kBA2JtC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"private-actions.d.ts","sourceRoot":"","sources":["../../src/store/private-actions.js"],"names":[],"mappings":"AAoBA;;;;;;GAMG;AACH,yCAJW,MAAM,GAEL,MAAM,CAOjB;AA4fD;;;;;GAKG;AACH,oCAHW,MAAM,GACL,MAAM,CAOjB;AAED;;;;;GAKG;AACH,uCAHW,OAAO,GACN,MAAM,CAOjB;AAED;;;;GAIG;AACH,yCAFY,MAAM,CAMjB;AAED;;;;;GAKG;AACH,8CAHW,MAAM,GACL,MAAM,CAOjB;AAED;;;;;;GAMG;AACH,iDAHW,MAAM,GAAC,IAAI,GACV,MAAM,CAOjB;AAED;;;;;GAKG;AACH,8CAHW,OAAO,GACN,MAAM,CAOjB;AAoED;;;;;;;GAOG;AACH,mCALW,SAAS,GAAC,MAAM,GAAC,KAAK,YAE9B;IAAyC,KAAK;CAC9C,GAAS,MAAM,CAQjB;;AAlpBM,yCAFK,MAAM,OAAA,IAIT;;;;CAA8B,kBAiCrC;AAOK,2CAFI,MAAM,EAAE,IAIhB;;CAAY,UAgBb;AAOK,2CAFI,MAAM,EAAE,IAIhB;;CAAY,UAcb;AAYK,iHANJ;IAA2B,MAAM;IACN,kBAAkB;IAClB,cAAc;IACd,KAAK;IACL,oBAAoB;CACjD,IASE;;CAAY,UAoGb;AAUK,yCALI,MAAM,kBAEd;IAA0B,SAAS;CAErC,IAGQ;;CAAY,mBA0HnB;AAOK,gDAEE;;CAAY,mBAwHnB;AAOK,8CAFI,MAAM,IAId;;;CAAoB,UAwBrB;AAqFK,4CAFI,MAAM,IAIR;;;;CAA8B,mBAwDrC"}
1
+ {"version":3,"file":"private-actions.d.ts","sourceRoot":"","sources":["../../src/store/private-actions.js"],"names":[],"mappings":"AAoBA;;;;;;GAMG;AACH,yCAJW,MAAM,GAEL,MAAM,CAOjB;AA4fD;;;;;GAKG;AACH,oCAHW,MAAM,GACL,MAAM,CAOjB;AAED;;;;;GAKG;AACH,uCAHW,OAAO,GACN,MAAM,CAOjB;AAED;;;;GAIG;AACH,yCAFY,MAAM,CAMjB;AAED;;;;;GAKG;AACH,8CAHW,MAAM,GACL,MAAM,CAOjB;AAED;;;;;;GAMG;AACH,iDAHW,MAAM,GAAC,IAAI,GACV,MAAM,CAOjB;AAED;;;;;GAKG;AACH,8CAHW,OAAO,GACN,MAAM,CAOjB;AAyFD;;;;;;;GAOG;AACH,mCALW,SAAS,GAAC,MAAM,GAAC,KAAK,YAE9B;IAAyC,KAAK;CAC9C,GAAS,MAAM,CAQjB;;AAvqBM,yCAFK,MAAM,OAAA,IAIT;;;;CAA8B,kBAiCrC;AAOK,2CAFI,MAAM,EAAE,IAIhB;;CAAY,UAgBb;AAOK,2CAFI,MAAM,EAAE,IAIhB;;CAAY,UAcb;AAYK,iHANJ;IAA2B,MAAM;IACN,kBAAkB;IAClB,cAAc;IACd,KAAK;IACL,oBAAoB;CACjD,IASE;;CAAY,UAoGb;AAUK,yCALI,MAAM,kBAEd;IAA0B,SAAS;CAErC,IAGQ;;CAAY,mBA0HnB;AAOK,gDAEE;;CAAY,mBAwHnB;AAOK,8CAFI,MAAM,IAId;;;CAAoB,UAwBrB;AAqFK,4CAFI,MAAM,IAIR;;;;CAA8B,mBA6ErC"}
@@ -1 +1 @@
1
- {"version":3,"file":"private-selectors.d.ts","sourceRoot":"","sources":["../../src/store/private-selectors.js"],"names":[],"mappings":"AAwHA,sDAEC;AACD,6DAEC;AAsFD,2GAEC;AAED,mEAEC;AAED,yGAEC;AAiGD;;;;;GAKG;AACH,qCAHW,MAAM,GACL,MAAM,CAIjB;AAED;;;;;GAKG;AACH,wCAHW,MAAM,GACL,OAAO,CAIlB;AAED;;;;;GAKG;AACH,0CAHW,MAAM,GACL,MAAM,CAIjB;AAED;;;;;GAKG;AACH,uCAHW,MAAM,GACL,OAAO,CAIlB;AAED;;;;;GAKG;AACH,6CAHW,MAAM,GACL,OAAO,CAIlB;AAED;;;;;GAKG;AACH,4CAHW,MAAM,GACL,MAAM,GAAC,IAAI,CAItB;AA8CD;;;;;;GAMG;AACH,uCAJW,MAAM,GAEL,SAAS,GAAC,MAAM,GAAC,KAAK,CAIjC;AAED;;;;;;GAMG;AACH,qCAJW,MAAM,GAEL,OAAO,CAIlB;AAhZD;;;;;;GAMG;AACH;;;;EAqEE;AAeF;;;;EAqCE;AAEF;;;;;;;;;GASG;AACH;;;;EA2BE;AAcF;;;;;;;;GAQG;AACH;;;;EAiCE;AAEF;;;;;;;GAOG;AACH;;;;EAyCE;AA8DF;;;;;GAKG;AACH;;;;EAoCE;AAwBF;;;;;;GAMG;AACH;;;;EA6CE"}
1
+ {"version":3,"file":"private-selectors.d.ts","sourceRoot":"","sources":["../../src/store/private-selectors.js"],"names":[],"mappings":"AAwHA,sDAEC;AACD,6DAEC;AAsFD,2GAEC;AAED,mEAEC;AAED,yGAEC;AAiGD;;;;;GAKG;AACH,qCAHW,MAAM,GACL,MAAM,CAIjB;AAED;;;;;GAKG;AACH,wCAHW,MAAM,GACL,OAAO,CAIlB;AAED;;;;;GAKG;AACH,0CAHW,MAAM,GACL,MAAM,CAIjB;AAED;;;;;GAKG;AACH,uCAHW,MAAM,GACL,OAAO,CAIlB;AAED;;;;;GAKG;AACH,6CAHW,MAAM,GACL,OAAO,CAIlB;AAED;;;;;GAKG;AACH,4CAHW,MAAM,GACL,MAAM,GAAC,IAAI,CAItB;AA2DD;;;;;;GAMG;AACH,uCAJW,MAAM,GAEL,SAAS,GAAC,MAAM,GAAC,KAAK,CAIjC;AAED;;;;;;GAMG;AACH,qCAJW,MAAM,GAEL,OAAO,CAIlB;AA7ZD;;;;;;GAMG;AACH;;;;EAqEE;AAeF;;;;EAqCE;AAEF;;;;;;;;;GASG;AACH;;;;EA2BE;AAcF;;;;;;;;GAQG;AACH;;;;EAiCE;AAEF;;;;;;;GAOG;AACH;;;;EAyCE;AA8DF;;;;;GAKG;AACH;;;;EAiDE;AAwBF;;;;;;GAMG;AACH;;;;EA8DE"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wordpress/editor",
3
- "version": "14.42.0",
3
+ "version": "14.43.0",
4
4
  "description": "Enhanced block editor for WordPress posts.",
5
5
  "author": "The WordPress Contributors",
6
6
  "license": "GPL-2.0-or-later",
@@ -61,48 +61,49 @@
61
61
  ],
62
62
  "dependencies": {
63
63
  "@floating-ui/react-dom": "2.0.8",
64
- "@wordpress/a11y": "^4.42.0",
65
- "@wordpress/api-fetch": "^7.42.0",
66
- "@wordpress/base-styles": "^6.18.0",
67
- "@wordpress/blob": "^4.42.0",
68
- "@wordpress/block-editor": "^15.15.0",
69
- "@wordpress/block-serialization-default-parser": "^5.42.0",
70
- "@wordpress/blocks": "^15.15.0",
71
- "@wordpress/commands": "^1.42.0",
72
- "@wordpress/components": "^32.4.0",
73
- "@wordpress/compose": "^7.42.0",
74
- "@wordpress/core-data": "^7.42.0",
75
- "@wordpress/data": "^10.42.0",
76
- "@wordpress/dataviews": "^13.1.0",
77
- "@wordpress/date": "^5.42.0",
78
- "@wordpress/deprecated": "^4.42.0",
79
- "@wordpress/dom": "^4.42.0",
80
- "@wordpress/element": "^6.42.0",
81
- "@wordpress/fields": "^0.34.0",
82
- "@wordpress/global-styles-engine": "^1.9.0",
83
- "@wordpress/global-styles-ui": "^1.9.0",
84
- "@wordpress/hooks": "^4.42.0",
85
- "@wordpress/html-entities": "^4.42.0",
86
- "@wordpress/i18n": "^6.15.0",
87
- "@wordpress/icons": "^12.0.0",
88
- "@wordpress/interface": "^9.27.0",
89
- "@wordpress/keyboard-shortcuts": "^5.42.0",
90
- "@wordpress/keycodes": "^4.42.0",
91
- "@wordpress/media-editor": "^0.5.0",
92
- "@wordpress/media-fields": "^0.7.0",
93
- "@wordpress/media-utils": "^5.42.0",
94
- "@wordpress/notices": "^5.42.0",
95
- "@wordpress/patterns": "^2.42.0",
96
- "@wordpress/plugins": "^7.42.0",
97
- "@wordpress/preferences": "^4.42.0",
98
- "@wordpress/private-apis": "^1.42.0",
99
- "@wordpress/reusable-blocks": "^5.42.0",
100
- "@wordpress/rich-text": "^7.42.0",
101
- "@wordpress/server-side-render": "^6.18.0",
102
- "@wordpress/upload-media": "^0.27.0",
103
- "@wordpress/url": "^4.42.0",
104
- "@wordpress/warning": "^3.42.0",
105
- "@wordpress/wordcount": "^4.42.0",
64
+ "@wordpress/a11y": "^4.43.0",
65
+ "@wordpress/api-fetch": "^7.43.0",
66
+ "@wordpress/base-styles": "^6.19.0",
67
+ "@wordpress/blob": "^4.43.0",
68
+ "@wordpress/block-editor": "^15.16.0",
69
+ "@wordpress/block-serialization-default-parser": "^5.43.0",
70
+ "@wordpress/blocks": "^15.16.0",
71
+ "@wordpress/commands": "^1.43.0",
72
+ "@wordpress/components": "^32.5.0",
73
+ "@wordpress/compose": "^7.43.0",
74
+ "@wordpress/core-data": "^7.43.0",
75
+ "@wordpress/data": "^10.43.0",
76
+ "@wordpress/dataviews": "^14.0.0",
77
+ "@wordpress/date": "^5.43.0",
78
+ "@wordpress/deprecated": "^4.43.0",
79
+ "@wordpress/dom": "^4.43.0",
80
+ "@wordpress/element": "^6.43.0",
81
+ "@wordpress/fields": "^0.35.0",
82
+ "@wordpress/global-styles-engine": "^1.10.0",
83
+ "@wordpress/global-styles-ui": "^1.10.0",
84
+ "@wordpress/hooks": "^4.43.0",
85
+ "@wordpress/html-entities": "^4.43.0",
86
+ "@wordpress/i18n": "^6.16.0",
87
+ "@wordpress/icons": "^12.1.0",
88
+ "@wordpress/interface": "^9.28.0",
89
+ "@wordpress/keyboard-shortcuts": "^5.43.0",
90
+ "@wordpress/keycodes": "^4.43.0",
91
+ "@wordpress/media-editor": "^0.6.0",
92
+ "@wordpress/media-fields": "^0.8.0",
93
+ "@wordpress/media-utils": "^5.43.0",
94
+ "@wordpress/notices": "^5.43.0",
95
+ "@wordpress/patterns": "^2.43.0",
96
+ "@wordpress/plugins": "^7.43.0",
97
+ "@wordpress/preferences": "^4.43.0",
98
+ "@wordpress/private-apis": "^1.43.0",
99
+ "@wordpress/reusable-blocks": "^5.43.0",
100
+ "@wordpress/rich-text": "^7.43.0",
101
+ "@wordpress/server-side-render": "^6.19.0",
102
+ "@wordpress/upload-media": "^0.28.0",
103
+ "@wordpress/url": "^4.43.0",
104
+ "@wordpress/views": "^1.10.0",
105
+ "@wordpress/warning": "^3.43.0",
106
+ "@wordpress/wordcount": "^4.43.0",
106
107
  "change-case": "^4.1.2",
107
108
  "client-zip": "^2.4.5",
108
109
  "clsx": "^2.1.1",
@@ -125,5 +126,5 @@
125
126
  "publishConfig": {
126
127
  "access": "public"
127
128
  },
128
- "gitHead": "c20787b1778ae64c2db65643b1c236309d68e6ba"
129
+ "gitHead": "2cea90674d11aa521ec3f71652fb3a6a4c383969"
129
130
  }
@@ -0,0 +1,96 @@
1
+ interface ScrollToCursorOptions {
2
+ behavior?: ScrollBehavior;
3
+ block?: ScrollLogicalPosition;
4
+ inline?: ScrollLogicalPosition;
5
+ highlightDuration?: number;
6
+ }
7
+
8
+ /**
9
+ * Cursor Registry
10
+ * ===
11
+ * This registry stores references to cursor elements so that we can access them
12
+ * in different parts of the component tree. This would more ideally be solved
13
+ * with React context or state in the awareness store, but:
14
+ *
15
+ * 1. EditorPresence and BlockCanvasCover slot/fill break context propagation. We
16
+ * don't currently have a way to provide context to both the slot and fill.
17
+ * 2. Storing pointers to the cursor elements in the awareness store might be a
18
+ * better solution, but would require broader refactoring.
19
+ *
20
+ * For now, we create a single instance of this registry and pass it down to the
21
+ * components that need it. It's important that we create a single instance and
22
+ * not a new instance per component or render; use useState with a lazy
23
+ * initializer to accomplish this.
24
+ */
25
+
26
+ function highlightCursor( element: HTMLElement, duration: number ): void {
27
+ element.classList.add( 'collaborators-overlay-cursor-highlighted' );
28
+
29
+ setTimeout( () => {
30
+ element.classList.remove( 'collaborators-overlay-cursor-highlighted' );
31
+ }, duration );
32
+ }
33
+
34
+ export function createCursorRegistry() {
35
+ const cursorMap = new Map< number, HTMLElement >();
36
+
37
+ return {
38
+ /**
39
+ * Register a cursor element when it's created.
40
+ *
41
+ * @param clientId - The clientId of the cursor to register.
42
+ * @param element - The cursor element to register.
43
+ */
44
+ registerCursor( clientId: number, element: HTMLElement ): void {
45
+ cursorMap.set( clientId, element );
46
+ },
47
+
48
+ /**
49
+ * Unregister a cursor element when it's removed.
50
+ *
51
+ * @param clientId - The clientId of the cursor to unregister.
52
+ */
53
+ unregisterCursor( clientId: number ): void {
54
+ cursorMap.delete( clientId );
55
+ },
56
+
57
+ /**
58
+ * Scroll to a cursor by clientId.
59
+ *
60
+ * @param clientId - The clientId of the cursor to scroll to.
61
+ * @param options - The options for the scroll.
62
+ * @return true if cursor was found and scrolled to, false otherwise.
63
+ */
64
+ scrollToCursor(
65
+ clientId: number,
66
+ options?: ScrollToCursorOptions
67
+ ): boolean {
68
+ const cursorElement = cursorMap.get( clientId );
69
+
70
+ if ( ! cursorElement ) {
71
+ return false;
72
+ }
73
+
74
+ cursorElement.scrollIntoView( {
75
+ behavior: options?.behavior ?? 'smooth',
76
+ block: options?.block ?? 'center',
77
+ inline: options?.inline ?? 'nearest',
78
+ } );
79
+
80
+ if ( options?.highlightDuration ) {
81
+ highlightCursor( cursorElement, options.highlightDuration );
82
+ }
83
+
84
+ return true;
85
+ },
86
+
87
+ /**
88
+ * Clear the registry.
89
+ */
90
+ removeAll(): void {
91
+ cursorMap.clear();
92
+ },
93
+ };
94
+ }
95
+
96
+ export type CursorRegistry = ReturnType< typeof createCursorRegistry >;
@@ -9,22 +9,29 @@ import { privateApis } from '@wordpress/block-editor';
9
9
  */
10
10
  import { unlock } from '../../lock-unlock';
11
11
  import { Overlay } from './overlay';
12
+ import { type CursorRegistry } from './cursor-registry';
12
13
 
13
14
  const { BlockCanvasCover } = unlock( privateApis );
14
15
 
15
16
  interface Props {
16
17
  postId: number | null;
17
18
  postType: string | null;
19
+ cursorRegistry?: CursorRegistry;
18
20
  }
19
21
 
20
22
  /**
21
23
  * Collaborators Overlay component
22
- * @param props - The props for the CollaboratorsOverlay component
23
- * @param props.postId - The ID of the post
24
- * @param props.postType - The type of the post
24
+ * @param props - The props for the CollaboratorsOverlay component
25
+ * @param props.postId - The ID of the post
26
+ * @param props.postType - The type of the post
27
+ * @param props.cursorRegistry - The shared cursor registry
25
28
  * @return The CollaboratorsOverlay component
26
29
  */
27
- export function CollaboratorsOverlay( { postId, postType }: Props ) {
30
+ export function CollaboratorsOverlay( {
31
+ postId,
32
+ postType,
33
+ cursorRegistry,
34
+ }: Props ) {
28
35
  return (
29
36
  <BlockCanvasCover.Fill>
30
37
  { ( {
@@ -36,6 +43,7 @@ export function CollaboratorsOverlay( { postId, postType }: Props ) {
36
43
  blockEditorDocument={ containerRef.current?.ownerDocument }
37
44
  postId={ postId }
38
45
  postType={ postType }
46
+ cursorRegistry={ cursorRegistry }
39
47
  />
40
48
  ) }
41
49
  </BlockCanvasCover.Fill>
@@ -119,7 +119,7 @@ export const OVERLAY_IFRAME_STYLES = `
119
119
  outline-style: solid;
120
120
  outline-width: calc(var(--wp-admin-border-width-focus) / var(--wp-block-editor-iframe-zoom-out-scale, 1));
121
121
  outline-offset: calc(-1 * var(--wp-admin-border-width-focus) / var(--wp-block-editor-iframe-zoom-out-scale, 1));
122
- box-shadow: inset 0 0 0 calc(var(--wp-admin-border-width-focus, ${ BORDER_WIDTH_FOCUS_FALLBACK }) + ${ BORDER_WIDTH }) ${ WHITE }, 0 0 0 ${ BORDER_WIDTH } ${ WHITE }, ${ ELEVATION_X_SMALL };
122
+ box-shadow: inset 0 0 0 calc((var(--wp-admin-border-width-focus) / var(--wp-block-editor-iframe-zoom-out-scale, 1)) + 0.5px) rgba(${ WHITE }, 0.7);
123
123
  z-index: 1;
124
124
  }
125
125
  @media (prefers-reduced-motion: reduce) {