repo
stringlengths
7
64
file_url
stringlengths
81
338
file_path
stringlengths
5
257
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 15:25:31
2026-01-05 01:50:38
truncated
bool
2 classes
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/editor/timeline/index.tsx
apps/web/src/components/editor/timeline/index.tsx
"use client"; import { ScrollArea } from "@/components/ui/scroll-area"; import { Button } from "../../ui/button"; import { Scissors, ArrowLeftToLine, ArrowRightToLine, Trash2, Snowflake, Copy, SplitSquareHorizontal, Pause, Play, SkipBack, Video, Music, TypeIcon, Magnet, Link, ZoomIn, ...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/editor/timeline/timeline-toolbar.tsx
apps/web/src/components/editor/timeline/timeline-toolbar.tsx
import { usePlaybackStore } from "@/stores/playback-store"; import { useProjectStore } from "@/stores/project-store"; import { useTimelineStore } from "@/stores/timeline-store"; import { useSceneStore } from "@/stores/scene-store"; import { toast } from "sonner"; import { TooltipProvider, Tooltip, TooltipTrigger,...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/editor/timeline/timeline-cache-indicator.tsx
apps/web/src/components/editor/timeline/timeline-cache-indicator.tsx
"use client"; import { cn } from "@/lib/utils"; import { TIMELINE_CONSTANTS } from "@/constants/timeline-constants"; import { TimelineTrack } from "@/types/timeline"; import { MediaFile } from "@/types/media"; import { TProject } from "@/types/project"; import { useSceneStore } from "@/stores/scene-store"; interface ...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/editor/timeline/timeline-playhead.tsx
apps/web/src/components/editor/timeline/timeline-playhead.tsx
"use client"; import { useRef, useState, useEffect } from "react"; import { TimelineTrack } from "@/types/timeline"; import { TIMELINE_CONSTANTS } from "@/constants/timeline-constants"; import { useTimelinePlayhead } from "@/hooks/use-timeline-playhead"; interface TimelinePlayheadProps { currentTime: number; dura...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/providers/editor-provider.tsx
apps/web/src/components/providers/editor-provider.tsx
"use client"; import { useEffect } from "react"; import { Loader2 } from "lucide-react"; import { useEditorStore } from "@/stores/editor-store"; import { useKeybindingsListener, useKeybindingDisabler, } from "@/hooks/use-keybindings"; import { useEditorActions } from "@/hooks/use-editor-actions"; interface Editor...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/providers/migrators/scenes-migrator.tsx
apps/web/src/components/providers/migrators/scenes-migrator.tsx
"use client"; import { useEffect, useState } from "react"; import { usePathname } from "next/navigation"; import { storageService } from "@/lib/storage/storage-service"; import { TProject, Scene } from "@/types/project"; import { generateUUID } from "@/lib/utils"; import { Dialog, DialogContent, DialogDescriptio...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/sonner.tsx
apps/web/src/components/ui/sonner.tsx
"use client"; import { useTheme } from "next-themes"; import { Toaster as Sonner } from "sonner"; type ToasterProps = React.ComponentProps<typeof Sonner>; const Toaster = ({ ...props }: ToasterProps) => { const { theme = "system" } = useTheme(); return ( <Sonner theme={theme as ToasterProps["theme"]} ...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/table.tsx
apps/web/src/components/ui/table.tsx
import * as React from "react"; import { cn } from "../../lib/utils"; const Table = React.forwardRef< HTMLTableElement, React.HTMLAttributes<HTMLTableElement> >(({ className, ...props }, ref) => ( <div className="relative w-full overflow-auto"> <table ref={ref} className={cn("w-full caption-bott...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/form.tsx
apps/web/src/components/ui/form.tsx
"use client"; import * as React from "react"; import { Label as LabelPrimitive, Slot as SlotPrimitive } from "radix-ui"; import { Controller, ControllerProps, FieldPath, FieldValues, FormProvider, useFormContext, } from "react-hook-form"; import { cn } from "../../lib/utils"; import { Label } from "./lab...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/toaster.tsx
apps/web/src/components/ui/toaster.tsx
"use client"; import { useToast } from "../../hooks/use-toast"; import { Toast, ToastClose, ToastDescription, ToastProvider, ToastTitle, ToastViewport, } from "./toast"; export function Toaster() { const { toasts } = useToast(); return ( <ToastProvider> {toasts.map(({ id, title, description...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/collapsible.tsx
apps/web/src/components/ui/collapsible.tsx
"use client"; import { Collapsible as CollapsiblePrimitive } from "radix-ui"; const Collapsible = CollapsiblePrimitive.Root; const CollapsibleTrigger = CollapsiblePrimitive.CollapsibleTrigger; const CollapsibleContent = CollapsiblePrimitive.CollapsibleContent; export { Collapsible, CollapsibleTrigger, CollapsibleC...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/avatar.tsx
apps/web/src/components/ui/avatar.tsx
"use client"; import * as React from "react"; import { Avatar as AvatarPrimitive } from "radix-ui"; import { cn } from "../../lib/utils"; const Avatar = React.forwardRef< React.ElementRef<typeof AvatarPrimitive.Root>, React.ComponentPropsWithoutRef<typeof AvatarPrimitive.Root> >(({ className, ...props }, ref) =>...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/aspect-ratio.tsx
apps/web/src/components/ui/aspect-ratio.tsx
"use client"; import { AspectRatio as AspectRatioPrimitive } from "radix-ui"; const AspectRatio = AspectRatioPrimitive.Root; export { AspectRatio };
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/navigation-menu.tsx
apps/web/src/components/ui/navigation-menu.tsx
import * as React from "react"; import { NavigationMenu as NavigationMenuPrimitive } from "radix-ui"; import { cva } from "class-variance-authority"; import { ChevronDown } from "lucide-react"; import { cn } from "../../lib/utils"; const NavigationMenu = React.forwardRef< React.ElementRef<typeof NavigationMenuPrimi...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/progress.tsx
apps/web/src/components/ui/progress.tsx
"use client"; import * as React from "react"; import { Progress as ProgressPrimitive } from "radix-ui"; import { cn } from "../../lib/utils"; const Progress = React.forwardRef< React.ElementRef<typeof ProgressPrimitive.Root>, React.ComponentPropsWithoutRef<typeof ProgressPrimitive.Root> >(({ className, value, .....
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/color-picker.tsx
apps/web/src/components/ui/color-picker.tsx
import * as React from "react"; import { createPortal } from "react-dom"; import { cn } from "../../lib/utils"; import { Input } from "./input"; interface ColorPickerProps { value?: string; onChange?: (value: string) => void; className?: string; containerRef?: React.RefObject<HTMLDivElement>; } const hexToHsv...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/toast.tsx
apps/web/src/components/ui/toast.tsx
"use client"; import * as React from "react"; import { Toast as ToastPrimitives } from "radix-ui"; import { cva, type VariantProps } from "class-variance-authority"; import { X } from "lucide-react"; import { cn } from "../../lib/utils"; const ToastProvider = ToastPrimitives.Provider; const ToastViewport = React.fo...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/menubar.tsx
apps/web/src/components/ui/menubar.tsx
"use client"; import * as React from "react"; import { Menubar as MenubarPrimitive } from "radix-ui"; import { Check, ChevronRight, Circle } from "lucide-react"; import { cn } from "../../lib/utils"; const MenubarMenu = MenubarPrimitive.Menu; const MenubarGroup = MenubarPrimitive.Group; const MenubarPortal = Menub...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/breadcrumb.tsx
apps/web/src/components/ui/breadcrumb.tsx
import * as React from "react"; import { Slot as SlotPrimitive } from "radix-ui"; import { ChevronRight, MoreHorizontal } from "lucide-react"; import { cn } from "../../lib/utils"; const Breadcrumb = React.forwardRef< HTMLElement, React.ComponentPropsWithoutRef<"nav"> & { separator?: React.ReactNode; } >(({...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/dialog.tsx
apps/web/src/components/ui/dialog.tsx
"use client"; import * as React from "react"; import { Dialog as DialogPrimitive } from "radix-ui"; import { X } from "lucide-react"; import { cn } from "../../lib/utils"; import { ScrollArea } from "./scroll-area"; const Dialog = DialogPrimitive.Root; const DialogTrigger = DialogPrimitive.Trigger; const DialogPor...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/label.tsx
apps/web/src/components/ui/label.tsx
"use client"; import * as React from "react"; import { Label as LabelPrimitive } from "radix-ui"; import { cva, type VariantProps } from "class-variance-authority"; import { cn } from "../../lib/utils"; const labelVariants = cva( "text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opac...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/drawer.tsx
apps/web/src/components/ui/drawer.tsx
"use client"; import * as React from "react"; import { Drawer as DrawerPrimitive } from "vaul"; import { cn } from "../../lib/utils"; const Drawer = ({ shouldScaleBackground = true, ...props }: React.ComponentProps<typeof DrawerPrimitive.Root>) => ( <DrawerPrimitive.Root shouldScaleBackground={shouldScaleB...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/toggle.tsx
apps/web/src/components/ui/toggle.tsx
"use client"; import * as React from "react"; import { Toggle as TogglePrimitive } from "radix-ui"; import { cva, type VariantProps } from "class-variance-authority"; import { cn } from "../../lib/utils"; const toggleVariants = cva( "inline-flex items-center justify-center gap-2 rounded-md text-sm font-medium tran...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/tabs.tsx
apps/web/src/components/ui/tabs.tsx
"use client"; import * as React from "react"; import { Tabs as TabsPrimitive } from "radix-ui"; import { cn } from "../../lib/utils"; const Tabs = TabsPrimitive.Root; const TabsList = React.forwardRef< React.ElementRef<typeof TabsPrimitive.List>, React.ComponentPropsWithoutRef<typeof TabsPrimitive.List> >(({ cl...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/button.tsx
apps/web/src/components/ui/button.tsx
import * as React from "react"; import { Slot as SlotPrimitive } from "radix-ui"; import { cva, type VariantProps } from "class-variance-authority"; import { cn } from "../../lib/utils"; const buttonVariants = cva( "inline-flex items-center cursor-pointer justify-center gap-2 whitespace-nowrap rounded-md text-sm fo...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/phone-input.tsx
apps/web/src/components/ui/phone-input.tsx
import * as React from "react"; import { CheckIcon, ChevronsUpDown } from "lucide-react"; import * as RPNInput from "react-phone-number-input"; import flags from "react-phone-number-input/flags"; import { Button } from "./button"; import { Command, CommandEmpty, CommandGroup, CommandInput, CommandItem, Com...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/sidebar.tsx
apps/web/src/components/ui/sidebar.tsx
"use client"; import * as React from "react"; import { Slot as SlotPrimitive } from "radix-ui"; import { VariantProps, cva } from "class-variance-authority"; import { PanelLeft } from "lucide-react"; import { useIsMobile } from "../../hooks/use-mobile"; import { cn } from "../../lib/utils"; import { Button } from "./...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/prose.tsx
apps/web/src/components/ui/prose.tsx
import { cn } from "@/lib/utils"; import type React from "react"; type ProseProps = React.HTMLAttributes<HTMLElement> & { as?: "article"; html: string; }; function Prose({ children, html, className }: ProseProps) { return ( <article className={cn( "prose prose-h2:font-semibold max-w-none prose...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/popover.tsx
apps/web/src/components/ui/popover.tsx
"use client"; import * as React from "react"; import { Popover as PopoverPrimitive } from "radix-ui"; import { cn } from "../../lib/utils"; const Popover = PopoverPrimitive.Root; const PopoverTrigger = PopoverPrimitive.Trigger; const PopoverAnchor = PopoverPrimitive.Anchor; const PopoverContent = React.forwardRef...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/sponsor-button.tsx
apps/web/src/components/ui/sponsor-button.tsx
import { motion } from "motion/react"; import { ComponentType } from "react"; interface SponsorButtonProps { href: string; logo: ComponentType<{ className?: string }>; companyName: string; className?: string; } export function SponsorButton({ href, logo: Logo, companyName, className = "", }: SponsorBu...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/textarea.tsx
apps/web/src/components/ui/textarea.tsx
import * as React from "react"; import { cn } from "../../lib/utils"; const Textarea = React.forwardRef< HTMLTextAreaElement, React.ComponentProps<"textarea"> >(({ className, ...props }, ref) => { return ( <textarea className={cn( "file:text-foreground placeholder:text-muted-foreground selecti...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/input-with-back.tsx
apps/web/src/components/ui/input-with-back.tsx
"use client"; import { Button } from "@/components/ui/button"; import { Input } from "@/components/ui/input"; import { ArrowLeft, Search } from "lucide-react"; import { motion } from "motion/react"; import { useState, useEffect } from "react"; interface InputWithBackProps { isExpanded: boolean; setIsExpanded: (is...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/resizable.tsx
apps/web/src/components/ui/resizable.tsx
"use client"; import * as ResizablePrimitive from "react-resizable-panels"; import { cn } from "../../lib/utils"; const ResizablePanelGroup = ({ className, ...props }: React.ComponentProps<typeof ResizablePrimitive.PanelGroup>) => ( <ResizablePrimitive.PanelGroup className={cn( "flex h-full w-full da...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/accordion.tsx
apps/web/src/components/ui/accordion.tsx
"use client"; import * as React from "react"; import { Accordion as AccordionPrimitive } from "radix-ui"; import { ChevronDown } from "lucide-react"; import { cn } from "../../lib/utils"; const Accordion = AccordionPrimitive.Root; const AccordionItem = React.forwardRef< React.ElementRef<typeof AccordionPrimitive....
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/dropdown-menu.tsx
apps/web/src/components/ui/dropdown-menu.tsx
"use client"; import * as React from "react"; import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui"; import { Check, ChevronRight, Circle } from "lucide-react"; import { cva, type VariantProps } from "class-variance-authority"; import { cn } from "../../lib/utils"; const DropdownMenu = DropdownMenuPrimiti...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/switch.tsx
apps/web/src/components/ui/switch.tsx
"use client"; import * as React from "react"; import { Switch as SwitchPrimitives } from "radix-ui"; import { cn } from "../../lib/utils"; const Switch = React.forwardRef< React.ElementRef<typeof SwitchPrimitives.Root>, React.ComponentPropsWithoutRef<typeof SwitchPrimitives.Root> >(({ className, ...props }, ref)...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/slider.tsx
apps/web/src/components/ui/slider.tsx
"use client"; import * as React from "react"; import { Slider as SliderPrimitive } from "radix-ui"; import { cn } from "../../lib/utils"; const Slider = React.forwardRef< React.ElementRef<typeof SliderPrimitive.Root>, React.ComponentPropsWithoutRef<typeof SliderPrimitive.Root> >(({ className, ...props }, ref) =>...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/carousel.tsx
apps/web/src/components/ui/carousel.tsx
"use client"; import * as React from "react"; import useEmblaCarousel, { type UseEmblaCarouselType, } from "embla-carousel-react"; import { ArrowLeft, ArrowRight } from "lucide-react"; import { cn } from "../../lib/utils"; import { Button } from "./button"; type CarouselApi = UseEmblaCarouselType[1]; type UseCarou...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/separator.tsx
apps/web/src/components/ui/separator.tsx
"use client"; import * as React from "react"; import * as SeparatorPrimitive from "@radix-ui/react-separator"; import { cn } from "@/lib/utils"; const Separator = React.forwardRef< React.ElementRef<typeof SeparatorPrimitive.Root>, React.ComponentPropsWithoutRef<typeof SeparatorPrimitive.Root> >( ( { classN...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/sheet.tsx
apps/web/src/components/ui/sheet.tsx
"use client"; import * as React from "react"; import { Dialog as SheetPrimitive } from "radix-ui"; import { cva, type VariantProps } from "class-variance-authority"; import { X } from "lucide-react"; import { cn } from "../../lib/utils"; const Sheet = SheetPrimitive.Root; const SheetTrigger = SheetPrimitive.Trigger...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/scroll-area.tsx
apps/web/src/components/ui/scroll-area.tsx
import * as React from "react"; import { cn } from "@/lib/utils"; const ScrollArea = React.forwardRef< HTMLDivElement, React.HTMLAttributes<HTMLDivElement> >(({ className, children, ...props }, ref) => ( <div ref={ref} className={cn("overflow-auto scrollbar-thin", className)} {...props} > {chil...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/card.tsx
apps/web/src/components/ui/card.tsx
import * as React from "react"; import { cn } from "../../lib/utils"; const Card = React.forwardRef< HTMLDivElement, React.HTMLAttributes<HTMLDivElement> >(({ className, ...props }, ref) => ( <div ref={ref} className={cn("rounded-xl border bg-card text-card-foreground", className)} {...props} /> )...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/draggable-item.tsx
apps/web/src/components/ui/draggable-item.tsx
"use client"; import { AspectRatio } from "@/components/ui/aspect-ratio"; import { Button } from "@/components/ui/button"; import { Tooltip, TooltipContent, TooltipTrigger, } from "@/components/ui/tooltip"; import { ReactNode, useState, useRef, useEffect } from "react"; import { createPortal } from "react-dom"; ...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/hover-card.tsx
apps/web/src/components/ui/hover-card.tsx
"use client"; import * as React from "react"; import { HoverCard as HoverCardPrimitive } from "radix-ui"; import { cn } from "../../lib/utils"; const HoverCard = HoverCardPrimitive.Root; const HoverCardTrigger = HoverCardPrimitive.Trigger; const HoverCardContent = React.forwardRef< React.ElementRef<typeof HoverC...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/editable-timecode.tsx
apps/web/src/components/ui/editable-timecode.tsx
"use client"; import { useState, useRef, useEffect } from "react"; import { cn } from "@/lib/utils"; import { formatTimeCode, parseTimeCode, TimeCode } from "@/lib/time"; import { DEFAULT_FPS } from "@/stores/project-store"; interface EditableTimecodeProps { time: number; duration?: number; format?: TimeCode; ...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/alert.tsx
apps/web/src/components/ui/alert.tsx
import * as React from "react"; import { cva, type VariantProps } from "class-variance-authority"; import { cn } from "../../lib/utils"; const alertVariants = cva( "relative w-full rounded-lg border px-4 py-3 text-sm [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foregroun...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/toggle-group.tsx
apps/web/src/components/ui/toggle-group.tsx
"use client"; import * as React from "react"; import { ToggleGroup as ToggleGroupPrimitive } from "radix-ui"; import { type VariantProps } from "class-variance-authority"; import { cn } from "../../lib/utils"; import { toggleVariants } from "./toggle"; const ToggleGroupContext = React.createContext< VariantProps<t...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/badge.tsx
apps/web/src/components/ui/badge.tsx
import * as React from "react"; import { cva, type VariantProps } from "class-variance-authority"; import { cn } from "../../lib/utils"; const badgeVariants = cva( "inline-flex items-center rounded-md border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-hidden focus:ring-2 focus:ring-ring focu...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/skeleton.tsx
apps/web/src/components/ui/skeleton.tsx
import { cn } from "../../lib/utils"; function Skeleton({ className, ...props }: React.HTMLAttributes<HTMLDivElement>) { return ( <div className={cn("animate-pulse rounded-md bg-primary/10", className)} {...props} /> ); } export { Skeleton };
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/tooltip.tsx
apps/web/src/components/ui/tooltip.tsx
import { cva, type VariantProps } from 'class-variance-authority'; import { Tooltip as TooltipPrimitive } from 'radix-ui'; import * as React from 'react'; import { cn } from '@/lib/utils'; const TooltipProvider = TooltipPrimitive.Provider; const Tooltip = TooltipPrimitive.Root; const TooltipTrigger = TooltipPrimiti...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/split-button.tsx
apps/web/src/components/ui/split-button.tsx
import { Button, ButtonProps } from "@/components/ui/button"; import { Separator } from "@/components/ui/separator"; import { ReactNode, forwardRef } from "react"; import { cn } from "@/lib/utils"; interface SplitButtonProps { children: ReactNode; className?: string; } interface SplitButtonSideProps extends Omit<...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/video-player.tsx
apps/web/src/components/ui/video-player.tsx
"use client"; import { useRef, useEffect } from "react"; import { usePlaybackStore } from "@/stores/playback-store"; interface VideoPlayerProps { src: string; poster?: string; className?: string; clipStartTime: number; trimStart: number; trimEnd: number; clipDuration: number; trackMuted?: boolean; } ...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/radio-group.tsx
apps/web/src/components/ui/radio-group.tsx
"use client"; import * as React from "react"; import { RadioGroup as RadioGroupPrimitive } from "radix-ui"; import { Circle } from "lucide-react"; import { cn } from "../../lib/utils"; const RadioGroup = React.forwardRef< React.ElementRef<typeof RadioGroupPrimitive.Root>, React.ComponentPropsWithoutRef<typeof Ra...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/chart.tsx
apps/web/src/components/ui/chart.tsx
"use client"; import * as React from "react"; import * as RechartsPrimitive from "recharts"; import { NameType, Payload, ValueType, } from "recharts/types/component/DefaultTooltipContent"; import { cn } from "../../lib/utils"; // Format: { THEME_NAME: CSS_SELECTOR } const THEMES = { light: "", dark: ".dark" } ...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/select.tsx
apps/web/src/components/ui/select.tsx
"use client"; import * as React from "react"; import { Select as SelectPrimitive } from "radix-ui"; import { Check, ChevronDown, ChevronUp } from "lucide-react"; import { cva, type VariantProps } from "class-variance-authority"; import { cn } from "../../lib/utils"; const Select = SelectPrimitive.Root; const Select...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/pagination.tsx
apps/web/src/components/ui/pagination.tsx
import * as React from "react"; import { ChevronLeft, ChevronRight, MoreHorizontal } from "lucide-react"; import { cn } from "../../lib/utils"; import { ButtonProps, buttonVariants } from "./button"; const Pagination = ({ className, ...props }: React.ComponentProps<"nav">) => ( <nav role="navigation" aria-l...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/image-timeline-treatment.tsx
apps/web/src/components/ui/image-timeline-treatment.tsx
"use client"; import { useState } from "react"; import { cn } from "@/lib/utils"; import type { BackgroundType } from "@/types/editor"; interface ImageTimelineTreatmentProps { src: string; alt: string; targetAspectRatio?: number; // Default to 16:9 for video className?: string; backgroundType?: BackgroundTy...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/audio-player.tsx
apps/web/src/components/ui/audio-player.tsx
"use client"; import { useRef, useEffect } from "react"; import { usePlaybackStore } from "@/stores/playback-store"; interface AudioPlayerProps { src: string; className?: string; clipStartTime: number; trimStart: number; trimEnd: number; clipDuration: number; trackMuted?: boolean; } export function Aud...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/alert-dialog.tsx
apps/web/src/components/ui/alert-dialog.tsx
"use client"; import * as React from "react"; import { AlertDialog as AlertDialogPrimitive } from "radix-ui"; import { cn } from "../../lib/utils"; import { buttonVariants } from "./button"; const AlertDialog = AlertDialogPrimitive.Root; const AlertDialogTrigger = AlertDialogPrimitive.Trigger; const AlertDialogPor...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/font-picker.tsx
apps/web/src/components/ui/font-picker.tsx
import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue, } from "@/components/ui/select"; import { FONT_OPTIONS, FontFamily } from "@/constants/font-constants"; interface FontPickerProps { defaultValue?: FontFamily; onValueChange?: (value: FontFamily) => void; className?: string; } expo...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/command.tsx
apps/web/src/components/ui/command.tsx
"use client"; import * as React from "react"; import { DialogProps } from "@radix-ui/react-dialog"; import { Command as CommandPrimitive } from "cmdk"; import { Search } from "lucide-react"; import { cn } from "../../lib/utils"; import { Dialog, DialogContent } from "./dialog"; const Command = React.forwardRef< Re...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/input-otp.tsx
apps/web/src/components/ui/input-otp.tsx
"use client"; import * as React from "react"; import { OTPInput, OTPInputContext } from "input-otp"; import { Minus } from "lucide-react"; import { cn } from "../../lib/utils"; const InputOTP = React.forwardRef< React.ElementRef<typeof OTPInput>, React.ComponentPropsWithoutRef<typeof OTPInput> >(({ className, co...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/input.tsx
apps/web/src/components/ui/input.tsx
"use client"; import { Eye, EyeOff, X } from "lucide-react"; import { cn } from "../../lib/utils"; import { Button } from "./button"; import { forwardRef, ComponentProps } from "react"; import { useState } from "react"; interface InputProps extends ComponentProps<"input"> { showPassword?: boolean; onShowPasswordC...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/checkbox.tsx
apps/web/src/components/ui/checkbox.tsx
"use client"; import * as React from "react"; import { Checkbox as CheckboxPrimitive } from "radix-ui"; import { Check } from "lucide-react"; import { cn } from "../../lib/utils"; const Checkbox = React.forwardRef< React.ElementRef<typeof CheckboxPrimitive.Root>, React.ComponentPropsWithoutRef<typeof CheckboxPri...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/context-menu.tsx
apps/web/src/components/ui/context-menu.tsx
"use client"; import * as React from "react"; import { ContextMenu as ContextMenuPrimitive } from "radix-ui"; import { Check, ChevronRight, Circle } from "lucide-react"; import { cva, type VariantProps } from "class-variance-authority"; import { cn } from "../../lib/utils"; const ContextMenu = ContextMenuPrimitive.R...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/components/ui/calendar.tsx
apps/web/src/components/ui/calendar.tsx
"use client"; import * as React from "react"; import { ChevronLeft, ChevronRight } from "lucide-react"; import { DayPicker } from "react-day-picker"; import { cn } from "../../lib/utils"; import { buttonVariants } from "./button"; export type CalendarProps = React.ComponentProps<typeof DayPicker>; function Calendar...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/stores/editor-store.ts
apps/web/src/stores/editor-store.ts
import { create } from "zustand"; import { persist } from "zustand/middleware"; import { CanvasPreset } from "@/types/editor"; export type PlatformLayout = "tiktok"; export const PLATFORM_LAYOUTS: Record<PlatformLayout, string> = { tiktok: "TikTok", }; interface LayoutGuideSettings { platform: PlatformLayout | n...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/stores/media-store.ts
apps/web/src/stores/media-store.ts
import { create } from "zustand"; import { storageService } from "@/lib/storage/storage-service"; import { useTimelineStore } from "./timeline-store"; import { generateUUID } from "@/lib/utils"; import { MediaType, MediaFile } from "@/types/media"; import { videoCache } from "@/lib/video-cache"; interface MediaStore {...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/stores/text-properties-store.ts
apps/web/src/stores/text-properties-store.ts
import { create } from "zustand"; import { persist } from "zustand/middleware"; export type TextPropertiesTab = "transform" | "style"; export interface TextPropertiesTabMeta { value: TextPropertiesTab; label: string; } export const TEXT_PROPERTIES_TABS: ReadonlyArray<TextPropertiesTabMeta> = [ { value: "transf...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/stores/project-store.ts
apps/web/src/stores/project-store.ts
import { TProject, BlurIntensity, Scene } from "@/types/project"; import { create } from "zustand"; import { storageService } from "@/lib/storage/storage-service"; import { toast } from "sonner"; import { useMediaStore } from "./media-store"; import { useTimelineStore } from "./timeline-store"; import { useSceneStore }...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/stores/playback-store.ts
apps/web/src/stores/playback-store.ts
import { create } from "zustand"; import type { PlaybackState, PlaybackControls } from "@/types/playback"; import { useTimelineStore } from "@/stores/timeline-store"; import { DEFAULT_FPS, useProjectStore } from "./project-store"; interface PlaybackStore extends PlaybackState, PlaybackControls { setDuration: (durati...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/stores/timeline-store.ts
apps/web/src/stores/timeline-store.ts
import { create } from "zustand"; import { TrackType, TimelineElement, CreateTimelineElement, TimelineTrack, TextElement, DragData, MediaElement, sortTracksByOrder, ensureMainTrack, validateElementTrackCompatibility, } from "@/types/timeline"; import { useMediaStore, getMediaAspectRatio } from "./me...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
true
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/stores/keybindings-store.ts
apps/web/src/stores/keybindings-store.ts
"use client"; import { create } from "zustand"; import { persist } from "zustand/middleware"; import { ActionWithOptionalArgs } from "@/constants/actions"; import { isAppleDevice, isDOMElement, isTypableElement } from "@/lib/utils"; import { KeybindingConfig, ShortcutKey } from "@/types/keybinding"; // Default keybin...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/stores/stickers-store.ts
apps/web/src/stores/stickers-store.ts
import { create } from "zustand"; import { getCollections, getCollection, searchIcons, downloadSvgAsText, svgToFile, type IconSet, type CollectionInfo, type IconSearchResult, } from "@/lib/iconify-api"; import { useProjectStore } from "@/stores/project-store"; import { useMediaStore } from "@/stores/med...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/stores/panel-store.ts
apps/web/src/stores/panel-store.ts
import { create } from "zustand"; import { persist } from "zustand/middleware"; export type PanelPreset = | "default" | "media" | "inspector" | "vertical-preview"; interface PanelSizes { toolsPanel: number; previewPanel: number; propertiesPanel: number; mainContent: number; timeline: number; } expo...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/stores/sounds-store.ts
apps/web/src/stores/sounds-store.ts
import { create } from "zustand"; import type { SoundEffect, SavedSound } from "@/types/sounds"; import { storageService } from "@/lib/storage/storage-service"; import { toast } from "sonner"; import { useMediaStore } from "./media-store"; import { useTimelineStore } from "./timeline-store"; import { useProjectStore } ...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/stores/scene-store.ts
apps/web/src/stores/scene-store.ts
import { create } from "zustand"; import { Scene } from "@/types/project"; import { useProjectStore } from "./project-store"; import { useTimelineStore } from "./timeline-store"; import { storageService } from "@/lib/storage/storage-service"; import { generateUUID } from "@/lib/utils"; export function getMainScene({ s...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/types/playback.ts
apps/web/src/types/playback.ts
export interface PlaybackState { isPlaying: boolean; currentTime: number; duration: number; volume: number; speed: number; muted: boolean; previousVolume?: number; } export interface PlaybackControls { play: () => void; pause: () => void; seek: (time: number) => void; setVolume: (volume: number) ...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/types/keybinding.ts
apps/web/src/types/keybinding.ts
import { ActionWithOptionalArgs } from "@/constants/actions"; /** * Alt is also regarded as macOS OPTION (⌥) key * Ctrl is also regarded as macOS COMMAND (⌘) key (NOTE: this differs from HTML Keyboard spec where COMMAND is Meta key!) */ export type ModifierKeys = | "ctrl" | "alt" | "shift" | "ctrl+shift" ...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/types/timeline.ts
apps/web/src/types/timeline.ts
import { MediaType } from "@/types/media"; import { generateUUID } from "@/lib/utils"; export type TrackType = "media" | "text" | "audio"; // Base element properties interface BaseTimelineElement { id: string; name: string; duration: number; startTime: number; trimStart: number; trimEnd: number; hidden?...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/types/editor.ts
apps/web/src/types/editor.ts
export type BackgroundType = "blur" | "mirror" | "color"; export type CanvasMode = "preset" | "original" | "custom"; export interface CanvasSize { width: number; height: number; } export interface CanvasPreset { name: string; width: number; height: number; } export interface TextElementDragState { isDra...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/types/post.ts
apps/web/src/types/post.ts
export type Post = { id: string; slug: string; title: string; content: string; description: string; coverImage: string; publishedAt: Date; updatedAt: Date; authors: { id: string; name: string; image: string; }[]; category: { id: string; slug: string; name: string; }; ta...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/types/sounds.ts
apps/web/src/types/sounds.ts
export interface SoundEffect { id: number; name: string; description: string; url: string; previewUrl?: string; downloadUrl?: string; duration: number; filesize: number; type: string; channels: number; bitrate: number; bitdepth: number; samplerate: number; username: string; tags: string[];...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/types/export.ts
apps/web/src/types/export.ts
export type ExportFormat = "mp4" | "webm"; export type ExportQuality = "low" | "medium" | "high" | "very_high"; export interface ExportOptions { format: ExportFormat; quality: ExportQuality; fps?: number; includeAudio?: boolean; onProgress?: (progress: number) => void; onCancel?: () => boolean; } export i...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/types/media.ts
apps/web/src/types/media.ts
export type MediaType = "image" | "video" | "audio"; // What's stored in media library export interface MediaFile { id: string; name: string; type: MediaType; file: File; url?: string; // Object URL for preview thumbnailUrl?: string; // For video thumbnails duration?: number; // For video/audio duration ...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/types/project.ts
apps/web/src/types/project.ts
import { CanvasSize } from "./editor"; export type BlurIntensity = 4 | 8 | 18; export interface Scene { id: string; name: string; isMain: boolean; createdAt: Date; updatedAt: Date; } export interface TProject { id: string; name: string; thumbnail: string; createdAt: Date; updatedAt: Date; scene...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/zk-encryption.ts
apps/web/src/lib/zk-encryption.ts
/** * True zero-knowledge encryption utilities * Keys are generated randomly in the browser and never derived from server secrets */ export interface ZeroKnowledgeEncryptionResult { encryptedData: ArrayBuffer; key: ArrayBuffer; iv: ArrayBuffer; } /** * Encrypt data with a randomly generated key (true zero-k...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/blog-query.ts
apps/web/src/lib/blog-query.ts
import type { MarbleAuthorList, MarbleCategoryList, MarblePost, MarblePostList, MarbleTagList, } from "@/types/post"; import { unified } from "unified"; import rehypeParse from "rehype-parse"; import rehypeStringify from "rehype-stringify"; import rehypeSlug from "rehype-slug"; import rehypeAutolinkHeadings f...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/timeline.ts
apps/web/src/lib/timeline.ts
import { TimelineElement } from "@/types/timeline"; // Helper function to check for element overlaps and prevent invalid timeline states export const checkElementOverlaps = (elements: TimelineElement[]): boolean => { // Sort elements by start time const sortedElements = [...elements].sort( (a, b) => a.startTim...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/iconify-api.ts
apps/web/src/lib/iconify-api.ts
export const ICONIFY_HOSTS = [ "https://api.iconify.design", "https://api.simplesvg.com", "https://api.unisvg.com", ]; let currentHost = ICONIFY_HOSTS[0]; async function fetchWithFallback(path: string): Promise<Response> { for (const host of ICONIFY_HOSTS) { try { const response = await fetch(`${ho...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/media-processing.ts
apps/web/src/lib/media-processing.ts
import { toast } from "sonner"; import { getFileType, getMediaDuration, getImageDimensions, } from "@/stores/media-store"; import { MediaFile } from "@/types/media"; import { generateThumbnail, getVideoInfo } from "./mediabunny-utils"; export interface ProcessedMediaItem extends Omit<MediaFile, "id"> {} export ...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/utils.ts
apps/web/src/lib/utils.ts
// Generic utilities import { type ClassValue, clsx } from "clsx"; import { twMerge } from "tailwind-merge"; export function cn(...inputs: ClassValue[]) { return twMerge(clsx(inputs)); } export function uppercase(str: string) { return str.toUpperCase(); } /** * Generates a UUID v4 string * Uses crypto.randomU...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/editor-utils.ts
apps/web/src/lib/editor-utils.ts
import { CanvasSize } from "@/types/editor"; const DEFAULT_CANVAS_PRESETS = [ { name: "16:9", width: 1920, height: 1080 }, { name: "9:16", width: 1080, height: 1920 }, { name: "1:1", width: 1080, height: 1080 }, { name: "4:3", width: 1440, height: 1080 }, ]; /** * Helper function to find the best matching ca...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/time.ts
apps/web/src/lib/time.ts
// Time-related utility functions import { DEFAULT_FPS } from "@/stores/project-store"; export type TimeCode = "MM:SS" | "HH:MM:SS" | "HH:MM:SS:CS" | "HH:MM:SS:FF"; // Helper function to format time in various formats (MM:SS, HH:MM:SS, HH:MM:SS:CS, HH:MM:SS:FF) export const formatTimeCode = ( timeInSeconds: number...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/rate-limit.ts
apps/web/src/lib/rate-limit.ts
// lib/rate-limit.ts import { Ratelimit } from "@upstash/ratelimit"; import { Redis } from "@upstash/redis"; import { env } from "@/env"; const redis = new Redis({ url: env.UPSTASH_REDIS_REST_URL, token: env.UPSTASH_REDIS_REST_TOKEN, }); export const baseRateLimit = new Ratelimit({ redis, limiter: Ratelimit.s...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/export.ts
apps/web/src/lib/export.ts
import { Output, Mp4OutputFormat, WebMOutputFormat, BufferTarget, CanvasSource, AudioBufferSource, QUALITY_LOW, QUALITY_MEDIUM, QUALITY_HIGH, QUALITY_VERY_HIGH, } from "mediabunny"; import { renderTimelineFrame } from "./timeline-renderer"; import { useTimelineStore } from "@/stores/timeline-store";...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/transcription-utils.ts
apps/web/src/lib/transcription-utils.ts
import { env } from "@/env"; export function isTranscriptionConfigured() { const missingVars = []; if (!env.CLOUDFLARE_ACCOUNT_ID) missingVars.push("CLOUDFLARE_ACCOUNT_ID"); if (!env.R2_ACCESS_KEY_ID) missingVars.push("R2_ACCESS_KEY_ID"); if (!env.R2_SECRET_ACCESS_KEY) missingVars.push("R2_SECRET_ACCESS_KEY")...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/video-cache.ts
apps/web/src/lib/video-cache.ts
import { Input, ALL_FORMATS, BlobSource, CanvasSink, WrappedCanvas, } from "mediabunny"; interface VideoSinkData { sink: CanvasSink; iterator: AsyncGenerator<WrappedCanvas, void, unknown> | null; currentFrame: WrappedCanvas | null; lastTime: number; } export class VideoCache { private sinks = new M...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/font-config.ts
apps/web/src/lib/font-config.ts
import { Inter, Roboto, Open_Sans, Playfair_Display, Comic_Neue, } from "next/font/google"; // Configure all fonts const inter = Inter({ subsets: ["latin"] }); const roboto = Roboto({ subsets: ["latin"], weight: ["400", "700"] }); const openSans = Open_Sans({ subsets: ["latin"] }); const playfairDisplay = Pl...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false
OpenCut-app/OpenCut
https://github.com/OpenCut-app/OpenCut/blob/0173db99448d1c4c6415dcf15272e17551b48b04/apps/web/src/lib/timeline-renderer.ts
apps/web/src/lib/timeline-renderer.ts
import type { TimelineTrack } from "@/types/timeline"; import type { MediaFile } from "@/types/media"; import type { BlurIntensity } from "@/types/project"; import { videoCache } from "./video-cache"; import { drawCssBackground } from "./canvas-gradients"; export interface RenderContext { ctx: CanvasRenderingContext...
typescript
MIT
0173db99448d1c4c6415dcf15272e17551b48b04
2026-01-04T15:42:54.730143Z
false