fix(eslint): rules included deprecated plugin

This commit is contained in:
Paul Makles
2022-06-12 19:38:29 +01:00
parent 8e1685a402
commit 74a42914d7
24 changed files with 122 additions and 61 deletions

View File

@@ -120,11 +120,11 @@ export default function Discover() {
useEffect(() => {
function onMessage(message: MessageEvent) {
let url = new URL(message.origin);
const url = new URL(message.origin);
if (!TRUSTED_HOSTS.includes(url.host)) return;
try {
let data = JSON.parse(message.data);
const data = JSON.parse(message.data);
if (data.source === "discover") {
switch (data.type) {
case "init": {

View File

@@ -77,17 +77,17 @@ export default observer(() => {
<div className={styles.socials}>
<a
href="https://github.com/revoltchat"
target="_blank">
target="_blank" rel="noreferrer">
<Github size={24} />
</a>
<a
href="https://twitter.com/revoltchat"
target="_blank">
target="_blank" rel="noreferrer">
<Twitter size={24} />
</a>
<a
href="https://mastodon.social/@revoltchat"
target="_blank">
target="_blank" rel="noreferrer">
<Mastodon size={24} />
</a>
</div>
@@ -116,7 +116,7 @@ export default observer(() => {
<a
className={styles.attribution}
href="https://unsplash.com/@fakurian"
target="_blank">
target="_blank" rel="noreferrer">
<Text id="general.image_by" /> &lrm;@fakurian &rlm;·
unsplash.com
</a>

View File

@@ -260,7 +260,7 @@ export const Form = observer(({ page, callback }: Props) => {
<a
href="https://developers.revolt.chat/faq/instances#what-is-a-third-party-instance"
style={{ color: "var(--accent)" }}
target="_blank">
target="_blank" rel="noreferrer">
<Text id="general.learn_more" />
</a>
</span>

View File

@@ -52,7 +52,7 @@ export function FormLogin() {
if (session.result === "MFA") {
const { allowed_methods } = session;
let mfa_response: API.MFAResponse | undefined =
const mfa_response: API.MFAResponse | undefined =
await new Promise((callback) =>
modalController.push({
type: "mfa_flow",

View File

@@ -101,7 +101,7 @@ export default observer(({ channel }: Props) => {
filter={[
...(channel.channel_type === "Group"
? []
: ["ViewChannel" as "ViewChannel"]),
: ["ViewChannel" as const]),
"ReadMessageHistory",
"SendMessage",
"ManageMessages",