fix(lib/discord/ui): cleanup common exports

This commit is contained in:
PalmDevs 2025-05-04 20:26:44 +07:00
parent a219f2a4df
commit 00265bdfa1
No known key found for this signature in database
GPG key ID: 6FAE8F8677ACA8BA
2 changed files with 6 additions and 4 deletions

View file

@ -11,13 +11,13 @@ export let Components: Components = proxify(
// [3237, 1366, 3238, 3239, 2, ...];
const module = lookupModule(
moduleStateAware(
byProps('TableRow', 'Button'),
byProps<Components>('TableRow', 'Button'),
byDependencies(looseDeps([relativeDep(1), undefined, relativeDep(2), relativeDep(3), 2])),
),
{
includeUninitialized: true,
},
) as Components | undefined
)
if (module) {
// This allows the Proxy instance to be garbage collected
@ -46,7 +46,9 @@ export interface Components {
IconButton: DiscordModules.Components.IconButton
ImageButton: DiscordModules.Components.ImageButton
Stack: DiscordModules.Components.Stack
Slider: DiscordModules.Components.Slider
TableRow: DiscordModules.Components.TableRow
TableRowGroup: DiscordModules.Components.TableRowGroup
TableRowTrailingText: DiscordModules.Components.TableRowTrailingText
TableSwitchRow: DiscordModules.Components.TableSwitchRow
Text: DiscordModules.Components.Text

View file

@ -11,7 +11,7 @@ export let SettingListRenderer: SettingListRenderer = proxify(
() => {
const module = lookupModule(
moduleStateAware(
byProps('SettingsList'),
byProps<SettingListRenderer>('SettingsList'),
byDependencies(
looseDeps([
ReactModuleId,
@ -26,7 +26,7 @@ export let SettingListRenderer: SettingListRenderer = proxify(
{
includeUninitialized: true,
},
) as SettingListRenderer | undefined
)
if (module) {
// This allows the Proxy instance to be garbage collected