mirror of
https://github.com/Frooodle/Stirling-PDF.git
synced 2025-12-18 20:04:17 +01:00
Fix path to sample file in tour (#5186)
# Description of Changes Fix path to sample file in tour
This commit is contained in:
parent
7faf7e50fa
commit
fa4d2bc09a
@ -1,4 +1,5 @@
|
||||
import React, { createContext, useContext, useCallback, useRef } from 'react';
|
||||
import { BASE_PATH } from '@app/constants/app';
|
||||
import { useFileHandler } from '@app/hooks/useFileHandler';
|
||||
import { useFilesModalContext } from '@app/contexts/FilesModalContext';
|
||||
import { useNavigationActions } from '@app/contexts/NavigationContext';
|
||||
@ -110,7 +111,7 @@ export const TourOrchestrationProvider: React.FC<{ children: React.ReactNode }>
|
||||
|
||||
const loadSampleFile = useCallback(async () => {
|
||||
try {
|
||||
const response = await fetch('samples/Sample.pdf');
|
||||
const response = await fetch(`${BASE_PATH}/samples/Sample.pdf`);
|
||||
const blob = await response.blob();
|
||||
const file = new File([blob], 'Sample.pdf', { type: 'application/pdf' });
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user