diff --git a/packages/snap/src/index.test.ts b/packages/snap/src/index.test.ts index 22ebf4d..5785c4c 100644 --- a/packages/snap/src/index.test.ts +++ b/packages/snap/src/index.test.ts @@ -172,8 +172,13 @@ describe('onRpcRequest', () => { panel([ heading(`A signature request is received from ${origin}`), divider(), - text('Data to sign:'), + text('Message to sign:'), panel([copyable(signRawParams.raw.data), divider()]), + row( + 'Warning:', + text(`**${'proceed only if you understand the message above!'}**`), + RowVariant.Warning, + ), ]) ); diff --git a/packages/snap/src/rpc/signRaw.ts b/packages/snap/src/rpc/signRaw.ts index 0e11311..48f3a40 100644 --- a/packages/snap/src/rpc/signRaw.ts +++ b/packages/snap/src/rpc/signRaw.ts @@ -1,5 +1,13 @@ /* eslint-disable jsdoc/require-jsdoc */ -import { copyable, divider, heading, panel, text } from '@metamask/snaps-sdk'; +import { + RowVariant, + copyable, + divider, + heading, + panel, + row, + text, +} from '@metamask/snaps-sdk'; import { SignerPayloadRaw, SignerResult } from '@polkadot/types/types'; import { isAscii, u8aToString, u8aUnwrapBytes } from '@polkadot/util'; import { getKeyPair } from '../util/getKeyPair'; @@ -12,8 +20,13 @@ const contentSignRaw = (origin: string, hexString: string) => { return panel([ heading(`A signature request is received from ${origin}`), divider(), - text('Data to sign:'), + text('Message to sign:'), panel([copyable(data), divider()]), + row( + 'Warning:', + text(`**${'proceed only if you understand the message above!'}**`), + RowVariant.Warning, + ), ]); };