💄 Prettier codebase
This commit is contained in:
@@ -12,10 +12,10 @@ import {
|
||||
} from '@tabler/icons-react';
|
||||
import { useTranslation } from 'next-i18next';
|
||||
import { useState } from 'react';
|
||||
|
||||
import { useConfigContext } from '~/config/provider';
|
||||
import { useConfigStore } from '~/config/store';
|
||||
import { AppType } from '~/types/app';
|
||||
|
||||
import { DebouncedImage } from '../../../IconSelector/DebouncedImage';
|
||||
import { useEditModeStore } from '../../Views/useEditModeStore';
|
||||
import { AppearanceTab } from './Tabs/AppereanceTab/AppereanceTab';
|
||||
|
||||
@@ -3,9 +3,8 @@ import { UseFormReturnType } from '@mantine/form';
|
||||
import { useDebouncedValue } from '@mantine/hooks';
|
||||
import { useTranslation } from 'next-i18next';
|
||||
import { useEffect, useRef } from 'react';
|
||||
|
||||
import { AppType } from '~/types/app';
|
||||
import { IconSelector } from '~/components/IconSelector/IconSelector';
|
||||
import { AppType } from '~/types/app';
|
||||
|
||||
interface AppearanceTabProps {
|
||||
form: UseFormReturnType<AppType, (values: AppType) => AppType>;
|
||||
@@ -83,7 +82,8 @@ export const AppearanceTab = ({
|
||||
data={[
|
||||
{
|
||||
value: 'column',
|
||||
label: t('appearance.positionAppName.dropdown.top') as string },
|
||||
label: t('appearance.positionAppName.dropdown.top') as string,
|
||||
},
|
||||
{
|
||||
value: 'row-reverse',
|
||||
label: t('appearance.positionAppName.dropdown.right') as string,
|
||||
@@ -94,7 +94,8 @@ export const AppearanceTab = ({
|
||||
},
|
||||
{
|
||||
value: 'row',
|
||||
label: t('appearance.positionAppName.dropdown.left') as string },
|
||||
label: t('appearance.positionAppName.dropdown.left') as string,
|
||||
},
|
||||
]}
|
||||
{...form.getInputProps('appearance.positionAppName')}
|
||||
onChange={(value) => {
|
||||
|
||||
@@ -1,9 +1,18 @@
|
||||
import { Text, TextInput, Tooltip, Stack, Switch, Tabs, Group, useMantineTheme, HoverCard } from '@mantine/core';
|
||||
import {
|
||||
Group,
|
||||
HoverCard,
|
||||
Stack,
|
||||
Switch,
|
||||
Tabs,
|
||||
Text,
|
||||
TextInput,
|
||||
Tooltip,
|
||||
useMantineTheme,
|
||||
} from '@mantine/core';
|
||||
import { UseFormReturnType } from '@mantine/form';
|
||||
import { useTranslation } from 'next-i18next';
|
||||
|
||||
import { InfoCard } from '~/components/InfoCard/InfoCard';
|
||||
import { AppType } from '~/types/app';
|
||||
import { InfoCard } from '~/components/InfoCard/InfoCard'
|
||||
|
||||
interface BehaviourTabProps {
|
||||
form: UseFormReturnType<AppType, (values: AppType) => AppType>;
|
||||
@@ -19,7 +28,7 @@ export const BehaviourTab = ({ form }: BehaviourTabProps) => {
|
||||
<Switch
|
||||
label={t('behaviour.isOpeningNewTab.label')}
|
||||
description={t('behaviour.isOpeningNewTab.description')}
|
||||
styles={{ label: { fontWeight: 500, }, description: { marginTop: 0, }, }}
|
||||
styles={{ label: { fontWeight: 500 }, description: { marginTop: 0 } }}
|
||||
{...form.getInputProps('behaviour.isOpeningNewTab', { type: 'checkbox' })}
|
||||
/>
|
||||
<Stack spacing="0.25rem">
|
||||
@@ -27,13 +36,11 @@ export const BehaviourTab = ({ form }: BehaviourTabProps) => {
|
||||
<Text size="0.875rem" weight={500}>
|
||||
{t('behaviour.tooltipDescription.label')}
|
||||
</Text>
|
||||
<InfoCard message={t('behaviour.tooltipDescription.description')}/>
|
||||
<InfoCard message={t('behaviour.tooltipDescription.description')} />
|
||||
</Group>
|
||||
<TextInput
|
||||
{...form.getInputProps('behaviour.tooltipDescription')}
|
||||
/>
|
||||
<TextInput {...form.getInputProps('behaviour.tooltipDescription')} />
|
||||
</Stack>
|
||||
</Stack>
|
||||
</Tabs.Panel>
|
||||
);
|
||||
};
|
||||
};
|
||||
|
||||
@@ -2,8 +2,8 @@ import { Stack, Tabs, Text, TextInput } from '@mantine/core';
|
||||
import { UseFormReturnType } from '@mantine/form';
|
||||
import { IconClick, IconCursorText, IconLink } from '@tabler/icons-react';
|
||||
import { useTranslation } from 'next-i18next';
|
||||
|
||||
import { AppType } from '~/types/app';
|
||||
|
||||
import { EditAppModalTab } from '../type';
|
||||
|
||||
interface GeneralTabProps {
|
||||
@@ -51,7 +51,7 @@ export const GeneralTab = ({ form, openTab }: GeneralTabProps) => {
|
||||
<Text color="red" mt="sm" size="sm">
|
||||
{t('behaviour.customProtocolWarning')}
|
||||
</Text>
|
||||
)}
|
||||
)}
|
||||
</Stack>
|
||||
</Tabs.Panel>
|
||||
);
|
||||
|
||||
@@ -15,7 +15,6 @@ import {
|
||||
import { Icon } from '@tabler/icons-react';
|
||||
import { useTranslation } from 'next-i18next';
|
||||
import { useState } from 'react';
|
||||
|
||||
import { AppIntegrationPropertyAccessabilityType } from '~/types/app';
|
||||
|
||||
interface GenericSecretInputProps {
|
||||
|
||||
@@ -3,7 +3,6 @@ import { Group, Image, Select, SelectItem, Text } from '@mantine/core';
|
||||
import { UseFormReturnType } from '@mantine/form';
|
||||
import { useTranslation } from 'next-i18next';
|
||||
import { forwardRef } from 'react';
|
||||
|
||||
import {
|
||||
AppIntegrationPropertyType,
|
||||
AppIntegrationType,
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
import { Stack } from '@mantine/core';
|
||||
import { UseFormReturnType } from '@mantine/form';
|
||||
import { IconKey } from '@tabler/icons-react';
|
||||
|
||||
import {
|
||||
AppIntegrationPropertyType,
|
||||
AppType,
|
||||
@@ -9,6 +8,7 @@ import {
|
||||
integrationFieldDefinitions,
|
||||
integrationFieldProperties,
|
||||
} from '~/types/app';
|
||||
|
||||
import { GenericSecretInput } from '../InputElements/GenericSecretInput';
|
||||
|
||||
interface IntegrationOptionsRendererProps {
|
||||
|
||||
@@ -2,8 +2,8 @@ import { Alert, Divider, Tabs, Text } from '@mantine/core';
|
||||
import { UseFormReturnType } from '@mantine/form';
|
||||
import { IconAlertTriangle } from '@tabler/icons-react';
|
||||
import { Trans, useTranslation } from 'next-i18next';
|
||||
|
||||
import { AppType } from '~/types/app';
|
||||
|
||||
import { IntegrationSelector } from './Components/InputElements/IntegrationSelector';
|
||||
import { IntegrationOptionsRenderer } from './Components/IntegrationOptionsRenderer/IntegrationOptionsRenderer';
|
||||
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
import { MultiSelect, Stack, Switch, Tabs } from '@mantine/core';
|
||||
import { UseFormReturnType } from '@mantine/form';
|
||||
import { useTranslation } from 'next-i18next';
|
||||
|
||||
import { StatusCodes } from '~/tools/acceptableStatusCodes';
|
||||
import { AppType } from '~/types/app';
|
||||
|
||||
@@ -20,7 +19,7 @@ export const NetworkTab = ({ form }: NetworkTabProps) => {
|
||||
<Switch
|
||||
label={t('network.statusChecker.label')}
|
||||
description={t('network.statusChecker.description')}
|
||||
styles={{ label: { fontWeight: 500, }, description: { marginTop: 0, }, }}
|
||||
styles={{ label: { fontWeight: 500 }, description: { marginTop: 0 } }}
|
||||
defaultChecked={form.values.network.enabledStatusChecker}
|
||||
{...form.getInputProps('network.enabledStatusChecker')}
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user