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

KAD-3056 tablet and mobile border radius styles fixed #521

Merged
merged 5 commits into from
Aug 12, 2024

Conversation

gilbert-hernandez
Copy link
Contributor

@gilbert-hernandez gilbert-hernandez commented Aug 1, 2024

🎫 #[Jira Ticket]
https://stellarwp.atlassian.net/browse/KAD-3056
...

Issue Info

  • Were you able to reproduce the issue?
  • Is the issue from the ticket solved? (If not, why?)

Checklist

  • I have performed a self-review.
  • No unrelated files are modified.
  • No debugging statements exist (Ex: console.log, error_log).
  • There are no warnings or notices in the wordpress error log.
  • Passes all tests (linting, acceptance, & unit)

Block specific checklist (where relevant)

  • Tested with an existing instance of this block .
  • Tested creating a new instance of this block.
  • Tested with Dynamic content & Elements.

Are there dependent changes in another repository?

  • No.
  • Yes. Please provide the link to the PR.

Copy link
Contributor

@mark-c-woodard mark-c-woodard left a comment

Choose a reason for hiding this comment

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

Frontend looks good.
For the backend you should use a "preview" variable to store the border radius that should be used for the current preview device. It's a pretty common pattern we use for responsive settings in the editor.
You'll actually see an example just below with previewHeight. So make a previewImageRadius variable to use in place of imageRadius instead of additional sections of device conditional output.

@gilbert-hernandez
Copy link
Contributor Author

@mark-c-woodard
I updated the backend, as you said. I created a previewImageRadius variable and used it instead of the tablet and mobile variables in the style.

@gilbert-hernandez
Copy link
Contributor Author

I also updated the frontend to use the imageRadiusUnit as well.

@oakesjosh oakesjosh merged commit 46930c3 into master Aug 12, 2024
20 checks passed
@oakesjosh oakesjosh deleted the bugfix/KAD-3056 branch August 12, 2024 20:53
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.

3 participants