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 { FC, useEffect, useMemo, useState } from "react";
|
|||
import { observer } from "mobx-react";
|
||||
import { ChevronLeft } from "lucide-react";
|
||||
// types
|
||||
import { EEstimateSystem, ESTIMATE_SYSTEMS } from "@plane/constants";
|
||||
import { useTranslation } from "@plane/i18n";
|
||||
import { IEstimateFormData, TEstimateSystemKeys, TEstimatePointsObject, TEstimateTypeError } from "@plane/types";
|
||||
// ui
|
||||
|
|
@ -13,7 +14,6 @@ import { EstimateCreateStageOne, EstimatePointCreateRoot } from "@/components/es
|
|||
// hooks
|
||||
import { useProjectEstimates } from "@/hooks/store";
|
||||
// plane web constants
|
||||
import { EEstimateSystem, ESTIMATE_SYSTEMS } from "@/plane-web/constants/estimates";
|
||||
|
||||
type TCreateEstimateModal = {
|
||||
workspaceSlug: string;
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
import { FC } from "react";
|
||||
import { Info } from "lucide-react";
|
||||
import { EEstimateSystem, ESTIMATE_SYSTEMS } from "@plane/constants";
|
||||
import { useTranslation } from "@plane/i18n";
|
||||
import { TEstimateSystemKeys } from "@plane/types";
|
||||
import { Tooltip } from "@plane/ui";
|
||||
|
|
@ -11,7 +12,6 @@ import { RadioInput } from "@/components/estimates";
|
|||
// plane web constants
|
||||
import { isEstimateSystemEnabled } from "@/plane-web/components/estimates/helper";
|
||||
import { UpgradeBadge } from "@/plane-web/components/workspace";
|
||||
import { EEstimateSystem, ESTIMATE_SYSTEMS } from "@/plane-web/constants/estimates";
|
||||
|
||||
type TEstimateCreateStageOne = {
|
||||
estimateSystem: TEstimateSystemKeys;
|
||||
|
|
|
|||
|
|
@ -1,13 +1,12 @@
|
|||
import { FC } from "react";
|
||||
import { observer } from "mobx-react";
|
||||
import { EEstimateSystem } from "@plane/constants";
|
||||
import { convertMinutesToHoursMinutesString, cn } from "@plane/utils";
|
||||
// helpers
|
||||
import { convertMinutesToHoursMinutesString } from "@plane/utils";
|
||||
import { cn } from "@/helpers/common.helper";
|
||||
// hooks
|
||||
import { useEstimate, useProjectEstimates } from "@/hooks/store";
|
||||
// plane web components
|
||||
import { EstimateListItemButtons } from "@/plane-web/components/estimates";
|
||||
import { EEstimateSystem } from "@/plane-web/constants/estimates";
|
||||
|
||||
type TEstimateListItem = {
|
||||
estimateId: string;
|
||||
|
|
|
|||
|
|
@ -3,12 +3,12 @@
|
|||
import { Dispatch, FC, SetStateAction, useCallback, useState } from "react";
|
||||
import { observer } from "mobx-react";
|
||||
import { Plus } from "lucide-react";
|
||||
import { estimateCount } from "@plane/constants";
|
||||
import { TEstimatePointsObject, TEstimateSystemKeys, TEstimateTypeError } from "@plane/types";
|
||||
import { Button, Sortable } from "@plane/ui";
|
||||
// components
|
||||
import { EstimatePointCreate, EstimatePointItemPreview } from "@/components/estimates/points";
|
||||
// plane web constants
|
||||
import { estimateCount } from "@/plane-web/constants/estimates";
|
||||
|
||||
type TEstimatePointCreateRoot = {
|
||||
workspaceSlug: string;
|
||||
|
|
|
|||
|
|
@ -3,17 +3,16 @@
|
|||
import { FC, useState, FormEvent } from "react";
|
||||
import { observer } from "mobx-react";
|
||||
import { Check, Info, X } from "lucide-react";
|
||||
import { EEstimateSystem, MAX_ESTIMATE_POINT_INPUT_LENGTH } from "@plane/constants";
|
||||
import { useTranslation } from "@plane/i18n";
|
||||
import { TEstimatePointsObject, TEstimateSystemKeys, TEstimateTypeErrorObject } from "@plane/types";
|
||||
import { Spinner, TOAST_TYPE, Tooltip, setToast } from "@plane/ui";
|
||||
import { cn, isEstimatePointValuesRepeated } from "@plane/utils";
|
||||
import { EstimateInputRoot } from "@/components/estimates/inputs/root";
|
||||
// helpers
|
||||
import { cn } from "@/helpers/common.helper";
|
||||
import { isEstimatePointValuesRepeated } from "@/helpers/estimates";
|
||||
// hooks
|
||||
import { useEstimate } from "@/hooks/store";
|
||||
// plane web constants
|
||||
import { EEstimateSystem, MAX_ESTIMATE_POINT_INPUT_LENGTH } from "@/plane-web/constants/estimates";
|
||||
|
||||
type TEstimatePointCreate = {
|
||||
workspaceSlug: string;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
import { FC, useEffect, useRef, useState } from "react";
|
||||
import { observer } from "mobx-react";
|
||||
import { GripVertical, Pencil, Trash2 } from "lucide-react";
|
||||
import { EEstimateSystem, estimateCount } from "@plane/constants";
|
||||
import { useTranslation } from "@plane/i18n";
|
||||
import { TEstimatePointsObject, TEstimateSystemKeys, TEstimateTypeErrorObject } from "@plane/types";
|
||||
// components
|
||||
|
|
@ -9,7 +10,6 @@ import { EstimatePointUpdate } from "@/components/estimates/points";
|
|||
// plane web components
|
||||
import { EstimatePointDelete } from "@/plane-web/components/estimates";
|
||||
// plane web constants
|
||||
import { EEstimateSystem, estimateCount } from "@/plane-web/constants/estimates";
|
||||
|
||||
type TEstimatePointItemPreview = {
|
||||
workspaceSlug: string;
|
||||
|
|
|
|||
|
|
@ -3,17 +3,16 @@
|
|||
import { FC, useEffect, useState, FormEvent } from "react";
|
||||
import { observer } from "mobx-react";
|
||||
import { Check, Info, X } from "lucide-react";
|
||||
import { EEstimateSystem, MAX_ESTIMATE_POINT_INPUT_LENGTH } from "@plane/constants";
|
||||
import { useTranslation } from "@plane/i18n";
|
||||
import { TEstimatePointsObject, TEstimateSystemKeys, TEstimateTypeErrorObject } from "@plane/types";
|
||||
import { Spinner, TOAST_TYPE, Tooltip, setToast } from "@plane/ui";
|
||||
import { cn, isEstimatePointValuesRepeated } from "@plane/utils";
|
||||
import { EstimateInputRoot } from "@/components/estimates/inputs/root";
|
||||
// helpers
|
||||
import { cn } from "@/helpers/common.helper";
|
||||
import { isEstimatePointValuesRepeated } from "@/helpers/estimates";
|
||||
// hooks
|
||||
import { useEstimatePoint } from "@/hooks/store";
|
||||
// plane web constants
|
||||
import { EEstimateSystem, MAX_ESTIMATE_POINT_INPUT_LENGTH } from "@/plane-web/constants/estimates";
|
||||
|
||||
type TEstimatePointUpdate = {
|
||||
workspaceSlug: string;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import React from "react";
|
||||
// helpers
|
||||
import { cn } from "@/helpers/common.helper";
|
||||
import { cn } from "@plane/utils";
|
||||
|
||||
type RadioInputProps = {
|
||||
name?: string;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue