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

feat: new login dialog

parent a5cf92a5
Branches
Tags
No related merge requests found
This diff is collapsed.
This diff is collapsed.
......@@ -127,7 +127,7 @@ class ToggleSwitch extends CustomControl {
initControlReferences.call(this);
initEventHandler.call(this);
getWindow().requestAnimationFrame(() => {
setTimeout(() => {
/**
* init value to off
* if the value was not defined before inserting it into the HTML
......@@ -154,7 +154,7 @@ class ToggleSwitch extends CustomControl {
} else {
toggleOff.call(self);
}
});
}, 0);
}
/**
......@@ -377,6 +377,9 @@ function toggleOff() {
}
}
/**
* @private
*/
function showError() {
if (!this[switchElementSymbol]) {
return;
......
......@@ -104,9 +104,8 @@ class Slider extends CustomElement {
mouseOverPause: null,
mouseout: null,
touchstart: null,
touchend: null
}
touchend: null,
},
};
// set --monster-slides-width
......@@ -370,48 +369,56 @@ function initAutoPlay() {
}, startDelay);
if (autoPlay.mouseOverPause) {
if (this[configSymbol].eventHandler.mouseOverPause === null) {
this[configSymbol].eventHandler.mouseOverPause = () => {
clearInterval(this[configSymbol].autoPlayInterval);
}
};
this.addEventListener("mouseover",this[configSymbol].eventHandler.mouseOverPause);
this.addEventListener(
"mouseover",
this[configSymbol].eventHandler.mouseOverPause,
);
}
if (this[configSymbol].eventHandler.mouseout === null) {
this[configSymbol].eventHandler.mouseout = () => {
if (this[configSymbol].isDragging) {
return;
}
start();
}
};
this.addEventListener("mouseout", this[configSymbol].eventHandler.mouseout);
this.addEventListener(
"mouseout",
this[configSymbol].eventHandler.mouseout,
);
}
}
if (autoPlay.touchPause) {
if (this[configSymbol].eventHandler.touchstart === null) {
this[configSymbol].eventHandler.touchstart = () => {
clearInterval(this[configSymbol].autoPlayInterval);
}
};
this.addEventListener("touchstart",this[configSymbol].eventHandler.touchstart);
this.addEventListener(
"touchstart",
this[configSymbol].eventHandler.touchstart,
);
}
if (this[configSymbol].eventHandler.touchend === null) {
this[configSymbol].eventHandler.touchend = () => {
if (this[configSymbol].isDragging) {
return;
}
start();
}
};
this.addEventListener("touchend", this[configSymbol].eventHandler.touchend);
this.addEventListener(
"touchend",
this[configSymbol].eventHandler.touchend,
);
}
}
}
......@@ -672,17 +679,15 @@ function initEventHandler() {
);
}
const initialSize = {
width: this[sliderElementSymbol]?.offsetWidth || 0,
height: this[sliderElementSymbol]?.offsetHeight || 0
height: this[sliderElementSymbol]?.offsetHeight || 0,
};
const resizeObserver = new ResizeObserver(entries => {
const resizeObserver = new ResizeObserver((entries) => {
for (let entry of entries) {
const { width, height } = entry.contentRect;
if (width !== initialSize.width || height !== initialSize.height) {
self.stopAutoPlay();
if (this.getOption("features.thumbnails")) {
......@@ -695,12 +700,12 @@ function initEventHandler() {
`${100 / slidesVisible}%`,
);
moveTo.call(self,0,false)
moveTo.call(self, 0, false);
self.startAutoPlay();
fireCustomEvent(self, "monster-slider-resized", {
width: width,
height: height
height: height,
});
}
}
......@@ -708,8 +713,6 @@ function initEventHandler() {
resizeObserver.observe(this[sliderElementSymbol]);
return this;
}
......@@ -807,7 +810,6 @@ function initControlReferences() {
this[thumbnailElementSymbol] = this.shadowRoot.querySelector(
`[${ATTRIBUTE_ROLE}="thumbnails"]`,
);
}
/**
......
......@@ -706,9 +706,11 @@ class CustomElement extends HTMLElement {
}
/**
* Checks if the provided node is part of this component's child nodes,
* including those within the shadow root, if present.
*
* @param {Node} node
* @return {boolean}
* @param {Node} node - The node to check for within this component's child nodes.
* @return {boolean} Returns true if the given node is found, otherwise false.
* @throws {TypeError} value is not an instance of
* @since 1.19.0
*/
......@@ -725,11 +727,11 @@ class CustomElement extends HTMLElement {
}
/**
* Calls a callback function if it exists.
* Invokes a callback function with the given name and arguments.
*
* @param {string} name
* @param {*} args
* @return {*}
* @param {string} name - The name of the callback to be executed.
* @param {Array} args - An array of arguments to be passed to the callback function.
* @return {*} The result of the callback function execution.
*/
callCallback(name, args) {
return callControlCallback.call(this, name, ...args);
......
......@@ -89,11 +89,9 @@ class ProxyObserver extends Base {
}
/**
* Get the real object
* Retrieves the real subject associated with the current instance.
*
* Changes to this object are not noticed by the observers, so you can make a large number of changes and inform the observers later.
*
* @return {object}
* @return {Object} The real subject object.
*/
getRealSubject() {
return this.realSubject;
......
......@@ -156,7 +156,7 @@ function getMonsterVersion() {
}
/** don't touch, replaced by make with package.json version */
monsterVersion = new Version("3.112.4");
monsterVersion = new Version("3.113.0");
return monsterVersion;
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment