import { ClientAnalytics } from '@zeniai/client-analytics'; import { AuthParams, CannedResponse, EditTaskLocalData, FetchState, FilePayload, ID, LoggedInUser, TagViewSelectorView, Task, TaskDetailSelectorView, UserGroup } from '@zeniai/client-epic-state'; import { UserMultiSelectFieldValue } from '../cockpit/common/userMultiSelect/UserMultiSelectField'; import { RequestToOpenThreadType } from '../commentsAndNotes/utils/ThreadsProvider'; import { MultiSelectFieldValue } from '../formElements/creatableMultiSelectField/CreatableMultiSelectField'; import { RecurringViewType } from '../formElements/recurringView/RecurringView'; import { SingleSelectPickerFieldValue } from '../formElements/singleSelectPickerField/SingleSelectPickerField'; import { SingleSelectFieldValue } from '../singleSelect/SingleSelectField'; import { AttachmentFormData } from './AllTaskAttachments'; import { TaskDetailSubtaskFormProps } from './TaskDetailSubtaskForm'; import { assigneeKey, statusKey, tagKey, taskDataKey, timeSpentKey } from './taskManagementFormConstants'; declare const name = "name"; declare const description = "description"; declare const status = "status"; declare const assignee = "assignee"; declare const dueDate = "dueDate"; declare const priority = "priority"; declare const tag = "tag"; declare const fileIds = "fileIds"; declare const taskSectionId = "taskDetail"; declare const subtaskDetailSectionId = "subtaskDetailRows"; declare const taskType = "taskType"; declare const recurringView = "recurringView"; declare const visibility = "visibility"; export interface TaskDetailFormData { [assignee]: UserMultiSelectFieldValue; [description]: string; [fileIds]: AttachmentFormData[]; [name]: string; [priority]: SingleSelectPickerFieldValue; [status]: SingleSelectPickerFieldValue; [tag]: MultiSelectFieldValue; [taskType]: SingleSelectFieldValue; [timeSpentKey]: string; [dueDate]?: Date; [recurringView]?: RecurringViewType; [visibility]?: string; } type FormDataKeys = keyof TaskDetailFormData; export interface SubtaskInlineFieldData { [assigneeKey]: UserMultiSelectFieldValue; [statusKey]: SingleSelectPickerFieldValue; [tagKey]: MultiSelectFieldValue; } export interface FormData { [taskSectionId]: TaskDetailFormData; [subtaskDetailSectionId]?: { [taskDataKey]: Record; }; } declare const uniqueName: (sectionId: string, key: FormDataKeys) => `${string}.fileIds` | `${string}.name` | `${string}.status` | `${string}.description` | `${string}.dueDate` | `${string}.priority` | `${string}.timeSpent` | `${string}.assignee` | `${string}.visibility` | `${string}.tag` | `${string}.taskType` | `${string}.recurringView`; export type FormDataKeyUniqueNames = ReturnType; export declare const uniqueFormName: (sectionId: ID) => `${string}_form`; export interface TaskDetailPageProps { analytics: ClientAnalytics; authParams: AuthParams; companyId: ID; companyName: string; currentUrl: string; filesEndPoint: string; isNewClicked: boolean; loggedInUser: LoggedInUser; tagListView: TagViewSelectorView; taskDetailSelectorView: TaskDetailSelectorView; userGroupList: UserGroup[]; cannedResponses?: CannedResponse[]; initialOpenThreadRequest?: RequestToOpenThreadType; isCannedResponsesLoading?: boolean; isTaskCannedResponsesEnabled?: boolean; isTaskGroupAssigneesEnabled?: boolean; isTaskRecurringParentEnabled?: boolean; isTaskSnoozeEnabled?: boolean; isTaskVisibilityEnabled?: boolean; isZeniUser?: boolean; /** Parent task ref for the breadcrumb on subtask detail pages. * Set when the current task has a parent_task_id. */ parentTaskRef?: { id: ID; name: string; }; recurringSourceTaskUrl?: string; subTaskCreateStatus?: FetchState; subtasks?: Task[]; taskDetailFetchState?: FetchState; taskGroupList?: Array<{ id: ID; isDefault: boolean; name: string; }>; taskGroupName?: string; taskId?: ID; handleZeniLogoClick: () => void; onArchiveTaskClick: () => void; onCreateTagClick: (tagName: string) => void; onDeleteFile: (fileId: ID) => void; onDeleteTagClick: (tagId: ID) => void; onDeleteTaskClick: () => void; onDismissClick: () => void; onEditFileName: (fileId: ID, name: string) => void; onReloadTaskDetailPage: () => void; onSaveChangesToLocalStore: (localData: EditTaskLocalData) => void; onSaveDetailClick: (selectedTaskGroupId?: ID) => void; onSnoozeTask: (taskId: ID, snoozedUntil: string) => void; onUnsnoozeTask: (taskId: ID) => void; updateFilesEntity: (files: FilePayload[]) => void; /** Fires when the user submits the full subtask form (Figma fields: * name, status, priority, assignees, due date, tags, time spent). * Wired to `createSubTask` in TaskDetailScreen. When omitted, the * "+ Add subtask" affordance is hidden. */ onCreateSubtask?: (parentTaskId: ID, data: Parameters[0]) => void; onFetchCannedResponses?: () => void; onManageTemplatesClick?: () => void; /** Fires when the user clicks the parent-task breadcrumb on a subtask * detail page. */ onParentBreadcrumbClick?: (parentTaskId: ID) => void; /** Fires when the user clicks a subtask row in the parent's SUBTASKS * section — navigates to the subtask detail page. */ onSubtaskRowClick?: (subtaskId: ID) => void; /** Wired to updateTaskFromListView in TaskDetailScreen — propagates inline * edits on subtask rows (status, assignee, tag, priority, due date, * time-spent) the same way the task-list page does. */ onSubtaskUpdate?: (task: Task, updates: Partial) => void; } declare const TaskDetailPage: ({ taskDetailSelectorView, companyName, companyId, loggedInUser, analytics, isNewClicked, filesEndPoint, authParams, currentUrl, taskId, taskGroupList, taskGroupName, taskDetailFetchState, onSaveChangesToLocalStore, onSaveDetailClick, onArchiveTaskClick, onSnoozeTask, onUnsnoozeTask, onDismissClick, handleZeniLogoClick: _handleZeniLogoClick, updateFilesEntity, onDeleteFile, onEditFileName, onDeleteTaskClick, onReloadTaskDetailPage, tagListView, userGroupList, onCreateTagClick, onDeleteTagClick, cannedResponses, initialOpenThreadRequest, isCannedResponsesLoading, isTaskCannedResponsesEnabled, isTaskGroupAssigneesEnabled, isTaskRecurringParentEnabled, isTaskSnoozeEnabled, isTaskVisibilityEnabled, isZeniUser, onFetchCannedResponses, onManageTemplatesClick, onCreateSubtask, subTaskCreateStatus, onSubtaskUpdate, parentTaskRef, onSubtaskRowClick, onParentBreadcrumbClick, recurringSourceTaskUrl, subtasks, }: TaskDetailPageProps) => import("react/jsx-runtime").JSX.Element; export default TaskDetailPage;