UNPKG

5.39 kBMarkdownView Raw
1# Changelog
2
3All notable changes to this project will be documented in this file.
4
5The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
6and this project adheres to
7[Semantic Versioning](http://semver.org/spec/v2.0.0.html).
8
9## [Unreleased]
10
11### Added
12
13- Support for `behavior`, `block` and `inline` options, from [the spec](https://developer.mozilla.org/en-US/docs/Web/API/Element/scrollIntoView).
14- `scrollMode: "if-needed" | "always"` to control the `if-needed` behavior, based on [the csswg proposal to the spec](https://github.com/w3c/csswg-drafts/pull/1805).
15
16### Removed
17
18- `centerIfNeeded`, use `scrollMode: "if-needed", block: "center"` instead.
19- `duration` to trigger animation, use [`smooth-scroll-into-view-if-needed`](https://github.com/stipsan/smooth-scroll-into-view-if-needed) instead.
20- `handleScroll(parent, {scrollLeft, scrollTop}, options)`, use `behavior: function(actions)` instead, where `actions` is an array of `{el, top, left}` allowing you to scroll everything in parallel or in a sequence, it's up to you.
21- `offset`, use wrapper elements and CSS like padding or margins instead.
22
23## [1.5.0] - 2018-02-25
24
25### Added
26
27- `sideEffects: false` in package.json to enable optimizations introduced in webpack v4.
28
29## [1.4.0] - 2017-11-17
30
31### Added
32
33- New `handleScroll` option allows customizing scrolling behavior.
34
35### Changed
36
37- Animation logic is separated from scroll calculation logic. This allows skip
38 importing animation dependencies and reduces bundle sizes when you don't need
39 the built in animation feature.
40
41## [1.3.0] - 2017-11-12
42
43### Added
44
45- New API interface (#148 @tonybdesign)
46
47## [1.2.8] - 2017-11-05
48
49### Fixed
50
51- Missing TypeScript definitions and rollup/webpack pkg.module files from
52 published package (#145)
53
54## [1.2.7] - 2017-11-05
55
56### Fixed
57
58- Package published on npm contained unnecessary files bloating the package
59 (#144)
60
61## [1.2.6] - 2017-11-05
62
63### Fixed
64
65- Don't use postinstall as it runs in userland (#143)
66
67## [1.2.5] - 2017-11-05
68
69### Fixed
70
71- Migrate tests to
72 [new page](https://stipsan.github.io/scroll-into-view-if-needed/) that
73 showcases how it works (#141)
74
75## [1.2.4] - 2017-11-05
76
77### Fixed
78
79- TypeScript requires HTMLElement when it should accept Element (#140)
80
81## [1.2.3] - 2017-11-04
82
83### Fixed
84
85- Incorrect TypeScript declarations and export format (#136)
86
87## [1.2.2] - 2017-10-29
88
89### Fixed
90
91- Incorrect export declaration in TS typings (#132)
92
93## [1.2.1] - 2017-10-02
94
95### Fixed
96
97- Fifth option should be optional (#129)
98
99## [1.2.0] - 2017-10-01
100
101### Added
102
103- Set offset feature (#127 @iwangulenko)
104
105## [1.1.1] - 2017-10-01
106
107### Fixed
108
109- Windows compatibility and CommonJS interop change back to Babel 5
110 functionality (#121 @khell)
111
112## [1.1.0] - 2017-03-29
113
114### Added
115
116- An optional argument finalElement was added to limit the scope of the function
117 (#108 @hemnstill)
118
119## [1.0.7] - 2017-03-14
120
121### Added
122
123- MIT License (#107 @JKillian)
124
125### Changed
126
127- Reduced size of dist build by switching from rollup to babel (#106 @JKillian)
128
129## [1.0.6] - 2016-11-17
130
131### Changed
132
133- Updated typescript definition making options optional (#75 @pelotom)
134
135## [1.0.5] - 2016-11-12
136
137### Fixed
138
139- Fix TypeScript definition file issues (#74 @forabi)
140
141### Documentation
142
143- React example snippet in readme.
144
145## [1.0.4] - 2016-10-31
146
147### Added
148
149- Changelog readme.
150- TypeScript definition file (#73 @forabi)
151
152## 1.0.3 - 2016-09-30
153
154### Documentation
155
156- link to official ponyfill page (#68 @sindresorhus)
157
158## 1.0.2 - 2016-04-18
159
160### Added
161
162- Greenkeeper
163
164### Fixes
165
166- Incomatibility with default webpack config.
167
168## 1.0.1 - 2016-04-18
169
170- PULLED: accidentally pushed incomplete build to npm!
171
172## 1.0.0 - 2016-04-18
173
174### Added
175
176- Initial release.
177
178[unreleased]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.5.0...HEAD
179[1.5.0]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.4.0...v1.5.0
180[1.4.0]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.3.0...v1.4.0
181[1.3.0]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.2.8...v1.3.0
182[1.2.8]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.2.7...v1.2.8
183[1.2.7]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.2.6...v1.2.7
184[1.2.6]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.2.5...v1.2.6
185[1.2.5]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.2.4...v1.2.5
186[1.2.4]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.2.3...v1.2.4
187[1.2.3]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.2.2...v1.2.3
188[1.2.2]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.2.1...v1.2.2
189[1.2.1]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.2.0...v1.2.1
190[1.2.0]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.1.1...v1.2.0
191[1.1.1]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.1.0...v1.1.1
192[1.1.0]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.0.7...v1.1.0
193[1.0.7]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.0.6...v1.0.7
194[1.0.6]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.0.5...v1.0.6
195[1.0.5]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.0.4...v1.0.5
196[1.0.4]: https://github.com/stipsan/scroll-into-view-if-needed/compare/v1.0.3...v1.0.4