diff --git a/RELEASE-NOTES.md b/RELEASE-NOTES.md index 7b0fb7568..20f020ae3 100644 --- a/RELEASE-NOTES.md +++ b/RELEASE-NOTES.md @@ -47,6 +47,7 @@ - **Container** - Fix issue with `fluid container` being `100% + gutter` at mobile resolution (causing overflow) - **Dropdown** - `forceSelection` no longer sets current value in search selection when current query is blank #2058 - **Dropdown** - Dropdown `@arrowSize` will now automatically reposition itself if size is changed with variable +- **Dropdown** - Fixed error where menu would disappear when entering spaced words using `allowAdditions: true` caused by value matching its own whitespace-trimed value #2853 - **Dropdown** - Dropdown arrow now has a variable `@dropdownArrowSize`, and is slightly smaller than previously - **Dropdown** - Fix `left menu` inside `ui menu` appearing horizontally #2778 - **Dropdown** - Fixed issue where "no results" message would be still be visible before search query on input focus #2824 diff --git a/src/definitions/modules/dropdown.js b/src/definitions/modules/dropdown.js index 967b3178c..2d5338c6f 100644 --- a/src/definitions/modules/dropdown.js +++ b/src/definitions/modules/dropdown.js @@ -724,7 +724,6 @@ $.fn.dropdown = function(parameters) { }) ; } - module.debug('Showing only matched items', searchTerm); module.remove.filteredItem(); $item @@ -2364,13 +2363,15 @@ $.fn.dropdown = function(parameters) { userSuggestion: function(value) { var $addition = $menu.children(selector.addition), - alreadyHasValue = module.get.item(value), + $existingItem = module.get.item(value), + alreadyHasValue = $existingItem && $existingItem.not(selector.addition).length, hasUserSuggestion = $addition.length > 0, html ; if(settings.useLabels && module.has.maxSelections()) { return; } + console.log(alreadyHasValue); if(value === '' || alreadyHasValue) { $addition.remove(); return;