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.

[LinearProgress][CircularProgress] Change from div to span

See original GitHub issue

So far, both [LinearProgress] and [CircularProgess] are made of <div />s.

That makes it hard to use inside of any text (e.g. Intractive Integration Button, which can naturally be placed inside of <p /> or <span />), because you will get Warning: validateDOMNesting(...) in that case.

I think that best solution would be to change <div />s in those components to <span />s with display: block. It would probably won’t event be considered breaking change, since nowhere in Docs is stated that those Components uses any particular HTML structure.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:16
  • Comments:14 (9 by maintainers)

github_iconTop GitHub Comments

8reactions
sarbogastcommented, Aug 25, 2018

I confirm the interest of this. Sometimes, you just want to display a small progress indicator instead of a text element that is loading, not just for a whole interface div.

5reactions
Mangattcommented, Aug 13, 2018

Sometimes it’s not possible to change parent structure, especially when you don’t have immediate control over it - predefined templates, contenteditable or when you let user create content via wysiwyg.

Read more comments on GitHub >

github_iconTop Results From Across the Web

[LinearProgress][CircularProgress] Change from div to span
I think that best solution would be to change <div /> s in those components to <span /> s with display: block ....
Read more >
MUI Progress Indicator center align horizontally - Stack Overflow
The solution below centres progress indicator without any hacky calculations that cause element to be offset: <div style={{display: 'flex', ...
Read more >
Progress - Bootstrap
Documentation and examples for using Bootstrap custom progress bars featuring support for stacked bars, animated backgrounds, and text labels.
Read more >
Circular, Linear progress React components - Material UI - MUI
The LinearProgress uses a transition on the CSS transform property to provide a smooth update between different values. The default transition duration is...
Read more >
Progress | Element Plus
Circular progress bar # ... You can specify type attribute to circle to use circular progress bar, and use width attribute to change...
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