New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@yaireo/tagify

Package Overview
Dependencies
Maintainers
1
Versions
270
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@yaireo/tagify - npm Package Compare versions

Comparing version 2.25.3 to 2.26.0

jest-puppeteer.config.js

7

dist/react.tagify.js

@@ -44,5 +44,3 @@ import React from 'react';

return this.props.mode === 'textarea' ?
<textarea {...attrs} defaultValue={this.props.initialValue}></textarea> :
<input {...attrs} defaultValue={this.props.initialValue} />
return React.createElement(this.props.mode, Object.assign({}, attrs, {defaultValue: this.props.initialValue}))
}

@@ -52,5 +50,6 @@ }

Tags.defaultProps = {
value: []
value: [],
mode: "input"
}
export default Tags;
{
"name": "@yaireo/tagify",
"version": "2.25.3",
"version": "2.26.0",
"homepage": "https://github.com/yairEO/tagify",

@@ -13,2 +13,5 @@ "description": "lightweight, efficient Tags input component in Vanilla JS / React / Angular [super customizable, tiny size & top performance]",

},
"jest": {
"preset": "jest-puppeteer"
},
"author": {

@@ -32,3 +35,2 @@ "name": "Yair Even-Or",

"babel-core": "^6.26.3",
"babel-jest": "^24.8.0",
"babel-preset-env": "^1.7.0",

@@ -59,3 +61,4 @@ "beepbeep": "^1.2.2",

"gulp-watch": "^5.0.1",
"jest": "^24.8.0",
"jest": "^24.9.0",
"jest-puppeteer": "^4.3.0",
"path": "^0.12.7",

@@ -62,0 +65,0 @@ "puppeteer": "^1.19.0",

@@ -1,9 +0,9 @@

const puppeteer = require("puppeteer");
// const puppeteer = require("puppeteer");
const path = require("path");
const APP = `file:${path.join(__dirname, '../', 'index.html')}`
const APP = `file:${path.join(__dirname, '/', 'test.html')}`
let page;
let browser;
const width = 1920;
const height = 1080;
// let page;
// let browser;
// const width = 1920;
// const height = 1080;

@@ -35,15 +35,16 @@ let elmSelectors = {

beforeAll(async () => {
browser = await puppeteer.launch(
{
headless: false,
slowMo : 80,
args : [`--window-size = ${width},${height}`]
}
)
// browser = await puppeteer.launch(
// {
// headless: false,
// slowMo : 80,
// args : [`--window-size = ${width},${height}`]
// }
// )
page = await browser.newPage()
// page = await browser.newPage()
await page.setUserAgent('Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.100 Safari/537.36')
await page.setViewport({ width, height })
// await page.setUserAgent('Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.100 Safari/537.36')
// await page.setViewport({ width, height })
await page.goto(APP);

@@ -61,15 +62,20 @@ })

})
// reset the tags
// TODO: use https://www.npmjs.com/package/jest-environment-puppeteer
})
afterAll(() => {
browser.close();
})
// afterAll(() => {
// browser.close();
// })
describe("simple tests", () => {
it("duplicate tags removed", async () => {
// fit("access window object", async () => {
// const performance = JSON.parse(await page.evaluate(
// () => JSON.stringify( window.tagify__basic )
// ))
// expect(performance).toEqual(1000)
// }, 200)
it("duplicate tags removed", async (done) => {
// await page.goto(APP);

@@ -88,8 +94,9 @@ // await page.waitForSelector(".some_class_name");

await page.waitFor(1000)
setTimeout(async ()=> {
texts = await page.evaluate(getAllTagsTexts, elmSelectors);
expect(texts).toEqual(["css", "html", "javascript"]);
done()
}, 1000)
}, 0);
texts = await page.evaluate(getAllTagsTexts, elmSelectors);
expect(texts).toEqual(["css", "html", "javascript"]);
}, 2000);
it("first tagify input has focus", async () => {

@@ -213,3 +220,3 @@ await page.waitForSelector(elmSelectors.tagify.scope);

await page.type(elmSelectors.tagify.input, "ja");
await page.click('.tagify__dropdown__item', { clickCount:1 });
await page.click('.basicDropdown .tagify__dropdown__item', { clickCount:1 });

@@ -252,3 +259,3 @@ function getAllTagsTexts(elmSelectors) {

done()
}, 100)
}, 400)
}, 0)

@@ -255,0 +262,0 @@ })

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc