splatter0 opened a new issue, #42224:
URL: https://github.com/apache/superset/issues/42224
## Feature request
Please support an optional, dedicated download button for charts embedded
through the Share iframe URL, especially standalone table and report embeds.
For example:
```text
/superset/explore/p/<permalink-key>/?standalone=1&show_download=1
```
## Background and use case
In our use case, tables and reports created in Superset need to be embedded
individually into existing business applications.
We do not want to embed a complete dashboard or expose the full Explore
interface. The embedded content should remain a clean, standalone table or
report.
However, users of the host application still need to download the displayed
report data, for example as CSV or XLSX.
Currently, when a chart is shared using a standalone iframe such as:
```html
<iframe
src="https://superset.example.com/superset/explore/p/<permalink-key>/?standalone=1"
></iframe>
```
the chart toolbar and download actions are hidden. There does not appear to
be a supported iframe parameter for displaying only the download action.
## Proposed solution
Add an iframe option such as:
```text
show_download=1
```
Alternatively, add a "Show download control" option to the Share / Embed
dialog.
When enabled, the standalone iframe should display a compact download button
or menu without displaying the complete Explore toolbar.
## Expected behavior
- The option should be disabled by default for backward compatibility.
- The download button should be displayed only when explicitly enabled.
- It should respect existing Superset export permissions, such as `can_csv`
or `can_export_data`.
- Unauthorized users should not see or be able to use the download action.
- The exported data should respect the report's current filters, table
filters, search conditions, and sorting.
- Available formats could follow the chart's existing export capabilities,
such as CSV or XLSX.
- The feature should work for a single shared chart iframe and should not
require creating a one-chart dashboard.
## Alternatives considered
1. Using `standalone=0`, which exposes more of the Explore interface than
desired.
2. Creating a dashboard containing only one table, which adds unnecessary
complexity.
3. Implementing a custom download function in every host application using
Superset APIs, which requires additional integration and maintenance.
## Environment
- Apache Superset 6.1.0
- Chart type: Table / tabular report
- Embedding method: Share iframe using an Explore permalink
Thank you for considering this feature.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]