Skip to content

Commit

Permalink
Fix typings of events.
Browse files Browse the repository at this point in the history
  • Loading branch information
NaotoshiFujita committed Sep 20, 2022
1 parent a006481 commit 69c3939
Show file tree
Hide file tree
Showing 11 changed files with 41 additions and 54 deletions.
2 changes: 1 addition & 1 deletion dist/js/splide-renderer.min.js.map

Large diffs are not rendered by default.

17 changes: 7 additions & 10 deletions dist/js/splide.cjs.js
Original file line number Diff line number Diff line change
Expand Up @@ -403,9 +403,6 @@ function EventBinder() {
};
}

var ARROWS = "arrows:";
var PAGINATION = "pagination:";
var AUTOPLAY = "autoplay:";
var EVENT_MOUNTED = "mounted";
var EVENT_READY = "ready";
var EVENT_MOVE = "move";
Expand All @@ -426,14 +423,14 @@ var EVENT_SCROLL = "scroll";
var EVENT_SCROLLED = "scrolled";
var EVENT_OVERFLOW = "overflow";
var EVENT_DESTROY = "destroy";
var EVENT_ARROWS_MOUNTED = ARROWS + "mounted";
var EVENT_ARROWS_UPDATED = ARROWS + "updated";
var EVENT_PAGINATION_MOUNTED = PAGINATION + "mounted";
var EVENT_PAGINATION_UPDATED = PAGINATION + "updated";
var EVENT_ARROWS_MOUNTED = "arrows:mounted";
var EVENT_ARROWS_UPDATED = "arrows:updated";
var EVENT_PAGINATION_MOUNTED = "pagination:mounted";
var EVENT_PAGINATION_UPDATED = "pagination:updated";
var EVENT_NAVIGATION_MOUNTED = "navigation:mounted";
var EVENT_AUTOPLAY_PLAY = AUTOPLAY + "play";
var EVENT_AUTOPLAY_PLAYING = AUTOPLAY + "playing";
var EVENT_AUTOPLAY_PAUSE = AUTOPLAY + "pause";
var EVENT_AUTOPLAY_PLAY = "autoplay:play";
var EVENT_AUTOPLAY_PLAYING = "autoplay:playing";
var EVENT_AUTOPLAY_PAUSE = "autoplay:pause";
var EVENT_LAZYLOAD_LOADED = "lazyload:loaded";
var EVENT_SLIDE_KEYDOWN = "sk";
var EVENT_SHIFTED = "sh";
Expand Down
17 changes: 7 additions & 10 deletions dist/js/splide.esm.js
Original file line number Diff line number Diff line change
Expand Up @@ -398,9 +398,6 @@ function EventBinder() {
};
}

var ARROWS = "arrows:";
var PAGINATION = "pagination:";
var AUTOPLAY = "autoplay:";
var EVENT_MOUNTED = "mounted";
var EVENT_READY = "ready";
var EVENT_MOVE = "move";
Expand All @@ -421,14 +418,14 @@ var EVENT_SCROLL = "scroll";
var EVENT_SCROLLED = "scrolled";
var EVENT_OVERFLOW = "overflow";
var EVENT_DESTROY = "destroy";
var EVENT_ARROWS_MOUNTED = ARROWS + "mounted";
var EVENT_ARROWS_UPDATED = ARROWS + "updated";
var EVENT_PAGINATION_MOUNTED = PAGINATION + "mounted";
var EVENT_PAGINATION_UPDATED = PAGINATION + "updated";
var EVENT_ARROWS_MOUNTED = "arrows:mounted";
var EVENT_ARROWS_UPDATED = "arrows:updated";
var EVENT_PAGINATION_MOUNTED = "pagination:mounted";
var EVENT_PAGINATION_UPDATED = "pagination:updated";
var EVENT_NAVIGATION_MOUNTED = "navigation:mounted";
var EVENT_AUTOPLAY_PLAY = AUTOPLAY + "play";
var EVENT_AUTOPLAY_PLAYING = AUTOPLAY + "playing";
var EVENT_AUTOPLAY_PAUSE = AUTOPLAY + "pause";
var EVENT_AUTOPLAY_PLAY = "autoplay:play";
var EVENT_AUTOPLAY_PLAYING = "autoplay:playing";
var EVENT_AUTOPLAY_PAUSE = "autoplay:pause";
var EVENT_LAZYLOAD_LOADED = "lazyload:loaded";
var EVENT_SLIDE_KEYDOWN = "sk";
var EVENT_SHIFTED = "sh";
Expand Down
17 changes: 7 additions & 10 deletions dist/js/splide.js
Original file line number Diff line number Diff line change
Expand Up @@ -399,9 +399,6 @@ function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _d
};
}

