author | ymh <ymh.work@gmail.com> |
Fri, 02 Dec 2016 13:25:08 +0100 | |
changeset 457 | a7a333c0b1eb |
parent 455 | a8bed1c7df8e |
permissions | -rw-r--r-- |
454
710a2ae08a74
rework transcript component to correct various bugs
ymh <ymh.work@gmail.com>
parents:
diff
changeset
|
1 |
import Ember from 'ember'; |
710a2ae08a74
rework transcript component to correct various bugs
ymh <ymh.work@gmail.com>
parents:
diff
changeset
|
2 |
|
710a2ae08a74
rework transcript component to correct various bugs
ymh <ymh.work@gmail.com>
parents:
diff
changeset
|
3 |
export default Ember.Component.extend({ |
710a2ae08a74
rework transcript component to correct various bugs
ymh <ymh.work@gmail.com>
parents:
diff
changeset
|
4 |
tagName: 'li', |
710a2ae08a74
rework transcript component to correct various bugs
ymh <ymh.work@gmail.com>
parents:
diff
changeset
|
5 |
|
710a2ae08a74
rework transcript component to correct various bugs
ymh <ymh.work@gmail.com>
parents:
diff
changeset
|
6 |
classNames: ['sentence'], |
710a2ae08a74
rework transcript component to correct various bugs
ymh <ymh.work@gmail.com>
parents:
diff
changeset
|
7 |
|
710a2ae08a74
rework transcript component to correct various bugs
ymh <ymh.work@gmail.com>
parents:
diff
changeset
|
8 |
begin: Ember.computed.readOnly('turn.begin'), |
710a2ae08a74
rework transcript component to correct various bugs
ymh <ymh.work@gmail.com>
parents:
diff
changeset
|
9 |
end: Ember.computed.readOnly('turn.end'), |
710a2ae08a74
rework transcript component to correct various bugs
ymh <ymh.work@gmail.com>
parents:
diff
changeset
|
10 |
title: Ember.computed.readOnly('turn.title'), |
710a2ae08a74
rework transcript component to correct various bugs
ymh <ymh.work@gmail.com>
parents:
diff
changeset
|
11 |
annotations: Ember.computed.readOnly('turn.annotations'), |
710a2ae08a74
rework transcript component to correct various bugs
ymh <ymh.work@gmail.com>
parents:
diff
changeset
|
12 |
|
455
a8bed1c7df8e
move the transcript highlight and autoscroll logic to the base component
ymh <ymh.work@gmail.com>
parents:
454
diff
changeset
|
13 |
didInsertElement: function() { |
a8bed1c7df8e
move the transcript highlight and autoscroll logic to the base component
ymh <ymh.work@gmail.com>
parents:
454
diff
changeset
|
14 |
if(this.get('intervals')) { |
a8bed1c7df8e
move the transcript highlight and autoscroll logic to the base component
ymh <ymh.work@gmail.com>
parents:
454
diff
changeset
|
15 |
this.get('intervals').add(this.get('begin'), this.get('end'), this.get('elementId'), this.$()); |
a8bed1c7df8e
move the transcript highlight and autoscroll logic to the base component
ymh <ymh.work@gmail.com>
parents:
454
diff
changeset
|
16 |
} |
a8bed1c7df8e
move the transcript highlight and autoscroll logic to the base component
ymh <ymh.work@gmail.com>
parents:
454
diff
changeset
|
17 |
}, |
a8bed1c7df8e
move the transcript highlight and autoscroll logic to the base component
ymh <ymh.work@gmail.com>
parents:
454
diff
changeset
|
18 |
|
454
710a2ae08a74
rework transcript component to correct various bugs
ymh <ymh.work@gmail.com>
parents:
diff
changeset
|
19 |
}); |