kolibri-design-system icon indicating copy to clipboard operation
kolibri-design-system copied to clipboard

KModal does not shrink when the content has a smaller height

Open AlexVelezLl opened this issue 1 year ago • 4 comments

Product

Studio

Expected behavior

The height of the KModal should dynamically adjust to the height of the content it renders.

Actual behavior

If for some reason the content of the KModal is expanded after its first render, the KModal is expanded accordingly, but if it is then shrinked, the KModal remains with the height of the expanded content, and this can lead to cases like this:

If initially we have a componente with a description like this:

image

But then we want to delete it, we get this view:

image

Cases like this occur in several places where the height of some element varies while the modal is displayed.

Steps to reproduce the issue

  1. Go to Studio and checkout the branch studio-usability-enhancements
  2. Edit the content nodes of a channel
  3. Edit the title and description of a node

Environment

  • OS: Ubuntu
  • Browser version: Chrome Version 122.0.6261.94 (Official Build) (64-bit)

AlexVelezLl avatar Mar 06 '24 13:03 AlexVelezLl

hey @AlexVelezLl great notice, but I think you listed this issue in the wrong Repo, correct me if am i wrong tho, I am really new to open source so..

shrudge avatar Mar 14 '24 15:03 shrudge

Hi @shrudge! No, the issue is in the correct repository. KDS is responsible for providing the components that will be used in other Kolibri products, you can learn more about KDS in the repo readme.

The issue is about the KModal component, here in KDS, probably it has something to do with the updateContentSectionStyle method.

AlexVelezLl avatar Mar 14 '24 16:03 AlexVelezLl

@AlexVelezLl Can I get this issue assigned?

galovdev avatar Mar 19 '24 16:03 galovdev

Hi @galovdev! Sure! Let me know if you have any question :)

AlexVelezLl avatar Mar 19 '24 17:03 AlexVelezLl

Closed by https://github.com/learningequality/kolibri-design-system/pull/590

MisRob avatar May 31 '24 08:05 MisRob