Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: "CHANGELOG entry secretary"
name: 'CHANGELOG entry secretary'
on:
pull_request:
branches: [main, development]
branches: [main]
# The specific activity types are listed here to include "labeled" and "unlabeled"
# (which are not included by default for the "pull_request" trigger).
# This is needed to allow skipping enforcement of the changelog in PRs with specific labels,
Expand All @@ -13,4 +13,4 @@ jobs:
changelog:
runs-on: ubuntu-latest
steps:
- uses: dangoslen/changelog-enforcer@v3
- uses: dangoslen/changelog-enforcer@v3
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

- ## [[2.3.2](https://github.com/multiversx/mx-explorer-dapp/pull/208)] - 2025-11-27

- [Handle deprecatedRelayedV1V2](https://github.com/multiversx/mx-explorer-dapp/pull/208)
- [Split Adapter Requests](https://github.com/multiversx/mx-explorer-dapp/pull/207)
- [Show reserved field on Block Details page](https://github.com/multiversx/mx-explorer-dapp/pull/205)
- [Add LowLiquidityTooltip on token row](https://github.com/multiversx/mx-explorer-dapp/pull/203)
- [Show PriceSourceTooltip on tokens in account and on tokens table](https://github.com/multiversx/mx-explorer-dapp/pull/200)

- ## [[2.3.1](https://github.com/multiversx/mx-explorer-dapp/pull/199)] - 2025-10-29

- [Updated Account Token Value display constrains](https://github.com/multiversx/mx-explorer-dapp/pull/198)
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "mx-explorer-dapp",
"description": "MultiversX Blockchain Explorer",
"version": "2.3.1",
"version": "2.3.2",
"author": "MultiversX",
"license": "GPL-3.0-or-later",
"repository": "multiversx/mx-explorer-dapp",
Expand Down
2 changes: 2 additions & 0 deletions src/appConstants/descriptions.constants.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export const DEPRECATED_RELAYED_TX_DESCRIPTION =
'The transaction is not behaving like a relayed transaction, but is simply considered a notarization transaction with a data field.';
2 changes: 2 additions & 0 deletions src/appConstants/docsLinks.constants.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export const DOCS_RELAYED_VERSION_URL =
'https://docs.multiversx.com/developers/relayed-transactions/#types-of-relayed-transactions';
2 changes: 2 additions & 0 deletions src/appConstants/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
export * from './apiFields.constants';
export * from './charts.constants';
export * from './descriptions.constants';
export * from './docsLinks.constants';
export * from './general.constants';
export * from './websocket.constants';
4 changes: 4 additions & 0 deletions src/assets/scss/common/_theme-helpers.scss
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ a > .cursor-context {
word-break: break-all;
}

.text-underline {
text-decoration: underline;
}

.min-w-0 {
min-width: 0;
}
Expand Down
45 changes: 44 additions & 1 deletion src/components/TransactionAction/TransactionAction.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
import { useEffect, useState } from 'react';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
import classNames from 'classnames';
import { useSelector } from 'react-redux';

import DefaultAvatar from 'assets/img/default-avatar.svg';
Expand All @@ -7,9 +9,11 @@ import {
AccountLink,
FormatAmount,
TransactionActionBlock,
NftBadge
NftBadge,
InfoTooltip
} from 'components';
import { addressIsBech32, urlBuilder } from 'helpers';
import { faArrowUpRightFromSquare } from 'icons/regular';
import { activeNetworkSelector } from 'redux/selectors';
import {
NftTypeEnum,
Expand Down Expand Up @@ -196,6 +200,45 @@ const ActionText = ({
</span>
);

case Boolean(entry.tooltip):
return (
<span className='d-inline'>
{entry.description && (
<span className='me-1'>{entry.description}</span>
)}
<InfoTooltip
title={
<>
{entry.tooltip}
{entry.externalLink && (
<>
<br />
<a
href={entry.externalLink}
target='_blank'
rel='noreferrer nofollow noopener'
className='text-underline mt-2'
>
Learn More
<FontAwesomeIcon
icon={faArrowUpRightFromSquare}
size='xs'
className='ms-1'
/>
</a>
</>
)}
</>
}
className='ms-0'
iconClassName={classNames({
'text-warning': Boolean(entry.isWarning)
})}
persistent
/>
</span>
);

default:
return null;
}
Expand Down
41 changes: 39 additions & 2 deletions src/components/TransactionAction/helpers/unwrapper.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
import BigNumber from 'bignumber.js';

import {
DEPRECATED_RELAYED_TX_DESCRIPTION,
DOCS_RELAYED_VERSION_URL
} from 'appConstants';
import {
TransactionActionType,
TransactionActionEnum,
Expand Down Expand Up @@ -114,6 +119,30 @@ export const mexUnwrapper = (
}
};

export const tooltipUnwrapper = (
action: TransactionActionType,
options: TransactionUnwrapperType = {}
): Array<string | TransactionUnwrapperType> => {
const description = options?.description || action?.description;
if (action?.name && description) {
const tooltipOptions = {
tooltip: description,
...(options?.externalLink ? { externalLink: options.externalLink } : {}),
...(options?.isWarning ? { isWarning: options.isWarning } : {})
};
if (options?.description) {
const actionText = `${action.name}${
action?.description ? `: ${action.description}` : ''
}`;
return [{ ...tooltipOptions, description: actionText }];
}

return [{ ...tooltipOptions, description: action.name }];
}

return defaultAction(action);
};

export const esdtNftUnwrapper = (
action: TransactionActionType
): Array<string | TransactionUnwrapperType> => {
Expand Down Expand Up @@ -189,6 +218,14 @@ export const stakeUnwrapper = (
export const unwrapper = (
action: TransactionActionType
): Array<string | TransactionUnwrapperType> => {
if (action.category === TransactionActionCategoryEnum.deprecatedRelayedV1V2) {
return tooltipUnwrapper(action, {
description: DEPRECATED_RELAYED_TX_DESCRIPTION,
externalLink: DOCS_RELAYED_VERSION_URL,
isWarning: true
});
}

if (action.arguments) {
switch (action.category) {
case TransactionActionCategoryEnum.esdtNft:
Expand All @@ -200,7 +237,7 @@ export const unwrapper = (
default:
return defaultAction(action);
}
} else {
return defaultAction(action);
}

return defaultAction(action);
};
35 changes: 20 additions & 15 deletions src/helpers/getValue/getTransactionMethod.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,32 @@ import {
} from 'types';

export const getTransactionMethod = (transaction: UITransactionType) => {
let transactionAction = 'transaction';
if (
transaction.action &&
transaction.action.name &&
transaction.action.category
) {
const transactionAction = 'transaction';

if (transaction?.function) {
return transaction.function;
}

if (transaction.action?.name && transaction.action?.category) {
if (
transaction.action.category === TransactionActionCategoryEnum.esdtNft &&
transaction.action.name === TransactionActionEnum.transfer
transaction.action.category ===
TransactionActionCategoryEnum.deprecatedRelayedV1V2
) {
transactionAction = 'transaction';
} else {
transactionAction = transaction.action.name;
return transactionAction;
}

if (transaction.action.arguments?.functionName) {
transactionAction = transaction.action.arguments?.functionName;
return transaction.action.arguments?.functionName;
}
}
if (transaction?.function) {
transactionAction = transaction.function;

if (
transaction.action.category === TransactionActionCategoryEnum.esdtNft &&
transaction.action.name === TransactionActionEnum.transfer
) {
return transactionAction;
}

return transaction.action.name;
}

return transactionAction;
Expand Down
Loading
Loading