#CopyFolderID
1 messages · Page 1 of 1 (latest)
Just curious, what did you need a folder ID for?
fixing betterfolders
😭
doing some debugging and wanted to do some testing with a folder
needed the folder id
which i didnt want to have to go into components to keep getting
new plugin? yes
is it gonna be helpful? no
will you install it? absloutely
Real.
could expand this into adding copy id buttons to everything missing it
Yea, but what else is missing it
shitton of stuff lol
Send a list and I’ll add it if you want
finding them's the annoying part xd
I made a copy sticker ID plugin the other day. was considering posting it but wasnt sure if it was worth it lol
oh that's in the picker?
I added it to right clicking one in chat
doesnt have that option there
actually added it to the message context menu didnt know stickers had their own context menu. should probably fix that
@gusty forge do you mind if i add it to this plugin
might move this to a more copy missing ids
Sure, here's all it is. not sure if there's a better way but 
const modifyMessageContextMenu: NavContextMenuPatchCallback = (children, props) => {
const { message } = props;
const { stickerItems } = message;
if (!stickerItems || stickerItems.length === 0) {
return;
}
const newMenuItem = (
<Menu.MenuItem
id="copy-sticker-id"
key="copy-sticker-id"
label={stickerItems.length === 1 ? "Copy Sticker ID" : "Copy Sticker IDs"}
icon={Icons.IdIcon}
action={() => {
const stickerIDs = stickerItems
.map(sticker => sticker.id || sticker.name)
.filter(idOrName => idOrName)
.join("\n");
if (stickerIDs && Clipboard.SUPPORTS_COPY) {
Clipboard.copy(stickerIDs);
}
}}
/>
);
const copyMessageIdIndex = children.findIndex(child => child?.props?.children?.props?.label === "Copy Message ID");
if (copyMessageIdIndex !== -1) {
if (children[copyMessageIdIndex]?.props?.children) {
children[copyMessageIdIndex].props.children = [children[copyMessageIdIndex].props.children, newMenuItem];
}
} else {
children.push(newMenuItem);
}
};
I think I wrote this before finding out about findGroupChildrenByChildId
findChildrenAndConsumeThem
This is so awesome and life changing. Thank you for posting this message.
broken(
src/plugins/vc-copyFolderId/index.tsx:10:9: ERROR: No matching export in "src/webpack/common/index.ts" for import "Icons"
just import from '@components/Icons' iirc
absolutely clueless
wait
maybe?
those are just replica icons though
GUHHHH @lethal coyote when you banned me on accident it kicked me off all my plugin threads
sadanic
@signal cape you will pr