var ARROWS = "arrows:";
var PAGINATION = "pagination:";
var AUTOPLAY = "autoplay:";
var EVENT_MOUNTED = "mounted";
var EVENT_READY = "ready";
var EVENT_MOVE = "move";
Expand All @@ -422,14 +419,14 @@ function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _d
var EVENT_SCROLLED = "scrolled";
var EVENT_OVERFLOW = "overflow";
var EVENT_DESTROY = "destroy";
var EVENT_ARROWS_MOUNTED = ARROWS + "mounted";
var EVENT_ARROWS_UPDATED = ARROWS + "updated";
var EVENT_PAGINATION_MOUNTED = PAGINATION + "mounted";
var EVENT_PAGINATION_UPDATED = PAGINATION + "updated";
var EVENT_ARROWS_MOUNTED = "arrows:mounted";
var EVENT_ARROWS_UPDATED = "arrows:updated";
var EVENT_PAGINATION_MOUNTED = "pagination:mounted";
var EVENT_PAGINATION_UPDATED = "pagination:updated";
var EVENT_NAVIGATION_MOUNTED = "navigation:mounted";
var EVENT_AUTOPLAY_PLAY = AUTOPLAY + "play";
var EVENT_AUTOPLAY_PLAYING = AUTOPLAY + "playing";
var EVENT_AUTOPLAY_PAUSE = AUTOPLAY + "pause";
var EVENT_AUTOPLAY_PLAY = "autoplay:play";
var EVENT_AUTOPLAY_PLAYING = "autoplay:playing";
var EVENT_AUTOPLAY_PAUSE = "autoplay:pause";
var EVENT_LAZYLOAD_LOADED = "lazyload:loaded";
var EVENT_SLIDE_KEYDOWN = "sk";
var EVENT_SHIFTED = "sh";
Expand Down
2 changes: 1 addition & 1 deletion dist/js/splide.min.js

Large diffs are not rendered by default.

Binary file modified dist/js/splide.min.js.gz
Binary file not shown.
2 changes: 1 addition & 1 deletion dist/js/splide.min.js.map

Large diffs are not rendered by default.

14 changes: 7 additions & 7 deletions dist/types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1581,14 +1581,14 @@ declare const EVENT_SCROLL = "scroll";
declare const EVENT_SCROLLED = "scrolled";
declare const EVENT_OVERFLOW = "overflow";
declare const EVENT_DESTROY = "destroy";
declare const EVENT_ARROWS_MOUNTED: string;
declare const EVENT_ARROWS_UPDATED: string;
declare const EVENT_PAGINATION_MOUNTED: string;
declare const EVENT_PAGINATION_UPDATED: string;
declare const EVENT_ARROWS_MOUNTED = "arrows:mounted";
declare const EVENT_ARROWS_UPDATED = "arrows:updated";
declare const EVENT_PAGINATION_MOUNTED = "pagination:mounted";
declare const EVENT_PAGINATION_UPDATED = "pagination:updated";
declare const EVENT_NAVIGATION_MOUNTED = "navigation:mounted";
declare const EVENT_AUTOPLAY_PLAY: string;
declare const EVENT_AUTOPLAY_PLAYING: string;
declare const EVENT_AUTOPLAY_PAUSE: string;
declare const EVENT_AUTOPLAY_PLAY = "autoplay:play";
declare const EVENT_AUTOPLAY_PLAYING = "autoplay:playing";
declare const EVENT_AUTOPLAY_PAUSE = "autoplay:pause";
declare const EVENT_LAZYLOAD_LOADED = "lazyload:loaded";
/** @internal */
declare const EVENT_SLIDE_KEYDOWN = "sk";
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

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

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@splidejs/splide",
"version": "4.1.0",
"version": "4.1.1",
"description": "Splide is a lightweight, flexible and accessible slider/carousel. No dependencies, no Lighthouse errors.",
"author": "Naotoshi Fujita",
"license": "MIT",
Expand Down
18 changes: 7 additions & 11 deletions src/js/constants/events.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
const ARROWS = `arrows:`;
const PAGINATION = `pagination:`;
const AUTOPLAY = `autoplay:`;

export const EVENT_MOUNTED = 'mounted';
export const EVENT_READY = 'ready';
export const EVENT_MOVE = 'move';
Expand All @@ -22,14 +18,14 @@ export const EVENT_SCROLL = 'scroll';
export const EVENT_SCROLLED = 'scrolled';
export const EVENT_OVERFLOW = 'overflow';
export const EVENT_DESTROY = 'destroy';
export const EVENT_ARROWS_MOUNTED = `${ ARROWS }mounted`;
export const EVENT_ARROWS_UPDATED = `${ ARROWS }updated`;
export const EVENT_PAGINATION_MOUNTED = `${ PAGINATION }mounted`;
export const EVENT_PAGINATION_UPDATED = `${ PAGINATION }updated`;
export const EVENT_ARROWS_MOUNTED = 'arrows:mounted';
export const EVENT_ARROWS_UPDATED = 'arrows:updated';
export const EVENT_PAGINATION_MOUNTED = 'pagination:mounted';
export const EVENT_PAGINATION_UPDATED = 'pagination:updated';
export const EVENT_NAVIGATION_MOUNTED = 'navigation:mounted';
export const EVENT_AUTOPLAY_PLAY = `${ AUTOPLAY }play`;
export const EVENT_AUTOPLAY_PLAYING = `${ AUTOPLAY }playing`;
export const EVENT_AUTOPLAY_PAUSE = `${ AUTOPLAY }pause`;
export const EVENT_AUTOPLAY_PLAY = 'autoplay:play';
export const EVENT_AUTOPLAY_PLAYING = 'autoplay:playing';
export const EVENT_AUTOPLAY_PAUSE = 'autoplay:pause';
export const EVENT_LAZYLOAD_LOADED = 'lazyload:loaded';

/** @internal */
Expand Down

0 comments on commit 69c3939

Please sign in to comment.