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.

Buttons vs. Text in layout

See original GitHub issue

Reading https://ipywidgets.readthedocs.io/en/stable/examples/Widget Styling.html

Why do Buttons behave differently to Texts? I would expect to see two smaller text areas, and no scrollbar.

2019-02-15-091433

(Sorry, not much of a frontend guy)

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
jasongroutcommented, Feb 15, 2019

For some reason, the browser is clamping things to a minimum width. Try explicitly setting the min width, like this:

import ipywidgets as widgets

widgets.HBox([
    widgets.Text(layout={'min_width': '0'}),
    widgets.Text(layout={'min_width': '0'}),    
], layout={'width': '200px'})
0reactions
jasongroutcommented, Feb 15, 2019

Closing as resolved - feel free to comment below if needed, though!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Buttons & Links: The Basics - UX Office - Indiana University
Text buttons are generally used in cards, dialogs, and against images as they minimize distraction from the main content. Since text buttons ...
Read more >
Why Text Buttons Hurt Mobile Usability - UX Movement
The only difference between text buttons and text is color. This similarity makes text buttons harder to recognize, especially for color-blind ...
Read more >
When to Use Buttons and Links | Wireframing Academy
Buttons can be styled many different ways, but it is important to realize there is an area around the text of the button...
Read more >
Button Design: Types of UX Buttons and Best Practices
Text buttons are text labels that fall outside of a block of text. The text should describe the action that will occur if...
Read more >
Links vs. buttons. How you know you're looking at a… - Medium
According to good old best practice, underline links and solid state buttons communicate two different things: a button says that you are going ......
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