@progress/kendo-angular-listbox 1.0.5 → 11.0.0-develop.80
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/NOTICE.txt +3 -3
- package/constants.d.ts +2 -2
- package/data-binding.directive.d.ts +1 -1
- package/{esm2015/constants.js → esm2020/constants.mjs} +6 -6
- package/{esm2015/data-binding.directive.js → esm2020/data-binding.directive.mjs} +6 -5
- package/{esm2015/main.js → esm2020/index.mjs} +1 -1
- package/{esm2015/item-selectable.directive.js → esm2020/item-selectable.directive.mjs} +5 -4
- package/{esm2015/item-template.directive.js → esm2020/item-template.directive.mjs} +5 -5
- package/{esm2015/listbox.component.js → esm2020/listbox.component.mjs} +53 -37
- package/{esm2015/listbox.module.js → esm2020/listbox.module.mjs} +5 -5
- package/{esm2015/package-metadata.js → esm2020/package-metadata.mjs} +2 -2
- package/{esm2015/kendo-angular-listbox.js → esm2020/progress-kendo-angular-listbox.mjs} +2 -2
- package/{esm2015/selection.service.js → esm2020/selection.service.mjs} +4 -4
- package/{esm2015/size.js → esm2020/size.mjs} +1 -1
- package/{esm2015/toolbar.js → esm2020/toolbar.mjs} +1 -1
- package/{esm2015/util.js → esm2020/util.mjs} +1 -1
- package/fesm2015/{kendo-angular-listbox.js → progress-kendo-angular-listbox.mjs} +75 -59
- package/fesm2020/progress-kendo-angular-listbox.mjs +603 -0
- package/{main.d.ts → index.d.ts} +2 -1
- package/item-selectable.directive.d.ts +1 -1
- package/item-template.directive.d.ts +1 -1
- package/listbox.component.d.ts +5 -2
- package/listbox.module.d.ts +1 -1
- package/package-metadata.d.ts +1 -1
- package/package.json +31 -57
- package/{kendo-angular-listbox.d.ts → progress-kendo-angular-listbox.d.ts} +2 -2
- package/schematics/ngAdd/index.js +1 -5
- package/selection.service.d.ts +1 -1
- package/size.d.ts +1 -1
- package/toolbar.d.ts +1 -1
- package/util.d.ts +1 -1
- package/bundles/kendo-angular-listbox.umd.js +0 -5
- package/schematics/ngAdd/index.js.map +0 -1
package/package.json
CHANGED
|
@@ -1,14 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@progress/kendo-angular-listbox",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "11.0.0-develop.80",
|
|
4
4
|
"description": "Kendo UI for Angular ListBox",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
6
6
|
"author": "Progress",
|
|
7
7
|
"homepage": "https://www.telerik.com/kendo-angular-ui/components/",
|
|
8
|
-
"repository": {
|
|
9
|
-
"type": "git",
|
|
10
|
-
"url": "https://github.com/telerik/kendo-angular-listbox.git"
|
|
11
|
-
},
|
|
12
8
|
"bugs": {
|
|
13
9
|
"url": "https://github.com/telerik/kendo-angular"
|
|
14
10
|
},
|
|
@@ -21,64 +17,42 @@
|
|
|
21
17
|
"@progress": {
|
|
22
18
|
"friendlyName": "ListBox"
|
|
23
19
|
},
|
|
24
|
-
"dependencies": {
|
|
25
|
-
"@progress/kendo-common": "^0.2.2",
|
|
26
|
-
"@progress/kendo-schematics": "^3.0.0",
|
|
27
|
-
"tslib": "^2.3.1"
|
|
28
|
-
},
|
|
29
20
|
"peerDependencies": {
|
|
30
|
-
"@angular/
|
|
31
|
-
"@angular/
|
|
32
|
-
"@
|
|
33
|
-
"@
|
|
34
|
-
"@progress/kendo-
|
|
35
|
-
"@progress/kendo-
|
|
36
|
-
"@progress/kendo-
|
|
21
|
+
"@angular/animations": "13 - 15",
|
|
22
|
+
"@angular/common": "13 - 15",
|
|
23
|
+
"@angular/core": "13 - 15",
|
|
24
|
+
"@angular/platform-browser": "13 - 15",
|
|
25
|
+
"@progress/kendo-common": "^0.2.2",
|
|
26
|
+
"@progress/kendo-licensing": "^1.0.2",
|
|
27
|
+
"@progress/kendo-angular-buttons": "11.0.0-develop.80",
|
|
28
|
+
"@progress/kendo-angular-common": "11.0.0-develop.80",
|
|
29
|
+
"@progress/kendo-angular-l10n": "11.0.0-develop.80",
|
|
30
|
+
"@progress/kendo-angular-popup": "11.0.0-develop.80",
|
|
31
|
+
"@progress/kendo-angular-schematics": "11.0.0-develop.80",
|
|
37
32
|
"rxjs": "^6.5.3 || ^7.0.0"
|
|
38
33
|
},
|
|
39
|
-
"
|
|
40
|
-
"
|
|
41
|
-
"path": "./node_modules/cz-conventional-changelog"
|
|
42
|
-
},
|
|
43
|
-
"ghooks": {
|
|
44
|
-
"commit-msg": "validate-commit-msg"
|
|
45
|
-
},
|
|
46
|
-
"validate-commit-msg": {
|
|
47
|
-
"types": [
|
|
48
|
-
"feat",
|
|
49
|
-
"fix",
|
|
50
|
-
"docs",
|
|
51
|
-
"style",
|
|
52
|
-
"refactor",
|
|
53
|
-
"perf",
|
|
54
|
-
"test",
|
|
55
|
-
"chore",
|
|
56
|
-
"revert"
|
|
57
|
-
],
|
|
58
|
-
"warnOnFail": false,
|
|
59
|
-
"maxSubjectLength": 100
|
|
60
|
-
}
|
|
34
|
+
"dependencies": {
|
|
35
|
+
"tslib": "^2.3.1"
|
|
61
36
|
},
|
|
62
37
|
"schematics": "./schematics/collection.json",
|
|
63
|
-
"
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
38
|
+
"module": "fesm2015/progress-kendo-angular-listbox.mjs",
|
|
39
|
+
"es2020": "fesm2020/progress-kendo-angular-listbox.mjs",
|
|
40
|
+
"esm2020": "esm2020/progress-kendo-angular-listbox.mjs",
|
|
41
|
+
"fesm2020": "fesm2020/progress-kendo-angular-listbox.mjs",
|
|
42
|
+
"fesm2015": "fesm2015/progress-kendo-angular-listbox.mjs",
|
|
43
|
+
"typings": "progress-kendo-angular-listbox.d.ts",
|
|
44
|
+
"exports": {
|
|
45
|
+
"./package.json": {
|
|
46
|
+
"default": "./package.json"
|
|
70
47
|
},
|
|
71
|
-
"
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
48
|
+
".": {
|
|
49
|
+
"types": "./progress-kendo-angular-listbox.d.ts",
|
|
50
|
+
"esm2020": "./esm2020/progress-kendo-angular-listbox.mjs",
|
|
51
|
+
"es2020": "./fesm2020/progress-kendo-angular-listbox.mjs",
|
|
52
|
+
"es2015": "./fesm2015/progress-kendo-angular-listbox.mjs",
|
|
53
|
+
"node": "./fesm2015/progress-kendo-angular-listbox.mjs",
|
|
54
|
+
"default": "./fesm2020/progress-kendo-angular-listbox.mjs"
|
|
55
|
+
}
|
|
76
56
|
},
|
|
77
|
-
"main": "bundles/kendo-angular-listbox.umd.js",
|
|
78
|
-
"module": "fesm2015/kendo-angular-listbox.js",
|
|
79
|
-
"es2015": "fesm2015/kendo-angular-listbox.js",
|
|
80
|
-
"esm2015": "esm2015/kendo-angular-listbox.js",
|
|
81
|
-
"fesm2015": "fesm2015/kendo-angular-listbox.js",
|
|
82
|
-
"typings": "kendo-angular-listbox.d.ts",
|
|
83
57
|
"sideEffects": false
|
|
84
58
|
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright ©
|
|
2
|
+
* Copyright © 2022 Progress Software Corporation. All rights reserved.
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
5
|
/**
|
|
6
6
|
* Generated bundle index. Do not edit.
|
|
7
7
|
*/
|
|
8
8
|
/// <amd-module name="@progress/kendo-angular-listbox" />
|
|
9
|
-
export * from './
|
|
9
|
+
export * from './index';
|
|
@@ -1,7 +1,3 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
1
|
"use strict";
|
|
6
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
3
|
const schematics_1 = require("@angular-devkit/schematics");
|
|
@@ -16,6 +12,6 @@ function default_1(options) {
|
|
|
16
12
|
// Peer of kendo-angular-buttons
|
|
17
13
|
"@progress/kendo-angular-popup": "^5.0.0"
|
|
18
14
|
} });
|
|
19
|
-
return schematics_1.externalSchematic('@progress/kendo-schematics', 'ng-add', finalOptions);
|
|
15
|
+
return (0, schematics_1.externalSchematic)('@progress/kendo-angular-schematics', 'ng-add', finalOptions);
|
|
20
16
|
}
|
|
21
17
|
exports.default = default_1;
|
package/selection.service.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright ©
|
|
2
|
+
* Copyright © 2022 Progress Software Corporation. All rights reserved.
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
5
|
import { EventEmitter } from "@angular/core";
|
package/size.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright ©
|
|
2
|
+
* Copyright © 2022 Progress Software Corporation. All rights reserved.
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
5
|
/**
|
package/toolbar.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright ©
|
|
2
|
+
* Copyright © 2022 Progress Software Corporation. All rights reserved.
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
5
|
/**
|
package/util.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright ©
|
|
2
|
+
* Copyright © 2022 Progress Software Corporation. All rights reserved.
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
5
|
import { ActionName } from './toolbar';
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/core"),require("@progress/kendo-licensing"),require("rxjs"),require("@progress/kendo-common"),require("@angular/common"),require("@progress/kendo-angular-buttons"),require("@progress/kendo-angular-common")):"function"==typeof define&&define.amd?define("KendoAngularListbox",["exports","@angular/core","@progress/kendo-licensing","rxjs","@progress/kendo-common","@angular/common","@progress/kendo-angular-buttons","@progress/kendo-angular-common"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).KendoAngularListbox={},e.ng.core,e.KendoLicensing,e.rxjs,e.KendoCommon,e.ng.common,e.KendoAngularButtons,e.KendoAngularCommon)}(this,function(e,i,s,r,o,t,n,l){"use strict";function a(n){var o;return n&&n.__esModule?n:(o=Object.create(null),n&&Object.keys(n).forEach(function(e){var t;"default"!==e&&(t=Object.getOwnPropertyDescriptor(n,e),Object.defineProperty(o,e,t.get?t:{enumerable:!0,get:function(){return n[e]}}))}),o.default=n,Object.freeze(o))}var c=a(i),d=a(t),p=a(n),m={name:"@progress/kendo-angular-listbox",productName:"Kendo UI for Angular",productCodes:["KENDOUIANGULAR","KENDOUICOMPLETE"],publishDate:1668698772,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-angular-ui/my-license/?utm_medium=product&utm_source=kendoangular&utm_campaign=kendo-ui-angular-purchase-license-keys-warning"},u=(g.prototype.select=function(e){this.selectedIndex=e,this.onSelect.next({index:this.selectedIndex})},g.prototype.isSelected=function(e){return e===this.selectedIndex},g.prototype.clearSelection=function(){this.selectedIndex=null},g);function g(){this.onSelect=new i.EventEmitter,this.selectedIndex=null}u.ɵfac=c.ɵɵngDeclareFactory({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:u,deps:[],target:c.ɵɵFactoryTarget.Injectable}),u.ɵprov=c.ɵɵngDeclareInjectable({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:u}),c.ɵɵngDeclareClassMetadata({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:u,decorators:[{type:i.Injectable}]});function b(e,t){var n;return I(e)?I(t)&&I(n=e)&&"object"==typeof n?o.getter(t)(e):e:null}function f(){return!1}var h=function(e){this.templateRef=e},y=(h.ɵfac=c.ɵɵngDeclareFactory({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:h,deps:[{token:c.TemplateRef}],target:c.ɵɵFactoryTarget.Directive}),h.ɵdir=c.ɵɵngDeclareDirective({minVersion:"12.0.0",version:"12.2.16",type:h,selector:"[kendoListBoxItemTemplate]",ngImport:c}),c.ɵɵngDeclareClassMetadata({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:h,decorators:[{type:i.Directive,args:[{selector:"[kendoListBoxItemTemplate]"}]}],ctorParameters:function(){return[{type:c.TemplateRef}]}}),"right"),x=[{name:"moveUp",label:"Move Up",icon:"arrow-n"},{name:"moveDown",label:"Move Down",icon:"arrow-s"},{name:"transferTo",label:"Transfer From",icon:"arrow-w"},{name:"transferFrom",label:"Transfer To",icon:"arrow-e"},{name:"transferAllTo",label:"Transfer All To",icon:"arrow-double-60-right"},{name:"transferAllFrom",label:"Transfer All From",icon:"arrow-double-60-left"},{name:"remove",label:"Remove",icon:"x"}],v={small:"sm",medium:"md",large:"lg"},k={left:"k-listbox-toolbar-left",right:"k-listbox-toolbar-right",top:"k-listbox-toolbar-top",bottom:"k-listbox-toolbar-bottom"},I=function(e){return null!=e},C=(Object.defineProperty(D.prototype,"selectedClassName",{get:function(){return this.selectionService.isSelected(this.index)},enumerable:!1,configurable:!0}),D.prototype.onClick=function(e){e.stopPropagation(),this.selectionService.select(this.index)},D);function D(e){this.selectionService=e}C.ɵfac=c.ɵɵngDeclareFactory({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:C,deps:[{token:u}],target:c.ɵɵFactoryTarget.Directive}),C.ɵdir=c.ɵɵngDeclareDirective({minVersion:"12.0.0",version:"12.2.16",type:C,selector:"[kendoListBoxItemSelectable]",inputs:{index:"index"},host:{listeners:{click:"onClick($event)"},properties:{"class.k-selected":"this.selectedClassName"}},ngImport:c}),c.ɵɵngDeclareClassMetadata({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:C,decorators:[{type:i.Directive,args:[{selector:"[kendoListBoxItemSelectable]"}]}],ctorParameters:function(){return[{type:u}]},propDecorators:{index:[{type:i.Input}],selectedClassName:[{type:i.HostBinding,args:["class.k-selected"]}],onClick:[{type:i.HostListener,args:["click",["$event"]]}]}});Object.defineProperty(T.prototype,"toolbar",{set:function(e){var t=y;"boolean"==typeof e?this.selectedTools=e?x:[]:(this.selectedTools=e.tools?e.tools.map(function(t){return x.find(function(e){return e.name===t})}):x,e.position&&(t=e.position)),this.setToolbarClass(t)},enumerable:!1,configurable:!0}),Object.defineProperty(T.prototype,"listClasses",{get:function(){return"k-list k-list-"+v[this.size]},enumerable:!1,configurable:!0}),T.prototype.ngOnDestroy=function(){this.sub.unsubscribe()},T.prototype.performAction=function(e){this.actionClick.next(e)},T.prototype.selectItem=function(e){this.selectionService.selectedIndex=e},T.prototype.clearSelection=function(){this.selectionService.clearSelection()},Object.defineProperty(T.prototype,"selectedIndex",{get:function(){return this.selectionService.selectedIndex},enumerable:!1,configurable:!0}),T.prototype.getText=function(e){if("string"!=typeof e&&!this.textField&&i.isDevMode())throw new Error("Missing textField input. When passing an array of objects as data, please set the textField input of the ListBox accordingly.");return b(e,this.textField)},T.prototype.setToolbarClass=function(t){var n=this;Object.keys(k).forEach(function(e){t===e?n.renderer.addClass(n.hostElement.nativeElement,k[e]):n.renderer.removeClass(n.hostElement.nativeElement,k[e])})};var B=T;function T(e,t,n){var o=this;this.selectionService=e,this.renderer=t,this.hostElement=n,this.listboxClassName=!0,this.data=[],this.size="medium",this.itemDisabled=f,this.selectionChange=new i.EventEmitter,this.actionClick=new i.EventEmitter,this.selectedTools=x,this.sub=new r.Subscription,s.validatePackage(m),this.setToolbarClass(y),this.sub.add(this.selectionService.onSelect.subscribe(function(e){o.selectionChange.next(e)}))}B.ɵfac=c.ɵɵngDeclareFactory({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:B,deps:[{token:u},{token:c.Renderer2},{token:c.ElementRef}],target:c.ɵɵFactoryTarget.Component}),B.ɵcmp=c.ɵɵngDeclareComponent({minVersion:"12.0.0",version:"12.2.16",type:B,selector:"kendo-listbox",inputs:{textField:"textField",data:"data",size:"size",toolbar:"toolbar",itemDisabled:"itemDisabled"},outputs:{selectionChange:"selectionChange",actionClick:"actionClick"},host:{properties:{"class.k-listbox":"this.listboxClassName"}},providers:[u],queries:[{propertyName:"itemTemplate",first:!0,predicate:h,descendants:!0}],ngImport:c,template:'\n <div class="k-listbox-toolbar" *ngIf="selectedTools.length > 0">\n <ul class="k-reset">\n <li *ngFor="let tool of selectedTools">\n <button kendoButton [icon]="tool.icon" (click)="performAction(tool.name)" role="button"></button>\n </li>\n\n \x3c!-- react moving items has a smoother removal of the style: https://www.telerik.com/kendo-react-ui/components/listbox/ --\x3e\n </ul>\n </div>\n <div class="k-list-scroller k-selectable">\n <div class="{{ listClasses }}">\n <div class="k-list-content">\n <ul class="k-list-ul">\n <li\n class="k-list-item"\n *ngFor="let item of data; let i = index;"\n kendoListBoxItemSelectable\n [index]="i"\n [class.k-disabled]="itemDisabled(item)"\n >\n <ng-template *ngIf="itemTemplate; else defaultItemTemplate"\n [templateContext]="{\n templateRef: itemTemplate.templateRef,\n $implicit: item\n }">\n </ng-template>\n <ng-template #defaultItemTemplate>\n <span class="k-list-item-text">{{ getText(item) }}</span>\n </ng-template>\n </li>\n </ul>\n </div>\n </div>\n </div>\n ',isInline:!0,directives:[{type:d.NgIf,selector:"[ngIf]",inputs:["ngIf","ngIfThen","ngIfElse"]},{type:d.NgForOf,selector:"[ngFor][ngForOf]",inputs:["ngForOf","ngForTrackBy","ngForTemplate"]},{type:p.ButtonDirective,selector:"button[kendoButton], span[kendoButton]",inputs:["toggleable","togglable","selected","tabIndex","icon","iconClass","imageUrl","disabled","size","rounded","fillMode","themeColor","role","primary","look"],outputs:["selectedChange","click"],exportAs:["kendoButton"]},{type:C,selector:"[kendoListBoxItemSelectable]",inputs:["index"]},{type:p.TemplateContextDirective,selector:"[templateContext]",inputs:["templateContext"]}]}),c.ɵɵngDeclareClassMetadata({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:B,decorators:[{type:i.Component,args:[{selector:"kendo-listbox",providers:[u],template:'\n <div class="k-listbox-toolbar" *ngIf="selectedTools.length > 0">\n <ul class="k-reset">\n <li *ngFor="let tool of selectedTools">\n <button kendoButton [icon]="tool.icon" (click)="performAction(tool.name)" role="button"></button>\n </li>\n\n \x3c!-- react moving items has a smoother removal of the style: https://www.telerik.com/kendo-react-ui/components/listbox/ --\x3e\n </ul>\n </div>\n <div class="k-list-scroller k-selectable">\n <div class="{{ listClasses }}">\n <div class="k-list-content">\n <ul class="k-list-ul">\n <li\n class="k-list-item"\n *ngFor="let item of data; let i = index;"\n kendoListBoxItemSelectable\n [index]="i"\n [class.k-disabled]="itemDisabled(item)"\n >\n <ng-template *ngIf="itemTemplate; else defaultItemTemplate"\n [templateContext]="{\n templateRef: itemTemplate.templateRef,\n $implicit: item\n }">\n </ng-template>\n <ng-template #defaultItemTemplate>\n <span class="k-list-item-text">{{ getText(item) }}</span>\n </ng-template>\n </li>\n </ul>\n </div>\n </div>\n </div>\n '}]}],ctorParameters:function(){return[{type:u},{type:c.Renderer2},{type:c.ElementRef}]},propDecorators:{listboxClassName:[{type:i.HostBinding,args:["class.k-listbox"]}],itemTemplate:[{type:i.ContentChild,args:[h,{static:!1}]}],textField:[{type:i.Input}],data:[{type:i.Input}],size:[{type:i.Input}],toolbar:[{type:i.Input}],itemDisabled:[{type:i.Input}],selectionChange:[{type:i.Output}],actionClick:[{type:i.Output}]}});Object.create;function S(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var o,i,s=n.call(e),r=[];try{for(;(void 0===t||0<t--)&&!(o=s.next()).done;)r.push(o.value)}catch(e){i={error:e}}finally{try{o&&!o.done&&(n=s.return)&&n.call(s)}finally{if(i)throw i.error}}return r}Object.create;F.prototype.ngOnChanges=function(e){var t=this;l.isChanged("connectedWith",e,!1)&&(e.connectedWith.firstChange||(this.selectedBoxSub.unsubscribe(),this.selectedBoxSub=new r.Subscription),this.selectedBoxSub.add(this.listbox.selectionChange.subscribe(function(){t.selectedBox=t.listbox,t.connectedWith.clearSelection()})),this.selectedBoxSub.add(this.connectedWith.selectionChange.subscribe(function(){t.selectedBox=t.connectedWith,t.listbox.clearSelection()})))},F.prototype.ngOnDestroy=function(){this.actionClickSub&&(this.actionClickSub.unsubscribe(),this.actionClickSub=null),this.selectedBoxSub&&(this.selectedBoxSub.unsubscribe(),this.selectedBoxSub=null)},F.prototype.moveVertically=function(e){var t,n=this.selectedBox.selectedIndex;I(n)&&(t="down"===e&&n>=this.selectedBox.data.length-1,"up"===e&&n<=0||t||(e=S([this.selectedBox.data[n],this.selectedBox.data[t="up"===e?n-1:n+1]],2),this.selectedBox.data[t]=e[0],this.selectedBox.data[n]=e[1],this.selectedBox.selectionService.select(t)))},F.prototype.removeItem=function(){var e=this.selectedBox.selectedIndex;I(e)&&(this.selectedBox.data.splice(e,1),this.selectedBox.selectionService.clearSelection())},F.prototype.transferItem=function(e,t){var n=e&&e.data[e.selectedIndex];n&&t&&e&&(t.data.push(n),e.data.splice(e.selectedIndex,1),e.clearSelection(),t.selectItem(t.data.length-1),this.selectedBox=t)},F.prototype.transferAll=function(e,t){var n;t&&e&&((n=t.data).splice.apply(n,function(e,t,n){if(n||2===arguments.length)for(var o,i=0,s=t.length;i<s;i++)!o&&i in t||((o=o||Array.prototype.slice.call(t,0,i))[i]=t[i]);return e.concat(o||Array.prototype.slice.call(t))}([t.data.length,0],S(e.data.splice(0,e.data.length)))),t.selectItem(t.data.length-1),this.selectedBox=t)};d=F;function F(e){var t=this;this.listbox=e,this.actionClickSub=new r.Subscription,this.selectedBoxSub=new r.Subscription,this.selectedBox=this.listbox,this.actionClickSub.add(this.listbox.actionClick.subscribe(function(e){switch(e){case"moveUp":t.moveVertically("up");break;case"moveDown":t.moveVertically("down");break;case"transferTo":t.transferItem(t.connectedWith,t.listbox);break;case"transferFrom":t.transferItem(t.listbox,t.connectedWith);break;case"transferAllTo":t.transferAll(t.listbox,t.connectedWith);break;case"transferAllFrom":t.transferAll(t.connectedWith,t.listbox);break;case"remove":t.removeItem()}}))}d.ɵfac=c.ɵɵngDeclareFactory({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:d,deps:[{token:B}],target:c.ɵɵFactoryTarget.Directive}),d.ɵdir=c.ɵɵngDeclareDirective({minVersion:"12.0.0",version:"12.2.16",type:d,selector:"[kendoListBoxDataBinding]",inputs:{connectedWith:"connectedWith"},usesOnChanges:!0,ngImport:c}),c.ɵɵngDeclareClassMetadata({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:d,decorators:[{type:i.Directive,args:[{selector:"[kendoListBoxDataBinding]"}]}],ctorParameters:function(){return[{type:B}]},propDecorators:{connectedWith:[{type:i.Input}]}});p=function(){};p.ɵfac=c.ɵɵngDeclareFactory({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:p,deps:[],target:c.ɵɵFactoryTarget.NgModule}),p.ɵmod=c.ɵɵngDeclareNgModule({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:p,declarations:[B,h,C,d],imports:[n.ButtonsModule,t.CommonModule],exports:[B,h,C,d]}),p.ɵinj=c.ɵɵngDeclareInjector({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:p,imports:[[n.ButtonsModule,t.CommonModule]]}),c.ɵɵngDeclareClassMetadata({minVersion:"12.0.0",version:"12.2.16",ngImport:c,type:p,decorators:[{type:i.NgModule,args:[{imports:[n.ButtonsModule,t.CommonModule],declarations:[B,h,C,d],exports:[B,h,C,d]}]}]}),e.DataBindingDirective=d,e.ItemSelectableDirective=C,e.ItemTemplateDirective=h,e.ListBoxComponent=B,e.ListBoxModule=p,Object.defineProperty(e,"__esModule",{value:!0})});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../tooling/schematics/ngAdd/index.ts"],"names":[],"mappings":";;AAAA,2DAGoC;AAEpC,mBAAyB,OAAY;IACjC,MAAM,YAAY,mCACX,OAAO,KACV,YAAY,EAAE,eAAe,EAC7B,OAAO,EAAE,SAAS;QAClB,sCAAsC;QACtC,4DAA4D;QAC5D,gBAAgB,EAAE;YACd,iCAAiC,EAAE,QAAQ;YAC3C,gCAAgC,EAAE,QAAQ;YAC1C,8BAA8B,EAAE,QAAQ;YACxC,gCAAgC;YAChC,+BAA+B,EAAE,QAAQ;SAC5C,GACJ,CAAC;IAEF,OAAO,8BAAiB,CAAC,4BAA4B,EAAE,QAAQ,EAAE,YAAY,CAAC,CAAC;AACnF,CAAC;AAjBD,4BAiBC"}
|