@@ -70,7 +70,7 @@ export function Account() {
onClick={() =>
openScreen({
id: "modify_account",
- field: field as any
+ field: field
})
}
contrast
diff --git a/src/pages/settings/panes/Appearance.tsx b/src/pages/settings/panes/Appearance.tsx
index 58426b31..714e4086 100644
--- a/src/pages/settings/panes/Appearance.tsx
+++ b/src/pages/settings/panes/Appearance.tsx
@@ -226,7 +226,7 @@ export function Component(props: Props) {
- {[
+ {([
"accent",
"background",
"foreground",
@@ -240,7 +240,6 @@ export function Component(props: Props) {
"block",
"message-box",
"mention",
- "sidebar-active",
"scrollbar-thumb",
"scrollbar-track",
"status-online",
@@ -252,15 +251,15 @@ export function Component(props: Props) {
"warning",
"error",
"hover"
- ].map(x => (
+ ] as const).map(x => (
{x}
+ style={{ backgroundColor: theme[x] }}>
setOverride({
[x]: v.currentTarget.value
@@ -270,7 +269,7 @@ export function Component(props: Props) {
setOverride({
[x]: y.currentTarget.value
diff --git a/src/pages/settings/panes/Notifications.tsx b/src/pages/settings/panes/Notifications.tsx
index ae3c1657..5098c85e 100644
--- a/src/pages/settings/panes/Notifications.tsx
+++ b/src/pages/settings/panes/Notifications.tsx
@@ -77,11 +77,11 @@ export function Component({ options }: Props) {
// tell the server we just subscribed
const json = sub.toJSON();
- if (json.keys) {
+ if (json.keys) {;
client.req("POST", "/push/subscribe", {
endpoint: sub.endpoint,
- ...json.keys
- } as any);
+ ...(json.keys as { p256dh: string, auth: string })
+ });
setPushEnabled(true);
}
} else {
diff --git a/src/pages/settings/panes/Profile.tsx b/src/pages/settings/panes/Profile.tsx
index 941d311d..1b6fa429 100644
--- a/src/pages/settings/panes/Profile.tsx
+++ b/src/pages/settings/panes/Profile.tsx
@@ -11,7 +11,7 @@ import { ClientStatus, StatusContext } from "../../../context/revoltjs/RevoltCli
import AutoComplete, { useAutoComplete } from "../../../components/common/AutoComplete";
export function Profile() {
- const { intl } = useContext(IntlContext) as any;
+ const { intl } = useContext(IntlContext);
const status = useContext(StatusContext);
const ctx = useForceUpdate();
@@ -121,7 +121,7 @@ export function Profile() {
: "placeholder"
}`,
"",
- intl.dictionary
+ (intl as any).dictionary as Record
)}
onKeyUp={onKeyUp}
onKeyDown={onKeyDown}
diff --git a/src/pages/settings/panes/Sessions.tsx b/src/pages/settings/panes/Sessions.tsx
index b9bccc4b..2ec357be 100644
--- a/src/pages/settings/panes/Sessions.tsx
+++ b/src/pages/settings/panes/Sessions.tsx
@@ -155,7 +155,7 @@ export function Sessions() {
]);
await client.req(
"DELETE",
- `/auth/sessions/${session.id}` as any
+ `/auth/sessions/${session.id}` as '/auth/sessions'
);
setSessions(
sessions?.filter(
diff --git a/yarn.lock b/yarn.lock
index 9362c74f..6fec1864 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -3590,10 +3590,10 @@ reusify@^1.0.4:
resolved "https://registry.yarnpkg.com/reusify/-/reusify-1.0.4.tgz#90da382b1e126efc02146e90845a88db12925d76"
integrity sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==
-revolt.js@4.3.3-alpha.7:
- version "4.3.3-alpha.7"
- resolved "https://registry.yarnpkg.com/revolt.js/-/revolt.js-4.3.3-alpha.7.tgz#de6ecef444e8368aac3753761e2e10f516f50712"
- integrity sha512-oi76A+EIxrD+tVRTU8s2LISFBpvMf0kpinw5rdukoc1VWpl0bCC6Kko26yC7lhVkWGLTZxHMOKaUkgbOgy0flA==
+revolt.js@4.3.3-alpha.8:
+ version "4.3.3-alpha.8"
+ resolved "https://registry.yarnpkg.com/revolt.js/-/revolt.js-4.3.3-alpha.8.tgz#2a191ffa9d4c304e328b5eb8d9dc1e13e1f99d9a"
+ integrity sha512-A6sjZ7cmeQuqS9otzANv+Rg4CfvpsTMoDARBwQuez4O7NPRopdWNHylUPo20UutAPzW9xoqVbF8673VlTu5Jag==
dependencies:
"@insertish/mutable" "1.1.0"
axios "^0.19.2"