angular-ui/ui-grid

minWidth does not work with percent values

Open

#4.912 geöffnet am 29. Dez. 2015

Auf GitHub ansehen
 (1 Kommentar) (0 Reaktionen) (1 zugewiesene Person)JavaScript (2.496 Forks)batch import
good first issue

Repository-Metriken

Stars
 (5.395 Stars)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

When entering the minWidth value of a given column, if the value is a percent, the grid will not render.

STEPS TO DUPLICATE

  1. Create a grid with columns (be sure minWidth is a property in at least one of them)
  2. Set the minWidth property to a percent value (must be a string value, i.e. '10%' and not 10%)
  3. Assuming everything else was done correctly, the grid will still not render (to verify this was done right, change the percent value to a number; if the grid renders properly in this instance, you presumably did everything else right).

Below is a link to a plunkr I made to demonstrate this (I basically took the tutorial plunkr from lesson 204 from the tutorial and changed the minWidth to 10% for the first column in app.js)

http://plnkr.co/edit/9kjMpGNtWKTAEbi1bOCe?p=preview

Analyzing the results with firebug, the following message came back in the console.

Error: Cannot parse column minWidth '10%' for column named 'name'

Contributor Guide