Update SearchBar

This commit is contained in:
Aj - Thomas
2022-04-27 23:18:57 +02:00
parent 6743d56c58
commit a72d9f0f55

View File

@@ -1,4 +1,4 @@
import { Input, TextInput, Text, ActionIcon, useMantineTheme } from '@mantine/core'; import { Input, TextInput, Text, ActionIcon, useMantineTheme, Center } from '@mantine/core';
import { useForm } from '@mantine/hooks'; import { useForm } from '@mantine/hooks';
import { showNotification } from '@mantine/notifications'; import { showNotification } from '@mantine/notifications';
import { useState, useEffect } from 'react'; import { useState, useEffect } from 'react';
@@ -11,7 +11,9 @@ export default function SearchBar(props: any) {
searchBar: true, searchBar: true,
searchUrl: 'https://www.google.com/search?q=', searchUrl: 'https://www.google.com/search?q=',
}); });
const querryUrl = config.searchUrl || 'https://www.google.com/search?q='; const querryUrl = config.searchUrl || 'https://www.google.com/search?q=';
const form = useForm({ const form = useForm({
initialValues: { initialValues: {
querry: '', querry: '',
@@ -41,7 +43,6 @@ export default function SearchBar(props: any) {
radius="xl" radius="xl"
size="md" size="md"
placeholder="Search the web" placeholder="Search the web"
rightSectionWidth={42}
{...props} {...props}
{...form.getInputProps('querry')} {...form.getInputProps('querry')}
/> />