Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bugs pack#3 #2980

Merged
merged 4 commits into from
Apr 12, 2024
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
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
"ng-inline-svg-2": "^15.0.1",
"ngx-cookie-service": "^16.0.0",
"querystring-es3": "^0.2.1",
"rubic-sdk": "5.15.2",
"rubic-sdk": "5.15.3",
"rxjs": "7.8.1",
"ts-cacheable": "^1.0.5",
"viem": "^1.21.1",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<ng-container>
<span>{{ 'modals.confirmImportModal.text' | translate }}</span>
<div class="buttons-container">
<app-rubic-button fullWidth appearance="secondary" (click)="onDecline()">{{
<app-rubic-button fullWidth appearance="outline" (click)="onDecline()">{{
'common.cancel' | translate
}}</app-rubic-button>
<app-rubic-button fullWidth bordered (click)="onAccept()">{{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,32 @@
@use 'src/scss/core' as *;

:host {
span {
display: block;
width: 100%;

text-align: center;
}
}

.buttons-container {
display: flex;
justify-content: space-between;
justify-content: space-evenly;
margin-top: 15px;

app-rubic-button {
width: 150px;
}
}

@include b($mobile-md) {
:host {
span {
padding: 0 25px;
}
}

.buttons-container {
padding: 0 25px;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { ChangeDetectionStrategy, Component, Inject } from '@angular/core';
import { POLYMORPHEUS_CONTEXT } from '@tinkoff/ng-polymorpheus';
import { TuiDialogContext } from '@taiga-ui/core';
import { TokenAmount } from '@shared/models/tokens/token-amount';
import { MobileNativeModalService } from '@core/modals/services/mobile-native-modal.service';

@Component({
selector: 'polymorpheus-custom-token-warning-modal',
Expand All @@ -14,12 +15,14 @@ export class CustomTokenWarningModalComponent {

constructor(
@Inject(POLYMORPHEUS_CONTEXT)
private readonly context: TuiDialogContext<boolean, { token: TokenAmount }>
private readonly context: TuiDialogContext<boolean, { token: TokenAmount }>,
private readonly mobileNativeService: MobileNativeModalService
) {
this.token = context.data.token;
}

public onAccept(): void {
this.mobileNativeService.forceClose();
this.context.completeWith(true);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,18 @@
</app-tokens-list-element>
</div>

<app-rubic-button
<button
*ngIf="token.available"
class="custom-token__button"
tuiButton
appearance="secondary"
fullWidth
(onClick)="onImportClick()"
type="button"
size="m"
class="custom-token__button"
(click)="onImportClick()"
[disabled]="!token.available"
>
Import {{ token.symbol }}
</app-rubic-button>
</button>
</div>

<ng-template #disabledTokenHint>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,8 @@
}

.custom-token {
padding-left: 24px;

&__element {
padding: 5px 10px;

border-radius: 15px;
padding: 5px 0;

cursor: default;

Expand All @@ -26,6 +22,19 @@

&__button {
display: block;
width: 100%;
margin-top: 15px;

::ng-deep {
.t-wrapper {
background-color: var(--tui-primary);

span {
height: 100%;

font-size: 14px;
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ const onChainBlacklist: Record<SupportedOnChainNetworks, OnChainTradeType[]> = {
],
[BLOCKCHAIN_NAME.CRONOS]: [],
[BLOCKCHAIN_NAME.OKE_X_CHAIN]: [ON_CHAIN_TRADE_TYPE.DODO],
[BLOCKCHAIN_NAME.GNOSIS]: [ON_CHAIN_TRADE_TYPE.CURVE],
[BLOCKCHAIN_NAME.GNOSIS]: [ON_CHAIN_TRADE_TYPE.CURVE, ON_CHAIN_TRADE_TYPE.ONE_INCH],
[BLOCKCHAIN_NAME.FUSE]: [],
[BLOCKCHAIN_NAME.MOONBEAM]: [],
[BLOCKCHAIN_NAME.CELO]: [ON_CHAIN_TRADE_TYPE.CURVE],
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -16441,10 +16441,10 @@ rpc-websockets@^7.5.1:
bufferutil "^4.0.1"
utf-8-validate "^5.0.2"

[email protected].2:
version "5.15.2"
resolved "https://registry.yarnpkg.com/rubic-sdk/-/rubic-sdk-5.15.2.tgz#66ef931b751b8ee2cb3bd4e1e9b582245e08b3fe"
integrity sha512-YsjR6uWvE5eF0+z4uyPxLt1ZWNf26dyL9fIFHHvo+u/qj9Htu2KIZgI3cxP/xEkRKsIs0PxBvDZ92jPuLLY6VA==
[email protected].3:
version "5.15.3"
resolved "https://registry.yarnpkg.com/rubic-sdk/-/rubic-sdk-5.15.3.tgz#8ca91b66b2d5557a33b451875d41e0d098ea6130"
integrity sha512-UjTjqmucKaIYp0ESkbZtUvPETHjJmYLOr0IXMqojbSig1q1N8riyp1w/rmPjgza11H5OV9kZTDv63ReuGn+OZg==
dependencies:
"@1inch/limit-order-protocol-utils" "3.0.1"
"@arbitrum/sdk" "^3.1.3"
Expand Down
Loading