/* Copyright (C) 2023-2026 QuantumNous This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . For commercial licensing, please contact support@quantumnous.com */ import { ArrowDownToLine, CircleHelp, Layers, Pause, Play, RotateCcw, } from 'lucide-react' import { useCallback, useState } from 'react' import { useTranslation } from 'react-i18next' import type { DataTableViewMode } from '@/components/data-table' import { Dialog } from '@/components/dialog' import { Button } from '@/components/ui/button' import { Tabs, TabsContent, TabsList, TabsTrigger } from '@/components/ui/tabs' import { useMediaQuery } from '@/hooks/use-media-query' import { ChannelPriorityDemo } from './channel-priority-demo' export function ChannelPriorityGuide(props: { open: boolean viewMode: DataTableViewMode onOpenChange: (open: boolean) => void }) { const { t } = useTranslation() const [playback, setPlayback] = useState(0) const [demo, setDemo] = useState<'same' | 'insert'>('same') const [playing, setPlaying] = useState(true) const reduced = useMediaQuery('(prefers-reduced-motion: reduce)') const nextDemo = useCallback(() => { setDemo((mode) => (mode === 'same' ? 'insert' : 'same')) }, []) const handleOpenChange = (open: boolean) => { if (!open) { setDemo('same') setPlaying(true) } props.onOpenChange(open) } return ( } footerClassName='flex-row items-center justify-between sm:justify-between' footer={ <>
{!reduced && ( )}
} > { if (value === 'same' || value === 'insert') setDemo(value) }} className='gap-3' > {t('Join the same priority tier')} {t('Insert a new priority tier')} {(['same', 'insert'] as const).map((mode) => ( {props.open && demo === mode && ( )} ))}

{t('Changes save on drop. You can undo the last move.')}

) }