Skip to content

Conversation

@haydnkerr
Copy link
Contributor

Before: No Story in place for Progress component as part of issue #435

After:

  • Create Empty, Halfway and Full Progress stories showcasing different progress values
  • Includes interactive controls for value, className and indicatorClassName.

Issue: Progress bar renders utilizing a parent component however this comes with an 'error' that I am still figuring out.

Before: No Story in place for Progress component as part of issue #435

After: Create Empty, Halfway and Full Progress stories showcasing different progress values

Includes interactive controls for value, className and indicatorClassName.

Issue: Progress bar renders utilizing a parent component however this comes with an 'error' that I am still figuring out
@vercel
Copy link

vercel bot commented Jul 1, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
elecretanta Ready Ready Preview Comment Oct 13, 2025 7:18pm
elecretanta-storybook Ready Ready Preview Comment Oct 13, 2025 7:18pm
elecretanta-unit-test Ready Ready Preview Comment Oct 13, 2025 7:18pm

@shashilo shashilo requested review from a team July 1, 2025 18:09
Removed cn import as it is not needed
@@ -0,0 +1,59 @@
import type { Meta, StoryObj } from '@storybook/react';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add headers.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Headers have been added

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just add a newline after the headers to fix the eslint error.

args: {
value: 0,
},
render: (args) => (
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Look up decorators in Storybook. This is a way to add a wrapper to the element so you can wrap each Progress in a div.
Then you can remove all the renders you have in each export.
https://storybook.js.org/docs/writing-stories/decorators

If it complains about a missing return type, import and use ReactElement. There might be a better type, but I found this works.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have implemented decorators and removed or renders for the individual examples

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's still a missing return type on the decorator. Use import { ReactElement } from 'react'; instead of importing all of React.
Then use ReactElement as the decorator's return type.

@suzuhe481
Copy link
Contributor

suzuhe481 commented Jul 1, 2025

Move the story file into the Progress component's folder.

In the Gridiron Survivor repo, stories were located inside their respective component instead of inside the stories folder. We should get confirmation, but I'm pretty sure we'll keep them in their respective components.

add 'react' import
Copy link
Member

@nickytonline nickytonline left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚢

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants