Minor visual improvements
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
This commit is contained in:
parent
7482d37f5c
commit
b57cecea8d
17 changed files with 28 additions and 29 deletions
|
@ -260,7 +260,7 @@ class AutosuggestTextarea extends ImmutablePureComponent<IAutosuggesteTextarea>
|
||||||
|
|
||||||
<Textarea
|
<Textarea
|
||||||
ref={this.setTextarea}
|
ref={this.setTextarea}
|
||||||
className={classNames('transition-[min-height] motion-reduce:transition-none dark:bg-slate-800 px-0 mt-1 border-0 text-gray-800 dark:text-white placeholder:text-gray-400 dark:placeholder:text-gray-500 resize-none w-full focus:shadow-none focus:border-0 focus:ring-0', {
|
className={classNames('transition-[min-height] motion-reduce:transition-none dark:bg-slate-800 px-0 border-0 text-gray-800 dark:text-white placeholder:text-gray-400 dark:placeholder:text-gray-500 resize-none w-full focus:shadow-none focus:border-0 focus:ring-0', {
|
||||||
'min-h-[40px]': condensed,
|
'min-h-[40px]': condensed,
|
||||||
'min-h-[100px]': !condensed,
|
'min-h-[100px]': !condensed,
|
||||||
})}
|
})}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import React, { useEffect, useRef, useState } from 'react';
|
import React, { useEffect, useState } from 'react';
|
||||||
import { FormattedMessage } from 'react-intl';
|
import { FormattedMessage } from 'react-intl';
|
||||||
import { useParams } from 'react-router-dom';
|
import { useParams } from 'react-router-dom';
|
||||||
|
|
||||||
|
@ -66,8 +66,11 @@ const AccountGallery = () => {
|
||||||
const isLoading = useAppSelector((state) => state.timelines.get(`account:${accountId}:media`)?.isLoading);
|
const isLoading = useAppSelector((state) => state.timelines.get(`account:${accountId}:media`)?.isLoading);
|
||||||
const hasMore = useAppSelector((state) => state.timelines.get(`account:${accountId}:media`)?.hasMore);
|
const hasMore = useAppSelector((state) => state.timelines.get(`account:${accountId}:media`)?.hasMore);
|
||||||
|
|
||||||
const ref = useRef<HTMLDivElement>(null);
|
const [width, setWidth] = useState(323);
|
||||||
const [width] = useState(323);
|
|
||||||
|
const handleRef = (c: HTMLDivElement) => {
|
||||||
|
if (c) setWidth(c.offsetWidth);
|
||||||
|
};
|
||||||
|
|
||||||
const handleScrollToBottom = () => {
|
const handleScrollToBottom = () => {
|
||||||
if (hasMore) {
|
if (hasMore) {
|
||||||
|
@ -138,7 +141,7 @@ const AccountGallery = () => {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Column label={`@${accountUsername}`} transparent withHeader={false}>
|
<Column label={`@${accountUsername}`} transparent withHeader={false}>
|
||||||
<div role='feed' className='account-gallery__container' ref={ref}>
|
<div role='feed' className='account-gallery__container' ref={handleRef}>
|
||||||
{attachments.map((attachment, index) => attachment === null ? (
|
{attachments.map((attachment, index) => attachment === null ? (
|
||||||
<LoadMoreMedia key={'more:' + attachments.get(index + 1)?.id} maxId={index > 0 ? (attachments.get(index - 1)?.id || null) : null} onLoadMore={handleLoadMore} />
|
<LoadMoreMedia key={'more:' + attachments.get(index + 1)?.id} maxId={index > 0 ? (attachments.get(index - 1)?.id || null) : null} onLoadMore={handleLoadMore} />
|
||||||
) : (
|
) : (
|
||||||
|
|
|
@ -25,7 +25,7 @@ const LoginForm: React.FC<ILoginForm> = ({ isLoading, handleSubmit }) => {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 border-solid -mx-4 sm:-mx-10'>
|
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 dark:border-gray-600 border-solid -mx-4 sm:-mx-10'>
|
||||||
<h1 className='text-center font-bold text-2xl'><FormattedMessage id='login_form.header' defaultMessage='Sign In' /></h1>
|
<h1 className='text-center font-bold text-2xl'><FormattedMessage id='login_form.header' defaultMessage='Sign In' /></h1>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
|
@ -48,7 +48,7 @@ const OtpAuthForm: React.FC<IOtpAuthForm> = ({ mfa_token }) => {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 border-solid -mx-4 sm:-mx-10'>
|
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 dark:border-gray-600 border-solid -mx-4 sm:-mx-10'>
|
||||||
<h1 className='text-center font-bold text-2xl'>
|
<h1 className='text-center font-bold text-2xl'>
|
||||||
<FormattedMessage id='login.otp_log_in' defaultMessage='OTP Login' />
|
<FormattedMessage id='login.otp_log_in' defaultMessage='OTP Login' />
|
||||||
</h1>
|
</h1>
|
||||||
|
|
|
@ -58,7 +58,7 @@ const PasswordResetConfirm = () => {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 border-solid -mx-4 sm:-mx-10'>
|
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 dark:border-gray-600 border-solid -mx-4 sm:-mx-10'>
|
||||||
<h1 className='text-center font-bold text-2xl'>
|
<h1 className='text-center font-bold text-2xl'>
|
||||||
<FormattedMessage id='reset_password.header' defaultMessage='Set New Password' />
|
<FormattedMessage id='reset_password.header' defaultMessage='Set New Password' />
|
||||||
</h1>
|
</h1>
|
||||||
|
|
|
@ -11,7 +11,7 @@ import { length } from 'stringz';
|
||||||
import AutosuggestInput from 'soapbox/components/autosuggest_input';
|
import AutosuggestInput from 'soapbox/components/autosuggest_input';
|
||||||
import AutosuggestTextarea from 'soapbox/components/autosuggest_textarea';
|
import AutosuggestTextarea from 'soapbox/components/autosuggest_textarea';
|
||||||
import Icon from 'soapbox/components/icon';
|
import Icon from 'soapbox/components/icon';
|
||||||
import { Button } from 'soapbox/components/ui';
|
import { Button, Stack } from 'soapbox/components/ui';
|
||||||
import { isMobile } from 'soapbox/is_mobile';
|
import { isMobile } from 'soapbox/is_mobile';
|
||||||
|
|
||||||
import PollForm from '../components/polls/poll-form';
|
import PollForm from '../components/polls/poll-form';
|
||||||
|
@ -290,7 +290,7 @@ class ComposeForm extends ImmutablePureComponent {
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className='w-full' ref={this.setForm} onClick={this.handleClick}>
|
<Stack className='w-full' space={1} ref={this.setForm} onClick={this.handleClick}>
|
||||||
{scheduledStatusCount > 0 && (
|
{scheduledStatusCount > 0 && (
|
||||||
<Warning
|
<Warning
|
||||||
message={(
|
message={(
|
||||||
|
@ -335,7 +335,7 @@ class ComposeForm extends ImmutablePureComponent {
|
||||||
onSuggestionSelected={this.onSpoilerSuggestionSelected}
|
onSuggestionSelected={this.onSpoilerSuggestionSelected}
|
||||||
searchTokens={[':']}
|
searchTokens={[':']}
|
||||||
id='cw-spoiler-input'
|
id='cw-spoiler-input'
|
||||||
className='mb-2 border-none shadow-none px-0 py-2 text-base'
|
className='border-none shadow-none px-0 py-2 text-base'
|
||||||
autoFocus
|
autoFocus
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
@ -395,7 +395,7 @@ class ComposeForm extends ImmutablePureComponent {
|
||||||
<Button theme='primary' text={publishText} onClick={this.handleSubmit} disabled={disabledButton} />
|
<Button theme='primary' text={publishText} onClick={this.handleSubmit} disabled={disabledButton} />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</Stack>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -60,6 +60,9 @@ const SuggestionItem = ({ accountId }: { accountId: string }) => {
|
||||||
const FeedSuggestions = () => {
|
const FeedSuggestions = () => {
|
||||||
const intl = useIntl();
|
const intl = useIntl();
|
||||||
const suggestedProfiles = useAppSelector((state) => state.suggestions.items);
|
const suggestedProfiles = useAppSelector((state) => state.suggestions.items);
|
||||||
|
const isLoading = useAppSelector((state) => state.suggestions.isLoading);
|
||||||
|
|
||||||
|
if (!isLoading && suggestedProfiles.size === 0) return null;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Card size='lg' variant='rounded'>
|
<Card size='lg' variant='rounded'>
|
||||||
|
|
|
@ -45,7 +45,7 @@ const BioStep = ({ onNext }: { onNext: () => void }) => {
|
||||||
<Card variant='rounded' size='xl'>
|
<Card variant='rounded' size='xl'>
|
||||||
<CardBody>
|
<CardBody>
|
||||||
<div>
|
<div>
|
||||||
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 border-solid -mx-4 sm:-mx-10'>
|
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 dark:border-gray-600 border-solid -mx-4 sm:-mx-10'>
|
||||||
<Stack space={2}>
|
<Stack space={2}>
|
||||||
<Text size='2xl' align='center' weight='bold'>
|
<Text size='2xl' align='center' weight='bold'>
|
||||||
<FormattedMessage id='onboarding.note.title' defaultMessage='Write a short bio' />
|
<FormattedMessage id='onboarding.note.title' defaultMessage='Write a short bio' />
|
||||||
|
|
|
@ -75,7 +75,7 @@ const CoverPhotoSelectionStep = ({ onNext }: { onNext: () => void }) => {
|
||||||
<Card variant='rounded' size='xl'>
|
<Card variant='rounded' size='xl'>
|
||||||
<CardBody>
|
<CardBody>
|
||||||
<div>
|
<div>
|
||||||
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 border-solid -mx-4 sm:-mx-10'>
|
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 dark:border-gray-600 border-solid -mx-4 sm:-mx-10'>
|
||||||
<Stack space={2}>
|
<Stack space={2}>
|
||||||
<Text size='2xl' align='center' weight='bold'>
|
<Text size='2xl' align='center' weight='bold'>
|
||||||
<FormattedMessage id='onboarding.header.title' defaultMessage='Pick a cover image' />
|
<FormattedMessage id='onboarding.header.title' defaultMessage='Pick a cover image' />
|
||||||
|
|
|
@ -52,7 +52,7 @@ const DisplayNameStep = ({ onNext }: { onNext: () => void }) => {
|
||||||
<Card variant='rounded' size='xl'>
|
<Card variant='rounded' size='xl'>
|
||||||
<CardBody>
|
<CardBody>
|
||||||
<div>
|
<div>
|
||||||
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 border-solid -mx-4 sm:-mx-10'>
|
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 dark:border-gray-600 border-solid -mx-4 sm:-mx-10'>
|
||||||
<Stack space={2}>
|
<Stack space={2}>
|
||||||
<Text size='2xl' align='center' weight='bold'>
|
<Text size='2xl' align='center' weight='bold'>
|
||||||
<FormattedMessage id='onboarding.display_name.title' defaultMessage='Choose a display name' />
|
<FormattedMessage id='onboarding.display_name.title' defaultMessage='Choose a display name' />
|
||||||
|
|
|
@ -76,7 +76,7 @@ const SuggestedAccountsStep = ({ onNext }: { onNext: () => void }) => {
|
||||||
<Card variant='rounded' size='xl'>
|
<Card variant='rounded' size='xl'>
|
||||||
<CardBody>
|
<CardBody>
|
||||||
<div>
|
<div>
|
||||||
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 border-solid -mx-4 sm:-mx-10'>
|
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 dark:border-gray-600 border-solid -mx-4 sm:-mx-10'>
|
||||||
<Stack space={2}>
|
<Stack space={2}>
|
||||||
<Text size='2xl' align='center' weight='bold'>
|
<Text size='2xl' align='center' weight='bold'>
|
||||||
<FormattedMessage id='onboarding.suggestions.title' defaultMessage='Suggested accounts' />
|
<FormattedMessage id='onboarding.suggestions.title' defaultMessage='Suggested accounts' />
|
||||||
|
|
|
@ -139,7 +139,7 @@ const StatusInteractionBar: React.FC<IStatusInteractionBar> = ({ status }): JSX.
|
||||||
return (
|
return (
|
||||||
<HStack space={0.5} className='emoji-react p-1' alignItems='center' key={i}>
|
<HStack space={0.5} className='emoji-react p-1' alignItems='center' key={i}>
|
||||||
<Emoji
|
<Emoji
|
||||||
className='emoji-react__emoji w-5 h-5 flex-none'
|
className='emoji-react__emoji w-5 h-5 flex-none cursor-pointer'
|
||||||
emoji={e.get('name')}
|
emoji={e.get('name')}
|
||||||
onClick={features.exposableReactions ? handleOpenReactionsModal(e) : undefined}
|
onClick={features.exposableReactions ? handleOpenReactionsModal(e) : undefined}
|
||||||
/>
|
/>
|
||||||
|
|
|
@ -94,7 +94,7 @@ const Registration = () => {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 border-solid -mx-4 sm:-mx-10'>
|
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 dark:border-gray-600 border-solid -mx-4 sm:-mx-10'>
|
||||||
<h1 className='text-center font-bold text-2xl'>
|
<h1 className='text-center font-bold text-2xl'>
|
||||||
<FormattedMessage id='registration.header' defaultMessage='Register your account' />
|
<FormattedMessage id='registration.header' defaultMessage='Register your account' />
|
||||||
</h1>
|
</h1>
|
||||||
|
|
|
@ -50,7 +50,7 @@ const AgeVerification = () => {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 border-solid -mx-4 sm:-mx-10'>
|
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 dark:border-gray-600 border-solid -mx-4 sm:-mx-10'>
|
||||||
<h1 className='text-center font-bold text-2xl'>
|
<h1 className='text-center font-bold text-2xl'>
|
||||||
<FormattedMessage id='age_verification.header' defaultMessage='Enter your birth date' />
|
<FormattedMessage id='age_verification.header' defaultMessage='Enter your birth date' />
|
||||||
</h1>
|
</h1>
|
||||||
|
|
|
@ -108,7 +108,7 @@ const EmailVerification = () => {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 border-solid -mx-4 sm:-mx-10'>
|
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 dark:border-gray-600 border-solid -mx-4 sm:-mx-10'>
|
||||||
<h1 className='text-center font-bold text-2xl'>{intl.formatMessage({ id: 'email_verification.header', defaultMessage: 'Enter your email address' })}</h1>
|
<h1 className='text-center font-bold text-2xl'>{intl.formatMessage({ id: 'email_verification.header', defaultMessage: 'Enter your email address' })}</h1>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
|
@ -95,7 +95,7 @@ const SmsVerification = () => {
|
||||||
if (status === Statuses.REQUESTED) {
|
if (status === Statuses.REQUESTED) {
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 border-solid -mx-4 sm:-mx-10'>
|
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 dark:border-gray-600 border-solid -mx-4 sm:-mx-10'>
|
||||||
<h1 className='text-center font-bold text-2xl'>
|
<h1 className='text-center font-bold text-2xl'>
|
||||||
{intl.formatMessage({ id: 'sms_verification.sent.header', defaultMessage: 'Verification code' })}
|
{intl.formatMessage({ id: 'sms_verification.sent.header', defaultMessage: 'Verification code' })}
|
||||||
</h1>
|
</h1>
|
||||||
|
@ -135,7 +135,7 @@ const SmsVerification = () => {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 border-solid -mx-4 sm:-mx-10'>
|
<div className='pb-4 sm:pb-10 mb-4 border-b border-gray-200 dark:border-gray-600 border-solid -mx-4 sm:-mx-10'>
|
||||||
<h1 className='text-center font-bold text-2xl'>{intl.formatMessage({ id: 'sms_verification.header', defaultMessage: 'Enter your phone number' })}</h1>
|
<h1 className='text-center font-bold text-2xl'>{intl.formatMessage({ id: 'sms_verification.header', defaultMessage: 'Enter your phone number' })}</h1>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
|
@ -67,13 +67,6 @@
|
||||||
.account__avatar-wrapper {
|
.account__avatar-wrapper {
|
||||||
float: left;
|
float: left;
|
||||||
margin-right: 12px;
|
margin-right: 12px;
|
||||||
|
|
||||||
.emoji-react__emoji {
|
|
||||||
position: absolute;
|
|
||||||
top: 36px;
|
|
||||||
left: 32px;
|
|
||||||
z-index: 1;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.account__avatar {
|
.account__avatar {
|
||||||
|
|
Loading…
Reference in a new issue