If you do not turn on asDockItem, then, by default, the iframe and your HTML occupy the whole of the chart panel: width:100%, height:100%. You can use the style settings to change this. For example, making the HTML 200px by 50px, positioned in the bottom right corner of the panel:
Framework.ChartChange({
mode: "active", // or "all", or "single" plus a .chartId value
command: "create-html",
options: {
foreground: true,
style: {
width: "200px",
height: "50px",
bottom: "0px",
right: "0px",
},
…
}
});