0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-03-29 01:18:11 +00:00

add small text

This commit is contained in:
Víctor Losada Hernández
2026-02-17 10:09:44 +01:00
parent dec91cc76e
commit bf8c866a74
4 changed files with 15 additions and 134 deletions

View File

@@ -339,9 +339,12 @@ const MetadataEditor = createReactClass({
{this.renderThumbnail()}
</div>
<TagInput label='tags' valuePatterns={/^(?:(?:group|meta|system|type):)?[A-Za-z0-9][A-Za-z0-9 \/.\-]{0,40}$/}
<TagInput
label='tags'
valuePatterns={/^(?:(?:group|meta|system|type):)?[A-Za-z0-9][A-Za-z0-9 \/.&_\-]{0,40}$/}
placeholder='add tag' unique={true}
values={this.props.metadata.tags}
smallText='You may start tags with "type", "system", "group" or "meta" followed by a colon ":", these will be colored in your userpage.'
onChange={(e)=>this.handleFieldChange('tags', e)}
/>
@@ -355,11 +358,13 @@ const MetadataEditor = createReactClass({
{this.renderAuthors()}
<TagInput label='invited authors' valuePatterns={/.+/}
<TagInput
label='invited authors'
valuePatterns={/.+/}
validators={[(v)=>!this.props.metadata.authors?.includes(v)]}
placeholder='invite author' unique={true}
values={this.props.metadata.invitedAuthors}
notes={['Invited author usernames are case sensitive.', 'After adding an invited author, send them the edit link. There, they can choose to accept or decline the invitation.']}
smallText='Invited author usernames are case sensitive. After adding an invited author, send them the edit link. There, they can choose to accept or decline the invitation.'
onChange={(e)=>this.handleFieldChange('invitedAuthors', e)}
/>