question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

feat: Add support to lock sheet modal height at set breakpoint

See original GitHub issue

Prerequisites

Describe the Feature Request

The sheet modal currently allows setting a new breakpoint after it has been presented, but this cannot be locked in place and the sheet will grow in height if the user attempts to scroll a list or date (month view). This feature request is to suggest adding a method to HTMLIonModalElement that enables/disables changing modal breakpoint.

Describe the Use Case

When attempting to scroll through a child element like ion-datetime in month-year presentation,

Describe Preferred Solution

Add a HTMLIonModalElement.lockBreakpoint(boolean?) that enables/disables breakpoint height changes

Describe Alternatives

No response

Related Code

async showTimelist() {
    if (this.rangeType === 'custom') {
      const modal = await this.modalCtrl.getTop();
      modal.setCurrentBreakpoint(1);
      modal.lockBreakpoint(true);
    }
 }

async onDateClick() {
    const modal = await this.modalCtrl.getTop();
    modal.lockBreakpoint();
  }

  async onDateBlur() {
    const modal = await this.modalCtrl.getTop();
    modal.lockBreakpoint(false);
  }

Additional Information

No response

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:1
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
liamdebeasicommented, Jul 19, 2022

Thanks! As noted in https://github.com/ionic-team/ionic-framework/issues/25641#issuecomment-1189021271 this would be solved by https://github.com/ionic-team/ionic-framework/issues/24631. Please follow that thread for updates on this feature.

1reaction
EinfachHanscommented, Jul 19, 2022

Duplicate of #24631 i guess? 😊

Read more comments on GitHub >

github_iconTop Results From Across the Web

feat: Add support to lock sheet modal height at set breakpoint ...
The sheet modal currently allows setting a new breakpoint after it has been presented, but this cannot be locked in place and the...
Read more >
How to limit the height of the modal? - Stack Overflow
Use viewport units with calc . Like this: .img-responsive { max-height: calc(100vh - 225px); } ...where the 225px corresponds to the combined height...
Read more >
August 2021 (version 1.60) - Visual Studio Code
Locked editor group preview - Keep a preferred editor layout by locking the editor group. Python extension testing updates - Better support for...
Read more >
Atmel Studio 7 User Guide - Microchip Technology
Atmel Studio provides a project management tool, source file editor, simulator, assembler, and front-end for C/C++, programming, and on-chip ...
Read more >
Bootstrap Modal Sizing - free examples & tutorial
Modal width, modal height, fullscreen modal, large modal with lg & xl modal ... These sizes kick in at certain breakpoints to avoid...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found