reformat code

This commit is contained in:
lukas 2021-01-24 16:43:38 +01:00
parent fe1a00d1af
commit d8aee9e5b7
5 changed files with 19 additions and 21 deletions

View File

@ -9,9 +9,9 @@
width: 140px; width: 140px;
} }
.searchinput{ .searchinput {
width: 120px;
float: left; float: left;
width: 120px;
} }
.searchbar { .searchbar {

View File

@ -120,14 +120,6 @@ class AddActorPopup extends React.Component<props, state> {
} }
} }
/**
* filter the actor array for search matches
* @param actor
*/
private filterSearch(actor: ActorType): boolean {
return actor.name.toLowerCase().includes(this.state.filter.toLowerCase());
}
/** /**
* event handling for ActorTile Click * event handling for ActorTile Click
*/ */
@ -155,6 +147,14 @@ class AddActorPopup extends React.Component<props, state> {
this.setState({actors: result}); this.setState({actors: result});
}); });
} }
/**
* filter the actor array for search matches
* @param actor
*/
private filterSearch(actor: ActorType): boolean {
return actor.name.toLowerCase().includes(this.state.filter.toLowerCase());
}
} }
export default AddActorPopup; export default AddActorPopup;

View File

@ -5,7 +5,7 @@ import {Link} from 'react-router-dom';
import GlobalInfos from '../../utils/GlobalInfos'; import GlobalInfos from '../../utils/GlobalInfos';
import {callAPIPlain} from '../../utils/Api'; import {callAPIPlain} from '../../utils/Api';
interface PreviewProps{ interface PreviewProps {
name: string; name: string;
movie_id: number; movie_id: number;
} }
@ -62,7 +62,7 @@ class Preview extends React.Component<PreviewProps, PreviewState> {
/** /**
* Component for a Tag-name tile (used in category page) * Component for a Tag-name tile (used in category page)
*/ */
export class TagPreview extends React.Component<{name: string}> { export class TagPreview extends React.Component<{ name: string }> {
render(): JSX.Element { render(): JSX.Element {
const themeStyle = GlobalInfos.getThemeStyle(); const themeStyle = GlobalInfos.getThemeStyle();
return ( return (

View File

@ -1,6 +1,6 @@
import {ActorType, TagType} from './VideoTypes'; import {ActorType, TagType} from './VideoTypes';
export namespace VideoTypes{ export namespace VideoTypes {
export interface loadVideoType { export interface loadVideoType {
movie_url: string movie_url: string
thumbnail: string thumbnail: string
@ -14,7 +14,7 @@ export namespace VideoTypes{
actors: ActorType[] actors: ActorType[]
} }
export interface startDataType{ export interface startDataType {
total: number; total: number;
fullhd: number; fullhd: number;
hd: number; hd: number;
@ -28,14 +28,14 @@ export namespace VideoTypes{
} }
} }
export namespace SettingsTypes{ export namespace SettingsTypes {
export interface initialApiCallData { export interface initialApiCallData {
DarkMode: boolean; DarkMode: boolean;
passwordEnabled: boolean; passwordEnabled: boolean;
mediacenter_name: string; mediacenter_name: string;
} }
export interface loadGeneralSettingsType{ export interface loadGeneralSettingsType {
video_path: string, video_path: string,
episode_path: string, episode_path: string,
mediacenter_name: string, mediacenter_name: string,
@ -49,13 +49,13 @@ export namespace SettingsTypes{
tagsadded: number tagsadded: number
} }
export interface getStatusMessageType{ export interface getStatusMessageType {
contentAvailable: boolean; contentAvailable: boolean;
message: string; message: string;
} }
} }
export namespace ActorTypes{ export namespace ActorTypes {
/** /**
* result of actor fetch * result of actor fetch
*/ */

View File

@ -1,5 +1,3 @@
/** /**
* type accepted by Tag component * type accepted by Tag component
*/ */