@wordpress/editor 14.35.2-next.dc3f6d3c1.0 → 14.36.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 (103) hide show
  1. package/CHANGELOG.md +1 -1
  2. package/build/bindings/post-data.js +15 -15
  3. package/build/bindings/post-data.js.map +2 -2
  4. package/build/bindings/term-data.js +97 -95
  5. package/build/bindings/term-data.js.map +2 -2
  6. package/build/components/collab-sidebar/comments.js +12 -4
  7. package/build/components/collab-sidebar/comments.js.map +2 -2
  8. package/build/components/collab-sidebar/hooks.js +9 -1
  9. package/build/components/collab-sidebar/hooks.js.map +2 -2
  10. package/build/components/global-styles/index.js +1 -1
  11. package/build/components/global-styles/index.js.map +1 -1
  12. package/build/components/post-schedule/panel.js +1 -7
  13. package/build/components/post-schedule/panel.js.map +2 -2
  14. package/build/components/post-status/index.js +1 -7
  15. package/build/components/post-status/index.js.map +2 -2
  16. package/build/components/post-template/block-theme.js +1 -1
  17. package/build/components/post-template/block-theme.js.map +2 -2
  18. package/build/components/post-template/hooks.js +1 -1
  19. package/build/components/post-template/hooks.js.map +2 -2
  20. package/build/components/provider/index.js +3 -1
  21. package/build/components/provider/index.js.map +2 -2
  22. package/build/components/visual-editor/index.js +1 -7
  23. package/build/components/visual-editor/index.js.map +2 -2
  24. package/build/components/visual-editor/use-edit-content-only-section-exit.js +5 -6
  25. package/build/components/visual-editor/use-edit-content-only-section-exit.js.map +2 -2
  26. package/build/dataviews/store/private-actions.js +5 -1
  27. package/build/dataviews/store/private-actions.js.map +2 -2
  28. package/build/hooks/template-part-navigation-edit-button.js +8 -11
  29. package/build/hooks/template-part-navigation-edit-button.js.map +3 -3
  30. package/build/store/actions.js +1 -1
  31. package/build/store/actions.js.map +2 -2
  32. package/build/store/constants.js +8 -0
  33. package/build/store/constants.js.map +2 -2
  34. package/build-module/bindings/post-data.js +15 -15
  35. package/build-module/bindings/post-data.js.map +2 -2
  36. package/build-module/bindings/term-data.js +93 -95
  37. package/build-module/bindings/term-data.js.map +2 -2
  38. package/build-module/components/collab-sidebar/comments.js +12 -4
  39. package/build-module/components/collab-sidebar/comments.js.map +2 -2
  40. package/build-module/components/collab-sidebar/hooks.js +9 -1
  41. package/build-module/components/collab-sidebar/hooks.js.map +2 -2
  42. package/build-module/components/global-styles/index.js +1 -1
  43. package/build-module/components/global-styles/index.js.map +1 -1
  44. package/build-module/components/post-schedule/panel.js +1 -12
  45. package/build-module/components/post-schedule/panel.js.map +2 -2
  46. package/build-module/components/post-status/index.js +1 -12
  47. package/build-module/components/post-status/index.js.map +2 -2
  48. package/build-module/components/post-template/block-theme.js +1 -1
  49. package/build-module/components/post-template/block-theme.js.map +2 -2
  50. package/build-module/components/post-template/hooks.js +1 -1
  51. package/build-module/components/post-template/hooks.js.map +2 -2
  52. package/build-module/components/provider/index.js +3 -1
  53. package/build-module/components/provider/index.js.map +2 -2
  54. package/build-module/components/visual-editor/index.js +2 -7
  55. package/build-module/components/visual-editor/index.js.map +2 -2
  56. package/build-module/components/visual-editor/use-edit-content-only-section-exit.js +5 -6
  57. package/build-module/components/visual-editor/use-edit-content-only-section-exit.js.map +2 -2
  58. package/build-module/dataviews/store/private-actions.js +5 -1
  59. package/build-module/dataviews/store/private-actions.js.map +2 -2
  60. package/build-module/hooks/template-part-navigation-edit-button.js +10 -17
  61. package/build-module/hooks/template-part-navigation-edit-button.js.map +2 -2
  62. package/build-module/store/actions.js +1 -1
  63. package/build-module/store/actions.js.map +2 -2
  64. package/build-module/store/constants.js +7 -0
  65. package/build-module/store/constants.js.map +2 -2
  66. package/build-style/style-rtl.css +263 -27
  67. package/build-style/style.css +263 -27
  68. package/build-types/bindings/post-data.d.ts +2 -1
  69. package/build-types/bindings/term-data.d.ts +86 -8
  70. package/build-types/bindings/term-data.d.ts.map +1 -1
  71. package/build-types/components/collab-sidebar/comments.d.ts.map +1 -1
  72. package/build-types/components/collab-sidebar/hooks.d.ts.map +1 -1
  73. package/build-types/components/post-schedule/panel.d.ts.map +1 -1
  74. package/build-types/components/post-status/index.d.ts.map +1 -1
  75. package/build-types/components/post-template/block-theme.d.ts.map +1 -1
  76. package/build-types/components/provider/index.d.ts.map +1 -1
  77. package/build-types/components/visual-editor/index.d.ts.map +1 -1
  78. package/build-types/components/visual-editor/use-edit-content-only-section-exit.d.ts.map +1 -1
  79. package/build-types/dataviews/store/private-actions.d.ts +5 -0
  80. package/build-types/dataviews/store/private-actions.d.ts.map +1 -1
  81. package/build-types/store/actions.d.ts.map +1 -1
  82. package/build-types/store/constants.d.ts +1 -0
  83. package/build-types/store/constants.d.ts.map +1 -1
  84. package/package.json +40 -40
  85. package/src/bindings/post-data.js +21 -20
  86. package/src/bindings/term-data.js +124 -151
  87. package/src/bindings/test/post-data.js +31 -20
  88. package/src/bindings/test/term-data.js +406 -0
  89. package/src/components/collab-sidebar/comments.js +24 -16
  90. package/src/components/collab-sidebar/hooks.js +12 -1
  91. package/src/components/global-styles/index.js +1 -1
  92. package/src/components/post-schedule/panel.js +1 -13
  93. package/src/components/post-status/index.js +1 -13
  94. package/src/components/post-template/block-theme.js +4 -1
  95. package/src/components/post-template/hooks.js +1 -1
  96. package/src/components/provider/index.js +7 -2
  97. package/src/components/visual-editor/index.js +1 -6
  98. package/src/components/visual-editor/use-edit-content-only-section-exit.js +9 -10
  99. package/src/dataviews/store/private-actions.ts +17 -1
  100. package/src/hooks/template-part-navigation-edit-button.js +4 -15
  101. package/src/store/actions.js +2 -0
  102. package/src/store/constants.ts +6 -0
  103. package/tsconfig.tsbuildinfo +1 -1
