mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-14 14:21:23 +00:00
[select-editor, link details] fixup: display the current option rightly for the 'select-editor'; removed ':' after 'Permission' for 'link details' (#6465)
This commit is contained in:
@@ -107,8 +107,6 @@ class SelectEditor extends React.Component {
|
||||
|
||||
render() {
|
||||
let { currentOption, isTextMode } = this.props;
|
||||
// scence1: isTextMode (text)editor-icon --> select
|
||||
// scence2: !isTextMode select
|
||||
return (
|
||||
<div className="permission-editor" onClick={this.onSelectHandler}>
|
||||
{(!isTextMode || this.state.isEditing) &&
|
||||
@@ -116,8 +114,7 @@ class SelectEditor extends React.Component {
|
||||
options={this.state.options}
|
||||
className="permission-editor-select"
|
||||
classNamePrefix="permission-editor"
|
||||
placeholder={this.props.translateOption(currentOption)}
|
||||
value={currentOption}
|
||||
value={this.state.options.filter(item => item.value == currentOption)[0]}
|
||||
onChange={this.onOptionChanged}
|
||||
captureMenuScroll={false}
|
||||
menuPlacement="auto"
|
||||
|
@@ -251,7 +251,7 @@ class LinkDetails extends React.Component {
|
||||
)}
|
||||
{sharedLinkInfo.permissions && (
|
||||
<>
|
||||
<dt className="text-secondary font-weight-normal">{gettext('Permission:')}</dt>
|
||||
<dt className="text-secondary font-weight-normal">{gettext('Permission')}</dt>
|
||||
<dd>
|
||||
<div className="w-50">
|
||||
<SelectEditor
|
||||
|
Reference in New Issue
Block a user