Changeset 249202 in webkit
- Timestamp:
- Aug 28, 2019, 9:42:40 AM (7 years ago)
- Location:
- trunk/Tools
- Files:
-
- 3 edited
-
ChangeLog (modified) (1 diff)
-
resultsdbpy/resultsdbpy/view/static/js/timeline.js (modified) (2 diffs)
-
resultsdbpy/resultsdbpy/view/static/library/js/components/TimelineComponents.js (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Tools/ChangeLog
r249200 r249202 1 2019-08-28 Jonathan Bedard <jbedard@apple.com> 2 3 results.webkit.org: Auto-expand single configurations 4 https://bugs.webkit.org/show_bug.cgi?id=201218 5 6 Rubber-stamped by Aakash Jain. 7 8 * resultsdbpy/resultsdbpy/view/static/js/timeline.js: 9 (TimelineFromEndpoint.toString): Automatically expand timeline when only one 10 configuration has been specified. 11 * resultsdbpy/resultsdbpy/view/static/library/js/components/TimelineComponents.js: 12 (prototype.ExpandableSeriesComponent): Add options so that the caller can set whether a timeline 13 is expanded or collapsed by default. 14 1 15 2019-08-28 Jonathan Bedard <jbedard@apple.com> 2 16 -
trunk/Tools/resultsdbpy/resultsdbpy/view/static/js/timeline.js
r249124 r249202 722 722 }))); 723 723 }); 724 myTimeline = Timeline.ExpandableSeriesWithHeaderExpanderComponent(myTimeline, ...timelinesBySDK);724 myTimeline = Timeline.ExpandableSeriesWithHeaderExpanderComponent(myTimeline, {}, ...timelinesBySDK); 725 725 } 726 726 collapsedTimelines.push(myTimeline); … … 748 748 exporter: exporterFactory(allResults), 749 749 })), 750 {expanded: this.configurations.length <= 1}, 750 751 ...collapsedTimelines 751 752 )); -
trunk/Tools/resultsdbpy/resultsdbpy/view/static/library/js/components/TimelineComponents.js
r249124 r249202 476 476 } 477 477 478 Timeline.ExpandableSeriesComponent = (mainSeries, subSerieses, exporter) => {478 Timeline.ExpandableSeriesComponent = (mainSeries, options, subSerieses, exporter) => { 479 479 const ref = REF.createRef({ 480 state: {expanded: false},480 state: {expanded: options.expanded ? options.expanded : false}, 481 481 onStateUpdate: (element, stateDiff) => { 482 482 if (stateDiff.expanded === false) { … … 506 506 } 507 507 508 Timeline.ExpandableHeaderComponent = (mainLabel, subLabels, exporter) => {508 Timeline.ExpandableHeaderComponent = (mainLabel, options, subLabels, exporter) => { 509 509 const ref = REF.createRef({ 510 state: {expanded: false},510 state: {expanded: options.expanded ? options.expanded : false}, 511 511 onStateUpdate: (element, stateDiff) => { 512 512 if (stateDiff.expanded === false) … … 532 532 } 533 533 534 Timeline.ExpandableSeriesWithHeaderExpanderComponent = (mainSeriesWithLable, ...subSeriesWithLable) => {534 Timeline.ExpandableSeriesWithHeaderExpanderComponent = (mainSeriesWithLable, options, ...subSeriesWithLable) => { 535 535 const ref = REF.createRef({ 536 state: {expanded: false},536 state: {expanded: options.expanded ? options.expanded : false}, 537 537 onStateUpdate: (element, stateDiff) => { 538 538 if (stateDiff.expanded === false) … … 559 559 })); 560 560 return { 561 header: Timeline.ExpandableHeaderComponent(`<a class="link-button" href="javascript:void(0)" ref="${ref}">+</a>` + mainLabel, subLabels, composer),562 series: Timeline.ExpandableSeriesComponent(mainSeries, subSerieses, composer),561 header: Timeline.ExpandableHeaderComponent(`<a class="link-button" href="javascript:void(0)" ref="${ref}">+</a>` + mainLabel, options, subLabels, composer), 562 series: Timeline.ExpandableSeriesComponent(mainSeries, options, subSerieses, composer), 563 563 } 564 564 }
Note:
See TracChangeset
for help on using the changeset viewer.