Skip to content

Commit 730633b

Browse files
authored
Merge pull request #1772 from RedisInsight/bugfix/RI-4217-4219_update_styles
#RI-4217-4219 - update styles
2 parents 9aea5cd + 83e6068 commit 730633b

File tree

18 files changed

+19
-27
lines changed

18 files changed

+19
-27
lines changed
File renamed without changes.

redisinsight/ui/src/components/uploadFile/UploadFile.tsx renamed to redisinsight/ui/src/components/upload-file/UploadFile.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React from 'react'
2-
import { EuiButtonEmpty, EuiText } from '@elastic/eui'
2+
import { EuiButtonEmpty, EuiText, EuiIcon } from '@elastic/eui'
33

44
import styles from './styles.module.scss'
55

@@ -10,18 +10,18 @@ export interface Props {
1010

1111
const UploadFile = ({ onFileChange, onClick }: Props) => (
1212
<EuiButtonEmpty
13-
iconType="folderOpen"
1413
className={styles.emptyBtn}
14+
onClick={onClick}
1515
>
1616
<label htmlFor="upload-input-file" className={styles.uploadBtn}>
17+
<EuiIcon className={styles.icon} type="folderOpen" />
1718
<EuiText className={styles.label}>Upload</EuiText>
1819
<input
1920
type="file"
2021
id="upload-input-file"
2122
data-testid="upload-input-file"
2223
accept="application/json, text/plain"
2324
onChange={onFileChange}
24-
onClick={onClick}
2525
className={styles.fileDrop}
2626
aria-label="Select file"
2727
/>
File renamed without changes.

redisinsight/ui/src/components/uploadFile/styles.module.scss renamed to redisinsight/ui/src/components/upload-file/styles.module.scss

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
.uploadBtn {
66
display: flex;
77
cursor: pointer;
8+
padding: 4px 12px;
89
}
910

1011
.emptyBtn:global(.euiButtonEmpty) {
@@ -13,7 +14,14 @@
1314
}
1415

1516
.emptyBtn:global(.euiButtonEmpty .euiButtonEmpty__content) {
16-
padding: 0 12px;
17+
padding: 0;
18+
}
19+
20+
.emptyBtn .icon {
21+
width: 14px;
22+
height: 14px;
23+
margin: 2px 4px 0 0;
24+
color: var(--inputTextColor);
1725
}
1826

1927
:global(.euiButtonEmpty.euiButtonEmpty--primary).emptyBtn .label {

redisinsight/ui/src/pages/browser/components/add-key/AddKeyReJSON/AddKeyReJSON.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import { Maybe, stringToBuffer } from 'uiSrc/utils'
1515
import { addKeyStateSelector, addReJSONKey, } from 'uiSrc/slices/browser/keys'
1616

1717
import MonacoJson from 'uiSrc/components/monaco-json'
18-
import UploadFile from 'uiSrc/components/uploadFile'
18+
import UploadFile from 'uiSrc/components/upload-file'
1919
import { sendEventTelemetry, TelemetryEvent } from 'uiSrc/telemetry'
2020
import { CreateRejsonRlWithExpireDto } from 'apiSrc/modules/browser/dto'
2121

redisinsight/ui/src/pages/home/HomePage.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -248,9 +248,8 @@ const HomePage = () => {
248248
[styles.contentActive]: editDialogIsOpen,
249249
})}
250250
id="form"
251-
minSize="538px"
252251
paddingSize="none"
253-
style={{ minWidth: '512px' }}
252+
style={{ minWidth: '494px' }}
254253
>
255254
{editDialogIsOpen && (
256255
<AddDatabaseContainer

redisinsight/ui/src/pages/home/components/AddInstanceForm/InstanceForm/InstanceForm.tsx

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -423,7 +423,6 @@ const AddStandaloneForm = (props: Props) => {
423423
<EuiButton
424424
fill
425425
color="secondary"
426-
className="btn-add"
427426
type="submit"
428427
onClick={onClick}
429428
disabled={submitIsDisabled}
@@ -446,7 +445,7 @@ const AddStandaloneForm = (props: Props) => {
446445
alignItems="center"
447446
className="footerAddDatabase"
448447
gutterSize="none"
449-
style={{ height: '68px' }}
448+
responsive={false}
450449
>
451450
<EuiFlexItem className="btn-back" grow={false}>
452451
{instanceType !== InstanceType.Sentinel && (
@@ -475,7 +474,7 @@ const AddStandaloneForm = (props: Props) => {
475474
</EuiFlexItem>
476475

477476
<EuiFlexItem grow={false}>
478-
<EuiFlexGroup>
477+
<EuiFlexGroup responsive={false}>
479478
{onClose && (
480479
<EuiButton
481480
onClick={onClose}
@@ -492,7 +491,7 @@ const AddStandaloneForm = (props: Props) => {
492491
submitIsDisabled={submitIsDisable()}
493492
/>
494493
</EuiFlexGroup>
495-
</EuiFlexItem>
494+
</EuiFlexItem>
496495
</EuiFlexGroup>,
497496
footerEl
498497
)

redisinsight/ui/src/pages/home/components/CloudConnection/CloudConnectionForm/CloudConnectionForm.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,6 @@ const CloudConnectionForm = (props: Props) => {
150150
<EuiButton
151151
fill
152152
color="secondary"
153-
className="btn-add"
154153
type="submit"
155154
onClick={onClick}
156155
disabled={submitIsDisabled}

redisinsight/ui/src/pages/home/components/ClusterConnection/ClusterConnectionForm/ClusterConnectionForm.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,6 @@ const ClusterConnectionForm = (props: Props) => {
218218
<EuiButton
219219
fill
220220
color="secondary"
221-
className="btn-add"
222221
type="submit"
223222
onClick={onClick}
224223
disabled={submitIsDisabled}

redisinsight/ui/src/pages/home/styles.scss

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -373,14 +373,10 @@
373373
padding: 12px;
374374
}
375375

376-
.euiButton.btn-add {
377-
padding-left: 10px;
378-
padding-right: 10px;
379-
}
380-
381376
.euiButton.btn-cancel,
382377
.euiButton.btn-back {
383-
margin-right: 20px;
378+
margin-right: 10px;
379+
min-width: 71px !important;
384380
}
385381

386382
.flexGroupResponsiveForm {

0 commit comments

Comments
 (0)