feat(video-card): add edit, versioning, and delete functionality with dialogs

- Implemented edit dialog for updating video title and description.
- Added functionality to create new video versions with URL validation.
- Included delete confirmation dialog for video removal.
- Enhanced UI with loading indicators and error handling.
- Updated video card layout for better user interaction.

feat(youtube): extend YT namespace with playback rate methods

- Added methods to set and get playback rate.
- Included method to retrieve available playback rates.
This commit is contained in:
Yusuf İpek
2026-02-07 08:17:25 +03:00
parent 6e95f667e3
commit 0228020041
13 changed files with 1982 additions and 704 deletions
@@ -46,9 +46,9 @@ export async function GET(request: NextRequest, { params }: RouteParams) {
// Check access
const isOwner = session?.user?.id === video.project.ownerId;
const isMember = video.project.members.length > 0;
const isPublicOrLink = video.project.visibility !== 'PRIVATE';
const isPublic = video.project.visibility === 'PUBLIC';
if (!isOwner && !isMember && !isPublicOrLink) {
if (!isOwner && !isMember && !isPublic) {
return NextResponse.json({ error: 'Access denied' }, { status: 403 });
}
@@ -27,9 +27,9 @@ export async function GET(request: NextRequest, { params }: RouteParams) {
const isOwner = session?.user?.id === video.project.ownerId;
const isMember = video.project.members.length > 0;
const isPublicOrLink = video.project.visibility !== 'PRIVATE';
const isPublic = video.project.visibility === 'PUBLIC';
if (!isOwner && !isMember && !isPublicOrLink) {
if (!isOwner && !isMember && !isPublic) {
return NextResponse.json({ error: 'Access denied' }, { status: 403 });
}
+2 -2
View File
@@ -24,9 +24,9 @@ export async function GET(request: NextRequest, { params }: RouteParams) {
const isOwner = session?.user?.id === project.ownerId;
const isMember = project.members.length > 0;
const isPublicOrLink = project.visibility !== 'PRIVATE';
const isPublic = project.visibility === 'PUBLIC';
if (!isOwner && !isMember && !isPublicOrLink) {
if (!isOwner && !isMember && !isPublic) {
return NextResponse.json({ error: 'Access denied' }, { status: 403 });
}