-
Notifications
You must be signed in to change notification settings - Fork 16
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
LegendCategories: support for custom markers #451
LegendCategories: support for custom markers #451
Conversation
This pull request has been linked to Shortcut Story #244132: Implement support for markers in Builder (I): Single icon. |
c1b2df7
to
f8e32bb
Compare
f8e32bb
to
174e53e
Compare
Pull Request Test Coverage Report for Build 2669328841
💛 - Coveralls |
maskRepeat: 'no-repeat', | ||
maskSize: 'cover', | ||
maskImage: `url(${icon})`, | ||
WebkitMaskRepeat: 'no-repeat', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this really required? MaterialUI is supposed to detect & add vendor prefixes (https://v4.mui.com/styles/advanced/#css-prefixes)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Didn't know about mui. This is not MUI, btw, this is generic react style
property ...
For sure prefixes are needed with vanilla CSS: https://jsfiddle.net/ongwmLrd/2/
Will check it...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@VictorVelarde
TLDR: It is needed ...
It's some other magic mechanism, which understands Firefox
vs Chrome:
difference and ... if we don't add Webkit*
, in Chrome only looks like this:
In other words, our "framework" understands which props are supported by which browser and emits only those into DOM.Too many frameworks for me
icon: { | ||
maskRepeat: 'no-repeat', | ||
maskSize: 'cover' | ||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@VictorVelarde
So update on story:
- yes, MUI adds proper prefixes, when used in
makeStyles
like above! - but something else (react/mui?) also requires Webkit prefixes ... and filters for inline
style={{...}}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great, I didn't notice those were inline styles and they were excluded. This way is better, thx!
9aaa4ee
to
8da4773
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGFM
Description
Shortcut: https://app.shortcut.com/cartoteam/story/244132/implement-support-for-markers-in-builder-i-single-icon
Add support for rendering of 'masked colored icons' in
LegendCategories
widget instead of classic circles.Rationale: This feature is needed in builder and it's simpler to implement here as we already use
LegendCategories
as a whole.Needed by: https://github.com/CartoDB/cloud-native/pull/8559
Type of change
(choose one and remove the others)
Acceptance
Basic checklist