Skip to content

Commit

Permalink
remove all use of $lib/time
Browse files Browse the repository at this point in the history
  • Loading branch information
hardingjam committed Nov 20, 2024
1 parent a08249d commit 914be84
Show file tree
Hide file tree
Showing 12 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion tauri-app/src/lib/components/TradesTable.svelte
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script lang="ts">
import { TableBodyCell, TableHeadCell } from 'flowbite-svelte';
import { formatTimestampSecondsAsLocal } from '$lib/utils/time';
import { formatTimestampSecondsAsLocal } from '@rainlanguage/ui-components';
import { Hash, HashType } from '@rainlanguage/ui-components';
import AppTable from '$lib/components/AppTable.svelte';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script lang="ts">
import { timestampSecondsToUTCTimestamp } from '$lib/utils/time';
import { timestampSecondsToUTCTimestamp } from '@rainlanguage/ui-components';
import { bigintToFloat } from '$lib/utils/number';
import type { Vault } from '$lib/typeshare/subgraphTypes';
import { createQuery } from '@tanstack/svelte-query';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { expect, test, vi } from 'vitest';
import { QueryClient } from '@tanstack/svelte-query';
import { mockIPC } from '@tauri-apps/api/mocks';
import VaultBalanceChart from './VaultBalanceChart.svelte';
import { timestampSecondsToUTCTimestamp } from '$lib/utils/time';
import { timestampSecondsToUTCTimestamp } from '@rainlanguage/ui-components';
import { bigintToFloat } from '$lib/utils/number';
import type { Vault } from '$lib/typeshare/subgraphTypes';
import type { VaultBalanceChangeUnwrapped } from '$lib/typeshare/subgraphTypes';
Expand Down
2 changes: 1 addition & 1 deletion tauri-app/src/lib/components/detail/OrderDetail.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import { Button, TabItem, Tabs } from 'flowbite-svelte';
import { walletAddressMatchesOrBlank } from '$lib/stores/wallets';
import BadgeActive from '$lib/components/BadgeActive.svelte';
import { formatTimestampSecondsAsLocal } from '$lib/utils/time';
import { formatTimestampSecondsAsLocal } from '@rainlanguage/ui-components';
import ButtonVaultLink from '$lib/components/ButtonVaultLink.svelte';
import { Hash, HashType } from '@rainlanguage/ui-components';
Expand Down
2 changes: 1 addition & 1 deletion tauri-app/src/lib/components/detail/OrderDetail.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import OrderDetail from './OrderDetail.svelte';
import { mockIPC } from '@tauri-apps/api/mocks';
import { mockOrderDetailsExtended } from '$lib/queries/orderDetail';
import { handleOrderRemoveModal } from '$lib/services/modal';
import { formatTimestampSecondsAsLocal } from '$lib/utils/time';
import { formatTimestampSecondsAsLocal } from '@rainlanguage/ui-components';
import { formatUnits } from 'viem';

const { mockWalletAddressMatchesOrBlankStore } = await vi.hoisted(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import { rpcUrl, subgraphUrl } from '$lib/stores/settings';
import { DEFAULT_PAGE_SIZE } from '$lib/queries/constants';
import { TableBodyCell, TableHeadCell } from 'flowbite-svelte';
import { formatTimestampSecondsAsLocal } from '$lib/utils/time';
import { formatTimestampSecondsAsLocal } from '@rainlanguage/ui-components';
import { Hash, HashType } from '@rainlanguage/ui-components';
import { formatUnits } from 'viem';
Expand Down
2 changes: 1 addition & 1 deletion tauri-app/src/lib/components/tables/OrdersListTable.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import { Hash, HashType } from '@rainlanguage/ui-components';
import { activeNetworkRef, activeOrderbookRef, activeSubgraphs } from '$lib/stores/settings';
import { formatTimestampSecondsAsLocal } from '$lib/utils/time';
import { formatTimestampSecondsAsLocal } from '@rainlanguage/ui-components';
import { handleOrderRemoveModal } from '$lib/services/modal';
import { activeAccounts, activeOrderStatus } from '$lib/stores/settings';
import { get } from 'svelte/store';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import OrdersListTable from './OrdersListTable.svelte';
import { mockIPC } from '@tauri-apps/api/mocks';
import { goto } from '$app/navigation';
import { handleOrderRemoveModal } from '$lib/services/modal';
import { formatTimestampSecondsAsLocal } from '$lib/utils/time';
import { formatTimestampSecondsAsLocal } from '@rainlanguage/ui-components';
import type { OrderWithSubgraphName } from '$lib/typeshare/subgraphTypes';

const { mockWalletAddressMatchesOrBlankStore } = await vi.hoisted(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script lang="ts">
import { Heading, TableHeadCell, TableBodyCell } from 'flowbite-svelte';
import { formatTimestampSecondsAsLocal } from '$lib/utils/time';
import { formatTimestampSecondsAsLocal } from '@rainlanguage/ui-components';
import { Hash, HashType } from '@rainlanguage/ui-components';
import { formatUnits } from 'viem';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { QueryClient } from '@tanstack/svelte-query';
import { mockIPC } from '@tauri-apps/api/mocks';
import VaultBalanceChangesTable from './VaultBalanceChangesTable.svelte';
import type { VaultBalanceChangeUnwrapped } from '$lib/typeshare/subgraphTypes';
import { formatTimestampSecondsAsLocal } from '$lib/utils/time';
import { formatTimestampSecondsAsLocal } from '@rainlanguage/ui-components';

vi.mock('$lib/stores/settings', async (importOriginal) => {
const { writable } = await import('svelte/store');
Expand Down
2 changes: 1 addition & 1 deletion tauri-app/src/lib/services/historicalOrderCharts.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { Trade } from '$lib/typeshare/subgraphTypes';
import type { UTCTimestamp } from 'lightweight-charts';
import { timestampSecondsToUTCTimestamp } from '$lib/utils/time';
import { timestampSecondsToUTCTimestamp } from '@rainlanguage/ui-components';
import { sortBy } from 'lodash';
import { formatUnits } from 'viem';

Expand Down
2 changes: 1 addition & 1 deletion tauri-app/src/routes/orders/add/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
import { ethersExecute } from '$lib/services/ethersTx';
import { formatEthersTransactionError } from '$lib/utils/transaction';
import CodeMirrorRainlang from '$lib/components/CodeMirrorRainlang.svelte';
import { promiseTimeout } from '$lib/utils/time';
import { promiseTimeout } from '@rainlanguage/ui-components';
import { SentrySeverityLevel, reportErrorToSentry } from '$lib/services/sentry';
import { pickScenarios } from '$lib/services/pickConfig';
import {
Expand Down

0 comments on commit 914be84

Please sign in to comment.