File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -24,7 +24,7 @@ export class StableBeamFilterModel extends SelectionModel {
2424 */
2525 constructor ( value = false ) {
2626 super ( { availableOptions : [ { value : true } , { value : false } ] ,
27- defaultSelection : [ { value : value } ] ,
27+ defaultSelection : [ { value } ] ,
2828 multiple : false ,
2929 allowEmpty : false } ) ;
3030 }
@@ -52,7 +52,15 @@ export class StableBeamFilterModel extends SelectionModel {
5252 * Get normalized selected option
5353 */
5454 get normalized ( ) {
55- return this . selected [ 0 ] ;
55+ return this . current ;
56+ }
57+
58+ /**
59+ * Overrides SelectionModel.isEmpty to respect the fact that stable beam filter cannot be empty.
60+ * @returns {boolean } true if the current value of the filter is false.
61+ */
62+ get isEmpty ( ) {
63+ return this . current === false ;
5664 }
5765
5866 /**
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ import { h } from '/js/src/index.js';
2020 */
2121
2222/**
23- * @typedef RadioButtonConfig - configration object for radioButton.
23+ * @typedef RadioButtonConfig - configuration object for radioButton.
2424 *
2525 * @property {string } label - label to be displayed to the user for radio button
2626 * @property {boolean } isChecked - is radio button selected or not
You can’t perform that action at this time.
0 commit comments