@yaireo/tagify
Advanced tools
Comparing version 4.26.1 to 4.26.2
/* | ||
Tagify v4.26.1 - tags input component | ||
Tagify v4.26.2 - tags input component | ||
By: Yair Even-Or <vsync.design@gmail.com> | ||
@@ -4,0 +4,0 @@ https://github.com/yairEO/tagify |
{ | ||
"name": "@yaireo/tagify", | ||
"version": "4.26.1", | ||
"version": "4.26.2", | ||
"homepage": "https://github.com/yairEO/tagify", | ||
@@ -67,5 +67,7 @@ "description": "lightweight, efficient Tags input component in Vanilla JS / React / Angular [super customizable, tiny size & top performance]", | ||
"devDependencies": { | ||
"@playwright/test": "^1.43.1", | ||
"@rollup/plugin-terser": "^0.4.4", | ||
"@rollup/stream": "^3.0.1", | ||
"@swc/core": "^1.4.12", | ||
"@types/node": "^20.12.8", | ||
"beepbeep": "^1.3.0", | ||
@@ -110,5 +112,5 @@ "gulp": "^5.0.0", | ||
"version": "gulp build && git add .", | ||
"test": "echo \"No test specified\"", | ||
"test": "pnpm exec playwright test", | ||
"serve": "npx http-server -o index.html -c-1" | ||
} | ||
} |
@@ -80,7 +80,2 @@ import { decode, extend, getfirstTextNode, isChromeAndroidBrowser, isNodeTag, isWithinNodeTag, injectAtCaret, getSetTagData, fixCaretBetweenTags, placeCaretAfterNode } from './helpers' | ||
// listen to original input changes (unfortunetly this is the best way...) | ||
// https://stackoverflow.com/a/1949416/104380 | ||
clearInterval(this.listeners.main.originalInputValueObserverInterval) | ||
this.listeners.main.originalInputValueObserverInterval = setInterval(_CB.observeOriginalInputValue.bind(this), 500) | ||
// observers | ||
@@ -96,4 +91,16 @@ var inputMutationObserver = this.listeners.main.inputMutationObserver || new MutationObserver(_CB.onInputDOMChange.bind(this)); | ||
} | ||
this.events.bindOriginaInputListener.call(this) | ||
}, | ||
bindOriginaInputListener(delay) { | ||
const DELAY = (delay||0) + 500 | ||
if(!this.listeners.main) return | ||
// listen to original input changes (unfortunetly this is the best way...) | ||
// https://stackoverflow.com/a/1949416/104380 | ||
clearInterval(this.listeners.main.originalInputValueObserverInterval) | ||
this.listeners.main.originalInputValueObserverInterval = setInterval(this.events.callbacks.observeOriginalInputValue.bind(this), DELAY) | ||
}, | ||
bindGlobal( unbind ) { | ||
@@ -759,3 +766,3 @@ var _CB = this.events.callbacks, | ||
this.state.hasFocus = false | ||
!this.settings.userInput && this.dropdown.hide() | ||
this.dropdown.hide() | ||
} | ||
@@ -762,0 +769,0 @@ }, |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
No tests
QualityPackage does not have any tests. This is a strong signal of a poorly maintained or low quality package.
Found 1 instance in 1 package
4309573
5552
0
39