mirror of
https://github.com/aykhans/slash-e.git
synced 2025-07-07 05:32:35 +00:00
chore: add sort import plugin
This commit is contained in:
@ -1,8 +1,8 @@
|
||||
import { useEffect, useState } from "react";
|
||||
import { Outlet } from "react-router-dom";
|
||||
import DemoBanner from "./components/DemoBanner";
|
||||
import { globalService } from "./services";
|
||||
import useUserStore from "./stores/v1/user";
|
||||
import DemoBanner from "./components/DemoBanner";
|
||||
|
||||
function App() {
|
||||
const userStore = useUserStore();
|
||||
|
@ -2,10 +2,10 @@ import { Button, Divider, Input, Modal, ModalDialog, Radio, RadioGroup, Textarea
|
||||
import classnames from "classnames";
|
||||
import { isUndefined } from "lodash-es";
|
||||
import { useEffect, useState } from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import { toast } from "react-hot-toast";
|
||||
import { shortcutService } from "../services";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import useLoading from "../hooks/useLoading";
|
||||
import { shortcutService } from "../services";
|
||||
import Icon from "./Icon";
|
||||
|
||||
interface Props {
|
||||
|
@ -1,7 +1,7 @@
|
||||
import { Button, Modal, ModalDialog } from "@mui/joy";
|
||||
import { QRCodeCanvas } from "qrcode.react";
|
||||
import { useRef } from "react";
|
||||
import { toast } from "react-hot-toast";
|
||||
import { QRCodeCanvas } from "qrcode.react";
|
||||
import { absolutifyLink } from "../helpers/utils";
|
||||
import Icon from "./Icon";
|
||||
|
||||
|
@ -3,9 +3,9 @@ import { useState } from "react";
|
||||
import { Link } from "react-router-dom";
|
||||
import * as api from "../helpers/api";
|
||||
import useUserStore from "../stores/v1/user";
|
||||
import Icon from "./Icon";
|
||||
import Dropdown from "./common/Dropdown";
|
||||
import AboutDialog from "./AboutDialog";
|
||||
import Dropdown from "./common/Dropdown";
|
||||
import Icon from "./Icon";
|
||||
|
||||
const Header: React.FC = () => {
|
||||
const currentUser = useUserStore().getCurrentUser();
|
||||
|
@ -1,19 +1,19 @@
|
||||
import { Divider, Tooltip } from "@mui/joy";
|
||||
import { Tooltip } from "@mui/joy";
|
||||
import copy from "copy-to-clipboard";
|
||||
import { useEffect, useState } from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import toast from "react-hot-toast";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import { absolutifyLink } from "../helpers/utils";
|
||||
import { shortcutService } from "../services";
|
||||
import useFaviconStore from "../stores/v1/favicon";
|
||||
import useViewStore from "../stores/v1/view";
|
||||
import useUserStore from "../stores/v1/user";
|
||||
import { absolutifyLink } from "../helpers/utils";
|
||||
import useViewStore from "../stores/v1/view";
|
||||
import { showCommonDialog } from "./Alert";
|
||||
import Icon from "./Icon";
|
||||
import Dropdown from "./common/Dropdown";
|
||||
import VisibilityIcon from "./VisibilityIcon";
|
||||
import GenerateQRCodeDialog from "./GenerateQRCodeDialog";
|
||||
import AnalyticsDialog from "./AnalyticsDialog";
|
||||
import Dropdown from "./common/Dropdown";
|
||||
import GenerateQRCodeDialog from "./GenerateQRCodeDialog";
|
||||
import Icon from "./Icon";
|
||||
import VisibilityIcon from "./VisibilityIcon";
|
||||
|
||||
interface Props {
|
||||
shortcut: Shortcut;
|
||||
@ -115,7 +115,6 @@ const ShortcutView = (props: Props) => {
|
||||
>
|
||||
<Icon.BarChart2 className="w-4 h-auto mr-2" /> Analytics
|
||||
</button>
|
||||
<Divider className="!my-1" />
|
||||
<button
|
||||
className="w-full px-2 flex flex-row justify-start items-center text-left leading-8 cursor-pointer rounded text-red-600 hover:bg-gray-100 disabled:cursor-not-allowed disabled:bg-gray-100 disabled:opacity-60"
|
||||
onClick={() => {
|
||||
|
@ -1,8 +1,8 @@
|
||||
import classNames from "classnames";
|
||||
import { useState } from "react";
|
||||
import useViewStore from "../stores/v1/view";
|
||||
import CreateShortcutDialog from "./CreateShortcutDialog";
|
||||
import ShortcutView from "./ShortcutView";
|
||||
import useViewStore from "../stores/v1/view";
|
||||
import classNames from "classnames";
|
||||
|
||||
interface Props {
|
||||
shortcutList: Shortcut[];
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { Select, Option, Button, Divider } from "@mui/joy";
|
||||
import { Button, Divider, Option, Select } from "@mui/joy";
|
||||
import { toast } from "react-hot-toast";
|
||||
import useViewStore from "../stores/v1/view";
|
||||
import Dropdown from "./common/Dropdown";
|
||||
|
@ -1,7 +1,7 @@
|
||||
import { useEffect, useState } from "react";
|
||||
import { Button } from "@mui/joy";
|
||||
import CreateUserDialog from "../CreateUserDialog";
|
||||
import { useEffect, useState } from "react";
|
||||
import useUserStore from "../../stores/v1/user";
|
||||
import CreateUserDialog from "../CreateUserDialog";
|
||||
|
||||
const MemberSection = () => {
|
||||
const userStore = useUserStore();
|
||||
|
@ -1,7 +1,7 @@
|
||||
import { useEffect } from "react";
|
||||
import { Outlet, useNavigate } from "react-router-dom";
|
||||
import useUserStore from "../stores/v1/user";
|
||||
import Header from "../components/Header";
|
||||
import useUserStore from "../stores/v1/user";
|
||||
|
||||
const Root: React.FC = () => {
|
||||
const navigate = useNavigate();
|
||||
|
@ -3,8 +3,8 @@ import { createRoot } from "react-dom/client";
|
||||
import { Toaster } from "react-hot-toast";
|
||||
import { Provider } from "react-redux";
|
||||
import { RouterProvider } from "react-router-dom";
|
||||
import store from "./stores";
|
||||
import router from "./routers";
|
||||
import store from "./stores";
|
||||
import "./i18n";
|
||||
import "./css/index.css";
|
||||
|
||||
|
@ -1,8 +1,8 @@
|
||||
import { Button } from "@mui/joy";
|
||||
import { useState } from "react";
|
||||
import useUserStore from "../stores/v1/user";
|
||||
import ChangePasswordDialog from "../components/ChangePasswordDialog";
|
||||
import EditUserinfoDialog from "../components/EditUserinfoDialog";
|
||||
import useUserStore from "../stores/v1/user";
|
||||
|
||||
const Account: React.FC = () => {
|
||||
const currentUser = useUserStore().getCurrentUser();
|
||||
|
@ -1,16 +1,16 @@
|
||||
import { Button, Input } from "@mui/joy";
|
||||
import { useEffect, useState } from "react";
|
||||
import { shortcutService } from "../services";
|
||||
import { useAppSelector } from "../stores";
|
||||
import useViewStore, { getFilteredShortcutList, getOrderedShortcutList } from "../stores/v1/view";
|
||||
import useUserStore from "../stores/v1/user";
|
||||
import useLoading from "../hooks/useLoading";
|
||||
import Icon from "../components/Icon";
|
||||
import ShortcutsContainer from "../components/ShortcutsContainer";
|
||||
import CreateShortcutDialog from "../components/CreateShortcutDialog";
|
||||
import FilterView from "../components/FilterView";
|
||||
import ViewSetting from "../components/ViewSetting";
|
||||
import Icon from "../components/Icon";
|
||||
import Navigator from "../components/Navigator";
|
||||
import ShortcutsContainer from "../components/ShortcutsContainer";
|
||||
import ViewSetting from "../components/ViewSetting";
|
||||
import useLoading from "../hooks/useLoading";
|
||||
import { shortcutService } from "../services";
|
||||
import { useAppSelector } from "../stores";
|
||||
import useUserStore from "../stores/v1/user";
|
||||
import useViewStore, { getFilteredShortcutList, getOrderedShortcutList } from "../stores/v1/view";
|
||||
|
||||
interface State {
|
||||
showCreateShortcutDialog: boolean;
|
||||
|
@ -1,7 +1,7 @@
|
||||
import useUserStore from "../stores/v1/user";
|
||||
import AccountSection from "../components/setting/AccountSection";
|
||||
import WorkspaceSection from "../components/setting/WorkspaceSection";
|
||||
import UserSection from "../components/setting/UserSection";
|
||||
import WorkspaceSection from "../components/setting/WorkspaceSection";
|
||||
import useUserStore from "../stores/v1/user";
|
||||
|
||||
const Setting: React.FC = () => {
|
||||
const currentUser = useUserStore().getCurrentUser();
|
||||
|
@ -1,10 +1,10 @@
|
||||
import { Button, Input } from "@mui/joy";
|
||||
import React, { FormEvent, useEffect, useState } from "react";
|
||||
import { Link, useNavigate } from "react-router-dom";
|
||||
import { toast } from "react-hot-toast";
|
||||
import { Link, useNavigate } from "react-router-dom";
|
||||
import * as api from "../helpers/api";
|
||||
import { useAppSelector } from "../stores";
|
||||
import useLoading from "../hooks/useLoading";
|
||||
import { useAppSelector } from "../stores";
|
||||
import useUserStore from "../stores/v1/user";
|
||||
|
||||
const SignIn: React.FC = () => {
|
||||
|
@ -1,10 +1,10 @@
|
||||
import { Button, Input } from "@mui/joy";
|
||||
import React, { FormEvent, useEffect, useState } from "react";
|
||||
import { Link, useNavigate } from "react-router-dom";
|
||||
import { toast } from "react-hot-toast";
|
||||
import { Link, useNavigate } from "react-router-dom";
|
||||
import * as api from "../helpers/api";
|
||||
import { globalService } from "../services";
|
||||
import useLoading from "../hooks/useLoading";
|
||||
import { globalService } from "../services";
|
||||
import useUserStore from "../stores/v1/user";
|
||||
|
||||
const SignUp: React.FC = () => {
|
||||
|
@ -1,10 +1,10 @@
|
||||
import { createBrowserRouter } from "react-router-dom";
|
||||
import App from "../App";
|
||||
import Root from "../layouts/Root";
|
||||
import SignIn from "../pages/SignIn";
|
||||
import SignUp from "../pages/SignUp";
|
||||
import Home from "../pages/Home";
|
||||
import Setting from "../pages/Setting";
|
||||
import App from "../App";
|
||||
import SignIn from "../pages/SignIn";
|
||||
import SignUp from "../pages/SignUp";
|
||||
|
||||
const router = createBrowserRouter([
|
||||
{
|
||||
|
Reference in New Issue
Block a user