1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-20 19:08:21 +00:00

add-share-link-authentication (#6201)

* add-share-link-authentication

* [share link - link creation] 'set scope': redesigned it

* update

* Update share_link_auth.py

* Update share_link_auth.py

* Update share_link_auth.py

* Update share_link_auth.py

* Update share_link_auth.py

* Update share_link_auth.py

* [share link - link details] redesigned the panel

* [share dialog - share link] 'authenticated users/emails' panels: redesigned them

* [share dialog - share link'] UI details, UX, and code improvements for 'link detais, authenticated users/emails' panels

* [share dialog - share link] updated the 'submit' handler for the 'authenticated emails/users' panels; fixup for 'set scope' in the 'link creation' panel'

* [share dialog - share link] deleted 'share-link-api.js', moved api modification to seafile-js; fixed 'change scope'  & etc. in 'link details'

* [share dialog - share link] link authenticated users: update 'submit' handler according to the python API update

* [share dialog - share link] added 'share-link-api.js' back & used it

* [share dialog - share link] handled eslint warnings and etc.

---------

Co-authored-by: llj <lingjun.li1@gmail.com>
This commit is contained in:
Ranjiwei
2024-07-19 18:12:35 +08:00
committed by GitHub
parent 69eb6263cf
commit add4689b02
25 changed files with 1621 additions and 291 deletions

View File

@@ -9,6 +9,8 @@ import Loading from '../loading';
import LinkDetails from './link-details';
import LinkCreation from './link-creation';
import LinkList from './link-list';
import LinkAuthenticatedUsers from './link-authenticated-users';
import LinkAuthenticatedEmails from './link-authenticated-emails';
const propTypes = {
itemPath: PropTypes.string.isRequired,
@@ -240,6 +242,7 @@ class ShareLinkPanel extends React.Component {
updateLink={this.updateLink}
deleteLink={this.deleteLink}
closeShareDialog={this.props.closeShareDialog}
setMode={this.setMode}
/>
);
case 'singleLinkCreation':
@@ -268,6 +271,24 @@ class ShareLinkPanel extends React.Component {
updateAfterCreation={this.updateAfterCreation}
/>
);
case 'linkAuthenticatedUsers':
return (
<LinkAuthenticatedUsers
repoID={repoID}
linkToken={sharedLinkInfo.token}
setMode={this.setMode}
path={itemPath}
/>
);
case 'linkAuthenticatedEmails':
return (
<LinkAuthenticatedEmails
repoID={repoID}
linkToken={sharedLinkInfo.token}
setMode={this.setMode}
path={itemPath}
/>
);
default:
return (
<LinkList