feat: Refactor styling and theme integration across components; update button gradients and remove unused component
This commit is contained in:
@@ -10,6 +10,7 @@ import {
|
||||
Group,
|
||||
} from '@mantine/core';
|
||||
import { MetodoSelect } from './MetodoSelect';
|
||||
import { useMantineTheme } from '@mantine/core';
|
||||
|
||||
export function LlamadorAPI() {
|
||||
const [direccion, setDireccion] = useState('http://localhost:8000/api/saludo');
|
||||
@@ -25,6 +26,9 @@ export function LlamadorAPI() {
|
||||
return 'red';
|
||||
};
|
||||
|
||||
const theme = useMantineTheme();
|
||||
|
||||
|
||||
const llamarAPI = async () => {
|
||||
try {
|
||||
const options: RequestInit = {
|
||||
@@ -101,7 +105,12 @@ export function LlamadorAPI() {
|
||||
minRows={3}
|
||||
/>
|
||||
|
||||
<Button onClick={llamarAPI} color="blue">
|
||||
<Button onClick={llamarAPI}
|
||||
variant="gradient"
|
||||
gradient={{
|
||||
from: theme.colors.brand[7],
|
||||
to: theme.colors.brand[4],
|
||||
}}>
|
||||
Enviar solicitud
|
||||
</Button>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user