@wordpress/components 19.6.1-next.a55ed9455a.0 → 19.7.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 (179) hide show
  1. package/CHANGELOG.md +31 -1
  2. package/build/base-control/index.js +19 -14
  3. package/build/base-control/index.js.map +1 -1
  4. package/build/base-control/styles/base-control-styles.js +33 -12
  5. package/build/base-control/styles/base-control-styles.js.map +1 -1
  6. package/build/box-control/all-input-control.js +3 -7
  7. package/build/box-control/all-input-control.js.map +1 -1
  8. package/build/box-control/axial-input-controls.js +20 -15
  9. package/build/box-control/axial-input-controls.js.map +1 -1
  10. package/build/box-control/input-controls.js +21 -16
  11. package/build/box-control/input-controls.js.map +1 -1
  12. package/build/box-control/utils.js +25 -11
  13. package/build/box-control/utils.js.map +1 -1
  14. package/build/checkbox-control/index.js +21 -1
  15. package/build/checkbox-control/index.js.map +1 -1
  16. package/build/color-palette/index.js +53 -4
  17. package/build/color-palette/index.js.map +1 -1
  18. package/build/custom-select-control/index.js +8 -3
  19. package/build/custom-select-control/index.js.map +1 -1
  20. package/build/divider/styles.js +28 -16
  21. package/build/divider/styles.js.map +1 -1
  22. package/build/focal-point-picker/controls.js +2 -3
  23. package/build/focal-point-picker/controls.js.map +1 -1
  24. package/build/form-file-upload/index.js +4 -1
  25. package/build/form-file-upload/index.js.map +1 -1
  26. package/build/input-control/input-field.js +21 -14
  27. package/build/input-control/input-field.js.map +1 -1
  28. package/build/input-control/reducer/actions.js +1 -3
  29. package/build/input-control/reducer/actions.js.map +1 -1
  30. package/build/input-control/reducer/reducer.js +1 -43
  31. package/build/input-control/reducer/reducer.js.map +1 -1
  32. package/build/number-control/index.js +15 -10
  33. package/build/number-control/index.js.map +1 -1
  34. package/build/resizable-box/resize-tooltip/styles/resize-tooltip.styles.js +4 -4
  35. package/build/resizable-box/resize-tooltip/styles/resize-tooltip.styles.js.map +1 -1
  36. package/build/toggle-group-control/toggle-group-control-option/component.js +1 -4
  37. package/build/toggle-group-control/toggle-group-control-option/component.js.map +1 -1
  38. package/build/toggle-group-control/toggle-group-control-option/styles.js +12 -19
  39. package/build/toggle-group-control/toggle-group-control-option/styles.js.map +1 -1
  40. package/build/tree-grid/index.js +4 -1
  41. package/build/tree-grid/index.js.map +1 -1
  42. package/build/unit-control/index.js +49 -27
  43. package/build/unit-control/index.js.map +1 -1
  44. package/build/unit-control/unit-select-control.js +2 -4
  45. package/build/unit-control/unit-select-control.js.map +1 -1
  46. package/build-module/base-control/index.js +19 -14
  47. package/build-module/base-control/index.js.map +1 -1
  48. package/build-module/base-control/styles/base-control-styles.js +34 -6
  49. package/build-module/base-control/styles/base-control-styles.js.map +1 -1
  50. package/build-module/box-control/all-input-control.js +4 -8
  51. package/build-module/box-control/all-input-control.js.map +1 -1
  52. package/build-module/box-control/axial-input-controls.js +18 -14
  53. package/build-module/box-control/axial-input-controls.js.map +1 -1
  54. package/build-module/box-control/input-controls.js +18 -14
  55. package/build-module/box-control/input-controls.js.map +1 -1
  56. package/build-module/box-control/utils.js +25 -11
  57. package/build-module/box-control/utils.js.map +1 -1
  58. package/build-module/checkbox-control/index.js +24 -3
  59. package/build-module/checkbox-control/index.js.map +1 -1
  60. package/build-module/color-palette/index.js +52 -4
  61. package/build-module/color-palette/index.js.map +1 -1
  62. package/build-module/custom-select-control/index.js +8 -3
  63. package/build-module/custom-select-control/index.js.map +1 -1
  64. package/build-module/divider/styles.js +29 -10
  65. package/build-module/divider/styles.js.map +1 -1
  66. package/build-module/focal-point-picker/controls.js +2 -3
  67. package/build-module/focal-point-picker/controls.js.map +1 -1
  68. package/build-module/form-file-upload/index.js +4 -1
  69. package/build-module/form-file-upload/index.js.map +1 -1
  70. package/build-module/input-control/input-field.js +21 -13
  71. package/build-module/input-control/input-field.js.map +1 -1
  72. package/build-module/input-control/reducer/actions.js +0 -1
  73. package/build-module/input-control/reducer/actions.js.map +1 -1
  74. package/build-module/input-control/reducer/reducer.js +2 -39
  75. package/build-module/input-control/reducer/reducer.js.map +1 -1
  76. package/build-module/number-control/index.js +15 -9
  77. package/build-module/number-control/index.js.map +1 -1
  78. package/build-module/resizable-box/resize-tooltip/styles/resize-tooltip.styles.js +4 -4
  79. package/build-module/resizable-box/resize-tooltip/styles/resize-tooltip.styles.js.map +1 -1
  80. package/build-module/toggle-group-control/toggle-group-control-option/component.js +1 -4
  81. package/build-module/toggle-group-control/toggle-group-control-option/component.js.map +1 -1
  82. package/build-module/toggle-group-control/toggle-group-control-option/styles.js +11 -17
  83. package/build-module/toggle-group-control/toggle-group-control-option/styles.js.map +1 -1
  84. package/build-module/tree-grid/index.js +4 -1
  85. package/build-module/tree-grid/index.js.map +1 -1
  86. package/build-module/unit-control/index.js +47 -25
  87. package/build-module/unit-control/index.js.map +1 -1
  88. package/build-module/unit-control/unit-select-control.js +2 -3
  89. package/build-module/unit-control/unit-select-control.js.map +1 -1
  90. package/build-style/style-rtl.css +29 -181
  91. package/build-style/style.css +29 -181
  92. package/build-types/base-control/index.d.ts +23 -18
  93. package/build-types/base-control/index.d.ts.map +1 -1
  94. package/build-types/base-control/styles/base-control-styles.d.ts +4 -0
  95. package/build-types/base-control/styles/base-control-styles.d.ts.map +1 -1
  96. package/build-types/card/card-divider/hook.d.ts +1 -1
  97. package/build-types/color-palette/index.d.ts.map +1 -1
  98. package/build-types/color-picker/styles.d.ts +1 -1
  99. package/build-types/divider/stories/index.d.ts +1 -0
  100. package/build-types/divider/stories/index.d.ts.map +1 -1
  101. package/build-types/divider/styles.d.ts.map +1 -1
  102. package/build-types/divider/types.d.ts +8 -1
  103. package/build-types/divider/types.d.ts.map +1 -1
  104. package/build-types/input-control/input-field.d.ts.map +1 -1
  105. package/build-types/input-control/reducer/actions.d.ts +1 -3
  106. package/build-types/input-control/reducer/actions.d.ts.map +1 -1
  107. package/build-types/input-control/reducer/reducer.d.ts +3 -9
  108. package/build-types/input-control/reducer/reducer.d.ts.map +1 -1
  109. package/build-types/input-control/types.d.ts +2 -2
  110. package/build-types/input-control/types.d.ts.map +1 -1
  111. package/build-types/number-control/index.d.ts +3 -3
  112. package/build-types/number-control/index.d.ts.map +1 -1
  113. package/build-types/range-control/styles/range-control-styles.d.ts +1 -1
  114. package/build-types/resizable-box/resize-tooltip/styles/resize-tooltip.styles.d.ts.map +1 -1
  115. package/build-types/toggle-group-control/toggle-group-control-option/component.d.ts.map +1 -1
  116. package/build-types/toggle-group-control/toggle-group-control-option/styles.d.ts +0 -4
  117. package/build-types/toggle-group-control/toggle-group-control-option/styles.d.ts.map +1 -1
  118. package/build-types/unit-control/index.d.ts +7 -4
  119. package/build-types/unit-control/index.d.ts.map +1 -1
  120. package/build-types/unit-control/stories/index.d.ts +33 -0
  121. package/build-types/unit-control/stories/index.d.ts.map +1 -0
  122. package/build-types/unit-control/styles/unit-control-styles.d.ts +1 -1
  123. package/build-types/unit-control/types.d.ts +23 -6
  124. package/build-types/unit-control/types.d.ts.map +1 -1
  125. package/build-types/unit-control/unit-select-control.d.ts.map +1 -1
  126. package/package.json +17 -17
  127. package/src/base-control/README.md +9 -1
  128. package/src/base-control/index.js +20 -13
  129. package/src/base-control/stories/index.js +2 -2
  130. package/src/base-control/styles/base-control-styles.js +23 -1
  131. package/src/box-control/all-input-control.js +2 -10
  132. package/src/box-control/axial-input-controls.js +32 -21
  133. package/src/box-control/input-controls.js +30 -19
  134. package/src/box-control/utils.js +29 -12
  135. package/src/checkbox-control/index.js +34 -3
  136. package/src/checkbox-control/stories/index.js +44 -0
  137. package/src/checkbox-control/style.scss +4 -2
  138. package/src/color-palette/index.js +73 -8
  139. package/src/color-palette/stories/index.js +62 -26
  140. package/src/color-palette/style.scss +11 -3
  141. package/src/color-palette/test/__snapshots__/index.js.snap +662 -12
  142. package/src/color-palette/test/index.js +1 -1
  143. package/src/custom-select-control/index.js +8 -2
  144. package/src/custom-select-control/stories/index.js +77 -74
  145. package/src/custom-select-control/style.scss +18 -3
  146. package/src/divider/stories/index.tsx +26 -23
  147. package/src/divider/styles.ts +9 -0
  148. package/src/divider/types.ts +11 -1
  149. package/src/focal-point-picker/controls.js +2 -3
  150. package/src/font-size-picker/test/index.js +0 -2
  151. package/src/form-file-upload/README.md +18 -0
  152. package/src/form-file-upload/index.js +3 -0
  153. package/src/form-file-upload/test/index.js +73 -11
  154. package/src/input-control/input-field.tsx +23 -12
  155. package/src/input-control/reducer/actions.ts +1 -7
  156. package/src/input-control/reducer/reducer.ts +0 -29
  157. package/src/input-control/types.ts +2 -1
  158. package/src/mobile/image/style.native.scss +1 -0
  159. package/src/number-control/README.md +14 -0
  160. package/src/number-control/index.js +13 -12
  161. package/src/number-control/stories/index.js +14 -7
  162. package/src/number-control/test/index.js +79 -1
  163. package/src/range-control/stories/index.js +91 -119
  164. package/src/resizable-box/resize-tooltip/styles/resize-tooltip.styles.js +1 -0
  165. package/src/toggle-group-control/test/__snapshots__/index.js.snap +0 -27
  166. package/src/toggle-group-control/toggle-group-control-option/component.tsx +1 -4
  167. package/src/toggle-group-control/toggle-group-control-option/styles.ts +0 -12
  168. package/src/toolbar-group/style.scss +0 -73
  169. package/src/tree-grid/README.md +1 -1
  170. package/src/tree-grid/index.js +4 -0
  171. package/src/tree-grid/test/index.js +61 -17
  172. package/src/unit-control/README.md +1 -3
  173. package/src/unit-control/index.tsx +59 -30
  174. package/src/unit-control/stories/index.tsx +170 -0
  175. package/src/unit-control/test/index.js +143 -100
  176. package/src/unit-control/types.ts +60 -41
  177. package/src/unit-control/unit-select-control.tsx +2 -3
  178. package/tsconfig.tsbuildinfo +1 -1
  179. package/src/unit-control/stories/index.js +0 -127
