Skip to content

Commit 7010394

Browse files
authored
MDS Console improvements (#3102)
- Removed mui badge component - Updated icons screen - Migrated Wizard Component - Improved modals styles - Updated KMS Status page Signed-off-by: Benjamin Perez <benjamin@bexsoft.net>
1 parent ec77a03 commit 7010394

File tree

11 files changed

+196
-700
lines changed

11 files changed

+196
-700
lines changed

portal-ui/src/screens/Console/Buckets/ListBuckets/BulkLifecycleModal.tsx

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ import {
2727
Switch,
2828
Tooltip,
2929
WarnIcon,
30+
Wizard,
3031
} from "mds";
3132
import get from "lodash/get";
3233
import ModalWrapper from "../../Common/ModalWrapper/ModalWrapper";
33-
import GenericWizard from "../../Common/GenericWizard/GenericWizard";
3434
import QueryMultiSelector from "../../Common/FormComponents/QueryMultiSelector/QueryMultiSelector";
3535
import { ITiersDropDown } from "../types";
3636
import { setModalErrorSnackMessage } from "../../../../systemSlice";
@@ -196,20 +196,23 @@ const AddBulkReplicationModal = ({
196196
}}
197197
title="Set Lifecycle to multiple buckets"
198198
>
199-
<GenericWizard
199+
<Wizard
200200
loadingStep={addLoading || loadingTiers}
201201
wizardSteps={[
202202
{
203203
label: "Lifecycle Configuration",
204204
componentRender: (
205205
<Fragment>
206-
<Grid item xs={12}>
207-
<ReadBox label="Local Buckets to replicate">
208-
{buckets.join(", ")}
209-
</ReadBox>
210-
</Grid>
211-
<h4>Remote Endpoint Configuration</h4>
212206
<FormLayout withBorders={false} containerPadding={false}>
207+
<Grid item xs={12}>
208+
<ReadBox
209+
label="Local Buckets to replicate"
210+
sx={{ maxWidth: "440px", width: "100%" }}
211+
>
212+
{buckets.join(", ")}
213+
</ReadBox>
214+
</Grid>
215+
<h4>Remote Endpoint Configuration</h4>
213216
<fieldset className={"inputItem"}>
214217
<legend>Lifecycle Configuration</legend>
215218
<RadioGroup

portal-ui/src/screens/Console/Buckets/ListBuckets/BulkReplicationModal.tsx

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -19,17 +19,16 @@ import {
1919
Box,
2020
CheckCircleIcon,
2121
FormLayout,
22-
Grid,
2322
InputBox,
2423
ReadBox,
2524
Select,
2625
Switch,
2726
Tooltip,
2827
WarnIcon,
28+
Wizard,
2929
} from "mds";
3030
import get from "lodash/get";
3131
import ModalWrapper from "../../Common/ModalWrapper/ModalWrapper";
32-
import GenericWizard from "../../Common/GenericWizard/GenericWizard";
3332
import { getBytes, k8sScalarUnitsExcluding } from "../../../../common/utils";
3433
import InputUnitMenu from "../../Common/FormComponents/InputUnitMenu/InputUnitMenu";
3534
import { setModalErrorSnackMessage } from "../../../../systemSlice";
@@ -302,28 +301,26 @@ const AddBulkReplicationModal = ({
302301
}}
303302
title="Set Multiple Bucket Replication"
304303
>
305-
<GenericWizard
304+
<Wizard
306305
loadingStep={addLoading || externalLoading}
307306
wizardSteps={[
308307
{
309308
label: "Remote Configuration",
310309
componentRender: (
311310
<Fragment>
312-
<Grid item xs={12}>
311+
<FormLayout containerPadding={false} withBorders={false}>
313312
<ReadBox
314-
sx={{ width: "100%" }}
315313
label="Local Buckets to replicate"
314+
sx={{ maxWidth: "440px", width: "100%" }}
316315
>
317316
{bucketsToAlter.join(", ")}
318317
</ReadBox>
319-
</Grid>
320-
<h4>Remote Endpoint Configuration</h4>
321-
<span style={{ fontSize: 14 }}>
322-
Please avoid the use of root credentials for this feature
323-
</span>
324-
<br />
325-
<br />
326-
<FormLayout containerPadding={false} withBorders={false}>
318+
<h4>Remote Endpoint Configuration</h4>
319+
<span style={{ fontSize: 14 }}>
320+
Please avoid the use of root credentials for this feature
321+
<br />
322+
<br />
323+
</span>
327324
<InputBox
328325
id="accessKey"
329326
name="accessKey"

portal-ui/src/screens/Console/Buckets/ListBuckets/Objects/ListObjects/ListObjects.tsx

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,9 @@ import {
3939
RefreshIcon,
4040
ScreenTitle,
4141
ShareIcon,
42+
Badge,
4243
} from "mds";
4344
import { api } from "api";
44-
import { Badge } from "@mui/material"; // TODO: Remove this
4545
import { errorToHandler } from "api/errors";
4646
import { BucketQuota } from "api/consoleApi";
4747
import { useSelector } from "react-redux";
@@ -1029,14 +1029,7 @@ const ListObjects = () => {
10291029
id={"rewind-objects-list"}
10301030
label={"Rewind"}
10311031
icon={
1032-
<Badge
1033-
badgeContent=" "
1034-
color="secondary"
1035-
variant="dot"
1036-
invisible={!rewindEnabled}
1037-
className={""}
1038-
sx={{ height: 16 }}
1039-
>
1032+
<Badge color="alert" dotOnly invisible={!rewindEnabled}>
10401033
<HistoryIcon
10411034
style={{
10421035
minWidth: 16,

portal-ui/src/screens/Console/Common/FormComponents/QueryMultiSelector/QueryMultiSelector.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -216,6 +216,7 @@ const QueryMultiSelector = ({
216216
fontWeight: 600,
217217
},
218218
}}
219+
className={"inputItem"}
219220
>
220221
<InputLabel>
221222
{label}

portal-ui/src/screens/Console/Common/FormComponents/common/styleLibrary.ts

Lines changed: 0 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -104,33 +104,6 @@ export const tooltipHelper = {
104104
},
105105
};
106106

107-
export const containerForHeader = {
108-
container: {
109-
position: "relative" as const,
110-
padding: "20px 35px 0",
111-
"& h6": {
112-
color: "#777777",
113-
fontSize: 30,
114-
},
115-
"& p": {
116-
"& span:not(*[class*='smallUnit'])": {
117-
fontSize: 16,
118-
},
119-
},
120-
},
121-
sectionTitle: {
122-
margin: 0,
123-
marginBottom: ".8rem",
124-
fontSize: "1.3rem",
125-
},
126-
boxy: {
127-
border: "#E5E5E5 1px solid",
128-
borderRadius: 2,
129-
padding: 40,
130-
backgroundColor: "#fff",
131-
},
132-
};
133-
134107
export const actionsTray = {
135108
label: {
136109
color: "#07193E",

0 commit comments

Comments
 (0)