Skip to content
This repository was archived by the owner on Jun 1, 2025. It is now read-only.

feat(resizer): add calculateAvailableSizeBy container option, issue #175 #179

Merged
merged 6 commits into from
May 10, 2019

Conversation

ghiscoding
Copy link
Owner

@ghiscoding ghiscoding commented May 7, 2019

  • bring an extra option to calculate available grid size by their container size

  • reference issue #175, mostly this post in particular

  • add full test suite

  • test in real life project

  • feedback from external users

- bring an extra option to calculate available grid size by their container size
@codecov-io
Copy link

codecov-io commented May 7, 2019

Codecov Report

Merging #179 into master will increase coverage by 0.42%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #179      +/-   ##
==========================================
+ Coverage   32.46%   32.88%   +0.42%     
==========================================
  Files         149      149              
  Lines        6287     6294       +7     
  Branches     1903     1988      +85     
==========================================
+ Hits         2041     2070      +29     
+ Misses       4238     4215      -23     
- Partials        8        9       +1
Impacted Files Coverage Δ
...p/modules/angular-slickgrid/global-grid-options.ts 75% <ø> (ø) ⬆️
...ules/angular-slickgrid/services/resizer.service.ts 95.37% <100%> (+23.52%) ⬆️
...lickgrid/components/angular-slickgrid.component.ts 59.88% <100%> (ø) ⬆️
.../modules/angular-slickgrid/filters/selectFilter.ts 12.69% <0%> (-0.07%) ⬇️
.../modules/angular-slickgrid/editors/selectEditor.ts 14.22% <0%> (-0.06%) ⬇️
...dules/angular-slickgrid/services/filter.service.ts 16.98% <0%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5e65e77...ce1ea93. Read the comment docs.

- also tweak some small issues found in the service & use window.innerHeight instead of jQuery(window) which comes to the same
@ghiscoding
Copy link
Owner Author

@amathew-statestreet-com
Would it be possible for you to test the new code?
I just finished adding a full test suite and I tested it with our real life project, seems all fine on my side but I didn't test the new flag with real html (thought the flag is covered in the test).

Also note I renamed attachAutoResizeDataGrid to bindAutoResizeDataGrid, just in case you want to copy the Service code only, just rename the method to previous name and you should be good to go.

Note about the Jest tests, it doesn't fully test everything since I learned the hard way that JSDOM always return 0 height on a div (spent half a day on this), so I can't fully test a browser rendering.

Ghislain Beaulac added 3 commits May 8, 2019 21:37
- note that we are staying on previous version of jest-preset-angular because version 7+ has some startup time issue
@amathew-statestreet-com
Copy link

sure. I will do a test today and will let you know if everything look ok.

@ghiscoding ghiscoding merged commit ef32b1e into master May 10, 2019
@ghiscoding ghiscoding deleted the feat/resizer-by-container branch May 11, 2019 00:39
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants