Hi,
Is there a reason (and a solution) for the last column of a Dashboard table (the right-most column) to be too wide when that table gets expanded?
Instead of distributing the width across columns, it is the last one that gets wider.
Solved! Go to Solution.
What you are experiencing regarding the last column being to wide mainly occurs when the dashboard consists of a table element that takes up the full width of the page.
If we were to add other dashboard elements that reduce the overall table container's width, we can make the Fit to data option actually fit better.
The use-case for having a table take up the whole page width may be more feasible in a mobile view.
ArcGIS Dashboards, as of 07/30/205 provides two options in the UI config:
Fit to element width:
Fit to data
The ArcGIS Assistant json config has a tableSettings > layout key/property.
Fit to element width there is written as fit-columns.
-Its the same as completely removing the layout key from the json.
Fit to data there is written as fit-data-stretch
There are other options available that you could experiment with, and see if it fits your data better:
fit-data-table
fit-data-fill
fit-data
We can reference these other options looking at another software's (Tabulator) docs:
https://tabulator.info/examples/6.3#fittodata
I had the problem on mobile dashboard with fit to data. It worked fine for the first category selected. Any change in filtering the column width stayed the same and characters were cut off.
The solution.
Open the dashboard in Arcgis Assistant
Find the widget you are trying to fix, in my case a table in a mobile view, then find the columnSettings parameter. For the column header title add [U+200E] multiple times
This effectively adds three hidden characters on either side of the title, forcing the column width.
The only issue is if you make a change to the widget and save it you will have to repeat the process., so get your widget functional first.
What you are experiencing regarding the last column being to wide mainly occurs when the dashboard consists of a table element that takes up the full width of the page.
If we were to add other dashboard elements that reduce the overall table container's width, we can make the Fit to data option actually fit better.
The use-case for having a table take up the whole page width may be more feasible in a mobile view.
ArcGIS Dashboards, as of 07/30/205 provides two options in the UI config:
Fit to element width:
Fit to data
The ArcGIS Assistant json config has a tableSettings > layout key/property.
Fit to element width there is written as fit-columns.
-Its the same as completely removing the layout key from the json.
Fit to data there is written as fit-data-stretch
There are other options available that you could experiment with, and see if it fits your data better:
fit-data-table
fit-data-fill
fit-data
We can reference these other options looking at another software's (Tabulator) docs:
https://tabulator.info/examples/6.3#fittodata
This is what the Fit to element width in UI option looks like with data center-aligned:
Here is the Fit to Data option with dummy elements to the left and right (allows resizing the table width), values left-aligned: