Skip to content

unable to set the openCustomDialog size in dialogOptions #115

@shrutikakhadyeCBRE

Description

@shrutikakhadyeCBRE

We want to implement a Modal in ADO plugin where we should be able to update the Modal size ie. The height and the width.

As there was the modal size issue, we were using panels as an alternative option.

We are using "ms.vss-features.host-dialog-service" service and openCustomDialog method
for implementing the Modal in our extension.

Below is the code snippet for openCustomDialog method.

import * as SDK from "azure-devops-extension-sdk";
SDK.init();

const openDialog = async() => {

const dialogService = await SDK.getService(
"ms.vss-features.host-dialog-service"
);
await dialogService.openCustomDialog(context.id + ".registration-form", {
message: "This is a custom message",
title: "Improve Form",
configuration: {
isModalOpen: true
},
onClose: (result) => {
if (result !== undefined) {
console.log("Dialog result:", result);
}
},
});
}

openDialog();

Also, we don’t have an option in the interface to manage the size of the Modal
https://learn.microsoft.com/en-us/javascript/api/azure-devops-extension-api/idialogoptions

Can someone help me with fixing this issue?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions