@angelscmf/front 1.0.27 → 1.0.29
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/dist/AngelsCore.cjs +44 -1
- package/dist/AngelsCore.cjs.map +1 -1
- package/dist/AngelsCore.js +44 -1
- package/dist/AngelsCore.js.map +1 -1
- package/dist/AngelsElement.cjs +67 -0
- package/dist/AngelsElement.cjs.map +1 -0
- package/dist/AngelsElement.d.cts +11 -0
- package/dist/AngelsElement.d.ts +11 -0
- package/dist/AngelsElement.js +42 -0
- package/dist/AngelsElement.js.map +1 -0
- package/dist/AngelsFrontAnimationLibrary.cjs +83 -35
- package/dist/AngelsFrontAnimationLibrary.cjs.map +1 -1
- package/dist/AngelsFrontAnimationLibrary.d.cts +4 -4
- package/dist/AngelsFrontAnimationLibrary.d.ts +4 -4
- package/dist/AngelsFrontAnimationLibrary.js +80 -32
- package/dist/AngelsFrontAnimationLibrary.js.map +1 -1
- package/dist/AngelsFrontDOMLibrary.cjs +85 -6
- package/dist/AngelsFrontDOMLibrary.cjs.map +1 -1
- package/dist/AngelsFrontDOMLibrary.d.cts +8 -2
- package/dist/AngelsFrontDOMLibrary.d.ts +8 -2
- package/dist/AngelsFrontDOMLibrary.js +78 -5
- package/dist/AngelsFrontDOMLibrary.js.map +1 -1
- package/dist/{AngelsFrontLibrary.cjs → AngelsFrontLoader.cjs} +103 -30
- package/dist/AngelsFrontLoader.cjs.map +1 -0
- package/dist/{AngelsFrontLibrary.js → AngelsFrontLoader.js} +103 -30
- package/dist/AngelsFrontLoader.js.map +1 -0
- package/package.json +1 -1
- package/sass/AngelsDesign.scss +2 -0
- package/sass/_AngelsScreenRanges.scss +82 -6
- package/sass/angelsMessages/_AngelsAlert.scss +20 -10
- package/sass/angelsMessages/_AngelsDebug.scss +15 -10
- package/sass/angelsMessages/_AngelsDone.scss +15 -10
- package/sass/angelsMessages/_AngelsError.scss +15 -10
- package/sass/angelsMessages/_AngelsInfo.scss +15 -10
- package/sass/angelsMessages/_AngelsTip.scss +15 -10
- package/sass/angelsMessages/_AngelsWarn.scss +15 -10
- package/sass/angelsTags/_a-state.scss +10 -0
- package/sass/angelsTags/_a-table.scss +59 -0
- package/dist/AngelsFrontLibrary.cjs.map +0 -1
- package/dist/AngelsFrontLibrary.js.map +0 -1
- /package/dist/{AngelsFrontLibrary.d.cts → AngelsFrontLoader.d.cts} +0 -0
- /package/dist/{AngelsFrontLibrary.d.ts → AngelsFrontLoader.d.ts} +0 -0
|
@@ -20,35 +20,117 @@ var __async = (__this, __arguments, generator) => {
|
|
|
20
20
|
});
|
|
21
21
|
};
|
|
22
22
|
|
|
23
|
+
// src/AngelsElement.ts
|
|
24
|
+
var AngelsElementClass = class {
|
|
25
|
+
constructor(element) {
|
|
26
|
+
this.originalElement = element;
|
|
27
|
+
return new Proxy(this, {
|
|
28
|
+
get(target, prop, receiver) {
|
|
29
|
+
if (prop in target) {
|
|
30
|
+
return target[prop];
|
|
31
|
+
}
|
|
32
|
+
return target.originalElement[prop];
|
|
33
|
+
},
|
|
34
|
+
set(target, prop, newValue, receiver) {
|
|
35
|
+
if (prop in target) {
|
|
36
|
+
target[prop] = newValue;
|
|
37
|
+
} else {
|
|
38
|
+
target.originalElement[prop] = newValue;
|
|
39
|
+
}
|
|
40
|
+
return true;
|
|
41
|
+
}
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
aHideElement() {
|
|
45
|
+
this.originalElement.hidden = true;
|
|
46
|
+
return this;
|
|
47
|
+
}
|
|
48
|
+
aShowElement() {
|
|
49
|
+
this.originalElement.hidden = false;
|
|
50
|
+
return this;
|
|
51
|
+
}
|
|
52
|
+
aTextContent(content = void 0) {
|
|
53
|
+
var _a;
|
|
54
|
+
if (content === void 0) {
|
|
55
|
+
return (_a = this.originalElement.textContent) != null ? _a : ``;
|
|
56
|
+
}
|
|
57
|
+
this.originalElement.textContent = content.toString();
|
|
58
|
+
return this;
|
|
59
|
+
}
|
|
60
|
+
};
|
|
61
|
+
|
|
23
62
|
// src/AngelsFrontDOMLibrary.ts
|
|
24
|
-
function
|
|
63
|
+
function aLibFindElement(selector) {
|
|
25
64
|
let element;
|
|
26
65
|
if (typeof selector === "undefined") {
|
|
27
|
-
|
|
66
|
+
return null;
|
|
28
67
|
} else if (selector === null) {
|
|
29
|
-
|
|
68
|
+
return null;
|
|
30
69
|
} else if (typeof selector === "string") {
|
|
31
70
|
const findElement = document.querySelector(selector);
|
|
32
71
|
if (!findElement) {
|
|
33
|
-
|
|
72
|
+
return null;
|
|
34
73
|
}
|
|
35
74
|
element = findElement;
|
|
36
75
|
} else if (selector instanceof HTMLElement) {
|
|
37
76
|
element = selector;
|
|
38
77
|
} else if (selector instanceof Element) {
|
|
39
78
|
element = selector;
|
|
79
|
+
} else if (selector instanceof AngelsElementClass) {
|
|
80
|
+
return selector;
|
|
40
81
|
} else {
|
|
41
82
|
element = selector;
|
|
42
83
|
}
|
|
84
|
+
return new AngelsElementClass(element);
|
|
85
|
+
}
|
|
86
|
+
function aLibRequireElement(selector) {
|
|
87
|
+
const element = aLibFindElement(selector);
|
|
88
|
+
if (element) {
|
|
89
|
+
return element;
|
|
90
|
+
}
|
|
91
|
+
throw Error(`Element not found by '${selector}' selector.`);
|
|
92
|
+
}
|
|
93
|
+
function aLibHideElement(selector) {
|
|
94
|
+
const element = aLibRequireElement(selector);
|
|
95
|
+
element.hidden = true;
|
|
96
|
+
return element;
|
|
97
|
+
}
|
|
98
|
+
function aLibShowElement(selector) {
|
|
99
|
+
const element = aLibRequireElement(selector);
|
|
100
|
+
element.hidden = false;
|
|
43
101
|
return element;
|
|
44
102
|
}
|
|
103
|
+
function aLibToggleElement(originalElement, switcher = void 0) {
|
|
104
|
+
const innerElement = aLibRequireElement(originalElement);
|
|
105
|
+
if (switcher === void 0) {
|
|
106
|
+
switcher = !innerElement.hidden;
|
|
107
|
+
}
|
|
108
|
+
if (switcher) {
|
|
109
|
+
return aLibShowElement(innerElement);
|
|
110
|
+
} else {
|
|
111
|
+
return aLibHideElement(innerElement);
|
|
112
|
+
}
|
|
113
|
+
}
|
|
45
114
|
|
|
46
115
|
// src/AngelsFrontAnimationLibrary.ts
|
|
47
|
-
function
|
|
116
|
+
function aLibEngageElement(originalElement, switcher = void 0) {
|
|
117
|
+
return __async(this, null, function* () {
|
|
118
|
+
const innerElement = aLibRequireElement(originalElement);
|
|
119
|
+
if (switcher === void 0) {
|
|
120
|
+
switcher = !innerElement.hidden;
|
|
121
|
+
}
|
|
122
|
+
if (switcher) {
|
|
123
|
+
return yield aLibRevealElement(innerElement);
|
|
124
|
+
} else {
|
|
125
|
+
return yield aLibConcealElement(innerElement);
|
|
126
|
+
}
|
|
127
|
+
});
|
|
128
|
+
}
|
|
129
|
+
function aLibConcealElement(originalElement) {
|
|
48
130
|
return __async(this, null, function* () {
|
|
49
131
|
const innerElement = aLibRequireElement(originalElement);
|
|
50
132
|
const promise = new Promise((resolve) => {
|
|
51
|
-
if (
|
|
133
|
+
if (innerElement.hidden) {
|
|
52
134
|
resolve();
|
|
53
135
|
return;
|
|
54
136
|
}
|
|
@@ -56,42 +138,34 @@ function aLibShowElement(originalElement) {
|
|
|
56
138
|
const animationHandler = () => {
|
|
57
139
|
clearTimeout(timeout);
|
|
58
140
|
innerElement.removeEventListener("animationend", animationHandler);
|
|
141
|
+
innerElement.hidden = true;
|
|
142
|
+
innerElement.classList.remove("a-out-animation");
|
|
59
143
|
resolve();
|
|
60
144
|
};
|
|
61
|
-
innerElement.
|
|
145
|
+
innerElement.classList.add("a-out-animation");
|
|
62
146
|
const animations = innerElement.getAnimations();
|
|
63
147
|
if (animations.length > 0) {
|
|
64
148
|
timeout = setTimeout(() => {
|
|
65
149
|
innerElement.removeEventListener("animationend", animationHandler);
|
|
150
|
+
innerElement.hidden = true;
|
|
151
|
+
innerElement.classList.remove("a-out-animation");
|
|
66
152
|
console.warn("Animation timeout");
|
|
67
153
|
resolve();
|
|
68
154
|
}, 5e3);
|
|
69
155
|
innerElement.addEventListener("animationend", animationHandler);
|
|
70
156
|
} else {
|
|
157
|
+
innerElement.hidden = true;
|
|
71
158
|
resolve();
|
|
72
159
|
}
|
|
73
160
|
});
|
|
74
161
|
return promise;
|
|
75
162
|
});
|
|
76
163
|
}
|
|
77
|
-
function
|
|
78
|
-
return __async(this, null, function* () {
|
|
79
|
-
const innerElement = aLibRequireElement(originalElement);
|
|
80
|
-
if (switcher === void 0) {
|
|
81
|
-
switcher = !innerElement.hidden;
|
|
82
|
-
}
|
|
83
|
-
if (switcher) {
|
|
84
|
-
return yield aLibShowElement(innerElement);
|
|
85
|
-
} else {
|
|
86
|
-
return yield aLibHideElement(innerElement);
|
|
87
|
-
}
|
|
88
|
-
});
|
|
89
|
-
}
|
|
90
|
-
function aLibHideElement(originalElement) {
|
|
164
|
+
function aLibRevealElement(originalElement) {
|
|
91
165
|
return __async(this, null, function* () {
|
|
92
166
|
const innerElement = aLibRequireElement(originalElement);
|
|
93
167
|
const promise = new Promise((resolve) => {
|
|
94
|
-
if (innerElement.hidden) {
|
|
168
|
+
if (!innerElement.hidden) {
|
|
95
169
|
resolve();
|
|
96
170
|
return;
|
|
97
171
|
}
|
|
@@ -99,23 +173,18 @@ function aLibHideElement(originalElement) {
|
|
|
99
173
|
const animationHandler = () => {
|
|
100
174
|
clearTimeout(timeout);
|
|
101
175
|
innerElement.removeEventListener("animationend", animationHandler);
|
|
102
|
-
innerElement.hidden = true;
|
|
103
|
-
innerElement.classList.remove("a-out-animation");
|
|
104
176
|
resolve();
|
|
105
177
|
};
|
|
106
|
-
innerElement.
|
|
178
|
+
innerElement.hidden = false;
|
|
107
179
|
const animations = innerElement.getAnimations();
|
|
108
180
|
if (animations.length > 0) {
|
|
109
181
|
timeout = setTimeout(() => {
|
|
110
182
|
innerElement.removeEventListener("animationend", animationHandler);
|
|
111
|
-
innerElement.hidden = true;
|
|
112
|
-
innerElement.classList.remove("a-out-animation");
|
|
113
183
|
console.warn("Animation timeout");
|
|
114
184
|
resolve();
|
|
115
185
|
}, 5e3);
|
|
116
186
|
innerElement.addEventListener("animationend", animationHandler);
|
|
117
187
|
} else {
|
|
118
|
-
innerElement.hidden = true;
|
|
119
188
|
resolve();
|
|
120
189
|
}
|
|
121
190
|
});
|
|
@@ -123,9 +192,13 @@ function aLibHideElement(originalElement) {
|
|
|
123
192
|
});
|
|
124
193
|
}
|
|
125
194
|
|
|
126
|
-
// src/
|
|
195
|
+
// src/AngelsFrontLoader.ts
|
|
196
|
+
window.aEngageElement = aLibEngageElement;
|
|
197
|
+
window.aConcealElement = aLibConcealElement;
|
|
198
|
+
window.aRevealElement = aLibRevealElement;
|
|
199
|
+
window.aFindElement = aLibFindElement;
|
|
127
200
|
window.aHideElement = aLibHideElement;
|
|
128
201
|
window.aRequireElement = aLibRequireElement;
|
|
129
202
|
window.aShowElement = aLibShowElement;
|
|
130
203
|
window.aToggleElement = aLibToggleElement;
|
|
131
|
-
//# sourceMappingURL=
|
|
204
|
+
//# sourceMappingURL=AngelsFrontLoader.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/AngelsElement.ts","../src/AngelsFrontDOMLibrary.ts","../src/AngelsFrontAnimationLibrary.ts","../src/AngelsFrontLoader.ts"],"sourcesContent":["export type AngelsElement<TElement extends HTMLElement = HTMLElement> = AngelsElementClass<TElement> & TElement;\n\nexport class AngelsElementClass<TElement extends HTMLElement = HTMLElement> {\n\n protected originalElement: TElement;\n\n constructor(element: TElement) {\n\n this.originalElement = element;\n\n return new Proxy(this, {\n get(target: any, prop: string | symbol, receiver: any) {\n if (prop in target) {\n return target[prop];\n }\n return target.originalElement[prop];\n },\n\n set(target: any, prop: string | symbol, newValue: any, receiver: any) {\n if (prop in target) {\n target[prop] = newValue;\n } else {\n target.originalElement[prop] = newValue;\n }\n return true;\n }\n });\n }\n\n aHideElement(): this {\n this.originalElement.hidden = true;\n return this;\n }\n\n aShowElement(): this {\n this.originalElement.hidden = false;\n return this;\n }\n\n aTextContent(): string;\n aTextContent(content: string): this;\n aTextContent(content: string | undefined = undefined): this | string {\n if (content === undefined) {\n return this.originalElement.textContent ?? ``;\n }\n this.originalElement.textContent = content.toString();\n return this;\n }\n}\n","import { AngelsElement, AngelsElementClass } from \"./AngelsElement\";\n\nexport function aLibFindElement<THTMLElement extends HTMLElement>(selector: AngelsSelectorType<THTMLElement>): AngelsElement<THTMLElement> | null {\n\n let element: THTMLElement;\n if (typeof selector === 'undefined') {\n return null;\n } else if (selector === null) {\n return null;\n } else if (typeof selector === 'string') {\n const findElement = document.querySelector<THTMLElement>(selector);\n if (!findElement) {\n return null;\n }\n element = findElement;\n } else if (selector instanceof HTMLElement) {\n element = selector as THTMLElement;\n } else if (selector instanceof Element) {\n element = selector as THTMLElement;\n } else if (selector instanceof AngelsElementClass) {\n return selector as AngelsElement<THTMLElement>;\n } else {\n element = selector;\n }\n return new AngelsElementClass(element) as AngelsElement<THTMLElement>;\n}\n\nexport function aLibRequireElement<THTMLElement extends HTMLElement>(selector: AngelsSelectorType): AngelsElement<THTMLElement> {\n const element = aLibFindElement<THTMLElement>(selector);\n if (element) {\n return element;\n }\n throw Error(`Element not found by '${selector}' selector.`);\n}\n\nexport function aLibHideElement<THTMLElement extends HTMLElement>(selector: AngelsSelectorType): AngelsElement<THTMLElement> {\n const element = aLibRequireElement<THTMLElement>(selector);\n element.hidden = true;\n return element;\n}\n\nexport function aLibShowElement<THTMLElement extends HTMLElement>(selector: AngelsSelectorType): AngelsElement<THTMLElement> {\n const element = aLibRequireElement<THTMLElement>(selector);\n element.hidden = false;\n return element;\n}\n\nexport function aLibToggleElement(originalElement: AngelsSelectorType, switcher: boolean | undefined = undefined) {\n const innerElement = aLibRequireElement(originalElement);\n if (switcher === undefined) {\n switcher = !innerElement.hidden;\n }\n if (switcher) {\n return aLibShowElement(innerElement);\n } else {\n return aLibHideElement(innerElement);\n }\n}\n","import { aLibRequireElement } from \"./AngelsFrontDOMLibrary\";\n\nexport async function aLibEngageElement(originalElement: AngelsSelectorType, switcher: boolean | undefined = undefined) {\n const innerElement = aLibRequireElement(originalElement);\n if (switcher === undefined) {\n switcher = !innerElement.hidden;\n }\n if (switcher) {\n return await aLibRevealElement(innerElement);\n } else {\n return await aLibConcealElement(innerElement);\n }\n}\n\nexport async function aLibConcealElement(originalElement: AngelsSelectorType) {\n const innerElement = aLibRequireElement(originalElement);\n const promise = new Promise<void>((resolve) => {\n\n if (innerElement.hidden) {\n resolve();\n return;\n }\n\n let timeout: NodeJS.Timeout | undefined;\n\n const animationHandler = () => {\n clearTimeout(timeout);\n innerElement.removeEventListener('animationend', animationHandler);\n innerElement.hidden = true;\n innerElement.classList.remove('a-out-animation');\n resolve();\n }\n\n innerElement.classList.add('a-out-animation');\n\n const animations = innerElement.getAnimations();\n if (animations.length > 0) {\n timeout = setTimeout(() => {\n innerElement.removeEventListener('animationend', animationHandler);\n innerElement.hidden = true;\n innerElement.classList.remove('a-out-animation');\n console.warn('Animation timeout');\n resolve();\n }, 5000); // 5 seconds timeout\n innerElement.addEventListener('animationend', animationHandler);\n } else {\n innerElement.hidden = true;\n resolve();\n }\n });\n\n return promise;\n}\n\nexport async function aLibRevealElement(originalElement: AngelsSelectorType) {\n const innerElement = aLibRequireElement(originalElement);\n const promise = new Promise<void>((resolve) => {\n\n if (!innerElement.hidden) {\n resolve();\n return;\n }\n\n let timeout: NodeJS.Timeout | undefined;\n\n const animationHandler = () => {\n clearTimeout(timeout);\n innerElement.removeEventListener('animationend', animationHandler);\n resolve();\n }\n\n innerElement.hidden = false;\n\n const animations = innerElement.getAnimations();\n if (animations.length > 0) {\n timeout = setTimeout(() => {\n innerElement.removeEventListener('animationend', animationHandler);\n console.warn('Animation timeout');\n resolve();\n }, 5000); // 5 seconds timeout\n innerElement.addEventListener('animationend', animationHandler);\n } else {\n resolve();\n }\n });\n\n return promise;\n}\n","import { aLibConcealElement, aLibRevealElement, aLibEngageElement } from \"./AngelsFrontAnimationLibrary\";\n\nwindow.aEngageElement = aLibEngageElement;\nwindow.aConcealElement = aLibConcealElement;\nwindow.aRevealElement = aLibRevealElement;\n\nimport { aLibFindElement, aLibHideElement, aLibRequireElement, aLibShowElement, aLibToggleElement } from \"./AngelsFrontDOMLibrary\";\n\nwindow.aFindElement = aLibFindElement;\nwindow.aHideElement = aLibHideElement;\nwindow.aRequireElement = aLibRequireElement;\nwindow.aShowElement = aLibShowElement;\nwindow.aToggleElement = aLibToggleElement;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAEO,IAAM,qBAAN,MAAqE;AAAA,EAIxE,YAAY,SAAmB;AAE3B,SAAK,kBAAkB;AAEvB,WAAO,IAAI,MAAM,MAAM;AAAA,MACnB,IAAI,QAAa,MAAuB,UAAe;AACnD,YAAI,QAAQ,QAAQ;AAChB,iBAAO,OAAO,IAAI;AAAA,QACtB;AACA,eAAO,OAAO,gBAAgB,IAAI;AAAA,MACtC;AAAA,MAEA,IAAI,QAAa,MAAuB,UAAe,UAAe;AAClE,YAAI,QAAQ,QAAQ;AAChB,iBAAO,IAAI,IAAI;AAAA,QACnB,OAAO;AACH,iBAAO,gBAAgB,IAAI,IAAI;AAAA,QACnC;AACA,eAAO;AAAA,MACX;AAAA,IACJ,CAAC;AAAA,EACL;AAAA,EAEA,eAAqB;AACjB,SAAK,gBAAgB,SAAS;AAC9B,WAAO;AAAA,EACX;AAAA,EAEA,eAAqB;AACjB,SAAK,gBAAgB,SAAS;AAC9B,WAAO;AAAA,EACX;AAAA,EAIA,aAAa,UAA8B,QAA0B;AAzCzE;AA0CQ,QAAI,YAAY,QAAW;AACvB,cAAO,UAAK,gBAAgB,gBAArB,YAAoC;AAAA,IAC/C;AACA,SAAK,gBAAgB,cAAc,QAAQ,SAAS;AACpD,WAAO;AAAA,EACX;AACJ;;;AC9CO,SAAS,gBAAkD,UAAgF;AAE9I,MAAI;AACJ,MAAI,OAAO,aAAa,aAAa;AACjC,WAAO;AAAA,EACX,WAAW,aAAa,MAAM;AAC1B,WAAO;AAAA,EACX,WAAW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G,GAAI;AACP,qBAAa,iBAAiB,gBAAgB,gBAAgB;AAAA,MAClE,OAAO;AACH,gBAAQ;AAAA,MACZ;AAAA,IACJ,CAAC;AAED,WAAO;AAAA,EACX;AAAA;;;ACrFA,OAAO,iBAAiB;AACxB,OAAO,kBAAkB;AACzB,OAAO,iBAAiB;AAIxB,OAAO,eAAe;AACtB,OAAO,eAAe;AACtB,OAAO,kBAAkB;AACzB,OAAO,eAAe;AACtB,OAAO,iBAAiB;","names":[]}
|
|
@@ -19,35 +19,117 @@ var __async = (__this, __arguments, generator) => {
|
|
|
19
19
|
});
|
|
20
20
|
};
|
|
21
21
|
|
|
22
|
+
// src/AngelsElement.ts
|
|
23
|
+
var AngelsElementClass = class {
|
|
24
|
+
constructor(element) {
|
|
25
|
+
this.originalElement = element;
|
|
26
|
+
return new Proxy(this, {
|
|
27
|
+
get(target, prop, receiver) {
|
|
28
|
+
if (prop in target) {
|
|
29
|
+
return target[prop];
|
|
30
|
+
}
|
|
31
|
+
return target.originalElement[prop];
|
|
32
|
+
},
|
|
33
|
+
set(target, prop, newValue, receiver) {
|
|
34
|
+
if (prop in target) {
|
|
35
|
+
target[prop] = newValue;
|
|
36
|
+
} else {
|
|
37
|
+
target.originalElement[prop] = newValue;
|
|
38
|
+
}
|
|
39
|
+
return true;
|
|
40
|
+
}
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
aHideElement() {
|
|
44
|
+
this.originalElement.hidden = true;
|
|
45
|
+
return this;
|
|
46
|
+
}
|
|
47
|
+
aShowElement() {
|
|
48
|
+
this.originalElement.hidden = false;
|
|
49
|
+
return this;
|
|
50
|
+
}
|
|
51
|
+
aTextContent(content = void 0) {
|
|
52
|
+
var _a;
|
|
53
|
+
if (content === void 0) {
|
|
54
|
+
return (_a = this.originalElement.textContent) != null ? _a : ``;
|
|
55
|
+
}
|
|
56
|
+
this.originalElement.textContent = content.toString();
|
|
57
|
+
return this;
|
|
58
|
+
}
|
|
59
|
+
};
|
|
60
|
+
|
|
22
61
|
// src/AngelsFrontDOMLibrary.ts
|
|
23
|
-
function
|
|
62
|
+
function aLibFindElement(selector) {
|
|
24
63
|
let element;
|
|
25
64
|
if (typeof selector === "undefined") {
|
|
26
|
-
|
|
65
|
+
return null;
|
|
27
66
|
} else if (selector === null) {
|
|
28
|
-
|
|
67
|
+
return null;
|
|
29
68
|
} else if (typeof selector === "string") {
|
|
30
69
|
const findElement = document.querySelector(selector);
|
|
31
70
|
if (!findElement) {
|
|
32
|
-
|
|
71
|
+
return null;
|
|
33
72
|
}
|
|
34
73
|
element = findElement;
|
|
35
74
|
} else if (selector instanceof HTMLElement) {
|
|
36
75
|
element = selector;
|
|
37
76
|
} else if (selector instanceof Element) {
|
|
38
77
|
element = selector;
|
|
78
|
+
} else if (selector instanceof AngelsElementClass) {
|
|
79
|
+
return selector;
|
|
39
80
|
} else {
|
|
40
81
|
element = selector;
|
|
41
82
|
}
|
|
83
|
+
return new AngelsElementClass(element);
|
|
84
|
+
}
|
|
85
|
+
function aLibRequireElement(selector) {
|
|
86
|
+
const element = aLibFindElement(selector);
|
|
87
|
+
if (element) {
|
|
88
|
+
return element;
|
|
89
|
+
}
|
|
90
|
+
throw Error(`Element not found by '${selector}' selector.`);
|
|
91
|
+
}
|
|
92
|
+
function aLibHideElement(selector) {
|
|
93
|
+
const element = aLibRequireElement(selector);
|
|
94
|
+
element.hidden = true;
|
|
95
|
+
return element;
|
|
96
|
+
}
|
|
97
|
+
function aLibShowElement(selector) {
|
|
98
|
+
const element = aLibRequireElement(selector);
|
|
99
|
+
element.hidden = false;
|
|
42
100
|
return element;
|
|
43
101
|
}
|
|
102
|
+
function aLibToggleElement(originalElement, switcher = void 0) {
|
|
103
|
+
const innerElement = aLibRequireElement(originalElement);
|
|
104
|
+
if (switcher === void 0) {
|
|
105
|
+
switcher = !innerElement.hidden;
|
|
106
|
+
}
|
|
107
|
+
if (switcher) {
|
|
108
|
+
return aLibShowElement(innerElement);
|
|
109
|
+
} else {
|
|
110
|
+
return aLibHideElement(innerElement);
|
|
111
|
+
}
|
|
112
|
+
}
|
|
44
113
|
|
|
45
114
|
// src/AngelsFrontAnimationLibrary.ts
|
|
46
|
-
function
|
|
115
|
+
function aLibEngageElement(originalElement, switcher = void 0) {
|
|
116
|
+
return __async(this, null, function* () {
|
|
117
|
+
const innerElement = aLibRequireElement(originalElement);
|
|
118
|
+
if (switcher === void 0) {
|
|
119
|
+
switcher = !innerElement.hidden;
|
|
120
|
+
}
|
|
121
|
+
if (switcher) {
|
|
122
|
+
return yield aLibRevealElement(innerElement);
|
|
123
|
+
} else {
|
|
124
|
+
return yield aLibConcealElement(innerElement);
|
|
125
|
+
}
|
|
126
|
+
});
|
|
127
|
+
}
|
|
128
|
+
function aLibConcealElement(originalElement) {
|
|
47
129
|
return __async(this, null, function* () {
|
|
48
130
|
const innerElement = aLibRequireElement(originalElement);
|
|
49
131
|
const promise = new Promise((resolve) => {
|
|
50
|
-
if (
|
|
132
|
+
if (innerElement.hidden) {
|
|
51
133
|
resolve();
|
|
52
134
|
return;
|
|
53
135
|
}
|
|
@@ -55,42 +137,34 @@ function aLibShowElement(originalElement) {
|
|
|
55
137
|
const animationHandler = () => {
|
|
56
138
|
clearTimeout(timeout);
|
|
57
139
|
innerElement.removeEventListener("animationend", animationHandler);
|
|
140
|
+
innerElement.hidden = true;
|
|
141
|
+
innerElement.classList.remove("a-out-animation");
|
|
58
142
|
resolve();
|
|
59
143
|
};
|
|
60
|
-
innerElement.
|
|
144
|
+
innerElement.classList.add("a-out-animation");
|
|
61
145
|
const animations = innerElement.getAnimations();
|
|
62
146
|
if (animations.length > 0) {
|
|
63
147
|
timeout = setTimeout(() => {
|
|
64
148
|
innerElement.removeEventListener("animationend", animationHandler);
|
|
149
|
+
innerElement.hidden = true;
|
|
150
|
+
innerElement.classList.remove("a-out-animation");
|
|
65
151
|
console.warn("Animation timeout");
|
|
66
152
|
resolve();
|
|
67
153
|
}, 5e3);
|
|
68
154
|
innerElement.addEventListener("animationend", animationHandler);
|
|
69
155
|
} else {
|
|
156
|
+
innerElement.hidden = true;
|
|
70
157
|
resolve();
|
|
71
158
|
}
|
|
72
159
|
});
|
|
73
160
|
return promise;
|
|
74
161
|
});
|
|
75
162
|
}
|
|
76
|
-
function
|
|
77
|
-
return __async(this, null, function* () {
|
|
78
|
-
const innerElement = aLibRequireElement(originalElement);
|
|
79
|
-
if (switcher === void 0) {
|
|
80
|
-
switcher = !innerElement.hidden;
|
|
81
|
-
}
|
|
82
|
-
if (switcher) {
|
|
83
|
-
return yield aLibShowElement(innerElement);
|
|
84
|
-
} else {
|
|
85
|
-
return yield aLibHideElement(innerElement);
|
|
86
|
-
}
|
|
87
|
-
});
|
|
88
|
-
}
|
|
89
|
-
function aLibHideElement(originalElement) {
|
|
163
|
+
function aLibRevealElement(originalElement) {
|
|
90
164
|
return __async(this, null, function* () {
|
|
91
165
|
const innerElement = aLibRequireElement(originalElement);
|
|
92
166
|
const promise = new Promise((resolve) => {
|
|
93
|
-
if (innerElement.hidden) {
|
|
167
|
+
if (!innerElement.hidden) {
|
|
94
168
|
resolve();
|
|
95
169
|
return;
|
|
96
170
|
}
|
|
@@ -98,23 +172,18 @@ function aLibHideElement(originalElement) {
|
|
|
98
172
|
const animationHandler = () => {
|
|
99
173
|
clearTimeout(timeout);
|
|
100
174
|
innerElement.removeEventListener("animationend", animationHandler);
|
|
101
|
-
innerElement.hidden = true;
|
|
102
|
-
innerElement.classList.remove("a-out-animation");
|
|
103
175
|
resolve();
|
|
104
176
|
};
|
|
105
|
-
innerElement.
|
|
177
|
+
innerElement.hidden = false;
|
|
106
178
|
const animations = innerElement.getAnimations();
|
|
107
179
|
if (animations.length > 0) {
|
|
108
180
|
timeout = setTimeout(() => {
|
|
109
181
|
innerElement.removeEventListener("animationend", animationHandler);
|
|
110
|
-
innerElement.hidden = true;
|
|
111
|
-
innerElement.classList.remove("a-out-animation");
|
|
112
182
|
console.warn("Animation timeout");
|
|
113
183
|
resolve();
|
|
114
184
|
}, 5e3);
|
|
115
185
|
innerElement.addEventListener("animationend", animationHandler);
|
|
116
186
|
} else {
|
|
117
|
-
innerElement.hidden = true;
|
|
118
187
|
resolve();
|
|
119
188
|
}
|
|
120
189
|
});
|
|
@@ -122,9 +191,13 @@ function aLibHideElement(originalElement) {
|
|
|
122
191
|
});
|
|
123
192
|
}
|
|
124
193
|
|
|
125
|
-
// src/
|
|
194
|
+
// src/AngelsFrontLoader.ts
|
|
195
|
+
window.aEngageElement = aLibEngageElement;
|
|
196
|
+
window.aConcealElement = aLibConcealElement;
|
|
197
|
+
window.aRevealElement = aLibRevealElement;
|
|
198
|
+
window.aFindElement = aLibFindElement;
|
|
126
199
|
window.aHideElement = aLibHideElement;
|
|
127
200
|
window.aRequireElement = aLibRequireElement;
|
|
128
201
|
window.aShowElement = aLibShowElement;
|
|
129
202
|
window.aToggleElement = aLibToggleElement;
|
|
130
|
-
//# sourceMappingURL=
|
|
203
|
+
//# sourceMappingURL=AngelsFrontLoader.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/AngelsElement.ts","../src/AngelsFrontDOMLibrary.ts","../src/AngelsFrontAnimationLibrary.ts","../src/AngelsFrontLoader.ts"],"sourcesContent":["export type AngelsElement<TElement extends HTMLElement = HTMLElement> = AngelsElementClass<TElement> & TElement;\n\nexport class AngelsElementClass<TElement extends HTMLElement = HTMLElement> {\n\n protected originalElement: TElement;\n\n constructor(element: TElement) {\n\n this.originalElement = element;\n\n return new Proxy(this, {\n get(target: any, prop: string | symbol, receiver: any) {\n if (prop in target) {\n return target[prop];\n }\n return target.originalElement[prop];\n },\n\n set(target: any, prop: string | symbol, newValue: any, receiver: any) {\n if (prop in target) {\n target[prop] = newValue;\n } else {\n target.originalElement[prop] = newValue;\n }\n return true;\n }\n });\n }\n\n aHideElement(): this {\n this.originalElement.hidden = true;\n return this;\n }\n\n aShowElement(): this {\n this.originalElement.hidden = false;\n return this;\n }\n\n aTextContent(): string;\n aTextContent(content: string): this;\n aTextContent(content: string | undefined = undefined): this | string {\n if (content === undefined) {\n return this.originalElement.textContent ?? ``;\n }\n this.originalElement.textContent = content.toString();\n return this;\n }\n}\n","import { AngelsElement, AngelsElementClass } from \"./AngelsElement\";\n\nexport function aLibFindElement<THTMLElement extends HTMLElement>(selector: AngelsSelectorType<THTMLElement>): AngelsElement<THTMLElement> | null {\n\n let element: THTMLElement;\n if (typeof selector === 'undefined') {\n return null;\n } else if (selector === null) {\n return null;\n } else if (typeof selector === 'string') {\n const findElement = document.querySelector<THTMLElement>(selector);\n if (!findElement) {\n return null;\n }\n element = findElement;\n } else if (selector instanceof HTMLElement) {\n element = selector as THTMLElement;\n } else if (selector instanceof Element) {\n element = selector as THTMLElement;\n } else if (selector instanceof AngelsElementClass) {\n return selector as AngelsElement<THTMLElement>;\n } else {\n element = selector;\n }\n return new AngelsElementClass(element) as AngelsElement<THTMLElement>;\n}\n\nexport function aLibRequireElement<THTMLElement extends HTMLElement>(selector: AngelsSelectorType): AngelsElement<THTMLElement> {\n const element = aLibFindElement<THTMLElement>(selector);\n if (element) {\n return element;\n }\n throw Error(`Element not found by '${selector}' selector.`);\n}\n\nexport function aLibHideElement<THTMLElement extends HTMLElement>(selector: AngelsSelectorType): AngelsElement<THTMLElement> {\n const element = aLibRequireElement<THTMLElement>(selector);\n element.hidden = true;\n return element;\n}\n\nexport function aLibShowElement<THTMLElement extends HTMLElement>(selector: AngelsSelectorType): AngelsElement<THTMLElement> {\n const element = aLibRequireElement<THTMLElement>(selector);\n element.hidden = false;\n return element;\n}\n\nexport function aLibToggleElement(originalElement: AngelsSelectorType, switcher: boolean | undefined = undefined) {\n const innerElement = aLibRequireElement(originalElement);\n if (switcher === undefined) {\n switcher = !innerElement.hidden;\n }\n if (switcher) {\n return aLibShowElement(innerElement);\n } else {\n return aLibHideElement(innerElement);\n }\n}\n","import { aLibRequireElement } from \"./AngelsFrontDOMLibrary\";\n\nexport async function aLibEngageElement(originalElement: AngelsSelectorType, switcher: boolean | undefined = undefined) {\n const innerElement = aLibRequireElement(originalElement);\n if (switcher === undefined) {\n switcher = !innerElement.hidden;\n }\n if (switcher) {\n return await aLibRevealElement(innerElement);\n } else {\n return await aLibConcealElement(innerElement);\n }\n}\n\nexport async function aLibConcealElement(originalElement: AngelsSelectorType) {\n const innerElement = aLibRequireElement(originalElement);\n const promise = new Promise<void>((resolve) => {\n\n if (innerElement.hidden) {\n resolve();\n return;\n }\n\n let timeout: NodeJS.Timeout | undefined;\n\n const animationHandler = () => {\n clearTimeout(timeout);\n innerElement.removeEventListener('animationend', animationHandler);\n innerElement.hidden = true;\n innerElement.classList.remove('a-out-animation');\n resolve();\n }\n\n innerElement.classList.add('a-out-animation');\n\n const animations = innerElement.getAnimations();\n if (animations.length > 0) {\n timeout = setTimeout(() => {\n innerElement.removeEventListener('animationend', animationHandler);\n innerElement.hidden = true;\n innerElement.classList.remove('a-out-animation');\n console.warn('Animation timeout');\n resolve();\n }, 5000); // 5 seconds timeout\n innerElement.addEventListener('animationend', animationHandler);\n } else {\n innerElement.hidden = true;\n resolve();\n }\n });\n\n return promise;\n}\n\nexport async function aLibRevealElement(originalElement: AngelsSelectorType) {\n const innerElement = aLibRequireElement(originalElement);\n const promise = new Promise<void>((resolve) => {\n\n if (!innerElement.hidden) {\n resolve();\n return;\n }\n\n let timeout: NodeJS.Timeout | undefined;\n\n const animationHandler = () => {\n clearTimeout(timeout);\n innerElement.removeEventListener('animationend', animationHandler);\n resolve();\n }\n\n innerElement.hidden = false;\n\n const animations = innerElement.getAnimations();\n if (animations.length > 0) {\n timeout = setTimeout(() => {\n innerElement.removeEventListener('animationend', animationHandler);\n console.warn('Animation timeout');\n resolve();\n }, 5000); // 5 seconds timeout\n innerElement.addEventListener('animationend', animationHandler);\n } else {\n resolve();\n }\n });\n\n return promise;\n}\n","import { aLibConcealElement, aLibRevealElement, aLibEngageElement } from \"./AngelsFrontAnimationLibrary\";\n\nwindow.aEngageElement = aLibEngageElement;\nwindow.aConcealElement = aLibConcealElement;\nwindow.aRevealElement = aLibRevealElement;\n\nimport { aLibFindElement, aLibHideElement, aLibRequireElement, aLibShowElement, aLibToggleElement } from \"./AngelsFrontDOMLibrary\";\n\nwindow.aFindElement = aLibFindElement;\nwindow.aHideElement = aLibHideElement;\nwindow.aRequireElement = aLibRequireElement;\nwindow.aShowElement = aLibShowElement;\nwindow.aToggleElement = aLibToggleElement;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAEO,IAAM,qBAAN,MAAqE;AAAA,EAIxE,YAAY,SAAmB;AAE3B,SAAK,kBAAkB;AAEvB,WAAO,IAAI,MAAM,MAAM;AAAA,MACnB,IAAI,QAAa,MAAuB,UAAe;AACnD,YAAI,QAAQ,QAAQ;AAChB,iBAAO,OAAO,IAAI;AAAA,QACtB;AACA,eAAO,OAAO,gBAAgB,IAAI;AAAA,MACtC;AAAA,MAEA,IAAI,QAAa,MAAuB,UAAe,UAAe;AAClE,YAAI,QAAQ,QAAQ;AAChB,iBAAO,IAAI,IAAI;AAAA,QACnB,OAAO;AACH,iBAAO,gBAAgB,IAAI,IAAI;AAAA,QACnC;AACA,eAAO;AAAA,MACX;AAAA,IACJ,CAAC;AAAA,EACL;AAAA,EAEA,eAAqB;AACjB,SAAK,gBAAgB,SAAS;AAC9B,WAAO;AAAA,EACX;AAAA,EAEA,eAAqB;AACjB,SAAK,gBAAgB,SAAS;AAC9B,WAAO;AAAA,EACX;AAAA,EAIA,aAAa,UAA8B,QAA0B;AAzCzE;AA0CQ,QAAI,YAAY,QAAW;AACvB,cAAO,UAAK,gBAAgB,gBAArB,YAAoC;AAAA,IAC/C;AACA,SAAK,gBAAgB,cAAc,QAAQ,SAAS;AACpD,WAAO;AAAA,EACX;AACJ;;;AC9CO,SAAS,gBAAkD,UAAgF;AAE9I,MAAI;AACJ,MAAI,OAAO,aAAa,aAAa;AACjC,WAAO;AAAA,EACX,WAAW,aAAa,MAAM;AAC1B,WAAO;AAAA,EACX,WAAW,OAAO,aAAa,U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BAAa,iBAAiB,gBAAgB,gBAAgB;AAAA,MAClE,OAAO;AACH,gBAAQ;AAAA,MACZ;AAAA,IACJ,CAAC;AAED,WAAO;AAAA,EACX;AAAA;;;ACrFA,OAAO,iBAAiB;AACxB,OAAO,kBAAkB;AACzB,OAAO,iBAAiB;AAIxB,OAAO,eAAe;AACtB,OAAO,eAAe;AACtB,OAAO,kBAAkB;AACzB,OAAO,eAAe;AACtB,OAAO,iBAAiB;","names":[]}
|
package/package.json
CHANGED
package/sass/AngelsDesign.scss
CHANGED
|
@@ -9,50 +9,110 @@
|
|
|
9
9
|
|
|
10
10
|
.a-desktops-only {
|
|
11
11
|
|
|
12
|
-
@media (
|
|
12
|
+
@media (max-width: $a-laptop-max-width) {
|
|
13
13
|
display: none;
|
|
14
14
|
}
|
|
15
15
|
}
|
|
16
16
|
|
|
17
17
|
.a-mobile-only {
|
|
18
|
-
@media (min-width: $a-
|
|
18
|
+
@media (min-width: $a-tablet-min-width) {
|
|
19
19
|
display: none;
|
|
20
20
|
}
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
.a-tablet-only {
|
|
24
|
-
@media (
|
|
24
|
+
@media (max-width: $a-mobile-max-width) {
|
|
25
|
+
display: none;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
@media (min-width: $a-laptop-min-width) {
|
|
25
29
|
display: none;
|
|
26
30
|
}
|
|
27
31
|
}
|
|
28
32
|
|
|
29
33
|
.a-laptop-only {
|
|
30
|
-
@media (
|
|
34
|
+
@media (max-width: $a-tablet-max-width) {
|
|
35
|
+
display: none;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
@media (min-width: $a-desktop-min-width) {
|
|
31
39
|
display: none;
|
|
32
40
|
}
|
|
33
41
|
}
|
|
34
42
|
|
|
35
43
|
.a-desktop-only {
|
|
36
|
-
@media (
|
|
44
|
+
@media (max-width: $a-laptop-max-width) {
|
|
45
|
+
display: none;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
@media (min-width: $a-large-min-width) {
|
|
37
49
|
display: none;
|
|
38
50
|
}
|
|
39
51
|
}
|
|
40
52
|
|
|
41
53
|
.a-large-only {
|
|
42
|
-
@media (
|
|
54
|
+
@media (max-width: $a-desktop-max-width) {
|
|
55
|
+
display: none;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
@media (min-width: $a-extra-min-width) {
|
|
43
59
|
display: none;
|
|
44
60
|
}
|
|
45
61
|
}
|
|
46
62
|
|
|
47
63
|
.a-extra-only {
|
|
64
|
+
@media (max-width: $a-large-max-width) {
|
|
65
|
+
display: none;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.a-mobile-off {
|
|
70
|
+
@media (max-width: $a-mobile-max-width) {
|
|
71
|
+
display: none;
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
.a-tablet-off {
|
|
76
|
+
@media (min-width: $a-tablet-min-width) and (max-width: $a-tablet-max-width) {
|
|
77
|
+
display: none;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
.a-laptop-off {
|
|
82
|
+
@media (min-width: $a-laptop-min-width) and (max-width: $a-laptop-max-width) {
|
|
83
|
+
display: none;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.a-desktop-off {
|
|
88
|
+
@media (min-width: $a-desktop-min-width) and (max-width: $a-desktop-max-width) {
|
|
89
|
+
display: none;
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.a-large-off {
|
|
94
|
+
@media (min-width: $a-large-min-width) and (max-width: $a-large-max-width) {
|
|
95
|
+
display: none;
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.a-extra-off {
|
|
48
100
|
@media (min-width: $a-extra-min-width) {
|
|
49
101
|
display: none;
|
|
50
102
|
}
|
|
51
103
|
}
|
|
52
104
|
|
|
105
|
+
|
|
106
|
+
|
|
53
107
|
/**
|
|
54
108
|
* a Range and Less section
|
|
55
109
|
*/
|
|
110
|
+
.a-mobile-and-less {
|
|
111
|
+
@media (min-width: $a-tablet-min-width) {
|
|
112
|
+
display: none;
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
|
|
56
116
|
.a-tablet-and-less {
|
|
57
117
|
@media (min-width: $a-laptop-min-width) {
|
|
58
118
|
display: none;
|
|
@@ -77,9 +137,19 @@
|
|
|
77
137
|
}
|
|
78
138
|
}
|
|
79
139
|
|
|
140
|
+
.a-extra-and-less {
|
|
141
|
+
// It displays always
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
|
|
80
145
|
/**
|
|
81
146
|
* a Range and More section
|
|
82
147
|
*/
|
|
148
|
+
|
|
149
|
+
.a-mobile-and-more {
|
|
150
|
+
// It displays always
|
|
151
|
+
}
|
|
152
|
+
|
|
83
153
|
.a-tablet-and-more {
|
|
84
154
|
@media (max-width: $a-mobile-max-width) {
|
|
85
155
|
display: none;
|
|
@@ -102,4 +172,10 @@
|
|
|
102
172
|
@media (max-width: $a-desktop-max-width) {
|
|
103
173
|
display: none;
|
|
104
174
|
}
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
.a-extra-and-more {
|
|
178
|
+
@media (max-width: $a-large-max-width) {
|
|
179
|
+
display: none;
|
|
180
|
+
}
|
|
105
181
|
}
|