-
Notifications
You must be signed in to change notification settings - Fork 617
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
v11.0.x #1166
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This was referenced Aug 6, 2024
Closed
Closed
This comment was marked as outdated.
This comment was marked as outdated.
This was
linked to
issues
Aug 6, 2024
Closed
This was referenced Aug 22, 2024
This was referenced Aug 22, 2024
This was referenced Aug 22, 2024
This was referenced Aug 22, 2024
This was referenced Aug 22, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
⚠ BREAKING CHANGES
allowHtml
now defaults to false.choices.js
, ~19.9KB), or "fuse basic" (choices.search-basic.js
~18.8KB) or "prefix filter" (choices.search-filter.js
~14.6KB) based on how much Fuse.js is included.'
characters for display.addItemText
/uniqueItemText
/customAddItemText
are now called with thevalue
argument already escaped.Choice
/Group
/Item
typescript classes have been renamed, and aliases left as required.select-one
andselect-multiple
, the placeholder value is pulled fromconfig.placeholderValue="..."
or<select data-placeholder="...">
before attempting to extract a placeholder from the options list. #912 #567 #843.d.ts.map
are no longer generated and various.test.d.ts
files are no longer generatedchoice
event firing.choice
event now occurs after theaddItem
evententer
key now consistently opens/closes the dropdown instead of the behavior varying depending on backing element or internal state of the highlighted choicesetChoiceByValue
/setChoices
/setValue
now throw an error if the Choices instance was not initialized or multiple choices instances where initialized on the same element. Prevents bad internal states from triggering unexpected errors #1129Features
closeDropdownOnSelect
option, controls how the dropdown is close after selection is made. #636 #973 #1012callbackOnCreateTemplates
callback must be used. #861config.classNames
now accept arrays to support multiple classes. #1121 #1074 #907 #832singleModeForMultiSelect
feature to treat aselect-single
as if it was aselect-multiple
with a max item count of1
, and still auto-close the dropdown and swap the active item on selection.Remove item text
can be localized.allowHtmlUserInput
.data-labelclass
/data-label-description
from<option>
HTML to drive adding a per-choice CSS label and description text whenallowHtml: false
.removeItemButtonAlignLeft
option, to control if the remove item button is at the start or the end of the item.removeChoice
method. Removes the choice from thechoices.js
object and any backing<option>
HTML elementrefresh
method. Reloads choices from the backing<select>
s options.escapeForTemplate
function is passed to the 2nd method of thecallbackOnCreateTemplates
callback.allowHtml
is false, default templates now render escaped html toinnerHtml
writing toinnerText
.innerText
is quirky and slower than escaped html intoinnerHtml
searchResultLimit
can be set to-1
for no limit of search results to display.Bug Fixes
fuse.js
which is just additional whitespace to the existing search term<select>
element. #1025search_term
element to appear in form submit data. #1049data-custom-properties
attribute did not serialize to created elements as a json blob as expected. #840 #1155 #543clearInput
function did not clear the last search.addItemFilter
would allow empty strings as input to be added for items.aria-label
for placeholders was set to the stringnull
searchEnable
flag was not respected forselect-multiple
#1042[aria-*]
attribute handling for better lighthouse accessibility scores #1169<fieldset disabled>
#1132silent
option does not silence warnings about unknown options #1119fuseOptions.sortFn
was effectively ignored #1106select-one
placeholder could ignore the non-option placeholder configurationFix the page scrolls when you press 'space' on a single select input #1103
Chore
fetch()
from breaking the rest of the examples_render
loop to avoid duplicating has-changed checkswebpack
torollup
, and provideesm
/cjs
/umd
bundles by default. Enables tree shaking! ~3kb dropped from theumd
bundle (aka compatible with the previous produced webpack bundle)mocha
tovitest
as the test running framework.puppeteer
/selenium
/cypress
toplaywright
as the end-to-end test running framework.@typescript-eslint/explicit-function-return-type
eslint ruledeepMerge
dependency.Tests:
[x] selenium (macos-latest, firefox)[x] selenium (windows-latest, edge)[x] selenium (windows-latest, firefox)[x] selenium (windows-latest, chrome)[x] puppeteerplaywright end-to-end tests:
playwright e2e test run against
choices.js
andchoices.min.js
bundles. Extending to support different bundles is easy.playwright supports the following browsers:
playwright supports the following OS's: