Skip to content

Conversation

@google-labs-jules
Copy link
Contributor

@google-labs-jules google-labs-jules bot commented Jan 15, 2026

Implemented a feature to allow users to add custom notes (not tied to a transcript selection) and capture the current video timestamp. This includes:

  1. Frontend Logic: Added handleAddNote callback in app/analyze/[videoId]/page.tsx to initialize a new "custom" note state.
  2. UI Updates: Modified NotesPanel to show an "Add a note" button. Modified NoteEditor to support editing notes without a selected snippet, and added a "Capture Timestamp" button that grabs the current video time.
  3. Prop Drilling: Ensured onAddNote and currentTime are passed down through RightColumnTabs to NotesPanel and NoteEditor.
  4. Metadata Handling: Updated handleSaveEditingNote to correctly merge metadata (including captured timestamps) when saving notes.

PR created automatically by Jules for task 29302733776464536 started by @SamuelZ12


Note

Introduces standalone note creation and timestamp capture with end-to-end wiring and metadata handling.

  • Adds handleAddNote in app/analyze/[videoId]/page.tsx and passes onAddNote through RightColumnTabsNotesPanelNoteEditor
  • Extends NoteEditor to work without a selected snippet, capture currentTime via "Capture Timestamp", and include it in metadata
  • Updates NotesPanel to show an "Add Note" button when empty and a top-level "Add Note" action; makes timestampLabel clickable (seeks via onTimestampClick)
  • Changes onSaveEditingNote payloads to include optional metadata; handleSaveEditingNote merges provided metadata (including timestamps) with existing note metadata
  • Minor UI tweaks: conditional quote section, button styles, and icons (e.g., Plus, Clock)

Written by Cursor Bugbot for commit 35a653f. This will update automatically on new commits. Configure here.

- Implement `handleAddNote` in `AnalyzePage` to support creating notes without transcript selection.
- Update `NotesPanel` to display "Add a note" button in empty/top states.
- Update `NoteEditor` to support custom notes (no snippet) and "Capture Timestamp" functionality.
- Ensure `RightColumnTabs` passes `onAddNote` prop correctly.
- Allow capturing current timestamp for any note type.
@google-labs-jules
Copy link
Contributor Author

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

@vercel
Copy link

vercel bot commented Jan 15, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
tldw Ready Ready Preview, Comment Jan 15, 2026 1:24am

@SamuelZ12 SamuelZ12 temporarily deployed to feature-add-notes-timestamp-29302733776464536 - longcut PR #54 January 15, 2026 01:23 — with Render Destroyed
@supabase
Copy link

supabase bot commented Jan 15, 2026

This pull request has been ignored for the connected project ioczjdqhdcjmrnsicqqz because there are no changes detected in supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@SamuelZ12 SamuelZ12 marked this pull request as ready for review January 16, 2026 17:02
Copilot AI review requested due to automatic review settings January 16, 2026 17:02
@SamuelZ12 SamuelZ12 merged commit fd8986d into main Jan 16, 2026
5 of 6 checks passed
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR implements a feature allowing users to create custom notes (not tied to transcript selections) and capture video timestamps. The changes enable users to add standalone notes with an optional timestamp reference to the video playback position.

Changes:

  • Added handleAddNote callback to initialize custom note state with empty text
  • Updated UI components to display "Add a note" button in the notes panel
  • Modified NoteEditor to support notes without selected snippets and added timestamp capture functionality

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
dev.log Development log file added (should be gitignored)
components/right-column-tabs.tsx Added onAddNote prop and updated onSaveEditingNote signature to accept metadata
components/notes-panel.tsx Added "Add a note" button UI and timestamp click handling for custom notes
components/note-editor.tsx Enhanced to support custom notes without snippets and added timestamp capture button
app/analyze/[videoId]/page.tsx Implemented handleAddNote and updated handleSaveEditingNote to merge metadata including captured timestamps

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

onSave: (payload: { noteText: string; selectedText: string }) => void;
currentTime?: number;
onSave: (payload: { noteText: string; selectedText: string; metadata?: NoteMetadata }) => void;
onCancel: () => void;
Copy link

Copilot AI Jan 16, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The onCancel prop is defined in the interface but never used in the component. This means users cannot cancel note editing, which is a critical UX issue. The component should include a Cancel button that calls onCancel.

Copilot uses AI. Check for mistakes.
}
};

const hasQuote = quoteText.length > 0;
Copy link

Copilot AI Jan 16, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The variable name 'hasQuote' is confusing when used for custom notes without selected text. Consider renaming to 'hasSelectedText' or 'hasSnippet' to better reflect its purpose across both use cases.

Copilot uses AI. Check for mistakes.
Comment on lines +63 to +72
if (capturedTimestamp !== null) {
finalMetadata = {
...(finalMetadata || {}),
transcript: {
...(finalMetadata?.transcript || {}),
start: capturedTimestamp,
},
timestampLabel: formatDuration(capturedTimestamp),
};
}
Copy link

Copilot AI Jan 16, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When capturing a timestamp, the code overwrites any existing transcript metadata except for the 'start' field. If the original metadata has 'end', 'segmentIndex', or 'topicId' fields, they will be preserved via the spread. However, capturing a new timestamp on a note that already has transcript metadata may create inconsistent state (e.g., a note with start from timestamp capture but end/segmentIndex from the original selection). Consider whether to preserve or clear other transcript fields when capturing a new timestamp.

Copilot uses AI. Check for mistakes.
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 2 potential issues.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

This is the final PR Bugbot will review for you during this billing cycle

Your free Bugbot reviews will reset on February 7

Details

You are on the Bugbot Free tier. On this plan, Bugbot will review limited PRs each billing cycle.

To receive Bugbot reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial.

Auth token refresh failed: Auth session missing!
GET /api/csrf-token 401 in 385ms
Auth token refresh failed: Auth session missing!
POST /api/update-video-analysis 401 in 356ms
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Development server log file accidentally committed

Medium Severity

A dev.log file containing 816 lines of Next.js development server output was committed to the repository. It includes internal server logs, authentication errors, stack traces with file paths, rate limiter errors, and other debug information that exposes internal system details and clutters the codebase.

Fix in Cursor Fix in Web

: {
...(editingNote.metadata ?? {}),
...(metadata ?? {})
};
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Metadata spread order overwrites edited selected text

High Severity

When merging metadata in handleSaveEditingNote, the ...(metadata ?? {}) spread is placed after selectedText: normalizedSelected. Since metadata comes from NoteEditor and contains a copy of editingNote.metadata (which already has selectedText from selection-actions.tsx line 165), the original selectedText overwrites any user edits. If a user modifies the quote text in the editor before saving, their changes are silently lost.

Fix in Cursor Fix in Web

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant