Skip to content

Commit

Permalink
improve path
Browse files Browse the repository at this point in the history
  • Loading branch information
domechn committed Nov 6, 2023
1 parent 513d8c4 commit d436ef7
Show file tree
Hide file tree
Showing 11 changed files with 41 additions and 42 deletions.
8 changes: 4 additions & 4 deletions src/components/asset-change.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { Line } from "react-chartjs-2";
import { useWindowSize } from "../utils/hook";
import { timestampToDate } from "../utils/date";
import { AssetChangeData, CurrencyRateDetail } from "../middlelayers/types";
import { useWindowSize } from "@/utils/hook";
import { timestampToDate } from "@/utils/date";
import { AssetChangeData, CurrencyRateDetail } from "@/middlelayers/types";
import _ from 'lodash'
import { currencyWrapper } from '../utils/currency'
import { currencyWrapper } from '@/utils/currency'

const App = ({
data,
Expand Down
8 changes: 4 additions & 4 deletions src/components/coins-amount-and-value-change.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@ import _ from "lodash";
import React from "react";
import { useEffect, useState } from "react";
import { Line } from "react-chartjs-2";
import { useWindowSize } from "../utils/hook";
import { timestampToDate } from "../utils/date";
import { useWindowSize } from "@/utils/hook";
import { timestampToDate } from "@/utils/date";
import {
CoinsAmountAndValueChangeData,
CurrencyRateDetail,
} from "../middlelayers/types";
import { currencyWrapper } from "../utils/currency";
} from "@/middlelayers/types";
import { currencyWrapper } from "@/utils/currency";
import { ButtonGroup, ButtonGroupItem } from "./ui/button-group";
import { Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectTrigger, SelectValue } from './ui/select'

Expand Down
3 changes: 1 addition & 2 deletions src/components/configuration.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,8 @@ import {
saveConfiguration,
} from "../middlelayers/configuration";
import { toast } from "react-hot-toast";
import deleteIcon from "../../assets/icons/delete-icon.png";
import deleteIcon from "@/assets/icons/delete-icon.png";
import { GlobalConfig, TokenConfig } from "../middlelayers/datafetch/types";
import { LoadingContext } from "../App";
import { CurrencyRateDetail } from "../middlelayers/types";
import { listAllCurrencyRates } from "../middlelayers/currency";
import { Separator } from "./ui/separator";
Expand Down
8 changes: 4 additions & 4 deletions src/components/data-management.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { toast } from "react-hot-toast";
import {
exportHistoricalData,
importHistoricalData,
} from "../middlelayers/data";
} from "@/middlelayers/data";
import { useEffect, useState } from "react";

import _ from "lodash";
Expand All @@ -17,9 +17,9 @@ import {
signIn,
signOut,
syncAssetsToCloudAndLocal,
} from "../middlelayers/cloudsync";
import { timestampToDate } from "../utils/date";
import { trackEventWithClientID } from "../utils/app";
} from "@/middlelayers/cloudsync";
import { timestampToDate } from "@/utils/date";
import { trackEventWithClientID } from "@/utils/app";
import { Separator } from "./ui/separator";
import { Checkbox } from "./ui/checkbox";
import { Label } from "./ui/label";
Expand Down
16 changes: 8 additions & 8 deletions src/components/historical-data/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,25 +3,25 @@ import {
deleteHistoricalDataByUUID,
deleteHistoricalDataDetailById,
queryHistoricalData,
} from "../../middlelayers/charts";
import { CurrencyRateDetail, HistoricalData } from "../../middlelayers/types";
import deleteIcon from "../../assets/icons/delete-icon.png";
} from "@/middlelayers/charts";
import { CurrencyRateDetail, HistoricalData } from "@/middlelayers/types";
import deleteIcon from "@/assets/icons/delete-icon.png";
import _ from "lodash";

import "./index.css";
import { toast } from "react-hot-toast";
import { LoadingContext } from "../../App";
import { timestampToDate } from "../../utils/date";
import { LoadingContext } from "@/App";
import { timestampToDate } from "@/utils/date";
import {
currencyWrapper,
prettyNumberToLocaleString,
prettyPriceNumberToLocaleString,
} from "../../utils/currency";
} from "@/utils/currency";
import Modal from "../common/modal";
import { downloadCoinLogos } from "../../middlelayers/data";
import { downloadCoinLogos } from "@/middlelayers/data";
import { appCacheDir as getAppCacheDir } from "@tauri-apps/api/path";
import { convertFileSrc } from "@tauri-apps/api/tauri";
import { useWindowSize } from "../../utils/hook";
import { useWindowSize } from "@/utils/hook";
import ImageStack from "../common/image-stack";

