Skip to content
This repository has been archived by the owner on Jan 11, 2023. It is now read-only.

experimental: storage on IPFS #187

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,15 +57,19 @@
"@lukeed/uuid": "^2.0.0",
"@metamask/detect-provider": "^1.2.0",
"@metamask/providers": "^9.0.0",
"@pinata/sdk": "^1.1.26",
"@walletconnect/qrcode-modal": "^1.7.8",
"@walletconnect/web3-provider": "^1.7.8",
"cupertino-pane": "^1.3.0",
"dotenv": "^16.0.2",
"drips-sdk": "https://github.com/radicle-dev/drips-js-sdk#973599caf3013a2ac56155f11b8cd2426ff263d1",
"ethers": "5.6.4",
"graphql-tag": "^2.12.6",
"multiformats": "^9.7.1",
"radicle-design-system": "https://github.com/radicle-dev/radicle-design-system#ecedcb410730a0a9c47b797b2018bcb52723b681",
"siwe": "^1.1.6",
"web3-utils": "^1.7.3"
"web3-utils": "^1.7.3",
"zod": "^3.18.0"
},
"lint-staged": {
"*.{js,css,svelte,ts}": "eslint --cache --fix",
Expand Down
30 changes: 0 additions & 30 deletions src/lib/api/drips-subgraph/__generated__/DripsAccount.ts

This file was deleted.

28 changes: 28 additions & 0 deletions src/lib/api/drips-subgraph/__generated__/DripsAccountsForUser.ts

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

30 changes: 0 additions & 30 deletions src/lib/api/drips-subgraph/__generated__/DripsConfigs.ts

This file was deleted.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

31 changes: 31 additions & 0 deletions src/lib/api/drips-subgraph/__generated__/SplitsConfig.ts

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

34 changes: 0 additions & 34 deletions src/lib/api/drips-subgraph/__generated__/dripsConfig.ts

This file was deleted.

24 changes: 0 additions & 24 deletions src/lib/api/drips-subgraph/__generated__/dripsEntries.ts

This file was deleted.

24 changes: 0 additions & 24 deletions src/lib/api/drips-subgraph/__generated__/lastDripEntry.ts

This file was deleted.

37 changes: 15 additions & 22 deletions src/lib/api/drips-subgraph/queries.ts
Original file line number Diff line number Diff line change
@@ -1,31 +1,24 @@
import { gql } from 'graphql-tag';

export const GET_LAST_DRIP_ENTRY = gql`
query LastDripsEntry($user: Bytes!) {
dripsEntries(
where: { user: $user, isAccountDrip: true }
orderBy: account
orderDirection: desc
first: 1
) {
account
user
isAccountDrip
receiver
export const DRIPS_ACCOUNTS_FOR_USER = gql`
query DripsAccountsForUser($user: ID!) {
dripsConfig(id: $user) {
dripsAccount {
isAccountDrip
id
account
}
}
}
`;

export const GET_DRIPS_ACCOUNT = gql`
query DripsAccount($id: ID!) {
dripsAccount(id: $id) {
id
lastUpdatedBlockTimestamp
dripsEntries {
receiver
amtPerSec
}
balance
export const DRIPS_ENTRIES_STREAMING_TO_USER = gql`
query DripsEntriesStreamingToUser($user: Bytes!) {
dripsEntries(where: { receiver: $user }) {
user
account
amtPerSec
isAccountDrip
}
}
`;
Expand Down
17 changes: 0 additions & 17 deletions src/lib/api/gnosis/index.ts

This file was deleted.

33 changes: 0 additions & 33 deletions src/lib/components/AwaitingSafeTransactionStep.svelte

This file was deleted.

14 changes: 5 additions & 9 deletions src/lib/components/BalanceButton.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -7,19 +7,15 @@
import * as modal from '$lib/utils/modal';
import drips from '$lib/stores/drips';
import { currencyFormat, padFloatString } from '$lib/utils/format';
import { workstreamsStore } from '$lib/stores/workstreams';
import workstreamsStore from '$lib/stores/workstreams';
import LoadingDots from './LoadingDots.svelte';
import { goto } from '$app/navigation';
import StepperModal from '$lib/components/StepperModal/index.svelte';
import Intro from '$lib/components/WithdrawSteps/Intro.svelte';
import { walletStore } from '$lib/stores/wallet/wallet';
import AwaitingSafeTransactionStep from './AwaitingSafeTransactionStep.svelte';

const estimates = workstreamsStore.estimates;

$: currentCycleBalanceEstimate =
$estimates.earnedInCurrentCycle !== undefined &&
currencyFormat($estimates.earnedInCurrentCycle);
$workstreamsStore.earnedInCurrentCycle !== undefined &&
currencyFormat($workstreamsStore.earnedInCurrentCycle);

$: withdrawable =
$drips.collectable && currencyFormat($drips.collectable.wei);
Expand All @@ -30,7 +26,7 @@
currentCycleBalanceEstimate &&
currencyFormat(
($drips.collectable?.wei ?? BigInt(0)) +
($estimates.earnedInCurrentCycle?.wei ?? BigInt(0))
($workstreamsStore.earnedInCurrentCycle?.wei ?? BigInt(0))
);

$: formattedCycleEnd = $drips.cycle && {
Expand All @@ -48,7 +44,7 @@

async function collect() {
modal.show(StepperModal, undefined, {
steps: [Intro, $walletStore.safe?.ready && AwaitingSafeTransactionStep]
steps: [Intro]
});
}

Expand Down
Loading