Custom UI in Header

Which product are you using?
PDF.js Express Plus

PDF.js Express Version
8.4.7
Detailed description of issue
Hi,
We are trying to add custom elements using dev express controls like dropdown to the header section in the viewer. we were able to add ui control but the dropdown menu position is not with in the viewer iframe and its opening some where in the web application. is there any setting to bound in pdf express viewer?

Expected behaviour
NA

Does your issue happen with every document, or just one?
NA

Link to document

const renderbutton = () => {
    const divElement = document.createElement('div');
    divElement.id = 'searchDrpDwn';
    divElement.style = 'width:150px';
    let dropdownArray = allSearchTermsArray.map((s, i) => ({ elemId: s.elemId, description: s.description }));
    $(divElement).dxTagBox({
        dataSource: dropdownArray,
        placeholder: "select search",
        displayExpr: "description",
        valueExpr:'elemId',
        showSelectionControls: true,
        searchEnabled: true,
        maxDisplayedTags: 1,
        value: searchTermsArray.map(c => c.elemId),
        onValueChanged: function (data) {
            instance.docViewer.clearSearchResults();
            results = [];
            searchDropDownClick(data.value);
            instance.UI.openElements(['searchPanel']);
        }
    });
    return divElement;
}
async function searchDropDownClick(selectedIdLst) {
    for (var selectedElemId of selectedIdLst) {
        await performSearch(allSearchTermsArray.find(k => k.elemId == selectedElemId));
    }
}
const newCustomElement = {
    type: 'customElement',
    id: 'searchLst',
    render: renderbutton
};
instance.UI.setHeaderItems((header) => {
    let exiIndex = header.getItems().findIndex(item => item.id == 'searchLst');
    if (exiIndex > -1) {
        header.delete(exiIndex);
    }
    /*header.unshift(newCustomElement);    */
    header.push(newCustomElement);    
});

Code snippet
{Provide a relevant code snippet}

Hello prajneshu.khandavall,

Using the code provided I wasnt able to add it to a sample project and see the issue shown in the screenshot, could you provide a sample project clearly demonstrating the issue?

Best regards,
Tyler

Hi sorry for the late. i am attaching sample code in angularjs and modified the code.

please use this link to download the code https://drive.google.com/file/d/1lU6AOQOx042Dgpzz11rpacqQFr8GzMfD/view?usp=sharing

Hi @tgordon can you please help on this?