@@ -8,11 +8,124 @@ exports[`ColorPalette Dropdown .renderContent should render dropdown content 1`]
8
8
  `;
9
9
 
10
10
  exports[`ColorPalette Dropdown .renderToggle should render dropdown content 1`] = `
11
- <button
11
+ .emotion-0 {
12
+ display: -webkit-box;
13
+ display: -webkit-flex;
14
+ display: -ms-flexbox;
15
+ display: flex;
16
+ }
17
+
18
+ .emotion-1 {
19
+ -webkit-align-items: flex-start;
20
+ -webkit-box-align: flex-start;
21
+ -ms-flex-align: flex-start;
22
+ align-items: flex-start;
23
+ -webkit-flex-direction: row;
24
+ -ms-flex-direction: row;
25
+ flex-direction: row;
26
+ -webkit-box-pack: justify;
27
+ -webkit-justify-content: space-between;
28
+ justify-content: space-between;
29
+ width: 100%;
30
+ }
31
+
32
+ .emotion-2>*+*:not( marquee ) {
33
+ margin-left: calc(4px * 2);
34
+ }
35
+
36
+ .emotion-3>* {
37
+ min-width: 0;
38
+ }
39
+
40
+ .emotion-4 {
41
+ display: -webkit-box;
42
+ display: -webkit-flex;
43
+ display: -ms-flexbox;
44
+ display: flex;
45
+ -webkit-align-items: flex-start;
46
+ -webkit-box-align: flex-start;
47
+ -ms-flex-align: flex-start;
48
+ align-items: flex-start;
49
+ -webkit-flex-direction: row;
50
+ -ms-flex-direction: row;
51
+ flex-direction: row;
52
+ -webkit-box-pack: justify;
53
+ -webkit-justify-content: space-between;
54
+ justify-content: space-between;
55
+ width: 100%;
56
+ }
57
+
58
+ .emotion-4>*+*:not( marquee ) {
59
+ margin-left: calc(4px * 2);
60
+ }
61
+
62
+ .emotion-4>* {
63
+ min-width: 0;
64
+ }
65
+
66
+ .emotion-6 {
67
+ display: block;
68
+ max-height: 100%;
69
+ max-width: 100%;
70
+ min-height: 0;
71
+ min-width: 0;
72
+ }
73
+
74
+ .emotion-8 {
75
+ -webkit-flex: 1;
76
+ -ms-flex: 1;
77
+ flex: 1;
78
+ }
79
+
80
+ .emotion-9 {
81
+ display: block;
82
+ max-height: 100%;
83
+ max-width: 100%;
84
+ min-height: 0;
85
+ min-width: 0;
86
+ -webkit-flex: 1;
87
+ -ms-flex: 1;
88
+ flex: 1;
89
+ }
90
+
91
+ .emotion-11 {
92
+ display: block;
93
+ overflow: hidden;
94
+ text-overflow: ellipsis;
95
+ white-space: nowrap;
96
+ }
97
+
98
+ .emotion-15 {
99
+ display: block;
100
+ overflow: hidden;
101
+ text-overflow: ellipsis;
102
+ white-space: nowrap;
103
+ display: block;
104
+ max-height: 100%;
105
+ max-width: 100%;
106
+ min-height: 0;
107
+ min-width: 0;
108
+ -webkit-flex: 1;
109
+ -ms-flex: 1;
110
+ flex: 1;
111
+ }
112
+
113
+ .emotion-19 {
114
+ display: block;
115
+ max-height: 100%;
116
+ max-width: 100%;
117
+ min-height: 0;
118
+ min-width: 0;
119
+ }
120
+
121
+ <Flex
122
+ align="flex-start"
12
123
  aria-expanded={true}
