Azure / Azure/api-management-developer-portal

Dynamically Sizing Custom Widgets

Open
#2,826 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
545
Forks
360
PR merge metrics
No merged PRs in 30d

Description

## Bug description
Previously, custom widgets in the self hosted portal were able to be dynamically sized. With upgrades over the past few years after widgets were sandboxed into an iframe, dynamic sizing does not work anymore.

This reduces the flexibility of custom widgets since the developer may not know the exact height of content at runtime. When this happens now, the widget keeps its constant height and has scrollbars for the overflow content. But that does not give a good UI experience.

Is this a bug or was dynamic sizing meant to be taken away?

## Reproduction steps

1. Create a custom widget, but keep the height at the default 500px for custom widgets.
2. Add content to the widget that has a height greater than 500px.
3. View the widget on the portal. It now had a vertical scroll bar

## Expected behavior
An option to dynamically size the widget based off it's contents like was available initially with custom widgets

## Is self-hosted portal?
Yes

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing the issue with a self-hosted portal custom widget whose content exceeds the default 500px height, then inspect how the sandboxed iframe currently determines the widget height. Done means the widget can size itself to its contents without the unnecessary vertical scrollbar, while preserving the stated default behavior for existing widgets.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, typescript
Domain
frontend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.