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

Fix custom icons not loading #2256

Merged
merged 2 commits into from
Feb 8, 2022
Merged

Fix custom icons not loading #2256

merged 2 commits into from
Feb 8, 2022

Conversation

jlemay-godaddy
Copy link
Contributor

Description

Fix custom icons crashing the Icons block.
See: #2251

Types of changes

Bug fix

How has this been tested?

Manually tested. @olafleur we should find a way to cover custom icons in our tests :)

Checklist:

  • My code is tested
  • My code follows accessibility standards
  • My code has proper inline documentation
  • I've included any necessary tests
  • I've included developer documentation
  • I've added proper labels to this pull request

@cypress
Copy link

cypress bot commented Jan 28, 2022



Test summary

402 0 0 0


Run details

Project CoBlocks
Status Passed
Commit 7ea563d
Started Jan 31, 2022 4:45 PM
Ended Jan 31, 2022 4:50 PM
Duration 04:14 💡
OS Linux Debian - 11.1
Browser Multiple

View run in Cypress Dashboard ➡️


This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard

@godaddy-wordpress-bot
Copy link
Contributor

godaddy-wordpress-bot commented Jan 28, 2022

Performance Test Results:

index master fix-custom-icons change %
focus 117.71 111.88 -4.95%
inserterHover 36.23 38.28 5.66%
inserterOpen 121.3 122.93 1.34%
inserterSearch 62.21 79.87 28.39%
load 24186.8 24224.4 0.16%
maxFocus 141.53 137.22 -3.05%
maxInserterHover 43.88 51.44 17.23%
maxInserterOpen 530.01 479.65 -9.5%
maxInserterSearch 68.49 186.93 172.93%
maxType 78.24 74.51 -4.77%
minFocus 105.54 95.68 -9.34%
minInserterHover 29.6 31.44 6.22%
minInserterOpen 68.59 69.35 1.11%
minInserterSearch 51.78 55.5 7.18%
minType 37.72 37.67 -0.13%
type 46.9 46.24 -1.41%

Create directory
@godaddy-wordpress-bot
Copy link
Contributor

@godaddy-wordpress-bot
Copy link
Contributor

Code Coverage: 96.66% 💚

🗂 Folder Coverage
src/blocks/accordion/                          100.00% ✅
src/blocks/accordion/accordion-item/           100.00% ✅
src/blocks/alert/                              100.00% ✅
src/blocks/author/                             100.00% ✅
src/blocks/buttons/                            100.00% ✅
src/blocks/click-to-tweet/                     100.00% ✅
src/blocks/counter/                            100.00% ✅
src/blocks/dynamic-separator/                  100.00% ✅
src/blocks/events/                             100.00% ✅
src/blocks/events/event-item/                  100.00% ✅
src/blocks/faq/                                100.00% ✅
src/blocks/faq/faq-item/                       100.00% ✅
src/blocks/features/                           100.00% ✅
src/blocks/features/feature/                   100.00% ✅
src/blocks/food-and-drinks/                    100.00% ✅
src/blocks/food-and-drinks/food-item/          100.00% ✅
src/blocks/form/fields/checkbox/               100.00% ✅
src/blocks/form/fields/date/                   100.00% ✅
src/blocks/form/fields/hidden/                 100.00% ✅
src/blocks/form/fields/name/                   100.00% ✅
src/blocks/form/fields/phone/                  100.00% ✅
src/blocks/form/fields/radio/                  100.00% ✅
src/blocks/form/fields/select/                 100.00% ✅
src/blocks/form/fields/text/                   100.00% ✅
src/blocks/form/fields/textarea/               100.00% ✅
src/blocks/form/fields/website/                100.00% ✅
src/blocks/gallery-carousel/                    96.43% 💚
src/blocks/gallery-collage/                    100.00% ✅
src/blocks/gallery-masonry/                     79.77% 💛
src/blocks/gallery-offset/                     100.00% ✅
src/blocks/gallery-stacked/                    100.00% ✅
src/blocks/gif/                                100.00% ✅
src/blocks/gist/                               100.00% ✅
src/blocks/hero/                                92.56% 💚
src/blocks/highlight/                          100.00% ✅
src/blocks/logos/                              100.00% ✅
src/blocks/map/                                100.00% ✅
src/blocks/media-card/                         100.00% ✅
src/blocks/opentable/                          100.00% ✅
src/blocks/post-carousel/                      100.00% ✅
src/blocks/posts/                              100.00% ✅
src/blocks/pricing-table/                      100.00% ✅
src/blocks/pricing-table/pricing-table-item/   100.00% ✅
src/blocks/row/                                 94.43% 💚
src/blocks/row/column/                          88.54% 💚
src/blocks/services/                           100.00% ✅
src/blocks/services/service/                   100.00% ✅
src/blocks/shape-divider/                      100.00% ✅
src/blocks/share/                               81.25% 💚
src/blocks/social-profiles/                     79.64% 💛

From Circle CI build 43040

@olafleur-godaddy
Copy link
Member

I've added a custom icon in the WordPress installation on CircleCI. That was failing on master, but should pass on this branch :)

Copy link
Member

@olafleur-godaddy olafleur-godaddy left a comment

Choose a reason for hiding this comment

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

It does. Good job! :)

Copy link
Member

@AnthonyLedesma AnthonyLedesma left a comment

Choose a reason for hiding this comment

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

I am able to use custom icon without issue but I am not able to get the optional config json to work. I am fine if we need to change this feature and what we support but let's update the doc at the same time.

https://github.com/godaddy-wordpress/coblocks/blob/master/docs/hooks/icons-block.md#optional-configuration-file

@olafleur-godaddy olafleur-godaddy merged commit cb654d0 into master Feb 8, 2022
@olafleur-godaddy olafleur-godaddy deleted the fix-custom-icons branch February 8, 2022 17:39
@AnthonyLedesma AnthonyLedesma added this to the Next Release milestone Feb 8, 2022
@AnthonyLedesma AnthonyLedesma mentioned this pull request Feb 8, 2022
4 tasks
@olafleur-godaddy olafleur-godaddy modified the milestones: 2.21.6, Next Release Feb 22, 2022
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.

4 participants