Skip to content
This repository was archived by the owner on Dec 28, 2023. It is now read-only.

Commit 7dcb8d6

Browse files
authored
Hubert / Update index scss (#279)
1 parent 1525b10 commit 7dcb8d6

File tree

49 files changed

+943
-1073
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+943
-1073
lines changed

src/components/api-guide/ApiGuide/ApiGuide.jsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export default function ApiGuide() {
1818
<h1>API guide</h1>
1919
{isMobile && <RenderOfficialDomainContents Component={Navigator} />}
2020
<div className={styles.textBlock}>
21-
<h2 id='what-is-api'>What is API?</h2>
21+
<h2 id='what-is-an-api'>What is an API?</h2>
2222
<p>
2323
API stands for Application Programming Interface - a software that allows 2 or more computer
2424
programs to communicate with each other. These 2 programs are usually referred to as server and
@@ -70,7 +70,7 @@ export default function ApiGuide() {
7070
<div className={styles.apiGuideImage}>
7171
<img src={howAPIWorksUrl} alt='How API works' loading='lazy' />
7272
</div>
73-
<h3>Client libraries</h3>
73+
<h4>Client libraries</h4>
7474
<p>
7575
{' '}
7676
Client libraries are pre-written pieces of code that can be used to send API calls instead of

src/components/api-guide/ApiGuide/ApiGuideTable/ApiGuideTable.module.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
}
1111
td {
1212
padding: 2.4rem 3.2rem;
13-
box-shadow: inset 0 -1px 0 var(--gray-15);
13+
box-shadow: inset 0 -0.1rem 0 var(--gray-15);
1414
}
1515
}
1616

src/components/api-guide/ApiGuide/DerivGuideContent/DerivGuideContent.tsx

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import React from 'react';
22
import { Link } from 'react-router-dom';
3+
import { InlineCode } from '../../../global/InlineCode/InlineCode';
34
import ApiGuideTable from '../ApiGuideTable/ApiGuideTable';
45
import CodeBlockSingleLanguage from '../../../global/CodeBlock/CodeBlockSingleLanguage';
56
import styles from '../ApiGuide.module.scss';
@@ -79,7 +80,7 @@ export const DerivGuideContent = () => {
7980
Client's stake with the markup = 1.07 USD + (2 USD x 2%) = <b>1.11 USD</b>
8081
</li>
8182
</ul>
82-
<h3>Conditions of using the Deriv API</h3>
83+
<h4>Conditions of using the Deriv API</h4>
8384
<p>
8485
The Deriv API is free of charge and is subject to our{' '}
8586
<a href='https://deriv.com/terms-and-conditions'>terms and conditions</a> and{' '}
@@ -120,7 +121,7 @@ export const DerivGuideContent = () => {
120121
For more information on how to write a client using WebSockets, visit this{' '}
121122
<a href='/docs/'>guide</a>.
122123
</p>
123-
<h2 id='json'>JSON</h2>
124+
<h3 id='json'>JSON</h3>
124125
<p>
125126
JavaScript Object Notation (JSON) is a data format based on JavaScript. However, it is completely
126127
language-independent, and can be used by any modern programming language. JSON has a good balance
@@ -156,7 +157,7 @@ export const DerivGuideContent = () => {
156157
<div className={styles.apiCodeBlock}>
157158
<CodeBlockSingleLanguage lang='json' content={statusContent} />
158159
</div>
159-
<h2 id='json-schemas'>JSON Schemas</h2>
160+
<h3 id='json-schemas'>JSON Schemas</h3>
160161
<p>
161162
JSON Schema is a defined format for the JSON messages used to describe their structure to Deriv API
162163
users. In a nutshell, it’s a standardised way of explaining what a JSON request should look like using
@@ -186,12 +187,12 @@ export const DerivGuideContent = () => {
186187
<img src={showJSONSchemaImg} alt='API Guide' loading='lazy' />
187188
</div>
188189
<p>The JSON Schema also forms the documentation for the API Explorer.</p>
189-
<h2 id='authorisation'>Authorisation</h2>
190+
<h3 id='authorisation'>Authorisation</h3>
190191
<p>
191192
Third-party developers can authorise calls to the API in two different ways: via API token or via
192193
OAuth2.
193194
</p>
194-
<h3>API token</h3>
195+
<h4>API token</h4>
195196
<p>
196197
An API token is a unique identifier of a client that requests access from a server. It's the simplest
197198
way of authorisation.
@@ -223,7 +224,7 @@ export const DerivGuideContent = () => {
223224
Please bear in mind that the API token can be used with any app, so both your app and your clients need
224225
to keep it secure.
225226
</p>
226-
<h3>OAuth2</h3>
227+
<h4>OAuth2</h4>
227228
<p>
228229
OAuth stands for Open Authorisation - a protocol that allows a client access resources hosted on a
229230
server on behalf of the user without revealing the credentials.
@@ -245,7 +246,7 @@ export const DerivGuideContent = () => {
245246
<div className={styles.apiGuideImage}>
246247
<img src={howOauthWorksImg} alt='API Guide' loading='lazy' />
247248
</div>
248-
<h2>What do you need to do to use OAuth authorisation for Deriv API?</h2>
249+
<h3>What do you need to do to use OAuth authorisation for Deriv API?</h3>
249250
<ul>
250251
<li>
251252
<p>
@@ -270,10 +271,11 @@ export const DerivGuideContent = () => {
270271
will have arguments added to it with the user's session tokens, and will look similar to this:
271272
</p>
272273
<p>
273-
<code className='inline-code'>
274-
https://mywebsite.com/redirect/?acct1=cr799393& token1=a1-f7pnteezo4jzhpxclctizt27hyeot&cur1=usd&
275-
acct2=vrtc1859315& token2=a1clwe3vfuuus5kraceykdsoqm4snfq& cur2=usd&state=
276-
</code>
274+
<InlineCode>
275+
https://&#91;YOUR_WEBSITE_URL&#93;/redirect/?acct1=cr799393&
276+
token1=a1-f7pnteezo4jzhpxclctizt27hyeot&cur1=usd& acct2=vrtc1859315&
277+
token2=a1clwe3vfuuus5kraceykdsoqm4snfq& cur2=usd&state=
278+
</InlineCode>
277279
</p>
278280
<p>In the parameters of the URL you will see all the accounts and the session token for each account.</p>
279281
<ul>

src/components/api-guide/ApiGuide/Navigator/Navigator.module.scss

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,25 +3,25 @@
33
flex-direction: column;
44
width: 100%;
55
background-color: var(--gray-06);
6-
right: 40px;
6+
right: 4rem;
77
z-index: 10;
88
box-sizing: border-box;
99
padding: 1.6rem;
10-
margin: 0 auto 30px;
10+
margin: 0 auto 3rem;
1111
.navigatorContent {
1212
display: flex;
1313
flex-direction: column;
1414
height: 0;
1515
overflow: hidden;
1616
transition: height 0.3s ease-in-out;
1717
&.opened {
18-
height: 370px;
18+
height: 37rem;
1919
}
2020
.navigatorLink {
21-
line-height: 26px;
22-
font-size: 12px;
21+
line-height: 2.6rem;
22+
font-size: var(--text-size-xxs);
2323
color: var(--gray-05);
24-
padding: 4px 0;
24+
padding: 0.4rem 0;
2525
&:hover {
2626
background-color: var(--gray-01);
2727
}
@@ -36,22 +36,22 @@
3636
align-items: center;
3737
justify-content: space-between;
3838
.navigatorTitle {
39-
font-size: 18px;
39+
font-size: var(--text-size-xsm);
4040
margin: 0;
4141
&.bold {
4242
font-weight: 700;
4343
}
4444
}
4545
.arrow {
46-
background-size: 22px;
46+
background-size: 2.2rem;
4747
background-position: center;
4848
background-repeat: no-repeat;
4949
cursor: pointer;
5050
background-image: url(/img/arrow_up.svg);
5151
transform: rotate(-180deg);
5252
transition: transform 0.2s;
53-
width: 22px;
54-
height: 22px;
53+
width: 2.2rem;
54+
height: 2.2rem;
5555
&.down {
5656
transform: rotate(0deg);
5757
}
@@ -61,14 +61,14 @@
6161

6262
[data-state~="responsive.mobileTablet"] {
6363
.navigator {
64-
width: 650px;
64+
width: 65rem;
6565
}
6666
}
6767

6868
[data-state*="responsive.desktop"] {
6969
.navigator {
70-
max-width: 270px;
71-
width: 270px;
70+
max-width: 27rem;
71+
width: 27rem;
7272
position: fixed;
7373
}
7474
}

src/components/api-guide/ApiGuide/Navigator/Navigator.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ export default function Navigator() {
1313
/>
1414
</div>
1515
<div className={`${styles.navigatorContent} ${is_closed ? '' : styles.opened}`}>
16-
<a className={styles.navigatorLink} href='#what-is-api'>
17-
What is API?
16+
<a className={styles.navigatorLink} href='#what-is-an-api'>
17+
What is an API?
1818
</a>
1919
<a className={styles.navigatorLink} href='#the-deriv-api'>
2020
The Deriv API

src/components/app-registration/AppManagement/AppManagement.module.scss

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,24 @@
1010
thead {
1111
background-color: var(--gray-02);
1212
height: 5rem;
13-
text-align: var(--text-align-left);
1413
}
1514

1615
th,
1716
td {
17+
text-align: var(--text-align-left);
1818
padding: 1.6rem;
1919
min-width: 12rem;
2020
max-width: 20rem;
2121
overflow: hidden;
2222
text-overflow: ellipsis;
2323
}
2424

25+
td:nth-child(3) {
26+
display: flex;
27+
flex-wrap: wrap;
28+
gap: 0.64rem;
29+
}
30+
2531
td:last-child,
2632
th:last-child {
2733
white-space: nowrap;
@@ -36,12 +42,6 @@
3642
tbody tr:nth-child(even) {
3743
background-color: var(--gray-03);
3844
}
39-
40-
td:nth-child(2n + 3) {
41-
display: flex;
42-
flex-wrap: wrap;
43-
gap: 0.64rem;
44-
}
4545
}
4646

4747
[data-state~='registration.logged_in.manage_tab'] .manageApps {
@@ -85,7 +85,7 @@
8585

8686
.appActions {
8787
display: flex;
88-
justify-content: var(--text-align-center);
88+
justify-content: var(--text-align-left);
8989
margin: 3rem;
9090
}
9191

@@ -100,7 +100,7 @@
100100
border-radius: 4px;
101101
color: var(--app-registration-tab-active-font);
102102
text-align: var(--text-align-center);
103-
border-radius: 6px;
103+
border-radius: 4px;
104104
padding: 0.5rem 0;
105105
position: absolute;
106106
z-index: 1;
@@ -124,7 +124,7 @@
124124
}
125125

126126
&:hover {
127-
transform: translateY(-2px);
127+
transform: translateY(-0.2rem);
128128

129129
.tooltipText {
130130
visibility: visible;
@@ -134,13 +134,13 @@
134134
}
135135

136136
.scope {
137-
border: 0.16rem solid #d6dadb;
138-
border-radius: 0.4rem;
139-
padding: 0.32rem 0.32rem;
140-
font-size: var(--text-size-xxs);
137+
border: 1.6px solid var(--border-normal);
138+
border-radius: 4px;
139+
padding: 0.24rem 0.24rem;
140+
font-size: 1.1rem;
141141
}
142142

143143
.adminScope {
144-
border: 0.1rem solid var(--teal-01);
144+
border: 1.6px solid var(--teal-01);
145145
color: var(--teal-01);
146146
}

src/components/app-registration/AppRegistration/AppRegistration.scss

Lines changed: 15 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,12 @@
22
display: none;
33
}
44

5-
.app-registration-header .form-title {
6-
font-size: var(--text-size-xm);
7-
}
8-
9-
.app-registration-header .form-title,
10-
.app-registration-header .form-subtitle {
11-
text-align: var(--text-align-center);
5+
.app-registration-header {
6+
padding: 0 2rem;
7+
.form-title,
8+
.form-subtitle {
9+
text-align: var(--text-align-center);
10+
}
1211
}
1312

1413
/* add delete.svg icon to app-remove-btn */
@@ -83,7 +82,7 @@
8382
height: auto;
8483
background-color: var(--white);
8584
border-radius: 16px;
86-
box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.5);
85+
box-shadow: 0 0 1rem rgba(0, 0, 0, 0.5);
8786
justify-content: space-between;
8887
}
8988

@@ -166,7 +165,7 @@
166165
background-color: var(--white);
167166
color: black;
168167
font-weight: var(--text-weight-bold);
169-
border: 1px solid #999999;
168+
border: 0.1rem solid var(--gray-05);
170169
height: 4rem;
171170
border-radius: 4px;
172171
padding: 1rem 1.6rem 1rem 1.6rem;
@@ -200,6 +199,7 @@ fieldset {
200199
width: 80%;
201200
margin: 0 auto;
202201
border: none;
202+
203203
.first {
204204
margin-top: 2rem;
205205
}
@@ -257,8 +257,7 @@ fieldset {
257257
display: none;
258258
}
259259

260-
[data-state~="registration.logged_in.manage_tab.loadingApps.empty"]
261-
.no-apps-wrapper {
260+
[data-state~="registration.logged_in.manage_tab.loadingApps.empty"] .no-apps-wrapper {
262261
display: inline-block;
263262
visibility: visible;
264263
}
@@ -318,7 +317,7 @@ fieldset {
318317
width: 100%;
319318
right: 0;
320319
top: 0;
321-
bottom: -1px;
320+
bottom: -0.1rem;
322321
}
323322

324323
[data-state~="registration.logged_in.update_mode"] .register-app {
@@ -346,8 +345,7 @@ fieldset {
346345
}
347346

348347
/* display register-app when [data-state] success */
349-
[data-state~="registration.logged_in.register_tab.unfolded_form.submitting_registration.registration_success"]
350-
.registration-dialog {
348+
[data-state~="registration.logged_in.register_tab.unfolded_form.submitting_registration.registration_success"] .registration-dialog {
351349
display: flex;
352350
}
353351

@@ -387,10 +385,11 @@ fieldset {
387385

388386
[data-state~="responsive.mobileL"],
389387
[data-state~="responsive.mobileTablet"],
390-
[data-state*="responsive.desktop"] {
388+
[data-state*="responsive.desktop"] {
391389
.dialog {
392390
width: 38.5rem;
393391
}
392+
394393
.dialog-delete,
395394
.dialog-update {
396395
width: 32rem;
@@ -447,4 +446,4 @@ fieldset {
447446
.expandable-form .register-app-button {
448447
padding: 1.2rem 2rem;
449448
}
450-
}
449+
}

0 commit comments

Comments
 (0)