1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-07 18:03:48 +00:00

[a11y] group view: modified 'Settings'

This commit is contained in:
llj
2021-09-23 16:14:13 +08:00
parent 6e2a296ca1
commit 3ccd165fbf

View File

@@ -456,19 +456,20 @@ class GroupView extends React.Component {
<div className="path-tool"> <div className="path-tool">
{ isShowSettingIcon && { isShowSettingIcon &&
<React.Fragment> <React.Fragment>
<a href="#" className="sf2-icon-cog1 action-icon group-top-action-icon" title="Settings" id="settings" <a href="#" role="button" aria-label={gettext('Settings')} className="sf2-icon-cog1 action-icon group-top-action-icon" title={gettext("Settings")} id="settings" onClick={this.toggleGroupDropdown}></a>
onClick={this.toggleGroupDropdown}></a>
<Popover placement="bottom" isOpen={this.state.showGroupDropdown} target="settings" <Popover placement="bottom" isOpen={this.state.showGroupDropdown} target="settings"
toggle={this.toggleGroupDropdown} hideArrow={true} className="sf-popover"> toggle={this.toggleGroupDropdown} hideArrow={true} className="sf-popover">
<div className="sf-popover-hd sf-popover-title"> <div className="sf-popover-hd sf-popover-title">
<span>{gettext('Settings')}</span> <span>{gettext('Settings')}</span>
<a href="#" className="sf-popover-close js-close sf2-icon-x1 action-icon" <a href="#" className="sf-popover-close js-close sf2-icon-x1 action-icon"
role="button"
aria-label={gettext('Close')}
onClick={this.toggleGroupDropdown}></a> onClick={this.toggleGroupDropdown}></a>
</div> </div>
<div className="sf-popover-con"> <div className="sf-popover-con">
{(this.state.isStaff || this.state.isOwner) && {(this.state.isStaff || this.state.isOwner) &&
<ul className="sf-popover-list"> <ul className="sf-popover-list">
<li><a href="#" className="sf-popover-item" onClick={this.toggleRenameGroupDialog} >{gettext('Rename')}</a></li> <li><a href="#" className="sf-popover-item" onClick={this.toggleRenameGroupDialog}>{gettext('Rename')}</a></li>
{ {
this.state.isOwner && this.state.isOwner &&
<li><a href="#" className="sf-popover-item" onClick={this.toggleTransferGroupDialog} >{gettext('Transfer')}</a></li> <li><a href="#" className="sf-popover-item" onClick={this.toggleTransferGroupDialog} >{gettext('Transfer')}</a></li>