pl-fe: more renyames
Signed-off-by: nicole mikołajczyk <git@mkljczk.pl>
This commit is contained in:
@ -148,7 +148,7 @@ const ComposeForm = <ID extends string>({ id, shouldCondense, autoFocus, clickab
|
||||
} = compose;
|
||||
|
||||
const hasPoll = !!compose.poll;
|
||||
const isEditing = compose.id !== null;
|
||||
const isEditing = compose.editedId !== null;
|
||||
const anyMedia = compose.mediaAttachments.length > 0;
|
||||
|
||||
const [composeFocused, setComposeFocused] = useState(false);
|
||||
|
||||
@ -140,7 +140,7 @@ const PrivacyDropdown: React.FC<IPrivacyDropdown> = ({
|
||||
const isReply = !!compose.inReplyToId;
|
||||
|
||||
const value = compose.visibility;
|
||||
const unavailable = compose.id;
|
||||
const unavailable = !!compose.editedId;
|
||||
|
||||
const onChange = (value: string) => value && dispatch(changeComposeVisibility(composeId,
|
||||
value));
|
||||
@ -162,7 +162,7 @@ const PrivacyDropdown: React.FC<IPrivacyDropdown> = ({
|
||||
text: intl.formatMessage(messages.local_short),
|
||||
meta: intl.formatMessage(messages.local_long),
|
||||
type: 'toggle',
|
||||
checked: compose.local_only,
|
||||
checked: compose.localOnly,
|
||||
onChange: () => dispatch(changeComposeFederated(composeId)),
|
||||
});
|
||||
|
||||
|
||||
@ -24,7 +24,7 @@ const ScheduleButton: React.FC<IScheduleButton> = ({ composeId, disabled }) => {
|
||||
const compose = useCompose(composeId);
|
||||
|
||||
const active = !!compose.scheduledAt;
|
||||
const unavailable = !!compose.id;
|
||||
const unavailable = !!compose.editedId;
|
||||
|
||||
const handleClick = () => {
|
||||
if (active) {
|
||||
|
||||
@ -15,7 +15,7 @@ const QuotedStatusContainer: React.FC<IQuotedStatusContainer> = ({ composeId })
|
||||
const dispatch = useAppDispatch();
|
||||
const getStatus = useCallback(makeGetStatus(), []);
|
||||
|
||||
const status = useAppSelector(state => getStatus(state, { id: state.compose[composeId]?.quote! }));
|
||||
const status = useAppSelector(state => getStatus(state, { id: state.compose[composeId]?.quoteId! }));
|
||||
|
||||
const onCancel = () => {
|
||||
dispatch(cancelQuoteCompose(composeId));
|
||||
|
||||
@ -15,7 +15,7 @@ interface IReplyIndicatorContainer {
|
||||
const ReplyIndicatorContainer: React.FC<IReplyIndicatorContainer> = ({ composeId }) => {
|
||||
const getStatus = useCallback(makeGetStatus(), []);
|
||||
|
||||
const { inReplyToId, id: statusId } = useCompose(composeId);
|
||||
const { inReplyToId, editedId } = useCompose(composeId);
|
||||
const status = useAppSelector(state => getStatus(state, { id: inReplyToId! }));
|
||||
const dispatch = useAppDispatch();
|
||||
|
||||
@ -26,7 +26,7 @@ const ReplyIndicatorContainer: React.FC<IReplyIndicatorContainer> = ({ composeId
|
||||
if (!status) return null;
|
||||
|
||||
return (
|
||||
<ReplyIndicator status={status} hideActions={!!statusId} onCancel={onCancel} />
|
||||
<ReplyIndicator status={status} hideActions={!!editedId} onCancel={onCancel} />
|
||||
);
|
||||
};
|
||||
|
||||
|
||||
@ -111,7 +111,7 @@ const StatePlugin: React.FC<IStatePlugin> = ({ composeId, isWysiwyg }) => {
|
||||
const state = getState();
|
||||
const compose = state.compose[composeId];
|
||||
|
||||
if (!features.quotePosts || compose?.quote) return;
|
||||
if (!features.quotePosts || compose?.quoteId) return;
|
||||
|
||||
const ids = getStatusIdsFromLinksInContent(text);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user