Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Address rwd qa test issues #4661

Merged
merged 6 commits into from
Dec 4, 2023
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -209,8 +209,14 @@ const CandidateCardStakeAndControls = styled.div`
align-items: flex-end;
width: fit-content;
column-gap: 32px;
row-gap: 8px;
margin-top: auto;
flex-wrap: wrap;

@media (min-width: 1440px) {
flex-wrap: nowrap;
min-width: fit-content;
}
`

const CandidateCardStatistics = styled.div`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ export const StakeStep = ({ candidacyMember, minStake, errorChecker, errorMessag
name="staking.account"
minBalance={minStake}
lockType="Council Candidate"
variant={isMobile ? 's' : size === 'md' ? 'm' : 'l'}
variant={size === 'lg' ? 'l' : 's'}
/>
</InputComponent>
<RowGapBlock gap={8}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -149,4 +149,6 @@ const AboutInvite = styled.div`
display: flex;
justify-content: space-between;
width: 100%;
align-items: center;
gap: 8px;
`
1 change: 1 addition & 0 deletions packages/ui/src/memberships/components/MembersSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -86,4 +86,5 @@ const MembershipsGroup = styled.div`
const MembershipsHeaders = styled(ListHeaders)`
grid-area: accountstablenav;
grid-column-gap: 16px;
padding: 0 24px;
`
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,12 @@ import { RowGapBlock } from '@/common/components/page/PageContent'
import { NotFoundText } from '@/common/components/typography/NotFoundText'
import { GetSortProps } from '@/common/hooks/useSort'
import { useMyMemberships } from '@/memberships/hooks/useMyMemberships'
import { ProposalColLayout, ProposalsListHeaders, ProposalListHeader } from '@/proposals/constants'
import {
ProposalColLayout,
ProposalsListHeaders,
ProposalListHeader,
ProposalColLayoutWithVoteDetails,
} from '@/proposals/constants'
import { Proposal } from '@/proposals/types'

import { ProposalListItem } from './ProposalListItem'
Expand All @@ -35,7 +40,7 @@ export const ProposalList = ({ proposals, getSortProps, isPast, isLoading }: Pro

return (
<RowGapBlock gap={4}>
<ProposalsListHeaders $colLayout={ProposalColLayout}>
<ProposalsListHeaders $colLayout={isCouncilMember ? ProposalColLayoutWithVoteDetails : ProposalColLayout}>
{getSortProps ? <SortHeader {...getSortProps('title')}>Title</SortHeader> : <ProposalListHeader />}
<ProposalListHeader>Stage</ProposalListHeader>
<ProposalListHeader>Proposer</ProposalListHeader>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import { Colors, Overflow } from '@/common/constants'
import { camelCaseToText } from '@/common/helpers'
import { toDDMMYY } from '@/common/utils/dates'
import { MemberInfo } from '@/memberships/components'
import { ProposalColLayout } from '@/proposals/constants'
import { ProposalColLayout, ProposalColLayoutWithVoteDetails } from '@/proposals/constants'
import { ProposalsRoutes } from '@/proposals/constants/routes'
import { isProposalActive } from '@/proposals/model/proposalStatus'
import { Proposal } from '@/proposals/types'
Expand Down Expand Up @@ -61,7 +61,7 @@ export const ProposalListItem = ({ proposal, isPast, memberId, isCouncilMember }
<ProposalItem
as={GhostRouterLink}
to={generatePath(ProposalsRoutes.preview, { id: proposal.id })}
$colLayout={ProposalColLayout}
$colLayout={isCouncilMember ? ProposalColLayoutWithVoteDetails : ProposalColLayout}
$isPast={!isProposalActive(proposal.status)}
>
<FieldWrapper>
Expand Down
3 changes: 2 additions & 1 deletion packages/ui/src/proposals/constants/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ import styled from 'styled-components'

import { ListHeaders, ListHeader } from '@/common/components/List/ListHeader'

export const ProposalColLayout = '296px 148px 156px 60px 1fr'
export const ProposalColLayout = '296px 148px 156px 60px'
export const ProposalColLayoutWithVoteDetails = ProposalColLayout + ' 80px'
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't the 60px be removed ? Because this grid always seem to have an unused column.

For normal members:
image

For CMs:
image


export const ProposalsListHeaders = styled(ListHeaders)`
padding-right: 16px;
Expand Down