@wordpress/block-editor 11.3.3 → 11.4.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 (192) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/build/components/block-popover/inbetween.js +10 -33
  3. package/build/components/block-popover/inbetween.js.map +1 -1
  4. package/build/components/block-types-list/index.native.js +2 -0
  5. package/build/components/block-types-list/index.native.js.map +1 -1
  6. package/build/components/colors-gradients/control.js +6 -3
  7. package/build/components/colors-gradients/control.js.map +1 -1
  8. package/build/components/font-appearance-control/index.js +0 -3
  9. package/build/components/font-appearance-control/index.js.map +1 -1
  10. package/build/components/global-styles/hooks.js +106 -45
  11. package/build/components/global-styles/hooks.js.map +1 -1
  12. package/build/components/global-styles/index.js +24 -0
  13. package/build/components/global-styles/index.js.map +1 -1
  14. package/build/components/global-styles/typography-panel.js +421 -0
  15. package/build/components/global-styles/typography-panel.js.map +1 -0
  16. package/build/components/global-styles/use-global-styles-output.js +6 -2
  17. package/build/components/global-styles/use-global-styles-output.js.map +1 -1
  18. package/build/components/iframe/index.js +17 -11
  19. package/build/components/iframe/index.js.map +1 -1
  20. package/build/components/image-editor/aspect-ratio-dropdown.js +2 -1
  21. package/build/components/image-editor/aspect-ratio-dropdown.js.map +1 -1
  22. package/build/components/image-size-control/index.js +6 -11
  23. package/build/components/image-size-control/index.js.map +1 -1
  24. package/build/components/inserter/block-patterns-tab.js +9 -15
  25. package/build/components/inserter/block-patterns-tab.js.map +1 -1
  26. package/build/components/inserter/block-types-tab.native.js +4 -1
  27. package/build/components/inserter/block-types-tab.native.js.map +1 -1
  28. package/build/components/inserter/reusable-blocks-tab.native.js +4 -1
  29. package/build/components/inserter/reusable-blocks-tab.native.js.map +1 -1
  30. package/build/components/inserter/search-results.native.js +4 -1
  31. package/build/components/inserter/search-results.native.js.map +1 -1
  32. package/build/components/link-control/index.js +15 -15
  33. package/build/components/link-control/index.js.map +1 -1
  34. package/build/components/link-control/settings-drawer.js +72 -30
  35. package/build/components/link-control/settings-drawer.js.map +1 -1
  36. package/build/components/link-control/settings.js +52 -0
  37. package/build/components/link-control/settings.js.map +1 -0
  38. package/build/components/list-view/index.js +6 -1
  39. package/build/components/list-view/index.js.map +1 -1
  40. package/build/components/off-canvas-editor/block-contents.js +3 -2
  41. package/build/components/off-canvas-editor/block-contents.js.map +1 -1
  42. package/build/components/off-canvas-editor/leaf-more-menu.js +116 -0
  43. package/build/components/off-canvas-editor/leaf-more-menu.js.map +1 -0
  44. package/build/components/off-canvas-editor/link-ui.js +1 -0
  45. package/build/components/off-canvas-editor/link-ui.js.map +1 -1
  46. package/build/components/rich-text/index.js +0 -2
  47. package/build/components/rich-text/index.js.map +1 -1
  48. package/build/components/url-input/index.js +2 -2
  49. package/build/components/url-input/index.js.map +1 -1
  50. package/build/hooks/dimensions.js +6 -0
  51. package/build/hooks/dimensions.js.map +1 -1
  52. package/build/hooks/font-family.js +2 -76
  53. package/build/hooks/font-family.js.map +1 -1
  54. package/build/hooks/font-size.js +3 -51
  55. package/build/hooks/font-size.js.map +1 -1
  56. package/build/hooks/gap.js +2 -1
  57. package/build/hooks/gap.js.map +1 -1
  58. package/build/hooks/index.js +2 -0
  59. package/build/hooks/index.js.map +1 -1
  60. package/build/hooks/line-height.js +0 -42
  61. package/build/hooks/line-height.js.map +1 -1
  62. package/build/hooks/typography.js +112 -127
  63. package/build/hooks/typography.js.map +1 -1
  64. package/build/private-apis.js +3 -0
  65. package/build/private-apis.js.map +1 -1
  66. package/build/store/selectors.js +18 -1
  67. package/build/store/selectors.js.map +1 -1
  68. package/build-module/components/block-popover/inbetween.js +10 -33
  69. package/build-module/components/block-popover/inbetween.js.map +1 -1
  70. package/build-module/components/block-types-list/index.native.js +2 -0
  71. package/build-module/components/block-types-list/index.native.js.map +1 -1
  72. package/build-module/components/colors-gradients/control.js +6 -3
  73. package/build-module/components/colors-gradients/control.js.map +1 -1
  74. package/build-module/components/font-appearance-control/index.js +2 -1
  75. package/build-module/components/font-appearance-control/index.js.map +1 -1
  76. package/build-module/components/global-styles/hooks.js +100 -46
  77. package/build-module/components/global-styles/hooks.js.map +1 -1
  78. package/build-module/components/global-styles/index.js +2 -1
  79. package/build-module/components/global-styles/index.js.map +1 -1
  80. package/build-module/components/global-styles/typography-panel.js +400 -0
  81. package/build-module/components/global-styles/typography-panel.js.map +1 -0
  82. package/build-module/components/global-styles/use-global-styles-output.js +6 -2
  83. package/build-module/components/global-styles/use-global-styles-output.js.map +1 -1
  84. package/build-module/components/iframe/index.js +17 -11
  85. package/build-module/components/iframe/index.js.map +1 -1
  86. package/build-module/components/image-editor/aspect-ratio-dropdown.js +2 -1
  87. package/build-module/components/image-editor/aspect-ratio-dropdown.js.map +1 -1
  88. package/build-module/components/image-size-control/index.js +7 -12
  89. package/build-module/components/image-size-control/index.js.map +1 -1
  90. package/build-module/components/inserter/block-patterns-tab.js +9 -15
  91. package/build-module/components/inserter/block-patterns-tab.js.map +1 -1
  92. package/build-module/components/inserter/block-types-tab.native.js +3 -1
  93. package/build-module/components/inserter/block-types-tab.native.js.map +1 -1
  94. package/build-module/components/inserter/reusable-blocks-tab.native.js +3 -1
  95. package/build-module/components/inserter/reusable-blocks-tab.native.js.map +1 -1
  96. package/build-module/components/inserter/search-results.native.js +3 -1
  97. package/build-module/components/inserter/search-results.native.js.map +1 -1
  98. package/build-module/components/link-control/index.js +16 -16
  99. package/build-module/components/link-control/index.js.map +1 -1
  100. package/build-module/components/link-control/settings-drawer.js +68 -30
  101. package/build-module/components/link-control/settings-drawer.js.map +1 -1
  102. package/build-module/components/link-control/settings.js +43 -0
  103. package/build-module/components/link-control/settings.js.map +1 -0
  104. package/build-module/components/list-view/index.js +6 -1
  105. package/build-module/components/list-view/index.js.map +1 -1
  106. package/build-module/components/off-canvas-editor/block-contents.js +3 -2
  107. package/build-module/components/off-canvas-editor/block-contents.js.map +1 -1
  108. package/build-module/components/off-canvas-editor/leaf-more-menu.js +99 -0
  109. package/build-module/components/off-canvas-editor/leaf-more-menu.js.map +1 -0
  110. package/build-module/components/off-canvas-editor/link-ui.js +1 -0
  111. package/build-module/components/off-canvas-editor/link-ui.js.map +1 -1
  112. package/build-module/components/rich-text/index.js +0 -2
  113. package/build-module/components/rich-text/index.js.map +1 -1
  114. package/build-module/components/url-input/index.js +2 -2
  115. package/build-module/components/url-input/index.js.map +1 -1
  116. package/build-module/hooks/dimensions.js +6 -0
  117. package/build-module/hooks/dimensions.js.map +1 -1
  118. package/build-module/hooks/font-family.js +3 -69
  119. package/build-module/hooks/font-family.js.map +1 -1
  120. package/build-module/hooks/font-size.js +6 -47
  121. package/build-module/hooks/font-size.js.map +1 -1
  122. package/build-module/hooks/gap.js +3 -2
  123. package/build-module/hooks/gap.js.map +1 -1
  124. package/build-module/hooks/index.js +1 -0
  125. package/build-module/hooks/index.js.map +1 -1
  126. package/build-module/hooks/line-height.js +0 -38
  127. package/build-module/hooks/line-height.js.map +1 -1
  128. package/build-module/hooks/typography.js +110 -123
  129. package/build-module/hooks/typography.js.map +1 -1
  130. package/build-module/private-apis.js +2 -0
  131. package/build-module/private-apis.js.map +1 -1
  132. package/build-module/store/selectors.js +18 -1
  133. package/build-module/store/selectors.js.map +1 -1
  134. package/build-style/style-rtl.css +35 -22
  135. package/build-style/style.css +35 -22
  136. package/package.json +31 -31
  137. package/src/components/block-popover/inbetween.js +21 -53
  138. package/src/components/block-types-list/index.native.js +2 -0
  139. package/src/components/colors-gradients/control.js +3 -0
  140. package/src/components/font-appearance-control/index.js +1 -1
  141. package/src/components/global-styles/hooks.js +186 -66
  142. package/src/components/global-styles/index.js +5 -0
  143. package/src/components/global-styles/typography-panel.js +403 -0
  144. package/src/components/global-styles/use-global-styles-output.js +6 -2
  145. package/src/components/iframe/index.js +20 -18
  146. package/src/components/image-editor/aspect-ratio-dropdown.js +1 -0
  147. package/src/components/image-size-control/index.js +10 -12
  148. package/src/components/image-size-control/style.scss +3 -21
  149. package/src/components/inserter/block-patterns-tab.js +9 -23
  150. package/src/components/inserter/block-types-tab.native.js +2 -0
  151. package/src/components/inserter/reusable-blocks-tab.native.js +2 -0
  152. package/src/components/inserter/search-results.native.js +2 -0
  153. package/src/components/link-control/index.js +22 -22
  154. package/src/components/link-control/settings-drawer.js +85 -30
  155. package/src/components/link-control/settings.js +41 -0
  156. package/src/components/link-control/style.scss +39 -7
  157. package/src/components/link-control/test/index.js +213 -4
  158. package/src/components/list-view/index.js +5 -0
  159. package/src/components/off-canvas-editor/block-contents.js +2 -1
  160. package/src/components/off-canvas-editor/leaf-more-menu.js +115 -0
  161. package/src/components/off-canvas-editor/link-ui.js +1 -0
  162. package/src/components/rich-text/index.js +0 -2
  163. package/src/components/url-input/index.js +3 -2
  164. package/src/hooks/dimensions.js +12 -0
  165. package/src/hooks/font-family.js +0 -58
  166. package/src/hooks/font-size.js +1 -36
  167. package/src/hooks/gap.js +9 -2
  168. package/src/hooks/index.js +1 -0
  169. package/src/hooks/line-height.js +0 -33
  170. package/src/hooks/typography.js +133 -212
  171. package/src/private-apis.js +2 -0
  172. package/src/store/selectors.js +16 -1
  173. package/build/hooks/font-appearance.js +0 -188
  174. package/build/hooks/font-appearance.js.map +0 -1
  175. package/build/hooks/letter-spacing.js +0 -129
  176. package/build/hooks/letter-spacing.js.map +0 -1
  177. package/build/hooks/text-decoration.js +0 -130
  178. package/build/hooks/text-decoration.js.map +0 -1
  179. package/build/hooks/text-transform.js +0 -130
  180. package/build/hooks/text-transform.js.map +0 -1
  181. package/build-module/hooks/font-appearance.js +0 -161
  182. package/build-module/hooks/font-appearance.js.map +0 -1
  183. package/build-module/hooks/letter-spacing.js +0 -107
  184. package/build-module/hooks/letter-spacing.js.map +0 -1
  185. package/build-module/hooks/text-decoration.js +0 -108
  186. package/build-module/hooks/text-decoration.js.map +0 -1
  187. package/build-module/hooks/text-transform.js +0 -108
  188. package/build-module/hooks/text-transform.js.map +0 -1
  189. package/src/hooks/font-appearance.js +0 -146
  190. package/src/hooks/letter-spacing.js +0 -101
  191. package/src/hooks/text-decoration.js +0 -102
  192. package/src/hooks/text-transform.js +0 -101
