I’m using embedded Quicksight dashboards with the SDK GitHub - awslabs/amazon-quicksight-embedding-sdk: A SDK to help users embed QuickSight dashboards on other pages.
Here’s the relevant code
<?php
...
$res = $this->qsClient->generateEmbedUrlForRegisteredUser($req);
$embedUrl = $res->get('EmbedUrl');
?>
<script src="https://unpkg.com/amazon-quicksight-embedding-sdk@2.6.0/dist/quicksight-embedding-js-sdk.min.js"></script>
<script type="text/javascript">
const embedDashboard = async () => {
const {
createEmbeddingContext,
} = QuickSightEmbedding;
const embeddingContext = await createEmbeddingContext();
const containerDiv = document.getElementById("embedding-container");
const frameOptions = {
// replace the value below with the one generated via embedding API
url: "<?= $embedUrl ?>",
container: containerDiv,
height: "2000px",
withIframePlaceholder: true
//width: "1000px",
};
const contentOptions = {
toolbarOptions: {
export: true, // PDF download
undoRedo: true,
reset: true,
bookmarks: true
},
sheetOptions: {
//initialSheetId: '<YOUR_SHEET_ID>',
singleSheet: false, // use this option to enable or disable sheet tab controls
emitSizeChangedEventOnSheetChange: false, // use this option in combination with resizeHeightOnSizeChangedEvent property,
// to allow iframe height to resize dynamically, based on sheet height, on changing sheets.
},
attributionOptions: {
overlayContent: false,
},
};
try {
const embeddedDashboard = await embeddingContext.embedDashboard(frameOptions, contentOptions);
But I’m finding that the “toolbarOptions” get ignored. I don’t get a PDF download link, but I do get the other options
Here are my advanced publish options
What am I doing wrong?