Skip to content

Conversation

Mash707
Copy link
Contributor

@Mash707 Mash707 commented May 10, 2025

Towards #11719

The following examples of Chart Donut will be converted to TypeScript:

  • Static thresholds
  • Static thresholds with right aligned legend
  • Inverted static thresholds with right aligned legend
  • Static thresholds with custom legend
  • Static thresholds with bottom aligned legend
  • Small with static thresholds
  • Small with static thresholds and right aligned legend
  • Small with subtitle
  • Small with thresholds and right aligned subtitle

This is related to #11819. The remaining 9 examples are converted in this PR to make it easier for reviewing.

@patternfly-build
Copy link
Contributor

patternfly-build commented May 10, 2025

@Mash707 Mash707 mentioned this pull request May 9, 2025
18 tasks
Copy link
Contributor

@thatblindgeye thatblindgeye left a comment

Choose a reason for hiding this comment

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

Actually, can we update the usage of things like React.useState etc in the examples to import those directly?

So each example file should import whatever hooks and such they're using (typically types like React.FunctionComponent are fine as-is, more things like useState, useEffect, etc and even React.Fragment we want to import) as import {useState...} from 'react', then the markdown file should include a similar import that includes all imports from each of the example files.

The ChartLegend.md file from one of your other PRs shows how that should look.

@Mash707
Copy link
Contributor Author

Mash707 commented May 14, 2025

I'll make the changes to this one and other PRs too.

@Mash707 Mash707 requested a review from thatblindgeye May 14, 2025 18:32
@thatblindgeye thatblindgeye merged commit f26b518 into patternfly:main May 19, 2025
13 checks passed
@Mash707 Mash707 deleted the chart-donut-utilization-convert-to-typescript-part-two branch May 20, 2025 20:56
mattnolting pushed a commit to mattnolting/patternfly-react that referenced this pull request Jun 4, 2025
…rnfly#11822)

* chore(chart donut utilization): convert to typescript part two

* updated usage of hooks

* updated markdown file to include necessary imports
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.

4 participants