2024-12-18 15:18:02 -08:00
|
|
|
/*jshint esversion: 6 */
|
2024-11-14 20:59:43 -08:00
|
|
|
// ==UserScript==
|
|
|
|
// @name Builded
|
|
|
|
// @namespace https://git.swee.codes/swee/Builded
|
2025-01-04 20:06:16 -08:00
|
|
|
// @version 0.1
|
2024-11-14 20:59:43 -08:00
|
|
|
// @description Vencord, but for Guilded
|
|
|
|
// @author Swee
|
2024-11-29 16:13:06 -08:00
|
|
|
// @match https://*.guilded.gg/*
|
2024-11-16 13:53:41 -08:00
|
|
|
// @match https://builded.swee.codes/settings
|
2024-11-14 21:02:25 -08:00
|
|
|
// @icon https://git.swee.codes/swee/Builded/raw/branch/main/Builded-solid.svg
|
2024-11-14 22:00:49 -08:00
|
|
|
// @grant GM_setValue
|
|
|
|
// @grant GM_getValue
|
2025-01-03 22:25:33 -08:00
|
|
|
// @require https://code.jquery.com/jquery-3.7.1.min.js
|
2025-01-03 22:35:07 -08:00
|
|
|
// @require https://github.com/pie6k/jquery.initialize/raw/refs/heads/master/jquery.initialize.min.js
|
2025-01-04 20:06:16 -08:00
|
|
|
// @run-at document-body
|
2025-01-03 22:24:52 -08:00
|
|
|
// ==/UserScript==
|
2025-01-03 22:54:39 -08:00
|
|
|
function waitForElm(selector) {
|
|
|
|
return new Promise(resolve => {
|
|
|
|
if (document.querySelector(selector)) {
|
|
|
|
return resolve(document.querySelector(selector));
|
|
|
|
}
|
2024-11-14 20:59:43 -08:00
|
|
|
|
2025-01-03 22:54:39 -08:00
|
|
|
const observer = new MutationObserver(mutations => {
|
|
|
|
if (document.querySelector(selector)) {
|
|
|
|
observer.disconnect();
|
|
|
|
resolve(document.querySelector(selector));
|
|
|
|
}
|
|
|
|
});
|
|
|
|
|
|
|
|
// If you get "parameter 1 is not of type 'Node'" error, see https://stackoverflow.com/a/77855838/492336
|
|
|
|
observer.observe(document.body, {
|
|
|
|
childList: true,
|
|
|
|
subtree: true
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
2025-01-04 20:08:11 -08:00
|
|
|
(async () => {
|
2024-12-18 15:19:43 -08:00
|
|
|
let settings_HTML = `
|
2025-01-03 23:34:13 -08:00
|
|
|
<p>There are no features here... Want to suggest some <a target="_blank" class=link onclick="window.close()" href="https://discuss.swee.codes/c/10">here?</a> :3</p>
|
2024-12-18 15:19:43 -08:00
|
|
|
`;
|
2025-01-04 20:06:16 -08:00
|
|
|
|
2025-01-04 20:07:31 -08:00
|
|
|
let customloader = await GM.getValue("customLoader", `
|
2025-01-04 20:27:00 -08:00
|
|
|
<img height="90px" src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAQAAAAEACAYAAABccqhmAAAACXBIWXMAAE69AABOvQFzamgUAAAAGXRFWHRTb2Z0d2FyZQB3d3cuaW5rc2NhcGUub3Jnm+48GgAAAFV0RVh0Q29weXJpZ2h0AENDIEF0dHJpYnV0aW9uLU5vbkNvbW1lcmNpYWwgaHR0cDovL2NyZWF0aXZlY29tbW9ucy5vcmcvbGljZW5zZXMvYnktbmMvNC4wL3xlHo0AABJYSURBVHic7d19kF11fcfx9/fuEkASBDrQB5FKKw9aLTDMIAhm7yYhNC2jrRWKVqStY7XtVDpKpbZToNMqgqBCKQU6yBRsUSMtCAMak92bkIioiAJFwlPKgxCTAHl+2s399o/dpRFisnvO79zf73fO5zWT2U2y53c+M3fv5zzcc37H3B0RaaZW7AAiEo8KQKTBVAAiDaYCEGkwFYBIg6kARBpMBSDSYCoAkQZTAYg0mApApMFUACINpgIQaTAVgEiDqQBEGkwFINJgKgCRBlMBiDSYCkCkwVQAIg3WHztAad+0g9iHi1/xrwfg2M9Z4gB4+f82AiNTWFsXY93Lf3M2A9vG/7YBGB3/fh1OlxYOrB1fcgfG+vHvt2NsGv/ZrXTZgrGNaWxmEeu40LtTyCRSmGU/KehCO4x+noodI7BtwGZgHbAV2ASsH/9+4/i/rwXW4ry00/dr6ecljLX0s5aTfEuc+JKL/PcA6mnv8T8H7vEn7RXfT+w77AA6thXjRZzVwPPjX9dg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bVTwGMJ5jrm0qs8YMllpXyZrPEDo8dYrJUAFWb6nlh48HC61pghwCnFV5eQ
|
2025-01-04 20:28:22 -08:00
|
|
|
<hr>Guilded load...
|
2025-01-04 20:06:16 -08:00
|
|
|
`)
|
2025-01-04 20:07:31 -08:00
|
|
|
let customloader_enable = await GM.getValue("customLoaderEnable", true)
|
2025-01-03 22:52:05 -08:00
|
|
|
let settings_entry = `
|
2025-01-03 23:30:35 -08:00
|
|
|
<div onclick="window.location = 'https://www.guilded.gg/explore/servers/overview';" class="DraggableHandle-container NavV4SelectorRow-container NavV4TeamSelectorBottomOptionsList-row">
|
|
|
|
<div class="NavV4SelectorRow-icon-container">
|
|
|
|
<div class="SVGIcon-container NavV4SelectorRow-svg-icon">
|
|
|
|
<svg class="icon SVGIcon-icon icon-globe" shape-rendering="geometricPrecision" role="img">
|
|
|
|
<use xml:space="http://www.w3.org/1999/xlink" xlink:href="#icon-globe"></use>
|
|
|
|
</svg>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="NavV4SelectorRow-row-content">
|
|
|
|
<div class="NavV4TeamSelectorBottomOptionsList-label">
|
|
|
|
Discover
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div onclick="window.location = 'https://www.guilded.gg/chat';" class="DraggableHandle-container NavV4SelectorRow-container NavV4TeamSelectorBottomOptionsList-row NavV4TeamSelectorBottomOptionsList-dms">
|
|
|
|
<div class="NavV4SelectorRow-icon-container">
|
|
|
|
<div class="SVGIcon-container NavV4SelectorRow-svg-icon">
|
|
|
|
<svg class="icon SVGIcon-icon icon-dm" shape-rendering="geometricPrecision" role="img">
|
|
|
|
<use xml:space="http://www.w3.org/1999/xlink" xlink:href="#icon-dm">
|
|
|
|
</use>
|
|
|
|
</svg>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="NavV4SelectorRow-row-content">
|
|
|
|
<div class="NavV4TeamSelectorBottomOptionsList-label">
|
|
|
|
Direct messages
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
2025-01-03 23:19:56 -08:00
|
|
|
<div onclick='window.open("https://builded.swee.codes/settings", "ree", "titlebar=yes,menubar=no,height=500px,width=300px,menubar=no,status=no");' class="DraggableHandle-container NavV4SelectorRow-container NavV4TeamSelectorBottomOptionsList-row">
|
|
|
|
<div class="NavV4SelectorRow-icon-container">
|
|
|
|
<div class="SVGIcon-container NavV4SelectorRow-svg-icon">
|
|
|
|
<img src="https://git.swee.codes/swee/Builded/raw/branch/main/Builded-solid.svg" height="32">
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="NavV4SelectorRow-row-content">
|
|
|
|
<div class="NavV4TeamSelectorBottomOptionsList-label">
|
|
|
|
Builded settings
|
|
|
|
</div>
|
|
|
|
</div>
|
2025-01-03 22:52:05 -08:00
|
|
|
</div>
|
|
|
|
`
|
2024-12-18 15:19:43 -08:00
|
|
|
if (location.host == "www.guilded.gg") {
|
|
|
|
console.info("Guilded.GG detected.");
|
2025-01-03 23:23:22 -08:00
|
|
|
$.initialize('.NavV4TeamSelectorBottomOptionsList-container', function() {
|
2025-01-03 23:19:56 -08:00
|
|
|
console.info("Injecting settings entry...")
|
2025-01-03 23:30:35 -08:00
|
|
|
$(this)[0].innerHTML = settings_entry;
|
2025-01-03 22:39:59 -08:00
|
|
|
});
|
2025-01-04 20:06:16 -08:00
|
|
|
$.initialize('#loading', function() {
|
|
|
|
$(this)[0].innerHTML = customloader;
|
|
|
|
});
|
2024-12-18 15:19:43 -08:00
|
|
|
} else {
|
|
|
|
document.body.innerHTML += settings_HTML;
|
|
|
|
}
|
|
|
|
console.info("Builded Loaded <3");
|
2025-01-04 20:08:11 -08:00
|
|
|
})();
|