Skip to content

Commit c891f81

Browse files
committed
update docs and changelog
1 parent b5a7ab0 commit c891f81

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

CHANGELOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
## [Unreleased]
22

33
### Added
4-
* DaisyUI 5 compatibility - active options now include both `active` and `menu-active` classes for compatibility with DaisyUI 3, 4, and 5.
5-
* Add `keep_options_on_select` toggle
4+
* DaisyUI 5 compatibility - active options now include both `active` and `menu-active` classes for compatibility with DaisyUI 3, 4, and 5
5+
* Add `keep_options_on_select` flag. By default, when not in `quick_tags` mode, input text field and list of selectable options are now cleared after selection. This flag suppresses this behavior
66
* Styling clear buttons entirely using JS
77

88
## 1.6.0 (2025-04-13)

lib/live_select.ex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ defmodule LiveSelect do
1818
clicking an option with the mouse.
1919
2020
Whenever an option is selected, `LiveSelect` will trigger a standard `phx-change` event in the form. See the "Examples" section
21-
below for details on how to handle the event. In `single` and `tags` mode, the input text and the list of selectable options is cleared after selection.
22-
To preserve both, use the `keep_options_on_select` flag in the assigns.
21+
below for details on how to handle the event. In `single` and `tags` mode, the content of the input text field and the list of selectable options are cleared on selection.
22+
To suppress this behavior, use the `keep_options_on_select` flag in the assigns.
2323
2424
In single mode, if the configuration option `allow_clear` is set, the user can manually clear the selection by clicking on the `x` button on the input field.
2525
In tags mode, single tags can be removed by clicking on them.
@@ -416,7 +416,7 @@ defmodule LiveSelect do
416416

417417
attr :keep_options_on_select, :boolean,
418418
doc:
419-
~s(if `true`, when in single or tags mode, the current set of options and the input text is preserved upon selection)
419+
~s(if `true`, the current list of selectable options and the content of the input text field are preserved upon selection)
420420

421421
attr :value, :any, doc: "used to manually set a selection - overrides any values from the form.
422422
Must be a single element in `:single` mode, or a list of elements in `:tags` mode."

0 commit comments

Comments
 (0)