Skip to content
This repository was archived by the owner on Feb 11, 2023. It is now read-only.

Commit d69be80

Browse files
Bump prettier from 2.2.1 to 2.5.1 (#400)
* Bump prettier from 2.2.1 to 2.5.1 Bumps [prettier](https://github.com/prettier/prettier) from 2.2.1 to 2.5.1. - [Release notes](https://github.com/prettier/prettier/releases) - [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md) - [Commits](prettier/prettier@2.2.1...2.5.1) --- updated-dependencies: - dependency-name: prettier dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> * Fix formatting Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Mark <[email protected]>
1 parent f4dc050 commit d69be80

File tree

4 files changed

+19
-21
lines changed

4 files changed

+19
-21
lines changed

package-lock.json

Lines changed: 7 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
"coveralls": "^3.0.7",
6767
"dotenv": "^10.0.0",
6868
"eslint": "^7.16.0",
69-
"prettier": "^2.2.1",
69+
"prettier": "^2.5.1",
7070
"rollup": "^2.49.0",
7171
"rollup-plugin-babel": "^4.3.3",
7272
"rollup-plugin-serve": "^1.0.1",

tests/scroll-into-view-tests.ts

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ describe('scrollIntoView', function () {
88
let getDocumentStub: SinonStub;
99

1010
beforeEach(function () {
11-
getDocumentStub = sinon.stub(utils, 'getDocument').returns(({
11+
getDocumentStub = sinon.stub(utils, 'getDocument').returns({
1212
body: document.createElement('div'),
1313
documentElement: document.createElement('div'),
14-
} as unknown) as HTMLDocument);
14+
} as unknown as HTMLDocument);
1515
});
1616

1717
afterEach(function () {
@@ -70,10 +70,10 @@ describe('scrollIntoView', function () {
7070
fakeDocumentBody.appendChild(innerEl);
7171
fakeDocumentBody.appendChild(secondInnerEl);
7272
document.body.appendChild(fakeDocumentBody);
73-
getDocumentStub.returns(({
73+
getDocumentStub.returns({
7474
body: fakeDocumentBody,
7575
documentElement: fakeDocumentBody,
76-
} as unknown) as HTMLDocument);
76+
} as unknown as HTMLDocument);
7777
scrollIntoView(secondInnerEl);
7878
await aTimeout(1);
7979
expect(fakeDocumentBody.scrollTop).to.not.equal(innerElHeight);
@@ -100,10 +100,10 @@ describe('scrollIntoView', function () {
100100
innerEl.style.height = '200px';
101101
containerEl.appendChild(innerEl);
102102
document.body.appendChild(fakeDocumentBody);
103-
getDocumentStub.returns(({
103+
getDocumentStub.returns({
104104
body: fakeDocumentBody,
105105
documentElement: fakeDocumentBody,
106-
} as unknown) as HTMLDocument);
106+
} as unknown as HTMLDocument);
107107
assert.equal(innerEl.getBoundingClientRect().top, firstInnerElHeight); // make sure element is in right position
108108
scrollIntoView(innerEl);
109109
await aTimeout(1);
@@ -148,10 +148,10 @@ describe('scrollIntoView', function () {
148148
fakeDocumentBody.appendChild(innerEl);
149149
fakeDocumentBody.appendChild(secondInnerEl);
150150
document.body.appendChild(fakeDocumentBody);
151-
getDocumentStub.returns(({
151+
getDocumentStub.returns({
152152
body: fakeDocumentBody,
153153
documentElement: fakeDocumentBody,
154-
} as unknown) as HTMLDocument);
154+
} as unknown as HTMLDocument);
155155
scrollIntoView(secondInnerEl, {
156156
duration: 5000,
157157
} as ScrollIntoViewOptions);

tests/scroll-to-tests.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,7 @@ describe('scroll', function () {
8484
documentElement: docEl,
8585
body: bodyElement,
8686
};
87-
getDocumentStub.returns(
88-
(testDocumentElement as unknown) as HTMLDocument
89-
);
87+
getDocumentStub.returns(testDocumentElement as unknown as HTMLDocument);
9088
await scrollTo(docEl, { top: testTo });
9189
expect(docEl.scrollTop).to.equal(testTo);
9290
docEl.remove();
@@ -153,10 +151,10 @@ describe('scroll', function () {
153151
fakeBodyElement.appendChild(innerEl);
154152
document.body.appendChild(fakeBodyElement);
155153
const testTo = 120;
156-
getDocumentStub.returns(({
154+
getDocumentStub.returns({
157155
body: fakeBodyElement,
158156
documentElement: document.createElement('div'),
159-
} as unknown) as HTMLDocument);
157+
} as unknown as HTMLDocument);
160158
await scrollTo(fakeBodyElement, { top: testTo });
161159
await scrollTo(fakeBodyElement, { top: 0 });
162160
expect(fakeBodyElement.scrollTop).to.equal(0);

0 commit comments

Comments
 (0)