Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat(AcePopup): adding getDataContainer and setVisibleRows methods #5708

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
marinsokol5 wants to merge 2 commits into master
base: master
Choose a base branch
Loading
from popup-api

Conversation

@marinsokol5
Copy link
Contributor

@marinsokol5 marinsokol5 commented Dec 24, 2024

Description of changes:

  • Extending AcePopup to have a method for setting number of visible rows and a method for fetching the HTML element where data is rendered into. The latter is especially useful for consumers who want to modify the popup themselves, which they often need to if they use the popup within something like https://www.w3.org/WAI/ARIA/apg/patterns/combobox/.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Pull Request Checklist:

Copy link

codecov bot commented Dec 24, 2024
edited
Loading

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 87.02%. Comparing base (de21d50) to head (e7a43b6).
Report is 80 commits behind head on master.

Additional details and impacted files
@@ Coverage Diff @@
## master #5708 +/- ##
=======================================
 Coverage 87.02% 87.02% 
=======================================
 Files 598 598 
 Lines 43593 43613 +20 
 Branches 7163 7163 
=======================================
+ Hits 37936 37956 +20 
 Misses 5657 5657 
Flag Coverage Δ
unittests 87.02% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

* @returns {HTMLDivElement} element
*/
popup.getDataContainer = function() {
return this.renderer.$textLayer.element;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was there a reason for exposing renderer.$textLayer.element here and not, for example, renderer.content or render.scroller? (which encompass all layers of the popup and might allow more flexibility when styling the popup)

* Number of rows shown in the popup.
* @param {number} rows
*/
popup.setVisibleRows = function(rows) {
Copy link
Member

@nightwing nightwing Jan 16, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not use popup.setOption("maxLInes", rows) instead of adding new api?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@nightwing nightwing nightwing left review comments

@akoreman akoreman akoreman left review comments

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /