From aba926f9e4f613156dea551a09b1edc978ac8599 Mon Sep 17 00:00:00 2001 From: MarkHoward Date: Fri, 23 Aug 2019 13:00:47 +1200 Subject: [PATCH 1/9] demo udates --- demo/index.html | 3 ++- src/index.ts | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/demo/index.html b/demo/index.html index ad1a3b9..84ab344 100644 --- a/demo/index.html +++ b/demo/index.html @@ -56,7 +56,8 @@

Basic scroll-to-top demo

- + + diff --git a/src/index.ts b/src/index.ts index cd30bcc..0868b46 100644 --- a/src/index.ts +++ b/src/index.ts @@ -57,7 +57,7 @@ export class ScrollToTop extends LitElement { opacity: 0.9; } - +
Date: Fri, 23 Aug 2019 14:21:07 +1200 Subject: [PATCH 2/9] Cypress testing updates --- cypress/integration/home_page_spec.js | 10 +++++++--- demo/index.html | 7 ++----- src/index.ts | 6 ++---- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/cypress/integration/home_page_spec.js b/cypress/integration/home_page_spec.js index 93e456d..9b20ff6 100644 --- a/cypress/integration/home_page_spec.js +++ b/cypress/integration/home_page_spec.js @@ -1,7 +1,11 @@ describe("The Home Page", function() { it("successfully loads", function() { - cy.visit("/").scrollTo('bottom'); - cy.pause(); - cy.get('#ScrollToTopWC').click(); + cy.visit("/").scrollTo("bottom", { duration: 1000 }); + + cy.contains("top").click(); + + cy.window().then($window => { + expect($window.scrollY).to.be.closeTo(0, 30); + }); }); }); diff --git a/demo/index.html b/demo/index.html index 84ab344..b584797 100644 --- a/demo/index.html +++ b/demo/index.html @@ -41,17 +41,14 @@ margin: 1rem; } - body, - html { - scroll-behavior: smooth; - } +
-

Basic scroll-to-top demo

+

Basic scroll-to-top demo

diff --git a/src/index.ts b/src/index.ts index 0868b46..bd691f5 100644 --- a/src/index.ts +++ b/src/index.ts @@ -57,7 +57,7 @@ export class ScrollToTop extends LitElement { opacity: 0.9; } - +
Date: Sun, 25 Aug 2019 20:54:22 +1200 Subject: [PATCH 3/9] Added keywords --- package.json | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/package.json b/package.json index 134f4e1..5ea75a1 100644 --- a/package.json +++ b/package.json @@ -24,6 +24,18 @@ "dependencies": { "lit-element": "^2.2.1" }, + "keywords": [ + "scroll", + "top", + "scrolltop", + "scroll to top", + "scroll top", + "scroll up", + "move to top", + "move top", + "scrollTo", + "smooth scroll" + ], "devDependencies": { "@pika/cli": "^0.2.0", "@pika/pack": "^0.5.0", From 1e415c0c79fa57f47917f5b4f3f261cb36be00c7 Mon Sep 17 00:00:00 2001 From: MarkHoward Date: Sun, 25 Aug 2019 21:04:37 +1200 Subject: [PATCH 4/9] package --- package.json | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index 5ea75a1..d8a7ace 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,9 @@ "browserslist": [ "Chrome > 70 " ], - "scripts": {}, + "scripts": { + "version": "npx @pika/pack" + }, "@pika/pack": { "pipeline": [ [ From 54fa8590b12bb9370ef6fb90e7ec0f0866850f99 Mon Sep 17 00:00:00 2001 From: MarkHoward Date: Sun, 25 Aug 2019 21:07:16 +1200 Subject: [PATCH 5/9] packge typo --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index d8a7ace..2398c37 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "scroll-to-top-wc", - "version": "0.3.6", + "version": "0.3.7", "description": "scroll page up", "main": "src/index.ts", "browserslist": [ @@ -12,7 +12,7 @@ "@pika/pack": { "pipeline": [ [ - "@pika/plugin-tsp-standard-pkg" + "@pika/plugin-ts-standard-pkg" ], [ "@pika/plugin-build-web" From d50435507fa3e8a1540187dcce001a1d9c0c19de Mon Sep 17 00:00:00 2001 From: MarkHoward Date: Sun, 25 Aug 2019 21:08:41 +1200 Subject: [PATCH 6/9] 0.3.8 --- package-lock.json | 2 +- package.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package-lock.json b/package-lock.json index f9ffc34..32ed65e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "scroll-to-top-wc", - "version": "0.3.6", + "version": "0.3.8", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 2398c37..ef1e958 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "scroll-to-top-wc", - "version": "0.3.7", + "version": "0.3.8", "description": "scroll page up", "main": "src/index.ts", "browserslist": [ From 9091899055c35d3d04964afa7ae5de1fc3369e4c Mon Sep 17 00:00:00 2001 From: MarkHoward Date: Mon, 26 Aug 2019 09:38:41 +1200 Subject: [PATCH 7/9] removed the polymer json file as no longer using Polymer --- polymer.json | 14 -------------- 1 file changed, 14 deletions(-) delete mode 100644 polymer.json diff --git a/polymer.json b/polymer.json deleted file mode 100644 index 712ffe8..0000000 --- a/polymer.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "npm": true, - "moduleResolution": "node", - "entrypoint": "./src/index.js", - "builds": [ - { - "name": "mybuild", - "bundle": false, - "js": { - "minify": true - } - } - ] -} From 369cd9f19d20c30a2a301ab95ca1316170aecf86 Mon Sep 17 00:00:00 2001 From: MarkHoward Date: Wed, 28 Aug 2019 10:12:08 +1200 Subject: [PATCH 8/9] Added the MIT license to package.json for npm --- package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/package.json b/package.json index ef1e958..720e1fc 100644 --- a/package.json +++ b/package.json @@ -3,6 +3,7 @@ "version": "0.3.8", "description": "scroll page up", "main": "src/index.ts", + "license": "MIT", "browserslist": [ "Chrome > 70 " ], From 93ef68ee1079b58f8d3c147bc860265f180efca5 Mon Sep 17 00:00:00 2001 From: MarkHoward Date: Wed, 28 Aug 2019 10:13:39 +1200 Subject: [PATCH 9/9] 0.3.9 --- package-lock.json | 2 +- package.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package-lock.json b/package-lock.json index 32ed65e..228c83a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "scroll-to-top-wc", - "version": "0.3.8", + "version": "0.3.9", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 720e1fc..8b78af6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "scroll-to-top-wc", - "version": "0.3.8", + "version": "0.3.9", "description": "scroll page up", "main": "src/index.ts", "license": "MIT",