13
124
  aria-haspopup="true"
14
- aria-label="Custom color picker"
125
+ aria-label="Custom color picker. The currently selected color is called \\"red\\" and has a value of \\"f00\\"."
126
+ as="button"
15
127
  className="components-color-palette__custom-color"
128
+ justify="space-between"
16
129
  onClick={[MockFunction]}
17
130
  style={
18
131
  Object {
@@ -21,11 +134,227 @@ exports[`ColorPalette Dropdown .renderToggle should render dropdown content 1`]
21
134
  }
22
135
  }
23
136
  >
24
- #f00
25
- </button>
137
+ <View
138
+ aria-expanded={true}
139
+ aria-haspopup="true"
140
+ aria-label="Custom color picker. The currently selected color is called \\"red\\" and has a value of \\"f00\\"."
141
+ as="button"
142
+ className="emotion-0 emotion-1 emotion-2 emotion-3 components-flex components-color-palette__custom-color"
143
+ data-wp-c16t={true}
144
+ data-wp-component="Flex"
145
+ onClick={[MockFunction]}
146
+ style={
147
+ Object {
148
+ "background": "#f00",
149
+ "color": "#000",
150
+ }
151
+ }
152
+ >
153
+ <Noop />
154
+ <button
155
+ aria-expanded={true}
156
+ aria-haspopup="true"
157
+ aria-label="Custom color picker. The currently selected color is called \\"red\\" and has a value of \\"f00\\"."
158
+ className="components-flex components-color-palette__custom-color emotion-4 emotion-5"
159
+ data-wp-c16t={true}
160
+ data-wp-component="Flex"
161
+ onClick={[MockFunction]}
162
+ style={
163
+ Object {
164
+ "background": "#f00",
165
+ "color": "#000",
166
+ }
167
+ }
168
+ >
169
+ <FlexItem
170
+ as={
171
+ Object {
172
+ "$$typeof": Symbol(react.forward_ref),
173
+ "__contextSystemKey__": Array [
174
+ "Truncate",
175
+ ],
176
+ "render": [Function],
177
+ "selector": ".components-truncate",
178
+ }
179
+ }
180
+ className="components-color-palette__custom-color-name"
181
+ isBlock={true}
182
+ >
183
+ <View
184
+ as={
185
+ Object {
186
+ "$$typeof": Symbol(react.forward_ref),
187
+ "__contextSystemKey__": Array [
188
+ "Truncate",
189
+ ],
190
+ "render": [Function],
191
+ "selector": ".components-truncate",
192
+ }
193
+ }
194
+ className="emotion-6 emotion-7 emotion-8 components-flex-item components-color-palette__custom-color-name"
195
+ data-wp-c16t={true}
196
+ data-wp-component="FlexItem"
197
+ >
198
+ <Noop />
199
+ <Truncate
200
+ className="components-flex-item components-color-palette__custom-color-name emotion-9 emotion-5"
201
+ data-wp-c16t={true}
202
+ data-wp-component="FlexItem"
203
+ >
204
+ <View
205
+ as="span"
206
+ className="emotion-11 components-truncate components-flex-item components-color-palette__custom-color-name emotion-9 emotion-5"
207
+ data-wp-c16t={true}
208
+ data-wp-component="FlexItem"
209
+ >
210
+ <Noop />
211
+ <span
212
+ className="components-truncate components-flex-item components-color-palette__custom-color-name emotion-5 emotion-15 emotion-5"
213
+ data-wp-c16t={true}
214
+ data-wp-component="FlexItem"
215
+ >
216
+ red
217
+ </span>
218
+ </View>
219
+ </Truncate>
220
+ </View>
221
+ </FlexItem>
222
+ <FlexItem
223
+ as="span"
224
+ className="components-color-palette__custom-color-value"
225
+ >
226
+ <View
227
+ as="span"
228
+ className="emotion-6 emotion-7 components-flex-item components-color-palette__custom-color-value"
229
+ data-wp-c16t={true}
230
+ data-wp-component="FlexItem"
231
+ >
232
+ <Noop />
233
+ <span
234
+ className="components-flex-item components-color-palette__custom-color-value emotion-19 emotion-5"
235
+ data-wp-c16t={true}
236
+ data-wp-component="FlexItem"
237
+ >
238
+ f00
239
+ </span>
240
+ </View>
241
+ </FlexItem>
242
+ </button>
243
+ </View>
244
+ </Flex>
26
245
  `;
27
246
 
28
247
  exports[`ColorPalette Dropdown should render it correctly 1`] = `
