Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

- [Eslint and prettierrc fixes](https://github.com/multiversx/mx-sdk-dapp-ui/pull/270)
- [Refactored sign transactions panel internal components](https://github.com/multiversx/mx-sdk-dapp-ui/pull/267)

## [[0.1.4](https://github.com/multiversx/mx-sdk-dapp-ui/pull/269)] - 2025-11-21
Expand Down
5 changes: 4 additions & 1 deletion src/assets/icons/arrow-right-icon/arrow-right-icon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,10 @@ export class ArrowRightIcon {
viewBox="0 0 448 512"
class={{ 'arrow-right-icon': true, [this.class]: Boolean(this.class) }}
>
<path fill="currentColor" d="M438.6 278.6c12.5-12.5 12.5-32.8 0-45.3l-160-160c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L338.8 224 32 224c-17.7 0-32 14.3-32 32s14.3 32 32 32l306.7 0L233.4 393.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l160-160z" />
<path
fill="currentColor"
d="M438.6 278.6c12.5-12.5 12.5-32.8 0-45.3l-160-160c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L338.8 224 32 224c-17.7 0-32 14.3-32 32s14.3 32 32 32l306.7 0L233.4 393.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l160-160z"
/>
</svg>
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@ export class LedgerProviderIcon {

render() {
return (
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 40" class={{ 'ledger-provider-icon': true, [this.class]: Boolean(this.class) }}>
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 40 40"
class={{ 'ledger-provider-icon': true, [this.class]: Boolean(this.class) }}
>
<path
d="M0.5 20.3198C0.5 15.5916 0.501062 12.0958 0.861658 9.41373C1.22032 6.74604 1.9264 4.95839 3.28249 3.60231C4.63857 2.24623 6.42621 1.54014 9.09391 1.18148C11.776 0.820886 15.2718 0.819824 20 0.819824C24.7282 0.819824 28.224 0.820886 30.9061 1.18148C33.5738 1.54014 35.3614 2.24623 36.7175 3.60231C38.0736 4.95839 38.7797 6.74604 39.1383 9.41373C39.4989 12.0958 39.5 15.5916 39.5 20.3198C39.5 25.048 39.4989 28.5438 39.1383 31.2259C38.7797 33.8936 38.0736 35.6813 36.7175 37.0373C35.3614 38.3934 33.5738 39.0995 30.9061 39.4582C28.224 39.8188 24.7282 39.8198 20 39.8198C15.2718 39.8198 11.776 39.8188 9.09391 39.4582C6.42621 39.0995 4.63857 38.3934 3.28249 37.0373C1.9264 35.6813 1.22032 33.8936 0.861658 31.2259C0.501062 28.5438 0.5 25.048 0.5 20.3198Z"
fill="#171717"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@ export class MagnifyingGlassIcon {

render() {
return (
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512" class={{ 'magnifying-glass-icon': true, [this.class]: Boolean(this.class) }}>
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 512 512"
class={{ 'magnifying-glass-icon': true, [this.class]: Boolean(this.class) }}
>
<path d="M416 208c0 45.9-14.9 88.3-40 122.7L502.6 457.4c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L330.7 376c-34.4 25.2-76.8 40-122.7 40C93.1 416 0 322.9 0 208S93.1 0 208 0S416 93.1 416 208zM208 352a144 144 0 1 0 0-288 144 144 0 1 0 0 288z" />
</svg>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@ export class MetaMaskProviderIcon {

render() {
return (
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 40" class={{ 'metamask-provider-icon': true, [this.class]: Boolean(this.class) }}>
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 40 40"
class={{ 'metamask-provider-icon': true, [this.class]: Boolean(this.class) }}
>
<path
d="M0.5 20.3198C0.5 15.5916 0.501062 12.0958 0.861658 9.41373C1.22032 6.74604 1.9264 4.95839 3.28249 3.60231C4.63857 2.24623 6.42621 1.54014 9.09391 1.18148C11.776 0.820886 15.2718 0.819824 20 0.819824C24.7282 0.819824 28.224 0.820886 30.9061 1.18148C33.5738 1.54014 35.3614 2.24623 36.7175 3.60231C38.0736 4.95839 38.7797 6.74604 39.1383 9.41373C39.4989 12.0958 39.5 15.5916 39.5 20.3198C39.5 25.048 39.4989 28.5438 39.1383 31.2259C38.7797 33.8936 38.0736 35.6813 36.7175 37.0373C35.3614 38.3934 33.5738 39.0995 30.9061 39.4582C28.224 39.8188 24.7282 39.8198 20 39.8198C15.2718 39.8198 11.776 39.8188 9.09391 39.4582C6.42621 39.0995 4.63857 38.3934 3.28249 37.0373C1.9264 35.6813 1.22032 33.8936 0.861658 31.2259C0.501062 28.5438 0.5 25.048 0.5 20.3198Z"
fill="#171717"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@ export class MultiversXLogoIcon {

render() {
return (
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 40" class={{ 'multiversx-logo-icon': true, [this.class]: Boolean(this.class) }}>
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 40 40"
class={{ 'multiversx-logo-icon': true, [this.class]: Boolean(this.class) }}
>
<path
d="M0 20.3198C0 10.8917 0 6.17769 2.92893 3.24876C5.85786 0.319824 10.5719 0.319824 20 0.319824C29.4281 0.319824 34.1421 0.319824 37.0711 3.24876C40 6.17769 40 10.8917 40 20.3198C40 29.7479 40 34.462 37.0711 37.3909C34.1421 40.3198 29.4281 40.3198 20 40.3198C10.5719 40.3198 5.85786 40.3198 2.92893 37.3909C0 34.462 0 29.7479 0 20.3198Z"
fill="#23F7DD"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@
.multiversx-symbol-icon {
@apply mvx:w-3 mvx:h-3 mvx:fill-current;
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
@apply mvx:w-48 mvx:h-16 mvx:flex mvx:fill-none;

rect {
&:hover {
fill: var(--mvx-neutral-800);
}
&:hover {
fill: var(--mvx-neutral-800);
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
@apply mvx:w-48 mvx:h-16 mvx:flex mvx:fill-none;

rect {
&:hover {
fill: var(--mvx-neutral-800);
}
&:hover {
fill: var(--mvx-neutral-800);
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
@apply mvx:w-48 mvx:h-16 mvx:flex mvx:fill-none;

rect {
&:hover {
fill: var(--mvx-neutral-800);
}
&:hover {
fill: var(--mvx-neutral-800);
}
}
}
}
}
80 changes: 70 additions & 10 deletions src/assets/icons/wallet-provider-icon/wallet-provider-icon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@ export class WalletProviderIcon {

render() {
return (
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 40" class={{ 'wallet-provider-icon': true, [this.class]: Boolean(this.class) }}>
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 40 40"
class={{ 'wallet-provider-icon': true, [this.class]: Boolean(this.class) }}
>
<mask id="mask0_7913_1658" maskUnits="userSpaceOnUse" x="0" y="0" width="40" height="41">
<path
fill-rule="evenodd"
Expand Down Expand Up @@ -55,47 +59,103 @@ export class WalletProviderIcon {
</g>
</g>
<defs>
<filter id="filter0_dddd_7913_1658" x="-5.00009" y="8.71786" width="34.903" height="31.9416" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
<filter
id="filter0_dddd_7913_1658"
x="-5.00009"
y="8.71786"
width="34.903"
height="31.9416"
filterUnits="userSpaceOnUse"
color-interpolation-filters="sRGB"
>
<feFlood flood-opacity="0" result="BackgroundImageFix" />
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha" />
<feColorMatrix
in="SourceAlpha"
type="matrix"
values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"
result="hardAlpha"
/>
<feOffset dy="0.970874" />
<feGaussianBlur stdDeviation="1.26214" />
<feComposite in2="hardAlpha" operator="out" />
<feColorMatrix type="matrix" values="0 0 0 0 0.137255 0 0 0 0 0.968627 0 0 0 0 0.866667 0 0 0 0.1 0" />
<feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_7913_1658" />
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha" />
<feColorMatrix
in="SourceAlpha"
type="matrix"
values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"
result="hardAlpha"
/>
<feOffset dy="2.13592" />
<feGaussianBlur stdDeviation="5.53398" />
<feComposite in2="hardAlpha" operator="out" />
<feColorMatrix type="matrix" values="0 0 0 0 0.137255 0 0 0 0 0.968627 0 0 0 0 0.866667 0 0 0 0.3 0" />
<feBlend mode="normal" in2="effect1_dropShadow_7913_1658" result="effect2_dropShadow_7913_1658" />
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha" />
<feColorMatrix
in="SourceAlpha"
type="matrix"
values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"
result="hardAlpha"
/>
<feOffset dy="0.291262" />
<feGaussianBlur stdDeviation="0.533981" />
<feComposite in2="hardAlpha" operator="out" />
<feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.35 0" />
<feBlend mode="normal" in2="effect2_dropShadow_7913_1658" result="effect3_dropShadow_7913_1658" />
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha" />
<feColorMatrix
in="SourceAlpha"
type="matrix"
values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"
result="hardAlpha"
/>
<feOffset dy="0.194175" />
<feGaussianBlur stdDeviation="0.0970874" />
<feComposite in2="hardAlpha" operator="out" />
<feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.25 0" />
<feBlend mode="normal" in2="effect3_dropShadow_7913_1658" result="effect4_dropShadow_7913_1658" />
<feBlend mode="normal" in="SourceGraphic" in2="effect4_dropShadow_7913_1658" result="shape" />
</filter>
<linearGradient id="paint0_linear_7913_1658" x1="20.2306" y1="15.5045" x2="20.2306" y2="35.9947" gradientUnits="userSpaceOnUse">
<linearGradient
id="paint0_linear_7913_1658"
x1="20.2306"
y1="15.5045"
x2="20.2306"
y2="35.9947"
gradientUnits="userSpaceOnUse"
>
<stop stop-color="#00FFE0" />
<stop offset="1" stop-color="#00FFE0" />
</linearGradient>
<linearGradient id="paint1_linear_7913_1658" x1="6.49826" y1="27.07" x2="42.1154" y2="23.7635" gradientUnits="userSpaceOnUse">
<linearGradient
id="paint1_linear_7913_1658"
x1="6.49826"
y1="27.07"
x2="42.1154"
y2="23.7635"
gradientUnits="userSpaceOnUse"
>
<stop stop-color="#00FFE0" />
<stop offset="1" stop-color="#4CFFE9" />
</linearGradient>
<linearGradient id="paint2_linear_7913_1658" x1="20.2306" y1="21.6695" x2="20.2306" y2="42.1597" gradientUnits="userSpaceOnUse">
<linearGradient
id="paint2_linear_7913_1658"
x1="20.2306"
y1="21.6695"
x2="20.2306"
y2="42.1597"
gradientUnits="userSpaceOnUse"
>
<stop stop-color="#00FFE0" />
<stop offset="1" stop-color="#00FFE0" />
</linearGradient>
<linearGradient id="paint3_linear_7913_1658" x1="6.49826" y1="33.2351" x2="42.1154" y2="29.9285" gradientUnits="userSpaceOnUse">
<linearGradient
id="paint3_linear_7913_1658"
x1="6.49826"
y1="33.2351"
x2="42.1154"
y2="29.9285"
gradientUnits="userSpaceOnUse"
>
<stop stop-color="#00FFE0" />
<stop offset="1" stop-color="#4CFFE9" />
</linearGradient>
Expand Down
72 changes: 41 additions & 31 deletions src/common/Button/Button.tsx
Original file line number Diff line number Diff line change
@@ -1,38 +1,48 @@
import { h } from '@stencil/core';
import { ButtonSizeEnum, ButtonVariantEnum } from './button.types';

import styles from './button.styles';
import { ButtonSizeEnum, ButtonVariantEnum } from './button.types';

interface ButtonPropsType {
class?: string;
dataTestId?: string;
disabled?: boolean;
size?: `${ButtonSizeEnum}`;
variant?: `${ButtonVariantEnum}`;
onClick?: (event: MouseEvent) => void;
class?: string;
dataTestId?: string;
disabled?: boolean;
size?: `${ButtonSizeEnum}`;
variant?: `${ButtonVariantEnum}`;
onClick?: (event: MouseEvent) => void;
}

export function Button({ class: className = '', dataTestId = '', disabled = false, size = 'large', variant = 'primary', onClick }: ButtonPropsType, children?: any) {
return (
<button
data-testid={dataTestId}
onClick={onClick}
disabled={disabled}
class={{
[styles.button]: true,
[styles.buttonDisabled]: disabled,
[size]: Boolean(size),
[styles.buttonLarge]: size === ButtonSizeEnum.large,
[styles.buttonSmall]: size === ButtonSizeEnum.small,
[variant]: Boolean(variant),
[styles.buttonPrimary]: variant === ButtonVariantEnum.primary,
[styles.buttonSecondary]: variant === ButtonVariantEnum.secondary,
[styles.buttonSecondarySmall]: variant === ButtonVariantEnum.secondary && size === ButtonSizeEnum.small,
[styles.buttonNeutral]: variant === ButtonVariantEnum.neutral,
[className]: Boolean(className),
}}
>
{children}
</button>
);

export function Button(
{
class: className = '',
dataTestId = '',
disabled = false,
size = 'large',
variant = 'primary',
onClick,
}: ButtonPropsType,
children?: any,
) {
return (
<button
data-testid={dataTestId}
onClick={onClick}
disabled={disabled}
class={{
[styles.button]: true,
[styles.buttonDisabled]: disabled,
[size]: Boolean(size),
[styles.buttonLarge]: size === ButtonSizeEnum.large,
[styles.buttonSmall]: size === ButtonSizeEnum.small,
[variant]: Boolean(variant),
[styles.buttonPrimary]: variant === ButtonVariantEnum.primary,
[styles.buttonSecondary]: variant === ButtonVariantEnum.secondary,
[styles.buttonSecondarySmall]: variant === ButtonVariantEnum.secondary && size === ButtonSizeEnum.small,
[styles.buttonNeutral]: variant === ButtonVariantEnum.neutral,
[className]: Boolean(className),
}}
>
{children}
</button>
);
}
2 changes: 1 addition & 1 deletion src/common/Button/button.styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ export default {
buttonSecondarySmall: 'button-secondary-small mvx:after:rounded-xl',
buttonNeutral: 'button-neutral mvx:text-neutral-925 mvx:bg-white mvx:hover:opacity-75',
buttonDisabled: 'button-disabled mvx:pointer-events-none mvx:bg-transparent mvx:cursor-default mvx:border mvx:border-secondary-text mvx:!text-secondary-text mvx:hover:opacity-100'
} satisfies Record<string, string>;
} satisfies Record<string, string>;
Loading