Proyectos de Subversion LeadersLinked - SPA

Rev

Rev 3321 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 3321 Rev 3324
Línea 1... Línea 1...
1
import React, { useState } from 'react'
1
import React, { useMemo, useState } from 'react'
2
import { useNavigate } from 'react-router-dom'
2
import { useNavigate } from 'react-router-dom'
3
import { useDispatch } from 'react-redux'
3
import { useDispatch } from 'react-redux'
4
import { Typography } from '@mui/material'
4
import { Typography } from '@mui/material'
Línea 5... Línea 5...
5
 
5
 
Línea 20... Línea 20...
20
    progress
20
    progress
Línea 21... Línea 21...
21
 
21
 
22
  const { removeItem, getItemById } = useHabitProgress()
22
  const { removeItem, getItemById } = useHabitProgress()
Línea -... Línea 23...
-
 
23
  const currentRegister = getItemById(id)
-
 
24
 
-
 
25
  const formatDate = useMemo(() => {
-
 
26
    const intlDate = new Intl.DateTimeFormat('es', {
-
 
27
      dateStyle: 'full',
-
 
28
      timeStyle: 'medium',
-
 
29
      timeZone: 'America/Bogota'
-
 
30
    }).format(new Date(date))
-
 
31
    return intlDate
23
  const currentRegister = getItemById(id)
32
  }, [date])
Línea 24... Línea 33...
24
 
33
 
25
  const toggleConfirmModal = () => setShow(!show)
34
  const toggleConfirmModal = () => setShow(!show)
26
 
35
 
Línea 38... Línea 47...
38
 
47
 
39
  return (
48
  return (
40
    <>
49
    <>
41
      <Widget>
50
      <Widget>
42
        <Widget.Header
51
        <Widget.Header
43
          title={date}
52
          title={formatDate}
44
          subheader={quantitative_value}
53
          subheader={quantitative_value}
45
          renderAction={() => (
54
          renderAction={() => (
46
            <Options>
55
            <Options>
47
              {actions.link_edit && (
56
              {actions.link_edit && (