Skip to content

Commit 94fa7c8

Browse files
committed
adding home page
1 parent ad4df43 commit 94fa7c8

File tree

24 files changed

+388
-185
lines changed

24 files changed

+388
-185
lines changed

dist/functionalty.min.js

Lines changed: 43 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,43 @@
1-
function getMid(r,n){return Math.floor((r+n)/2)}function getFactors(n){return[...Array(n+1).keys()].filter(r=>n%r==0)}function randomNum(r,n){return Math.floor(Math.random()*(n-r+1)+r)}function randomBoolean(){return.5<=Math.random()}function randomElementFrom(r){return r[Math.floor(Math.random()*r.length)]}function randomHex(){return"#"+Math.floor(16777215*Math.random()).toString(16).padEnd(6,"0")}function filterArray(r,n){return r.filter(r=>r!=n)}function sumOfArray(r){return r.reduce((r,n)=>r+n,0)}function minArray(r){return Math.min(...r)}function maxArray(r){return Math.max(...r)}function removeDuplicate(t){t.filter(function(r,n){return[...new Set(t)]})}
1+
function getMid(r, n) {
2+
return Math.floor((parseFloat(r) + parseFloat(n)) / 2);
3+
}
4+
function getFactors(n) {
5+
return [...Array(n + 1).keys()].filter((r) => n % r == 0);
6+
}
7+
function randomNum(r, n) {
8+
return Math.floor(Math.random() * (n - r + 1) + r);
9+
}
10+
function randomBoolean() {
11+
return 0.5 <= Math.random();
12+
}
13+
function randomElementFrom(r) {
14+
return r[Math.floor(Math.random() * r.length)];
15+
}
16+
function randomHex() {
17+
return (
18+
"#" +
19+
Math.floor(16777215 * Math.random())
20+
.toString(16)
21+
.padEnd(6, "0")
22+
);
23+
}
24+
function filterArray(r, n) {
25+
return r.filter((r) => r != n);
26+
}
27+
function sumOfArray(r) {
28+
return r.reduce((r, n) => r + n, 0);
29+
}
30+
function minArray(r) {
31+
return Math.min(...r);
32+
}
33+
function maxArray(r) {
34+
return Math.max(...r);
35+
}
36+
function removeDuplicate(t) {
37+
t.filter(function (r, n) {
38+
return [...new Set(t)];
39+
});
40+
}
41+
function throwError() {
42+
return J;
43+
}

functionalty.zip

108 Bytes
Binary file not shown.

gulpfile.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ var uglify = require("gulp-uglify");
99
var rename = require("gulp-rename");
1010
var pug = require("gulp-pug");
1111
var livereload = require("gulp-livereload");
12+
var zip = require("gulp-zip");
1213

1314
// HTML Task
1415
gulp.task("html", () => {
@@ -50,6 +51,7 @@ gulp.task("scripts", () => {
5051

5152
// Functionalty.js File Task
5253
gulp.task("functionalty", () => {
54+
livereload.listen();
5355
require("./server.js");
5456
return gulp
5557
.src("./project/js/functionalty.js")
@@ -58,6 +60,11 @@ gulp.task("functionalty", () => {
5860
.pipe(gulp.dest("./dist"));
5961
});
6062

63+
// Compressing The Dist Folder For The User
64+
gulp.task("compress", () => {
65+
return gulp.src("./dist").pipe(zip("functionalty.zip")).pipe(gulp.dest("./"));
66+
});
67+
6168
// Watch Task (Main Task)
6269
gulp.task("watch", () => {
6370
require("./server.js");

package-lock.json

Lines changed: 86 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
"homepage": "https://github.com/Ali-Eldeba/functionalty.js#readme",
1919
"devDependencies": {
2020
"@babel/core": "^7.17.12",
21+
"@types/livereload": "^0.9.2",
2122
"gulp": "^4.0.2",
2223
"gulp-autoprefixer": "^8.0.0",
2324
"gulp-babel": "^8.0.0",
@@ -28,6 +29,7 @@
2829
"gulp-rename": "^2.0.0",
2930
"gulp-sass": "^5.1.0",
3031
"gulp-uglify": "^3.0.2",
32+
"gulp-zip": "^5.1.0",
3133
"sass": "^1.52.0"
3234
},
3335
"dependencies": {

project/css/_global.scss

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
@import "./library/variables.scss";
12
* {
23
margin: 0;
34
padding: 0;
@@ -6,6 +7,12 @@
67
body {
78
font-family: "Cairo", sans-serif;
89
}
10+
html {
11+
scroll-behavior: smooth;
12+
}
13+
::selection {
14+
background-color: $selection-color !important;
15+
}
916
a {
1017
text-decoration: none !important;
1118
color: black !important;
File renamed without changes.

project/css/layouts/_github.scss

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
@import "../library/variables.scss";
2+
.github {
3+
background-color: $soft-black;
4+
height: 30px;
5+
color: #fff;
6+
a {
7+
color: $js !important;
8+
&:hover {
9+
text-decoration: underline !important;
10+
}
11+
}
12+
}

project/css/layouts/header.scss renamed to project/css/layouts/_header.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
@import "../library/variables";
22
nav {
33
background-color: $js;
4+
height: 60px;
5+
box-shadow: 0px 5px 40px rgb(0 0 0 / 20%);
46
.container {
57
display: flex;
68
align-items: center;

project/css/library/_loading.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
background: $js;
99
display: flex;
1010
align-items: center;
11+
z-index: 999;
1112
}
1213

1314
.loader {
@@ -18,6 +19,7 @@
1819
top: 50%;
1920
left: 50%;
2021
transform: translate(-50%, -50%);
22+
z-index: 1000;
2123
}
2224

2325
.dot {

0 commit comments

Comments
 (0)