opensearch-project / oui

OpenSearch UI Framework
Apache License 2.0
31 stars 65 forks source link

[BUG] Polygon. Icon bug #1068

Open canascar opened 9 months ago

canascar commented 9 months ago

Describe the bug

Current Polygon icon SVG renders incorrectly.

To Reproduce Steps to reproduce the behavior: https://oui.opensearch.org/1.3/#/display/icons (Look for Polygon

Expected behavior

Items are filled when they should be empty.

Screenshots Current Incorrect:

Screenshot 2023-10-09 at 9 14 58 AM

Should render correctly like below:

Screenshot 2023-10-09 at 9 19 34 AM

Replace with SVG below polygon.zip

willie-hung commented 9 months ago

Hi @joshuarrrr @BSFishy I would like to work on this issue. Thanks!

canascar commented 8 months ago

Sorry all - reopening this bug as there is a sizing issue on the icon. Here's the corrected version: polygon.zip @joshuarrrr, @BSFishy

willie-hung commented 8 months ago

Hi @canascar, I've updated the SVG file in my local environment. However, the extra attributesclip-rule="evenodd" fill="#000" fill-rule="evenodd" is causing errors when updating snapshots. Should we adjust the snapshot testing tool to accommodate this single file or is there any workaround to update the snapshots.

BSFishy commented 8 months ago

I've updated the SVG file in my local environment. However, the extra propertiesclip-rule="evenodd" fill="#000" fill-rule="evenodd" is causing errors when updating snapshots. Should we adjust the snapshot testing tool to accommodate this single file or is there any workaround to update the snapshots.

I know for a fact the fill attribute should be removed. I think one of clip-rule or fill-rule can be removed too, but not sure. Test each one out, making sure it doesn't affect how the SVG looks, then I would recommend trying to update the snapshots again

willie-hung commented 8 months ago

Thanks @BSFishy! Just figure out the problem, when I changed the attributes from fill-rule to fillRule, the snapshot got updated 🤯. Additionally, I've removed any unnecessary attributes.

canascar commented 8 months ago

Thank you for working on this @Willie-The-Lord - please let me know if there are any other existing issues.