mirror of
https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
synced 2025-05-30 01:20:22 +09:00
Merge branch 'Yidadaa:main' into main
This commit is contained in:
commit
e95242adde
@ -393,11 +393,13 @@ export function MaskPage() {
|
||||
const [searchText, setSearchText] = useState("");
|
||||
const masks = searchText.length > 0 ? searchMasks : allMasks;
|
||||
|
||||
// simple search, will refactor later
|
||||
// refactored already, now it accurate
|
||||
const onSearch = (text: string) => {
|
||||
setSearchText(text);
|
||||
if (text.length > 0) {
|
||||
const result = allMasks.filter((m) => m.name.includes(text));
|
||||
const result = allMasks.filter((m) =>
|
||||
m.name.toLowerCase().includes(text.toLowerCase())
|
||||
);
|
||||
setSearchMasks(result);
|
||||
} else {
|
||||
setSearchMasks(allMasks);
|
||||
|
@ -101,7 +101,7 @@ export const useSyncStore = createPersistStore(
|
||||
mergeAppState(localState, remoteState);
|
||||
setLocalAppState(localState);
|
||||
} catch (e) {
|
||||
console.log("[Sync] failed to get remoate state", e);
|
||||
console.log("[Sync] failed to get remote state", e);
|
||||
}
|
||||
|
||||
await client.set(config.username, JSON.stringify(localState));
|
||||
|
Loading…
Reference in New Issue
Block a user