@seniorsistemas/angular-components 17.26.12 → 17.26.13-bugfix-sds-312-bce78028
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/bundles/seniorsistemas-angular-components.umd.js +18 -30
- package/bundles/seniorsistemas-angular-components.umd.js.map +1 -1
- package/bundles/seniorsistemas-angular-components.umd.min.js +1 -1
- package/bundles/seniorsistemas-angular-components.umd.min.js.map +1 -1
- package/components/dynamic-form/components/fields/text/text-field.component.d.ts +3 -1
- package/components/dynamic-form/components/fields/text-area/text-area-field.component.d.ts +1 -2
- package/components/tooltip/tooltip.directive.d.ts +0 -3
- package/esm2015/components/code-editor/code-editor.component.js +1 -1
- package/esm2015/components/dynamic-form/components/fields/text/text-field.component.js +11 -2
- package/esm2015/components/dynamic-form/components/fields/text-area/text-area-field.component.js +3 -6
- package/esm2015/components/info-sign/info-sign.component.js +2 -2
- package/esm2015/components/speech-recognition/speech-recognition/speech-recognition.component.js +2 -1
- package/esm2015/components/tooltip/tooltip.directive.js +3 -25
- package/esm5/components/code-editor/code-editor.component.js +1 -1
- package/esm5/components/dynamic-form/components/fields/text/text-field.component.js +15 -2
- package/esm5/components/dynamic-form/components/fields/text-area/text-area-field.component.js +3 -6
- package/esm5/components/info-sign/info-sign.component.js +2 -2
- package/esm5/components/speech-recognition/speech-recognition/speech-recognition.component.js +2 -1
- package/esm5/components/tooltip/tooltip.directive.js +3 -25
- package/fesm2015/seniorsistemas-angular-components.js +15 -31
- package/fesm2015/seniorsistemas-angular-components.js.map +1 -1
- package/fesm5/seniorsistemas-angular-components.js +19 -31
- package/fesm5/seniorsistemas-angular-components.js.map +1 -1
- package/package.json +1 -1
- package/seniorsistemas-angular-components.metadata.json +1 -1
|
@@ -38,7 +38,7 @@ import { CheckboxModule as CheckboxModule$1 } from 'primeng/checkbox';
|
|
|
38
38
|
import { ChipsModule as ChipsModule$1 } from 'primeng/chips';
|
|
39
39
|
import { DropdownModule } from 'primeng/dropdown';
|
|
40
40
|
import { FieldsetModule } from 'primeng/fieldset';
|
|
41
|
-
import { InputMaskModule } from 'primeng/inputmask';
|
|
41
|
+
import { InputMask, InputMaskModule } from 'primeng/inputmask';
|
|
42
42
|
import { InputTextModule } from 'primeng/inputtext';
|
|
43
43
|
import { InputTextareaModule } from 'primeng/inputtextarea';
|
|
44
44
|
import { KeyFilterModule } from 'primeng/keyfilter';
|
|
@@ -477,8 +477,6 @@ let TooltipDirective = class TooltipDirective {
|
|
|
477
477
|
this.visible = true;
|
|
478
478
|
this.mobileBehavior = MobileBehavior.Pressing;
|
|
479
479
|
this.componentRef = null;
|
|
480
|
-
this.existFocusedInputRefTooltip = false;
|
|
481
|
-
this.boundOnWindowMouseMoveFunction = this.onWindowMouseMove.bind(this);
|
|
482
480
|
this.debounceCreateTooltipFunction = this.debounceUtils.debounceLeading(() => this._createTooltip(true, true));
|
|
483
481
|
}
|
|
484
482
|
ngOnInit() {
|
|
@@ -488,22 +486,6 @@ let TooltipDirective = class TooltipDirective {
|
|
|
488
486
|
ngOnDestroy() {
|
|
489
487
|
this.destroy();
|
|
490
488
|
}
|
|
491
|
-
onWindowMouseMove(event) {
|
|
492
|
-
if (!this.componentRef) {
|
|
493
|
-
return;
|
|
494
|
-
}
|
|
495
|
-
const elementRect = this.elementRef.nativeElement.getBoundingClientRect();
|
|
496
|
-
const toolTipRect = this.tooltipDivElement.getBoundingClientRect();
|
|
497
|
-
const totalElementArea = {
|
|
498
|
-
top: Math.min(elementRect.top, toolTipRect.top),
|
|
499
|
-
right: Math.max(elementRect.right, toolTipRect.right),
|
|
500
|
-
left: Math.min(elementRect.left, toolTipRect.left),
|
|
501
|
-
bottom: Math.max(elementRect.bottom, toolTipRect.bottom),
|
|
502
|
-
};
|
|
503
|
-
if (isMousePositionOutsideOfElement(event, totalElementArea) && !this.existFocusedInputRefTooltip) {
|
|
504
|
-
this.destroy();
|
|
505
|
-
}
|
|
506
|
-
}
|
|
507
489
|
/**
|
|
508
490
|
* Manipula a visibilidade do tooltip quando houver uma referência de input.
|
|
509
491
|
*/
|
|
@@ -513,7 +495,6 @@ let TooltipDirective = class TooltipDirective {
|
|
|
513
495
|
const icon = this.getIconFromFocusedInput();
|
|
514
496
|
this.renderer.listen(inputFocus, "focus", () => {
|
|
515
497
|
if (icon) {
|
|
516
|
-
this.existFocusedInputRefTooltip = true;
|
|
517
498
|
this._createTooltip(false, false);
|
|
518
499
|
}
|
|
519
500
|
});
|
|
@@ -521,7 +502,6 @@ let TooltipDirective = class TooltipDirective {
|
|
|
521
502
|
if (icon) {
|
|
522
503
|
this.removeTooltip(icon);
|
|
523
504
|
this.destroy();
|
|
524
|
-
this.existFocusedInputRefTooltip = false;
|
|
525
505
|
}
|
|
526
506
|
});
|
|
527
507
|
}
|
|
@@ -566,7 +546,7 @@ let TooltipDirective = class TooltipDirective {
|
|
|
566
546
|
}
|
|
567
547
|
}
|
|
568
548
|
onMouseLeave() {
|
|
569
|
-
if (this.tooltipEvent === TooltipEvent.Hover
|
|
549
|
+
if (this.tooltipEvent === TooltipEvent.Hover) {
|
|
570
550
|
this.destroy();
|
|
571
551
|
}
|
|
572
552
|
}
|
|
@@ -628,7 +608,6 @@ let TooltipDirective = class TooltipDirective {
|
|
|
628
608
|
if (this.componentRef !== null) {
|
|
629
609
|
this.componentRef.instance.visible = this.visible;
|
|
630
610
|
this.setTooltipPositionProperty();
|
|
631
|
-
window.addEventListener("mousemove", this.boundOnWindowMouseMoveFunction);
|
|
632
611
|
}
|
|
633
612
|
}
|
|
634
613
|
setTooltipPositionProperty() {
|
|
@@ -738,7 +717,6 @@ let TooltipDirective = class TooltipDirective {
|
|
|
738
717
|
this.componentRef = null;
|
|
739
718
|
this.tooltipDivElement = null;
|
|
740
719
|
}
|
|
741
|
-
window.removeEventListener("mousemove", this.boundOnWindowMouseMoveFunction);
|
|
742
720
|
}
|
|
743
721
|
};
|
|
744
722
|
TooltipDirective.ctorParameters = () => [
|
|
@@ -973,7 +951,7 @@ let InfoSignComponent = class InfoSignComponent {
|
|
|
973
951
|
InfoSignComponent = __decorate([
|
|
974
952
|
Component({
|
|
975
953
|
selector: "s-info-sign-component",
|
|
976
|
-
template: "<span class=\"info-sign\">\n <span *ngTemplateOutlet=\"templateRef\"></span>\n <i\n class=\"info-sign__icon fa fa-info-circle\"\n aria-hidden=\"true\"\n [sTooltip]=\"tooltip\"\n [escape]=\"false\"\n tooltipPosition=\"top\"\n [displayTime]=\"displayTime\"\n mobileBehavior=\"tap\"\n showDelay=\"0\"\n [focusedInputRef]=\"focusedInputRef\">\n </i>\n</span>\n",
|
|
954
|
+
template: "<span class=\"info-sign\">\n <span *ngTemplateOutlet=\"templateRef\"></span>\n <i\n class=\"info-sign__icon fa fa-info-circle\"\n aria-hidden=\"true\"\n [sTooltip]=\"tooltip\"\n [escape]=\"false\"\n tooltipPosition=\"top\"\n [displayTime]=\"displayTime\"\n mobileBehavior=\"tap\"\n showDelay=\"0\"\n [tooltipEvent]=\"focusedInputRef ? 'focus' : 'hover'\"\n [focusedInputRef]=\"focusedInputRef\">\n </i>\n</span>\n",
|
|
977
955
|
styles: [".info-sign{-ms-flex-align:baseline;align-items:baseline;display:-ms-inline-flexbox;display:inline-flex;-ms-flex-pack:start;justify-content:flex-start}.info-sign .info-sign__icon{padding:0 12px}"]
|
|
978
956
|
})
|
|
979
957
|
], InfoSignComponent);
|
|
@@ -4033,7 +4011,7 @@ CodeEditorComponent = CodeEditorComponent_1 = __decorate([
|
|
|
4033
4011
|
multi: true,
|
|
4034
4012
|
},
|
|
4035
4013
|
],
|
|
4036
|
-
styles: [".core-wrapper{height:100
|
|
4014
|
+
styles: [".core-wrapper{height:100%;border:1px solid #c1c1cc;border-radius:3px}"]
|
|
4037
4015
|
})
|
|
4038
4016
|
], CodeEditorComponent);
|
|
4039
4017
|
|
|
@@ -10920,12 +10898,9 @@ __decorate([
|
|
|
10920
10898
|
__decorate([
|
|
10921
10899
|
Input()
|
|
10922
10900
|
], TextAreaFieldComponent.prototype, "formControl", void 0);
|
|
10923
|
-
__decorate([
|
|
10924
|
-
ViewChild('inputRef')
|
|
10925
|
-
], TextAreaFieldComponent.prototype, "inputRef", void 0);
|
|
10926
10901
|
TextAreaFieldComponent = __decorate([
|
|
10927
10902
|
Component({
|
|
10928
|
-
template: "<s-field-label *ngIf=\"textArea\" [field]=\"field\"\n [fieldContainerRef]=\"textArea.textAreaElement?.nativeElement\"></s-field-label>\n\n<s-textarea\n #textArea\n [inputId]=\"(field.id || field.name)\"\n [rows]=\"field.rows\"\n [formControl]=\"formControl\"\n [inputStyle]=\"field.style\"\n [readOnly]=\"field.readonly ? field.readonly() : false\"\n [keyFilter]=\"field.keyFilter\"\n [placeholder]=\"field.placeholder\"\n [keepContext]=\"field.keepContext\"\n [speechRecognitionPlaceholder]=\"field.speechRecognitionPlaceholder\"\n [maxLength]=\"field.maxLength\"\n [speechRecognition]=\"field.speechRecognition\">\n</s-textarea>\n"
|
|
10903
|
+
template: "<s-field-label *ngIf=\"textArea.textAreaElement\" [field]=\"field\"\n [fieldContainerRef]=\"textArea.textAreaElement?.nativeElement\"></s-field-label>\n\n<s-textarea\n #textArea\n [inputId]=\"(field.id || field.name)\"\n [rows]=\"field.rows\"\n [formControl]=\"formControl\"\n [inputStyle]=\"field.style\"\n [readOnly]=\"field.readonly ? field.readonly() : false\"\n [keyFilter]=\"field.keyFilter\"\n [placeholder]=\"field.placeholder\"\n [keepContext]=\"field.keepContext\"\n [speechRecognitionPlaceholder]=\"field.speechRecognitionPlaceholder\"\n [maxLength]=\"field.maxLength\"\n [speechRecognition]=\"field.speechRecognition\">\n</s-textarea>\n"
|
|
10929
10904
|
})
|
|
10930
10905
|
], TextAreaFieldComponent);
|
|
10931
10906
|
|
|
@@ -11383,6 +11358,14 @@ let TextFieldComponent = class TextFieldComponent extends BaseFieldComponent {
|
|
|
11383
11358
|
this.ngUnsubscribe.next();
|
|
11384
11359
|
this.ngUnsubscribe.complete();
|
|
11385
11360
|
}
|
|
11361
|
+
get inputElement() {
|
|
11362
|
+
if (this.inputRef instanceof InputMask) {
|
|
11363
|
+
return this.inputRef.inputViewChild.nativeElement;
|
|
11364
|
+
}
|
|
11365
|
+
else {
|
|
11366
|
+
return this.inputRef;
|
|
11367
|
+
}
|
|
11368
|
+
}
|
|
11386
11369
|
getCharacterPattern() {
|
|
11387
11370
|
return typeof this.field.characterPattern === "function"
|
|
11388
11371
|
? this.field.characterPattern()
|
|
@@ -11417,7 +11400,7 @@ __decorate([
|
|
|
11417
11400
|
], TextFieldComponent.prototype, "inputRef", void 0);
|
|
11418
11401
|
TextFieldComponent = __decorate([
|
|
11419
11402
|
Component({
|
|
11420
|
-
template: "<s-field-label *ngIf=\"
|
|
11403
|
+
template: "<s-field-label *ngIf=\"inputElement\" [field]=\"field\" [fieldContainerRef]=\"inputElement\"></s-field-label>\n\n<p-inputMask\n #inputRef\n *ngIf=\"field.mask; else noMask\"\n [type]=\"field.inputType || 'text'\"\n [inputId]=\"field.id || field.name\"\n [name]=\"field.name\"\n [mask]=\"isFunction(field.mask) ? field.mask() : field.mask\"\n [characterPattern]=\"getCharacterPattern()\"\n [unmask]=\"getUnmask()\"\n [placeholder]=\"field.placeholder\"\n slotChar=\"_\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\"\n styleClass=\"mousetrap\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n (onFocus)=\"onFocus.next($event)\"\n (onComplete)=\"onComplete.next($event)\"\n (onInput)=\"onInput.next($event)\"\n [formControl]=\"formControl\"\n [readonly]=\"field.readonly ? field.readonly() : false\"\n [autocomplete]=\"field.browserAutocomplete ? 'on' : 'off'\"\n>\n</p-inputMask>\n\n<ng-template #noMask>\n <ng-container>\n <div class=\"ui-inputgroup\">\n <ng-container *ngIf=\"field.leftAddon\">\n <span *ngIf=\"field.leftAddon.callback\" class=\"addon-button addon-button--left\">\n <s-button\n [label]=\"field.leftAddon.label\"\n [iconClass]=\"field.leftAddon.icon\"\n [priority]=\"field.leftAddon.priority\"\n [disabled]=\"isFunction(field.leftAddon.disabled) ? field.leftAddon.disabled() : field.leftAddon.disabled\"\n (onClick)=\"field.leftAddon.callback()\"\n >\n </s-button>\n </span>\n <span *ngIf=\"!field.leftAddon.callback\" class=\"ui-inputgroup-addon\">\n <span *ngIf=\"field.leftAddon.label\">{{ field.leftAddon.label }}</span>\n <span *ngIf=\"!field.leftAddon.label\" [ngClass]=\"field.leftAddon.icon\"></span>\n </span>\n </ng-container>\n\n <ng-container *ngTemplateOutlet=\"field.keyFilter ? inputKeyFilter : input\"></ng-container>\n\n <ng-container *ngIf=\"field.rightAddon\">\n <span *ngIf=\"field.rightAddon.callback\" class=\"addon-button addon-button--right\">\n <s-button\n [label]=\"field.rightAddon.label\"\n [iconClass]=\"field.rightAddon.icon\"\n [priority]=\"field.rightAddon.priority\"\n [disabled]=\"isFunction(field.rightAddon.disabled) ? field.rightAddon.disabled() : field.rightAddon.disabled\"\n (onClick)=\"field.rightAddon.callback()\"\n >\n </s-button>\n </span>\n <span *ngIf=\"!field.rightAddon.callback\" class=\"ui-inputgroup-addon\">\n <span *ngIf=\"field.rightAddon.label\">{{ field.rightAddon.label }}</span>\n <span *ngIf=\"!field.rightAddon.label\" [ngClass]=\"field.rightAddon.icon\"></span>\n </span>\n </ng-container>\n </div>\n </ng-container>\n</ng-template>\n\n<ng-template #input>\n <input\n #inputRef\n [type]=\"field.inputType || 'text'\"\n [id]=\"field.id || field.name\"\n [name]=\"field.name\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [placeholder]=\"field.placeholder\"\n [showDelay]=\"500\"\n [maxLength]=\"field.maxLength\"\n pInputText\n [autocomplete]=\"field.browserAutocomplete ? 'on' : 'off'\"\n [ngClass]=\"'mousetrap'\"\n (blur)=\"field.onBlur ? field.onBlur($event) : null\"\n (focus)=\"onFocus.next($event)\"\n (input)=\"onInput.next($event)\"\n [formControl]=\"formControl\"\n [ngStyle]=\"field.style\"\n [readOnly]=\"field.readonly ? field.readonly() : false\"\n />\n</ng-template>\n\n<ng-template #inputKeyFilter>\n <input\n #inputText\n [type]=\"field.inputType || 'text'\"\n [id]=\"field.id || field.name\"\n [name]=\"field.name\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [placeholder]=\"field.placeholder\"\n [showDelay]=\"500\"\n [maxLength]=\"field.maxLength\"\n pInputText\n [autocomplete]=\"field.browserAutocomplete ? 'on' : 'off'\"\n [ngClass]=\"'mousetrap'\"\n (blur)=\"field.onBlur ? field.onBlur($event) : null\"\n (focus)=\"onFocus.next($event)\"\n (input)=\"onInput.next($event)\"\n [pKeyFilter]=\"field.keyFilter\"\n [formControl]=\"formControl\"\n [ngStyle]=\"field.style\"\n [readOnly]=\"field.readonly ? field.readonly() : false\"\n />\n</ng-template>\n",
|
|
11421
11404
|
encapsulation: ViewEncapsulation.None,
|
|
11422
11405
|
styles: ["s-text-field.ng-dirty.ng-invalid .ui-inputtext{border-color:#c13018}s-text-field.ng-dirty.ng-invalid .ui-inputtext:hover{border-color:#e44328}.addon-button{border:1px solid #c1c1cc}.addon-button s-button .s-button-with-text,.addon-button s-button button{height:100%;min-width:40px}.addon-button--left{border-radius:5px 0 0 5px;border-right:none}.addon-button--left s-button button{border-bottom-right-radius:0;border-top-right-radius:0}.addon-button--right{border-left:none;border-radius:0 5px 5px 0}.addon-button--right s-button button{border-bottom-left-radius:0;border-top-left-radius:0}"]
|
|
11423
11406
|
})
|
|
@@ -13017,6 +13000,7 @@ let SpeechRecognitionComponent = SpeechRecognitionComponent_1 = class SpeechReco
|
|
|
13017
13000
|
this._recognizedText = '';
|
|
13018
13001
|
this.disabled = false;
|
|
13019
13002
|
this.textToSpeechService.cancel();
|
|
13003
|
+
SpeechRecognitionComponent_1.TOOLBAR_ACTIVE = false;
|
|
13020
13004
|
}
|
|
13021
13005
|
ngOnDestroy() {
|
|
13022
13006
|
this.onDestroy$.next();
|