cms/app-client/app/templates/components/transcript-component.hbs
author Chloe Laisne <chloe.laisne@gmail.com>
Fri, 05 Aug 2016 18:51:59 +0200
changeset 253 0be9770b09b4
parent 248 256272c33349
child 254 a7cf2887e993
permissions -rw-r--r--
Hide/show transcript button in the player - Do not request transscript when property is null in the document request
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
245
c9dd78a43b07 Transcript model and erializer
Chloe Laisne <chloe.laisne@gmail.com>
parents:
diff changeset
     1
<h2>{{player.transcript.title}}</h2>
247
7a5d729992b8 Design and animate transcript
Chloe Laisne <chloe.laisne@gmail.com>
parents: 246
diff changeset
     2
<ol class="transcript">
245
c9dd78a43b07 Transcript model and erializer
Chloe Laisne <chloe.laisne@gmail.com>
parents:
diff changeset
     3
{{#each player.transcript.annotations as |annotation|}}
248
256272c33349 Transcript sentence lick and play
Chloe Laisne <chloe.laisne@gmail.com>
parents: 247
diff changeset
     4
	{{#if (if-and (if-operator player.progress '>=' annotation.start) (if-operator player.progress '<' annotation.end))}}
256272c33349 Transcript sentence lick and play
Chloe Laisne <chloe.laisne@gmail.com>
parents: 247
diff changeset
     5
	<li class="sentence active">
247
7a5d729992b8 Design and animate transcript
Chloe Laisne <chloe.laisne@gmail.com>
parents: 246
diff changeset
     6
		<i class="fa fa-play" {{action 'play' annotation.start}}>Play</i>
246
5b7ae96768be Bsic transcript-component design
Chloe Laisne <chloe.laisne@gmail.com>
parents: 245
diff changeset
     7
		<p class="original">{{annotation.content}}</p>
5b7ae96768be Bsic transcript-component design
Chloe Laisne <chloe.laisne@gmail.com>
parents: 245
diff changeset
     8
		<p class="translation">{{annotation.translation}}</p>
247
7a5d729992b8 Design and animate transcript
Chloe Laisne <chloe.laisne@gmail.com>
parents: 246
diff changeset
     9
	</li>
248
256272c33349 Transcript sentence lick and play
Chloe Laisne <chloe.laisne@gmail.com>
parents: 247
diff changeset
    10
	{{else}}
256272c33349 Transcript sentence lick and play
Chloe Laisne <chloe.laisne@gmail.com>
parents: 247
diff changeset
    11
	<li class="sentence" {{action 'play' annotation.start}}>
256272c33349 Transcript sentence lick and play
Chloe Laisne <chloe.laisne@gmail.com>
parents: 247
diff changeset
    12
		<i class="fa fa-play">Play</i>
256272c33349 Transcript sentence lick and play
Chloe Laisne <chloe.laisne@gmail.com>
parents: 247
diff changeset
    13
		<p class="original">{{annotation.content}}</p>
256272c33349 Transcript sentence lick and play
Chloe Laisne <chloe.laisne@gmail.com>
parents: 247
diff changeset
    14
		<p class="translation">{{annotation.translation}}</p>
256272c33349 Transcript sentence lick and play
Chloe Laisne <chloe.laisne@gmail.com>
parents: 247
diff changeset
    15
	</li>
256272c33349 Transcript sentence lick and play
Chloe Laisne <chloe.laisne@gmail.com>
parents: 247
diff changeset
    16
	{{/if}}
245
c9dd78a43b07 Transcript model and erializer
Chloe Laisne <chloe.laisne@gmail.com>
parents:
diff changeset
    17
{{/each}}
247
7a5d729992b8 Design and animate transcript
Chloe Laisne <chloe.laisne@gmail.com>
parents: 246
diff changeset
    18
</ol>