There are 7 updates, 1 comment.
 
 
XWiki Platform / cid:jira-generated-image-avatar-b95e7fa8-09c7-49b3-9157-c9aa27c98ed3 XWIKI-25647 Closed

The list filter doesn't display a filter value set by the live data configuration when its options come only from a search URL

 
View issue   ยท   Add comment
 

7 updates

 
cid:jira-generated-image-avatar-60e351b7-8a95-4bd5-aca1-a2a8aee5fcf9 Changes by Marius Dumitru Florea on 18/Nov/26 09:18
 
Fix Version: 18.4.9
Fix Version: 18.10.0-rc-1
Documentation in Release Notes: N/A
Documentation: N/A
Resolution: Fixed
Tests: Unit
Status: Open Closed
 
 

1 comment

 
cid:jira-generated-image-avatar-60e351b7-8a95-4bd5-aca1-a2a8aee5fcf9 Marius Dumitru Florea on 18/Nov/26 09:17
 

Fixed in PR #7347 (commit 9373eef).

The cause was a regression from the switch to Tom Select (XWIKI-24088): Tom Select creates an option for the initial value of the input, but when the caller passes its own options (e.g. an empty list when the options come only from a search URL) they replace that option, so the initial value was lost. Selectize used to merge the two.

Changes in xwiki.selectize.js:

  • the initial value of a text input is saved before creating the Tom Select widget and selected again afterwards, loading the labels of the selected values, so a filter value set by the live data configuration is displayed again
  • the initial value is no longer split on the delimiter when multiple selection is disabled (e.g. "Smith, John")
  • a value that has no option is now selected without triggering a change event, even when creating options is disabled
  • added unit tests for the suggest widget covering initial values, option order and multiple selects