#π§©-plugin-development
1 messages Β· Page 87 of 1
Didn't saw your message π
I've updated about an hour ago
you get a stopwatch and time yours too
@dapper salmon so basically Goodperson intercepts message create events and message update events, scans for bad words, replaces them with good words and fires a message update event with the new content (and a suffix so you donβt end up in a loop of message updates)
Is the message in async MESSAGE_CREATE ({ guildId, message }) the same message type thats in onBeforeMessageSend and whatnot?
Does it have the same fields and information
no since the MESSAGE_CREATE is a full message and the onBefore message is a pre-send
just look at how i use it

I made a plugin to replace some users messages with meowing
Can I post into js snippets
agony
f
why they naming a store f though fr
If you ever accidentally created a store named f, it will be persisted or something like that
wdym?
I forget exactly but I have some stores with random names from when I was just playing around
that's a builtin store
one of discord's
that's actually used by the client on the activity tab on profiles
Oh π I guess I was thinking of something else
well it's only used for a marvel rivals special widget at the moment
but it seems wuvering waves support is incoming
based on an enum of only those 2 games
sometimes they forget to add name to stores so it becomes a one letter name
alternative to Forms.FormSection?
nothing
well alright
@pure temple any news regarding this? I just got through my midterms as well, I could dedicate some time to help out
oh yeah i've been working on it
ok so i figured out how discord handles time formats and it's
super scuffed but figured out
omg 
oh those steps refer to my own
try out the newest version of the plugin, it's rather different
does it also include timestamps near usernames?
nah, i was thinking about it but it might be out of scope for the plugin? but im kinda bored and have nothing to do this morning so might as well right
mine shows the current date of the other user
why would it be out of scope? the pronouns plugin does the same, just takes it off the profile and shows it directly
so you have instant feedback
obviously this should be an optional feature
imo
TimezoneOnProfile was my thought so it's just on profile, but im absolutely downf or expansion
i think alll id' have to do is make my inline render patched into the messages
i think this feature is great
do you have code that makes that happen?
if not then i can make it
yeah well, the problem is getting it compatible with the pronouns plugin
but yes mine already does it
that was the original goal for me anyway
it doesn't show it on the profile at all
perfect, show me the code
zamn
sorry it's like 0750 and i've already cleaned the house for like two hours im kinda cooked
need breakfast
oh yeah nws, I'm just omw home rn as well
I just saw the new comments on the PR and thought I'd try and catch up on things
the main issue for me was always proper compatibility, since the pronouns plugin patched a single jsx return into an array and injects itself
thus I have to count for both the unpatched and already patched version, and there isn't really a better way positioning wise to patch afaik either
and I doubt two patches where one will always get ignored would be the way to go, I should probably improve the single patch itself but I haven't really had the time
yeah no worries, just let me know
I'm hella curious
I unfortunately barely have enough time with school and work on top
but I should have more free time this month
uni has JUST started for me so i still have the time before calc 2, calc physics, discrete math, and my two other engineering classes academically molest me
lmao π₯
anyway overall I also implemented listeners back when I made it, just so it could easily update the timezone changes when the user does update them
oh and instead of having the select on the profile it comes up in the right click user menu
i think i forgot to make the plugin re-render itself when you select a timezone so you don't have to refresh
mhm, mine includes that
the menu also uses built in components
so no issues there with css either
since it doesn't use any really
directly
anyway, lmk if you can figure out the patch, I could write a merge with your plugin after that you could look through
that should be easier
y eah alright
but up to you really 
im gonna quickly make this patch then i'll decide on merge stuff
i will say that the method that i calculate the timezone math is like, 10x more disgusting now
update() went from a 3 line to like 25 line method
@eager egret so how does this look?
i tried to make it be before the pronouns plugin but that was kind of a headache that i'll get to later
but otherwise i think it looks nice there?
wait i just realized something should we make it their relative time NOW? or the relative time of the message?


with a single patch?

oh I replied to the wrong message
π
their current relative time yes

i love seeing my time twice
why can you even set it for yourself π
(so can I in mine but that's besides the point)
that's a great question
do you need help with anything or is my fork already enough additional info?

should be a quick fix
unfortunately the boys are really intent on inticing me with some mahjong rn
just let me help dude π
aight fine
can you figure out how to just not have it appear for myself, TZ on your own profile and otherwise?
mhm 
thanks king
could you perhaps slide the patch?
wouldn't it be easier to just disable the set option entirely for self?
it should be pretty simple to get the user id there anyway
{
find: "showCommunicationDisabledStyles",
replacement: {
match: /(?<=\i.*&&.*!.*\i\.*&&.*)(:\i,application:\i}\))/,
replace: "$1,$self.TimezoneTriggerInline(arguments[0])"
}
}
here king

might just be me but I genuinely don't see an option to even set the timezones after building your PR
click on where it says TZ
css isbroken again?

strange, on mine it's fine
I feel like you could literally just transition to my implementation entirely
it uses built in components directly
try it, if it's good hten im all for it
i like this
could be added to the profile as well if needed
it's only on the right click menu currently
try it see how it feels
bet
why not just a dropdown where you can seach lol
I mean a searchbar is definitely doable

mhm
on it 
it's beautiful
don't context menus support a search bar at the top. I swear I saw a plugin with it. or was it a custom component π€
I could only find the built in SearchableSelect from webpack
lmk if there's anything better-

haven't touched messages yet though 
I'll try and figure out something a bit more pleasing UI wise
btw, how come PRs nowadays are opened into main directly?
searchable select is fine tbh as long as the normalization logic on the searched terms and the compared timezones is good
commit message for better context:
feat: Refactor UI to use ContextMenus and Modals
Replaces inconsistent CSS styling with standard components. Separates the plugin into multiple files for improved readability. Add plugin option to show current user-specific time next to messages for better UX.
people dont know that other branches exist ig
shrug
lmao istg I remember PRs getting rejected instantly back then for this, although I might be confusing it with another project 

anyway
they do
look at BetterSettings/VencordToolbox
vencord plugin that lets you do this
you don't need a mod for that do u
no but still
oh i did it with a manual http request I remember
we could definitely do this, I'd probably prefer it over a unified search select myself, not sure what y'all think?
seems more organized to me overall
and a lot more appealing
I don't think using a context menu for this would make sense

what's wrong with a select?
just don't sort it alphabetically that's atrocious
put the GMT offset at the start and sort it by offset
sort it by offset then by alphabet

the primary GMT group is sorted by the offset already, the other timezones following that are based on the Intl.supportedValuesOf() order
i dont think you need to add the manual offsets
I didn't really modify much of the functionality that Hazrtine did 
I was wondering about that as well tbf lmao 
but wanted to discuss it first with him among some other additions

