Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
swipe-it
Advanced tools
Readme
Swipe a custom element out.
Give me a feed back if you have any problem with this.
bind
and unbind
var tap = require('component-tap-event')
var SwipeIt = require('swipe-it')
var template = require('./template.html')
var s = new SwipeIt(template)
s.bind(document.getElementById('list'), 'li')
s.delegate('touchstart', '.remove', tap(function(e, li) {
// remove holder and swiped element with transition
s.clear().then(function() {
// callback on element removed
})
}))
start
emit with swipe element when swipe startend
emit with swipe element after swiped element reset backclear
emit with swipe element just before remove transition begin, used for change the style of swiped element for transitiontemplate
string or element for element swiped outopts
optional optionsopts.ease
a ease function or string for reset&expand animation, default out-quad
opts.duration
duration for reset in millisecon, default 350Bind swipe event to parentNode with delegated selector
Bind to listRender instance, which enables automate model reative-lite bind
Ignore touchstart event from target that within element matches selector
Set a optional render function for swiped out element , fn
is passed with related swiped element(which matches the bind selector) and template
string, fn
should return an element
Delegate handler
of type
event with matched selector
within swiped out element, handler is called with original event and related swiped element.
Reset the swiped element to original stat with animation, return promise
Remove the swiped element and related holder with transition specified by duration
(default 300) in millisecond and ease
timing function, return promise.
Unbind all event listeners, and reset status synchronizely, could be active again be calling bind
FAQs
Swipe a custom element out with animation
The npm package swipe-it receives a total of 2 weekly downloads. As such, swipe-it popularity was classified as not popular.
We found that swipe-it demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.