Refactor folder structure (#4759)

This commit is contained in:
Satish Gandham 2024-06-11 14:39:52 +05:30 committed by GitHub
parent a0e16692da
commit 346bc2afe2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1218 changed files with 187 additions and 177 deletions

View File

@ -9,6 +9,9 @@ module.exports = {
relative: true, relative: true,
files: [ files: [
"./app/**/*.{js,ts,jsx,tsx}", "./app/**/*.{js,ts,jsx,tsx}",
"./core/**/*.{js,ts,jsx,tsx}",
"./ce/**/*.{js,ts,jsx,tsx}",
"./ee/**/*.{js,ts,jsx,tsx}",
"./components/**/*.tsx", "./components/**/*.tsx",
"./constants/**/*.{js,ts,jsx,tsx}", "./constants/**/*.{js,ts,jsx,tsx}",
"./layouts/**/*.tsx", "./layouts/**/*.tsx",

View File

@ -12,7 +12,7 @@ import { CycleLayoutRoot } from "@/components/issues/issue-layouts";
import { useCycle, useProject } from "@/hooks/store"; import { useCycle, useProject } from "@/hooks/store";
import useLocalStorage from "@/hooks/use-local-storage"; import useLocalStorage from "@/hooks/use-local-storage";
// assets // assets
import emptyCycle from "public/empty-state/cycle.svg"; import emptyCycle from "@/public/empty-state/cycle.svg";
const CycleDetailPage = observer(() => { const CycleDetailPage = observer(() => {
// router // router

View File

@ -12,7 +12,7 @@ import { ModuleDetailsSidebar } from "@/components/modules";
import { useModule, useProject } from "@/hooks/store"; import { useModule, useProject } from "@/hooks/store";
import useLocalStorage from "@/hooks/use-local-storage"; import useLocalStorage from "@/hooks/use-local-storage";
// assets // assets
import emptyModule from "public/empty-state/module.svg"; import emptyModule from "@/public/empty-state/module.svg";
const ModuleIssuesPage = observer(() => { const ModuleIssuesPage = observer(() => {
// router // router

View File

@ -10,7 +10,7 @@ import { ProjectViewLayoutRoot } from "@/components/issues";
// hooks // hooks
import { useProject, useProjectView } from "@/hooks/store"; import { useProject, useProjectView } from "@/hooks/store";
// assets // assets
import emptyView from "public/empty-state/view.svg"; import emptyView from "@/public/empty-state/view.svg";
const ProjectViewIssuesPage = observer(() => { const ProjectViewIssuesPage = observer(() => {
// router // router

View File

@ -21,12 +21,12 @@ import useTimer from "@/hooks/use-timer";
// wrappers // wrappers
import { AuthenticationWrapper } from "@/lib/wrappers"; import { AuthenticationWrapper } from "@/lib/wrappers";
// services // services
import { AuthService } from "@/services/auth.service";
// images // images
import PlaneBackgroundPatternDark from "public/auth/background-pattern-dark.svg"; import PlaneBackgroundPatternDark from "@/public/auth/background-pattern-dark.svg";
import PlaneBackgroundPattern from "public/auth/background-pattern.svg"; import PlaneBackgroundPattern from "@/public/auth/background-pattern.svg";
import BlackHorizontalLogo from "public/plane-logos/black-horizontal-with-blue-logo.png"; import BlackHorizontalLogo from "@/public/plane-logos/black-horizontal-with-blue-logo.png";
import WhiteHorizontalLogo from "public/plane-logos/white-horizontal-with-blue-logo.png"; import WhiteHorizontalLogo from "@/public/plane-logos/white-horizontal-with-blue-logo.png";
import { AuthService } from "@/services/auth.service";
type TForgotPasswordFormValues = { type TForgotPasswordFormValues = {
email: string; email: string;

View File

@ -24,12 +24,12 @@ import { getPasswordStrength } from "@/helpers/password.helper";
// wrappers // wrappers
import { AuthenticationWrapper } from "@/lib/wrappers"; import { AuthenticationWrapper } from "@/lib/wrappers";
// services // services
import { AuthService } from "@/services/auth.service";
// images // images
import PlaneBackgroundPatternDark from "public/auth/background-pattern-dark.svg"; import PlaneBackgroundPatternDark from "@/public/auth/background-pattern-dark.svg";
import PlaneBackgroundPattern from "public/auth/background-pattern.svg"; import PlaneBackgroundPattern from "@/public/auth/background-pattern.svg";
import BlackHorizontalLogo from "public/plane-logos/black-horizontal-with-blue-logo.png"; import BlackHorizontalLogo from "@/public/plane-logos/black-horizontal-with-blue-logo.png";
import WhiteHorizontalLogo from "public/plane-logos/white-horizontal-with-blue-logo.png"; import WhiteHorizontalLogo from "@/public/plane-logos/white-horizontal-with-blue-logo.png";
import { AuthService } from "@/services/auth.service";
type TResetPasswordFormValues = { type TResetPasswordFormValues = {
email: string; email: string;

View File

@ -20,12 +20,12 @@ import { useUser } from "@/hooks/store";
// wrappers // wrappers
import { AuthenticationWrapper } from "@/lib/wrappers"; import { AuthenticationWrapper } from "@/lib/wrappers";
// services // services
import { AuthService } from "@/services/auth.service";
// images // images
import PlaneBackgroundPatternDark from "public/auth/background-pattern-dark.svg"; import PlaneBackgroundPatternDark from "@/public/auth/background-pattern-dark.svg";
import PlaneBackgroundPattern from "public/auth/background-pattern.svg"; import PlaneBackgroundPattern from "@/public/auth/background-pattern.svg";
import BlackHorizontalLogo from "public/plane-logos/black-horizontal-with-blue-logo.png"; import BlackHorizontalLogo from "@/public/plane-logos/black-horizontal-with-blue-logo.png";
import WhiteHorizontalLogo from "public/plane-logos/white-horizontal-with-blue-logo.png"; import WhiteHorizontalLogo from "@/public/plane-logos/white-horizontal-with-blue-logo.png";
import { AuthService } from "@/services/auth.service";
type TResetPasswordFormValues = { type TResetPasswordFormValues = {
email: string; email: string;

View File

@ -14,8 +14,8 @@ import { useUser, useUserProfile } from "@/hooks/store";
// wrappers // wrappers
import { AuthenticationWrapper } from "@/lib/wrappers"; import { AuthenticationWrapper } from "@/lib/wrappers";
// images // images
import BlackHorizontalLogo from "public/plane-logos/black-horizontal-with-blue-logo.png"; import BlackHorizontalLogo from "@/public/plane-logos/black-horizontal-with-blue-logo.png";
import WhiteHorizontalLogo from "public/plane-logos/white-horizontal-with-blue-logo.png"; import WhiteHorizontalLogo from "@/public/plane-logos/white-horizontal-with-blue-logo.png";
const CreateWorkspacePage = observer(() => { const CreateWorkspacePage = observer(() => {
// router // router

View File

@ -25,11 +25,11 @@ import { getUserRole } from "@/helpers/user.helper";
import { useEventTracker, useUser, useUserProfile, useWorkspace } from "@/hooks/store"; import { useEventTracker, useUser, useUserProfile, useWorkspace } from "@/hooks/store";
// services // services
import { AuthenticationWrapper } from "@/lib/wrappers"; import { AuthenticationWrapper } from "@/lib/wrappers";
import { WorkspaceService } from "@/services/workspace.service";
// images // images
import emptyInvitation from "public/empty-state/invitation.svg"; import emptyInvitation from "@/public/empty-state/invitation.svg";
import BlackHorizontalLogo from "public/plane-logos/black-horizontal-with-blue-logo.png"; import BlackHorizontalLogo from "@/public/plane-logos/black-horizontal-with-blue-logo.png";
import WhiteHorizontalLogo from "public/plane-logos/white-horizontal-with-blue-logo.png"; import WhiteHorizontalLogo from "@/public/plane-logos/white-horizontal-with-blue-logo.png";
import { WorkspaceService } from "@/services/workspace.service";
const workspaceService = new WorkspaceService(); const workspaceService = new WorkspaceService();
@ -153,7 +153,8 @@ const UserInvitationsPage = observer(() => {
return ( return (
<div <div
key={invitation.id} key={invitation.id}
className={`flex cursor-pointer items-center gap-2 rounded border px-3.5 py-5 ${isSelected className={`flex cursor-pointer items-center gap-2 rounded border px-3.5 py-5 ${
isSelected
? "border-custom-primary-100" ? "border-custom-primary-100"
: "border-custom-border-200 hover:bg-custom-background-80" : "border-custom-border-200 hover:bg-custom-background-80"
}`} }`}

View File

@ -7,7 +7,7 @@ import Link from "next/link";
// ui // ui
import { Button } from "@plane/ui"; import { Button } from "@plane/ui";
// images // images
import Image404 from "public/404.svg"; import Image404 from "@/public/404.svg";
export const metadata: Metadata = { export const metadata: Metadata = {
title: "404 - Page Not Found", title: "404 - Page Not Found",

View File

@ -20,10 +20,10 @@ import DefaultLayout from "@/layouts/default-layout";
// wrappers // wrappers
import { AuthenticationWrapper } from "@/lib/wrappers"; import { AuthenticationWrapper } from "@/lib/wrappers";
// assets // assets
import PlaneBackgroundPatternDark from "public/auth/background-pattern-dark.svg"; import PlaneBackgroundPatternDark from "@/public/auth/background-pattern-dark.svg";
import PlaneBackgroundPattern from "public/auth/background-pattern.svg"; import PlaneBackgroundPattern from "@/public/auth/background-pattern.svg";
import BlackHorizontalLogo from "public/plane-logos/black-horizontal-with-blue-logo.png"; import BlackHorizontalLogo from "@/public/plane-logos/black-horizontal-with-blue-logo.png";
import WhiteHorizontalLogo from "public/plane-logos/white-horizontal-with-blue-logo.png"; import WhiteHorizontalLogo from "@/public/plane-logos/white-horizontal-with-blue-logo.png";
const HomePage = observer(() => { const HomePage = observer(() => {
const { resolvedTheme } = useTheme(); const { resolvedTheme } = useTheme();

View File

@ -15,10 +15,10 @@ import { EAuthModes, EPageTypes } from "@/helpers/authentication.helper";
import { useEventTracker } from "@/hooks/store"; import { useEventTracker } from "@/hooks/store";
// assets // assets
import { AuthenticationWrapper } from "@/lib/wrappers"; import { AuthenticationWrapper } from "@/lib/wrappers";
import PlaneBackgroundPatternDark from "public/auth/background-pattern-dark.svg"; import PlaneBackgroundPatternDark from "@/public/auth/background-pattern-dark.svg";
import PlaneBackgroundPattern from "public/auth/background-pattern.svg"; import PlaneBackgroundPattern from "@/public/auth/background-pattern.svg";
import BlackHorizontalLogo from "public/plane-logos/black-horizontal-with-blue-logo.png"; import BlackHorizontalLogo from "@/public/plane-logos/black-horizontal-with-blue-logo.png";
import WhiteHorizontalLogo from "public/plane-logos/white-horizontal-with-blue-logo.png"; import WhiteHorizontalLogo from "@/public/plane-logos/white-horizontal-with-blue-logo.png";
export type AuthType = "sign-in" | "sign-up"; export type AuthType = "sign-in" | "sign-up";

View File

@ -1,7 +1,7 @@
// ui // ui
import { ProfileEmptyState } from "@/components/ui"; import { ProfileEmptyState } from "@/components/ui";
// image // image
import emptyUsers from "public/empty-state/empty_users.svg"; import emptyUsers from "@/public/empty-state/empty_users.svg";
type Props = { type Props = {
users: { users: {

View File

@ -2,7 +2,7 @@
import { IDefaultAnalyticsUser } from "@plane/types"; import { IDefaultAnalyticsUser } from "@plane/types";
import { BarGraph, ProfileEmptyState } from "@/components/ui"; import { BarGraph, ProfileEmptyState } from "@/components/ui";
// image // image
import emptyBarGraph from "public/empty-state/empty_bar_graph.svg"; import emptyBarGraph from "@/public/empty-state/empty_bar_graph.svg";
// types // types
type Props = { type Props = {

View File

@ -3,7 +3,7 @@ import { IDefaultAnalyticsResponse } from "@plane/types";
import { LineGraph, ProfileEmptyState } from "@/components/ui"; import { LineGraph, ProfileEmptyState } from "@/components/ui";
// image // image
import { MONTHS_LIST } from "@/constants/calendar"; import { MONTHS_LIST } from "@/constants/calendar";
import emptyGraph from "public/empty-state/empty_graph.svg"; import emptyGraph from "@/public/empty-state/empty_graph.svg";
// types // types
// constants // constants

View File

@ -5,7 +5,7 @@ import Image from "next/image";
// ui // ui
import { Button } from "@plane/ui"; import { Button } from "@plane/ui";
// assets // assets
import emptyApiTokens from "public/empty-state/api-token.svg"; import emptyApiTokens from "@/public/empty-state/api-token.svg";
type Props = { type Props = {
onClick: () => void; onClick: () => void;

View File

@ -8,8 +8,8 @@ import { useUser } from "@/hooks/store";
// layouts // layouts
import DefaultLayout from "@/layouts/default-layout"; import DefaultLayout from "@/layouts/default-layout";
// images // images
import ProjectNotAuthorizedImg from "public/auth/project-not-authorized.svg"; import ProjectNotAuthorizedImg from "@/public/auth/project-not-authorized.svg";
import WorkspaceNotAuthorizedImg from "public/auth/workspace-not-authorized.svg"; import WorkspaceNotAuthorizedImg from "@/public/auth/workspace-not-authorized.svg";
type Props = { type Props = {
actionButton?: React.ReactNode; actionButton?: React.ReactNode;

View File

@ -9,7 +9,7 @@ import { useProject, useUser } from "@/hooks/store";
// ui // ui
// icons // icons
// images // images
import JoinProjectImg from "public/auth/project-not-authorized.svg"; import JoinProjectImg from "@/public/auth/project-not-authorized.svg";
export const JoinProject: React.FC = () => { export const JoinProject: React.FC = () => {
// states // states

View File

@ -4,7 +4,7 @@ import { useTheme } from "next-themes";
// icons // icons
import { Lightbulb } from "lucide-react"; import { Lightbulb } from "lucide-react";
// images // images
import latestFeatures from "public/onboarding/onboarding-pages.svg"; import latestFeatures from "@/public/onboarding/onboarding-pages.svg";
export const LatestFeatureBlock = () => { export const LatestFeatureBlock = () => {
const { resolvedTheme } = useTheme(); const { resolvedTheme } = useTheme();

Some files were not shown because too many files have changed in this diff Show More