@simpleangularcontrols/sac-bootstrap3 10.0.0-rc.1
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/README.md +27 -0
- package/bundles/simpleangularcontrols-sac-bootstrap3.umd.js +2587 -0
- package/bundles/simpleangularcontrols-sac-bootstrap3.umd.js.map +1 -0
- package/bundles/simpleangularcontrols-sac-bootstrap3.umd.min.js +2 -0
- package/bundles/simpleangularcontrols-sac-bootstrap3.umd.min.js.map +1 -0
- package/controls/buttons/button.d.ts +3 -0
- package/controls/buttons/button.module.d.ts +2 -0
- package/controls/buttons/button.module.ngfactory.d.ts +3 -0
- package/controls/buttons/button.ngfactory.d.ts +1 -0
- package/controls/checkbox/checkbox.d.ts +11 -0
- package/controls/checkbox/checkbox.module.d.ts +2 -0
- package/controls/checkbox/checkbox.module.ngfactory.d.ts +3 -0
- package/controls/checkbox/checkbox.ngfactory.d.ts +1 -0
- package/controls/checkbox/checkbox.scss.ngstyle.d.ts +1 -0
- package/controls/checkbox/checkbox.scss.shim.ngstyle.d.ts +1 -0
- package/controls/checkbox/radiobutton.d.ts +5 -0
- package/controls/checkbox/radiobutton.ngfactory.d.ts +1 -0
- package/controls/checkbox/radiobutton.scss.ngstyle.d.ts +1 -0
- package/controls/checkbox/radiobutton.scss.shim.ngstyle.d.ts +1 -0
- package/controls/checkbox/radiobuttons.d.ts +11 -0
- package/controls/checkbox/radiobuttons.ngfactory.d.ts +1 -0
- package/controls/confirm/confirm.d.ts +3 -0
- package/controls/confirm/confirm.module.d.ts +11 -0
- package/controls/confirm/confirm.module.ngfactory.d.ts +3 -0
- package/controls/confirm/confirm.ngfactory.d.ts +1 -0
- package/controls/confirm/confirm.service.d.ts +54 -0
- package/controls/confirm/confirm.service.ngfactory.d.ts +1 -0
- package/controls/datetime/date.d.ts +12 -0
- package/controls/datetime/date.ngfactory.d.ts +1 -0
- package/controls/datetime/dateselector.d.ts +3 -0
- package/controls/datetime/dateselector.ngfactory.d.ts +1 -0
- package/controls/datetime/datetime.d.ts +12 -0
- package/controls/datetime/datetime.module.d.ts +2 -0
- package/controls/datetime/datetime.module.ngfactory.d.ts +3 -0
- package/controls/datetime/datetime.ngfactory.d.ts +1 -0
- package/controls/datetime/time.d.ts +12 -0
- package/controls/datetime/time.ngfactory.d.ts +1 -0
- package/controls/dialog/dialog.d.ts +11 -0
- package/controls/dialog/dialog.module.d.ts +2 -0
- package/controls/dialog/dialog.module.ngfactory.d.ts +3 -0
- package/controls/dialog/dialog.ngfactory.d.ts +1 -0
- package/controls/form/form.d.ts +28 -0
- package/controls/form/form.module.d.ts +2 -0
- package/controls/form/form.module.ngfactory.d.ts +3 -0
- package/controls/form/form.ngfactory.d.ts +1 -0
- package/controls/form/inheritform.directive.d.ts +47 -0
- package/controls/form/inheritform.directive.ngfactory.d.ts +1 -0
- package/controls/grid/grid.d.ts +6 -0
- package/controls/grid/grid.module.d.ts +2 -0
- package/controls/grid/grid.module.ngfactory.d.ts +3 -0
- package/controls/grid/grid.ngfactory.d.ts +1 -0
- package/controls/grid/gridbutton.d.ts +19 -0
- package/controls/grid/gridbutton.ngfactory.d.ts +1 -0
- package/controls/grid/gridcolumn.d.ts +6 -0
- package/controls/grid/gridcolumn.ngfactory.d.ts +1 -0
- package/controls/grid/gridcolumnaction.d.ts +6 -0
- package/controls/grid/gridcolumnaction.ngfactory.d.ts +1 -0
- package/controls/grid/gridimage.d.ts +4 -0
- package/controls/grid/gridimage.ngfactory.d.ts +1 -0
- package/controls/grid/paging.d.ts +8 -0
- package/controls/grid/paging.ngfactory.d.ts +1 -0
- package/controls/input/input.d.ts +11 -0
- package/controls/input/input.module.d.ts +2 -0
- package/controls/input/input.module.ngfactory.d.ts +3 -0
- package/controls/input/input.ngfactory.d.ts +1 -0
- package/controls/input/inputarea.d.ts +23 -0
- package/controls/input/inputarea.ngfactory.d.ts +1 -0
- package/controls/input/inputcurrency.d.ts +11 -0
- package/controls/input/inputcurrency.ngfactory.d.ts +1 -0
- package/controls/input/inputdecimal.d.ts +11 -0
- package/controls/input/inputdecimal.ngfactory.d.ts +1 -0
- package/controls/input/inputemail.d.ts +11 -0
- package/controls/input/inputemail.ngfactory.d.ts +1 -0
- package/controls/input/inputinteger.d.ts +11 -0
- package/controls/input/inputinteger.ngfactory.d.ts +1 -0
- package/controls/input/inputpassword.d.ts +11 -0
- package/controls/input/inputpassword.ngfactory.d.ts +1 -0
- package/controls/input/inputsearch.d.ts +11 -0
- package/controls/input/inputsearch.ngfactory.d.ts +1 -0
- package/controls/layout/formlayout.directive.d.ts +3 -0
- package/controls/layout/formlayout.directive.ngfactory.d.ts +1 -0
- package/controls/layout/layout.module.d.ts +2 -0
- package/controls/layout/layout.module.ngfactory.d.ts +3 -0
- package/controls/layout/tocontrolheight.pipe.d.ts +9 -0
- package/controls/layout/tocontrolheight.pipe.ngfactory.d.ts +1 -0
- package/controls/layout/tocontrolwidthcss.pipe.d.ts +16 -0
- package/controls/layout/tocontrolwidthcss.pipe.ngfactory.d.ts +1 -0
- package/controls/layout/tolabelheight.pipe.d.ts +9 -0
- package/controls/layout/tolabelheight.pipe.ngfactory.d.ts +1 -0
- package/controls/layout/tolabelwidthcss.pipe.d.ts +10 -0
- package/controls/layout/tolabelwidthcss.pipe.ngfactory.d.ts +1 -0
- package/controls/list/dropdown.d.ts +22 -0
- package/controls/list/dropdown.ngfactory.d.ts +1 -0
- package/controls/list/list.module.d.ts +2 -0
- package/controls/list/list.module.ngfactory.d.ts +3 -0
- package/controls/list/listbox.d.ts +11 -0
- package/controls/list/listbox.ngfactory.d.ts +1 -0
- package/controls/static/formcontainer.d.ts +25 -0
- package/controls/static/formcontainer.ngfactory.d.ts +1 -0
- package/controls/static/staticlabel.d.ts +11 -0
- package/controls/static/staticlabel.module.d.ts +2 -0
- package/controls/static/staticlabel.module.ngfactory.d.ts +3 -0
- package/controls/static/staticlabel.ngfactory.d.ts +1 -0
- package/controls/tabs/tab.d.ts +7 -0
- package/controls/tabs/tab.ngfactory.d.ts +1 -0
- package/controls/tabs/tabitem.d.ts +3 -0
- package/controls/tabs/tabitem.ngfactory.d.ts +1 -0
- package/controls/tabs/tabs.module.d.ts +2 -0
- package/controls/tabs/tabs.module.ngfactory.d.ts +3 -0
- package/controls/tinymce/tinymce.d.ts +20 -0
- package/controls/tinymce/tinymce.module.d.ts +2 -0
- package/controls/tinymce/tinymce.module.ngfactory.d.ts +3 -0
- package/controls/tinymce/tinymce.ngfactory.d.ts +1 -0
- package/controls/tooltip/tooltip.d.ts +29 -0
- package/controls/tooltip/tooltip.module.d.ts +2 -0
- package/controls/tooltip/tooltip.module.ngfactory.d.ts +3 -0
- package/controls/tooltip/tooltip.ngfactory.d.ts +1 -0
- package/controls/treeview/ngtreeitemaction.d.ts +5 -0
- package/controls/treeview/ngtreeitemaction.ngfactory.d.ts +1 -0
- package/controls/treeview/treeview.d.ts +3 -0
- package/controls/treeview/treeview.module.d.ts +2 -0
- package/controls/treeview/treeview.module.ngfactory.d.ts +3 -0
- package/controls/treeview/treeview.ngfactory.d.ts +1 -0
- package/controls/treeview/treeviewchild.d.ts +3 -0
- package/controls/treeview/treeviewchild.ngfactory.d.ts +1 -0
- package/controls/upload/upload.d.ts +13 -0
- package/controls/upload/upload.module.d.ts +2 -0
- package/controls/upload/upload.module.ngfactory.d.ts +3 -0
- package/controls/upload/upload.ngfactory.d.ts +1 -0
- package/controls/upload/upload.scss.ngstyle.d.ts +1 -0
- package/controls/upload/upload.scss.shim.ngstyle.d.ts +1 -0
- package/controls/upload/uploadmultiple.d.ts +13 -0
- package/controls/upload/uploadmultiple.ngfactory.d.ts +1 -0
- package/controls/validation/validationsummary.d.ts +11 -0
- package/controls/validation/validationsummary.module.d.ts +2 -0
- package/controls/validation/validationsummary.module.ngfactory.d.ts +3 -0
- package/controls/validation/validationsummary.ngfactory.d.ts +1 -0
- package/controls/wizard/wizard.d.ts +7 -0
- package/controls/wizard/wizard.module.d.ts +2 -0
- package/controls/wizard/wizard.module.ngfactory.d.ts +3 -0
- package/controls/wizard/wizard.ngfactory.d.ts +1 -0
- package/controls/wizard/wizarditem.d.ts +3 -0
- package/controls/wizard/wizarditem.ngfactory.d.ts +1 -0
- package/esm2015/controls/buttons/button.js +11 -0
- package/esm2015/controls/buttons/button.module.js +15 -0
- package/esm2015/controls/buttons/button.module.ngfactory.js +7 -0
- package/esm2015/controls/buttons/button.ngfactory.js +7 -0
- package/esm2015/controls/checkbox/checkbox.js +40 -0
- package/esm2015/controls/checkbox/checkbox.module.js +24 -0
- package/esm2015/controls/checkbox/checkbox.module.ngfactory.js +7 -0
- package/esm2015/controls/checkbox/checkbox.ngfactory.js +7 -0
- package/esm2015/controls/checkbox/checkbox.scss.ngstyle.js +7 -0
- package/esm2015/controls/checkbox/checkbox.scss.shim.ngstyle.js +7 -0
- package/esm2015/controls/checkbox/radiobutton.js +19 -0
- package/esm2015/controls/checkbox/radiobutton.ngfactory.js +7 -0
- package/esm2015/controls/checkbox/radiobutton.scss.ngstyle.js +7 -0
- package/esm2015/controls/checkbox/radiobutton.scss.shim.ngstyle.js +7 -0
- package/esm2015/controls/checkbox/radiobuttons.js +39 -0
- package/esm2015/controls/checkbox/radiobuttons.ngfactory.js +7 -0
- package/esm2015/controls/confirm/confirm.js +11 -0
- package/esm2015/controls/confirm/confirm.module.js +31 -0
- package/esm2015/controls/confirm/confirm.module.ngfactory.js +7 -0
- package/esm2015/controls/confirm/confirm.ngfactory.js +7 -0
- package/esm2015/controls/confirm/confirm.service.js +102 -0
- package/esm2015/controls/confirm/confirm.service.ngfactory.js +7 -0
- package/esm2015/controls/datetime/date.js +44 -0
- package/esm2015/controls/datetime/date.ngfactory.js +7 -0
- package/esm2015/controls/datetime/dateselector.js +11 -0
- package/esm2015/controls/datetime/dateselector.ngfactory.js +7 -0
- package/esm2015/controls/datetime/datetime.js +41 -0
- package/esm2015/controls/datetime/datetime.module.js +28 -0
- package/esm2015/controls/datetime/datetime.module.ngfactory.js +7 -0
- package/esm2015/controls/datetime/datetime.ngfactory.js +7 -0
- package/esm2015/controls/datetime/time.js +41 -0
- package/esm2015/controls/datetime/time.ngfactory.js +7 -0
- package/esm2015/controls/dialog/dialog.js +51 -0
- package/esm2015/controls/dialog/dialog.module.js +15 -0
- package/esm2015/controls/dialog/dialog.module.ngfactory.js +7 -0
- package/esm2015/controls/dialog/dialog.ngfactory.js +7 -0
- package/esm2015/controls/form/form.js +49 -0
- package/esm2015/controls/form/form.module.js +15 -0
- package/esm2015/controls/form/form.module.ngfactory.js +7 -0
- package/esm2015/controls/form/form.ngfactory.js +7 -0
- package/esm2015/controls/form/inheritform.directive.js +71 -0
- package/esm2015/controls/form/inheritform.directive.ngfactory.js +7 -0
- package/esm2015/controls/grid/grid.js +24 -0
- package/esm2015/controls/grid/grid.module.js +20 -0
- package/esm2015/controls/grid/grid.module.ngfactory.js +7 -0
- package/esm2015/controls/grid/grid.ngfactory.js +7 -0
- package/esm2015/controls/grid/gridbutton.js +47 -0
- package/esm2015/controls/grid/gridbutton.ngfactory.js +7 -0
- package/esm2015/controls/grid/gridcolumn.js +26 -0
- package/esm2015/controls/grid/gridcolumn.ngfactory.js +7 -0
- package/esm2015/controls/grid/gridcolumnaction.js +27 -0
- package/esm2015/controls/grid/gridcolumnaction.ngfactory.js +7 -0
- package/esm2015/controls/grid/gridimage.js +21 -0
- package/esm2015/controls/grid/gridimage.ngfactory.js +7 -0
- package/esm2015/controls/grid/paging.js +24 -0
- package/esm2015/controls/grid/paging.ngfactory.js +7 -0
- package/esm2015/controls/input/input.js +35 -0
- package/esm2015/controls/input/input.module.js +47 -0
- package/esm2015/controls/input/input.module.ngfactory.js +7 -0
- package/esm2015/controls/input/input.ngfactory.js +7 -0
- package/esm2015/controls/input/inputarea.js +51 -0
- package/esm2015/controls/input/inputarea.ngfactory.js +7 -0
- package/esm2015/controls/input/inputcurrency.js +39 -0
- package/esm2015/controls/input/inputcurrency.ngfactory.js +7 -0
- package/esm2015/controls/input/inputdecimal.js +39 -0
- package/esm2015/controls/input/inputdecimal.ngfactory.js +7 -0
- package/esm2015/controls/input/inputemail.js +39 -0
- package/esm2015/controls/input/inputemail.ngfactory.js +7 -0
- package/esm2015/controls/input/inputinteger.js +39 -0
- package/esm2015/controls/input/inputinteger.ngfactory.js +7 -0
- package/esm2015/controls/input/inputpassword.js +39 -0
- package/esm2015/controls/input/inputpassword.ngfactory.js +7 -0
- package/esm2015/controls/input/inputsearch.js +39 -0
- package/esm2015/controls/input/inputsearch.ngfactory.js +7 -0
- package/esm2015/controls/layout/formlayout.directive.js +10 -0
- package/esm2015/controls/layout/formlayout.directive.ngfactory.js +7 -0
- package/esm2015/controls/layout/layout.module.js +29 -0
- package/esm2015/controls/layout/layout.module.ngfactory.js +7 -0
- package/esm2015/controls/layout/tocontrolheight.pipe.js +29 -0
- package/esm2015/controls/layout/tocontrolheight.pipe.ngfactory.js +7 -0
- package/esm2015/controls/layout/tocontrolwidthcss.pipe.js +47 -0
- package/esm2015/controls/layout/tocontrolwidthcss.pipe.ngfactory.js +7 -0
- package/esm2015/controls/layout/tolabelheight.pipe.js +29 -0
- package/esm2015/controls/layout/tolabelheight.pipe.ngfactory.js +7 -0
- package/esm2015/controls/layout/tolabelwidthcss.pipe.js +31 -0
- package/esm2015/controls/layout/tolabelwidthcss.pipe.ngfactory.js +7 -0
- package/esm2015/controls/list/dropdown.js +65 -0
- package/esm2015/controls/list/dropdown.ngfactory.js +7 -0
- package/esm2015/controls/list/list.module.js +30 -0
- package/esm2015/controls/list/list.module.ngfactory.js +7 -0
- package/esm2015/controls/list/listbox.js +41 -0
- package/esm2015/controls/list/listbox.ngfactory.js +7 -0
- package/esm2015/controls/static/formcontainer.js +53 -0
- package/esm2015/controls/static/formcontainer.ngfactory.js +7 -0
- package/esm2015/controls/static/staticlabel.js +39 -0
- package/esm2015/controls/static/staticlabel.module.js +20 -0
- package/esm2015/controls/static/staticlabel.module.ngfactory.js +7 -0
- package/esm2015/controls/static/staticlabel.ngfactory.js +7 -0
- package/esm2015/controls/tabs/tab.js +18 -0
- package/esm2015/controls/tabs/tab.ngfactory.js +7 -0
- package/esm2015/controls/tabs/tabitem.js +11 -0
- package/esm2015/controls/tabs/tabitem.ngfactory.js +7 -0
- package/esm2015/controls/tabs/tabs.module.js +16 -0
- package/esm2015/controls/tabs/tabs.module.ngfactory.js +7 -0
- package/esm2015/controls/tinymce/tinymce.js +50 -0
- package/esm2015/controls/tinymce/tinymce.module.js +25 -0
- package/esm2015/controls/tinymce/tinymce.module.ngfactory.js +7 -0
- package/esm2015/controls/tinymce/tinymce.ngfactory.js +7 -0
- package/esm2015/controls/tooltip/tooltip.js +42 -0
- package/esm2015/controls/tooltip/tooltip.module.js +15 -0
- package/esm2015/controls/tooltip/tooltip.module.ngfactory.js +7 -0
- package/esm2015/controls/tooltip/tooltip.ngfactory.js +7 -0
- package/esm2015/controls/treeview/ngtreeitemaction.js +17 -0
- package/esm2015/controls/treeview/ngtreeitemaction.ngfactory.js +7 -0
- package/esm2015/controls/treeview/treeview.js +11 -0
- package/esm2015/controls/treeview/treeview.module.js +17 -0
- package/esm2015/controls/treeview/treeview.module.ngfactory.js +7 -0
- package/esm2015/controls/treeview/treeview.ngfactory.js +7 -0
- package/esm2015/controls/treeview/treeviewchild.js +11 -0
- package/esm2015/controls/treeview/treeviewchild.ngfactory.js +7 -0
- package/esm2015/controls/upload/upload.js +44 -0
- package/esm2015/controls/upload/upload.module.js +16 -0
- package/esm2015/controls/upload/upload.module.ngfactory.js +7 -0
- package/esm2015/controls/upload/upload.ngfactory.js +7 -0
- package/esm2015/controls/upload/upload.scss.ngstyle.js +7 -0
- package/esm2015/controls/upload/upload.scss.shim.ngstyle.js +7 -0
- package/esm2015/controls/upload/uploadmultiple.js +44 -0
- package/esm2015/controls/upload/uploadmultiple.ngfactory.js +7 -0
- package/esm2015/controls/validation/validationsummary.js +34 -0
- package/esm2015/controls/validation/validationsummary.module.js +15 -0
- package/esm2015/controls/validation/validationsummary.module.ngfactory.js +7 -0
- package/esm2015/controls/validation/validationsummary.ngfactory.js +7 -0
- package/esm2015/controls/wizard/wizard.js +23 -0
- package/esm2015/controls/wizard/wizard.module.js +16 -0
- package/esm2015/controls/wizard/wizard.module.ngfactory.js +7 -0
- package/esm2015/controls/wizard/wizard.ngfactory.js +7 -0
- package/esm2015/controls/wizard/wizarditem.js +11 -0
- package/esm2015/controls/wizard/wizarditem.ngfactory.js +7 -0
- package/esm2015/public_api.js +72 -0
- package/esm2015/public_api.ngfactory.js +7 -0
- package/esm2015/simpleangularcontrols-sac-bootstrap3.js +5 -0
- package/esm2015/simpleangularcontrols-sac-bootstrap3.ngfactory.js +7 -0
- package/fesm2015/simpleangularcontrols-sac-bootstrap3.js +1832 -0
- package/fesm2015/simpleangularcontrols-sac-bootstrap3.js.map +1 -0
- package/package.json +32 -0
- package/public_api.d.ts +66 -0
- package/public_api.ngfactory.d.ts +1 -0
- package/simpleangularcontrols-sac-bootstrap3-10.0.0-rc.1.tgz +0 -0
- package/simpleangularcontrols-sac-bootstrap3.d.ts +4 -0
- package/simpleangularcontrols-sac-bootstrap3.metadata.json +1 -0
- package/simpleangularcontrols-sac-bootstrap3.ngfactory.d.ts +1 -0
|
@@ -0,0 +1,1832 @@
|
|
|
1
|
+
import { Component, NgModule, Directive, Pipe, forwardRef, Host, Optional, Injector, ElementRef, ChangeDetectorRef, Input, Injectable, ComponentFactoryResolver, Inject, ApplicationRef, ContentChild, TemplateRef, Renderer2, ContentChildren, NgZone, HostBinding, SkipSelf } from '@angular/core';
|
|
2
|
+
import { SacButtonCommon, SacFormLayoutCommon, ControlHeight, SacCheckboxCommon, SacRadiobuttonsCommon, SacRadiobuttonCommon, SacDialogCommon, SacConfirmCommon, ServiceConfirmCommon, isDefined, SacConfirmButton, SacDateCommon, SacDateSelectorCommon, SacDateTimeCommon, SacTimeCommon, SacGridCommon, SacGridColumnCommon, SacGridColumnBaseCommon, SacGridButtonCommon, SacPagingCommon, SacGridColumnActionCommon, SacGridImageCommon, SacTooltipCommon, SacInputCommon, SacInputAreaCommon, SacInputCurrencyCommon, SacInputDecimalCommon, SacInputEmailCommon, SacInputIntegerCommon, SacInputPasswordCommon, SacInputSearchCommon, SacDropdownCommon, SacDropdownOptionCommon, SacListboxCommon, SACCommonListboxOptionModule, SacStaticFormContainerCommon, SacStaticLabelCommon, SacTabItemCommon, SacTabCommon, SacTinyMceCommon, SacTreeViewCommon, SacTreeViewChildCommon, SacTreeItemActionCommon, SacUploadSingleCommon, SacUploadMultipleCommon, SacFormCommon, SacValidationSummaryCommon, SacWizardItemCommon, SacWizardCommon } from '@simpleangularcontrols/sac-common';
|
|
3
|
+
import { CommonModule } from '@angular/common';
|
|
4
|
+
import { NG_VALUE_ACCESSOR, NG_VALIDATORS, FormsModule, NgForm, ControlContainer } from '@angular/forms';
|
|
5
|
+
import { forkJoin } from 'rxjs';
|
|
6
|
+
import { take } from 'rxjs/operators';
|
|
7
|
+
import { IMaskModule } from 'angular-imask';
|
|
8
|
+
import moment_ from 'moment';
|
|
9
|
+
import { EditorModule } from '@tinymce/tinymce-angular';
|
|
10
|
+
|
|
11
|
+
class SacButtonComponent extends SacButtonCommon {
|
|
12
|
+
}
|
|
13
|
+
SacButtonComponent.decorators = [
|
|
14
|
+
{ type: Component, args: [{
|
|
15
|
+
selector: 'sac-button',
|
|
16
|
+
template: "<a\r\n [id]=\"name\"\r\n class=\"btn\"\r\n [class.btn-primary]=\"role === 'primary'\"\r\n [class.btn-secondary]=\"role === 'secondary'\"\r\n [class.btn-success]=\"role === 'success'\"\r\n [class.btn-danger]=\"role === 'danger'\"\r\n [class.btn-warning]=\"role === 'warning'\"\r\n [class.btn-info]=\"role === 'info'\"\r\n [class.btn-default]=\"role === 'default'\"\r\n [class.btn-link]=\"role === 'link'\"\r\n [attr.disabled]=\"_isdisabled ? 'disabled' : null\"\r\n (click)=\"buttonClick()\"\r\n>\r\n <i\r\n *ngIf=\"icon !== ''\"\r\n [ngClass]=\"icon\"\r\n [ngStyle]=\"{ 'margin-right': text ? '0.5rem': null}\"\r\n ></i>\r\n {{text}}\r\n</a>\r\n"
|
|
17
|
+
},] }
|
|
18
|
+
];
|
|
19
|
+
|
|
20
|
+
class SACBootstrap3ButtonModule {
|
|
21
|
+
}
|
|
22
|
+
SACBootstrap3ButtonModule.decorators = [
|
|
23
|
+
{ type: NgModule, args: [{
|
|
24
|
+
declarations: [SacButtonComponent],
|
|
25
|
+
imports: [
|
|
26
|
+
CommonModule
|
|
27
|
+
],
|
|
28
|
+
exports: [SacButtonComponent]
|
|
29
|
+
},] }
|
|
30
|
+
];
|
|
31
|
+
|
|
32
|
+
class SacFormLayoutDirective extends SacFormLayoutCommon {
|
|
33
|
+
}
|
|
34
|
+
SacFormLayoutDirective.decorators = [
|
|
35
|
+
{ type: Directive, args: [{
|
|
36
|
+
selector: '[sacFormLayout]',
|
|
37
|
+
},] }
|
|
38
|
+
];
|
|
39
|
+
|
|
40
|
+
class SacToControlHeightPipe {
|
|
41
|
+
// #region Public Methods
|
|
42
|
+
/**
|
|
43
|
+
* Returns the CSS class that defines the height for the control
|
|
44
|
+
* @param value ControlHeight value or null
|
|
45
|
+
*/
|
|
46
|
+
transform(value) {
|
|
47
|
+
// Return default value
|
|
48
|
+
if (!value) {
|
|
49
|
+
return '';
|
|
50
|
+
}
|
|
51
|
+
switch (value) {
|
|
52
|
+
case ControlHeight.Small:
|
|
53
|
+
return 'input-sm';
|
|
54
|
+
case ControlHeight.Large:
|
|
55
|
+
return 'input-lg';
|
|
56
|
+
default:
|
|
57
|
+
return '';
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
SacToControlHeightPipe.decorators = [
|
|
62
|
+
{ type: Pipe, args: [{
|
|
63
|
+
name: 'toControlHeight',
|
|
64
|
+
},] }
|
|
65
|
+
];
|
|
66
|
+
|
|
67
|
+
class SacToControlWidthCssPipe {
|
|
68
|
+
// #region Public Methods
|
|
69
|
+
/**
|
|
70
|
+
* Get CSS classes from label width configuration to set control size
|
|
71
|
+
* @param value Configuration with grid columns for different viewports
|
|
72
|
+
* @returns string with css classe for bootstrap3
|
|
73
|
+
*/
|
|
74
|
+
transform(value) {
|
|
75
|
+
const classes = [];
|
|
76
|
+
if (value.labelSizeXs) {
|
|
77
|
+
classes.push('col-xs-' + this.calcControlSize(value.labelSizeXs));
|
|
78
|
+
}
|
|
79
|
+
if (value.labelSizeSm) {
|
|
80
|
+
classes.push('col-sm-' + this.calcControlSize(value.labelSizeSm));
|
|
81
|
+
}
|
|
82
|
+
if (value.labelSizeMd) {
|
|
83
|
+
classes.push('col-md-' + this.calcControlSize(value.labelSizeMd));
|
|
84
|
+
}
|
|
85
|
+
if (value.labelSizeLg) {
|
|
86
|
+
classes.push('col-lg-' + this.calcControlSize(value.labelSizeLg));
|
|
87
|
+
}
|
|
88
|
+
return classes.join(' ');
|
|
89
|
+
}
|
|
90
|
+
// #endregion Public Methods
|
|
91
|
+
// #region Private Methods
|
|
92
|
+
/**
|
|
93
|
+
* calculate the control size
|
|
94
|
+
* @param labelsize grid size of label
|
|
95
|
+
* @returns grid size for control. should be between 1 and 12
|
|
96
|
+
*/
|
|
97
|
+
calcControlSize(labelsize) {
|
|
98
|
+
if (labelsize === 12) {
|
|
99
|
+
return 12;
|
|
100
|
+
}
|
|
101
|
+
if (!labelsize) {
|
|
102
|
+
return 12;
|
|
103
|
+
}
|
|
104
|
+
return 12 - labelsize;
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
SacToControlWidthCssPipe.decorators = [
|
|
108
|
+
{ type: Pipe, args: [{
|
|
109
|
+
name: 'toControlWidthCss',
|
|
110
|
+
},] }
|
|
111
|
+
];
|
|
112
|
+
|
|
113
|
+
class SacToLabelHeightPipe {
|
|
114
|
+
// #region Public Methods
|
|
115
|
+
/**
|
|
116
|
+
* Returns the CSS class that defines the height for the control
|
|
117
|
+
* @param value ControlHeight value or null
|
|
118
|
+
*/
|
|
119
|
+
transform(value) {
|
|
120
|
+
// Return default value
|
|
121
|
+
if (!value) {
|
|
122
|
+
return '';
|
|
123
|
+
}
|
|
124
|
+
switch (value) {
|
|
125
|
+
case ControlHeight.Small:
|
|
126
|
+
return 'form-group-sm';
|
|
127
|
+
case ControlHeight.Large:
|
|
128
|
+
return 'form-group-lg';
|
|
129
|
+
default:
|
|
130
|
+
return '';
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
SacToLabelHeightPipe.decorators = [
|
|
135
|
+
{ type: Pipe, args: [{
|
|
136
|
+
name: 'toLabelHeight',
|
|
137
|
+
},] }
|
|
138
|
+
];
|
|
139
|
+
|
|
140
|
+
class SacToLabelWidthCssPipe {
|
|
141
|
+
// #region Public Methods
|
|
142
|
+
/**
|
|
143
|
+
* Get CSS classes from label width configuration to set label size
|
|
144
|
+
* @param value Configuration with grid columns for different viewports
|
|
145
|
+
* @returns string with css classe for bootstrap3
|
|
146
|
+
*/
|
|
147
|
+
transform(value) {
|
|
148
|
+
const classes = [];
|
|
149
|
+
if (value.labelSizeXs) {
|
|
150
|
+
classes.push('col-xs-' + value.labelSizeXs);
|
|
151
|
+
}
|
|
152
|
+
if (value.labelSizeSm) {
|
|
153
|
+
classes.push('col-sm-' + value.labelSizeSm);
|
|
154
|
+
}
|
|
155
|
+
if (value.labelSizeMd) {
|
|
156
|
+
classes.push('col-md-' + value.labelSizeMd);
|
|
157
|
+
}
|
|
158
|
+
if (value.labelSizeLg) {
|
|
159
|
+
classes.push('col-lg-' + value.labelSizeLg);
|
|
160
|
+
}
|
|
161
|
+
return classes.join(' ');
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
SacToLabelWidthCssPipe.decorators = [
|
|
165
|
+
{ type: Pipe, args: [{
|
|
166
|
+
name: 'toLabelWidthCss',
|
|
167
|
+
},] }
|
|
168
|
+
];
|
|
169
|
+
|
|
170
|
+
class SACBootstrap3LayoutModule {
|
|
171
|
+
}
|
|
172
|
+
SACBootstrap3LayoutModule.decorators = [
|
|
173
|
+
{ type: NgModule, args: [{
|
|
174
|
+
declarations: [
|
|
175
|
+
SacFormLayoutDirective,
|
|
176
|
+
SacToControlHeightPipe,
|
|
177
|
+
SacToControlWidthCssPipe,
|
|
178
|
+
SacToLabelHeightPipe,
|
|
179
|
+
SacToLabelWidthCssPipe,
|
|
180
|
+
],
|
|
181
|
+
imports: [CommonModule],
|
|
182
|
+
exports: [
|
|
183
|
+
SacFormLayoutDirective,
|
|
184
|
+
SacToControlHeightPipe,
|
|
185
|
+
SacToControlWidthCssPipe,
|
|
186
|
+
SacToLabelHeightPipe,
|
|
187
|
+
SacToLabelWidthCssPipe,
|
|
188
|
+
],
|
|
189
|
+
},] }
|
|
190
|
+
];
|
|
191
|
+
|
|
192
|
+
class SacCheckboxComponent extends SacCheckboxCommon {
|
|
193
|
+
// #region Constructors
|
|
194
|
+
/**
|
|
195
|
+
* Constructor
|
|
196
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
197
|
+
* @param injector Injector for injecting services
|
|
198
|
+
*/
|
|
199
|
+
constructor(formLayout, injector) {
|
|
200
|
+
super(formLayout, injector);
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
SacCheckboxComponent.decorators = [
|
|
204
|
+
{ type: Component, args: [{
|
|
205
|
+
selector: 'sac-checkbox',
|
|
206
|
+
template: "<div\r\n class=\"row\"\r\n [class.form-group]=\"!stacked\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"!disablelabel && !stacked\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[!disablelabel && !stacked ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[!disablelabel && !stacked ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <div\r\n class=\"checkbox\"\r\n [class.checkbox-sm]=\"componentHeight === ControlHeight.Small\"\r\n [class.checkbox-lg]=\"componentHeight === ControlHeight.Large\"\r\n >\r\n <label>\r\n <input\r\n id=\"{{name}}\"\r\n name=\"{{name}}\"\r\n type=\"checkbox\"\r\n class=\"visible-checkbox\"\r\n [checked]=\"value\"\r\n [disabled]=\"isdisabled\"\r\n (blur)=\"onTouch()\"\r\n (change)=\"setValue($event.target.checked)\"\r\n />\r\n <ng-container *ngIf=\"checkboxtext\"\r\n > <span>{{checkboxtext}}</span></ng-container\r\n >\r\n </label>\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
207
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
208
|
+
providers: [
|
|
209
|
+
{
|
|
210
|
+
provide: NG_VALUE_ACCESSOR,
|
|
211
|
+
multi: true,
|
|
212
|
+
useExisting: SacCheckboxComponent,
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
provide: NG_VALIDATORS,
|
|
216
|
+
useExisting: forwardRef(() => SacCheckboxComponent),
|
|
217
|
+
multi: true,
|
|
218
|
+
},
|
|
219
|
+
],
|
|
220
|
+
styles: [".checkbox-sm{padding-top:2px}.checkbox-sm input{height:12px;margin-top:2px;width:12px}.checkbox-sm label{font-size:12px;padding-top:2px}.checkbox-lg input{height:20px;margin-top:2px;width:20px}.checkbox-lg label{font-size:18px;padding-top:4px}"]
|
|
221
|
+
},] }
|
|
222
|
+
];
|
|
223
|
+
SacCheckboxComponent.ctorParameters = () => [
|
|
224
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
225
|
+
{ type: Injector }
|
|
226
|
+
];
|
|
227
|
+
|
|
228
|
+
class SacRadiobuttonsComponent extends SacRadiobuttonsCommon {
|
|
229
|
+
// #region Constructors
|
|
230
|
+
/**
|
|
231
|
+
* Constructor
|
|
232
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
233
|
+
* @param injector Injector for injecting services
|
|
234
|
+
*/
|
|
235
|
+
constructor(formLayout, injector) {
|
|
236
|
+
super(formLayout, injector);
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
SacRadiobuttonsComponent.decorators = [
|
|
240
|
+
{ type: Component, args: [{
|
|
241
|
+
selector: 'sac-radiobuttons',
|
|
242
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <div>\r\n <ng-content></ng-content>\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
243
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
244
|
+
providers: [
|
|
245
|
+
{
|
|
246
|
+
provide: NG_VALUE_ACCESSOR,
|
|
247
|
+
useExisting: forwardRef(() => SacRadiobuttonsComponent),
|
|
248
|
+
multi: true,
|
|
249
|
+
},
|
|
250
|
+
{
|
|
251
|
+
provide: NG_VALIDATORS,
|
|
252
|
+
useExisting: forwardRef(() => SacRadiobuttonsComponent),
|
|
253
|
+
multi: true,
|
|
254
|
+
},
|
|
255
|
+
]
|
|
256
|
+
},] }
|
|
257
|
+
];
|
|
258
|
+
SacRadiobuttonsComponent.ctorParameters = () => [
|
|
259
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
260
|
+
{ type: Injector }
|
|
261
|
+
];
|
|
262
|
+
|
|
263
|
+
class SacRadiobuttonComponent extends SacRadiobuttonCommon {
|
|
264
|
+
constructor(sacRadioButtons) {
|
|
265
|
+
super(sacRadioButtons);
|
|
266
|
+
}
|
|
267
|
+
}
|
|
268
|
+
SacRadiobuttonComponent.decorators = [
|
|
269
|
+
{ type: Component, args: [{
|
|
270
|
+
selector: 'sac-radiobutton',
|
|
271
|
+
template: "<div\r\n class=\"radio\"\r\n *ngIf=\"hidden===false\"\r\n [class.radio-sm]=\"componentHeight === ControlHeight.Small\"\r\n [class.radio-lg]=\"componentHeight === ControlHeight.Large\"\r\n>\r\n <label for=\"{{getName}}_{{getIndex}}\">\r\n <input\r\n id=\"{{getName}}_{{getIndex}}\"\r\n name=\"{{getName}}\"\r\n type=\"radio\"\r\n [value]=\"value\"\r\n [checked]=\"checked\"\r\n (change)=\"ChangeEvent()\"\r\n [disabled]=\"isDisabled\"\r\n />\r\n <ng-template\r\n *ngTemplateOutlet=\"labeltemplate || defaultItemLabelTemplate;context:{ label: label }\"\r\n >\r\n </ng-template>\r\n </label>\r\n</div>\r\n\r\n<ng-template #defaultItemLabelTemplate let-label=\"label\"\r\n > <span>{{label}}</span></ng-template\r\n>\r\n",
|
|
272
|
+
styles: [".radio-lg label{font-size:18px;padding-top:2px}.radio-lg label input{height:20px;margin-top:2px;width:20px}.radio-sm{padding-top:2px}.radio-sm label{font-size:12px;min-height:14px;padding-top:2px}.radio-sm label input{height:12px;margin-top:2px;width:12px}"]
|
|
273
|
+
},] }
|
|
274
|
+
];
|
|
275
|
+
SacRadiobuttonComponent.ctorParameters = () => [
|
|
276
|
+
{ type: SacRadiobuttonsComponent, decorators: [{ type: Host }] }
|
|
277
|
+
];
|
|
278
|
+
|
|
279
|
+
class SACBootstrap3CheckboxModule {
|
|
280
|
+
}
|
|
281
|
+
SACBootstrap3CheckboxModule.decorators = [
|
|
282
|
+
{ type: NgModule, args: [{
|
|
283
|
+
declarations: [
|
|
284
|
+
SacCheckboxComponent,
|
|
285
|
+
SacRadiobuttonComponent,
|
|
286
|
+
SacRadiobuttonsComponent,
|
|
287
|
+
],
|
|
288
|
+
imports: [CommonModule, SACBootstrap3LayoutModule],
|
|
289
|
+
exports: [
|
|
290
|
+
SacCheckboxComponent,
|
|
291
|
+
SacRadiobuttonComponent,
|
|
292
|
+
SacRadiobuttonsComponent,
|
|
293
|
+
],
|
|
294
|
+
},] }
|
|
295
|
+
];
|
|
296
|
+
|
|
297
|
+
class SacDialogComponent extends SacDialogCommon {
|
|
298
|
+
constructor(el, cdRef) {
|
|
299
|
+
super(cdRef);
|
|
300
|
+
//#region Bootstrap 3 Spezifische Properites
|
|
301
|
+
this.zindex = 20002;
|
|
302
|
+
this._lastDialogMarginTop = 0;
|
|
303
|
+
this.element = el.nativeElement;
|
|
304
|
+
}
|
|
305
|
+
// Margin Top für Center Position des Dialogs berechnen
|
|
306
|
+
get dialogMarginTop() {
|
|
307
|
+
let result = 0;
|
|
308
|
+
// ContentPlaceholder kann NULL/UNDEFINED sein wenn Dialog nicht angezeigt wird
|
|
309
|
+
if (this.dialogElement !== null && this.dialogElement !== undefined) {
|
|
310
|
+
result = (this.dialogElement.nativeElement.clientHeight / 2) * -1;
|
|
311
|
+
}
|
|
312
|
+
// Change Detection ausführen, falls Wert nach Rendering noch geändert hat. Kann durch HTML Content / Zeilenumbrüche usw. ausgelöst werden.
|
|
313
|
+
if (this._lastDialogMarginTop !== result) {
|
|
314
|
+
this._lastDialogMarginTop = result;
|
|
315
|
+
this.ChangeDetector.detectChanges();
|
|
316
|
+
}
|
|
317
|
+
return result;
|
|
318
|
+
}
|
|
319
|
+
//#endregion
|
|
320
|
+
ngOnInit() {
|
|
321
|
+
// Element an Body für korrektes Styling unter Bootstrap 3 verschieben
|
|
322
|
+
document.body.appendChild(this.element);
|
|
323
|
+
}
|
|
324
|
+
ngOnDestroy() {
|
|
325
|
+
this.hide();
|
|
326
|
+
if (document.body.contains(this.element)) {
|
|
327
|
+
document.body.removeChild(this.element);
|
|
328
|
+
}
|
|
329
|
+
super.ngOnDestroy();
|
|
330
|
+
}
|
|
331
|
+
}
|
|
332
|
+
SacDialogComponent.decorators = [
|
|
333
|
+
{ type: Component, args: [{
|
|
334
|
+
selector: 'sac-dialog',
|
|
335
|
+
template: "<div [id]=\"name\" *ngIf=\"_show\" [ngStyle]=\"{'z-index': zindex}\">\r\n <div class=\"modal in\" style=\"display: block;\" tabindex=\"-1\" role=\"dialog\" #dialog>\r\n <div class=\"modal-dialog\" role=\"document\" [style.width]=\"width\">\r\n <div class=\"modal-content\">\r\n <div class=\"modal-header\">\r\n <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\" (click)=\"hide()\" *ngIf=\"closebutton\"><span aria-hidden=\"true\">×</span></button>\r\n <span class=\"modal-title\">{{title}}</span>\r\n </div>\r\n <div class=\"modal-body\">\r\n <ng-content select=\"[dialogbody]\"></ng-content>\r\n </div>\r\n <div class=\"modal-footer\">\r\n <ng-content select=\"[dialogfooter]\"></ng-content>\r\n </div>\r\n </div><!-- /.modal-content -->\r\n </div><!-- /.modal-dialog -->\r\n </div><!-- /.modal -->\r\n</div>\r\n<div class=\"modal-backdrop in\" *ngIf=\"_show && backdrop\" #backdrop></div>\r\n"
|
|
336
|
+
},] }
|
|
337
|
+
];
|
|
338
|
+
SacDialogComponent.ctorParameters = () => [
|
|
339
|
+
{ type: ElementRef },
|
|
340
|
+
{ type: ChangeDetectorRef }
|
|
341
|
+
];
|
|
342
|
+
SacDialogComponent.propDecorators = {
|
|
343
|
+
zindex: [{ type: Input }]
|
|
344
|
+
};
|
|
345
|
+
|
|
346
|
+
class SACBootstrap3DialogModule {
|
|
347
|
+
}
|
|
348
|
+
SACBootstrap3DialogModule.decorators = [
|
|
349
|
+
{ type: NgModule, args: [{
|
|
350
|
+
declarations: [SacDialogComponent],
|
|
351
|
+
imports: [
|
|
352
|
+
CommonModule
|
|
353
|
+
],
|
|
354
|
+
exports: [SacDialogComponent]
|
|
355
|
+
},] }
|
|
356
|
+
];
|
|
357
|
+
|
|
358
|
+
class SacConfirmComponent extends SacConfirmCommon {
|
|
359
|
+
}
|
|
360
|
+
SacConfirmComponent.decorators = [
|
|
361
|
+
{ type: Component, args: [{
|
|
362
|
+
selector: 'sac-confirm',
|
|
363
|
+
template: "<sac-dialog\r\n [(isvisible)]=\"isvisible\"\r\n [title]=\"title\"\r\n [allowesc]=\"false\"\r\n [closebutton]=\"false\"\r\n>\r\n <div dialogbody>\r\n <div class=\"media\">\r\n <div class=\"media-left media-middle\" *ngIf=\"hasImage()\">\r\n <img [attr.src]=\"image\" />\r\n </div>\r\n <div class=\"media-body\">{{message}}</div>\r\n </div>\r\n </div>\r\n <div dialogfooter>\r\n <ng-container *ngFor=\"let button of buttons\">\r\n <sac-button\r\n [name]=\"button.key\"\r\n [text]=\"button.text\"\r\n [role]=\"button.role || 'default'\"\r\n (clicked)=\"confirm(button.key)\"\r\n style=\"margin-left: 15px\"\r\n ></sac-button>\r\n </ng-container>\r\n </div>\r\n</sac-dialog>\r\n"
|
|
364
|
+
},] }
|
|
365
|
+
];
|
|
366
|
+
|
|
367
|
+
/**
|
|
368
|
+
* Service für Confirm Messages in TypeScript Code
|
|
369
|
+
*
|
|
370
|
+
* @example
|
|
371
|
+
* // Beispiel für ConfirmMessage mit Standard Buttons (Ja / Nein).
|
|
372
|
+
* confirmService.ConfirmMessage('titel', 'frage').subscribe(action => { // Action Code });
|
|
373
|
+
*
|
|
374
|
+
* @example
|
|
375
|
+
* // Beispiel für ConfirmMessage mit eigenen Buttons
|
|
376
|
+
* let buttons: SacConfirmButton[] = [];
|
|
377
|
+
* buttons.push(new SacConfirmButton('ActionKey','Text Primary'));
|
|
378
|
+
* buttons.push(new SacConfirmButton('ActionKey2','Text Button 2'));
|
|
379
|
+
* confirmService.ConfirmMessage('titel', 'frage', buttons).subscribe(action => { // Action Code });
|
|
380
|
+
*/
|
|
381
|
+
class ServiceConfirm extends ServiceConfirmCommon {
|
|
382
|
+
// #endregion Properties
|
|
383
|
+
// #region Constructors
|
|
384
|
+
/**
|
|
385
|
+
* Konstruktor
|
|
386
|
+
* @param componentFactoryResolver Component Factory Resolver Instanz
|
|
387
|
+
* @param appRef Application Referenz. Wird benötigt um den Dialog am Body anzuhängen
|
|
388
|
+
* @param injector Injector. Wird benötigt um den Dialog dynamisch zu erzeugen
|
|
389
|
+
*/
|
|
390
|
+
constructor(componentFactoryResolver, appRef, injector) {
|
|
391
|
+
super(appRef, injector);
|
|
392
|
+
this.componentFactoryResolver = componentFactoryResolver;
|
|
393
|
+
// #region Properties
|
|
394
|
+
/**
|
|
395
|
+
* Collection von Buttons die angezeigt werden müssen.
|
|
396
|
+
*/
|
|
397
|
+
this.buttons = [];
|
|
398
|
+
/**
|
|
399
|
+
* Message die in Dialog angezeigt werden soll.
|
|
400
|
+
*/
|
|
401
|
+
this.message = '';
|
|
402
|
+
/**
|
|
403
|
+
* Titel der im Dialog angezeigt werden soll.
|
|
404
|
+
*/
|
|
405
|
+
this.title = '';
|
|
406
|
+
}
|
|
407
|
+
// #endregion Constructors
|
|
408
|
+
// #region Public Methods
|
|
409
|
+
/**
|
|
410
|
+
* Confirm Dialog anzeigen
|
|
411
|
+
* @param message Nachricht die angezeigt werden soll.
|
|
412
|
+
* @returns EventEmitter mit Key des Buttons, welcher geklickt wurde.
|
|
413
|
+
*/
|
|
414
|
+
ConfirmMessage(title, message, buttons = null) {
|
|
415
|
+
this.title = title;
|
|
416
|
+
this.message = message;
|
|
417
|
+
// Default Buttons setzen, wenn keine Buttons angegeben sind
|
|
418
|
+
if (!isDefined(buttons)) {
|
|
419
|
+
this.buttons = [];
|
|
420
|
+
forkJoin({
|
|
421
|
+
button_yes: this.localisationService.GetString(this.validationKeyService.ConfirmDefaultButtonYes),
|
|
422
|
+
button_no: this.localisationService.GetString(this.validationKeyService.ConfirmDefaultButtonNo),
|
|
423
|
+
})
|
|
424
|
+
.pipe(take(1))
|
|
425
|
+
.subscribe((texte) => {
|
|
426
|
+
this.buttons.push(new SacConfirmButton('yes', texte.button_yes, 'primary'));
|
|
427
|
+
this.buttons.push(new SacConfirmButton('no', texte.button_no));
|
|
428
|
+
});
|
|
429
|
+
}
|
|
430
|
+
else {
|
|
431
|
+
this.buttons = buttons;
|
|
432
|
+
}
|
|
433
|
+
return super.Confirm();
|
|
434
|
+
}
|
|
435
|
+
/**
|
|
436
|
+
* Erzeugen einer Component Factory für einen Dialog
|
|
437
|
+
*/
|
|
438
|
+
GetComponentFactory() {
|
|
439
|
+
return this.componentFactoryResolver.resolveComponentFactory(SacConfirmComponent);
|
|
440
|
+
}
|
|
441
|
+
// #endregion Public Methods
|
|
442
|
+
// #region Protected Methods
|
|
443
|
+
/**
|
|
444
|
+
* Konfiguration des Dialogs
|
|
445
|
+
* @param instance Instanz eines SacConfirm Dialogs
|
|
446
|
+
*/
|
|
447
|
+
ConfigureDialog(instance) {
|
|
448
|
+
// Text in Dialog setzen
|
|
449
|
+
instance.title = this.title;
|
|
450
|
+
instance.message = this.message;
|
|
451
|
+
instance.buttons = this.buttons;
|
|
452
|
+
instance.image = this.iconService.ConfirmDefaultImage;
|
|
453
|
+
}
|
|
454
|
+
}
|
|
455
|
+
ServiceConfirm.decorators = [
|
|
456
|
+
{ type: Injectable }
|
|
457
|
+
];
|
|
458
|
+
ServiceConfirm.ctorParameters = () => [
|
|
459
|
+
{ type: ComponentFactoryResolver, decorators: [{ type: Inject, args: [ComponentFactoryResolver,] }] },
|
|
460
|
+
{ type: ApplicationRef },
|
|
461
|
+
{ type: Injector }
|
|
462
|
+
];
|
|
463
|
+
|
|
464
|
+
/**
|
|
465
|
+
* Module für Confirm Messages
|
|
466
|
+
*
|
|
467
|
+
* In NgModule der Applikation folgenden Eintrag bei Imports einfügen: ExanicBootstrap3ConfirmModule.forRoot()
|
|
468
|
+
*
|
|
469
|
+
*/
|
|
470
|
+
class SACBootstrap3ConfirmModule {
|
|
471
|
+
// #region Public Static Methods
|
|
472
|
+
static forRoot() {
|
|
473
|
+
return {
|
|
474
|
+
ngModule: SACBootstrap3ConfirmModule,
|
|
475
|
+
providers: [ServiceConfirm],
|
|
476
|
+
};
|
|
477
|
+
}
|
|
478
|
+
}
|
|
479
|
+
SACBootstrap3ConfirmModule.decorators = [
|
|
480
|
+
{ type: NgModule, args: [{
|
|
481
|
+
declarations: [SacConfirmComponent],
|
|
482
|
+
imports: [CommonModule, SACBootstrap3DialogModule, SACBootstrap3ButtonModule],
|
|
483
|
+
exports: [SacConfirmComponent],
|
|
484
|
+
entryComponents: [SacConfirmComponent],
|
|
485
|
+
},] }
|
|
486
|
+
];
|
|
487
|
+
|
|
488
|
+
const moment = moment_;
|
|
489
|
+
class SacDateComponent extends SacDateCommon {
|
|
490
|
+
// #region Constructors
|
|
491
|
+
/**
|
|
492
|
+
* Constructor
|
|
493
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
494
|
+
* @param injector Injector for injecting services
|
|
495
|
+
* @param elementRef Reference to html dom element
|
|
496
|
+
*/
|
|
497
|
+
constructor(formLayout, injector, elementRef) {
|
|
498
|
+
super(formLayout, injector, elementRef);
|
|
499
|
+
}
|
|
500
|
+
}
|
|
501
|
+
SacDateComponent.decorators = [
|
|
502
|
+
{ type: Component, args: [{
|
|
503
|
+
selector: 'sac-date',
|
|
504
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <div\r\n style=\"position: relative\"\r\n [style.width.px]=\"componentHeight === ControlHeight.Small ? 120 : componentHeight === ControlHeight.Large ? 180 : 140\"\r\n >\r\n <div\r\n id=\"{{name}}\"\r\n class=\"datetime-textbox input-group\"\r\n [class.input-group-sm]=\"componentHeight === ControlHeight.Small\"\r\n [class.input-group-lg]=\"componentHeight === ControlHeight.Large\"\r\n >\r\n <!-- this class comes in the div above when disabled [ngClass]=\"[disablelabel === false ? 'col-md-' + _inputsize : 'col-md-12']\" -->\r\n <input\r\n name=\"{{name}}\"\r\n type=\"text\"\r\n class=\"form-control date-control\"\r\n [class.is-invalid]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"[componentHeight | toControlHeight]\"\r\n [imask]=\"imaskDate\"\r\n placeholder=\"dd.mm.yyyy\"\r\n [attr.placeholder]=\"placeholder\"\r\n [value]=\"valuestring\"\r\n maxlength=\"10\"\r\n size=\"10\"\r\n (blur)=\"onTouch()\"\r\n (accept)=\"setValueString($event)\"\r\n [disabled]=\"isdisabled\"\r\n (click)=\"showDateSelector()\"\r\n />\r\n <span class=\"input-group-btn\">\r\n <button\r\n class=\"btn btn-default\"\r\n type=\"button\"\r\n (click)=\"showDateSelector()\"\r\n [disabled]=\"isdisabled\"\r\n >\r\n <i [class]=\"IconSelector\"></i>\r\n </button>\r\n </span>\r\n </div>\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n\r\n <div\r\n class=\"popover bottom in\"\r\n role=\"tooltip\"\r\n *ngIf=\"_showselector\"\r\n style=\"\r\n display: block;\r\n left: unset;\r\n right: 0px;\r\n top: unset;\r\n max-width: 325px;\r\n \"\r\n >\r\n <div\r\n class=\"arrow\"\r\n style=\"left: unset\"\r\n [style.right.px]=\"componentHeight === ControlHeight.Small ? 4 : componentHeight === ControlHeight.Large ? 14 : 10\"\r\n ></div>\r\n <h3 class=\"popover-title\" style=\"display: none\"></h3>\r\n <div class=\"popover-content\">\r\n <sac-dateselector\r\n *ngIf=\"_showselector\"\r\n [initialvalue]=\"value\"\r\n (selectdate)=\"dateselect($event)\"\r\n dateselection=\"true\"\r\n ></sac-dateselector>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
505
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
506
|
+
providers: [
|
|
507
|
+
{
|
|
508
|
+
provide: NG_VALUE_ACCESSOR,
|
|
509
|
+
multi: true,
|
|
510
|
+
useExisting: forwardRef(() => SacDateComponent),
|
|
511
|
+
},
|
|
512
|
+
{
|
|
513
|
+
provide: NG_VALIDATORS,
|
|
514
|
+
multi: true,
|
|
515
|
+
useExisting: forwardRef(() => SacDateComponent),
|
|
516
|
+
},
|
|
517
|
+
]
|
|
518
|
+
},] }
|
|
519
|
+
];
|
|
520
|
+
SacDateComponent.ctorParameters = () => [
|
|
521
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
522
|
+
{ type: Injector },
|
|
523
|
+
{ type: ElementRef }
|
|
524
|
+
];
|
|
525
|
+
|
|
526
|
+
class SacDateSelectorComponent extends SacDateSelectorCommon {
|
|
527
|
+
}
|
|
528
|
+
SacDateSelectorComponent.decorators = [
|
|
529
|
+
{ type: Component, args: [{
|
|
530
|
+
selector: 'sac-dateselector',
|
|
531
|
+
template: "<div class=\"calendar-selector\" style=\"min-width: 265px\">\r\n <table class=\"table-condensed\" style=\"width: 100%\" *ngIf=\"dateselection\">\r\n <thead>\r\n <tr>\r\n <th class=\"prev text-left\" (click)=\"monthBack()\">\r\n <i [class]=\"iconMonthPrev\"></i>\r\n </th>\r\n <th colspan=\"5\" class=\"switch text-center\">{{month+1}}/{{year}}</th>\r\n <th class=\"next text-right\" (click)=\"monthNext()\">\r\n <i [class]=\"iconMonthNext\"></i>\r\n </th>\r\n </tr>\r\n <tr>\r\n <th class=\"dow text-center\">Mo</th>\r\n <th class=\"dow text-center\">Di</th>\r\n <th class=\"dow text-center\">Mi</th>\r\n <th class=\"dow text-center\">Do</th>\r\n <th class=\"dow text-center\">Fr</th>\r\n <th class=\"dow text-center\">Sa</th>\r\n <th class=\"dow text-center\">So</th>\r\n </tr>\r\n </thead>\r\n <tbody>\r\n <ng-container *ngFor=\"let week of dates; let i=index\">\r\n <tr>\r\n <td\r\n class=\"text-center\"\r\n *ngFor=\"let item of week\"\r\n [ngStyle]=\"{'cursor': item.isenabled ? 'pointer' : null}\"\r\n [ngClass]=\"{'day-current': item.iscurrent, 'day-selected': item.isselected, 'day-new': item.isnew, 'day-disabled': !item.isenabled}\"\r\n (click)=\"selectDate(item)\"\r\n >\r\n {{ item.displaytext }}\r\n </td>\r\n </tr>\r\n </ng-container>\r\n </tbody>\r\n </table>\r\n <div class=\"container-fluid\" *ngIf=\"timeselection\" style=\"margin-top: 10px\">\r\n <div class=\"row\">\r\n <div class=\"col-md-6\" style=\"padding-right: 20px\">\r\n <div class=\"form-group\">\r\n <label>Stunde</label>\r\n <input\r\n type=\"number\"\r\n class=\"form-control\"\r\n [value]=\"getHours()\"\r\n (input)=\"setHours($event.target.value)\"\r\n min=\"0\"\r\n max=\"23\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6\" style=\"padding-left: 20px\">\r\n <div class=\"form-group\">\r\n <label>Minute</label>\r\n <input\r\n type=\"number\"\r\n class=\"form-control\"\r\n [value]=\"getMinutes()\"\r\n (input)=\"setMinutes($event.target.value)\"\r\n min=\"0\"\r\n max=\"59\"\r\n />\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"row\" style=\"margin-top: 10px\">\r\n <div class=\"col-md-4 text-left\">\r\n <button type=\"button\" class=\"btn btn-default\" (click)=\"setToday()\">\r\n Heute\r\n </button>\r\n </div>\r\n <div class=\"col-md-8 text-right\">\r\n <button type=\"button\" class=\"btn btn-default\" (click)=\"resetSelection()\">\r\n Reset\r\n </button>\r\n <button\r\n type=\"button\"\r\n class=\"btn btn-primary\"\r\n style=\"margin-left: 10px\"\r\n (click)=\"applySelection()\"\r\n >\r\n Apply\r\n </button>\r\n </div>\r\n </div>\r\n</div>\r\n"
|
|
532
|
+
},] }
|
|
533
|
+
];
|
|
534
|
+
|
|
535
|
+
class SacDateTimeComponent extends SacDateTimeCommon {
|
|
536
|
+
// #region Constructors
|
|
537
|
+
/**
|
|
538
|
+
* Constructor
|
|
539
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
540
|
+
* @param injector Injector for injecting services
|
|
541
|
+
* @param elementRef Reference to html dom element
|
|
542
|
+
*/
|
|
543
|
+
constructor(formLayout, injector, elementRef) {
|
|
544
|
+
super(formLayout, injector, elementRef);
|
|
545
|
+
}
|
|
546
|
+
}
|
|
547
|
+
SacDateTimeComponent.decorators = [
|
|
548
|
+
{ type: Component, args: [{
|
|
549
|
+
selector: 'sac-datetime',
|
|
550
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <div\r\n style=\"position: relative\"\r\n [style.width.px]=\"componentHeight === ControlHeight.Small ? 160 : componentHeight === ControlHeight.Large ? 230 : 180\"\r\n >\r\n <div\r\n id=\"{{name}}\"\r\n class=\"datetime-textbox input-group\"\r\n [class.input-group-sm]=\"componentHeight === ControlHeight.Small\"\r\n [class.input-group-lg]=\"componentHeight === ControlHeight.Large\"\r\n >\r\n <input\r\n id=\"{{name}}\"\r\n name=\"{{name}}\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [class.is-invalid]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"[componentHeight | toControlHeight]\"\r\n [imask]=\"imaskDate\"\r\n [attr.placeholder]=\"placeholder\"\r\n [value]=\"valuestring\"\r\n (blur)=\"onTouch()\"\r\n (accept)=\"setValueString($event)\"\r\n [disabled]=\"isdisabled\"\r\n (click)=\"showDateSelector()\"\r\n />\r\n <span class=\"input-group-btn\">\r\n <button\r\n class=\"btn btn-default\"\r\n type=\"button\"\r\n (click)=\"showDateSelector()\"\r\n [disabled]=\"isdisabled\"\r\n >\r\n <i [class]=\"IconSelector\"></i>\r\n </button>\r\n </span>\r\n </div>\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n\r\n <div\r\n class=\"popover bottom in\"\r\n role=\"tooltip\"\r\n *ngIf=\"_showselector\"\r\n style=\"\r\n display: block;\r\n left: unset;\r\n right: 0px;\r\n top: 34px;\r\n max-width: 325px;\r\n \"\r\n >\r\n <div class=\"arrow\" style=\"left: unset; right: 10px\"></div>\r\n <h3 class=\"popover-title\" style=\"display: none\"></h3>\r\n <div class=\"popover-content\">\r\n <sac-dateselector\r\n *ngIf=\"_showselector\"\r\n [initialvalue]=\"value\"\r\n (selectdate)=\"dateselect($event)\"\r\n dateselection=\"true\"\r\n timeselection=\"true\"\r\n ></sac-dateselector>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
551
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
552
|
+
providers: [
|
|
553
|
+
{
|
|
554
|
+
provide: NG_VALUE_ACCESSOR,
|
|
555
|
+
multi: true,
|
|
556
|
+
useExisting: forwardRef(() => SacDateTimeComponent),
|
|
557
|
+
},
|
|
558
|
+
{
|
|
559
|
+
provide: NG_VALIDATORS,
|
|
560
|
+
multi: true,
|
|
561
|
+
useExisting: forwardRef(() => SacDateTimeComponent),
|
|
562
|
+
},
|
|
563
|
+
]
|
|
564
|
+
},] }
|
|
565
|
+
];
|
|
566
|
+
SacDateTimeComponent.ctorParameters = () => [
|
|
567
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
568
|
+
{ type: Injector },
|
|
569
|
+
{ type: ElementRef }
|
|
570
|
+
];
|
|
571
|
+
|
|
572
|
+
class SacTimeComponent extends SacTimeCommon {
|
|
573
|
+
// #region Constructors
|
|
574
|
+
/**
|
|
575
|
+
* Constructor
|
|
576
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
577
|
+
* @param injector Injector for injecting services
|
|
578
|
+
* @param elementRef Reference to html dom element
|
|
579
|
+
*/
|
|
580
|
+
constructor(formLayout, injector, elementRef) {
|
|
581
|
+
super(formLayout, injector, elementRef);
|
|
582
|
+
}
|
|
583
|
+
}
|
|
584
|
+
SacTimeComponent.decorators = [
|
|
585
|
+
{ type: Component, args: [{
|
|
586
|
+
selector: 'sac-time',
|
|
587
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <div\r\n style=\"position: relative\"\r\n [style.width.px]=\"componentHeight === ControlHeight.Small ? 120 : componentHeight === ControlHeight.Large ? 160 : 140\"\r\n >\r\n <div\r\n class=\"input-group\"\r\n [class.input-group-sm]=\"componentHeight === ControlHeight.Small\"\r\n [class.input-group-lg]=\"componentHeight === ControlHeight.Large\"\r\n >\r\n <input\r\n id=\"{{name}}\"\r\n name=\"{{name}}\"\r\n type=\"text\"\r\n [value]=\"valuestring\"\r\n maxlength=\"6\"\r\n [imask]=\"imaskDate\"\r\n size=\"6\"\r\n class=\"form-control\"\r\n [attr.placeholder]=\"placeholder\"\r\n data-error-msg=\"ctl00_cphContent_ctl00_ucPublicationDetail_dtpValidFrom_timeTextBoxTypeValidator\"\r\n [ngClass]=\"{'is-invalid': invalid && (dirty || touched) }\"\r\n (blur)=\"onTouch()\"\r\n (accept)=\"setValueString($event)\"\r\n [disabled]=\"isdisabled\"\r\n />\r\n <span class=\"input-group-btn\">\r\n <button\r\n class=\"btn btn-default\"\r\n type=\"button\"\r\n (click)=\"showTimeSelector()\"\r\n [disabled]=\"isdisabled\"\r\n >\r\n <i [class]=\"IconSelector\"></i>\r\n </button>\r\n </span>\r\n </div>\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n <div\r\n class=\"popover bottom in\"\r\n role=\"tooltip\"\r\n *ngIf=\"_showselector\"\r\n style=\"\r\n display: block;\r\n left: unset;\r\n right: 0px;\r\n top: 34px;\r\n max-width: 325px;\r\n \"\r\n >\r\n <div class=\"arrow\" style=\"left: unset; right: 10px\"></div>\r\n <h3 class=\"popover-title\" style=\"display: none\"></h3>\r\n <div class=\"popover-content\">\r\n <sac-dateselector\r\n *ngIf=\"_showselector\"\r\n [initialvalue]=\"value\"\r\n (selectdate)=\"timeselect($event)\"\r\n timeselection=\"true\"\r\n ></sac-dateselector>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
588
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
589
|
+
providers: [
|
|
590
|
+
{
|
|
591
|
+
provide: NG_VALUE_ACCESSOR,
|
|
592
|
+
multi: true,
|
|
593
|
+
useExisting: forwardRef(() => SacTimeComponent),
|
|
594
|
+
},
|
|
595
|
+
{
|
|
596
|
+
provide: NG_VALIDATORS,
|
|
597
|
+
multi: true,
|
|
598
|
+
useExisting: forwardRef(() => SacTimeComponent),
|
|
599
|
+
},
|
|
600
|
+
]
|
|
601
|
+
},] }
|
|
602
|
+
];
|
|
603
|
+
SacTimeComponent.ctorParameters = () => [
|
|
604
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
605
|
+
{ type: Injector },
|
|
606
|
+
{ type: ElementRef }
|
|
607
|
+
];
|
|
608
|
+
|
|
609
|
+
class SACBootstrap3DateTimeModule {
|
|
610
|
+
}
|
|
611
|
+
SACBootstrap3DateTimeModule.decorators = [
|
|
612
|
+
{ type: NgModule, args: [{
|
|
613
|
+
declarations: [
|
|
614
|
+
SacDateComponent,
|
|
615
|
+
SacDateTimeComponent,
|
|
616
|
+
SacTimeComponent,
|
|
617
|
+
SacDateSelectorComponent,
|
|
618
|
+
],
|
|
619
|
+
imports: [CommonModule, IMaskModule, SACBootstrap3LayoutModule],
|
|
620
|
+
exports: [
|
|
621
|
+
SacDateComponent,
|
|
622
|
+
SacDateTimeComponent,
|
|
623
|
+
SacTimeComponent,
|
|
624
|
+
SacDateSelectorComponent,
|
|
625
|
+
],
|
|
626
|
+
},] }
|
|
627
|
+
];
|
|
628
|
+
|
|
629
|
+
class SacGridComponent extends SacGridCommon {
|
|
630
|
+
constructor() {
|
|
631
|
+
super(...arguments);
|
|
632
|
+
this.ellipsis = false;
|
|
633
|
+
}
|
|
634
|
+
}
|
|
635
|
+
SacGridComponent.decorators = [
|
|
636
|
+
{ type: Component, args: [{
|
|
637
|
+
selector: 'sac-grid',
|
|
638
|
+
template: "<table class=\"table table-striped table-condensed table-hover\" id={{name}}>\r\n <thead>\r\n <tr>\r\n <ng-container *ngTemplateOutlet=\"template; context { row: {}, type: 'header'}\">\r\n </ng-container>\r\n </tr>\r\n </thead>\r\n <tbody>\r\n <ng-container *ngFor=\"let item of value; let i=index\">\r\n <tr>\r\n <ng-container *ngTemplateOutlet=\"template; context { row: item, type: 'body'}\">\r\n </ng-container>\r\n </tr>\r\n </ng-container>\r\n <tr *ngIf=\"value === undefined || value === null || value.length === 0\">\r\n <td [attr.colspan]=\"ColumnCount\">{{emptytext}}</td>\r\n </tr>\r\n <tr>\r\n <td [attr.colspan]=\"ColumnCount\">\r\n <div class=\"container-fluid\">\r\n <sac-paging name=\"{{name}}Paging\" (paging)=\"pageChange($event)\" [pagerdata]=\"pagerdata\" [pagingtext]=\"pagingtext\" [pagesizetext]=\"pagesizetext\"></sac-paging>\r\n </div>\r\n </td>\r\n </tr>\r\n </tbody>\r\n</table>\r\n",
|
|
639
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
640
|
+
providers: [
|
|
641
|
+
{ provide: NG_VALUE_ACCESSOR, multi: true, useExisting: SacGridComponent },
|
|
642
|
+
{ provide: NG_VALIDATORS, multi: true, useExisting: forwardRef(() => SacGridComponent) }
|
|
643
|
+
]
|
|
644
|
+
},] }
|
|
645
|
+
];
|
|
646
|
+
SacGridComponent.propDecorators = {
|
|
647
|
+
template: [{ type: ContentChild, args: [TemplateRef, { static: true },] }]
|
|
648
|
+
};
|
|
649
|
+
|
|
650
|
+
class SacGridColumnComponent extends SacGridColumnCommon {
|
|
651
|
+
constructor(grid, injector, el) {
|
|
652
|
+
super(grid, injector, el);
|
|
653
|
+
}
|
|
654
|
+
}
|
|
655
|
+
SacGridColumnComponent.decorators = [
|
|
656
|
+
{ type: Component, args: [{
|
|
657
|
+
selector: 'sac-gridcolumn',
|
|
658
|
+
template: "<th\r\n scope=\"col\"\r\n *ngIf=\"IsHeader()\"\r\n [style.width]=\"width\"\r\n (click)=\"SortByColumn()\"\r\n>\r\n <span>{{header}}</span>\r\n <span\r\n [class]=\"IconSortUp\"\r\n style=\"padding-left: 0.5rem\"\r\n *ngIf=\"IsSortedColumn() && GetSortDirection() ==='asc'\"\r\n ></span>\r\n <span\r\n [class]=\"IconSortDown\"\r\n style=\"padding-left: 0.5rem\"\r\n *ngIf=\"IsSortedColumn() && GetSortDirection() ==='desc'\"\r\n ></span>\r\n</th>\r\n<td\r\n scope=\"col\"\r\n *ngIf=\"IsBody()\"\r\n [style.width]=\"width\"\r\n [class.ellipsis]=\"IsEllipsis()\"\r\n>\r\n <span [attr.title]=\"IsEllipsis() ? value : null\"> {{value}} </span>\r\n</td>\r\n",
|
|
659
|
+
providers: [
|
|
660
|
+
{
|
|
661
|
+
provide: SacGridColumnBaseCommon,
|
|
662
|
+
useExisting: forwardRef(() => SacGridColumnComponent),
|
|
663
|
+
},
|
|
664
|
+
]
|
|
665
|
+
},] }
|
|
666
|
+
];
|
|
667
|
+
SacGridColumnComponent.ctorParameters = () => [
|
|
668
|
+
{ type: SacGridComponent },
|
|
669
|
+
{ type: Injector },
|
|
670
|
+
{ type: ElementRef }
|
|
671
|
+
];
|
|
672
|
+
|
|
673
|
+
/**
|
|
674
|
+
* Grid Action Button
|
|
675
|
+
*
|
|
676
|
+
* @example Standard Action
|
|
677
|
+
*
|
|
678
|
+
* <ngGridButton icon="edit" (clicked)="action('edit')" [isdisabled]="true"></ngGridButton>
|
|
679
|
+
*
|
|
680
|
+
* @example Custom Action
|
|
681
|
+
*
|
|
682
|
+
* <ngGridButton iconstyle="sprite" icon="icon-sprite-base-main_info" (clicked)="action('info')"></ngGridButton>
|
|
683
|
+
*
|
|
684
|
+
*/
|
|
685
|
+
class SacGridButtonComponent extends SacGridButtonCommon {
|
|
686
|
+
/**
|
|
687
|
+
* Gibt das Icon für den Button zurück
|
|
688
|
+
*/
|
|
689
|
+
getIconClass() {
|
|
690
|
+
let iconset = this.iconstyle;
|
|
691
|
+
let iconcss = this.icon;
|
|
692
|
+
if (iconset === '') {
|
|
693
|
+
switch (this.icon) {
|
|
694
|
+
case 'edit':
|
|
695
|
+
iconset = 'sprite';
|
|
696
|
+
iconcss = 'icon-sprite-base-main_edit';
|
|
697
|
+
break;
|
|
698
|
+
case 'delete':
|
|
699
|
+
iconset = 'sprite';
|
|
700
|
+
iconcss = 'icon-sprite-base-main_delete';
|
|
701
|
+
break;
|
|
702
|
+
}
|
|
703
|
+
}
|
|
704
|
+
if (this._isdisabledvalue) {
|
|
705
|
+
iconcss += '_disabled';
|
|
706
|
+
}
|
|
707
|
+
const result = iconset + ' ' + iconcss;
|
|
708
|
+
return result.trim();
|
|
709
|
+
}
|
|
710
|
+
}
|
|
711
|
+
SacGridButtonComponent.decorators = [
|
|
712
|
+
{ type: Component, args: [{
|
|
713
|
+
selector: 'sac-gridbutton',
|
|
714
|
+
template: "<a (click)=\"callaction()\" style=\"padding-right: 5px;\" [class.disabled]=\"isdisabled\" [attr.disabled]=\"isdisabled ? 'disabled' : null\"><span class=\"{{getIconClass()}}\"></span></a>\r\n"
|
|
715
|
+
},] }
|
|
716
|
+
];
|
|
717
|
+
|
|
718
|
+
class SacPagingComponent extends SacPagingCommon {
|
|
719
|
+
/**
|
|
720
|
+
* Konstruktor
|
|
721
|
+
*/
|
|
722
|
+
constructor(injector) { super(injector); }
|
|
723
|
+
}
|
|
724
|
+
SacPagingComponent.decorators = [
|
|
725
|
+
{ type: Component, args: [{
|
|
726
|
+
selector: 'sac-paging',
|
|
727
|
+
template: "<div class=\"row\">\r\n <div class=\"pager-nav col-sm-9\" id=\"{{name}}\">\r\n <ul class=\"pagination\" style=\"margin: 10px 0\">\r\n <li\r\n [ngClass]=\"{'aspNetDisabled disabled': activePageIndex === firstPageIndex}\"\r\n >\r\n <a (click)=\"firstPage()\">\u00AB</a>\r\n </li>\r\n <li\r\n *ngFor=\"let page of paginators; let i = index\"\r\n [ngClass]=\"{'active': page === activePageIndex}\"\r\n >\r\n <a (click)=\"changePage(page)\">{{page + 1 }}</a>\r\n </li>\r\n <li\r\n [ngClass]=\"{'aspNetDisabled disabled': activePageIndex === lastPageIndex}\"\r\n >\r\n <a (click)=\"lastPage()\">\u00BB</a>\r\n </li>\r\n </ul>\r\n </div>\r\n <div class=\"col-sm-3 text-right\" style=\"margin: 20px 0\">\r\n Seite {{getCurrentPageNumber()}} von {{getTotalPageNumber()}}\r\n </div>\r\n</div>\r\n",
|
|
728
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
729
|
+
providers: [
|
|
730
|
+
{ provide: NG_VALUE_ACCESSOR, multi: true, useExisting: SacPagingComponent },
|
|
731
|
+
{ provide: NG_VALIDATORS, multi: true, useExisting: forwardRef(() => SacPagingComponent) }
|
|
732
|
+
]
|
|
733
|
+
},] }
|
|
734
|
+
];
|
|
735
|
+
SacPagingComponent.ctorParameters = () => [
|
|
736
|
+
{ type: Injector }
|
|
737
|
+
];
|
|
738
|
+
|
|
739
|
+
class SacGridColumnActionComponent extends SacGridColumnActionCommon {
|
|
740
|
+
constructor(grid, injector, el) {
|
|
741
|
+
super(grid, injector, el);
|
|
742
|
+
this.width = '52px';
|
|
743
|
+
}
|
|
744
|
+
}
|
|
745
|
+
SacGridColumnActionComponent.decorators = [
|
|
746
|
+
{ type: Component, args: [{
|
|
747
|
+
selector: 'sac-gridcolumnaction',
|
|
748
|
+
template: "<th scope=\"col\" *ngIf=\"IsHeader()\" [style.width]=\"width\"><span></span></th>\r\n<td scope=\"col\" *ngIf=\"IsBody()\">\r\n <ng-content></ng-content>\r\n</td>\r\n",
|
|
749
|
+
providers: [
|
|
750
|
+
{
|
|
751
|
+
provide: SacGridColumnBaseCommon,
|
|
752
|
+
useExisting: forwardRef(() => SacGridColumnActionComponent),
|
|
753
|
+
},
|
|
754
|
+
]
|
|
755
|
+
},] }
|
|
756
|
+
];
|
|
757
|
+
SacGridColumnActionComponent.ctorParameters = () => [
|
|
758
|
+
{ type: SacGridComponent },
|
|
759
|
+
{ type: Injector },
|
|
760
|
+
{ type: ElementRef }
|
|
761
|
+
];
|
|
762
|
+
|
|
763
|
+
class SacGridImageComponent extends SacGridImageCommon {
|
|
764
|
+
getIconClass() {
|
|
765
|
+
switch (this.iconstyle) {
|
|
766
|
+
case 'edit':
|
|
767
|
+
return 'sprite icon-sprite-base-main_edit';
|
|
768
|
+
case 'delete':
|
|
769
|
+
return 'sprite icon-sprite-base-main_delete';
|
|
770
|
+
default:
|
|
771
|
+
return this.iconstyle;
|
|
772
|
+
}
|
|
773
|
+
}
|
|
774
|
+
}
|
|
775
|
+
SacGridImageComponent.decorators = [
|
|
776
|
+
{ type: Component, args: [{
|
|
777
|
+
selector: 'sac-gridimage',
|
|
778
|
+
template: "<span style=\"padding-right: 5px;\"><span class=\"{{getIconClass()}}\"></span></span>\r\n"
|
|
779
|
+
},] }
|
|
780
|
+
];
|
|
781
|
+
|
|
782
|
+
class SACBootstrap3GridModule {
|
|
783
|
+
}
|
|
784
|
+
SACBootstrap3GridModule.decorators = [
|
|
785
|
+
{ type: NgModule, args: [{
|
|
786
|
+
declarations: [SacGridComponent, SacGridColumnComponent, SacGridColumnActionComponent, SacPagingComponent, SacGridButtonComponent, SacGridImageComponent],
|
|
787
|
+
imports: [
|
|
788
|
+
CommonModule
|
|
789
|
+
],
|
|
790
|
+
exports: [SacGridComponent, SacGridColumnComponent, SacGridColumnActionComponent, SacPagingComponent, SacGridButtonComponent, SacGridImageComponent]
|
|
791
|
+
},] }
|
|
792
|
+
];
|
|
793
|
+
|
|
794
|
+
/**
|
|
795
|
+
* Tooltip Komponente
|
|
796
|
+
*
|
|
797
|
+
* @example ToolTip Control
|
|
798
|
+
*
|
|
799
|
+
* <ngTooltip tooltiptext="Mein Tooltip" [inlinemode]="true">
|
|
800
|
+
* <i class="tooltip"></i>
|
|
801
|
+
* </ngTooltip>
|
|
802
|
+
*
|
|
803
|
+
* @example ToolTip Control im Inline Mode. Style auf Icon kann auch in Klasse ausgelagert werden.
|
|
804
|
+
*
|
|
805
|
+
* <div class="form-inline">
|
|
806
|
+
* <ngInputSearch iconname="Suchen"></ngInputSearch>
|
|
807
|
+
* <ngTooltip tooltiptext="Mein Tooltip" [inlinemode]="true">
|
|
808
|
+
* <i class="tooltip" style="position: relative; left: 0; top: 3px; display: inline-block; margin-right: 10px;"></i>
|
|
809
|
+
* </ngTooltip>
|
|
810
|
+
* </div>
|
|
811
|
+
*
|
|
812
|
+
*/
|
|
813
|
+
class SacTooltipComponent extends SacTooltipCommon {
|
|
814
|
+
/**
|
|
815
|
+
* Konstrukor
|
|
816
|
+
* @param parent SacFormular Instanz
|
|
817
|
+
* @param injector Component Injector
|
|
818
|
+
*/
|
|
819
|
+
constructor(cdRef, ref) {
|
|
820
|
+
super(cdRef, ref);
|
|
821
|
+
}
|
|
822
|
+
}
|
|
823
|
+
SacTooltipComponent.decorators = [
|
|
824
|
+
{ type: Component, args: [{
|
|
825
|
+
selector: 'sac-tooltip',
|
|
826
|
+
template: "<div [style.display]=\"inlinemode ? 'inline' : null\">\r\n <div #container (mouseenter)=\"ShowTooltip()\" (mouseleave)=\"HideTooltip()\" [style.display]=\"inlinemode ? 'inline' : null\">\r\n <ng-content></ng-content>\r\n </div>\r\n <div *ngIf=\"IsTooltipVisible()\" [style.visibility]=\"IsTooltipContentVisible ? 'visible' : 'hidden'\" #tooltip class=\"tooltip in\" style=\"display: block;\"\r\n [style.left.px]=\"LeftPos\" [style.top.px]=\"TopPos\"\r\n [class.top]=\"GetTooltipPosition() === TooltipPosition.top\" [class.left]=\"GetTooltipPosition() === TooltipPosition.left\"\r\n [class.right]=\"GetTooltipPosition() === TooltipPosition.right\" [class.bottom]=\"GetTooltipPosition() === TooltipPosition.bottom\">\r\n <div class=\"tooltip-arrow\" style=\"top: 50%;\"></div>\r\n <div class=\"tooltip-inner\">\r\n {{tooltiptext}}\r\n </div>\r\n </div>\r\n</div>\r\n"
|
|
827
|
+
},] }
|
|
828
|
+
];
|
|
829
|
+
SacTooltipComponent.ctorParameters = () => [
|
|
830
|
+
{ type: ChangeDetectorRef },
|
|
831
|
+
{ type: ElementRef }
|
|
832
|
+
];
|
|
833
|
+
|
|
834
|
+
class SACBootstrap3TooltipModule {
|
|
835
|
+
}
|
|
836
|
+
SACBootstrap3TooltipModule.decorators = [
|
|
837
|
+
{ type: NgModule, args: [{
|
|
838
|
+
declarations: [SacTooltipComponent],
|
|
839
|
+
imports: [
|
|
840
|
+
CommonModule, CommonModule
|
|
841
|
+
],
|
|
842
|
+
exports: [SacTooltipComponent]
|
|
843
|
+
},] }
|
|
844
|
+
];
|
|
845
|
+
|
|
846
|
+
class SacInputComponent extends SacInputCommon {
|
|
847
|
+
// #region Constructors
|
|
848
|
+
/**
|
|
849
|
+
* Constructor
|
|
850
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
851
|
+
* @param injector Injector for injecting services
|
|
852
|
+
*/
|
|
853
|
+
constructor(formLayout, injector) {
|
|
854
|
+
super(formLayout, injector);
|
|
855
|
+
}
|
|
856
|
+
}
|
|
857
|
+
SacInputComponent.decorators = [
|
|
858
|
+
{ type: Component, args: [{
|
|
859
|
+
selector: 'sac-input',
|
|
860
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <input\r\n id=\"{{name}}\"\r\n name=\"{{name}}\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [ngClass]=\"[componentHeight | toControlHeight]\"\r\n [value]=\"value\"\r\n [attr.placeholder]=\"placeholder\"\r\n (blur)=\"onTouch()\"\r\n (input)=\"setValue($event.target.value)\"\r\n [attr.maxlength]=\"maxlength\"\r\n [disabled]=\"isdisabled\"\r\n [readonly]=\"readonly\"\r\n />\r\n <label\r\n for=\"{{name}}\"\r\n class=\"form-label-adaptive form-label-fixed\"\r\n [ngClass]=\"{ 'required': isrequired }\"\r\n *ngIf=\"isAdaptiveLabel && !disablelabel\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
861
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
862
|
+
providers: [
|
|
863
|
+
{ provide: NG_VALUE_ACCESSOR, multi: true, useExisting: SacInputComponent },
|
|
864
|
+
{
|
|
865
|
+
provide: NG_VALIDATORS,
|
|
866
|
+
multi: true,
|
|
867
|
+
useExisting: forwardRef(() => SacInputComponent),
|
|
868
|
+
},
|
|
869
|
+
]
|
|
870
|
+
},] }
|
|
871
|
+
];
|
|
872
|
+
SacInputComponent.ctorParameters = () => [
|
|
873
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
874
|
+
{ type: Injector }
|
|
875
|
+
];
|
|
876
|
+
|
|
877
|
+
/**
|
|
878
|
+
* Komponente für TextArea
|
|
879
|
+
*
|
|
880
|
+
* @example
|
|
881
|
+
*
|
|
882
|
+
* <ngInputArea name="ngInputArea" label="My Label" placeholder='i am input area' [isrequired]="true" customCssClass="myClass1 myClass3"></ngInputArea>
|
|
883
|
+
*
|
|
884
|
+
* @example
|
|
885
|
+
*
|
|
886
|
+
* <ngInputArea name="ngInputArea" label="My Label" height="150px" placeholder='i am input area' [islanguagespecific]="true">
|
|
887
|
+
*
|
|
888
|
+
*/
|
|
889
|
+
class SacInputAreaComponent extends SacInputAreaCommon {
|
|
890
|
+
// #region Constructors
|
|
891
|
+
/**
|
|
892
|
+
* Constructor
|
|
893
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
894
|
+
* @param injector Injector for injecting services
|
|
895
|
+
*/
|
|
896
|
+
constructor(formLayout, injector) {
|
|
897
|
+
super(formLayout, injector);
|
|
898
|
+
}
|
|
899
|
+
}
|
|
900
|
+
SacInputAreaComponent.decorators = [
|
|
901
|
+
{ type: Component, args: [{
|
|
902
|
+
selector: 'sac-inputarea',
|
|
903
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <textarea\r\n id=\"{{name}}\"\r\n name=\"{{name}}\"\r\n type=\"\"\r\n class=\"form-control\"\r\n [class.is-invalid]=\"invalid && (dirty || touched)\"\r\n [class.validation-error]=\"invalid && (dirty || touched)\"\r\n [class.required]=\"isrequired\"\r\n [ngClass]=\"[componentHeight | toControlHeight]\"\r\n [value]=\"value\"\r\n [attr.placeholder]=\"placeholder\"\r\n (blur)=\"onTouch()\"\r\n (input)=\"setValue($event.target.value)\"\r\n (keypress)=\"onKeyPress($event)\"\r\n [attr.rows]=\"rows\"\r\n [disabled]=\"isdisabled\"\r\n [readonly]=\"readonly\"\r\n ></textarea>\r\n <label\r\n for=\"{{name}}\"\r\n class=\"form-label-adaptive form-label-fixed\"\r\n [ngClass]=\"{ 'required': isrequired }\"\r\n *ngIf=\"isAdaptiveLabel && !disablelabel\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
904
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
905
|
+
providers: [
|
|
906
|
+
{
|
|
907
|
+
provide: NG_VALUE_ACCESSOR,
|
|
908
|
+
multi: true,
|
|
909
|
+
useExisting: SacInputAreaComponent,
|
|
910
|
+
},
|
|
911
|
+
{
|
|
912
|
+
provide: NG_VALIDATORS,
|
|
913
|
+
multi: true,
|
|
914
|
+
useExisting: forwardRef(() => SacInputAreaComponent),
|
|
915
|
+
},
|
|
916
|
+
]
|
|
917
|
+
},] }
|
|
918
|
+
];
|
|
919
|
+
SacInputAreaComponent.ctorParameters = () => [
|
|
920
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
921
|
+
{ type: Injector }
|
|
922
|
+
];
|
|
923
|
+
|
|
924
|
+
class SacInputCurrencyComponent extends SacInputCurrencyCommon {
|
|
925
|
+
// #region Constructors
|
|
926
|
+
/**
|
|
927
|
+
* Constructor
|
|
928
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
929
|
+
* @param injector Injector for injecting services
|
|
930
|
+
*/
|
|
931
|
+
constructor(formLayout, injector) {
|
|
932
|
+
super(formLayout, injector);
|
|
933
|
+
}
|
|
934
|
+
}
|
|
935
|
+
SacInputCurrencyComponent.decorators = [
|
|
936
|
+
{ type: Component, args: [{
|
|
937
|
+
selector: 'sac-inputcurrency',
|
|
938
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <div\r\n class=\"input-group\"\r\n [class.input-group-sm]=\"componentHeight === ControlHeight.Small\"\r\n [class.input-group-lg]=\"componentHeight === ControlHeight.Large\"\r\n >\r\n <input\r\n id=\"{{name}}\"\r\n name=\"{{name}}\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [ngClass]=\"[componentHeight | toControlHeight]\"\r\n [value]=\"value\"\r\n [attr.placeholder]=\"placeholder\"\r\n (blur)=\"onTouch()\"\r\n (input)=\"setValue($event.target.value)\"\r\n (keypress)=\"onKeyPress($event)\"\r\n [disabled]=\"isdisabled\"\r\n [readonly]=\"readonly\"\r\n />\r\n <label\r\n for=\"{{name}}\"\r\n class=\"form-label-adaptive form-label-fixed\"\r\n [ngClass]=\"{ 'required': isrequired }\"\r\n *ngIf=\"isAdaptiveLabel && !disablelabel\"\r\n >{{label}}</label\r\n >\r\n <div class=\"input-group-addon\">{{currency}}</div>\r\n </div>\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
939
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
940
|
+
providers: [
|
|
941
|
+
{
|
|
942
|
+
provide: NG_VALUE_ACCESSOR,
|
|
943
|
+
multi: true,
|
|
944
|
+
useExisting: SacInputCurrencyComponent,
|
|
945
|
+
},
|
|
946
|
+
{
|
|
947
|
+
provide: NG_VALIDATORS,
|
|
948
|
+
multi: true,
|
|
949
|
+
useExisting: forwardRef(() => SacInputCurrencyComponent),
|
|
950
|
+
},
|
|
951
|
+
]
|
|
952
|
+
},] }
|
|
953
|
+
];
|
|
954
|
+
SacInputCurrencyComponent.ctorParameters = () => [
|
|
955
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
956
|
+
{ type: Injector }
|
|
957
|
+
];
|
|
958
|
+
|
|
959
|
+
class SacInputDecimalComponent extends SacInputDecimalCommon {
|
|
960
|
+
// #region Constructors
|
|
961
|
+
/**
|
|
962
|
+
* Constructor
|
|
963
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
964
|
+
* @param injector Injector for injecting services
|
|
965
|
+
*/
|
|
966
|
+
constructor(formLayout, injector) {
|
|
967
|
+
super(formLayout, injector);
|
|
968
|
+
}
|
|
969
|
+
}
|
|
970
|
+
SacInputDecimalComponent.decorators = [
|
|
971
|
+
{ type: Component, args: [{
|
|
972
|
+
selector: 'sac-inputdecimal',
|
|
973
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <input\r\n id=\"{{name}}\"\r\n name=\"{{name}}\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [ngClass]=\"[componentHeight | toControlHeight]\"\r\n [value]=\"value\"\r\n [attr.placeholder]=\"placeholder\"\r\n (blur)=\"onTouch()\"\r\n (input)=\"setValue($event.target.value)\"\r\n (keypress)=\"onKeyPress($event)\"\r\n [disabled]=\"isdisabled\"\r\n [readonly]=\"readonly\"\r\n />\r\n <label\r\n for=\"{{name}}\"\r\n class=\"form-label-adaptive form-label-fixed\"\r\n [ngClass]=\"{ 'required': isrequired }\"\r\n *ngIf=\"isAdaptiveLabel && !disablelabel\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
974
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
975
|
+
providers: [
|
|
976
|
+
{
|
|
977
|
+
provide: NG_VALUE_ACCESSOR,
|
|
978
|
+
multi: true,
|
|
979
|
+
useExisting: SacInputDecimalComponent,
|
|
980
|
+
},
|
|
981
|
+
{
|
|
982
|
+
provide: NG_VALIDATORS,
|
|
983
|
+
multi: true,
|
|
984
|
+
useExisting: forwardRef(() => SacInputDecimalComponent),
|
|
985
|
+
},
|
|
986
|
+
]
|
|
987
|
+
},] }
|
|
988
|
+
];
|
|
989
|
+
SacInputDecimalComponent.ctorParameters = () => [
|
|
990
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
991
|
+
{ type: Injector }
|
|
992
|
+
];
|
|
993
|
+
|
|
994
|
+
class SacInputEmailComponent extends SacInputEmailCommon {
|
|
995
|
+
// #region Constructors
|
|
996
|
+
/**
|
|
997
|
+
* Constructor
|
|
998
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
999
|
+
* @param injector Injector for injecting services
|
|
1000
|
+
*/
|
|
1001
|
+
constructor(formLayout, injector) {
|
|
1002
|
+
super(formLayout, injector);
|
|
1003
|
+
}
|
|
1004
|
+
}
|
|
1005
|
+
SacInputEmailComponent.decorators = [
|
|
1006
|
+
{ type: Component, args: [{
|
|
1007
|
+
selector: 'sac-inputemail',
|
|
1008
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <div\r\n class=\"input-group\"\r\n [class.input-group-sm]=\"componentHeight === ControlHeight.Small\"\r\n [class.input-group-lg]=\"componentHeight === ControlHeight.Large\"\r\n >\r\n <div class=\"input-group-addon\">@</div>\r\n <input\r\n id=\"{{name}}\"\r\n name=\"{{name}}\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [ngClass]=\"[componentHeight | toControlHeight]\"\r\n [value]=\"value\"\r\n [attr.placeholder]=\"placeholder\"\r\n (blur)=\"onTouch()\"\r\n (input)=\"setValue($event.target.value)\"\r\n autocomplete=\"email\"\r\n [attr.maxlength]=\"maxlength\"\r\n [disabled]=\"isdisabled\"\r\n [readonly]=\"readonly\"\r\n />\r\n <label\r\n for=\"{{name}}\"\r\n class=\"form-label-adaptive form-label-fixed\"\r\n [ngClass]=\"{ 'required': isrequired }\"\r\n *ngIf=\"isAdaptiveLabel && !disablelabel\"\r\n >{{label}}</label\r\n >\r\n </div>\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
1009
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
1010
|
+
providers: [
|
|
1011
|
+
{
|
|
1012
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1013
|
+
multi: true,
|
|
1014
|
+
useExisting: SacInputEmailComponent,
|
|
1015
|
+
},
|
|
1016
|
+
{
|
|
1017
|
+
provide: NG_VALIDATORS,
|
|
1018
|
+
multi: true,
|
|
1019
|
+
useExisting: forwardRef(() => SacInputEmailComponent),
|
|
1020
|
+
},
|
|
1021
|
+
]
|
|
1022
|
+
},] }
|
|
1023
|
+
];
|
|
1024
|
+
SacInputEmailComponent.ctorParameters = () => [
|
|
1025
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
1026
|
+
{ type: Injector }
|
|
1027
|
+
];
|
|
1028
|
+
|
|
1029
|
+
class SacInputIntegerComponent extends SacInputIntegerCommon {
|
|
1030
|
+
// #region Constructors
|
|
1031
|
+
/**
|
|
1032
|
+
* Constructor
|
|
1033
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
1034
|
+
* @param injector Injector for injecting services
|
|
1035
|
+
*/
|
|
1036
|
+
constructor(formLayout, injector) {
|
|
1037
|
+
super(formLayout, injector);
|
|
1038
|
+
}
|
|
1039
|
+
}
|
|
1040
|
+
SacInputIntegerComponent.decorators = [
|
|
1041
|
+
{ type: Component, args: [{
|
|
1042
|
+
selector: 'sac-inputinteger',
|
|
1043
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <input\r\n id=\"{{name}}\"\r\n name=\"{{name}}\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [ngClass]=\"[componentHeight | toControlHeight]\"\r\n [value]=\"value\"\r\n [attr.placeholder]=\"placeholder\"\r\n (blur)=\"onTouch()\"\r\n (input)=\"setValue($event.target.value)\"\r\n (keypress)=\"onKeyPress($event)\"\r\n [disabled]=\"isdisabled\"\r\n [readonly]=\"readonly\"\r\n />\r\n <label\r\n for=\"{{name}}\"\r\n class=\"form-label-adaptive form-label-fixed\"\r\n [ngClass]=\"{ 'required': isrequired }\"\r\n *ngIf=\"isAdaptiveLabel && !disablelabel\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
1044
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
1045
|
+
providers: [
|
|
1046
|
+
{
|
|
1047
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1048
|
+
multi: true,
|
|
1049
|
+
useExisting: SacInputIntegerComponent,
|
|
1050
|
+
},
|
|
1051
|
+
{
|
|
1052
|
+
provide: NG_VALIDATORS,
|
|
1053
|
+
multi: true,
|
|
1054
|
+
useExisting: forwardRef(() => SacInputIntegerComponent),
|
|
1055
|
+
},
|
|
1056
|
+
]
|
|
1057
|
+
},] }
|
|
1058
|
+
];
|
|
1059
|
+
SacInputIntegerComponent.ctorParameters = () => [
|
|
1060
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
1061
|
+
{ type: Injector }
|
|
1062
|
+
];
|
|
1063
|
+
|
|
1064
|
+
class SacInputPasswordComponent extends SacInputPasswordCommon {
|
|
1065
|
+
// #region Constructors
|
|
1066
|
+
/**
|
|
1067
|
+
* Constructor
|
|
1068
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
1069
|
+
* @param injector Injector for injecting services
|
|
1070
|
+
*/
|
|
1071
|
+
constructor(formLayout, injector) {
|
|
1072
|
+
super(formLayout, injector);
|
|
1073
|
+
}
|
|
1074
|
+
}
|
|
1075
|
+
SacInputPasswordComponent.decorators = [
|
|
1076
|
+
{ type: Component, args: [{
|
|
1077
|
+
selector: 'sac-inputpassword',
|
|
1078
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <input\r\n id=\"{{name}}\"\r\n name=\"{{name}}\"\r\n class=\"form-control\"\r\n [ngClass]=\"[componentHeight | toControlHeight]\"\r\n type=\"password\"\r\n [value]=\"value\"\r\n [attr.placeholder]=\"placeholder\"\r\n (blur)=\"onTouch()\"\r\n (input)=\"setValue($event.target.value)\"\r\n [attr.maxlength]=\"maxlength\"\r\n autocomplete=\"new-password\"\r\n [disabled]=\"isdisabled\"\r\n [readonly]=\"readonly\"\r\n />\r\n <label\r\n for=\"{{name}}\"\r\n class=\"form-label-adaptive form-label-fixed\"\r\n [ngClass]=\"{ 'required': isrequired }\"\r\n *ngIf=\"isAdaptiveLabel && !disablelabel\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
1079
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
1080
|
+
providers: [
|
|
1081
|
+
{
|
|
1082
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1083
|
+
multi: true,
|
|
1084
|
+
useExisting: SacInputPasswordComponent,
|
|
1085
|
+
},
|
|
1086
|
+
{
|
|
1087
|
+
provide: NG_VALIDATORS,
|
|
1088
|
+
multi: true,
|
|
1089
|
+
useExisting: forwardRef(() => SacInputPasswordComponent),
|
|
1090
|
+
},
|
|
1091
|
+
]
|
|
1092
|
+
},] }
|
|
1093
|
+
];
|
|
1094
|
+
SacInputPasswordComponent.ctorParameters = () => [
|
|
1095
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
1096
|
+
{ type: Injector }
|
|
1097
|
+
];
|
|
1098
|
+
|
|
1099
|
+
class SacInputSearchComponent extends SacInputSearchCommon {
|
|
1100
|
+
// #region Constructors
|
|
1101
|
+
/**
|
|
1102
|
+
* Constructor
|
|
1103
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
1104
|
+
* @param injector Injector for injecting services
|
|
1105
|
+
*/
|
|
1106
|
+
constructor(formLayout, injector) {
|
|
1107
|
+
super(formLayout, injector);
|
|
1108
|
+
}
|
|
1109
|
+
}
|
|
1110
|
+
SacInputSearchComponent.decorators = [
|
|
1111
|
+
{ type: Component, args: [{
|
|
1112
|
+
selector: 'sac-inputsearch',
|
|
1113
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <div\r\n class=\"input-group\"\r\n [class.input-group-sm]=\"componentHeight === ControlHeight.Small\"\r\n [class.input-group-lg]=\"componentHeight === ControlHeight.Large\"\r\n >\r\n <input\r\n id=\"{{name}}\"\r\n name=\"{{name}}\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [ngClass]=\"[componentHeight | toControlHeight]\"\r\n [value]=\"value\"\r\n [attr.placeholder]=\"placeholder\"\r\n (blur)=\"onTouch()\"\r\n (input)=\"setValue($event.target.value)\"\r\n [attr.maxlength]=\"maxlength\"\r\n [disabled]=\"isdisabled\"\r\n [readonly]=\"readonly\"\r\n />\r\n <span class=\"input-group-btn\">\r\n <input\r\n type=\"submit\"\r\n class=\"btn btn-default\"\r\n id=\"{{name}}_search\"\r\n (click)=\"searchClick()\"\r\n [value]=\"buttontext\"\r\n />\r\n </span>\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
1114
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
1115
|
+
providers: [
|
|
1116
|
+
{
|
|
1117
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1118
|
+
multi: true,
|
|
1119
|
+
useExisting: SacInputSearchComponent,
|
|
1120
|
+
},
|
|
1121
|
+
{
|
|
1122
|
+
provide: NG_VALIDATORS,
|
|
1123
|
+
multi: true,
|
|
1124
|
+
useExisting: forwardRef(() => SacInputSearchComponent),
|
|
1125
|
+
},
|
|
1126
|
+
]
|
|
1127
|
+
},] }
|
|
1128
|
+
];
|
|
1129
|
+
SacInputSearchComponent.ctorParameters = () => [
|
|
1130
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
1131
|
+
{ type: Injector }
|
|
1132
|
+
];
|
|
1133
|
+
|
|
1134
|
+
class SACBootstrap3InputModule {
|
|
1135
|
+
}
|
|
1136
|
+
SACBootstrap3InputModule.decorators = [
|
|
1137
|
+
{ type: NgModule, args: [{
|
|
1138
|
+
declarations: [
|
|
1139
|
+
SacInputComponent,
|
|
1140
|
+
SacInputAreaComponent,
|
|
1141
|
+
SacInputCurrencyComponent,
|
|
1142
|
+
SacInputDecimalComponent,
|
|
1143
|
+
SacInputEmailComponent,
|
|
1144
|
+
SacInputIntegerComponent,
|
|
1145
|
+
SacInputPasswordComponent,
|
|
1146
|
+
SacInputSearchComponent,
|
|
1147
|
+
],
|
|
1148
|
+
imports: [
|
|
1149
|
+
CommonModule,
|
|
1150
|
+
CommonModule,
|
|
1151
|
+
FormsModule,
|
|
1152
|
+
SACBootstrap3TooltipModule,
|
|
1153
|
+
SACBootstrap3LayoutModule,
|
|
1154
|
+
],
|
|
1155
|
+
exports: [
|
|
1156
|
+
SacInputComponent,
|
|
1157
|
+
SacInputAreaComponent,
|
|
1158
|
+
SacInputCurrencyComponent,
|
|
1159
|
+
SacInputDecimalComponent,
|
|
1160
|
+
SacInputEmailComponent,
|
|
1161
|
+
SacInputIntegerComponent,
|
|
1162
|
+
SacInputPasswordComponent,
|
|
1163
|
+
SacInputSearchComponent,
|
|
1164
|
+
],
|
|
1165
|
+
},] }
|
|
1166
|
+
];
|
|
1167
|
+
|
|
1168
|
+
// #region Classes
|
|
1169
|
+
class SacDropdownComponent extends SacDropdownCommon {
|
|
1170
|
+
// #region Constructors
|
|
1171
|
+
/**
|
|
1172
|
+
* Constructor
|
|
1173
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
1174
|
+
* @param injector Injector for injecting services
|
|
1175
|
+
* @param renderer Angular rendering engine
|
|
1176
|
+
* @param elementRef Reference to html dom element
|
|
1177
|
+
*/
|
|
1178
|
+
constructor(formLayout, injector, renderer, elementRef) {
|
|
1179
|
+
super(formLayout, injector, renderer, elementRef);
|
|
1180
|
+
}
|
|
1181
|
+
}
|
|
1182
|
+
SacDropdownComponent.decorators = [
|
|
1183
|
+
{ type: Component, args: [{
|
|
1184
|
+
selector: 'sac-dropdown',
|
|
1185
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <select\r\n #dropdownitem\r\n id=\"{{name}}\"\r\n name=\"{{name}}\"\r\n class=\"form-control\"\r\n [ngClass]=\"[componentHeight | toControlHeight]\"\r\n (blur)=\"onTouch()\"\r\n (change)=\"setValue(dropdownitem.value)\"\r\n [disabled]=\"isdisabled\"\r\n >\r\n <option *ngIf=\"emptylabel !== ''\" [ngValue]=\"emptyvalue\">\r\n {{emptylabel}}\r\n </option>\r\n\r\n <ng-content></ng-content>\r\n\r\n <ng-container *ngIf=\"groupitems === ''\">\r\n <option\r\n *ngFor=\"let item of options\"\r\n [ngValue]=\"optionvalue ? item[optionvalue] : item\"\r\n [disabled]=\"optionenabled !== '' && item[optionenabled] === false\"\r\n >\r\n <ng-template\r\n *ngTemplateOutlet=\"optionlabeltemplate || defaultItemLabelTemplate;context:{ label: item[optionlabel], item: item }\"\r\n >\r\n </ng-template>\r\n </option>\r\n </ng-container>\r\n\r\n <ng-container *ngIf=\"groupitems !== ''\">\r\n <optgroup\r\n *ngFor=\"let group of options\"\r\n [attr.label]=\"group[grouplabel]\"\r\n >\r\n <option\r\n *ngFor=\"let item of group[groupitems]\"\r\n [ngValue]=\"optionvalue ? item[optionvalue] : item\"\r\n [disabled]=\"optionenabled !== '' && item[optionenabled] === false\"\r\n >\r\n <ng-template\r\n *ngTemplateOutlet=\"optionlabeltemplate || defaultItemLabelTemplate;context:{ label: item[optionlabel], item: item }\"\r\n >\r\n </ng-template>\r\n </option>\r\n </optgroup>\r\n </ng-container>\r\n </select>\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n </div>\r\n</div>\r\n\r\n<ng-template #defaultItemLabelTemplate let-label=\"label\">\r\n {{label}}\r\n</ng-template>\r\n",
|
|
1186
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
1187
|
+
providers: [
|
|
1188
|
+
{
|
|
1189
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1190
|
+
multi: true,
|
|
1191
|
+
useExisting: SacDropdownComponent,
|
|
1192
|
+
},
|
|
1193
|
+
{
|
|
1194
|
+
provide: NG_VALIDATORS,
|
|
1195
|
+
multi: true,
|
|
1196
|
+
useExisting: forwardRef(() => SacDropdownComponent),
|
|
1197
|
+
},
|
|
1198
|
+
]
|
|
1199
|
+
},] }
|
|
1200
|
+
];
|
|
1201
|
+
SacDropdownComponent.ctorParameters = () => [
|
|
1202
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
1203
|
+
{ type: Injector },
|
|
1204
|
+
{ type: Renderer2 },
|
|
1205
|
+
{ type: ElementRef }
|
|
1206
|
+
];
|
|
1207
|
+
class SacDropdownOptionDirective extends SacDropdownOptionCommon {
|
|
1208
|
+
// #region Constructors
|
|
1209
|
+
/**
|
|
1210
|
+
* Konstruktor
|
|
1211
|
+
* @param elementRef Referenz auf HTML DOM Element
|
|
1212
|
+
* @param renderer Angular Rendering Engine
|
|
1213
|
+
* @param dropdownList Referenz auf DropDown Komponente
|
|
1214
|
+
*/
|
|
1215
|
+
constructor(elementRef, renderer, dropdownList) {
|
|
1216
|
+
super(elementRef, renderer, dropdownList);
|
|
1217
|
+
}
|
|
1218
|
+
}
|
|
1219
|
+
SacDropdownOptionDirective.decorators = [
|
|
1220
|
+
{ type: Directive, args: [{ selector: 'option,[sacOption]' },] }
|
|
1221
|
+
];
|
|
1222
|
+
SacDropdownOptionDirective.ctorParameters = () => [
|
|
1223
|
+
{ type: ElementRef },
|
|
1224
|
+
{ type: Renderer2 },
|
|
1225
|
+
{ type: SacDropdownComponent, decorators: [{ type: Optional }, { type: Host }] }
|
|
1226
|
+
];
|
|
1227
|
+
// #endregion Classes
|
|
1228
|
+
|
|
1229
|
+
class SacListboxComponent extends SacListboxCommon {
|
|
1230
|
+
// #region Constructors
|
|
1231
|
+
/**
|
|
1232
|
+
* Constructor
|
|
1233
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
1234
|
+
* @param injector Injector for injecting services
|
|
1235
|
+
*/
|
|
1236
|
+
constructor(formLayout, injector) {
|
|
1237
|
+
super(formLayout, injector);
|
|
1238
|
+
}
|
|
1239
|
+
}
|
|
1240
|
+
SacListboxComponent.decorators = [
|
|
1241
|
+
{ type: Component, args: [{
|
|
1242
|
+
selector: 'sac-listbox',
|
|
1243
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <select\r\n multiple\r\n id=\"{{name}}\"\r\n name=\"{{name}}\"\r\n class=\"form-control\"\r\n [ngClass]=\"[componentHeight | toControlHeight]\"\r\n [size]=\"rowsize\"\r\n (blur)=\"onTouch()\"\r\n (change)=\"getSelectedItems($event.target)\"\r\n [disabled]=\"isdisabled\"\r\n >\r\n <ng-content></ng-content>\r\n <ng-container *ngIf=\"groupitems === ''\">\r\n <option\r\n *ngFor=\"let option of options\"\r\n [value]=\"option[optionvalue]\"\r\n [disabled]=\"optionenabled !== '' && option[optionenabled] === false\"\r\n >\r\n <ng-template\r\n *ngTemplateOutlet=\"optionlabeltemplate || defaultItemLabelTemplate;context:{ label: option[optionlabel] }\"\r\n >\r\n </ng-template>\r\n </option>\r\n </ng-container>\r\n <ng-container *ngIf=\"groupitems !== ''\">\r\n <optgroup\r\n *ngFor=\"let option of options\"\r\n [attr.label]=\"option[grouplabel]\"\r\n >\r\n <option\r\n *ngFor=\"let item of option[groupitems]\"\r\n [value]=\"item[optionvalue]\"\r\n [disabled]=\"optionenabled !== '' && item[optionenabled] === false\"\r\n >\r\n <ng-template\r\n *ngTemplateOutlet=\"optionlabeltemplate || defaultItemLabelTemplate;context:{ label: item[optionlabel] }\"\r\n >\r\n </ng-template>\r\n </option>\r\n </optgroup>\r\n </ng-container>\r\n </select>\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n </div>\r\n</div>\r\n\r\n<ng-template #defaultItemLabelTemplate let-label=\"label\">\r\n {{label}}\r\n</ng-template>\r\n",
|
|
1244
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
1245
|
+
providers: [
|
|
1246
|
+
{
|
|
1247
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1248
|
+
multi: true,
|
|
1249
|
+
useExisting: SacListboxComponent,
|
|
1250
|
+
},
|
|
1251
|
+
{
|
|
1252
|
+
provide: NG_VALIDATORS,
|
|
1253
|
+
multi: true,
|
|
1254
|
+
useExisting: forwardRef(() => SacListboxComponent),
|
|
1255
|
+
},
|
|
1256
|
+
]
|
|
1257
|
+
},] }
|
|
1258
|
+
];
|
|
1259
|
+
SacListboxComponent.ctorParameters = () => [
|
|
1260
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
1261
|
+
{ type: Injector }
|
|
1262
|
+
];
|
|
1263
|
+
|
|
1264
|
+
class SACBootstrap3ListModule {
|
|
1265
|
+
}
|
|
1266
|
+
SACBootstrap3ListModule.decorators = [
|
|
1267
|
+
{ type: NgModule, args: [{
|
|
1268
|
+
declarations: [
|
|
1269
|
+
SacDropdownComponent,
|
|
1270
|
+
SacDropdownOptionDirective,
|
|
1271
|
+
SacListboxComponent,
|
|
1272
|
+
],
|
|
1273
|
+
imports: [
|
|
1274
|
+
CommonModule,
|
|
1275
|
+
SACCommonListboxOptionModule,
|
|
1276
|
+
FormsModule,
|
|
1277
|
+
SACBootstrap3LayoutModule,
|
|
1278
|
+
],
|
|
1279
|
+
exports: [
|
|
1280
|
+
SacDropdownComponent,
|
|
1281
|
+
SacDropdownOptionDirective,
|
|
1282
|
+
SacListboxComponent,
|
|
1283
|
+
],
|
|
1284
|
+
},] }
|
|
1285
|
+
];
|
|
1286
|
+
|
|
1287
|
+
/**
|
|
1288
|
+
* Component für einbindung eines beliebigen Controls in die Form Struktur
|
|
1289
|
+
*
|
|
1290
|
+
* @example
|
|
1291
|
+
* <ngStaticFormContainer name='myformcontainer' label="My Custom Form Control" [isrequired]='false'>
|
|
1292
|
+
* <input type="range" class="form-control" />
|
|
1293
|
+
* </ngStaticFormContainer>
|
|
1294
|
+
*
|
|
1295
|
+
* @example
|
|
1296
|
+
* <ngStaticFormContainer name='myformcintainer' label="My Custom Form Control" [isrequired]='false' tooltiptext="Dies ist ein Tooltip Text">
|
|
1297
|
+
* <input type="range" class="form-control" />
|
|
1298
|
+
* </ngStaticFormContainer>
|
|
1299
|
+
*
|
|
1300
|
+
**/
|
|
1301
|
+
class SacStaticFormContainerComponent extends SacStaticFormContainerCommon {
|
|
1302
|
+
// #region Constructors
|
|
1303
|
+
/**
|
|
1304
|
+
* Constructor
|
|
1305
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
1306
|
+
* @param injector Injector for injecting services
|
|
1307
|
+
*/
|
|
1308
|
+
constructor(formLayout, injector) {
|
|
1309
|
+
super(formLayout, injector);
|
|
1310
|
+
}
|
|
1311
|
+
}
|
|
1312
|
+
SacStaticFormContainerComponent.decorators = [
|
|
1313
|
+
{ type: Component, args: [{
|
|
1314
|
+
selector: 'sac-staticformcontainer',
|
|
1315
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <ng-content></ng-content>\r\n <label\r\n for=\"{{name}}\"\r\n class=\"form-label-adaptive form-label-fixed\"\r\n [ngClass]=\"{ 'required': isrequired }\"\r\n *ngIf=\"isAdaptiveLabel && !disablelabel\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
1316
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
1317
|
+
providers: [
|
|
1318
|
+
{
|
|
1319
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1320
|
+
multi: true,
|
|
1321
|
+
useExisting: SacStaticFormContainerComponent,
|
|
1322
|
+
},
|
|
1323
|
+
{
|
|
1324
|
+
provide: NG_VALIDATORS,
|
|
1325
|
+
multi: true,
|
|
1326
|
+
useExisting: forwardRef(() => SacStaticFormContainerComponent),
|
|
1327
|
+
},
|
|
1328
|
+
]
|
|
1329
|
+
},] }
|
|
1330
|
+
];
|
|
1331
|
+
SacStaticFormContainerComponent.ctorParameters = () => [
|
|
1332
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
1333
|
+
{ type: Injector }
|
|
1334
|
+
];
|
|
1335
|
+
|
|
1336
|
+
class SacStaticLabelComponent extends SacStaticLabelCommon {
|
|
1337
|
+
// #region Constructors
|
|
1338
|
+
/**
|
|
1339
|
+
* Constructor
|
|
1340
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
1341
|
+
* @param injector Injector for injecting services
|
|
1342
|
+
*/
|
|
1343
|
+
constructor(formLayout, injector) {
|
|
1344
|
+
super(formLayout, injector);
|
|
1345
|
+
}
|
|
1346
|
+
}
|
|
1347
|
+
SacStaticLabelComponent.decorators = [
|
|
1348
|
+
{ type: Component, args: [{
|
|
1349
|
+
selector: 'sac-staticlabel',
|
|
1350
|
+
template: "<div class=\"row form-group\" [ngClass]=\"componentHeight | toLabelHeight\">\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <div\r\n class=\"form-control-static\"\r\n [style.padding-left.px]=\"0\"\r\n [innerHTML]=\"value\"\r\n ></div>\r\n <label\r\n for=\"{{name}}\"\r\n class=\"col-left control-label\"\r\n *ngIf=\"isAdaptiveLabel && !disablelabel\"\r\n >{{label}}</label\r\n >\r\n </div>\r\n</div>\r\n",
|
|
1351
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
1352
|
+
providers: [
|
|
1353
|
+
{
|
|
1354
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1355
|
+
multi: true,
|
|
1356
|
+
useExisting: SacStaticLabelComponent,
|
|
1357
|
+
},
|
|
1358
|
+
{
|
|
1359
|
+
provide: NG_VALIDATORS,
|
|
1360
|
+
multi: true,
|
|
1361
|
+
useExisting: forwardRef(() => SacStaticLabelComponent),
|
|
1362
|
+
},
|
|
1363
|
+
]
|
|
1364
|
+
},] }
|
|
1365
|
+
];
|
|
1366
|
+
SacStaticLabelComponent.ctorParameters = () => [
|
|
1367
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
1368
|
+
{ type: Injector }
|
|
1369
|
+
];
|
|
1370
|
+
|
|
1371
|
+
class SACBootstrap3StaticLabelModule {
|
|
1372
|
+
}
|
|
1373
|
+
SACBootstrap3StaticLabelModule.decorators = [
|
|
1374
|
+
{ type: NgModule, args: [{
|
|
1375
|
+
declarations: [SacStaticLabelComponent, SacStaticFormContainerComponent],
|
|
1376
|
+
imports: [
|
|
1377
|
+
CommonModule,
|
|
1378
|
+
SACBootstrap3TooltipModule,
|
|
1379
|
+
SACBootstrap3LayoutModule,
|
|
1380
|
+
],
|
|
1381
|
+
exports: [SacStaticLabelComponent, SacStaticFormContainerComponent],
|
|
1382
|
+
},] }
|
|
1383
|
+
];
|
|
1384
|
+
|
|
1385
|
+
class SacTabItemComponent extends SacTabItemCommon {
|
|
1386
|
+
}
|
|
1387
|
+
SacTabItemComponent.decorators = [
|
|
1388
|
+
{ type: Component, args: [{
|
|
1389
|
+
selector: 'sac-tabitem',
|
|
1390
|
+
template: "<div [id]=\"id\" [hidden]=\"unloadwhenhidden === false && active === false\"\r\n *ngIf=\"(unloadwhenhidden === true && active === true) || unloadwhenhidden === false\" class=\"tab-pane\">\r\n <ng-template [ngTemplateOutlet]=\"templateRef\"></ng-template>\r\n</div>\r\n\r\n"
|
|
1391
|
+
},] }
|
|
1392
|
+
];
|
|
1393
|
+
|
|
1394
|
+
class SacTabComponent extends SacTabCommon {
|
|
1395
|
+
tabItems() {
|
|
1396
|
+
return this._tabItems.toArray();
|
|
1397
|
+
}
|
|
1398
|
+
}
|
|
1399
|
+
SacTabComponent.decorators = [
|
|
1400
|
+
{ type: Component, args: [{
|
|
1401
|
+
selector: 'sac-tab',
|
|
1402
|
+
template: "<!-- Nav tabs -->\r\n<div [id]=\"name\" class=\"content-nav-tabs\">\r\n <ul class=\"nav nav-tabs\" role=\"tablist\">\r\n <li\r\n *ngFor=\"let item of _tabItems\"\r\n [ngClass]=\"{ 'active show': item.active, 'disabled': item.disabled }\"\r\n (click)=\"selectTab(item)\"\r\n [ngStyle]=\"{'cursor': item._disabled ? 'not-allowed' : 'pointer'}\"\r\n >\r\n <a [id]=\"GetTabItemButtonId(item._id)\" role=\"tab\">\r\n <ng-template\r\n *ngTemplateOutlet=\"tablabeltemplate || defaultTabLabelTemplate;context:{ label: item.label }\"\r\n >\r\n </ng-template>\r\n </a>\r\n </li>\r\n </ul>\r\n</div>\r\n\r\n<!-- Tab panes -->\r\n<div class=\"tab-content\" style=\"margin-top: 15px\">\r\n <ng-content></ng-content>\r\n</div>\r\n\r\n<ng-template #defaultTabLabelTemplate let-label=\"label\">\r\n {{label}}\r\n</ng-template>\r\n"
|
|
1403
|
+
},] }
|
|
1404
|
+
];
|
|
1405
|
+
SacTabComponent.propDecorators = {
|
|
1406
|
+
_tabItems: [{ type: ContentChildren, args: [SacTabItemComponent,] }]
|
|
1407
|
+
};
|
|
1408
|
+
|
|
1409
|
+
class SACBootstrap3TabsModule {
|
|
1410
|
+
}
|
|
1411
|
+
SACBootstrap3TabsModule.decorators = [
|
|
1412
|
+
{ type: NgModule, args: [{
|
|
1413
|
+
declarations: [SacTabComponent, SacTabItemComponent],
|
|
1414
|
+
imports: [
|
|
1415
|
+
CommonModule
|
|
1416
|
+
],
|
|
1417
|
+
exports: [SacTabComponent, SacTabItemComponent]
|
|
1418
|
+
},] }
|
|
1419
|
+
];
|
|
1420
|
+
|
|
1421
|
+
class SacTinyMceComponent extends SacTinyMceCommon {
|
|
1422
|
+
// #region Constructors
|
|
1423
|
+
/**
|
|
1424
|
+
* Constructor
|
|
1425
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
1426
|
+
* @param injector Injector for injecting services
|
|
1427
|
+
* @param ngZone ngZone to manage external javascripts
|
|
1428
|
+
*/
|
|
1429
|
+
constructor(formLayout, injector, ngZone) {
|
|
1430
|
+
super(formLayout, injector, ngZone);
|
|
1431
|
+
}
|
|
1432
|
+
// #endregion Constructors
|
|
1433
|
+
// #region Public Methods
|
|
1434
|
+
/**
|
|
1435
|
+
* overwrite tinymce defaults
|
|
1436
|
+
* @returns boostrap3 does not support file browser
|
|
1437
|
+
*/
|
|
1438
|
+
overwriteDefaultSettings() {
|
|
1439
|
+
return { file_picker_types: undefined, file_picker_callback: undefined };
|
|
1440
|
+
}
|
|
1441
|
+
}
|
|
1442
|
+
SacTinyMceComponent.decorators = [
|
|
1443
|
+
{ type: Component, args: [{
|
|
1444
|
+
selector: 'sac-tinymce',
|
|
1445
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n >\r\n {{label}}\r\n </label>\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n [class.has-error]=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n <editor\r\n [id]=\"name + '_tinymce'\"\r\n [init]=\"_config\"\r\n [initialValue]=\"value\"\r\n ngModel\r\n [ngModelOptions]=\"{standalone: true}\"\r\n (ngModelChange)=\"setValue($event)\"\r\n (onSaveContent)=\"save($event.event.content)\"\r\n [disabled]=\"disabled\"\r\n [class.is-invalid]=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n ></editor>\r\n <div\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n class=\"help-block\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n </div>\r\n</div>\r\n\r\n<sac-dialog\r\n *ngIf=\"selectdialogvisible\"\r\n [allowesc]=\"false\"\r\n [backdrop]=\"true\"\r\n [(isvisible)]=\"selectdialogvisible\"\r\n title=\"{{ lngResourceService.GetString(validationKeyService.TinyMceFileselectDialogtitle) | async }}\"\r\n size=\"large\"\r\n height=\"500px\"\r\n>\r\n <ng-container dialogbody> </ng-container>\r\n <ng-container dialogfooter>\r\n <sac-button\r\n role=\"primary\"\r\n [name]=\"name + '_modalOk'\"\r\n text=\"{{ lngResourceService.GetString(validationKeyService.TinyMceFileselectOk) | async }}\"\r\n (clicked)=\"setSelectDialogResult()\"\r\n ></sac-button>\r\n <sac-button\r\n [name]=\"name + '_modalClose'\"\r\n text=\"{{ lngResourceService.GetString(validationKeyService.TinyMceFileselectCancel) | async }}\"\r\n (clicked)=\"closeSelectDialog()\"\r\n ></sac-button>\r\n </ng-container>\r\n</sac-dialog>\r\n",
|
|
1446
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
1447
|
+
providers: [
|
|
1448
|
+
{
|
|
1449
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1450
|
+
multi: true,
|
|
1451
|
+
useExisting: SacTinyMceComponent,
|
|
1452
|
+
},
|
|
1453
|
+
{
|
|
1454
|
+
provide: NG_VALIDATORS,
|
|
1455
|
+
useExisting: forwardRef(() => SacTinyMceComponent),
|
|
1456
|
+
multi: true,
|
|
1457
|
+
},
|
|
1458
|
+
]
|
|
1459
|
+
},] }
|
|
1460
|
+
];
|
|
1461
|
+
SacTinyMceComponent.ctorParameters = () => [
|
|
1462
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
1463
|
+
{ type: Injector },
|
|
1464
|
+
{ type: NgZone }
|
|
1465
|
+
];
|
|
1466
|
+
|
|
1467
|
+
class SACBootstrap3TinyMceModule {
|
|
1468
|
+
}
|
|
1469
|
+
SACBootstrap3TinyMceModule.decorators = [
|
|
1470
|
+
{ type: NgModule, args: [{
|
|
1471
|
+
declarations: [SacTinyMceComponent],
|
|
1472
|
+
imports: [
|
|
1473
|
+
CommonModule,
|
|
1474
|
+
FormsModule,
|
|
1475
|
+
EditorModule,
|
|
1476
|
+
SACBootstrap3ButtonModule,
|
|
1477
|
+
SACBootstrap3DialogModule,
|
|
1478
|
+
SACBootstrap3LayoutModule,
|
|
1479
|
+
],
|
|
1480
|
+
exports: [SacTinyMceComponent],
|
|
1481
|
+
},] }
|
|
1482
|
+
];
|
|
1483
|
+
|
|
1484
|
+
class SacTreeViewComponent extends SacTreeViewCommon {
|
|
1485
|
+
}
|
|
1486
|
+
SacTreeViewComponent.decorators = [
|
|
1487
|
+
{ type: Component, args: [{
|
|
1488
|
+
selector: 'sac-treeview',
|
|
1489
|
+
template: "<div class=\"structure panel panel-default\" icon=\"Structure\">\r\n <div class=\"panel-heading\">\r\n <p class=\"panel-title\"><span>{{ name }}</span></p>\r\n </div>\r\n <div class=\"panel-body\">\r\n <div class=\"right\">\r\n <div\r\n class=\"form-submit form-inline\"\r\n style=\"text-align: right; height: 24px\"\r\n >\r\n <a class=\"btn-inline\"\r\n ><i class=\"icon icon-base-expand\" (click)=\"collapseAllNode(false)\"></i\r\n ></a>\r\n <a class=\"btn-inline\"\r\n ><i\r\n class=\"icon icon-base-collapse\"\r\n (click)=\"collapseAllNode(true)\"\r\n ></i\r\n ></a>\r\n </div>\r\n </div>\r\n <div\r\n [id]=\"name\"\r\n class=\"structure-tree single-root jstree jstree-1 jstree-default\"\r\n >\r\n <ul\r\n class=\"jstree-container-ul jstree-children jstree-no-dots jstree-striped jstree-wholerow-ul\"\r\n *ngIf=\"nodes && nodes.length\"\r\n >\r\n <li\r\n *ngFor=\"let node of nodes; let last = last\"\r\n class=\"jstree-node\"\r\n [ngClass]=\"{\r\n 'jstree-open': !node[collapseAttr] && node[childrenAttr] && node[childrenAttr].length,\r\n 'jstree-closed': node[collapseAttr] && node[childrenAttr] && node[childrenAttr].length,\r\n 'jstree-leaf': !node[childrenAttr].length,\r\n 'jstree-last': last\r\n }\"\r\n [id]=\"node[idAttr]\"\r\n >\r\n <div\r\n unselectable=\"on\"\r\n role=\"presentation\"\r\n class=\"jstree-wholerow\"\r\n (mouseover)=\"node.hover=true\"\r\n (mouseout)=\"node.hover=false\"\r\n [ngClass]=\"{'jstree-wholerow-clicked': node === selectedNode, 'jstree-wholerow-hovered': node.hover}\"\r\n >\r\n \r\n </div>\r\n\r\n <i\r\n class=\"jstree-icon jstree-ocl\"\r\n role=\"presentation\"\r\n (click)=\"onCollapseClick(node)\"\r\n (mouseover)=\"node.hover=true\"\r\n (mouseout)=\"node.hover=false\"\r\n ></i>\r\n\r\n <a\r\n class=\"jstree-anchor\"\r\n (click)=\"onClick(node)\"\r\n [ngClass]=\"{'jstree-clicked': node === selectedNode, 'jstreehovered': node.hover}\"\r\n (mouseover)=\"node.hover=true\"\r\n (mouseout)=\"node.hover=false\"\r\n >\r\n <ng-container\r\n *ngTemplateOutlet=\"treefileicon; context { item: node }\"\r\n ;\r\n content\r\n ></ng-container>\r\n\r\n <span>{{node[textAttr]}}</span>\r\n </a>\r\n\r\n <ng-container\r\n *ngTemplateOutlet=\"template; context { item: node }\"\r\n ;\r\n content\r\n ></ng-container>\r\n\r\n <sac-treeviewchild\r\n *ngIf=\"node[childrenAttr] && node[childrenAttr].length\"\r\n [fileicontemplate]=\"fileicontemplate\"\r\n [template]=\"template\"\r\n [collapseall]=\"collapseall\"\r\n [ngClass]=\"(node[collapseAttr]===true)?'collapse':'show'\"\r\n [data]=\"node[childrenAttr]\"\r\n [idAttr]=\"idAttr\"\r\n [parentAttr]=\"parentAttr\"\r\n [textAttr]=\"textAttr\"\r\n [prepareData]=\"false\"\r\n (onselecteditem)=\"sendMsgToParent($event)\"\r\n [(selectedid)]=\"selectedid\"\r\n >\r\n </sac-treeviewchild>\r\n </li>\r\n </ul>\r\n </div>\r\n </div>\r\n</div>\r\n"
|
|
1490
|
+
},] }
|
|
1491
|
+
];
|
|
1492
|
+
|
|
1493
|
+
class SacTreeViewChildComponent extends SacTreeViewChildCommon {
|
|
1494
|
+
}
|
|
1495
|
+
SacTreeViewChildComponent.decorators = [
|
|
1496
|
+
{ type: Component, args: [{
|
|
1497
|
+
selector: 'sac-treeviewchild',
|
|
1498
|
+
template: "<ul class=\"jstree-children\" *ngIf=\"nodes && nodes.length\">\r\n <li\r\n *ngFor=\"let node of nodes; let last = last\"\r\n class=\"jstree-node\"\r\n [ngClass]=\"{\r\n 'jstree-open': !node[collapseAttr] && node[childrenAttr] && node[childrenAttr].length,\r\n 'jstree-closed': node[collapseAttr] && node[childrenAttr] && node[childrenAttr].length,\r\n 'jstree-leaf': !node[childrenAttr].length,\r\n 'jstree-last': last\r\n }\"\r\n [id]=\"node[idAttr]\"\r\n >\r\n <div\r\n unselectable=\"on\"\r\n role=\"presentation\"\r\n class=\"jstree-wholerow\"\r\n (mouseover)=\"node.hover=true\"\r\n (mouseout)=\"node.hover=false\"\r\n [ngClass]=\"{'jstree-wholerow-clicked': node === selectedNode, 'jstree-wholerow-hovered': node.hover}\"\r\n >\r\n \r\n </div>\r\n\r\n <i\r\n class=\"jstree-icon jstree-ocl\"\r\n role=\"presentation\"\r\n (click)=\"onCollapseClick(node)\"\r\n (mouseover)=\"node.hover=true\"\r\n (mouseout)=\"node.hover=false\"\r\n ></i>\r\n\r\n <a\r\n class=\"jstree-anchor\"\r\n (click)=\"onClick(node)\"\r\n [ngClass]=\"{'jstree-clicked': node === selectedNode, 'jstreehovered': node.hover}\"\r\n (mouseover)=\"node.hover=true\"\r\n (mouseout)=\"node.hover=false\"\r\n >\r\n <ng-container\r\n *ngTemplateOutlet=\"treefileicon; context { item: node }\"\r\n ;\r\n content\r\n ></ng-container>\r\n\r\n {{node[textAttr]}}\r\n </a>\r\n\r\n <ng-container\r\n *ngTemplateOutlet=\"template; context { item: node }\"\r\n ></ng-container>\r\n\r\n <sac-treeviewchild\r\n *ngIf=\"node[childrenAttr] && node[childrenAttr].length\"\r\n [fileicontemplate]=\"fileicontemplate\"\r\n [template]=\"template\"\r\n [collapseall]=\"collapseall\"\r\n [ngClass]=\"(node[collapseAttr]===true)?'collapse':'show'\"\r\n [data]=\"node[childrenAttr]\"\r\n [idAttr]=\"idAttr\"\r\n [parentAttr]=\"parentAttr\"\r\n [textAttr]=\"textAttr\"\r\n [prepareData]=\"false\"\r\n (onselecteditem)=\"sendMsgToParent($event)\"\r\n [(selectedid)]=\"selectedid\"\r\n >\r\n </sac-treeviewchild>\r\n </li>\r\n</ul>\r\n"
|
|
1499
|
+
},] }
|
|
1500
|
+
];
|
|
1501
|
+
|
|
1502
|
+
class SacTreeItemActionComponent extends SacTreeItemActionCommon {
|
|
1503
|
+
constructor(el) {
|
|
1504
|
+
super(el);
|
|
1505
|
+
}
|
|
1506
|
+
}
|
|
1507
|
+
SacTreeItemActionComponent.decorators = [
|
|
1508
|
+
{ type: Component, args: [{
|
|
1509
|
+
selector: 'sac-treeitemaction',
|
|
1510
|
+
template: "<i class=\"{{transformClass(iconstyle)}}\" (mouseover)=\"item.hover=true\" (mouseout)=\"item.hover=false\" (click)=\"iconaction()\" ></i>"
|
|
1511
|
+
},] }
|
|
1512
|
+
];
|
|
1513
|
+
SacTreeItemActionComponent.ctorParameters = () => [
|
|
1514
|
+
{ type: ElementRef }
|
|
1515
|
+
];
|
|
1516
|
+
|
|
1517
|
+
class SACBootstrap3TtreeviewModule {
|
|
1518
|
+
}
|
|
1519
|
+
SACBootstrap3TtreeviewModule.decorators = [
|
|
1520
|
+
{ type: NgModule, args: [{
|
|
1521
|
+
declarations: [SacTreeViewComponent, SacTreeViewChildComponent, SacTreeItemActionComponent],
|
|
1522
|
+
imports: [
|
|
1523
|
+
CommonModule
|
|
1524
|
+
],
|
|
1525
|
+
exports: [SacTreeViewComponent, SacTreeViewChildComponent, SacTreeItemActionComponent]
|
|
1526
|
+
},] }
|
|
1527
|
+
];
|
|
1528
|
+
|
|
1529
|
+
// https://github.com/kukhariev/ngx-uploadx/
|
|
1530
|
+
class SacUploadComponent extends SacUploadSingleCommon {
|
|
1531
|
+
// #region Constructors
|
|
1532
|
+
/**
|
|
1533
|
+
* Constructor
|
|
1534
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
1535
|
+
* @param injector Injector for injecting services
|
|
1536
|
+
* @param renderer Angular rendering engine
|
|
1537
|
+
* @param ngZone ngZone to manage external javascripts
|
|
1538
|
+
*/
|
|
1539
|
+
constructor(formLayout, injector, renderer, ngZone) {
|
|
1540
|
+
super(formLayout, injector, renderer, ngZone);
|
|
1541
|
+
}
|
|
1542
|
+
}
|
|
1543
|
+
SacUploadComponent.decorators = [
|
|
1544
|
+
{ type: Component, args: [{
|
|
1545
|
+
selector: 'sac-upload',
|
|
1546
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <div\r\n class=\"input-group upload-component upload-single\"\r\n [class.input-group-sm]=\"componentHeight === ControlHeight.Small\"\r\n [class.input-group-lg]=\"componentHeight === ControlHeight.Large\"\r\n >\r\n <div class=\"input-group-btn\">\r\n <!-- image-preview-input -->\r\n <div\r\n class=\"btn upload-input custom-file\"\r\n [class.disabled]=\"HasQueueItem()\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <i [class]=\"IconBrowse\"></i>\r\n <span class=\"upload-browse\"\r\n >{{\r\n lngResourceService.GetString(validationKeyService.UploadButtonBrowse)\r\n | async }}</span\r\n >\r\n <input\r\n type=\"file\"\r\n class=\"custom-file-input\"\r\n #files\r\n (click)=\"files.value = ''\"\r\n (uploadxState)=\"onUpload($event)\"\r\n multiple\r\n [disabled]=\"HasQueueItem()\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"form-control upload-progress\">\r\n <div class=\"progress\">\r\n <div\r\n class=\"progress-bar\"\r\n [class.progress-bar-success]=\"Progress()===100\"\r\n role=\"progressbar\"\r\n [attr.aria-valuenow]=\"Progress()\"\r\n aria-valuemin=\"0\"\r\n aria-valuemax=\"100\"\r\n [style.width.%]=\"Progress()\"\r\n >\r\n <span class=\"progress-text text-dark\"\r\n >{{ Filename() | async }}</span\r\n >\r\n </div>\r\n </div>\r\n </div>\r\n <!-- <input type=\"textimage-preview-filename\" class=\"form-control image-preview-filename\" disabled=\"disabled\"> --><!-- don't give a name === doesn't send on POST/GET -->\r\n <div class=\"input-group-btn\">\r\n <!-- image-preview-clear button -->\r\n <a\r\n class=\"btn\"\r\n (click)=\"cancelAll()\"\r\n [attr.disabled]=\"HasQueueItem() === false ? 'disabled' : null\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <span [class]=\"IconDelete\"></span>\r\n </a>\r\n <a\r\n *ngIf=\"(autoupload === false && enablepause) || (autoupload && enablepause && IsPaused() === false)\"\r\n class=\"btn\"\r\n (click)=\"pauseAll()\"\r\n [attr.disabled]=\"IsUploading() === false ? 'disabled' : null\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <span [class]=\"IconPause\"></span>\r\n </a>\r\n <a\r\n *ngIf=\"autoupload && enablepause && IsPaused()\"\r\n class=\"btn\"\r\n (click)=\"uploadAll()\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <span [class]=\"IconContinue\"></span>\r\n </a>\r\n <a\r\n *ngIf=\"autoupload === false\"\r\n class=\"btn\"\r\n (click)=\"uploadAll()\"\r\n [attr.disabled]=\"IsStateToUpload() === false ? 'disabled' : null\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <span [class]=\"IconUpload\"></span> {{\r\n lngResourceService.GetString(validationKeyService.UploadButtonUpload)\r\n | async }}\r\n </a>\r\n </div>\r\n </div>\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
1547
|
+
providers: [
|
|
1548
|
+
{
|
|
1549
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1550
|
+
multi: true,
|
|
1551
|
+
useExisting: SacUploadComponent,
|
|
1552
|
+
},
|
|
1553
|
+
{
|
|
1554
|
+
provide: NG_VALIDATORS,
|
|
1555
|
+
multi: true,
|
|
1556
|
+
useExisting: forwardRef(() => SacUploadComponent),
|
|
1557
|
+
},
|
|
1558
|
+
],
|
|
1559
|
+
styles: [".upload-component .upload-input{position:relative}.upload-component .custom-file>i{margin-right:15px}.upload-component .custom-file .custom-file-input{bottom:0;display:inline-block;left:0;margin:0;opacity:0;overflow:hidden;position:absolute;right:0;top:0;width:100%;z-index:2}.upload-component.upload-multiple .upload-progress .progress{border-bottom-right-radius:0;border-top-right-radius:0}.upload-component.upload-single .upload-progress .progress{border-radius:0}.upload-component .upload-progress{padding:0}.upload-component .upload-progress .progress{height:100%}.upload-component .upload-progress .progress .progress-text{color:#000;display:table-cell;height:34px;left:0;line-height:34px;position:absolute;right:0;top:50%;transform:translateY(-50%)}"]
|
|
1560
|
+
},] }
|
|
1561
|
+
];
|
|
1562
|
+
SacUploadComponent.ctorParameters = () => [
|
|
1563
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
1564
|
+
{ type: Injector },
|
|
1565
|
+
{ type: Renderer2 },
|
|
1566
|
+
{ type: NgZone }
|
|
1567
|
+
];
|
|
1568
|
+
|
|
1569
|
+
// https://github.com/kukhariev/ngx-uploadx/
|
|
1570
|
+
class SacUploadMultipleComponent extends SacUploadMultipleCommon {
|
|
1571
|
+
// #region Constructors
|
|
1572
|
+
/**
|
|
1573
|
+
* Constructor
|
|
1574
|
+
* @param formLayout SacFormLayout to define scoped layout settings
|
|
1575
|
+
* @param injector Injector for injecting services
|
|
1576
|
+
* @param renderer Angular rendering engine
|
|
1577
|
+
* @param ngZone ngZone to manage external javascripts
|
|
1578
|
+
*/
|
|
1579
|
+
constructor(formLayout, injector, renderer, ngZone) {
|
|
1580
|
+
super(formLayout, injector, renderer, ngZone);
|
|
1581
|
+
}
|
|
1582
|
+
}
|
|
1583
|
+
SacUploadMultipleComponent.decorators = [
|
|
1584
|
+
{ type: Component, args: [{
|
|
1585
|
+
selector: 'sac-uploadmultiple',
|
|
1586
|
+
template: "<div\r\n class=\"row form-group\"\r\n [class.has-error]=\"invalid && (dirty || touched)\"\r\n [ngClass]=\"componentHeight | toLabelHeight\"\r\n>\r\n <label\r\n *ngIf=\"disablelabel === false && !isAdaptiveLabel\"\r\n id=\"{{name}}label\"\r\n for=\"{{name}}\"\r\n class=\"col-xs-12 control-label\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toLabelWidthCss) : 'sr-only' ]\"\r\n [class.required]=\"isrequired\"\r\n >{{label}}</label\r\n >\r\n <div\r\n class=\"col-xs-12\"\r\n [ngClass]=\"[disablelabel === false ? (this.labelSizes | toControlWidthCss) : '']\"\r\n >\r\n <div class=\"upload-component\">\r\n <div class=\"row\">\r\n <div class=\"col-xs-12\">\r\n <div\r\n class=\"btn-group\"\r\n [class.btn-group-sm]=\"componentHeight === ControlHeight.Small\"\r\n [class.btn-group-lg]=\"componentHeight === ControlHeight.Large\"\r\n >\r\n <div\r\n class=\"btn upload-input custom-file\"\r\n [class.disabled]=\"maxfiles > 0 && uploads.length >= maxfiles\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <i [class]=\"IconBrowse\"></i>\r\n <span class=\"upload-browse\">Browse</span>\r\n <input\r\n type=\"file\"\r\n class=\"custom-file-input\"\r\n #files\r\n (click)=\"files.value = ''\"\r\n (uploadxState)=\"onUpload($event)\"\r\n multiple\r\n [disabled]=\"maxfiles > 0 && uploads.length >= maxfiles\"\r\n />\r\n </div>\r\n\r\n <div\r\n class=\"btn-group\"\r\n [class.btn-group-sm]=\"componentHeight === ControlHeight.Small\"\r\n [class.btn-group-lg]=\"componentHeight === ControlHeight.Large\"\r\n >\r\n <!-- image-preview-clear button -->\r\n <a\r\n class=\"btn\"\r\n (click)=\"cancelAll()\"\r\n [attr.disabled]=\"HasQueueItem() === false ? 'disabled' : null\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <span [class]=\"IconDelete\"></span>\r\n </a>\r\n <a\r\n *ngIf=\"(autoupload === false && enablepause) || (autoupload && enablepause && IsPaused() === false)\"\r\n class=\"btn\"\r\n (click)=\"pauseAll()\"\r\n [attr.disabled]=\"IsUploading() === false ? 'disabled' : null\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <span [class]=\"IconPause\"></span>\r\n </a>\r\n <a\r\n *ngIf=\"autoupload && enablepause && IsPaused() === true\"\r\n class=\"btn\"\r\n (click)=\"uploadAll()\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <span [class]=\"IconContinue\"></span>\r\n </a>\r\n <a\r\n *ngIf=\"autoupload === false\"\r\n class=\"btn\"\r\n (click)=\"uploadAll()\"\r\n [attr.disabled]=\"IsStateToUpload() === false ? 'disabled' : null\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <span [class]=\"IconUpload\"></span> {{\r\n lngResourceService.GetString(validationKeyService.UploadButtonUpload)\r\n | async }}\r\n </a>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <div *ngFor=\"let file of uploads\" style=\"margin-top: 5px\">\r\n <div\r\n class=\"input-group upload-component upload-multiple\"\r\n [class.input-group-sm]=\"componentHeight === ControlHeight.Small\"\r\n [class.input-group-lg]=\"componentHeight === ControlHeight.Large\"\r\n >\r\n <div class=\"form-control upload-progress\">\r\n <div class=\"progress\">\r\n <div\r\n class=\"progress-bar\"\r\n [class.progress-bar-success]=\"file.progress===100\"\r\n role=\"progressbar\"\r\n [attr.aria-valuenow]=\"file.progress\"\r\n aria-valuemin=\"0\"\r\n aria-valuemax=\"100\"\r\n [style.width.%]=\"file.progress\"\r\n >\r\n <span class=\"progress-text text-dark\">{{ file.name }}</span>\r\n </div>\r\n </div>\r\n </div>\r\n <div\r\n class=\"input-group-btn\"\r\n [class.input-group-sm]=\"componentHeight === ControlHeight.Small\"\r\n [class.input-group-lg]=\"componentHeight === ControlHeight.Large\"\r\n >\r\n <!-- image-preview-clear button -->\r\n <a\r\n class=\"btn\"\r\n (click)=\"cancel(file.uploadId)\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <span [class]=\"IconDelete\"></span>\r\n </a>\r\n <a\r\n *ngIf=\"(autoupload === false && enablepause) || (autoupload && enablepause && file.status !== 'paused')\"\r\n class=\"btn\"\r\n (click)=\"pause(file.uploadId)\"\r\n [attr.disabled]=\"file.status !== 'uploading' ? 'disabled' : null\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <span [class]=\"IconPause\"></span>\r\n </a>\r\n <a\r\n *ngIf=\"autoupload && enablepause && file.status === 'paused'\"\r\n class=\"btn\"\r\n (click)=\"upload(file.uploadId)\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <span [class]=\"IconContinue\"></span>\r\n </a>\r\n <a\r\n *ngIf=\"autoupload === false\"\r\n class=\"btn\"\r\n (click)=\"upload(file.uploadId)\"\r\n [attr.disabled]=\"file.status !== 'added' && file.status !== 'paused' ? 'disabled' : null\"\r\n [class.btn-default]=\"!(invalid && (dirty || touched))\"\r\n [class.btn-danger]=\"invalid && (dirty || touched)\"\r\n >\r\n <span [class]=\"IconUpload\"></span> {{\r\n lngResourceService.GetString(validationKeyService.UploadButtonUpload)\r\n | async }}\r\n </a>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n <div\r\n class=\"help-block help-block-error\"\r\n *ngIf=\"isinlineerrorenabled && invalid && (dirty || touched)\"\r\n >\r\n {{ GetErrorMessage() | async }}\r\n </div>\r\n </div>\r\n</div>\r\n",
|
|
1587
|
+
providers: [
|
|
1588
|
+
{
|
|
1589
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1590
|
+
multi: true,
|
|
1591
|
+
useExisting: SacUploadMultipleComponent,
|
|
1592
|
+
},
|
|
1593
|
+
{
|
|
1594
|
+
provide: NG_VALIDATORS,
|
|
1595
|
+
multi: true,
|
|
1596
|
+
useExisting: forwardRef(() => SacUploadMultipleComponent),
|
|
1597
|
+
},
|
|
1598
|
+
],
|
|
1599
|
+
styles: [".upload-component .upload-input{position:relative}.upload-component .custom-file>i{margin-right:15px}.upload-component .custom-file .custom-file-input{bottom:0;display:inline-block;left:0;margin:0;opacity:0;overflow:hidden;position:absolute;right:0;top:0;width:100%;z-index:2}.upload-component.upload-multiple .upload-progress .progress{border-bottom-right-radius:0;border-top-right-radius:0}.upload-component.upload-single .upload-progress .progress{border-radius:0}.upload-component .upload-progress{padding:0}.upload-component .upload-progress .progress{height:100%}.upload-component .upload-progress .progress .progress-text{color:#000;display:table-cell;height:34px;left:0;line-height:34px;position:absolute;right:0;top:50%;transform:translateY(-50%)}"]
|
|
1600
|
+
},] }
|
|
1601
|
+
];
|
|
1602
|
+
SacUploadMultipleComponent.ctorParameters = () => [
|
|
1603
|
+
{ type: SacFormLayoutDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
1604
|
+
{ type: Injector },
|
|
1605
|
+
{ type: Renderer2 },
|
|
1606
|
+
{ type: NgZone }
|
|
1607
|
+
];
|
|
1608
|
+
|
|
1609
|
+
class SACBootstrap3UploadModule {
|
|
1610
|
+
}
|
|
1611
|
+
SACBootstrap3UploadModule.decorators = [
|
|
1612
|
+
{ type: NgModule, args: [{
|
|
1613
|
+
declarations: [SacUploadComponent, SacUploadMultipleComponent],
|
|
1614
|
+
imports: [CommonModule, FormsModule, SACBootstrap3LayoutModule],
|
|
1615
|
+
exports: [SacUploadComponent, SacUploadMultipleComponent],
|
|
1616
|
+
},] }
|
|
1617
|
+
];
|
|
1618
|
+
|
|
1619
|
+
/**
|
|
1620
|
+
* Erweiterung / Hooking für automatismen in Formular. Wird als Container für alle Controls benötigt.
|
|
1621
|
+
*
|
|
1622
|
+
* @example Beispiel über Div Container
|
|
1623
|
+
*
|
|
1624
|
+
* <div ngForm></div>
|
|
1625
|
+
*
|
|
1626
|
+
* @example Beispiel über Form Tag
|
|
1627
|
+
*
|
|
1628
|
+
* <form></form>
|
|
1629
|
+
*/
|
|
1630
|
+
/* eslint @angular-eslint/directive-selector: 0 */
|
|
1631
|
+
class SacFormDirective extends SacFormCommon {
|
|
1632
|
+
// #endregion Properties
|
|
1633
|
+
// #region Constructors
|
|
1634
|
+
/**
|
|
1635
|
+
* Konstruktor
|
|
1636
|
+
* @param form Instanz von NgForm für eigene automatische Formular Logik
|
|
1637
|
+
*/
|
|
1638
|
+
constructor(form) {
|
|
1639
|
+
super(form);
|
|
1640
|
+
// #region Properties
|
|
1641
|
+
/**
|
|
1642
|
+
* Sets the standard CSS class for forms on the form container
|
|
1643
|
+
*/
|
|
1644
|
+
this.cssClassForm = true;
|
|
1645
|
+
/**
|
|
1646
|
+
* Sets the default CSS class for horizontal forms on the form container
|
|
1647
|
+
*/
|
|
1648
|
+
this.cssClassHorizontal = true;
|
|
1649
|
+
}
|
|
1650
|
+
}
|
|
1651
|
+
SacFormDirective.decorators = [
|
|
1652
|
+
{ type: Directive, args: [{
|
|
1653
|
+
selector: 'form:not([ngNoForm]):not([formGroup]),[ngForm]',
|
|
1654
|
+
exportAs: 'sacform',
|
|
1655
|
+
},] }
|
|
1656
|
+
];
|
|
1657
|
+
SacFormDirective.ctorParameters = () => [
|
|
1658
|
+
{ type: NgForm }
|
|
1659
|
+
];
|
|
1660
|
+
SacFormDirective.propDecorators = {
|
|
1661
|
+
cssClassForm: [{ type: HostBinding, args: ['class.form',] }],
|
|
1662
|
+
cssClassHorizontal: [{ type: HostBinding, args: ['class.form-horizontal',] }]
|
|
1663
|
+
};
|
|
1664
|
+
|
|
1665
|
+
class SacValidationSummaryComponent extends SacValidationSummaryCommon {
|
|
1666
|
+
// #region Constructors
|
|
1667
|
+
/**
|
|
1668
|
+
* Constructor
|
|
1669
|
+
* @param formControl Instance of Form Component to receive invalid form controls
|
|
1670
|
+
* @param injector Injector for injecting services
|
|
1671
|
+
*/
|
|
1672
|
+
constructor(formControl, injector) {
|
|
1673
|
+
super(formControl, injector);
|
|
1674
|
+
}
|
|
1675
|
+
}
|
|
1676
|
+
SacValidationSummaryComponent.decorators = [
|
|
1677
|
+
{ type: Component, args: [{
|
|
1678
|
+
selector: 'sac-validationsummary',
|
|
1679
|
+
template: "<div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"hasErrors\" [id]=\"name\">\r\n <ul>\r\n <li *ngFor=\"let error of formErrors\">\r\n {{error | async}}\r\n </li>\r\n </ul>\r\n</div>\r\n",
|
|
1680
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
1681
|
+
providers: [
|
|
1682
|
+
{
|
|
1683
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1684
|
+
multi: true,
|
|
1685
|
+
useExisting: SacValidationSummaryComponent,
|
|
1686
|
+
},
|
|
1687
|
+
]
|
|
1688
|
+
},] }
|
|
1689
|
+
];
|
|
1690
|
+
SacValidationSummaryComponent.ctorParameters = () => [
|
|
1691
|
+
{ type: SacFormDirective, decorators: [{ type: Host }, { type: Optional }] },
|
|
1692
|
+
{ type: Injector }
|
|
1693
|
+
];
|
|
1694
|
+
|
|
1695
|
+
class SACBootstrap3ValidationSummaryModule {
|
|
1696
|
+
}
|
|
1697
|
+
SACBootstrap3ValidationSummaryModule.decorators = [
|
|
1698
|
+
{ type: NgModule, args: [{
|
|
1699
|
+
declarations: [SacValidationSummaryComponent],
|
|
1700
|
+
imports: [
|
|
1701
|
+
CommonModule
|
|
1702
|
+
],
|
|
1703
|
+
exports: [SacValidationSummaryComponent]
|
|
1704
|
+
},] }
|
|
1705
|
+
];
|
|
1706
|
+
|
|
1707
|
+
class SacWizardItemComponent extends SacWizardItemCommon {
|
|
1708
|
+
}
|
|
1709
|
+
SacWizardItemComponent.decorators = [
|
|
1710
|
+
{ type: Component, args: [{
|
|
1711
|
+
selector: 'sac-wizarditem',
|
|
1712
|
+
template: ""
|
|
1713
|
+
},] }
|
|
1714
|
+
];
|
|
1715
|
+
|
|
1716
|
+
class SacWizardComponent extends SacWizardCommon {
|
|
1717
|
+
wizardItems() {
|
|
1718
|
+
return this._wizardItems;
|
|
1719
|
+
}
|
|
1720
|
+
}
|
|
1721
|
+
SacWizardComponent.decorators = [
|
|
1722
|
+
{ type: Component, args: [{
|
|
1723
|
+
selector: 'sac-wizard',
|
|
1724
|
+
template: "<ul [id]=\"name\" class=\"nav nav-wizard\" role=\"tablist\">\r\n <li *ngFor=\"let item of _wizardItems\" class=\"nav-item\" [ngClass]=\"{ 'active': item._active, 'disabled': item._disabled, 'success': item._iscomplete }\"\r\n [ngStyle]=\"{'cursor': item._disabled ? 'not-allowed' : 'pointer'}\">\r\n <a role=\"tab\" (click)=\"selectStep(item)\">\r\n <div class=\"circle\">\r\n <span class=\"step\"></span>\r\n </div>\r\n </a>\r\n <div class=\"info\">\r\n <a (click)=\"selectStep(item)\">{{item.label}}</a>\r\n </div>\r\n </li>\r\n</ul>\r\n",
|
|
1725
|
+
// Value Access Provider registrieren, damit Wert via Model geschrieben und gelesen werden kann
|
|
1726
|
+
providers: [
|
|
1727
|
+
{ provide: NG_VALUE_ACCESSOR, multi: true, useExisting: SacWizardComponent }
|
|
1728
|
+
]
|
|
1729
|
+
},] }
|
|
1730
|
+
];
|
|
1731
|
+
SacWizardComponent.propDecorators = {
|
|
1732
|
+
_wizardItems: [{ type: ContentChildren, args: [SacWizardItemComponent,] }]
|
|
1733
|
+
};
|
|
1734
|
+
|
|
1735
|
+
class SACBootstrap3WizardModule {
|
|
1736
|
+
}
|
|
1737
|
+
SACBootstrap3WizardModule.decorators = [
|
|
1738
|
+
{ type: NgModule, args: [{
|
|
1739
|
+
declarations: [SacWizardComponent, SacWizardItemComponent],
|
|
1740
|
+
imports: [
|
|
1741
|
+
CommonModule
|
|
1742
|
+
],
|
|
1743
|
+
exports: [SacWizardComponent, SacWizardItemComponent]
|
|
1744
|
+
},] }
|
|
1745
|
+
];
|
|
1746
|
+
|
|
1747
|
+
/**
|
|
1748
|
+
* Factory Methode für SacForm
|
|
1749
|
+
* @param form NgFormular
|
|
1750
|
+
*/
|
|
1751
|
+
function SACFORM_FACTORY(form) {
|
|
1752
|
+
return form;
|
|
1753
|
+
}
|
|
1754
|
+
/**
|
|
1755
|
+
* Factory Methode für NgForm
|
|
1756
|
+
* @param form NgForm
|
|
1757
|
+
*/
|
|
1758
|
+
function NGFORM_FACTORY(form) {
|
|
1759
|
+
return form;
|
|
1760
|
+
}
|
|
1761
|
+
/**
|
|
1762
|
+
* Directive zum erben eines NgForm/NgFormular einer übergeordneten Komponente
|
|
1763
|
+
*
|
|
1764
|
+
* @example Implementation in Markup
|
|
1765
|
+
*
|
|
1766
|
+
* <div sacInheritForm>
|
|
1767
|
+
* </div>
|
|
1768
|
+
*
|
|
1769
|
+
* @example Model an Sub-Komponente übergeben
|
|
1770
|
+
*
|
|
1771
|
+
* <div sacInheritForm>
|
|
1772
|
+
* <div>SubForm</div>
|
|
1773
|
+
* <div>
|
|
1774
|
+
* <ngInput [(ngModel)]="mymodel.fieldarea2" name="subformField3" label="field 3" [isrequired]="true"></ngInput>
|
|
1775
|
+
* </div>
|
|
1776
|
+
* </div>
|
|
1777
|
+
*
|
|
1778
|
+
*
|
|
1779
|
+
* (at)Component({
|
|
1780
|
+
* selector: 'sacInheritForm',
|
|
1781
|
+
* templateUrl: './subform.component.html'
|
|
1782
|
+
* })
|
|
1783
|
+
* export class SubFormComponent implements DoCheck {
|
|
1784
|
+
*
|
|
1785
|
+
* (at)Input() mymodel;
|
|
1786
|
+
* (at)Output() mymodelChange = new EventEmitter();
|
|
1787
|
+
*
|
|
1788
|
+
* ngDoCheck() {
|
|
1789
|
+
* this.mymodelChange.next(this.mymodel);
|
|
1790
|
+
* }
|
|
1791
|
+
*}
|
|
1792
|
+
*
|
|
1793
|
+
*/
|
|
1794
|
+
class SacInheritFormDirective {
|
|
1795
|
+
}
|
|
1796
|
+
SacInheritFormDirective.decorators = [
|
|
1797
|
+
{ type: Directive, args: [{
|
|
1798
|
+
selector: '[sacInheritForm]',
|
|
1799
|
+
providers: [
|
|
1800
|
+
{
|
|
1801
|
+
provide: SacFormDirective,
|
|
1802
|
+
useFactory: SACFORM_FACTORY,
|
|
1803
|
+
deps: [[new SkipSelf(), SacFormDirective]]
|
|
1804
|
+
}, {
|
|
1805
|
+
provide: ControlContainer,
|
|
1806
|
+
useFactory: NGFORM_FACTORY,
|
|
1807
|
+
deps: [NgForm]
|
|
1808
|
+
}
|
|
1809
|
+
]
|
|
1810
|
+
},] }
|
|
1811
|
+
];
|
|
1812
|
+
|
|
1813
|
+
class SACBootstrap3FormModule {
|
|
1814
|
+
}
|
|
1815
|
+
SACBootstrap3FormModule.decorators = [
|
|
1816
|
+
{ type: NgModule, args: [{
|
|
1817
|
+
declarations: [SacFormDirective, SacInheritFormDirective],
|
|
1818
|
+
imports: [CommonModule, FormsModule],
|
|
1819
|
+
exports: [SacFormDirective, SacInheritFormDirective],
|
|
1820
|
+
},] }
|
|
1821
|
+
];
|
|
1822
|
+
|
|
1823
|
+
/*
|
|
1824
|
+
* Public API Surface of sac-bootstrap3
|
|
1825
|
+
*/
|
|
1826
|
+
|
|
1827
|
+
/**
|
|
1828
|
+
* Generated bundle index. Do not edit.
|
|
1829
|
+
*/
|
|
1830
|
+
|
|
1831
|
+
export { NGFORM_FACTORY, SACBootstrap3ButtonModule, SACBootstrap3CheckboxModule, SACBootstrap3ConfirmModule, SACBootstrap3DateTimeModule, SACBootstrap3DialogModule, SACBootstrap3FormModule, SACBootstrap3GridModule, SACBootstrap3InputModule, SACBootstrap3LayoutModule, SACBootstrap3ListModule, SACBootstrap3StaticLabelModule, SACBootstrap3TabsModule, SACBootstrap3TinyMceModule, SACBootstrap3TooltipModule, SACBootstrap3TtreeviewModule, SACBootstrap3UploadModule, SACBootstrap3ValidationSummaryModule, SACBootstrap3WizardModule, SACFORM_FACTORY, SacButtonComponent, SacCheckboxComponent, SacConfirmComponent, SacDateComponent, SacDateSelectorComponent, SacDateTimeComponent, SacDialogComponent, SacDropdownComponent, SacDropdownOptionDirective, SacFormDirective, SacFormLayoutDirective, SacGridButtonComponent, SacGridColumnActionComponent, SacGridColumnComponent, SacGridComponent, SacGridImageComponent, SacInheritFormDirective, SacInputAreaComponent, SacInputComponent, SacInputCurrencyComponent, SacInputDecimalComponent, SacInputEmailComponent, SacInputIntegerComponent, SacInputPasswordComponent, SacInputSearchComponent, SacListboxComponent, SacPagingComponent, SacRadiobuttonComponent, SacRadiobuttonsComponent, SacStaticFormContainerComponent, SacStaticLabelComponent, SacTabComponent, SacTabItemComponent, SacTimeComponent, SacTinyMceComponent, SacToControlHeightPipe, SacToControlWidthCssPipe, SacToLabelHeightPipe, SacToLabelWidthCssPipe, SacTooltipComponent, SacTreeItemActionComponent, SacTreeViewChildComponent, SacTreeViewComponent, SacUploadComponent, SacUploadMultipleComponent, SacValidationSummaryComponent, SacWizardComponent, SacWizardItemComponent, ServiceConfirm };
|
|
1832
|
+
//# sourceMappingURL=simpleangularcontrols-sac-bootstrap3.js.map
|