frontend: fix typing issues
This commit is contained in:
@@ -28,7 +28,6 @@ type CellData<I, V> = {
|
|||||||
|
|
||||||
@Options({
|
@Options({
|
||||||
name: 'MangaListTable',
|
name: 'MangaListTable',
|
||||||
methods: {decode},
|
|
||||||
components: {BTable, MangaEntryDetailsModal},
|
components: {BTable, MangaEntryDetailsModal},
|
||||||
})
|
})
|
||||||
export default class MangaListTable extends Vue {
|
export default class MangaListTable extends Vue {
|
||||||
@@ -43,6 +42,7 @@ export default class MangaListTable extends Vue {
|
|||||||
latestChaptersSorted = latestChaptersSorted;
|
latestChaptersSorted = latestChaptersSorted;
|
||||||
latestChapterString = latestChapterString;
|
latestChapterString = latestChapterString;
|
||||||
newChapterCount = newChapterCount;
|
newChapterCount = newChapterCount;
|
||||||
|
decode = decode;
|
||||||
|
|
||||||
get fields(): TableFieldObject<ViewEntry>[] {
|
get fields(): TableFieldObject<ViewEntry>[] {
|
||||||
return [{
|
return [{
|
||||||
|
|||||||
@@ -58,7 +58,7 @@ export default class MangaUpdatesDataService {
|
|||||||
return str.toLowerCase().replaceAll('"', '\'').replaceAll(' - ', ' ').replaceAll(': ', ' ');
|
return str.toLowerCase().replaceAll('"', '\'').replaceAll(' - ', ' ').replaceAll(': ', ' ');
|
||||||
};
|
};
|
||||||
matching = results.results
|
matching = results.results
|
||||||
.filter(e => stringSimilarity(cleaner(title), cleaner(decode(e.record.title)), 2, false) >= 0.95)
|
.filter(e => stringSimilarity(cleaner(title ?? ""), cleaner(decode(e.record.title)), 2, false) >= 0.95)
|
||||||
.filter(e => allowedTypes.has(e.record.type.toLowerCase())) //check if a manga or similar but not novel
|
.filter(e => allowedTypes.has(e.record.type.toLowerCase())) //check if a manga or similar but not novel
|
||||||
.filter(e => m.startDate.year - 1 <= parseInt('' + e.record.year)
|
.filter(e => m.startDate.year - 1 <= parseInt('' + e.record.year)
|
||||||
&& parseInt('' + e.record.year) <= m.startDate.year + 1); //check year +-1
|
&& parseInt('' + e.record.year) <= m.startDate.year + 1); //check year +-1
|
||||||
|
|||||||
Reference in New Issue
Block a user