Skip to content

Commit

Permalink
Merge branch 'develop' into fix/CORL-3180-dont-autoplay-gifs-mod-queue
Browse files Browse the repository at this point in the history
  • Loading branch information
tessalt authored Sep 30, 2024
2 parents a648c02 + 554602f commit 6945b13
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 41 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -152,13 +152,13 @@ it("user drawer is open and user can be scheduled for deletion and have deletion
"userHistoryDrawer-modal"
);
const historyTab = await within(isabelleUserHistory).findByRole("tab", {
name: "Tab: time-reverse Account History",
name: "time-reverse Account History",
});
await act(async () => {
userEvent.click(historyTab);
});
const tabRegion = screen.getByRole("region", {
name: "Tab: time-reverse Account History",
name: "time-reverse Account History",
});
const deleteAccountButton = within(tabRegion).getByRole("button", {
name: "Delete account",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,7 @@ it("show reaction details for a comment with reactions", async () => {
});
userEvent.click(detailsButton);
const reactionsButton = within(reported).getByRole("tab", {
name: "Tab: Reactions",
name: "Reactions",
});
await act(async () => {
userEvent.click(reactionsButton);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,7 @@ it("renders comment stream with answered comments", async () => {
"comments-featuredComments-log"
);
expect(answeredComments).toBeVisible();
expect(
screen.getByRole("tab", { name: "Tab: Answered ( 2 )" })
).toBeVisible();
expect(screen.getByRole("tab", { name: "Answered ( 2 )" })).toBeVisible();
expect(
screen.getByRole("article", {
name: "Answer from Markus 2018-07-06T18:24:00.000Z",
Expand All @@ -88,9 +86,7 @@ it("renders oldest first sort answered comments tab with post comment form", asy
"comments-featuredComments-log"
);
expect(answeredComments).toBeVisible();
expect(
screen.getByRole("tab", { name: "Tab: Answered ( 2 )" })
).toBeVisible();
expect(screen.getByRole("tab", { name: "Answered ( 2 )" })).toBeVisible();
expect(
screen.getByRole("article", {
name: "Answer from Markus 2018-07-06T18:24:00.000Z",
Expand Down
12 changes: 1 addition & 11 deletions client/src/core/client/ui/components/v2/Tabs/Tab.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
import { Localized } from "@fluent/react/compat";
import cn from "classnames";
import React from "react";

import BaseButton from "coral-ui/components/v2/BaseButton";
import { withStyles } from "coral-ui/hocs";

import AriaInfo from "../AriaInfo";

import styles from "./Tab.css";

export interface TabProps {
Expand Down Expand Up @@ -103,14 +100,7 @@ class Tab extends React.Component<TabProps> {
title={title}
onClick={this.handleTabClick}
>
<>
<AriaInfo>
<Localized id="ui-tabAriaPrefix">
<span>Tab:</span>
</Localized>
</AriaInfo>
{children}
</>
{children}
</BaseButton>
</li>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,6 @@ exports[`sets initial tab as active 1`] = `
role="tab"
type="button"
>
<div
className="AriaInfo-root"
>
<span>
Tab:
</span>
</div>
One
</button>
</li>
Expand All @@ -51,13 +44,6 @@ exports[`sets initial tab as active 1`] = `
role="tab"
type="button"
>
<div
className="AriaInfo-root"
>
<span>
Tab:
</span>
</div>
Two
</button>
</li>
Expand All @@ -79,13 +65,6 @@ exports[`sets initial tab as active 1`] = `
role="tab"
type="button"
>
<div
className="AriaInfo-root"
>
<span>
Tab:
</span>
</div>
Three
</button>
</li>
Expand Down

0 comments on commit 6945b13

Please sign in to comment.