Skip to content

feat: adjust rating styles - #2635

Merged
hellofanny merged 5 commits into
mainfrom
feat/adjust-actionable-rating
Feb 6, 2025
Merged

hellofanny merged 5 commits into
mainfrom
feat/adjust-actionable-rating

Conversation

@artursantiago

@artursantiago artursantiago commented Jan 28, 2025 •

Copy link
Copy Markdown
Contributor

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?

Starters Deploy Preview

Preview

References

JIRA TASK: SFS-2077

Figma

Default

image

Actionable

image

@artursantiago artursantiago self-assigned this Jan 28, 2025
@vercel

vercel Bot commented Jan 28, 2025 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
faststore-site ✅ Ready (Inspect) Visit Preview Jan 28, 2025 0:18am

@codesandbox-ci

codesandbox-ci Bot commented Jan 28, 2025 •

Copy link
Copy Markdown

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.

@artursantiago artursantiago changed the title Feat/adjust actionable rating feat: adjust actionable rating Jan 28, 2025
@artursantiago artursantiago added the enhancement New feature or request label Jan 28, 2025
@artursantiago artursantiago changed the title feat: adjust actionable rating feat: adjust rating styles Jan 28, 2025
@artursantiago
artursantiago marked this pull request as ready for review January 30, 2025 17:43
@artursantiago
artursantiago requested a review from a team as a code owner January 30, 2025 17:43
@artursantiago
artursantiago requested review from hellofanny and pedromtec and removed request for a team January 30, 2025 17:43
@artursantiago
artursantiago force-pushed the feat/adjust-actionable-rating branch from 4632fa9 to 7470db2 Compare February 4, 2025 22:14

@hellofanny hellofanny left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@artursantiago well done! 🌟

LGTM!

@hellofanny

Copy link
Copy Markdown
Contributor

@mariana-caetano JTLYK We are updating this component tokens. I've open a request here

@hellofanny
hellofanny merged commit 3498a76 into main Feb 6, 2025
@hellofanny
hellofanny deleted the feat/adjust-actionable-rating branch February 6, 2025 19:54
hellofanny added a commit that referenced this pull request Feb 13, 2025
>⚠️ 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)


![image](https://github.com/user-attachments/assets/56da1a26-1764-489c-90e9-2d81275715c3)


![image](https://github.com/user-attachments/assets/8351c008-3fca-4e36-ad6d-30518e005dbb)

---------

Co-authored-by: Fanny Chien <[email protected]>
Co-authored-by: Fanny Chien <[email protected]>
artursantiago added a commit that referenced this pull request Feb 14, 2025
## 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


![image](https://github.com/user-attachments/assets/53cff9ef-b54a-4ea6-9ea0-1d1d574ce04c)

Actionable


![image](https://github.com/user-attachments/assets/ae6395cb-2bc8-4dff-94a3-c99f0eb7c5ac)
artursantiago added a commit that referenced this pull request Feb 14, 2025
>⚠️ 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)


![image](https://github.com/user-attachments/assets/56da1a26-1764-489c-90e9-2d81275715c3)


![image](https://github.com/user-attachments/assets/8351c008-3fca-4e36-ad6d-30518e005dbb)

---------

Co-authored-by: Fanny Chien <[email protected]>
Co-authored-by: Fanny Chien <[email protected]>
artursantiago added a commit that referenced this pull request Feb 14, 2025
## 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


![image](https://github.com/user-attachments/assets/53cff9ef-b54a-4ea6-9ea0-1d1d574ce04c)

Actionable


![image](https://github.com/user-attachments/assets/ae6395cb-2bc8-4dff-94a3-c99f0eb7c5ac)
artursantiago added a commit that referenced this pull request Feb 14, 2025
>⚠️ 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)


![image](https://github.com/user-attachments/assets/56da1a26-1764-489c-90e9-2d81275715c3)


![image](https://github.com/user-attachments/assets/8351c008-3fca-4e36-ad6d-30518e005dbb)

---------

Co-authored-by: Fanny Chien <[email protected]>
Co-authored-by: Fanny Chien <[email protected]>
artursantiago added a commit that referenced this pull request Feb 14, 2025
## 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


![image](https://github.com/user-attachments/assets/53cff9ef-b54a-4ea6-9ea0-1d1d574ce04c)

Actionable


![image](https://github.com/user-attachments/assets/ae6395cb-2bc8-4dff-94a3-c99f0eb7c5ac)
artursantiago added a commit that referenced this pull request Feb 14, 2025
>⚠️ 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)


![image](https://github.com/user-attachments/assets/56da1a26-1764-489c-90e9-2d81275715c3)


![image](https://github.com/user-attachments/assets/8351c008-3fca-4e36-ad6d-30518e005dbb)

---------

Co-authored-by: Fanny Chien <[email protected]>
Co-authored-by: Fanny Chien <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants