netwerk-digitaal-erfgoed / LDWizard-ErfgoedWizard

LDWizard Application for converting Cultural Heritage data into Linked Data
https://ldwizard.netwerkdigitaalerfgoed.nl
2 stars 0 forks source link

dynamic column width #34

Open ivozandhuis opened 3 years ago

ivozandhuis commented 3 years ago

Could the column width change dynamically depending on the amount of characters in a cell?

GerwinBosch commented 3 years ago

Hello @ivozandhuis,

At the moment the table decides the width based on the header and its values. When the table is wider than its viewport. It'll try and break the values at logical places (spaces, dashes, and slashes). So in a way it already tries to dynamically assign width.

Am I correct in assuming that this is trying to limit the size of the table in total? In which case, there might some other solutions we might want to look at like ellipsing the values or rendering them differently

wouterbeek commented 3 years ago

@ivozandhuis I see a couple of options here: (1) word wrap, (2) character wrap, (3) ellipsis.

Is it ok if we apply ellipsis. A concrete example:

from:

<http://www.opengis.net/def/crs/EPSG/0/28992> POLYGON Z ((254059.737 593504.637 0,254059.227 593500 0,254059.216 593499.899 0,254058.242 593500 0,254057.914 593500.034 0,254057.893 593500 0,254057.807 593499.863 0,254052.074 593490.692 0,254052.182 593490.639 0,254058.138 593490.002 0,254057.932 593488.165 0,254074.487 593486.413 0,254075.981 593500 0,254076.265 593502.583 0,254076.561 593502.55 0,254076.594 593502.847 0,254059.737 593504.637 0))

to:

<http://www.opengis. … 9.737 593504.637 0))
ivozandhuis commented 3 years ago

Yes, that would be fine. How much characters do we choose? The general use case would be a column with a 'description'. IMO that would imply more characters than in your example to keep logical unit.