mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
migrate User Library Access Page
This commit is contained in:
parent
3f8b305995
commit
5d29529562
4 changed files with 27 additions and 24 deletions
|
@ -1,3 +0,0 @@
|
|||
<div id="userLibraryAccessPage" data-role="page" class="page type-interior">
|
||||
|
||||
</div>
|
|
@ -1,16 +1,17 @@
|
|||
import { UserDto } from '@thornbill/jellyfin-sdk/dist/generated-client';
|
||||
import React, { FunctionComponent, useCallback, useEffect, useState, useRef } from 'react';
|
||||
|
||||
import loading from '../loading/loading';
|
||||
import libraryMenu from '../../scripts/libraryMenu';
|
||||
import globalize from '../../scripts/globalize';
|
||||
import toast from '../toast/toast';
|
||||
import SectionTabs from '../dashboard/users/SectionTabs';
|
||||
import ButtonElement from '../dashboard/elements/ButtonElement';
|
||||
import { getParameterByName } from '../../utils/url';
|
||||
import SectionTitleContainer from '../dashboard/elements/SectionTitleContainer';
|
||||
import AccessContainer from '../dashboard/users/AccessContainer';
|
||||
import CheckBoxElement from '../dashboard/elements/CheckBoxElement';
|
||||
import loading from '../components/loading/loading';
|
||||
import libraryMenu from '../scripts/libraryMenu';
|
||||
import globalize from '../scripts/globalize';
|
||||
import toast from '../components/toast/toast';
|
||||
import SectionTabs from '../components/dashboard/users/SectionTabs';
|
||||
import ButtonElement from '../components/dashboard/elements/ButtonElement';
|
||||
import { getParameterByName } from '../utils/url';
|
||||
import SectionTitleContainer from '../components/dashboard/elements/SectionTitleContainer';
|
||||
import AccessContainer from '../components/dashboard/users/AccessContainer';
|
||||
import CheckBoxElement from '../components/dashboard/elements/CheckBoxElement';
|
||||
import Page from '../components/Page';
|
||||
|
||||
type ItemsArr = {
|
||||
Name?: string;
|
||||
|
@ -226,8 +227,11 @@ const UserLibraryAccessPage: FunctionComponent = () => {
|
|||
}, [loadData]);
|
||||
|
||||
return (
|
||||
<div ref={element}>
|
||||
<div className='content-primary'>
|
||||
<Page
|
||||
id='userLibraryAccessPage'
|
||||
className='mainAnimatedPage type-interior'
|
||||
>
|
||||
<div ref={element} className='content-primary'>
|
||||
<div className='verticalSection'>
|
||||
<SectionTitleContainer
|
||||
title={userName}
|
||||
|
@ -309,7 +313,8 @@ const UserLibraryAccessPage: FunctionComponent = () => {
|
|||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</Page>
|
||||
|
||||
);
|
||||
};
|
||||
|
|
@ -5,6 +5,7 @@ import ConnectionRequired from '../components/ConnectionRequired';
|
|||
import NewUserPage from './NewUserPage';
|
||||
import SearchPage from './search';
|
||||
import UserEditPage from './UserEditPage';
|
||||
import UserLibraryAccessPage from './UserLibraryAccessPage';
|
||||
import UserProfilesPage from './UserProfilesPage';
|
||||
|
||||
const AppRoutes = () => (
|
||||
|
@ -42,6 +43,14 @@ const AppRoutes = () => (
|
|||
</ConnectionRequired>
|
||||
}
|
||||
/>
|
||||
<Route
|
||||
path='userLibraryAccessPage.html'
|
||||
element={
|
||||
<ConnectionRequired>
|
||||
<UserLibraryAccessPage />
|
||||
</ConnectionRequired>
|
||||
}
|
||||
/>
|
||||
{/* Suppress warnings for unhandled routes */}
|
||||
<Route path='*' element={null} />
|
||||
</Route>
|
||||
|
|
|
@ -429,14 +429,6 @@ import { appRouter } from '../components/appRouter';
|
|||
controller: 'shows/tvrecommended'
|
||||
});
|
||||
|
||||
defineRoute({
|
||||
alias: '/userlibraryaccess.html',
|
||||
path: 'dashboard/users/userlibraryaccess.html',
|
||||
autoFocus: false,
|
||||
roles: 'admin',
|
||||
pageComponent: 'UserLibraryAccessPage'
|
||||
});
|
||||
|
||||
defineRoute({
|
||||
alias: '/userparentalcontrol.html',
|
||||
path: 'dashboard/users/userparentalcontrol.html',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue