-
Notifications
You must be signed in to change notification settings - Fork 7.2k
/
article.art
38 lines (35 loc) · 1.06 KB
/
article.art
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
{{ if item.audio }}
<audio src="{{ item.audio }}" controls></audio><br>
{{ /if }}
{{ if $('.article .subhead').length }}
<blockquote><p>{{@ $('.article .subhead').html() }}</p></blockquote>
<br>
{{ /if }}
{{ if $('.article .media').length }}
{{@ $('.article .media').html() }}
<br>
{{ /if }}
{{ if $('.article .content_video').length }}
<% const video = $('script').text().match(/initPlayer\('(.*?)','(.*?)'\)/); %>
<% const videoUrl = video[1]; %>
<% const poster = video[2]; %>
<video controls preload="none" poster="{{ poster }}" src="{{ videoUrl }}"></video>
<br>
{{ /if }}
{{ if $('div#Main_Content_Val.text').length }}
{{@ $('div#Main_Content_Val.text').html() }}
{{ else }}
{{ if item.summary }}
<blockquote><p>{{ item.summary }}</p></blockquote>
<br>
{{ /if }}
{{ if item.pics?.includes('#') }}
{{ each item.pics.split('#') pic }}
<img src="{{ pic }}">
<br>
{{ /each }}
{{ else }}
<img src="{{ item.pics }}">
<br>
{{ /if }}
{{ /if }}