From a866baea5fdbf30650cbfbf4aa383019ef61ec3d Mon Sep 17 00:00:00 2001
From: bobzel <zzzman@gmail.com>
Date: Fri, 27 Oct 2023 13:39:04 -0400
Subject: added collection itself to timeline

---
 src/client/views/animationtimeline/Timeline.tsx | 14 +++-----------
 1 file changed, 3 insertions(+), 11 deletions(-)

(limited to 'src/client/views/animationtimeline/Timeline.tsx')

diff --git a/src/client/views/animationtimeline/Timeline.tsx b/src/client/views/animationtimeline/Timeline.tsx
index 71517d4fe..4be3b05ab 100644
--- a/src/client/views/animationtimeline/Timeline.tsx
+++ b/src/client/views/animationtimeline/Timeline.tsx
@@ -543,7 +543,7 @@ export class Timeline extends React.Component<FieldViewProps> {
                                 <div key="timeline_scrubberhead" className="scrubberhead" onPointerDown={this.onScrubberDown}></div>
                             </div>
                             <div key="timeline_trackbox" className="trackbox" ref={this._trackbox} style={{ width: `${this._totalLength}px` }}>
-                                {this.children.map(doc => (
+                                {[...this.children, this.props.Document].map(doc => (
                                     <Track
                                         ref={ref => this.mapOfTracks.push(ref)}
                                         timeline={this}
@@ -562,16 +562,8 @@ export class Timeline extends React.Component<FieldViewProps> {
                         </div>
                         <div className="currentTime">Current: {this.getCurrentTime()}</div>
                         <div key="timeline_title" className="title-container" ref={this._titleContainer}>
-                            {this.children.map(doc => (
-                                <div
-                                    style={{ height: `${this._titleHeight}px` }}
-                                    className="datapane"
-                                    onPointerOver={() => {
-                                        Doc.BrushDoc(doc);
-                                    }}
-                                    onPointerOut={() => {
-                                        Doc.UnBrushDoc(doc);
-                                    }}>
+                            {[...this.children, this.props.Document].map(doc => (
+                                <div style={{ height: `${this._titleHeight}px` }} className="datapane" onPointerOver={() => Doc.BrushDoc(doc)} onPointerOut={() => Doc.UnBrushDoc(doc)}>
                                     <p>{StrCast(doc.title)}</p>
                                 </div>
                             ))}
-- 
cgit v1.2.3-70-g09d2

