Skip to content
This repository has been archived by the owner on Jan 13, 2025. It is now read-only.

chore(select): Remove default variant #3476

Merged
merged 19 commits into from
Sep 5, 2018

Conversation

williamernest
Copy link
Contributor

@williamernest williamernest commented Aug 30, 2018

fixes: #2899

@williamernest williamernest requested a review from acdvorak August 30, 2018 00:01
@mdc-web-bot
Copy link
Collaborator

All 349 screenshot tests passed for commit 31bfd09 vs. master! 💯🎉

@mdc-web-bot
Copy link
Collaborator

All 349 screenshot tests passed for commit fc5c80c vs. master! 💯🎉

@mdc-web-bot
Copy link
Collaborator

All 349 screenshot tests passed for commit 45e4af7 vs. master! 💯🎉

@codecov-io
Copy link

codecov-io commented Aug 30, 2018

Codecov Report

❗ No coverage uploaded for pull request base (master@1eb86cc). Click here to learn what that means.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff            @@
##             master    #3476   +/-   ##
=========================================
  Coverage          ?   98.41%           
=========================================
  Files             ?      120           
  Lines             ?     5033           
  Branches          ?      619           
=========================================
  Hits              ?     4953           
  Misses            ?       80           
  Partials          ?        0
Impacted Files Coverage Δ
packages/mdc-select/constants.js 100% <ø> (ø)
packages/mdc-select/index.js 96.42% <100%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1eb86cc...225a0c9. Read the comment docs.

@williamernest williamernest requested review from kfranqueiro and removed request for acdvorak September 5, 2018 14:52
Copy link
Contributor

@acdvorak acdvorak left a comment

Choose a reason for hiding this comment

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

LGTM! Just two minor questions

@include mdc-rtl-reflexive-position(left, 16px);

bottom: 12px;
line-height: 1.75rem;
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this related to any of our typography variables or mixins? Or just a component-specific value?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is required to get the notched outline to float to the correct position. This will be refactored in a follow up PR so that the notched outline requires no changes in the default version of text field and the select.

@@ -145,7 +145,7 @@ class MDCSelect extends MDCComponent {
this.outline_ = outlineFactory(outlineElement);
}

if (this.root_.classList.contains(cssClasses.BOX)) {
if (!this.root_.classList.contains(cssClasses.OUTLINED)) {
Copy link
Contributor

Choose a reason for hiding this comment

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

This seems like a change of behavior. Did outlined previously not have ripples?

Copy link
Contributor

Choose a reason for hiding this comment

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

Never mind... I missed the !.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The outlined variant does not have ripples. This code used to single out the box variant to add ripples, but since there is no longer a default variant this needs to exclude the outlined variant.

@@ -83,21 +83,6 @@ See [Importing the JS component](../../docs/importing-js.md) for more informatio

## Variants

### Select Box
Copy link
Contributor

Choose a reason for hiding this comment

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

Should we also remove the default style deprecation notice?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think we should leave the deprecation notice in so people see it if they come looking for why their default variant changes.

@@ -215,7 +199,7 @@ Mixin | Description
`mdc-select-focused-label-color($color)` | Customizes the label color of the select when focused.
`mdc-select-bottom-line-color($color)` | Customizes the color of the default bottom line of the select.
`mdc-select-focused-bottom-line-color($color)` | Customizes the color of the bottom line of the select when focused.
`mdc-select-corner-radius($radius)` | Customizes the corner radius of the box variant of the select.
`mdc-select-corner-radius($radius)` | Customizes the corner radius of the select.
Copy link
Contributor

Choose a reason for hiding this comment

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

Should we say "of the filled select variant" or something? Since there's a separate mixin for outlined...

will-change: opacity, transform, color;

// stylelint-disable-next-line plugin/selector-bem-pattern
.mdc-floating-label {
Copy link
Contributor

Choose a reason for hiding this comment

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

Should this be moved to the floating-label_ mixin you created? (Though that mixin is only seemingly invoked in one place)

@williamernest williamernest force-pushed the chore/select/remove-default-variant branch from 5020366 to 7e01f0e Compare September 5, 2018 17:41
@williamernest williamernest merged commit 92fb8b9 into master Sep 5, 2018
@williamernest williamernest deleted the chore/select/remove-default-variant branch September 5, 2018 23:12
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Deprecate and delete the non-box version of Select
6 participants