mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Use interface over type
This commit is contained in:
parent
9d88af3dfe
commit
de4a359c98
21 changed files with 100 additions and 106 deletions
|
@ -1,16 +1,16 @@
|
|||
import { BaseItemDtoQueryResult } from '@thornbill/jellyfin-sdk/dist/generated-client';
|
||||
import React, { FunctionComponent, useCallback, useEffect, useRef } from 'react';
|
||||
import React, { FC, useCallback, useEffect, useRef } from 'react';
|
||||
import IconButtonElement from '../../elements/IconButtonElement';
|
||||
import globalize from '../../scripts/globalize';
|
||||
import { IQuery } from './type';
|
||||
import { QueryI } from './interface';
|
||||
|
||||
type PaginationProps = {
|
||||
query: IQuery;
|
||||
interface PaginationI {
|
||||
query: QueryI;
|
||||
itemsResult?: BaseItemDtoQueryResult;
|
||||
reloadItems: () => void;
|
||||
}
|
||||
|
||||
const Pagination: FunctionComponent<PaginationProps> = ({ query, itemsResult = {}, reloadItems }: PaginationProps) => {
|
||||
const Pagination: FC<PaginationI> = ({ query, itemsResult = {}, reloadItems }) => {
|
||||
const startIndex = query.StartIndex;
|
||||
const limit = query.Limit;
|
||||
const totalRecordCount = itemsResult.TotalRecordCount || 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue