Hi,
I can’t open a fly-out modal from the panel menu. What am I doing wrong?
Thank you for your help.
Fred
manifes.json
"entrypoints": [
{
"type": "command",
"id": "openStartInterface",
"label": "Mouli Master"
}
],
main.js
entrypoints.setup({
commands: {
openStartInterface: async () => openStartInterface()
});
const openStartInterface = () => {
document.querySelector('#startInterface').setAttribute('open');
showAlert("openStartInterface " + document.querySelector('#startInterface').setAttribute('open'))
}
index.html
<sp-dialog id="startInterface">
<sp-heading slot="title" size="XS">SELECT THE CAMPAIGN:</sp-heading>
<sp-body slot="description">Please, select the campaign.</sp-body>
<div class="row">
<sp-action-button id="select" size="M">Select</sp-action-button>
<sp-heading size="XS" id="showCampaignNane">Lala</sp-heading>
</div>
<div class="row" style="justify-content: center;">
<sp-button id="btnCancel" variant="primary" >Cancel</sp-button>
<sp-button id="btnStart" selected>START</sp-button>
</div>
</sp-dialog>