mirror of
https://github.com/Equicord/Equicord.git
synced 2025-06-10 15:13:02 -04:00
Fix all plugins for new i18n lib (#2993)
This commit is contained in:
parent
5216bcca1e
commit
00f82e96bd
89 changed files with 351 additions and 238 deletions
|
@ -19,10 +19,10 @@
|
|||
import ErrorBoundary from "@components/ErrorBoundary";
|
||||
import { Flex } from "@components/Flex";
|
||||
import { InfoIcon, OwnerCrownIcon } from "@components/Icons";
|
||||
import { getUniqueUsername } from "@utils/discord";
|
||||
import { getIntlMessage, getUniqueUsername } from "@utils/discord";
|
||||
import { ModalCloseButton, ModalContent, ModalHeader, ModalProps, ModalRoot, ModalSize, openModal } from "@utils/modal";
|
||||
import { findByCodeLazy } from "@webpack";
|
||||
import { Clipboard, ContextMenuApi, FluxDispatcher, GuildMemberStore, GuildStore, i18n, Menu, PermissionsBits, ScrollerThin, Text, Tooltip, useEffect, UserStore, useState, useStateFromStores } from "@webpack/common";
|
||||
import { Clipboard, ContextMenuApi, FluxDispatcher, GuildMemberStore, GuildStore, Menu, PermissionsBits, ScrollerThin, Text, Tooltip, useEffect, UserStore, useState, useStateFromStores } from "@webpack/common";
|
||||
import { UnicodeEmoji } from "@webpack/types";
|
||||
import type { Guild, Role, User } from "discord-types/general";
|
||||
|
||||
|
@ -216,7 +216,7 @@ function RoleContextMenu({ guild, roleId, onClose }: { guild: Guild; roleId: str
|
|||
>
|
||||
<Menu.MenuItem
|
||||
id={cl("copy-role-id")}
|
||||
label={i18n.Messages.COPY_ID_ROLE}
|
||||
label={getIntlMessage("COPY_ID_ROLE")}
|
||||
action={() => {
|
||||
Clipboard.copy(roleId);
|
||||
}}
|
||||
|
@ -225,7 +225,7 @@ function RoleContextMenu({ guild, roleId, onClose }: { guild: Guild; roleId: str
|
|||
{(settings.store as any).unsafeViewAsRole && (
|
||||
<Menu.MenuItem
|
||||
id={cl("view-as-role")}
|
||||
label={i18n.Messages.VIEW_AS_ROLE}
|
||||
label={getIntlMessage("VIEW_AS_ROLE")}
|
||||
action={() => {
|
||||
const role = GuildStore.getRole(guild.id, roleId);
|
||||
if (!role) return;
|
||||
|
@ -257,7 +257,7 @@ function UserContextMenu({ userId }: { userId: string; }) {
|
|||
>
|
||||
<Menu.MenuItem
|
||||
id={cl("copy-user-id")}
|
||||
label={i18n.Messages.COPY_ID_USER}
|
||||
label={getIntlMessage("COPY_ID_USER")}
|
||||
action={() => {
|
||||
Clipboard.copy(userId);
|
||||
}}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue