Skip to content

Commit 7f30533

Browse files
alex-pagelaurkimchloerice
authored
Rename AlphaStack to VerticalStack (#8935)
### WHY are these changes introduced? With the UI consolidation effort happening we are aligning component names and properties across repositories. This is a first step to align component names. ### WHAT is this pull request doing? **⚠️ Breaking change** to rename `AlphaStack` to `VerticalStack` --------- Co-authored-by: Lo Kim <lo.kim@shopify.com> Co-authored-by: Chloe Rice <chloerice@users.noreply.github.com>
1 parent 090d096 commit 7f30533

File tree

55 files changed

+247
-243
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+247
-243
lines changed

.changeset/silly-meals-hang.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
'@shopify/polaris': minor
3+
'polaris.shopify.com': minor
4+
---
5+
6+
Renamed `AlphaStack` to `VerticalStack`

polaris-react/src/components/AccountConnection/AccountConnection.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import {AlphaCard} from '../AlphaCard';
88
import {Box} from '../Box';
99
import {Inline} from '../Inline';
1010
import {Text} from '../Text';
11-
import {AlphaStack} from '../AlphaStack';
11+
import {VerticalStack} from '../VerticalStack';
1212

1313
export interface AccountConnectionProps {
1414
/** Content to display as title */
@@ -73,10 +73,10 @@ export function AccountConnection({
7373
<SettingAction action={actionElement}>
7474
<Inline gap="4">
7575
{avatarMarkup}
76-
<AlphaStack gap="2">
76+
<VerticalStack gap="2">
7777
{titleMarkup}
7878
{detailsMarkup}
79-
</AlphaStack>
79+
</VerticalStack>
8080
</Inline>
8181
</SettingAction>
8282
{termsOfServiceMarkup}

polaris-react/src/components/AlphaCard/AlphaCard.stories.tsx

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import React from 'react';
22
import type {ComponentMeta} from '@storybook/react';
33
import {
44
AlphaCard,
5-
AlphaStack,
5+
VerticalStack,
66
Bleed,
77
Box,
88
Divider,
@@ -17,59 +17,59 @@ export default {
1717
export function Default() {
1818
return (
1919
<AlphaCard>
20-
<AlphaStack gap="5">
20+
<VerticalStack gap="5">
2121
<Text as="h3" variant="headingMd">
2222
Online store dashboard
2323
</Text>
2424
<p>View a summary of your online store’s performance.</p>
25-
</AlphaStack>
25+
</VerticalStack>
2626
</AlphaCard>
2727
);
2828
}
2929

3030
export function WithBackgroundSubdued() {
3131
return (
3232
<AlphaCard background="bg-subdued">
33-
<AlphaStack gap="5">
33+
<VerticalStack gap="5">
3434
<Text as="h3" variant="headingMd">
3535
Online store dashboard
3636
</Text>
3737
<p>View a summary of your online store’s performance.</p>
38-
</AlphaStack>
38+
</VerticalStack>
3939
</AlphaCard>
4040
);
4141
}
4242

4343
export function WithBorderRadiusRoundedAbove() {
4444
return (
4545
<AlphaCard roundedAbove="sm">
46-
<AlphaStack gap="5">
46+
<VerticalStack gap="5">
4747
<Text as="h3" variant="headingMd">
4848
Online store dashboard
4949
</Text>
5050
<p>View a summary of your online store’s performance.</p>
51-
</AlphaStack>
51+
</VerticalStack>
5252
</AlphaCard>
5353
);
5454
}
5555

5656
export function WithResponsivePadding() {
5757
return (
5858
<AlphaCard padding={{xs: '5', sm: '6', md: '8'}} roundedAbove="sm">
59-
<AlphaStack gap={{xs: '4', sm: '5'}}>
59+
<VerticalStack gap={{xs: '4', sm: '5'}}>
6060
<Text as="h3" variant="headingMd">
6161
Online store dashboard
6262
</Text>
6363
<p>View a summary of your online store’s performance.</p>
64-
</AlphaStack>
64+
</VerticalStack>
6565
</AlphaCard>
6666
);
6767
}
6868

6969
export function WithSubduedSection() {
7070
return (
7171
<AlphaCard roundedAbove="sm">
72-
<AlphaStack gap="5">
72+
<VerticalStack gap="5">
7373
<Text as="h3" variant="headingMd">
7474
Staff accounts
7575
</Text>
@@ -79,22 +79,22 @@ export function WithSubduedSection() {
7979
<List.Item>Ezequiel Manno</List.Item>
8080
</List>
8181
</Box>
82-
</AlphaStack>
82+
</VerticalStack>
8383
<Bleed
8484
marginBlockEnd={{xs: '4', sm: '5'}}
8585
marginInline={{xs: '4', sm: '5'}}
8686
>
8787
<Divider />
8888
<Box background="bg-subdued" padding={{xs: '4', sm: '5'}}>
89-
<AlphaStack gap="2">
89+
<VerticalStack gap="2">
9090
<Text variant="headingSm" as="h3">
9191
Deactivated staff accounts
9292
</Text>
9393
<List>
9494
<List.Item>Felix Crafford</List.Item>
9595
<List.Item>Ezequiel Manno</List.Item>
9696
</List>
97-
</AlphaStack>
97+
</VerticalStack>
9898
</Box>
9999
</Bleed>
100100
</AlphaCard>

polaris-react/src/components/AlphaFilters/components/FilterPill/FilterPill.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import {useI18n} from '../../../../utilities/i18n';
55
import {useToggle} from '../../../../utilities/use-toggle';
66
import {Popover} from '../../../Popover';
77
import {Button} from '../../../Button';
8-
import {AlphaStack} from '../../../AlphaStack';
8+
import {VerticalStack} from '../../../VerticalStack';
99
import {Icon} from '../../../Icon';
1010
import {Text} from '../../../Text';
1111
import {Inline} from '../../../Inline';
@@ -178,10 +178,10 @@ export function FilterPill({
178178
>
179179
<div className={styles.PopoverWrapper}>
180180
<Popover.Section>
181-
<AlphaStack gap="1">
181+
<VerticalStack gap="1">
182182
{filter}
183183
{clearButtonMarkup}
184-
</AlphaStack>
184+
</VerticalStack>
185185
</Popover.Section>
186186
</div>
187187
</Popover>

polaris-react/src/components/AlphaStack/index.ts

Lines changed: 0 additions & 1 deletion
This file was deleted.

polaris-react/src/components/Banner/Banner.stories.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import React, {useCallback, useEffect, useRef, useState} from 'react';
22
import type {ComponentMeta} from '@storybook/react';
33
import {
4-
AlphaStack,
4+
VerticalStack,
55
Banner,
66
Button,
77
LegacyCard,
@@ -193,7 +193,7 @@ export function InACard() {
193193
export function WithEndJustifiedContent() {
194194
return (
195195
<Banner status="critical">
196-
<AlphaStack gap="1">
196+
<VerticalStack gap="1">
197197
<Inline gap="4" align="space-between">
198198
<Text variant="headingMd" fontWeight="semibold" as="h3">
199199
Deployment failed in 5min
@@ -203,7 +203,7 @@ export function WithEndJustifiedContent() {
203203
</Link>
204204
</Inline>
205205
<p>This order was archived on March 7, 2017 at 3:12pm EDT.</p>
206-
</AlphaStack>
206+
</VerticalStack>
207207
</Banner>
208208
);
209209
}

polaris-react/src/components/Box/Box.stories.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import React from 'react';
22
import type {ComponentMeta} from '@storybook/react';
3-
import {AlphaStack, Box, Icon} from '@shopify/polaris';
3+
import {VerticalStack, Box, Icon} from '@shopify/polaris';
44
import {PaintBrushMajor} from '@shopify/polaris-icons';
55

66
export default {
@@ -33,7 +33,7 @@ export function WithBorderRadius() {
3333

3434
export function WithResponsivePadding() {
3535
return (
36-
<AlphaStack gap="4">
36+
<VerticalStack gap="4">
3737
<Box background="bg" padding={{xs: '2', sm: '8'}} border="dark">
3838
<Icon source={PaintBrushMajor} color="base" />
3939
</Box>
@@ -64,6 +64,6 @@ export function WithResponsivePadding() {
6464
<Box background="bg" paddingInlineEnd={{xs: '4', sm: '10'}} border="dark">
6565
<Icon source={PaintBrushMajor} color="base" />
6666
</Box>
67-
</AlphaStack>
67+
</VerticalStack>
6868
);
6969
}

polaris-react/src/components/ChoiceList/ChoiceList.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import type {Error} from '../../types';
55
import {Checkbox} from '../Checkbox';
66
import {RadioButton} from '../RadioButton';
77
import {InlineError, errorTextID} from '../InlineError';
8-
import {AlphaStack} from '../AlphaStack';
8+
import {VerticalStack} from '../VerticalStack';
99
import {Box} from '../Box';
1010
import {Bleed} from '../Bleed';
1111

@@ -132,18 +132,18 @@ export function ChoiceList({
132132
);
133133

134134
return (
135-
<AlphaStack
135+
<VerticalStack
136136
as="fieldset"
137137
gap={{xs: '4', md: '0'}}
138138
aria-invalid={error != null}
139139
id={finalName}
140140
>
141141
{titleMarkup}
142-
<AlphaStack as="ul" gap={{xs: '4', md: '0'}}>
142+
<VerticalStack as="ul" gap={{xs: '4', md: '0'}}>
143143
{choicesMarkup}
144-
</AlphaStack>
144+
</VerticalStack>
145145
{errorMarkup}
146-
</AlphaStack>
146+
</VerticalStack>
147147
);
148148
}
149149

polaris-react/src/components/Divider/Divider.stories.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import React from 'react';
22
import type {ComponentMeta} from '@storybook/react';
3-
import {AlphaStack, Divider, Text} from '@shopify/polaris';
3+
import {VerticalStack, Divider, Text} from '@shopify/polaris';
44

55
export default {
66
component: Divider,
@@ -12,7 +12,7 @@ export function Default() {
1212

1313
export function WithBorderStyles() {
1414
return (
15-
<AlphaStack gap="5">
15+
<VerticalStack gap="5">
1616
<Text as="h1" variant="headingXs">
1717
Default
1818
</Text>
@@ -29,6 +29,6 @@ export function WithBorderStyles() {
2929
Transparent
3030
</Text>
3131
<Divider borderColor="transparent" />
32-
</AlphaStack>
32+
</VerticalStack>
3333
);
3434
}

0 commit comments

Comments
 (0)