diff --git a/attribute-picker.js b/attribute-picker.js index 5f7e670..e5bbe24 100644 --- a/attribute-picker.js +++ b/attribute-picker.js @@ -430,7 +430,7 @@ class AttributePicker extends RtlMixin(Localizer(LitElement)) { if (this._dropdownIndex >= 0 && this._dropdownIndex < list.length) { this.addAttribute(list[this._dropdownIndex].text); } else if (this.allowFreeform) { - const trimmedAttribute = this._text.trim(); + const trimmedAttribute = this._text.trim(); if (trimmedAttribute.length === 0) { return; } diff --git a/multi-select-input.js b/multi-select-input.js index 479c545..5984d4f 100644 --- a/multi-select-input.js +++ b/multi-select-input.js @@ -43,7 +43,7 @@ class D2LMultiSelectInput extends PolymerElement { addItem(text, ctx = this) { const item = document.createElement('d2l-labs-multi-select-list-item'); - item.setAttribute('text', text); + item.setAttribute('text', text); item.setAttribute('deletable', true); item.setAttribute('role', 'listitem'); diff --git a/package.json b/package.json index 8866303..07109d8 100644 --- a/package.json +++ b/package.json @@ -40,7 +40,7 @@ "@web/dev-server": "^0.2.5", "@web/test-runner": "^0.16", "eslint": "^8", - "eslint-config-brightspace": "^0.20", + "eslint-config-brightspace": "^0.24", "lit-analyzer": "^1", "messageformat-validator": "^2.4.1", "sinon": "^15", diff --git a/test/attribute-picker.test.js b/test/attribute-picker.test.js index 50ae751..22a687e 100644 --- a/test/attribute-picker.test.js +++ b/test/attribute-picker.test.js @@ -309,7 +309,7 @@ describe('attribute-picker', () => { await el.updateComplete; //Confirm the item has been deleted, and the second element is now focused - let expectedAttributeList = ['one', 'two']; + let expectedAttributeList = ['one', 'two']; let dropdownElements = el.shadowRoot.querySelectorAll('.d2l-attribute-picker-attribute'); expect(evaluateListValues(expectedAttributeList, dropdownElements)).to.equal(true); focusElement = el.shadowRoot.querySelector(':focus'); @@ -320,7 +320,7 @@ describe('attribute-picker', () => { focusElement.dispatchEvent(new KeyboardEvent('keydown', { key: 'Backspace', keyCode: 8, bubbles: true })); await el.updateComplete; - expectedAttributeList = ['two']; + expectedAttributeList = ['two']; dropdownElements = el.shadowRoot.querySelectorAll('.d2l-attribute-picker-attribute'); expect(dropdownElements.length).equal(1); expect(evaluateListValues(expectedAttributeList, dropdownElements)).to.equal(true); @@ -340,7 +340,7 @@ describe('attribute-picker', () => { await el.updateComplete; //Confirm the item has been deleted, and the second element is now focused - let expectedAttributeList = ['one', 'two']; + let expectedAttributeList = ['one', 'two']; let dropdownElements = el.shadowRoot.querySelectorAll('.d2l-attribute-picker-attribute'); expect(evaluateListValues(expectedAttributeList, dropdownElements)).to.equal(true); focusElement = el.shadowRoot.querySelector(':focus'); @@ -351,7 +351,7 @@ describe('attribute-picker', () => { focusElement.dispatchEvent(new KeyboardEvent('keydown', { key: 'Delete', keyCode: 46, bubbles: true })); await el.updateComplete; - expectedAttributeList = ['two']; + expectedAttributeList = ['two']; dropdownElements = el.shadowRoot.querySelectorAll('.d2l-attribute-picker-attribute'); expect(dropdownElements.length).equal(1); expect(evaluateListValues(expectedAttributeList, dropdownElements)).to.equal(true); diff --git a/test/multi-select-list.test.js b/test/multi-select-list.test.js index 3f91cf8..e561623 100644 --- a/test/multi-select-list.test.js +++ b/test/multi-select-list.test.js @@ -114,11 +114,11 @@ describe('multi-select-list', () => { await testDeleteAndFocus(item0, item1, 'Backspace', _keyCodes.BACKSPACE); }); - it('should delete the item when Delete is pressed and switch focus to the next item', async() => { + it('should delete the item when Delete is pressed and switch focus to the next item', async() => { await testDeleteAndFocus(item1, item2, 'Delete', _keyCodes.DELETE); }); - it('should delete the item when Delete is pressed and switch focus to the previous item when it is the last item', async() => { + it('should delete the item when Delete is pressed and switch focus to the previous item when it is the last item', async() => { await testDeleteAndFocus(item2, item1, 'Delete', _keyCodes.DELETE); }); });