@bosonprotocol/react-kit 0.29.0-alpha.11 → 0.29.0-alpha.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/assets/logo.svg +11 -5
- package/dist/cjs/components/buttons/Button.d.ts +3 -3
- package/dist/cjs/components/buttons/Button.d.ts.map +1 -1
- package/dist/cjs/components/buttons/Button.js.map +1 -1
- package/dist/cjs/components/buttons/CommitButtonView.d.ts +20 -0
- package/dist/cjs/components/buttons/CommitButtonView.d.ts.map +1 -0
- package/dist/cjs/components/buttons/CommitButtonView.js +80 -0
- package/dist/cjs/components/buttons/CommitButtonView.js.map +1 -0
- package/dist/cjs/components/cta/offer/CommitButton.js +1 -1
- package/dist/cjs/components/cta/offer/CommitButton.js.map +1 -1
- package/dist/cjs/components/modal/components/Commit/CommitNonModal.js +2 -2
- package/dist/cjs/components/modal/components/Commit/CommitNonModal.js.map +1 -1
- package/dist/cjs/components/modal/components/PurchaseOverview/PurchaseOverview.d.ts +7 -0
- package/dist/cjs/components/modal/components/PurchaseOverview/PurchaseOverview.d.ts.map +1 -0
- package/dist/cjs/components/modal/components/PurchaseOverview/PurchaseOverview.js +20 -0
- package/dist/cjs/components/modal/components/PurchaseOverview/PurchaseOverview.js.map +1 -0
- package/dist/cjs/components/modal/components/common/StepsOverview/PurchaseOverview.js +3 -3
- package/dist/cjs/components/modal/components/common/StepsOverview/PurchaseOverview.js.map +1 -1
- package/dist/cjs/components/modal/components/common/StepsOverview/PurchaseOverviewView.d.ts +1 -1
- package/dist/cjs/components/modal/components/common/StepsOverview/PurchaseOverviewView.d.ts.map +1 -1
- package/dist/cjs/components/modal/components/common/StepsOverview/PurchaseOverviewView.js +4 -4
- package/dist/cjs/components/modal/components/common/StepsOverview/PurchaseOverviewView.js.map +1 -1
- package/dist/cjs/components/modal/components/common/detail/Detail.style.d.ts +7 -7
- package/dist/cjs/components/modal/nonModal/Header.d.ts.map +1 -1
- package/dist/cjs/components/modal/nonModal/Header.js +1 -0
- package/dist/cjs/components/modal/nonModal/Header.js.map +1 -1
- package/dist/cjs/components/ui/ThemedButton.d.ts +11 -5
- package/dist/cjs/components/ui/ThemedButton.d.ts.map +1 -1
- package/dist/cjs/components/ui/ThemedButton.js +14 -8
- package/dist/cjs/components/ui/ThemedButton.js.map +1 -1
- package/dist/cjs/components/ui/styles.js +1 -1
- package/dist/cjs/index.d.ts +2 -0
- package/dist/cjs/index.d.ts.map +1 -1
- package/dist/cjs/index.js +2 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/assets/logo.svg +11 -5
- package/dist/esm/components/buttons/Button.d.ts +3 -3
- package/dist/esm/components/buttons/Button.d.ts.map +1 -1
- package/dist/esm/components/buttons/Button.js.map +1 -1
- package/dist/esm/components/buttons/CommitButtonView.d.ts +20 -0
- package/dist/esm/components/buttons/CommitButtonView.d.ts.map +1 -0
- package/dist/esm/components/buttons/CommitButtonView.js +51 -0
- package/dist/esm/components/buttons/CommitButtonView.js.map +1 -0
- package/dist/esm/components/cta/offer/CommitButton.js +1 -1
- package/dist/esm/components/cta/offer/CommitButton.js.map +1 -1
- package/dist/esm/components/modal/components/Commit/CommitNonModal.js +2 -2
- package/dist/esm/components/modal/components/Commit/CommitNonModal.js.map +1 -1
- package/dist/esm/components/modal/components/PurchaseOverview/PurchaseOverview.d.ts +7 -0
- package/dist/esm/components/modal/components/PurchaseOverview/PurchaseOverview.d.ts.map +1 -0
- package/dist/esm/components/modal/components/PurchaseOverview/PurchaseOverview.js +13 -0
- package/dist/esm/components/modal/components/PurchaseOverview/PurchaseOverview.js.map +1 -0
- package/dist/esm/components/modal/components/common/StepsOverview/PurchaseOverview.js +3 -3
- package/dist/esm/components/modal/components/common/StepsOverview/PurchaseOverview.js.map +1 -1
- package/dist/esm/components/modal/components/common/StepsOverview/PurchaseOverviewView.d.ts +1 -1
- package/dist/esm/components/modal/components/common/StepsOverview/PurchaseOverviewView.d.ts.map +1 -1
- package/dist/esm/components/modal/components/common/StepsOverview/PurchaseOverviewView.js +4 -4
- package/dist/esm/components/modal/components/common/StepsOverview/PurchaseOverviewView.js.map +1 -1
- package/dist/esm/components/modal/components/common/detail/Detail.style.d.ts +7 -7
- package/dist/esm/components/modal/nonModal/Header.d.ts.map +1 -1
- package/dist/esm/components/modal/nonModal/Header.js +1 -0
- package/dist/esm/components/modal/nonModal/Header.js.map +1 -1
- package/dist/esm/components/ui/ThemedButton.d.ts +11 -5
- package/dist/esm/components/ui/ThemedButton.d.ts.map +1 -1
- package/dist/esm/components/ui/ThemedButton.js +14 -8
- package/dist/esm/components/ui/ThemedButton.js.map +1 -1
- package/dist/esm/components/ui/styles.js +1 -1
- package/dist/esm/index.d.ts +2 -0
- package/dist/esm/index.d.ts.map +1 -1
- package/dist/esm/index.js +2 -0
- package/dist/esm/index.js.map +1 -1
- package/package.json +4 -4
- package/src/assets/logo.svg +11 -5
- package/src/components/buttons/Button.tsx +2 -1
- package/src/components/buttons/CommitButtonView.tsx +117 -0
- package/src/components/cta/offer/CommitButton.tsx +1 -1
- package/src/components/modal/components/Commit/CommitNonModal.tsx +2 -2
- package/src/components/modal/components/PurchaseOverview/PurchaseOverview.tsx +30 -0
- package/src/components/modal/components/common/StepsOverview/PurchaseOverview.tsx +5 -5
- package/src/components/modal/components/common/StepsOverview/PurchaseOverviewView.tsx +11 -8
- package/src/components/modal/nonModal/Header.tsx +1 -0
- package/src/components/ui/ThemedButton.tsx +14 -8
- package/src/components/ui/styles.ts +1 -1
- package/src/index.tsx +2 -0
- package/src/stories/PurchaseOverview.stories.tsx +28 -0
- package/src/stories/buttons/CommitButtonView.stories.tsx +44 -0
- package/src/stories/cta/dispute/AddFeesDisputeResolverButton.stories.tsx +2 -2
- package/src/stories/cta/dispute/AddSellerToDisputeResolverButton.stories.tsx +4 -2
- package/src/stories/cta/dispute/CreateDisputeResolverButton.stories.tsx +4 -2
- package/src/stories/cta/dispute/DecideDisputeButton.stories.tsx +4 -2
- package/src/stories/cta/dispute/EscalateDisputeButton.stories.tsx +4 -2
- package/src/stories/cta/dispute/ExpireDisputeButton.stories.tsx +4 -2
- package/src/stories/cta/dispute/ExpireEscalationDisputeButton.stories.tsx +2 -2
- package/src/stories/cta/dispute/ExtendDisputeTimeoutButton.stories.tsx +4 -2
- package/src/stories/cta/dispute/RaiseDisputeButton.stories.tsx +4 -2
- package/src/stories/cta/dispute/RefuseDisputeButton.stories.tsx +4 -2
- package/src/stories/cta/dispute/RemoveFeesDisputeResolverButton.stories.tsx +4 -2
- package/src/stories/cta/dispute/RemoveSellerFromDisputeResolverButton.stories.tsx +2 -2
- package/src/stories/cta/dispute/ResolveDisputeButton.stories.tsx +4 -2
- package/src/stories/cta/dispute/RetractDisputeButton.stories.tsx +4 -2
- package/src/stories/cta/dispute/UpdateDisputeResolverButton.stories.tsx +4 -2
- package/src/stories/cta/exchange/BatchCompleteButton.stories.tsx +4 -2
- package/src/stories/cta/exchange/CancelButton.stories.tsx +4 -2
- package/src/stories/cta/exchange/CompleteButton.stories.tsx +4 -2
- package/src/stories/cta/exchange/ExpireButton.stories.tsx +4 -2
- package/src/stories/cta/exchange/RevokeButton.stories.tsx +4 -2
- package/src/stories/cta/funds/DepositFundsButton.stories.tsx +4 -2
- package/src/stories/cta/funds/WithdrawAllFunds.stories.tsx +4 -2
- package/src/stories/cta/funds/WithdrawFundsButton.stories.tsx +4 -2
- package/src/stories/cta/offer/BatchVoidButton.stories.tsx +4 -2
- package/src/stories/cta/offer/CommitButton.stories.tsx +4 -2
- package/src/stories/cta/offer/CreateOfferButton.stories.tsx +4 -2
- package/src/stories/cta/offer/VoidButton.stories.tsx +4 -2
- package/src/stories/cta/seller/CreateSellerButton.stories.tsx +4 -2
- package/src/stories/cta/seller/UpdateSellerButton.stories.tsx +4 -2
- package/src/stories/helpers/CtaButtonWrapper.tsx +32 -5
- package/src/stories/helpers/connect-wallet.ts +45 -15
|
@@ -7,7 +7,7 @@ import { Grid } from "../../../../ui/Grid";
|
|
|
7
7
|
|
|
8
8
|
const colors = theme.colors.light;
|
|
9
9
|
type Props = {
|
|
10
|
-
onBackClick
|
|
10
|
+
onBackClick?: () => void;
|
|
11
11
|
};
|
|
12
12
|
export function PurchaseOverviewView({ onBackClick }: Props) {
|
|
13
13
|
const dispatch = useNonModalContext();
|
|
@@ -16,11 +16,15 @@ export function PurchaseOverviewView({ onBackClick }: Props) {
|
|
|
16
16
|
payload: {
|
|
17
17
|
headerComponent: (
|
|
18
18
|
<Grid style={{ flex: "1" }}>
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
19
|
+
{onBackClick && (
|
|
20
|
+
<ArrowLeft
|
|
21
|
+
onClick={() => {
|
|
22
|
+
onBackClick();
|
|
23
|
+
}}
|
|
24
|
+
size={32}
|
|
25
|
+
style={{ cursor: "pointer" }}
|
|
26
|
+
/>
|
|
27
|
+
)}
|
|
24
28
|
</Grid>
|
|
25
29
|
),
|
|
26
30
|
contentStyle: {
|
|
@@ -28,7 +32,6 @@ export function PurchaseOverviewView({ onBackClick }: Props) {
|
|
|
28
32
|
}
|
|
29
33
|
}
|
|
30
34
|
});
|
|
31
|
-
|
|
32
|
-
}, [dispatch]);
|
|
35
|
+
}, [dispatch, onBackClick]);
|
|
33
36
|
return <PurchaseOverview />;
|
|
34
37
|
}
|
|
@@ -207,7 +207,7 @@ const allThemes = ({ withBosonStyle }: { withBosonStyle?: boolean }) => {
|
|
|
207
207
|
outline: {
|
|
208
208
|
color: colors.black,
|
|
209
209
|
borderColor: colors.border,
|
|
210
|
-
borderWidth:
|
|
210
|
+
borderWidth: 2,
|
|
211
211
|
hover: {
|
|
212
212
|
background: colors.border,
|
|
213
213
|
color: "var(--accent)"
|
|
@@ -222,7 +222,6 @@ const allThemes = ({ withBosonStyle }: { withBosonStyle?: boolean }) => {
|
|
|
222
222
|
},
|
|
223
223
|
blank: {
|
|
224
224
|
color: `${colors.black}4d`,
|
|
225
|
-
padding: "0.75rem 0.5rem",
|
|
226
225
|
hover: {
|
|
227
226
|
color: colors.black
|
|
228
227
|
},
|
|
@@ -233,7 +232,6 @@ const allThemes = ({ withBosonStyle }: { withBosonStyle?: boolean }) => {
|
|
|
233
232
|
},
|
|
234
233
|
blankSecondary: {
|
|
235
234
|
color: "var(--accent)",
|
|
236
|
-
padding: "0.75rem 0.5rem",
|
|
237
235
|
hover: {
|
|
238
236
|
borderColor: colors.secondary,
|
|
239
237
|
background: colors.border,
|
|
@@ -242,7 +240,7 @@ const allThemes = ({ withBosonStyle }: { withBosonStyle?: boolean }) => {
|
|
|
242
240
|
},
|
|
243
241
|
blankSecondaryOutline: {
|
|
244
242
|
color: "var(--accent)",
|
|
245
|
-
borderWidth:
|
|
243
|
+
borderWidth: 2,
|
|
246
244
|
borderColor: colors.secondary,
|
|
247
245
|
hover: {
|
|
248
246
|
borderColor: colors.secondary,
|
|
@@ -252,8 +250,7 @@ const allThemes = ({ withBosonStyle }: { withBosonStyle?: boolean }) => {
|
|
|
252
250
|
},
|
|
253
251
|
blankOutline: {
|
|
254
252
|
color: colors.black,
|
|
255
|
-
|
|
256
|
-
borderWidth: 1,
|
|
253
|
+
borderWidth: 2,
|
|
257
254
|
hover: {
|
|
258
255
|
borderColor: colors.secondary,
|
|
259
256
|
background: colors.border,
|
|
@@ -263,14 +260,23 @@ const allThemes = ({ withBosonStyle }: { withBosonStyle?: boolean }) => {
|
|
|
263
260
|
white: {
|
|
264
261
|
color: colors.black,
|
|
265
262
|
background: colors.white,
|
|
266
|
-
|
|
267
|
-
borderWidth: 1,
|
|
263
|
+
borderWidth: 2,
|
|
268
264
|
borderColor: colors.border,
|
|
269
265
|
hover: {
|
|
270
266
|
color: colors.white,
|
|
271
267
|
background: colors.black
|
|
272
268
|
}
|
|
273
269
|
},
|
|
270
|
+
black: {
|
|
271
|
+
color: colors.white,
|
|
272
|
+
background: colors.black,
|
|
273
|
+
borderWidth: 2,
|
|
274
|
+
borderColor: colors.black,
|
|
275
|
+
hover: {
|
|
276
|
+
color: colors.black,
|
|
277
|
+
background: colors.white
|
|
278
|
+
}
|
|
279
|
+
},
|
|
274
280
|
warning: {
|
|
275
281
|
color: colors.black,
|
|
276
282
|
borderColor: colors.orange,
|
package/src/index.tsx
CHANGED
|
@@ -6,6 +6,7 @@ export { default as ThemedButton, IButton } from "./components/ui/ThemedButton";
|
|
|
6
6
|
export * from "./components/ui/zIndex";
|
|
7
7
|
export * from "./components/ui/buttonSize";
|
|
8
8
|
export * from "./components/buttons/Button";
|
|
9
|
+
export * from "./components/buttons/CommitButtonView";
|
|
9
10
|
export * from "./components/cta/exchange/BatchCompleteButton";
|
|
10
11
|
export * from "./components/cta/exchange/CancelButton";
|
|
11
12
|
export * from "./components/cta/exchange/CompleteButton";
|
|
@@ -49,6 +50,7 @@ export * from "./components/magicLink/MagicProvider";
|
|
|
49
50
|
export * from "./components/magicLink/UserContext";
|
|
50
51
|
export * from "./components/modal/components/common/OfferFullDescription/ExternalOfferFullDescription";
|
|
51
52
|
export * from "./components/modal/components/common/detail/useGetOfferDetailData";
|
|
53
|
+
export * from "./components/modal/components/PurchaseOverview/PurchaseOverview";
|
|
52
54
|
export * from "./components/modal/components/Commit/DetailView/ExternalCommitDetailView";
|
|
53
55
|
export * from "./components/modal/components/Redeem/DetailView/ExternalExchangeDetailView";
|
|
54
56
|
export * from "./components/ui/Grid";
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { ComponentStory, ComponentMeta } from "@storybook/react";
|
|
3
|
+
import { PurchaseOverview } from "../components/modal/components/PurchaseOverview/PurchaseOverview";
|
|
4
|
+
|
|
5
|
+
// More on default export: https://storybook.js.org/docs/react/writing-stories/introduction#default-export
|
|
6
|
+
export default {
|
|
7
|
+
title: "Visual Components/PurchaseOverview",
|
|
8
|
+
component: PurchaseOverview,
|
|
9
|
+
argTypes: {
|
|
10
|
+
lookAndFeel: {
|
|
11
|
+
options: ["modal", "regular"],
|
|
12
|
+
control: { type: "radio" }
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
} as ComponentMeta<typeof PurchaseOverview>;
|
|
16
|
+
|
|
17
|
+
// More on component templates: https://storybook.js.org/docs/react/writing-stories/introduction#using-args
|
|
18
|
+
const Template: ComponentStory<typeof PurchaseOverview> = (args) => (
|
|
19
|
+
<PurchaseOverview {...args} />
|
|
20
|
+
);
|
|
21
|
+
|
|
22
|
+
export const Base: ComponentStory<typeof PurchaseOverview> = Template.bind({});
|
|
23
|
+
|
|
24
|
+
// More on args: https://storybook.js.org/docs/react/writing-stories/args
|
|
25
|
+
Base.args = {
|
|
26
|
+
hideModal: () => console.log("hideModal"),
|
|
27
|
+
lookAndFeel: "modal"
|
|
28
|
+
};
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { ComponentStory, ComponentMeta } from "@storybook/react";
|
|
3
|
+
|
|
4
|
+
import { CommitButtonView } from "../../components/buttons/CommitButtonView";
|
|
5
|
+
|
|
6
|
+
// More on default export: https://storybook.js.org/docs/react/writing-stories/introduction#default-export
|
|
7
|
+
export default {
|
|
8
|
+
title: "Visual Components/Buttons/CommitButton",
|
|
9
|
+
component: CommitButtonView,
|
|
10
|
+
argTypes: {
|
|
11
|
+
layout: {
|
|
12
|
+
options: ["horizontal", "vertical"],
|
|
13
|
+
control: { type: "radio" }
|
|
14
|
+
},
|
|
15
|
+
color: {
|
|
16
|
+
options: ["green", "black", "white"],
|
|
17
|
+
control: { type: "radio" }
|
|
18
|
+
},
|
|
19
|
+
shape: {
|
|
20
|
+
options: ["sharp", "rounded", "pill"],
|
|
21
|
+
control: { type: "radio" }
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
} as ComponentMeta<typeof CommitButtonView>;
|
|
25
|
+
|
|
26
|
+
// More on component templates: https://storybook.js.org/docs/react/writing-stories/introduction#using-args
|
|
27
|
+
const Template: ComponentStory<typeof CommitButtonView> = (args) => (
|
|
28
|
+
<CommitButtonView {...args} />
|
|
29
|
+
);
|
|
30
|
+
|
|
31
|
+
export const Base: ComponentStory<typeof CommitButtonView> = Template.bind({});
|
|
32
|
+
|
|
33
|
+
// More on args: https://storybook.js.org/docs/react/writing-stories/args
|
|
34
|
+
Base.args = {
|
|
35
|
+
disabled: false,
|
|
36
|
+
onClick: () => console.log("click"),
|
|
37
|
+
onTaglineClick: () => console.log("tagline click"),
|
|
38
|
+
minWidth: "200px",
|
|
39
|
+
minHeight: "300px",
|
|
40
|
+
layout: "horizontal",
|
|
41
|
+
tagline: true,
|
|
42
|
+
color: "green",
|
|
43
|
+
shape: "sharp"
|
|
44
|
+
};
|
|
@@ -19,12 +19,12 @@ export default {
|
|
|
19
19
|
} as ComponentMeta<typeof AddFeesDisputeResolverButton>;
|
|
20
20
|
|
|
21
21
|
const Template: ComponentStory<typeof AddFeesDisputeResolverButton> = (
|
|
22
|
-
args
|
|
22
|
+
args: Parameters<typeof AddFeesDisputeResolverButton>[0]
|
|
23
23
|
) => {
|
|
24
24
|
const provider = hooks.useProvider();
|
|
25
25
|
|
|
26
26
|
return (
|
|
27
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
28
28
|
<AddFeesDisputeResolverButton
|
|
29
29
|
{...args}
|
|
30
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof AddSellerToDisputeResolver>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof AddSellerToDisputeResolver> = (
|
|
21
|
+
const Template: ComponentStory<typeof AddSellerToDisputeResolver> = (
|
|
22
|
+
args: Parameters<typeof AddSellerToDisputeResolver>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<AddSellerToDisputeResolver
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof CreateDisputeResolverButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof CreateDisputeResolverButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof CreateDisputeResolverButton> = (
|
|
22
|
+
args: Parameters<typeof CreateDisputeResolverButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<CreateDisputeResolverButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof DecideDisputeButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof DecideDisputeButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof DecideDisputeButton> = (
|
|
22
|
+
args: Parameters<typeof DecideDisputeButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<DecideDisputeButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof EscalateDisputeButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof EscalateDisputeButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof EscalateDisputeButton> = (
|
|
22
|
+
args: Parameters<typeof EscalateDisputeButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<EscalateDisputeButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof ExpireDisputeButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof ExpireDisputeButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof ExpireDisputeButton> = (
|
|
22
|
+
args: Parameters<typeof ExpireDisputeButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<ExpireDisputeButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -19,12 +19,12 @@ export default {
|
|
|
19
19
|
} as ComponentMeta<typeof ExpireEscalationDisputeButton>;
|
|
20
20
|
|
|
21
21
|
const Template: ComponentStory<typeof ExpireEscalationDisputeButton> = (
|
|
22
|
-
args
|
|
22
|
+
args: Parameters<typeof ExpireEscalationDisputeButton>[0]
|
|
23
23
|
) => {
|
|
24
24
|
const provider = hooks.useProvider();
|
|
25
25
|
|
|
26
26
|
return (
|
|
27
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
28
28
|
<ExpireEscalationDisputeButton
|
|
29
29
|
{...args}
|
|
30
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof ExtendDisputeTimeoutButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof ExtendDisputeTimeoutButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof ExtendDisputeTimeoutButton> = (
|
|
22
|
+
args: Parameters<typeof ExtendDisputeTimeoutButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<ExtendDisputeTimeoutButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof RaiseDisputeButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof RaiseDisputeButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof RaiseDisputeButton> = (
|
|
22
|
+
args: Parameters<typeof RaiseDisputeButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<RaiseDisputeButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof RefuseDisputeButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof RefuseDisputeButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof RefuseDisputeButton> = (
|
|
22
|
+
args: Parameters<typeof RefuseDisputeButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<RefuseDisputeButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof RemoveFeesDisputeResolver>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof RemoveFeesDisputeResolver> = (
|
|
21
|
+
const Template: ComponentStory<typeof RemoveFeesDisputeResolver> = (
|
|
22
|
+
args: Parameters<typeof RemoveFeesDisputeResolver>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<RemoveFeesDisputeResolver
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -19,12 +19,12 @@ export default {
|
|
|
19
19
|
} as ComponentMeta<typeof RemoveSellerFromDisputeResolverButton>;
|
|
20
20
|
|
|
21
21
|
const Template: ComponentStory<typeof RemoveSellerFromDisputeResolverButton> = (
|
|
22
|
-
args
|
|
22
|
+
args: Parameters<typeof RemoveSellerFromDisputeResolverButton>[0]
|
|
23
23
|
) => {
|
|
24
24
|
const provider = hooks.useProvider();
|
|
25
25
|
|
|
26
26
|
return (
|
|
27
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
28
28
|
<RemoveSellerFromDisputeResolverButton
|
|
29
29
|
{...args}
|
|
30
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof ResolveDisputeButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof ResolveDisputeButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof ResolveDisputeButton> = (
|
|
22
|
+
args: Parameters<typeof ResolveDisputeButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<ResolveDisputeButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof RetractDisputeButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof RetractDisputeButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof RetractDisputeButton> = (
|
|
22
|
+
args: Parameters<typeof RetractDisputeButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<RetractDisputeButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof UpdateDisputeResolverButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof UpdateDisputeResolverButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof UpdateDisputeResolverButton> = (
|
|
22
|
+
args: Parameters<typeof UpdateDisputeResolverButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<UpdateDisputeResolverButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof BatchCompleteButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof BatchCompleteButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof BatchCompleteButton> = (
|
|
22
|
+
args: Parameters<typeof BatchCompleteButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<BatchCompleteButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof CancelButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof CancelButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof CancelButton> = (
|
|
22
|
+
args: Parameters<typeof CancelButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<CancelButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof CompleteButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof CompleteButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof CompleteButton> = (
|
|
22
|
+
args: Parameters<typeof CompleteButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<CompleteButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof ExpireButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof ExpireButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof ExpireButton> = (
|
|
22
|
+
args: Parameters<typeof ExpireButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<ExpireButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -18,11 +18,13 @@ export default {
|
|
|
18
18
|
}
|
|
19
19
|
} as ComponentMeta<typeof RevokeButton>;
|
|
20
20
|
|
|
21
|
-
const Template: ComponentStory<typeof RevokeButton> = (
|
|
21
|
+
const Template: ComponentStory<typeof RevokeButton> = (
|
|
22
|
+
args: Parameters<typeof RevokeButton>[0]
|
|
23
|
+
) => {
|
|
22
24
|
const provider = hooks.useProvider();
|
|
23
25
|
|
|
24
26
|
return (
|
|
25
|
-
<CtaButtonWrapper>
|
|
27
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
26
28
|
<RevokeButton
|
|
27
29
|
{...args}
|
|
28
30
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -19,11 +19,13 @@ export default {
|
|
|
19
19
|
}
|
|
20
20
|
} as ComponentMeta<typeof DepositFundsButton>;
|
|
21
21
|
|
|
22
|
-
const Template: ComponentStory<typeof DepositFundsButton> = (
|
|
22
|
+
const Template: ComponentStory<typeof DepositFundsButton> = (
|
|
23
|
+
args: Parameters<typeof DepositFundsButton>[0]
|
|
24
|
+
) => {
|
|
23
25
|
const buttonRef = useRef<HTMLButtonElement>(null);
|
|
24
26
|
const provider = hooks.useProvider();
|
|
25
27
|
return (
|
|
26
|
-
<CtaButtonWrapper>
|
|
28
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
27
29
|
<DepositFundsButton
|
|
28
30
|
{...args}
|
|
29
31
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -19,12 +19,14 @@ export default {
|
|
|
19
19
|
}
|
|
20
20
|
} as ComponentMeta<typeof WithdrawAllFundsButton>;
|
|
21
21
|
|
|
22
|
-
const Template: ComponentStory<typeof WithdrawAllFundsButton> = (
|
|
22
|
+
const Template: ComponentStory<typeof WithdrawAllFundsButton> = (
|
|
23
|
+
args: Parameters<typeof WithdrawAllFundsButton>[0]
|
|
24
|
+
) => {
|
|
23
25
|
const buttonRef = useRef<HTMLButtonElement>(null);
|
|
24
26
|
const provider = hooks.useProvider();
|
|
25
27
|
|
|
26
28
|
return (
|
|
27
|
-
<CtaButtonWrapper>
|
|
29
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
28
30
|
<WithdrawAllFundsButton
|
|
29
31
|
{...args}
|
|
30
32
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -20,12 +20,14 @@ export default {
|
|
|
20
20
|
}
|
|
21
21
|
} as ComponentMeta<typeof WithdrawFundsButton>;
|
|
22
22
|
|
|
23
|
-
const Template: ComponentStory<typeof WithdrawFundsButton> = (
|
|
23
|
+
const Template: ComponentStory<typeof WithdrawFundsButton> = (
|
|
24
|
+
args: Parameters<typeof WithdrawFundsButton>[0]
|
|
25
|
+
) => {
|
|
24
26
|
const buttonRef = useRef<HTMLButtonElement>(null);
|
|
25
27
|
const provider = hooks.useProvider();
|
|
26
28
|
|
|
27
29
|
return (
|
|
28
|
-
<CtaButtonWrapper>
|
|
30
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
29
31
|
<WithdrawFundsButton
|
|
30
32
|
{...args}
|
|
31
33
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -19,11 +19,13 @@ export default {
|
|
|
19
19
|
}
|
|
20
20
|
} as ComponentMeta<typeof BatchVoidButton>;
|
|
21
21
|
|
|
22
|
-
const Template: ComponentStory<typeof BatchVoidButton> = (
|
|
22
|
+
const Template: ComponentStory<typeof BatchVoidButton> = (
|
|
23
|
+
args: Parameters<typeof BatchVoidButton>[0]
|
|
24
|
+
) => {
|
|
23
25
|
const provider = hooks.useProvider();
|
|
24
26
|
|
|
25
27
|
return (
|
|
26
|
-
<CtaButtonWrapper>
|
|
28
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
27
29
|
<BatchVoidButton
|
|
28
30
|
{...args}
|
|
29
31
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|
|
@@ -19,12 +19,14 @@ export default {
|
|
|
19
19
|
}
|
|
20
20
|
} as ComponentMeta<typeof CommitButton>;
|
|
21
21
|
|
|
22
|
-
const Template: ComponentStory<typeof CommitButton> = (
|
|
22
|
+
const Template: ComponentStory<typeof CommitButton> = (
|
|
23
|
+
args: Parameters<typeof CommitButton>[0]
|
|
24
|
+
) => {
|
|
23
25
|
const buttonRef = useRef<HTMLButtonElement>(null);
|
|
24
26
|
const provider = hooks.useProvider();
|
|
25
27
|
|
|
26
28
|
return (
|
|
27
|
-
<CtaButtonWrapper>
|
|
29
|
+
<CtaButtonWrapper configId={args.coreSdkConfig.configId}>
|
|
28
30
|
<CommitButton
|
|
29
31
|
{...args}
|
|
30
32
|
coreSdkConfig={{ ...args.coreSdkConfig, web3Provider: provider }}
|