Skip to content

Commit

Permalink
fix: steps
Browse files Browse the repository at this point in the history
  • Loading branch information
DamonSalvatoreDeveloper committed Jul 21, 2024
1 parent 8d9bda6 commit e82b083
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions src/pages/sharedSteps/Step2.tsx
Original file line number Diff line number Diff line change
@@ -1,30 +1,36 @@
import { Box } from '@mui/material';
import { useEffect } from 'react';
import { useNavigate } from 'react-router-dom';
import MainButton from '../../components/MainButton';
import Typography from '../../components/Typography';
import { useActiveStep } from '../../providers/activeStepProvider';
import { useInstallType } from '../../providers/installTypeProvider';
import { urls } from '../../routes/urls';

const Step2 = () => {
const { setActiveStep } = useActiveStep();
const { setInstallType } = useInstallType();
const navigate = useNavigate();

useEffect(() => {
setActiveStep(2);
}, []);

const handleNewInstall = () => {
setInstallType('new-install');
navigate(urls.newInstallSteps.step3);
setActiveStep(3);
};

const handleBackup = () => {
setInstallType('backup-install');
navigate(urls.backupInstallSteps.step3);
setActiveStep(3);
};

const handleMainServer = () => {
setInstallType('main-server-install');
navigate(urls.mainServerInstallSteps.step3);
setActiveStep(3);
};

Expand Down
2 changes: 1 addition & 1 deletion vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { defineConfig } from 'vite';

// https://vitejs.dev/config/
export default defineConfig({
base: '/hiddify-admin-front/',
base: '/hiddify-admin-front',
plugins: [react()],
server: {
port: 3000, // You can specify the port you want the dev server to run on
Expand Down

0 comments on commit e82b083

Please sign in to comment.