Skip to content
Snippets Groups Projects
Verified Commit b2a23d04 authored by Volker Schukai's avatar Volker Schukai :alien:
Browse files

feat(slider): add more breakpoints

parent 20f58418
No related branches found
No related tags found
No related merge requests found
......@@ -104,9 +104,7 @@ class ConfirmButton extends PopperButton {
this.hideDialog();
};
obj["actions"]["confirm"] = (e) => {
throw new Error("this callback must be implemented");
};
obj["actions"]["confirm"] = () => {};
return obj;
}
......@@ -119,7 +117,7 @@ class ConfirmButton extends PopperButton {
/**
*
* @return {Monster.Components.Form.PopperButton}
* @return {PopperButton}
*/
[assembleMethodSymbol]() {
super[assembleMethodSymbol]();
......@@ -145,7 +143,7 @@ class ConfirmButton extends PopperButton {
/**
*
* @return {Monster.Components.Form.PopperButton}
* @return {ConfirmButton}
*/
showDialog() {
const confirmButtonClass = this.getOption("classes.confirmButton");
......@@ -172,7 +170,7 @@ class ConfirmButton extends PopperButton {
*
* @param {string} state
* @param {number} timeout
* @return {Monster.Components.Form.ConfirmButton}
* @return {ConfirmButton}
*/
setConfirmButtonState(state, timeout) {
this[confirmButtonElementSymbol].setState(state, timeout);
......@@ -184,7 +182,7 @@ class ConfirmButton extends PopperButton {
*
* @param {string} message
* @param {number} timeout
* @return {Monster.Components.Form.ConfirmButton}
* @return {ConfirmButton}
*/
showConfirmButtonMessage(message, timeout) {
this[confirmButtonElementSymbol].setMessage(message);
......@@ -216,8 +214,8 @@ function getAction(type) {
/**
* @private
* @return {initEventhandler}
* @fires Monster.Components.Form.PopperButton#monster-confirm
* @fires Monster.Components.Form.PopperButton#monster-confirmed
* @fires ConfirmButton#monster-confirm
* @fires ConfirmButton#monster-confirmed
*/
function initEventhandler() {
this[cancelButtonElementSymbol].setOption(
......@@ -235,9 +233,13 @@ function initEventhandler() {
);
this[confirmButtonElementSymbol].setOption("actions.click", () => {
const callback = getAction.call(this, "confirm");
fireCustomEvent(this, "monster-confirm", {});
fireCustomEvent(this, "monster-confirm", {
button: this,
});
callback.call(this);
fireCustomEvent(this, "monster-confirmed", {});
fireCustomEvent(this, "monster-confirmed", {
button: this,
});
});
return this;
......
......@@ -160,6 +160,9 @@ class Slider extends CustomElement {
slides: {
0: 1,
600: 2,
1200: 3,
1800: 4,
},
carousel: {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment