Files
redash/client/app/components/dashboards/widget-dialog.html
Sami Jaktholm 9c8d06578a feat: add support for expanding dashboard visualizations (#2824)
* feat: add support for expanding dashboard visualizations

These changes implement support for expanding a dashboard visualization
into a larger modal dialog.

This is useful if you have a dashboard with lots of small widgets and
want to inspect one of the widgets more closely. In the past, this
would've required you to navigate to the query page to see a larger
version of the visualization. With these changes, visualizations can
be expanded right from the dashboard.

The implementation is simple as it just renders the visualization into
a modal dialog. Other parts of the widget (e.g. parameters) are not
included in this dialog.

* chore(widget-dialog): use query-link widget to render title

This reduces code duplication a bit. The link is made read-only
as navigation doesn't close the modal dialog.

* fix: make ui-select dropdown z-index > modal dialog z-index in dashboard page

Otherwise the dropdown renders behind the modal dialog if filter value
is changed from the modal view of a widget.
2018-10-14 10:42:31 +03:00

13 lines
612 B
HTML

<div class="modal-header">
<button type="button" class="close" aria-hidden="true" ng-click="$ctrl.dismiss()">&times;</button>
<div class="visualization-title">
<query-link query="$ctrl.widget.getQuery()" visualization="$ctrl.widget.visualization" readonly="true"></query-link>
</div>
</div>
<div class="modal-body">
<visualization-renderer visualization="$ctrl.widget.visualization" query-result="$ctrl.widget.getQueryResult()" class="t-body"></visualization-renderer>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" ng-click="$ctrl.dismiss()">Close</button>
</div>