Feature requests

This commit is contained in:
Ral 2021-12-27 17:01:20 +01:00
parent e2f6bfb51d
commit 49049693f6
7 changed files with 28 additions and 11 deletions

View File

@ -4,7 +4,7 @@
<meta name=viewport content="width=device-width,initial-scale=1,shrink-to-fit=no"> <meta name=viewport content="width=device-width,initial-scale=1,shrink-to-fit=no">
<title>rC3 NOWHERE</title> <title>rC3 NOWHERE</title>
<link href=/fork-awesome/css/fork-awesome.min.css rel=stylesheet type=text/css> <link href=/fork-awesome/css/fork-awesome.min.css rel=stylesheet type=text/css>
<link rel=stylesheet href=https://infobeamer.montage2.de/hashtag.min.f51cff1ba38414d9536af60c407a9355010d66bbc4838dd06742d900708e6b1a.css> <link rel=stylesheet href=https://infobeamer.montage2.de/hashtag.min.2aa7328190003e6cb7a17022ef4963477c4b84a66394cbf036577da543d0edad.css>
<script src=https://infobeamer.montage2.de/js/config.0f4d0d28e4cf21f765f0b1911e185b73399aa76b4db102fc085df728a4e0c8fe.js integrity="sha256-D00NKOTPIfdl8LGRHhhbczmap2tNsQL8CF33KKTgyP4="></script> <script src=https://infobeamer.montage2.de/js/config.0f4d0d28e4cf21f765f0b1911e185b73399aa76b4db102fc085df728a4e0c8fe.js integrity="sha256-D00NKOTPIfdl8LGRHhhbczmap2tNsQL8CF33KKTgyP4="></script>
</head> </head>
<body> <body>
@ -13,6 +13,6 @@
<script src=https://infobeamer.montage2.de/js/moment/moment.min.73de4254959530e4d1d9bec586379184f96b4953dacf9cd5e5e2bdd7bfeceef7.js integrity="sha256-c95CVJWVMOTR2b7FhjeRhPlrSVPaz5zV5eK917/s7vc="></script> <script src=https://infobeamer.montage2.de/js/moment/moment.min.73de4254959530e4d1d9bec586379184f96b4953dacf9cd5e5e2bdd7bfeceef7.js integrity="sha256-c95CVJWVMOTR2b7FhjeRhPlrSVPaz5zV5eK917/s7vc="></script>
<script src=https://infobeamer.montage2.de/js/preact/preact.min.0c204e20934f1e09cfe86fbcf1d069d842f988fc71efe3a923021c08892c71c8.js integrity="sha256-DCBOIJNPHgnP6G+88dBp2EL5iPxx7+OpIwIcCIksccg="></script> <script src=https://infobeamer.montage2.de/js/preact/preact.min.0c204e20934f1e09cfe86fbcf1d069d842f988fc71efe3a923021c08892c71c8.js integrity="sha256-DCBOIJNPHgnP6G+88dBp2EL5iPxx7+OpIwIcCIksccg="></script>
<script src=https://infobeamer.montage2.de/js/htm/htm.80e39afe20fd61183412eda89efa10532d57945e6364642aceacd50eb2384b4b.js integrity="sha256-gOOa/iD9YRg0Eu2onvoQUy1XlF5jZGQqzqzVDrI4S0s="></script> <script src=https://infobeamer.montage2.de/js/htm/htm.80e39afe20fd61183412eda89efa10532d57945e6364642aceacd50eb2384b4b.js integrity="sha256-gOOa/iD9YRg0Eu2onvoQUy1XlF5jZGQqzqzVDrI4S0s="></script>
<script src=https://infobeamer.montage2.de/main.ec4847eb1a7e9db3e0ba4d4ccd76aec3fd6761cf9309df4a74f2216e541cbed6.js integrity="sha256-7EhH6xp+nbPguk1MzXauw/1nYc+TCd9KdPIhblQcvtY=" type=module></script> <script src=https://infobeamer.montage2.de/main.6088a37a89f70987a1a9e5ae8a30b5f78523fa343161b81b945288bae18d92fd.js integrity="sha256-YIijeon3CYehqeWuijC194Uj+jQxYbgblFKIuuGNkv0=" type=module></script>
</body> </body>
</html> </html>

View File

