Skip to content

Fix rating field default value #12792

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

Merged
merged 1 commit into from
Jun 23, 2025
Merged

Fix rating field default value #12792

merged 1 commit into from
Jun 23, 2025

Conversation

prastoin
Copy link
Contributor

@prastoin prastoin commented Jun 23, 2025

close #12789

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

Changed default rating field behavior by removing the default 'RATING_1' value in packages/twenty-front/src/modules/object-record/record-field/meta-types/hooks/useRatingFieldDisplay.ts, now defaulting to null instead.

  • Modified useRecordFieldValue hook implementation to include proper generic typing for better type safety
  • Breaking Change: Changed rating field default from 'RATING_1' to null which may affect components expecting non-null values
  • Consider documenting this breaking change and ensuring components handle null rating values gracefully

1 file reviewed, no comments
Edit PR Review Bot Settings | Greptile

Copy link
Contributor

🚀 Preview Environment Ready!

Your preview environment is available at: http://bore.pub:17808

This environment will automatically shut down when the PR is closed or after 5 hours.

@lucasbordeau lucasbordeau self-requested a review June 23, 2025 14:51
Copy link
Contributor

@lucasbordeau lucasbordeau left a comment

Choose a reason for hiding this comment

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

LGTM

@Bonapara Shouldn't we be able to "clear" a rating field ? So that it is NULL ?

@prastoin prastoin merged commit b2a560e into main Jun 23, 2025
56 checks passed
@prastoin prastoin deleted the rating-default-value branch June 23, 2025 14:56
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.

null Rating field aren't correctly displayed
2 participants