RostislavLitovkin / PlutoWallet

Multi-platform mobile wallet for substrate-based chains. Focuses on the best UX. First C# mobile wallet in Polkadot ecosystem.
MIT License
16 stars 9 forks source link

Add `MnemonicsExplanationPage` #70

Open RostislavLitovkin opened 2 months ago

RostislavLitovkin commented 2 months ago

1) Fork PlutoWallet repo 2) Switch to devel branch 3) Create a new branch called MnemonicsExplanationPage 4) In PlutoWallet/Components/Mnemonics/ folder, create a new ContentPage and name it MnemonicsExplanationPage.xaml 5) Use the following xaml code as template for the page:

<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
             x:Class="PlutoWallet.Components.Extrinsic.ExtrinsicDetailPage"
             xmlns:navigationbar="clr-namespace:PlutoWallet.Components.NavigationBar"
             xmlns:confirmtransaction="clr-namespace:PlutoWallet.Components.ConfirmTransaction"             Title="MnemonicsExplanationPage"
         BackgroundColor="Black">
    <AbsoluteLayout AbsoluteLayout.LayoutBounds="0.5, 0.5, 1, 1" AbsoluteLayout.LayoutFlags="All">

        <Image AbsoluteLayout.LayoutBounds="0.5, 0.5, 1, 1" AbsoluteLayout.LayoutFlags="All"
           Source="{AppThemeBinding Light=whitebackground.png, Dark=darkbackground2.png}"
           Opacity="{AppThemeBinding Light=0.96}"
           Aspect="AspectFill"/>

        <ScrollView Orientation="Vertical"
                x:Name="scrollView"
                AbsoluteLayout.LayoutBounds="0.5, 0.5, 1, 1"
                AbsoluteLayout.LayoutFlags="All"
                Padding="0, 55, 0, 0">
            <!--
            Put content here
            -->

        </ScrollView>

        <navigationbar:TopNavigationBar Title="Title of the page"
                                    x:Name="topNavigationBar" />

        <confirmtransaction:ConfirmTransactionView />

    </AbsoluteLayout>

</ContentPage>

This will setup the correct background image, etc..

6) Add the following 2 lines to the constructor:

public MnemonicsExplanationPage()
{
    NavigationPage.SetHasNavigationBar(this, false);
    Shell.SetNavBarIsVisible(this, false);

    InitializeComponent();
}

7) Fill the content of the page. Be sure to use the custom Card element. 8) Add a button to PlutoWallet/View/MnemonicsPage.xaml which will navigate the user to the MnemonicsExplanationPage 9) Make PR

RostislavLitovkin commented 2 months ago

Content of the page:

What are Mnemonics?

Mnemonics, also known as seed phrases or recovery phrases, are a series of 12 words that represent the private key of your cryptocurrency wallet. These phrases are crucial because they allow you to recover your wallet and access your funds if you lose your device or forget your password.

How to Store Mnemonics Safely

  1. Write it Down on Paper and store it in a secure place where you will not lose it. Potentionally consider creating multiple copies.

  2. Do not store your mnemonic phrase in cloud storage, email, or any online service. These platforms are vulnerable to cyber-attacks, which could compromise your mnemonic phrase.

  3. Never share your mnemonic phrase with anyone. Possession of the mnemonic phrase means full control over your wallet and its funds.

  4. Never enter the mnemonic phrase into any website/application, even if they ask you. Be wary of phishing attempts and scams that may try to trick you into revealing your phrase.

Source: https://support.polkadot.network/support/solutions/articles/65000110873-glossary