From d6d5a1d6b81ce81ab4f5760f50b569156fd13935 Mon Sep 17 00:00:00 2001 From: Abhigyan Ghosh Date: Wed, 21 Feb 2024 20:47:34 +0530 Subject: [PATCH] refactor: lint code --- .../react/components/Form/Feature/Feature.tsx | 378 +++++++++--------- static/sass/styles.scss | 23 +- 2 files changed, 210 insertions(+), 191 deletions(-) diff --git a/static/js/src/advantage/subscribe/react/components/Form/Feature/Feature.tsx b/static/js/src/advantage/subscribe/react/components/Form/Feature/Feature.tsx index dfdc5bd05e6..ebea6d62dd9 100644 --- a/static/js/src/advantage/subscribe/react/components/Form/Feature/Feature.tsx +++ b/static/js/src/advantage/subscribe/react/components/Form/Feature/Feature.tsx @@ -27,15 +27,21 @@ const Feature = () => { return ( <> -

What security coverage do you need?

+ +

What security coverage do you need?

+
-

Not sure? Run pro security-status to find out which packages and repositories you are currently using.

+ data-testid="wrapper" + > +

+ Not sure? Run pro security-status to find out which + packages and repositories you are currently using. +

{ disabled={proDisabled} />
- {
- +

{feature === Features.pro ? "25000" : "2300"}

-

Covers {feature === Features.pro ? "25000" : "2300"} packages in Ubuntu Main {feature === Features.pro ? "and Universe" : ""}

+

+ Covers {feature === Features.pro ? "25000" : "2300"} packages in + Ubuntu Main {feature === Features.pro ? "and Universe" : ""} +

-
-

LTS standard security maintenance for Ubuntu Main (initial 5 years)

- {feature === Features.pro &&

LTS Expanded Security Maintenance (ESM) for Ubuntu Main (additional 5 years)

} +
+

+ LTS standard security maintenance for Ubuntu Main (initial 5 years) +

+ {feature === Features.pro && ( +

+ LTS Expanded Security Maintenance (ESM) for Ubuntu Main + (additional 5 years) +

+ )} @@ -84,7 +103,7 @@ const Feature = () => { width="67" height="64" className="p-logo-section__logo" - /> + />
{ className="p-logo-section__logo" />
- { feature===Features.pro && - <> -
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
-
- -
- } + {feature === Features.pro && ( + <> +
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+ + )}
@@ -333,4 +353,4 @@ const Feature = () => { ); }; -export default Feature; \ No newline at end of file +export default Feature; diff --git a/static/sass/styles.scss b/static/sass/styles.scss index cc4210c1fc7..64b2cbb32f6 100644 --- a/static/sass/styles.scss +++ b/static/sass/styles.scss @@ -1466,20 +1466,20 @@ $color-link-dark: #69c !default; } } -.p-graphic-main{ +.p-graphic-main { width: 10%; - background: #923A66; + background: #923a66; height: 48px; display: inline-block; } -.p-graphic-universe{ +.p-graphic-universe { width: 90%; background: #000000; height: 48px; display: inline-block; } -.p-graphic-universe--empty{ +.p-graphic-universe--empty { border-width: 1px; border-color: #757575; border-style: dashed; @@ -1488,22 +1488,23 @@ $color-link-dark: #69c !default; display: inline-block; } -.graphic-legend-main, .graphic-legend-universe{ - gap:1.2rem; +.graphic-legend-main, +.graphic-legend-universe { + gap: 1.2rem; display: flex; flex-direction: row; - &::before{ + &::before { display: inline-flex; height: 25px; width: 25px; - content:""; + content: ""; flex-shrink: 0; } } -.graphic-legend-main::before{ +.graphic-legend-main::before { background: #923a66; } -.graphic-legend-universe::before{ +.graphic-legend-universe::before { background: #000; } @@ -1534,5 +1535,3 @@ hr.is-extra-muted { background-color: rgba(0, 0, 0, 0.1); opacity: 0.5; } - -