-
Notifications
You must be signed in to change notification settings - Fork 2.7k
[MM-28199] Dropdown Input Common Component #6543
Conversation
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.
LGTM
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.
Hey @devinbinnie, this is looking good.
I believe we called this out before, but the focused state stroke is supposed to be on the inside of the input box, not the outside. I thought we resolved this with the text input components, but I'm seeing it again here (and on the inputs in the Getting Started screen.
It might be hard to see, but it does cause the border radius to look larger and does cause the actual size of the input box to be larger in the focus state.
Given my little expertise with React, I think @ali-farooq0 is better suited to give you a better review here |
As mentioned in our chat @devinbinnie, I'm now seeing a shift in the other direction when I focus |
/update-branch |
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.
Thanks @devinbinnie! Looks great
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.
Nice work @devinbinnie!
components/dropdown_input.scss
Outdated
|
||
.DropdownInput__option.focused > div { | ||
background-color: rgba(var(--center-channel-color-rgb), 0.08); | ||
} |
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.
nit: empty line
components/dropdown_input.tsx
Outdated
} | ||
}; | ||
|
||
let inputClass = className ? `Input ${className}` : 'Input'; |
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.
Would it be better to use pkg Classnames here? might help inline these as opposed to using the ternary operator.
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.
Yeah, this was pulled from CWS where I don't think we're using this. Should be a quick refactor.
/update-branch |
@@ -142,8 +145,18 @@ const BillingSubscriptions: React.FC<Props> = () => { | |||
className='BillingSubscriptions__topWrapper' | |||
style={{marginTop: '20px'}} | |||
> | |||
<div style={{border: '1px solid #000', width: '568px'}}> | |||
<div style={{border: '1px solid #000', width: '568px', padding: '8px', backgroundColor: '#fff'}}> |
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.
Are you planning on moving inline styles (these and others) out to a css module or global styles at some point?
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.
These are temporary just so I can get an idea of the layout.
All of these in-line styles will be going away and replaced with actual components or div
s with classes attached.
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.
LGTM, again with the understanding that these components will be iterated on as part of the upcoming common components initiative.
@devinbinnie, I chatted briefly with @matthewbirtch and we were thinking that we should have the mouse cursor change to show the interaction hand when mousing over the input field and dropdown options.
Test server destroyed |
1 similar comment
Test server destroyed |
…o MM-20462 * 'master' of github.com:Tak-Iwamoto/mattermost-webapp: (23 commits) [MM-25553] favicon added for unread messages without mention (mattermost#6431) fix intermittent failing tests at common commands (mattermost#6606) [MM-28260] Automate backlogs - Integrations > Slash Commands (mattermost#6429) [MM-27207] e2e archived channels I (4) (mattermost#6511) MM-24813 Add e2e tests for archive post menu options (mattermost#6571) fix MM-T1467 (mattermost#6588) MM-23345 - MM-T187 Inline markdown images open preview window (mattermost#6455) [Mm-27817] e2e add user to gm (mattermost#6278) [MM-28199] Dropdown Input Common Component (mattermost#6543) [MM-28783] migrate string refs in edit post modal (mattermost#6560) MM-24811 Archive channels should not have options to manage users (mattermost#6570) MM-28263: Cypress/E2E: Automate backlogs - Messaging > Pinned Posts part 2 (mattermost#6519) Cypress/E2E: Fix MM-T1462 accessibility for incoming message (mattermost#6589) Added legal text to upgrade button, and showing again the Edition section in team edition (mattermost#6470) add uiClickPostDropdownMenu (mattermost#6581) Fix nested a tags in Marketplace labels (mattermost#6520) [MM-27277] Enable stream mode for file uploads (mattermost#6568) move cypress plugin api (mattermost#6496) [MM-28361] User limit reached and overage banners for Mattermost Cloud (mattermost#6548) MM-28409 Add e2e for testing archive channel header (mattermost#6522) ...
@devinbinnie just a reminder to cherry-pick this to |
@devinbinnie Ignore my comment above, this is already in |
* WIP * [MM-28199] Dropdown Input Common Component * Remove commented code * Inset focus borders * More CSS fixes * Refactor to use classnames * Blank line * Added cursor:pointer for the input and menu Co-authored-by: Mattermod <[email protected]>
* WIP * [MM-28199] Dropdown Input Common Component * Remove commented code * Inset focus borders * More CSS fixes * Refactor to use classnames * Blank line * Added cursor:pointer for the input and menu Co-authored-by: Mattermod <[email protected]>
Summary
Dropdown Input using
react-select
, needed for Cloud Billing.Demo in System Console > Biling > Subscription
Ticket Link
https://mattermost.atlassian.net/browse/MM-28199