survey-angular-ui 1.11.5 → 1.11.7
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/survey-angular-ui.umd.js +19 -3
- package/bundles/survey-angular-ui.umd.js.map +1 -1
- package/esm2015/components/action-bar/action-bar-item.component.js +2 -2
- package/esm2015/questions/text.component.js +21 -4
- package/fesm2015/survey-angular-ui.js +19 -3
- package/fesm2015/survey-angular-ui.js.map +1 -1
- package/package.json +2 -2
- package/questions/text.component.d.ts +4 -0
|
@@ -2401,10 +2401,23 @@
|
|
|
2401
2401
|
enumerable: false,
|
|
2402
2402
|
configurable: true
|
|
2403
2403
|
});
|
|
2404
|
+
TextQuestionComponent.prototype.blur = function (event) {
|
|
2405
|
+
this.model.onBlur(event);
|
|
2406
|
+
this.updateInputDomElement();
|
|
2407
|
+
};
|
|
2408
|
+
TextQuestionComponent.prototype.updateInputDomElement = function () {
|
|
2409
|
+
var _a;
|
|
2410
|
+
if (!!((_a = this.inputElementRef) === null || _a === void 0 ? void 0 : _a.nativeElement)) {
|
|
2411
|
+
var control = this.inputElementRef.nativeElement;
|
|
2412
|
+
if (!Survey.Helpers.isTwoValueEquals(this.value, control.value, false, true, false)) {
|
|
2413
|
+
control.value = this.value;
|
|
2414
|
+
}
|
|
2415
|
+
}
|
|
2416
|
+
};
|
|
2404
2417
|
return TextQuestionComponent;
|
|
2405
2418
|
}(QuestionAngular));
|
|
2406
2419
|
TextQuestionComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: TextQuestionComponent, deps: null, target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
2407
|
-
TextQuestionComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: TextQuestionComponent, selector: "sv-ng-text-question", usesInheritance: true, ngImport: i0__namespace, template: " <ng-container [ngTemplateOutlet]=\"input\" *ngIf=\"!model.dataListId && !model.isReadOnlyRenderDiv()\"></ng-container>\n <div *ngIf=\"model.dataListId && !model.isReadOnlyRenderDiv()\">\n <ng-container [ngTemplateOutlet]=\"input\"></ng-container>\n <datalist [id]=\"model.dataListId\">\n <option *ngFor=\"let dataListItem of model.dataList\" [value]=\"dataListItem\"></option>\n </datalist>\n </div>\n <div *ngIf=\"model.isReadOnlyRenderDiv()\" #contentElement>{{ value }}</div>\n <ng-template #input>\n <input [style]=\"model.inputStyle\" [class]=\"model.getControlClass()\" [attr.list]=\"model.dataListId\"\n (change)=\"model.onChange($event)\" [value]=\"value\" [disabled]=\"model.isDisabledAttr\" [type]=\"model.inputType\" [id]=\"model.inputId\" [attr.placeholder]=\"model.renderedPlaceholder || ''\"\n (keyup)=\"model.onKeyUp($event)\" (keydown)=\"model.onKeyDown($event)\" (blur)=\"
|
|
2420
|
+
TextQuestionComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: TextQuestionComponent, selector: "sv-ng-text-question", viewQueries: [{ propertyName: "inputElementRef", first: true, predicate: ["inputElement"], descendants: true }], usesInheritance: true, ngImport: i0__namespace, template: " <ng-container [ngTemplateOutlet]=\"input\" *ngIf=\"!model.dataListId && !model.isReadOnlyRenderDiv()\"></ng-container>\n <div *ngIf=\"model.dataListId && !model.isReadOnlyRenderDiv()\">\n <ng-container [ngTemplateOutlet]=\"input\"></ng-container>\n <datalist [id]=\"model.dataListId\">\n <option *ngFor=\"let dataListItem of model.dataList\" [value]=\"dataListItem\"></option>\n </datalist>\n </div>\n <div *ngIf=\"model.isReadOnlyRenderDiv()\" #contentElement>{{ value }}</div>\n <ng-template #input>\n <input #inputElement [style]=\"model.inputStyle\" [class]=\"model.getControlClass()\" [attr.list]=\"model.dataListId\"\n (change)=\"model.onChange($event)\" [value]=\"value\" [disabled]=\"model.isDisabledAttr\" [type]=\"model.inputType\" [id]=\"model.inputId\" [attr.placeholder]=\"model.renderedPlaceholder || ''\"\n (keyup)=\"model.onKeyUp($event)\" (keydown)=\"model.onKeyDown($event)\" (blur)=\"blur($event)\" (focus)=\"model.onFocus($event)\" (compositionupdate)=\"model.onCompositionUpdate($event)\" \n [attr.size] = \"model.renderedInputSize\" [attr.maxlength]= \"model.getMaxLength()\" [attr.min]=\"model.renderedMin\" [readonly]=\"model.isReadOnlyAttr\"\n [attr.max]=\"model.renderedMax\" [attr.step]=\"model.renderedStep\" [attr.max]=\"model.renderedMax\" [attr.aria-required]=\"model.a11y_input_ariaRequired\"\n [attr.aria-label]=\"model.a11y_input_ariaLabel\" [attr.aria-labelledby]=\"model.a11y_input_ariaLabelledBy\" [attr.aria-describedby]=\"model.a11y_input_ariaDescribedBy\"[attr.aria-invalid]=\"model.a11y_input_ariaInvalid\" [attr.aria-errormessage]=\"model.a11y_input_ariaErrormessage\" [attr.autocomplete]=\"model.autocomplete\" #contentElement/>\n <sv-ng-character-counter *ngIf=\"model.getMaxLength()\" \n [counter]=\"model.characterCounter\"\n [remainingCharacterCounter]=\"model.cssClasses.remainingCharacterCounter\">\n </sv-ng-character-counter>\n </ng-template>", styles: [""], components: [{ type: CharacterCounterComponent, selector: "sv-ng-character-counter", inputs: ["counter", "remainingCharacterCounter"] }], directives: [{ type: i2__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2__namespace.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i2__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2__namespace$1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { type: i2__namespace$1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }] });
|
|
2408
2421
|
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: TextQuestionComponent, decorators: [{
|
|
2409
2422
|
type: i0.Component,
|
|
2410
2423
|
args: [{
|
|
@@ -2412,7 +2425,10 @@
|
|
|
2412
2425
|
templateUrl: "./text.component.html",
|
|
2413
2426
|
styleUrls: ["./text.component.scss"]
|
|
2414
2427
|
}]
|
|
2415
|
-
}]
|
|
2428
|
+
}], propDecorators: { inputElementRef: [{
|
|
2429
|
+
type: i0.ViewChild,
|
|
2430
|
+
args: ["inputElement"]
|
|
2431
|
+
}] } });
|
|
2416
2432
|
AngularComponentFactory.Instance.registerComponent("text-question", TextQuestionComponent);
|
|
2417
2433
|
|
|
2418
2434
|
var HtmlQuestionComponent = /** @class */ (function (_super) {
|
|
@@ -2916,7 +2932,7 @@
|
|
|
2916
2932
|
return ActionBarItemComponent;
|
|
2917
2933
|
}(BaseAngular));
|
|
2918
2934
|
ActionBarItemComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: ActionBarItemComponent, deps: null, target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
2919
|
-
ActionBarItemComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: ActionBarItemComponent, selector: "sv-action-bar-item", inputs: { model: "model" }, usesInheritance: true, ngImport: i0__namespace, template: "<ng-template #template>\n <button type=\"button\" (click)=\"model.
|
|
2935
|
+
ActionBarItemComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: ActionBarItemComponent, selector: "sv-action-bar-item", inputs: { model: "model" }, usesInheritance: true, ngImport: i0__namespace, template: "<ng-template #template>\n <button type=\"button\" (click)=\"model.doAction($event)\" (mousedown)=\"model.doMouseDown()\" (focus)=\"model.doFocus($event)\" [key2click]=\"{ processEsc: false, disableTabStop: model.disableTabStop }\" [class]=\"model.getActionBarItemCss()\" [attr.title]=\"model.tooltip || model.title\" [attr.aria-checked]=\"model.ariaChecked\" [attr.aria-expanded]=\"model.ariaExpanded\" [attr.role]=\"model.ariaRole\" [disabled]=\"model.disabled\">\n <svg *ngIf=\"model.iconName\" [iconName]=\"model.iconName\" [size]=\"model.iconSize\" [title]=\"model.tooltip || model.title\" [class]=\"model.cssClasses.itemIcon\" sv-ng-svg-icon></svg>\n <span *ngIf=\"model.hasTitle\" [class]=\"model.getActionBarItemTitleCss()\">{{ model.title }}</span>\n </button>\n<ng-template>", styles: [":host{display:none}\n"], components: [{ type: SvgIconComponent, selector: "'[sv-ng-svg-icon]'", inputs: ["size", "width", "height", "iconName", "partCss", "css", "title"] }], directives: [{ type: Key2ClickDirective, selector: "[key2click]", inputs: ["key2click"] }, { type: i2__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
2920
2936
|
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: ActionBarItemComponent, decorators: [{
|
|
2921
2937
|
type: i0.Component,
|
|
2922
2938
|
args: [{
|