feat: add initialUrl to store the first url
This commit is contained in:
@@ -20,6 +20,8 @@ interface GlobalInfo {
|
|||||||
setRecordingId: (newId: string | null) => void;
|
setRecordingId: (newId: string | null) => void;
|
||||||
recordingName: string;
|
recordingName: string;
|
||||||
setRecordingName: (recordingName: string) => void;
|
setRecordingName: (recordingName: string) => void;
|
||||||
|
initialUrl: string;
|
||||||
|
setInitialUrl: (initialUrl: string) => void;
|
||||||
recordingUrl: string;
|
recordingUrl: string;
|
||||||
setRecordingUrl: (recordingUrl: string) => void;
|
setRecordingUrl: (recordingUrl: string) => void;
|
||||||
currentWorkflowActionsState: {
|
currentWorkflowActionsState: {
|
||||||
@@ -49,6 +51,7 @@ class GlobalInfoStore implements Partial<GlobalInfo> {
|
|||||||
recordings: string[] = [];
|
recordings: string[] = [];
|
||||||
rerenderRuns = false;
|
rerenderRuns = false;
|
||||||
recordingName = '';
|
recordingName = '';
|
||||||
|
initialUrl = 'https://';
|
||||||
recordingUrl = 'https://';
|
recordingUrl = 'https://';
|
||||||
currentWorkflowActionsState = {
|
currentWorkflowActionsState = {
|
||||||
hasScrapeListAction: false,
|
hasScrapeListAction: false,
|
||||||
@@ -72,6 +75,7 @@ export const GlobalInfoProvider = ({ children }: { children: JSX.Element }) => {
|
|||||||
const [recordingLength, setRecordingLength] = useState<number>(globalInfoStore.recordingLength);
|
const [recordingLength, setRecordingLength] = useState<number>(globalInfoStore.recordingLength);
|
||||||
const [recordingId, setRecordingId] = useState<string | null>(globalInfoStore.recordingId);
|
const [recordingId, setRecordingId] = useState<string | null>(globalInfoStore.recordingId);
|
||||||
const [recordingName, setRecordingName] = useState<string>(globalInfoStore.recordingName);
|
const [recordingName, setRecordingName] = useState<string>(globalInfoStore.recordingName);
|
||||||
|
const [initialUrl, setInitialUrl] = useState<string>(globalInfoStore.initialUrl);
|
||||||
const [recordingUrl, setRecordingUrl] = useState<string>(globalInfoStore.recordingUrl);
|
const [recordingUrl, setRecordingUrl] = useState<string>(globalInfoStore.recordingUrl);
|
||||||
const [currentWorkflowActionsState, setCurrentWorkflowActionsState] = useState(globalInfoStore.currentWorkflowActionsState);
|
const [currentWorkflowActionsState, setCurrentWorkflowActionsState] = useState(globalInfoStore.currentWorkflowActionsState);
|
||||||
const [shouldResetInterpretationLog, setShouldResetInterpretationLog] = useState<boolean>(globalInfoStore.shouldResetInterpretationLog);
|
const [shouldResetInterpretationLog, setShouldResetInterpretationLog] = useState<boolean>(globalInfoStore.shouldResetInterpretationLog);
|
||||||
@@ -119,6 +123,8 @@ export const GlobalInfoProvider = ({ children }: { children: JSX.Element }) => {
|
|||||||
setRecordingId,
|
setRecordingId,
|
||||||
recordingName,
|
recordingName,
|
||||||
setRecordingName,
|
setRecordingName,
|
||||||
|
initialUrl,
|
||||||
|
setInitialUrl,
|
||||||
recordingUrl,
|
recordingUrl,
|
||||||
setRecordingUrl,
|
setRecordingUrl,
|
||||||
currentWorkflowActionsState,
|
currentWorkflowActionsState,
|
||||||
|
|||||||
Reference in New Issue
Block a user