From 7b05dd384c4a4c59d384a267166edfe71a100de4 Mon Sep 17 00:00:00 2001 From: Fernando Dodino Date: Sun, 28 Jul 2024 00:50:54 -0300 Subject: [PATCH] Change coverage badge --- README.md | 36 +++++++++++++++++------------------- 1 file changed, 17 insertions(+), 19 deletions(-) diff --git a/README.md b/README.md index 73ef839..0a6497f 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ -[![Build React App](https://github.com/uqbar-project/eg-conversor-react/actions/workflows/build.yml/badge.svg)](https://github.com/uqbar-project/eg-conversor-react/actions/workflows/build.yml) ![coverage](./badges/coverage/coverage.svg) +[![Build React App](https://github.com/uqbar-project/eg-conversor-react/actions/workflows/build.yml/badge.svg)](https://github.com/uqbar-project/eg-conversor-react/actions/workflows/build.yml) [![codecov](https://codecov.io/gh/uqbar-project/eg-conversor-react/graph/badge.svg?token=KYlbA99E6E)](https://codecov.io/gh/uqbar-project/eg-conversor-react) # Conversor ReactJS @@ -17,28 +17,26 @@ const App = () => { const [millas, setMillas] = useState(INITIAL_VALUE) const millasConvertido = +millas - const kilometros = millas === INITIAL_VALUE ? '' : isNaN(millasConvertido) ? '' : convertirMillasAKms(millasConvertido) - const colorConversion = millas === INITIAL_VALUE || isNaN(millasConvertido) ? 'warning' : 'success' + const kilometros = millas === INITIAL_VALUE ? '' : convertirMillasAKms(millasConvertido) + const colorConversion = millas === INITIAL_VALUE ? 'warning' : 'success' return (
- - +
Conversor de millas a kilómetros - React - - - - - setMillas(event.target.value)} /> - - - - - - - - - +
+
+
+ + setMillas(event.target.value)} /> +
+
+ +
+ {kilometros.toLocaleString('es')} +
+
+
) }