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.

[Feature] Independent height/width and %

See original GitHub issue

I’m submitting a … (check one with “x”)

[ ] bug report => search github for a similar issue or PR before submitting
[x] feature request
[ ] support request => Please do not submit support request here

Discussed in Gitter:

Current behavior Currently you can only set height/width together in view

Requested behavior It would be nice to have height and width as separate values, and if you leave off width it fills the parent like it does now.

It would also be nice if percentage % values were accepted.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:18
  • Comments:17 (5 by maintainers)

github_iconTop GitHub Comments

19reactions
marjan-georgievcommented, Jan 3, 2017

Let’s replace the view input with width and height inputs.

These properties would accept either a numeric value, a percentage, or left undefined:

  • Numeric value: [width]="500" - chart is 500 px wide
  • Percentage value: [width]="50%" - chart is 50% the width of its parent element
  • not specified, or undefined - chart fits to the parent element. This is equivalent to [width]="100%"
18reactions
dthulincommented, Feb 13, 2018

Yes, updates please? Whether or not I use ngx-charts on my website depends entirely upon the status of this issue, as I cannot get auto-sizing to function when wrapped in a div with set with height or width % values instead of px values.

Read more comments on GitHub >

github_iconTop Results From Across the Web

box-sizing - CSS: Cascading Style Sheets - MDN Web Docs
The box-sizing CSS property sets how the total width and height of an element is calculated.
Read more >
Defining css width/heights in device independent units?
I have a div and I'm trying to figure out how to get it to occupy the same amount of screen space regardless...
Read more >
Applied Deep Learning - Part 4: Convolutional Neural Networks
Pooling layers downsample each feature map independently, reducing the height and width, keeping the depth intact.
Read more >
Cropping width and height not setting independently
Cropping width and height not setting independently. I'm using Format Picture>Crop to crop a number of images to the same exact size, ...
Read more >
Media Queries Level 4 - W3C
4.1 Width: the width feature; 4.2 Height: the height feature ... Media queries are (almost) always independent of the contents of the ...
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