Skip to content

Commit

Permalink
Merge pull request #217 from BrightspaceUILabs/dependabot/npm_and_yar…
Browse files Browse the repository at this point in the history
…n/eslint-config-brightspace-0.24.0

chore(deps-dev): bump eslint-config-brightspace from 0.20.1 to 0.24.0
  • Loading branch information
ChrisLabattD2L authored Jul 11, 2023
2 parents 244fd91 + 6e32ce3 commit c6ee88d
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion attribute-picker.js
Original file line number Diff line number Diff line change
Expand Up @@ -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;
}
Expand Down
2 changes: 1 addition & 1 deletion multi-select-input.js
Original file line number Diff line number Diff line change
Expand Up @@ -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');

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -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",
Expand Down
8 changes: 4 additions & 4 deletions test/attribute-picker.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -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');
Expand All @@ -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);
Expand All @@ -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');
Expand All @@ -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);
Expand Down
4 changes: 2 additions & 2 deletions test/multi-select-list.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -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);
});
});
Expand Down

0 comments on commit c6ee88d

Please sign in to comment.