You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is probably some oversight on my part - it makes sense to do it the way you mentioned here.
I'd have to investigate if I have a map (value:apiName) somewhere to reference during the final save to server (or save to collection datatable array).
If not, the LOE is slightly higher but should be fixed.
Investigating this one now, here's a quick update:
The value of the cell is now held until the label can be derived from the getPicklistValues wire adapter, I check the delta and then assign the displayValue for you. However, this is causing some UX issues:
The load of the cell LWC is faster than the load of the getPicklistValues wire adapter, resulting in the datatable thinking there is no value - and thus - shrinking its horizontal width (auto columns width is detrimental here).
Then, the value gets loaded in, but the column width is still still shrunk (truncates the value).
The alternative here is (open to suggestions!):
Load the SOQL-ed picklist value in the picklist cell first (same as current state).
Add secondary function which runs only to change the display label if it is different than value.
Does not resize the columns after (so if your label is much longer than your value, you have to deal with it yourself)
Rationale here is I don't want to introduce additional "screen judder" by manipulating the column widths after initial paint (which is driven, partially, by the length of the picklist value).
I'll stash changes I have now and work on a patch that reflects the alternative listed here, it should provide a "good enough" UX.
Currenty, when a picklist field is displayed in a Datatable, it displays the API Name instead of the Value/Label.
In the example above, it displays 60 instead of 60 min (But it does display
60 min
in the picker)The text was updated successfully, but these errors were encountered: