Skip to content
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

Replaced all the css into tailwind css on FontSection component #1784

Merged
merged 10 commits into from
Dec 14, 2023

Conversation

subhajit20
Copy link
Contributor

Description of changes

Replaced all the css into tailwind css on FontSection component
Issue - #1725

Issue Resolved

Fixes #NA

Screenshots/GIFs

Copy link

vercel bot commented Dec 6, 2023

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

Name Status Preview Comments Updated (UTC)
operation-code ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 12, 2023 3:30pm
storybook ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 12, 2023 3:30pm

.fontsList > li {
margin: 1rem;
}

.primaryFontFamily div > h6,
.primaryFontFamily div > p {
Copy link
Contributor Author

@subhajit20 subhajit20 Dec 6, 2023

Choose a reason for hiding this comment

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

I did not find these two classes. @kylemh

Copy link
Member

Choose a reason for hiding this comment

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

you can apply them directly on L22 and L23

Copy link

cypress bot commented Dec 6, 2023

1 flaky test on run #4575 ↗︎

0 35 0 0 Flakiness 1

Details:

Replaced all the css into tailwind css on FontSection component
Project: operation_code Commit: 4143dce3fe
Status: Passed Duration: 03:44 💡
Started: Dec 12, 2023 3:32 PM Ended: Dec 12, 2023 3:35 PM
Flakiness  cypress/e2e/modal.spec.js • 1 flaky test • all tests

View Output Video

Test Artifacts
when the server responds successfully > closes the modal when the x button is clicked Screenshots Video

Review all test suite changes for PR #1784 ↗︎

@@ -18,7 +18,7 @@ function FontSection() {
};
return (
<li key={item}>
<div>
<div className="[&>p]:font-serif [&>h6]:font-serif">
Copy link
Member

Choose a reason for hiding this comment

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

If you do this, the font family will just always be sans-serif... for all font families...

Instead we have to differentiate between primary and secondary AND we have to try rendering the relevant font style. font-serif is meant to be a fallback.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I made certain changes,
let me know if that works


.primaryFontFamily div > h6,
.primaryFontFamily div > p {
font-family: var(--primaryFontFamily), sans-serif;
Copy link
Member

Choose a reason for hiding this comment

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

Nice job on the condition.

Do you see here how it's 2 values separated by a comma?

  1. var(--primaryFontFamily)
  2. sans-serif

That's what's missing.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

where to set that variable?

Copy link
Member

Choose a reason for hiding this comment

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

In the tailwind config

Copy link
Contributor Author

Choose a reason for hiding this comment

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

will it look like this ? ->
fontFamily:{
sans:{
primaryFontFamily:'"DIN Condensed Bold"'
}
}

Copy link
Member

@kylemh kylemh Dec 12, 2023

Choose a reason for hiding this comment

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

fontFamily: {
  primary: "DIN Condensed Bold"
},

and then you can use font-primary

Copy link
Contributor Author

Choose a reason for hiding this comment

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

got it

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done certain changes

Copy link

codeclimate bot commented Dec 12, 2023

Code Climate has analyzed commit 4143dce and detected 0 issues on this pull request.

The test coverage on the diff in this pull request is 100.0% (90% is the threshold).

This pull request will bring the total coverage in the repository to 75.6% (0.0% change).

View more on Code Climate.

@kylemh kylemh merged commit 9de6301 into OperationCode:main Dec 14, 2023
14 checks passed
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.

2 participants