Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
0.4.0
->1.0.2
Release Notes
francoischalifour/medium-zoom
v1.0.2
Compare Source
v1.0.1
Compare Source
Bug fixes
71b46fa
)v1.0.0
Compare Source
New features
open()
,close()
andtoggle()
) return the zoom object to allow method calls to be chained.open()
,close()
andtoggle()
return promises resolving with the zoom for acting accordingly when the animation is completed. To remain compatible with IE10, promises are converted to no-operation functions if unavailable.Options
background
supports thebackground
CSS property (not onlybackground-color
)Methods
attach(...selectors: string[]|Element[]|NodeList[]|Array[]) => Zoom
clone(options?: object) => Zoom
getOptions() => object
getImages() => Element[]
getZoomedImage() => Element
Events
update
method is calledAdd TypeScript definitions
Improve documentation
Bug fixes
264c81f
)srcset
attribute (#51)Breaking changes
No images selected by default. Prior to version 1, all scaled images (via HTML or CSS properties) were added to the zoom when calling
mediumZoom()
. Now, callingmediumZoom()
without selector does not attach any images to the zoom. This change is necessary for having a more predictable behavior and a more composable API.Options
metaClick
was removedMethods
show() => void
→open({ target?: Element }) => Promise<Zoom>
hide() => void
→close() => Promise<Zoom>
toggle() => void
→toggle({ target?: Element }) => Promise<Zoom>
detach() => void
→detach(...selectors: string[]|Element[]|NodeList[]|Array[]) => Zoom
update(options: object) => void
→update(options: object) => Zoom
addEventListeners(type: string, listener: Function) => void
→on(type: string, listener: Function, options?: object) => Zoom
removeEventListeners(type: string, listener: Function) => void
→off(type: string, listener: Function, options?: object) => Zoom
Attributes
data-zoom-target
→data-zoom-src
Events
Special thanks
@tuelsch, @garviand and @mimamuh.
Renovate configuration
📅 Schedule: At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻️ Rebasing: Whenever PR becomes conflicted, or if you modify the PR title to begin with "
rebase!
".🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Renovate Bot. View repository job log here.