Skip to content

Commit

Permalink
Merge pull request #45 from kimulaco/alpha
Browse files Browse the repository at this point in the history
Release v2.2.5
  • Loading branch information
kimulaco committed Sep 23, 2020
2 parents bcab7b2 + da3491a commit 8245355
Show file tree
Hide file tree
Showing 12 changed files with 30 additions and 23 deletions.
1 change: 0 additions & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ on:
push:
branches:
- master
- develop
pull_request:
branches:
- "*"
Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
12.14.0
12.18.4
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Change Log

## [v2.2.5] 2020-09-23

- fix: change callback arg to optional #42
- update dependency
- Bump yargs-parser from 18.1.0 to 18.1.3 #44
- Bump lodash from 4.17.15 to 4.17.19 #43
- Bump acorn from 6.3.0 to 6.4.1 #41

## [v2.2.4] 2020-03-15

- Update devDependencies
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ npm install --save vanilla-smoothie
You can also use CDN. Suitable for creating small websites and samples.

```html
<script src="https://cdn.jsdelivr.net/npm/vanilla-smoothie@2.2.4/dist/vanilla-smoothie.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/vanilla-smoothie@2.2.5/dist/vanilla-smoothie.min.js"></script>
```

## Use
Expand Down
2 changes: 1 addition & 1 deletion dist/vanilla-smoothie.d.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
declare type VanillaSmoothieTarget = string | number;
declare type VanillaSmoothieCallbak = () => void;
declare type VanillaSmoothieCallbak = () => void | undefined;
interface VanillaSmoothieOption {
element?: HTMLElement;
easing?: string;
Expand Down
2 changes: 1 addition & 1 deletion dist/vanilla-smoothie.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* vanilla-smoothie.js v2.2.4
* vanilla-smoothie.js v2.2.5
* https://kimulaco.github.io/vanilla-smoothie/
* Copyright (c) 2020 kimulaco
* This software is released under the MIT License.
Expand Down
2 changes: 1 addition & 1 deletion dist/vanilla-smoothie.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ <h3 id="nodejs">Node.js</h3>
<pre><code class="language-shell">npm install --save vanilla-smoothie</code></pre>
<h3 id="cdn">CDN</h3>
<p>You can also use CDN. Suitable for creating small websites and samples.</p>
<pre><code class="language-html">&lt;script src=&quot;https://cdn.jsdelivr.net/npm/vanilla-smoothie@2.2.4/dist/vanilla-smoothie.min.js&quot;&gt;&lt;/script&gt;</code></pre>
<pre><code class="language-html">&lt;script src=&quot;https://cdn.jsdelivr.net/npm/vanilla-smoothie@2.2.5/dist/vanilla-smoothie.min.js&quot;&gt;&lt;/script&gt;</code></pre>
<h2 id="use">Use</h2>
<p>You can achieve smooth scroll with a simple and intuitive way of writing.</p>
<p>In addition, you can write any way you like, such as Callback or Promise.</p>
Expand Down
2 changes: 1 addition & 1 deletion docs/js/vanilla-smoothie.d.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
declare type VanillaSmoothieTarget = string | number;
declare type VanillaSmoothieCallbak = () => void;
declare type VanillaSmoothieCallbak = () => void | undefined;
interface VanillaSmoothieOption {
element?: HTMLElement;
easing?: string;
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vanilla-smoothie",
"version": "2.2.4",
"version": "2.2.5",
"description": "A minimal smooth scroll library based on vanilla JavaScript.",
"author": "kimulaco",
"license": "MIT",
Expand Down
10 changes: 5 additions & 5 deletions src/ts/vanilla-smoothie.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import easing from './easing'
import { animation } from './animation'

type VanillaSmoothieTarget = string | number
type VanillaSmoothieCallbak = () => void
type VanillaSmoothieCallbak = () => void | undefined

interface VanillaSmoothieOption {
element?: HTMLElement
Expand Down Expand Up @@ -66,7 +66,7 @@ class VanillaSmoothie {
scrollTo (
target: VanillaSmoothieTarget,
option: VanillaSmoothieOption = {},
callback: VanillaSmoothieCallbak
callback?: VanillaSmoothieCallbak | undefined
): Promise<void> {
const history = window.history && window.history.pushState ?
window.history : null
Expand Down Expand Up @@ -116,14 +116,14 @@ class VanillaSmoothie {

scrollTop (
option: VanillaSmoothieOption,
callback: VanillaSmoothieCallbak
callback?: VanillaSmoothieCallbak
): Promise<void> {
return this.scrollTo(0, option, callback)
}

scrollBottom (
option: VanillaSmoothieOption,
callback: VanillaSmoothieCallbak
callback?: VanillaSmoothieCallbak
): Promise<void> {
return this.scrollTo(this.getScrollBottomOffset(), option, callback)
}
Expand All @@ -135,7 +135,7 @@ class VanillaSmoothie {
private validateArgvType (
target: VanillaSmoothieTarget,
option: VanillaSmoothieOption,
callback: VanillaSmoothieCallbak
callback?: VanillaSmoothieCallbak
): boolean {
let isValid = true

Expand Down
18 changes: 9 additions & 9 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -674,9 +674,9 @@ acorn-walk@^6.0.1:
integrity sha512-7evsyfH1cLOCdAzZAd43Cic04yKydNx0cF+7tiA19p1XnLLPU4dpCQOqpjqwokFe//vS0QqfqqjCS2JkiIs0cA==

acorn@^6.0.1:
version "6.3.0"
resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.3.0.tgz#0087509119ffa4fc0a0041d1e93a417e68cb856e"
integrity sha512-/czfa8BwS88b9gWQVhc8eknunSA2DoJpJyTQkhheIf5E48u1N0R4q/YxxsAeqRrmK9TQ/uYfgLDfZo91UlANIA==
version "6.4.1"
resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.4.1.tgz#531e58ba3f51b9dacb9a6646ca4debf5b14ca474"
integrity sha512-ZVA9k326Nwrj3Cj9jlh3wGFutC2ZornPNARZwsNYqQYgN0EsV2d53w5RN/co65Ohn4sUAUtb1rSUAOD6XN9idA==

acorn@^7.0.0, acorn@^7.1.0:
version "7.1.0"
Expand Down Expand Up @@ -3498,9 +3498,9 @@ lodash.templatesettings@^4.0.0:
lodash._reinterpolate "^3.0.0"

lodash@^4.17.12, lodash@^4.17.13, lodash@^4.17.14, lodash@^4.17.15:
version "4.17.15"
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.15.tgz#b447f6670a0455bbfeedd11392eff330ea097548"
integrity sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A==
version "4.17.19"
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.19.tgz#e48ddedbe30b3321783c5b4301fbd353bc1e4a4b"
integrity sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==

log-symbols@^1.0.2:
version "1.0.2"
Expand Down Expand Up @@ -5637,9 +5637,9 @@ yaml@^1.7.2:
"@babel/runtime" "^7.8.7"

yargs-parser@^18.1.0:
version "18.1.0"
resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-18.1.0.tgz#1b0ab1118ebd41f68bb30e729f4c83df36ae84c3"
integrity sha512-o/Jr6JBOv6Yx3pL+5naWSoIA2jJ+ZkMYQG/ie9qFbukBe4uzmBatlXFOiu/tNKRWEtyf+n5w7jc/O16ufqOTdQ==
version "18.1.3"
resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-18.1.3.tgz#be68c4975c6b2abf469236b0c870362fab09a7b0"
integrity sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==
dependencies:
camelcase "^5.0.0"
decamelize "^1.2.0"
Expand Down

0 comments on commit 8245355

Please sign in to comment.