@rpg-engine/long-bow 0.8.223 → 0.8.225
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/long-bow.cjs.development.js +52 -43
- package/dist/long-bow.cjs.development.js.map +1 -1
- package/dist/long-bow.cjs.production.min.js +1 -1
- package/dist/long-bow.cjs.production.min.js.map +1 -1
- package/dist/long-bow.esm.js +53 -44
- package/dist/long-bow.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/Store/CartView.tsx +35 -22
- package/src/components/Store/FeaturedBanner.tsx +3 -3
- package/src/components/Store/PaymentMethodModal.tsx +2 -2
- package/src/components/Store/PurchaseSuccess.tsx +6 -4
- package/src/components/Store/Store.tsx +10 -7
- package/src/components/Store/StoreCharacterSkinRow.tsx +2 -2
- package/src/components/Store/StoreHeader.tsx +2 -2
- package/src/components/Store/StoreItemDetails.tsx +4 -3
- package/src/components/Store/StoreItemRow.tsx +4 -3
- package/src/components/Store/TrustBar.tsx +6 -4
- package/src/components/Store/sections/StorePacksSection.tsx +4 -3
- package/src/components/Store/sections/StoreRedeemSection.tsx +8 -6
package/package.json
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
import { IProductBlueprint, MetadataType } from '@rpg-engine/shared';
|
|
2
|
+
import { Cancel } from 'pixelarticons/react/Cancel';
|
|
3
|
+
import { Delete } from 'pixelarticons/react/Delete';
|
|
4
|
+
import { InfoBox } from 'pixelarticons/react/InfoBox';
|
|
5
|
+
import { Box } from 'pixelarticons/react/Box';
|
|
6
|
+
import { ShoppingBag } from 'pixelarticons/react/ShoppingBag';
|
|
2
7
|
import React, { useState } from 'react';
|
|
3
|
-
import { FaInfoCircle, FaShoppingBag, FaTimes, FaTrash } from 'react-icons/fa';
|
|
4
8
|
import styled from 'styled-components';
|
|
5
9
|
import characterAtlasJSON from '../../mocks/atlas/entities/entities.json';
|
|
6
10
|
import characterAtlasIMG from '../../mocks/atlas/entities/entities.png';
|
|
@@ -46,7 +50,7 @@ const MetadataDisplay: React.FC<{
|
|
|
46
50
|
return (
|
|
47
51
|
<MetadataInfo>
|
|
48
52
|
<MetadataLabel>
|
|
49
|
-
<
|
|
53
|
+
<InfoBox />
|
|
50
54
|
<span>Skin:</span>
|
|
51
55
|
</MetadataLabel>
|
|
52
56
|
<MetadataValue>{metadata.selectedSkinName || 'Custom skin'}</MetadataValue>
|
|
@@ -139,16 +143,19 @@ export const CartView: React.FC<ICartViewProps> = ({
|
|
|
139
143
|
<Header>
|
|
140
144
|
<Title>Shopping Cart ({cartItems.reduce((s, ci) => s + ci.quantity, 0)})</Title>
|
|
141
145
|
<CloseButton onPointerDown={onClose}>
|
|
142
|
-
<
|
|
146
|
+
<Cancel />
|
|
143
147
|
</CloseButton>
|
|
144
148
|
</Header>
|
|
145
149
|
|
|
146
150
|
<MainContent>
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
<
|
|
150
|
-
|
|
151
|
-
|
|
151
|
+
{cartItems.length === 0 ? (
|
|
152
|
+
<EmptyCart>
|
|
153
|
+
<Box />
|
|
154
|
+
Your cart is empty
|
|
155
|
+
</EmptyCart>
|
|
156
|
+
) : (
|
|
157
|
+
<CartItems>
|
|
158
|
+
{cartItems.map(cartItem => {
|
|
152
159
|
const getSpriteKey = (textureKey: string) => {
|
|
153
160
|
return textureKey + '/down/standing/0.png';
|
|
154
161
|
};
|
|
@@ -190,7 +197,7 @@ export const CartView: React.FC<ICartViewProps> = ({
|
|
|
190
197
|
</ItemDetails>
|
|
191
198
|
|
|
192
199
|
<CTAButton
|
|
193
|
-
icon={<
|
|
200
|
+
icon={<Delete />}
|
|
194
201
|
onClick={e => {
|
|
195
202
|
e.stopPropagation();
|
|
196
203
|
onRemoveFromCart(cartItem.item.key);
|
|
@@ -198,9 +205,9 @@ export const CartView: React.FC<ICartViewProps> = ({
|
|
|
198
205
|
/>
|
|
199
206
|
</CartItemRow>
|
|
200
207
|
);
|
|
201
|
-
})
|
|
202
|
-
|
|
203
|
-
|
|
208
|
+
})}
|
|
209
|
+
</CartItems>
|
|
210
|
+
)}
|
|
204
211
|
|
|
205
212
|
{cartItems.length > 0 && (
|
|
206
213
|
<OrderSummaryPanel>
|
|
@@ -233,7 +240,7 @@ export const CartView: React.FC<ICartViewProps> = ({
|
|
|
233
240
|
<TrustBar signals={trustSignals} />
|
|
234
241
|
{error && <ErrorMessage>{error}</ErrorMessage>}
|
|
235
242
|
<CTAButton
|
|
236
|
-
icon={<
|
|
243
|
+
icon={<ShoppingBag />}
|
|
237
244
|
label={isLoading ? 'Processing...' : `Pay ${currencySymbol}${formatPrice(total)}`}
|
|
238
245
|
onClick={handlePurchase}
|
|
239
246
|
fullWidth
|
|
@@ -286,19 +293,13 @@ const CloseButton = styled.div`
|
|
|
286
293
|
|
|
287
294
|
const MainContent = styled.div`
|
|
288
295
|
display: grid;
|
|
289
|
-
grid-template-columns: minmax(0,
|
|
296
|
+
grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
|
|
290
297
|
gap: 1rem;
|
|
291
298
|
flex: 1;
|
|
292
299
|
min-height: 0;
|
|
293
300
|
margin: 1rem 0;
|
|
294
301
|
|
|
295
|
-
@media (max-width: 700px) {
|
|
296
|
-
grid-template-columns: minmax(0, 1fr) 180px;
|
|
297
|
-
gap: 0.75rem;
|
|
298
|
-
}
|
|
299
|
-
|
|
300
302
|
@media (max-width: 480px) {
|
|
301
|
-
grid-template-columns: minmax(0, 1fr) 130px;
|
|
302
303
|
gap: 0.5rem;
|
|
303
304
|
margin: 0.5rem 0;
|
|
304
305
|
}
|
|
@@ -351,14 +352,22 @@ const OrderSummaryPanel = styled.div`
|
|
|
351
352
|
`;
|
|
352
353
|
|
|
353
354
|
const EmptyCart = styled.div`
|
|
355
|
+
grid-column: 1 / -1;
|
|
354
356
|
display: flex;
|
|
357
|
+
flex-direction: column;
|
|
355
358
|
align-items: center;
|
|
356
359
|
justify-content: center;
|
|
360
|
+
gap: 1rem;
|
|
357
361
|
height: 100%;
|
|
358
362
|
color: #ffffff;
|
|
359
363
|
font-family: 'Press Start 2P', cursive;
|
|
360
364
|
font-size: 0.875rem;
|
|
361
365
|
opacity: 0.7;
|
|
366
|
+
|
|
367
|
+
svg {
|
|
368
|
+
width: 48px;
|
|
369
|
+
height: 48px;
|
|
370
|
+
}
|
|
362
371
|
`;
|
|
363
372
|
|
|
364
373
|
const CartItemRow = styled.div`
|
|
@@ -455,10 +464,14 @@ const TotalRow = styled.div<{ $isTotal?: boolean }>`
|
|
|
455
464
|
color: #fef08a;
|
|
456
465
|
}
|
|
457
466
|
|
|
458
|
-
@media (max-width:
|
|
459
|
-
font-size: ${p => p.$isTotal ? '0.
|
|
467
|
+
@media (max-width: 700px) {
|
|
468
|
+
font-size: ${p => p.$isTotal ? '0.75rem' : '0.6rem'};
|
|
460
469
|
gap: 0.5rem;
|
|
461
470
|
}
|
|
471
|
+
|
|
472
|
+
@media (max-width: 480px) {
|
|
473
|
+
font-size: ${p => p.$isTotal ? '0.65rem' : '0.5rem'};
|
|
474
|
+
}
|
|
462
475
|
`;
|
|
463
476
|
|
|
464
477
|
const PaymentMethodRow = styled.div`
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Zap } from 'pixelarticons/react/Zap';
|
|
3
3
|
import styled from 'styled-components';
|
|
4
4
|
import { uiColors } from '../../constants/uiColors';
|
|
5
5
|
import { CTAButton } from '../shared/CTAButton/CTAButton';
|
|
@@ -53,7 +53,7 @@ export const FeaturedBanner: React.FC<IFeaturedBannerProps> = ({
|
|
|
53
53
|
return (
|
|
54
54
|
<BannerWrapper>
|
|
55
55
|
<BannerHeader>
|
|
56
|
-
<
|
|
56
|
+
<Zap />
|
|
57
57
|
<span>FEATURED OFFERS</span>
|
|
58
58
|
</BannerHeader>
|
|
59
59
|
<CardsRow>
|
|
@@ -114,7 +114,7 @@ export const FeaturedBanner: React.FC<IFeaturedBannerProps> = ({
|
|
|
114
114
|
<CardActions onClick={e => e.stopPropagation()}>
|
|
115
115
|
{onQuickBuy && (
|
|
116
116
|
<CTAButton
|
|
117
|
-
icon={<
|
|
117
|
+
icon={<Zap />}
|
|
118
118
|
label="Buy Now"
|
|
119
119
|
onClick={() => onQuickBuy(item)}
|
|
120
120
|
/>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React, { useCallback, useEffect, useState } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Cancel } from 'pixelarticons/react/Cancel';
|
|
3
3
|
import styled from 'styled-components';
|
|
4
4
|
import ModalPortal from '../Abstractions/ModalPortal';
|
|
5
5
|
import { Button, ButtonTypes } from '../Button';
|
|
@@ -77,7 +77,7 @@ export const PaymentMethodModal: React.FC<IPaymentMethodModalProps> = ({
|
|
|
77
77
|
<Header>
|
|
78
78
|
<Title>How would you like to pay?</Title>
|
|
79
79
|
<CloseButton onPointerDown={onClose} aria-label="Close">
|
|
80
|
-
<
|
|
80
|
+
<Cancel />
|
|
81
81
|
</CloseButton>
|
|
82
82
|
</Header>
|
|
83
83
|
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { MetadataType } from '@rpg-engine/shared';
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import {
|
|
3
|
+
import { Cancel } from 'pixelarticons/react/Cancel';
|
|
4
|
+
import { ShoppingBag } from 'pixelarticons/react/ShoppingBag';
|
|
5
|
+
import { Sparkle } from 'pixelarticons/react/Sparkle';
|
|
4
6
|
import styled, { keyframes } from 'styled-components';
|
|
5
7
|
import characterAtlasJSON from '../../mocks/atlas/entities/entities.json';
|
|
6
8
|
import characterAtlasIMG from '../../mocks/atlas/entities/entities.png';
|
|
@@ -41,7 +43,7 @@ export const PurchaseSuccess: React.FC<IPurchaseSuccessProps> = ({
|
|
|
41
43
|
<Header>
|
|
42
44
|
<TrophyArea>
|
|
43
45
|
<TrophyIcon>
|
|
44
|
-
<
|
|
46
|
+
<Sparkle />
|
|
45
47
|
</TrophyIcon>
|
|
46
48
|
</TrophyArea>
|
|
47
49
|
<Title>PURCHASE COMPLETE!</Title>
|
|
@@ -81,13 +83,13 @@ export const PurchaseSuccess: React.FC<IPurchaseSuccessProps> = ({
|
|
|
81
83
|
|
|
82
84
|
<Actions>
|
|
83
85
|
<CTAButton
|
|
84
|
-
icon={<
|
|
86
|
+
icon={<ShoppingBag />}
|
|
85
87
|
label="Continue Shopping"
|
|
86
88
|
onClick={onContinueShopping}
|
|
87
89
|
fullWidth
|
|
88
90
|
/>
|
|
89
91
|
<CloseLink onPointerDown={onClose}>
|
|
90
|
-
<
|
|
92
|
+
<Cancel /> Close Store
|
|
91
93
|
</CloseLink>
|
|
92
94
|
</Actions>
|
|
93
95
|
</Container>
|
|
@@ -4,7 +4,10 @@ import { Gift } from 'pixelarticons/react/Gift';
|
|
|
4
4
|
import { Package } from 'pixelarticons/react/Package';
|
|
5
5
|
import { Wallet } from 'pixelarticons/react/Wallet';
|
|
6
6
|
import React, { ReactNode, useMemo, useState } from 'react';
|
|
7
|
-
import {
|
|
7
|
+
import { DateTime } from 'pixelarticons/react/DateTime';
|
|
8
|
+
import { Receipt } from 'pixelarticons/react/Receipt';
|
|
9
|
+
import { ShoppingCart } from 'pixelarticons/react/ShoppingCart';
|
|
10
|
+
import { Users } from 'pixelarticons/react/Users';
|
|
8
11
|
import styled from 'styled-components';
|
|
9
12
|
import { uiColors } from '../../constants/uiColors';
|
|
10
13
|
import { DraggableContainer } from '../DraggableContainer';
|
|
@@ -251,13 +254,13 @@ export const Store: React.FC<IStoreProps> = ({
|
|
|
251
254
|
characters: {
|
|
252
255
|
id: 'characters',
|
|
253
256
|
title: 'Char Trade',
|
|
254
|
-
icon: <
|
|
257
|
+
icon: <Users />,
|
|
255
258
|
content: customCharactersContent ?? null,
|
|
256
259
|
},
|
|
257
260
|
redeem: {
|
|
258
261
|
id: 'redeem',
|
|
259
262
|
title: 'Redeem',
|
|
260
|
-
icon: <
|
|
263
|
+
icon: <Receipt />,
|
|
261
264
|
content: onRedeem ? (
|
|
262
265
|
<StoreRedeemSection
|
|
263
266
|
onRedeem={onRedeem}
|
|
@@ -272,17 +275,17 @@ export const Store: React.FC<IStoreProps> = ({
|
|
|
272
275
|
icon: <Wallet width={18} height={18} />,
|
|
273
276
|
content: customWalletContent ?? (
|
|
274
277
|
<CenteredContent>
|
|
275
|
-
<CTAButton icon={<
|
|
278
|
+
<CTAButton icon={<Wallet />} label={`Open ${walletLabel ?? 'Wallet'}`} onClick={onShowWallet} />
|
|
276
279
|
</CenteredContent>
|
|
277
280
|
),
|
|
278
281
|
},
|
|
279
282
|
history: {
|
|
280
283
|
id: 'history',
|
|
281
284
|
title: 'History',
|
|
282
|
-
icon: <
|
|
285
|
+
icon: <DateTime />,
|
|
283
286
|
content: customHistoryContent ?? (
|
|
284
287
|
<CenteredContent>
|
|
285
|
-
<CTAButton icon={<
|
|
288
|
+
<CTAButton icon={<DateTime />} label="Open History" onClick={onShowHistory} />
|
|
286
289
|
</CenteredContent>
|
|
287
290
|
),
|
|
288
291
|
},
|
|
@@ -370,7 +373,7 @@ export const Store: React.FC<IStoreProps> = ({
|
|
|
370
373
|
{cartItems.length > 0 && (
|
|
371
374
|
<Footer>
|
|
372
375
|
<CTAButton
|
|
373
|
-
icon={<
|
|
376
|
+
icon={<ShoppingCart />}
|
|
374
377
|
label={`Proceed to Checkout (${currencySymbol}${getTotalPrice().toFixed(2)})`}
|
|
375
378
|
onClick={handleOpenCart}
|
|
376
379
|
fullWidth
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
UserAccountTypes,
|
|
5
5
|
} from '@rpg-engine/shared';
|
|
6
6
|
import React from 'react';
|
|
7
|
-
import {
|
|
7
|
+
import { ShoppingCart } from 'pixelarticons/react/ShoppingCart';
|
|
8
8
|
import styled from 'styled-components';
|
|
9
9
|
import { SelectArrow } from '../Arrow/SelectArrow';
|
|
10
10
|
import { ICharacterProps } from '../Character/CharacterSelection';
|
|
@@ -163,7 +163,7 @@ export const StoreCharacterSkinRow: React.FC<IStoreCharacterSkinRowProps> = ({
|
|
|
163
163
|
</ItemDetails>
|
|
164
164
|
<Controls>
|
|
165
165
|
<CTAButton
|
|
166
|
-
icon={<
|
|
166
|
+
icon={<ShoppingCart />}
|
|
167
167
|
label="Add"
|
|
168
168
|
onClick={handleAddToCart}
|
|
169
169
|
disabled={!hasRequiredAccount}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { ShoppingCart } from 'pixelarticons/react/ShoppingCart';
|
|
3
3
|
import styled from 'styled-components';
|
|
4
4
|
import { CTAButton } from '../shared/CTAButton/CTAButton';
|
|
5
5
|
import { Tabs } from '../shared/Tabs';
|
|
@@ -29,7 +29,7 @@ export const StoreHeader: React.FC<IStoreHeaderProps> = ({
|
|
|
29
29
|
/>
|
|
30
30
|
</TabsFlexWrapper>
|
|
31
31
|
<CartButtonWrapper>
|
|
32
|
-
<CTAButton icon={<
|
|
32
|
+
<CTAButton icon={<ShoppingCart />} onClick={onOpenCart} />
|
|
33
33
|
{cartItemCount > 0 && <CartBadge>{cartItemCount}</CartBadge>}
|
|
34
34
|
</CartButtonWrapper>
|
|
35
35
|
</HeaderRow>
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { IItemPack, IProductBlueprint } from '@rpg-engine/shared';
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import {
|
|
3
|
+
import { ArrowLeft } from 'pixelarticons/react/ArrowLeft';
|
|
4
|
+
import { ShoppingCart } from 'pixelarticons/react/ShoppingCart';
|
|
4
5
|
import styled from 'styled-components';
|
|
5
6
|
import { CTAButton } from '../shared/CTAButton/CTAButton';
|
|
6
7
|
import { MMORPGNumber } from '../../components/shared/MMORPGNumber';
|
|
@@ -33,7 +34,7 @@ export const StoreItemDetails: React.FC<IStoreItemDetailsProps> = ({
|
|
|
33
34
|
<Container>
|
|
34
35
|
<Header>
|
|
35
36
|
<BackButton onClick={onBack}>
|
|
36
|
-
<
|
|
37
|
+
<ArrowLeft />
|
|
37
38
|
<span>Back</span>
|
|
38
39
|
</BackButton>
|
|
39
40
|
</Header>
|
|
@@ -62,7 +63,7 @@ export const StoreItemDetails: React.FC<IStoreItemDetailsProps> = ({
|
|
|
62
63
|
|
|
63
64
|
<Actions>
|
|
64
65
|
<CTAButton
|
|
65
|
-
icon={<
|
|
66
|
+
icon={<ShoppingCart />}
|
|
66
67
|
label="Add to Cart"
|
|
67
68
|
onClick={() => onAddToCart(item as IProductBlueprint)}
|
|
68
69
|
fullWidth
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { IProductBlueprint, UserAccountTypes } from '@rpg-engine/shared';
|
|
2
2
|
import React, { useEffect, useState } from 'react';
|
|
3
|
-
import {
|
|
3
|
+
import { ShoppingCart } from 'pixelarticons/react/ShoppingCart';
|
|
4
|
+
import { Zap } from 'pixelarticons/react/Zap';
|
|
4
5
|
import styled from 'styled-components';
|
|
5
6
|
import { SelectArrow } from '../Arrow/SelectArrow';
|
|
6
7
|
import { CTAButton } from '../shared/CTAButton/CTAButton';
|
|
@@ -198,7 +199,7 @@ export const StoreItemRow: React.FC<IStoreItemRowProps> = ({
|
|
|
198
199
|
|
|
199
200
|
{onQuickBuy && (
|
|
200
201
|
<CTAButton
|
|
201
|
-
icon={<
|
|
202
|
+
icon={<Zap />}
|
|
202
203
|
label="Buy"
|
|
203
204
|
onClick={handleQuickBuy}
|
|
204
205
|
disabled={!hasRequiredAccount}
|
|
@@ -208,7 +209,7 @@ export const StoreItemRow: React.FC<IStoreItemRowProps> = ({
|
|
|
208
209
|
/>
|
|
209
210
|
)}
|
|
210
211
|
<CTAButton
|
|
211
|
-
icon={<
|
|
212
|
+
icon={<ShoppingCart />}
|
|
212
213
|
label="Add"
|
|
213
214
|
onClick={handleAddToCartInternal}
|
|
214
215
|
disabled={!hasRequiredAccount}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
+
import { Headphone } from 'pixelarticons/react/Headphone';
|
|
2
|
+
import { Lock } from 'pixelarticons/react/Lock';
|
|
3
|
+
import { Zap } from 'pixelarticons/react/Zap';
|
|
1
4
|
import React from 'react';
|
|
2
|
-
import { FaHeadset, FaLock, FaRocket } from 'react-icons/fa';
|
|
3
5
|
import styled from 'styled-components';
|
|
4
6
|
|
|
5
7
|
export interface ITrustSignal {
|
|
@@ -13,9 +15,9 @@ export interface ITrustBarProps {
|
|
|
13
15
|
|
|
14
16
|
const DefaultSignals: React.FC = () => (
|
|
15
17
|
<>
|
|
16
|
-
<Signal><SignalIcon><
|
|
17
|
-
<Signal><SignalIcon><
|
|
18
|
-
<Signal><SignalIcon><
|
|
18
|
+
<Signal><SignalIcon><Lock /></SignalIcon><SignalLabel>Secure Payment</SignalLabel></Signal>
|
|
19
|
+
<Signal><SignalIcon><Zap /></SignalIcon><SignalLabel>Instant Delivery</SignalLabel></Signal>
|
|
20
|
+
<Signal><SignalIcon><Headphone /></SignalIcon><SignalLabel>24/7 Support</SignalLabel></Signal>
|
|
19
21
|
</>
|
|
20
22
|
);
|
|
21
23
|
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { IItemPack } from '@rpg-engine/shared';
|
|
2
2
|
import React, { useCallback, useEffect } from 'react';
|
|
3
|
-
import {
|
|
3
|
+
import { ShoppingCart } from 'pixelarticons/react/ShoppingCart';
|
|
4
|
+
import { Zap } from 'pixelarticons/react/Zap';
|
|
4
5
|
import styled from 'styled-components';
|
|
5
6
|
import { CTAButton } from '../../shared/CTAButton/CTAButton';
|
|
6
7
|
import { ItemRowWrapper } from '../../shared/ItemRowWrapper';
|
|
@@ -97,9 +98,9 @@ const PackRowItem: React.FC<IPackRowItemProps> = ({
|
|
|
97
98
|
<SelectArrow direction="right" onPointerDown={incrementQuantity} size={24} />
|
|
98
99
|
</ArrowsContainer>
|
|
99
100
|
{onQuickBuy && (
|
|
100
|
-
<CTAButton icon={<
|
|
101
|
+
<CTAButton icon={<Zap />} label="Buy" onClick={handleQuickBuy} iconColor="#fff" textColor="#fff" />
|
|
101
102
|
)}
|
|
102
|
-
<CTAButton icon={<
|
|
103
|
+
<CTAButton icon={<ShoppingCart />} label="Add" onClick={handleAdd} pulse />
|
|
103
104
|
</Controls>
|
|
104
105
|
</PackRow>
|
|
105
106
|
);
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import React, { useState } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Check } from 'pixelarticons/react/Check';
|
|
3
|
+
import { Receipt } from 'pixelarticons/react/Receipt';
|
|
4
|
+
import { WarningDiamond } from 'pixelarticons/react/WarningDiamond';
|
|
3
5
|
import styled, { keyframes } from 'styled-components';
|
|
4
6
|
import { uiColors } from '../../../constants/uiColors';
|
|
5
7
|
import { CTAButton } from '../../shared/CTAButton/CTAButton';
|
|
@@ -65,7 +67,7 @@ export const StoreRedeemSection: React.FC<IStoreRedeemSectionProps> = ({
|
|
|
65
67
|
<Container>
|
|
66
68
|
<ResultContainer>
|
|
67
69
|
<SuccessIcon>
|
|
68
|
-
<
|
|
70
|
+
<Check width={32} height={32} />
|
|
69
71
|
</SuccessIcon>
|
|
70
72
|
<SuccessTitle>Code Redeemed!</SuccessTitle>
|
|
71
73
|
{dcAmount != null && (
|
|
@@ -74,7 +76,7 @@ export const StoreRedeemSection: React.FC<IStoreRedeemSectionProps> = ({
|
|
|
74
76
|
<SuccessHint>Your wallet balance has been updated.</SuccessHint>
|
|
75
77
|
<ButtonWrapper>
|
|
76
78
|
<CTAButton
|
|
77
|
-
icon={<
|
|
79
|
+
icon={<Receipt />}
|
|
78
80
|
label="Redeem Another"
|
|
79
81
|
onClick={handleReset}
|
|
80
82
|
/>
|
|
@@ -89,12 +91,12 @@ export const StoreRedeemSection: React.FC<IStoreRedeemSectionProps> = ({
|
|
|
89
91
|
<Container>
|
|
90
92
|
<ResultContainer>
|
|
91
93
|
<ErrorIcon>
|
|
92
|
-
<
|
|
94
|
+
<WarningDiamond width={32} height={32} />
|
|
93
95
|
</ErrorIcon>
|
|
94
96
|
<ErrorTitle>{errorMessage}</ErrorTitle>
|
|
95
97
|
<ButtonWrapper>
|
|
96
98
|
<CTAButton
|
|
97
|
-
icon={<
|
|
99
|
+
icon={<Receipt />}
|
|
98
100
|
label="Try Again"
|
|
99
101
|
onClick={handleReset}
|
|
100
102
|
/>
|
|
@@ -126,7 +128,7 @@ export const StoreRedeemSection: React.FC<IStoreRedeemSectionProps> = ({
|
|
|
126
128
|
</InputRow>
|
|
127
129
|
<ButtonWrapper>
|
|
128
130
|
<CTAButton
|
|
129
|
-
icon={<
|
|
131
|
+
icon={<Receipt />}
|
|
130
132
|
label={status === 'loading' ? 'Redeeming...' : 'Redeem Code'}
|
|
131
133
|
onClick={() => { void handleSubmit(); }}
|
|
132
134
|
disabled={!canSubmit}
|