@pushwoosh/dumb-components 1.1.226 → 1.1.227
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.
|
@@ -3,7 +3,4 @@ export declare const BubbleText: import("styled-components").StyledComponent<"sp
|
|
|
3
3
|
$uppercase?: boolean | undefined;
|
|
4
4
|
$ellipsis?: boolean | undefined;
|
|
5
5
|
$variant?: import("@pushwoosh/kit-typography").TypographyVariant | undefined;
|
|
6
|
-
}
|
|
7
|
-
$variant: "footnote";
|
|
8
|
-
$color: import("@pushwoosh/kit-constants").Color;
|
|
9
|
-
}, "$color" | "$variant">;
|
|
6
|
+
}, never>;
|
|
@@ -35,7 +35,4 @@ export declare const PreviewText: import("styled-components").StyledComponent<"s
|
|
|
35
35
|
$uppercase?: boolean | undefined;
|
|
36
36
|
$ellipsis?: boolean | undefined;
|
|
37
37
|
$variant?: import("@pushwoosh/kit-typography").TypographyVariant | undefined;
|
|
38
|
-
}
|
|
39
|
-
$variant: "footnote";
|
|
40
|
-
$color: Color;
|
|
41
|
-
}, "$color" | "$variant">;
|
|
38
|
+
}, never>;
|
|
@@ -18,10 +18,12 @@ export const Bubble = styled(Vertical).attrs({
|
|
|
18
18
|
displayName: "Bubble",
|
|
19
19
|
componentId: "sc-15y0kbp-1"
|
|
20
20
|
})(["box-shadow:", ";overflow-wrap:anywhere;"], Shadow.LARGE);
|
|
21
|
-
|
|
21
|
+
// styled-components merges attrs OVER incoming props, so a plain object here would
|
|
22
|
+
// silently clobber every call-site `$color`; the callback keeps MAIN as a default only.
|
|
23
|
+
export const PreviewText = styled(Text).attrs(props => ({
|
|
22
24
|
$variant: 'footnote',
|
|
23
|
-
$color: Color.MAIN
|
|
24
|
-
}).withConfig({
|
|
25
|
+
$color: props.$color ?? Color.MAIN
|
|
26
|
+
})).withConfig({
|
|
25
27
|
displayName: "PreviewText",
|
|
26
28
|
componentId: "sc-15y0kbp-2"
|
|
27
29
|
})(["overflow:hidden;line-height:18px;text-overflow:ellipsis;"]);
|