248
+ .emotion-0 {
249
+ display: -webkit-box;
250
+ display: -webkit-flex;
251
+ display: -ms-flexbox;
252
+ display: flex;
253
+ }
254
+
255
+ .emotion-1 {
256
+ -webkit-align-items: flex-start;
257
+ -webkit-box-align: flex-start;
258
+ -ms-flex-align: flex-start;
259
+ align-items: flex-start;
260
+ -webkit-flex-direction: row;
261
+ -ms-flex-direction: row;
262
+ flex-direction: row;
263
+ -webkit-box-pack: justify;
264
+ -webkit-justify-content: space-between;
265
+ justify-content: space-between;
266
+ width: 100%;
267
+ }
268
+
269
+ .emotion-2>*+*:not( marquee ) {
270
+ margin-left: calc(4px * 2);
271
+ }
272
+
273
+ .emotion-3>* {
274
+ min-width: 0;
275
+ }
276
+
277
+ .emotion-4 {
278
+ display: -webkit-box;
279
+ display: -webkit-flex;
280
+ display: -ms-flexbox;
281
+ display: flex;
282
+ -webkit-align-items: flex-start;
283
+ -webkit-box-align: flex-start;
284
+ -ms-flex-align: flex-start;
285
+ align-items: flex-start;
286
+ -webkit-flex-direction: row;
287
+ -ms-flex-direction: row;
288
+ flex-direction: row;
289
+ -webkit-box-pack: justify;
290
+ -webkit-justify-content: space-between;
291
+ justify-content: space-between;
292
+ width: 100%;
293
+ }
294
+
295
+ .emotion-4>*+*:not( marquee ) {
296
+ margin-left: calc(4px * 2);
297
+ }
298
+
299
+ .emotion-4>* {
300
+ min-width: 0;
301
+ }
302
+
303
+ .emotion-6 {
304
+ display: block;
305
+ max-height: 100%;
306
+ max-width: 100%;
307
+ min-height: 0;
308
+ min-width: 0;
309
+ }
310
+
311
+ .emotion-8 {
312
+ -webkit-flex: 1;
313
+ -ms-flex: 1;
314
+ flex: 1;
315
+ }
316
+
317
+ .emotion-9 {
318
+ display: block;
319
+ max-height: 100%;
320
+ max-width: 100%;
321
+ min-height: 0;
322
+ min-width: 0;
323
+ -webkit-flex: 1;
324
+ -ms-flex: 1;
325
+ flex: 1;
326
+ }
327
+
328
+ .emotion-11 {
329
+ display: block;
330
+ overflow: hidden;
331
+ text-overflow: ellipsis;
332
+ white-space: nowrap;
333
+ }
334
+
335
+ .emotion-15 {
336
+ display: block;
337
+ overflow: hidden;
338
+ text-overflow: ellipsis;
339
+ white-space: nowrap;
340
+ display: block;
341
+ max-height: 100%;
342
+ max-width: 100%;
343
+ min-height: 0;
344
+ min-width: 0;
345
+ -webkit-flex: 1;
346
+ -ms-flex: 1;
347
+ flex: 1;
348
+ }
349
+
350
+ .emotion-19 {
351
+ display: block;
352
+ max-height: 100%;
353
+ max-width: 100%;
354
+ min-height: 0;
355
+ min-width: 0;
356
+ }
357
+
29
358
  <Dropdown
