amenpunk преди 2 години
родител
ревизия
2224170b7d
променени са 3 файла, в които са добавени 34 реда и са изтрити 7 реда
  1. 18 4
      src/Components/Generics/loading.jsx
  2. 11 0
      src/Components/Modal/PasswordModal.jsx
  3. 5 3
      src/Pages/Login.jsx

+ 18 - 4
src/Components/Generics/loading.jsx

@@ -2,13 +2,15 @@ import React from "react";
 import '../../Css/loading.css'
 
 import { Box, Paper } from '@mui/material'
+  
+const types = [
+  "dot-pulse", "dot-elastic", "dot-flashing", "dot-collision", "dot-revolution", "dot-carousel",
+  "dot-fire", "dot-spin", "dot-falling", "dot-stretching"
+];
+
 
 export function Loading() {
 
-  const types = [
-    "dot-pulse", "dot-elastic", "dot-flashing", "dot-collision", "dot-revolution", "dot-carousel",
-    "dot-fire", "dot-spin", "dot-falling", "dot-stretching"
-  ];
 
   return (
     <div className="content-section">
@@ -29,3 +31,15 @@ export function Loading() {
 
   )
 }
+
+export function Simple() {
+  return (
+    <div className="snippet" data-title=".dot-pulse">
+      <div className="stage">
+        <div className={types[0]}></div>
+      </div>
+    </div>
+
+  )
+}
+

+ 11 - 0
src/Components/Modal/PasswordModal.jsx

@@ -7,6 +7,7 @@ import {
 } from '@mui/material'
 
 import { Puesto } from '../Password/Steps/puesto'
+import { TypePwd } from '../Password/Steps/TypePwd'
 import { Password } from '../Password/Steps/password'
 import { Candidato } from '../Password/Steps/candidato'
 import { Resume } from '../Password/Steps/resume'
@@ -71,6 +72,16 @@ export function HelpModal(props) {
 
 
   const steps = [
+    {
+      label : "Tipo de contraseña",
+      operation : 
+        <TypePwd
+        handleNext={handleNext}
+        handleBack={handleBack}
+        password={password}
+        setPassword={setPassword}
+        />
+    },
     {
       label: 'Puesto',
       operation:

+ 5 - 3
src/Pages/Login.jsx

@@ -96,11 +96,13 @@ export function Login() {
   });
   
   React.useEffect(() => {
+    console.log('auth', auth)
     if(auth.token){
-      let body_token = jwt_decode(auth.token);
-      if(body_token.authorities.includes("Reclutador")){
+      // let body_token = jwt_decode(auth.token);
+      // console.log(,body_token)
+      // if(body_token.authorities.includes("Reclutador")){
         navigate('/dashboard/home')
-      }
+      // }
     }
   }, [auth, navigate])