refactor: expose actions through context

This commit is contained in:
Carlos Valente
2026-01-06 18:27:56 +01:00
parent fc007cf124
commit db9444aaa4
21 changed files with 138 additions and 90 deletions
@@ -3,8 +3,8 @@ import { OntimeEvent } from 'ontime-types';
import * as Editor from '../../../common/components/editor-utils/EditorUtils';
import AppLink from '../../../common/components/link/app-link/AppLink';
import { useEntryActions } from '../../../common/hooks/useEntryAction';
import useCustomFields from '../../../common/hooks-query/useCustomFields';
import { useRundownEntryActions } from '../context/RundownActionsContext';
import EntryEditorCustomFields from './composite/EventEditorCustomFields';
import EventEditorTimes from './composite/EventEditorTimes';
@@ -22,7 +22,7 @@ interface EventEditorProps {
export default function EventEditor({ event }: EventEditorProps) {
const { data: customFields } = useCustomFields();
const { updateEntry } = useEntryActions();
const { updateEntry } = useRundownEntryActions();
const isEditor = window.location.pathname.includes('editor');