mirror of
https://github.com/yusufipk/OpenFrame.git
synced 2026-09-11 17:46:06 +00:00
- Added support for self-hosted S3 video uploads with new environment variables: OPENFRAME_ENABLE_S3_VIDEO_UPLOADS and OPENFRAME_MAX_VIDEO_UPLOAD_BYTES. - Updated .env.example and .env.docker.example to reflect new configuration options. - Enhanced Content Security Policy to include origins for S3-compatible storage. - Updated dependencies for AWS SDK to support new features. - Refactored upload logic to accommodate both Bunny and S3 upload providers. - Updated documentation to clarify the usage of direct uploads and S3 configurations. - Closes #11
53 lines
1.3 KiB
TypeScript
53 lines
1.3 KiB
TypeScript
'use client';
|
|
|
|
import { ProjectFilter } from './project-filter';
|
|
import { VideoDragDropUploader } from '@/components/video-drag-drop-uploader';
|
|
import type { DirectUploadProvider } from '@/components/video-page/types';
|
|
|
|
interface SerializedProject {
|
|
id: string;
|
|
name: string;
|
|
description: string | null;
|
|
visibility: string;
|
|
updatedAt: string;
|
|
workspaceId: string | null;
|
|
workspaceName: string | null;
|
|
memberCount: number;
|
|
videoCount: number;
|
|
}
|
|
|
|
interface DashboardClientProps {
|
|
serializedProjects: SerializedProject[];
|
|
workspaces: { id: string; name: string }[];
|
|
totalPages: number;
|
|
canCreateProjects: boolean;
|
|
canUploadVideos: boolean;
|
|
directUploadsEnabled: boolean;
|
|
directUploadProvider: DirectUploadProvider;
|
|
}
|
|
|
|
export function DashboardClient({
|
|
serializedProjects,
|
|
workspaces,
|
|
totalPages,
|
|
canCreateProjects,
|
|
canUploadVideos,
|
|
directUploadsEnabled,
|
|
directUploadProvider,
|
|
}: DashboardClientProps) {
|
|
return (
|
|
<div className="px-6 lg:px-8 py-8 w-full">
|
|
<VideoDragDropUploader
|
|
canUpload={canUploadVideos && directUploadsEnabled}
|
|
directUploadProvider={directUploadProvider}
|
|
/>
|
|
<ProjectFilter
|
|
projects={serializedProjects}
|
|
workspaces={workspaces}
|
|
totalPages={totalPages}
|
|
canCreateProjects={canCreateProjects}
|
|
/>
|
|
</div>
|
|
);
|
|
}
|