@smart-webcomponents-angular/window 13.0.9 → 14.2.0

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.
@@ -4,10 +4,10 @@ import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
4
4
  import * as i0 from "@angular/core";
5
5
  export class WindowModule {
6
6
  }
7
- WindowModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.2", ngImport: i0, type: WindowModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
8
- WindowModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.2", ngImport: i0, type: WindowModule, declarations: [WindowComponent], exports: [WindowComponent] });
9
- WindowModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.2", ngImport: i0, type: WindowModule });
10
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.2", ngImport: i0, type: WindowModule, decorators: [{
7
+ WindowModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.6", ngImport: i0, type: WindowModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
8
+ WindowModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.6", ngImport: i0, type: WindowModule, declarations: [WindowComponent], exports: [WindowComponent] });
9
+ WindowModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.6", ngImport: i0, type: WindowModule });
10
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.6", ngImport: i0, type: WindowModule, decorators: [{
11
11
  type: NgModule,
12
12
  args: [{
13
13
  declarations: [WindowComponent],
@@ -9,7 +9,7 @@ import './../source/modules/smart.window';
9
9
 
10
10
  import { __awaiter } from 'tslib';
11
11
  import * as i0 from '@angular/core';
12
- import { EventEmitter, Component, Output, Input, Directive, NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
12
+ import { EventEmitter, Directive, Output, Input, NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
13
13
 
14
14
  class BaseElement {
15
15
  constructor(ref) {
@@ -80,13 +80,10 @@ class BaseElement {
80
80
  this.nativeElement ? this.nativeElement.theme = value : undefined;
81
81
  }
82
82
  }
83
- BaseElement.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.2", ngImport: i0, type: BaseElement, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
84
- BaseElement.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.2.2", type: BaseElement, selector: "ng-component", inputs: { locale: "locale", localizeFormatFunction: "localizeFormatFunction", messages: "messages", rightToLeft: "rightToLeft", theme: "theme" }, outputs: { onCreate: "onCreate", onReady: "onReady", onAttach: "onAttach", onDetach: "onDetach" }, ngImport: i0, template: '', isInline: true });
85
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.2", ngImport: i0, type: BaseElement, decorators: [{
86
- type: Component,
87
- args: [{
88
- template: ''
89
- }]
83
+ BaseElement.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.6", ngImport: i0, type: BaseElement, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
84
+ BaseElement.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.2.6", type: BaseElement, inputs: { locale: "locale", localizeFormatFunction: "localizeFormatFunction", messages: "messages", rightToLeft: "rightToLeft", theme: "theme" }, outputs: { onCreate: "onCreate", onReady: "onReady", onAttach: "onAttach", onDetach: "onDetach" }, ngImport: i0 });
85
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.6", ngImport: i0, type: BaseElement, decorators: [{
86
+ type: Directive
90
87
  }], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { onCreate: [{
91
88
  type: Output
92
89
  }], onReady: [{
@@ -247,6 +244,20 @@ class WindowComponent extends BaseElement {
247
244
  set disableSnap(value) {
248
245
  this.nativeElement ? this.nativeElement.disableSnap = value : undefined;
249
246
  }
247
+ /** @description By default the window is closing after the 'Escape' key is pressed. Set this property to true, if you want to disable that. */
248
+ get disableEscape() {
249
+ return this.nativeElement ? this.nativeElement.disableEscape : undefined;
250
+ }
251
+ set disableEscape(value) {
252
+ this.nativeElement ? this.nativeElement.disableEscape = value : undefined;
253
+ }
254
+ /** @description By default the window is handling keyboard keys like 'Arrows', 'Escape', etc. Set this property to true, if you want to disable that. */
255
+ get disableKeyboard() {
256
+ return this.nativeElement ? this.nativeElement.disableKeyboard : undefined;
257
+ }
258
+ set disableKeyboard(value) {
259
+ this.nativeElement ? this.nativeElement.disableKeyboard = value : undefined;
260
+ }
250
261
  /** @description Determines how the characters are displayed inside the input. Applicable to Prompt Window. */
251
262
  get displayMode() {
252
263
  return this.nativeElement ? this.nativeElement.displayMode : undefined;
@@ -766,37 +777,20 @@ class WindowComponent extends BaseElement {
766
777
  return result;
767
778
  });
768
779
  }
769
- /** @description Removes a tab and its associated content section. Applicable only to TabsWindow.
770
- * @param {number} index. The index of the tab to remove.
780
+ /** @description Moves the window to a new position
781
+ * @param {string | number} left. Left position. For example: '100px'.
782
+ * @param {string | number} top. Top position. For example: '100px'.
771
783
  */
772
- removeAt(index) {
784
+ move(left, top) {
773
785
  if (this.nativeElement.isRendered) {
774
- this.nativeElement.removeAt(index);
786
+ this.nativeElement.move(left, top);
775
787
  }
776
788
  else {
777
789
  this.nativeElement.whenRendered(() => {
778
- this.nativeElement.removeAt(index);
790
+ this.nativeElement.move(left, top);
779
791
  });
780
792
  }
781
793
  }
782
- /** @description Removes a child "smart-tab-item" node. Applicable only to TabsWindow.
783
- * @param {Node} node. The "smart-tab-item" node to remove.
784
- * @returns {Node}
785
- */
786
- removeChild(node) {
787
- return __awaiter(this, void 0, void 0, function* () {
788
- const getResultOnRender = () => {
789
- return new Promise(resolve => {
790
- this.nativeElement.whenRendered(() => {
791
- const result = this.nativeElement.removeChild(node);
792
- resolve(result);
793
- });
794
- });
795
- };
796
- const result = yield getResultOnRender();
797
- return result;
798
- });
799
- }
800
794
  /** @description Maximizes the window to fill the area.
801
795
  */
802
796
  maximize() {
@@ -845,6 +839,37 @@ class WindowComponent extends BaseElement {
845
839
  });
846
840
  }
847
841
  }
842
+ /** @description Removes a tab and its associated content section. Applicable only to TabsWindow.
843
+ * @param {number} index. The index of the tab to remove.
844
+ */
845
+ removeAt(index) {
846
+ if (this.nativeElement.isRendered) {
847
+ this.nativeElement.removeAt(index);
848
+ }
849
+ else {
850
+ this.nativeElement.whenRendered(() => {
851
+ this.nativeElement.removeAt(index);
852
+ });
853
+ }
854
+ }
855
+ /** @description Removes a child "smart-tab-item" node. Applicable only to TabsWindow.
856
+ * @param {Node} node. The "smart-tab-item" node to remove.
857
+ * @returns {Node}
858
+ */
859
+ removeChild(node) {
860
+ return __awaiter(this, void 0, void 0, function* () {
861
+ const getResultOnRender = () => {
862
+ return new Promise(resolve => {
863
+ this.nativeElement.whenRendered(() => {
864
+ const result = this.nativeElement.removeChild(node);
865
+ resolve(result);
866
+ });
867
+ });
868
+ };
869
+ const result = yield getResultOnRender();
870
+ return result;
871
+ });
872
+ }
848
873
  /** @description Restores the window to it's previous size before maximization/minimization.
849
874
  */
850
875
  restore() {
@@ -882,7 +907,33 @@ class WindowComponent extends BaseElement {
882
907
  });
883
908
  }
884
909
  }
885
- /** @description Updates a tab and its associated content section. Applicalbe only to TabsWindow elements.
910
+ /** @description Updates the header label.
911
+ * @param {string} label. The new label of the Header.
912
+ */
913
+ updateLabel(label) {
914
+ if (this.nativeElement.isRendered) {
915
+ this.nativeElement.updateLabel(label);
916
+ }
917
+ else {
918
+ this.nativeElement.whenRendered(() => {
919
+ this.nativeElement.updateLabel(label);
920
+ });
921
+ }
922
+ }
923
+ /** @description Updates the content.
924
+ * @param {string | HTMLElement} content. The new content of the window.
925
+ */
926
+ updateContent(content) {
927
+ if (this.nativeElement.isRendered) {
928
+ this.nativeElement.updateContent(content);
929
+ }
930
+ else {
931
+ this.nativeElement.whenRendered(() => {
932
+ this.nativeElement.updateContent(content);
933
+ });
934
+ }
935
+ }
936
+ /** @description Updates a TAB in TAB Window and its associated content section. Applies only to TabsWindow elements.
886
937
  * @param {number} index. The index of the tab to update.
887
938
  * @param {string} label. The new label of the tab. The value can be the id of an HTMLTemplateElement
888
939
  * @param {string | HTMLElement} content. The new content of the tab.
@@ -996,12 +1047,12 @@ class WindowComponent extends BaseElement {
996
1047
  }
997
1048
  }
998
1049
  }
999
- WindowComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.2", ngImport: i0, type: WindowComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
1000
- WindowComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.2.2", type: WindowComponent, selector: "smart-window, [smart-window], smart-tabs-window, smart-prompt-window, smart-multilineprompt-window, smart-dialog-window, smart-alert-window, smart-progress-window, smart-wait-window", inputs: { addNewTab: "addNewTab", animation: "animation", autoCapitalize: "autoCapitalize", autoExpand: "autoExpand", cancelLabel: "cancelLabel", completeLabel: "completeLabel", confirmLabel: "confirmLabel", collapsed: "collapsed", closeOnMaskClick: "closeOnMaskClick", dataSource: "dataSource", disabled: "disabled", disableSnap: "disableSnap", displayMode: "displayMode", dropPosition: "dropPosition", formatFunction: "formatFunction", footerPosition: "footerPosition", footerTemplate: "footerTemplate", headerButtons: "headerButtons", headerTemplate: "headerTemplate", headerPosition: "headerPosition", hint: "hint", indeterminate: "indeterminate", inverted: "inverted", label: "label", liveResize: "liveResize", layout: "layout", locale: "locale", locked: "locked", localizeFormatFunction: "localizeFormatFunction", maximized: "maximized", messages: "messages", modal: "modal", max: "max", min: "min", minimized: "minimized", maxLength: "maxLength", minLength: "minLength", opened: "opened", pinned: "pinned", placeholder: "placeholder", promptLabel: "promptLabel", readonly: "readonly", resizeIndicator: "resizeIndicator", resizeMode: "resizeMode", rightToLeft: "rightToLeft", required: "required", requiredMessage: "requiredMessage", selectAllOnFocus: "selectAllOnFocus", selectedIndex: "selectedIndex", selectionMode: "selectionMode", selectionEnd: "selectionEnd", selectionStart: "selectionStart", showProgressValue: "showProgressValue", siblings: "siblings", size: "size", spellCheck: "spellCheck", tabCloseButtons: "tabCloseButtons", tabCloseButtonMode: "tabCloseButtonMode", tabOverflow: "tabOverflow", tabPosition: "tabPosition", tabScrollButtonsPosition: "tabScrollButtonsPosition", tabTextOrientation: "tabTextOrientation", theme: "theme", unfocusable: "unfocusable", value: "value", windowParent: "windowParent", wrap: "wrap" }, outputs: { onOpening: "onOpening", onOpen: "onOpen", onClosing: "onClosing", onClose: "onClose", onCollapse: "onCollapse", onDragEnd: "onDragEnd", onDragStart: "onDragStart", onExpand: "onExpand", onMaximize: "onMaximize", onMinimize: "onMinimize", onResizeEnd: "onResizeEnd", onResizeStart: "onResizeStart", onRestore: "onRestore" }, usesInheritance: true, usesOnChanges: true, ngImport: i0 });
1001
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.2", ngImport: i0, type: WindowComponent, decorators: [{
1050
+ WindowComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.6", ngImport: i0, type: WindowComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
1051
+ WindowComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.2.6", type: WindowComponent, selector: "smart-window, [smart-window], smart-tabs-window, smart-prompt-window, smart-multilineprompt-window, smart-dialog-window, smart-alert-window, smart-progress-window, smart-wait-window", inputs: { addNewTab: "addNewTab", animation: "animation", autoCapitalize: "autoCapitalize", autoExpand: "autoExpand", cancelLabel: "cancelLabel", completeLabel: "completeLabel", confirmLabel: "confirmLabel", collapsed: "collapsed", closeOnMaskClick: "closeOnMaskClick", dataSource: "dataSource", disabled: "disabled", disableSnap: "disableSnap", disableEscape: "disableEscape", disableKeyboard: "disableKeyboard", displayMode: "displayMode", dropPosition: "dropPosition", formatFunction: "formatFunction", footerPosition: "footerPosition", footerTemplate: "footerTemplate", headerButtons: "headerButtons", headerTemplate: "headerTemplate", headerPosition: "headerPosition", hint: "hint", indeterminate: "indeterminate", inverted: "inverted", label: "label", liveResize: "liveResize", layout: "layout", locale: "locale", locked: "locked", localizeFormatFunction: "localizeFormatFunction", maximized: "maximized", messages: "messages", modal: "modal", max: "max", min: "min", minimized: "minimized", maxLength: "maxLength", minLength: "minLength", opened: "opened", pinned: "pinned", placeholder: "placeholder", promptLabel: "promptLabel", readonly: "readonly", resizeIndicator: "resizeIndicator", resizeMode: "resizeMode", rightToLeft: "rightToLeft", required: "required", requiredMessage: "requiredMessage", selectAllOnFocus: "selectAllOnFocus", selectedIndex: "selectedIndex", selectionMode: "selectionMode", selectionEnd: "selectionEnd", selectionStart: "selectionStart", showProgressValue: "showProgressValue", siblings: "siblings", size: "size", spellCheck: "spellCheck", tabCloseButtons: "tabCloseButtons", tabCloseButtonMode: "tabCloseButtonMode", tabOverflow: "tabOverflow", tabPosition: "tabPosition", tabScrollButtonsPosition: "tabScrollButtonsPosition", tabTextOrientation: "tabTextOrientation", theme: "theme", unfocusable: "unfocusable", value: "value", windowParent: "windowParent", wrap: "wrap" }, outputs: { onOpening: "onOpening", onOpen: "onOpen", onClosing: "onClosing", onClose: "onClose", onCollapse: "onCollapse", onDragEnd: "onDragEnd", onDragStart: "onDragStart", onExpand: "onExpand", onMaximize: "onMaximize", onMinimize: "onMinimize", onResizeEnd: "onResizeEnd", onResizeStart: "onResizeStart", onRestore: "onRestore" }, exportAs: ["smart-window"], usesInheritance: true, usesOnChanges: true, ngImport: i0 });
1052
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.6", ngImport: i0, type: WindowComponent, decorators: [{
1002
1053
  type: Directive,
1003
1054
  args: [{
1004
- selector: 'smart-window, [smart-window], smart-tabs-window, smart-prompt-window, smart-multilineprompt-window, smart-dialog-window, smart-alert-window, smart-progress-window, smart-wait-window'
1055
+ exportAs: 'smart-window', selector: 'smart-window, [smart-window], smart-tabs-window, smart-prompt-window, smart-multilineprompt-window, smart-dialog-window, smart-alert-window, smart-progress-window, smart-wait-window'
1005
1056
  }]
1006
1057
  }], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { addNewTab: [{
1007
1058
  type: Input
@@ -1027,6 +1078,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.2", ngImpor
1027
1078
  type: Input
1028
1079
  }], disableSnap: [{
1029
1080
  type: Input
1081
+ }], disableEscape: [{
1082
+ type: Input
1083
+ }], disableKeyboard: [{
1084
+ type: Input
1030
1085
  }], displayMode: [{
1031
1086
  type: Input
1032
1087
  }], dropPosition: [{
@@ -1167,10 +1222,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.2", ngImpor
1167
1222
 
1168
1223
  class WindowModule {
1169
1224
  }
1170
- WindowModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.2", ngImport: i0, type: WindowModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1171
- WindowModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.2", ngImport: i0, type: WindowModule, declarations: [WindowComponent], exports: [WindowComponent] });
1172
- WindowModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.2", ngImport: i0, type: WindowModule });
1173
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.2", ngImport: i0, type: WindowModule, decorators: [{
1225
+ WindowModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.6", ngImport: i0, type: WindowModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1226
+ WindowModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.6", ngImport: i0, type: WindowModule, declarations: [WindowComponent], exports: [WindowComponent] });
1227
+ WindowModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.6", ngImport: i0, type: WindowModule });
1228
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.6", ngImport: i0, type: WindowModule, decorators: [{
1174
1229
  type: NgModule,
1175
1230
  args: [{
1176
1231
  declarations: [WindowComponent],