Skip to content

Commit

Permalink
rebase
Browse files Browse the repository at this point in the history
+ i18n dup
+ fix tests
  • Loading branch information
bgptr committed Feb 7, 2022
1 parent 75c04ed commit 70c06ae
Show file tree
Hide file tree
Showing 7 changed files with 28 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const LoadingPage = ({ onShowOnboardingTutorial }) => {
className={styles.subtitle}
title={
<T
id="getstarted.tutorials.learnAboutDecred"
id="getstarted.loadingpage.learnAboutDecred"
m="Learn about decred"
/>
}
Expand Down
5 changes: 1 addition & 4 deletions app/components/views/LNPage/ConnectPage/ConnectPage.jsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
import { StandalonePage, StandaloneHeader } from "layout";
import { FormattedMessage as T } from "react-intl";
import {
PiUiPassphraseModalButton,
ToggleSwitch
} from "buttons";
import { PiUiPassphraseModalButton } from "buttons";
import { Tooltip } from "pi-ui";
import {
LNWALLET_STARTUPSTAGE_STARTDCRLND,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,23 @@ const CreationWarning = ({ onAcceptCreationWarning }) => {
);

return (
<>
<Documentation name="LNWalletCreationWarning" />
<KeyBlueButton onClick={onAcceptCreationWarning}>
<div className={styles.container}>
<Subtitle
className={styles.header}
title={<T id="ln.creationWarning.title" m="Before You continue..." />}>
<KeyBlueButton
onClick={onAcceptCreationWarning}
disabled={!isAcceptCreationWarningButtonEnabled}>
<T
id="ln.createWalletWarning.okBtn"
m="I understand and accept the risks"
/>
</KeyBlueButton>
</Subtitle>
<div className={styles.desc}>
<T
id="ln.createWalletWarning.okBtn"
m="I understand and accept the risks"
id="ln.creationWarning.desc"
m="Please understand that Lightning Network is still work in progress and should be used with caution. In particular:"
/>
</div>
<PagedTutorial
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const PagedTutorial = ({
activeTabIndex,
setActiveTabIndex,
className,
tabContentWrapperClassName
tabContentWrapperClassName,
onFinish
}) => {
useMountEffect(() => {
Expand Down Expand Up @@ -159,7 +159,7 @@ PagedTutorial.propTypes = {
activeTabIndex: PropTypes.number,
setActiveTabIndex: PropTypes.func.isRequired,
className: PropTypes.string,
tabContentWrapperClassName: PropTypes.string
tabContentWrapperClassName: PropTypes.string,
onFinish: PropTypes.func
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ const TutorialPage = ({
activeTabIndex,
setActiveTabIndex,
className: pagedTutorialClassname,
tabContentWrapperClassName
tabContentWrapperClassName,
onFinish: goBackHistory
}}
/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,10 +169,14 @@ test("click on settings link and go back", async () => {
await wait(() => screen.getByText(/welcome to decrediton/i));

user.click(screen.getByText(/settings/i));
await wait(() => screen.getByText(/connectivity/i));
await wait(() => screen.getByText("Connectivity"));

// go back
user.click(screen.getByText(/go back/i).nextElementSibling);
user.click(
screen.getByRole("button", {
name: "Go back"
})
);
await wait(() => screen.getByText(/welcome to decrediton/i));
});

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import PrivacyPage from "components/views/GetStartedPage/PrivacyPage/PrivacyPage";
import { PrivacyPage } from "components/views/GetStartedPage";
import { render } from "test-utils.js";
import { screen } from "@testing-library/react";
import user from "@testing-library/user-event";
Expand Down

0 comments on commit 70c06ae

Please sign in to comment.