Initial commit

This commit is contained in:
2020-11-16 21:22:51 +01:00
commit 25d5bd4322
66 changed files with 8393 additions and 0 deletions

0
theme/helpers/.gitkeep Normal file
View File

6
theme/helpers/aspect.js Normal file
View File

@@ -0,0 +1,6 @@
module.exports = (width, height) => {
if (width <0 || !width || height < 0 || !height) {
return null;
}
return width/height;
};

View File

@@ -0,0 +1,6 @@
module.exports = (a, b) => {
if (isNaN(a) || isNaN(b)) {
return null;
}
return a * b;
};

View File

@@ -0,0 +1,9 @@
module.exports = (filename) => {
let dot = filename.lastIndexOf(".");
if (dot < 0) {
return filename;
}
return filename.substring(0, dot);
};