@stellar-expert/ui-framework 1.21.1 → 1.21.3

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.
Files changed (76) hide show
  1. package/account/account-address.js +6 -6
  2. package/account/signer-key.js +1 -1
  3. package/api/explorer-api-hooks.js +4 -4
  4. package/api/explorer-api-paginated-list-hooks.js +4 -4
  5. package/api/explorer-tx-api.js +3 -3
  6. package/api/ledger-stream.js +2 -2
  7. package/asset/amount.js +2 -2
  8. package/asset/asset-icon.js +2 -2
  9. package/asset/asset-issuer.js +2 -2
  10. package/asset/asset-link.js +6 -6
  11. package/asset/asset-list-hooks.js +3 -3
  12. package/asset/asset-meta-hooks.js +3 -3
  13. package/asset/asset-selector.js +3 -3
  14. package/charts/axis/axis.js +24 -4
  15. package/charts/axis/tick-positioner.js +1 -1
  16. package/charts/chart-default-options.js +1 -1
  17. package/charts/chart-options-builder.js +2 -2
  18. package/charts/chart.js +5 -5
  19. package/charts/core/animate.js +1 -1
  20. package/charts/core/chart.js +25 -15
  21. package/charts/core/options.js +1 -1
  22. package/charts/globals.js +5 -5
  23. package/charts/index.js +2 -2
  24. package/charts/interaction/tooltip.js +2 -2
  25. package/charts/pie/pie-chart.js +2 -2
  26. package/charts/polar/polar-chart.js +2 -2
  27. package/charts/series/area-series.js +3 -3
  28. package/charts/series/candlestick-series.js +3 -3
  29. package/charts/series/column-series.js +3 -3
  30. package/charts/series/index.js +4 -4
  31. package/charts/series/line-series.js +3 -3
  32. package/charts/series/series.js +1 -1
  33. package/charts/stock/data-grouping.js +1 -1
  34. package/charts/stock/navigator.js +33 -5
  35. package/charts/stock/range-selector.js +25 -3
  36. package/claimable-balance/claimable-balance-claimants.js +2 -2
  37. package/claimable-balance/claimable-balance-id.js +1 -1
  38. package/contract/contract-api.js +2 -2
  39. package/contract/invocation-info-view.js +6 -6
  40. package/contract/sc-val.js +1 -1
  41. package/controls/dropdown.js +1 -1
  42. package/controls/info-tooltip.js +1 -1
  43. package/controls/tabs.js +1 -1
  44. package/controls/update-highlighter.js +1 -1
  45. package/date/utc-timestamp.js +28 -28
  46. package/directory/directory-hooks.js +2 -2
  47. package/effect/effect-description.js +9 -9
  48. package/effect/op-effects-view.js +57 -57
  49. package/errors/error-boundary.js +1 -1
  50. package/filter/editors/account-filter-view.js +2 -2
  51. package/filter/editors/asset-filter-view.js +2 -2
  52. package/filter/editors/timestamp-filter-view.js +3 -3
  53. package/filter/editors/type-filter-view.js +1 -1
  54. package/filter/filter-editors.js +6 -6
  55. package/filter/filter-view.js +2 -2
  56. package/horizon/horizon-account-helpers.js +1 -1
  57. package/horizon/horizon-ledger-helpers.js +1 -1
  58. package/horizon/horizon-orderbook-helpers.js +14 -14
  59. package/horizon/horizon-trades-helper.js +1 -1
  60. package/horizon/horizon-transaction-helpers.js +1 -1
  61. package/index.js +73 -73
  62. package/interaction/system-dialog.js +2 -2
  63. package/interaction/theme-selector.js +1 -1
  64. package/ledger/ledger-entry-href-formatter.js +1 -1
  65. package/ledger/ledger-entry-link.js +2 -2
  66. package/module/dynamic-module.js +1 -1
  67. package/package.json +2 -3
  68. package/state/page-visibility-hooks.js +1 -1
  69. package/toast/toast-notifications-block.js +2 -2
  70. package/tx/op-accounting-changes.js +26 -26
  71. package/tx/op-description-view.js +13 -13
  72. package/tx/parser/tx-details-parser.js +2 -2
  73. package/tx/parser/tx-matcher.js +1 -1
  74. package/tx/tx-fee-effect.js +13 -13
  75. package/tx/tx-list-hooks.js +2 -2
  76. package/tx/tx-operations-list.js +6 -6