30
359
  contentClassName="components-color-palette__custom-color-dropdown-content"
31
360
  renderContent={[Function]}
@@ -35,11 +364,14 @@ exports[`ColorPalette Dropdown should render it correctly 1`] = `
35
364
  className="components-dropdown"
36
365
  tabIndex="-1"
37
366
  >
38
- <button
367
+ <Flex
368
+ align="flex-start"
39
369
  aria-expanded={false}
40
370
  aria-haspopup="true"
41
- aria-label="Custom color picker"
371
+ aria-label="Custom color picker. The currently selected color is called \\"red\\" and has a value of \\"f00\\"."
372
+ as="button"
42
373
  className="components-color-palette__custom-color"
374
+ justify="space-between"
43
375
  onClick={[Function]}
44
376
  style={
45
377
  Object {
@@ -48,8 +380,114 @@ exports[`ColorPalette Dropdown should render it correctly 1`] = `
48
380
  }
49
381
  }
50
382
  >
51
- #f00
52
- </button>
383
+ <View
384
+ aria-expanded={false}
385
+ aria-haspopup="true"
386
+ aria-label="Custom color picker. The currently selected color is called \\"red\\" and has a value of \\"f00\\"."
387
+ as="button"
388
+ className="emotion-0 emotion-1 emotion-2 emotion-3 components-flex components-color-palette__custom-color"
389
+ data-wp-c16t={true}
390
+ data-wp-component="Flex"
391
+ onClick={[Function]}
392
+ style={
393
+ Object {
394
+ "background": "#f00",
395
+ "color": "#000",
396
+ }
397
+ }
398
+ >
399
+ <Noop />
400
+ <button
401
+ aria-expanded={false}
402
+ aria-haspopup="true"
403
+ aria-label="Custom color picker. The currently selected color is called \\"red\\" and has a value of \\"f00\\"."
404
+ className="components-flex components-color-palette__custom-color emotion-4 emotion-5"
405
+ data-wp-c16t={true}
406
+ data-wp-component="Flex"
407
+ onClick={[Function]}
408
+ style={
409
+ Object {
410
+ "background": "#f00",
411
+ "color": "#000",
412
+ }
413
+ }
414
+ >
415
+ <FlexItem
416
+ as={
417
+ Object {
418
+ "$$typeof": Symbol(react.forward_ref),
419
+ "__contextSystemKey__": Array [
420
+ "Truncate",
421
+ ],
422
+ "render": [Function],
423
+ "selector": ".components-truncate",
424
+ }
425
+ }
426
+ className="components-color-palette__custom-color-name"
427
+ isBlock={true}
428
+ >
429
+ <View
430
+ as={
431
+ Object {
432
+ "$$typeof": Symbol(react.forward_ref),
433
+ "__contextSystemKey__": Array [
434
+ "Truncate",
435
+ ],
436
+ "render": [Function],
437
+ "selector": ".components-truncate",
438
+ }
439
+ }
440
+ className="emotion-6 emotion-7 emotion-8 components-flex-item components-color-palette__custom-color-name"
441
+ data-wp-c16t={true}
442
+ data-wp-component="FlexItem"
443
+ >
444
+ <Noop />
445
+ <Truncate
446
+ className="components-flex-item components-color-palette__custom-color-name emotion-9 emotion-5"
447
+ data-wp-c16t={true}
448
+ data-wp-component="FlexItem"
449
+ >
450
+ <View
451
+ as="span"
452
+ className="emotion-11 components-truncate components-flex-item components-color-palette__custom-color-name emotion-9 emotion-5"
453
+ data-wp-c16t={true}
454
+ data-wp-component="FlexItem"
455
+ >
456
+ <Noop />
457
+ <span
458
+ className="components-truncate components-flex-item components-color-palette__custom-color-name emotion-5 emotion-15 emotion-5"
459
+ data-wp-c16t={true}
460
+ data-wp-component="FlexItem"
461
+ >
462
+ red
463
+ </span>
464
+ </View>
465
+ </Truncate>
466
+ </View>
467
+ </FlexItem>
468
+ <FlexItem
469
+ as="span"
470
+ className="components-color-palette__custom-color-value"
471
+ >
472
+ <View
473
+ as="span"
474
+ className="emotion-6 emotion-7 components-flex-item components-color-palette__custom-color-value"
475
+ data-wp-c16t={true}
476
+ data-wp-component="FlexItem"
477
+ >
478
+ <Noop />
479
+ <span
480
+ className="components-flex-item components-color-palette__custom-color-value emotion-19 emotion-5"
481
+ data-wp-c16t={true}
482
+ data-wp-component="FlexItem"
483
+ >
484
+ f00
485
+ </span>
486
+ </View>
487
+ </FlexItem>
488
+ </button>
489
+ </View>
490
+ </Flex>
53
491
  </div>