type RankData = {
Expand Down
4 changes: 2 additions & 2 deletions src/components/latest-assets-percentage.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Doughnut } from "react-chartjs-2";
import { useWindowSize } from "../utils/hook";
import { LatestAssetsPercentageData } from "../middlelayers/types";
import { useWindowSize } from "@/utils/hook";
import { LatestAssetsPercentageData } from "@/middlelayers/types";

const App = ({ data }: { data: LatestAssetsPercentageData }) => {
const size = useWindowSize();
Expand Down
8 changes: 4 additions & 4 deletions src/components/top-coins-percentage-change.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import { Line } from "react-chartjs-2";
import { useWindowSize } from "../utils/hook";
import { timestampToDate } from "../utils/date";
import { TopCoinsPercentageChangeData } from "../middlelayers/types";
import { useWindowSize } from "@/utils/hook";
import { timestampToDate } from "@/utils/date";
import { TopCoinsPercentageChangeData } from "@/middlelayers/types";
import { useRef, useState } from "react";
import _ from "lodash";
import { ChartJSOrUndefined } from "react-chartjs-2/dist/types";
import { BubbleDataPoint, Point } from "chart.js";
import { legendOnClick } from "../utils/legend";
import { legendOnClick } from "@/utils/legend";
import { ButtonGroup, ButtonGroupItem } from "./ui/button-group";

const prefix = "tcpc";
Expand Down
8 changes: 4 additions & 4 deletions src/components/top-coins-rank.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import { Line } from "react-chartjs-2";
import { useWindowSize } from "../utils/hook";
import { timestampToDate } from "../utils/date";
import { TopCoinsRankData } from "../middlelayers/types";
import { useWindowSize } from "@/utils/hook";
import { timestampToDate } from "@/utils/date";
import { TopCoinsRankData } from "@/middlelayers/types";
import { useRef } from "react";
import { ChartJSOrUndefined } from "react-chartjs-2/dist/types";
import { BubbleDataPoint, Point } from "chart.js";
import _ from "lodash";
import { legendOnClick } from "../utils/legend";
import { legendOnClick } from "@/utils/legend";

const App = ({ data }: { data: TopCoinsRankData }) => {
const size = useWindowSize();
Expand Down
6 changes: 3 additions & 3 deletions src/components/wallet-analyzer.tsx
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { useContext, useEffect, useState } from "react";
import WalletAssetsPercentage from "./wallet-assets-percentage";
import WalletAssetsChange from "./wallet-assets-change";
import { LoadingContext } from "../App";
import { LoadingContext } from "@/App";
import {
CurrencyRateDetail,
WalletAssetsChangeData,
WalletAssetsPercentageData,
} from "../middlelayers/types";
import { WALLET_ANALYZER } from "../middlelayers/charts";
} from "@/middlelayers/types";
import { WALLET_ANALYZER } from "@/middlelayers/charts";
import { Separator } from "./ui/separator";

const App = ({ currency }: { currency: CurrencyRateDetail }) => {
Expand Down
6 changes: 3 additions & 3 deletions src/components/wallet-assets-change.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@ import _ from "lodash";
import {
CurrencyRateDetail,
WalletAssetsChangeData,
} from "../middlelayers/types";
} from "@/middlelayers/types";
import {
currencyWrapper,
prettyNumberToLocaleString,
} from "../utils/currency";
import { insertEllipsis } from "../utils/string";
} from "@/utils/currency";
import { insertEllipsis } from "@/utils/string";
import {
TableHead,
TableRow,
Expand Down
8 changes: 4 additions & 4 deletions src/components/wallet-assets-percentage.tsx
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { Bar } from "react-chartjs-2";
import { useWindowSize } from "../utils/hook";
import { useWindowSize } from "@/utils/hook";
import {
CurrencyRateDetail,
WalletAssetsPercentageData,
} from "../middlelayers/types";
import { currencyWrapper, prettyNumberToLocaleString } from "../utils/currency";
} from "@/middlelayers/types";
import { currencyWrapper, prettyNumberToLocaleString } from "@/utils/currency";
import _ from "lodash";
import { useEffect, useState } from "react";
import { insertEllipsis } from '../utils/string'
import { insertEllipsis } from '@/utils/string'

const App = ({
data,
Expand Down

0 comments on commit d436ef7

Please sign in to comment.