File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed
dotcom-rendering/src/components Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -20,6 +20,7 @@ export const ProductCardButtons = ({
2020 label = { label }
2121 url = { productCta . url }
2222 minimisePadding = { true }
23+ fullWidthText = { productCtas . length > 1 }
2324 priority = { index === 0 ? 'primary' : 'tertiary' }
2425 fullwidth = { true }
2526 />
Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ type ProductLinkButtonProps = {
1515 url : string ;
1616 size ?: 'default' | 'small' ;
1717 fullwidth ?: boolean ;
18+ fullWidthText ?: boolean ;
1819 priority ?: ButtonPriority ;
1920 dataComponent ?: string ;
2021 minimisePadding ?: boolean ;
@@ -54,6 +55,7 @@ export const ProductLinkButton = ({
5455 size = 'default' ,
5556 fullwidth = false ,
5657 minimisePadding = false ,
58+ fullWidthText = false ,
5759 priority = 'primary' ,
5860 dataComponent,
5961} : ProductLinkButtonProps ) => {
@@ -81,7 +83,10 @@ export const ProductLinkButton = ({
8183 cssOverrides = { cssOverrides }
8284 >
8385 < span
86+ style = { fullWidthText ? { width : '100%' } : { } }
8487 css = { css `
88+ text-wrap : balance;
89+ text-align : center;
8590 white-space : normal;
8691 padding : 4px 0 4px ;
8792 ` }
You can’t perform that action at this time.
0 commit comments