@@ -1,7 +1,7 @@
1
1
  import React from 'react'
2
2
  import PropTypes from 'prop-types'
3
- import {formatExplorerLink} from './ledger-entry-href-formatter.js'
4
- import {useStellarNetwork} from '../state/stellar-network-hooks.js'
3
+ import {formatExplorerLink} from './ledger-entry-href-formatter'
4
+ import {useStellarNetwork} from '../state/stellar-network-hooks'
5
5
 
6
6
  function LedgerEntryLink({type, id, network, children}) {
7
7
  const globallySetNetwork = useStellarNetwork()
@@ -1,6 +1,6 @@
1
1
  import React, {useEffect, useState} from 'react'
2
2
  import PropTypes from 'prop-types'
3
- import {withErrorBoundary} from '../errors/error-boundary.js'
3
+ import {withErrorBoundary} from '../errors/error-boundary'
4
4
 
5
5
  const loadedModules = new Map()
6
6
 
package/package.json CHANGED
@@ -1,10 +1,9 @@
1
1
  {
2
2
  "name": "@stellar-expert/ui-framework",
3
- "version": "1.21.1",
3
+ "version": "1.21.3",
4
4
  "description": "StellarExpert shared UI components library",
5
5
  "author": "orbitlens <orbit@stellar.expert>",
6
6
  "license": "MIT",
7
- "type": "module",
8
7
  "main": "index.js",
9
8
  "module": "./index.js",
10
9
  "types": "index.d.ts",
@@ -21,7 +20,7 @@
21
20
  "@stellar-expert/asset-descriptor": "^2.0.0",
22
21
  "@stellar-expert/claimable-balance-utils": "^2.0.0",
23
22
  "@stellar-expert/client-cache": "^1.1.0",
24
- "@stellar-expert/contract-wasm-interface-parser": "^5.0.0",
23
+ "@stellar-expert/contract-wasm-interface-parser": "^5.0.1",
25
24
  "@stellar-expert/formatter": "^3.1.0",
26
25
  "@stellar-expert/navigation": "^1.1.0",
27
26
  "@stellar-expert/tx-meta-effects-parser": "^9.3.0",
@@ -1,5 +1,5 @@
1
1
  import {useState, useEffect} from 'react'
2
- import {isDocumentVisible, addVisibilityChangeListener, isDocumentVisibilitySupported} from './page-visibility-helpers.js'
2
+ import {isDocumentVisible, addVisibilityChangeListener, isDocumentVisibilitySupported} from './page-visibility-helpers'
3
3
 
4
4
  /**
5
5
  * Hook that tracks whether the current browser tab/page is visible
@@ -1,7 +1,7 @@
1
1
  import React, {useCallback, useEffect, useState} from 'react'
2
2
  import {render} from 'react-dom'
3
- import ToastNotificationInstance from './toast-notification-instance.js'
4
- import Notification from './toast-notification.js'
3
+ import ToastNotificationInstance from './toast-notification-instance'
4
+ import Notification from './toast-notification'
5
5
  import './toast-notifications.scss'
6
6
 
7
7
  let notificationsCounter = 0
@@ -1,27 +1,27 @@
1
- import React from 'react'
2
- import {Amount} from '../asset/amount.js'
3
- import {retrieveOpBalanceChanges} from './parser/op-balance-changes.js'
4
-
5
- /**
6
- * Compact accounting effects (credited/debited amounts)
7
- * @param {OperationDescriptor} op
8
- * @constructor
9
- */
10
- export function OpAccountingChanges({op}) {
11
- const changes = retrieveOpBalanceChanges(op)
12
- return <div className="accounting-effects condensed">
13
- {changes.map((ch, i) => <div key={op.txHash + op.order + i}
14
- className={ch.type === 'accountDebited' ? 'dimmed' : 'color-success'}>
15
- {ch.type === 'accountDebited' ? '-' : '+'}
16
- <Amount amount={ch.amount} asset={ch.asset} issuer={false} icon={false} adjust/>
17
- </div>)}
18
- </div>
19
- }
20
-
21
- export function TxFeeAccountingChanges({amount}) {
22
- return <div className="accounting-effects condensed">
23
- <div className="dimmed">
24
- -<Amount amount={amount} asset="XLM" issuer={false} icon={false} adjust/>
25
- </div>
26
- </div>
1
+ import React from 'react'
2
+ import {Amount} from '../asset/amount'
3
+ import {retrieveOpBalanceChanges} from './parser/op-balance-changes'
4
+
5
+ /**
6
+ * Compact accounting effects (credited/debited amounts)
7
+ * @param {OperationDescriptor} op
8
+ * @constructor
9
+ */
10
+ export function OpAccountingChanges({op}) {
11
+ const changes = retrieveOpBalanceChanges(op)
12
+ return <div className="accounting-effects condensed">
13
+ {changes.map((ch, i) => <div key={op.txHash + op.order + i}
14
+ className={ch.type === 'accountDebited' ? 'dimmed' : 'color-success'}>
15
+ {ch.type === 'accountDebited' ? '-' : '+'}
16
+ <Amount amount={ch.amount} asset={ch.asset} issuer={false} icon={false} adjust/>
17
+ </div>)}
18
+ </div>
19
+ }
20
+
21
+ export function TxFeeAccountingChanges({amount}) {
22
+ return <div className="accounting-effects condensed">
23
+ <div className="dimmed">
24
+ -<Amount amount={amount} asset="XLM" issuer={false} icon={false} adjust/>
25
+ </div>
26
+ </div>
27
27
  }
@@ -3,19 +3,19 @@ import {Networks, AuthRequiredFlag, AuthRevocableFlag, AuthClawbackEnabledFlag,
3
3
  import {AssetDescriptor} from '@stellar-expert/asset-descriptor'
4
4
  import {formatPrice, formatWithAutoPrecision, fromStroops, toStroops, shortenString} from '@stellar-expert/formatter'
5
5
  import {xdrParserUtils, contractPreimageEncoder} from '@stellar-expert/tx-meta-effects-parser'
6
- import {AccountAddress} from '../account/account-address.js'
7
- import {AccountIdenticon} from '../account/identicon.js'
8
- import {SignerKey} from '../account/signer-key.js'
9
- import {Amount} from '../asset/amount.js'
10
- import {AssetLink} from '../asset/asset-link.js'
11
- import {useAssetMeta} from '../asset/asset-meta-hooks.js'
12
- import {OfferLink} from '../ledger/ledger-entry-link.js'
13
- import {formatExplorerLink} from '../ledger/ledger-entry-href-formatter.js'
14
- import {ClaimableBalanceClaimants} from '../claimable-balance/claimable-balance-claimants.js'
15
- import {CopyToClipboard} from '../interaction/copy-to-clipboard.js'
16
- import {useStellarNetwork} from '../state/stellar-network-hooks.js'
17
- import InvocationInfoView from '../contract/invocation-info-view.js'
18
- import {ClaimableBalanceId} from '../claimable-balance/claimable-balance-id.js'
6
+ import {AccountAddress} from '../account/account-address'
7
+ import {AccountIdenticon} from '../account/identicon'
8
+ import {SignerKey} from '../account/signer-key'
9
+ import {Amount} from '../asset/amount'
10
+ import {AssetLink} from '../asset/asset-link'
11
+ import {useAssetMeta} from '../asset/asset-meta-hooks'
12
+ import {OfferLink} from '../ledger/ledger-entry-link'
13
+ import {formatExplorerLink} from '../ledger/ledger-entry-href-formatter'
14
+ import {ClaimableBalanceClaimants} from '../claimable-balance/claimable-balance-claimants'
15
+ import {CopyToClipboard} from '../interaction/copy-to-clipboard'
16
+ import {useStellarNetwork} from '../state/stellar-network-hooks'
17
+ import InvocationInfoView from '../contract/invocation-info-view'
18
+ import {ClaimableBalanceId} from '../claimable-balance/claimable-balance-id'
19
19
 
20
20
  /**
21
21
  * Detailed operation description within a transaction
@@ -1,6 +1,6 @@
1
1
  import {parseTxOperationsMeta} from '@stellar-expert/tx-meta-effects-parser'
2
- import OperationDescriptor from './op-descriptor.js'
3
- import TxMatcher from './tx-matcher.js'
2
+ import OperationDescriptor from './op-descriptor'
3
+ import TxMatcher from './tx-matcher'
4
4
 
5
5
  /**
6
6
  * @typedef {Object} ParsedTxDetails - Parsed transaction
@@ -1,6 +1,6 @@
1
1
  import {LiquidityPoolAsset} from '@stellar/stellar-sdk'
2
2
  import {AssetDescriptor} from '@stellar-expert/asset-descriptor'
3
- import {TypeFilterMatcher} from './type-filter-matcher.js'
3
+ import {TypeFilterMatcher} from './type-filter-matcher'
4
4
 
5
5
  export default class TxMatcher {
6
6
  constructor(filters, skipUnrelated = false) {
@@ -1,14 +1,14 @@
1
- import React from 'react'
2
- import {Amount} from '../asset/amount.js'
3
- import {fromStroops} from '@stellar-expert/formatter'
4
-
5
- export default function TxFeeEffect({feeEffect, compact}) {
6
- const {charged, bid, bump} = feeEffect
7
- if (charged)
8
- return <div>
9
- <Amount amount={fromStroops(charged)} asset="XLM" issuer={!compact}/> transaction {!!bump && 'bump'} fee charged
10
- </div>
11
- return <div>
12
- Charge transaction {!!bump && 'bump'} fee <Amount amount={fromStroops(bid)} asset="XLM" issuer={!compact}/>
13
- </div>
1
+ import React from 'react'
2
+ import {Amount} from '../asset/amount'
3
+ import {fromStroops} from '@stellar-expert/formatter'
4
+
5
+ export default function TxFeeEffect({feeEffect, compact}) {
6
+ const {charged, bid, bump} = feeEffect
7
+ if (charged)
8
+ return <div>
9
+ <Amount amount={fromStroops(charged)} asset="XLM" issuer={!compact}/> transaction {!!bump && 'bump'} fee charged
10
+ </div>
11
+ return <div>
12
+ Charge transaction {!!bump && 'bump'} fee <Amount amount={fromStroops(bid)} asset="XLM" issuer={!compact}/>
13
+ </div>
14
14
  }
@@ -1,5 +1,5 @@
1
- import {useExplorerPaginatedApi} from '../api/explorer-api-paginated-list-hooks.js'
2
- import {useExplorerApi} from '../api/explorer-api-hooks.js'
1
+ import {useExplorerPaginatedApi} from '../api/explorer-api-paginated-list-hooks'
2
+ import {useExplorerApi} from '../api/explorer-api-hooks'
3
3
 
4
4
  /**
5
5
  * React hook that fetches paginated transaction history from the Explorer API
@@ -1,10 +1,10 @@
1
1
  import React, {useCallback, useState} from 'react'
2
- import {Spoiler} from '../interaction/spoiler.js'
3
- import {OpEffectsView} from '../effect/op-effects-view.js'
4
- import {OpAccountingChanges, TxFeeAccountingChanges} from './op-accounting-changes.js'
5
- import TxFeeEffect from './tx-fee-effect.js'
6
- import {OpDescriptionView} from './op-description-view.js'
7
- import {OpIcon} from './op-icon.js'
2
+ import {Spoiler} from '../interaction/spoiler'
3
+ import {OpEffectsView} from '../effect/op-effects-view'
4
+ import {OpAccountingChanges, TxFeeAccountingChanges} from './op-accounting-changes'
5
+ import TxFeeEffect from './tx-fee-effect'
6
+ import {OpDescriptionView} from './op-description-view'
7
+ import {OpIcon} from './op-icon'
8
8
  import './op-description.scss'
9
9
 
10
10
  /*