Browse Source

增加鉴别诊断demo视频

“gmcs” 1 year ago
parent
commit
489fd2585b
4 changed files with 9 additions and 5 deletions
  1. 3 3
      src/main.jsx
  2. BIN
      src/mp4/demo.mp4
  3. 4 1
      src/pages/measurement/Diagnosis.jsx
  4. 2 1
      vite.config.js

+ 3 - 3
src/main.jsx

@@ -1,14 +1,14 @@
 import React from 'react'
 import ReactDOM from 'react-dom/client'
-import { BrowserRouter } from 'react-router-dom'
+import { BrowserRouter, HashRouter } from 'react-router-dom'
 import App from './App.jsx'
 import './index.css'
 
 const root = ReactDOM.createRoot(document.getElementById('root'))
 root.render(
   <React.StrictMode>
-    <BrowserRouter>
+    <HashRouter>
       <App />
-    </BrowserRouter>
+    </HashRouter>
   </React.StrictMode>,
 )

BIN
src/mp4/demo.mp4


+ 4 - 1
src/pages/measurement/Diagnosis.jsx

@@ -3,6 +3,7 @@ import { Button } from 'tdesign-react'
 import { useNavigate } from 'react-router-dom'
 import MeasurementStep from '../../components/Steps/MeasurementStep'
 import '../../assets/css/diagnosis.css'
+import vidio from '../../mp4/demo.mp4' 
 
 export default function Diagnosis() {
   const navigate = useNavigate()
@@ -13,7 +14,9 @@ export default function Diagnosis() {
         <MeasurementStep current={1} />
 
         <div className='diagnosis-box'>
-          诊断信息等
+          <video width="1280" height="960" controls>
+            <source src={vidio} type="video/mp4" />
+          </video>
         </div>
 
         <Button block variant="base" style={{ width: '30%', margin: '40px auto' }}

+ 2 - 1
vite.config.js

@@ -6,5 +6,6 @@ export default defineConfig({
   plugins: [react()],
   server: {
     port: 7274
-  }
+  },
+  base:"./"
 })