@@ -1455,23 +1455,9 @@
1455
1455
  .block-editor-image-size-control {
1456
1456
  margin-bottom: 1em;
1457
1457
  }
1458
- .block-editor-image-size-control .block-editor-image-size-control__row {
1459
- display: flex;
1460
- justify-content: space-between;
1461
- }
1462
- .block-editor-image-size-control .block-editor-image-size-control__row .block-editor-image-size-control__width,
1463
- .block-editor-image-size-control .block-editor-image-size-control__row .block-editor-image-size-control__height {
1464
- margin-bottom: 0.5em;
1465
- }
1466
- .block-editor-image-size-control .block-editor-image-size-control__row .block-editor-image-size-control__width input,
1467
- .block-editor-image-size-control .block-editor-image-size-control__row .block-editor-image-size-control__height input {
1468
- line-height: 1.25;
1469
- }
1470
- .block-editor-image-size-control .block-editor-image-size-control__row .block-editor-image-size-control__width {
1471
- margin-left: 5px;
1472
- }
1473
- .block-editor-image-size-control .block-editor-image-size-control__row .block-editor-image-size-control__height {
1474
- margin-right: 5px;
1458
+ .block-editor-image-size-control .block-editor-image-size-control__width,
1459
+ .block-editor-image-size-control .block-editor-image-size-control__height {
1460
+ margin-bottom: 1.115em;
1475
1461
  }
1476
1462
 
1477
1463
  .block-editor-block-types-list__list-item {
@@ -1742,6 +1728,7 @@
1742
1728
  flex-direction: row-reverse;
1743
1729
  justify-content: flex-start;
1744
1730
  gap: 8px;
1731
+ order: 20;
1745
1732
  }
1746
1733
 
1747
1734
  .components-button .block-editor-link-control__search-submit .has-icon {
@@ -2028,11 +2015,40 @@
2028
2015
 
2029
2016
  .block-editor-link-control__drawer {
2030
2017
  display: flex;
2018
+ order: 30;
2019
+ flex-direction: column;
2020
+ flex-basis: 100%;
2021
+ }
2022
+
2023
+ .block-editor-link-control__drawer-inner {
2024
+ display: flex;
2025
+ flex-direction: column;
2026
+ flex-basis: 100%;
2027
+ margin-top: 16px;
2028
+ padding-top: 16px;
2029
+ position: relative;
2030
+ }
2031
+ .block-editor-link-control__drawer-inner::after {
2032
+ content: "";
2033
+ display: block;
2034
+ height: 1px;
2035
+ background-color: #ddd;
2036
+ position: absolute;
2037
+ right: -16px;
2038
+ left: -16px;
2039
+ top: 0;
2040
+ }
2041
+
2042
+ .block-editor-link-control__tools {
2043
+ display: flex;
2044
+ flex-wrap: wrap;
2031
2045
  align-items: center;
2032
2046
  justify-content: space-between;
2033
- border-top: 1px solid #ddd;
2034
2047
  margin: 0;
2035
2048
  padding: 16px;
2049
+ margin-top: calc(var(--wp-admin-border-width-focus) * -1);
2050
+ padding-top: var(--wp-admin-border-width-focus);
2051
+ overflow: hidden;
2036
2052
  }
2037
2053
 
2038
2054
  .block-editor-link-control__unlink {
@@ -2044,9 +2060,6 @@
2044
2060
  flex: 1;
2045
2061
  margin: 0;
2046
2062
  }
2047
- .block-editor-link-control__settings :last-child {
2048
- margin-bottom: 0;
2049
- }
2050
2063
  .is-alternate .block-editor-link-control__settings {
2051
2064
  border-top: 1px solid #1e1e1e;
2052
2065
  }
@@ -2054,7 +2067,7 @@
2054
2067
  .block-editor-link-control__setting {
2055
2068
  margin-bottom: 16px;
2056
2069
  }
2057
- .block-editor-link-control__setting :last-child {
2070
+ .block-editor-link-control__setting.block-editor-link-control__setting:last-child {
2058
2071
  margin-bottom: 0;
2059
2072
  }
2060
2073
 
@@ -1455,23 +1455,9 @@
1455
1455
  .block-editor-image-size-control {
1456
1456
  margin-bottom: 1em;
1457
1457
  }
1458
- .block-editor-image-size-control .block-editor-image-size-control__row {
1459
- display: flex;
1460
- justify-content: space-between;
1461
- }
1462
- .block-editor-image-size-control .block-editor-image-size-control__row .block-editor-image-size-control__width,
1463
- .block-editor-image-size-control .block-editor-image-size-control__row .block-editor-image-size-control__height {
1464
- margin-bottom: 0.5em;
1465
- }
1466
- .block-editor-image-size-control .block-editor-image-size-control__row .block-editor-image-size-control__width input,
1467
- .block-editor-image-size-control .block-editor-image-size-control__row .block-editor-image-size-control__height input {
1468
- line-height: 1.25;
1469
- }
1470
- .block-editor-image-size-control .block-editor-image-size-control__row .block-editor-image-size-control__width {
1471
- margin-right: 5px;
1472
- }
1473
- .block-editor-image-size-control .block-editor-image-size-control__row .block-editor-image-size-control__height {
1474
- margin-left: 5px;
1458
+ .block-editor-image-size-control .block-editor-image-size-control__width,
1459
+ .block-editor-image-size-control .block-editor-image-size-control__height {
1460
+ margin-bottom: 1.115em;
1475
1461
  }
1476
1462
 
1477
1463
  .block-editor-block-types-list__list-item {
@@ -1742,6 +1728,7 @@
1742
1728
  flex-direction: row-reverse;
1743
1729
  justify-content: flex-start;
1744
1730
  gap: 8px;
1731
+ order: 20;
1745
1732
  }
1746
1733
 
1747
1734
  .components-button .block-editor-link-control__search-submit .has-icon {
@@ -2028,11 +2015,40 @@
2028
2015
 
2029
2016
  .block-editor-link-control__drawer {
2030
2017
  display: flex;
2018
+ order: 30;
2019
+ flex-direction: column;
2020
+ flex-basis: 100%;
2021
+ }
2022
+
2023
+ .block-editor-link-control__drawer-inner {
2024
+ display: flex;
2025
+ flex-direction: column;
2026
+ flex-basis: 100%;
2027
+ margin-top: 16px;
2028
+ padding-top: 16px;
2029
+ position: relative;
2030
+ }
2031
+ .block-editor-link-control__drawer-inner::after {
2032
+ content: "";
2033
+ display: block;
2034
+ height: 1px;
2035
+ background-color: #ddd;
2036
+ position: absolute;
2037
+ left: -16px;
2038
+ right: -16px;
2039
+ top: 0;
2040
+ }
2041
+
2042
+ .block-editor-link-control__tools {
2043
+ display: flex;
2044
+ flex-wrap: wrap;
2031
2045
  align-items: center;
2032
2046
  justify-content: space-between;
2033
- border-top: 1px solid #ddd;
2034
2047
  margin: 0;
2035
2048
  padding: 16px;
2049
+ margin-top: calc(var(--wp-admin-border-width-focus) * -1);
2050
+ padding-top: var(--wp-admin-border-width-focus);
2051
+ overflow: hidden;
2036
2052
  }
2037
2053
 
2038
2054
  .block-editor-link-control__unlink {
@@ -2044,9 +2060,6 @@
2044
2060
  flex: 1;
2045
2061
  margin: 0;
2046
2062
  }
2047
- .block-editor-link-control__settings :last-child {
2048
- margin-bottom: 0;
2049
- }
2050
2063
  .is-alternate .block-editor-link-control__settings {
2051
2064
  border-top: 1px solid #1e1e1e;
2052
2065
  }
@@ -2054,7 +2067,7 @@
2054
2067
  .block-editor-link-control__setting {
2055
2068
  margin-bottom: 16px;
2056
2069
  }
2057
- .block-editor-link-control__setting :last-child {
2070
+ .block-editor-link-control__setting.block-editor-link-control__setting:last-child {
2058
2071
  margin-bottom: 0;
2059
2072
  }
2060
2073
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wordpress/block-editor",
3
- "version": "11.3.3",
3
+ "version": "11.4.0",
4
4
  "description": "Generic block editor.",
5
5
  "author": "The WordPress Contributors",
6
6
  "license": "GPL-2.0-or-later",
@@ -33,35 +33,35 @@
33
33
  "dependencies": {
34
34
  "@babel/runtime": "^7.16.0",
35
35
  "@react-spring/web": "^9.4.5",
36
- "@wordpress/a11y": "^3.26.1",
37
- "@wordpress/api-fetch": "^6.23.1",
38
- "@wordpress/blob": "^3.26.1",
39
- "@wordpress/blocks": "^12.3.2",
40
- "@wordpress/components": "^23.3.2",
41
- "@wordpress/compose": "^6.3.2",
42
- "@wordpress/data": "^8.3.2",
43
- "@wordpress/date": "^4.26.2",
44
- "@wordpress/deprecated": "^3.26.1",
45
- "@wordpress/dom": "^3.26.1",
46
- "@wordpress/element": "^5.3.1",
47
- "@wordpress/escape-html": "^2.26.1",
48
- "@wordpress/hooks": "^3.26.1",
49
- "@wordpress/html-entities": "^3.26.1",
50
- "@wordpress/i18n": "^4.26.1",
51
- "@wordpress/icons": "^9.17.1",
52
- "@wordpress/is-shallow-equal": "^4.26.1",
53
- "@wordpress/keyboard-shortcuts": "^4.3.2",
54
- "@wordpress/keycodes": "^3.26.2",
55
- "@wordpress/notices": "^3.26.2",
56
- "@wordpress/preferences": "^3.3.2",
57
- "@wordpress/private-apis": "^0.8.1",
58
- "@wordpress/rich-text": "^6.3.2",
59
- "@wordpress/shortcode": "^3.26.1",
60
- "@wordpress/style-engine": "^1.9.1",
61
- "@wordpress/token-list": "^2.26.1",
62
- "@wordpress/url": "^3.27.1",
63
- "@wordpress/warning": "^2.26.1",
64
- "@wordpress/wordcount": "^3.26.1",
36
+ "@wordpress/a11y": "^3.27.0",
37
+ "@wordpress/api-fetch": "^6.24.0",
38
+ "@wordpress/blob": "^3.27.0",
39
+ "@wordpress/blocks": "^12.4.0",
40
+ "@wordpress/components": "^23.4.0",
41
+ "@wordpress/compose": "^6.4.0",
42
+ "@wordpress/data": "^8.4.0",
43
+ "@wordpress/date": "^4.27.0",
44
+ "@wordpress/deprecated": "^3.27.0",
45
+ "@wordpress/dom": "^3.27.0",
46
+ "@wordpress/element": "^5.4.0",
47
+ "@wordpress/escape-html": "^2.27.0",
48
+ "@wordpress/hooks": "^3.27.0",
49
+ "@wordpress/html-entities": "^3.27.0",
50
+ "@wordpress/i18n": "^4.27.0",
51
+ "@wordpress/icons": "^9.18.0",
52
+ "@wordpress/is-shallow-equal": "^4.27.0",
53
+ "@wordpress/keyboard-shortcuts": "^4.4.0",
54
+ "@wordpress/keycodes": "^3.27.0",
55
+ "@wordpress/notices": "^3.27.0",
56
+ "@wordpress/preferences": "^3.4.0",
57
+ "@wordpress/private-apis": "^0.9.0",
58
+ "@wordpress/rich-text": "^6.4.0",
59
+ "@wordpress/shortcode": "^3.27.0",
60
+ "@wordpress/style-engine": "^1.10.0",
61
+ "@wordpress/token-list": "^2.27.0",
62
+ "@wordpress/url": "^3.28.0",
63
+ "@wordpress/warning": "^2.27.0",
64
+ "@wordpress/wordcount": "^3.27.0",
65
65
  "change-case": "^4.1.2",
66
66
  "classnames": "^2.3.1",
67
67
  "colord": "^2.7.0",
@@ -83,5 +83,5 @@
83
83
  "publishConfig": {
84
84
  "access": "public"
85
85
  },
86
- "gitHead": "1bf01c01a8238ce3a681ad1e517f86033818b78d"
86
+ "gitHead": "c25ff895413bad4354c55c0c2d732552618b0d56"
87
87
  }
@@ -68,53 +68,6 @@ function BlockPopoverInbetween( {
68
68
  const previousElement = useBlockElement( previousClientId );
69
69
  const nextElement = useBlockElement( nextClientId );
70
70
  const isVertical = orientation === 'vertical';
71
- const style = useMemo( () => {
72
- if (
73
- // popoverRecomputeCounter is by definition always equal or greater than 0.
74
- // This check is only there to satisfy the correctness of the
75
- // exhaustive-deps rule for the `useMemo` hook.
76
- popoverRecomputeCounter < 0 ||
77
- ( ! previousElement && ! nextElement ) ||
78
- ! isVisible
79
- ) {
80
- return {};
81
- }
82
-
83
- const previousRect = previousElement
84
- ? previousElement.getBoundingClientRect()
85
- : null;
86
- const nextRect = nextElement
87
- ? nextElement.getBoundingClientRect()
88
- : null;
89
-
90
- if ( isVertical ) {
91
- return {
92
- width: previousRect ? previousRect.width : nextRect.width,
93
- height:
94
- nextRect && previousRect
95
- ? nextRect.top - previousRect.bottom
96
- : 0,
97
- };
98
- }
99
-
100
- let width = 0;
101
- if ( previousRect && nextRect ) {
102
- width = isRTL()
103
- ? previousRect.left - nextRect.right
104
- : nextRect.left - previousRect.right;
105
- }
106
-
107
- return {
108
- width,
109
- height: previousRect ? previousRect.height : nextRect.height,
110
- };
111
- }, [
112
- previousElement,
113
- nextElement,
114
- isVertical,
115
- popoverRecomputeCounter,
116
- isVisible,
117
- ] );
118
71
 
119
72
  const popoverAnchor = useMemo( () => {
120
73
  if (
@@ -142,10 +95,17 @@ function BlockPopoverInbetween( {
142
95
 
143
96
  let left = 0;
144
97
  let top = 0;
98
+ let width = 0;
99
+ let height = 0;
145
100
 
146
101
  if ( isVertical ) {
147
102
  // vertical
148
103
  top = previousRect ? previousRect.bottom : nextRect.top;
104
+ width = previousRect ? previousRect.width : nextRect.width;
105
+ height =
106
+ nextRect && previousRect
107
+ ? nextRect.top - previousRect.bottom
108
+ : 0;
149
109
 
150
110
  if ( isRTL() ) {
151
111
  // vertical, rtl
@@ -158,21 +118,32 @@ function BlockPopoverInbetween( {
158
118
  }
159
119
  } else {
160
120
  top = previousRect ? previousRect.top : nextRect.top;
121
+ height = previousRect
122
+ ? previousRect.height
123
+ : nextRect.height;
161
124
 
162
125
  if ( isRTL() ) {
163
126
  // non vertical, rtl
164
127
  left = previousRect
165
128
  ? previousRect.left
166
129
  : nextRect.right;
130
+ width =
131
+ previousRect && nextRect
132
+ ? previousRect.left - nextRect.right
133
+ : 0;
167
134
  } else {
168
135
  // non vertical, ltr
169
136
  left = previousRect
170
137
  ? previousRect.right
171
138
  : nextRect.left;
139
+ width =
140
+ previousRect && nextRect
141
+ ? nextRect.left - previousRect.right
142
+ : 0;
172
143
  }
173
144
  }
174
145
 
175
- return new window.DOMRect( left, top, 0, 0 );
146
+ return new window.DOMRect( left, top, width, height );
176
147
  },
177
148
  };
178
149
  }, [
@@ -267,13 +238,10 @@ function BlockPopoverInbetween( {
267
238
  ) }
268
239
  resize={ false }
269
240
  flip={ false }
270
- placement="bottom-start"
241
+ placement="overlay"
271
242
  variant="unstyled"
272
243
  >
273
- <div
274
- className="block-editor-block-popover__inbetween-container"
275
- style={ style }
276
- >
244
+ <div className="block-editor-block-popover__inbetween-container">
277
245
  { children }
278
246
  </div>
279
247
  </Popover>
@@ -32,6 +32,7 @@ export default function BlockTypesList( {
32
32
  name,
33
33
  sections,
34
34
  onSelect,
35
+ label,
35
36
  listProps,
36
37
  initialNumToRender = 3,
37
38
  } ) {
@@ -154,6 +155,7 @@ export default function BlockTypesList( {
154
155
  <SectionList
155
156
  onLayout={ onLayout }
156
157
  testID={ `InserterUI-${ name }` }
158
+ accessibilityLabel={ label }
157
159
  keyboardShouldPersistTaps="always"
158
160
  sections={ sections }
159
161
  initialNumToRender={ initialNumToRender }
@@ -55,6 +55,7 @@ function ColorGradientControlInner( {
55
55
  clearable,
56
56
  showTitle = true,
57
57
  enableAlpha,
58
+ headingLevel,
58
59
  } ) {
59
60
  const canChooseAColor =
60
61
  onColorChange && ( ! isEmpty( colors ) || ! disableCustomColors );
@@ -84,6 +85,7 @@ function ColorGradientControlInner( {
84
85
  }
85
86
  clearable={ clearable }
86
87
  enableAlpha={ enableAlpha }
88
+ headingLevel={ headingLevel }
87
89
  />
88
90
  ),
89
91
  [ TAB_GRADIENT.value ]: (
@@ -103,6 +105,7 @@ function ColorGradientControlInner( {
103
105
  __experimentalIsRenderedInSidebar
104
106
  }
105
107
  clearable={ clearable }
108
+ headingLevel={ headingLevel }
106
109
  />
107
110
  ),
108
111
  };
@@ -63,7 +63,7 @@ const FONT_WEIGHTS = [
63
63
  * @param {boolean} hasFontWeights Whether font weights are enabled and present.
64
64
  * @return {string} A label representing what font appearance is being edited.
65
65
  */
66
- export const getFontAppearanceLabel = ( hasFontStyles, hasFontWeights ) => {
66
+ const getFontAppearanceLabel = ( hasFontStyles, hasFontWeights ) => {
67
67
  if ( ! hasFontStyles ) {
68
68
  return __( 'Font weight' );
69
69
  }