Skip to content

Commit

Permalink
fix: search content was returned if we are syncing a pdf
Browse files Browse the repository at this point in the history
  • Loading branch information
sywhb committed Sep 28, 2023
1 parent a9a3eac commit 3c10e1a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions src/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ export interface Article {
readingProgressPercent: number;
isArchived: boolean;
archivedAt?: string;
contentReader?: string;
}

export interface Label {
Expand Down Expand Up @@ -122,6 +123,7 @@ export const loadArticles = async (
isArchived
readingProgressPercent
archivedAt
contentReader
highlights {
id
quote
Expand Down
4 changes: 2 additions & 2 deletions src/settings/template.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ export type ArticleView =
labels?: LabelView[];
dateSaved: string;
highlights: HighlightView[];
content: string;
content?: string;
datePublished?: string;
fileAttachment?: string;
description?: string;
Expand Down Expand Up @@ -219,7 +219,7 @@ export const renderArticleContnet = async (
labels: renderLabels(article.labels),
dateSaved,
highlights,
content: article.content,
content: article.contentReader === 'WEB' ? article.content : undefined,
datePublished,
fileAttachment,
description: article.description,
Expand Down

0 comments on commit 3c10e1a

Please sign in to comment.