mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-22 20:08:19 +00:00
fix code format (#6365)
This commit is contained in:
@@ -81,7 +81,7 @@ class EditFileTagPopover extends React.Component {
|
||||
} else {
|
||||
let fileTag = null;
|
||||
let fileTagList = this.props.fileTagList;
|
||||
for(let i = 0; i < fileTagList.length; i++) {
|
||||
for (let i = 0; i < fileTagList.length; i++) {
|
||||
if (fileTagList[i].repo_tag_id === repoTag.id) {
|
||||
fileTag = fileTagList[i];
|
||||
break;
|
||||
|
@@ -36,7 +36,7 @@ class TagItem extends React.Component {
|
||||
} else {
|
||||
let fileTag = null;
|
||||
let fileTagList = this.props.fileTagList;
|
||||
for(let i = 0; i < fileTagList.length; i++) {
|
||||
for (let i = 0; i < fileTagList.length; i++) {
|
||||
if (fileTagList[i].repo_tag_id === repoTag.id) {
|
||||
fileTag = fileTagList[i];
|
||||
break;
|
||||
@@ -63,7 +63,7 @@ class TagItem extends React.Component {
|
||||
onMouseEnter={this.onMouseEnter}
|
||||
onMouseLeave={this.onMouseLeave}
|
||||
>
|
||||
<div className="tag-item d-flex align-items-center" style={{backgroundColor: repoTag.color}}>
|
||||
<div className="tag-item d-flex align-items-center" style={{ backgroundColor: repoTag.color }}>
|
||||
<span className="tag-name">{repoTag.name}</span>
|
||||
</div>
|
||||
{isTagSelected && <i className="sf2-icon-tick tag-selected-icon"></i>}
|
||||
|
@@ -24,7 +24,7 @@ export default class TagListFooter extends Component {
|
||||
}
|
||||
|
||||
toggleTooltip = () => {
|
||||
this.setState({showTooltip: !this.state.showTooltip});
|
||||
this.setState({ showTooltip: !this.state.showTooltip });
|
||||
};
|
||||
|
||||
onClickImport = () => {
|
||||
@@ -109,10 +109,10 @@ export default class TagListFooter extends Component {
|
||||
render() {
|
||||
return (
|
||||
<div className="tag-list-footer">
|
||||
<span className="sf3-font sf3-font-tips mr-2" style={{color: '#999'}} id="import-export-tags-tip"></span>
|
||||
<span className="sf3-font sf3-font-tips mr-2" style={{ color: '#999' }} id="import-export-tags-tip"></span>
|
||||
<Tooltip
|
||||
toggle={this.toggleTooltip}
|
||||
delay={{show: 0, hide: 0}}
|
||||
delay={{ show: 0, hide: 0 }}
|
||||
target='import-export-tags-tip'
|
||||
placement='bottom'
|
||||
isOpen={this.state.showTooltip}
|
||||
|
@@ -10,7 +10,7 @@ import './list-tag-popover.css';
|
||||
const tagListItemPropTypes = {
|
||||
item: PropTypes.object.isRequired,
|
||||
repoID: PropTypes.string.isRequired,
|
||||
onDeleteTag : PropTypes.func.isRequired
|
||||
onDeleteTag: PropTypes.func.isRequired
|
||||
};
|
||||
|
||||
class TagListItem extends React.Component {
|
||||
@@ -54,7 +54,8 @@ class TagListItem extends React.Component {
|
||||
onClick={this.deleteTag}
|
||||
aria-label={gettext('Delete')}
|
||||
title={gettext('Delete')}
|
||||
></button>
|
||||
>
|
||||
</button>
|
||||
</li>
|
||||
);
|
||||
}
|
||||
|
@@ -60,7 +60,7 @@ export default class VirtualTagColor extends React.Component {
|
||||
<span
|
||||
id={`tag-${id}-color`}
|
||||
className="tag-color cursor-pointer rounded-circle d-flex align-items-center justify-content-center"
|
||||
style={{backgroundColor: tagColor}}
|
||||
style={{ backgroundColor: tagColor }}
|
||||
onClick={this.togglePopover}
|
||||
>
|
||||
<i className="sf3-font sf3-font-down text-white"></i>
|
||||
@@ -74,12 +74,12 @@ export default class VirtualTagColor extends React.Component {
|
||||
>
|
||||
<PopoverBody className="p-2">
|
||||
<div className="d-flex justify-content-between">
|
||||
{colorList.map((item, index)=>{
|
||||
{colorList.map((item, index) => {
|
||||
return (
|
||||
<div key={index} className="tag-color-option mx-1">
|
||||
<label className="colorinput">
|
||||
<input name="color" type="radio" value={item} className="colorinput-input" defaultChecked={item == tagColor} onClick={this.selectTagColor} />
|
||||
<span className="colorinput-color rounded-circle d-flex align-items-center justify-content-center" style={{backgroundColor: item}}>
|
||||
<span className="colorinput-color rounded-circle d-flex align-items-center justify-content-center" style={{ backgroundColor: item }}>
|
||||
<i className="sf2-icon-tick color-selected"></i>
|
||||
</span>
|
||||
</label>
|
||||
|
@@ -51,7 +51,8 @@ export default class VirtualTagListItem extends React.Component {
|
||||
onClick={this.deleteVirtualTag}
|
||||
aria-label={gettext('Delete')}
|
||||
title={gettext('Delete')}
|
||||
></button>
|
||||
>
|
||||
</button>
|
||||
</li>
|
||||
);
|
||||
}
|
||||
|
@@ -80,8 +80,9 @@ export default class VirtualTagName extends React.Component {
|
||||
<span
|
||||
onClick={this.toggleMode}
|
||||
className="cursor-pointer flex-fill"
|
||||
style={{width: 100, height: 20}}
|
||||
>{tagName}</span>
|
||||
style={{ width: 100, height: 20 }}
|
||||
>{tagName}
|
||||
</span>
|
||||
}
|
||||
</div>
|
||||
);
|
||||
|
Reference in New Issue
Block a user