@0xsquid/ui 0.8.2 → 0.9.0
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/README.md +22 -0
- package/dist/cjs/index.js +134 -71
- package/dist/cjs/types/components/badges/index.d.ts +1 -0
- package/dist/cjs/types/components/controls/Input.d.ts +3 -1
- package/dist/cjs/types/components/controls/Tooltip.d.ts +1 -2
- package/dist/cjs/types/components/layout/DropdownMenu.d.ts +4 -1
- package/dist/cjs/types/components/layout/ErrorMessage.d.ts +5 -2
- package/dist/cjs/types/components/layout/InfoBox.d.ts +8 -0
- package/dist/cjs/types/components/layout/Menu.d.ts +2 -1
- package/dist/cjs/types/components/layout/ProfileHeaderBackground.d.ts +1 -0
- package/dist/cjs/types/components/layout/SwapConfiguration.d.ts +2 -1
- package/dist/cjs/types/components/layout/index.d.ts +2 -0
- package/dist/cjs/types/components/lists/DropdownMenuItem.d.ts +2 -1
- package/dist/cjs/types/components/lists/HistoryItem.d.ts +3 -1
- package/dist/cjs/types/components/lists/SettingsItem.d.ts +5 -1
- package/dist/cjs/types/hooks/index.d.ts +1 -1
- package/dist/cjs/types/hooks/useDropdownMenu.d.ts +10 -0
- package/dist/cjs/types/stories/buttons/AssetsButton.stories.d.ts +2 -1
- package/dist/cjs/types/stories/controls/Input.stories.d.ts +1 -0
- package/dist/cjs/types/stories/layout/ErrorMessage.stories.d.ts +1 -0
- package/dist/cjs/types/stories/layout/InfoBox.stories.d.ts +7 -0
- package/dist/cjs/types/stories/lists/HistoryItem.stories.d.ts +1 -0
- package/dist/cjs/types/stories/lists/SettingsItem.stories.d.ts +3 -0
- package/dist/esm/index.js +131 -71
- package/dist/esm/types/components/badges/index.d.ts +1 -0
- package/dist/esm/types/components/controls/Input.d.ts +3 -1
- package/dist/esm/types/components/controls/Tooltip.d.ts +1 -2
- package/dist/esm/types/components/layout/DropdownMenu.d.ts +4 -1
- package/dist/esm/types/components/layout/ErrorMessage.d.ts +5 -2
- package/dist/esm/types/components/layout/InfoBox.d.ts +8 -0
- package/dist/esm/types/components/layout/Menu.d.ts +2 -1
- package/dist/esm/types/components/layout/ProfileHeaderBackground.d.ts +1 -0
- package/dist/esm/types/components/layout/SwapConfiguration.d.ts +2 -1
- package/dist/esm/types/components/layout/index.d.ts +2 -0
- package/dist/esm/types/components/lists/DropdownMenuItem.d.ts +2 -1
- package/dist/esm/types/components/lists/HistoryItem.d.ts +3 -1
- package/dist/esm/types/components/lists/SettingsItem.d.ts +5 -1
- package/dist/esm/types/hooks/index.d.ts +1 -1
- package/dist/esm/types/hooks/useDropdownMenu.d.ts +10 -0
- package/dist/esm/types/stories/buttons/AssetsButton.stories.d.ts +2 -1
- package/dist/esm/types/stories/controls/Input.stories.d.ts +1 -0
- package/dist/esm/types/stories/layout/ErrorMessage.stories.d.ts +1 -0
- package/dist/esm/types/stories/layout/InfoBox.stories.d.ts +7 -0
- package/dist/esm/types/stories/lists/HistoryItem.stories.d.ts +1 -0
- package/dist/esm/types/stories/lists/SettingsItem.stories.d.ts +3 -0
- package/dist/index.css +38 -20
- package/dist/index.d.ts +44 -16
- package/package.json +1 -1
- package/dist/cjs/types/hooks/useModal.d.ts +0 -10
- package/dist/esm/types/hooks/useModal.d.ts +0 -10
|
@@ -4,5 +4,6 @@ export interface DropdownMenuItemProps {
|
|
|
4
4
|
labelClassName?: string;
|
|
5
5
|
imageUrl?: string;
|
|
6
6
|
icon?: React.ReactNode;
|
|
7
|
+
onClick?: () => void;
|
|
7
8
|
}
|
|
8
|
-
export declare function DropdownMenuItem({ label, imageUrl, icon, labelClassName, }: DropdownMenuItemProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export declare function DropdownMenuItem({ label, imageUrl, icon, labelClassName, onClick, }: DropdownMenuItemProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { DropdownMenuItemProps } from './DropdownMenuItem';
|
|
1
2
|
interface HistoryItemProps {
|
|
2
3
|
firstImageUrl: string;
|
|
3
4
|
secondImageUrl: string;
|
|
@@ -8,6 +9,7 @@ interface HistoryItemProps {
|
|
|
8
9
|
dateCompleted: string;
|
|
9
10
|
fromAmount: string;
|
|
10
11
|
toAmount: string;
|
|
12
|
+
dropdownMenuItems?: DropdownMenuItemProps[];
|
|
11
13
|
}
|
|
12
|
-
export declare function HistoryItem({ firstImageUrl, secondImageUrl, isPending, dateCompleted, fromAmount, fromLabel, toAmount, toLabel, pendingLabel, }: HistoryItemProps): import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
export declare function HistoryItem({ firstImageUrl, secondImageUrl, isPending, dateCompleted, fromAmount, fromLabel, toAmount, toLabel, pendingLabel, dropdownMenuItems, }: HistoryItemProps): import("react/jsx-runtime").JSX.Element;
|
|
13
15
|
export {};
|
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import { TooltipProps } from '../controls';
|
|
2
3
|
export interface SettingsItemProps {
|
|
3
4
|
icon: React.ReactNode;
|
|
4
5
|
label: string;
|
|
5
6
|
controls?: React.ReactNode;
|
|
6
7
|
transparentControls?: boolean;
|
|
7
8
|
showHelpIcon?: boolean;
|
|
9
|
+
link?: string;
|
|
10
|
+
transparent?: boolean;
|
|
11
|
+
helpTooltip?: Omit<TooltipProps, 'children'>;
|
|
8
12
|
}
|
|
9
|
-
export declare function SettingsItem({ icon, label, controls, transparentControls, showHelpIcon, }: SettingsItemProps): import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export declare function SettingsItem({ icon, label, controls, transparentControls, showHelpIcon, link, transparent, helpTooltip, }: SettingsItemProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './
|
|
1
|
+
export * from './useDropdownMenu';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare function useDropdownMenu(props?: {
|
|
3
|
+
initialIsModalOpen?: boolean;
|
|
4
|
+
}): {
|
|
5
|
+
isDropdownOpen: boolean;
|
|
6
|
+
openDropdown: () => void;
|
|
7
|
+
closeDropdown: () => void;
|
|
8
|
+
dropdownRef: React.RefObject<HTMLDivElement>;
|
|
9
|
+
openDropdownButtonRef: React.RefObject<HTMLButtonElement>;
|
|
10
|
+
};
|
|
@@ -5,5 +5,6 @@ export default meta;
|
|
|
5
5
|
type Story = StoryObj<typeof meta>;
|
|
6
6
|
export declare const Empty: Story;
|
|
7
7
|
export declare const ChainOnly: Story;
|
|
8
|
-
export declare const
|
|
8
|
+
export declare const ChainAndTokenLightText: Story;
|
|
9
|
+
export declare const ChainAndTokenDarkText: Story;
|
|
9
10
|
export declare const LongTokenSymbol: Story;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { InfoBox } from '../../components/layout/InfoBox';
|
|
3
|
+
declare const meta: Meta<typeof InfoBox>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof meta>;
|
|
6
|
+
export declare const Default: Story;
|
|
7
|
+
export declare const WithIcon: Story;
|
|
@@ -7,3 +7,6 @@ export declare const Default: Story;
|
|
|
7
7
|
export declare const WithControls: Story;
|
|
8
8
|
export declare const WithoutHelpIcon: Story;
|
|
9
9
|
export declare const TransparentControls: Story;
|
|
10
|
+
export declare const Link: Story;
|
|
11
|
+
export declare const Transparent: Story;
|
|
12
|
+
export declare const WithHelpTooltip: Story;
|
package/dist/index.css
CHANGED
|
@@ -605,10 +605,6 @@ video {
|
|
|
605
605
|
left: -5px;
|
|
606
606
|
}
|
|
607
607
|
|
|
608
|
-
.-tw-left-\[85px\] {
|
|
609
|
-
left: -85px;
|
|
610
|
-
}
|
|
611
|
-
|
|
612
608
|
.-tw-right-1\/3 {
|
|
613
609
|
right: -33.333333%;
|
|
614
610
|
}
|
|
@@ -633,6 +629,10 @@ video {
|
|
|
633
629
|
top: -4px;
|
|
634
630
|
}
|
|
635
631
|
|
|
632
|
+
.-tw-top-\[55px\] {
|
|
633
|
+
top: -55px;
|
|
634
|
+
}
|
|
635
|
+
|
|
636
636
|
.-tw-top-full {
|
|
637
637
|
top: -100%;
|
|
638
638
|
}
|
|
@@ -649,6 +649,10 @@ video {
|
|
|
649
649
|
bottom: 0.5rem;
|
|
650
650
|
}
|
|
651
651
|
|
|
652
|
+
.tw-bottom-7 {
|
|
653
|
+
bottom: 1.75rem;
|
|
654
|
+
}
|
|
655
|
+
|
|
652
656
|
.tw-bottom-full {
|
|
653
657
|
bottom: 100%;
|
|
654
658
|
}
|
|
@@ -669,8 +673,8 @@ video {
|
|
|
669
673
|
left: -14px;
|
|
670
674
|
}
|
|
671
675
|
|
|
672
|
-
.tw-left-\[
|
|
673
|
-
left:
|
|
676
|
+
.tw-left-\[15px\] {
|
|
677
|
+
left: 15px;
|
|
674
678
|
}
|
|
675
679
|
|
|
676
680
|
.tw-left-\[54px\] {
|
|
@@ -697,6 +701,14 @@ video {
|
|
|
697
701
|
right: 1rem;
|
|
698
702
|
}
|
|
699
703
|
|
|
704
|
+
.tw-right-\[40px\] {
|
|
705
|
+
right: 40px;
|
|
706
|
+
}
|
|
707
|
+
|
|
708
|
+
.tw-right-\[calc\(100\%-10px\)\] {
|
|
709
|
+
right: calc(100% - 10px);
|
|
710
|
+
}
|
|
711
|
+
|
|
700
712
|
.tw-right-squid-xxs {
|
|
701
713
|
right: 0.3125rem;
|
|
702
714
|
}
|
|
@@ -1495,6 +1507,10 @@ video {
|
|
|
1495
1507
|
animation: tw-translate-to-top 0.4s ease-in-out both;
|
|
1496
1508
|
}
|
|
1497
1509
|
|
|
1510
|
+
.tw-cursor-help {
|
|
1511
|
+
cursor: help;
|
|
1512
|
+
}
|
|
1513
|
+
|
|
1498
1514
|
.tw-cursor-not-allowed {
|
|
1499
1515
|
cursor: not-allowed;
|
|
1500
1516
|
}
|
|
@@ -1503,11 +1519,6 @@ video {
|
|
|
1503
1519
|
cursor: pointer;
|
|
1504
1520
|
}
|
|
1505
1521
|
|
|
1506
|
-
.tw-scroll-px-5 {
|
|
1507
|
-
scroll-padding-left: 1.25rem;
|
|
1508
|
-
scroll-padding-right: 1.25rem;
|
|
1509
|
-
}
|
|
1510
|
-
|
|
1511
1522
|
.tw-grid-cols-\[180px_1fr_299px\] {
|
|
1512
1523
|
grid-template-columns: 180px 1fr 299px;
|
|
1513
1524
|
}
|
|
@@ -1632,10 +1643,6 @@ video {
|
|
|
1632
1643
|
border-radius: 1rem;
|
|
1633
1644
|
}
|
|
1634
1645
|
|
|
1635
|
-
.tw-rounded-\[25px\] {
|
|
1636
|
-
border-radius: 25px;
|
|
1637
|
-
}
|
|
1638
|
-
|
|
1639
1646
|
.tw-rounded-full {
|
|
1640
1647
|
border-radius: 9999px;
|
|
1641
1648
|
}
|
|
@@ -1998,11 +2005,6 @@ video {
|
|
|
1998
2005
|
padding-right: 1rem;
|
|
1999
2006
|
}
|
|
2000
2007
|
|
|
2001
|
-
.tw-px-5 {
|
|
2002
|
-
padding-left: 1.25rem;
|
|
2003
|
-
padding-right: 1.25rem;
|
|
2004
|
-
}
|
|
2005
|
-
|
|
2006
2008
|
.tw-px-\[3px\] {
|
|
2007
2009
|
padding-left: 3px;
|
|
2008
2010
|
padding-right: 3px;
|
|
@@ -2228,6 +2230,10 @@ video {
|
|
|
2228
2230
|
line-height: 1rem;
|
|
2229
2231
|
}
|
|
2230
2232
|
|
|
2233
|
+
.\!tw-font-medium {
|
|
2234
|
+
font-weight: 500 !important;
|
|
2235
|
+
}
|
|
2236
|
+
|
|
2231
2237
|
.tw-font-heading-bold {
|
|
2232
2238
|
font-weight: 600;
|
|
2233
2239
|
}
|
|
@@ -2455,6 +2461,10 @@ video {
|
|
|
2455
2461
|
outline-color: var(--squid-theme-material-light-thin);
|
|
2456
2462
|
}
|
|
2457
2463
|
|
|
2464
|
+
.tw-outline-status-negative {
|
|
2465
|
+
outline-color: var(--squid-theme-status-negative);
|
|
2466
|
+
}
|
|
2467
|
+
|
|
2458
2468
|
.tw-backdrop-blur-2xl {
|
|
2459
2469
|
--tw-backdrop-blur: blur(40px);
|
|
2460
2470
|
-webkit-backdrop-filter: var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);
|
|
@@ -2503,6 +2513,10 @@ video {
|
|
|
2503
2513
|
transition-duration: 150ms;
|
|
2504
2514
|
}
|
|
2505
2515
|
|
|
2516
|
+
.tw-duration-200 {
|
|
2517
|
+
transition-duration: 200ms;
|
|
2518
|
+
}
|
|
2519
|
+
|
|
2506
2520
|
.tw-duration-300 {
|
|
2507
2521
|
transition-duration: 300ms;
|
|
2508
2522
|
}
|
|
@@ -2575,6 +2589,10 @@ li {
|
|
|
2575
2589
|
background-color: var(--squid-theme-material-light-thin);
|
|
2576
2590
|
}
|
|
2577
2591
|
|
|
2592
|
+
.hover\:tw-text-grey-400:hover {
|
|
2593
|
+
color: var(--squid-theme-grey-400);
|
|
2594
|
+
}
|
|
2595
|
+
|
|
2578
2596
|
.focus\:tw-bg-material-light-thin:focus {
|
|
2579
2597
|
background-color: var(--squid-theme-material-light-thin);
|
|
2580
2598
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -12,6 +12,11 @@ interface BadgeImageProps {
|
|
|
12
12
|
type BadgeSize = 'sm' | 'md';
|
|
13
13
|
declare function BadgeImage({ imageUrl, badgeUrl, size, extraMarginForBadge, rounded, }: BadgeImageProps): react_jsx_runtime.JSX.Element | null;
|
|
14
14
|
|
|
15
|
+
declare function LoadingSkeleton({ className, height, }: {
|
|
16
|
+
className?: string;
|
|
17
|
+
height?: string;
|
|
18
|
+
}): react_jsx_runtime.JSX.Element;
|
|
19
|
+
|
|
15
20
|
interface UsdAmountProps {
|
|
16
21
|
usdAmount: string;
|
|
17
22
|
}
|
|
@@ -101,8 +106,10 @@ interface InputProps extends React.InputHTMLAttributes<HTMLInputElement> {
|
|
|
101
106
|
showIcon?: boolean;
|
|
102
107
|
showPasteButton?: boolean;
|
|
103
108
|
icon?: React.ReactNode;
|
|
109
|
+
isError?: boolean;
|
|
110
|
+
onPasteButtonClick?: () => void;
|
|
104
111
|
}
|
|
105
|
-
declare function Input({ placeholder, showIcon, showPasteButton, className, icon, ...props }: InputProps): react_jsx_runtime.JSX.Element;
|
|
112
|
+
declare function Input({ placeholder, showIcon, showPasteButton, className, icon, isError, onPasteButtonClick, ...props }: InputProps): react_jsx_runtime.JSX.Element;
|
|
106
113
|
|
|
107
114
|
interface Props extends InputHTMLAttributes<HTMLInputElement> {
|
|
108
115
|
onParsedValueChanged: (value: string) => void;
|
|
@@ -178,8 +185,9 @@ interface DropdownMenuItemProps {
|
|
|
178
185
|
labelClassName?: string;
|
|
179
186
|
imageUrl?: string;
|
|
180
187
|
icon?: React.ReactNode;
|
|
188
|
+
onClick?: () => void;
|
|
181
189
|
}
|
|
182
|
-
declare function DropdownMenuItem({ label, imageUrl, icon, labelClassName, }: DropdownMenuItemProps): react_jsx_runtime.JSX.Element;
|
|
190
|
+
declare function DropdownMenuItem({ label, imageUrl, icon, labelClassName, onClick, }: DropdownMenuItemProps): react_jsx_runtime.JSX.Element;
|
|
183
191
|
|
|
184
192
|
interface HistoryItemProps {
|
|
185
193
|
firstImageUrl: string;
|
|
@@ -191,8 +199,9 @@ interface HistoryItemProps {
|
|
|
191
199
|
dateCompleted: string;
|
|
192
200
|
fromAmount: string;
|
|
193
201
|
toAmount: string;
|
|
202
|
+
dropdownMenuItems?: DropdownMenuItemProps[];
|
|
194
203
|
}
|
|
195
|
-
declare function HistoryItem({ firstImageUrl, secondImageUrl, isPending, dateCompleted, fromAmount, fromLabel, toAmount, toLabel, pendingLabel, }: HistoryItemProps): react_jsx_runtime.JSX.Element;
|
|
204
|
+
declare function HistoryItem({ firstImageUrl, secondImageUrl, isPending, dateCompleted, fromAmount, fromLabel, toAmount, toLabel, pendingLabel, dropdownMenuItems, }: HistoryItemProps): react_jsx_runtime.JSX.Element;
|
|
196
205
|
|
|
197
206
|
interface ListItemProps extends React.HTMLAttributes<HTMLLIElement> {
|
|
198
207
|
itemTitle: string | React.ReactNode;
|
|
@@ -238,8 +247,11 @@ interface SettingsItemProps {
|
|
|
238
247
|
controls?: React.ReactNode;
|
|
239
248
|
transparentControls?: boolean;
|
|
240
249
|
showHelpIcon?: boolean;
|
|
250
|
+
link?: string;
|
|
251
|
+
transparent?: boolean;
|
|
252
|
+
helpTooltip?: Omit<TooltipProps, 'children'>;
|
|
241
253
|
}
|
|
242
|
-
declare function SettingsItem({ icon, label, controls, transparentControls, showHelpIcon, }: SettingsItemProps): react_jsx_runtime.JSX.Element;
|
|
254
|
+
declare function SettingsItem({ icon, label, controls, transparentControls, showHelpIcon, link, transparent, helpTooltip, }: SettingsItemProps): react_jsx_runtime.JSX.Element;
|
|
243
255
|
|
|
244
256
|
interface SwapDetailListItemProps {
|
|
245
257
|
label: string;
|
|
@@ -260,14 +272,26 @@ declare function SwapStepItem({ descriptionBlocks, chipContent, showStepSeparato
|
|
|
260
272
|
|
|
261
273
|
interface DropdownMenuProps {
|
|
262
274
|
dropdownRef?: React.RefObject<HTMLDivElement>;
|
|
275
|
+
menuRef?: React.RefObject<HTMLDivElement>;
|
|
263
276
|
items: DropdownMenuItemProps[];
|
|
264
277
|
className?: string;
|
|
278
|
+
isHidden?: boolean;
|
|
279
|
+
listClassName?: string;
|
|
265
280
|
}
|
|
266
|
-
declare function DropdownMenu({ dropdownRef, items, className, }: DropdownMenuProps): react_jsx_runtime.JSX.Element;
|
|
281
|
+
declare function DropdownMenu({ dropdownRef, items, className, menuRef, isHidden, listClassName, }: DropdownMenuProps): react_jsx_runtime.JSX.Element;
|
|
267
282
|
|
|
268
|
-
|
|
283
|
+
type ErrorMessageProps = {
|
|
269
284
|
message: string;
|
|
270
|
-
|
|
285
|
+
showIcon?: boolean;
|
|
286
|
+
};
|
|
287
|
+
declare function ErrorMessage({ message, showIcon }: ErrorMessageProps): react_jsx_runtime.JSX.Element;
|
|
288
|
+
|
|
289
|
+
interface InfoBoxProps {
|
|
290
|
+
title: string;
|
|
291
|
+
description: string;
|
|
292
|
+
icon?: React.ReactNode;
|
|
293
|
+
}
|
|
294
|
+
declare function InfoBox({ title, description, icon }: InfoBoxProps): react_jsx_runtime.JSX.Element;
|
|
271
295
|
|
|
272
296
|
type Rounded = 'sm' | 'lg';
|
|
273
297
|
interface MenuProps extends React$1.ComponentProps<'div'> {
|
|
@@ -276,8 +300,9 @@ interface MenuProps extends React$1.ComponentProps<'div'> {
|
|
|
276
300
|
title?: string;
|
|
277
301
|
displayControls?: boolean;
|
|
278
302
|
rounded?: Rounded;
|
|
303
|
+
menuRef?: React$1.RefObject<HTMLDivElement>;
|
|
279
304
|
}
|
|
280
|
-
declare function Menu({ children, containerClassName, contentClassName, title, displayControls, rounded, ...props }: MenuProps): react_jsx_runtime.JSX.Element;
|
|
305
|
+
declare function Menu({ children, containerClassName, contentClassName, title, displayControls, rounded, menuRef, ...props }: MenuProps): react_jsx_runtime.JSX.Element;
|
|
281
306
|
|
|
282
307
|
interface ModalProps {
|
|
283
308
|
children: React.ReactNode;
|
|
@@ -302,6 +327,8 @@ declare function NavigationBar({ title, displayBackButton, logoUrl, transparent,
|
|
|
302
327
|
|
|
303
328
|
declare function ProductCard({ children }: React.PropsWithChildren): react_jsx_runtime.JSX.Element;
|
|
304
329
|
|
|
330
|
+
declare function ProfileHeaderBackground(): react_jsx_runtime.JSX.Element;
|
|
331
|
+
|
|
305
332
|
interface SwapConfigurationProps {
|
|
306
333
|
direction: SwapDirection;
|
|
307
334
|
priceImpactPercentage?: string;
|
|
@@ -329,8 +356,9 @@ interface SwapConfigurationProps {
|
|
|
329
356
|
message: string;
|
|
330
357
|
};
|
|
331
358
|
criticalPriceImpactPercentage?: number;
|
|
359
|
+
emptyAddressLabel?: string;
|
|
332
360
|
}
|
|
333
|
-
declare function SwapConfiguration({ priceImpactPercentage, amount, forcedAmount, swapAmountUsd, balance, isFetching, chain, token, direction, onAmountChange, onWalletButtonClick, onAssetsButtonClick, onBalanceButtonClick, address, error, criticalPriceImpactPercentage, }: SwapConfigurationProps): react_jsx_runtime.JSX.Element;
|
|
361
|
+
declare function SwapConfiguration({ priceImpactPercentage, amount, forcedAmount, swapAmountUsd, balance, isFetching, chain, token, direction, onAmountChange, onWalletButtonClick, onAssetsButtonClick, onBalanceButtonClick, address, error, criticalPriceImpactPercentage, emptyAddressLabel, }: SwapConfigurationProps): react_jsx_runtime.JSX.Element;
|
|
334
362
|
|
|
335
363
|
interface SwapProgressViewHeaderProps {
|
|
336
364
|
title: string;
|
|
@@ -416,14 +444,14 @@ declare function SquidConfigProvider({ theme, children, themeType, }: {
|
|
|
416
444
|
themeType?: ThemeType;
|
|
417
445
|
}): react_jsx_runtime.JSX.Element;
|
|
418
446
|
|
|
419
|
-
declare function
|
|
447
|
+
declare function useDropdownMenu(props?: {
|
|
420
448
|
initialIsModalOpen?: boolean;
|
|
421
449
|
}): {
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
450
|
+
isDropdownOpen: boolean;
|
|
451
|
+
openDropdown: () => void;
|
|
452
|
+
closeDropdown: () => void;
|
|
453
|
+
dropdownRef: React.RefObject<HTMLDivElement>;
|
|
454
|
+
openDropdownButtonRef: React.RefObject<HTMLButtonElement>;
|
|
427
455
|
};
|
|
428
456
|
|
|
429
|
-
export { AddressButton, ArrowButton, AssetsButton, BadgeImage, BodyText, Boost, BoostButton, Button, CaptionText, Chip, DetailsToolbar, DropdownMenu, DropdownMenuItem, type DropdownMenuItemProps, ErrorMessage, FeeButton, HeadingText, HistoryItem, Input, ListItem, Menu, MenuItem, Modal, NavigationBar, NumericInput, ProductCard, SectionTitle, SettingsButton, type SettingsButtonProps, SettingsItem, type SettingsItemProps, SettingsSlider, type SettingsSliderProps, SquidConfigProvider, type SquidTheme, SwapConfiguration, SwapDetailListItem, SwapProgressViewHeader, SwapStepItem, SwapStepsCollapsed, Switch, TokenPair, Tooltip, type TooltipThreshold, type TooltipWidth, UsdAmount,
|
|
457
|
+
export { AddressButton, ArrowButton, AssetsButton, BadgeImage, BodyText, Boost, BoostButton, Button, CaptionText, Chip, DetailsToolbar, DropdownMenu, DropdownMenuItem, type DropdownMenuItemProps, ErrorMessage, FeeButton, HeadingText, HistoryItem, InfoBox, Input, ListItem, LoadingSkeleton, Menu, MenuItem, Modal, NavigationBar, NumericInput, ProductCard, ProfileHeaderBackground, SectionTitle, SettingsButton, type SettingsButtonProps, SettingsItem, type SettingsItemProps, SettingsSlider, type SettingsSliderProps, SquidConfigProvider, type SquidTheme, SwapConfiguration, SwapDetailListItem, SwapProgressViewHeader, SwapStepItem, SwapStepsCollapsed, Switch, TokenPair, Tooltip, type TooltipProps, type TooltipThreshold, type TooltipWidth, UsdAmount, useDropdownMenu };
|
package/package.json
CHANGED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
export declare function useModal(props?: {
|
|
3
|
-
initialIsModalOpen?: boolean;
|
|
4
|
-
}): {
|
|
5
|
-
isModalOpen: boolean;
|
|
6
|
-
openModal: () => void;
|
|
7
|
-
closeModal: () => void;
|
|
8
|
-
modalRef: React.RefObject<HTMLDivElement>;
|
|
9
|
-
openModalButtonRef: React.RefObject<HTMLButtonElement>;
|
|
10
|
-
};
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
export declare function useModal(props?: {
|
|
3
|
-
initialIsModalOpen?: boolean;
|
|
4
|
-
}): {
|
|
5
|
-
isModalOpen: boolean;
|
|
6
|
-
openModal: () => void;
|
|
7
|
-
closeModal: () => void;
|
|
8
|
-
modalRef: React.RefObject<HTMLDivElement>;
|
|
9
|
-
openModalButtonRef: React.RefObject<HTMLButtonElement>;
|
|
10
|
-
};
|