@ng-simplicity/forms-bootstrap 1.0.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.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 NG-Simplicity
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,100 @@
1
+ # @ng-simplicity/forms-bootstrap
2
+
3
+ A package containing pre-styled Bootstrap form inputs, containers, and templates for the **NG-Simplicity Forms** dynamic engine.
4
+
5
+ ---
6
+
7
+ ## Installation
8
+
9
+ Ensure that you have `bootstrap` installed and imported in your application styles, along with the core forms package:
10
+
11
+ ```bash
12
+ npm install @ng-simplicity/forms-core @ng-simplicity/forms-bootstrap bootstrap lodash
13
+ ```
14
+
15
+ Make sure to include Bootstrap's CSS inside your `angular.json` styles or `index.scss`:
16
+ ```scss
17
+ @import "bootstrap/scss/bootstrap";
18
+ ```
19
+
20
+ ---
21
+
22
+ ## Quick Start & Registration
23
+
24
+ To make these styling components available to the dynamic renderer, register them using `NgsFormsBootstrapModule` in your page component constructor:
25
+
26
+ ```typescript
27
+ import { Component } from '@angular/core';
28
+ import { NgsFormsComponentRegistryService } from '@ng-simplicity/forms-core';
29
+ import { NgsFormsBootstrapModule } from '@ng-simplicity/forms-bootstrap';
30
+
31
+ @Component({
32
+ selector: 'app-bootstrap-form-page',
33
+ templateUrl: './bootstrap-form-page.component.html'
34
+ })
35
+ export class BootstrapFormPageComponent {
36
+ constructor(registry: NgsFormsComponentRegistryService) {
37
+ // Registers input-text, input-textarea, row, column, and other components
38
+ NgsFormsBootstrapModule.registerAllBootStrapComponents(registry);
39
+ }
40
+ }
41
+ ```
42
+
43
+ ---
44
+
45
+ ## Available Components & Schemas
46
+
47
+ ### 1. Text Input (`input-text`)
48
+ Uses `NgsFormsBootstrapFormItemInputComponent`.
49
+
50
+ - **Selector/Key**: `input-text`
51
+ - **Config Type**: `NgsFormsFormItemConfigBootstrapTextInput`
52
+ - **Features**: Supports label locations (`top` or `left`), validation status borders, invalid feedback, custom types (`text`, `email`, `password`), and placeholder bindings.
53
+
54
+ ```typescript
55
+ import { NgsFormsBootstrapFormItemInputComponent } from '@ng-simplicity/forms-bootstrap';
56
+ import { Validators } from '@angular/forms';
57
+
58
+ const usernameField = NgsFormsBootstrapFormItemInputComponent.create({
59
+ name: 'username',
60
+ label: 'Username',
61
+ placeholder: 'Enter username...',
62
+ type: 'text',
63
+ labelLocation: 'top',
64
+ validators: [Validators.required]
65
+ });
66
+ ```
67
+
68
+ ### 2. Text Area (`input-textarea`)
69
+ Uses `NgsFormsBootstrapFormsItemTextAreaComponent`.
70
+
71
+ - **Selector/Key**: `input-textarea`
72
+ - **Config Type**: `NgsFormsFormItemConfigBootstrapTextArea`
73
+ - **Features**: Supports rows configuration, css classes override, validation classes, label locations, and placeholder bindings.
74
+
75
+ ```typescript
76
+ import { NgsFormsBootstrapFormsItemTextAreaComponent } from '@ng-simplicity/forms-bootstrap';
77
+
78
+ const bioField = NgsFormsBootstrapFormsItemTextAreaComponent.create({
79
+ name: 'bio',
80
+ label: 'About Me',
81
+ placeholder: 'Tell us about yourself...',
82
+ labelLocation: 'left',
83
+ inputCssClass: 'shadow-sm'
84
+ });
85
+ ```
86
+
87
+ ---
88
+
89
+ ## Unit Testing
90
+
91
+ Run unit tests for this library package using:
92
+
93
+ ```bash
94
+ nx test forms-bootstrap
95
+ ```
96
+
97
+ To run with coverage enabled:
98
+ ```bash
99
+ nx test forms-bootstrap --codeCoverage
100
+ ```
@@ -0,0 +1,135 @@
1
+ import * as i0 from '@angular/core';
2
+ import { ChangeDetectionStrategy, Component, NgModule } from '@angular/core';
3
+ import { NgsFormsBaseClassFormInputComponent, NgsFormsBaseClassFormItemInputWithOptionsComponent, NgsFormsCoreModule } from '@ng-simplicity/forms-core';
4
+ import * as i1 from '@angular/forms';
5
+ import { ReactiveFormsModule, FormsModule } from '@angular/forms';
6
+ import { v4 } from 'uuid';
7
+ import { defaults } from 'lodash';
8
+ import { NgIf, CommonModule } from '@angular/common';
9
+
10
+ class NgsFormsBootstrapFormsItemCheckboxComponent extends NgsFormsBaseClassFormInputComponent {
11
+ static key = 'checkbox';
12
+ checkboxConfig = this.config;
13
+ static create(config) {
14
+ return {
15
+ uuid: v4(),
16
+ type: NgsFormsBootstrapFormsItemCheckboxComponent.key,
17
+ config,
18
+ };
19
+ }
20
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapFormsItemCheckboxComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
21
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: NgsFormsBootstrapFormsItemCheckboxComponent, isStandalone: true, selector: "ngs-form-item-bs-checkbox", usesInheritance: true, ngImport: i0, template: "@if (control) {\n <div class=\"form-check\">\n <input [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\" class=\"form-check-input\" id=\"{{id}}\"\n type=\"checkbox\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-check-label\" for=\"{{id}}\">\n {{ checkboxConfig.label }}\n </label>\n </div>\n}\n\n", dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
22
+ }
23
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapFormsItemCheckboxComponent, decorators: [{
24
+ type: Component,
25
+ args: [{ selector: 'ngs-form-item-bs-checkbox', imports: [ReactiveFormsModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (control) {\n <div class=\"form-check\">\n <input [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\" class=\"form-check-input\" id=\"{{id}}\"\n type=\"checkbox\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-check-label\" for=\"{{id}}\">\n {{ checkboxConfig.label }}\n </label>\n </div>\n}\n\n" }]
26
+ }] });
27
+
28
+ const NgsFormBootstrapInputComponentResources = {
29
+ defaults: {
30
+ type: 'text',
31
+ labelLocation: 'top',
32
+ },
33
+ };
34
+
35
+ class NgsFormsBootstrapFormItemInputComponent extends NgsFormsBaseClassFormInputComponent {
36
+ static key = 'input-text';
37
+ textConfig = defaults(this.config, NgsFormBootstrapInputComponentResources.defaults);
38
+ constructor() {
39
+ super();
40
+ }
41
+ static create(config) {
42
+ return {
43
+ uuid: v4(),
44
+ type: NgsFormsBootstrapFormItemInputComponent.key,
45
+ config,
46
+ };
47
+ }
48
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapFormItemInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
49
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: NgsFormsBootstrapFormItemInputComponent, isStandalone: true, selector: "ngs-forms-bs-input", usesInheritance: true, ngImport: i0, template: "@if (!!control) {\n @if (textConfig.labelLocation === 'top') {\n <div class=\"mb-2\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-label\" for=\"{{id}}-top\">{{ textConfig.label }}</label>\n <input [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\" class=\"form-control\"\n id=\"{{id}}-top\" placeholder=\"{{textConfig.placeholder}}\" type=\"{{textConfig.type}}\" />\n @if (errorMessage) {\n <div class=\"invalid-feedback\">{{ errorMessage }}</div>\n }\n </div>\n }\n @if (textConfig.labelLocation === 'left') {\n <div class=\"row mb-2\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"col-sm-2 col-form-label\"\n for=\"{{id}}-left\">{{ textConfig.label }}</label>\n <div class=\"col-sm-10\">\n <input [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\" class=\"form-control\"\n id=\"{{id}}-left\" placeholder=\"{{textConfig.placeholder}}\" type=\"{{textConfig.type}}\" />\n </div>\n @if (errorMessage) {\n <div class=\"invalid-feedback\">{{ errorMessage }}</div>\n }\n </div>\n }\n}\n", dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
50
+ }
51
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapFormItemInputComponent, decorators: [{
52
+ type: Component,
53
+ args: [{ selector: 'ngs-forms-bs-input', imports: [ReactiveFormsModule, NgIf], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (!!control) {\n @if (textConfig.labelLocation === 'top') {\n <div class=\"mb-2\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-label\" for=\"{{id}}-top\">{{ textConfig.label }}</label>\n <input [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\" class=\"form-control\"\n id=\"{{id}}-top\" placeholder=\"{{textConfig.placeholder}}\" type=\"{{textConfig.type}}\" />\n @if (errorMessage) {\n <div class=\"invalid-feedback\">{{ errorMessage }}</div>\n }\n </div>\n }\n @if (textConfig.labelLocation === 'left') {\n <div class=\"row mb-2\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"col-sm-2 col-form-label\"\n for=\"{{id}}-left\">{{ textConfig.label }}</label>\n <div class=\"col-sm-10\">\n <input [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\" class=\"form-control\"\n id=\"{{id}}-left\" placeholder=\"{{textConfig.placeholder}}\" type=\"{{textConfig.type}}\" />\n </div>\n @if (errorMessage) {\n <div class=\"invalid-feedback\">{{ errorMessage }}</div>\n }\n </div>\n }\n}\n" }]
54
+ }], ctorParameters: () => [] });
55
+
56
+ class NgsFormsBootstrapRadioInputComponent extends NgsFormsBaseClassFormItemInputWithOptionsComponent {
57
+ static key = 'radio';
58
+ radioConfig = this.config;
59
+ static create(config) {
60
+ return {
61
+ uuid: v4(),
62
+ type: NgsFormsBootstrapRadioInputComponent.key,
63
+ config,
64
+ };
65
+ }
66
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapRadioInputComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
67
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: NgsFormsBootstrapRadioInputComponent, isStandalone: true, selector: "ngs-forms-bootstrap-radio-group-input", usesInheritance: true, ngImport: i0, template: "@if (control) {\n <div [class.d-flex]=\"radioConfig.alignment==='horizontal'\">\n @if (!!radioConfig.label) {\n <div [class.text-danger]=\"!!errorMessage\" class=\"form-label me-2 pt-0\">\n {{ radioConfig.label }}\n </div>\n }\n @for (option of options(); track option.id) {\n <div [class.form-check-inline]=\"radioConfig.alignment==='horizontal'\"\n [class.me-2]=\"radioConfig.alignment==='horizontal'\"\n class=\"form-check\">\n <input [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\" value=\"{{option.id}}\" class=\"form-check-input\"\n id=\"{{id}}{{option.id}}\" type=\"radio\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-check-label\"\n for=\"{{id}}{{option.id}}\">{{ option.label }}</label>\n </div>\n }\n </div>\n}\n\n", dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.RadioControlValueAccessor, selector: "input[type=radio][formControlName],input[type=radio][formControl],input[type=radio][ngModel]", inputs: ["name", "formControlName", "value"] }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
68
+ }
69
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapRadioInputComponent, decorators: [{
70
+ type: Component,
71
+ args: [{ selector: 'ngs-forms-bootstrap-radio-group-input', imports: [ReactiveFormsModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (control) {\n <div [class.d-flex]=\"radioConfig.alignment==='horizontal'\">\n @if (!!radioConfig.label) {\n <div [class.text-danger]=\"!!errorMessage\" class=\"form-label me-2 pt-0\">\n {{ radioConfig.label }}\n </div>\n }\n @for (option of options(); track option.id) {\n <div [class.form-check-inline]=\"radioConfig.alignment==='horizontal'\"\n [class.me-2]=\"radioConfig.alignment==='horizontal'\"\n class=\"form-check\">\n <input [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\" value=\"{{option.id}}\" class=\"form-check-input\"\n id=\"{{id}}{{option.id}}\" type=\"radio\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-check-label\"\n for=\"{{id}}{{option.id}}\">{{ option.label }}</label>\n </div>\n }\n </div>\n}\n\n" }]
72
+ }] });
73
+
74
+ class NgsFormsBootstrapFormItemSelectInputComponent extends NgsFormsBaseClassFormItemInputWithOptionsComponent {
75
+ static key = 'select';
76
+ selectConfig = this.config;
77
+ static create(config) {
78
+ return {
79
+ uuid: v4(),
80
+ type: NgsFormsBootstrapFormItemSelectInputComponent.key,
81
+ config,
82
+ };
83
+ }
84
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapFormItemSelectInputComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
85
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: NgsFormsBootstrapFormItemSelectInputComponent, isStandalone: true, selector: "ngs-forms-bootstrap-select-input", usesInheritance: true, ngImport: i0, template: "@if (control) {\n @if (selectConfig.labelLocation === 'top') {\n <div class=\"mb-3\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-label\" for=\"{{id}}-top\">{{ selectConfig.label }}</label>\n <select [attr.aria-label]=\"selectConfig.label\" [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\"\n class=\"form-select\">\n @if (selectConfig.placeholder) {\n <option [disabled]=\"true\" [value]=\"selectConfig.placeHolderValue || ''\">{{ selectConfig.placeholder }}\n </option>\n }\n @for (option of options(); track option.id) {\n <option [disabled]=\"option.disabled\" [value]=\"option.id\">\n {{ option.label }}\n </option>\n }\n </select>\n @if (errorMessage) {\n <div class=\"invalid-feedback\">{{ errorMessage }}</div>\n }\n </div>\n } @else {\n\n <div class=\"mb-3 row\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"col-sm-2 col-form-label\"\n for=\"{{id}}-left\">{{ selectConfig.label }}</label>\n <div class=\"col-sm-10\">\n <select [attr.aria-label]=\"selectConfig.label\" [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\"\n class=\"form-select\">\n @if (selectConfig.placeholder) {\n <option [disabled]=\"true\" [value]=\"selectConfig.placeHolderValue || ''\">{{ selectConfig.placeholder }}\n </option>\n }\n @for (option of options(); track option.id) {\n <option [disabled]=\"option.disabled\" [value]=\"option.id\">\n {{ option.label }}\n </option>\n }\n </select>\n @if (errorMessage) {\n <div class=\"invalid-feedback\">{{ errorMessage }}</div>\n }\n </div>\n </div>\n }\n}\n\n", dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
86
+ }
87
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapFormItemSelectInputComponent, decorators: [{
88
+ type: Component,
89
+ args: [{ selector: 'ngs-forms-bootstrap-select-input', imports: [ReactiveFormsModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (control) {\n @if (selectConfig.labelLocation === 'top') {\n <div class=\"mb-3\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-label\" for=\"{{id}}-top\">{{ selectConfig.label }}</label>\n <select [attr.aria-label]=\"selectConfig.label\" [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\"\n class=\"form-select\">\n @if (selectConfig.placeholder) {\n <option [disabled]=\"true\" [value]=\"selectConfig.placeHolderValue || ''\">{{ selectConfig.placeholder }}\n </option>\n }\n @for (option of options(); track option.id) {\n <option [disabled]=\"option.disabled\" [value]=\"option.id\">\n {{ option.label }}\n </option>\n }\n </select>\n @if (errorMessage) {\n <div class=\"invalid-feedback\">{{ errorMessage }}</div>\n }\n </div>\n } @else {\n\n <div class=\"mb-3 row\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"col-sm-2 col-form-label\"\n for=\"{{id}}-left\">{{ selectConfig.label }}</label>\n <div class=\"col-sm-10\">\n <select [attr.aria-label]=\"selectConfig.label\" [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\"\n class=\"form-select\">\n @if (selectConfig.placeholder) {\n <option [disabled]=\"true\" [value]=\"selectConfig.placeHolderValue || ''\">{{ selectConfig.placeholder }}\n </option>\n }\n @for (option of options(); track option.id) {\n <option [disabled]=\"option.disabled\" [value]=\"option.id\">\n {{ option.label }}\n </option>\n }\n </select>\n @if (errorMessage) {\n <div class=\"invalid-feedback\">{{ errorMessage }}</div>\n }\n </div>\n </div>\n }\n}\n\n" }]
90
+ }] });
91
+
92
+ class NgsFormsBootstrapFormsItemTextAreaComponent extends NgsFormsBaseClassFormInputComponent {
93
+ static key = 'input-textarea';
94
+ textAreaConfig = this.config;
95
+ static create(config) {
96
+ return {
97
+ uuid: v4(),
98
+ type: NgsFormsBootstrapFormsItemTextAreaComponent.key,
99
+ config,
100
+ };
101
+ }
102
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapFormsItemTextAreaComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
103
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: NgsFormsBootstrapFormsItemTextAreaComponent, isStandalone: true, selector: "ngs-form-item-bs-text-area", usesInheritance: true, ngImport: i0, template: "@if (control) {\n @if (textAreaConfig.labelLocation === 'top' || !textAreaConfig.labelLocation) {\n <div class=\"mb-3\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-label\" for=\"{{id}}-top\">{{ textAreaConfig.label }}</label>\n <textarea [class.border-danger]=\"!!errorMessage\"\n [formControl]=\"control\"\n class=\"form-control {{textAreaConfig.inputCssClass}}\"\n id=\"{{id}}-top\"\n placeholder=\"{{textAreaConfig.placeholder}}\"\n style=\"height: 210px\"></textarea>\n @if (errorMessage) {\n <div class=\"text-danger\">{{ errorMessage }}</div>\n }\n </div>\n\n } @else {\n @if (textAreaConfig.labelLocation === 'left') {\n <div class=\"mb-3 row\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"col-sm-2 col-form-label\"\n for=\"{{id}}-left\">{{ textAreaConfig.label }}</label>\n <div class=\"col-sm-10\">\n <textarea [class.border-danger]=\"!!errorMessage\"\n [formControl]=\"control\"\n class=\"form-control {{textAreaConfig.inputCssClass}}\"\n id=\"{{id}}-left\"\n placeholder=\"{{textAreaConfig.placeholder}}\"\n style=\"height: 210px\"></textarea>\n </div>\n @if (errorMessage) {\n <div class=\"text-danger\">{{ errorMessage }}</div>\n }\n </div>\n }\n }\n}\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
104
+ }
105
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapFormsItemTextAreaComponent, decorators: [{
106
+ type: Component,
107
+ args: [{ selector: 'ngs-form-item-bs-text-area', imports: [CommonModule, ReactiveFormsModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (control) {\n @if (textAreaConfig.labelLocation === 'top' || !textAreaConfig.labelLocation) {\n <div class=\"mb-3\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-label\" for=\"{{id}}-top\">{{ textAreaConfig.label }}</label>\n <textarea [class.border-danger]=\"!!errorMessage\"\n [formControl]=\"control\"\n class=\"form-control {{textAreaConfig.inputCssClass}}\"\n id=\"{{id}}-top\"\n placeholder=\"{{textAreaConfig.placeholder}}\"\n style=\"height: 210px\"></textarea>\n @if (errorMessage) {\n <div class=\"text-danger\">{{ errorMessage }}</div>\n }\n </div>\n\n } @else {\n @if (textAreaConfig.labelLocation === 'left') {\n <div class=\"mb-3 row\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"col-sm-2 col-form-label\"\n for=\"{{id}}-left\">{{ textAreaConfig.label }}</label>\n <div class=\"col-sm-10\">\n <textarea [class.border-danger]=\"!!errorMessage\"\n [formControl]=\"control\"\n class=\"form-control {{textAreaConfig.inputCssClass}}\"\n id=\"{{id}}-left\"\n placeholder=\"{{textAreaConfig.placeholder}}\"\n style=\"height: 210px\"></textarea>\n </div>\n @if (errorMessage) {\n <div class=\"text-danger\">{{ errorMessage }}</div>\n }\n </div>\n }\n }\n}\n" }]
108
+ }] });
109
+
110
+ class NgsFormsBootstrapModule {
111
+ static registerAllBootStrapComponents(registryService) {
112
+ NgsFormsCoreModule.registerCoreNgsFormComponents(registryService);
113
+ registryService.register(NgsFormsBootstrapFormsItemCheckboxComponent.key, NgsFormsBootstrapFormsItemCheckboxComponent);
114
+ registryService.register(NgsFormsBootstrapFormItemInputComponent.key, NgsFormsBootstrapFormItemInputComponent);
115
+ registryService.register(NgsFormsBootstrapRadioInputComponent.key, NgsFormsBootstrapRadioInputComponent);
116
+ registryService.register(NgsFormsBootstrapFormItemSelectInputComponent.key, NgsFormsBootstrapFormItemSelectInputComponent);
117
+ registryService.register(NgsFormsBootstrapFormsItemTextAreaComponent.key, NgsFormsBootstrapFormsItemTextAreaComponent);
118
+ }
119
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
120
+ static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapModule, imports: [CommonModule, FormsModule, ReactiveFormsModule, NgsFormsCoreModule] });
121
+ static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapModule, imports: [CommonModule, FormsModule, ReactiveFormsModule, NgsFormsCoreModule] });
122
+ }
123
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NgsFormsBootstrapModule, decorators: [{
124
+ type: NgModule,
125
+ args: [{
126
+ imports: [CommonModule, FormsModule, ReactiveFormsModule, NgsFormsCoreModule],
127
+ }]
128
+ }] });
129
+
130
+ /**
131
+ * Generated bundle index. Do not edit.
132
+ */
133
+
134
+ export { NgsFormsBootstrapFormItemInputComponent, NgsFormsBootstrapFormItemSelectInputComponent, NgsFormsBootstrapFormsItemCheckboxComponent, NgsFormsBootstrapFormsItemTextAreaComponent, NgsFormsBootstrapModule, NgsFormsBootstrapRadioInputComponent };
135
+ //# sourceMappingURL=ng-simplicity-forms-bootstrap.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ng-simplicity-forms-bootstrap.mjs","sources":["../../../../libs/forms-bootstrap/src/lib/form-components/checkbox/checkbox.component.ts","../../../../libs/forms-bootstrap/src/lib/form-components/checkbox/checkbox.component.html","../../../../libs/forms-bootstrap/src/lib/form-components/input/input-component.resources.ts","../../../../libs/forms-bootstrap/src/lib/form-components/input/input.component.ts","../../../../libs/forms-bootstrap/src/lib/form-components/input/input.component.html","../../../../libs/forms-bootstrap/src/lib/form-components/radio/radio.component.ts","../../../../libs/forms-bootstrap/src/lib/form-components/radio/radio.component.html","../../../../libs/forms-bootstrap/src/lib/form-components/select/select.component.ts","../../../../libs/forms-bootstrap/src/lib/form-components/select/select.component.html","../../../../libs/forms-bootstrap/src/lib/form-components/text-area/text-area.component.ts","../../../../libs/forms-bootstrap/src/lib/form-components/text-area/text-area.component.html","../../../../libs/forms-bootstrap/src/lib/forms-bootstrap.module.ts","../../../../libs/forms-bootstrap/src/ng-simplicity-forms-bootstrap.ts"],"sourcesContent":["import { Component, ChangeDetectionStrategy } from '@angular/core';\nimport { NgsFormsBaseClassFormInputComponent, NgsFormsFormItem, NgsFormsFormItemConfigBaseInput } from '@ng-simplicity/forms-core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { NgsFormsFormItemConfigBootstrapCheckbox } from './checkbox.config';\nimport { v4 } from 'uuid';\n\n@Component({\n selector: 'ngs-form-item-bs-checkbox',\n imports: [ReactiveFormsModule],\n templateUrl: './checkbox.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class NgsFormsBootstrapFormsItemCheckboxComponent extends NgsFormsBaseClassFormInputComponent<NgsFormsFormItemConfigBootstrapCheckbox> {\n static override key = 'checkbox';\n checkboxConfig = this.config as NgsFormsFormItemConfigBootstrapCheckbox;\n\n static create(\n config: NgsFormsFormItemConfigBootstrapCheckbox\n ): NgsFormsFormItem<NgsFormsFormItemConfigBootstrapCheckbox> {\n return {\n uuid: v4(),\n type: NgsFormsBootstrapFormsItemCheckboxComponent.key,\n config,\n };\n }\n}\n","@if (control) {\n <div class=\"form-check\">\n <input [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\" class=\"form-check-input\" id=\"{{id}}\"\n type=\"checkbox\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-check-label\" for=\"{{id}}\">\n {{ checkboxConfig.label }}\n </label>\n </div>\n}\n\n","import { NgsFormsFormItemConfigBootstrapTextInput } from './input.config';\n\nexport const NgsFormBootstrapInputComponentResources: INgsFormBoostrapInputComponentResources = {\n defaults: {\n type: 'text',\n labelLocation: 'top',\n },\n};\n\nexport interface INgsFormBoostrapInputComponentResources {\n defaults: Partial<NgsFormsFormItemConfigBootstrapTextInput>;\n}\n","import { Component, ChangeDetectionStrategy } from '@angular/core';\nimport { NgsFormsBaseClassFormInputComponent, NgsFormsFormItem } from '@ng-simplicity/forms-core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { defaults } from 'lodash';\nimport { NgsFormBootstrapInputComponentResources } from './input-component.resources';\nimport { NgsFormsFormItemConfigBootstrapTextInput } from './input.config';\nimport { v4 } from 'uuid';\nimport { NgIf } from '@angular/common';\n\n@Component({\n selector: 'ngs-forms-bs-input',\n imports: [ReactiveFormsModule, NgIf],\n templateUrl: './input.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class NgsFormsBootstrapFormItemInputComponent extends NgsFormsBaseClassFormInputComponent<NgsFormsFormItemConfigBootstrapTextInput> {\n static override key = 'input-text';\n textConfig: NgsFormsFormItemConfigBootstrapTextInput = defaults(this.config as NgsFormsFormItemConfigBootstrapTextInput, NgsFormBootstrapInputComponentResources.defaults);\n constructor() {\n super();\n }\n\n static create(config: NgsFormsFormItemConfigBootstrapTextInput): NgsFormsFormItem<NgsFormsFormItemConfigBootstrapTextInput> {\n return {\n uuid: v4(),\n type: NgsFormsBootstrapFormItemInputComponent.key,\n config,\n };\n }\n}\n","@if (!!control) {\n @if (textConfig.labelLocation === 'top') {\n <div class=\"mb-2\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-label\" for=\"{{id}}-top\">{{ textConfig.label }}</label>\n <input [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\" class=\"form-control\"\n id=\"{{id}}-top\" placeholder=\"{{textConfig.placeholder}}\" type=\"{{textConfig.type}}\" />\n @if (errorMessage) {\n <div class=\"invalid-feedback\">{{ errorMessage }}</div>\n }\n </div>\n }\n @if (textConfig.labelLocation === 'left') {\n <div class=\"row mb-2\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"col-sm-2 col-form-label\"\n for=\"{{id}}-left\">{{ textConfig.label }}</label>\n <div class=\"col-sm-10\">\n <input [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\" class=\"form-control\"\n id=\"{{id}}-left\" placeholder=\"{{textConfig.placeholder}}\" type=\"{{textConfig.type}}\" />\n </div>\n @if (errorMessage) {\n <div class=\"invalid-feedback\">{{ errorMessage }}</div>\n }\n </div>\n }\n}\n","import { Component, ChangeDetectionStrategy } from '@angular/core';\nimport { NgsFormsBaseClassFormItemInputWithOptionsComponent, NgsFormsFormItem } from '@ng-simplicity/forms-core';\nimport { NgsFormsFormsItemConfigBoostrapRadio } from './radio.config';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { v4 } from 'uuid';\n\n@Component({\n selector: 'ngs-forms-bootstrap-radio-group-input',\n imports: [ReactiveFormsModule],\n templateUrl: './radio.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class NgsFormsBootstrapRadioInputComponent extends NgsFormsBaseClassFormItemInputWithOptionsComponent<NgsFormsFormsItemConfigBoostrapRadio> {\n static override key = 'radio';\n radioConfig = this.config as NgsFormsFormsItemConfigBoostrapRadio;\n\n static create(\n config: NgsFormsFormsItemConfigBoostrapRadio\n ): NgsFormsFormItem<NgsFormsFormsItemConfigBoostrapRadio> {\n return {\n uuid: v4(),\n type: NgsFormsBootstrapRadioInputComponent.key,\n config,\n };\n }\n}\n","@if (control) {\n <div [class.d-flex]=\"radioConfig.alignment==='horizontal'\">\n @if (!!radioConfig.label) {\n <div [class.text-danger]=\"!!errorMessage\" class=\"form-label me-2 pt-0\">\n {{ radioConfig.label }}\n </div>\n }\n @for (option of options(); track option.id) {\n <div [class.form-check-inline]=\"radioConfig.alignment==='horizontal'\"\n [class.me-2]=\"radioConfig.alignment==='horizontal'\"\n class=\"form-check\">\n <input [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\" value=\"{{option.id}}\" class=\"form-check-input\"\n id=\"{{id}}{{option.id}}\" type=\"radio\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-check-label\"\n for=\"{{id}}{{option.id}}\">{{ option.label }}</label>\n </div>\n }\n </div>\n}\n\n","import { Component, ChangeDetectionStrategy } from '@angular/core';\nimport { NgsFormsFormItemConfigBootstrapSelectInput } from './select.config';\n\nimport { NgsFormsBaseClassFormItemInputWithOptionsComponent, NgsFormsFormItem } from '@ng-simplicity/forms-core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { v4 } from 'uuid';\n\n@Component({\n selector: 'ngs-forms-bootstrap-select-input',\n imports: [ReactiveFormsModule],\n templateUrl: './select.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class NgsFormsBootstrapFormItemSelectInputComponent extends NgsFormsBaseClassFormItemInputWithOptionsComponent<NgsFormsFormItemConfigBootstrapSelectInput> {\n static override key = 'select';\n selectConfig = this.config as NgsFormsFormItemConfigBootstrapSelectInput;\n\n static create(\n config: NgsFormsFormItemConfigBootstrapSelectInput\n ): NgsFormsFormItem<NgsFormsFormItemConfigBootstrapSelectInput> {\n return {\n uuid: v4(),\n type: NgsFormsBootstrapFormItemSelectInputComponent.key,\n config,\n };\n }\n}\n","@if (control) {\n @if (selectConfig.labelLocation === 'top') {\n <div class=\"mb-3\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-label\" for=\"{{id}}-top\">{{ selectConfig.label }}</label>\n <select [attr.aria-label]=\"selectConfig.label\" [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\"\n class=\"form-select\">\n @if (selectConfig.placeholder) {\n <option [disabled]=\"true\" [value]=\"selectConfig.placeHolderValue || ''\">{{ selectConfig.placeholder }}\n </option>\n }\n @for (option of options(); track option.id) {\n <option [disabled]=\"option.disabled\" [value]=\"option.id\">\n {{ option.label }}\n </option>\n }\n </select>\n @if (errorMessage) {\n <div class=\"invalid-feedback\">{{ errorMessage }}</div>\n }\n </div>\n } @else {\n\n <div class=\"mb-3 row\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"col-sm-2 col-form-label\"\n for=\"{{id}}-left\">{{ selectConfig.label }}</label>\n <div class=\"col-sm-10\">\n <select [attr.aria-label]=\"selectConfig.label\" [class.border-danger]=\"!!errorMessage\" [formControl]=\"control\"\n class=\"form-select\">\n @if (selectConfig.placeholder) {\n <option [disabled]=\"true\" [value]=\"selectConfig.placeHolderValue || ''\">{{ selectConfig.placeholder }}\n </option>\n }\n @for (option of options(); track option.id) {\n <option [disabled]=\"option.disabled\" [value]=\"option.id\">\n {{ option.label }}\n </option>\n }\n </select>\n @if (errorMessage) {\n <div class=\"invalid-feedback\">{{ errorMessage }}</div>\n }\n </div>\n </div>\n }\n}\n\n","import { Component, ChangeDetectionStrategy } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { NgsFormsBaseClassFormInputComponent, NgsFormsFormItem } from '@ng-simplicity/forms-core';\nimport { NgsFormsFormItemConfigBootstrapTextArea } from './text-area.config';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { v4 } from 'uuid';\n\n@Component({\n selector: 'ngs-form-item-bs-text-area',\n imports: [CommonModule, ReactiveFormsModule],\n templateUrl: './text-area.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class NgsFormsBootstrapFormsItemTextAreaComponent extends NgsFormsBaseClassFormInputComponent<NgsFormsFormItemConfigBootstrapTextArea> {\n static override key = 'input-textarea';\n textAreaConfig = this.config as NgsFormsFormItemConfigBootstrapTextArea;\n\n static create(config: NgsFormsFormItemConfigBootstrapTextArea): NgsFormsFormItem<NgsFormsFormItemConfigBootstrapTextArea> {\n return {\n uuid: v4(),\n type: NgsFormsBootstrapFormsItemTextAreaComponent.key,\n config,\n };\n }\n}\n","@if (control) {\n @if (textAreaConfig.labelLocation === 'top' || !textAreaConfig.labelLocation) {\n <div class=\"mb-3\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"form-label\" for=\"{{id}}-top\">{{ textAreaConfig.label }}</label>\n <textarea [class.border-danger]=\"!!errorMessage\"\n [formControl]=\"control\"\n class=\"form-control {{textAreaConfig.inputCssClass}}\"\n id=\"{{id}}-top\"\n placeholder=\"{{textAreaConfig.placeholder}}\"\n style=\"height: 210px\"></textarea>\n @if (errorMessage) {\n <div class=\"text-danger\">{{ errorMessage }}</div>\n }\n </div>\n\n } @else {\n @if (textAreaConfig.labelLocation === 'left') {\n <div class=\"mb-3 row\">\n <label [class.text-danger]=\"!!errorMessage\" class=\"col-sm-2 col-form-label\"\n for=\"{{id}}-left\">{{ textAreaConfig.label }}</label>\n <div class=\"col-sm-10\">\n <textarea [class.border-danger]=\"!!errorMessage\"\n [formControl]=\"control\"\n class=\"form-control {{textAreaConfig.inputCssClass}}\"\n id=\"{{id}}-left\"\n placeholder=\"{{textAreaConfig.placeholder}}\"\n style=\"height: 210px\"></textarea>\n </div>\n @if (errorMessage) {\n <div class=\"text-danger\">{{ errorMessage }}</div>\n }\n </div>\n }\n }\n}\n","import { NgModule } from '@angular/core';\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\nimport { CommonModule } from '@angular/common';\nimport { NgsFormsComponentRegistryService, NgsFormsCoreModule } from '@ng-simplicity/forms-core';\nimport {\n NgsFormsBootstrapFormItemInputComponent,\n NgsFormsBootstrapFormsItemTextAreaComponent,\n NgsFormsBootstrapFormsItemCheckboxComponent,\n NgsFormsBootstrapRadioInputComponent,\n NgsFormsBootstrapFormItemSelectInputComponent\n} from './form-components';\n\n@NgModule({\n imports: [CommonModule, FormsModule, ReactiveFormsModule, NgsFormsCoreModule],\n})\nexport class NgsFormsBootstrapModule {\n static registerAllBootStrapComponents(registryService: NgsFormsComponentRegistryService) {\n NgsFormsCoreModule.registerCoreNgsFormComponents(registryService);\n registryService.register(NgsFormsBootstrapFormsItemCheckboxComponent.key, NgsFormsBootstrapFormsItemCheckboxComponent);\n registryService.register(NgsFormsBootstrapFormItemInputComponent.key, NgsFormsBootstrapFormItemInputComponent);\n registryService.register(NgsFormsBootstrapRadioInputComponent.key, NgsFormsBootstrapRadioInputComponent);\n registryService.register(NgsFormsBootstrapFormItemSelectInputComponent.key, NgsFormsBootstrapFormItemSelectInputComponent);\n registryService.register(NgsFormsBootstrapFormsItemTextAreaComponent.key, NgsFormsBootstrapFormsItemTextAreaComponent);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;AAYM,MAAO,2CAA4C,SAAQ,mCAA4E,CAAA;AAC3I,IAAA,OAAgB,GAAG,GAAG,UAAU;AAChC,IAAA,cAAc,GAAG,IAAI,CAAC,MAAiD;IAEvE,OAAO,MAAM,CACX,MAA+C,EAAA;QAE/C,OAAO;YACL,IAAI,EAAE,EAAE,EAAE;YACV,IAAI,EAAE,2CAA2C,CAAC,GAAG;YACrD,MAAM;SACP;IACH;wGAZW,2CAA2C,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;4FAA3C,2CAA2C,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,2BAAA,EAAA,eAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,ECZxD,qWAUA,EAAA,YAAA,EAAA,CAAA,EAA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AAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,uBAAuB,YAFxB,YAAY,EAAE,WAAW,EAAE,mBAAmB,EAAE,kBAAkB,CAAA,EAAA,CAAA;AAEjE,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,uBAAuB,YAFxB,YAAY,EAAE,WAAW,EAAE,mBAAmB,EAAE,kBAAkB,CAAA,EAAA,CAAA;;4FAEjE,uBAAuB,EAAA,UAAA,EAAA,CAAA;kBAHnC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,YAAY,EAAE,WAAW,EAAE,mBAAmB,EAAE,kBAAkB,CAAC;AAC9E,iBAAA;;;ACdD;;AAEG;;;;"}
package/index.d.ts ADDED
@@ -0,0 +1,78 @@
1
+ import * as i3 from '@ng-simplicity/forms-core';
2
+ import { NgsFormsFormItemConfigBaseInput, NgsFormsBaseClassFormInputComponent, NgsFormsFormItem, NgsFormsFormItemConfigBaseTextInput, NgsFormsFormItemConfigBaseInputWithOptions, NgsFormsBaseClassFormItemInputWithOptionsComponent, NgsFormsComponentRegistryService } from '@ng-simplicity/forms-core';
3
+ import * as i0 from '@angular/core';
4
+ import * as i1 from '@angular/common';
5
+ import * as i2 from '@angular/forms';
6
+
7
+ interface NgsFormsFormItemConfigBootstrapCheckbox extends NgsFormsFormItemConfigBaseInput {
8
+ }
9
+
10
+ declare class NgsFormsBootstrapFormsItemCheckboxComponent extends NgsFormsBaseClassFormInputComponent<NgsFormsFormItemConfigBootstrapCheckbox> {
11
+ static key: string;
12
+ checkboxConfig: NgsFormsFormItemConfigBootstrapCheckbox;
13
+ static create(config: NgsFormsFormItemConfigBootstrapCheckbox): NgsFormsFormItem<NgsFormsFormItemConfigBootstrapCheckbox>;
14
+ static ɵfac: i0.ɵɵFactoryDeclaration<NgsFormsBootstrapFormsItemCheckboxComponent, never>;
15
+ static ɵcmp: i0.ɵɵComponentDeclaration<NgsFormsBootstrapFormsItemCheckboxComponent, "ngs-form-item-bs-checkbox", never, {}, {}, never, never, true, never>;
16
+ }
17
+
18
+ interface NgsFormsFormItemConfigBootstrapTextInput extends NgsFormsFormItemConfigBaseTextInput {
19
+ labelLocation?: 'left' | 'top';
20
+ }
21
+
22
+ declare class NgsFormsBootstrapFormItemInputComponent extends NgsFormsBaseClassFormInputComponent<NgsFormsFormItemConfigBootstrapTextInput> {
23
+ static key: string;
24
+ textConfig: NgsFormsFormItemConfigBootstrapTextInput;
25
+ constructor();
26
+ static create(config: NgsFormsFormItemConfigBootstrapTextInput): NgsFormsFormItem<NgsFormsFormItemConfigBootstrapTextInput>;
27
+ static ɵfac: i0.ɵɵFactoryDeclaration<NgsFormsBootstrapFormItemInputComponent, never>;
28
+ static ɵcmp: i0.ɵɵComponentDeclaration<NgsFormsBootstrapFormItemInputComponent, "ngs-forms-bs-input", never, {}, {}, never, never, true, never>;
29
+ }
30
+
31
+ interface NgsFormsFormsItemConfigBoostrapRadio extends NgsFormsFormItemConfigBaseInputWithOptions {
32
+ alignment?: 'horizontal' | 'vertical';
33
+ }
34
+
35
+ declare class NgsFormsBootstrapRadioInputComponent extends NgsFormsBaseClassFormItemInputWithOptionsComponent<NgsFormsFormsItemConfigBoostrapRadio> {
36
+ static key: string;
37
+ radioConfig: NgsFormsFormsItemConfigBoostrapRadio;
38
+ static create(config: NgsFormsFormsItemConfigBoostrapRadio): NgsFormsFormItem<NgsFormsFormsItemConfigBoostrapRadio>;
39
+ static ɵfac: i0.ɵɵFactoryDeclaration<NgsFormsBootstrapRadioInputComponent, never>;
40
+ static ɵcmp: i0.ɵɵComponentDeclaration<NgsFormsBootstrapRadioInputComponent, "ngs-forms-bootstrap-radio-group-input", never, {}, {}, never, never, true, never>;
41
+ }
42
+
43
+ interface NgsFormsFormItemConfigBootstrapSelectInput extends NgsFormsFormItemConfigBaseInputWithOptions {
44
+ labelLocation?: 'top' | 'left';
45
+ placeholder?: boolean;
46
+ placeHolderValue?: string;
47
+ }
48
+
49
+ declare class NgsFormsBootstrapFormItemSelectInputComponent extends NgsFormsBaseClassFormItemInputWithOptionsComponent<NgsFormsFormItemConfigBootstrapSelectInput> {
50
+ static key: string;
51
+ selectConfig: NgsFormsFormItemConfigBootstrapSelectInput;
52
+ static create(config: NgsFormsFormItemConfigBootstrapSelectInput): NgsFormsFormItem<NgsFormsFormItemConfigBootstrapSelectInput>;
53
+ static ɵfac: i0.ɵɵFactoryDeclaration<NgsFormsBootstrapFormItemSelectInputComponent, never>;
54
+ static ɵcmp: i0.ɵɵComponentDeclaration<NgsFormsBootstrapFormItemSelectInputComponent, "ngs-forms-bootstrap-select-input", never, {}, {}, never, never, true, never>;
55
+ }
56
+
57
+ interface NgsFormsFormItemConfigBootstrapTextArea extends NgsFormsFormItemConfigBaseTextInput {
58
+ labelLocation?: 'left' | 'top';
59
+ inputCssClass?: string;
60
+ }
61
+
62
+ declare class NgsFormsBootstrapFormsItemTextAreaComponent extends NgsFormsBaseClassFormInputComponent<NgsFormsFormItemConfigBootstrapTextArea> {
63
+ static key: string;
64
+ textAreaConfig: NgsFormsFormItemConfigBootstrapTextArea;
65
+ static create(config: NgsFormsFormItemConfigBootstrapTextArea): NgsFormsFormItem<NgsFormsFormItemConfigBootstrapTextArea>;
66
+ static ɵfac: i0.ɵɵFactoryDeclaration<NgsFormsBootstrapFormsItemTextAreaComponent, never>;
67
+ static ɵcmp: i0.ɵɵComponentDeclaration<NgsFormsBootstrapFormsItemTextAreaComponent, "ngs-form-item-bs-text-area", never, {}, {}, never, never, true, never>;
68
+ }
69
+
70
+ declare class NgsFormsBootstrapModule {
71
+ static registerAllBootStrapComponents(registryService: NgsFormsComponentRegistryService): void;
72
+ static ɵfac: i0.ɵɵFactoryDeclaration<NgsFormsBootstrapModule, never>;
73
+ static ɵmod: i0.ɵɵNgModuleDeclaration<NgsFormsBootstrapModule, never, [typeof i1.CommonModule, typeof i2.FormsModule, typeof i2.ReactiveFormsModule, typeof i3.NgsFormsCoreModule], never>;
74
+ static ɵinj: i0.ɵɵInjectorDeclaration<NgsFormsBootstrapModule>;
75
+ }
76
+
77
+ export { NgsFormsBootstrapFormItemInputComponent, NgsFormsBootstrapFormItemSelectInputComponent, NgsFormsBootstrapFormsItemCheckboxComponent, NgsFormsBootstrapFormsItemTextAreaComponent, NgsFormsBootstrapModule, NgsFormsBootstrapRadioInputComponent };
78
+ export type { NgsFormsFormItemConfigBootstrapCheckbox, NgsFormsFormItemConfigBootstrapSelectInput, NgsFormsFormItemConfigBootstrapTextArea, NgsFormsFormItemConfigBootstrapTextInput };
package/package.json ADDED
@@ -0,0 +1,31 @@
1
+ {
2
+ "name": "@ng-simplicity/forms-bootstrap",
3
+ "version": "1.0.0",
4
+ "license": "MIT",
5
+ "repository": {
6
+ "type": "git",
7
+ "url": "git+https://github.com/BryanGWalsh/NgSimplicityForms.git",
8
+ "directory": "libs/forms-bootstrap"
9
+ },
10
+ "peerDependencies": {
11
+ "@angular/common": "^19.0.0 || ^20.0.0",
12
+ "@angular/core": "^19.0.0 || ^20.0.0",
13
+ "@angular/forms": "^19.0.0 || ^20.0.0",
14
+ "@ng-simplicity/forms-core": "^1.0.0"
15
+ },
16
+ "sideEffects": false,
17
+ "module": "fesm2022/ng-simplicity-forms-bootstrap.mjs",
18
+ "typings": "index.d.ts",
19
+ "exports": {
20
+ "./package.json": {
21
+ "default": "./package.json"
22
+ },
23
+ ".": {
24
+ "types": "./index.d.ts",
25
+ "default": "./fesm2022/ng-simplicity-forms-bootstrap.mjs"
26
+ }
27
+ },
28
+ "dependencies": {
29
+ "tslib": "^2.3.0"
30
+ }
31
+ }