question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

MDCSelect wrong setStyle width

See original GitHub issue

What MDC-Web Version are you using?

material-components-web@0.14.0

What browser(s) is this bug affecting?

Only tested chrome and firefox on GNOME

What OS are you using?

Ubuntu Gnome 17.04

What are the steps to reproduce the bug?

  • MDCSelect.attachTo(element)
  • done.

What is the expected behavior?

mdc-select width should be correct

What is the actual behavior?

returns short values.

Any other information you believe would be useful?

When not yet attaching an instance, the element looks good. Once initialized, the selected text cannot be seen.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:1
  • Comments:9 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
RobertSmitscommented, Dec 4, 2017

Do you do somthing like

* {
  box-sizing: border-box;
}

'cause then that’s your problem. The width is calculated as content-box

0reactions
abhiomkarcommented, Sep 17, 2019

Closing this as obsolete.

Read more comments on GitHub >

github_iconTop Results From Across the Web

@material/select - npm
MDC Select provides Material Design single-option select menus. It functions analogously to the browser's native <select> element, ...
Read more >
Styling mat-select in Angular Material - css - Stack Overflow
The width of the panel is always equal to the width of the select element. Sometimes In options You have too long strings...
Read more >
@material/floating-label | Yarn - Package Manager
MDCLinearProgressAdapter method getBuffer , getPrimaryBar , setStyle removed. ... root of mdc-select is now an inline-block element, use custom width class ...
Read more >
Select Menus - Material Design
NOTE: The menu width matches the width of the select by default. To set menu to its natural width, remove mdc-menu-surface--fullwidth from the...
Read more >
https://raw.githubusercontent.com/material-compone...
The mixin would request `font-size`/`font-weight`/`letter-spacing` from the `$theme` map (which expects ... **select:** Added theme mixins to MDC select ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found