Skip to content
This repository was archived by the owner on Feb 22, 2024. It is now read-only.

Commit c221941

Browse files
authored
Merge pull request #3695 from mitra-deriv/addressing-comments
address comments
2 parents d98449d + 3567c48 commit c221941

File tree

6 files changed

+45
-68
lines changed

6 files changed

+45
-68
lines changed

src/botPage/view/View.js

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ import {
5050
saveBeforeUnload,
5151
} from './blockly/utils';
5252
import { moveToDeriv } from '../../common/utils/utility';
53-
import { setTimeOutBanner } from '../../indexPage';
53+
import { setTimeOutBanner, getComponent } from '../../indexPage';
5454

5555
let realityCheckTimeout;
5656
let chart;
@@ -842,14 +842,7 @@ function renderErrorPage() {
842842
// eslint-disable-next-line consistent-return
843843
function renderReactComponents() {
844844
// eslint-disable-next-line no-unused-vars
845-
let Component, dynVar;
846-
if (window.location.pathname === '/movetoderv.html') {
847-
Component = <BinaryLanding />;
848-
dynVar = 'movetoderiv';
849-
} else {
850-
Component = <BotLanding />;
851-
dynVar = 'bot-landing';
852-
}
845+
getComponent();
853846
$('.barspinner').show();
854847
const bannerToken = getStorage('setDueDateForBanner');
855848
const qs = parseQueryString();

src/indexPage/index.js

Lines changed: 12 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,16 @@ const checkifBotRunning = () => {
4242
}
4343
return false;
4444
};
45-
45+
let Component, dynamicVar;
46+
export const getComponent = () => {
47+
if (window.location.pathname === '/movetoderiv.html') {
48+
Component = <BinaryLanding />;
49+
dynamicVar = 'movetoderiv';
50+
} else {
51+
Component = <BotLanding />;
52+
dynamicVar = 'bot-landing';
53+
}
54+
};
4655
export const setTimeOutBanner = route => {
4756
let bannerDisplayed;
4857
const qs = parseQueryString();
@@ -67,14 +76,7 @@ export const setTimeOutBanner = route => {
6776
};
6877

6978
const renderBanner = () => {
70-
let Component, dynamicVar;
71-
if (window.location.pathname === '/movetoderiv.html') {
72-
Component = <BinaryLanding />;
73-
dynamicVar = 'movetoderiv';
74-
} else {
75-
Component = <BotLanding />;
76-
dynamicVar = 'bot-landing';
77-
}
79+
getComponent();
7880
render(Component, document.getElementById(dynamicVar));
7981
// setStorage('setDueDateForBanner', expirationDate());
8082
elements.map(elem => document.querySelector(elem).classList.add('hidden'));
@@ -87,14 +89,7 @@ const renderBanner = () => {
8789
// eslint-disable-next-line consistent-return
8890
const renderElements = () => {
8991
// eslint-disable-next-line one-var, no-unused-vars
90-
let Component, dynamicVar;
91-
if (window.location.pathname === '/movetoderiv.html') {
92-
Component = <BinaryLanding />;
93-
dynamicVar = 'movetoderiv';
94-
} else {
95-
Component = <BotLanding />;
96-
dynamicVar = 'bot-landing';
97-
}
92+
getComponent();
9893
setTimeOutBanner('index');
9994
$('.barspinner').show();
10095

src/indexPage/react-components/binary-landing/Navigation.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const MoveToDerivNav = () => (
1111
</a>
1212
</div>
1313
<a href="https://oauth.deriv.com/oauth2/authorize?app_id=16929&l=en&brand=deriv" className="navigation-to-deriv" rel="noopener noreferrer">
14-
<button className='btn-group r-btn'>
14+
<button className='btn-group right-btn'>
1515
{translate('Take me to deriv')}
1616
</button>
1717
</a>

static/css/_carousel.scss

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
flex-direction: column;
55

66
&__content {
7-
max-width: 992px;
7+
max-width: 62rem;
88
}
99

1010
h1 {
1111
text-align: center;
12-
margin-top: 80px;
13-
margin-bottom: 40px;
12+
margin-top: 5rem;
13+
margin-bottom: 2.5rem;
1414
font: 700 3rem $font-IBM;
1515
line-height: 4rem;
1616
color: $header-color;
@@ -24,7 +24,7 @@
2424
}
2525

2626
.carousel_section .slick-list {
27-
margin: 0 0 0 120px;
27+
margin: 0 0 0 7.5rem;
2828

2929
@media (max-width: 1024px) {
3030
margin: 0 0 0 2em;
@@ -43,7 +43,7 @@
4343
display: flex;
4444
flex-direction: column;
4545
align-items: center;
46-
margin-top: -74px;
46+
margin-top: -4.625rem;
4747

4848

4949
@media (min-width: 768px) {
@@ -52,7 +52,7 @@
5252
}
5353

5454
&__content {
55-
max-width: 996px;
55+
max-width: 62.25rem;
5656
display: flex;
5757
justify-content: center;
5858

@@ -73,25 +73,25 @@
7373
}
7474

7575
&__slide_img {
76-
max-width: 384px;
76+
max-width: 24rem;
7777

7878
@include for-size(mobile) {
79-
max-width: 318px;
79+
max-width: 19.875rem;
8080

8181
}
8282
}
8383

8484
&__arrow-btn {
8585
text-transform: none;
86-
padding: 10px 12px 10px 16px;
87-
font-size: 14px;
86+
padding: 0.625rem 0.75rem 0.625rem 1rem;
87+
font-size: 0.875rem;
8888
font-weight: 700;
89-
width: 131px;
89+
width: 8.18rem;
9090
color: #FF444F;
9191
background: #FFFFFF;
92-
border-radius: 100px;
93-
filter: drop-shadow(0px 0px 24px rgba(0, 0, 0, 0.08)) drop-shadow(0px 24px 24px rgba(0, 0, 0, 0.08));
94-
transform: translate(0px, -20px);
92+
border-radius: 6.25rem;
93+
filter: drop-shadow(0px 0px 1.5rem rgba(0, 0, 0, 0.08)) drop-shadow(0px 1.5rem 1.5rem rgba(0, 0, 0, 0.08));
94+
transform: translate(0px, -1.25rem);
9595
}
9696

9797
&__arrow-btn:hover {
@@ -101,8 +101,8 @@
101101
}
102102

103103
&__slide_card {
104-
max-width: 384px;
105-
max-height: 585px;
104+
max-width: 24rem;
105+
max-height: 36.563rem;
106106
display: flex;
107107
text-align: center;
108108
outline: none;
@@ -111,40 +111,40 @@
111111

112112
&__btn_inner {
113113
display: flex;
114-
gap: 8px;
114+
gap: 0.5rem;
115115
}
116116
}
117117

118118
.carousel_section__mobile .carousel_section__slide_card {
119119
flex-direction: column;
120-
max-width: 328px;
121-
max-height: 418px;
120+
max-width: 20.5rem;
121+
max-height: 26.125rem;
122122
display: flex;
123123
text-align: center;
124124
outline: none;
125125
}
126126

127127
.carousel_section .slick-slide {
128-
max-width: 384px;
128+
max-width: 24rem;
129129
}
130130

131131
.carousel_section .slick-slide {
132-
margin: 0 12.5px;
132+
margin: 0 0.781rem;
133133
}
134134

135135

136136
.carousel_slide_info_wrapper {
137-
max-height: 92px;
137+
max-height: 5.75rem;
138138
display: flex;
139139
flex-direction: column;
140140
justify-content: center;
141141
align-items: center;
142142

143143
position: relative;
144-
top: 198px;
144+
top: 12.375rem;
145145

146146
@include for-size(mobile) {
147-
top: 166px;
147+
top: 10.375rem;
148148
}
149149

150150
}
@@ -153,25 +153,25 @@
153153
margin-top: 0;
154154
font: 700 1.6rem $font-IBM;
155155
color: $header-color;
156-
margin-bottom: 8px;
156+
margin-bottom: 0.5rem;
157157
@include for-size(mobile) {
158158
font: 700 1.3rem $font-IBM;
159-
margin-bottom: 8px;
159+
margin-bottom: 0.5rem;
160160
}
161161

162162
}
163163

164164
.platform_description {
165-
min-height: 42px;
166-
max-width: 336px;
165+
min-height: 2.62rem;
166+
max-width: 21rem;
167167
margin-top: 0;
168168
font: 400 1rem $font-IBM;
169169
color: $header-color;
170170

171171
@include for-size(mobile) {
172172
font: 400 1rem $font-IBM;
173173
margin-bottom: 0;
174-
max-width: 280px;
174+
max-width: 17.5rem;
175175

176176
}
177177

static/css/_landing-binary.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ $header-color : #333333;
5555
}
5656

5757
}
58-
.r-btn{
58+
.right-btn{
5959
padding: 10px 16px;
6060
font: 700 0.9rem $font-IBM;
6161
text-transform: none;

static/css/_mtd-langbar.scss

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -69,17 +69,6 @@
6969
}
7070
}
7171

72-
// .language_list {
73-
// padding-top: 26px !important;
74-
// display: flex !important;
75-
// flex-direction: column;
76-
// align-items: center;
77-
// width: 176px !important;
78-
// height: 216px;
79-
// margin-top: 40px !important;
80-
// border-radius: 8px;
81-
// }
82-
8372
.hide_lang {
8473
display: none !important;
8574
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy