The all-in-one local AI studio for your desktop: chat, image and video generation and a coding agent in one free, open source app. Windows and Linux. No Docker, no terminal, no cloud required.
TypeScript agentai-chatai-studioall-in-onecoding-agentdesktop-appfluximage-generationlinuxllmlocal-ailocal-llmopen-sourceprivacyself-hostedstable-diffusionuncensoreduncensored-aivideo-generationwindows
fix(release-notes): wait while a Hugging Face link is open
purple1b315ef95b43
diff --git a/src/components/release/ReleaseNotesModal.tsx b/src/components/release/ReleaseNotesModal.tsxindex 0cc2c19e..748cb6e4 100644--- a/src/components/release/ReleaseNotesModal.tsx+++ b/src/components/release/ReleaseNotesModal.tsx@@ -35,6 +35,7 @@ import { useSettingsStore } from '../../stores/settingsStore'import { useUIStore } from '../../stores/uiStore'import { useCloudAuthStore, deriveCloudAvailable } from '../../stores/cloudAuthStore'import { useReleaseNotesStore, shouldShowReleaseNotes } from '../../stores/releaseNotesStore'+import { useHfLinkStore } from '../../stores/hfLinkStore'import { releaseNoteFor, itemDetail, itemTitle, type ReleaseNote, type ReleaseNoteItem } from '../../lib/release-notes'export function ReleaseNotesModal() {@@ -46,7 +47,11 @@ export function ReleaseNotesModal() {const setCloudGateOpen = useUIStore((s) => s.setCloudGateOpen)const cloudAvailable = useCloudAuthStore(deriveCloudAvailable)- const open = reopened || shouldShowReleaseNotes(currentVersion, lastNotesVersion, onboardingDone)+ // A Hugging Face link the user just clicked comes first: the sheet waits+ // until its question is answered instead of covering it (P9, Mac test of+ // 3.0.9: the first start after an update put the sheet on top of it).+ const hfLinkOpen = useHfLinkStore((s) => s.pending !== null || s.rejected !== null)+ const open = !hfLinkOpen && (reopened || shouldShowReleaseNotes(currentVersion, lastNotesVersion, onboardingDone))const note = releaseNoteFor(currentVersion)const close = () => markNotesSeen(currentVersion)diff --git a/src/components/release/__tests__/release-notes-modal.test.tsx b/src/components/release/__tests__/release-notes-modal.test.tsxindex 5a6b99b4..1a714327 100644--- a/src/components/release/__tests__/release-notes-modal.test.tsx+++ b/src/components/release/__tests__/release-notes-modal.test.tsx@@ -30,11 +30,12 @@ import { readFileSync } from 'node:fs'import { resolve, dirname } from 'node:path'import { fileURLToPath } from 'node:url'import { beforeEach, describe, expect, it, vi } from 'vitest'-import { cleanup, fireEvent, render, screen, waitFor } from '@testing-library/react'+import { act, cleanup, fireEvent, render, screen, waitFor } from '@testing-library/react'import { ReleaseNoteBody, ReleaseNotesModal } from '../ReleaseNotesModal'import { MONOGRAM } from '../../layout/brand'import { useReleaseNotesStore } from '../../../stores/releaseNotesStore'import { useSettingsStore } from '../../../stores/settingsStore'+import { useHfLinkStore } from '../../../stores/hfLinkStore'import type { ReleaseNote } from '../../../lib/release-notes'const SRC = readFileSync(@@ -231,6 +232,17 @@ describe('the wired-up sheet, end to end', () => {cleanup()useReleaseNotesStore.setState({ lastNotesVersion: null })useSettingsStore.setState((s) => ({ settings: { ...s.settings, onboardingDone: true } }))+ useHfLinkStore.getState().clear()+ })++ // P9 (3.0.9), found on the Mac: a Hugging Face link that started the app+ // after an update had its download question hidden under this sheet.+ it('waits while a Hugging Face link is being asked about, and opens after', async () => {+ useHfLinkStore.getState().offer({ repo: 'a/b', file: 'm.gguf' }, false)+ render(<ReleaseNotesModal />)+ expect(screen.queryByTestId('release-heading')).toBeNull()+ act(() => useHfLinkStore.getState().clear())+ await waitFor(() => expect(screen.getByTestId('release-heading')).toBeTruthy())})it('opens for the shipping version and Escape closes it, stamping the version so it does not return', async () => {