slightly improve channel edits

This commit is contained in:
Sean Yesmunt 2020-03-13 18:15:37 -04:00
parent d4d150bb39
commit c154db73fd
3 changed files with 10 additions and 6 deletions

View file

@ -30,7 +30,4 @@ const perform = dispatch => ({
updateChannel: params => dispatch(doUpdateChannel(params)), updateChannel: params => dispatch(doUpdateChannel(params)),
}); });
export default connect( export default connect(select, perform)(ChannelPage);
select,
perform
)(ChannelPage);

View file

@ -103,6 +103,7 @@ function ChannelForm(props: Props) {
updateChannel(params); updateChannel(params);
setEditing(false); setEditing(false);
}; };
// TODO clear and bail after submit // TODO clear and bail after submit
return ( return (
<section className={'card--section'}> <section className={'card--section'}>
@ -176,7 +177,7 @@ function ChannelForm(props: Props) {
<TagsSearch <TagsSearch
suggestMature suggestMature
disabledAutoFocus disableAutoFocus
tagsPassedIn={params.tags || []} tagsPassedIn={params.tags || []}
label={__('Tags Selected')} label={__('Tags Selected')}
onRemove={clickedTag => { onRemove={clickedTag => {

View file

@ -237,7 +237,13 @@ function ChannelPage(props: Props) {
)} )}
<h1 className="channel__title">{title || '@' + channelName}</h1> <h1 className="channel__title">{title || '@' + channelName}</h1>
{channelIsMine && !editing && ( {channelIsMine && !editing && (
<Button button="alt" title={__('Edit')} onClick={() => setEditing(!editing)} icon={ICONS.EDIT} /> <Button
button="alt"
title={__('Edit')}
onClick={() => setEditing(!editing)}
icon={ICONS.EDIT}
iconSize={28}
/>
)} )}
<div className="channel__meta"> <div className="channel__meta">
<span> <span>