54
492
  </Dropdown>
55
493
  `;
@@ -144,6 +582,109 @@ exports[`ColorPalette should render a dynamic toolbar of colors 1`] = `
144
582
  min-height: 0;
145
583
  }
146
584
 
585
+ .emotion-7 {
586
+ -webkit-align-items: flex-start;
587
+ -webkit-box-align: flex-start;
588
+ -ms-flex-align: flex-start;
589
+ align-items: flex-start;
590
+ -webkit-flex-direction: row;
591
+ -ms-flex-direction: row;
592
+ flex-direction: row;
593
+ -webkit-box-pack: justify;
594
+ -webkit-justify-content: space-between;
595
+ justify-content: space-between;
596
+ width: 100%;
597
+ }
598
+
599
+ .emotion-8>*+*:not( marquee ) {
600
+ margin-left: calc(4px * 2);
601
+ }
602
+
603
+ .emotion-9>* {
604
+ min-width: 0;
605
+ }
606
+
607
+ .emotion-10 {
608
+ display: -webkit-box;
609
+ display: -webkit-flex;
610
+ display: -ms-flexbox;
611
+ display: flex;
612
+ -webkit-align-items: flex-start;
613
+ -webkit-box-align: flex-start;
614
+ -ms-flex-align: flex-start;
615
+ align-items: flex-start;
616
+ -webkit-flex-direction: row;
617
+ -ms-flex-direction: row;
618
+ flex-direction: row;
619
+ -webkit-box-pack: justify;
620
+ -webkit-justify-content: space-between;
621
+ justify-content: space-between;
622
+ width: 100%;
623
+ }
624
+
625
+ .emotion-10>*+*:not( marquee ) {
626
+ margin-left: calc(4px * 2);
627
+ }
628
+
629
+ .emotion-10>* {
630
+ min-width: 0;
631
+ }
632
+
633
+ .emotion-12 {
634
+ display: block;
635
+ max-height: 100%;
636
+ max-width: 100%;
637
+ min-height: 0;
638
+ min-width: 0;
639
+ }
640
+
641
+ .emotion-14 {
642
+ -webkit-flex: 1;
643
+ -ms-flex: 1;
644
+ flex: 1;
645
+ }
646
+
647
+ .emotion-15 {
648
+ display: block;
649
+ max-height: 100%;
650
+ max-width: 100%;
651
+ min-height: 0;
652
+ min-width: 0;
653
+ -webkit-flex: 1;
654
+ -ms-flex: 1;
655
+ flex: 1;
656
+ }
657
+
658
+ .emotion-17 {
659
+ display: block;
660
+ overflow: hidden;
661
+ text-overflow: ellipsis;
662
+ white-space: nowrap;
663
+ }
664
+
665
+ .emotion-21 {
666
+ display: block;
667
+ overflow: hidden;
668
+ text-overflow: ellipsis;
669
+ white-space: nowrap;
670
+ display: block;
671
+ max-height: 100%;
672
+ max-width: 100%;
673
+ min-height: 0;
674
+ min-width: 0;
675
+ -webkit-flex: 1;
676
+ -ms-flex: 1;
677
+ flex: 1;
678
+ }
679
+
680
+ .emotion-25 {
681
+ display: block;
682
+ max-height: 100%;
683
+ max-width: 100%;
684
+ min-height: 0;
685
+ min-width: 0;
686
+ }
687
+
147
688
  <ColorPalette
