forked from FoundKeyGang/FoundKey
auto-fix lints with eslint
This commit is contained in:
parent
10e7e65279
commit
6c4655693e
3 changed files with 5 additions and 6 deletions
|
@ -134,8 +134,8 @@ function emojiSearch<Type>(src: Type[], max: number, query: string): Type[] {
|
|||
const match = (str: string): boolean => str && re.test(str);
|
||||
const matches = src.filter(emoji =>
|
||||
match(emoji.name)
|
||||
|| emoji.aliases?.some(match) // custom emoji
|
||||
|| emoji.keywords?.some(match) // unicode emoji
|
||||
|| emoji.aliases?.some(match) // custom emoji
|
||||
|| emoji.keywords?.some(match), // unicode emoji
|
||||
);
|
||||
// TODO: sort matches by distance to query
|
||||
if (max <= 0 || matches.length < max) return matches;
|
||||
|
@ -148,9 +148,9 @@ const queryCallback = (query) => {
|
|||
searchResultCustom.value = emojiSearch(instance.emojis, maxCustomEmojiPicker.value, query);
|
||||
searchResultUnicode.value = emojiSearch(emojilist, maxUnicodeEmojiPicker.value, query);
|
||||
queryTimeoutId = -1;
|
||||
}
|
||||
};
|
||||
watch(q, () => {
|
||||
if(queryTimeoutId >= 0) {
|
||||
if (queryTimeoutId >= 0) {
|
||||
clearTimeout(queryTimeoutId);
|
||||
queryTimeoutId = -1;
|
||||
}
|
||||
|
|
|
@ -21,7 +21,6 @@ const props = defineProps<{
|
|||
showing: boolean;
|
||||
}>();
|
||||
|
||||
|
||||
let top = $ref(0);
|
||||
let left = $ref(0);
|
||||
const zIndex = os.claimZIndex('middle');
|
||||
|
|
|
@ -65,7 +65,7 @@ const pagination = {
|
|||
limit: 10,
|
||||
offsetMode: true,
|
||||
params: computed(() => ({
|
||||
sort: sort,
|
||||
sort,
|
||||
host: host !== '' ? host : null,
|
||||
...(
|
||||
state === 'federating' ? { federating: true } :
|
||||
|
|
Loading…
Reference in a new issue