@ -4,7 +4,7 @@
<meta name=viewport content="width=device-width,initial-scale=1,shrink-to-fit=no"> <meta name=viewport content="width=device-width,initial-scale=1,shrink-to-fit=no">
<title>rC3 NOWHERE</title> <title>rC3 NOWHERE</title>
<link href=/fork-awesome/css/fork-awesome.min.css rel=stylesheet type=text/css> <link href=/fork-awesome/css/fork-awesome.min.css rel=stylesheet type=text/css>
<link rel=stylesheet href=https://infobeamer.montage2.de/main.min.3246905d9c5049050261edfad3e555dfb4633e1f36e4b3ab755c9f643cfac284.css> <link rel=stylesheet href=https://infobeamer.montage2.de/main.min.b382673c86fa3dbd614dda558d4e4094904d954e4dd4d3d427e2af5f254dc968.css>
<script src=https://infobeamer.montage2.de/js/config.0f4d0d28e4cf21f765f0b1911e185b73399aa76b4db102fc085df728a4e0c8fe.js integrity="sha256-D00NKOTPIfdl8LGRHhhbczmap2tNsQL8CF33KKTgyP4="></script> <script src=https://infobeamer.montage2.de/js/config.0f4d0d28e4cf21f765f0b1911e185b73399aa76b4db102fc085df728a4e0c8fe.js integrity="sha256-D00NKOTPIfdl8LGRHhhbczmap2tNsQL8CF33KKTgyP4="></script>
</head> </head>
<body> <body>
@ -13,6 +13,6 @@
<script src=https://infobeamer.montage2.de/js/moment/moment.min.73de4254959530e4d1d9bec586379184f96b4953dacf9cd5e5e2bdd7bfeceef7.js integrity="sha256-c95CVJWVMOTR2b7FhjeRhPlrSVPaz5zV5eK917/s7vc="></script> <script src=https://infobeamer.montage2.de/js/moment/moment.min.73de4254959530e4d1d9bec586379184f96b4953dacf9cd5e5e2bdd7bfeceef7.js integrity="sha256-c95CVJWVMOTR2b7FhjeRhPlrSVPaz5zV5eK917/s7vc="></script>
<script src=https://infobeamer.montage2.de/js/preact/preact.min.0c204e20934f1e09cfe86fbcf1d069d842f988fc71efe3a923021c08892c71c8.js integrity="sha256-DCBOIJNPHgnP6G+88dBp2EL5iPxx7+OpIwIcCIksccg="></script> <script src=https://infobeamer.montage2.de/js/preact/preact.min.0c204e20934f1e09cfe86fbcf1d069d842f988fc71efe3a923021c08892c71c8.js integrity="sha256-DCBOIJNPHgnP6G+88dBp2EL5iPxx7+OpIwIcCIksccg="></script>
<script src=https://infobeamer.montage2.de/js/htm/htm.80e39afe20fd61183412eda89efa10532d57945e6364642aceacd50eb2384b4b.js integrity="sha256-gOOa/iD9YRg0Eu2onvoQUy1XlF5jZGQqzqzVDrI4S0s="></script> <script src=https://infobeamer.montage2.de/js/htm/htm.80e39afe20fd61183412eda89efa10532d57945e6364642aceacd50eb2384b4b.js integrity="sha256-gOOa/iD9YRg0Eu2onvoQUy1XlF5jZGQqzqzVDrI4S0s="></script>
<script src=https://infobeamer.montage2.de/main.ec4847eb1a7e9db3e0ba4d4ccd76aec3fd6761cf9309df4a74f2216e541cbed6.js integrity="sha256-7EhH6xp+nbPguk1MzXauw/1nYc+TCd9KdPIhblQcvtY=" type=module></script> <script src=https://infobeamer.montage2.de/main.6088a37a89f70987a1a9e5ae8a30b5f78523fa343161b81b945288bae18d92fd.js integrity="sha256-YIijeon3CYehqeWuijC194Uj+jQxYbgblFKIuuGNkv0=" type=module></script>
</body> </body>
</html> </html>

View File

