Skip to content

feat: add fullscreen video player#244

Merged
siddharthvaddem merged 2 commits intosiddharthvaddem:mainfrom
ateendra24:fix-issue-226
Mar 22, 2026
Merged

feat: add fullscreen video player#244
siddharthvaddem merged 2 commits intosiddharthvaddem:mainfrom
ateendra24:fix-issue-226

Conversation

@ateendra24
Copy link
Contributor

@ateendra24 ateendra24 commented Mar 22, 2026

Pull Request Template

Description

Added a fullscreen button and functionality to the video player preview in the video editor.

Motivation

This allows users to view their video preview in full screen, improving the editing experience.

Type of Change

  • New Feature
  • Bug Fix
  • Refactor / Code Cleanup
  • Documentation Update
  • Other (please specify)

Related Issue(s)

fixes #226

Screenshots / Video

Screenshot:

ss1 ss2

Video:

issue.226.mp4

Testing

  1. Open the video editor with a loaded video.
  2. Click the new fullscreen button on the playback controls.
  3. Verify the video preview goes into fullscreen mode and can be exited cleanly.

Checklist

  • I have performed a self-review of my code.
  • I have added any necessary screenshots or videos.
  • I have linked related issue(s) and updated the changelog if applicable.

Summary by CodeRabbit

  • New Features

    • Fullscreen mode for the video editor with a toggle in playback controls
    • Video preview expands to fill the screen and restores to panel view
    • Press Escape to exit fullscreen
    • Toggle button updates icon/label to reflect current state
  • Localization

    • Added translations for fullscreen/exit-fullscreen in English, Spanish, and Chinese

@coderabbitai
Copy link

coderabbitai bot commented Mar 22, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 8c4e924f-580c-427d-bfbf-59500d9a3d67

📥 Commits

Reviewing files that changed from the base of the PR and between 5d561ff and eae3f11.

📒 Files selected for processing (4)
  • src/components/video-editor/PlaybackControls.tsx
  • src/i18n/locales/en/common.json
  • src/i18n/locales/es/common.json
  • src/i18n/locales/zh-CN/common.json
✅ Files skipped from review due to trivial changes (3)
  • src/i18n/locales/es/common.json
  • src/i18n/locales/en/common.json
  • src/i18n/locales/zh-CN/common.json
🚧 Files skipped from review as they are similar to previous changes (1)
  • src/components/video-editor/PlaybackControls.tsx

📝 Walkthrough

Walkthrough

Adds fullscreen support: PlaybackControls gains optional fullscreen props and button; VideoEditor manages isFullscreen, toggles fullscreen, updates preview layout, and listens for Escape to exit fullscreen; i18n strings for fullscreen/exit added.

Changes

Cohort / File(s) Summary
PlaybackControls
src/components/video-editor/PlaybackControls.tsx
Added optional props isFullscreen?: boolean, onToggleFullscreen?: () => void; renders fullscreen toggle button when handler provided; imports Maximize/Minimize; aria-labels use t("playback.fullscreen") / t("playback.exitFullscreen").
VideoEditor
src/components/video-editor/VideoEditor.tsx
Introduced isFullscreen state and toggleFullscreen handler; wired onToggleFullscreen into PlaybackControls; conditional layout classes for fullscreen (fixed, inset-0, z-index, no rounded borders) vs normal panel; Escape key listener to exit fullscreen.
Localization
src/i18n/locales/en/common.json, src/i18n/locales/es/common.json, src/i18n/locales/zh-CN/common.json
Added playback.fullscreen and playback.exitFullscreen translations for English, Spanish, and Simplified Chinese.

Sequence Diagram(s)

sequenceDiagram
  participant User as User
  participant UI as PlaybackControls
  participant Editor as VideoEditor
  participant Window as Browser (Keyboard)

  User->>UI: Click fullscreen button
  UI->>Editor: onToggleFullscreen()
  Editor->>Editor: toggle isFullscreen state
  Editor->>Editor: apply fullscreen layout classes
  Window->>Editor: Press Escape
  Editor->>Editor: set isFullscreen = false
  Editor->>UI: pass isFullscreen (update icon/aria)
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

Poem

🐰 I hopped on screen to stretch so wide,
A toggle button led me to glide.
Maximize the view, then Escape to flee,
A rabbit’s cheer for editing glee!

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely describes the main feature addition—fullscreen functionality for the video player.
Description check ✅ Passed The PR description follows the template with all essential sections: description, motivation, type of change, related issue, screenshots, testing steps, and checklist.
Linked Issues check ✅ Passed The PR fully addresses issue #226 by implementing a fullscreen button in the playback controls and handling fullscreen state management.
Out of Scope Changes check ✅ Passed All changes directly support the fullscreen feature: PlaybackControls enhancements, VideoEditor fullscreen state, and i18n strings for UI labels.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands and usage tips.

Tip

You can make CodeRabbit's review stricter and more nitpicky using the `assertive` profile, if that's what you prefer.

Change the reviews.profile setting to assertive to make CodeRabbit's nitpick more issues in your PRs.

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5d561ff06f

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@src/components/video-editor/PlaybackControls.tsx`:
- Around line 94-108: PlaybackControls.tsx uses aria-labels
t("playback.fullscreen") and t("playback.exitFullscreen") which are missing from
the locales and will render the keys literally; add "fullscreen" and
"exitFullscreen" under the "playback" object in your locale file (e.g.,
common.json alongside "play" and "pause") so translations are available, and
update the JSX for the Maximize and Minimize icons in PlaybackControls (the
<Maximize> and <Minimize> elements) to remove the ineffective "fill-current"
class since lucide-react icons are stroke-based.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 5e1b4820-66cd-4a3a-a3c6-f56050ef664d

📥 Commits

Reviewing files that changed from the base of the PR and between a8bb0e8 and 5d561ff.

📒 Files selected for processing (2)
  • src/components/video-editor/PlaybackControls.tsx
  • src/components/video-editor/VideoEditor.tsx

…ommon terms in English, Spanish, and Chinese.
@siddharthvaddem siddharthvaddem merged commit e35780b into siddharthvaddem:main Mar 22, 2026
5 checks passed
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.

[Feature]: Allow video fullscreen during video editing

2 participants