@shoper/phoenix_design_system 1.6.13 → 1.6.15-0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cjs/packages/phoenix/src/components/accordion/accordion_content.js +10 -4
- package/build/cjs/packages/phoenix/src/components/accordion/accordion_content.js.map +1 -1
- package/build/cjs/packages/phoenix/src/components/form/input_stepper/display_stepper.js +1 -1
- package/build/esm/packages/phoenix/src/components/accordion/accordion_content.js +10 -4
- package/build/esm/packages/phoenix/src/components/accordion/accordion_content.js.map +1 -1
- package/build/esm/packages/phoenix/src/components/form/input_stepper/display_stepper.js +1 -1
- package/package.json +2 -2
|
@@ -23,8 +23,14 @@ exports.HAccordionContent = class HAccordionContent extends phoenix_light_lit_el
|
|
|
23
23
|
this.style.display = '';
|
|
24
24
|
this.style.height = this._originalHeight;
|
|
25
25
|
};
|
|
26
|
-
this._setOriginalHeightValue = () => {
|
|
27
|
-
this._originalHeight
|
|
26
|
+
this._setOriginalHeightValue = (rewriteHeight = false) => {
|
|
27
|
+
const shouldApplyNewHeight = !this._originalHeight || rewriteHeight;
|
|
28
|
+
if (!shouldApplyNewHeight)
|
|
29
|
+
return;
|
|
30
|
+
const newHeight = this.getBoundingClientRect().height;
|
|
31
|
+
if (newHeight === 0)
|
|
32
|
+
return;
|
|
33
|
+
this._originalHeight = `${newHeight}px`;
|
|
28
34
|
};
|
|
29
35
|
this._expand = () => {
|
|
30
36
|
this._setHeight(this._originalHeight);
|
|
@@ -54,8 +60,8 @@ exports.HAccordionContent = class HAccordionContent extends phoenix_light_lit_el
|
|
|
54
60
|
this._accordionGroupProps.subscribe(this._accordionGroupPropsObserver);
|
|
55
61
|
const mutationObserver = new MutationObserver(() => {
|
|
56
62
|
this.style.height = '';
|
|
57
|
-
this._setOriginalHeightValue();
|
|
58
|
-
this._expand();
|
|
63
|
+
this._setOriginalHeightValue(true);
|
|
64
|
+
this.hidden ? this._collapse() : this._expand();
|
|
59
65
|
});
|
|
60
66
|
mutationObserver.observe(this, { childList: true, subtree: true });
|
|
61
67
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":null,"sources":[null],"sourcesContent":[null],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA,wBAAwB,4CAAgD;AACxE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;"}
|
|
1
|
+
{"version":3,"file":null,"sources":[null],"sourcesContent":[null],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA,wBAAwB,4CAAgD;AACxE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;"}
|
|
@@ -61,7 +61,7 @@ exports.HDisplayStepper = class HDisplayStepper extends phoenix_light_lit_elemen
|
|
|
61
61
|
_preventLettersToBeAdded(ev) {
|
|
62
62
|
const digitsDotAndBackspaceAllowedRegExp = /^[\d\b.,-]$/i;
|
|
63
63
|
const isAllowed = digitsDotAndBackspaceAllowedRegExp.test(ev.key);
|
|
64
|
-
if (!isAllowed && !['Enter', 'Backspace', 'ArrowRight', 'ArrowLeft'].includes(ev.key)) {
|
|
64
|
+
if (!isAllowed && !['Enter', 'Backspace', 'ArrowRight', 'ArrowLeft', 'Tab'].includes(ev.key)) {
|
|
65
65
|
ev.preventDefault();
|
|
66
66
|
}
|
|
67
67
|
}
|
|
@@ -19,8 +19,14 @@ let HAccordionContent = class HAccordionContent extends PhoenixLightLitElement {
|
|
|
19
19
|
this.style.display = '';
|
|
20
20
|
this.style.height = this._originalHeight;
|
|
21
21
|
};
|
|
22
|
-
this._setOriginalHeightValue = () => {
|
|
23
|
-
this._originalHeight
|
|
22
|
+
this._setOriginalHeightValue = (rewriteHeight = false) => {
|
|
23
|
+
const shouldApplyNewHeight = !this._originalHeight || rewriteHeight;
|
|
24
|
+
if (!shouldApplyNewHeight)
|
|
25
|
+
return;
|
|
26
|
+
const newHeight = this.getBoundingClientRect().height;
|
|
27
|
+
if (newHeight === 0)
|
|
28
|
+
return;
|
|
29
|
+
this._originalHeight = `${newHeight}px`;
|
|
24
30
|
};
|
|
25
31
|
this._expand = () => {
|
|
26
32
|
this._setHeight(this._originalHeight);
|
|
@@ -50,8 +56,8 @@ let HAccordionContent = class HAccordionContent extends PhoenixLightLitElement {
|
|
|
50
56
|
this._accordionGroupProps.subscribe(this._accordionGroupPropsObserver);
|
|
51
57
|
const mutationObserver = new MutationObserver(() => {
|
|
52
58
|
this.style.height = '';
|
|
53
|
-
this._setOriginalHeightValue();
|
|
54
|
-
this._expand();
|
|
59
|
+
this._setOriginalHeightValue(true);
|
|
60
|
+
this.hidden ? this._collapse() : this._expand();
|
|
55
61
|
});
|
|
56
62
|
mutationObserver.observe(this, { childList: true, subtree: true });
|
|
57
63
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":null,"sources":[null],"sourcesContent":[null],"names":[],"mappings":"AAAA,uCAAuC,4CAAgD;AACvF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;"}
|
|
1
|
+
{"version":3,"file":null,"sources":[null],"sourcesContent":[null],"names":[],"mappings":"AAAA,uCAAuC,4CAAgD;AACvF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;"}
|
|
@@ -57,7 +57,7 @@ let HDisplayStepper = class HDisplayStepper extends PhoenixLightLitElement {
|
|
|
57
57
|
_preventLettersToBeAdded(ev) {
|
|
58
58
|
const digitsDotAndBackspaceAllowedRegExp = /^[\d\b.,-]$/i;
|
|
59
59
|
const isAllowed = digitsDotAndBackspaceAllowedRegExp.test(ev.key);
|
|
60
|
-
if (!isAllowed && !['Enter', 'Backspace', 'ArrowRight', 'ArrowLeft'].includes(ev.key)) {
|
|
60
|
+
if (!isAllowed && !['Enter', 'Backspace', 'ArrowRight', 'ArrowLeft', 'Tab'].includes(ev.key)) {
|
|
61
61
|
ev.preventDefault();
|
|
62
62
|
}
|
|
63
63
|
}
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@shoper/phoenix_design_system",
|
|
3
3
|
"packageManager": "yarn@3.2.0",
|
|
4
4
|
"sideEffects": false,
|
|
5
|
-
"version": "1.6.
|
|
5
|
+
"version": "1.6.15-0",
|
|
6
6
|
"description": "phoenix design system",
|
|
7
7
|
"author": "zefirek",
|
|
8
8
|
"license": "MIT",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"@splidejs/splide": "^4.0.7"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
|
-
"@dreamcommerce/utilities": "^1.
|
|
33
|
+
"@dreamcommerce/utilities": "^1.7.0",
|
|
34
34
|
"@shoper/jest_config": "^0.0.0",
|
|
35
35
|
"@shoper/tsconfig": "^0.0.0",
|
|
36
36
|
"@splidejs/splide": "4.0.7",
|