Skip to content

Commit

Permalink
Update styleguide Button props
Browse files Browse the repository at this point in the history
  • Loading branch information
aveline committed Aug 16, 2023
1 parent 4a33f52 commit e318f4f
Show file tree
Hide file tree
Showing 11 changed files with 12 additions and 14 deletions.
3 changes: 1 addition & 2 deletions polaris.shopify.com/pages/examples/filters-disabled.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,7 @@ function FiltersDisabledExample() {
<div style={{paddingLeft: '8px'}}>
<Button
disabled
primary
plain
variant="primaryPlain"
onClick={() => console.log('New filter saved')}
>
Save
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,7 @@ function FiltersWithSomeDisabledExample() {
<div style={{paddingLeft: '8px'}}>
<Button
disabled
primary
plain
variant="primaryPlain"
onClick={() => console.log('New filter saved')}
>
Save
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ function FullscreenBarExample() {
</div>
<ButtonGroup>
<Button onClick={() => {}}>Secondary Action</Button>
<Button primary onClick={() => {}}>
<Button variant="primary" onClick={() => {}}>
Primary Action
</Button>
</ButtonGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ function LegacyCardExample() {
<Popover
active={false}
activator={
<Button disclosure plain>
<Button disclosure variant="plain">
View Sales
</Button>
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ function LegacyCardExample() {
<LegacyStack distribution="trailing">
<ButtonGroup>
<Button>Enable two-step authentication</Button>
<Button plain>Learn more</Button>
<Button variant="plain">Learn more</Button>
</ButtonGroup>
</LegacyStack>
</LegacyStack>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ function PageExample() {
<PageActions
primaryAction={
<Button
primary
variant="primary"
connectedDisclosure={{
accessibilityLabel: 'Other save actions',
actions: [{content: 'Save as draft'}],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ function PageExample() {
title="General"
primaryAction={
<Button
primary
variant="primary"
connectedDisclosure={{
accessibilityLabel: 'Other save actions',
actions: [{content: 'Save as new'}],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ function PageExample() {
<LegacyStack.Item fill>
<p>Buy postage and ship remaining 2 items</p>
</LegacyStack.Item>
<Button primary>Continue</Button>
<Button variant="primary">Continue</Button>
</LegacyStack>
</LegacyCard>
</Page>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ export function WithPrimitiveComponents() {

const helpLink = (
<Button
plain
variant="plain"
icon={CircleInformationMajor}
accessibilityLabel="Learn more"
/>
Expand Down
4 changes: 2 additions & 2 deletions polaris.shopify.com/pages/examples/sheet-default.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ function SheetExample() {
accessibilityLabel="Cancel"
icon={MobileCancelMajor}
onClick={toggleSheetActive}
plain
variant="plain"
/>
</div>
<Scrollable style={{padding: '1rem', height: '100%'}}>
Expand All @@ -136,7 +136,7 @@ function SheetExample() {
}}
>
<Button onClick={toggleSheetActive}>Cancel</Button>
<Button primary onClick={toggleSheetActive}>
<Button variant="primary" onClick={toggleSheetActive}>
Done
</Button>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ function SheetWithSearchableListboxExample() {
accessibilityLabel="Cancel"
icon={MobileCancelMajor}
onClick={handleCloseSheet}
plain
variant="plain"
/>
</div>
<TextContainer>
Expand Down

0 comments on commit e318f4f

Please sign in to comment.