fore.st - Panama Red (v1)

changelist:
-pseudo-random name colors
-layout fixes(moved chat after the video on the .pug. also disabled said
feature in fcyp.js)
-theme updates(tokebot flair, changed modflair, more compact layout,
unfucked cytube provided css (srsly, WTF calzoneman? Why?)
link decorations, made things moar unified)
-added image embedding, disabling fcyp image embed (nothing new from a
user standpoint, simply slowly stripping fcyp.js out)
-moved emote button to chatbar, added send button as well
-chatpaste & chatsmack functions allowing clickable usernames/
-fixed raw video controls
-ripped out chat processing logic from fcyp.js, it was breaking a lot of
shit and everything it did has been implemented by this update and moar

devnotes:
Biggest update yet, also made some good steps towards fully ripping
fcyp.js out completely. Played around with an image upload button. I
might have to setup a cors relay to get that working, I'll have to play
around more :p
This commit is contained in:
rainbownapkin 2022-02-03 02:27:31 +00:00
parent 1148f63959
commit 9455fd8964
16 changed files with 5744 additions and 198 deletions

View file

@ -68,7 +68,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
// If you need more explanations, go to https://github.com/zimny-lech/CyTube-Plus/wiki/FAQ
UI_DefaultSynchtube = 1; // default old Synchtube layout (player and playlist on the left)
UI_DefaultSynchtube = 0; // default old Synchtube layout (player and playlist on the left)
UI_Favicon = 0; // [&] channel favicon
UI_MiniLogo = 0; // [&] small channel logo/avatar in the top navbar
UI_ChannelName =0; // [&] channel custom brand name
@ -92,7 +92,7 @@ UI_UserCommands = 1; // [&] additional commands in the chat window
UI_UserMarks = 0; // [&] special signs/avatars before every message for defined users
UI_Squavatars = 0; // automatic squavatars (2-colored square avatars) before every message
// [ REQUIRE: UI_UserMarks enabled ]
UI_UsernameMark = 1; // [&] custom mark after username (default ":")
UI_UsernameMark = 0; // [&] custom mark after username (default ":")
UI_MessagesSuffix = 0; // [&] text added to random chat messages
UI_CustomPingSound = 1; // [&] custom sound for chat notifications
UI_SoundFilters = 0; // [&] chat sounds played after sending certain words
@ -115,7 +115,7 @@ UI_ChannelDatabase = 1; // [&] box with embed additional media database
UI_ChannelGalleries = 0; // [&] box with embed galleries
UI_DisplayModeSel = 1; // selector with player display modes
UI_ChannelTheme = 1; // [&] additional default channel theme
UI_EmbeddingMedia = 1; // [&] possibility to embedding (displaying) images and .webm videos on the chat
UI_EmbeddingMedia = 0; // [&] possibility to embedding (displaying) images and .webm videos on the chat
UI_MediaControls = 1; // embedded video preloaded controls
// [ REQUIRE: UI_EmbeddingMedia enabled ]
UI_QuickCommandsBtns = 1; // buttons with '/clear' and '/afk' functions
@ -651,16 +651,16 @@ function customCSS(a) {
// set global layout according to user preferences
function setLayout() {
playerLocation(USERCONFIG.player);
userlistLocation(USERCONFIG.userlist);
queueLocation(USERCONFIG.queue);
queueSize(USERCONFIG.qsize);
mainLocation(USERCONFIG.main);
motdLocation(USERCONFIG.motd);
logoInsert(USERCONFIG.logo);
headerMode(USERCONFIG.header);
customCSS(USERCONFIG.css);
refreshPlayer();
// playerLocation(USERCONFIG.player);
// userlistLocation(USERCONFIG.userlist);
// queueLocation(USERCONFIG.queue);
// queueSize(USERCONFIG.qsize);
// mainLocation(USERCONFIG.main);
// motdLocation(USERCONFIG.motd);
// logoInsert(USERCONFIG.logo);
// headerMode(USERCONFIG.header);
// customCSS(USERCONFIG.css);
// refreshPlayer();
}
//-----STOP BREAKIN SHIT!
@ -929,7 +929,7 @@ function createSquavatar(str) {
// format chat messages before sending and execute commands
function prepareMessage(msg) {
if (UI_MessagesSuffix=="1") {
/*if (UI_MessagesSuffix=="1") {
if ((typeof MessagesSuffix_Percentage!=="number") || MessagesSuffix_Percentage<0) {
MessagesSuffix_Percentage='10';
}
@ -1085,7 +1085,7 @@ function prepareMessage(msg) {
} else {
COMMAND=false;
}
}
}*/
return msg;
}
@ -2292,7 +2292,7 @@ zerorow = $('<div id="zerorow" class="row" />').insertBefore("#motdrow");
// adding top logo row
azukirow = $('<div id="azukirow" class="row" />').insertBefore(zerorow);
//azukirow = $('<div id="azukirow" class="row" />').insertBefore(zerorow);
// adding video wrap if user has enabled "Hide Player" option
@ -2347,7 +2347,7 @@ $("#rightpane").prepend($("#videocontrols").detach());
$("#rightpane").prepend($("#plcontrol").detach());
$("#leftpane").prepend($("#newpollbtn").detach());
$("#plcontrol").prepend($("#showmediaurl").detach());
$("#leftpane").prepend($("#emotelistbtn").detach());
//$("#leftpane").prepend($("#emotelistbtn").detach());
// header and footer links open in a new tab
@ -3342,16 +3342,16 @@ if (UI_UserStatistics=="1") {
// alter chat messages formatting
// DEV NOTE: this is extended function from CyTube "util.js" file
if (ALTERCHATFORMAT) {
/*if (ALTERCHATFORMAT) {
function formatChatMessage(data, last) {
if (!data.meta || data.msgclass) {
data.meta = {addClass:data.msgclass, addClassToNameAndTimestamp:data.msgclass};
}
skip=data.username===last.name;
data.meta.addClass==="server-whisper" ? skip=true : '';
data.msg.match(/^\s*<strong>\w+\s*:\s*<\/strong>\s*/) ? skip=false : '';
data.meta.forceShowName ? skip=false : '';
data.meta.addClass==="server-whisper" ? skip=true : '';*/
//*data.msg.match(/^\s*<strong>\w+\s*:\s*<\/strong>\s*/) ? skip=false : '';/*
/*data.meta.forceShowName ? skip=false : '';
data.msg=execEmotes(data.msg);
last.name = data.username;
@ -3473,7 +3473,7 @@ if (ALTERCHATFORMAT) {
return div;
}
}
}*/
// client-side chat buffer for playing sounds
@ -3507,7 +3507,7 @@ addChatMessage=function(data) {
// fix formatting and sending chat messages
// DEV NOTE: this are extended events from CyTube "util.js" file
/*
$("#chatline, #chatbtn").unbind();
$("#chatline").on("keydown", function(ev) {
@ -3580,7 +3580,7 @@ $("#chatbtn").on("click", function() {
$("#chatline").val('');
}
});
*/
// fix layout behaviour after resizing
// DEV NOTE: this is extended function from CyTube "util.js" file
//