expack_gem 0.1.0 → 0.2.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.
- checksums.yaml +4 -4
- data/assets/javascript/expack.bundle.js +284 -118
- data/assets/javascript/expack.js +266 -147
- data/assets/javascript/expack.min.js +1 -1
- data/assets/stylesheet/expack.css +82 -20
- data/lib/expack_gem/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 19d89d1b866f43e8d753a1c34e798b39017b92f2b5f4ff02dca36c0f71c727e1
|
4
|
+
data.tar.gz: 0e5a9be051534da32575b05887acad219620c8608b3f2d28371a9f3db679512e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e6d51b87c760866b4eadd1da7b493e2b5b9b299cd453d1c88f3d4420bd2a5b459ba44452b3fb22f1c8682738de2d0f1d189f0defc0cd9d292142bbd3c269324d
|
7
|
+
data.tar.gz: 12aabdae7595c0cef371329cc052ae6d8a7e7c937dec838b3ab4a5cf2c5fe8a2a168d1a9a7b5108574225e1c2af410d084eb3d14e231aca476b4e668805e9176
|
@@ -1,118 +1,284 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
1
|
+
function modalFunction() {
|
2
|
+
var modal = document.getElementsByClassName("modal");
|
3
|
+
var modalBtn = document.getElementsByClassName("modal-btn");
|
4
|
+
var closeClick = document.getElementsByClassName("close");
|
5
|
+
modalBtn.onclick = function () {
|
6
|
+
modal.style.display = "block";
|
7
|
+
};
|
8
|
+
closeClick.onclick = function () {
|
9
|
+
modal.style.display = "none";
|
10
|
+
};
|
11
|
+
window.onclick = function (event) {
|
12
|
+
if (event.target == modal) {
|
13
|
+
modal.style.display = "none";
|
14
|
+
}
|
15
|
+
};
|
16
|
+
}
|
17
|
+
|
18
|
+
function loginOption() {
|
19
|
+
var emailClass = document.getElementsByClassName("login-email");
|
20
|
+
var passwordClass = document.getElementsByClassName("login-password");
|
21
|
+
var usernameClass = document.getElementsByClassName("login-username");
|
22
|
+
function hasRequiredClass(elements) {
|
23
|
+
for (var i = 0; i < elements.length; i++) {
|
24
|
+
if (elements[i].classList.contains('required')) {
|
25
|
+
return true;
|
26
|
+
}
|
27
|
+
}
|
28
|
+
return false;
|
29
|
+
}
|
30
|
+
var registerBtn = document.getElementsByClassName("register-btn");
|
31
|
+
if (registerBtn.length > 0) {
|
32
|
+
for (var i = 0; i < registerBtn.length; i++) {
|
33
|
+
registerBtn[i].onclick = function () {
|
34
|
+
var emailRequired = hasRequiredClass(emailClass);
|
35
|
+
var passwordRequired = hasRequiredClass(passwordClass);
|
36
|
+
var usernameRequired = hasRequiredClass(usernameClass);
|
37
|
+
if (emailRequired && emailClass.length > 0) {
|
38
|
+
var emailValue = emailClass[0].value;
|
39
|
+
localStorage.setItem("email saved", emailValue);
|
40
|
+
document.cookie = "userEmail=".concat(emailValue);
|
41
|
+
}
|
42
|
+
if (passwordRequired && passwordClass.length > 0) {
|
43
|
+
var passwordValue = passwordClass[0].value;
|
44
|
+
localStorage.setItem("password saved", passwordValue);
|
45
|
+
document.cookie = "userPassword=".concat(passwordValue);
|
46
|
+
}
|
47
|
+
if (usernameRequired && usernameClass.length > 0) {
|
48
|
+
var usernameValue = usernameClass[0].value;
|
49
|
+
localStorage.setItem("username saved", usernameValue);
|
50
|
+
document.cookie = "userUsername=".concat(usernameValue);
|
51
|
+
}
|
52
|
+
};
|
53
|
+
}
|
54
|
+
} else {
|
55
|
+
console.log("no register");
|
56
|
+
}
|
57
|
+
}
|
58
|
+
|
59
|
+
function unicodeFunction() {
|
60
|
+
document.addEventListener("DOMContentLoaded", function () {
|
61
|
+
var unicode = document.querySelectorAll("[class*='u-']");
|
62
|
+
unicode.forEach(function (element) {
|
63
|
+
var classes = element.className.split(" ");
|
64
|
+
classes.forEach(function (cls) {
|
65
|
+
if (cls.startsWith("c")) {
|
66
|
+
var unicodeChar = cls.substring(4);
|
67
|
+
element.textConent = unicodeMap[unicodeChar];
|
68
|
+
}
|
69
|
+
});
|
70
|
+
});
|
71
|
+
});
|
72
|
+
}
|
73
|
+
|
74
|
+
function copyClip() {
|
75
|
+
var copyText = document.querySelectorAll("[class^='copy-text'");
|
76
|
+
copyText.forEach(function (elements) {
|
77
|
+
elements.focus();
|
78
|
+
elements.select();
|
79
|
+
elements.setSelectionRange(0, 99999);
|
80
|
+
navigator.clipboard.writeText(elements.value);
|
81
|
+
alert("Copied Text: " + elements.value);
|
82
|
+
});
|
83
|
+
}
|
84
|
+
|
85
|
+
// import $ from "jquery";
|
86
|
+
function expackExport() {
|
87
|
+
document.addEventListener("DOMContentLoaded", function () {
|
88
|
+
var bgElements = document.querySelectorAll("[class*='bg-']");
|
89
|
+
bgElements.forEach(function (element) {
|
90
|
+
var classes = element.className.split(" ");
|
91
|
+
classes.forEach(function (cls) {
|
92
|
+
if (cls.startsWith("bg-")) {
|
93
|
+
var colorCode = cls.substring(3);
|
94
|
+
if (/^[0-9A-Fa-f]{6}$/.test(colorCode)) {
|
95
|
+
element.style.backgroundColor = "#".concat(colorCode);
|
96
|
+
}
|
97
|
+
}
|
98
|
+
});
|
99
|
+
});
|
100
|
+
var mnElements = document.querySelectorAll("[class*='fr-']");
|
101
|
+
mnElements.forEach(function (element) {
|
102
|
+
var classes = element.className.split(" ");
|
103
|
+
classes.forEach(function (cls) {
|
104
|
+
if (cls.startsWith("fr-")) {
|
105
|
+
var colorCode = cls.substring(3);
|
106
|
+
if (/^[0-9A-Fa-f]{6}$/.test(colorCode)) {
|
107
|
+
element.style.color = "#".concat(colorCode);
|
108
|
+
}
|
109
|
+
}
|
110
|
+
});
|
111
|
+
});
|
112
|
+
var fontWeightClass = document.querySelectorAll("[class^='fw-']");
|
113
|
+
fontWeightClass.forEach(function (element) {
|
114
|
+
var classes = element.className.split(" ");
|
115
|
+
classes.forEach(function (cls) {
|
116
|
+
if (cls.startsWith("fw-")) {
|
117
|
+
var fwValue = cls.substring(3);
|
118
|
+
if (/^\d+px?$/.test(fwValue)) {
|
119
|
+
element.style.fontWeight = fwValue;
|
120
|
+
}
|
121
|
+
}
|
122
|
+
});
|
123
|
+
});
|
124
|
+
|
125
|
+
/*const closingClass = document.querySelectorAll("[class*='close']");
|
126
|
+
closingClass.forEach(element => {
|
127
|
+
element.innerHTML = "×";
|
128
|
+
element.addEventListener("click", function(){
|
129
|
+
element.style.visibility = "hidden";
|
130
|
+
});
|
131
|
+
});*/
|
132
|
+
/*const elementAlignment = document.querySelectorAll("[class*='align-']");
|
133
|
+
elementAlignment.forEach(element => {
|
134
|
+
const classes = element.className.split(" ");
|
135
|
+
classes.forEach(cls => {
|
136
|
+
if (cls.startsWith("align-")) {
|
137
|
+
const alignment = cls.substring(5);
|
138
|
+
if (alignment === "center" || alignment === "left" || alignment === "right") {
|
139
|
+
element.style.textAlign = alignment;
|
140
|
+
$(elementAlignment).css("text-align", alignment);
|
141
|
+
}
|
142
|
+
}
|
143
|
+
});
|
144
|
+
});*/
|
145
|
+
var elementPadding = document.querySelectorAll("[class^='pad-']");
|
146
|
+
elementPadding.forEach(function (element) {
|
147
|
+
var classes = element.className.split(" ");
|
148
|
+
classes.forEach(function (cls) {
|
149
|
+
if (cls.startsWith("pad-")) {
|
150
|
+
var paddingValue = cls.substring(5);
|
151
|
+
if (cls.startsWith("pad-t-")) {
|
152
|
+
if (/^\d+px?$/.test(paddingValue)) {
|
153
|
+
element.style.paddingTop = paddingValue;
|
154
|
+
}
|
155
|
+
} else if (cls.startsWith("pad-l-")) {
|
156
|
+
// left
|
157
|
+
if (/^\d+px?$/.test(paddingValue)) {
|
158
|
+
element.style.paddingLeft = paddingValue;
|
159
|
+
}
|
160
|
+
} else if (cls.startsWith("pad-r-")) {
|
161
|
+
// right
|
162
|
+
if (/^\d+px?$/.test(paddingValue)) {
|
163
|
+
element.style.paddingRight = paddingValue;
|
164
|
+
}
|
165
|
+
} else if (cls.startsWith("pad-b-")) {
|
166
|
+
// bottom
|
167
|
+
if (/^\d+px?$/.test(paddingValue)) {
|
168
|
+
element.style.paddingBottom = paddingValue;
|
169
|
+
}
|
170
|
+
} else {
|
171
|
+
if (/^\d+px?$/.test(paddingValue)) {
|
172
|
+
// padding all
|
173
|
+
element.style.padding = paddingValue;
|
174
|
+
}
|
175
|
+
}
|
176
|
+
}
|
177
|
+
});
|
178
|
+
});
|
179
|
+
|
180
|
+
// figure out how to have this work for all borders
|
181
|
+
var borderElements = document.querySelectorAll("[data-border]");
|
182
|
+
borderElements.forEach(function (element) {
|
183
|
+
var borderData = element.getAttribute('data-border');
|
184
|
+
if (borderData) {
|
185
|
+
var parts = borderData.split(" ");
|
186
|
+
parts.forEach(function (part) {
|
187
|
+
if (part.startsWith("color-")) {
|
188
|
+
var colorCode = part.substring(7);
|
189
|
+
if (/^[0-9A-Fa-f]{6}$/.test(colorCode)) {
|
190
|
+
element.style.borderColor = "#".concat(colorCode);
|
191
|
+
}
|
192
|
+
}
|
193
|
+
if (part.startsWith("radius-")) {
|
194
|
+
var borderRadius = part.substring(7);
|
195
|
+
if (borderRadius.includes("%")) {
|
196
|
+
borderRadius += "%";
|
197
|
+
} else {
|
198
|
+
borderRadius += "px";
|
199
|
+
}
|
200
|
+
element.style.borderRadius = borderRadius;
|
201
|
+
}
|
202
|
+
if (part.startsWith("size-")) {
|
203
|
+
var borderSize = part.substring(7);
|
204
|
+
element.style.borderWidth = borderSize;
|
205
|
+
}
|
206
|
+
});
|
207
|
+
}
|
208
|
+
});
|
209
|
+
var imageDimension = document.querySelectorAll("[data-image]");
|
210
|
+
imageDimension.forEach(function (element) {
|
211
|
+
var imageData = element.getAttribute('data-image');
|
212
|
+
if (imageData) {
|
213
|
+
var parts = imageData.split(" ");
|
214
|
+
parts.forEach(function (part) {
|
215
|
+
if (part.startsWith("height-")) {
|
216
|
+
var imageHeight = part.substring(7);
|
217
|
+
if (imageHeight.includes("%")) {
|
218
|
+
imageHeight += "%";
|
219
|
+
} else if (imageHeight.includes("em") || imageHeight.includes("-em")) {
|
220
|
+
imageHeight += "em";
|
221
|
+
} else {
|
222
|
+
imageHeight += "px";
|
223
|
+
}
|
224
|
+
element.style.height = imageHeight;
|
225
|
+
}
|
226
|
+
if (part.startsWith("width-")) {
|
227
|
+
var imageWidth = part.substring(6);
|
228
|
+
if (imageWidth.includes("%")) {
|
229
|
+
imageWidth += "%";
|
230
|
+
} else if (imageWidth.includes("em") || imageWidth.includes("-em")) {
|
231
|
+
imageWidth += "em";
|
232
|
+
} else {
|
233
|
+
imageWidth += "px";
|
234
|
+
}
|
235
|
+
element.style.width = imageWidth;
|
236
|
+
}
|
237
|
+
});
|
238
|
+
}
|
239
|
+
});
|
240
|
+
var marginCheck = document.querySelectorAll("[data-margin]");
|
241
|
+
marginCheck.forEach(function (element) {
|
242
|
+
var parts = element.className.split(" ");
|
243
|
+
parts.forEach(function (part) {
|
244
|
+
if (part.startsWith("a-")) {
|
245
|
+
var everyMargin = part.substring(5);
|
246
|
+
element.style.margin = everyMargin + "px";
|
247
|
+
} else if (part.startsWith("r-")) {
|
248
|
+
var rightMargin = part.substring(5);
|
249
|
+
element.style.marginRight = rightMargin + "px";
|
250
|
+
} else if (part.startsWith("l-")) {
|
251
|
+
var leftMargin = part.substring(5);
|
252
|
+
element.style.marginLeft = leftMargin + "px";
|
253
|
+
} else if (part.startsWith("t-")) {
|
254
|
+
var topMargin = part.substring(5);
|
255
|
+
element.style.marginTop = topMargin + "px";
|
256
|
+
} else if (part.startsWith("b-")) {
|
257
|
+
var bottomMargin = part.substring(5);
|
258
|
+
element.style.marginBottom = bottomMargin + "px";
|
259
|
+
}
|
260
|
+
});
|
261
|
+
});
|
262
|
+
var indexValue = document.querySelectorAll("[data-index]");
|
263
|
+
indexValue.forEach(function (element) {
|
264
|
+
var indexData = element.getAttribute('data-index');
|
265
|
+
if (indexData) {
|
266
|
+
var parts = indexData.split(" ");
|
267
|
+
parts.forEach(function (part) {
|
268
|
+
if (part.startsWith("z-")) {
|
269
|
+
var zIndex = part.substring(5);
|
270
|
+
element.style.zIndex = zIndex;
|
271
|
+
}
|
272
|
+
});
|
273
|
+
}
|
274
|
+
});
|
275
|
+
});
|
276
|
+
modalFunction();
|
277
|
+
loginOption();
|
278
|
+
unicodeFunction();
|
279
|
+
copyClip();
|
280
|
+
}
|
281
|
+
var global = expackExport();
|
282
|
+
|
283
|
+
export { global as default };
|
284
|
+
|
data/assets/javascript/expack.js
CHANGED
@@ -1,165 +1,284 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
document.
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
}
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
1
|
+
function modalFunction() {
|
2
|
+
var modal = document.getElementsByClassName("modal");
|
3
|
+
var modalBtn = document.getElementsByClassName("modal-btn");
|
4
|
+
var closeClick = document.getElementsByClassName("close");
|
5
|
+
modalBtn.onclick = function () {
|
6
|
+
modal.style.display = "block";
|
7
|
+
};
|
8
|
+
closeClick.onclick = function () {
|
9
|
+
modal.style.display = "none";
|
10
|
+
};
|
11
|
+
window.onclick = function (event) {
|
12
|
+
if (event.target == modal) {
|
13
|
+
modal.style.display = "none";
|
14
|
+
}
|
15
|
+
};
|
16
|
+
}
|
17
|
+
|
18
|
+
function loginOption() {
|
19
|
+
var emailClass = document.getElementsByClassName("login-email");
|
20
|
+
var passwordClass = document.getElementsByClassName("login-password");
|
21
|
+
var usernameClass = document.getElementsByClassName("login-username");
|
22
|
+
function hasRequiredClass(elements) {
|
23
|
+
for (var i = 0; i < elements.length; i++) {
|
24
|
+
if (elements[i].classList.contains('required')) {
|
25
|
+
return true;
|
26
|
+
}
|
27
|
+
}
|
28
|
+
return false;
|
29
|
+
}
|
30
|
+
var registerBtn = document.getElementsByClassName("register-btn");
|
31
|
+
if (registerBtn.length > 0) {
|
32
|
+
for (var i = 0; i < registerBtn.length; i++) {
|
33
|
+
registerBtn[i].onclick = function () {
|
34
|
+
var emailRequired = hasRequiredClass(emailClass);
|
35
|
+
var passwordRequired = hasRequiredClass(passwordClass);
|
36
|
+
var usernameRequired = hasRequiredClass(usernameClass);
|
37
|
+
if (emailRequired && emailClass.length > 0) {
|
38
|
+
var emailValue = emailClass[0].value;
|
39
|
+
localStorage.setItem("email saved", emailValue);
|
40
|
+
document.cookie = "userEmail=".concat(emailValue);
|
41
|
+
}
|
42
|
+
if (passwordRequired && passwordClass.length > 0) {
|
43
|
+
var passwordValue = passwordClass[0].value;
|
44
|
+
localStorage.setItem("password saved", passwordValue);
|
45
|
+
document.cookie = "userPassword=".concat(passwordValue);
|
46
|
+
}
|
47
|
+
if (usernameRequired && usernameClass.length > 0) {
|
48
|
+
var usernameValue = usernameClass[0].value;
|
49
|
+
localStorage.setItem("username saved", usernameValue);
|
50
|
+
document.cookie = "userUsername=".concat(usernameValue);
|
51
|
+
}
|
52
|
+
};
|
53
|
+
}
|
54
|
+
} else {
|
55
|
+
console.log("no register");
|
56
|
+
}
|
57
|
+
}
|
58
|
+
|
59
|
+
function unicodeFunction() {
|
60
|
+
document.addEventListener("DOMContentLoaded", function () {
|
61
|
+
var unicode = document.querySelectorAll("[class*='u-']");
|
62
|
+
unicode.forEach(function (element) {
|
63
|
+
var classes = element.className.split(" ");
|
64
|
+
classes.forEach(function (cls) {
|
65
|
+
if (cls.startsWith("c")) {
|
66
|
+
var unicodeChar = cls.substring(4);
|
67
|
+
element.textConent = unicodeMap[unicodeChar];
|
68
|
+
}
|
21
69
|
});
|
70
|
+
});
|
71
|
+
});
|
72
|
+
}
|
73
|
+
|
74
|
+
function copyClip() {
|
75
|
+
var copyText = document.querySelectorAll("[class^='copy-text'");
|
76
|
+
copyText.forEach(function (elements) {
|
77
|
+
elements.focus();
|
78
|
+
elements.select();
|
79
|
+
elements.setSelectionRange(0, 99999);
|
80
|
+
navigator.clipboard.writeText(elements.value);
|
81
|
+
alert("Copied Text: " + elements.value);
|
22
82
|
});
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
83
|
+
}
|
84
|
+
|
85
|
+
// import $ from "jquery";
|
86
|
+
function expackExport() {
|
87
|
+
document.addEventListener("DOMContentLoaded", function () {
|
88
|
+
var bgElements = document.querySelectorAll("[class*='bg-']");
|
89
|
+
bgElements.forEach(function (element) {
|
90
|
+
var classes = element.className.split(" ");
|
91
|
+
classes.forEach(function (cls) {
|
92
|
+
if (cls.startsWith("bg-")) {
|
93
|
+
var colorCode = cls.substring(3);
|
94
|
+
if (/^[0-9A-Fa-f]{6}$/.test(colorCode)) {
|
95
|
+
element.style.backgroundColor = "#".concat(colorCode);
|
32
96
|
}
|
97
|
+
}
|
33
98
|
});
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
if (
|
42
|
-
|
43
|
-
if (/^\d+px?$/.test(fwValue)) {
|
44
|
-
element.style.fontWeight = fwValue;
|
45
|
-
}
|
99
|
+
});
|
100
|
+
var mnElements = document.querySelectorAll("[class*='fr-']");
|
101
|
+
mnElements.forEach(function (element) {
|
102
|
+
var classes = element.className.split(" ");
|
103
|
+
classes.forEach(function (cls) {
|
104
|
+
if (cls.startsWith("fr-")) {
|
105
|
+
var colorCode = cls.substring(3);
|
106
|
+
if (/^[0-9A-Fa-f]{6}$/.test(colorCode)) {
|
107
|
+
element.style.color = "#".concat(colorCode);
|
46
108
|
}
|
109
|
+
}
|
47
110
|
});
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
if (
|
56
|
-
|
57
|
-
if (alignment === "center" || alignment === "left" || alignment === "right") {
|
58
|
-
element.style.textAlign = alignment;
|
59
|
-
}
|
111
|
+
});
|
112
|
+
var fontWeightClass = document.querySelectorAll("[class^='fw-']");
|
113
|
+
fontWeightClass.forEach(function (element) {
|
114
|
+
var classes = element.className.split(" ");
|
115
|
+
classes.forEach(function (cls) {
|
116
|
+
if (cls.startsWith("fw-")) {
|
117
|
+
var fwValue = cls.substring(3);
|
118
|
+
if (/^\d+px?$/.test(fwValue)) {
|
119
|
+
element.style.fontWeight = fwValue;
|
60
120
|
}
|
121
|
+
}
|
61
122
|
});
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
123
|
+
});
|
124
|
+
|
125
|
+
/*const closingClass = document.querySelectorAll("[class*='close']");
|
126
|
+
closingClass.forEach(element => {
|
127
|
+
element.innerHTML = "×";
|
128
|
+
element.addEventListener("click", function(){
|
129
|
+
element.style.visibility = "hidden";
|
130
|
+
});
|
131
|
+
});*/
|
132
|
+
/*const elementAlignment = document.querySelectorAll("[class*='align-']");
|
133
|
+
elementAlignment.forEach(element => {
|
134
|
+
const classes = element.className.split(" ");
|
135
|
+
classes.forEach(cls => {
|
136
|
+
if (cls.startsWith("align-")) {
|
137
|
+
const alignment = cls.substring(5);
|
138
|
+
if (alignment === "center" || alignment === "left" || alignment === "right") {
|
139
|
+
element.style.textAlign = alignment;
|
140
|
+
$(elementAlignment).css("text-align", alignment);
|
141
|
+
}
|
142
|
+
}
|
143
|
+
});
|
144
|
+
});*/
|
145
|
+
var elementPadding = document.querySelectorAll("[class^='pad-']");
|
146
|
+
elementPadding.forEach(function (element) {
|
147
|
+
var classes = element.className.split(" ");
|
148
|
+
classes.forEach(function (cls) {
|
149
|
+
if (cls.startsWith("pad-")) {
|
150
|
+
var paddingValue = cls.substring(5);
|
151
|
+
if (cls.startsWith("pad-t-")) {
|
152
|
+
if (/^\d+px?$/.test(paddingValue)) {
|
153
|
+
element.style.paddingTop = paddingValue;
|
154
|
+
}
|
155
|
+
} else if (cls.startsWith("pad-l-")) {
|
156
|
+
// left
|
157
|
+
if (/^\d+px?$/.test(paddingValue)) {
|
158
|
+
element.style.paddingLeft = paddingValue;
|
159
|
+
}
|
160
|
+
} else if (cls.startsWith("pad-r-")) {
|
161
|
+
// right
|
162
|
+
if (/^\d+px?$/.test(paddingValue)) {
|
163
|
+
element.style.paddingRight = paddingValue;
|
164
|
+
}
|
165
|
+
} else if (cls.startsWith("pad-b-")) {
|
166
|
+
// bottom
|
167
|
+
if (/^\d+px?$/.test(paddingValue)) {
|
168
|
+
element.style.paddingBottom = paddingValue;
|
169
|
+
}
|
170
|
+
} else {
|
171
|
+
if (/^\d+px?$/.test(paddingValue)) {
|
172
|
+
// padding all
|
173
|
+
element.style.padding = paddingValue;
|
174
|
+
}
|
73
175
|
}
|
176
|
+
}
|
74
177
|
});
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
178
|
+
});
|
179
|
+
|
180
|
+
// figure out how to have this work for all borders
|
181
|
+
var borderElements = document.querySelectorAll("[data-border]");
|
182
|
+
borderElements.forEach(function (element) {
|
183
|
+
var borderData = element.getAttribute('data-border');
|
80
184
|
if (borderData) {
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
});
|
185
|
+
var parts = borderData.split(" ");
|
186
|
+
parts.forEach(function (part) {
|
187
|
+
if (part.startsWith("color-")) {
|
188
|
+
var colorCode = part.substring(7);
|
189
|
+
if (/^[0-9A-Fa-f]{6}$/.test(colorCode)) {
|
190
|
+
element.style.borderColor = "#".concat(colorCode);
|
191
|
+
}
|
192
|
+
}
|
193
|
+
if (part.startsWith("radius-")) {
|
194
|
+
var borderRadius = part.substring(7);
|
195
|
+
if (borderRadius.includes("%")) {
|
196
|
+
borderRadius += "%";
|
197
|
+
} else {
|
198
|
+
borderRadius += "px";
|
199
|
+
}
|
200
|
+
element.style.borderRadius = borderRadius;
|
201
|
+
}
|
202
|
+
if (part.startsWith("size-")) {
|
203
|
+
var borderSize = part.substring(7);
|
204
|
+
element.style.borderWidth = borderSize;
|
205
|
+
}
|
206
|
+
});
|
104
207
|
}
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
208
|
+
});
|
209
|
+
var imageDimension = document.querySelectorAll("[data-image]");
|
210
|
+
imageDimension.forEach(function (element) {
|
211
|
+
var imageData = element.getAttribute('data-image');
|
109
212
|
if (imageData) {
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
}
|
136
|
-
element.style.width = imageWidth;
|
137
|
-
}
|
138
|
-
});
|
139
|
-
}
|
140
|
-
});
|
141
|
-
const marginCheck = document.querySelectorAll("[data-margin]");
|
142
|
-
marginCheck.forEach(element => {
|
143
|
-
const parts = element.className.split(" ");
|
144
|
-
if (parts.startsWith("a-")) {
|
145
|
-
const everyMargin = parts.cls(5);
|
146
|
-
element.style.margin = everyMargin;
|
147
|
-
} else if (parts.startsWith("r-")) {
|
148
|
-
const rightMargin = parts.cls(5);
|
149
|
-
element.style.marginRight = rightMargin;
|
150
|
-
} else if (parts.startsWith("l-")) {
|
151
|
-
|
213
|
+
var parts = imageData.split(" ");
|
214
|
+
parts.forEach(function (part) {
|
215
|
+
if (part.startsWith("height-")) {
|
216
|
+
var imageHeight = part.substring(7);
|
217
|
+
if (imageHeight.includes("%")) {
|
218
|
+
imageHeight += "%";
|
219
|
+
} else if (imageHeight.includes("em") || imageHeight.includes("-em")) {
|
220
|
+
imageHeight += "em";
|
221
|
+
} else {
|
222
|
+
imageHeight += "px";
|
223
|
+
}
|
224
|
+
element.style.height = imageHeight;
|
225
|
+
}
|
226
|
+
if (part.startsWith("width-")) {
|
227
|
+
var imageWidth = part.substring(6);
|
228
|
+
if (imageWidth.includes("%")) {
|
229
|
+
imageWidth += "%";
|
230
|
+
} else if (imageWidth.includes("em") || imageWidth.includes("-em")) {
|
231
|
+
imageWidth += "em";
|
232
|
+
} else {
|
233
|
+
imageWidth += "px";
|
234
|
+
}
|
235
|
+
element.style.width = imageWidth;
|
236
|
+
}
|
237
|
+
});
|
152
238
|
}
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
239
|
+
});
|
240
|
+
var marginCheck = document.querySelectorAll("[data-margin]");
|
241
|
+
marginCheck.forEach(function (element) {
|
242
|
+
var parts = element.className.split(" ");
|
243
|
+
parts.forEach(function (part) {
|
244
|
+
if (part.startsWith("a-")) {
|
245
|
+
var everyMargin = part.substring(5);
|
246
|
+
element.style.margin = everyMargin + "px";
|
247
|
+
} else if (part.startsWith("r-")) {
|
248
|
+
var rightMargin = part.substring(5);
|
249
|
+
element.style.marginRight = rightMargin + "px";
|
250
|
+
} else if (part.startsWith("l-")) {
|
251
|
+
var leftMargin = part.substring(5);
|
252
|
+
element.style.marginLeft = leftMargin + "px";
|
253
|
+
} else if (part.startsWith("t-")) {
|
254
|
+
var topMargin = part.substring(5);
|
255
|
+
element.style.marginTop = topMargin + "px";
|
256
|
+
} else if (part.startsWith("b-")) {
|
257
|
+
var bottomMargin = part.substring(5);
|
258
|
+
element.style.marginBottom = bottomMargin + "px";
|
259
|
+
}
|
260
|
+
});
|
261
|
+
});
|
262
|
+
var indexValue = document.querySelectorAll("[data-index]");
|
263
|
+
indexValue.forEach(function (element) {
|
264
|
+
var indexData = element.getAttribute('data-index');
|
157
265
|
if (indexData) {
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
266
|
+
var parts = indexData.split(" ");
|
267
|
+
parts.forEach(function (part) {
|
268
|
+
if (part.startsWith("z-")) {
|
269
|
+
var zIndex = part.substring(5);
|
270
|
+
element.style.zIndex = zIndex;
|
162
271
|
}
|
272
|
+
});
|
163
273
|
}
|
274
|
+
});
|
164
275
|
});
|
165
|
-
|
276
|
+
modalFunction();
|
277
|
+
loginOption();
|
278
|
+
unicodeFunction();
|
279
|
+
copyClip();
|
280
|
+
}
|
281
|
+
var global = expackExport();
|
282
|
+
|
283
|
+
export { global as default };
|
284
|
+
|
@@ -1 +1 @@
|
|
1
|
-
|
1
|
+
var ExPack=function(){"use strict";var t,e,s;return document.addEventListener("DOMContentLoaded",(function(){document.querySelectorAll("[class*='bg-']").forEach((function(t){t.className.split(" ").forEach((function(e){if(e.startsWith("bg-")){var s=e.substring(3);/^[0-9A-Fa-f]{6}$/.test(s)&&(t.style.backgroundColor="#".concat(s))}}))})),document.querySelectorAll("[class*='fr-']").forEach((function(t){t.className.split(" ").forEach((function(e){if(e.startsWith("fr-")){var s=e.substring(3);/^[0-9A-Fa-f]{6}$/.test(s)&&(t.style.color="#".concat(s))}}))})),document.querySelectorAll("[class^='fw-']").forEach((function(t){t.className.split(" ").forEach((function(e){if(e.startsWith("fw-")){var s=e.substring(3);/^\d+px?$/.test(s)&&(t.style.fontWeight=s)}}))})),document.querySelectorAll("[class^='pad-']").forEach((function(t){t.className.split(" ").forEach((function(e){if(e.startsWith("pad-")){var s=e.substring(5);e.startsWith("pad-t-")?/^\d+px?$/.test(s)&&(t.style.paddingTop=s):e.startsWith("pad-l-")?/^\d+px?$/.test(s)&&(t.style.paddingLeft=s):e.startsWith("pad-r-")?/^\d+px?$/.test(s)&&(t.style.paddingRight=s):e.startsWith("pad-b-")?/^\d+px?$/.test(s)&&(t.style.paddingBottom=s):/^\d+px?$/.test(s)&&(t.style.padding=s)}}))})),document.querySelectorAll("[data-border]").forEach((function(t){var e=t.getAttribute("data-border");e&&e.split(" ").forEach((function(e){if(e.startsWith("color-")){var s=e.substring(7);/^[0-9A-Fa-f]{6}$/.test(s)&&(t.style.borderColor="#".concat(s))}if(e.startsWith("radius-")){var a=e.substring(7);a.includes("%")?a+="%":a+="px",t.style.borderRadius=a}if(e.startsWith("size-")){var n=e.substring(7);t.style.borderWidth=n}}))})),document.querySelectorAll("[data-image]").forEach((function(t){var e=t.getAttribute("data-image");e&&e.split(" ").forEach((function(e){if(e.startsWith("height-")){var s=e.substring(7);s.includes("%")?s+="%":s.includes("em")||s.includes("-em")?s+="em":s+="px",t.style.height=s}if(e.startsWith("width-")){var a=e.substring(6);a.includes("%")?a+="%":a.includes("em")||a.includes("-em")?a+="em":a+="px",t.style.width=a}}))})),document.querySelectorAll("[data-margin]").forEach((function(t){t.className.split(" ").forEach((function(e){if(e.startsWith("a-")){var s=e.substring(5);t.style.margin=s+"px"}else if(e.startsWith("r-")){var a=e.substring(5);t.style.marginRight=a+"px"}else if(e.startsWith("l-")){var n=e.substring(5);t.style.marginLeft=n+"px"}else if(e.startsWith("t-")){var r=e.substring(5);t.style.marginTop=r+"px"}else if(e.startsWith("b-")){var i=e.substring(5);t.style.marginBottom=i+"px"}}))})),document.querySelectorAll("[data-index]").forEach((function(t){var e=t.getAttribute("data-index");e&&e.split(" ").forEach((function(e){if(e.startsWith("z-")){var s=e.substring(5);t.style.zIndex=s}}))}))})),t=document.getElementsByClassName("modal"),e=document.getElementsByClassName("modal-btn"),s=document.getElementsByClassName("close"),e.onclick=function(){t.style.display="block"},s.onclick=function(){t.style.display="none"},window.onclick=function(e){e.target==t&&(t.style.display="none")},function(){var t=document.getElementsByClassName("login-email"),e=document.getElementsByClassName("login-password"),s=document.getElementsByClassName("login-username");function a(t){for(var e=0;e<t.length;e++)if(t[e].classList.contains("required"))return!0;return!1}var n=document.getElementsByClassName("register-btn");if(n.length>0)for(var r=0;r<n.length;r++)n[r].onclick=function(){var n=a(t),r=a(e),i=a(s);if(n&&t.length>0){var o=t[0].value;localStorage.setItem("email saved",o),document.cookie="userEmail=".concat(o)}if(r&&e.length>0){var l=e[0].value;localStorage.setItem("password saved",l),document.cookie="userPassword=".concat(l)}if(i&&s.length>0){var c=s[0].value;localStorage.setItem("username saved",c),document.cookie="userUsername=".concat(c)}};else console.log("no register")}(),document.addEventListener("DOMContentLoaded",(function(){document.querySelectorAll("[class*='u-']").forEach((function(t){t.className.split(" ").forEach((function(e){if(e.startsWith("c")){var s=e.substring(4);t.textConent=unicodeMap[s]}}))}))})),void document.querySelectorAll("[class^='copy-text'").forEach((function(t){t.focus(),t.select(),t.setSelectionRange(0,99999),navigator.clipboard.writeText(t.value),alert("Copied Text: "+t.value)}))}();
|
@@ -29,7 +29,7 @@
|
|
29
29
|
font-family: "Trebuchet MS", "Lucida Sans Unicode", "Lucida Grande", "Lucida Sans", Arial, sans-serif;
|
30
30
|
}
|
31
31
|
|
32
|
-
[data-popup=modal] [data-modal=content] .
|
32
|
+
[data-popup=modal] [data-modal=content] .global_header__IlGen {
|
33
33
|
font-weight: bold;
|
34
34
|
text-decoration: none;
|
35
35
|
font-family: "Alegreya Sans SC", sans-serif;
|
@@ -78,70 +78,132 @@
|
|
78
78
|
nav {
|
79
79
|
margin: auto;
|
80
80
|
}
|
81
|
-
nav ul.
|
81
|
+
nav ul.global_nav-list__pDZv2 {
|
82
82
|
list-style-type: none;
|
83
83
|
margin: 0;
|
84
84
|
padding: 0;
|
85
85
|
overflow: hidden;
|
86
86
|
}
|
87
|
-
nav ul.
|
87
|
+
nav ul.global_nav-list__pDZv2 li.global_nav-item__5FV3J {
|
88
88
|
float: left;
|
89
89
|
padding: 5px;
|
90
90
|
}
|
91
|
-
nav ul.
|
91
|
+
nav ul.global_nav-list__pDZv2 li.global_nav-item__5FV3J .global_brand__9j8I3::before {
|
92
92
|
content: "!";
|
93
93
|
}
|
94
|
-
nav ul.
|
94
|
+
nav ul.global_nav-list__pDZv2 li.global_nav-item__5FV3J a.global_nav-link__F1Uas {
|
95
95
|
text-align: center;
|
96
96
|
text-decoration: none;
|
97
97
|
}
|
98
|
-
nav ul.
|
98
|
+
nav ul.global_nav-list__pDZv2 li.global_nav-item__5FV3J a.global_nav-link__F1Uas:hover {
|
99
99
|
filter: brightness(150%);
|
100
100
|
}
|
101
|
-
nav ul.
|
101
|
+
nav ul.global_nav-list__pDZv2 li.global_profile__uSBuY {
|
102
102
|
float: right;
|
103
103
|
padding: 5px;
|
104
104
|
}
|
105
|
-
nav ul.
|
105
|
+
nav ul.global_nav-list__pDZv2 img.global_nav-icon__gslqH {
|
106
106
|
height: 40px;
|
107
107
|
width: 40px;
|
108
108
|
}
|
109
109
|
|
110
|
-
.
|
110
|
+
nav .global_sidenav__-Z4oT ul.global_nav-list__pDZv2 {
|
111
|
+
list-style-type: none;
|
112
|
+
margin: 0;
|
113
|
+
padding: 0;
|
114
|
+
}
|
115
|
+
nav .global_sidenav__-Z4oT ul.global_nav-list__pDZv2 li.global_nav-item__5FV3J {
|
116
|
+
padding: 5px;
|
117
|
+
}
|
118
|
+
nav .global_sidenav__-Z4oT ul.global_nav-list__pDZv2 li.global_nav-item__5FV3J .global_brand__9j8I3::before {
|
119
|
+
content: "!";
|
120
|
+
}
|
121
|
+
nav .global_sidenav__-Z4oT ul.global_nav-list__pDZv2 li.global_nav-item__5FV3J li.global_profile__uSBuY {
|
122
|
+
float: right;
|
123
|
+
padding: 5px;
|
124
|
+
}
|
125
|
+
nav .global_sidenav__-Z4oT ul.global_nav-list__pDZv2 li.global_nav-item__5FV3J a.global_nav-link__F1Uas {
|
126
|
+
text-align: center;
|
127
|
+
text-decoration: none;
|
128
|
+
}
|
129
|
+
nav .global_sidenav__-Z4oT ul.global_nav-list__pDZv2 li.global_nav-item__5FV3J a.global_nav-link__F1Uas:hover {
|
130
|
+
filter: brightness(150%);
|
131
|
+
}
|
132
|
+
nav .global_sidenav__-Z4oT ul.global_nav-list__pDZv2 img.global_nav-icon__gslqH {
|
133
|
+
height: 40px;
|
134
|
+
width: 40px;
|
135
|
+
}
|
136
|
+
|
137
|
+
.global_align-left__RHxSb {
|
111
138
|
float: left;
|
112
139
|
}
|
113
140
|
|
114
|
-
.
|
115
|
-
|
116
|
-
|
141
|
+
.global_align-center__hV74U {
|
142
|
+
justify-content: center;
|
143
|
+
display: flex;
|
117
144
|
text-align: center;
|
145
|
+
margin: 0 auto;
|
118
146
|
}
|
119
147
|
|
120
|
-
.
|
148
|
+
.global_align-right__ZGT5c {
|
121
149
|
float: right;
|
122
150
|
}
|
123
151
|
|
124
|
-
.
|
152
|
+
.global_justify-left__PyPDA {
|
153
|
+
justify-content: left;
|
154
|
+
}
|
155
|
+
|
156
|
+
.global_justify-center__MZme1 {
|
157
|
+
justify-content: center;
|
158
|
+
}
|
159
|
+
|
160
|
+
.global_justify-right__u1a6a {
|
161
|
+
justify-content: right;
|
162
|
+
}
|
163
|
+
|
164
|
+
.global_math__08ce8 .global_times-x__-56vN::before {
|
165
|
+
content: "×";
|
166
|
+
}
|
167
|
+
.global_math__08ce8 .global_divide__2Cux1::before {
|
168
|
+
content: "÷";
|
169
|
+
}
|
170
|
+
.global_math__08ce8 .global_mean__fMsl4::before {
|
171
|
+
content: "x̄";
|
172
|
+
}
|
173
|
+
.global_math__08ce8 .global_sigma__FqIDQ::before {
|
174
|
+
content: "Σ";
|
175
|
+
}
|
176
|
+
.global_math__08ce8 .global_delta__jDnRj::before {
|
177
|
+
content: "Δ";
|
178
|
+
}
|
179
|
+
|
180
|
+
.global_close__rVQEY {
|
125
181
|
color: #aaa;
|
126
182
|
float: right;
|
127
183
|
font-size: 28px;
|
128
184
|
font-weight: bold;
|
129
185
|
}
|
130
|
-
.
|
186
|
+
.global_close__rVQEY::before {
|
131
187
|
content: "×";
|
132
188
|
}
|
133
|
-
.
|
189
|
+
.global_close__rVQEY:hover, .global_close__rVQEY:focus {
|
134
190
|
color: black;
|
135
191
|
text-decoration: none;
|
136
192
|
cursor: pointer;
|
137
193
|
}
|
138
194
|
|
139
|
-
.
|
195
|
+
.global_place-hrz__L1bNO {
|
140
196
|
display: inline;
|
141
197
|
}
|
142
198
|
|
143
|
-
|
144
|
-
|
199
|
+
iframe {
|
200
|
+
margin: auto;
|
201
|
+
}
|
202
|
+
iframe .global_no-border__cEHI5 {
|
203
|
+
border: none;
|
145
204
|
}
|
146
205
|
|
147
|
-
|
206
|
+
.global_disable__OR46N {
|
207
|
+
cursor: move;
|
208
|
+
}
|
209
|
+
/*# sourceMappingURL=expack.esm.css.map */
|
data/lib/expack_gem/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: expack_gem
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- ruby_rose
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-10-02 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description:
|
14
14
|
email:
|