Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ng2-tag-input

Package Overview
Dependencies
Maintainers
1
Versions
109
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ng2-tag-input - npm Package Compare versions

Comparing version 0.2.5 to 0.2.6

dist/modules/components/accessor.d.ts

2

dist/components/tag-input.d.ts
import { ElementRef, EventEmitter, Renderer, OnInit } from '@angular/core';
import { TagInputAccessor } from './accessor';
export declare class TagInput extends TagInputAccessor implements OnInit {
export declare class TagInputComponent extends TagInputAccessor implements OnInit {
private element;

@@ -5,0 +5,0 @@ private renderer;

@@ -23,7 +23,6 @@ "use strict";

var keypress_actions_1 = require('./keypress-actions');
var icon_1 = require('./icon/icon');
var input_manager_1 = require('./input-manager');
var TagInput = (function (_super) {
__extends(TagInput, _super);
function TagInput(element, renderer) {
var TagInputComponent = (function (_super) {
__extends(TagInputComponent, _super);
function TagInputComponent(element, renderer) {
_super.call(this);

@@ -55,3 +54,3 @@ this.element = element;

}
TagInput.prototype.removeItem = function (item) {
TagInputComponent.prototype.removeItem = function (item) {
this.items = this.items.filter(function (_item) { return _item !== item; }).slice(0);

@@ -64,3 +63,3 @@ if (this.selectedTag === item) {

};
TagInput.prototype.addItem = function (isFromAutocomplete) {
TagInputComponent.prototype.addItem = function (isFromAutocomplete) {
if (isFromAutocomplete === void 0) { isFromAutocomplete = false; }

@@ -82,3 +81,3 @@ if (this.autocomplete && this.dropdown.state.selectedItem && !isFromAutocomplete) {

};
TagInput.prototype.selectItem = function (item) {
TagInputComponent.prototype.selectItem = function (item) {
if (this.readonly) {

@@ -92,7 +91,7 @@ var el = this.element.nativeElement;

};
TagInput.prototype.fireEvents = function (eventName, $event) {
TagInputComponent.prototype.fireEvents = function (eventName, $event) {
var _this = this;
this.listeners[eventName].forEach(function (listener) { return listener.call(_this, $event); });
};
TagInput.prototype.handleKeydown = function ($event, item) {
TagInputComponent.prototype.handleKeydown = function ($event, item) {
var action = keypress_actions_1.getAction($event.keyCode || $event.which);

@@ -103,12 +102,12 @@ var itemIndex = this.items.indexOf(item);

};
TagInput.prototype.setInputValue = function (value) {
TagInputComponent.prototype.setInputValue = function (value) {
var item = value ? this.transform(value) : '';
var control = this.getControl();
control.updateValue(item);
control.setValue(item);
return item;
};
TagInput.prototype.getControl = function () {
return this.form.find('item');
TagInputComponent.prototype.getControl = function () {
return this.form.get('item');
};
TagInput.prototype.focus = function () {
TagInputComponent.prototype.focus = function () {
if (this.readonly) {

@@ -119,6 +118,6 @@ return;

};
TagInput.prototype.blur = function () {
TagInputComponent.prototype.blur = function () {
this.input.blur.call(this);
};
Object.defineProperty(TagInput.prototype, "maxItemsReached", {
Object.defineProperty(TagInputComponent.prototype, "maxItemsReached", {
get: function () {

@@ -130,3 +129,3 @@ return this.maxItems !== undefined && this.items.length >= this.maxItems;

});
TagInput.prototype.escapeDropdown = function ($event) {
TagInputComponent.prototype.escapeDropdown = function ($event) {
var isArrowUp = $event.keyCode === 38;

@@ -138,3 +137,3 @@ var isFirstItemsSelected = this.dropdown.menu.items.first.isSelected;

};
TagInput.prototype.ngOnInit = function () {
TagInputComponent.prototype.ngOnInit = function () {
events_actions_1.addListener.call(this, constants_1.KEYDOWN, events_actions_1.backSpaceListener);

@@ -151,7 +150,7 @@ events_actions_1.addListener.call(this, constants_1.KEYDOWN, events_actions_1.customSeparatorKeys, this.separatorKeys.length > 0);

};
TagInput.prototype.ngAfterViewChecked = function () {
TagInputComponent.prototype.ngAfterViewChecked = function () {
this.input.element = this.input.element || this.element.nativeElement.querySelector('input');
this.tagElements = this.element.nativeElement.querySelectorAll('.tag');
};
TagInput.prototype.ngAfterViewInit = function () {
TagInputComponent.prototype.ngAfterViewInit = function () {
var vm = this;

@@ -180,63 +179,62 @@ vm.hasTemplate = vm.template && vm.template.nativeElement.childElementCount > 0;

__metadata('design:type', Array)
], TagInput.prototype, "separatorKeys", void 0);
], TagInputComponent.prototype, "separatorKeys", void 0);
__decorate([
core_1.Input(),
__metadata('design:type', String)
], TagInput.prototype, "placeholder", void 0);
], TagInputComponent.prototype, "placeholder", void 0);
__decorate([
core_1.Input(),
__metadata('design:type', String)
], TagInput.prototype, "secondaryPlaceholder", void 0);
], TagInputComponent.prototype, "secondaryPlaceholder", void 0);
__decorate([
core_1.Input(),
__metadata('design:type', Number)
], TagInput.prototype, "maxItems", void 0);
], TagInputComponent.prototype, "maxItems", void 0);
__decorate([
core_1.Input(),
__metadata('design:type', Boolean)
], TagInput.prototype, "readonly", void 0);
], TagInputComponent.prototype, "readonly", void 0);
__decorate([
core_1.Input(),
__metadata('design:type', Function)
], TagInput.prototype, "transform", void 0);
], TagInputComponent.prototype, "transform", void 0);
__decorate([
core_1.Input(),
__metadata('design:type', Object)
], TagInput.prototype, "validators", void 0);
], TagInputComponent.prototype, "validators", void 0);
__decorate([
core_1.Input(),
__metadata('design:type', Boolean)
], TagInput.prototype, "autocomplete", void 0);
], TagInputComponent.prototype, "autocomplete", void 0);
__decorate([
core_1.Input(),
__metadata('design:type', Array)
], TagInput.prototype, "autocompleteItems", void 0);
], TagInputComponent.prototype, "autocompleteItems", void 0);
__decorate([
core_1.Input(),
__metadata('design:type', Boolean)
], TagInput.prototype, "onlyFromAutocomplete", void 0);
], TagInputComponent.prototype, "onlyFromAutocomplete", void 0);
__decorate([
core_1.Output(),
__metadata('design:type', Object)
], TagInput.prototype, "onAdd", void 0);
], TagInputComponent.prototype, "onAdd", void 0);
__decorate([
core_1.Output(),
__metadata('design:type', Object)
], TagInput.prototype, "onRemove", void 0);
], TagInputComponent.prototype, "onRemove", void 0);
__decorate([
core_1.Output(),
__metadata('design:type', Object)
], TagInput.prototype, "onSelect", void 0);
], TagInputComponent.prototype, "onSelect", void 0);
__decorate([
core_1.ViewChild('template'),
__metadata('design:type', core_1.ElementRef)
], TagInput.prototype, "template", void 0);
], TagInputComponent.prototype, "template", void 0);
__decorate([
core_1.ViewChild(ng2_material_dropdown_1.Ng2Dropdown),
__metadata('design:type', Object)
], TagInput.prototype, "dropdown", void 0);
TagInput = __decorate([
], TagInputComponent.prototype, "dropdown", void 0);
TagInputComponent = __decorate([
core_1.Component({
selector: 'tag-input',
directives: [icon_1.DeleteIcon].concat(ng2_material_dropdown_1.NG2_DROPDOWN_DIRECTIVES, [forms_1.REACTIVE_FORM_DIRECTIVES]),
providers: [{

@@ -251,6 +249,6 @@ provide: forms_1.NG_VALUE_ACCESSOR,

__metadata('design:paramtypes', [core_1.ElementRef, core_1.Renderer])
], TagInput);
return TagInput;
], TagInputComponent);
return TagInputComponent;
}(accessor_1.TagInputAccessor));
exports.TagInput = TagInput;
exports.TagInputComponent = TagInputComponent;
//# sourceMappingURL=tag-input.js.map