@ -8,6 +8,10 @@
"https://abs.twimg.com/sticky/default_profile_images/default_profile_normal.png", "https://abs.twimg.com/sticky/default_profile_images/default_profile_normal.png",
"https://chaos.social/avatars/original/missing.png" "https://chaos.social/avatars/original/missing.png"
]; ];
var socialFilters = [
RegExp("http.://bit.ly/.*\\w+")
];
var socialReplacement = "\u2588\u2588\u2588\u2588\u2588";
var default_profile_image_url = () => "./nounicorn.png"; var default_profile_image_url = () => "./nounicorn.png";
var social_limiter = (tweets, toots) => { var social_limiter = (tweets, toots) => {
let posts = tweets.concat(toots); let posts = tweets.concat(toots);
@ -15,6 +19,7 @@
let recentPosts = posts.filter(maxAge); let recentPosts = posts.filter(maxAge);
let byDate = (fst, snd) => Date.parse(fst.time) - Date.parse(snd.time); let byDate = (fst, snd) => Date.parse(fst.time) - Date.parse(snd.time);
let postsSorted = recentPosts.sort(byDate); let postsSorted = recentPosts.sort(byDate);
console.log("Number distinct social posts in loop: " + postsSorted.length);
if (postsSorted.length > 0) { if (postsSorted.length > 0) {
while (postsSorted.length < postsLimit) { while (postsSorted.length < postsLimit) {
postsSorted = postsSorted.concat(postsSorted); postsSorted = postsSorted.concat(postsSorted);
@ -24,6 +29,12 @@
return postsLimited; return postsLimited;
}; };
var replace_default_image_url = (url) => defaultUrlSet.includes(url) === true ? default_profile_image_url() : url; var replace_default_image_url = (url) => defaultUrlSet.includes(url) === true ? default_profile_image_url() : url;
var censorship = (text) => {
socialFilters.forEach((f) => {
text = text.replace(f, socialReplacement);
});
return text;
};
var tweet_author = (data, tweet) => { var tweet_author = (data, tweet) => {
let authorId = tweet.author_id; let authorId = tweet.author_id;
let users = data.includes.users; let users = data.includes.users;
@ -46,7 +57,7 @@
return { return {
author: tweet_author(d, t), author: tweet_author(d, t),
image: tweet_profile_image(d, t), image: tweet_profile_image(d, t),
text: tweet_text(t), text: censorship(tweet_text(t)),
time: tweet_time(t), time: tweet_time(t),
source: "twitter" source: "twitter"
}; };
@ -73,7 +84,7 @@
return { return {
author: toot_author(t), author: toot_author(t),
image: toot_profile_image(t), image: toot_profile_image(t),
text: html_plainify(toot_text(t)), text: censorship(html_plainify(toot_text(t))),
time: toot_time(t), time: toot_time(t),
source: "mastodon" source: "mastodon"
}; };
@ -396,11 +407,17 @@
}; };
var hashtag_dom = () => { var hashtag_dom = () => {
let inner = html` let inner = html`
<div id="hashtags" class="visible hashtags"> <div class="hashtags short">
<div class="box"> <div class="box">
<div class="header">For Questions:</div> <div class="header">For Questions:</div>
<div class="text">Please use the Hashtag <span class="hashtag">#rc3cwtv</span> or join our IRC Channel <span class="irc">#rc3-cwtv</span></div> <div class="text">Please use the Hashtag <span class="hashtag">#rc3cwtv</span> or join our IRC Channel <span class="irc">#rc3-cwtv</span></div>
</div> </div>
</div>
<div class="hashtags extended">
<div class="box">
<div class="header">For Questions:</div>
<div class="text">Please use the Hashtag <span class="hashtag">#rc3cwtv</span> on Twitter or Mastodon, or join our IRC channel <span class="irc">#rc3-cwtv</span>:irc.hackint.org</div>
</div>
</div>`; </div>`;
return inner; return inner;
}; };

View File

@ -13,6 +13,6 @@
<script src=https://infobeamer.montage2.de/js/moment/moment.min.73de4254959530e4d1d9bec586379184f96b4953dacf9cd5e5e2bdd7bfeceef7.js integrity="sha256-c95CVJWVMOTR2b7FhjeRhPlrSVPaz5zV5eK917/s7vc="></script> <script src=https://infobeamer.montage2.de/js/moment/moment.min.73de4254959530e4d1d9bec586379184f96b4953dacf9cd5e5e2bdd7bfeceef7.js integrity="sha256-c95CVJWVMOTR2b7FhjeRhPlrSVPaz5zV5eK917/s7vc="></script>
<script src=https://infobeamer.montage2.de/js/preact/preact.min.0c204e20934f1e09cfe86fbcf1d069d842f988fc71efe3a923021c08892c71c8.js integrity="sha256-DCBOIJNPHgnP6G+88dBp2EL5iPxx7+OpIwIcCIksccg="></script> <script src=https://infobeamer.montage2.de/js/preact/preact.min.0c204e20934f1e09cfe86fbcf1d069d842f988fc71efe3a923021c08892c71c8.js integrity="sha256-DCBOIJNPHgnP6G+88dBp2EL5iPxx7+OpIwIcCIksccg="></script>
<script src=https://infobeamer.montage2.de/js/htm/htm.80e39afe20fd61183412eda89efa10532d57945e6364642aceacd50eb2384b4b.js integrity="sha256-gOOa/iD9YRg0Eu2onvoQUy1XlF5jZGQqzqzVDrI4S0s="></script> <script src=https://infobeamer.montage2.de/js/htm/htm.80e39afe20fd61183412eda89efa10532d57945e6364642aceacd50eb2384b4b.js integrity="sha256-gOOa/iD9YRg0Eu2onvoQUy1XlF5jZGQqzqzVDrI4S0s="></script>
<script src=https://infobeamer.montage2.de/main.ec4847eb1a7e9db3e0ba4d4ccd76aec3fd6761cf9309df4a74f2216e541cbed6.js integrity="sha256-7EhH6xp+nbPguk1MzXauw/1nYc+TCd9KdPIhblQcvtY=" type=module></script> <script src=https://infobeamer.montage2.de/main.6088a37a89f70987a1a9e5ae8a30b5f78523fa343161b81b945288bae18d92fd.js integrity="sha256-YIijeon3CYehqeWuijC194Uj+jQxYbgblFKIuuGNkv0=" type=module></script>
</body> </body>
</html> </html>

View File

@ -13,6 +13,6 @@
<script src=https://infobeamer.montage2.de/js/moment/moment.min.73de4254959530e4d1d9bec586379184f96b4953dacf9cd5e5e2bdd7bfeceef7.js integrity="sha256-c95CVJWVMOTR2b7FhjeRhPlrSVPaz5zV5eK917/s7vc="></script> <script src=https://infobeamer.montage2.de/js/moment/moment.min.73de4254959530e4d1d9bec586379184f96b4953dacf9cd5e5e2bdd7bfeceef7.js integrity="sha256-c95CVJWVMOTR2b7FhjeRhPlrSVPaz5zV5eK917/s7vc="></script>
<script src=https://infobeamer.montage2.de/js/preact/preact.min.0c204e20934f1e09cfe86fbcf1d069d842f988fc71efe3a923021c08892c71c8.js integrity="sha256-DCBOIJNPHgnP6G+88dBp2EL5iPxx7+OpIwIcCIksccg="></script> <script src=https://infobeamer.montage2.de/js/preact/preact.min.0c204e20934f1e09cfe86fbcf1d069d842f988fc71efe3a923021c08892c71c8.js integrity="sha256-DCBOIJNPHgnP6G+88dBp2EL5iPxx7+OpIwIcCIksccg="></script>
<script src=https://infobeamer.montage2.de/js/htm/htm.80e39afe20fd61183412eda89efa10532d57945e6364642aceacd50eb2384b4b.js integrity="sha256-gOOa/iD9YRg0Eu2onvoQUy1XlF5jZGQqzqzVDrI4S0s="></script> <script src=https://infobeamer.montage2.de/js/htm/htm.80e39afe20fd61183412eda89efa10532d57945e6364642aceacd50eb2384b4b.js integrity="sha256-gOOa/iD9YRg0Eu2onvoQUy1XlF5jZGQqzqzVDrI4S0s="></script>
<script src=https://infobeamer.montage2.de/main.ec4847eb1a7e9db3e0ba4d4ccd76aec3fd6761cf9309df4a74f2216e541cbed6.js integrity="sha256-7EhH6xp+nbPguk1MzXauw/1nYc+TCd9KdPIhblQcvtY=" type=module></script> <script src=https://infobeamer.montage2.de/main.6088a37a89f70987a1a9e5ae8a30b5f78523fa343161b81b945288bae18d92fd.js integrity="sha256-YIijeon3CYehqeWuijC194Uj+jQxYbgblFKIuuGNkv0=" type=module></script>
</body> </body>
</html> </html>