Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
actions-user committed Feb 3, 2024
2 parents b787a38 + 4511aa4 commit 9cc3aaa
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 6 deletions.
2 changes: 1 addition & 1 deletion app/components/emoji.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export function getEmojiUrl(unified: string, style: EmojiStyle) {
// Whoever owns this Content Delivery Network (CDN), I am using your CDN to serve emojis
// Old CDN broken, so I had to switch to this one
// Author: https://github.com/H0llyW00dzZ
return `https://cdn.jsdelivr.net/npm/emoji-datasource-apple/img/${style}/64/${unified}.png`;
return `https://fastly.jsdelivr.net/npm/emoji-datasource-apple/img/${style}/64/${unified}.png`;
}

export function AvatarPicker(props: {
Expand Down
4 changes: 2 additions & 2 deletions app/components/settings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ function CheckButton() {
const syncStore = useSyncStore();

const couldCheck = useMemo(() => {
return syncStore.coundSync();
return syncStore.cloudSync();
}, [syncStore]);

const [checkState, setCheckState] = useState<
Expand Down Expand Up @@ -472,7 +472,7 @@ function SyncItems() {
const promptStore = usePromptStore();
const maskStore = useMaskStore();
const couldSync = useMemo(() => {
return syncStore.coundSync();
return syncStore.cloudSync();
}, [syncStore]);

const [showSyncConfigModal, setShowSyncConfigModal] = useState(false);
Expand Down
9 changes: 9 additions & 0 deletions app/constant.ts
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,15 @@ export const DEFAULT_MODELS = [
providerType: "openai",
},
},
{
name: "gpt-3.5-turbo-0125",
available: true,
provider: {
id: "openai",
providerName: "OpenAI",
providerType: "openai",
},
},
{
name: "gpt-3.5-turbo-0301",
available: true,
Expand Down
8 changes: 5 additions & 3 deletions app/store/sync.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ const DEFAULT_SYNC_STATE = {
export const useSyncStore = createPersistStore(
DEFAULT_SYNC_STATE,
(set, get) => ({
coundSync() {
cloudSync() {
const config = get()[get().provider];
return Object.values(config).every((c) => c.toString().length > 0);
},
Expand All @@ -60,8 +60,10 @@ export const useSyncStore = createPersistStore(
export() {
const state = getLocalAppState();
const datePart = isApp
? `${new Date().toLocaleDateString().replace(/\//g, '_')} ${new Date().toLocaleTimeString().replace(/:/g, '_')}`
: new Date().toLocaleString();
? `${new Date().toLocaleDateString().replace(/\//g, "_")} ${new Date()
.toLocaleTimeString()
.replace(/:/g, "_")}`
: new Date().toLocaleString();

const fileName = `Backup-${datePart}.json`;
downloadAs(JSON.stringify(state), fileName);
Expand Down

0 comments on commit 9cc3aaa

Please sign in to comment.