@@ -6,14 +6,10 @@ import { createHigherOrderComponent } from '@wordpress/compose';
6
6
  import { useCallback } from '@wordpress/element';
7
7
  import { __ } from '@wordpress/i18n';
8
8
  import {
9
- BlockControls,
9
+ __unstableBlockToolbarLastItem as BlockToolbarLastItem,
10
10
  store as blockEditorStore,
11
11
  } from '@wordpress/block-editor';
12
- import {
13
- ToolbarButton,
14
- ToolbarGroup,
15
- __experimentalDivider as Divider,
16
- } from '@wordpress/components';
12
+ import { ToolbarButton, ToolbarGroup } from '@wordpress/components';
17
13
  import { useSelect, useDispatch } from '@wordpress/data';
18
14
  import { store as interfaceStore } from '@wordpress/interface';
19
15
 
@@ -96,15 +92,8 @@ function TemplatePartNavigationEditButton( { clientId } ) {
96
92
  }
97
93
 
98
94
  return (
99
- <BlockControls group="other">
95
+ <BlockToolbarLastItem>
100
96
  <ToolbarGroup>
101
- { /*
102
- * Add a vertical divider to visually separate the "Edit navigation"
103
- * button from the template part's "Edit" button. Both buttons share
104
- * the same toolbar group ("other"), so without this divider they
105
- * would appear directly adjacent with no visual separation.
106
- */ }
107
- <Divider orientation="vertical" marginEnd={ 3 } />
108
97
  <ToolbarButton
109
98
  label={ __( 'Edit navigation' ) }
110
99
  onClick={ onEditNavigation }
@@ -112,7 +101,7 @@ function TemplatePartNavigationEditButton( { clientId } ) {
112
101
  { __( 'Edit navigation' ) }
113
102
  </ToolbarButton>
114
103
  </ToolbarGroup>
115
- </BlockControls>
104
+ </BlockToolbarLastItem>
116
105
  );
117
106
  }
118
107
 
@@ -274,6 +274,8 @@ export const savePost =
274
274
  dispatch( { type: 'REQUEST_POST_UPDATE_FINISH', options } );
275
275
 
276
276
  if (
277
+ typeof window !== 'undefined' &&
278
+ window.__experimentalTemplateActivate &&
277
279
  ! options.isAutosave &&
278
280
  previousRecord.type === 'wp_template' &&
279
281
  ( typeof previousRecord.id === 'number' ||
@@ -30,3 +30,9 @@ export const GLOBAL_POST_TYPES = [
30
30
  'wp_block',
31
31
  'wp_navigation',
32
32
  ];
33
+ export const DESIGN_POST_TYPES = [
34
+ TEMPLATE_POST_TYPE,
35
+ TEMPLATE_PART_POST_TYPE,
36
+ PATTERN_POST_TYPE,
37
+ NAVIGATION_POST_TYPE,
38
+ ];