@schukai/monster 3.67.0 → 3.68.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -78,11 +78,9 @@ class ToggleButton extends CallButton {
78
78
  * @property {string} templates.main Main template
79
79
  */
80
80
  get defaults() {
81
- const obj = Object.assign({}, super.defaults, {
81
+ return Object.assign({}, super.defaults, {
82
82
  call: "toggle",
83
83
  });
84
-
85
- return obj;
86
84
  }
87
85
 
88
86
  /**
@@ -91,6 +91,8 @@ describe('ToggleSwitch', function () {
91
91
  it('toggle to on', function () {
92
92
 
93
93
  const toggleSwitch = document.createElement('monster-toggle-switch');
94
+ toggleSwitch.setOption('actions.on', 'true');
95
+ toggleSwitch.setOption('actions.off', 'false');
94
96
 
95
97
  expect(toggleSwitch.value).is.equal('off');
96
98
  expect(toggleSwitch.state).is.equal('off');