since I'm not sure of the exact reason these were added anyway
what he meant was sort by the GMT+ offset
and if the offset is same sort alphabetically
fair enough, I kinda misunderstood mb
do it like this
it's easier to find your timezone without search that way
I think to a lot of people timezone isn't that intuitive
the plugin should definitely detect and display your own timezone so you can just tell it other people
add like
Your time zone: Europe/Berlin to the settings page
gotcha
@eager egret pls send me a friend req i can't send you one
Anyone know why it's showing unexpected token?
{
find: "zoomedMediaModalHelper",
replacement: {
match: /(function \i\((\i),(\i),(\i)\){)(let \i\=\i.length)/,
replace: "$1$self.propogateImages($2,$3,$4);$5"
}
}```
probably its not updated to handle arrow function modules
just change this for now ig
i was lazy to actually try this
Hey! wanted to retry plugins after a little while. But even if i pnpm dev'd i can't have the react devtool
so i used the native html and found the "onclick" function define that seems to be empty..
what i'm trying to do is unfollowing all threads from a post with one button.
I found a req in the network tab but it includes weird ass arguments and the token is needed, then i tried searching in FluxDispatcher but when i manually dispatch two related events it just doesn't work, leading me to searching the button itself but yeah doesn't seem to be working.. (Where can i see all the stores btw? maybe one is related)
-# ping on reply please, and if you want to know what flux event i used + the fetch req lmk
Press ctrl-R to restart, react devtools dont immediately load the first time
As for the stores, you can see them if you enable the experiments plugin, then go to the developer options tab in settings, and enable devtools, then hit ctrl-alt-O to open the discord devtools (different from electron devtools). There you can find a stores tab containing all stores.
Good to know for the stores, but i restarted discord multiple times and never saw react things
Do you have them enabled in vencord settings? I can't remember whether they're disabled by default ngl
is there something i need to enable to use chrome dev tools ctrl shift i doesnt do anything (im using vesktop on mac)
im pretty sure i need to add "DANGEROUS_ENABLE_DEVTOOLS_ONLY_ENABLE_IF_YOU_KNOW_WHAT_YOU'RE_DOING": true to the settings.json but i actually cannot for the life of me find it π
its not a thing in vesktop
it just works
if it doesnt work youre probably pressing the wrong key combo
its command shift i right
devtoolsFixes.ts: Lines 11-18
// Discord Web blocks the devtools keybin on mac specifically, disable that
{
find: '"mod+alt+i"',
replacement: {
match: /"discord\.com"===location\.host/,
replace: "false"
}
},
did this break
vai what do I press for this on mac: mod+alt+i
On a Mac, mod+alt+i generally translates to Command (β) + Option (β₯) + I.
If you're trying to open Discord's Developer Tools, you might also find that Control (β) + Shift (β§) + I works. Some users have noted this as the functional shortcut on macOS for Discord's DevTools, even though Command (β) + Option (β₯) + I is the more standard Mac equivalent for many applications.
-# Response generated by gemini-2.5-flash. AI may be incorrect or misleading.
yeah i already tried ctrl
well idk
ig ill try reinstalling
How does Discord handle webp? Thinking of making usrbg banners all encoded in webp, does Discord have any issues displaying them over something like png or jpg? (embedded as an image in someones profile)
I think discord makes their native banners you upload webp anyway
Oh nvm that was just ViewIcons but I replaced the url with webp and it still rendered perfectly fine
does changing the url actually change it? I was under the impression it changes the headers but still sends the same image (Discord handles image types very poorly, relies on extension and never checks file headers)
but mostly just wondering if the rendering + display is on-par with jpg, png, gif, etc. And also how it does with animated webp
Discord makes everything you upload webp
Webp supports animation and on discord that's used via ?animated=true query paramater for webp assets
most assets are available as png, jpg, and webp regardless of their source format
if you have an animated webp and dont provied the query param does it provide a static version?
on the cdn you get different assets with ?format=<png/jpeg/webp> but on media proxy you get it by changing the extension in the url .<png/jpg/webp
on the media proxy you get different assets with ?format=<png/jpeg/webp> but on cdn you get it by changing the extension in the url .<png/jpg/webp
yes
for apng the parameter is ?passthrough=true and false
the media proxy?
ah gotcha
Discord's API is based around two core layers, a HTTPS/REST API for general operations, and persistent secure WebSocket based connection for sending and subscribing to real-time events. The most commo...
other way round
i need to doc media proxy there tbh
I did find a weird thing with emojis recently
if you upload an emoji as AWEBP or AVIF they arent converted to gif
but there's no way to know that
they still have the usual a_ hash prefix
but no signifier they are non-gif animated emojis
unlike gif emojis which are converted to awebp 
had to map this out for my plugin
yup
it is docced pretty sure
this is cursed but also I have to do a similar thing
couldnt find it when i checked but dont remember how hard I checked
not that cursed
comparatively maybe not
interesting autofix
Windows moment
do i have to reinject in order to update the CSP rules? they dont seem to be changing at all on restart
happy late 1 year anniversary to this
yep full restart, but it doesnt seem to be changing
if i understand correctly then i just need to add the domain here in src/main/csp/index.ts right?
oh whoops i think the cors is on my side lol
yeah it was
how joyous
iframe horror
i could very easily use my own custom embeds since i already have the logic written for that
but im more worried about audio preview CORS
Hop off microslop
They're applied in native, you need a full restart
hi, how can i edit the dom using patches ?
like i have a mutation observer on start listening on document
document.querySelectorAll<HTMLImageElement>(paths.img_badge).forEach(img => {
if (img.src.includes(oldBadge)) {
img.src = img.src.replaceAll(oldBadge, newBadge);
}
});
and is there a guide to making patches please
dom manip kinda goated
Typing for SearchableSelect shows that it takes:
className?: string;
popoutClassName?: string;
wrapperClassName?: string;
optionClassName?: string;
however I could only get className and wrapperClassName working. Had to patch the other 2 in. Am I missing something or is this just typed wrong?
oh agony, on top of that there's an expiriment for this that breaks my code π
dev://experiment/2025-09-mana-desktop-select
new mana select isnt getting all the props passed to the searchable select. agony
What's the mana select?
mana is discord's name for their new components
it's just an entire replacement of the component
but it has some different props
and isnt accepting some of the old props
cant set a classname on it ,-,
hiya, what's the best way to quickly reload discord during development?
for some reason when i reload through vencord settings it keeps logging me out
and reload() in console is inconsistent ;-;
ctrl+r
oh my ty
might help
^ this and F5 with devtools open
plugins i use in my dev env, maybe i miss smh
like devcompanion can be useful
very useful yes
I dont use it π
insane
you have push perms tho dont you. you can just run reporter whenever you want on branch dev10
yes but I obviously test the patches before I push
thats why companion so goated. it shows whether the patch even applied or not lol
it never works for me
companion?
all you can really do is LSP's iirc
whatever, its rare when i use devcompanion
did satan himself really say that
idk
i have something cooler 
real slopper in discord
its like that for a while
i did it that way at the beginning for some reason, and i havent touched it since
π§
Jnder Construction
Yes
I have no reason to make an LSP version rn tho
The vscode apis make it 10x easier to write and debug
And I use vscode
^ ok yes turns out audio is affected by CORS as well (unsurprisingly)
so im in a bit of a corner, either i could add the audio preview URLs to csp.ts (which im not sure Vee would accept), or I could add a media proxy to my songspotlight API (which im not sure my cloudflare limits would like very much)
Is there something I need to do for my PR to get it looked at? If there is something wrong with it I can fix it I just haven't gotten any feedback on it.
TLDR:
This should fix the "Error 15" in youtube embeds related to youtube identity verification. This also adds detection and workaround for the Youtube "you look like a ...
has anyone successfully managed to add a tab to the expression picker? im making a plugin that has a button in the chat bar but would like to integrate with the picker and i'm not super familiar with patching
currently just using a popout with a card component
for some reason, the exact same fetch request in my plugin's native.ts and in a normal nodejs file doesnt produce the same result, the plugin helper somehow fails the captcha while the nodejs script doesnt
im pretty sure i dont even need to spoof the user agent but im just throwing everything at the wall and seeing what sticks rn
checking httpbin it really is the exact same so im confused
ok so as it turns out its some nodejs TLS client hello handshake bullshittery blah blah so i wrote a fetch() wrapper around electron's net.request and now it works
why do you have minecraft color codes in javascript lmao
So I'm making a plugin that uses this patch
β¨β¨```js
{
find: "0===i&&n&&!r&&(i=-1)",
replacement: {
match: /0===i&&n&&!r&&(i=-1)/,
replace: "i=Vencord.Plugins.plugins.NotificationBadgeControl.logic(d.default.getTotalMentionCount(), u.dH([h.A, c.A]), d.default.hasAnyUnread(), p.A.getDisableUnreadBadge())",
},
}
But you know what's weird? It doesn't work on Vesktop, but it works on the stock client
Vesktop just uses the default behavior regardless of what the β¨β¨`logic`β©β© function returns... but what's weird is that the logs still show that my logic function is being called
β¨β¨```js
logic(mentions: number, other: number, hasUnread: boolean, disabled: boolean): number {
const checked = check();
if (debug) logger.log("Received badge number logic call", checked, mentions, other, hasUnread, disabled, settings.store);
if (!checked) return defaultNumber;
const custom = settings.store.customLogic;
// Later will return an integer
}
```β©β©
If anyone has any suggestions that'd be cool, I'll keep trying to figure this out... or not, depending on if I get bored lol
I've never done plugins before, so idk if my patch is actually terrible lol
- Finds shouldn't use variable names such as β¨β¨β¨β¨β¨β¨
iβ©β©β©β©β©β©, β¨β¨β¨β¨β¨β¨nβ©β©β©β©β©β©, β¨β¨β¨β¨β¨β¨rβ©β©β©β©β©β©, etc. They change frequently as Discord reobfuscates. Best to find a section of code which is unique without being interrupted by a variable name. - Matches shouldn't use variable names. Use β¨β¨β¨β¨β¨β¨
\iβ©β©β©β©β©β© in place to match any variable. For example, β¨β¨β¨β¨β¨β¨\i.\iβ©β©β©β©β© would match β¨β¨β¨β¨β¨β©w.jsrβ©β©β©β©β©. - Replaces shouldn't use variable names. Use capturing groups in the match β¨β¨
(\i)β©β© to capture variables and use them with β¨β¨$1β©β©, β¨β¨$2β©β©, etc (number by order captured). - Replaces shouldn't have spaces in them except occasional situations like a variable after a return (so β¨
return a.iβ© instead of β¨returna.iβ©).
Mmm okay thanks π
Also, you shouldn't use your match as your find if you're overwriting the match with the replace.
β¨getDisableUnreadBadge(),β© is a unique find for that location.
Oh cool thanks
I'll correct this one (and probably others I screwed up haha)
what even is this supposed to do
As for 3/4 of the arguments you're passing to β¨β¨logic()β©β©, you can just access the stores directly. You can check if Vencord already exports them (GuildReadStateStore, NotificationSettingsStore) and if not, use β¨β¨findByPropsLazyβ©β© (lazy is better in code to give it time to load) with some unique identifier such as in the picture.
Or I guess capture the existing calls is fine. More complex patch though.
β¨β¨```
(\i)=\i.default.getTotalMentionCount(),(\i)=[^]]{0,25}]),(\i)=\i.default.hasAnyUnread(),(\i)=\i.\i.getDisableUnreadBadge(),(\i)=\i+\i;
idk something like that
Sorry if this is dumb⦠how did you run that in the console?
I keep getting the not defined error
Iβve tried switching from βtopβ to others, idk if that does anything
ConsoleShortcuts plugin or Vencord.Webpack.Common(or .Util?).findByProps
nvm neither lol. β¨β¨Vencord.Webpack.find<...>β©β©
β¨```js
{
find: ".getDisableUnreadBadge(),",
replacement: {
match: /0===(\i)&&(\i)&&!(\i)&&(\i=-1)/,
replace: "$1=Vencord.Plugins.plugins.NotificationBadgeControl.logic($1)",
},
}
Hmm this works
Does it look decent? I think it looks good imho
so you meant to do β¨β¨i=V...logic(i)β©β©?
and not make use of β¨$2β© or β¨$3β©
β¨iβ© as in β¨$1β© resolved
I mean it works for some reason lol, I'll check that out tho
Also yeah I used the stores to get the rest of the data now
use β¨$selfβ© instead of β¨β¨Vencord.Plugins.plugins.NotificationBadgeControlβ©β©
oh yeah that too lol
Oh, neat
Ok did that
Yeah I know
I thought you were saying that β¨i=...logic(i)β© didn't make sense
i still dont really know what your function does so just checking if passing the value you're updating made sense to you lol
Oh lol ok
Well basically the entire plugin is to customize the app badge
Idk if it's been done before, ik there's a plugin to disable it
But mine patches the function that passes the status to the app badge function...thing and returns a different number, based on settings
So like that weird period that you might see is β¨-1β©, no app badge is β¨0β©, and greater than 0 actually shows the number
Anyways thanks guys, I have no idea why it's not working in Vesktop but it's def not cuz of the patch
does vesktop even support badges
I opened a pull request a year ago and I still haven't got a response yet πππ»
https://github.com/Vendicated/Vencord/pull/2765
give it a few more
yeah prs take a random time of from 1 to 900 days to get reviewed
just pray
how can I improve this finder? it works, but it's not really ideal lol β¨```tsx
{
find: "=57.75,",
replacement: {
match: /openUserProfileModal)(.{0,20}userId:(.*?),.{0,500},disabled:\i})})/,
replace: "$&,$self.renderProfileSongs({userId:$1})"
}
}
webpack module for reference
β¨#{intl::USER_PROFILE_VIEW_FULL_BIO}β© seems to work
awesome thx
if you let a computer run for long enough you'd eventually be able to unhash every single intl key
it really is only 27 characters
there are way too many collisions for even very short keys, you'd have to be able to somehow filter out the invalid results using a dictionary of real words or something
the hash stores 36 bits of entropy iirc (used to be 32 since they incorrectly duplicated some bits before)
ig alternative is generating keys based on known words like USER or PROFILE, but guessing new words would be a pain
also they sometimes misspell the keys π
does that use satan's intl list
not yet
if you just loop through every possible combination, ignoring combinations that start with _ or have two _ next to each other and give it like a year or something ur good to go
So it seems as though β¨NoSystemBadgeβ© specifies itself as only working on the stock Discord desktop client (not Vesktop and I'd assume not web). And I've noticed that with my plugin (which manipulates the system badge instead of outright disabling it), it works in the stock desktop client but not Vesktop. (I've not tested on web yet.) Vesktop almost just ignores my patches. Is there a reason for this? Does Vesktop just handle the system badge differently?
i managed to find some using a markov chain
Did you generate the chain based on whole words or individual characters?
whole words
and only order 1, cos anything above that woldnt be unique enough
I see, interesting
the main issue was hash collisions, but since the json file dc uses is sorted alphabetically, i could check if an identifier was in the expected location
Do you have the source code for that public anywhere
i can put it on gh later if u want
i was planning on refining it to enable searching for a specific key, but wasnt sure exactly how id go about it
Hmm ig it's quite likely that u find a hash match for one key, but some keys dont follow the pattern (some have a _ as the first character or are lowercase) so you would never find the original
yeah, i just removed them
(i think they have all been found)
ill check if theres any gaps around those ones later
did prism remove their vencord clanker repo π
i was checking how they did their intl lookup thing
i renamed it
did a full refactor and stuff
later ill reupload
btw I dont really get the alphabetical lookup thing
I assume the KEY_MAP values are the original keys (the same as in satan's file), but you also check whether hashing the keys would keep the order with the candidate key?
but like the hashes of two ordered keys don't neccesarily also have to be ordered?
also why not just directly compare the 64bit hash representation, that should be faster than comparing strings
was this also vibecoded
yeah, the essence of this project is that the ai develops itself, including its own tools
i should fix some stuff but im lazy
i love seeing how it sometimes overcomplicates a 10s problem as if it were related to quantum equations

in the end, i still have to fix the issues it generated 
this multi step modal looks so cool
finder so unused even vencord companion forgot it exists
what do i do when the module infact is lazy loaded
the patch works but it always complains
noWarn: true
ignore
guhh
use β¨DiscordNative.clipboard.readβ© or smh like this
oh yeah
Heyo. I want to open the gif menu from my code. I've tried to import β¨β¨import ExpressionPickerStore from "@webpack/common"β©β© and then do β¨β¨ExpressionPickerStore.openExpressionPicker("gif");β©β© however this doesnt work. It somehow sets the state to "open" so discord thinks it is opened (realized this when clicking the official gif button, that I need to click twice to open the menu, so propably it is "closing" the menu first time) but the menu doesnt really opens. Am I doing something wrong here or is the function broken?
Also tried to query the gif button to call click on it but its really hard as the only way Ive encountered would be to use the exact aria label which makes it language incompatible.
try this:
β¨```ts
const ComponentDispatch = findByPropsLazy("dispatchToLastSubscribed", "emitter");
ComponentDispatch.dispatch("OPEN_EXPRESSION_PICKER", { activeView: "gif" });
You can also just import ComponentDispatch from @webpack/common
hell yea that works, thank you very much π«Ά
well, thanks for the tip
damn it be that easy?
I was cooking tho
picker = findByCode("activeView", "activeViewType", "lastActiveView", "getState().activeView");
picker("gif", findByProps("NORMAL", "OVERLAY").NORMAL, SelectedChannelStore.getChannelId());
yea i was surprised as well, ive tried around for 1 hour now and nothing worked haha
I just reverse engineered the onClick of the emoji button
took a while to find findByProps("NORMAL", "OVERLAY").NORMAL though
lmao
I'll do you one better: β¨ComponentDispatch.dispatch("TOGGLE_GIF_PICKER")β©
I just searched for what ctrl+g did tbh
damn
well smart, ive completly forgot this short cut even exists haha
"emoji", ..., channelid
figuring out where a came from was annoying lol
you need a recent user action to be able to read clipboard
like a click
To ensure applications are unable to abuse APIs that can create a bad user experience when the behavior is not desired, some APIs can only be used when the user is in an "active interaction" state, meaning the user is currently interacting with the web page, or has interacted with the page at least once.
Browsers limit access to sensitive APIs l...
I'll assume that there's a reason and my plugin won't work on Vesktop
it's already a setting in vesktop
NotificationBadgeToggle.tsx: Lines 14-23
<VesktopSettingsSwitch
title="Notification Badge"
description="Show mention badge on the app icon"
value={settings.appBadge ?? true}
onChange={v => {
settings.appBadge = v;
if (v) setBadge();
else VesktopNative.app.setBadgeCount(0);
}}
/>
i could probably abuse the media proxy API lol wait
this will surely work
oh rip
guess not
hey i mean spotify previews work
since their urls are not that long
why you gotta do allat
you just need the urls for images dont you? cant you just use spotify's image url and let electron resolve the image
even discord itself doesnt use the media proxy for spotify covers it just uses spotify's cdn directly
β¨β¨https://i.scdn.co/image/<hash>β©β©
then there's also soundcloud album covers & apple music album covers (and also audio previews)
but wdym let electron resolve the image
like in native.ts?
alternative solution
you can't create object URLs in the native thread, that was the first thing i tried
but this also requires the thumbnail & all audio previews to be loaded otherwise the component wont render
ehh
i still think this is better than adding like 6 more domains to csp
just set the image element src is what I meant
ok nvm turns out its not that many domains
Ah cool
Is there a way to control it in a plugin, like call β¨VesktopNative.app.setBadgeCount(0);β© in a regular Vencord plugin?
You might want to check out the CSP for the spotimbed userplugih
It does a lot for things like this
It's somewhere buried in user plugins
what are u doing π
im CORSing it
if you're having issues with cors you're doing something wrong
cors doesn't apply to image tags
why are you fetching the images
that is csp not cors
no..
vai explain csp vs cors
CSP (Content Security Policy) and CORS (Cross-Origin Resource Sharing) are both security mechanisms that protect web applications, but they operate differently:
- CSP is a browser security mechanism that helps prevent attacks like Cross-Site Scripting (XSS) by allowing you to define which sources (domains, protocols, etc.) your website is permitted to load content (scripts, styles, images) from. The browser will only execute or render resources from these whitelisted sources.
- CORS is an HTTP-header based mechanism that allows a server to specify any origins (domain, scheme, or port) other than its own from which a browser should permit loading resources. It provides a controlled way to bypass the Same-Origin Policy, which normally restricts web pages from making requests to a different domain.
In short, CSP focuses on what content your website can load and execute, acting as an allowlist for client-side resources. CORS, conversely, focuses on who can access resources from your domain, enabling secure cross-origin data sharing between different web origins.
-# Response generated by gemini-2.5-flash. AI may be incorrect or misleading.
yea i didnt wanna add more domains to CSP so i did the image fetching instead but i think this is cleaner anyway
but i still needed to push the song parsing part to native because of CORS
Update: I got it to work
My plugin now works in vesktop so yay
@umbral canopy im sorry for rejecting it but don't get discouraged, you did a great job anyway π€
Thank u
for next time I suggest discussing ur idea here first to get early feedback!
Deleting that because the embeds didn't work...
Hello guys π I had a few ideas for plugins
Well, I call them ideas but I already made them lol
Just wanting feedback on them, it doesn't bother me if they don't get merged anyway
-
MessageCorrector: Auto-organizes messages based on their timestamp. Basically Discord normally just gets a message and adds it, it can lead to some inconsistencies (first screenshot). My plugin organizes them based on their timestamp, which is when Discord's server received them.
- How do I know it works? Because I'm torturing my eyes lol (second screenshot)
-
NotificationBadgeControl: I feel this one wouldn't get merged, but I'll share it anyway
Basically I got annoyed at Discord's (and Vesktop's) badge behavior, specifically the weird period or whatever that showed when you had unread messages (which is all the time for me). So I made this, which can make it so that the unread badge only shows when you want (always, never, or default), and you can also control a lot of other things (even adding your own JavaScript logic!). It even works with Vesktop (although for Vesktop, instead of patching it just call's Vesktop'ssetBadgeCountso it sometimes seems to fight with vesktop lol) -
MemberLeftBadge: Adds a badge next to members who are no longer in the current server (includes bots (can be changed) and deleted users). It'll also show a badge on threads/posts created by someone who's left, although it'll only show for the one you've selected (due to limitations with Discord). It's very helpful for if someone created a post asking for help then leaves an hour later
Fourth screenshot just didn't wanna show... I'll send it right here (it did wanna show it's just smal)
-# please ping me for replies I don't check this server often
Question to the more experienced in the plugin development community:
How should I communicate data from the native environment to the browser?
I have a native.ts which spawns a playerctl process to listen to changes on local media players (linux only for now), but have no idea how to get the data over to the browser side to display it (like how SpotifyControls), or vise-versa. I would use electron's ipc system, but I'm not allowed to import that on the browser plugin.
Also: when trying to build I get a similar error
src/VencordNative.ts:13:28: ERROR: [plugin: ban-imports] Cannot import electron in browser code. You need to use a native.ts file
```, where VencordNative is unmodified. Unsure what is happening here
i don't really understand what NotificationBadgeControl does but the other two plugins seem like nice qol changes
Ah cool thx
NotificationBadgeControl controls the system badge
So first screenshot is Discord Canary, which doesn't have Vencord installed
It shows that weird dot
This one is Vesktop with NotificationBadgeControl
Notice how there's no dot
Basically it manipulates the system badge, kinda like NoSystemBadge but with the ability to control it
Idk if that explains it very well lol
those can already be customised
don't import ur file
look how other plugins do it
native.ts: Line 9
export async function makeDeeplTranslateRequest(_: IpcMainInvokeEvent, pro: boolean, apiKey: string, payload: string) {
utils.ts: Line 29
const Native = VencordNative.pluginHelpers.Translate as PluginNative<typeof import("./native")>;
utils.ts: Line 124
const { status, data } = await Native.makeDeeplTranslateRequest(
I like the memberLeftBadge plugin, I've had the exact same problem with people opening a support forum post and leaving, so I've added a custom badge to show that the person left, it's cool that you did the same in other places too
Oh neat
I could try to make that a feature in mine... although if you can already do that with a different plugin it might not be worth it
my plugin is unofficial cuz it's way too big (and harder to maintain), but as a standalone feature I think it has a higher chance of being accepted
Oh yeah you made the BetterForums one I saw in #1256395889354997771
I might tinker around with the "OP Left" badge on forum posts later, when I have the time
yup
Well my plugin comes with the added bonus of making it seem like you have friends hehe /j

Okay, so far I have figured out how to call a native function, but I still need a way to go from native to my plugin.
I have tried registering a callback, but this doesn't seem to be possible, because, well, Uncaught (in promise) Error: An object could not be cloned..
I found the appleMusic.desktop plugin which has a similar issue where they need to get native metadata and then update rpc. The way they solved it is by having a constant timeout (defaulted to 5 seconds). Though definitely a possible solution, I want to look deeper to see if there are other alternatives. After all, playerctl has the ability to send me updates when they occur (playerctl --follow), which gives more real-time feedback than the timeout solution (say you skip a song just after the update was called, you would have 5 seconds, or whatever setting you have, where it displays the incorrect data).
Since this is the SpotifyControls application, and not an activity generator, it would be nice for a user to have a more responsive real time update when tracks change automatically. (Since if I were to have user input I could update it instantly anyway since we are going browser -> native)
TL;DR:
Is there a way to send information native -> browser, which is not a callback created from the browser (since it doesn't work), and not electron's ipcMain?
there is no good way to do this right now
you can use webFrame.executeJavascript to run js in the browser
pass data via JSON.stringify
// index.ts
export default definePlugin({
someMethod(data) {
console.log(data);
}
})
// native.ts
export async function someNativeMethod(e) {
const data = doStuff();
// callback:
e.sender.executeJavaScript(
`void Vencord.Plugins.plugins.YourPluginName.someMethod(${JSON.stringify(data)})`
); // void keyword ensures that it doesn't return anything, otherwise you may get clone errors
}
using JSON.stringify ensures that evaling it is safe
anyway this is very ugly and I plan to add a better solution eventually
Vesktop has a better api, I will port that to Vencord probably
https://github.com/Vencord/Vesktop/blob/main/src/main/mainWindow.ts#L236
https://github.com/Vencord/Vesktop/blob/main/src/renderer/ipcCommands.ts#L52
mainWindow.ts: Line 236
languages ??= await sendRendererCommand(IpcCommands.GET_LANGUAGES);
ipcCommands.ts: Line 52
onIpcCommand(IpcCommands.GET_LANGUAGES, () => navigator.languages);
damn since when did discord start bundling code with the spread operator
oh lmao I think this is related #πΎ-core-development message
Well, it's kind of working haha
memberLeftBadge is cool
Thanks
Can confirm it works with both posts and threads now
I'ma work on making it show a tag for forum posts too
Hey -- is there anything I can do to increase the chances of a plugin being accepted into Vencord? We've been maintaining it for around a month or so, but haven't received any review yet
Discord already has a built-in per-server channel hider so probably not going to be accepted.
There's also the hide muted channels option.
I understand you can hide server channels. This plugin is for private channels
DM Groups?
DM Groups and Users, yes.
Why not just leave the group?
Have you read the PR description?
Yeah, and if you don't want to hear about a group then leave it, no?
If you want the group to know that, and to not have the possibility to come back without an invite, sure.
We also use this plugin for users who we want to ignore, but without using the built-in Ignore feature that collapses all their messages. It's useful that their channel doesn't jump to the top of the list each time they message, stealing our attention from other things, but we can still access it using the Quick Switcher when needed
Also, it's worth noting that "private channels" is everything under direct messages. It's not just group DMs; user DMs are channels as well
(I hate Discord's image cropping)
Alright well I got everything working and am doing some cleanup and I have noticed that the plugins stop method is never called. Or at least, it doesn't seem to be working as I imagine.
I try to remove the child_process (playerctl) when that function is called, but whenever I exit discord or restart (ctrl + r), it doesn't properly kill the processes.
I know the killing works since I've run the function after a 10s delay and it worked perfectly fine. Is this a known bug in Vencord or am I possibly doing something wrong?
I currently have a workaround to have a process.on("exit"), but this isn't called when the browser restarts, meaning that it leaves behind some ghost processes every time you restart.
I am also unsure what to do with the plugin. I will probably publish it as an unofficial plugin since it currently only supports Linux (and very specifically the Elisa media player at that, though adding player support on Linux is trivial).
I saw some of the discussion on the plugin requests github (#198) and it would likely need to be cross-platform, which playerctl is not. Could a solution to this be having different native backends for the different platforms?
It might be nice to have a swappable backend to be able to support even other online apis in the future, though for this my code might have to be improved a bit :P
This is especially the case since this plugin is not compatible with the SpotifyControls as I stoleborrowed their code (and patch where the panel is drawn)
My recommendation:
- You can have the webpage ping your native code every second or so to prove it's still alive. If your native code doesn't receive a ping from the webpage for a couple seconds, assume it froze or was unloaded, and clean up.
- If you call some setup routine on load, then make sure to perform any clean up first, just in case a reload happened quickly and the two seconds hasn't elapsed yet.
Of course, you'll have to reinit if you clean up but the webpage starts being alive again, but I think that's a fair tradeoff?
I really don't understand the motivation
block the user or leave the group
We're not interested in justifying our use-case, and this is a pain point for at least some other users, given there was a request for it during the short time plugin suggestions was active.
you have to justify your use case if you want to have any chance of it being considered
I don't see the point of it so I wouldn't accept it
Not in the way you are asking. I explained how existing features don't work for us given the constraints (no blocking or leaving, no collapsing of messages). I don't need to sell my constraints to you; they're not unreasonable, and come up all the time in nuanced social situations.
Tons of plugins in Vencord exist purely for decorative purposes, for accessibility, for convenience, or etc. This plugin fills a convenience niche in a well-defined and fairly simple way. The code also should be fairly idiomatic. You could just as well argue that nobody needs to see someone else's platform, etc.
And say, ShowMessageButtons practically just automates the action of holding Shift. (Although we have another open PR slightly improving it for us)
We have tons of plugins we probably won't ever try to upstream because the constraints are far more particular to ourselves. We want to upstream this one because there are documented instances of other users asking for it.
who's we
loaded question lol. their bio has a link explaining
plural
but at the same time couldnβt css do this? @craggy hazel
We did use CSS for visual hiding before, but the class for muted channels is deeper in the tree than we'd like, and CSS also can't alter alt+arrows behavior
oh boy
i guess that's the users pluralchum wouldve been used for
what do you mean loaded question bruh
it sounded like they were working together with someone so I asked for clarification
and if u think I'm clicking view full bio on "Fluffy, cuddly female Flareon, lover of glue things and lewd things~
" you're crazy
I mean real
I would've answered "first person plural"
I feel it'd only be loaded if you were asking just to criticize the answer, I get it genuinely from time to time
I reformatted my bio a bit to get the link to show up without having to open the full profile
I donβt think thatβs gonna help lol
But what do I know Iβve been here what like 2 days
Oh, 7? Time flies
hi
how to add a setting tab in settings ?
I did use makeSettingsCategory but i suppose i need to add something like a hook
finally succeed to do it
Hello, newbie here, im trying to understand how match-replace works, i read pinned message but that confused me still, cause that nsfwallowed thing isnt a UI or component. The reason im trying to fix this cuz cant see nsfw server pings/mentions in my inbox when living outside of dumb EU verification ideas. Idk why asia is affected on this, cant verify or do anything at all to make this work even though im 28. <.>
it's just regex replace
that's it
hi! do i need to include the license preamble in any files i write?
id like to merge them at some point, but speaking of which, since the plugin requests are closed can i still submit prs to add plugins? i made a vosk voice message transcription plugin
Eslint automatically adds it
how am i supposed to make it more specific if theres no other exports 
i figured it out ```js
let filter = m => Vencord.Webpack.filters.byClassNames("bar", "error")(m) && Object.keys(m).length == 2;
Vencord.Webpack.mapMangledCssClasses(Vencord.Webpack.find(filter, { isIndirect: true, topLevelOnly: true }), ["bar", "error"])
use an exclusive filter
Could I in theory create a plugin that allows you to create profile presets, like. idk.
click apply and it changes your pfp, bio, whatever you want
and also maybe some server nicknames
Or would I get like ratelimited wicked hard or osmething
yeah youd hit rate limits quick afaik, but if you just make a way to save a preset before saving modiifcations you could prob just restore that state from fs or smth
Lost me on that last statement
change your discord user profile however u want -> "save, discard, save preset" -> save preset -> copy input image and modified data to.. somewhere. you could probably store the image as an image string along with the data in indexed db or something but filesystem (fs) just putting it in a folder might be better, but i rarely dabble with electron so theres probably a better way to do it
then youd just restore the modifications from that location
True
Though, if I only change a PFP and some server nicknames, that wouldn't be too ratelimity, would it? I could also make it wait.
pfp is like twice an hour isnt it. or is that username
I do not remember, though I've been able to change my PFP pretty quickly.
am I good to just open a pr to merge this or will my access get restricted or smth because there's no plugin request for it π
the docs aren't very consistent
Not helpful but I have the same confusion too lol
you can pr plugins you've made you just can't ask others to make plugins anymore
also know the odds of getting a pr merged are like 1/1000 and the timeframe is an exponential curve of like 0.00001% chance tomorrow to 5% chance in 3 years.
Ah cool
also if you pr obviously ai generated code or ai plugin description you will get shit on and then pr closed
That plugin won't work because it's a server side check now
I've replicated the plugin because my alt acc got into the age verification testing group even though I'm not in the UK or EU
@cobalt prism
You can look at the request headers when opening the nsfw channel, it returns a 403 forbidden response
I dont care about age verification honestly channels are works fine. just the inbox feature is broken none of mentions are showing up from a nsfw channels. and there no way to verify that since im not from EU 
But good to know. probably wont reach here. hopefully
i was able to fix it via injecting console at the moment, that at least works fine for my inbox issues
im so dumb about how regex replace works so i will try whenever got time for it
Ask chatgipiti to teach u to understand regex replace
wait, ratelimits aside, can you even do this
can a plugin change that stuff at all
dont see why not. you'd just call RestAPI.patch or smthn like that on /users/@me or w/e the endpoint is
just change that stuff manually and watch network tab
or take a look at https://discord.food docs on it
are there liek example plugins or sm ive never done this before lol i have no clyue how vencord works..
There's a couple hundred plugins right there
search the repo for examples
That is an extremely valid point
you can take a look at how this plugin does it, although it's not maintained anymore https://github.com/D3SOX/vc-serverProfilesToolbox
Vencord ServerProfilesToolbox user plugin. Contribute to D3SOX/vc-serverProfilesToolbox development by creating an account on GitHub.
ion see a reason to do that though i see why youd say that it would probably less brittle to just inject updates on the user profile page from presets
hm good point
ok lowkey been testing some shit
i dont think the pfp ratelimit is twice an hour anymore
there definitely still is one
cause the endpoint is how you update your profile?
looks like it might be 2 per 10 minutes
Oh that's not so bad at all
Also the endpoint works just fine
i mean from the profile edit page you could just load the preset into the input boxes and file inputs instead of doing a direct api call
eh i like how i have it where i can do it from anywhere
plus im updating server nicknames too which needs the api(?) so i might as well go all in
though i almost want to add it so where if you are able to, it switches your answer in channels & roles or maybe applies a reaction role
but
also
like
i think discord would take me out back and shoot me
Has anyone made a plugin that implements this little audio player on desktop yet? Might do that if not
Would be nice to be able to listen to an audio file without it stopping if you navigate literally anywhere
[Ikr?](#π³-plugin-requests message) 
Oh lol
I didn't consider embedded stuff, that might be harder but I can give it a go
I haven't done any programming in months so will be a good one to get back into
I guess it would be expanding this rather than its own plugin
setting to auto pip when navigating away
Yeah that's the plugin I originally mentioned in the feature requests model
I am blind
Haha dw
Am I cooking with this?
and yes i copied raycast
didnt @oblique viper also make something like this
I do know there's a command palette plugin in equicord
And probably a userplugin version
was just a figma concept
this is what the one in equicord looks like
Yea actually its sick lookin
absly
added alot more commands, made the commands faster too
UI is faster
page fluidity is better
gonnna try adding direct plugin support, as if they were Raycast Extensions
so lets say you can control equicord's holynotes from the palette
or uhhh SilentTyping
stuff like that
big plans and big ideas
ctrl+k?
oh nvm then
i can add a setting to replace it with crtl+k pretty easily
Are there any docs for slash commands? I swear I'm doing something wrong, considering the fact that it sends a message with the sent command along with actually doing the action.
it worked
only figured out one so far
but it works!
you can look at plugins like friendinvites and spotifysharecommands
to learn how
there's no official docs on slash commands afaik
so like i did and they both did it very differently and i couldn't figure out what I was doing wrong
mmmm
specify inputType to built in
i like it but make a bit more compact ig
this sohuld be smaller
these too
most likely these ig
i plan to just turn it into an action panel
I am having some trouble getting it to recognize the custom dist set, I followed the guide, and I am not actually seeing any errors that lead me to believe this failed in some way, just routine stuff. I originally tried to build in WSL, figured it might be a directory issue, and restarted from scratch following the guide precisely. I don't see custom plugins or any indicator that it is failing to load them. Is there something from the guide I am missing, beyond just pointing vesktop to the dist?
(and also restarting the client completely, that's been done too)
Do I specifically need to specifiy --dev?
Are there no errors in the console related to the custom plugins you're installing?
also this isn't support
None. Forgive me if I am in the wrong place, but more generically I am trying to ensure that it is actually loading the dist. Nothing in the console suggests any issues with the plugins I am trying to run, and ultimately I am not looking for support for those plugins, more just wondering what would cause issues with a custom dist seemingly not even loading
Figured it out was a permissions issue
WSL funk
π
I do that but pass the function to $self
substantially less cursed
Good timing
ye lol
now how do I access that outside of a patch π
cursed? type hinting for accessing plugins object was yelling at me
aint working. agony
Just ts-ignore the plugins way
that also didnt work
function is just returning null
which is the initial behavior
when I call it in dev console it returns fine though
I haven't written anything for vencord in months tbh so I don't remember much off the top of my head anymore
oh looks like I might be victim of bad typing
I was tryna access effect_id but data im getting has it as effectId
yeah that worked
Howdy! I am working on a few things, But was curious about backing up data in CloudSync, is there documentation anyone can link to where that might be explained so I can read up on how one does that?
save it in your plugin settings and it will be saved to cloud automatically
why did you send VoiceMessage plugin files
oh wait
hang on i'm stupid
π
i'm so tired i can't bro give me a second
ok THERE'S the correct files π
the first argument is the event object
export async function uploadFileNative(
event: IpcMainInvokeEvent,
url: string,
besides that
- You are using your own method wrong (even without the event arg)
- Use JS apis like FormData instead of rolling your own
- Your code isn't safe. You shouldn't allow sending arbitrary http requests
god i'm so bad at this π
hang on thanks for the help let me see if i can change some stuff rq
That's quite the lines of code
heyy
i don't think there's a plugin that does that but i feel like that would be useful
i'm trying to make a code that gives you the list of all channels of a discord with their descriptions and permissions if available
but i suck and llms i asked help too sucked too
any help on how i'd be doing this ?
There are some existing plugins Iβd look at if I were you
well there isn't a plugin that does this all in one modal, but there are plugins to show you this one-by-one
permisionsviewer, showhiddenchannels is a good mix
simply right click on a channel, click permissions and this comes up
then look at both of those plugins and figure out a design to make this in one modal.
I would depend on characters count more but probably ye
yes
but can it be justified
no
not even a little bit
no you just write shitcode
how can i add a right side panel to discord
like devtools/modview
@hushed loom figure out
thanks !
what could possibly take up that many lines
https://raycast.com/ in discord
oh right
with plugin integrations like silentMessageToggle, Experiments ect
you can open stuff like theme library, quickcss ect
this is going to be PR'd to equicord as equicord is a more experimental fork than vencord and i don't see it being merged here tbh
i don't think vee will be happy to review all 9 thousand something lines of code
yes
honestly its a good plugin imo
yeah the codes a little bit horror
but its a useful plugin
well..i hope it is atleast
you should 100% split the code into multiple files
it is already split
into alot of files
maybe too many actually lmfao
I could tell you are more into design
yo fix your website
always reminds me of those usual SaaS designs
I mean it's not wrong
That's not my product LOL
I'm just copying an existing product into discord
I mean you are technically right I used to do UI/UX design
ohh lol
where's the plugin wip code then?
uhh i pr'd a draft to https://github.com/Equicord/Equicord
@iron epoch
okie dokie, ty
the codes a little horror
so keep that in mind
there are still a few bugs
compact mode doesn't quite work
and the UI has a sort of delay/lag
oughh
thank you
its missing some things from discord devtools'
like the ability to make it into its own window or resize it
wouldnt be too hard to add
also css i forgor
added this as a test ```css
#vc-custom-panel {
background: var(--background-base-low);
color: var(--text-default);
}
think devtols is like that idk
now discord app isnt loading cus internet so idk
@lost gulch AI plugin soon
hop on return new class extends Flux.store
neverrrr :3
idk if it's just me but syntax coloration of Java seems a bit broken
@Mixin(LightmapTextureManager.class)
public class LightmapTextureManagerMixin {
@WrapOperation(
method = "update",
at = @At(
value = "INVOKE",
target = "Ljava/lang/Double;floatValue()F",
ordinal = 1
)
)
private float getGammaFloatValue(Double instance, Operation<Float> original) {
return original.call((!Config.VisionLimiter.enableFullbright ? instance : Double.valueOf(Float.MAX_VALUE)));
}
}
it's better in chatbox than in chat
yeah i use shiki code blocks with pretty much defaults iirc except i have set the theme
and setting it to prefer shiki over highlight.js make code coloration kinda cursed and even more broken
bug in shiki then ig
ih i'll have to debug it :pain:
I think it is just normal discord behavior
they're saying the blue one is better/correct
so shiki is failing to make it all the same color
Ohh, yeah then that is incorrect π
and also as you can see here it fail on the multiline annotation
only the first line is blue
also shiki might not be wrong, but it's kinda unreadable imo with color being all over the place
well I do think shiki is wrong because the blue extends even into the ( parenthesis which doesnt make sense
if only @WrapOperation was supposed to be colored and not the function itself
i think the whole annotation is supposed to be blue
yeah thats more likely
just stating I dont see a world where it was a stylistic choice to not color the function itself
since the opening curly was blue'd
i think it just did not expect that the annotation would be multi-line
which tbh is fair
most of the time you don't do big annotations
except when you code minecraft stuff and you use Mixins
wait i think shikicodeblocks plugins also break discord ansi codeblocks
\u001b[0;40m\u001b[1;32mThat's some cool formatted text right?\u001b[0m
or
\u001b[1;40;32mThat's some cool formatted text right?\u001b[0m
cause that's all i can see
that isn't working for me without shiki either
nvm found out you need to use the non escaped character
[0;40m[1;32mThat's some cool formatted text right?[0m
or
[1;40;32mThat's some cool formatted text right?[0m
like the actual code 001b
like the char value
tho it makes the WYSIWYG editor a bit eeeeeh
there's this generator btw https://rebane2001.com/discord-colored-text-generator/
Rebane's Discord Colored Text Generator
me who just type my shit by hand :w:
- here it wasn't for much, just to have accurate terminal output
root@Free:~# apt install -s snapd
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Package snapd is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
[0;31mE:[0;0m Package 'snapd' has no installation candidate
what 'find' would you guys use for this module?
Hmm maybe β¨=500;functionβ©
or ["aria-hidden"],onMouseEnter
ye what suff said
suff's better tho
cause it could be extended to the let current to anchor it even more
findByCode searches for specific exports and the "500" is part of the module's code
Oh true
oh reason davs didnt work is cause findbycode is for functions
right
whats the function to test a patch find in console then
i think discord did not like me doing that
π
findModuleFactory I think
^
Just takes a string or regex
Vencord.Webpack.findModuleFactory("=500;function")
real and true
hi, i made a small Vencord userplugin called ShowPing that always shows your WebSocket ping in the voice panel below the channel name, without having to hover over the icon.
https://github.com/gaprj/vencord-show-ping
Would you guys add it to the official list or should I just leave it on GitHub?
i have 2 monitors and its really useful for me
already exist π
yours isn't overdone though so props to that
I tried to patch this module but for somereson vencord says it has no effect why?
function InjectedBar() {
return (
<div style={{
padding: "8px",
marginBottom: "8px",
borderRadius: "8px",
background: "rgba(0,0,0,0.2)"
}}>
TEST β
</div>
);
}
.
.
.
.
find: "aria-labelledby",
replacement: {
match: /children:\s*\[\(0,\s*r\.jsx\)\("div",\s*\{\s*className:\s*a\(\)\(y\.wx,\s*this\.props\.headerClassName\),/,
replace: 'children:[(0,r.jsx)($self.InjectedBar,{}),(0,r.jsx)("div",{className:a()(y.wx,this.props.headerClassName),'
}
.
.
.
.
also I am new to vencord plugins so sorry if its a bit dumb question
First of all, try to find something more specific to that module rather than aria-labeledby. If you use the patch helper it will warn you that there are multiple matching modules
Also, you don't have to use \s* since discord's bundle is minified and doesn't contain any spaces unless necessary
That's because it finds the first module and tries to patch that
if you want all modules to be affected, add all: true
and noWarn: true (neither is recommended tho)
so it just patches the wrong module?
yeah
FavoriteGifSearch injects into the same module it looks like, so you can take a look at their patches
ok, so copying FavoriteGifSearch find works, but it feels wrong to look for compleley another function name to find the module no?
It's fine really, since this is a single component it's unlikely that it would ever get split into multiple modules
ah...
didnt know that ahaha
so something like this wouldn't be accepted into vencord?
Aren't those changes batched into one "save changes" on stock anyway?
So it's still one button press -> one action
I dunno why I assumed the question was in relation to this, they weren't even close in time #πΎ-core-development message
it saves your pre set
not the actual profile
So it just fills in the page and you still click save yourself?
Yes
Save or Cancel
I think it'd be fine even if it did submit it personally but I do think that's better
I don't see any reason it couldn't be included besides maybe being niche but I can't really judge that as I don't use server profiles
not the same yeah very different things
well people use profiles all throughout discord and have many different changes within their profile i think profiles are a pretty big thing on discord
its pretty much your identity and many people like customizing their profiles with different colors, different name plate styles etc so its practical for those users
You'd get rate limited which is why it's pending cause changing profile too fast will be api-spam
Yeah I imagine some people would use it a lot, I'm just not one of those people so I'm not a good judge of how much people would like it
yeah true well thanks for your response and btw love your profile and username
this button feels off and quite distracting imo
srgb linear gradient horror
yop
yeah that's what i originally thought also
looks like something you would see in some aislop generator site
even expressive looks better 
it still stands out quite alot
haha true
i was just jokinπ₯
π
i do like it actually quite alot more though to be fair
looks beautiful gif does not do it justice nvm
this is better
animated gifs are terrible and shouldn't be used
actual video files are higher quality while being significantly smaller file size
and it seems like static gifs are almost as useless
true
would anyone actually use this
fun fact, expressive is built with rive, i remade it in rive in the past
βͺοΈ Replying to @discord
@discord Nitro gift Button using @rive_app
Does anyone know where I can find a near-perfect replica of discord dm ui? Could help me with testing features to add to plugins
why can't you test it with the actual dm ui?
Well I have to navigate alot of obfuscated code
you can find some stuff on figma
this one has the user sidebar + mobile dms https://www.figma.com/community/file/1458208266676217372
this one is more modern but lacks some details https://www.figma.com/community/file/1490562611382147791/new-discord-design-mockup
why is the top code valid but the bottom one not? what am i missing?
this is not my original use case but i've abbreviated because the rest is unnecessary :p
The edit one has a different signature
So your messageObj argument there is actually just the messageId
oh, not sure how i missed that. thanks!
just for completeness- what would the correct code snippet be?
Just that one part needs to be addMessagePreEditListener(async (channelId, messageId, messageObj) => { and the rest can stay the same
np 