mirror of
https://github.com/Equicord/Equicord.git
synced 2025-06-29 08:24:26 -04:00
ReplaceGoogleSearch: fix broken icons
This commit is contained in:
parent
e4b1a196ae
commit
96516f113a
2 changed files with 2 additions and 15 deletions
|
@ -20,7 +20,7 @@ import { definePluginSettings } from "@api/Settings";
|
||||||
import { Devs } from "@utils/constants";
|
import { Devs } from "@utils/constants";
|
||||||
import definePlugin, { OptionType } from "@utils/types";
|
import definePlugin, { OptionType } from "@utils/types";
|
||||||
import { findStoreLazy } from "@webpack";
|
import { findStoreLazy } from "@webpack";
|
||||||
import { Constants, FluxDispatcher, GuildStore, RelationshipStore, RestAPI, SnowflakeUtils, UserStore } from "@webpack/common";
|
import { Constants, FluxDispatcher, GuildStore, RelationshipStore, SnowflakeUtils, UserStore } from "@webpack/common";
|
||||||
import { Settings } from "Vencord";
|
import { Settings } from "Vencord";
|
||||||
|
|
||||||
const UserAffinitiesStore = findStoreLazy("UserAffinitiesV2Store");
|
const UserAffinitiesStore = findStoreLazy("UserAffinitiesV2Store");
|
||||||
|
@ -121,19 +121,6 @@ export default definePlugin({
|
||||||
: comparator(row);
|
: comparator(row);
|
||||||
},
|
},
|
||||||
|
|
||||||
async refreshUserAffinities() {
|
|
||||||
try {
|
|
||||||
await RestAPI.get({ url: "/users/@me/affinities/users", retries: 3 }).then(({ body }) => {
|
|
||||||
FluxDispatcher.dispatch({
|
|
||||||
type: "LOAD_USER_AFFINITIES_SUCCESS",
|
|
||||||
affinities: body,
|
|
||||||
});
|
|
||||||
});
|
|
||||||
} catch (e) {
|
|
||||||
// Not a critical error if this fails for some reason
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
async fetchImplicitRelationships() {
|
async fetchImplicitRelationships() {
|
||||||
// Implicit relationships are defined as users that you:
|
// Implicit relationships are defined as users that you:
|
||||||
// 1. Have an affinity for
|
// 1. Have an affinity for
|
||||||
|
|
|
@ -69,7 +69,7 @@ function makeSearchItem(src: string) {
|
||||||
aria-hidden="true"
|
aria-hidden="true"
|
||||||
height={16}
|
height={16}
|
||||||
width={16}
|
width={16}
|
||||||
src={`https://www.google.com/s2/favicons?domain=${Engines[engine]}&sz=64`}
|
src={`https://icons.duckduckgo.com/ip3/${new URL(Engines[engine]).hostname}.ico`}
|
||||||
/>
|
/>
|
||||||
{engine}
|
{engine}
|
||||||
</Flex>
|
</Flex>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue