You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- adds documentation around making sure the default border is applied in
cases where a swatch is empty/undefined
- updates the no-color test case to apply the default border
- removes non-existent swatch arguments isGradient and isImage
- fix rectangle story name to shape
* A swatch shows a small sample of a fill--such as a color, gradient, texture, or material--that is intended to be applied to an object.
@@ -183,29 +183,30 @@ Border.parameters = {
183
183
/**
184
184
* Swatches can also have a rectangle shape with an aspect ratio of 2:1. The square shape is the default and is used in swatch groups (e.g., a palette of colors).
185
185
*/
186
-
exportconstRectangle=Template.bind({});
187
-
Rectangle.args={
186
+
exportconstShape=Template.bind({});
187
+
Shape.args={
188
188
shape: "rectangle",
189
189
swatchColor: "rgba(174, 216, 230, 0.25)",
190
190
};
191
-
Rectangle.tags=["!dev"];
192
-
Rectangle.parameters={
191
+
Shape.tags=["!dev"];
192
+
Shape.parameters={
193
193
chromatic: {disableSnapshot: true},
194
194
};
195
+
Shape.storyName="Shape - rectangle";
195
196
196
197
/**
197
-
* A swatch will appear "empty" when its color, image, or gradient are undefined.
198
+
* A swatch will appear "empty" when its preview is undefined, for instance when the image or gradient is undefined, or when a swatch color is transparent. The `.is-nothing` class is applied to the swatch in these cases. Implementations should ensure that the default border style is applied when a swatch is empty.
0 commit comments