Skip to content

feat: useColumnWidth for inline longText editor#2506

Open
zewa666 wants to merge 4 commits intoghiscoding:masterfrom
zewa666:feat/longtext-resize
Open

feat: useColumnWidth for inline longText editor#2506
zewa666 wants to merge 4 commits intoghiscoding:masterfrom
zewa666:feat/longtext-resize

Conversation

@zewa666
Copy link
Copy Markdown
Collaborator

@zewa666 zewa666 commented Mar 30, 2026

the LongText editor is currently using a fixed size. If users modify the column width, the size of the inline editor currently does not scale along. This fixes it by introducing a new useColumnWidth option that negates the col setting and lets it grow/shrink along with the columns width.

@codecov
Copy link
Copy Markdown

codecov bot commented Mar 30, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.0%. Comparing base (5b9b288) to head (54c1003).
⚠️ Report is 10 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff            @@
##           master    #2506    +/-   ##
========================================
  Coverage   100.0%   100.0%            
========================================
  Files         195      196     +1     
  Lines       24393    24766   +373     
  Branches     8574     8749   +175     
========================================
+ Hits        24393    24766   +373     
Flag Coverage Δ
angular 100.0% <ø> (ø)
universal 100.0% <100.0%> (ø)

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.

@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new bot commented Mar 30, 2026

angular-slickgrid

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/angular-slickgrid@2506

aurelia-slickgrid

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/aurelia-slickgrid@2506

slickgrid-react

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/slickgrid-react@2506

slickgrid-vue

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/slickgrid-vue@2506

@slickgrid-universal/angular-row-detail-plugin

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/angular-row-detail-plugin@2506

@slickgrid-universal/aurelia-row-detail-plugin

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/aurelia-row-detail-plugin@2506

@slickgrid-universal/react-row-detail-plugin

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/react-row-detail-plugin@2506

@slickgrid-universal/vue-row-detail-plugin

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/vue-row-detail-plugin@2506

@slickgrid-universal/binding

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/binding@2506

@slickgrid-universal/common

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/common@2506

@slickgrid-universal/composite-editor-component

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/composite-editor-component@2506

@slickgrid-universal/custom-footer-component

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/custom-footer-component@2506

@slickgrid-universal/custom-tooltip-plugin

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/custom-tooltip-plugin@2506

@slickgrid-universal/empty-warning-component

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/empty-warning-component@2506

@slickgrid-universal/event-pub-sub

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/event-pub-sub@2506

@slickgrid-universal/excel-export

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/excel-export@2506

@slickgrid-universal/graphql

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/graphql@2506

@slickgrid-universal/odata

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/odata@2506

@slickgrid-universal/pagination-component

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/pagination-component@2506

@slickgrid-universal/pdf-export

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/pdf-export@2506

@slickgrid-universal/row-detail-view-plugin

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/row-detail-view-plugin@2506

@slickgrid-universal/rxjs-observable

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/rxjs-observable@2506

@slickgrid-universal/sql

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/sql@2506

@slickgrid-universal/text-export

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/text-export@2506

@slickgrid-universal/utils

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/utils@2506

@slickgrid-universal/vanilla-bundle

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/vanilla-bundle@2506

@slickgrid-universal/vanilla-force-bundle

npm i https://pkg.pr.new/ghiscoding/slickgrid-universal/@slickgrid-universal/vanilla-force-bundle@2506

commit: 54c1003

@ghiscoding
Copy link
Copy Markdown
Owner

does that scale the editor with the same width as the column OR does that auto-grow with text entered? Can you maybe add a print screen?

@zewa666
Copy link
Copy Markdown
Collaborator Author

zewa666 commented Mar 30, 2026

Sure, here you are, nope it doesnt it really only affects the width when it opens.
https://github.com/user-attachments/assets/3617233b-4f48-4d7e-9828-27f83ffcce1a

@ghiscoding
Copy link
Copy Markdown
Owner

ok so it's the column width, do you know if there's a reason why it's a bit wider by about 5-10px?

@zewa666
Copy link
Copy Markdown
Collaborator Author

zewa666 commented Mar 30, 2026

I would assume its because of the borders/paddings. need to check this more in detail. I'm using the offsetWidth of the above container, so perhaps that also needs a fixed amount of correction

@ghiscoding
Copy link
Copy Markdown
Owner

ghiscoding commented Mar 30, 2026

there's a width that doesn't include padding I think, you might want to try all 3 available element widths to see which one is the closest.

I'm finishing up a new SQL Backend Service for MSSQL project (hopefully useful for them), then I'll probably release a new version tonight. Did you have anything else after this PR?

@zewa666
Copy link
Copy Markdown
Collaborator Author

zewa666 commented Mar 30, 2026

mssql backend? I'm all ears 😁

all good aside from this one. gonna do an upgrade in 2-3 weeks

@ghiscoding
Copy link
Copy Markdown
Owner

ghiscoding commented Mar 30, 2026

mssql backend? I'm all ears 😁

lol it's a new Backend Service I'm adding, it's similar to the existing OData/GraphQL but produces SQL query string instead. I'm assuming this will resolve an issue that the MSSQL VScode extension project currently have "Edit Data filters are only applied to prefetched rows", but I think they haven't realized yet that is what they need, I'm adding it nonetheless and see if they adopt it 😆 I think it can be useful for some of us anyway, so... and Ag-Grid also have something similar https://www.ag-grid.com/react-data-grid/server-side-operations-nodejs/#server-endpoint

I've put an animated gif in the new PR #2504, I'm pretty much done with it I think

@zewa666
Copy link
Copy Markdown
Collaborator Author

zewa666 commented Mar 30, 2026

oh dang just 2years too late 🤣 jokes aside though, we're still happy with the OData integration and I'm also way more confident exposing that middlelayer vs letting users directly bomb our DB with unoptimzed queries 😅

@ghiscoding
Copy link
Copy Markdown
Owner

ghiscoding commented Mar 30, 2026

yeah I think it just gives another way of connecting DB if you can't use OData/GraphQL, so it might just reach new users with this approach. For cheap users like us who don't want to give thousand of dollars to Ag-Grid 😆 Looking at their docs, it's unbelievable how many simple features are reserved for the pro license. Also if you didn't know yet, Ag was a short for Angular-Grid at the time, they just renamed it with a shorter and non-Angular name but their origin is really based on mainly SlickGrid and UI-Grid at the time.
https://blog.ag-grid.com/why-the-world-needed-another-angular-grid/

Are you going to try the other width or should I just merge as is and you might revisit in the future?

@zewa666
Copy link
Copy Markdown
Collaborator Author

zewa666 commented Mar 30, 2026

I can check again tomorrow at work, timezones are a real productivity killer ;)

@ghiscoding
Copy link
Copy Markdown
Owner

ghiscoding commented Mar 30, 2026

just 6 hours 🤣
np I'll release tomorrow then.. Thanks

@zewa666
Copy link
Copy Markdown
Collaborator Author

zewa666 commented Mar 31, 2026

Ok, its actually a bit more involved since I need to exclude the paddings yet also fix the initial positioning of the LongText component too (it wasn't respecting the left padding of the cell so it starts a bit off the cell to the left). Its now aligned with the cell start/end

2026-03-31_08h47_11

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants