Skip to content
This repository has been archived by the owner on Mar 23, 2023. It is now read-only.

Commit

Permalink
feat: add my registrations (#2292)
Browse files Browse the repository at this point in the history
  • Loading branch information
clucasalcantara committed Jun 30, 2020
1 parent da844ee commit 9a7b9e3
Show file tree
Hide file tree
Showing 44 changed files with 3,912 additions and 73 deletions.
4 changes: 4 additions & 0 deletions src/app/assets/svg/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ import { ReactComponent as Profile } from "./profile.svg";
import { ReactComponent as Qrcode } from "./qrcode.svg";
import { ReactComponent as Receive } from "./receive.svg";
import { ReactComponent as Received } from "./received.svg";
import { ReactComponent as Redirect } from "./redirect.svg";
import { ReactComponent as RegistrationsIllustration } from "./register.svg";
import { ReactComponent as ReplyArrow } from "./reply-arrow.svg";
import { ReactComponent as Reset } from "./reset.svg";
import { ReactComponent as Search } from "./search.svg";
Expand Down Expand Up @@ -129,8 +131,10 @@ export const SvgCollection: any = {
Qrcode,
Receive,
Received,
Redirect,
ReplyArrow,
Reset,
RegistrationsIllustration,
Search,
Send,
Sent,
Expand Down
1 change: 1 addition & 0 deletions src/app/assets/svg/redirect.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions src/app/assets/svg/register.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
exports[`Avatar should render 1`] = `
<DocumentFragment>
<div
class="Avatar__AvatarStyled-yiil9n-0 fympLW"
class="Avatar__AvatarStyled-sc-1vsy2s2-0 jZYOhz"
data-testid="Avatar"
/>
</DocumentFragment>
Expand All @@ -12,7 +12,7 @@ exports[`Avatar should render 1`] = `
exports[`Avatar should render with custom size 1`] = `
<DocumentFragment>
<div
class="Avatar__AvatarStyled-yiil9n-0 clAjq"
class="Avatar__AvatarStyled-sc-1vsy2s2-0 kySuJj"
data-testid="Avatar"
/>
</DocumentFragment>
Expand All @@ -21,7 +21,7 @@ exports[`Avatar should render with custom size 1`] = `
exports[`Avatar should render without shadow 1`] = `
<DocumentFragment>
<div
class="Avatar__AvatarStyled-yiil9n-0 jrvbgl"
class="Avatar__AvatarStyled-sc-1vsy2s2-0 bnuliI"
data-testid="Avatar"
/>
</DocumentFragment>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ exports[`AddressList should render 1`] = `
class="py-5"
>
<div
class="Avatar__AvatarStyled-yiil9n-0 fympLW"
class="Avatar__AvatarStyled-sc-1vsy2s2-0 jZYOhz"
data-testid="Avatar"
/>
</td>
Expand Down Expand Up @@ -315,7 +315,7 @@ exports[`AddressList should render 1`] = `
class="py-5"
>
<div
class="Avatar__AvatarStyled-yiil9n-0 fympLW"
class="Avatar__AvatarStyled-sc-1vsy2s2-0 jZYOhz"
data-testid="Avatar"
/>
</td>
Expand Down Expand Up @@ -397,7 +397,7 @@ exports[`AddressList should render 1`] = `
class="py-5"
>
<div
class="Avatar__AvatarStyled-yiil9n-0 fympLW"
class="Avatar__AvatarStyled-sc-1vsy2s2-0 jZYOhz"
data-testid="Avatar"
/>
</td>
Expand Down Expand Up @@ -441,7 +441,7 @@ exports[`AddressList should render 1`] = `
class="py-5"
>
<div
class="Avatar__AvatarStyled-yiil9n-0 fympLW"
class="Avatar__AvatarStyled-sc-1vsy2s2-0 jZYOhz"
data-testid="Avatar"
/>
</td>
Expand Down Expand Up @@ -503,7 +503,7 @@ exports[`AddressList should render 1`] = `
class="py-5"
>
<div
class="Avatar__AvatarStyled-yiil9n-0 fympLW"
class="Avatar__AvatarStyled-sc-1vsy2s2-0 jZYOhz"
data-testid="Avatar"
/>
</td>
Expand Down Expand Up @@ -578,7 +578,7 @@ exports[`AddressList should render 1`] = `
class="py-5"
>
<div
class="Avatar__AvatarStyled-yiil9n-0 fympLW"
class="Avatar__AvatarStyled-sc-1vsy2s2-0 jZYOhz"
data-testid="Avatar"
/>
</td>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { Address } from "app/components/Address";
import { Avatar } from "app/components/Avatar";
import { Button } from "app/components/Button";
import { Circle } from "app/components/Circle";
import { Icon } from "app/components/Icon";
import { Avatar } from "domains/wallet/components/Avatar";
import React from "react";
import { useTranslation } from "react-i18next";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ exports[`AddressListItem should emit action on select button 1`] = `
class="py-5"
>
<div
class="Avatar__AvatarStyled-yiil9n-0 fympLW"
class="Avatar__AvatarStyled-sc-1vsy2s2-0 jZYOhz"
data-testid="Avatar"
/>
</td>
Expand Down Expand Up @@ -61,7 +61,7 @@ exports[`AddressListItem should emit action on select button 1`] = `
class="py-5"
>
<div
class="Avatar__AvatarStyled-yiil9n-0 fympLW"
class="Avatar__AvatarStyled-sc-1vsy2s2-0 jZYOhz"
data-testid="Avatar"
/>
</td>
Expand Down Expand Up @@ -152,7 +152,7 @@ exports[`AddressListItem should render 1`] = `
class="py-5"
>
<div
class="Avatar__AvatarStyled-yiil9n-0 fympLW"
class="Avatar__AvatarStyled-sc-1vsy2s2-0 jZYOhz"
data-testid="Avatar"
/>
</td>
Expand Down Expand Up @@ -202,7 +202,7 @@ exports[`AddressListItem should render 1`] = `
class="py-5"
>
<div
class="Avatar__AvatarStyled-yiil9n-0 fympLW"
class="Avatar__AvatarStyled-sc-1vsy2s2-0 jZYOhz"
data-testid="Avatar"
/>
</td>
Expand Down
14 changes: 7 additions & 7 deletions src/domains/myvote/components/DelegateList/DelegateList.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { Avatar } from "app/components/Avatar";
import { Button } from "app/components/Button";
import { Circle } from "app/components/Circle";
import { Table } from "app/components/Table";
import { Avatar } from "domains/wallet/components/Avatar";
import React, { useState } from "react";
import { useTranslation } from "react-i18next";

Expand All @@ -18,7 +18,7 @@ const SelectedDelegateList = ({ delegates, className }: { delegates: any[]; clas
output.push(
<div
key={delegate.username}
className="flex items-center py-4 font-semibold border-b border-dashed border-theme-neutral-200 last:border-0"
className="border-theme-neutral-200 last:border-0 flex items-center py-4 font-semibold border-b border-dashed"
>
<div className="flex flex-1">
<Avatar address={delegate.address} className="mr-8" />
Expand Down Expand Up @@ -46,7 +46,7 @@ const DelegateAvatarList = ({ delegates, limit }: { delegates: any[]; limit: num
<Circle
data-testid="DelegateAvatarList__avatar-list__rest"
size="large"
className="text-lg font-bold bg-theme-background border-theme-neutral-200 text-theme-primary-700"
className="bg-theme-background border-theme-neutral-200 text-theme-primary-700 text-lg font-bold"
>
+{rest}
</Circle>
Expand Down Expand Up @@ -128,8 +128,8 @@ export const DelegateList = (props: DelegateListProps) => {
data-testid="DelegateList__footer"
>
<div className="flex">
<div className="px-8 mr-8 font-semibold border-r border-theme-neutral-300">
<div className="text-sm text-theme-neutral-500">{t("COMMON.QUANTITY")}</div>
<div className="border-theme-neutral-300 px-8 mr-8 font-semibold border-r">
<div className="text-theme-neutral-500 text-sm">{t("COMMON.QUANTITY")}</div>
<div className="text-theme-neutral-700">{selected.length}/50</div>
</div>

Expand All @@ -141,7 +141,7 @@ export const DelegateList = (props: DelegateListProps) => {
<div className="inline-flex">
<Avatar address={selected[0].address} className="mr-4" />
<div className="flex flex-col">
<div className="text-sm text-theme-neutral-700">
<div className="text-theme-neutral-700 text-sm">
Address Delegate
</div>
<div className="text-theme-neutral-500">
Expand All @@ -155,7 +155,7 @@ export const DelegateList = (props: DelegateListProps) => {
<DelegateAvatarList delegates={selected} limit={2} />
<div
data-testid="DelegateList__toggle-show-selected"
className="ml-4 cursor-pointer text-theme-primary-700 hover:text-theme-primary-500"
className="text-theme-primary-700 hover:text-theme-primary-500 ml-4 cursor-pointer"
onClick={() => setShowSelectedList(!showSelectedList)}
>
{showSelectedList ? "Hide" : "Show"} List
Expand Down

0 comments on commit 9a7b9e3

Please sign in to comment.