Skip to content

Private AI meeting notes that stay on your computer. No meeting bot. Free and open source for Mac, Windows and Linux. An alternative to Granola, Otter and Fireflies.

summary ring: the frame no longer shares the note pane's class, the writing label waits for text so it never sits beside the model download, and wheeling up stops following at once

Eric Brownrout37416fa9959e
diff --git a/app/src/renderer/src/components/NoteReadingPane.tsx b/app/src/renderer/src/components/NoteReadingPane.tsx
index 2ff419c9..706207b1 100644
--- a/app/src/renderer/src/components/NoteReadingPane.tsx
+++ b/app/src/renderer/src/components/NoteReadingPane.tsx
@@ -4,8 +4,8 @@ import { t } from '../../../shared/i18n'
import { useFollowLatest } from '../useFollowLatest'
import { ScrollFade } from './ScrollFade'
-export function NoteReadingPane({ active, summary, generating, scroll, children }: {
- active: boolean; summary: boolean; generating: boolean; scroll: RefObject<HTMLElement | null>; children: ReactNode
+export function NoteReadingPane({ active, summary, generating, writing, scroll, children }: {
+ active: boolean; summary: boolean; generating: boolean; writing: boolean; scroll: RefObject<HTMLElement | null>; children: ReactNode
}) {
const frame = useRef<HTMLDivElement>(null), content = useRef<HTMLDivElement>(null)
const [visible, setVisible] = useState(false)
@@ -19,14 +19,14 @@ export function NoteReadingPane({ active, summary, generating, scroll, children
return () => { observer.disconnect(); document.removeEventListener('visibilitychange', sync) }
}, [active, generating])
const follow = useFollowLatest(scroll, content, active && generating && visible)
- return <div ref={frame} className="note-reading-frame note-content" hidden={!active} data-generating={generating} data-active={active && generating && visible}>
+ return <div ref={frame} className="note-reading-frame" hidden={!active} data-generating={generating} data-active={active && generating && visible}>
<div className="note-reading-clip">
<ScrollFade enabled={active}><section ref={scroll} id="note-notes-panel" role="tabpanel" aria-labelledby={summary ? 'note-summary-tab' : 'note-notes-tab'} className="note-content note-notes-pane">
<div ref={content} className="note-page-width note-notes-body">{children}</div>
</section></ScrollFade>
</div>
<span className="ask-border note-summary-rim" data-testid="note-summary-rim" aria-hidden="true" />
- {generating && !follow.behind && <span className="note-summary-status" aria-hidden="true">{t('Generating notes…')}</span>}
+ {writing && !follow.behind && <span className="note-summary-status" aria-hidden="true">{t('Generating notes…')}</span>}
{follow.behind && <button type="button" className="note-latest" data-testid="note-summary-latest" onClick={follow.latest}><ArrowDown size={12} aria-hidden="true" />{t('Latest')}</button>}
</div>
}
diff --git a/app/src/renderer/src/followLatest.ts b/app/src/renderer/src/followLatest.ts
index 1e9248a8..13c2737d 100644
--- a/app/src/renderer/src/followLatest.ts
+++ b/app/src/renderer/src/followLatest.ts
@@ -19,6 +19,8 @@ export function attachFollowLatest(el: HTMLElement, body: HTMLElement, stuck: {
report()
}
const touch = () => { stop() }
+ // Wheeling up is a decision to read: stop following before the next resize can pull the pane back down.
+ const wheel = (event: Event) => { stop(); if ((event as WheelEvent).deltaY < 0) { stuck.current = false; report() } }
const key = (event: KeyboardEvent) => {
if (['ArrowUp', 'ArrowDown', 'PageUp', 'PageDown', 'Home', 'End', ' '].includes(event.key)) stop()
}
@@ -26,7 +28,8 @@ export function attachFollowLatest(el: HTMLElement, body: HTMLElement, stuck: {
const observer = new ResizeObserver(follow)
observer.observe(body); observer.observe(el)
el.addEventListener('scroll', scroll, { passive: true })
- for (const event of ['wheel', 'touchstart', 'pointerdown']) el.addEventListener(event, touch, { passive: true })
+ el.addEventListener('wheel', wheel, { passive: true })
+ for (const event of ['touchstart', 'pointerdown']) el.addEventListener(event, touch, { passive: true })
el.addEventListener('keydown', key)
document.addEventListener('visibilitychange', visibility)
follow()
@@ -41,7 +44,8 @@ export function attachFollowLatest(el: HTMLElement, body: HTMLElement, stuck: {
dispose() {
stop(); observer.disconnect()
el.removeEventListener('scroll', scroll)
- for (const event of ['wheel', 'touchstart', 'pointerdown']) el.removeEventListener(event, touch)
+ el.removeEventListener('wheel', wheel)
+ for (const event of ['touchstart', 'pointerdown']) el.removeEventListener(event, touch)
el.removeEventListener('keydown', key)
document.removeEventListener('visibilitychange', visibility)
},
diff --git a/app/src/renderer/src/screens/Note.tsx b/app/src/renderer/src/screens/Note.tsx
index 5c86d83e..b1c94064 100644
--- a/app/src/renderer/src/screens/Note.tsx
+++ b/app/src/renderer/src/screens/Note.tsx
@@ -378,7 +378,7 @@ export function Note({ id, onTitleChange, at, folderSuggestion, onSource }: {
</header>
<div ref={setChatAnchor} className="note-reading-area">
<div ref={panels} className="note-panels">
- <NoteReadingPane active={primary === 'notes'} summary={shown === 'enhanced'} generating={shown === 'enhanced' && (notes.status === 'waiting' || notes.status === 'writing')} scroll={readingScroll}>
+ <NoteReadingPane active={primary === 'notes'} summary={shown === 'enhanced'} generating={shown === 'enhanced' && (notes.status === 'waiting' || notes.status === 'writing')} writing={shown === 'enhanced' && notes.status === 'writing' && !!notes.draft} scroll={readingScroll}>
{shown === 'mine' ? <Editor
focus={primary === 'notes' && at?.ms === null ? at : undefined} testId="note-mine" label={t('My notes')} className="min-h-[40vh]" markdown={notes.mine} placeholder={t('Write notes here. Yogurt fills in the rest after the meeting.')}
onChange={(md) => { typing.current = true; const next = { ...current.current!, mine: md }; current.current = next; setNotes(next); mineSave.change(md) }}
diff --git a/app/src/renderer/src/workspace.css b/app/src/renderer/src/workspace.css
index ecce908e..df9c5855 100644
--- a/app/src/renderer/src/workspace.css
+++ b/app/src/renderer/src/workspace.css
@@ -575,7 +575,7 @@ body:has(.chat-panel[open]) .app-toast-viewport { inset-inline-end:460px; }
:root[data-chrome=overlay] .sidebar-collapsed .workspace-toolbar { padding-inline-start:24px; }
/* The frame preserves the note's existing text inset and 22px heading offset in every state. */
-.note-reading-frame { position:relative;min-width:0;margin:8px calc(max(0px,(100% - 860px)/2) + clamp(20px,calc(10cqw - 42px),48px) - 14px) 8px;padding:2px;border-radius:12px; }
+.note-reading-frame { position:relative;min-width:0;min-height:0;flex:1;margin:8px calc(max(0px,(100% - 860px)/2) + clamp(20px,calc(10cqw - 42px),48px) - 14px) 8px;padding:2px;border-radius:12px; }
.note-reading-frame[hidden] { display:none; }
.note-reading-frame[data-generating=true] { --ask-ring-opacity:1; }
.note-reading-frame[data-active=true] { --ask-ring-play:running; }
diff --git a/app/test/followLatest.test.ts b/app/test/followLatest.test.ts
index d7f8e1e0..fae136c3 100644
--- a/app/test/followLatest.test.ts
+++ b/app/test/followLatest.test.ts
@@ -41,6 +41,13 @@ it('shares resize-driven following, the 24px threshold and reading-earlier prese
expect(followGlide).not.toHaveBeenCalled()
follow.dispose()
})
+it('wheeling up stops following at once, so a resize before the scroll lands cannot pull the pane back down', () => {
+ const { pane, state, behind, follow } = setup()
+ pane.dispatchEvent(Object.assign(new Event('wheel'), { deltaY: -400 })); expect(state.current).toBe(false)
+ pane.scrollTop = 100; pane.scrollHeight = 1400; Resize.current.change(); expect(pane.scrollTop).toBe(100)
+ expect(behind).toHaveBeenLastCalledWith(true)
+ follow.dispose()
+})
it('keeps a remembered reading position rather than jumping on attachment', () => {
const { pane, follow } = setup(false)
expect(pane.scrollTop).toBe(0)