148
689
  colors={
149
690
  Array [
@@ -194,11 +735,14 @@ exports[`ColorPalette should render a dynamic toolbar of colors 1`] = `
194
735
  className="components-dropdown"
195
736
  tabIndex="-1"
196
737
  >
197
- <button
738
+ <Flex
739
+ align="flex-start"
198
740
  aria-expanded={false}
199
741
  aria-haspopup="true"
200
- aria-label="Custom color picker"
742
+ aria-label="Custom color picker. The currently selected color is called \\"red\\" and has a value of \\"f00\\"."
743
+ as="button"
201
744
  className="components-color-palette__custom-color"
745
+ justify="space-between"
202
746
  onClick={[Function]}
203
747
  style={
204
748
  Object {
@@ -207,8 +751,114 @@ exports[`ColorPalette should render a dynamic toolbar of colors 1`] = `
207
751
  }
208
752
  }
209
753
  >
210
- #f00
211
- </button>
754
+ <View
755
+ aria-expanded={false}
756
+ aria-haspopup="true"
757
+ aria-label="Custom color picker. The currently selected color is called \\"red\\" and has a value of \\"f00\\"."
758
+ as="button"
759
+ className="emotion-0 emotion-7 emotion-8 emotion-9 components-flex components-color-palette__custom-color"
760
+ data-wp-c16t={true}
761
+ data-wp-component="Flex"
762
+ onClick={[Function]}
763
+ style={
764
+ Object {
765
+ "background": "#f00",
766
+ "color": "#000",
767
+ }
768
+ }
769
+ >
770
+ <Noop />
771
+ <button
772
+ aria-expanded={false}
773
+ aria-haspopup="true"
774
+ aria-label="Custom color picker. The currently selected color is called \\"red\\" and has a value of \\"f00\\"."
775
+ className="components-flex components-color-palette__custom-color emotion-10 emotion-5"
776
+ data-wp-c16t={true}
777
+ data-wp-component="Flex"
778
+ onClick={[Function]}
779
+ style={
780
+ Object {
781
+ "background": "#f00",
782
+ "color": "#000",
783
+ }
784
+ }
785
+ >
786
+ <FlexItem
787
+ as={
788
+ Object {
789
+ "$$typeof": Symbol(react.forward_ref),
790
+ "__contextSystemKey__": Array [
791
+ "Truncate",
792
+ ],
793
+ "render": [Function],
794
+ "selector": ".components-truncate",
795
+ }
796
+ }
797
+ className="components-color-palette__custom-color-name"
798
+ isBlock={true}
799
+ >
800
+ <View
801
+ as={
802
+ Object {
803
+ "$$typeof": Symbol(react.forward_ref),
804
+ "__contextSystemKey__": Array [
805
+ "Truncate",
806
+ ],
807
+ "render": [Function],
808
+ "selector": ".components-truncate",
809
+ }
810
+ }
811
+ className="emotion-12 emotion-13 emotion-14 components-flex-item components-color-palette__custom-color-name"
812
+ data-wp-c16t={true}
813
+ data-wp-component="FlexItem"
814
+ >
815
+ <Noop />
816
+ <Truncate
817
+ className="components-flex-item components-color-palette__custom-color-name emotion-15 emotion-5"
818
+ data-wp-c16t={true}
819
+ data-wp-component="FlexItem"
820
+ >
821
+ <View
822
+ as="span"
823
+ className="emotion-17 components-truncate components-flex-item components-color-palette__custom-color-name emotion-15 emotion-5"
824
+ data-wp-c16t={true}
825
+ data-wp-component="FlexItem"
826
+ >
827
+ <Noop />
828
+ <span
829
+ className="components-truncate components-flex-item components-color-palette__custom-color-name emotion-5 emotion-21 emotion-5"
830
+ data-wp-c16t={true}
831
+ data-wp-component="FlexItem"
832
+ >
833
+ red
834
+ </span>
835
+ </View>
836
+ </Truncate>
837
+ </View>
838
+ </FlexItem>
839
+ <FlexItem
840
+ as="span"
841
+ className="components-color-palette__custom-color-value"
842
+ >
843
+ <View
844
+ as="span"
845
+ className="emotion-12 emotion-13 components-flex-item components-color-palette__custom-color-value"
846
+ data-wp-c16t={true}
847
+ data-wp-component="FlexItem"
848
+ >
849
+ <Noop />
850
+ <span
851
+ className="components-flex-item components-color-palette__custom-color-value emotion-25 emotion-5"
852
+ data-wp-c16t={true}
853
+ data-wp-component="FlexItem"
854
+ >
855
+ f00
856
+ </span>
857
+ </View>
858
+ </FlexItem>
859
+ </button>
860
+ </View>
861
+ </Flex>
212
862
  </div>
213
863
  </Dropdown>
214
864
  </CustomColorPickerDropdown>