-
Notifications
You must be signed in to change notification settings - Fork 64
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
feat: adjust rating styles #2635
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. |
4632fa9
to
7470db2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@artursantiago well done! 🌟
LGTM!
@mariana-caetano JTLYK We are updating this component tokens. I've open a request here |
>⚠️ THIS PR DEPENDS ON [PR#2635](#2635)⚠️ ## What's the purpose of this pull request? This pull request adds the RatingField component, which will initially be used in the modal for adding reviews to a product. ## How it works? This PR creates a new molecule component called `RatingField`. In addition to the "input" fields for the actionable rating, it can also receive an `id`, `label`, and `error` via props to be displayed in the form. The component uses the `Rating` component with the `actionable` view, passing the `onChange` handler to it. ## How to test it? <!--- Describe the steps with bullet points. Is there any external link that can be used to better test it or an example? ---> ### Starters Deploy Preview <!--- Add a link to a deploy preview from `starter.store` with this branch being used. ---> <!--- Tip: You can get an installable version of this branch from the CodeSandbox generated when this PR is created. ---> [Preview](https://starter-git-feat-rating-field-vtex.vercel.app//review-and-ratings-playground) ## References [JIRA TASK: SFS-2078](https://vtex-dev.atlassian.net/browse/SFS-2078) [JIRA TASK: SFS-2077](https://vtex-dev.atlassian.net/browse/SFS-2077) [Figma](https://www.figma.com/design/YXU6IX2htN2yg7udpCumZv/Reviews-%26-Ratings?node-id=131-49445&t=iOanfcOwmDa4bolf-4)   --------- Co-authored-by: Fanny Chien <fanny.chien@vtex.com> Co-authored-by: Fanny Chien <fannychienn@gmail.com>
## What's the purpose of this pull request? This pull request introduces adjustments to the **Rating component** for the new **Reviews & Ratings** section. ## How it works? It updates the colors for both the default and actionable versions, using `main-2` for active stars and `neutral-4` for empty stars. Additionally, it includes the addition of a `disabled` style for the actionable rating. ## How to test it? <!--- Describe the steps with bullet points. Is there any external link that can be used to better test it or an example? ---> ### Starters Deploy Preview <!--- Add a link to a deploy preview from `starter.store` with this branch being used. ---> <!--- Tip: You can get an installable version of this branch from the CodeSandbox generated when this PR is created. ---> [Preview](https://starter-git-feat-rating-field-vtex.vercel.app/review-and-ratings-playground) ## References [JIRA TASK: SFS-2077](https://vtex-dev.atlassian.net/browse/SFS-2077) [Figma](https://www.figma.com/design/YXU6IX2htN2yg7udpCumZv/Reviews-%26-Ratings?node-id=131-49445&t=97j1KIeA0brteiq8-4) Default  Actionable 
>⚠️ THIS PR DEPENDS ON [PR#2635](#2635)⚠️ ## What's the purpose of this pull request? This pull request adds the RatingField component, which will initially be used in the modal for adding reviews to a product. ## How it works? This PR creates a new molecule component called `RatingField`. In addition to the "input" fields for the actionable rating, it can also receive an `id`, `label`, and `error` via props to be displayed in the form. The component uses the `Rating` component with the `actionable` view, passing the `onChange` handler to it. ## How to test it? <!--- Describe the steps with bullet points. Is there any external link that can be used to better test it or an example? ---> ### Starters Deploy Preview <!--- Add a link to a deploy preview from `starter.store` with this branch being used. ---> <!--- Tip: You can get an installable version of this branch from the CodeSandbox generated when this PR is created. ---> [Preview](https://starter-git-feat-rating-field-vtex.vercel.app//review-and-ratings-playground) ## References [JIRA TASK: SFS-2078](https://vtex-dev.atlassian.net/browse/SFS-2078) [JIRA TASK: SFS-2077](https://vtex-dev.atlassian.net/browse/SFS-2077) [Figma](https://www.figma.com/design/YXU6IX2htN2yg7udpCumZv/Reviews-%26-Ratings?node-id=131-49445&t=iOanfcOwmDa4bolf-4)   --------- Co-authored-by: Fanny Chien <fanny.chien@vtex.com> Co-authored-by: Fanny Chien <fannychienn@gmail.com>
## What's the purpose of this pull request? This pull request introduces adjustments to the **Rating component** for the new **Reviews & Ratings** section. ## How it works? It updates the colors for both the default and actionable versions, using `main-2` for active stars and `neutral-4` for empty stars. Additionally, it includes the addition of a `disabled` style for the actionable rating. ## How to test it? <!--- Describe the steps with bullet points. Is there any external link that can be used to better test it or an example? ---> ### Starters Deploy Preview <!--- Add a link to a deploy preview from `starter.store` with this branch being used. ---> <!--- Tip: You can get an installable version of this branch from the CodeSandbox generated when this PR is created. ---> [Preview](https://starter-git-feat-rating-field-vtex.vercel.app/review-and-ratings-playground) ## References [JIRA TASK: SFS-2077](https://vtex-dev.atlassian.net/browse/SFS-2077) [Figma](https://www.figma.com/design/YXU6IX2htN2yg7udpCumZv/Reviews-%26-Ratings?node-id=131-49445&t=97j1KIeA0brteiq8-4) Default  Actionable 
>⚠️ THIS PR DEPENDS ON [PR#2635](#2635)⚠️ ## What's the purpose of this pull request? This pull request adds the RatingField component, which will initially be used in the modal for adding reviews to a product. ## How it works? This PR creates a new molecule component called `RatingField`. In addition to the "input" fields for the actionable rating, it can also receive an `id`, `label`, and `error` via props to be displayed in the form. The component uses the `Rating` component with the `actionable` view, passing the `onChange` handler to it. ## How to test it? <!--- Describe the steps with bullet points. Is there any external link that can be used to better test it or an example? ---> ### Starters Deploy Preview <!--- Add a link to a deploy preview from `starter.store` with this branch being used. ---> <!--- Tip: You can get an installable version of this branch from the CodeSandbox generated when this PR is created. ---> [Preview](https://starter-git-feat-rating-field-vtex.vercel.app//review-and-ratings-playground) ## References [JIRA TASK: SFS-2078](https://vtex-dev.atlassian.net/browse/SFS-2078) [JIRA TASK: SFS-2077](https://vtex-dev.atlassian.net/browse/SFS-2077) [Figma](https://www.figma.com/design/YXU6IX2htN2yg7udpCumZv/Reviews-%26-Ratings?node-id=131-49445&t=iOanfcOwmDa4bolf-4)   --------- Co-authored-by: Fanny Chien <fanny.chien@vtex.com> Co-authored-by: Fanny Chien <fannychienn@gmail.com>
## What's the purpose of this pull request? This pull request introduces adjustments to the **Rating component** for the new **Reviews & Ratings** section. ## How it works? It updates the colors for both the default and actionable versions, using `main-2` for active stars and `neutral-4` for empty stars. Additionally, it includes the addition of a `disabled` style for the actionable rating. ## How to test it? <!--- Describe the steps with bullet points. Is there any external link that can be used to better test it or an example? ---> ### Starters Deploy Preview <!--- Add a link to a deploy preview from `starter.store` with this branch being used. ---> <!--- Tip: You can get an installable version of this branch from the CodeSandbox generated when this PR is created. ---> [Preview](https://starter-git-feat-rating-field-vtex.vercel.app/review-and-ratings-playground) ## References [JIRA TASK: SFS-2077](https://vtex-dev.atlassian.net/browse/SFS-2077) [Figma](https://www.figma.com/design/YXU6IX2htN2yg7udpCumZv/Reviews-%26-Ratings?node-id=131-49445&t=97j1KIeA0brteiq8-4) Default  Actionable 
>⚠️ THIS PR DEPENDS ON [PR#2635](#2635)⚠️ ## What's the purpose of this pull request? This pull request adds the RatingField component, which will initially be used in the modal for adding reviews to a product. ## How it works? This PR creates a new molecule component called `RatingField`. In addition to the "input" fields for the actionable rating, it can also receive an `id`, `label`, and `error` via props to be displayed in the form. The component uses the `Rating` component with the `actionable` view, passing the `onChange` handler to it. ## How to test it? <!--- Describe the steps with bullet points. Is there any external link that can be used to better test it or an example? ---> ### Starters Deploy Preview <!--- Add a link to a deploy preview from `starter.store` with this branch being used. ---> <!--- Tip: You can get an installable version of this branch from the CodeSandbox generated when this PR is created. ---> [Preview](https://starter-git-feat-rating-field-vtex.vercel.app//review-and-ratings-playground) ## References [JIRA TASK: SFS-2078](https://vtex-dev.atlassian.net/browse/SFS-2078) [JIRA TASK: SFS-2077](https://vtex-dev.atlassian.net/browse/SFS-2077) [Figma](https://www.figma.com/design/YXU6IX2htN2yg7udpCumZv/Reviews-%26-Ratings?node-id=131-49445&t=iOanfcOwmDa4bolf-4)   --------- Co-authored-by: Fanny Chien <fanny.chien@vtex.com> Co-authored-by: Fanny Chien <fannychienn@gmail.com>
What's the purpose of this pull request?
This pull request introduces adjustments to the Rating component for the new Reviews & Ratings section.
How it works?
It updates the colors for both the default and actionable versions, using
main-2
for active stars andneutral-4
for empty stars.Additionally, it includes the addition of a
disabled
style for the actionable rating.How to test it?
Starters Deploy Preview
Preview
References
JIRA TASK: SFS-2077
Figma
Default
Actionable