Skip to content

Add plugin toggling to venbot embeds#2732

Open
Masterjoona wants to merge 39 commits into
Vendicated:devfrom
Masterjoona:feat/supporthelper
Open

Add plugin toggling to venbot embeds#2732
Masterjoona wants to merge 39 commits into
Vendicated:devfrom
Masterjoona:feat/supporthelper

Conversation

@Masterjoona
Copy link
Copy Markdown
Contributor

@Masterjoona Masterjoona commented Jul 27, 2024

Discord_pftXYSe25P.mp4

Comment thread src/components/PluginSettings/togglePluginEnabled.ts Outdated
Comment thread src/components/PluginSettings/utils.ts Outdated
@Sqaaakoi
Copy link
Copy Markdown
Contributor

after a tiny bit of extra thinking, why not just delete the original embed and replace it with a PluginCard using MessageAccessoriesAPI

@Masterjoona
Copy link
Copy Markdown
Contributor Author

looking into this

@Masterjoona
Copy link
Copy Markdown
Contributor Author


the excluded looks kinda ugly, idk what would be a good component for it

@lewisakura
Copy link
Copy Markdown
Collaborator

this is really cool, never thought about doing something like this when i wrote the original feature

for the exclusion stuff, i think it would be best to just render a plugin card but then replace the switch with a yellow exclamation icon (like what discord uses) with a tooltip that explains why, it'd require modification of the plugin card to support this though

Copy link
Copy Markdown
Contributor

@Sqaaakoi Sqaaakoi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel like you've oversimplified what code I gave you earlier in order to not duplicate things and to make it easier to understand, rather than keeping consistency with how PluginCard is wrapped in PluginSettings
Additionally I have some concerns about how URLs aren't being used to get the plugin name

Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
@Masterjoona
Copy link
Copy Markdown
Contributor Author


Copy link
Copy Markdown
Contributor

@Sqaaakoi Sqaaakoi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I love it so far! I still feel there are a few more details that need to be added/tweaked

Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
@Vendicated
Copy link
Copy Markdown
Owner

maybe instead of completely replacing the original message, we could instead add the plugin card as Accessory? So the message will have both

please also resolve conflicts 🙏🏻

@Vendicated
Copy link
Copy Markdown
Owner

I'm gonna rework how plugin cards look soon with components v2

let's wait for that and make these buttons look less crap then (not the ugly blue buttons)

Comment thread src/components/settings/tabs/plugins/PluginCard.tsx Outdated
@Vendicated
Copy link
Copy Markdown
Owner

I'm not really a fan of all these changes to the settings. the code should for the most part be only in the plugin file, settings shouldn't have to know about any of this

@Masterjoona
Copy link
Copy Markdown
Contributor Author

reverted those changes

Comment thread src/components/settings/tabs/plugins/index.tsx Outdated
Comment thread src/components/settings/tabs/plugins/PluginCard.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/plugins/_core/supportHelper.tsx Outdated
Comment thread src/components/settings/tabs/plugins/PluginCard.tsx Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Not Reviewed

Development

Successfully merging this pull request may close these issues.

5 participants