@gearbox-protocol/permissionless-ui 1.22.0-next.46 → 1.22.0-next.48
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/components/accordion/accordion.cjs +1 -1
- package/dist/cjs/components/address/address.cjs +1 -1
- package/dist/cjs/components/alert-badge/alert-badge.cjs +1 -1
- package/dist/cjs/components/alert-dialog/alert-dialog.cjs +1 -1
- package/dist/cjs/components/apy/apy.cjs +1 -1
- package/dist/cjs/components/arc-loader/arc-loader.cjs +1 -1
- package/dist/cjs/components/asset-line/asset-line.cjs +1 -1
- package/dist/cjs/components/assets-list-cell/assets-list-cell.cjs +1 -1
- package/dist/cjs/components/assets-ratio/assets-ratio.cjs +1 -1
- package/dist/cjs/components/auth/connect-required.cjs +1 -1
- package/dist/cjs/components/auth/signin-required.cjs +1 -1
- package/dist/cjs/components/avatar/avatar.cjs +1 -1
- package/dist/cjs/components/badge/badge.cjs +1 -1
- package/dist/cjs/components/base-link/base-link.cjs +1 -1
- package/dist/cjs/components/block-sync/block-sync.cjs +1 -1
- package/dist/cjs/components/breadcrumbs/breadcrumbs.cjs +1 -1
- package/dist/cjs/components/button-checkbox/button-checkbox.cjs +1 -1
- package/dist/cjs/components/buttons/back-button/back-button.cjs +1 -1
- package/dist/cjs/components/buttons/button/button.cjs +1 -1
- package/dist/cjs/components/buttons/copy-button/copy-button.cjs +1 -1
- package/dist/cjs/components/buttons/external-button/external-button.cjs +1 -1
- package/dist/cjs/components/buttons/navigation-button/navigation-button.cjs +1 -1
- package/dist/cjs/components/buttons/range-buttons/range-buttons.cjs +1 -1
- package/dist/cjs/components/card-grid/card-grid.cjs +1 -1
- package/dist/cjs/components/cards/card/card.cjs +1 -1
- package/dist/cjs/components/cards/expandable-call/expandable-call.cjs +1 -1
- package/dist/cjs/components/cards/expandable-card/expandable-card.cjs +1 -1
- package/dist/cjs/components/carousel/carousel.cjs +1 -1
- package/dist/cjs/components/checkbox/checkbox-labeled.cjs +1 -1
- package/dist/cjs/components/checkbox/checkbox.cjs +1 -1
- package/dist/cjs/components/checkbox-item/checkbox-item.cjs +1 -1
- package/dist/cjs/components/client-adapters/styled-button/styled-button.cjs +1 -1
- package/dist/cjs/components/client-adapters/styled-dialog-container/styled-dialog-container.cjs +1 -1
- package/dist/cjs/components/client-adapters/styled-rounded-image/styled-rounded-image.cjs +1 -1
- package/dist/cjs/components/colored-text/colored-text.cjs +1 -1
- package/dist/cjs/components/complex-input/complex-input.cjs +1 -1
- 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/credit-session-status/credit-session-status.cjs +1 -1
- package/dist/cjs/components/currency-button/currency-button.cjs +1 -1
- package/dist/cjs/components/description/description.cjs +1 -1
- package/dist/cjs/components/detailed-apy/detailed-apy.cjs +1 -1
- package/dist/cjs/components/detailed-page-title/detailed-page-title.cjs +1 -1
- package/dist/cjs/components/dialog/dialog-container.cjs +1 -1
- package/dist/cjs/components/dialog/dialog-content.cjs +1 -1
- package/dist/cjs/components/dialog/dialog-description.cjs +1 -1
- package/dist/cjs/components/dialog/dialog-footer.cjs +1 -1
- package/dist/cjs/components/dialog/dialog-form.cjs +1 -1
- package/dist/cjs/components/dialog/dialog-header.cjs +1 -1
- package/dist/cjs/components/dialog/dialog-modal-container.cjs +1 -1
- package/dist/cjs/components/dialog/dialog-overlay.cjs +1 -1
- package/dist/cjs/components/dialog/dialog-title.cjs +1 -1
- package/dist/cjs/components/dropdown-label/dropdown-label.cjs +1 -1
- package/dist/cjs/components/dropdown-menu/dropdown-menu-checkbox-item.cjs +1 -1
- package/dist/cjs/components/dropdown-menu/dropdown-menu-content.cjs +1 -1
- package/dist/cjs/components/dropdown-menu/dropdown-menu-item.cjs +1 -1
- package/dist/cjs/components/dropdown-menu/dropdown-menu-label.cjs +1 -1
- package/dist/cjs/components/dropdown-menu/dropdown-menu-radio-item.cjs +1 -1
- package/dist/cjs/components/dropdown-menu/dropdown-menu-separator.cjs +1 -1
- package/dist/cjs/components/dropdown-menu/dropdown-menu-shortcut.cjs +1 -1
- package/dist/cjs/components/dropdown-menu/dropdown-menu-sub-content.cjs +1 -1
- package/dist/cjs/components/dropdown-menu/dropdown-menu-sub-trigger.cjs +1 -1
- package/dist/cjs/components/edit-input/edit-input.cjs +1 -1
- package/dist/cjs/components/error-message/error-line-message.cjs +1 -1
- package/dist/cjs/components/error-message/error-message.cjs +1 -1
- package/dist/cjs/components/error-view/error-view.cjs +1 -1
- package/dist/cjs/components/explorer-links-dropdown/explorer-links-dropdown.cjs +1 -1
- package/dist/cjs/components/fadeout-loading/fadeout-loading.cjs +1 -1
- package/dist/cjs/components/filter/filter-block.cjs +1 -1
- package/dist/cjs/components/filter/filter-checkbox-item.cjs +1 -1
- package/dist/cjs/components/filter/filter-chip.cjs +1 -1
- package/dist/cjs/components/filter/filter-chips.cjs +1 -1
- package/dist/cjs/components/filter/filter-dropdown-item.cjs +1 -1
- package/dist/cjs/components/filter/filter-group.cjs +1 -1
- package/dist/cjs/components/filter/filter-label.cjs +1 -1
- package/dist/cjs/components/filter/filter-modal-item.cjs +1 -1
- package/dist/cjs/components/filter/filter-modal.cjs +1 -1
- package/dist/cjs/components/filter/filter-radio-item.cjs +1 -1
- package/dist/cjs/components/filter/filter-separator.cjs +1 -1
- package/dist/cjs/components/formatted-number/formatted-number.cjs +1 -1
- package/dist/cjs/components/general-asset-list/general-asset-list.cjs +1 -1
- package/dist/cjs/components/general-select/general-select.cjs +1 -1
- package/dist/cjs/components/grid-td-cell/grid-td-cell.cjs +1 -1
- package/dist/cjs/components/head-cell/head-cell.cjs +1 -1
- package/dist/cjs/components/health-factor/health-factor.cjs +1 -1
- package/dist/cjs/components/help-sections/help-sections.cjs +1 -1
- package/dist/cjs/components/help-tip/help-tip.cjs +1 -1
- package/dist/cjs/components/horizontal-indicator/horizontal-indicator.cjs +1 -1
- package/dist/cjs/components/icon-button/icon-button.cjs +1 -1
- package/dist/cjs/components/icons/fa-icon.cjs +1 -1
- package/dist/cjs/components/index.cjs +1 -1
- package/dist/cjs/components/input/input.cjs +1 -1
- package/dist/cjs/components/label/label.cjs +1 -1
- package/dist/cjs/components/layout/block/block.cjs +1 -1
- package/dist/cjs/components/liquidation-price/liquidation-price.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/modal/modal.cjs +1 -1
- package/dist/cjs/components/navbar/navbar.cjs +1 -1
- package/dist/cjs/components/navbar-logo/navbar-logo.cjs +1 -1
- package/dist/cjs/components/navitem/navitem.cjs +1 -1
- package/dist/cjs/components/not-found/not-found.cjs +1 -1
- package/dist/cjs/components/options-list/options-list.cjs +1 -1
- package/dist/cjs/components/overflow/overflow.cjs +1 -1
- package/dist/cjs/components/overflow-container/overflow-container.cjs +1 -1
- package/dist/cjs/components/page-title/page-title.cjs +1 -1
- package/dist/cjs/components/percent-indicator/percent-indicator.cjs +1 -1
- package/dist/cjs/components/pool-indicator-icon/pool-indicator-icon.cjs +1 -1
- package/dist/cjs/components/pool-points-indicator/pool-points-indicator.cjs +1 -1
- package/dist/cjs/components/progress/progress.cjs +1 -1
- package/dist/cjs/components/progress-circle/progress-circle.cjs +1 -1
- package/dist/cjs/components/radio-group/radio-group.cjs +1 -1
- package/dist/cjs/components/rounded-image/rounded-image.cjs +1 -1
- package/dist/cjs/components/row/row.cjs +1 -1
- package/dist/cjs/components/search-bar/search-bar.cjs +1 -1
- package/dist/cjs/components/search-line/search-line.cjs +1 -1
- package/dist/cjs/components/segmented-control/segmented-control.cjs +1 -1
- package/dist/cjs/components/select/select.cjs +1 -1
- package/dist/cjs/components/separate-line/index.cjs +1 -0
- package/dist/cjs/components/separate-line/separate-line.cjs +1 -0
- package/dist/cjs/components/separator/separator.cjs +1 -1
- package/dist/cjs/components/short-string/short-string.cjs +1 -1
- package/dist/cjs/components/signatures/confirmation-item.cjs +1 -1
- package/dist/cjs/components/skeleton/skeleton-stack.cjs +1 -1
- package/dist/cjs/components/skeleton/skeleton.cjs +1 -1
- package/dist/cjs/components/slider/slider.cjs +1 -1
- package/dist/cjs/components/slider-token/slider-token.cjs +1 -1
- package/dist/cjs/components/smart-number-input/balance-indicator.cjs +1 -1
- package/dist/cjs/components/smart-number-input/smart-number-input.cjs +1 -1
- package/dist/cjs/components/spinner/spinner.cjs +1 -1
- package/dist/cjs/components/split-list/split-list.cjs +1 -1
- package/dist/cjs/components/stat-badge/stat-badge.cjs +1 -1
- package/dist/cjs/components/status-dot/status-dot.cjs +1 -1
- package/dist/cjs/components/status-elements/status-elements.cjs +1 -1
- package/dist/cjs/components/status-triangle/status-triangle.cjs +1 -1
- package/dist/cjs/components/stepper/stepper.cjs +1 -1
- package/dist/cjs/components/styled-dropdown/styled-dropdown.cjs +1 -1
- package/dist/cjs/components/switch/switch.cjs +1 -1
- package/dist/cjs/components/tab-control/tab-control.cjs +1 -1
- package/dist/cjs/components/table/edit-button.cjs +1 -1
- package/dist/cjs/components/table/editable-grid-table.cjs +1 -1
- package/dist/cjs/components/table/editable-table.cjs +1 -1
- package/dist/cjs/components/table/grid-loading-line.cjs +1 -1
- package/dist/cjs/components/table/table-sm.cjs +1 -1
- package/dist/cjs/components/table/table.cjs +1 -1
- package/dist/cjs/components/tabs/tabs.cjs +1 -1
- package/dist/cjs/components/text-button/text-button.cjs +1 -1
- package/dist/cjs/components/textarea/textarea.cjs +1 -1
- package/dist/cjs/components/time-to-liquidation/time-to-liquidation.cjs +1 -1
- package/dist/cjs/components/tip-card/tip-card.cjs +1 -1
- package/dist/cjs/components/token-symbol/token-symbol.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/tooltip/simple-tooltip.cjs +1 -1
- package/dist/cjs/components/tooltip/tooltip.cjs +1 -1
- package/dist/cjs/components/typography/typography.cjs +1 -1
- package/dist/cjs/components/vertical-indicator/vertical-indicator.cjs +1 -1
- package/dist/cjs/components/vertical-list/vertical-list.cjs +1 -1
- package/dist/cjs/components/with-copy/with-copy.cjs +1 -1
- package/dist/cjs/components/with-filter-button/with-filter-button.cjs +1 -1
- package/dist/cjs/components/with-title/with-title.cjs +1 -1
- package/dist/cjs/index.cjs +1 -1
- package/dist/cjs/utils/format-money.cjs +1 -1
- package/dist/cjs/utils/index.cjs +1 -1
- package/dist/cjs/utils/ttl.cjs +1 -1
- package/dist/esm/components/accordion/accordion.js +6 -5
- package/dist/esm/components/address/address.js +3 -2
- package/dist/esm/components/alert-badge/alert-badge.js +1 -0
- package/dist/esm/components/alert-dialog/alert-dialog.js +4 -3
- package/dist/esm/components/apy/apy.js +14 -13
- package/dist/esm/components/arc-loader/arc-loader.js +8 -7
- package/dist/esm/components/asset-line/asset-line.js +8 -7
- package/dist/esm/components/assets-list-cell/assets-list-cell.js +3 -2
- package/dist/esm/components/assets-ratio/assets-ratio.js +17 -16
- package/dist/esm/components/auth/connect-required.js +6 -5
- package/dist/esm/components/auth/signin-required.js +10 -9
- package/dist/esm/components/avatar/avatar.js +8 -7
- package/dist/esm/components/badge/badge.js +3 -2
- package/dist/esm/components/base-link/base-link.js +11 -10
- package/dist/esm/components/block-sync/block-sync.js +5 -2
- package/dist/esm/components/breadcrumbs/breadcrumbs.js +3 -2
- package/dist/esm/components/button-checkbox/button-checkbox.js +8 -7
- package/dist/esm/components/buttons/back-button/back-button.js +8 -7
- package/dist/esm/components/buttons/button/button.js +1 -0
- package/dist/esm/components/buttons/copy-button/copy-button.js +1 -0
- package/dist/esm/components/buttons/external-button/external-button.js +1 -0
- package/dist/esm/components/buttons/navigation-button/navigation-button.js +1 -0
- package/dist/esm/components/buttons/range-buttons/range-buttons.js +3 -2
- package/dist/esm/components/card-grid/card-grid.js +9 -8
- package/dist/esm/components/cards/card/card.js +5 -4
- package/dist/esm/components/cards/expandable-call/expandable-call.js +7 -6
- package/dist/esm/components/cards/expandable-card/expandable-card.js +5 -4
- package/dist/esm/components/carousel/carousel.js +7 -6
- package/dist/esm/components/checkbox/checkbox-labeled.js +3 -0
- package/dist/esm/components/checkbox/checkbox.js +4 -3
- package/dist/esm/components/checkbox-item/checkbox-item.js +1 -0
- package/dist/esm/components/client-adapters/styled-button/styled-button.js +5 -4
- package/dist/esm/components/client-adapters/styled-dialog-container/styled-dialog-container.js +14 -13
- package/dist/esm/components/client-adapters/styled-rounded-image/styled-rounded-image.js +3 -0
- package/dist/esm/components/colored-text/colored-text.js +5 -4
- package/dist/esm/components/complex-input/complex-input.js +5 -2
- package/dist/esm/components/compound-apy/compound-apy.js +10 -9
- package/dist/esm/components/confirm-menu/confirm-menu.js +8 -7
- package/dist/esm/components/credit-session-status/credit-session-status.js +7 -6
- package/dist/esm/components/currency-button/currency-button.js +3 -2
- package/dist/esm/components/description/description.js +5 -4
- package/dist/esm/components/detailed-apy/detailed-apy.js +11 -10
- package/dist/esm/components/detailed-page-title/detailed-page-title.js +3 -2
- package/dist/esm/components/dialog/dialog-container.js +1 -0
- package/dist/esm/components/dialog/dialog-content.js +4 -3
- package/dist/esm/components/dialog/dialog-description.js +6 -5
- package/dist/esm/components/dialog/dialog-footer.js +8 -7
- package/dist/esm/components/dialog/dialog-form.js +3 -2
- package/dist/esm/components/dialog/dialog-header.js +1 -0
- package/dist/esm/components/dialog/dialog-modal-container.js +6 -5
- package/dist/esm/components/dialog/dialog-overlay.js +1 -0
- package/dist/esm/components/dialog/dialog-title.js +1 -0
- package/dist/esm/components/dropdown-label/dropdown-label.js +9 -8
- package/dist/esm/components/dropdown-menu/dropdown-menu-checkbox-item.js +1 -0
- package/dist/esm/components/dropdown-menu/dropdown-menu-content.js +4 -3
- package/dist/esm/components/dropdown-menu/dropdown-menu-item.js +1 -0
- package/dist/esm/components/dropdown-menu/dropdown-menu-label.js +6 -5
- package/dist/esm/components/dropdown-menu/dropdown-menu-radio-item.js +4 -3
- package/dist/esm/components/dropdown-menu/dropdown-menu-separator.js +1 -0
- package/dist/esm/components/dropdown-menu/dropdown-menu-shortcut.js +1 -0
- package/dist/esm/components/dropdown-menu/dropdown-menu-sub-content.js +1 -0
- package/dist/esm/components/dropdown-menu/dropdown-menu-sub-trigger.js +6 -5
- package/dist/esm/components/edit-input/edit-input.js +3 -2
- package/dist/esm/components/error-message/error-line-message.js +7 -6
- package/dist/esm/components/error-message/error-message.js +3 -2
- package/dist/esm/components/error-view/error-view.js +11 -10
- package/dist/esm/components/explorer-links-dropdown/explorer-links-dropdown.js +8 -7
- package/dist/esm/components/fadeout-loading/fadeout-loading.js +9 -8
- package/dist/esm/components/filter/filter-block.js +1 -0
- package/dist/esm/components/filter/filter-checkbox-item.js +4 -3
- package/dist/esm/components/filter/filter-chip.js +5 -4
- package/dist/esm/components/filter/filter-chips.js +9 -8
- package/dist/esm/components/filter/filter-dropdown-item.js +5 -4
- package/dist/esm/components/filter/filter-group.js +1 -0
- package/dist/esm/components/filter/filter-label.js +8 -7
- package/dist/esm/components/filter/filter-modal-item.js +5 -4
- package/dist/esm/components/filter/filter-modal.js +3 -2
- package/dist/esm/components/filter/filter-radio-item.js +4 -3
- package/dist/esm/components/filter/filter-separator.js +1 -0
- package/dist/esm/components/formatted-number/formatted-number.js +3 -2
- package/dist/esm/components/general-asset-list/general-asset-list.js +3 -2
- package/dist/esm/components/general-select/general-select.js +3 -2
- package/dist/esm/components/grid-td-cell/grid-td-cell.js +3 -2
- package/dist/esm/components/head-cell/head-cell.js +5 -4
- package/dist/esm/components/health-factor/health-factor.js +11 -10
- package/dist/esm/components/help-sections/help-sections.js +5 -4
- package/dist/esm/components/help-tip/help-tip.js +1 -0
- package/dist/esm/components/horizontal-indicator/horizontal-indicator.js +1 -0
- package/dist/esm/components/icon-button/icon-button.js +4 -3
- package/dist/esm/components/icons/fa-icon.js +3 -2
- package/dist/esm/components/index.js +214 -210
- package/dist/esm/components/input/input.js +7 -6
- package/dist/esm/components/label/label.js +7 -6
- package/dist/esm/components/layout/block/block.js +7 -6
- package/dist/esm/components/liquidation-price/liquidation-price.js +5 -4
- package/dist/esm/components/loader-guard/loader-guard.js +9 -8
- package/dist/esm/components/markdown-viewer/markdown-viewer.js +3 -2
- package/dist/esm/components/modal/modal.js +1 -0
- package/dist/esm/components/navbar/navbar.js +16 -15
- package/dist/esm/components/navbar-logo/navbar-logo.js +9 -8
- package/dist/esm/components/navitem/navitem.js +11 -10
- package/dist/esm/components/not-found/not-found.js +7 -6
- package/dist/esm/components/options-list/options-list.js +12 -11
- package/dist/esm/components/overflow/overflow.js +9 -8
- package/dist/esm/components/overflow-container/overflow-container.js +11 -10
- package/dist/esm/components/page-title/page-title.js +1 -0
- package/dist/esm/components/percent-indicator/percent-indicator.js +6 -5
- package/dist/esm/components/pool-indicator-icon/pool-indicator-icon.js +5 -4
- package/dist/esm/components/pool-points-indicator/pool-points-indicator.js +8 -7
- package/dist/esm/components/progress/progress.js +8 -7
- package/dist/esm/components/progress-circle/progress-circle.js +11 -10
- package/dist/esm/components/radio-group/radio-group.js +6 -5
- package/dist/esm/components/rounded-image/rounded-image.js +6 -5
- package/dist/esm/components/row/row.js +7 -6
- package/dist/esm/components/search-bar/search-bar.js +9 -8
- package/dist/esm/components/search-line/search-line.js +8 -7
- package/dist/esm/components/segmented-control/segmented-control.js +1 -0
- package/dist/esm/components/select/select.js +4 -3
- package/dist/esm/components/separate-line/index.js +4 -0
- package/dist/esm/components/separate-line/separate-line.js +28 -0
- package/dist/esm/components/separator/separator.js +4 -3
- package/dist/esm/components/short-string/short-string.js +6 -5
- package/dist/esm/components/signatures/confirmation-item.js +11 -10
- package/dist/esm/components/skeleton/skeleton-stack.js +8 -7
- package/dist/esm/components/skeleton/skeleton.js +7 -6
- package/dist/esm/components/slider/slider.js +24 -23
- package/dist/esm/components/slider-token/slider-token.js +10 -9
- package/dist/esm/components/smart-number-input/balance-indicator.js +3 -2
- package/dist/esm/components/smart-number-input/smart-number-input.js +1 -0
- package/dist/esm/components/spinner/spinner.js +1 -0
- package/dist/esm/components/split-list/split-list.js +5 -4
- package/dist/esm/components/stat-badge/stat-badge.js +1 -0
- package/dist/esm/components/status-dot/status-dot.js +3 -2
- package/dist/esm/components/status-elements/status-elements.js +5 -4
- package/dist/esm/components/status-triangle/status-triangle.js +5 -4
- package/dist/esm/components/stepper/stepper.js +1 -0
- package/dist/esm/components/styled-dropdown/styled-dropdown.js +11 -10
- package/dist/esm/components/switch/switch.js +1 -0
- package/dist/esm/components/tab-control/tab-control.js +11 -10
- package/dist/esm/components/table/edit-button.js +3 -2
- package/dist/esm/components/table/editable-grid-table.js +7 -6
- package/dist/esm/components/table/editable-table.js +20 -19
- package/dist/esm/components/table/grid-loading-line.js +3 -2
- package/dist/esm/components/table/table-sm.js +8 -7
- package/dist/esm/components/table/table.js +13 -12
- package/dist/esm/components/tabs/tabs.js +11 -10
- package/dist/esm/components/text-button/text-button.js +14 -13
- package/dist/esm/components/textarea/textarea.js +3 -2
- package/dist/esm/components/time-to-liquidation/time-to-liquidation.js +151 -37
- package/dist/esm/components/tip-card/tip-card.js +1 -0
- package/dist/esm/components/token-symbol/token-symbol.js +1 -0
- package/dist/esm/components/token-template/token-template.js +9 -8
- package/dist/esm/components/tokens-list-cell/tokens-list-cell.js +10 -9
- package/dist/esm/components/tooltip/simple-tooltip.js +9 -8
- package/dist/esm/components/tooltip/tooltip.js +9 -8
- package/dist/esm/components/typography/typography.js +6 -5
- package/dist/esm/components/vertical-indicator/vertical-indicator.js +6 -5
- package/dist/esm/components/vertical-list/vertical-list.js +13 -12
- package/dist/esm/components/with-copy/with-copy.js +3 -2
- package/dist/esm/components/with-filter-button/with-filter-button.js +5 -4
- package/dist/esm/components/with-title/with-title.js +9 -8
- package/dist/esm/index.js +346 -342
- package/dist/esm/utils/format-money.js +9 -8
- package/dist/esm/utils/index.js +18 -18
- package/dist/esm/utils/ttl.js +32 -33
- package/dist/types/components/index.d.ts +2 -0
- package/dist/types/components/separate-line/index.d.ts +1 -0
- package/dist/types/components/separate-line/separate-line.d.ts +28 -0
- package/dist/types/components/time-to-liquidation/time-to-liquidation.d.ts +18 -14
- package/dist/types/index.d.ts +2 -0
- package/dist/types/utils/ttl.d.ts +13 -13
- package/package.json +1 -1
|
@@ -5,11 +5,12 @@ import "clsx";
|
|
|
5
5
|
import "tailwind-merge";
|
|
6
6
|
import "sonner";
|
|
7
7
|
import "react/jsx-runtime";
|
|
8
|
+
import "luxon";
|
|
8
9
|
const _ = 10000000000000000n;
|
|
9
10
|
function F(t) {
|
|
10
11
|
return BigInt(t.toFixed(18).replace(".", ""));
|
|
11
12
|
}
|
|
12
|
-
function
|
|
13
|
+
function y(t, r) {
|
|
13
14
|
const n = typeof t == "number" && t < 0 || typeof t == "bigint" && t < 0n ? "-" : "", s = typeof t == "number" ? F(Math.abs(t)) : M.abs(t), u = s < _ && s > 0n, f = u ? "0.01" : $(s, A, r), o = `${n}$${f}`;
|
|
14
15
|
return u ? `< ${o}` : o;
|
|
15
16
|
}
|
|
@@ -18,10 +19,10 @@ function p(t, r, i = !0) {
|
|
|
18
19
|
const n = typeof t == "number" ? t : Number(t);
|
|
19
20
|
return Number.isNaN(n) || n === void 0 || n === null ? "0" : n === 0 ? 0 : i && n > O ? n.toExponential(r) : n.toFixed(r);
|
|
20
21
|
}
|
|
21
|
-
function
|
|
22
|
+
function H(t, r = 2) {
|
|
22
23
|
return `${p(t, r)}%`;
|
|
23
24
|
}
|
|
24
|
-
function
|
|
25
|
+
function U(t, r = 2) {
|
|
25
26
|
const i = Number(t) / Number(g);
|
|
26
27
|
return `${p(i, r)}%`;
|
|
27
28
|
}
|
|
@@ -33,7 +34,7 @@ const c = {
|
|
|
33
34
|
minExponentialThreshold: 1e-4,
|
|
34
35
|
maxExponentialThreshold: 1e6,
|
|
35
36
|
locale: "en-US"
|
|
36
|
-
},
|
|
37
|
+
}, V = ({
|
|
37
38
|
amount: t,
|
|
38
39
|
format: r = "full",
|
|
39
40
|
maximumFractionDigits: i = c.maximumFractionDigits,
|
|
@@ -66,9 +67,9 @@ const c = {
|
|
|
66
67
|
};
|
|
67
68
|
export {
|
|
68
69
|
c as DEFAULT_FORMAT_MONEY_CONSTANTS,
|
|
69
|
-
|
|
70
|
-
|
|
70
|
+
y as formatMoney,
|
|
71
|
+
V as formatMoneyAmount,
|
|
71
72
|
p as formatPercentAmount,
|
|
72
|
-
|
|
73
|
-
|
|
73
|
+
H as percentTemplate,
|
|
74
|
+
U as percentageTemplate
|
|
74
75
|
};
|
package/dist/esm/utils/index.js
CHANGED
|
@@ -4,11 +4,11 @@ import { bnToPrettyView as i } from "./bn-to-pretty-view.js";
|
|
|
4
4
|
import { cn as f, cn as l } from "./cn.js";
|
|
5
5
|
import { generateColorsFromBase as T, getCSSVariable as x, hexToRgba as c, resolveCSSColor as g } from "./colors.js";
|
|
6
6
|
import { copyToClipboard as u } from "./copy.js";
|
|
7
|
-
import { convertPercent as b, formatBytecodeSize as h, formatBytecodeVersion as N, formatTimestamp as A, shortenHash as I, significantTrunc as
|
|
8
|
-
import { formatAssetAmount as
|
|
7
|
+
import { convertPercent as b, formatBytecodeSize as h, formatBytecodeVersion as N, formatTimestamp as A, shortenHash as I, significantTrunc as y } from "./format.js";
|
|
8
|
+
import { formatAssetAmount as L } from "./format-asset-amount.js";
|
|
9
9
|
import { formatMoney as k, formatMoneyAmount as v, formatPercentAmount as w, percentTemplate as C, percentageTemplate as V } from "./format-money.js";
|
|
10
|
-
import { FORMAT_CONSTANTS as D, formatNumberWithSuffix as z, formatPrice as
|
|
11
|
-
import { slippageTemplate as
|
|
10
|
+
import { FORMAT_CONSTANTS as D, formatNumberWithSuffix as z, formatPrice as H, getAdaptiveDecimals as M, isBelowDisplayThreshold as O, isEffectivelyZero as R, toSignificantDigits as Z } from "./format-number.js";
|
|
11
|
+
import { slippageTemplate as E } from "./format-slippage.js";
|
|
12
12
|
import { allLoaded as q, loadingProgress as X, round5 as j } from "./loading.js";
|
|
13
13
|
import { getNetworkIcon as J } from "./network-icons.js";
|
|
14
14
|
import { bnToLiquidationPriceView as Q, isPositiveFloat as U, parseInputToBN as Y, parseSmallNumber as $ } from "./parse-input-to-bn.js";
|
|
@@ -20,12 +20,12 @@ import { createTokenSearchFilter as se, searchInToken as Te } from "./search-in-
|
|
|
20
20
|
import { shortSHA as ce } from "./short-sha.js";
|
|
21
21
|
import { isLongString as Se, shortenString as ue } from "./shorten-string.js";
|
|
22
22
|
import { negativeTokenTemplate as be, tokenTemplate as he, tokenTemplateNumber as Ne, tokenTemplateString as Ae } from "./templates.js";
|
|
23
|
-
import { TTL_CONSTANTS as
|
|
23
|
+
import { TTL_CONSTANTS as ye, getTTLZones as Fe, ttlFromTimestamp as Le, ttlLeft as Pe, ttlLeftHuman as ke } from "./ttl.js";
|
|
24
24
|
import { openInNewWindow as we } from "./window.js";
|
|
25
25
|
import { Z_INDEX as Ve } from "./z-index.js";
|
|
26
26
|
export {
|
|
27
27
|
D as FORMAT_CONSTANTS,
|
|
28
|
-
|
|
28
|
+
ye as TTL_CONSTANTS,
|
|
29
29
|
Ve as Z_INDEX,
|
|
30
30
|
q as allLoaded,
|
|
31
31
|
m as bnToInputView,
|
|
@@ -37,25 +37,25 @@ export {
|
|
|
37
37
|
se as createTokenSearchFilter,
|
|
38
38
|
l as default,
|
|
39
39
|
ne as extractTextFromLabel,
|
|
40
|
-
|
|
40
|
+
L as formatAssetAmount,
|
|
41
41
|
h as formatBytecodeSize,
|
|
42
42
|
N as formatBytecodeVersion,
|
|
43
43
|
k as formatMoney,
|
|
44
44
|
v as formatMoneyAmount,
|
|
45
45
|
z as formatNumberWithSuffix,
|
|
46
46
|
w as formatPercentAmount,
|
|
47
|
-
|
|
47
|
+
H as formatPrice,
|
|
48
48
|
A as formatTimestamp,
|
|
49
49
|
T as generateColorsFromBase,
|
|
50
50
|
r as generateId,
|
|
51
|
-
|
|
51
|
+
M as getAdaptiveDecimals,
|
|
52
52
|
ae as getAvailableRanges,
|
|
53
53
|
x as getCSSVariable,
|
|
54
54
|
J as getNetworkIcon,
|
|
55
|
-
|
|
55
|
+
Fe as getTTLZones,
|
|
56
56
|
c as hexToRgba,
|
|
57
|
-
|
|
58
|
-
|
|
57
|
+
O as isBelowDisplayThreshold,
|
|
58
|
+
R as isEffectivelyZero,
|
|
59
59
|
Se as isLongString,
|
|
60
60
|
U as isPositiveFloat,
|
|
61
61
|
X as loadingProgress,
|
|
@@ -75,14 +75,14 @@ export {
|
|
|
75
75
|
ce as shortSHA,
|
|
76
76
|
I as shortenHash,
|
|
77
77
|
ue as shortenString,
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
78
|
+
y as significantTrunc,
|
|
79
|
+
E as slippageTemplate,
|
|
80
|
+
Z as toSignificantDigits,
|
|
81
81
|
he as tokenTemplate,
|
|
82
82
|
Ne as tokenTemplateNumber,
|
|
83
83
|
Ae as tokenTemplateString,
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
ke as
|
|
84
|
+
Le as ttlFromTimestamp,
|
|
85
|
+
Pe as ttlLeft,
|
|
86
|
+
ke as ttlLeftHuman,
|
|
87
87
|
t as useFormFieldIds
|
|
88
88
|
};
|
package/dist/esm/utils/ttl.js
CHANGED
|
@@ -1,43 +1,42 @@
|
|
|
1
|
-
|
|
1
|
+
import { Duration as a } from "luxon";
|
|
2
|
+
const s = 1e3, f = 60 * s, u = 60 * f, i = 24 * u, c = 7 * i, m = 30 * i;
|
|
3
|
+
function N(n) {
|
|
2
4
|
if (!n) return;
|
|
3
|
-
const
|
|
4
|
-
return
|
|
5
|
+
const t = typeof n == "bigint" ? Number(n) : n;
|
|
6
|
+
return t >= m ? "good" : t > c ? "medium" : "bad";
|
|
5
7
|
}
|
|
6
|
-
function
|
|
8
|
+
function d(n) {
|
|
7
9
|
if (!n) return "Expired";
|
|
8
|
-
const
|
|
9
|
-
if (
|
|
10
|
-
const
|
|
11
|
-
return
|
|
10
|
+
const t = typeof n == "bigint" ? Number(n) : n;
|
|
11
|
+
if (t <= 0) return "Expired";
|
|
12
|
+
const o = Math.floor(t / i), r = Math.floor(t % i / u), e = Math.floor(t % u / f);
|
|
13
|
+
return o > 0 ? r > 0 ? `${o}d ${r}h` : `${o}d` : r > 0 ? e > 0 ? `${r}h ${e}m` : `${r}h` : e > 0 ? `${e}m` : "< 1m";
|
|
12
14
|
}
|
|
13
|
-
function
|
|
15
|
+
function b(n, t = Date.now()) {
|
|
14
16
|
if (!n) return "Expired";
|
|
15
|
-
let
|
|
16
|
-
|
|
17
|
-
const
|
|
18
|
-
return
|
|
17
|
+
let o = typeof n == "bigint" ? Number(n) : n;
|
|
18
|
+
o < 1e12 && (o *= 1e3);
|
|
19
|
+
const r = o - t;
|
|
20
|
+
return d(r);
|
|
19
21
|
}
|
|
20
|
-
function
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
if (t > 3) return { months: Math.floor(t) };
|
|
26
|
-
const o = r / 864e5;
|
|
27
|
-
if (o >= 1) return { day: Math.floor(o) };
|
|
22
|
+
function M(n) {
|
|
23
|
+
const t = typeof n == "bigint" ? Number(n) : n, o = a.fromMillis(t), r = o.as("months");
|
|
24
|
+
if (r > 3) return { months: Math.floor(r) };
|
|
25
|
+
const e = o.as("days");
|
|
26
|
+
if (e >= 1) return { day: Math.floor(e) };
|
|
28
27
|
}
|
|
29
|
-
const
|
|
30
|
-
SECOND:
|
|
31
|
-
MINUTE:
|
|
32
|
-
HOUR:
|
|
33
|
-
DAY:
|
|
34
|
-
WEEK:
|
|
35
|
-
MONTH:
|
|
28
|
+
const T = {
|
|
29
|
+
SECOND: s,
|
|
30
|
+
MINUTE: f,
|
|
31
|
+
HOUR: u,
|
|
32
|
+
DAY: i,
|
|
33
|
+
WEEK: c,
|
|
34
|
+
MONTH: m
|
|
36
35
|
};
|
|
37
36
|
export {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
37
|
+
T as TTL_CONSTANTS,
|
|
38
|
+
N as getTTLZones,
|
|
39
|
+
b as ttlFromTimestamp,
|
|
40
|
+
M as ttlLeft,
|
|
41
|
+
d as ttlLeftHuman
|
|
43
42
|
};
|
|
@@ -88,6 +88,7 @@ export * from './search-bar';
|
|
|
88
88
|
export * from './search-line';
|
|
89
89
|
export * from './segmented-control';
|
|
90
90
|
export * from './select';
|
|
91
|
+
export * from './separate-line';
|
|
91
92
|
export * from './separator';
|
|
92
93
|
export * from './short-string';
|
|
93
94
|
export * from './signatures';
|
|
@@ -111,6 +112,7 @@ export * from './text-button';
|
|
|
111
112
|
export * from './textarea';
|
|
112
113
|
export * from './theme-provider';
|
|
113
114
|
export * from './theme-toggle';
|
|
115
|
+
export * from './time-to-liquidation';
|
|
114
116
|
export * from './tip-card';
|
|
115
117
|
export * from './token-icon';
|
|
116
118
|
export * from './token-symbol';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { SeparateLine, type SeparateLineProps, } from './separate-line';
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
export interface SeparateLineProps {
|
|
3
|
+
/** Horizontal overflow (width = 100% + outOfBound px). @default 0 */
|
|
4
|
+
outOfBound?: number;
|
|
5
|
+
/** Vertical margin in px. @default 10 */
|
|
6
|
+
margin?: number;
|
|
7
|
+
/** Left offset in px (applied as left: -left). @default 0 */
|
|
8
|
+
left?: number;
|
|
9
|
+
/** Border thickness in px. @default 1 */
|
|
10
|
+
thickness?: number;
|
|
11
|
+
/** Extra class name. */
|
|
12
|
+
className?: string;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* SeparateLine — horizontal divider line (matches interface OptionsMenu SeparateLine).
|
|
16
|
+
*
|
|
17
|
+
* @usage
|
|
18
|
+
* Use as a visual separator between sections; supports extending width and offset.
|
|
19
|
+
*
|
|
20
|
+
* @example
|
|
21
|
+
* ```tsx
|
|
22
|
+
* <SeparateLine />
|
|
23
|
+
* <SeparateLine margin={20} />
|
|
24
|
+
* <SeparateLine left={16} outOfBound={32} thickness={2} />
|
|
25
|
+
* ```
|
|
26
|
+
*/
|
|
27
|
+
declare const SeparateLine: React.ForwardRefExoticComponent<SeparateLineProps & React.RefAttributes<HTMLDivElement>>;
|
|
28
|
+
export { SeparateLine };
|
|
@@ -1,20 +1,24 @@
|
|
|
1
|
-
|
|
1
|
+
import { TTLZones } from '../../utils';
|
|
2
|
+
import * as React from "react";
|
|
2
3
|
export interface TimeToLiquidationProps {
|
|
3
|
-
/**
|
|
4
|
-
* Time to liquidation in milliseconds
|
|
5
|
-
*/
|
|
4
|
+
/** Time to liquidation in milliseconds (bigint or number). */
|
|
6
5
|
timeToLiquidation: bigint | number | null;
|
|
7
|
-
/**
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
ttlZone?: HFZone;
|
|
11
|
-
/**
|
|
12
|
-
* Additional CSS class
|
|
13
|
-
*/
|
|
6
|
+
/** TTL zone for status dot (matches A TTLZones). */
|
|
7
|
+
ttlZone?: TTLZones;
|
|
8
|
+
/** Extra class name. */
|
|
14
9
|
className?: string;
|
|
15
10
|
}
|
|
16
11
|
/**
|
|
17
|
-
* TimeToLiquidation
|
|
12
|
+
* TimeToLiquidation — displays time remaining until liquidation (matches interface).
|
|
13
|
+
*
|
|
14
|
+
* @usage
|
|
15
|
+
* Use next to health/liquidation info to show remaining time and optional zone dot.
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* ```tsx
|
|
19
|
+
* <TimeToLiquidation timeToLiquidation={86400000} ttlZone="good" />
|
|
20
|
+
* <TimeToLiquidation timeToLiquidation={null} />
|
|
21
|
+
* ```
|
|
18
22
|
*/
|
|
19
|
-
|
|
20
|
-
export
|
|
23
|
+
declare const TimeToLiquidation: React.ForwardRefExoticComponent<TimeToLiquidationProps & React.RefAttributes<HTMLDivElement>>;
|
|
24
|
+
export { TimeToLiquidation };
|
package/dist/types/index.d.ts
CHANGED
|
@@ -86,6 +86,7 @@ export * from './components/search-bar';
|
|
|
86
86
|
export * from './components/search-line';
|
|
87
87
|
export * from './components/segmented-control';
|
|
88
88
|
export * from './components/select';
|
|
89
|
+
export * from './components/separate-line';
|
|
89
90
|
export * from './components/separator';
|
|
90
91
|
export * from './components/short-string';
|
|
91
92
|
export * from './components/signatures';
|
|
@@ -109,6 +110,7 @@ export * from './components/text-button';
|
|
|
109
110
|
export * from './components/textarea';
|
|
110
111
|
export * from './components/theme-provider';
|
|
111
112
|
export * from './components/theme-toggle';
|
|
113
|
+
export * from './components/time-to-liquidation';
|
|
112
114
|
export * from './components/tip-card';
|
|
113
115
|
export * from './components/token-icon';
|
|
114
116
|
export * from './components/token-symbol';
|
|
@@ -7,12 +7,12 @@ export type TTLZones = "good" | "medium" | "bad";
|
|
|
7
7
|
*
|
|
8
8
|
* @example
|
|
9
9
|
* ```ts
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
10
|
+
* getTTLZones(40 * DAY) // "good"
|
|
11
|
+
* getTTLZones(14 * DAY) // "medium"
|
|
12
|
+
* getTTLZones(3 * DAY) // "bad"
|
|
13
13
|
* ```
|
|
14
14
|
*/
|
|
15
|
-
export declare function
|
|
15
|
+
export declare function getTTLZones(ttl: number | bigint | undefined): TTLZones | undefined;
|
|
16
16
|
/**
|
|
17
17
|
* Format remaining time as a human-readable string
|
|
18
18
|
*
|
|
@@ -21,13 +21,13 @@ export declare function getTTLZone(ttl: number | bigint | undefined): TTLZones |
|
|
|
21
21
|
*
|
|
22
22
|
* @example
|
|
23
23
|
* ```ts
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
24
|
+
* ttlLeftHuman(5 * DAY + 12 * HOUR) // "5d 12h"
|
|
25
|
+
* ttlLeftHuman(3 * HOUR + 45 * MINUTE) // "3h 45m"
|
|
26
|
+
* ttlLeftHuman(30 * SECOND) // "< 1m"
|
|
27
|
+
* ttlLeftHuman(0) // "Expired"
|
|
28
28
|
* ```
|
|
29
29
|
*/
|
|
30
|
-
export declare function
|
|
30
|
+
export declare function ttlLeftHuman(ttl: number | bigint | undefined): string;
|
|
31
31
|
/**
|
|
32
32
|
* Format timestamp to remaining time string
|
|
33
33
|
*
|
|
@@ -60,12 +60,12 @@ export type TTLLeftResult = {
|
|
|
60
60
|
*
|
|
61
61
|
* @example
|
|
62
62
|
* ```ts
|
|
63
|
-
*
|
|
64
|
-
*
|
|
65
|
-
*
|
|
63
|
+
* ttlLeft(100 * DAY) // { months: 3 }
|
|
64
|
+
* ttlLeft(15 * DAY) // { day: 15 }
|
|
65
|
+
* ttlLeft(12 * HOUR) // undefined
|
|
66
66
|
* ```
|
|
67
67
|
*/
|
|
68
|
-
export declare function
|
|
68
|
+
export declare function ttlLeft(ttl: number | bigint): TTLLeftResult;
|
|
69
69
|
export declare const TTL_CONSTANTS: {
|
|
70
70
|
readonly SECOND: 1000;
|
|
71
71
|
readonly MINUTE: number;
|