@@ -1,2 +0,1 @@

declare const TagInput: any;
export { TagInput };
declare const components: any;

@@ -1,5 +0,4 @@

"use strict";
var TagInput = require('./dist/ng2-tag-input.bundle.js').TagInput;
exports.TagInput = TagInput;
exports.TagInput = TagInput;
var components = require('./dist/ng2-tag-input.bundle.js');
exports.TagInput = components.TagInput;
exports.TagInputModule = components.TagInputModule;
//# sourceMappingURL=index.js.map

@@ -10,3 +10,3 @@ (function webpackUniversalModuleDefinition(root, factory) {

root["ng2-tag-input"] = factory(root["@angular/core"], root["@angular/forms"], root["@angular/common"]);
})(this, function(__WEBPACK_EXTERNAL_MODULE_1__, __WEBPACK_EXTERNAL_MODULE_2__, __WEBPACK_EXTERNAL_MODULE_17__) {
})(this, function(__WEBPACK_EXTERNAL_MODULE_1__, __WEBPACK_EXTERNAL_MODULE_7__, __WEBPACK_EXTERNAL_MODULE_20__) {
return /******/ (function(modules) { // webpackBootstrap

@@ -60,4 +60,4 @@ /******/ // The module cache

__webpack_require__(1);
__webpack_require__(17);
module.exports = __webpack_require__(2);
__webpack_require__(20);
module.exports = __webpack_require__(7);

@@ -74,13 +74,13 @@

/***/ 2:
/***/ 7:
/***/ function(module, exports) {
module.exports = __WEBPACK_EXTERNAL_MODULE_2__;
module.exports = __WEBPACK_EXTERNAL_MODULE_7__;
/***/ },
/***/ 17:
/***/ 20:
/***/ function(module, exports) {
module.exports = __WEBPACK_EXTERNAL_MODULE_17__;
module.exports = __WEBPACK_EXTERNAL_MODULE_20__;

@@ -87,0 +87,0 @@ /***/ }

@@ -1,4 +0,4 @@

const TagInput = require('./dist/ng2-tag-input.bundle.js').TagInput;
const components = require('./dist/ng2-tag-input.bundle.js');
exports.TagInput = TagInput;
export {TagInput};
exports.TagInput = components.TagInput;
exports.TagInputModule = components.TagInputModule;
{
"name": "ng2-tag-input",
"version": "0.2.5",
"version": "0.2.6",
"description": "Tag Input component for Angular 2",

@@ -22,14 +22,14 @@ "scripts": {

"devDependencies": {
"@angular/common": "^2.0.0-rc.5",
"@angular/compiler": "^2.0.0-rc.5",
"@angular/core": "^2.0.0-rc.5",
"@angular/forms": "^0.3.0",
"@angular/http": "^2.0.0-rc.5",
"@angular/platform-browser": "^2.0.0-rc.5",
"@angular/platform-browser-dynamic": "^2.0.0-rc.5",
"@angular/platform-server": "^2.0.0-rc.5",
"@angular/common": "^2.0.0-rc.6",
"@angular/compiler": "^2.0.0-rc.6",
"@angular/core": "^2.0.0-rc.6",
"@angular/forms": "^2.0.0-rc.6",
"@angular/http": "^2.0.0-rc.6",
"@angular/platform-browser": "^2.0.0-rc.6",
"@angular/platform-browser-dynamic": "^2.0.0-rc.6",
"@angular/platform-server": "^2.0.0-rc.6",
"@angular/router": "^2.0.0-rc.2",
"autoprefixer": "^6.3.7",
"awesome-typescript-loader": "~0.16.2",
"core-js": "^2.2.0",
"core-js": "^2.4.1",
"css-loader": "^0.23.1",

@@ -52,3 +52,3 @@ "es6-promise": "3.0.2",

"reflect-metadata": "0.1.2",
"rxjs": "5.0.0-beta.6",
"rxjs": "5.0.0-beta.11",
"sass-loader": "^3.2.3",

@@ -66,6 +66,6 @@ "source-map-loader": "^0.1.5",

"webpack-merge": "^0.8.4",
"zone.js": "0.6.12"
"zone.js": "0.6.17"
},
"dependencies": {
"ng2-material-dropdown": "^0.2.5"
"ng2-material-dropdown": "^0.2.9"
},

@@ -72,0 +72,0 @@ "keywords": [

Sorry, the diff of this file is not supported yet

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 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