@gearbox-protocol/ui-kit 3.14.0-next.6 → 3.14.0-next.61
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 +1 -0
- package/dist/cjs/components/alert-badge/alert-badge.cjs +1 -1
- package/dist/cjs/components/app-bar/app-bar.cjs +1 -1
- package/dist/cjs/components/apy/apy.cjs +1 -1
- package/dist/cjs/components/assets-list-cell/assets-list-cell.cjs +1 -1
- package/dist/cjs/components/block-sync/block-sync.cjs +1 -1
- package/dist/cjs/components/block-sync-pill/block-sync-pill.cjs +1 -0
- package/dist/cjs/components/block-sync-pill/block-sync-status.cjs +1 -0
- package/dist/cjs/components/block-sync-pill/index.cjs +1 -0
- package/dist/cjs/components/buttons/button/button.cjs +1 -1
- package/dist/cjs/components/checkbox/checkbox-labeled.cjs +1 -1
- package/dist/cjs/components/client-adapters/styled-button/styled-button.cjs +1 -1
- package/dist/cjs/components/client-adapters/styled-rounded-image/styled-rounded-image.cjs +1 -1
- package/dist/cjs/components/complex-input/complex-input.cjs +1 -1
- package/dist/cjs/components/composites/credit-account-history/body.cjs +1 -0
- package/dist/cjs/components/composites/credit-account-history/cells/details.cjs +1 -0
- package/dist/cjs/components/composites/credit-account-history/cells/hash.cjs +1 -0
- package/dist/cjs/components/composites/credit-account-history/cells/index.cjs +1 -0
- package/dist/cjs/components/composites/credit-account-history/cells/protocol.cjs +1 -0
- package/dist/cjs/components/composites/credit-account-history/cells/token-list.cjs +1 -0
- package/dist/cjs/components/composites/credit-account-history/credit-account-history.cjs +1 -0
- package/dist/cjs/components/composites/credit-account-history/index.cjs +1 -0
- package/dist/cjs/components/composites/credit-account-history/line.cjs +1 -0
- package/dist/cjs/components/composites/credit-account-history/types.cjs +1 -0
- package/dist/cjs/components/composites/index.cjs +1 -1
- package/dist/cjs/components/composites/notification-center/index.cjs +1 -0
- package/dist/cjs/components/composites/notification-center/notification-center.cjs +1 -0
- package/dist/cjs/components/composites/notification-center/types.cjs +1 -0
- package/dist/cjs/components/composites/pool-table/columns.cjs +1 -1
- package/dist/cjs/components/composites/tx-preview/confirm/amounts/TransactionConfirmAmountField.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/amounts/constants.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/amounts/index.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/dialog/TransactionConfirmModalView.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/dialog/TransactionConfirmPageView.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/dialog/TransactionConfirmShell.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/dialog/computeTransactionConfirmDialogLayout.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/dialog/constants.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/dialog/index.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/dialog/transactionConfirmPhase.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/execution/TransactionConfirmExecuteButton.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/execution/index.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/index.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/result/TransactionConfirmFailureResult.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/result/TransactionConfirmSuccessIcon.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/result/TransactionConfirmSuccessResult.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/result/TransactionConfirmTxHashRow.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/result/constants.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/result/index.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/stepper/ProgressStepper.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/stepper/constants.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/stepper/index.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/confirm/stepper/transactionExecutionStepTypes.cjs +1 -0
- package/dist/cjs/components/composites/tx-preview/index.cjs +1 -0
- package/dist/cjs/components/compound-apy/compound-apy.cjs +1 -1
- package/dist/cjs/components/confirm-menu/confirm-menu.cjs +1 -1
- package/dist/cjs/components/detailed-page-title/detailed-page-title.cjs +1 -1
- package/dist/cjs/components/graph/formatters.cjs +1 -1
- package/dist/cjs/components/graph/graph.cjs +1 -1
- package/dist/cjs/components/graph/index.cjs +1 -1
- package/dist/cjs/components/health-factor/health-factor.cjs +1 -1
- package/dist/cjs/components/index.cjs +1 -1
- package/dist/cjs/components/layout/app-footer/app-footer.cjs +1 -0
- package/dist/cjs/components/layout/app-footer/index.cjs +1 -0
- package/dist/cjs/components/layout/app-header/app-header.cjs +1 -0
- package/dist/cjs/components/layout/app-header/index.cjs +1 -0
- package/dist/cjs/components/layout/index.cjs +1 -1
- package/dist/cjs/components/layout/main-aside-layout/main-aside-layout.cjs +1 -1
- package/dist/cjs/components/legal-agreement/index.cjs +1 -1
- package/dist/cjs/components/legal-agreement/legal-agreement-awaiting-panel.cjs +1 -0
- package/dist/cjs/components/legal-agreement/legal-agreement-dialog.cjs +1 -1
- package/dist/cjs/components/legal-agreement/legal-agreement-link.cjs +1 -0
- package/dist/cjs/components/legal-agreement/legal-agreement-panel.cjs +1 -0
- package/dist/cjs/components/legal-agreement/legal-agreement-theme.cjs +1 -0
- package/dist/cjs/components/legal-agreement/legal-agreement.stories-config.cjs +1 -0
- package/dist/cjs/components/link/link.cjs +1 -1
- package/dist/cjs/components/loader-guard/loader-guard.cjs +1 -1
- package/dist/cjs/components/markdown-viewer/markdown-viewer.cjs +1 -1
- package/dist/cjs/components/segmented-control/segmented-control.cjs +1 -1
- package/dist/cjs/components/smart-number-input/smart-number-input.cjs +1 -1
- package/dist/cjs/components/tab-control/tab-control.cjs +1 -1
- package/dist/cjs/components/time-to-liquidation/time-to-liquidation.cjs +1 -1
- package/dist/cjs/components/token-template/token-template.cjs +1 -1
- package/dist/cjs/components/tokens-list-cell/tokens-list-cell.cjs +1 -1
- package/dist/cjs/components/trading-view/trading-view.cjs +1 -1
- package/dist/cjs/components/vertical-indicator/vertical-indicator.cjs +1 -1
- package/dist/cjs/components/with-copy/with-copy.cjs +1 -1
- package/dist/cjs/configs/tailwind-preset.cjs +1 -1
- package/dist/cjs/hooks/index.cjs +1 -1
- package/dist/cjs/hooks/use-filter.cjs +1 -1
- package/dist/cjs/index.cjs +1 -1
- package/dist/cjs/locale/en.json.cjs +1 -1
- package/dist/cjs/test-ids/index.cjs +1 -1
- package/dist/cjs/test-ids/notification-center.cjs +1 -0
- package/dist/esm/components/alert-badge/alert-badge.js +12 -10
- package/dist/esm/components/app-bar/app-bar.js +1 -1
- package/dist/esm/components/apy/apy.js +9 -9
- package/dist/esm/components/assets-list-cell/assets-list-cell.js +14 -8
- package/dist/esm/components/block-sync/block-sync.js +14 -8
- package/dist/esm/components/block-sync-pill/block-sync-pill.js +243 -0
- package/dist/esm/components/block-sync-pill/block-sync-status.js +12 -0
- package/dist/esm/components/block-sync-pill/index.js +4 -0
- package/dist/esm/components/buttons/button/button.js +1 -0
- package/dist/esm/components/checkbox/checkbox-labeled.js +12 -6
- package/dist/esm/components/client-adapters/styled-button/styled-button.js +11 -11
- package/dist/esm/components/client-adapters/styled-rounded-image/styled-rounded-image.js +12 -6
- package/dist/esm/components/complex-input/complex-input.js +14 -8
- package/dist/esm/components/composites/credit-account-history/body.js +73 -0
- package/dist/esm/components/composites/credit-account-history/cells/details.js +22 -0
- package/dist/esm/components/composites/credit-account-history/cells/hash.js +24 -0
- package/dist/esm/components/composites/credit-account-history/cells/index.js +10 -0
- package/dist/esm/components/composites/credit-account-history/cells/protocol.js +25 -0
- package/dist/esm/components/composites/credit-account-history/cells/token-list.js +43 -0
- package/dist/esm/components/composites/credit-account-history/credit-account-history.js +46 -0
- package/dist/esm/components/composites/credit-account-history/index.js +8 -0
- package/dist/esm/components/composites/credit-account-history/line.js +125 -0
- package/dist/esm/components/composites/credit-account-history/types.js +9 -0
- package/dist/esm/components/composites/index.js +125 -79
- package/dist/esm/components/composites/notification-center/index.js +4 -0
- package/dist/esm/components/composites/notification-center/notification-center.js +208 -0
- package/dist/esm/components/composites/notification-center/types.js +1 -0
- package/dist/esm/components/composites/pool-table/columns.js +51 -45
- package/dist/esm/components/composites/tx-preview/confirm/amounts/TransactionConfirmAmountField.js +234 -0
- package/dist/esm/components/composites/tx-preview/confirm/amounts/constants.js +10 -0
- package/dist/esm/components/composites/tx-preview/confirm/amounts/index.js +7 -0
- package/dist/esm/components/composites/tx-preview/confirm/dialog/TransactionConfirmModalView.js +213 -0
- package/dist/esm/components/composites/tx-preview/confirm/dialog/TransactionConfirmPageView.js +53 -0
- package/dist/esm/components/composites/tx-preview/confirm/dialog/TransactionConfirmShell.js +97 -0
- package/dist/esm/components/composites/tx-preview/confirm/dialog/computeTransactionConfirmDialogLayout.js +35 -0
- package/dist/esm/components/composites/tx-preview/confirm/dialog/constants.js +23 -0
- package/dist/esm/components/composites/tx-preview/confirm/dialog/index.js +14 -0
- package/dist/esm/components/composites/tx-preview/confirm/dialog/transactionConfirmPhase.js +1 -0
- package/dist/esm/components/composites/tx-preview/confirm/execution/TransactionConfirmExecuteButton.js +30 -0
- package/dist/esm/components/composites/tx-preview/confirm/execution/index.js +4 -0
- package/dist/esm/components/composites/tx-preview/confirm/index.js +40 -0
- package/dist/esm/components/composites/tx-preview/confirm/result/TransactionConfirmFailureResult.js +55 -0
- package/dist/esm/components/composites/tx-preview/confirm/result/TransactionConfirmSuccessIcon.js +25 -0
- package/dist/esm/components/composites/tx-preview/confirm/result/TransactionConfirmSuccessResult.js +60 -0
- package/dist/esm/components/composites/tx-preview/confirm/result/TransactionConfirmTxHashRow.js +21 -0
- package/dist/esm/components/composites/tx-preview/confirm/result/constants.js +24 -0
- package/dist/esm/components/composites/tx-preview/confirm/result/index.js +15 -0
- package/dist/esm/components/composites/tx-preview/confirm/stepper/ProgressStepper.js +105 -0
- package/dist/esm/components/composites/tx-preview/confirm/stepper/constants.js +6 -0
- package/dist/esm/components/composites/tx-preview/confirm/stepper/index.js +8 -0
- package/dist/esm/components/composites/tx-preview/confirm/stepper/transactionExecutionStepTypes.js +6 -0
- package/dist/esm/components/composites/tx-preview/index.js +40 -0
- package/dist/esm/components/compound-apy/compound-apy.js +14 -8
- package/dist/esm/components/confirm-menu/confirm-menu.js +28 -25
- package/dist/esm/components/detailed-page-title/detailed-page-title.js +12 -6
- package/dist/esm/components/graph/formatters.js +128 -132
- package/dist/esm/components/graph/graph.js +744 -389
- package/dist/esm/components/graph/index.js +26 -24
- package/dist/esm/components/health-factor/health-factor.js +27 -26
- package/dist/esm/components/index.js +793 -722
- package/dist/esm/components/layout/app-footer/app-footer.js +54 -0
- package/dist/esm/components/layout/app-footer/index.js +5 -0
- package/dist/esm/components/layout/app-header/app-header.js +100 -0
- package/dist/esm/components/layout/app-header/index.js +4 -0
- package/dist/esm/components/layout/index.js +32 -27
- package/dist/esm/components/layout/main-aside-layout/main-aside-layout.js +107 -58
- package/dist/esm/components/legal-agreement/index.js +23 -7
- package/dist/esm/components/legal-agreement/legal-agreement-awaiting-panel.js +29 -0
- package/dist/esm/components/legal-agreement/legal-agreement-dialog.js +72 -212
- package/dist/esm/components/legal-agreement/legal-agreement-link.js +22 -0
- package/dist/esm/components/legal-agreement/legal-agreement-panel.js +130 -0
- package/dist/esm/components/legal-agreement/legal-agreement-theme.js +137 -0
- package/dist/esm/components/legal-agreement/legal-agreement.stories-config.js +170 -0
- package/dist/esm/components/link/link.js +42 -35
- package/dist/esm/components/loader-guard/loader-guard.js +7 -5
- package/dist/esm/components/markdown-viewer/markdown-viewer.js +14 -8
- package/dist/esm/components/segmented-control/segmented-control.js +21 -21
- package/dist/esm/components/smart-number-input/smart-number-input.js +33 -29
- package/dist/esm/components/tab-control/tab-control.js +1 -1
- package/dist/esm/components/time-to-liquidation/time-to-liquidation.js +12 -6
- package/dist/esm/components/token-template/token-template.js +17 -17
- package/dist/esm/components/tokens-list-cell/tokens-list-cell.js +14 -8
- package/dist/esm/components/trading-view/trading-view.js +164 -147
- package/dist/esm/components/vertical-indicator/vertical-indicator.js +39 -33
- package/dist/esm/components/with-copy/with-copy.js +14 -8
- package/dist/esm/configs/tailwind-preset.js +1 -0
- package/dist/esm/hooks/index.js +50 -47
- package/dist/esm/hooks/use-filter.js +63 -29
- package/dist/esm/index.js +972 -896
- package/dist/esm/locale/en.json.js +10 -0
- package/dist/esm/test-ids/index.js +14 -12
- package/dist/esm/test-ids/notification-center.js +16 -0
- package/dist/globals.css +1 -1
- package/dist/types/components/alert-badge/alert-badge.d.ts +1 -1
- package/dist/types/components/block-sync-pill/block-sync-pill.d.ts +35 -0
- package/dist/types/components/block-sync-pill/block-sync-status.d.ts +29 -0
- package/dist/types/components/block-sync-pill/index.d.ts +1 -0
- package/dist/types/components/buttons/button/button.d.ts +4 -3
- package/dist/types/components/composites/credit-account-history/body.d.ts +14 -0
- package/dist/types/components/composites/credit-account-history/cells/details.d.ts +9 -0
- package/dist/types/components/composites/credit-account-history/cells/hash.d.ts +6 -0
- package/dist/types/components/composites/credit-account-history/cells/index.d.ts +4 -0
- package/dist/types/components/composites/credit-account-history/cells/protocol.d.ts +7 -0
- package/dist/types/components/composites/credit-account-history/cells/token-list.d.ts +9 -0
- package/dist/types/components/composites/credit-account-history/credit-account-history.d.ts +15 -0
- package/dist/types/components/composites/credit-account-history/index.d.ts +2 -0
- package/dist/types/components/composites/credit-account-history/line.d.ts +18 -0
- package/dist/types/components/composites/credit-account-history/types.d.ts +36 -0
- package/dist/types/components/composites/index.d.ts +3 -0
- package/dist/types/components/composites/notification-center/index.d.ts +2 -0
- package/dist/types/components/composites/notification-center/notification-center.d.ts +9 -0
- package/dist/types/components/composites/notification-center/types.d.ts +31 -0
- package/dist/types/components/composites/tx-preview/confirm/amounts/TransactionConfirmAmountField.d.ts +29 -0
- package/dist/types/components/composites/tx-preview/confirm/amounts/constants.d.ts +6 -0
- package/dist/types/components/composites/tx-preview/confirm/amounts/index.d.ts +2 -0
- package/dist/types/components/composites/tx-preview/confirm/dialog/TransactionConfirmModalView.d.ts +17 -0
- package/dist/types/components/composites/tx-preview/confirm/dialog/TransactionConfirmPageView.d.ts +15 -0
- package/dist/types/components/composites/tx-preview/confirm/dialog/TransactionConfirmShell.d.ts +23 -0
- package/dist/types/components/composites/tx-preview/confirm/dialog/computeTransactionConfirmDialogLayout.d.ts +8 -0
- package/dist/types/components/composites/tx-preview/confirm/dialog/constants.d.ts +17 -0
- package/dist/types/components/composites/tx-preview/confirm/dialog/index.d.ts +5 -0
- package/dist/types/components/composites/tx-preview/confirm/dialog/transactionConfirmPhase.d.ts +4 -0
- package/dist/types/components/composites/tx-preview/confirm/execution/TransactionConfirmExecuteButton.d.ts +6 -0
- package/dist/types/components/composites/tx-preview/confirm/execution/index.d.ts +1 -0
- package/dist/types/components/composites/tx-preview/confirm/index.d.ts +5 -0
- package/dist/types/components/composites/tx-preview/confirm/result/TransactionConfirmFailureResult.d.ts +8 -0
- package/dist/types/components/composites/tx-preview/confirm/result/TransactionConfirmSuccessIcon.d.ts +2 -0
- package/dist/types/components/composites/tx-preview/confirm/result/TransactionConfirmSuccessResult.d.ts +8 -0
- package/dist/types/components/composites/tx-preview/confirm/result/TransactionConfirmTxHashRow.d.ts +6 -0
- package/dist/types/components/composites/tx-preview/confirm/result/constants.d.ts +18 -0
- package/dist/types/components/composites/tx-preview/confirm/result/index.d.ts +5 -0
- package/dist/types/components/composites/tx-preview/confirm/stepper/ProgressStepper.d.ts +36 -0
- package/dist/types/components/composites/tx-preview/confirm/stepper/constants.d.ts +3 -0
- package/dist/types/components/composites/tx-preview/confirm/stepper/index.d.ts +3 -0
- package/dist/types/components/composites/tx-preview/confirm/stepper/transactionExecutionStepTypes.d.ts +10 -0
- package/dist/types/components/composites/tx-preview/index.d.ts +1 -0
- package/dist/types/components/confirm-menu/confirm-menu.d.ts +4 -2
- package/dist/types/components/graph/graph.d.ts +112 -2
- package/dist/types/components/graph/index.d.ts +1 -1
- package/dist/types/components/health-factor/health-factor.d.ts +6 -3
- package/dist/types/components/index.d.ts +1 -0
- package/dist/types/components/layout/app-footer/app-footer.d.ts +62 -0
- package/dist/types/components/layout/app-footer/index.d.ts +1 -0
- package/dist/types/components/layout/app-header/app-header.d.ts +67 -0
- package/dist/types/components/layout/app-header/index.d.ts +1 -0
- package/dist/types/components/layout/index.d.ts +2 -0
- package/dist/types/components/layout/main-aside-layout/main-aside-layout.d.ts +42 -0
- package/dist/types/components/legal-agreement/index.d.ts +5 -1
- package/dist/types/components/legal-agreement/legal-agreement-awaiting-panel.d.ts +10 -0
- package/dist/types/components/legal-agreement/legal-agreement-dialog.d.ts +19 -52
- package/dist/types/components/legal-agreement/legal-agreement-link.d.ts +11 -0
- package/dist/types/components/legal-agreement/legal-agreement-panel.d.ts +16 -0
- package/dist/types/components/legal-agreement/legal-agreement-theme.d.ts +36 -0
- package/dist/types/components/legal-agreement/legal-agreement.stories-config.d.ts +11 -0
- package/dist/types/components/trading-view/trading-view.d.ts +15 -1
- package/dist/types/components/vertical-indicator/vertical-indicator.d.ts +6 -0
- package/dist/types/configs/tailwind-preset.d.ts +1 -0
- package/dist/types/hooks/use-filter.d.ts +46 -0
- package/dist/types/index.d.ts +2 -0
- package/dist/types/locale/en.json.d.ts +13 -0
- package/dist/types/test-ids/index.d.ts +1 -0
- package/dist/types/test-ids/notification-center.d.ts +13 -0
- package/dist/types/types/footer.d.ts +24 -3
- package/package.json +7 -4
- package/src/styles/base.css +2 -0
- package/src/styles/theme.css +1 -0
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
import { jsxs as o, Fragment as a, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { formatLeverage as C } from "@gearbox-protocol/sdk";
|
|
3
|
+
import { GridTableRow as l, GridTableCell as s } from "../../table/grid-table.js";
|
|
4
|
+
import { TableLineSm as I, TableCellSm as p } from "../../table/table-sm.js";
|
|
5
|
+
import { FormattedMessageTyped as d } from "../../typed-intl/index.js";
|
|
6
|
+
import { useIsMobile as M } from "../../../hooks/use-media-query.js";
|
|
7
|
+
import "react";
|
|
8
|
+
import { cn as n } from "../../../utils/cn.js";
|
|
9
|
+
import "sonner";
|
|
10
|
+
import "@gearbox-protocol/sdk/common-utils";
|
|
11
|
+
import { tokenTemplate as R } from "../../../utils/templates.js";
|
|
12
|
+
import "luxon";
|
|
13
|
+
import "../../../utils/z-index.js";
|
|
14
|
+
import { Details as j } from "./cells/details.js";
|
|
15
|
+
import { Hash as O } from "./cells/hash.js";
|
|
16
|
+
import { Protocol as D } from "./cells/protocol.js";
|
|
17
|
+
import "../../tooltip/simple-tooltip.js";
|
|
18
|
+
import "../../tooltip/tooltip.js";
|
|
19
|
+
import "../../token-symbol/token-symbol.js";
|
|
20
|
+
import { GEARBOX_PROTOCOL_INFO as F, isMulticallOperation as G } from "./types.js";
|
|
21
|
+
function oe({
|
|
22
|
+
data: t,
|
|
23
|
+
details: T,
|
|
24
|
+
tokens: h,
|
|
25
|
+
protocols: y,
|
|
26
|
+
hideBorder: m,
|
|
27
|
+
index: f,
|
|
28
|
+
underlyingToken: A,
|
|
29
|
+
explorerUrl: i
|
|
30
|
+
}) {
|
|
31
|
+
const L = M(), u = y?.[t.protocol.toLowerCase()] || F, c = G(t), r = f.index === 0, x = r && f.outOf === 0 || !r, b = () => {
|
|
32
|
+
if (t.operationType === "OpenCreditAccount") {
|
|
33
|
+
const v = t, w = h[A];
|
|
34
|
+
return /* @__PURE__ */ o(a, { children: [
|
|
35
|
+
" ",
|
|
36
|
+
"(",
|
|
37
|
+
R(v.from, w),
|
|
38
|
+
" ",
|
|
39
|
+
">",
|
|
40
|
+
" x",
|
|
41
|
+
C(v.leverage),
|
|
42
|
+
")"
|
|
43
|
+
] });
|
|
44
|
+
}
|
|
45
|
+
return null;
|
|
46
|
+
}, N = () => u && /* @__PURE__ */ e(D, { isUnderlying: !r, protocol: u }), g = () => c ? null : t.operation, H = () => /* @__PURE__ */ e(j, { tokensList: h, data: T });
|
|
47
|
+
return L ? /* @__PURE__ */ o(a, { children: [
|
|
48
|
+
r && /* @__PURE__ */ e(l, { noHover: !0, children: /* @__PURE__ */ e(s, { span: "full", className: "pb-2 pt-4", children: /* @__PURE__ */ o("div", { className: "flex flex-col gap-1", children: [
|
|
49
|
+
/* @__PURE__ */ o("div", { className: "text-xs", children: [
|
|
50
|
+
t.date,
|
|
51
|
+
" ",
|
|
52
|
+
t.time,
|
|
53
|
+
c && ` - ${t.operation}`,
|
|
54
|
+
b()
|
|
55
|
+
] }),
|
|
56
|
+
i && /* @__PURE__ */ e(O, { txHash: t.txHash, etherscanAddress: i })
|
|
57
|
+
] }) }) }),
|
|
58
|
+
x && /* @__PURE__ */ e(
|
|
59
|
+
l,
|
|
60
|
+
{
|
|
61
|
+
noHover: !0,
|
|
62
|
+
className: n(m && "[&>*]:!border-b-0"),
|
|
63
|
+
children: /* @__PURE__ */ e(s, { span: "full", className: n(!r && "pl-4"), children: /* @__PURE__ */ o(I, { columns: 3, columnsXs: 2, columnsSm: 3, children: [
|
|
64
|
+
/* @__PURE__ */ e(
|
|
65
|
+
p,
|
|
66
|
+
{
|
|
67
|
+
title: /* @__PURE__ */ e(d, { messageId: "components.creditAccountHistory.table.protocol" }),
|
|
68
|
+
children: N()
|
|
69
|
+
}
|
|
70
|
+
),
|
|
71
|
+
/* @__PURE__ */ e(
|
|
72
|
+
p,
|
|
73
|
+
{
|
|
74
|
+
title: /* @__PURE__ */ e(d, { messageId: "components.creditAccountHistory.table.operation" }),
|
|
75
|
+
children: g()
|
|
76
|
+
}
|
|
77
|
+
),
|
|
78
|
+
/* @__PURE__ */ e(
|
|
79
|
+
p,
|
|
80
|
+
{
|
|
81
|
+
title: /* @__PURE__ */ e(d, { messageId: "components.creditAccountHistory.table.details" }),
|
|
82
|
+
className: "items-start",
|
|
83
|
+
children: H()
|
|
84
|
+
}
|
|
85
|
+
)
|
|
86
|
+
] }) })
|
|
87
|
+
}
|
|
88
|
+
)
|
|
89
|
+
] }) : /* @__PURE__ */ o(a, { children: [
|
|
90
|
+
r && /* @__PURE__ */ e(l, { noHover: !0, children: /* @__PURE__ */ e(s, { span: "full", className: "pb-2 pt-4", children: /* @__PURE__ */ o("div", { className: "flex flex-col sm:flex-row justify-between sm:items-center gap-1 sm:gap-2", children: [
|
|
91
|
+
/* @__PURE__ */ o("div", { className: "text-xs sm:text-sm", children: [
|
|
92
|
+
t.date,
|
|
93
|
+
" ",
|
|
94
|
+
t.time,
|
|
95
|
+
c && ` - ${t.operation}`,
|
|
96
|
+
b()
|
|
97
|
+
] }),
|
|
98
|
+
i && /* @__PURE__ */ e(O, { txHash: t.txHash, etherscanAddress: i })
|
|
99
|
+
] }) }) }),
|
|
100
|
+
x && /* @__PURE__ */ o(
|
|
101
|
+
l,
|
|
102
|
+
{
|
|
103
|
+
className: n(
|
|
104
|
+
!r && !m && "[&>*]:!border-t-0",
|
|
105
|
+
m && "[&>*]:!border-b-0",
|
|
106
|
+
"hover:[&>*]:bg-transparent"
|
|
107
|
+
),
|
|
108
|
+
children: [
|
|
109
|
+
/* @__PURE__ */ e(
|
|
110
|
+
s,
|
|
111
|
+
{
|
|
112
|
+
className: n(r ? "" : "pl-8 sm:pl-4", "text-xs sm:text-sm"),
|
|
113
|
+
children: N()
|
|
114
|
+
}
|
|
115
|
+
),
|
|
116
|
+
/* @__PURE__ */ e(s, { className: "text-xs sm:text-sm", children: g() }),
|
|
117
|
+
/* @__PURE__ */ e(s, { className: "text-xs sm:text-sm", children: H() })
|
|
118
|
+
]
|
|
119
|
+
}
|
|
120
|
+
)
|
|
121
|
+
] });
|
|
122
|
+
}
|
|
123
|
+
export {
|
|
124
|
+
oe as HistoryLine
|
|
125
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
const l = "0x0000000000000000000000000000000000000000", t = {
|
|
2
|
+
name: "Gearbox",
|
|
3
|
+
icon: "/logo/logo_symbol.png"
|
|
4
|
+
}, c = (o) => typeof o == "object" && !!o && !!o.multicall;
|
|
5
|
+
export {
|
|
6
|
+
t as GEARBOX_PROTOCOL_INFO,
|
|
7
|
+
l as ZERO_ADDRESS,
|
|
8
|
+
c as isMulticallOperation
|
|
9
|
+
};
|
|
@@ -1,81 +1,127 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
1
|
+
import { CreditAccountHistory as e } from "./credit-account-history/credit-account-history.js";
|
|
2
|
+
import { GEARBOX_PROTOCOL_INFO as a, ZERO_ADDRESS as n, isMulticallOperation as i } from "./credit-account-history/types.js";
|
|
3
|
+
import { NotificationCenter as m } from "./notification-center/notification-center.js";
|
|
4
|
+
import { OracleComponent as p } from "./oracles-and-lt-table/oracle-component.js";
|
|
5
|
+
import { OraclesAndLTLineView as u } from "./oracles-and-lt-table/oracles-and-lt-line-view.js";
|
|
6
|
+
import { OraclesAndLTTableView as T } from "./oracles-and-lt-table/oracles-and-lt-table.js";
|
|
7
|
+
import { OraclesAndLTTableHead as c } from "./oracles-and-lt-table/oracles-and-lt-table-head.js";
|
|
8
|
+
import { OraclesList as P, getPriceFeedInfo as g } from "./oracles-and-lt-table/oracles-list.js";
|
|
9
|
+
import { PoolAssetsTable as R } from "./pool-assets-table/pool-assets-table.js";
|
|
10
|
+
import { PoolAssetsTableHead as A } from "./pool-assets-table/pool-assets-table-head.js";
|
|
11
|
+
import { PoolAssetsTableRow as F } from "./pool-assets-table/pool-assets-table-row.js";
|
|
12
|
+
import { overflowContainerClassName as y, overflowWrapClassName as L } from "./pool-credit-manager-info/overflow-layout.js";
|
|
13
|
+
import { PoolCreditManagerInfo as H } from "./pool-credit-manager-info/pool-credit-manager-info.js";
|
|
14
|
+
import { PoolCreditManagersTable as h } from "./pool-credit-managers-table/pool-credit-managers-table.js";
|
|
15
|
+
import { PoolCreditManagersTableHead as N } from "./pool-credit-managers-table/pool-credit-managers-table-head.js";
|
|
16
|
+
import { PoolCreditManagersTableRow as E } from "./pool-credit-managers-table/pool-credit-managers-table-row.js";
|
|
17
|
+
import { balanceColumn as B, borrowApyColumn as W, borrowedColumn as _, collateralColumn as G, customColumn as Y, defaultPoolName as Z, poolColumn as z, supplyApyColumn as X, supplyColumn as j, utilizationColumn as k } from "./pool-table/columns.js";
|
|
18
|
+
import { PoolTable as J } from "./pool-table/pool-table.js";
|
|
19
|
+
import { customStrategyColumn as Q, strategyColumn as U, strategyLeverageColumn as $, strategyRewardsColumn as oo } from "./strategies-table/columns.js";
|
|
20
|
+
import { APYFeature as eo, APYFeatureTooltip as to } from "./strategies-table/components/apy-feature/apy-feature.js";
|
|
21
|
+
import { RWAFeature as no, StrategiesRewardsCell as io, StrategyPoints as so, ZeroSlippageFeature as mo } from "./strategies-table/components/cells/cells.js";
|
|
22
|
+
import { DisabledWrap as po, Plus as fo, TitleGrid as uo } from "./strategies-table/components/cells/cells.styles.js";
|
|
23
|
+
import { Feature as To } from "./strategies-table/components/feature/feature.js";
|
|
24
|
+
import { FeatureRoot as co } from "./strategies-table/components/feature/feature.styles.js";
|
|
25
|
+
import { StrategiesTableNotFoundLine as go } from "./strategies-table/components/not-found-line.js";
|
|
26
|
+
import { PointsFeature as Ro, PointsFeatureTooltip as So, PointsLabel as Ao } from "./strategies-table/components/points-feature/points-feature.js";
|
|
27
|
+
import { RewardsTooltip as Fo, RewardsTooltipHover as Oo } from "./strategies-table/components/rewards-tooltip/rewards-tooltip.js";
|
|
28
|
+
import { RewardsTooltipRoot as Lo } from "./strategies-table/components/rewards-tooltip/rewards-tooltip-root.js";
|
|
29
|
+
import { RewardsTooltipView as Ho } from "./strategies-table/components/rewards-tooltip/rewards-tooltip-view.js";
|
|
30
|
+
import { RewardsTooltipContent as ho } from "./strategies-table/components/rewards-tooltip/tooltip-content.js";
|
|
31
|
+
import { StrategiesTable as No } from "./strategies-table/components/strategies-table.js";
|
|
32
|
+
import { TransactionConfirmAmountFieldTest as Eo, TransactionConfirmAmountPairTest as Io } from "./tx-preview/confirm/amounts/constants.js";
|
|
33
|
+
import { TransactionConfirmAmountField as Wo } from "./tx-preview/confirm/amounts/TransactionConfirmAmountField.js";
|
|
34
|
+
import { computeTransactionConfirmDialogLayout as Go } from "./tx-preview/confirm/dialog/computeTransactionConfirmDialogLayout.js";
|
|
35
|
+
import { TransactionConfirmDialogTest as Zo, transactionConfirmDialogShellVariants as zo, transactionConfirmModalContainerVariants as Xo, transactionConfirmPreviewScrollVariants as jo, transactionConfirmShellContentVariants as ko } from "./tx-preview/confirm/dialog/constants.js";
|
|
36
|
+
import { TransactionConfirmModalView as Jo } from "./tx-preview/confirm/dialog/TransactionConfirmModalView.js";
|
|
37
|
+
import { TransactionConfirmPageView as Qo } from "./tx-preview/confirm/dialog/TransactionConfirmPageView.js";
|
|
38
|
+
import { TransactionConfirmExecuteButton as $o } from "./tx-preview/confirm/execution/TransactionConfirmExecuteButton.js";
|
|
39
|
+
import { TransactionConfirmExecuteButtonTest as rr, TransactionConfirmFailureResultTest as er, TransactionConfirmSuccessResultTest as tr, TransactionConfirmTxHashRowTest as ar } from "./tx-preview/confirm/result/constants.js";
|
|
40
|
+
import { TransactionConfirmFailureResult as ir } from "./tx-preview/confirm/result/TransactionConfirmFailureResult.js";
|
|
41
|
+
import { TransactionConfirmSuccessIcon as mr } from "./tx-preview/confirm/result/TransactionConfirmSuccessIcon.js";
|
|
42
|
+
import { TransactionConfirmSuccessResult as pr } from "./tx-preview/confirm/result/TransactionConfirmSuccessResult.js";
|
|
43
|
+
import { TransactionConfirmTxHashRow as ur } from "./tx-preview/confirm/result/TransactionConfirmTxHashRow.js";
|
|
44
|
+
import { ProgressStepperTest as Tr } from "./tx-preview/confirm/stepper/constants.js";
|
|
45
|
+
import { ProgressStepper as cr } from "./tx-preview/confirm/stepper/ProgressStepper.js";
|
|
46
|
+
import { shouldShowTransactionProgressStepper as Pr } from "./tx-preview/confirm/stepper/transactionExecutionStepTypes.js";
|
|
29
47
|
export {
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
a as
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
h as
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
48
|
+
eo as APYFeature,
|
|
49
|
+
to as APYFeatureTooltip,
|
|
50
|
+
e as CreditAccountHistory,
|
|
51
|
+
po as DisabledWrap,
|
|
52
|
+
To as Feature,
|
|
53
|
+
co as FeatureRoot,
|
|
54
|
+
a as GEARBOX_PROTOCOL_INFO,
|
|
55
|
+
m as NotificationCenter,
|
|
56
|
+
p as OracleComponent,
|
|
57
|
+
u as OraclesAndLTLineView,
|
|
58
|
+
c as OraclesAndLTTableHead,
|
|
59
|
+
T as OraclesAndLTTableView,
|
|
60
|
+
P as OraclesList,
|
|
61
|
+
fo as Plus,
|
|
62
|
+
Ro as PointsFeature,
|
|
63
|
+
So as PointsFeatureTooltip,
|
|
64
|
+
Ao as PointsLabel,
|
|
65
|
+
R as PoolAssetsTable,
|
|
66
|
+
A as PoolAssetsTableHead,
|
|
67
|
+
F as PoolAssetsTableRow,
|
|
68
|
+
H as PoolCreditManagerInfo,
|
|
69
|
+
h as PoolCreditManagersTable,
|
|
70
|
+
N as PoolCreditManagersTableHead,
|
|
71
|
+
E as PoolCreditManagersTableRow,
|
|
72
|
+
J as PoolTable,
|
|
73
|
+
cr as ProgressStepper,
|
|
74
|
+
Tr as ProgressStepperTest,
|
|
75
|
+
no as RWAFeature,
|
|
76
|
+
Fo as RewardsTooltip,
|
|
77
|
+
ho as RewardsTooltipContent,
|
|
78
|
+
Oo as RewardsTooltipHover,
|
|
79
|
+
Lo as RewardsTooltipRoot,
|
|
80
|
+
Ho as RewardsTooltipView,
|
|
81
|
+
io as StrategiesRewardsCell,
|
|
82
|
+
No as StrategiesTable,
|
|
83
|
+
go as StrategiesTableNotFoundLine,
|
|
84
|
+
so as StrategyPoints,
|
|
85
|
+
uo as TitleGrid,
|
|
86
|
+
Wo as TransactionConfirmAmountField,
|
|
87
|
+
Eo as TransactionConfirmAmountFieldTest,
|
|
88
|
+
Io as TransactionConfirmAmountPairTest,
|
|
89
|
+
Zo as TransactionConfirmDialogTest,
|
|
90
|
+
$o as TransactionConfirmExecuteButton,
|
|
91
|
+
rr as TransactionConfirmExecuteButtonTest,
|
|
92
|
+
ir as TransactionConfirmFailureResult,
|
|
93
|
+
er as TransactionConfirmFailureResultTest,
|
|
94
|
+
Jo as TransactionConfirmModalView,
|
|
95
|
+
Qo as TransactionConfirmPageView,
|
|
96
|
+
mr as TransactionConfirmSuccessIcon,
|
|
97
|
+
pr as TransactionConfirmSuccessResult,
|
|
98
|
+
tr as TransactionConfirmSuccessResultTest,
|
|
99
|
+
ur as TransactionConfirmTxHashRow,
|
|
100
|
+
ar as TransactionConfirmTxHashRowTest,
|
|
101
|
+
n as ZERO_ADDRESS,
|
|
102
|
+
mo as ZeroSlippageFeature,
|
|
103
|
+
B as balanceColumn,
|
|
104
|
+
W as borrowApyColumn,
|
|
105
|
+
_ as borrowedColumn,
|
|
106
|
+
G as collateralColumn,
|
|
107
|
+
Go as computeTransactionConfirmDialogLayout,
|
|
108
|
+
Y as customColumn,
|
|
109
|
+
Q as customStrategyColumn,
|
|
110
|
+
Z as defaultPoolName,
|
|
111
|
+
g as getPriceFeedInfo,
|
|
112
|
+
i as isMulticallOperation,
|
|
113
|
+
y as overflowContainerClassName,
|
|
114
|
+
L as overflowWrapClassName,
|
|
115
|
+
z as poolColumn,
|
|
116
|
+
Pr as shouldShowTransactionProgressStepper,
|
|
117
|
+
U as strategyColumn,
|
|
118
|
+
$ as strategyLeverageColumn,
|
|
119
|
+
oo as strategyRewardsColumn,
|
|
120
|
+
X as supplyApyColumn,
|
|
121
|
+
j as supplyColumn,
|
|
122
|
+
zo as transactionConfirmDialogShellVariants,
|
|
123
|
+
Xo as transactionConfirmModalContainerVariants,
|
|
124
|
+
jo as transactionConfirmPreviewScrollVariants,
|
|
125
|
+
ko as transactionConfirmShellContentVariants,
|
|
126
|
+
k as utilizationColumn
|
|
81
127
|
};
|
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
import { jsx as e, jsxs as i, Fragment as x } from "react/jsx-runtime";
|
|
2
|
+
import { faBell as h } from "@fortawesome/free-solid-svg-icons";
|
|
3
|
+
import { FaIcon as g } from "../../icons/fa-icon.js";
|
|
4
|
+
import { SimpleDropdown as y } from "../../simple-dropdown/simple-dropdown.js";
|
|
5
|
+
import "../../simple-dropdown/simple-dropdown-menu-item.js";
|
|
6
|
+
import { FormattedMessageTyped as r } from "../../typed-intl/index.js";
|
|
7
|
+
import { Typography as n } from "../../typography/typography.js";
|
|
8
|
+
import { notificationCenterTestIds as a } from "../../../test-ids/notification-center.js";
|
|
9
|
+
import "react";
|
|
10
|
+
import "@gearbox-protocol/sdk";
|
|
11
|
+
import { cn as c } from "../../../utils/cn.js";
|
|
12
|
+
import "sonner";
|
|
13
|
+
import "@gearbox-protocol/sdk/common-utils";
|
|
14
|
+
import "luxon";
|
|
15
|
+
import "../../../utils/z-index.js";
|
|
16
|
+
function b({ row: t }) {
|
|
17
|
+
const s = /* @__PURE__ */ i(x, { children: [
|
|
18
|
+
/* @__PURE__ */ e(
|
|
19
|
+
"span",
|
|
20
|
+
{
|
|
21
|
+
className: c(
|
|
22
|
+
"mt-[5px] size-[7px] shrink-0 rounded-full",
|
|
23
|
+
t.isReady ? "bg-success" : "bg-gray-50"
|
|
24
|
+
)
|
|
25
|
+
}
|
|
26
|
+
),
|
|
27
|
+
/* @__PURE__ */ i("div", { className: "flex min-w-0 flex-1 flex-col gap-1.5", children: [
|
|
28
|
+
/* @__PURE__ */ i("div", { className: "flex items-start justify-between gap-3", children: [
|
|
29
|
+
/* @__PURE__ */ e(
|
|
30
|
+
n,
|
|
31
|
+
{
|
|
32
|
+
as: "span",
|
|
33
|
+
variant: "bodySmall",
|
|
34
|
+
className: "truncate text-foreground",
|
|
35
|
+
children: t.title
|
|
36
|
+
}
|
|
37
|
+
),
|
|
38
|
+
/* @__PURE__ */ e(
|
|
39
|
+
n,
|
|
40
|
+
{
|
|
41
|
+
as: "span",
|
|
42
|
+
variant: "bodySmall",
|
|
43
|
+
color: t.isReady ? "success" : "muted",
|
|
44
|
+
className: "shrink-0 text-right",
|
|
45
|
+
children: t.statusLabel
|
|
46
|
+
}
|
|
47
|
+
)
|
|
48
|
+
] }),
|
|
49
|
+
/* @__PURE__ */ e(n, { as: "span", variant: "bodySmall", color: "muted", children: t.positionName })
|
|
50
|
+
] })
|
|
51
|
+
] });
|
|
52
|
+
return t.isClickable && t.onExecute ? /* @__PURE__ */ e(
|
|
53
|
+
"button",
|
|
54
|
+
{
|
|
55
|
+
type: "button",
|
|
56
|
+
"data-testid": a.requestRow,
|
|
57
|
+
onClick: t.onExecute,
|
|
58
|
+
className: "flex w-full cursor-pointer items-start gap-2 py-4 text-left hover:opacity-80",
|
|
59
|
+
children: s
|
|
60
|
+
}
|
|
61
|
+
) : /* @__PURE__ */ e(
|
|
62
|
+
"div",
|
|
63
|
+
{
|
|
64
|
+
"data-testid": a.requestRow,
|
|
65
|
+
className: "flex w-full items-start gap-2 py-4",
|
|
66
|
+
children: s
|
|
67
|
+
}
|
|
68
|
+
);
|
|
69
|
+
}
|
|
70
|
+
function L({
|
|
71
|
+
open: t,
|
|
72
|
+
onOpenChange: s,
|
|
73
|
+
deferredRows: o,
|
|
74
|
+
successRows: d,
|
|
75
|
+
deferredCount: m,
|
|
76
|
+
hasReady: u,
|
|
77
|
+
hasAny: f,
|
|
78
|
+
onClear: p
|
|
79
|
+
}) {
|
|
80
|
+
return /* @__PURE__ */ e(
|
|
81
|
+
y,
|
|
82
|
+
{
|
|
83
|
+
open: t,
|
|
84
|
+
onOpenChange: s,
|
|
85
|
+
align: "end",
|
|
86
|
+
asChild: !0,
|
|
87
|
+
className: "w-[460px] max-w-[calc(100vw-32px)] bg-modal p-0",
|
|
88
|
+
title: /* @__PURE__ */ i(
|
|
89
|
+
"button",
|
|
90
|
+
{
|
|
91
|
+
type: "button",
|
|
92
|
+
"data-testid": a.trigger,
|
|
93
|
+
className: "relative flex size-8 items-center justify-center rounded-md text-secondary-foreground hover:text-foreground",
|
|
94
|
+
children: [
|
|
95
|
+
/* @__PURE__ */ e(g, { icon: h, className: "size-4" }),
|
|
96
|
+
m > 0 ? /* @__PURE__ */ e(
|
|
97
|
+
"span",
|
|
98
|
+
{
|
|
99
|
+
"data-testid": a.badge,
|
|
100
|
+
className: c(
|
|
101
|
+
"absolute -right-0.5 -top-0.5 flex size-[15px] items-center justify-center rounded-full text-[10px] font-medium leading-none text-white",
|
|
102
|
+
u ? "bg-primary" : "bg-gray-50"
|
|
103
|
+
),
|
|
104
|
+
children: m
|
|
105
|
+
}
|
|
106
|
+
) : null
|
|
107
|
+
]
|
|
108
|
+
}
|
|
109
|
+
),
|
|
110
|
+
children: /* @__PURE__ */ i(
|
|
111
|
+
"div",
|
|
112
|
+
{
|
|
113
|
+
"data-testid": a.panel,
|
|
114
|
+
className: "flex flex-col p-8",
|
|
115
|
+
children: [
|
|
116
|
+
f ? null : /* @__PURE__ */ e(
|
|
117
|
+
n,
|
|
118
|
+
{
|
|
119
|
+
as: "span",
|
|
120
|
+
variant: "bodySmall",
|
|
121
|
+
color: "muted",
|
|
122
|
+
"data-testid": a.empty,
|
|
123
|
+
children: /* @__PURE__ */ e(r, { messageId: "components.notificationCenter.empty" })
|
|
124
|
+
}
|
|
125
|
+
),
|
|
126
|
+
o.length > 0 ? /* @__PURE__ */ i(
|
|
127
|
+
"div",
|
|
128
|
+
{
|
|
129
|
+
className: "flex flex-col",
|
|
130
|
+
"data-testid": a.requestsSection,
|
|
131
|
+
children: [
|
|
132
|
+
/* @__PURE__ */ e(
|
|
133
|
+
n,
|
|
134
|
+
{
|
|
135
|
+
as: "span",
|
|
136
|
+
variant: "bodySmall",
|
|
137
|
+
className: "pb-2 font-medium text-foreground",
|
|
138
|
+
children: /* @__PURE__ */ e(r, { messageId: "components.notificationCenter.requests" })
|
|
139
|
+
}
|
|
140
|
+
),
|
|
141
|
+
/* @__PURE__ */ e("div", { className: "-mr-2 flex max-h-[40dvh] flex-col divide-y divide-gray-60 overflow-y-auto overflow-x-hidden pr-2 [scrollbar-gutter:stable]", children: o.map((l) => /* @__PURE__ */ e(b, { row: l }, l.id)) })
|
|
142
|
+
]
|
|
143
|
+
}
|
|
144
|
+
) : null,
|
|
145
|
+
d.length > 0 ? /* @__PURE__ */ i(
|
|
146
|
+
"div",
|
|
147
|
+
{
|
|
148
|
+
className: c(
|
|
149
|
+
"flex flex-col",
|
|
150
|
+
o.length > 0 && "mt-4 pt-4"
|
|
151
|
+
),
|
|
152
|
+
"data-testid": a.successSection,
|
|
153
|
+
children: [
|
|
154
|
+
/* @__PURE__ */ i("div", { className: "flex items-center justify-between pb-2", children: [
|
|
155
|
+
/* @__PURE__ */ e(
|
|
156
|
+
n,
|
|
157
|
+
{
|
|
158
|
+
as: "span",
|
|
159
|
+
variant: "bodySmall",
|
|
160
|
+
className: "font-medium text-foreground",
|
|
161
|
+
children: /* @__PURE__ */ e(r, { messageId: "components.notificationCenter.recent" })
|
|
162
|
+
}
|
|
163
|
+
),
|
|
164
|
+
p ? /* @__PURE__ */ e(
|
|
165
|
+
"button",
|
|
166
|
+
{
|
|
167
|
+
type: "button",
|
|
168
|
+
"data-testid": a.clear,
|
|
169
|
+
onClick: p,
|
|
170
|
+
className: "cursor-pointer text-xs text-secondary-foreground hover:text-foreground",
|
|
171
|
+
children: /* @__PURE__ */ e(r, { messageId: "components.notificationCenter.clear" })
|
|
172
|
+
}
|
|
173
|
+
) : null
|
|
174
|
+
] }),
|
|
175
|
+
/* @__PURE__ */ e("div", { className: "-mr-2 flex max-h-[30dvh] flex-col overflow-y-auto overflow-x-hidden pr-2 [scrollbar-gutter:stable]", children: d.map((l) => /* @__PURE__ */ i(
|
|
176
|
+
"button",
|
|
177
|
+
{
|
|
178
|
+
type: "button",
|
|
179
|
+
"data-testid": a.successRow,
|
|
180
|
+
onClick: l.onView,
|
|
181
|
+
className: "flex cursor-pointer items-center justify-between gap-3 py-2 text-left hover:opacity-80",
|
|
182
|
+
children: [
|
|
183
|
+
/* @__PURE__ */ e(
|
|
184
|
+
n,
|
|
185
|
+
{
|
|
186
|
+
as: "span",
|
|
187
|
+
variant: "bodySmall",
|
|
188
|
+
className: "truncate text-foreground",
|
|
189
|
+
children: l.label
|
|
190
|
+
}
|
|
191
|
+
),
|
|
192
|
+
/* @__PURE__ */ e(n, { as: "span", variant: "caption", color: "muted", children: l.timestampLabel })
|
|
193
|
+
]
|
|
194
|
+
},
|
|
195
|
+
l.id
|
|
196
|
+
)) })
|
|
197
|
+
]
|
|
198
|
+
}
|
|
199
|
+
) : null
|
|
200
|
+
]
|
|
201
|
+
}
|
|
202
|
+
)
|
|
203
|
+
}
|
|
204
|
+
);
|
|
205
|
+
}
|
|
206
|
+
export {
|
|
207
|
+
L as NotificationCenter
|
|
208
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|