Reorder imports by running biome check --fix

This commit is contained in:
Quentin Gliech
2024-10-22 11:03:49 +02:00
parent 5f0dc9545b
commit 0a776d64f3
32 changed files with 56 additions and 56 deletions

View File

@@ -5,14 +5,14 @@
// Please see LICENSE in the repository root for full details.
import { ArgTypes, Decorator, Parameters, Preview } from "@storybook/react";
import { useLayoutEffect } from "react";
import { TooltipProvider } from "@vector-im/compound-web";
import { useLayoutEffect } from "react";
import "../src/shared.css";
import i18n from "../src/i18n";
import localazyMetadata from "./locales";
import { DummyRouter } from "../src/test-utils/router";
import localazyMetadata from "./locales";
export const parameters: Parameters = {
controls: {

View File

@@ -5,7 +5,7 @@
// Please see LICENSE in the repository root for full details.
import type { Meta, StoryObj } from "@storybook/react";
import { H1, H5, Body } from "@vector-im/compound-web";
import { Body, H1, H5 } from "@vector-im/compound-web";
import Block from "./Block";

View File

@@ -6,8 +6,8 @@
// @vitest-environment happy-dom
import { render, cleanup } from "@testing-library/react";
import { describe, expect, it, afterEach } from "vitest";
import { cleanup, render } from "@testing-library/react";
import { afterEach, describe, expect, it } from "vitest";
import { makeFragmentData } from "../../gql/fragment-masking";

View File

@@ -8,7 +8,7 @@
import { create } from "react-test-renderer";
import { Provider } from "urql";
import { describe, expect, it, beforeAll } from "vitest";
import { beforeAll, describe, expect, it } from "vitest";
import { never } from "wonka";
import { makeFragmentData } from "../gql";

View File

@@ -5,10 +5,10 @@
// Please see LICENSE in the repository root for full details.
import {
differenceInHours,
formatISO,
intlFormat,
intlFormatDistance,
differenceInHours,
parseISO,
} from "date-fns";

View File

@@ -7,7 +7,7 @@
import { action } from "@storybook/addon-actions";
import type { Meta, StoryObj } from "@storybook/react";
import { Dialog, Title, Description } from "./Dialog";
import { Description, Dialog, Title } from "./Dialog";
const Template: React.FC<{
title: string;

View File

@@ -5,13 +5,13 @@
// Please see LICENSE in the repository root for full details.
import {
Root as DialogRoot,
Trigger,
Portal,
Close,
Title as DialogTitle,
Overlay as DialogOverlay,
Content as DialogContent,
Overlay as DialogOverlay,
Root as DialogRoot,
Title as DialogTitle,
Portal,
Trigger,
} from "@radix-ui/react-dialog";
import IconClose from "@vector-im/compound-design-tokens/assets/web/icons/close";
import { Glass, Tooltip } from "@vector-im/compound-web";

View File

@@ -4,7 +4,7 @@
// SPDX-License-Identifier: AGPL-3.0-only
// Please see LICENSE in the repository root for full details.
import { ErrorInfo, ReactNode, PureComponent } from "react";
import { ErrorInfo, PureComponent, ReactNode } from "react";
import GenericError from "./GenericError";
import Layout from "./Layout";

View File

@@ -8,7 +8,7 @@
import { create } from "react-test-renderer";
import { Provider } from "urql";
import { describe, expect, it, beforeAll } from "vitest";
import { beforeAll, describe, expect, it } from "vitest";
import { never } from "wonka";
import { makeFragmentData } from "../gql";

View File

@@ -6,8 +6,8 @@
// @vitest-environment happy-dom
import { render, cleanup } from "@testing-library/react";
import { describe, it, expect, afterEach } from "vitest";
import { cleanup, render } from "@testing-library/react";
import { afterEach, describe, expect, it } from "vitest";
import ClientAvatar from "./ClientAvatar";

View File

@@ -7,8 +7,8 @@
// @vitest-environment happy-dom
import { composeStory } from "@storybook/react";
import { render, cleanup } from "@testing-library/react";
import { describe, it, expect, afterEach } from "vitest";
import { cleanup, render } from "@testing-library/react";
import { afterEach, describe, expect, it } from "vitest";
import Meta, { Unknown, Pc, Mobile, Tablet } from "./DeviceTypeIcon.stories";

View File

@@ -7,8 +7,8 @@
// @vitest-environment happy-dom
import { composeStory } from "@storybook/react";
import { render, cleanup } from "@testing-library/react";
import { describe, afterEach, expect, it, beforeAll } from "vitest";
import { cleanup, render } from "@testing-library/react";
import { afterEach, beforeAll, describe, expect, it } from "vitest";
import { mockLocale } from "../../test-utils/mockLocale";

View File

@@ -6,9 +6,9 @@
// @vitest-environment happy-dom
import { render, cleanup } from "@testing-library/react";
import { cleanup, render } from "@testing-library/react";
import { Provider } from "urql";
import { describe, expect, it, afterEach, beforeAll } from "vitest";
import { afterEach, beforeAll, describe, expect, it } from "vitest";
import { never } from "wonka";
import { makeFragmentData } from "../../gql";

View File

@@ -6,9 +6,9 @@
// @vitest-environment happy-dom
import { render, cleanup } from "@testing-library/react";
import { cleanup, render } from "@testing-library/react";
import { Provider } from "urql";
import { describe, expect, it, afterEach, beforeAll } from "vitest";
import { afterEach, beforeAll, describe, expect, it } from "vitest";
import { never } from "wonka";
import { makeFragmentData } from "../../gql";

View File

@@ -7,8 +7,8 @@
// @vitest-environment happy-dom
import { composeStory } from "@storybook/react";
import { render, cleanup } from "@testing-library/react";
import { describe, it, expect, afterEach } from "vitest";
import { cleanup, render } from "@testing-library/react";
import { afterEach, describe, expect, it } from "vitest";
import { DummyRouter } from "../../test-utils/router";

View File

@@ -4,7 +4,7 @@
// SPDX-License-Identifier: AGPL-3.0-only
// Please see LICENSE in the repository root for full details.
import { createElement, Children } from "react";
import { Children, createElement } from "react";
type Variant = "headline" | "title" | "subtitle" | "body" | "caption" | "micro";

View File

@@ -6,8 +6,8 @@
// @vitest-environment happy-dom
import { render, cleanup, fireEvent } from "@testing-library/react";
import { describe, it, expect, afterEach } from "vitest";
import { cleanup, fireEvent, render } from "@testing-library/react";
import { afterEach, describe, expect, it } from "vitest";
import { makeFragmentData } from "../../gql/fragment-masking";
import { DummyRouter } from "../../test-utils/router";

View File

@@ -8,7 +8,7 @@ import { Alert } from "@vector-im/compound-web";
import { useEffect, useState } from "react";
import { useTranslation } from "react-i18next";
import { FragmentType, useFragment, graphql } from "../../gql";
import { FragmentType, graphql, useFragment } from "../../gql";
import { Link } from "../Link";
import styles from "./UnverifiedEmailAlert.module.css";

View File

@@ -6,7 +6,7 @@
import type { Meta, StoryObj } from "@storybook/react";
import { Provider } from "urql";
import { fromValue, delay, pipe } from "wonka";
import { delay, fromValue, pipe } from "wonka";
import { makeFragmentData } from "../../gql";
import {

View File

@@ -7,12 +7,12 @@
import IconClose from "@vector-im/compound-design-tokens/assets/web/icons/close";
import IconEdit from "@vector-im/compound-design-tokens/assets/web/icons/edit";
import {
Text,
Avatar,
IconButton,
Tooltip,
Button,
Form,
IconButton,
Text,
Tooltip,
} from "@vector-im/compound-web";
import { ComponentPropsWithoutRef, forwardRef, useRef, useState } from "react";
import { useTranslation } from "react-i18next";

View File

@@ -6,8 +6,8 @@
// @vitest-environment happy-dom
import { render, cleanup } from "@testing-library/react";
import { describe, expect, it, afterEach } from "vitest";
import { cleanup, render } from "@testing-library/react";
import { afterEach, describe, expect, it } from "vitest";
import { makeFragmentData } from "../../gql";
import { DummyRouter } from "../../test-utils/router";

View File

@@ -4,7 +4,7 @@
// SPDX-License-Identifier: AGPL-3.0-only
// Please see LICENSE in the repository root for full details.
import { Text, H5 } from "@vector-im/compound-web";
import { H5, Text } from "@vector-im/compound-web";
import { useTranslation } from "react-i18next";
import { FragmentType, graphql, useFragment } from "../../gql";

View File

@@ -7,7 +7,7 @@
import { useLinkProps, useNavigate } from "@tanstack/react-router";
import IconArrowLeft from "@vector-im/compound-design-tokens/assets/web/icons/arrow-left";
import IconSend from "@vector-im/compound-design-tokens/assets/web/icons/send-solid";
import { Button, Form, Alert, H1, Text } from "@vector-im/compound-web";
import { Alert, Button, Form, H1, Text } from "@vector-im/compound-web";
import { useRef } from "react";
import { Trans, useTranslation } from "react-i18next";
import { useMutation } from "urql";

View File

@@ -5,12 +5,12 @@
// Please see LICENSE in the repository root for full details.
import {
default as i18n,
BackendModule,
InitOptions,
LanguageDetectorModule,
BackendModule,
ReadCallback,
ResourceKey,
default as i18n,
} from "i18next";
import { initReactI18next } from "react-i18next";

View File

@@ -6,7 +6,7 @@
import { RouterProvider, createRouter } from "@tanstack/react-router";
import { TooltipProvider } from "@vector-im/compound-web";
import { Suspense, StrictMode } from "react";
import { StrictMode, Suspense } from "react";
import { createRoot } from "react-dom/client";
import { I18nextProvider } from "react-i18next";
import { Provider as UrqlProvider } from "urql";

View File

@@ -13,17 +13,17 @@ import { createFileRoute } from '@tanstack/react-router'
// Import Routes
import { Route as rootRoute } from './routes/__root'
import { Route as ResetCrossSigningImport } from './routes/reset-cross-signing'
import { Route as AccountImport } from './routes/_account'
import { Route as AccountIndexImport } from './routes/_account.index'
import { Route as DevicesSplatImport } from './routes/devices.$'
import { Route as ClientsIdImport } from './routes/clients.$id'
import { Route as PasswordRecoveryIndexImport } from './routes/password.recovery.index'
import { Route as PasswordChangeIndexImport } from './routes/password.change.index'
import { Route as AccountSessionsIndexImport } from './routes/_account.sessions.index'
import { Route as EmailsIdVerifyImport } from './routes/emails.$id.verify'
import { Route as AccountSessionsBrowsersImport } from './routes/_account.sessions.browsers'
import { Route as AccountSessionsIdImport } from './routes/_account.sessions.$id'
import { Route as AccountSessionsBrowsersImport } from './routes/_account.sessions.browsers'
import { Route as AccountSessionsIndexImport } from './routes/_account.sessions.index'
import { Route as ClientsIdImport } from './routes/clients.$id'
import { Route as DevicesSplatImport } from './routes/devices.$'
import { Route as EmailsIdVerifyImport } from './routes/emails.$id.verify'
import { Route as PasswordChangeIndexImport } from './routes/password.change.index'
import { Route as PasswordRecoveryIndexImport } from './routes/password.recovery.index'
import { Route as ResetCrossSigningImport } from './routes/reset-cross-signing'
// Create Virtual Routes

View File

@@ -4,7 +4,7 @@
// SPDX-License-Identifier: AGPL-3.0-only
// Please see LICENSE in the repository root for full details.
import { createRootRouteWithContext, Outlet } from "@tanstack/react-router";
import { Outlet, createRootRouteWithContext } from "@tanstack/react-router";
import { TanStackRouterDevtools } from "@tanstack/router-devtools";
import { Client } from "urql";

View File

@@ -19,7 +19,7 @@ import BrowserSessionsOverview from "../components/UserSessionsOverview/BrowserS
import { usePages } from "../pagination";
import { getNinetyDaysAgo } from "../utils/dates";
import { QUERY, LIST_QUERY } from "./_account.sessions.index";
import { LIST_QUERY, QUERY } from "./_account.sessions.index";
const PAGE_SIZE = 6;

View File

@@ -13,10 +13,10 @@ import IconKeyOffSolid from "@vector-im/compound-design-tokens/assets/web/icons/
import { Button, Text } from "@vector-im/compound-web";
import {
ForwardRefExoticComponent,
MouseEvent,
RefAttributes,
SVGProps,
useState,
MouseEvent,
} from "react";
import { useTranslation } from "react-i18next";
import { useMutation, useQuery } from "urql";

View File

@@ -4,7 +4,7 @@
// SPDX-License-Identifier: AGPL-3.0-only
// Please see LICENSE in the repository root for full details.
import { notFound, createFileRoute } from "@tanstack/react-router";
import { createFileRoute, notFound } from "@tanstack/react-router";
import { zodSearchValidator } from "@tanstack/router-zod-adapter";
import * as z from "zod";

View File

@@ -5,7 +5,7 @@
* Please see LICENSE in the repository root for full details.
*/
import { describe, it, expect } from "vitest";
import { describe, expect, it } from "vitest";
import { getDeviceIdFromScope } from "./deviceIdFromScope";

View File

@@ -4,8 +4,8 @@
// SPDX-License-Identifier: AGPL-3.0-only
// Please see LICENSE in the repository root for full details.
import { readFile, writeFile } from "fs/promises";
import { resolve } from "path";
import { readFile, writeFile } from "fs/promises";
import { codecovVitePlugin } from "@codecov/vite-plugin";
import { TanStackRouterVite as tanStackRouter } from "@tanstack/router-vite-plugin";