Skip to content

🐛 fix(progress bar): Multiple errors in the progress bar component. #289

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: release/1.9.0
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 23 additions & 37 deletions packages/react-progress-bar/docs/progress-bar-elements.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,16 +105,14 @@ export const Loader = () => {
return (
<Section
title="Loading Wheel"
description={[
'By default, the component shows the loading wheel but you can hide it by setting ',
<code style={{ fontSize: 11 }}>hasLoader</code>,
' property to ',
<code style={{ fontSize: 11 }}>false</code>,
'.',
]}
description={
<>
By default, the component shows the loading wheel but you can hide it by setting <code style={{ fontSize: 11 }}>hasLoader</code> property to <code style={{ fontSize: 11 }}>false</code>.
</>
}
isLast={true}
>
<ProgressBar now={30} hasCancel={false} hasBar={false} hasLabel={false} />
<ProgressBar now={30} hasCancel={false} hasLabel={false} />
</Section>
);
};
Expand All @@ -123,16 +121,14 @@ export const Percent = () => {
return (
<Section
title="Percentage Text"
description={[
'By default, the component shows the progress value or percentage, but you can hide it by setting ',
<code style={{ fontSize: 11 }}>hasLabel</code>,
' property to ',
<code style={{ fontSize: 11 }}>false</code>,
'.',
]}
description={
<>
By default, the component shows the progress value or percentage, but you can hide it by setting <code style={{ fontSize: 11 }}>hasLabel</code> property to <code style={{ fontSize: 11 }}>false</code>.
</>
}
isLast={true}
>
<ProgressBar hasLoader={false} hasCancel={false} hasBar={false} now={30} />
<ProgressBar hasLoader={false} hasCancel={false} now={30} />
</Section>
);
};
Expand All @@ -141,18 +137,14 @@ export const Cancel = () => {
return (
<Section
title="Cancel Button"
description={[
'By default, the component shows the cancel button, but you can hide it by setting ',
<code style={{ fontSize: 11 }}>hasCancel</code>,
' property to ',
<code style={{ fontSize: 11 }}>false</code>,
'. You can also pass a function when clicking on it by using the ',
<code style={{ fontSize: 11 }}>cbFunction</code>,
' property.',
]}
description={
<>
By default, the component shows the cancel button, but you can hide it by setting <code style={{ fontSize: 11 }}>hasCancel</code> property to <code style={{ fontSize: 11 }}>false</code>. You can also pass a function when clicking on it by using the <code style={{ fontSize: 11 }}>cbFunction</code> property.
</>
}
isLast={true}
>
<ProgressBar now={30} hasLoader={false} hasBar={false} hasLabel={false} />
<ProgressBar now={30} hasLoader={false} hasLabel={false} />
</Section>
);
};
Expand All @@ -162,17 +154,11 @@ export const Legend = () => {
<>
<Section
title="Legend Text"
description={[
'This text appears below the progress bar and only when ',
<code style={{ fontSize: 11 }}>hasFrame</code>,
' and ',
<code style={{ fontSize: 11 }}>hasLegend</code>,
' properties are set to ',
<code style={{ fontSize: 11 }}>true</code>,
'. You can edit the text using ',
<code style={{ fontSize: 11 }}>sourceLang</code>,
' property.',
]}
description={
<>
This text appears below the progress bar and only when <code style={{ fontSize: 11 }}>hasFrame</code> and <code style={{ fontSize: 11 }}>hasLegend</code> properties are set to <code style={{ fontSize: 11 }}>true</code>. You can edit the text using <code style={{ fontSize: 11 }}>sourceLang</code> property.
</>
}
isLast={true}
>
<ProgressBar
Expand Down
20 changes: 10 additions & 10 deletions packages/react-progress-bar/docs/progress-bar-modifiers.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,23 +115,23 @@ export const Design = () => {

<Section
title="Boxed Simple"
description={[
'Using the ',
<code style={{ fontSize: 11 }}>hasFrame</code>,
' property, you can display a gray border with inner spacing around the progress bar and its elements.',
]}
description={
<>
Using the <code style={{ fontSize: 11 }}>hasFrame</code> property, you can display a gray border with inner spacing around the progress bar and its elements.
</>
}
code="&lt;ProgressBar now={ 30 } hasFrame={ true } hasLegend={ false } /&gt;"
>
<ProgressBar now={30} hasFrame={true} hasLegend={false} />
</Section>

<Section
title="Boxed with Legend"
description={[
'The boxed variation can come with a legend at the bottom if necessary that you can display using the ',
<code style={{ fontSize: 11 }}>hasLegend</code>,
' property.',
]}
description={
<>
The boxed variation can come with a legend at the bottom if necessary that you can display using the <code style={{ fontSize: 11 }}>hasLegend</code> property.
</>
}
code="&lt;ProgressBar now={ 30 } hasFrame={ true } hasLegend={ true } /&gt;"
isLast={true}
>
Expand Down