Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

obsidian 微信读书模板 #60

Closed
smallSpoon opened this issue Jun 30, 2022 · 1 comment
Closed

obsidian 微信读书模板 #60

smallSpoon opened this issue Jun 30, 2022 · 1 comment

Comments

@smallSpoon
Copy link


isbn: {{metaData.isbn}}
category: {{metaData.category}}

Meta

[!abstract] {{metaData.title}}

  •  {{metaData.title}}|200
  • 书名: {{metaData.title}}
  • 作者: {{metaData.author}}
  • 简介: {{metaData.intro}}
  • 出版时间 {{metaData.publishTime}}
  • ISBN: {{metaData.isbn}}
  • 分类: {{metaData.category}}
  • 出版社: {{metaData.publisher}}

{% if bookReview.bookReviews %}{% for bookReview in bookReview.bookReviews %}
{% if loop.first %}{% if bookReview.mdContent.length %}#本书评论{% endif %}{% endif %}
{% if bookReview.mdContent.length %}- {{bookReview.mdContent}} ^{{bookReview.reviewId}}
[[{{bookReview.createTime.slice(0, 10)}}]]{{bookReview.createTime.slice(10, 16)}}
{% endif %}{% endfor%}{% endif %}

{% for chapter in bookReview.chapterReviews %}{% if chapter.reviews or chapter.chapterReview %}{% if chapter.chapterReviews %}{% for chapterReview in chapter.chapterReviews %}- {{chapterReview.content}} ^{{chapterReview.reviewId}}
[[{{chapterReview.createTime.slice(0, 10)}}]]{{chapterReview.createTime.slice(10, 16)}}
{% endfor%}
{%endif %}{% if chapter.reviews %}{%for review in chapter.reviews %}
{% endfor %} {%endif %} {% endif %} {% endfor %}

{% for chapter in chapterHighlights %}{% if loop.first %}## highlights{% endif %}

{{chapter.chapterTitle}}

{% for highlight in chapter.highlights %}{% if highlight.reviewContent %}

  • {{ highlight.markText |trim }} — created on [[{{highlight.createTime.slice(0, 10)}}]]{{highlight.createTime.slice(10, 16)}} ^{{highlight.chapterUid}}-{{highlight.range}}
    {% set regExp = r/#/g %}{% if regExp.test(highlight.reviewContent) === false %}#读书笔记{% endif %} {{highlight.reviewContent}}
    {% else %}
  • {{ highlight.markText |trim }} — created on [[{{highlight.createTime.slice(0, 10)}}]]{{highlight.createTime.slice(10, 16)}} ^{{highlight.chapterUid}}-{{highlight.range}}
    {% endif %} {% endfor %}{% endfor %}
@zhaohongxuan
Copy link
Owner

migrate to discussion

@zhaohongxuan zhaohongxuan closed this as not planned Won't fix, can't repro, duplicate, stale Jul 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants