experimental hummus compat + random things

pull/1/head
Drake 2 years ago
parent a3272cfa7c
commit 2b884b7642

2
dist/build.js vendored

File diff suppressed because one or more lines are too long

@ -6,14 +6,12 @@ import * as nestsReact from "nests/react"
const { findByProps } = webpack
const React = findByProps(
"__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED",
"createElement"
)
export default {
React,
ReactDOM: findByProps(
"__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED",
"hydrate"
),
dispatch: findByProps("dirtyDispatch").__proto__,

@ -19,7 +19,7 @@ export default (props) => {
return null //you wouldn't think i'd have to do this but
}
return (<>
<Card type="cardPrimary" outline={false} editable={false}>
<Card type="cardPrimary" className="demon-settings-card-base" outline={false} editable={false}>
<Header className="demon-settings-card-header" size={Header.Sizes.SIZE_20}>
{props.name}
</Header>

@ -19,6 +19,9 @@ function init() {
"height": "1px",
"border": "thin solid var(--background-modifier-accent)"
})
css.createClass("demon-settings-card-base", {
"margin-button": "10px"
})
css.createClass("demon-settings-card-header", {
"margin-left": "10px",
"margin-top": "10px"
@ -48,22 +51,24 @@ function init() {
"font-size": "30px",
"line-height": "34px"
})
after("getPredicateSections", SettingsView.prototype, (args, sections) => {
sections.unshift(
{
section: "HEADER",
label: "Demoncord"
},
{
section: "demoncord",
label: "Plugins",
element: plugins
},
{
section: "DIVIDER"
if (!!window.webpackChunkdiscord_app) {
after("getPredicateSections", SettingsView.prototype, (args, sections) => {
sections.unshift(
{
section: "HEADER",
label: "Demoncord"
},
{
section: "demoncord",
label: "Plugins",
element: plugins
},
{
section: "DIVIDER"
})
return sections;
})
return sections;
})
}
}
export default { init }

@ -1,13 +1,18 @@
function getModules() {
let modules = {};
window.webpackChunkdiscord_app.push([
[Math.random().toString(36)],
{},
(e) => {
modules = e;
}
]);
if (!window.webpackChunkdiscord_app) {
//funny hummus compat (maybe)
modules = webpackJsonp([ ], [ (mod, _exports, req) => { mod.exports = req; } ]);
} else {
window.webpackChunkdiscord_app.push([
[Math.random().toString(36)],
{},
(e) => {
modules = e;
}
]);
}
return modules.c;
}

@ -7,7 +7,7 @@ import css from "./api/css.js"
import patcher from "./api/patcher"
if (!window.DiscordNative) {
throw new Error("Sorry, Demoncord cannot be used on web!")
//throw new Error("Sorry, Demoncord cannot be used on web!")
}
const demon = {

@ -3,7 +3,6 @@
import webpack from "./api/webpack"
const React = webpack.findByProps(
"__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED",
"createElement"
)

Loading…
Cancel
Save