refactor: move web utils to packages (#7145)
* refactor: move web utils to packages * fix: build and lint errors * chore: update drag handle plugin * chore: update table cell type to fix build errors * fix: build errors * chore: sync few changes * fix: build errors * chore: minor fixes related to duplicate assets imports * fix: build errors * chore: minor changes
This commit is contained in:
parent
dffcc6dc10
commit
2014400bed
614 changed files with 1999 additions and 3030 deletions
|
|
@ -4,6 +4,7 @@ import { useParams } from "next/navigation";
|
|||
// icons
|
||||
import { History, MessageSquare } from "lucide-react";
|
||||
import { IUserActivityResponse } from "@plane/types";
|
||||
import { calculateTimeAgo, getFileURL } from "@plane/utils";
|
||||
// hooks
|
||||
// components
|
||||
import { ActivityIcon, ActivityMessage, IssueLink } from "@/components/core";
|
||||
|
|
@ -12,8 +13,6 @@ import { RichTextReadOnlyEditor } from "@/components/editor/rich-text-editor/ric
|
|||
// ui
|
||||
import { ActivitySettingsLoader } from "@/components/ui";
|
||||
// helpers
|
||||
import { calculateTimeAgo } from "@/helpers/date-time.helper";
|
||||
import { getFileURL } from "@/helpers/file.helper";
|
||||
// hooks
|
||||
import { useUser, useWorkspace } from "@/hooks/store";
|
||||
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ import { useParams } from "next/navigation";
|
|||
import { useTranslation } from "@plane/i18n";
|
||||
import { Button } from "@plane/ui";
|
||||
// helpers
|
||||
import { renderFormattedPayloadDate } from "@/helpers/date-time.helper";
|
||||
import { renderFormattedPayloadDate } from "@plane/utils";
|
||||
import { UserService } from "@/services/user.service";
|
||||
|
||||
const userService = new UserService();
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ import Link from "next/link";
|
|||
import useSWR from "swr";
|
||||
// icons
|
||||
import { History, MessageSquare } from "lucide-react";
|
||||
import { calculateTimeAgo, getFileURL } from "@plane/utils";
|
||||
// hooks
|
||||
import { ActivityIcon, ActivityMessage, IssueLink } from "@/components/core";
|
||||
import { RichTextReadOnlyEditor } from "@/components/editor/rich-text-editor/rich-text-read-only-editor";
|
||||
|
|
@ -11,8 +12,6 @@ import { ActivitySettingsLoader } from "@/components/ui";
|
|||
// constants
|
||||
import { USER_ACTIVITY } from "@/constants/fetch-keys";
|
||||
// helpers
|
||||
import { calculateTimeAgo } from "@/helpers/date-time.helper";
|
||||
import { getFileURL } from "@/helpers/file.helper";
|
||||
// hooks
|
||||
import { useUser } from "@/hooks/store";
|
||||
// services
|
||||
|
|
|
|||
|
|
@ -11,11 +11,10 @@ import type { IUser, TUserProfile } from "@plane/types";
|
|||
import { Button, Input, TOAST_TYPE, setPromiseToast, setToast } from "@plane/ui";
|
||||
// components
|
||||
import { getButtonStyling } from "@plane/ui/src/button";
|
||||
import { cn } from "@plane/utils";
|
||||
import { cn, getFileURL } from "@plane/utils";
|
||||
import { DeactivateAccountModal } from "@/components/account";
|
||||
import { ImagePickerPopover, UserImageUploadModal } from "@/components/core";
|
||||
// helpers
|
||||
import { getFileURL } from "@/helpers/file.helper";
|
||||
// hooks
|
||||
import { useUser, useUserProfile } from "@/hooks/store";
|
||||
|
||||
|
|
|
|||
|
|
@ -6,14 +6,13 @@ import useSWR from "swr";
|
|||
// ui
|
||||
import { useTranslation } from "@plane/i18n";
|
||||
import { Loader, Card } from "@plane/ui";
|
||||
import { calculateTimeAgo, getFileURL } from "@plane/utils";
|
||||
// components
|
||||
import { ActivityMessage, IssueLink } from "@/components/core";
|
||||
import { ProfileEmptyState } from "@/components/ui";
|
||||
// constants
|
||||
import { USER_PROFILE_ACTIVITY } from "@/constants/fetch-keys";
|
||||
// helpers
|
||||
import { calculateTimeAgo } from "@/helpers/date-time.helper";
|
||||
import { getFileURL } from "@/helpers/file.helper";
|
||||
// hooks
|
||||
import { useUser } from "@/hooks/store";
|
||||
// assets
|
||||
|
|
|
|||
|
|
@ -5,9 +5,9 @@ import { useTranslation } from "@plane/i18n";
|
|||
import { BarChart } from "@plane/propel/charts/bar-chart";
|
||||
import { IUserProfileData } from "@plane/types";
|
||||
import { Loader, Card } from "@plane/ui";
|
||||
import { capitalizeFirstLetter } from "@plane/utils";
|
||||
import { ProfileEmptyState } from "@/components/ui";
|
||||
// image
|
||||
import { capitalizeFirstLetter } from "@/helpers/string.helper";
|
||||
import emptyBarGraph from "@/public/empty-state/empty_bar_graph.svg";
|
||||
// helpers
|
||||
// types
|
||||
|
|
|
|||
|
|
@ -5,9 +5,9 @@ import { PieChart } from "@plane/propel/charts/pie-chart";
|
|||
import { IUserProfileData, IUserStateDistribution } from "@plane/types";
|
||||
// ui
|
||||
import { Card } from "@plane/ui";
|
||||
import { capitalizeFirstLetter } from "@plane/utils";
|
||||
import { ProfileEmptyState } from "@/components/ui";
|
||||
// helpers
|
||||
import { capitalizeFirstLetter } from "@/helpers/string.helper";
|
||||
// image
|
||||
import stateGraph from "@/public/empty-state/state_graph.svg";
|
||||
|
||||
|
|
|
|||
|
|
@ -8,9 +8,9 @@ import { useTranslation } from "@plane/i18n";
|
|||
// types
|
||||
import { IIssueDisplayFilterOptions, IIssueDisplayProperties, IIssueFilterOptions } from "@plane/types";
|
||||
// components
|
||||
import { isIssueFilterActive } from "@plane/utils";
|
||||
import { DisplayFiltersSelection, FilterSelection, FiltersDropdown, LayoutSelection } from "@/components/issues";
|
||||
// helpers
|
||||
import { isIssueFilterActive } from "@/helpers/filter.helper";
|
||||
// hooks
|
||||
import { useIssues, useLabel } from "@/hooks/store";
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
"use client";
|
||||
import React, { FC } from "react";
|
||||
// helpers
|
||||
import { cn } from "@/helpers/common.helper";
|
||||
import { cn } from "@plane/utils";
|
||||
import { SidebarHamburgerToggle } from "../core";
|
||||
|
||||
type Props = {
|
||||
|
|
|
|||
|
|
@ -15,12 +15,10 @@ import { useTranslation } from "@plane/i18n";
|
|||
import { IUserProfileProjectSegregation } from "@plane/types";
|
||||
// plane ui
|
||||
import { Loader, Tooltip } from "@plane/ui";
|
||||
import { cn, renderFormattedDate, getFileURL } from "@plane/utils";
|
||||
// components
|
||||
import { Logo } from "@/components/common";
|
||||
// helpers
|
||||
import { cn } from "@/helpers/common.helper";
|
||||
import { renderFormattedDate } from "@/helpers/date-time.helper";
|
||||
import { getFileURL } from "@/helpers/file.helper";
|
||||
// hooks
|
||||
import { useAppTheme, useProject, useUser } from "@/hooks/store";
|
||||
import { usePlatformOS } from "@/hooks/use-platform-os";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue