Skip to content

Commit

Permalink
docs(progressbar,meter): pr fixes and edits
Browse files Browse the repository at this point in the history
- removes some duplicative docs language for pgoress bar
- adds correct punctuation to CHANGELOG
- passes default value for customWidth in args for progress bar
- uses passive voice in meter documentation
- removes repetitive StaticWhiteDocs story in favor of previous
StaticWhite story
- removes Chromatic snapshot for WithoutLabel progress bar story
  • Loading branch information
marissahuysentruyt committed Oct 1, 2024
1 parent e2796d5 commit f383888
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 24 deletions.
2 changes: 1 addition & 1 deletion components/progressbar/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline

### spectrum-Meter class

Meter now uses the class `spectrum-Meter` on the parent `div`
Meter now uses the class `spectrum-Meter` on the parent `div`.

### 🔙 Reverts

Expand Down
2 changes: 1 addition & 1 deletion components/progressbar/stories/meter.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ Sizing.parameters = {
};

/**
* Meter variants can be used to represent semantic values by switching variants as the value changes, from positive, to notice, and then to negative. This kind of variant switching should be handled appropriately within the context of your product so that you’re setting accurate expectations for your users about the semantic meaning.
* Meter variants can be used to represent semantic values by switching variants as the value changes, from positive, to notice, and then to negative. This kind of variant switching should be handled appropriately within the context of your product so that accurate expectations are set for users about the semantic meaning.
*
* By default, the meter has a informative, blue fill to show the value. This can be used to represent a neutral or non-semantic value. The positive variant has a green fill, representing a positive semantic value. The notice variant has an orange fill, and can be used to warn users about a situation that may need to be addressed soon. The negative variant has a red fill, and can be used to warn users about a critical situation that needs their urgent attention.
*/
Expand Down
30 changes: 8 additions & 22 deletions components/progressbar/stories/progressbar.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ export default {
label: "Loading",
labelPosition: "top",
value: 0,
customWidth: 192,
isIndeterminate: false,
showValueLabel: true,
},
Expand Down Expand Up @@ -158,7 +159,7 @@ WithoutLabel.parameters = {
};

/**
* The example below shows a progress bar without its value label. This value label works in conjunction with the label, and should not be displayed if the label itself is not displayed.
* The example below shows a progress bar without its value label.
*/
export const WithoutValue = Template.bind({});
WithoutValue.storyName = "Without value";
Expand All @@ -168,20 +169,18 @@ WithoutValue.args = {
};
WithoutValue.tags = ["!dev"];
WithoutValue.parameters = {
chromatic: {
modes: disableDefaultModes
},
chromatic: { disableSnapshot: true },
};

export const StaticWhiteDocs = Template.bind({});
StaticWhiteDocs.storyName = "Static white";
StaticWhiteDocs.args = {
export const StaticWhite = ProgressBarGroup.bind({});
StaticWhite.storyName = "Static white";
StaticWhite.tags = ["!dev"];
StaticWhite.args = {
staticColor: "white",
label: "Loading your fonts, images, and icons",
value: 50,
};
StaticWhiteDocs.tags = ["!dev"];
StaticWhiteDocs.parameters = {
StaticWhite.parameters = {
chromatic: {
modes: disableDefaultModes
},
Expand All @@ -197,16 +196,3 @@ WithForcedColors.parameters = {
modes: disableDefaultModes
},
};

export const StaticWhite = ProgressBarGroup.bind({});
StaticWhite.tags = ["!autodocs", "!dev"];
StaticWhite.args = {
staticColor: "white",
label: "Loading your fonts, images, and icons",
value: 50,
};
StaticWhite.parameters = {
chromatic: {
modes: disableDefaultModes
},
};

0 comments on commit f383888

Please sign in to comment.