Skip to content

Commit

Permalink
Merge branch 'main' into add-security-warning-modal
Browse files Browse the repository at this point in the history
  • Loading branch information
OKendigelyan committed Nov 8, 2024
2 parents 0bfc301 + 8a3a5bb commit 798da10
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 16 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { SecurityWarningModal } from "./SecurityWarningModal";
import { SecurityWarningModal, accordionItems } from "./SecurityWarningModal";
import {
act,
dynamicModalContextMock,
Expand Down Expand Up @@ -30,15 +30,7 @@ describe("<SecurityWarningModal />", () => {
it("renders all accordion items", async () => {
await renderInModal(<SecurityWarningModal />);

const expectedTitles = [
"Install Extensions Only from Trusted Sources",
"Review Permissions and Ratings",
"Maintain a Separate Browser for Financial Activities",
"Keep Your Browser Updated",
"Stay Alert to Social Engineering Risks",
];

expectedTitles.forEach(title => {
accordionItems.forEach(({ title }) => {
expect(screen.getByText(title)).toBeVisible();
});
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,34 +27,34 @@ import {
} from "../../assets/icons";
import { useColor } from "../../styles/useColor";

const accordionItems = [
export const accordionItems = [
{
icon: CheckmarkIcon,
title: "Install Extensions Only from Trusted Sources",
title: "Install extensions only from trusted sources",
content:
"Use only official platforms like the Chrome Web Store or Firefox Add-ons, as these include security reviews. Avoid third-party websites and direct download links.",
},
{
icon: ThumbsUpIcon,
title: "Review Permissions and Ratings",
title: "Review permissions and ratings",
content:
"Before installing, check extension reviews, download counts, and requested permissions. Extensions that ask for access to sensitive data (like local storage or clipboard) should be trusted and necessary.",
},
{
icon: LockIcon,
title: "Maintain a Separate Browser for Financial Activities",
title: "Maintain a separate browser for financial activities",
content:
"Use a dedicated browser with no extensions installed. This minimizes risk by isolating financial activities from other browsing.",
},
{
icon: RefreshIcon,
title: "Keep Your Browser Updated",
title: "Keep your browser updated",
content:
"Regularly update your browser and extensions to ensure you have the latest security features and bug fixes.",
},
{
icon: AlertCircleIcon,
title: "Stay Alert to Social Engineering Risks",
title: "Stay alert to social engineering risks",
content:
"Avoid installing extensions prompted by emails, ads, or pop-ups, as these may use deceptive methods to gain access. Reliable services generally don’t push extensions, so question any unexpected installation requests.",
},
Expand Down

0 comments on commit 798da10

Please sign in to comment.