Skip to content

Conversation

nakul-py
Copy link
Contributor

@nakul-py nakul-py commented Sep 23, 2025

Description

Adding typing to useState hooks and Disable the Classify button if user does not provide valid number or negative.

Checklist

  • PR has a descriptive title and content.
  • PR description contains references to any issues the PR resolves, e.g. Resolves #XXX.
  • PR has one of the labels: documentation, bug, enhancement, feature, maintenance
  • Checks are passing.
    Failing lint checks can be resolved with:
    • pre-commit run --all-files
    • jlpm run lint

📚 Documentation preview: https://jupytergis--937.org.readthedocs.build/en/937/
💡 JupyterLite preview: https://jupytergis--937.org.readthedocs.build/en/937/lite

Copy link
Contributor

Binder 👈 Launch a Binder on branch nakul-py/jupytergis/hooks

Copy link
Contributor

github-actions bot commented Sep 23, 2025

Integration tests report: appsharing.space

@nakul-py nakul-py requested a review from mfisher87 September 24, 2025 10:27
…in SingleBandPseudoColor, Categorized, and Graduated components
…SingleBandPseudoColor and Graduated components
Copy link
Member

@mfisher87 mfisher87 left a comment

Choose a reason for hiding this comment

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

I have to leave for a conference soon, so just leaving some thoughts for now :) I'd like to help out a bit more soon!


useEffect(() => {
if (selectedRamp === '' && selectedMode === '' && numberOfShades === '') {
if (selectedRamp === '') {
Copy link
Member

Choose a reason for hiding this comment

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

Should we still check if selectedMode and numberofShades are undefined here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sure we can check if selectedMode and numberofShades are undefined here as it is More defensive ensures all three are unset before populating.

@nakul-py nakul-py requested a review from mfisher87 September 25, 2025 05:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

Review and improve typing for react states
2 participants