Compare commits

...
41 Commits
Author SHA1 Message Date
Danilo Di Cuia 27e0427e96 lots of fixes 2024-04-08 17:24:14 +02:00
Danilo Di Cuia f85344e90b improvements to upload and style changes 2024-04-07 19:00:31 +02:00
Danilo Di Cuia 79e0b64de3 fixed stff 2024-02-11 19:29:07 +01:00
Danilo Di Cuia 7a0dbbd5fb added camera 2024-02-11 19:16:29 +01:00
Danilo Di Cuia fbae62eec9 refactoring upload 2023-04-04 01:22:15 +02:00
Danilo Di Cuia 6ca12bc3cc link colors 2023-04-03 15:26:03 +02:00
Danilo Di Cuia 1e3650bf92 aggiunto indice 2023-04-03 14:43:32 +02:00
Danilo Di Cuia 4db86b2195 package lock 2023-03-27 12:59:38 +02:00
Danilo Di Cuia 4826fef377 package 2023-03-27 12:53:41 +02:00
Danilo Di Cuia 6e91222de7 stranezze 2023-03-27 12:46:23 +02:00
Danilo Di Cuia 9f5b3c88e0 firebase.json 2023-03-27 12:39:45 +02:00
Danilo Di Cuia a52f79b3bc moved video 2023-03-27 12:02:13 +02:00
Danilo Di Cuia bd8123ba09 style 2023-03-27 09:31:53 +02:00
Danilo Di Cuia 9fcd5a7a96 target container 2023-03-27 09:17:57 +02:00
Danilo Di Cuia c9ebed81c6 small fixes 2023-03-27 09:15:13 +02:00
Danilo Di Cuia 2be0829d35 stuff 2023-03-26 17:44:55 +02:00
Danilo Di Cuia 786328c9bd added post-hook 2023-02-17 17:00:14 +01:00
Danilo Di Cuia 6588be886b changes to layout and logic in db 2023-02-17 16:51:18 +01:00
Danilo Di Cuia c71766d6ea image loading 2023-01-07 19:26:22 +01:00
Danilo Di Cuia ce499bbed7 image loading 2023-01-06 19:51:56 +01:00
Danilo Di Cuia f9d038825e layout 2023-01-06 18:43:50 +01:00
Danilo Di Cuia 113033ccc6 layout 2023-01-06 18:40:46 +01:00
Danilo Di Cuia 769b27bfbf date 2023-01-06 18:37:24 +01:00
Danilo Di Cuia 849bc16fe4 logo 2023-01-06 18:26:09 +01:00
Danilo Di Cuia 0d2876baf3 video and chat gallery 2023-01-06 18:15:58 +01:00
Danilo Di Cuia 483abab330 change 2022-12-31 17:49:30 +01:00
Danilo Di Cuia 7fbe99bf63 fixed icons 2022-12-30 21:21:24 +01:00
Danilo Di Cuia e55cc77d98 fixed admin 2022-12-30 21:07:19 +01:00
Danilo Di Cuia 539ee83e73 fixed form 2022-12-30 20:47:10 +01:00
Danilo Di Cuia 451e63b37d fixed countdown 2022-12-30 19:07:54 +01:00
Danilo Di Cuia 0e96ba197f fixed countdown 2022-12-30 19:06:28 +01:00
Danilo Di Cuia eb9c3ccd2c blabla 2022-12-30 18:55:34 +01:00
Danilo Di Cuia 28c8123794 improvements 2022-12-30 18:20:39 +01:00
Danilo Di Cuia 03e8bc6c99 changed homepage 2022-12-30 17:24:45 +01:00
Danilo Di Cuia fd12ff9faf Merge branch 'master' of ssh://git.enne2.net:222/danilo/letsswingchat 2022-12-30 17:15:50 +01:00
Danilo Di Cuia 20c7a8eb72 style style baby 2022-12-30 17:15:35 +01:00
enne2 3cf79e7858 first build 2022-12-29 16:32:23 +01:00
Danilo Di Cuia 2b562e3495 added image upload functionality 2022-12-27 15:11:17 +01:00
Danilo Di Cuia b4cfaaddf1 started imgage upload 2022-12-25 19:20:41 +01:00
Danilo Di Cuia 56ccb30abc added countdown to messaggio 2022-12-25 19:01:26 +01:00
Danilo Di Cuia 9c22a780de fixed messaggio approvati 2022-12-25 18:51:43 +01:00
39 changed files with 3393 additions and 871 deletions
+5
View File
@@ -0,0 +1,5 @@
{
"projects": {
"default": "messaggiswing"
}
}
+2
View File
@@ -21,3 +21,5 @@
npm-debug.log*
yarn-debug.log*
yarn-error.log*
*.mp4
+43
View File
@@ -0,0 +1,43 @@
import firebase from "firebase/compat/app";
import "firebase/compat/database";
import fs from "fs";
firebase.initializeApp({
apiKey: "AIzaSyBWE1l8WV_7eyKT-PMu0Kq2w_WiV0SUhJw",
authDomain: "messaggiswing.firebaseapp.com",
projectId: "messaggiswing",
storageBucket: "messaggiswing.appspot.com",
messagingSenderId: "983131964310",
appId: "1:983131964310:web:5ef430e42c42d2dfe253b7",
measurementId: "G-1CBJZ3B48E",
databaseURL:
"https://messaggiswing-default-rtdb.europe-west1.firebasedatabase.app",
});
var defaultDatabase = firebase.database();
const folder = "capodanno2022";
defaultDatabase.ref(`/messaggi/${folder}`).once("value", (s) => {
const obj = s.val();
const messages = Object.keys(obj).map((d) => obj[d]);
var i = 0;
function move() {
const m = messages[i];
const { immagineURL } = m;
if (immagineURL) {
var d = immagineURL.substring(
immagineURL.indexOf("images%2F") + 9,
immagineURL.indexOf(".jpg") + 4
);
try {
if (fs.existsSync(`./images/${d}`)) {
//file exists
fs.renameSync(`./images/${d}`, `./images/${folder}/${d}`);
}
} catch (e) {}
}
i++;
if (i < messages.length) move();
}
move();
});
+970
View File
@@ -0,0 +1,970 @@
{
"name": "admin",
"version": "1.0.0",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "admin",
"version": "1.0.0",
"license": "ISC",
"dependencies": {
"firebase": "^9.19.1",
"fs": "^0.0.1-security"
}
},
"node_modules/@firebase/analytics": {
"version": "0.9.5",
"resolved": "https://registry.npmjs.org/@firebase/analytics/-/analytics-0.9.5.tgz",
"integrity": "sha512-hJTVs2jLxPXE7hs7D/jaEsgGivrm7tSEl65kb5NkDBWV7QQBUnRfVML/xra9nTFLLJhAdbExZPHg6HfIuMSYEQ==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/installations": "0.6.4",
"@firebase/logger": "0.4.0",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app": "0.x"
}
},
"node_modules/@firebase/analytics-compat": {
"version": "0.2.5",
"resolved": "https://registry.npmjs.org/@firebase/analytics-compat/-/analytics-compat-0.2.5.tgz",
"integrity": "sha512-ohKUrwSoXvyUJdSLuDr82mOqrzgWKyHMUt9/TfYKkyDXnFjNlBcFBpkpl/UHMAOJe0M60YYXiVCZoGQYldCslA==",
"dependencies": {
"@firebase/analytics": "0.9.5",
"@firebase/analytics-types": "0.8.0",
"@firebase/component": "0.6.4",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app-compat": "0.x"
}
},
"node_modules/@firebase/analytics-types": {
"version": "0.8.0",
"resolved": "https://registry.npmjs.org/@firebase/analytics-types/-/analytics-types-0.8.0.tgz",
"integrity": "sha512-iRP+QKI2+oz3UAh4nPEq14CsEjrjD6a5+fuypjScisAh9kXKFvdJOZJDwk7kikLvWVLGEs9+kIUS4LPQV7VZVw=="
},
"node_modules/@firebase/app": {
"version": "0.9.7",
"resolved": "https://registry.npmjs.org/@firebase/app/-/app-0.9.7.tgz",
"integrity": "sha512-ADnRXaW4XQF11QYYhZQEJEtOGnmLkGl2FCixCxPighLrmJmGwCZrzSFtwITd8w/EU3dRYaU5Og37VfnY+gKxGw==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/logger": "0.4.0",
"@firebase/util": "1.9.3",
"idb": "7.0.1",
"tslib": "^2.1.0"
}
},
"node_modules/@firebase/app-check": {
"version": "0.6.4",
"resolved": "https://registry.npmjs.org/@firebase/app-check/-/app-check-0.6.4.tgz",
"integrity": "sha512-M9qyVTWkEkHXmgwGtObvXQqKcOe9iKAOPqm0pCe74mzgKVTNq157ff39+fxHPb4nFbipToY+GuvtabLUzkHehQ==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/logger": "0.4.0",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app": "0.x"
}
},
"node_modules/@firebase/app-check-compat": {
"version": "0.3.4",
"resolved": "https://registry.npmjs.org/@firebase/app-check-compat/-/app-check-compat-0.3.4.tgz",
"integrity": "sha512-s6ON0ixPKe99M1DNYMI2eR5aLwQZgy0z8fuW1tnEbzg5p/N/GKFmqiIHSV4gfp8+X7Fw5NLm7qMfh4xrcPgQCw==",
"dependencies": {
"@firebase/app-check": "0.6.4",
"@firebase/app-check-types": "0.5.0",
"@firebase/component": "0.6.4",
"@firebase/logger": "0.4.0",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app-compat": "0.x"
}
},
"node_modules/@firebase/app-check-interop-types": {
"version": "0.2.0",
"resolved": "https://registry.npmjs.org/@firebase/app-check-interop-types/-/app-check-interop-types-0.2.0.tgz",
"integrity": "sha512-+3PQIeX6/eiVK+x/yg8r6xTNR97fN7MahFDm+jiQmDjcyvSefoGuTTNQuuMScGyx3vYUBeZn+Cp9kC0yY/9uxQ=="
},
"node_modules/@firebase/app-check-types": {
"version": "0.5.0",
"resolved": "https://registry.npmjs.org/@firebase/app-check-types/-/app-check-types-0.5.0.tgz",
"integrity": "sha512-uwSUj32Mlubybw7tedRzR24RP8M8JUVR3NPiMk3/Z4bCmgEKTlQBwMXrehDAZ2wF+TsBq0SN1c6ema71U/JPyQ=="
},
"node_modules/@firebase/app-compat": {
"version": "0.2.7",
"resolved": "https://registry.npmjs.org/@firebase/app-compat/-/app-compat-0.2.7.tgz",
"integrity": "sha512-KYBUKoRrvSGW8jqKgARRsma0lJie9M0zyWhPF3PNjqc9pYsw7SZXp5s5SzsheeCXzIDFydP5uEA4f1Z87D7CxQ==",
"dependencies": {
"@firebase/app": "0.9.7",
"@firebase/component": "0.6.4",
"@firebase/logger": "0.4.0",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
}
},
"node_modules/@firebase/app-types": {
"version": "0.9.0",
"resolved": "https://registry.npmjs.org/@firebase/app-types/-/app-types-0.9.0.tgz",
"integrity": "sha512-AeweANOIo0Mb8GiYm3xhTEBVCmPwTYAu9Hcd2qSkLuga/6+j9b1Jskl5bpiSQWy9eJ/j5pavxj6eYogmnuzm+Q=="
},
"node_modules/@firebase/auth": {
"version": "0.22.0",
"resolved": "https://registry.npmjs.org/@firebase/auth/-/auth-0.22.0.tgz",
"integrity": "sha512-4PiaDJEhJ7FNo48WG0TAlqHiCuRBXxUow2q+0emh+PhmM0cLT1UdqK1EuWWGc5CY+ztNQZUh+Yzeh+nv9tZL0w==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/logger": "0.4.0",
"@firebase/util": "1.9.3",
"node-fetch": "2.6.7",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app": "0.x"
}
},
"node_modules/@firebase/auth-compat": {
"version": "0.3.7",
"resolved": "https://registry.npmjs.org/@firebase/auth-compat/-/auth-compat-0.3.7.tgz",
"integrity": "sha512-+r8/++hYZLA/to6Iq8A70LTUsZvhkdT2R4mB4oJGxryJ7vNjpuP5m5hfAd42h/VvX8eT1OXJCENCfEZoDyhksA==",
"dependencies": {
"@firebase/auth": "0.22.0",
"@firebase/auth-types": "0.12.0",
"@firebase/component": "0.6.4",
"@firebase/util": "1.9.3",
"node-fetch": "2.6.7",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app-compat": "0.x"
}
},
"node_modules/@firebase/auth-interop-types": {
"version": "0.2.1",
"resolved": "https://registry.npmjs.org/@firebase/auth-interop-types/-/auth-interop-types-0.2.1.tgz",
"integrity": "sha512-VOaGzKp65MY6P5FI84TfYKBXEPi6LmOCSMMzys6o2BN2LOsqy7pCuZCup7NYnfbk5OkkQKzvIfHOzTm0UDpkyg=="
},
"node_modules/@firebase/auth-types": {
"version": "0.12.0",
"resolved": "https://registry.npmjs.org/@firebase/auth-types/-/auth-types-0.12.0.tgz",
"integrity": "sha512-pPwaZt+SPOshK8xNoiQlK5XIrS97kFYc3Rc7xmy373QsOJ9MmqXxLaYssP5Kcds4wd2qK//amx/c+A8O2fVeZA==",
"peerDependencies": {
"@firebase/app-types": "0.x",
"@firebase/util": "1.x"
}
},
"node_modules/@firebase/component": {
"version": "0.6.4",
"resolved": "https://registry.npmjs.org/@firebase/component/-/component-0.6.4.tgz",
"integrity": "sha512-rLMyrXuO9jcAUCaQXCMjCMUsWrba5fzHlNK24xz5j2W6A/SRmK8mZJ/hn7V0fViLbxC0lPMtrK1eYzk6Fg03jA==",
"dependencies": {
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
}
},
"node_modules/@firebase/database": {
"version": "0.14.4",
"resolved": "https://registry.npmjs.org/@firebase/database/-/database-0.14.4.tgz",
"integrity": "sha512-+Ea/IKGwh42jwdjCyzTmeZeLM3oy1h0mFPsTy6OqCWzcu/KFqRAr5Tt1HRCOBlNOdbh84JPZC47WLU18n2VbxQ==",
"dependencies": {
"@firebase/auth-interop-types": "0.2.1",
"@firebase/component": "0.6.4",
"@firebase/logger": "0.4.0",
"@firebase/util": "1.9.3",
"faye-websocket": "0.11.4",
"tslib": "^2.1.0"
}
},
"node_modules/@firebase/database-compat": {
"version": "0.3.4",
"resolved": "https://registry.npmjs.org/@firebase/database-compat/-/database-compat-0.3.4.tgz",
"integrity": "sha512-kuAW+l+sLMUKBThnvxvUZ+Q1ZrF/vFJ58iUY9kAcbX48U03nVzIF6Tmkf0p3WVQwMqiXguSgtOPIB6ZCeF+5Gg==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/database": "0.14.4",
"@firebase/database-types": "0.10.4",
"@firebase/logger": "0.4.0",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
}
},
"node_modules/@firebase/database-types": {
"version": "0.10.4",
"resolved": "https://registry.npmjs.org/@firebase/database-types/-/database-types-0.10.4.tgz",
"integrity": "sha512-dPySn0vJ/89ZeBac70T+2tWWPiJXWbmRygYv0smT5TfE3hDrQ09eKMF3Y+vMlTdrMWq7mUdYW5REWPSGH4kAZQ==",
"dependencies": {
"@firebase/app-types": "0.9.0",
"@firebase/util": "1.9.3"
}
},
"node_modules/@firebase/firestore": {
"version": "3.10.0",
"resolved": "https://registry.npmjs.org/@firebase/firestore/-/firestore-3.10.0.tgz",
"integrity": "sha512-St6yy2r7zYxJiAEiI19aQJqxVV8LDvlmeK52R9KMn2nZsgdDVOurch1cH7bBl0OxEgfiVxBmAQJLYvZc+qwAgw==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/logger": "0.4.0",
"@firebase/util": "1.9.3",
"@firebase/webchannel-wrapper": "0.9.0",
"@grpc/grpc-js": "~1.7.0",
"@grpc/proto-loader": "^0.6.13",
"node-fetch": "2.6.7",
"tslib": "^2.1.0"
},
"engines": {
"node": ">=10.10.0"
},
"peerDependencies": {
"@firebase/app": "0.x"
}
},
"node_modules/@firebase/firestore-compat": {
"version": "0.3.6",
"resolved": "https://registry.npmjs.org/@firebase/firestore-compat/-/firestore-compat-0.3.6.tgz",
"integrity": "sha512-svS8oV0nwTyoHW5mslFV0gRb3FLpRQGjz2F7nc5imnPUTjSJmAfXECtgs5HG5MSJM/laSimfAeGuQVh5FM1AEw==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/firestore": "3.10.0",
"@firebase/firestore-types": "2.5.1",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app-compat": "0.x"
}
},
"node_modules/@firebase/firestore-types": {
"version": "2.5.1",
"resolved": "https://registry.npmjs.org/@firebase/firestore-types/-/firestore-types-2.5.1.tgz",
"integrity": "sha512-xG0CA6EMfYo8YeUxC8FeDzf6W3FX1cLlcAGBYV6Cku12sZRI81oWcu61RSKM66K6kUENP+78Qm8mvroBcm1whw==",
"peerDependencies": {
"@firebase/app-types": "0.x",
"@firebase/util": "1.x"
}
},
"node_modules/@firebase/functions": {
"version": "0.9.4",
"resolved": "https://registry.npmjs.org/@firebase/functions/-/functions-0.9.4.tgz",
"integrity": "sha512-3H2qh6U+q+nepO5Hds+Ddl6J0pS+zisuBLqqQMRBHv9XpWfu0PnDHklNmE8rZ+ccTEXvBj6zjkPfdxt6NisvlQ==",
"dependencies": {
"@firebase/app-check-interop-types": "0.2.0",
"@firebase/auth-interop-types": "0.2.1",
"@firebase/component": "0.6.4",
"@firebase/messaging-interop-types": "0.2.0",
"@firebase/util": "1.9.3",
"node-fetch": "2.6.7",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app": "0.x"
}
},
"node_modules/@firebase/functions-compat": {
"version": "0.3.4",
"resolved": "https://registry.npmjs.org/@firebase/functions-compat/-/functions-compat-0.3.4.tgz",
"integrity": "sha512-kxVxTGyLV1MBR3sp3mI+eQ6JBqz0G5bk310F8eX4HzDFk4xjk5xY0KdHktMH+edM2xs1BOg0vwvvsAHczIjB+w==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/functions": "0.9.4",
"@firebase/functions-types": "0.6.0",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app-compat": "0.x"
}
},
"node_modules/@firebase/functions-types": {
"version": "0.6.0",
"resolved": "https://registry.npmjs.org/@firebase/functions-types/-/functions-types-0.6.0.tgz",
"integrity": "sha512-hfEw5VJtgWXIRf92ImLkgENqpL6IWpYaXVYiRkFY1jJ9+6tIhWM7IzzwbevwIIud/jaxKVdRzD7QBWfPmkwCYw=="
},
"node_modules/@firebase/installations": {
"version": "0.6.4",
"resolved": "https://registry.npmjs.org/@firebase/installations/-/installations-0.6.4.tgz",
"integrity": "sha512-u5y88rtsp7NYkCHC3ElbFBrPtieUybZluXyzl7+4BsIz4sqb4vSAuwHEUgCgCeaQhvsnxDEU6icly8U9zsJigA==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/util": "1.9.3",
"idb": "7.0.1",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app": "0.x"
}
},
"node_modules/@firebase/installations-compat": {
"version": "0.2.4",
"resolved": "https://registry.npmjs.org/@firebase/installations-compat/-/installations-compat-0.2.4.tgz",
"integrity": "sha512-LI9dYjp0aT9Njkn9U4JRrDqQ6KXeAmFbRC0E7jI7+hxl5YmRWysq5qgQl22hcWpTk+cm3es66d/apoDU/A9n6Q==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/installations": "0.6.4",
"@firebase/installations-types": "0.5.0",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app-compat": "0.x"
}
},
"node_modules/@firebase/installations-types": {
"version": "0.5.0",
"resolved": "https://registry.npmjs.org/@firebase/installations-types/-/installations-types-0.5.0.tgz",
"integrity": "sha512-9DP+RGfzoI2jH7gY4SlzqvZ+hr7gYzPODrbzVD82Y12kScZ6ZpRg/i3j6rleto8vTFC8n6Len4560FnV1w2IRg==",
"peerDependencies": {
"@firebase/app-types": "0.x"
}
},
"node_modules/@firebase/logger": {
"version": "0.4.0",
"resolved": "https://registry.npmjs.org/@firebase/logger/-/logger-0.4.0.tgz",
"integrity": "sha512-eRKSeykumZ5+cJPdxxJRgAC3G5NknY2GwEbKfymdnXtnT0Ucm4pspfR6GT4MUQEDuJwRVbVcSx85kgJulMoFFA==",
"dependencies": {
"tslib": "^2.1.0"
}
},
"node_modules/@firebase/messaging": {
"version": "0.12.4",
"resolved": "https://registry.npmjs.org/@firebase/messaging/-/messaging-0.12.4.tgz",
"integrity": "sha512-6JLZct6zUaex4g7HI3QbzeUrg9xcnmDAPTWpkoMpd/GoSVWH98zDoWXMGrcvHeCAIsLpFMe4MPoZkJbrPhaASw==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/installations": "0.6.4",
"@firebase/messaging-interop-types": "0.2.0",
"@firebase/util": "1.9.3",
"idb": "7.0.1",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app": "0.x"
}
},
"node_modules/@firebase/messaging-compat": {
"version": "0.2.4",
"resolved": "https://registry.npmjs.org/@firebase/messaging-compat/-/messaging-compat-0.2.4.tgz",
"integrity": "sha512-lyFjeUhIsPRYDPNIkYX1LcZMpoVbBWXX4rPl7c/rqc7G+EUea7IEtSt4MxTvh6fDfPuzLn7+FZADfscC+tNMfg==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/messaging": "0.12.4",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app-compat": "0.x"
}
},
"node_modules/@firebase/messaging-interop-types": {
"version": "0.2.0",
"resolved": "https://registry.npmjs.org/@firebase/messaging-interop-types/-/messaging-interop-types-0.2.0.tgz",
"integrity": "sha512-ujA8dcRuVeBixGR9CtegfpU4YmZf3Lt7QYkcj693FFannwNuZgfAYaTmbJ40dtjB81SAu6tbFPL9YLNT15KmOQ=="
},
"node_modules/@firebase/performance": {
"version": "0.6.4",
"resolved": "https://registry.npmjs.org/@firebase/performance/-/performance-0.6.4.tgz",
"integrity": "sha512-HfTn/bd8mfy/61vEqaBelNiNnvAbUtME2S25A67Nb34zVuCSCRIX4SseXY6zBnOFj3oLisaEqhVcJmVPAej67g==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/installations": "0.6.4",
"@firebase/logger": "0.4.0",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app": "0.x"
}
},
"node_modules/@firebase/performance-compat": {
"version": "0.2.4",
"resolved": "https://registry.npmjs.org/@firebase/performance-compat/-/performance-compat-0.2.4.tgz",
"integrity": "sha512-nnHUb8uP9G8islzcld/k6Bg5RhX62VpbAb/Anj7IXs/hp32Eb2LqFPZK4sy3pKkBUO5wcrlRWQa6wKOxqlUqsg==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/logger": "0.4.0",
"@firebase/performance": "0.6.4",
"@firebase/performance-types": "0.2.0",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app-compat": "0.x"
}
},
"node_modules/@firebase/performance-types": {
"version": "0.2.0",
"resolved": "https://registry.npmjs.org/@firebase/performance-types/-/performance-types-0.2.0.tgz",
"integrity": "sha512-kYrbr8e/CYr1KLrLYZZt2noNnf+pRwDq2KK9Au9jHrBMnb0/C9X9yWSXmZkFt4UIdsQknBq8uBB7fsybZdOBTA=="
},
"node_modules/@firebase/remote-config": {
"version": "0.4.4",
"resolved": "https://registry.npmjs.org/@firebase/remote-config/-/remote-config-0.4.4.tgz",
"integrity": "sha512-x1ioTHGX8ZwDSTOVp8PBLv2/wfwKzb4pxi0gFezS5GCJwbLlloUH4YYZHHS83IPxnua8b6l0IXUaWd0RgbWwzQ==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/installations": "0.6.4",
"@firebase/logger": "0.4.0",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app": "0.x"
}
},
"node_modules/@firebase/remote-config-compat": {
"version": "0.2.4",
"resolved": "https://registry.npmjs.org/@firebase/remote-config-compat/-/remote-config-compat-0.2.4.tgz",
"integrity": "sha512-FKiki53jZirrDFkBHglB3C07j5wBpitAaj8kLME6g8Mx+aq7u9P7qfmuSRytiOItADhWUj7O1JIv7n9q87SuwA==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/logger": "0.4.0",
"@firebase/remote-config": "0.4.4",
"@firebase/remote-config-types": "0.3.0",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app-compat": "0.x"
}
},
"node_modules/@firebase/remote-config-types": {
"version": "0.3.0",
"resolved": "https://registry.npmjs.org/@firebase/remote-config-types/-/remote-config-types-0.3.0.tgz",
"integrity": "sha512-RtEH4vdcbXZuZWRZbIRmQVBNsE7VDQpet2qFvq6vwKLBIQRQR5Kh58M4ok3A3US8Sr3rubYnaGqZSurCwI8uMA=="
},
"node_modules/@firebase/storage": {
"version": "0.11.2",
"resolved": "https://registry.npmjs.org/@firebase/storage/-/storage-0.11.2.tgz",
"integrity": "sha512-CtvoFaBI4hGXlXbaCHf8humajkbXhs39Nbh6MbNxtwJiCqxPy9iH3D3CCfXAvP0QvAAwmJUTK3+z9a++Kc4nkA==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/util": "1.9.3",
"node-fetch": "2.6.7",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app": "0.x"
}
},
"node_modules/@firebase/storage-compat": {
"version": "0.3.2",
"resolved": "https://registry.npmjs.org/@firebase/storage-compat/-/storage-compat-0.3.2.tgz",
"integrity": "sha512-wvsXlLa9DVOMQJckbDNhXKKxRNNewyUhhbXev3t8kSgoCotd1v3MmqhKKz93ePhDnhHnDs7bYHy+Qa8dRY6BXw==",
"dependencies": {
"@firebase/component": "0.6.4",
"@firebase/storage": "0.11.2",
"@firebase/storage-types": "0.8.0",
"@firebase/util": "1.9.3",
"tslib": "^2.1.0"
},
"peerDependencies": {
"@firebase/app-compat": "0.x"
}
},
"node_modules/@firebase/storage-types": {
"version": "0.8.0",
"resolved": "https://registry.npmjs.org/@firebase/storage-types/-/storage-types-0.8.0.tgz",
"integrity": "sha512-isRHcGrTs9kITJC0AVehHfpraWFui39MPaU7Eo8QfWlqW7YPymBmRgjDrlOgFdURh6Cdeg07zmkLP5tzTKRSpg==",
"peerDependencies": {
"@firebase/app-types": "0.x",
"@firebase/util": "1.x"
}
},
"node_modules/@firebase/util": {
"version": "1.9.3",
"resolved": "https://registry.npmjs.org/@firebase/util/-/util-1.9.3.tgz",
"integrity": "sha512-DY02CRhOZwpzO36fHpuVysz6JZrscPiBXD0fXp6qSrL9oNOx5KWICKdR95C0lSITzxp0TZosVyHqzatE8JbcjA==",
"dependencies": {
"tslib": "^2.1.0"
}
},
"node_modules/@firebase/webchannel-wrapper": {
"version": "0.9.0",
"resolved": "https://registry.npmjs.org/@firebase/webchannel-wrapper/-/webchannel-wrapper-0.9.0.tgz",
"integrity": "sha512-BpiZLBWdLFw+qFel9p3Zs1jD6QmH7Ii4aTDu6+vx8ShdidChZUXqDhYJly4ZjSgQh54miXbBgBrk0S+jTIh/Qg=="
},
"node_modules/@grpc/grpc-js": {
"version": "1.7.3",
"resolved": "https://registry.npmjs.org/@grpc/grpc-js/-/grpc-js-1.7.3.tgz",
"integrity": "sha512-H9l79u4kJ2PVSxUNA08HMYAnUBLj9v6KjYQ7SQ71hOZcEXhShE/y5iQCesP8+6/Ik/7i2O0a10bPquIcYfufog==",
"dependencies": {
"@grpc/proto-loader": "^0.7.0",
"@types/node": ">=12.12.47"
},
"engines": {
"node": "^8.13.0 || >=10.10.0"
}
},
"node_modules/@grpc/grpc-js/node_modules/@grpc/proto-loader": {
"version": "0.7.6",
"resolved": "https://registry.npmjs.org/@grpc/proto-loader/-/proto-loader-0.7.6.tgz",
"integrity": "sha512-QyAXR8Hyh7uMDmveWxDSUcJr9NAWaZ2I6IXgAYvQmfflwouTM+rArE2eEaCtLlRqO81j7pRLCt81IefUei6Zbw==",
"dependencies": {
"@types/long": "^4.0.1",
"lodash.camelcase": "^4.3.0",
"long": "^4.0.0",
"protobufjs": "^7.0.0",
"yargs": "^16.2.0"
},
"bin": {
"proto-loader-gen-types": "build/bin/proto-loader-gen-types.js"
},
"engines": {
"node": ">=6"
}
},
"node_modules/@grpc/grpc-js/node_modules/protobufjs": {
"version": "7.2.3",
"resolved": "https://registry.npmjs.org/protobufjs/-/protobufjs-7.2.3.tgz",
"integrity": "sha512-TtpvOqwB5Gdz/PQmOjgsrGH1nHjAQVCN7JG4A6r1sXRWESL5rNMAiRcBQlCAdKxZcAbstExQePYG8xof/JVRgg==",
"hasInstallScript": true,
"dependencies": {
"@protobufjs/aspromise": "^1.1.2",
"@protobufjs/base64": "^1.1.2",
"@protobufjs/codegen": "^2.0.4",
"@protobufjs/eventemitter": "^1.1.0",
"@protobufjs/fetch": "^1.1.0",
"@protobufjs/float": "^1.0.2",
"@protobufjs/inquire": "^1.1.0",
"@protobufjs/path": "^1.1.2",
"@protobufjs/pool": "^1.1.0",
"@protobufjs/utf8": "^1.1.0",
"@types/node": ">=13.7.0",
"long": "^5.0.0"
},
"engines": {
"node": ">=12.0.0"
}
},
"node_modules/@grpc/grpc-js/node_modules/protobufjs/node_modules/long": {
"version": "5.2.1",
"resolved": "https://registry.npmjs.org/long/-/long-5.2.1.tgz",
"integrity": "sha512-GKSNGeNAtw8IryjjkhZxuKB3JzlcLTwjtiQCHKvqQet81I93kXslhDQruGI/QsddO83mcDToBVy7GqGS/zYf/A=="
},
"node_modules/@grpc/proto-loader": {
"version": "0.6.13",
"resolved": "https://registry.npmjs.org/@grpc/proto-loader/-/proto-loader-0.6.13.tgz",
"integrity": "sha512-FjxPYDRTn6Ec3V0arm1FtSpmP6V50wuph2yILpyvTKzjc76oDdoihXqM1DzOW5ubvCC8GivfCnNtfaRE8myJ7g==",
"dependencies": {
"@types/long": "^4.0.1",
"lodash.camelcase": "^4.3.0",
"long": "^4.0.0",
"protobufjs": "^6.11.3",
"yargs": "^16.2.0"
},
"bin": {
"proto-loader-gen-types": "build/bin/proto-loader-gen-types.js"
},
"engines": {
"node": ">=6"
}
},
"node_modules/@protobufjs/aspromise": {
"version": "1.1.2",
"resolved": "https://registry.npmjs.org/@protobufjs/aspromise/-/aspromise-1.1.2.tgz",
"integrity": "sha512-j+gKExEuLmKwvz3OgROXtrJ2UG2x8Ch2YZUxahh+s1F2HZ+wAceUNLkvy6zKCPVRkU++ZWQrdxsUeQXmcg4uoQ=="
},
"node_modules/@protobufjs/base64": {
"version": "1.1.2",
"resolved": "https://registry.npmjs.org/@protobufjs/base64/-/base64-1.1.2.tgz",
"integrity": "sha512-AZkcAA5vnN/v4PDqKyMR5lx7hZttPDgClv83E//FMNhR2TMcLUhfRUBHCmSl0oi9zMgDDqRUJkSxO3wm85+XLg=="
},
"node_modules/@protobufjs/codegen": {
"version": "2.0.4",
"resolved": "https://registry.npmjs.org/@protobufjs/codegen/-/codegen-2.0.4.tgz",
"integrity": "sha512-YyFaikqM5sH0ziFZCN3xDC7zeGaB/d0IUb9CATugHWbd1FRFwWwt4ld4OYMPWu5a3Xe01mGAULCdqhMlPl29Jg=="
},
"node_modules/@protobufjs/eventemitter": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/@protobufjs/eventemitter/-/eventemitter-1.1.0.tgz",
"integrity": "sha512-j9ednRT81vYJ9OfVuXG6ERSTdEL1xVsNgqpkxMsbIabzSo3goCjDIveeGv5d03om39ML71RdmrGNjG5SReBP/Q=="
},
"node_modules/@protobufjs/fetch": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/@protobufjs/fetch/-/fetch-1.1.0.tgz",
"integrity": "sha512-lljVXpqXebpsijW71PZaCYeIcE5on1w5DlQy5WH6GLbFryLUrBD4932W/E2BSpfRJWseIL4v/KPgBFxDOIdKpQ==",
"dependencies": {
"@protobufjs/aspromise": "^1.1.1",
"@protobufjs/inquire": "^1.1.0"
}
},
"node_modules/@protobufjs/float": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/@protobufjs/float/-/float-1.0.2.tgz",
"integrity": "sha512-Ddb+kVXlXst9d+R9PfTIxh1EdNkgoRe5tOX6t01f1lYWOvJnSPDBlG241QLzcyPdoNTsblLUdujGSE4RzrTZGQ=="
},
"node_modules/@protobufjs/inquire": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/@protobufjs/inquire/-/inquire-1.1.0.tgz",
"integrity": "sha512-kdSefcPdruJiFMVSbn801t4vFK7KB/5gd2fYvrxhuJYg8ILrmn9SKSX2tZdV6V+ksulWqS7aXjBcRXl3wHoD9Q=="
},
"node_modules/@protobufjs/path": {
"version": "1.1.2",
"resolved": "https://registry.npmjs.org/@protobufjs/path/-/path-1.1.2.tgz",
"integrity": "sha512-6JOcJ5Tm08dOHAbdR3GrvP+yUUfkjG5ePsHYczMFLq3ZmMkAD98cDgcT2iA1lJ9NVwFd4tH/iSSoe44YWkltEA=="
},
"node_modules/@protobufjs/pool": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/@protobufjs/pool/-/pool-1.1.0.tgz",
"integrity": "sha512-0kELaGSIDBKvcgS4zkjz1PeddatrjYcmMWOlAuAPwAeccUrPHdUqo/J6LiymHHEiJT5NrF1UVwxY14f+fy4WQw=="
},
"node_modules/@protobufjs/utf8": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/@protobufjs/utf8/-/utf8-1.1.0.tgz",
"integrity": "sha512-Vvn3zZrhQZkkBE8LSuW3em98c0FwgO4nxzv6OdSxPKJIEKY2bGbHn+mhGIPerzI4twdxaP8/0+06HBpwf345Lw=="
},
"node_modules/@types/long": {
"version": "4.0.2",
"resolved": "https://registry.npmjs.org/@types/long/-/long-4.0.2.tgz",
"integrity": "sha512-MqTGEo5bj5t157U6fA/BiDynNkn0YknVdh48CMPkTSpFTVmvao5UQmm7uEF6xBEo7qIMAlY/JSleYaE6VOdpaA=="
},
"node_modules/@types/node": {
"version": "18.15.11",
"resolved": "https://registry.npmjs.org/@types/node/-/node-18.15.11.tgz",
"integrity": "sha512-E5Kwq2n4SbMzQOn6wnmBjuK9ouqlURrcZDVfbo9ftDDTFt3nk7ZKK4GMOzoYgnpQJKcxwQw+lGaBvvlMo0qN/Q=="
},
"node_modules/ansi-regex": {
"version": "5.0.1",
"resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz",
"integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==",
"engines": {
"node": ">=8"
}
},
"node_modules/ansi-styles": {
"version": "4.3.0",
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
"integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
"dependencies": {
"color-convert": "^2.0.1"
},
"engines": {
"node": ">=8"
},
"funding": {
"url": "https://github.com/chalk/ansi-styles?sponsor=1"
}
},
"node_modules/cliui": {
"version": "7.0.4",
"resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz",
"integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==",
"dependencies": {
"string-width": "^4.2.0",
"strip-ansi": "^6.0.0",
"wrap-ansi": "^7.0.0"
}
},
"node_modules/color-convert": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
"integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
"dependencies": {
"color-name": "~1.1.4"
},
"engines": {
"node": ">=7.0.0"
}
},
"node_modules/color-name": {
"version": "1.1.4",
"resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
"integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA=="
},
"node_modules/emoji-regex": {
"version": "8.0.0",
"resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz",
"integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A=="
},
"node_modules/escalade": {
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz",
"integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==",
"engines": {
"node": ">=6"
}
},
"node_modules/faye-websocket": {
"version": "0.11.4",
"resolved": "https://registry.npmjs.org/faye-websocket/-/faye-websocket-0.11.4.tgz",
"integrity": "sha512-CzbClwlXAuiRQAlUyfqPgvPoNKTckTPGfwZV4ZdAhVcP2lh9KUxJg2b5GkE7XbjKQ3YJnQ9z6D9ntLAlB+tP8g==",
"dependencies": {
"websocket-driver": ">=0.5.1"
},
"engines": {
"node": ">=0.8.0"
}
},
"node_modules/firebase": {
"version": "9.19.1",
"resolved": "https://registry.npmjs.org/firebase/-/firebase-9.19.1.tgz",
"integrity": "sha512-MeukV4NIk6usV1ZbnoA36gumK62JzxOZmF6OZyqkFwJ7edpAEyYNZXvExQlFsvnx2ery0UwNIvu4pKIZS3HiEQ==",
"dependencies": {
"@firebase/analytics": "0.9.5",
"@firebase/analytics-compat": "0.2.5",
"@firebase/app": "0.9.7",
"@firebase/app-check": "0.6.4",
"@firebase/app-check-compat": "0.3.4",
"@firebase/app-compat": "0.2.7",
"@firebase/app-types": "0.9.0",
"@firebase/auth": "0.22.0",
"@firebase/auth-compat": "0.3.7",
"@firebase/database": "0.14.4",
"@firebase/database-compat": "0.3.4",
"@firebase/firestore": "3.10.0",
"@firebase/firestore-compat": "0.3.6",
"@firebase/functions": "0.9.4",
"@firebase/functions-compat": "0.3.4",
"@firebase/installations": "0.6.4",
"@firebase/installations-compat": "0.2.4",
"@firebase/messaging": "0.12.4",
"@firebase/messaging-compat": "0.2.4",
"@firebase/performance": "0.6.4",
"@firebase/performance-compat": "0.2.4",
"@firebase/remote-config": "0.4.4",
"@firebase/remote-config-compat": "0.2.4",
"@firebase/storage": "0.11.2",
"@firebase/storage-compat": "0.3.2",
"@firebase/util": "1.9.3"
}
},
"node_modules/fs": {
"version": "0.0.1-security",
"resolved": "https://registry.npmjs.org/fs/-/fs-0.0.1-security.tgz",
"integrity": "sha512-3XY9e1pP0CVEUCdj5BmfIZxRBTSDycnbqhIOGec9QYtmVH2fbLpj86CFWkrNOkt/Fvty4KZG5lTglL9j/gJ87w=="
},
"node_modules/get-caller-file": {
"version": "2.0.5",
"resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz",
"integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==",
"engines": {
"node": "6.* || 8.* || >= 10.*"
}
},
"node_modules/http-parser-js": {
"version": "0.5.8",
"resolved": "https://registry.npmjs.org/http-parser-js/-/http-parser-js-0.5.8.tgz",
"integrity": "sha512-SGeBX54F94Wgu5RH3X5jsDtf4eHyRogWX1XGT3b4HuW3tQPM4AaBzoUji/4AAJNXCEOWZ5O0DgZmJw1947gD5Q=="
},
"node_modules/idb": {
"version": "7.0.1",
"resolved": "https://registry.npmjs.org/idb/-/idb-7.0.1.tgz",
"integrity": "sha512-UUxlE7vGWK5RfB/fDwEGgRf84DY/ieqNha6msMV99UsEMQhJ1RwbCd8AYBj3QMgnE3VZnfQvm4oKVCJTYlqIgg=="
},
"node_modules/is-fullwidth-code-point": {
"version": "3.0.0",
"resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz",
"integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==",
"engines": {
"node": ">=8"
}
},
"node_modules/lodash.camelcase": {
"version": "4.3.0",
"resolved": "https://registry.npmjs.org/lodash.camelcase/-/lodash.camelcase-4.3.0.tgz",
"integrity": "sha512-TwuEnCnxbc3rAvhf/LbG7tJUDzhqXyFnv3dtzLOPgCG/hODL7WFnsbwktkD7yUV0RrreP/l1PALq/YSg6VvjlA=="
},
"node_modules/long": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/long/-/long-4.0.0.tgz",
"integrity": "sha512-XsP+KhQif4bjX1kbuSiySJFNAehNxgLb6hPRGJ9QsUr8ajHkuXGdrHmFUTUUXhDwVX2R5bY4JNZEwbUiMhV+MA=="
},
"node_modules/node-fetch": {
"version": "2.6.7",
"resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.7.tgz",
"integrity": "sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ==",
"dependencies": {
"whatwg-url": "^5.0.0"
},
"engines": {
"node": "4.x || >=6.0.0"
},
"peerDependencies": {
"encoding": "^0.1.0"
},
"peerDependenciesMeta": {
"encoding": {
"optional": true
}
}
},
"node_modules/protobufjs": {
"version": "6.11.3",
"resolved": "https://registry.npmjs.org/protobufjs/-/protobufjs-6.11.3.tgz",
"integrity": "sha512-xL96WDdCZYdU7Slin569tFX712BxsxslWwAfAhCYjQKGTq7dAU91Lomy6nLLhh/dyGhk/YH4TwTSRxTzhuHyZg==",
"hasInstallScript": true,
"dependencies": {
"@protobufjs/aspromise": "^1.1.2",
"@protobufjs/base64": "^1.1.2",
"@protobufjs/codegen": "^2.0.4",
"@protobufjs/eventemitter": "^1.1.0",
"@protobufjs/fetch": "^1.1.0",
"@protobufjs/float": "^1.0.2",
"@protobufjs/inquire": "^1.1.0",
"@protobufjs/path": "^1.1.2",
"@protobufjs/pool": "^1.1.0",
"@protobufjs/utf8": "^1.1.0",
"@types/long": "^4.0.1",
"@types/node": ">=13.7.0",
"long": "^4.0.0"
},
"bin": {
"pbjs": "bin/pbjs",
"pbts": "bin/pbts"
}
},
"node_modules/require-directory": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz",
"integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==",
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/safe-buffer": {
"version": "5.2.1",
"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz",
"integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==",
"funding": [
{
"type": "github",
"url": "https://github.com/sponsors/feross"
},
{
"type": "patreon",
"url": "https://www.patreon.com/feross"
},
{
"type": "consulting",
"url": "https://feross.org/support"
}
]
},
"node_modules/string-width": {
"version": "4.2.3",
"resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz",
"integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==",
"dependencies": {
"emoji-regex": "^8.0.0",
"is-fullwidth-code-point": "^3.0.0",
"strip-ansi": "^6.0.1"
},
"engines": {
"node": ">=8"
}
},
"node_modules/strip-ansi": {
"version": "6.0.1",
"resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz",
"integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==",
"dependencies": {
"ansi-regex": "^5.0.1"
},
"engines": {
"node": ">=8"
}
},
"node_modules/tr46": {
"version": "0.0.3",
"resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz",
"integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw=="
},
"node_modules/tslib": {
"version": "2.5.0",
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.5.0.tgz",
"integrity": "sha512-336iVw3rtn2BUK7ORdIAHTyxHGRIHVReokCR3XjbckJMK7ms8FysBfhLR8IXnAgy7T0PTPNBWKiH514FOW/WSg=="
},
"node_modules/webidl-conversions": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz",
"integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ=="
},
"node_modules/websocket-driver": {
"version": "0.7.4",
"resolved": "https://registry.npmjs.org/websocket-driver/-/websocket-driver-0.7.4.tgz",
"integrity": "sha512-b17KeDIQVjvb0ssuSDF2cYXSg2iztliJ4B9WdsuB6J952qCPKmnVq4DyW5motImXHDC1cBT/1UezrJVsKw5zjg==",
"dependencies": {
"http-parser-js": ">=0.5.1",
"safe-buffer": ">=5.1.0",
"websocket-extensions": ">=0.1.1"
},
"engines": {
"node": ">=0.8.0"
}
},
"node_modules/websocket-extensions": {
"version": "0.1.4",
"resolved": "https://registry.npmjs.org/websocket-extensions/-/websocket-extensions-0.1.4.tgz",
"integrity": "sha512-OqedPIGOfsDlo31UNwYbCFMSaO9m9G/0faIHj5/dZFDMFqPTcx6UwqyOy3COEaEOg/9VsGIpdqn62W5KhoKSpg==",
"engines": {
"node": ">=0.8.0"
}
},
"node_modules/whatwg-url": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz",
"integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==",
"dependencies": {
"tr46": "~0.0.3",
"webidl-conversions": "^3.0.0"
}
},
"node_modules/wrap-ansi": {
"version": "7.0.0",
"resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz",
"integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==",
"dependencies": {
"ansi-styles": "^4.0.0",
"string-width": "^4.1.0",
"strip-ansi": "^6.0.0"
},
"engines": {
"node": ">=10"
},
"funding": {
"url": "https://github.com/chalk/wrap-ansi?sponsor=1"
}
},
"node_modules/y18n": {
"version": "5.0.8",
"resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz",
"integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==",
"engines": {
"node": ">=10"
}
},
"node_modules/yargs": {
"version": "16.2.0",
"resolved": "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz",
"integrity": "sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==",
"dependencies": {
"cliui": "^7.0.2",
"escalade": "^3.1.1",
"get-caller-file": "^2.0.5",
"require-directory": "^2.1.1",
"string-width": "^4.2.0",
"y18n": "^5.0.5",
"yargs-parser": "^20.2.2"
},
"engines": {
"node": ">=10"
}
},
"node_modules/yargs-parser": {
"version": "20.2.9",
"resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz",
"integrity": "sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==",
"engines": {
"node": ">=10"
}
}
}
}
+16
View File
@@ -0,0 +1,16 @@
{
"name": "admin",
"version": "1.0.0",
"description": "",
"main": "index.js",
"type": "module",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC",
"dependencies": {
"firebase": "^9.19.1",
"fs": "^0.0.1-security"
}
}
+52
View File
@@ -0,0 +1,52 @@
import firebase from "firebase/compat/app";
import "firebase/compat/database";
import "firebase/compat/storage";
import fs from "fs";
firebase.initializeApp({
apiKey: "AIzaSyBWE1l8WV_7eyKT-PMu0Kq2w_WiV0SUhJw",
authDomain: "messaggiswing.firebaseapp.com",
projectId: "messaggiswing",
storageBucket: "messaggiswing.appspot.com",
messagingSenderId: "983131964310",
appId: "1:983131964310:web:5ef430e42c42d2dfe253b7",
measurementId: "G-1CBJZ3B48E",
databaseURL:
"https://messaggiswing-default-rtdb.europe-west1.firebasedatabase.app",
});
var defaultDatabase = firebase.database();
var storageRef = firebase.storage().ref();
const folder = "danisqualo";
defaultDatabase.ref(`/messaggi/${folder}`).once("value", (s) => {
const obj = s.val();
const messages = Object.keys(obj).map((d) => {
return {
key: d,
...obj[d],
};
});
var i = 0;
function move() {
const m = messages[i];
const { immagineURL } = m;
if (immagineURL) {
var url = immagineURL.substring(
immagineURL.lastIndexOf("%2F") + 3,
immagineURL.indexOf(".jpg") + 4
);
console.log(url);
storageRef
.child(`images/${folder}/${url}`)
.getDownloadURL()
.then((url) => {
defaultDatabase
.ref(`/messaggi/${folder}/${m.key}/immagineURL`)
.set(url);
});
}
i++;
if (i < messages.length) move();
}
move();
});
+6
View File
@@ -0,0 +1,6 @@
{
"rules": {
".read": true,
".write": true
}
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 632 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

+1
View File
@@ -0,0 +1 @@
{"name":"","short_name":"","icons":[{"src":"/android-chrome-192x192.png","sizes":"192x192","type":"image/png"},{"src":"/android-chrome-512x512.png","sizes":"512x512","type":"image/png"}],"theme_color":"#ffffff","background_color":"#ffffff","display":"standalone"}
+29
View File
@@ -0,0 +1,29 @@
{
"database": {
"rules": "database.rules.json"
},
"hosting": {
"public": "build",
"ignore": ["firebase.json", "**/.*", "**/node_modules/**"],
"headers": [
{
"source": "**/.jpg",
"headers": [
{
"key": "Cache-Control",
"value": "max-age=3000000"
}
]
}
],
"rewrites": [
{
"source": "**",
"destination": "/index.html"
}
]
},
"storage": {
"rules": "storage.rules"
}
}
+949 -601
View File
File diff suppressed because it is too large Load Diff
+13 -7
View File
@@ -2,36 +2,42 @@
"name": "messaggi",
"version": "0.1.0",
"private": true,
"homepage": "/",
"dependencies": {
"@emotion/react": "^11.10.5",
"@emotion/styled": "^11.10.5",
"@mui/icons-material": "^5.11.0",
"@mui/material": "^5.11.1",
"@testing-library/jest-dom": "^5.16.5",
"@testing-library/react": "^13.4.0",
"@testing-library/user-event": "^13.5.0",
"firebase": "^8.10.1",
"exif-js": "^2.3.0",
"firebase": "^9.17.2",
"localforage": "^1.10.0",
"match-sorter": "^6.3.1",
"moment": "^2.30.1",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-hook-form": "^7.41.0",
"react-router-dom": "^6.6.1",
"react-scripts": "5.0.1",
"sass": "^1.60.0",
"sort-by": "^1.2.0",
"uuid": "^9.0.1",
"web-vitals": "^2.1.4"
},
"eslintConfig": {
"extends": [
"react-app"
]
},
"scripts": {
"go": "npm run build && rm ./build/*.mp4 && scp -r ./build danilo@enne2.net:www/letsswingchat/",
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": [
"react-app",
"react-app/jest"
]
},
"browserslist": {
"production": [
">0.2%",
Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.8 KiB

After

Width:  |  Height:  |  Size: 15 KiB

+5 -21
View File
@@ -1,19 +1,13 @@
<!DOCTYPE html>
<html lang="en">
<html lang="it">
<head>
<meta charset="utf-8" />
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#000000" />
<meta
name="description"
content="Web site created using create-react-app"
/>
<meta name="description" content="Let's swing Chat!" />
<link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />
<!--
manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
-->
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
<!--
Notice the use of %PUBLIC_URL% in the tags above.
@@ -24,20 +18,10 @@
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
<title>React App</title>
<title>Let's swing chat</title>
</head>
<body>
<body style="margin: 0">
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
<!--
This HTML file is a template.
If you open it directly in the browser, you will see an empty page.
You can add webfonts, meta tags, or analytics to this file.
The build step will place the bundled scripts into the <body> tag.
To begin the development, run `npm start` or `yarn start`.
To create a production bundle, use `npm run build` or `yarn build`.
-->
</body>
</html>
Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.2 KiB

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.4 KiB

After

Width:  |  Height:  |  Size: 39 KiB

+2 -2
View File
@@ -1,6 +1,6 @@
{
"short_name": "React App",
"name": "Create React App Sample",
"short_name": "Chat Let's Swing!",
"name": "Chat Let's Swing!",
"icons": [
{
"src": "favicon.ico",
+41 -25
View File
@@ -1,38 +1,54 @@
.App {
text-align: center;
@font-face {
font-family: "LineaturaLight";
src: url("./fonts/Lineatura-Light.woff") format("woff"),
url("./fonts/Lineatura-Light.ttf") format("truetype");
font-weight: normal;
font-style: normal;
}
.App-logo {
height: 40vmin;
pointer-events: none;
@font-face {
font-family: "Lineatura";
src: url("./fonts/Lineatura.woff") format("woff"),
url("./fonts/Lineatura.ttf") format("truetype");
font-weight: normal;
font-style: normal;
}
@media (prefers-reduced-motion: no-preference) {
.App-logo {
animation: App-logo-spin infinite 20s linear;
}
html {
background: black;
}
.App-header {
background-color: #282c34;
min-height: 100vh;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
font-size: calc(10px + 2vmin);
color: white;
#myVideo {
position: fixed;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
min-width: 100%;
min-height: 100%;
}
.App-link {
color: #61dafb;
.fade-in {
transition: opacity 1s ease;
}
.fade-out {
opacity: 0;
transition: opacity 1s ease;
}
@keyframes App-logo-spin {
from {
transform: rotate(0deg);
.okbutton {
background: linear-gradient(-45deg, #ee7752, #e73c7e, #23a6d5, #23d5ab);
background-size: 400% 400%;
animation: gradient 15s ease infinite;
}
@keyframes gradient {
0% {
background-position: 0% 50%;
}
50% {
background-position: 100% 50%;
}
to {
transform: rotate(360deg);
100% {
background-position: 0% 50%;
}
}
+49
View File
@@ -0,0 +1,49 @@
import React from "react";
import ArrowForwardIcon from "@mui/icons-material/ArrowForward";
import ArrowBackIcon from "@mui/icons-material/ArrowBack";
import IconButton from "@mui/material/IconButton";
import CloseIcon from "@mui/icons-material/Close";
import { Stack } from "@mui/system";
export function Buttons(
indiceCorrente,
cambiaindiceCorrente,
messaggi,
setMainMessage
) {
return (
<Stack
style={{
display: "flex",
width: "100vw",
}}
direction="row"
>
<Stack
style={{
display: "flex",
width: "70vw",
margin: "0 auto",
justifyContent: "space-between",
}}
direction="row"
>
{indiceCorrente > 0 && (
<IconButton onClick={() => cambiaindiceCorrente(indiceCorrente - 1)}>
<ArrowBackIcon style={{ fontSize: "3rem", color: "#ddd" }} />
</IconButton>
)}
<IconButton onClick={() => setMainMessage(null)}>
<CloseIcon style={{ fontSize: "3rem", color: "#ddd" }} />
</IconButton>
{indiceCorrente < messaggi.length - 1 && (
<IconButton onClick={() => cambiaindiceCorrente(indiceCorrente + 1)}>
<ArrowForwardIcon style={{ fontSize: "3rem", color: "#ddd" }} />
</IconButton>
)}
</Stack>
</Stack>
);
}
+7 -16
View File
@@ -1,6 +1,6 @@
import { useEffect, useRef, useState } from "react";
function useInterval(callback, delay) {
export function useInterval(callback, delay) {
const savedCallback = useRef();
// Remember the latest callback.
@@ -20,29 +20,20 @@ function useInterval(callback, delay) {
}, [delay]);
}
function Countdown({ duration, onComplete }) {
// Initialize the countdown timer with the duration prop
const [timeLeft, setTimeLeft] = useState(duration);
// Decrement the timer by 1 second every 1000ms
useInterval(() => {
if(timeLeft === 1) {
onComplete()
} else{
setTimeLeft(timeLeft - 1);
if (timeLeft === 1) {
onComplete();
} else {
setTimeLeft(timeLeft - 1);
}
}, 1000);
// Return the time left formatted as minutes and seconds
let minutes = Math.floor(timeLeft / 60);
let seconds = timeLeft % 60;
return (
<div>{seconds}
</div>
);
return <span>{seconds}</span>;
}
export default Countdown
export default Countdown;
+146
View File
@@ -0,0 +1,146 @@
import React, { useState } from "react";
import firebase from "firebase/compat/app";
import "firebase/compat/storage";
import { Stack } from "@mui/system";
import { Button } from "@mui/material";
import { useParams } from "react-router-dom";
import { v4 as uuidv4 } from "uuid";
const IDLE = 0;
const IMAGE_SET = 1;
const UPLOADING = 2;
const DONE = 3;
function ImageUpload({ onImageURLSet, onImageUploading }) {
const { evento } = useParams();
const [state, setState] = useState();
const [image, setImage] = useState(null);
const [imageUrl, setImageUrl] = useState("");
const [progress, setProgress] = useState(0);
const handleChange = (e) => {
const imgRef = `images/${evento}/${uuidv4()}_${image.name}`;
if (e.target.files[0]) {
// setState(1);
let image = e.target.files[0];
onImageUploading(true);
const uploadTask = firebase.storage(imgRef).ref().put(image, {
cacheControl: "public,max-age=3000000",
contentType: "image/jpeg",
});
setState(UPLOADING);
uploadTask.on(
"state_changed",
(snapshot) => {
const progress = Math.round(
(snapshot.bytesTransferred / snapshot.totalBytes) * 100
);
setProgress(progress);
},
(error) => {
console.log(error);
},
() => {
firebase
.storage()
.ref(imgRef)
.getDownloadURL()
.then((url) => {
setImageUrl(url);
setProgress(0);
setImage(null);
onImageURLSet(url);
setState(3);
});
}
);
}
};
let componente;
switch (state) {
default:
case IDLE:
componente = (
<Stack
style={{ justifyContent: "center", alignItems: "center" }}
direction="row"
>
<input
style={{ display: "none" }}
id="camera-input"
multiple
type="file"
accept="image/*"
capture="camera"
onChange={handleChange}
/>
<label htmlFor="camera-input">
<Button style={{ padding: 20, width: "100%" }} component="span">
scatta una foto
</Button>
</label>
<input
style={{ display: "none" }}
id="gallery-input"
multiple
type="file"
accept="image/*"
onChange={handleChange}
/>
<label htmlFor="gallery-input">
<Button style={{ padding: 20, width: "100%" }} component="span">
Aggiungi un'immagine
</Button>
</label>
</Stack>
);
break;
case IMAGE_SET:
componente = (
<Stack
spacing={2}
style={{ justifyContent: "center", alignItems: "center" }}
>
<img style={{ width: 100 }} src={URL.createObjectURL(image)} />
<Stack
spacing={4}
style={{ width: "100%", justifyContent: "center" }}
direction="row"
>
<Button
onClick={() => {
setState(IDLE);
}}
>
riprova
</Button>
<Button>carica</Button>
</Stack>
</Stack>
);
break;
case UPLOADING:
componente = (
<div style={{ width: "100%" }}>
<p style={{ fontFamily: "Lineatura" }}>un attimo sto caricando...</p>
<progress style={{ width: "100%" }} value={progress} max="100" />
</div>
);
break;
case DONE:
componente = (
<div>
<img style={{ width: 200 }} src={imageUrl} />
</div>
);
}
return componente;
}
export default ImageUpload;
+19
View File
@@ -0,0 +1,19 @@
<svg width="1382" height="1382" viewBox="0 0 1382 1382" fill="none"
xmlns="http://www.w3.org/2000/svg">
<circle cx="690.606" cy="690.606" r="690.606" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M448.498 332.773L457.698 670.746L486.61 649.887L491.679 656.913C486.61 649.887 486.61 649.887 486.61 649.887L486.611 649.886L486.615 649.883L546.295 606.827L561.656 628.118L501.976 671.175L501.974 671.176L501.972 671.178L501.971 671.178C501.971 671.179 501.971 671.179 496.86 664.095L501.971 671.178L432.804 721.08L422.253 333.488L448.498 332.773Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M742.673 294.942L736.349 221.764L710.192 224.024L716.976 302.523L507.278 364.385L514.707 389.567L719.283 329.216L743.083 604.616L769.24 602.355L744.98 321.635L980.25 252.229L972.821 227.048L742.673 294.942Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M1067.97 356.735L1054.71 768.636L1028.47 767.792L1041.73 355.891L1067.97 356.735Z" fill="white"/>
<path d="M1060.05 823.936C1060.05 835.363 1050.79 844.626 1039.36 844.626C1027.93 844.626 1018.67 835.363 1018.67 823.936C1018.67 812.509 1027.93 803.246 1039.36 803.246C1050.79 803.246 1060.05 812.509 1060.05 823.936Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M1039.36 825.544C1040.25 825.544 1040.97 824.822 1040.97 823.936C1040.97 823.05 1040.25 822.328 1039.36 822.328C1038.47 822.328 1037.75 823.05 1037.75 823.936C1037.75 824.822 1038.47 825.544 1039.36 825.544ZM1039.36 844.626C1050.79 844.626 1060.05 835.363 1060.05 823.936C1060.05 812.509 1050.79 803.246 1039.36 803.246C1027.93 803.246 1018.67 812.509 1018.67 823.936C1018.67 835.363 1027.93 844.626 1039.36 844.626Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M830.82 355.371L827.343 368.029C823.809 380.894 816.733 396.693 806.676 408.586L798.2 418.61L778.152 401.658L786.628 391.634C793.627 383.357 799.224 371.275 802.026 361.074L805.504 348.416L830.82 355.371Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M547.863 751.67L582.323 956.203L558.155 965.193L489.079 851.32L512.741 973.263L488.604 982.529L365.139 777.207L387.638 763.678L472.813 905.322L449.309 784.193L473.419 774.884L545.043 892.956L521.974 756.032L547.863 751.67Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M696.373 662.459L708.866 770.841C711.603 752.426 715.157 735.473 719.804 722.214C722.605 714.22 726.102 706.682 730.68 700.906C735.283 695.099 742.302 689.531 751.876 689.531C761.136 689.531 768.059 694.588 772.691 700.339C777.181 705.913 780.407 713.117 782.865 720.581C787.82 735.626 790.864 755.586 792.769 776.521C796.605 818.657 796.108 868.226 795.208 898.772L794.821 911.893L768.578 911.12L768.965 897.998C769.857 867.716 770.312 819.421 766.623 778.901C764.767 758.508 761.929 740.942 757.928 728.793C755.909 722.66 753.889 718.849 752.245 716.808C752.13 716.665 752.023 716.539 751.924 716.426C751.73 716.636 751.507 716.896 751.256 717.213C749.295 719.687 746.964 724.098 744.581 730.897C739.861 744.364 736.099 763.751 733.252 786.239C727.588 830.977 725.898 884.973 726.103 921.069L699.935 922.647L670.292 665.465L696.373 662.459ZM752.892 715.577C752.892 715.581 752.858 715.604 752.789 715.633C752.857 715.588 752.892 715.573 752.892 715.577ZM751.126 715.653C751.061 715.624 751.029 715.602 751.029 715.597C751.029 715.593 751.061 715.607 751.126 715.653Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M630.288 776.027L652.844 942.736L626.827 946.256L604.271 779.548L630.288 776.027Z" fill="white"/>
<path d="M631.56 729.491C631.56 740.917 622.296 750.181 610.868 750.181C599.44 750.181 590.176 740.917 590.176 729.491C590.176 718.064 599.44 708.801 610.868 708.801C622.296 708.801 631.56 718.064 631.56 729.491Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M610.868 731.098C611.758 731.098 612.477 730.377 612.477 729.491C612.477 728.604 611.758 727.883 610.868 727.883C609.978 727.883 609.258 728.604 609.258 729.491C609.258 730.377 609.978 731.098 610.868 731.098ZM610.868 750.181C622.296 750.181 631.56 740.917 631.56 729.491C631.56 718.064 622.296 708.801 610.868 708.801C599.44 708.801 590.176 718.064 590.176 729.491C590.176 740.917 599.44 750.181 610.868 750.181Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M948.273 659.196L947.02 646.129L920.885 648.635L922.139 661.702C922.627 666.795 923.15 672.346 923.7 678.288C922.951 677.989 922.182 677.716 921.394 677.47C911.791 674.48 902.252 676.522 894.089 680.711C885.998 684.864 878.443 691.488 871.667 699.391C858.083 715.233 845.913 738.213 837.723 764.51C829.532 790.807 826.5 816.633 828.686 837.386C829.777 847.738 832.233 857.48 836.536 865.492C840.876 873.576 847.569 880.672 857.172 883.662C866.774 886.653 876.313 884.611 884.476 880.421C892.567 876.269 900.122 869.645 906.898 861.742C917.501 849.377 927.242 832.663 934.901 813.418C938.117 857.549 940.821 901.697 941.879 936.034C887.38 951.077 824.483 968.705 754.395 989.235C698.354 1005.65 656.686 1023.17 628.501 1040.58C614.412 1049.28 603.245 1058.22 595.334 1067.36C587.464 1076.46 582.143 1086.56 581.441 1097.35C579.927 1120.61 599.251 1135.92 622.522 1144.75C646.836 1153.97 681.694 1158.96 724.979 1158.96C848.886 1158.96 912.374 1136.4 943.218 1096.97C958.649 1077.25 964.806 1054.61 967.261 1031.85C969.114 1014.68 968.915 996.429 968.725 978.903V978.899C968.667 973.634 968.611 968.435 968.611 963.35C968.611 960.959 968.597 958.479 968.569 955.914C985.152 951.356 1000.88 947.051 1015.74 942.986L1015.75 942.983C1050.55 933.459 1080.54 925.253 1105.37 918.189L1118 914.597L1110.82 889.344L1098.19 892.936C1073.82 899.868 1044.06 908.012 1009.41 917.495L1009.4 917.498L1009.39 917.501C996.259 921.095 982.422 924.882 967.908 928.868C965.041 847.61 954.102 719.975 948.273 659.196ZM761.775 1014.43C829.149 994.696 889.584 977.725 942.356 963.139L942.356 963.35C942.356 969.126 942.416 974.773 942.475 980.305V980.308C942.657 997.483 942.828 1013.56 941.158 1029.04C938.997 1049.07 933.851 1066.34 922.538 1080.8C899.894 1109.75 848.13 1132.71 724.979 1132.71C683.195 1132.71 651.927 1127.82 631.835 1120.2C610.7 1112.18 607.339 1103.67 607.64 1099.05C607.844 1095.91 609.555 1091.05 615.188 1084.54C620.781 1078.08 629.589 1070.76 642.295 1062.92C667.699 1047.23 706.896 1030.51 761.775 1014.43ZM913.586 702.537C914.761 702.903 916.756 704.072 918.898 708.062C921.08 712.124 922.901 718.263 923.769 726.498C925.498 742.921 923.163 765.097 915.775 788.817C908.387 812.536 897.717 832.116 886.967 844.653C881.577 850.94 876.591 854.959 872.489 857.064C868.46 859.132 866.153 858.961 864.979 858.596C863.805 858.23 861.809 857.061 859.667 853.071C857.486 849.009 855.664 842.87 854.796 834.635C853.067 818.212 855.402 796.036 862.79 772.316C870.178 748.597 880.848 729.016 891.598 716.48C896.989 710.193 901.974 706.174 906.076 704.069C910.105 702.001 912.412 702.171 913.586 702.537Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M285.031 627.512C278.752 635.128 272.841 649.083 272.841 673.443C272.841 729.255 304.709 786.245 339.081 841.184C342.864 847.231 346.682 853.262 350.476 859.256C363.531 879.881 376.306 900.063 386.431 918.92C399.388 943.049 409.318 967.267 409.318 989.747C409.318 1001.87 406.236 1011.96 400.614 1020C395.049 1027.96 387.632 1033 380.386 1036.17C366.635 1042.2 351.811 1042.19 346.278 1042.19L345.963 1042.19C329.615 1042.19 305.154 1032.76 285.032 1015.71C264.352 998.197 246.587 971.251 246.587 934.958V921.831H272.841V934.958C272.841 961.826 285.77 981.932 302.001 995.679C318.787 1009.9 337.452 1015.94 345.963 1015.94C351.468 1015.94 361.445 1015.81 369.845 1012.13C373.81 1010.39 376.93 1008.06 379.1 1004.95C381.213 1001.93 383.063 997.279 383.063 989.747C383.063 974.18 375.933 954.865 363.301 931.34C353.664 913.393 341.588 894.312 328.64 873.854C324.766 867.731 320.813 861.485 316.824 855.109C282.957 800.978 246.587 737.862 246.587 673.443C246.587 645.043 253.486 624.502 264.774 610.811C276.146 597.017 291.08 591.322 304.361 591.322C316.538 591.322 333.795 597.074 347.662 612.563C361.762 628.311 371.465 653.049 370.543 689.619C370.439 693.77 370.198 698.075 369.812 702.54L368.68 715.618L342.524 713.356L343.655 700.277C343.997 696.322 344.207 692.551 344.297 688.958C345.092 657.393 336.729 639.712 328.101 630.075C319.241 620.178 309.11 617.577 304.361 617.577C298.616 617.577 291.226 619.998 285.031 627.512Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M667.144 411.415C672.139 413.586 675.993 417.251 678.918 421.43C696.479 446.529 683.944 474.664 668.703 494.657C652.768 515.559 629.43 534.035 611.565 544.847L608.802 546.519C608.121 552.4 607.762 558.108 607.767 563.534C607.788 584.829 613.304 597.504 621.606 602.796C623.781 604.183 625.348 604.247 627.367 603.572C630.053 602.672 633.757 600.237 638.237 595.478C647.168 585.992 655.715 571.053 662.383 556.893L667.975 545.016L691.728 556.201L686.136 568.077C679.148 582.918 669.188 600.904 657.352 613.475C651.449 619.745 644.204 625.622 635.701 628.468C626.53 631.538 616.666 630.783 607.492 624.934C587.35 612.094 581.536 587.143 581.512 563.56C581.489 539.18 587.539 511.582 596.218 487.089C604.843 462.746 616.609 439.94 629.044 425.725C635.045 418.865 642.727 412.221 651.81 410.117C656.719 408.979 662.023 409.189 667.144 411.415ZM616.547 509.494C627.83 500.694 639.273 489.957 647.823 478.74C661.941 460.221 664.232 446.237 657.406 436.482C657.26 436.273 657.129 436.1 657.014 435.958C655.62 436.596 652.803 438.44 648.805 443.011C639.441 453.716 629.042 473.06 620.964 495.858C619.374 500.344 617.896 504.905 616.547 509.494ZM656.446 435.371C656.446 435.371 656.452 435.374 656.462 435.382C656.451 435.375 656.446 435.371 656.446 435.371Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M847.332 419.345C847.153 387.186 873.826 369.801 899.321 369.801C926.954 369.801 942.568 391.397 947.321 400.618L953.335 412.286L929.998 424.315L923.984 412.646C920.835 406.538 912.095 396.055 899.321 396.055C884.408 396.055 873.509 405.279 873.586 419.199C873.609 423.334 875.963 428.355 883.494 435.316C889.858 441.2 898.042 446.815 907.502 453.307C909.262 454.515 911.067 455.753 912.913 457.029C924.1 464.765 936.53 473.744 946.108 484.586C955.899 495.67 963.4 509.476 963.4 526.703C963.4 544.339 955.144 557.824 942.948 566.297C931.205 574.455 916.354 577.682 902.314 577.091C888.242 576.499 873.612 572.022 862.186 563.088C850.444 553.906 842.33 540.113 842.33 522.494V509.366H868.584V522.494C868.584 531.236 872.322 537.686 878.358 542.405C884.711 547.373 893.785 550.455 903.417 550.86C913.081 551.266 921.934 548.927 927.969 544.735C933.55 540.857 937.146 535.207 937.146 526.703C937.146 517.789 933.448 509.911 926.432 501.968C919.203 493.785 909.22 486.395 897.98 478.624C896.363 477.505 894.708 476.372 893.03 475.223C883.645 468.796 873.571 461.898 865.672 454.596C856.343 445.972 847.416 434.468 847.332 419.345Z" fill="white"/>
</svg>

After

Width:  |  Height:  |  Size: 11 KiB

+22
View File
@@ -0,0 +1,22 @@
<svg width="730" height="729" viewBox="0 0 730 729" fill="none" xmlns="http://www.w3.org/2000/svg">
<circle cx="364.753" cy="364.384" r="364.306" fill="black" style="fill:black;fill-opacity:1;"/>
<path d="M315.856 615.891L304.136 619.566C303.414 617.285 302.185 615.314 300.451 613.653C298.776 611.958 296.759 610.79 294.4 610.151C290.654 609.136 287.105 609.589 283.754 611.511C280.404 613.433 278.221 616.267 277.206 620.013C276.19 623.76 276.644 627.308 278.566 630.659C280.487 634.009 283.322 636.192 287.068 637.208C289.427 637.847 291.751 637.881 294.04 637.31C296.389 636.705 298.45 635.601 300.226 633.996L308.486 643.086C305.137 646.101 301.307 648.141 296.997 649.207C292.687 650.273 288.312 650.205 283.872 649.001C276.842 647.096 271.54 643.028 267.966 636.797C264.358 630.507 263.507 623.847 265.412 616.817C267.304 609.833 271.396 604.538 277.685 600.93C283.975 597.322 290.612 596.465 297.596 598.357C302.036 599.561 305.847 601.71 309.029 604.807C312.212 607.903 314.487 611.598 315.856 615.891Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path d="M370.024 609.813L365.76 659.946L353.585 658.911L355.199 639.932L330.849 637.861L329.235 656.84L317.059 655.804L321.323 605.671L333.499 606.706L331.884 625.685L356.235 627.756L357.849 608.777L370.024 609.813Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path d="M392.075 650.333L389.502 658.913L376.206 660.302L392.782 607.982L406.793 606.518L433.825 654.282L420.528 655.671L416.238 647.808L392.075 650.333ZM409.893 636.186L401.139 620.189L395.881 637.65L409.893 636.186Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path d="M440.765 612.639L431.042 615.234L427.891 603.428L459.142 595.087L462.293 606.892L452.57 609.488L462.395 646.294L450.589 649.445L440.765 612.639Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M261.583 172.438L271.016 318.929L305.085 300.156L310.518 310.015L260.922 337.344L250.35 173.161L261.583 172.438Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M458.473 134.822L464.078 134.591L463.615 123.344C462.971 123.37 462.326 123.391 461.681 123.413C460.26 123.46 458.837 123.506 457.42 123.61C457.1 123.633 456.653 123.671 456.086 123.732C454.951 123.853 453.335 124.064 451.297 124.431C447.222 125.166 441.456 126.522 434.471 129.021C422.249 133.394 406.335 141.251 389.26 155.335L384.83 125.403L373.694 127.051L379.187 164.166C361.692 179.37 344.787 185.69 332.191 188.223C325.559 189.557 320.093 189.846 316.338 189.809C314.461 189.791 313.014 189.692 312.068 189.602C311.594 189.557 311.246 189.515 311.032 189.487C310.925 189.472 310.852 189.462 310.813 189.456L310.786 189.452L310.785 189.451L310.781 189.451L305.252 188.514L303.371 199.612C304.008 199.72 304.645 199.834 305.282 199.948C306.7 200.201 308.118 200.455 309.545 200.645C309.896 200.692 310.386 200.75 311.006 200.809C312.247 200.927 314.012 201.044 316.229 201.066C320.662 201.109 326.916 200.766 334.411 199.259C347.358 196.655 363.925 190.589 381.111 177.165L399.788 303.365L410.923 301.717L391.208 168.499C409.198 152.421 425.98 144.015 438.263 139.62C444.614 137.348 449.775 136.144 453.293 135.51C455.052 135.193 456.4 135.019 457.28 134.925C457.719 134.878 458.042 134.852 458.24 134.837C458.339 134.83 458.407 134.826 458.443 134.824L458.468 134.822L458.469 134.822L458.473 134.822Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M510.375 185.602L516.478 361.734L505.228 362.124L499.125 185.991L510.375 185.602Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path d="M520.859 385.824C520.859 390.724 516.887 394.695 511.987 394.695C507.087 394.695 503.115 390.724 503.115 385.824C503.115 380.925 507.087 376.953 511.987 376.953C516.887 376.953 520.859 380.925 520.859 385.824Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M511.987 386.514C512.369 386.514 512.677 386.204 512.677 385.824C512.677 385.444 512.369 385.135 511.987 385.135C511.605 385.135 511.297 385.444 511.297 385.824C511.297 386.204 511.605 386.514 511.987 386.514ZM511.987 394.695C516.887 394.695 520.859 390.724 520.859 385.824C520.859 380.925 516.887 376.953 511.987 376.953C507.087 376.953 503.115 380.925 503.115 385.824C503.115 390.724 507.087 394.695 511.987 394.695Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M438.197 171.433L419.807 190.057L411.797 182.147L430.187 163.523L438.197 171.433Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M310.528 361.492L325.303 449.189L314.941 453.044L285.323 404.219L295.469 456.504L285.12 460.477L232.182 372.442L241.829 366.641L278.349 427.373L268.271 375.437L278.609 371.446L309.319 422.071L299.427 363.362L310.528 361.492Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M396.841 349.907C396.521 349.708 396.266 349.616 395.633 349.803C395.588 349.817 394.914 350.073 393.786 351.539C392.704 352.945 391.532 355.042 390.358 357.86C388.014 363.482 385.984 371.183 384.5 379.91C381.773 395.941 381.055 414.412 383.078 428.171L383.737 432.007L372.668 434.053C372.407 432.731 372.172 431.366 371.964 429.965L357.232 344.231L368.327 342.324L373.943 375.006C375.461 366.952 377.486 359.482 379.967 353.53C381.358 350.192 382.974 347.131 384.864 344.675C386.707 342.279 389.189 339.968 392.445 339.007C396.117 337.923 399.701 338.429 402.787 340.349C405.651 342.131 407.722 344.894 409.255 347.761C412.311 353.473 414.199 361.44 415.348 369.761C417.668 386.564 417.276 407.225 415.278 420.64L414.449 426.207L403.315 424.549L404.144 418.982C405.987 406.609 406.368 387.026 404.197 371.301C403.1 363.359 401.427 356.992 399.329 353.071C398.286 351.122 397.383 350.244 396.841 349.907Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M340.519 364.5L353.389 441.44L342.286 443.297L329.416 366.357L340.519 364.5Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path d="M340.615 343.332C340.615 348.232 336.643 352.203 331.743 352.203C326.843 352.203 322.871 348.232 322.871 343.332C322.871 338.433 326.843 334.461 331.743 334.461C336.643 334.461 340.615 338.433 340.615 343.332Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M331.743 344.021C332.125 344.021 332.433 343.712 332.433 343.332C332.433 342.952 332.125 342.643 331.743 342.643C331.361 342.643 331.053 342.952 331.053 343.332C331.053 343.712 331.361 344.021 331.743 344.021ZM331.743 352.203C336.643 352.203 340.615 348.232 340.615 343.332C340.615 338.433 336.643 334.461 331.743 334.461C326.843 334.461 322.871 338.433 322.871 343.332C322.871 348.232 326.843 352.203 331.743 352.203Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M478.038 314.564L477.501 308.961L466.295 310.036L466.833 315.638C467.143 318.878 467.487 322.549 467.852 326.561C466.346 325.48 464.618 324.667 462.657 324.26C458.455 323.388 454.491 324.651 451.202 326.765C447.944 328.86 445.016 331.98 442.473 335.606C437.374 342.876 433.171 353.108 430.79 364.578C428.408 376.047 428.191 387.107 429.973 395.805C430.863 400.144 432.306 404.172 434.462 407.391C436.637 410.639 439.771 413.375 443.973 414.248C448.175 415.12 452.139 413.857 455.428 411.743C458.687 409.648 461.614 406.528 464.157 402.901C467.446 398.212 470.363 392.289 472.658 385.598C473.879 402.855 474.883 419.814 475.297 433.263C451.929 439.713 424.961 447.271 394.91 456.074C370.881 463.112 353.015 470.625 340.93 478.088C334.889 481.818 330.101 485.653 326.71 489.572C323.335 493.473 321.054 497.802 320.752 502.43C320.104 512.402 328.389 518.966 338.367 522.752C348.792 526.707 363.738 528.847 382.297 528.847C435.424 528.847 462.646 519.175 475.871 502.269C482.487 493.81 485.127 484.104 486.18 474.346C486.974 466.984 486.889 459.159 486.807 451.644V451.644V451.643C486.783 449.385 486.759 447.156 486.759 444.975C486.759 443.95 486.752 442.886 486.741 441.787C493.851 439.832 500.596 437.986 506.965 436.244L506.969 436.242C521.892 432.159 534.75 428.64 545.398 425.611L550.812 424.071L547.732 413.244L542.318 414.784C531.868 417.756 519.108 421.248 504.249 425.315C498.616 426.857 492.682 428.481 486.457 430.19C485.228 395.35 480.537 340.624 478.038 314.564ZM398.074 466.877C426.962 458.415 452.874 451.138 475.501 444.885L475.501 444.975C475.501 447.452 475.527 449.874 475.552 452.246C475.631 459.61 475.704 466.504 474.988 473.139C474.061 481.727 471.855 489.132 467.004 495.333C457.295 507.745 435.1 517.59 382.297 517.59C364.381 517.59 350.975 515.495 342.36 512.227C333.298 508.789 331.857 505.142 331.986 503.161C332.074 501.812 332.807 499.73 335.222 496.938C337.62 494.167 341.397 491.03 346.845 487.666C357.737 480.94 374.544 473.769 398.074 466.877ZM460.369 335.282C460.865 335.385 461.748 335.788 462.815 337.38C463.901 339.002 464.923 341.518 465.629 344.963C467.037 351.833 466.965 361.305 464.818 371.642C462.672 381.978 458.967 390.697 454.941 396.438C452.922 399.318 450.982 401.219 449.34 402.274C447.728 403.311 446.758 403.329 446.261 403.226C445.765 403.123 444.882 402.72 443.816 401.127C442.73 399.506 441.707 396.99 441.001 393.545C439.593 386.675 439.666 377.202 441.812 366.866C443.958 356.53 447.663 347.811 451.689 342.069C453.709 339.19 455.648 337.289 457.29 336.233C458.902 335.197 459.873 335.179 460.369 335.282Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M196.279 311.836C192.967 314.797 189.941 320.573 189.941 330.659C189.941 339.127 193.054 347.837 198.236 357.05C203.425 366.275 210.393 375.508 217.658 385.104L217.907 385.432C224.991 394.788 232.344 404.5 237.91 414.336C243.547 424.299 247.658 434.902 247.658 446.004C247.658 470.846 230.858 484.893 213.082 484.612C204.352 484.475 195.64 480.839 189.152 473.652C182.65 466.448 178.684 456.032 178.684 442.788V437.16H189.941V442.788C189.941 453.756 193.189 461.324 197.508 466.109C201.843 470.91 207.561 473.267 213.26 473.357C224.342 473.531 236.401 464.975 236.401 446.004C236.401 437.662 233.297 429.043 228.112 419.88C222.921 410.706 215.953 401.5 208.683 391.899L208.671 391.882C201.51 382.425 194.054 372.577 188.425 362.569C182.785 352.542 178.684 341.86 178.684 330.659C178.684 318.377 182.415 309.132 188.776 303.444C195.156 297.74 203.452 296.295 210.944 298.301C226.321 302.418 237.161 320.125 228.828 343.489L226.937 348.791L216.334 345.009L218.225 339.708C224.743 321.432 215.976 311.302 208.033 309.175C203.864 308.059 199.573 308.891 196.279 311.836Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M366.577 249.756C362.674 260.903 351.965 273.467 337.17 273.467L333.61 273.467C333.805 276.602 334.261 279.643 334.991 282.485C336.755 289.347 339.977 294.568 344.478 297.558C346.566 298.945 350.399 299.837 354.373 299.022C358.117 298.253 361.638 296.046 363.718 291.628L366.115 286.536L376.3 291.332L373.902 296.424C370.127 304.441 363.409 308.659 356.636 310.049C350.093 311.392 343.131 310.178 338.249 306.935C330.703 301.922 326.29 293.854 324.088 285.286C321.881 276.695 321.754 267.116 323.17 258.213C324.583 249.337 327.597 240.714 332.054 234.15C336.459 227.661 342.93 222.325 351.264 222.325C354.918 222.325 358.262 223.136 361.074 224.898C363.913 226.678 365.862 229.213 367.022 232.061C369.261 237.553 368.568 244.068 366.577 249.756ZM333.973 262.21C334.065 261.465 334.17 260.722 334.288 259.982C335.512 252.286 338.065 245.336 341.367 240.472C344.721 235.532 348.198 233.582 351.264 233.582C353.26 233.582 354.427 234.017 355.095 234.436C355.735 234.837 356.235 235.418 356.598 236.31C357.407 238.296 357.451 241.753 355.952 246.036C352.873 254.831 345.236 262.21 337.17 262.21L333.973 262.21Z" fill="white" style="fill:white;fill-opacity:1;"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M424.361 223.617C423.309 209.869 434.19 201.624 445.094 200.851C456.912 200.013 464.245 208.776 466.558 212.575L469.484 217.383L459.868 223.236L456.941 218.428C455.41 215.91 451.354 211.692 445.89 212.08C439.512 212.532 435.13 216.808 435.586 222.759C435.721 224.527 436.88 226.603 440.312 229.352C443.212 231.675 446.883 233.828 451.126 236.318C451.915 236.781 452.725 237.256 453.553 237.746C458.572 240.715 464.161 244.178 468.586 248.525C473.11 252.968 476.737 258.645 477.26 266.013C477.77 273.211 475.31 279.22 470.969 283.514C466.744 287.694 461.044 289.967 455.323 290.569C444.059 291.755 430.595 286.499 425.958 272.946L424.136 267.621L434.787 263.977L436.609 269.303C439.105 276.598 446.614 280.167 454.145 279.374C457.821 278.987 460.973 277.569 463.052 275.512C465.016 273.568 466.313 270.791 466.031 266.809C465.76 262.997 463.94 259.74 460.698 256.555C457.358 253.275 452.864 250.417 447.821 247.434C447.096 247.005 446.353 246.57 445.601 246.13C441.392 243.666 436.874 241.021 433.275 238.138C429.023 234.732 424.856 230.083 424.361 223.617Z" fill="white" style="fill:white;fill-opacity:1;"/>
</svg>

After

Width:  |  Height:  |  Size: 13 KiB

+19
View File
@@ -0,0 +1,19 @@
<svg width="1382" height="1382" viewBox="0 0 1382 1382" fill="none"
xmlns="http://www.w3.org/2000/svg">
<circle cx="690.606" cy="690.606" r="690.606" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M448.498 332.773L457.698 670.746L486.61 649.887L491.679 656.913C486.61 649.887 486.61 649.887 486.61 649.887L486.611 649.886L486.615 649.883L546.295 606.827L561.656 628.118L501.976 671.175L501.974 671.176L501.972 671.178L501.971 671.178C501.971 671.179 501.971 671.179 496.86 664.095L501.971 671.178L432.804 721.08L422.253 333.488L448.498 332.773Z" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M742.673 294.942L736.349 221.764L710.192 224.024L716.976 302.523L507.278 364.385L514.707 389.567L719.283 329.216L743.083 604.616L769.24 602.355L744.98 321.635L980.25 252.229L972.821 227.048L742.673 294.942Z" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M1067.97 356.735L1054.71 768.636L1028.47 767.792L1041.73 355.891L1067.97 356.735Z" fill="black"/>
<path d="M1060.05 823.936C1060.05 835.363 1050.79 844.626 1039.36 844.626C1027.93 844.626 1018.67 835.363 1018.67 823.936C1018.67 812.509 1027.93 803.246 1039.36 803.246C1050.79 803.246 1060.05 812.509 1060.05 823.936Z" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M1039.36 825.544C1040.25 825.544 1040.97 824.822 1040.97 823.936C1040.97 823.05 1040.25 822.328 1039.36 822.328C1038.47 822.328 1037.75 823.05 1037.75 823.936C1037.75 824.822 1038.47 825.544 1039.36 825.544ZM1039.36 844.626C1050.79 844.626 1060.05 835.363 1060.05 823.936C1060.05 812.509 1050.79 803.246 1039.36 803.246C1027.93 803.246 1018.67 812.509 1018.67 823.936C1018.67 835.363 1027.93 844.626 1039.36 844.626Z" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M830.82 355.371L827.343 368.029C823.809 380.894 816.733 396.693 806.676 408.586L798.2 418.61L778.152 401.658L786.628 391.634C793.627 383.357 799.224 371.275 802.026 361.074L805.504 348.416L830.82 355.371Z" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M547.863 751.67L582.323 956.203L558.155 965.193L489.079 851.32L512.741 973.263L488.604 982.529L365.139 777.207L387.638 763.678L472.813 905.322L449.309 784.193L473.419 774.884L545.043 892.956L521.974 756.032L547.863 751.67Z" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M696.373 662.459L708.866 770.841C711.603 752.426 715.157 735.473 719.804 722.214C722.605 714.22 726.102 706.682 730.68 700.906C735.283 695.099 742.302 689.531 751.876 689.531C761.136 689.531 768.059 694.588 772.691 700.339C777.181 705.913 780.407 713.117 782.865 720.581C787.82 735.626 790.864 755.586 792.769 776.521C796.605 818.657 796.108 868.226 795.208 898.772L794.821 911.893L768.578 911.12L768.965 897.998C769.857 867.716 770.312 819.421 766.623 778.901C764.767 758.508 761.929 740.942 757.928 728.793C755.909 722.66 753.889 718.849 752.245 716.808C752.13 716.665 752.023 716.539 751.924 716.426C751.73 716.636 751.507 716.896 751.256 717.213C749.295 719.687 746.964 724.098 744.581 730.897C739.861 744.364 736.099 763.751 733.252 786.239C727.588 830.977 725.898 884.973 726.103 921.069L699.935 922.647L670.292 665.465L696.373 662.459ZM752.892 715.577C752.892 715.581 752.858 715.604 752.789 715.633C752.857 715.588 752.892 715.573 752.892 715.577ZM751.126 715.653C751.061 715.624 751.029 715.602 751.029 715.597C751.029 715.593 751.061 715.607 751.126 715.653Z" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M630.288 776.027L652.844 942.736L626.827 946.256L604.271 779.548L630.288 776.027Z" fill="black"/>
<path d="M631.56 729.491C631.56 740.917 622.296 750.181 610.868 750.181C599.44 750.181 590.176 740.917 590.176 729.491C590.176 718.064 599.44 708.801 610.868 708.801C622.296 708.801 631.56 718.064 631.56 729.491Z" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M610.868 731.098C611.758 731.098 612.477 730.377 612.477 729.491C612.477 728.604 611.758 727.883 610.868 727.883C609.978 727.883 609.258 728.604 609.258 729.491C609.258 730.377 609.978 731.098 610.868 731.098ZM610.868 750.181C622.296 750.181 631.56 740.917 631.56 729.491C631.56 718.064 622.296 708.801 610.868 708.801C599.44 708.801 590.176 718.064 590.176 729.491C590.176 740.917 599.44 750.181 610.868 750.181Z" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M948.273 659.196L947.02 646.129L920.885 648.635L922.139 661.702C922.627 666.795 923.15 672.346 923.7 678.288C922.951 677.989 922.182 677.716 921.394 677.47C911.791 674.48 902.252 676.522 894.089 680.711C885.998 684.864 878.443 691.488 871.667 699.391C858.083 715.233 845.913 738.213 837.723 764.51C829.532 790.807 826.5 816.633 828.686 837.386C829.777 847.738 832.233 857.48 836.536 865.492C840.876 873.576 847.569 880.672 857.172 883.662C866.774 886.653 876.313 884.611 884.476 880.421C892.567 876.269 900.122 869.645 906.898 861.742C917.501 849.377 927.242 832.663 934.901 813.418C938.117 857.549 940.821 901.697 941.879 936.034C887.38 951.077 824.483 968.705 754.395 989.235C698.354 1005.65 656.686 1023.17 628.501 1040.58C614.412 1049.28 603.245 1058.22 595.334 1067.36C587.464 1076.46 582.143 1086.56 581.441 1097.35C579.927 1120.61 599.251 1135.92 622.522 1144.75C646.836 1153.97 681.694 1158.96 724.979 1158.96C848.886 1158.96 912.374 1136.4 943.218 1096.97C958.649 1077.25 964.806 1054.61 967.261 1031.85C969.114 1014.68 968.915 996.429 968.725 978.903V978.899C968.667 973.634 968.611 968.435 968.611 963.35C968.611 960.959 968.597 958.479 968.569 955.914C985.152 951.356 1000.88 947.051 1015.74 942.986L1015.75 942.983C1050.55 933.459 1080.54 925.253 1105.37 918.189L1118 914.597L1110.82 889.344L1098.19 892.936C1073.82 899.868 1044.06 908.012 1009.41 917.495L1009.4 917.498L1009.39 917.501C996.259 921.095 982.422 924.882 967.908 928.868C965.041 847.61 954.102 719.975 948.273 659.196ZM761.775 1014.43C829.149 994.696 889.584 977.725 942.356 963.139L942.356 963.35C942.356 969.126 942.416 974.773 942.475 980.305V980.308C942.657 997.483 942.828 1013.56 941.158 1029.04C938.997 1049.07 933.851 1066.34 922.538 1080.8C899.894 1109.75 848.13 1132.71 724.979 1132.71C683.195 1132.71 651.927 1127.82 631.835 1120.2C610.7 1112.18 607.339 1103.67 607.64 1099.05C607.844 1095.91 609.555 1091.05 615.188 1084.54C620.781 1078.08 629.589 1070.76 642.295 1062.92C667.699 1047.23 706.896 1030.51 761.775 1014.43ZM913.586 702.537C914.761 702.903 916.756 704.072 918.898 708.062C921.08 712.124 922.901 718.263 923.769 726.498C925.498 742.921 923.163 765.097 915.775 788.817C908.387 812.536 897.717 832.116 886.967 844.653C881.577 850.94 876.591 854.959 872.489 857.064C868.46 859.132 866.153 858.961 864.979 858.596C863.805 858.23 861.809 857.061 859.667 853.071C857.486 849.009 855.664 842.87 854.796 834.635C853.067 818.212 855.402 796.036 862.79 772.316C870.178 748.597 880.848 729.016 891.598 716.48C896.989 710.193 901.974 706.174 906.076 704.069C910.105 702.001 912.412 702.171 913.586 702.537Z" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M285.031 627.512C278.752 635.128 272.841 649.083 272.841 673.443C272.841 729.255 304.709 786.245 339.081 841.184C342.864 847.231 346.682 853.262 350.476 859.256C363.531 879.881 376.306 900.063 386.431 918.92C399.388 943.049 409.318 967.267 409.318 989.747C409.318 1001.87 406.236 1011.96 400.614 1020C395.049 1027.96 387.632 1033 380.386 1036.17C366.635 1042.2 351.811 1042.19 346.278 1042.19L345.963 1042.19C329.615 1042.19 305.154 1032.76 285.032 1015.71C264.352 998.197 246.587 971.251 246.587 934.958V921.831H272.841V934.958C272.841 961.826 285.77 981.932 302.001 995.679C318.787 1009.9 337.452 1015.94 345.963 1015.94C351.468 1015.94 361.445 1015.81 369.845 1012.13C373.81 1010.39 376.93 1008.06 379.1 1004.95C381.213 1001.93 383.063 997.279 383.063 989.747C383.063 974.18 375.933 954.865 363.301 931.34C353.664 913.393 341.588 894.312 328.64 873.854C324.766 867.731 320.813 861.485 316.824 855.109C282.957 800.978 246.587 737.862 246.587 673.443C246.587 645.043 253.486 624.502 264.774 610.811C276.146 597.017 291.08 591.322 304.361 591.322C316.538 591.322 333.795 597.074 347.662 612.563C361.762 628.311 371.465 653.049 370.543 689.619C370.439 693.77 370.198 698.075 369.812 702.54L368.68 715.618L342.524 713.356L343.655 700.277C343.997 696.322 344.207 692.551 344.297 688.958C345.092 657.393 336.729 639.712 328.101 630.075C319.241 620.178 309.11 617.577 304.361 617.577C298.616 617.577 291.226 619.998 285.031 627.512Z" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M667.144 411.415C672.139 413.586 675.993 417.251 678.918 421.43C696.479 446.529 683.944 474.664 668.703 494.657C652.768 515.559 629.43 534.035 611.565 544.847L608.802 546.519C608.121 552.4 607.762 558.108 607.767 563.534C607.788 584.829 613.304 597.504 621.606 602.796C623.781 604.183 625.348 604.247 627.367 603.572C630.053 602.672 633.757 600.237 638.237 595.478C647.168 585.992 655.715 571.053 662.383 556.893L667.975 545.016L691.728 556.201L686.136 568.077C679.148 582.918 669.188 600.904 657.352 613.475C651.449 619.745 644.204 625.622 635.701 628.468C626.53 631.538 616.666 630.783 607.492 624.934C587.35 612.094 581.536 587.143 581.512 563.56C581.489 539.18 587.539 511.582 596.218 487.089C604.843 462.746 616.609 439.94 629.044 425.725C635.045 418.865 642.727 412.221 651.81 410.117C656.719 408.979 662.023 409.189 667.144 411.415ZM616.547 509.494C627.83 500.694 639.273 489.957 647.823 478.74C661.941 460.221 664.232 446.237 657.406 436.482C657.26 436.273 657.129 436.1 657.014 435.958C655.62 436.596 652.803 438.44 648.805 443.011C639.441 453.716 629.042 473.06 620.964 495.858C619.374 500.344 617.896 504.905 616.547 509.494ZM656.446 435.371C656.446 435.371 656.452 435.374 656.462 435.382C656.451 435.375 656.446 435.371 656.446 435.371Z" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M847.332 419.345C847.153 387.186 873.826 369.801 899.321 369.801C926.954 369.801 942.568 391.397 947.321 400.618L953.335 412.286L929.998 424.315L923.984 412.646C920.835 406.538 912.095 396.055 899.321 396.055C884.408 396.055 873.509 405.279 873.586 419.199C873.609 423.334 875.963 428.355 883.494 435.316C889.858 441.2 898.042 446.815 907.502 453.307C909.262 454.515 911.067 455.753 912.913 457.029C924.1 464.765 936.53 473.744 946.108 484.586C955.899 495.67 963.4 509.476 963.4 526.703C963.4 544.339 955.144 557.824 942.948 566.297C931.205 574.455 916.354 577.682 902.314 577.091C888.242 576.499 873.612 572.022 862.186 563.088C850.444 553.906 842.33 540.113 842.33 522.494V509.366H868.584V522.494C868.584 531.236 872.322 537.686 878.358 542.405C884.711 547.373 893.785 550.455 903.417 550.86C913.081 551.266 921.934 548.927 927.969 544.735C933.55 540.857 937.146 535.207 937.146 526.703C937.146 517.789 933.448 509.911 926.432 501.968C919.203 493.785 909.22 486.395 897.98 478.624C896.363 477.505 894.708 476.372 893.03 475.223C883.645 468.796 873.571 461.898 865.672 454.596C856.343 445.972 847.416 434.468 847.332 419.345Z" fill="black"/>
</svg>

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+119 -198
View File
@@ -1,225 +1,146 @@
import React, { useEffect, useState } from "react";
import "./App.css";
import React, { useState } from "react";
import ReactDOM from "react-dom/client";
import { BrowserRouter as Router, Routes, Route, Link } from "react-router-dom";
import firebase from "firebase/app";
import "firebase/database";
import TextField from "@mui/material/TextField";
import { Stack } from "@mui/system";
import { Button } from "@mui/material";
import { useForm } from "react-hook-form";
import Countdown from "./Countdown";
import List from "@mui/material/List";
import ListItem from "@mui/material/ListItem";
import ListItemButton from "@mui/material/ListItemButton";
import ListItemText from "@mui/material/ListItemText";
import Checkbox from "@mui/material/Checkbox";
const MyForm = () => {
const [mandato, cambiaMandato] = useState(false);
const { register, handleSubmit } = useForm();
const onSubmit = ({ testo, autore }) => {
var postListRef = firebase.database().ref("messaggi");
var newPostRef = postListRef.push();
console.log(newPostRef.key);
newPostRef.set({
id: newPostRef.key,
autore,
testo,
timestamp: firebase.database.ServerValue.TIMESTAMP,
approvato: true,
});
cambiaMandato(true);
};
if (mandato) {
return (
<Stack>
<div>mandato e mo aspetti</div>
<Countdown onComplete={() => cambiaMandato(false)} duration={5} />
</Stack>
);
}
return (
<form onSubmit={handleSubmit(onSubmit)}>
<Stack spacing={2}>
<TextField
{...register("testo", { required: true, maxLength: 20 })}
id="outlined-basic"
label="messaggio"
variant="outlined"
/>
<TextField
{...register("autore", { pattern: /^[A-Za-z]+$/i })}
id="outlined-basic"
label="da"
variant="outlined"
/>
<Button type="submit" variant="contained">
manda
</Button>
</Stack>
</form>
);
};
import {
BrowserRouter as Router,
Routes,
Route,
Link,
useParams,
} from "react-router-dom";
import firebase from "firebase/compat/app";
import "firebase/compat/database";
import "firebase/compat/analytics";
import { ProjectionPage } from "./routes/ProjectionPage";
import { MyFormPage } from "./routes/MyFormPage";
import { AdminPage } from "./routes/AdminPage";
import { GalleryPage } from "./routes/GalleryPage";
import { HomePage } from "./routes/HomePage";
import { Button, CssBaseline, ThemeProvider, createTheme } from "@mui/material";
import EXIF from "exif-js";
const firebaseConfig = {
apiKey: "AIzaSyASAEVOTQ38EmRoelz9qGiF6QsqpBOuU_k",
authDomain: "messaggi-letsswing.firebaseapp.com",
apiKey: "AIzaSyBWE1l8WV_7eyKT-PMu0Kq2w_WiV0SUhJw",
authDomain: "messaggiswing.firebaseapp.com",
databaseURL:
"https://messaggi-letsswing-default-rtdb.europe-west1.firebasedatabase.app",
projectId: "messaggi-letsswing",
storageBucket: "messaggi-letsswing.appspot.com",
messagingSenderId: "154307951524",
appId: "1:154307951524:web:f320027fb89982a3f05f31",
"https://messaggiswing-default-rtdb.europe-west1.firebasedatabase.app",
projectId: "messaggiswing",
storageBucket: "messaggiswing.appspot.com",
messagingSenderId: "983131964310",
appId: "1:983131964310:web:5ef430e42c42d2dfe253b7",
measurementId: "G-1CBJZ3B48E",
};
firebase.initializeApp(firebaseConfig);
firebase.analytics();
function CheckboxListSecondary({ messaggi, onChecked }) {
return (
<List
dense
sx={{ width: "100%", maxWidth: 360, bgcolor: "background.paper" }}
>
{messaggi.map((m) => {
const labelId = `checkbox-list-secondary-label-${m.timestamp}`;
return (
<ListItem
key={m.timestamp}
secondaryAction={
<Checkbox
edge="end"
onChange={() => onChecked(m)}
checked={m.approvato}
inputProps={{ "aria-labelledby": labelId }}
/>
}
disablePadding
>
<ListItemButton>
<ListItemText
id={labelId}
primary={`"${m.testo}" da ${m.autore}`}
/>
</ListItemButton>
</ListItem>
);
})}
</List>
);
function parseDate(s) {
var b = s.split(/\D/);
return new Date(b[0], b[1] - 1, b[2], b[3], b[4], b[5]);
}
const Admin = () => {
const [messaggi, cambiaMessaggi] = useState([]);
const [indiceCorrente, cambiaindiceCorrente] = useState(0);
const darkTheme = createTheme({
palette: {
mode: "dark",
background: "black",
},
});
useEffect(() => {
// Get a reference to the messages node in the Realtime Database
var messagesRef = firebase.database().ref("/messaggi");
const Upload = () => {
const { evento } = useParams();
const [uploadedFiles, setUploadedFiles] = useState([]);
messagesRef.on("value", function (snapshot) {
var messaggi = snapshot.val();
messaggi = Object.keys(messaggi).map((d) => messaggi[d]);
cambiaMessaggi(messaggi);
});
const handleUploadFiles = (files) => {
let index = 0;
messagesRef.on("child_changed", function (snapshot) {
var messaggio = snapshot.val();
const i = messaggi.findIndex((m) => messaggio.timestamp === m.timestamp);
});
}, []);
if (!messaggi.length) return <div>nessun messaggio</div>;
return (
<Stack>
<hr />
<CheckboxListSecondary
messaggi={messaggi}
onChecked={(m) => {
firebase
.database()
.ref("messaggi/" + m.id)
.update({
approvato: !m.approvato,
function upload() {
const image = files[index];
EXIF.getData(image, function () {
var time = EXIF.getTag(this, "DateTime");
if (time) {
const timestamp = new Date(parseDate(time)).getTime();
const uploadTask = firebase
.storage()
.ref(`images/${evento}/${image.name}`)
.put(image, {
cacheControl: "public,max-age=3000000",
contentType: "image/jpeg",
});
}}
/>
</Stack>
);
};
const Proiezione = () => {
const [messaggi, cambiaMessaggi] = useState([]);
const [indiceCorrente, cambiaindiceCorrente] = useState(0);
uploadTask.on(
"state_changed",
(snapshot) => {
const progress = Math.round(
(snapshot.bytesTransferred / snapshot.totalBytes) * 100
);
console.log(progress);
},
(error) => {
console.log(error);
},
(d) => {
// all done
console.log(d);
// var postListRef = firebase.database().ref(`messaggi/${evento}`);
// var newPostRef = postListRef.push();
// const update = {
// id: newPostRef.key,
// timestamp,
// approvato: true,
// immagineURL: "",
// };
useEffect(() => {
// Get a reference to the messages node in the Realtime Database
var messagesRef = firebase.database().ref("/messaggi");
// newPostRef.set(update);
messagesRef.on("child_added", function (snapshot) {
var messaggio = snapshot.val();
if (messaggio.approvato) {
cambiaMessaggi((oldArray) =>
[...oldArray, messaggio].sort((a, b) => b.timestamp - a.timestamp)
);
}
});
// if (++index < files.length) {
// upload();
// }
}
);
}
});
}
messagesRef.on("child_changed", function (snapshot) {
// console.log(indiceCorrente); Rimane alla versione iniziale!
var messaggio = snapshot.val();
if (messaggio.approvato) {
cambiaMessaggi((oldArray) =>
[...oldArray, messaggio].sort((a, b) => b.timestamp - a.timestamp)
);
} else {
var nuovoIndice
cambiaMessaggi((oldArray) => {
nuovoIndice = oldArray.findIndex((d) => d.id === messaggio.id);
oldArray.splice(nuovoIndice, 1);
return oldArray;
});
}
});
}, []);
const nextMessage = (i) => {
let nuovoIndice = (i + 1) % messaggi.length;
cambiaindiceCorrente(nuovoIndice);
upload();
};
const whereAmI = () => {
console.log(indiceCorrente);
const handleFileEvent = (e) => {
const chosenFiles = Array.prototype.slice.call(e.target.files);
handleUploadFiles(chosenFiles);
};
return (
<div>
<MyForm />
{!messaggi.length && <div>nessun messaggio</div>}
{messaggi.length && (
<div>
<i>{indiceCorrente}</i>
<h1>{messaggi[indiceCorrente].testo}</h1>
<p>da {messaggi[indiceCorrente].autore}</p>
</div>
)}
<Button onClick={() => nextMessage(indiceCorrente)}>next</Button>
<div className="App">
<input
id="fileUpload"
type="file"
multiple
accept="image/jpg"
onChange={handleFileEvent}
/>
<Admin />
<Button variant="contained">Upload Files</Button>
<div className="uploaded-files-list">
{uploadedFiles.map((file) => (
<div>{file.name}</div>
))}
</div>
</div>
);
};
const Input = () => {
return <div> Input </div>;
};
ReactDOM.createRoot(document.getElementById("root")).render(
<Router>
<Routes>
<Route path="/" element={<Input />} />
<Route path="proiezione" element={<Proiezione />} />
<Route path="admin" element={<Admin />} />
</Routes>
</Router>
<ThemeProvider theme={darkTheme}>
<CssBaseline />
<Router>
<Routes>
<Route path="/" element={<HomePage />} />
<Route path="/:evento" element={<MyFormPage />} />
<Route path="/eventi/:evento" element={<GalleryPage />} />
<Route path="proiezione/:evento" element={<ProjectionPage />} />
<Route path="admin/:evento" element={<AdminPage />} />
<Route path="upload/:evento" element={<Upload />} />
</Routes>
</Router>
</ThemeProvider>
);
-1
View File
@@ -1 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 841.9 595.3"><g fill="#61DAFB"><path d="M666.3 296.5c0-32.5-40.7-63.3-103.1-82.4 14.4-63.6 8-114.2-20.2-130.4-6.5-3.8-14.1-5.6-22.4-5.6v22.3c4.6 0 8.3.9 11.4 2.6 13.6 7.8 19.5 37.5 14.9 75.7-1.1 9.4-2.9 19.3-5.1 29.4-19.6-4.8-41-8.5-63.5-10.9-13.5-18.5-27.5-35.3-41.6-50 32.6-30.3 63.2-46.9 84-46.9V78c-27.5 0-63.5 19.6-99.9 53.6-36.4-33.8-72.4-53.2-99.9-53.2v22.3c20.7 0 51.4 16.5 84 46.6-14 14.7-28 31.4-41.3 49.9-22.6 2.4-44 6.1-63.6 11-2.3-10-4-19.7-5.2-29-4.7-38.2 1.1-67.9 14.6-75.8 3-1.8 6.9-2.6 11.5-2.6V78.5c-8.4 0-16 1.8-22.6 5.6-28.1 16.2-34.4 66.7-19.9 130.1-62.2 19.2-102.7 49.9-102.7 82.3 0 32.5 40.7 63.3 103.1 82.4-14.4 63.6-8 114.2 20.2 130.4 6.5 3.8 14.1 5.6 22.5 5.6 27.5 0 63.5-19.6 99.9-53.6 36.4 33.8 72.4 53.2 99.9 53.2 8.4 0 16-1.8 22.6-5.6 28.1-16.2 34.4-66.7 19.9-130.1 62-19.1 102.5-49.9 102.5-82.3zm-130.2-66.7c-3.7 12.9-8.3 26.2-13.5 39.5-4.1-8-8.4-16-13.1-24-4.6-8-9.5-15.8-14.4-23.4 14.2 2.1 27.9 4.7 41 7.9zm-45.8 106.5c-7.8 13.5-15.8 26.3-24.1 38.2-14.9 1.3-30 2-45.2 2-15.1 0-30.2-.7-45-1.9-8.3-11.9-16.4-24.6-24.2-38-7.6-13.1-14.5-26.4-20.8-39.8 6.2-13.4 13.2-26.8 20.7-39.9 7.8-13.5 15.8-26.3 24.1-38.2 14.9-1.3 30-2 45.2-2 15.1 0 30.2.7 45 1.9 8.3 11.9 16.4 24.6 24.2 38 7.6 13.1 14.5 26.4 20.8 39.8-6.3 13.4-13.2 26.8-20.7 39.9zm32.3-13c5.4 13.4 10 26.8 13.8 39.8-13.1 3.2-26.9 5.9-41.2 8 4.9-7.7 9.8-15.6 14.4-23.7 4.6-8 8.9-16.1 13-24.1zM421.2 430c-9.3-9.6-18.6-20.3-27.8-32 9 .4 18.2.7 27.5.7 9.4 0 18.7-.2 27.8-.7-9 11.7-18.3 22.4-27.5 32zm-74.4-58.9c-14.2-2.1-27.9-4.7-41-7.9 3.7-12.9 8.3-26.2 13.5-39.5 4.1 8 8.4 16 13.1 24 4.7 8 9.5 15.8 14.4 23.4zM420.7 163c9.3 9.6 18.6 20.3 27.8 32-9-.4-18.2-.7-27.5-.7-9.4 0-18.7.2-27.8.7 9-11.7 18.3-22.4 27.5-32zm-74 58.9c-4.9 7.7-9.8 15.6-14.4 23.7-4.6 8-8.9 16-13 24-5.4-13.4-10-26.8-13.8-39.8 13.1-3.1 26.9-5.8 41.2-7.9zm-90.5 125.2c-35.4-15.1-58.3-34.9-58.3-50.6 0-15.7 22.9-35.6 58.3-50.6 8.6-3.7 18-7 27.7-10.1 5.7 19.6 13.2 40 22.5 60.9-9.2 20.8-16.6 41.1-22.2 60.6-9.9-3.1-19.3-6.5-28-10.2zM310 490c-13.6-7.8-19.5-37.5-14.9-75.7 1.1-9.4 2.9-19.3 5.1-29.4 19.6 4.8 41 8.5 63.5 10.9 13.5 18.5 27.5 35.3 41.6 50-32.6 30.3-63.2 46.9-84 46.9-4.5-.1-8.3-1-11.3-2.7zm237.2-76.2c4.7 38.2-1.1 67.9-14.6 75.8-3 1.8-6.9 2.6-11.5 2.6-20.7 0-51.4-16.5-84-46.6 14-14.7 28-31.4 41.3-49.9 22.6-2.4 44-6.1 63.6-11 2.3 10.1 4.1 19.8 5.2 29.1zm38.5-66.7c-8.6 3.7-18 7-27.7 10.1-5.7-19.6-13.2-40-22.5-60.9 9.2-20.8 16.6-41.1 22.2-60.6 9.9 3.1 19.3 6.5 28.1 10.2 35.4 15.1 58.3 34.9 58.3 50.6-.1 15.7-23 35.6-58.4 50.6zM320.8 78.4z"/><circle cx="420.9" cy="296.5" r="45.7"/><path d="M520.5 78.1z"/></g></svg>

Before

Width:  |  Height:  |  Size: 2.6 KiB

+119
View File
@@ -0,0 +1,119 @@
import IconButton from "@mui/material/IconButton";
import DeleteIcon from "@mui/icons-material/Delete";
import React, { useEffect, useState } from "react";
import firebase from "firebase/compat/app";
import { Stack } from "@mui/system";
import { useParams } from "react-router-dom";
import { Checkbox } from "@mui/material";
function CheckboxListSecondary({ messaggi, evento, onChecked }) {
return (
<Stack sx={{ background: "white" }} spacing={4}>
{messaggi.map((m) => {
const labelId = `checkbox-list-secondary-label-${m.timestamp}`;
return (
<Stack spacing={3} direction="row" key={m.timestamp}>
<Checkbox
edge="end"
onChange={() => onChecked(m)}
checked={m.approvato}
inputProps={{ "aria-labelledby": labelId }}
/>
<div
style={{
background: `url("${m.immagineURL}")`,
backgroundSize: "cover",
width: 50,
height: 50,
}}
/>
<p style={{ maxWidth: 200, width: 200 }}>
{`"${m.testo}"`}
{m.autore && <span>da {m.autore}</span>}
</p>
<IconButton
variant="outlined"
onClick={() => {
console.log(`messaggi/${evento}/${m.id}`);
firebase.database().ref(`messaggi/${evento}/${m.id}`).remove();
}}
>
<DeleteIcon />
</IconButton>
</Stack>
);
})}
</Stack>
);
}
export const AdminPage = () => {
const [messaggi, cambiaMessaggi] = useState([]);
const { evento } = useParams();
useEffect(() => {
// Get a reference to the messages node in the Realtime Database
var messagesRef = firebase.database().ref(`/messaggi/${evento}`);
console.log(messagesRef);
messagesRef.on("value", function (snapshot) {
var messaggi = snapshot.val();
if (messaggi) {
messaggi = Object.keys(messaggi).map((d) => messaggi[d]);
cambiaMessaggi(messaggi);
}
});
messagesRef.on("child_changed", function (snapshot) {
messagesRef.once("value", function (snapshot) {
var messaggi = snapshot.val();
if (messaggi) {
messaggi = Object.keys(messaggi).map((d) => messaggi[d]);
cambiaMessaggi(messaggi);
}
});
});
messagesRef.on("child_removed", function (snapshot) {
messagesRef.once("value", function (snapshot) {
var messaggi = snapshot.val();
if (messaggi) {
messaggi = Object.keys(messaggi).map((d) => messaggi[d]);
console.log("sdaf");
cambiaMessaggi(messaggi);
} else {
cambiaMessaggi([]);
}
});
});
}, []);
let element;
if (!messaggi.length) {
element = <div>nessun messaggio</div>;
} else {
element = (
<CheckboxListSecondary
evento={evento}
messaggi={messaggi}
onChecked={(m) => {
firebase
.database()
.ref(`/messaggi/${evento}/` + m.id)
.update({
approvato: !m.approvato,
});
}}
/>
);
}
return (
<Stack>
<h2>Admin</h2>
{element}
</Stack>
);
};
+268
View File
@@ -0,0 +1,268 @@
import React, { useEffect, useState } from "react";
import { useParams } from "react-router-dom";
import firebase from "firebase/compat/app";
import { Stack } from "@mui/system";
import logoSrc from "../assets/logo_chat.svg";
import { Box, Button, CircularProgress, Container, Grid } from "@mui/material";
import { VideoComponent } from "./ProjectionPage";
import { Buttons } from "../Buttons";
import moment from "moment";
import { Logo } from "./HomePage";
export const GalleryPage = () => {
const { evento } = useParams();
const [mainMessage, setMainMessage] = useState(null);
const [messages, setMessages] = useState([]);
const [eventDetails, setEventDetails] = useState(null);
useEffect(() => {
const eventRef = firebase.database().ref(`/eventi/${evento}`);
eventRef.once("value", function (s) {
setEventDetails(s.val());
});
const messagesRef = firebase.database().ref(`/messaggi/${evento}`);
messagesRef.once("value", function (snapshot) {
const messaggiObject = snapshot.val();
const messaggi = Object.keys(messaggiObject)
.map((d) => {
return messaggiObject[d];
})
.filter((d) => d.approvato)
.sort((a, b) => a.timestamp - b.timestamp);
setMessages(messaggi);
});
}, [evento]);
if (!eventDetails) return <></>;
return (
<div style={{ background: "black" }}>
<Logo />
<Container
style={{
fontFamily: "Lineatura",
fontWeight: "bold",
color: "white",
zIndex: 1,
position: "relative",
top: 0,
}}
>
{mainMessage == null ? (
<GridView
eventDetails={eventDetails}
setMainMessage={setMainMessage}
messages={messages}
/>
) : (
<ContenitoreMessaggio
messages={messages}
setMainMessage={setMainMessage}
mainMessage={mainMessage}
/>
)}
</Container>
</div>
);
};
const GridView = ({ eventDetails, messages, setMainMessage }) => {
return (
<>
<h1
style={{
fontSize: "4.6rem",
}}
>
{eventDetails.title}
</h1>
{messages.length && (
<GridThumbs messages={messages} setMainMessage={setMainMessage} />
)}
</>
);
};
const Timestamp = ({ message }) => {
return <p>alle {moment(message.timestamp).format("HH:MM")}</p>;
};
const GridThumbs = ({ messages, setMainMessage }) => {
const getElement = (message) => {
let element;
if (message.immagineURL) {
element = (
<img
onClick={() => {
setMainMessage(message);
}}
width="100%"
height="auto"
sx={{ border: "4px solid white" }}
src={message.immagineURL}
alt={message.message}
/>
);
} else {
element = (
<h1
style={{
fontSize: "1.2rem",
textAlign: "center",
textShadow:
"0px 0px 10px rgba(0,0,0,100), 0px 0px 10px rgba(0,0,0,100), 0px 0px 10px rgba(0,0,0,100)",
}}
>
{message.testo}
</h1>
);
}
return (
<div style={{ textAlign: "center" }}>
{element}
{message.autore && (
<div>
<p
style={{
fontSize: 20,
margin: 0,
display: "inline-block",
background: "black",
padding: "0px 6px",
paddingBottom: "4px",
}}
>
da {message.autore}
</p>
</div>
)}
<Timestamp message={message} />
</div>
);
};
return (
<Grid xs={12} sm={12} container spacing={2}>
{messages.map((message, index) => (
<Grid item xs={6} sm={4} key={index}>
<Box
my={4}
p={2}
sx={{ overflow: "hidden", height: "100%" }}
display="flex"
alignItems="center"
justifyContent="center"
>
{getElement(message)}
</Box>
</Grid>
))}
</Grid>
);
};
const ContenitoreMessaggio = ({ messages, setMainMessage, mainMessage }) => {
const [indiceCorrente, cambiaindiceCorrente] = useState(
messages.findIndex((d) => d === mainMessage)
);
const messaggioDaMostrare = messages[indiceCorrente];
return (
<Stack sx={{ zIndex: 1 }} alignItems={"center"} justifyContent={"center"}>
{messaggioDaMostrare.immagineURL && (
<ImagePlaceholder
messaggioDaMostrare={messaggioDaMostrare}
style={{
maxWidth: "100%",
maxHeight: "80vh",
}}
/>
)}
<Messaggio messaggioDaMostrare={messaggioDaMostrare} />
{Buttons(indiceCorrente, cambiaindiceCorrente, messages, setMainMessage)}
</Stack>
);
};
function ImagePlaceholder({ messaggioDaMostrare }) {
const [imageLoaded, setImageLoaded] = useState(false);
useEffect(() => {
console.log("go");
setImageLoaded(false);
if (messaggioDaMostrare.immagineURL) {
const image = new Image();
image.onload = () => {
setImageLoaded(true);
};
image.src = messaggioDaMostrare.immagineURL;
} else {
setImageLoaded(true);
}
}, [messaggioDaMostrare.immagineURL]);
if (imageLoaded) {
return (
<div>
{messaggioDaMostrare.immagineURL && (
<img
alt=""
src={messaggioDaMostrare.immagineURL}
style={{
maxWidth: "100%",
maxHeight: "65vh",
}}
/>
)}
</div>
);
} else {
return (
<Box
sx={{
display: "flex",
alignItems: "center",
justifyContent: "space-around",
width: "100%",
}}
>
<CircularProgress />
</Box>
);
}
}
const Messaggio = ({ messaggioDaMostrare }) => {
return (
<>
<h1
style={{
fontSize: messaggioDaMostrare.immagineURL ? 20 : 50,
textShadow:
"0px 0px 10px rgba(0,0,0,100), 0px 0px 10px rgba(0,0,0,100), 0px 0px 10px rgba(0,0,0,100)",
}}
>
{messaggioDaMostrare.testo}
</h1>
{messaggioDaMostrare.autore && (
<div>
<p
style={{
fontSize: 20,
margin: 0,
display: "inline-block",
background: "black",
padding: "0px 6px",
paddingBottom: "4px",
}}
>
da {messaggioDaMostrare.autore}
</p>
</div>
)}
<Timestamp message={messaggioDaMostrare} />
</>
);
};
+77
View File
@@ -0,0 +1,77 @@
import React, { useEffect, useState } from "react";
import firebase from "firebase/compat/app";
import { CircularProgress, Container, Stack, Typography } from "@mui/material";
import logoSrc from "../assets/logo_chat.svg";
export const HomePage = () => {
const [eventi, cambiaEventi] = useState([]);
useEffect(() => {
var messagesRef = firebase.database().ref(`/eventi`);
messagesRef.once("value", function (snapshot) {
const eventiObject = snapshot.val();
console.log(eventiObject);
const e = Object.keys(eventiObject)
.map((d) => {
return { key: d, ...eventiObject[d] };
})
.sort((a, b) => {
return parseInt(a.timestamp) - parseInt(b.timestamp);
})
.map((d, i) => {
const color = `hsl(${i * 10}, 75%, 70%`;
return (
<div key={d.key}>
<a
style={{
textDecoration: "none",
display: "inline-block",
color,
fontFamily: "Lineatura",
borderBottom: `1px solid ${color}`,
}}
href={`/eventi/${d.key}`}
>
{d.title}
</a>
</div>
);
});
cambiaEventi(e);
});
}, []);
if (!eventi) return <div></div>;
return (
<Container maxWidth="md">
<img
alt="logo"
src={logoSrc}
style={{
width: 120,
position: "absolute",
top: 20,
right: 20,
}}
/>
<Stack
spacing={2}
sx={{
paddingTop: 20,
}}
>
<Typography
variant="p"
style={{
fontFamily: "Lineatura",
}}
>
I nostri eventi
</Typography>
{eventi.length === 0 && <CircularProgress size={20} />}
{eventi}
</Stack>
</Container>
);
};
+86
View File
@@ -0,0 +1,86 @@
import React, { useEffect, useState } from "react";
import firebase from "firebase/compat/app";
import { CircularProgress, Container, Stack, Typography } from "@mui/material";
import logoSrc from "../assets/logo_chat.svg";
export const HomePage = () => {
const [eventi, cambiaEventi] = useState([]);
useEffect(() => {
var messagesRef = firebase.database().ref(`/eventi`);
messagesRef.once("value", function (snapshot) {
const eventiObject = snapshot.val();
console.log(eventiObject);
const e = Object.keys(eventiObject)
.map((d) => {
return { key: d, ...eventiObject[d] };
})
.sort((a, b) => {
return parseInt(a.timestamp) - parseInt(b.timestamp);
})
.map((d, i) => {
const color = `hsl(${i * 10}, 75%, 70%`;
return (
<div key={d.key}>
<a
style={{
textDecoration: "none",
display: "inline-block",
color,
fontSize: "1.5rem",
fontFamily: "Lineatura",
borderBottom: `2px solid ${color}`,
}}
href={`/eventi/${d.key}`}
>
{d.title}
</a>
</div>
);
});
cambiaEventi(e);
});
}, []);
if (!eventi) return <div></div>;
return (
<Container maxWidth="md">
<Logo />
<Stack
spacing={2}
sx={{
paddingTop: 20,
}}
>
<Typography
variant="p"
style={{
color: "white",
fontFamily: "Lineatura",
}}
>
I nostri eventi
</Typography>
{eventi.length === 0 && <CircularProgress size={20} />}
{eventi}
</Stack>
</Container>
);
};
export const Logo = () => {
return (
<img
alt="logo"
src={logoSrc}
style={{
width: 120,
position: "absolute",
zIndex: 2,
top: 20,
right: 20,
}}
/>
);
};
+127
View File
@@ -0,0 +1,127 @@
import logoSrc from "../assets/logo_chat.svg";
import React, { useState } from "react";
import firebase from "firebase/compat/app";
import TextField from "@mui/material/TextField";
import { Container, Stack } from "@mui/system";
import { Button, Typography } from "@mui/material";
import { useForm } from "react-hook-form";
import Countdown from "../Countdown";
import ImageUpload from "../ImageUpload";
import { useParams } from "react-router-dom";
export const MyFormPage = () => {
const { evento } = useParams();
const [mandato, setMandato] = useState(false);
const [imageUploading, setImageUploading] = useState(false);
const [immagineURL, cambiaimmagineURL] = useState(null);
const { register, handleSubmit, reset } = useForm();
const onSubmit = ({ testo, autore }, e) => {
reset("", {
keepValues: false,
});
setMandato(true);
cambiaimmagineURL(null);
var postListRef = firebase.database().ref(`messaggi/${evento}`);
var newPostRef = postListRef.push();
const update = {
id: newPostRef.key,
autore,
testo,
timestamp: firebase.database.ServerValue.TIMESTAMP,
approvato: true,
};
if (immagineURL) update.immagineURL = immagineURL;
newPostRef.set(update);
};
const onImageURLSet = (url) => {
cambiaimmagineURL(url);
};
if (mandato) {
return (
<div
style={{
fontFamily: "Lineatura",
height: "100vh",
width: "100%",
textAlign: "center",
}}
>
<Typography
style={{
fontFamily: "Lineatura",
}}
variant="h2"
>
mandato!
</Typography>
<h1 style={{ fontFamily: "LineaturaLight" }}>
puoi rimandere un altro messaggio in...
<Countdown onComplete={() => setMandato(false)} duration={5} />
</h1>
</div>
);
}
return (
<Container maxWidth="sm" style={{ color: "white", marginTop: 20 }}>
<div style={{ textAlign: "center" }}>
<img
alt="logo"
src={logoSrc}
style={{
width: 200,
marginBottom: 20,
}}
/>
<Typography
variant="h5"
style={{ marginBottom: 40, fontFamily: "Lineatura" }}
>
Manda un messaggio!
</Typography>
</div>
<form onSubmit={handleSubmit(onSubmit)}>
<Stack spacing={2}>
<TextField
multiline
rows={4}
{...register("testo")}
id="outlined-basic"
label="messaggio"
variant="outlined"
/>
<TextField
{...register("autore")}
id="outlined-basic"
label="da"
variant="outlined"
/>
<ImageUpload
onImageUploading={() => {
setImageUploading(true);
}}
onImageURLSet={(b) => {
onImageURLSet(b);
setImageUploading(false);
}}
/>
{!imageUploading && (
<Button
className="okbutton"
type="submit"
style={{
padding: "30px 0px",
fontSize: 20,
fontFamily: "Lineatura",
}}
variant="contained"
>
ok
</Button>
)}
</Stack>
</form>
</Container>
);
};
+193
View File
@@ -0,0 +1,193 @@
import React, { useEffect, useState } from "react";
import firebase from "firebase/compat/app";
import logoSrc from "../assets/logo_chat.svg";
import { useParams } from "react-router-dom";
const SHOW_MESSAGE_TIME = 6000;
window.debug = false;
export const ProjectionPage = () => {
const { evento } = useParams();
const [messaggi, cambiaMessaggi] = useState([]);
const [messaggiApprovati, cambiaMessaggiApprovati] = useState([]);
useEffect(() => {
var messagesRef = firebase.database().ref(`/messaggi/${evento}`);
messagesRef.on("child_added", function (snapshot) {
console.log("child_added");
var messaggio = snapshot.val();
cambiaMessaggi((oldArray) => {
const newArray = [...oldArray, messaggio].sort(
(a, b) => b.timestamp - a.timestamp
);
cambiaMessaggiApprovati(newArray.filter((d) => d.approvato));
return newArray;
});
});
messagesRef.on("child_removed", function (snapshot) {
console.log("child_removed");
var messaggio = snapshot.val();
cambiaMessaggi((oldArray) => {
const newArray = [];
oldArray.forEach((d) => {
if (d.id !== messaggio.id) {
newArray.push(d);
}
});
newArray.sort((a, b) => b.timestamp - a.timestamp);
cambiaMessaggiApprovati(newArray.filter((d) => d.approvato));
return newArray;
});
});
messagesRef.on("child_changed", function (snapshot) {
console.log("child_changed");
const messaggio = snapshot.val();
cambiaMessaggi((oldArray) => {
const newArray = [...oldArray];
newArray.forEach((d, i, a) => {
if (d.id === messaggio.id) a[i] = messaggio;
});
cambiaMessaggiApprovati(newArray.filter((d) => d.approvato));
return newArray;
});
});
messagesRef.onDisconnect();
}, []);
const ContainerMessaggio = ({ messaggiApprovati }) => {
if (!messaggiApprovati.length) {
return <div>nessun messaggio</div>;
} else {
return <Messaggio messaggiApprovati={messaggiApprovati} />;
}
};
return (
<div>
<VideoComponent />
<ContainerMessaggio messaggiApprovati={messaggiApprovati} />
<img
src={logoSrc}
style={{
width: 120,
position: "absolute",
top: 20,
right: 20,
}}
/>
</div>
);
};
const Messaggio = ({ messaggiApprovati }) => {
const [fadeProp, setFadeProp] = useState("in");
const [messaggioDaMostrare, setMessaggioDaMostrare] = useState(null);
const [indiceCorrente, cambiaindiceCorrente] = useState(0);
const [imageWidth, setImageWidth] = useState(0);
const [rotation, setRotation] = useState(0);
const nextMessage = () => {
const newIndice = (indiceCorrente + 1) % messaggiApprovati.length;
cambiaindiceCorrente(newIndice);
};
const showNextMessage = (newMessage) => {
setFadeProp("in");
setMessaggioDaMostrare(newMessage);
setTimeout(() => {
nextMessage();
}, SHOW_MESSAGE_TIME);
};
useEffect(() => {
const newMessage = messaggiApprovati[indiceCorrente];
if (newMessage !== messaggioDaMostrare) {
setFadeProp("out");
const timeout = setTimeout(() => {
console.log(newMessage.immagineURL);
if (newMessage.immagineURL) {
const img = new Image();
img.onload = (i) => {
setImageWidth(img.width > img.height ? 800 : 400);
setRotation(Math.random() * 10 - 5);
showNextMessage(newMessage);
};
img.src = newMessage.immagineURL;
} else {
showNextMessage(newMessage);
}
}, 3000);
return () => clearTimeout(timeout);
}
}, [indiceCorrente]);
return (
<div className={"fade-" + fadeProp}>
<div
style={{
position: "absolute",
fontFamily: "Lineatura",
width: "100%",
height: "100vh",
fontWeight: "bold",
color: "white",
display: "flex",
justifyContent: "space-around",
alignContent: "center",
alignItems: "center",
textAlign: "center",
}}
>
{messaggioDaMostrare && (
<div>
{messaggioDaMostrare.immagineURL && (
<img
src={messaggioDaMostrare.immagineURL}
style={{
border: "10px solid #ccc",
width: imageWidth,
transformOrigin: "50% 50%",
transform: `rotate(${rotation}deg)`,
}}
/>
)}
<h1
style={{
fontSize: messaggioDaMostrare.immagineURL ? 20 : 50,
textShadow:
"0px 0px 10px rgba(0,0,0,100), 0px 0px 10px rgba(0,0,0,100), 0px 0px 10px rgba(0,0,0,100)",
}}
>
{messaggioDaMostrare.testo}
</h1>
{messaggioDaMostrare.autore && (
<p
style={{
fontSize: 20,
display: "inline-block",
background: "black",
padding: "0px 6px",
paddingBottom: "4px",
}}
>
da {messaggioDaMostrare.autore}
</p>
)}
</div>
)}
</div>
</div>
);
};
export const VideoComponent = React.memo(() => {
return (
<video autoPlay muted loop id="myVideo">
<source src={"https://letsswing.it/video.mp4"} type="video/mp4" />
</video>
);
});
+8
View File
@@ -0,0 +1,8 @@
rules_version = '2';
service firebase.storage {
match /b/{bucket}/o {
match /{allPaths=**} {
allow read, write: if false;
}
}
}