mirror of
https://github.com/bookorbit/bookorbit.git
synced 2026-11-03 08:21:39 -06:00
feat(books): rename tags to genres and add user tags
This commit is contained in:
@@ -16,6 +16,7 @@ export type BookCard = {
|
||||
files: BookFileRef[];
|
||||
publishedYear: number | null;
|
||||
language: string | null;
|
||||
genres: string[];
|
||||
tags: string[];
|
||||
rating: number | null;
|
||||
readingProgress: number | null;
|
||||
@@ -54,6 +55,7 @@ export type BookDetail = {
|
||||
coverSource: 'extracted' | 'custom' | null;
|
||||
providerIds: ProviderIds;
|
||||
authors: { id: number; name: string; sortName: string | null }[];
|
||||
genres: string[];
|
||||
tags: string[];
|
||||
files: BookDetailFile[];
|
||||
};
|
||||
|
||||
@@ -23,7 +23,7 @@ export interface MetadataCandidate {
|
||||
isbn13?: string;
|
||||
seriesName?: string;
|
||||
seriesIndex?: number;
|
||||
tags?: string[];
|
||||
genres?: string[];
|
||||
coverUrl?: string;
|
||||
sourceUrl?: string;
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ export type RuleField =
|
||||
| 'publishedYear'
|
||||
| 'pageCount'
|
||||
| 'author'
|
||||
| 'tag'
|
||||
| 'genre'
|
||||
| 'format'
|
||||
| 'addedAt'
|
||||
| 'fileAvailability'
|
||||
@@ -48,7 +48,7 @@ export const FIELD_OPERATORS: Record<RuleField, RuleOperator[]> = {
|
||||
language: ['eq', 'notEq', 'isEmpty', 'isNotEmpty'],
|
||||
series: ['contains', 'notContains', 'isEmpty', 'isNotEmpty'],
|
||||
author: ['includesAny', 'includesAll', 'excludesAll', 'isEmpty', 'isNotEmpty'],
|
||||
tag: ['includesAny', 'includesAll', 'excludesAll', 'isEmpty', 'isNotEmpty'],
|
||||
genre: ['includesAny', 'includesAll', 'excludesAll', 'isEmpty', 'isNotEmpty'],
|
||||
format: ['includesAny', 'excludesAll'],
|
||||
publishedYear: ['eq', 'notEq', 'gt', 'gte', 'lt', 'lte', 'between', 'isEmpty', 'isNotEmpty'],
|
||||
seriesIndex: ['eq', 'notEq', 'gt', 'gte', 'lt', 'lte', 'between', 'isEmpty', 'isNotEmpty'],
|
||||
|
||||
Reference in New Issue
Block a user