-
Notifications
You must be signed in to change notification settings - Fork 178
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
Implement form elements for the design panel #271
Conversation
I think we should discuss the use of material-ui instead of implement our own here. |
I agree. Let's give it a little time for us to review material libraries and material requirements. |
Hey @obetomuniz , to close this let's just address the review comments and to recap:
and to fully close #255 (probably using a separate PR since this one is getting big)
|
@obetomuniz @wassgha @ndev1991, some comments on the todo:
Not relevant for #255. #66 is separate issue all together.
Not relevant for #255. Just create the components themselves. Organizing the panels will come in several follow-up PR's. |
All (the pull request submitter and all commit authors) CLAs are signed, but one or more commits were authored or co-authored by someone other than the pull request submitter. We need to confirm that all authors are ok with their commits being contributed to this project. Please have them confirm that by leaving a comment that contains only Note to project maintainer: There may be cases where the author cannot leave a comment, or the comment is not properly detected as consent. In those cases, you can manually confirm consent of the commit author(s), and set the ℹ️ Googlers: Go here for more info. |
- Remove expand and boxed properties to promote wrap styling of core components - Refactor input.js and re-use it on color.js and numeric.js - Remove specific styles to promote wrap styling of core components
Hello, from what we brief in order to close this PR#271, I accomplished the following:
I'm now involved with the last one |
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.
Very clean and nice component library. Great stuff!
Hey @wassgha @swissspidy @barklund @ndev1991, given my research on the My initial suggestion is to use a Numeric Input side by side the Color Input instead of a plain percentage text label and allow the user to change that value in order to have the opacity representation of a given color. BTW, we can even retrieve #RRGGBBAA format, or as usual, RGBA. Let me know your thoughts and if there is any other workaround to support the alpha channel on it. function hexToRGBA(color, opacity) {
const R = parseInt(color.slice(-6, -4), 16);
const G = parseInt(color.slice(-4, -2), 16);
const B = parseInt(color.slice(-2), 16);
return `rgba(${R}, ${G}, ${B}, ${opacity / 100})`;
}
function hexToRRGGBBAA(color, opacity) {
const opacityRGBRef = Math.round((opacity / 100) * 255);
const hex = opacityRGBRef.toString(16);
return `#${color}${hex.padStart(2, "0").toUpperCase()}`;
}
hexToRGBA('000000', 80) // rgba(0, 0, 0, 0.8)
hexToRRGGBBAA('000000', 80) // #000000CC |
@googlebot I consent. |
@obetomuniz @ndev1991 remember to consent to Google CLA Bot (as you have contributed to a PR, you didn't originate) by simply typing |
@googlebot I consent. |
…design-panel * 'design-panel' of github.com:google/web-stories-wp: fix color on form button based on design
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.
Note that there are parallel PR-s for the functionality of the Design Panel parts which also do shuffling around the panels and adding missing functionality.
As long as the form elements all exist and are designed I'm happy to do all the refactoring and functionality fixes for the things that broke, in those PRs to get this merged faster and for having more smaller follow-up PRs instead. /cc @swissspidy
…design-panel * 'design-panel' of github.com:google/web-stories-wp: remove duplicated external dependencies section
In order to accomplish potential improvements in this PR, since the current state is stable and pretty advanced, I would recommend approve/merge it ASAP. It's blocking other PRs, and like other parts of the current version of the plugin, it will require on-demand improvements that we can deal with separately in additional PRs. |
We're merging as-is and following up in new PR's
Addresses #255
Changes
To-do
/cc @dvoytenko
See #255