mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-03 07:55:36 +00:00
[share dialog] improvements (#4540)
This commit is contained in:
@@ -243,7 +243,7 @@ class ShareDialog extends React.Component {
|
|||||||
const enableShareLink = !repoEncrypted && canGenerateShareLink;
|
const enableShareLink = !repoEncrypted && canGenerateShareLink;
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
<Modal isOpen={true} style={{maxWidth: '720px'}} className="share-dialog" toggle={this.props.toggleDialog}>
|
<Modal isOpen={true} style={{maxWidth: '760px'}} className="share-dialog" toggle={this.props.toggleDialog}>
|
||||||
<ModalHeader toggle={this.props.toggleDialog}>
|
<ModalHeader toggle={this.props.toggleDialog}>
|
||||||
{gettext('Share')} <span className="op-target" title={itemName}>{itemName}</span>
|
{gettext('Share')} <span className="op-target" title={itemName}>{itemName}</span>
|
||||||
{this.renderExternalShareMessage()}
|
{this.renderExternalShareMessage()}
|
||||||
|
@@ -287,16 +287,19 @@ class ShareToGroup extends React.Component {
|
|||||||
}
|
}
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
|
const thead = (
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th width="47%">{gettext('Group')}</th>
|
||||||
|
<th width="35%">{gettext('Permission')}</th>
|
||||||
|
<th width="18%"></th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
);
|
||||||
return (
|
return (
|
||||||
<Fragment>
|
<Fragment>
|
||||||
<table className="w-xs-200">
|
<table className="w-xs-200">
|
||||||
<thead>
|
{thead}
|
||||||
<tr>
|
|
||||||
<th width="50%">{gettext('Group')}</th>
|
|
||||||
<th width="35%">{gettext('Permission')}</th>
|
|
||||||
<th width="15%"></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
@@ -338,13 +341,7 @@ class ShareToGroup extends React.Component {
|
|||||||
</table>
|
</table>
|
||||||
<div className="share-list-container">
|
<div className="share-list-container">
|
||||||
<table className="table-thead-hidden w-xs-200">
|
<table className="table-thead-hidden w-xs-200">
|
||||||
<thead>
|
{thead}
|
||||||
<tr>
|
|
||||||
<th width="50%">{gettext('Group')}</th>
|
|
||||||
<th width="35%">{gettext('Permission')}</th>
|
|
||||||
<th width="15%"></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<GroupList
|
<GroupList
|
||||||
items={this.state.sharedItems}
|
items={this.state.sharedItems}
|
||||||
permissions={this.permissions}
|
permissions={this.permissions}
|
||||||
|
@@ -272,16 +272,19 @@ class ShareToUser extends React.Component {
|
|||||||
|
|
||||||
render() {
|
render() {
|
||||||
let { sharedItems } = this.state;
|
let { sharedItems } = this.state;
|
||||||
|
const thead = (
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th width="47%">{gettext('User')}</th>
|
||||||
|
<th width="35%">{gettext('Permission')}</th>
|
||||||
|
<th width="18%"></th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
);
|
||||||
return (
|
return (
|
||||||
<Fragment>
|
<Fragment>
|
||||||
<table className="w-xs-200">
|
<table className="w-xs-200">
|
||||||
<thead>
|
{thead}
|
||||||
<tr>
|
|
||||||
<th width="50%">{gettext('User')}</th>
|
|
||||||
<th width="35%">{gettext('Permission')}</th>
|
|
||||||
<th width="15%"></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
@@ -325,13 +328,7 @@ class ShareToUser extends React.Component {
|
|||||||
</table>
|
</table>
|
||||||
<div className="share-list-container">
|
<div className="share-list-container">
|
||||||
<table className="table-thead-hidden w-xs-200">
|
<table className="table-thead-hidden w-xs-200">
|
||||||
<thead>
|
{thead}
|
||||||
<tr>
|
|
||||||
<th width="50%">{gettext('User')}</th>
|
|
||||||
<th width="35%">{gettext('Permission')}</th>
|
|
||||||
<th width="15%"></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<UserList
|
<UserList
|
||||||
items={sharedItems}
|
items={sharedItems}
|
||||||
permissions={this.permissions}
|
permissions={this.permissions}
|
||||||
|
@@ -34,7 +34,7 @@
|
|||||||
.share-dialog-content .share-dialog-main {
|
.share-dialog-content .share-dialog-main {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex: 0 0 78%;
|
flex: 0 0 78%;
|
||||||
padding: 1rem 1.5rem 2rem;
|
padding: 1rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.share-dialog-content .share-dialog-main .tab-content {
|
.share-dialog-content .share-dialog-main .tab-content {
|
||||||
|
Reference in New Issue
Block a user