@coolon/angular-ui-powerups 1.20.0 → 2.0.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +21 -0
- package/bundles/coolon-angular-ui-powerups.umd.js +82 -47
- package/bundles/coolon-angular-ui-powerups.umd.js.map +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.min.js +2 -2
- package/bundles/coolon-angular-ui-powerups.umd.min.js.map +1 -1
- package/coolon-angular-ui-powerups.metadata.json +1 -1
- package/esm2015/lib/components/components.module.js +3 -1
- package/esm2015/lib/components/components.module.js.map +1 -1
- package/esm2015/lib/components/components.module.metadata.json +1 -1
- package/esm2015/lib/components/components.module.ngfactory.js.map +1 -1
- package/esm2015/lib/components/forms/abstract-list-input.component.js +3 -3
- package/esm2015/lib/components/forms/abstract-list-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/abstract-value-input.component.js +3 -3
- package/esm2015/lib/components/forms/abstract-value-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/checkbox-input/checkbox-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/multiple-select-input/multiple-select-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/number-input/number-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/password-input/password-input.component.js +1 -1
- package/esm2015/lib/components/forms/password-input/password-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/password-input/password-input.component.metadata.json +1 -1
- package/esm2015/lib/components/forms/select-input/select-input.component.js +3 -3
- package/esm2015/lib/components/forms/select-input/select-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/string-input/string-input.component.js.map +1 -1
- package/esm2015/lib/components/forms/string-input/string-input.component.metadata.json +1 -1
- package/esm2015/lib/components/forms/text-input/text-input.component.js.map +1 -1
- package/esm2015/lib/components/icon/icon.component.js +21 -23
- package/esm2015/lib/components/icon/icon.component.js.map +1 -1
- package/esm2015/lib/components/icon/icon.component.metadata.json +1 -1
- package/esm2015/lib/components/table/cell-editors.js.map +1 -1
- package/esm2015/lib/components/table/column-model.js.map +1 -1
- package/esm2015/lib/components/table/column-model.metadata.json +1 -1
- package/esm2015/lib/components/table/edit-row-controls/edit-row-controls.component.js.map +1 -1
- package/esm2015/lib/components/table/edit-session.js.map +1 -1
- package/esm2015/lib/components/table/edit-session.metadata.json +1 -1
- package/esm2015/lib/components/table/table-model.js +24 -4
- package/esm2015/lib/components/table/table-model.js.map +1 -1
- package/esm2015/lib/components/table/table-model.metadata.json +1 -1
- package/esm2015/lib/components/table/table.component.js +1 -1
- package/esm2015/lib/components/table/table.component.js.map +1 -1
- package/esm2015/lib/components/table/table.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/add-item-interaction-context/add-item-interaction-context.component.js +10 -1
- package/esm2015/lib/interaction/components/add-item-interaction-context/add-item-interaction-context.component.js.map +1 -1
- package/esm2015/lib/interaction/components/add-item-interaction-context/add-item-interaction-context.component.metadata.json +1 -1
- package/esm2015/lib/interaction/components/input-activities/abstract-input-activity.js +2 -2
- package/esm2015/lib/interaction/components/input-activities/abstract-input-activity.js.map +1 -1
- package/esm2015/lib/interaction/components/input-activities/input-activity-data.js.map +1 -1
- package/esm2015/lib/place/components/side-place-navigation/side-place-navigation.component.js +1 -1
- package/esm2015/lib/place/components/side-place-navigation/side-place-navigation.component.js.map +1 -1
- package/esm2015/lib/place/components/side-place-navigation/side-place-navigation.component.metadata.json +1 -1
- package/esm2015/lib/place/place.module.ngfactory.js.map +1 -1
- package/esm5/lib/components/components.module.js +3 -1
- package/esm5/lib/components/components.module.js.map +1 -1
- package/esm5/lib/components/components.module.ngfactory.js.map +1 -1
- package/esm5/lib/components/forms/abstract-list-input.component.js +3 -3
- package/esm5/lib/components/forms/abstract-list-input.component.js.map +1 -1
- package/esm5/lib/components/forms/abstract-value-input.component.js +3 -3
- package/esm5/lib/components/forms/abstract-value-input.component.js.map +1 -1
- package/esm5/lib/components/forms/checkbox-input/checkbox-input.component.js.map +1 -1
- package/esm5/lib/components/forms/multiple-select-input/multiple-select-input.component.js.map +1 -1
- package/esm5/lib/components/forms/number-input/number-input.component.js.map +1 -1
- package/esm5/lib/components/forms/password-input/password-input.component.js +1 -1
- package/esm5/lib/components/forms/password-input/password-input.component.js.map +1 -1
- package/esm5/lib/components/forms/select-input/select-input.component.js +3 -3
- package/esm5/lib/components/forms/select-input/select-input.component.js.map +1 -1
- package/esm5/lib/components/forms/string-input/string-input.component.js.map +1 -1
- package/esm5/lib/components/forms/text-input/text-input.component.js.map +1 -1
- package/esm5/lib/components/icon/icon.component.js +30 -27
- package/esm5/lib/components/icon/icon.component.js.map +1 -1
- package/esm5/lib/components/table/cell-editors.js.map +1 -1
- package/esm5/lib/components/table/column-model.js.map +1 -1
- package/esm5/lib/components/table/edit-row-controls/edit-row-controls.component.js.map +1 -1
- package/esm5/lib/components/table/edit-session.js.map +1 -1
- package/esm5/lib/components/table/table-model.js +26 -4
- package/esm5/lib/components/table/table-model.js.map +1 -1
- package/esm5/lib/components/table/table.component.js +1 -1
- package/esm5/lib/components/table/table.component.js.map +1 -1
- package/esm5/lib/interaction/components/add-item-interaction-context/add-item-interaction-context.component.js +10 -1
- package/esm5/lib/interaction/components/add-item-interaction-context/add-item-interaction-context.component.js.map +1 -1
- package/esm5/lib/interaction/components/input-activities/abstract-input-activity.js +2 -2
- package/esm5/lib/interaction/components/input-activities/abstract-input-activity.js.map +1 -1
- package/esm5/lib/interaction/components/input-activities/input-activity-data.js.map +1 -1
- package/esm5/lib/place/components/side-place-navigation/side-place-navigation.component.js +1 -1
- package/esm5/lib/place/components/side-place-navigation/side-place-navigation.component.js.map +1 -1
- package/esm5/lib/place/place.module.ngfactory.js.map +1 -1
- package/fesm2015/coolon-angular-ui-powerups.js +69 -41
- package/fesm2015/coolon-angular-ui-powerups.js.map +1 -1
- package/fesm5/coolon-angular-ui-powerups.js +80 -45
- package/fesm5/coolon-angular-ui-powerups.js.map +1 -1
- package/lib/components/forms/abstract-list-input.component.d.ts +3 -3
- package/lib/components/forms/abstract-value-input.component.d.ts +3 -3
- package/lib/components/forms/checkbox-input/checkbox-input.component.d.ts +2 -2
- package/lib/components/forms/multiple-select-input/multiple-select-input.component.d.ts +2 -2
- package/lib/components/forms/number-input/number-input.component.d.ts +2 -2
- package/lib/components/forms/password-input/password-input.component.d.ts +2 -2
- package/lib/components/forms/select-input/select-input.component.d.ts +2 -2
- package/lib/components/forms/string-input/string-input.component.d.ts +2 -2
- package/lib/components/forms/text-input/text-input.component.d.ts +2 -2
- package/lib/components/icon/icon.component.d.ts +6 -7
- package/lib/components/table/cell-editors.d.ts +3 -3
- package/lib/components/table/column-model.d.ts +2 -2
- package/lib/components/table/edit-row-controls/edit-row-controls.component.d.ts +2 -2
- package/lib/components/table/edit-session.d.ts +4 -4
- package/lib/components/table/table-model.d.ts +8 -5
- package/lib/interaction/components/add-item-interaction-context/add-item-interaction-context.component.d.ts +9 -0
- package/lib/interaction/components/input-activities/abstract-input-activity.d.ts +2 -2
- package/lib/interaction/components/input-activities/input-activity-data.d.ts +2 -2
- package/package.json +1 -1
|
@@ -13,13 +13,14 @@ import { MatButtonModule } from '@angular/material/button';
|
|
|
13
13
|
import { MatCheckboxModule } from '@angular/material/checkbox';
|
|
14
14
|
import { MatIconModule } from '@angular/material/icon';
|
|
15
15
|
import { MatTableModule } from '@angular/material/table';
|
|
16
|
-
import { DelegatingValueModel, assert, UnaryCommand, lang, Dsl, GarbageCollector, Logger, TrackExternal, Command, FocusManager,
|
|
16
|
+
import { DelegatingValueModel, assert, UnaryCommand, lang, Dsl, GarbageCollector, Logger, TrackExternal, Command, FocusManager, Form, ListModel, StoreInListModel, ValueModel, StoreInValueModel, MutableValueModel, MultipleSelectionModel, MutableListModel, DirtyTrackingForm, DelegatingCommand, Deferred, Trace, Guard, DebugContext, Binding, Functions } from '@coolon/pectin';
|
|
17
17
|
import { assert as assert$1, Opts, lang as lang$1, Klass } from '@coolon/typescript-utilities';
|
|
18
18
|
import { Memoize } from '@typescript-plus/fast-memoize-decorator/dist/src';
|
|
19
19
|
import ___default, { isEqual, isNil } from 'lodash';
|
|
20
20
|
import produce from 'immer';
|
|
21
21
|
import { FaIconLibrary, FontAwesomeModule } from '@fortawesome/angular-fontawesome';
|
|
22
22
|
import { fas } from '@fortawesome/free-solid-svg-icons';
|
|
23
|
+
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
23
24
|
import { FlexModule, GridModule } from '@angular/flex-layout';
|
|
24
25
|
import { MatDialogModule, MatDialog, MatDialogConfig, MAT_DIALOG_DEFAULT_OPTIONS } from '@angular/material/dialog';
|
|
25
26
|
import { RouterModule, UrlSegment, Router, UrlSerializer, NavigationStart, NavigationEnd, NavigationError, NavigationCancel, RouterOutlet } from '@angular/router';
|
|
@@ -27,7 +28,6 @@ import { Overlay, CdkScrollable } from '@angular/cdk/overlay';
|
|
|
27
28
|
import ResizeObserver from 'resize-observer-polyfill';
|
|
28
29
|
import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
|
29
30
|
import { MatListModule } from '@angular/material/list';
|
|
30
|
-
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
31
31
|
import { Memoize as Memoize$1 } from '@typescript-plus/fast-memoize-decorator';
|
|
32
32
|
import 'reflect-metadata';
|
|
33
33
|
import { style, query, group, animate, trigger, transition } from '@angular/animations';
|
|
@@ -688,14 +688,14 @@ var AbstractListInputComponent = /** @class */ (function (_super) {
|
|
|
688
688
|
* A backing model for all our @Input() valueModel properties which should be defined as follows.
|
|
689
689
|
*
|
|
690
690
|
* @Input() @TrackExternal({useExisting: "inputModel"})
|
|
691
|
-
* valueModel:
|
|
691
|
+
* valueModel: Form.ListModelBase<string> | IMutableListModel<string>;
|
|
692
692
|
*
|
|
693
693
|
* This approach allows the input to accept plain or form models but all backed by a form
|
|
694
694
|
* friendly delegate. We have to use an existing delegate for union types as pectin just
|
|
695
695
|
* gets told it's an Object and can't scan for a base type annotated with @DelegateUsing(..).
|
|
696
696
|
*/
|
|
697
697
|
// We have to register it as a disposable so it ditches any listeners when we're disposed.
|
|
698
|
-
_this.inputModel = _this.registerDisposable(new
|
|
698
|
+
_this.inputModel = _this.registerDisposable(new Form.DelegatingListModel());
|
|
699
699
|
return _this;
|
|
700
700
|
}
|
|
701
701
|
AbstractListInputComponent = __decorate([
|
|
@@ -712,14 +712,14 @@ var AbstractValueInputComponent = /** @class */ (function (_super) {
|
|
|
712
712
|
* A backing model for all our @Input() valueModel properties which should be defined as follows.
|
|
713
713
|
*
|
|
714
714
|
* @Input() @TrackExternal({useExisting: "inputModel"})
|
|
715
|
-
* valueModel:
|
|
715
|
+
* valueModel: DirtyTrackingForm.ValueModel<string> | IMutableValueModel<string>;
|
|
716
716
|
*
|
|
717
717
|
* This approach allows the input to accept plain or form models but all backed by a form
|
|
718
718
|
* friendly delegate. We have to use an existing delegate for union types as pectin just
|
|
719
719
|
* gets told it's an Object and can't scan for a base type annotated with @DelegateUsing(..).
|
|
720
720
|
*/
|
|
721
721
|
// We have to register it as a disposable so it ditches any listeners when we're disposed.
|
|
722
|
-
_this.inputModel = _this.registerDisposable(new
|
|
722
|
+
_this.inputModel = _this.registerDisposable(new Form.DelegatingValueModel());
|
|
723
723
|
return _this;
|
|
724
724
|
}
|
|
725
725
|
AbstractValueInputComponent = __decorate([
|
|
@@ -802,7 +802,7 @@ var PasswordInputComponent = /** @class */ (function (_super) {
|
|
|
802
802
|
PasswordInputComponent.prototype.ngOnInit = function () {
|
|
803
803
|
};
|
|
804
804
|
__decorate([
|
|
805
|
-
Input(), TrackExternal({ delegateTo:
|
|
805
|
+
Input(), TrackExternal({ delegateTo: 'inputModel' }),
|
|
806
806
|
__metadata("design:type", Object)
|
|
807
807
|
], PasswordInputComponent.prototype, "valueModel", void 0);
|
|
808
808
|
PasswordInputComponent = __decorate([
|
|
@@ -826,7 +826,7 @@ var SelectInputComponent = /** @class */ (function (_super) {
|
|
|
826
826
|
SelectInputComponent.prototype.ngOnInit = function () {
|
|
827
827
|
};
|
|
828
828
|
__decorate([
|
|
829
|
-
Input(), TrackExternal({ delegateTo:
|
|
829
|
+
Input(), TrackExternal({ delegateTo: 'inputModel' }),
|
|
830
830
|
__metadata("design:type", Object)
|
|
831
831
|
], SelectInputComponent.prototype, "valueModel", void 0);
|
|
832
832
|
__decorate([
|
|
@@ -846,11 +846,11 @@ var SelectInputComponent = /** @class */ (function (_super) {
|
|
|
846
846
|
__metadata("design:type", Boolean)
|
|
847
847
|
], SelectInputComponent.prototype, "allowNil", void 0);
|
|
848
848
|
__decorate([
|
|
849
|
-
ContentChild(
|
|
849
|
+
ContentChild('optionTemplate'),
|
|
850
850
|
__metadata("design:type", TemplateRef)
|
|
851
851
|
], SelectInputComponent.prototype, "optionTemplateRef", void 0);
|
|
852
852
|
__decorate([
|
|
853
|
-
ContentChild(
|
|
853
|
+
ContentChild('nilOptionTemplate'),
|
|
854
854
|
__metadata("design:type", TemplateRef)
|
|
855
855
|
], SelectInputComponent.prototype, "nilOptionTemplateRef", void 0);
|
|
856
856
|
__decorate([
|
|
@@ -1679,6 +1679,13 @@ var SelectionColumnModel = /** @class */ (function (_super) {
|
|
|
1679
1679
|
|
|
1680
1680
|
// export type StringPropertiesOf<T> = { [K in keyof T]: T[K] extends string ? K : never }[keyof T];
|
|
1681
1681
|
// export type NumberPropertiesOf<T> = { [K in keyof T]: T[K] extends number ? K : never }[keyof T];
|
|
1682
|
+
var RowClass = /** @class */ (function () {
|
|
1683
|
+
function RowClass(className, matches) {
|
|
1684
|
+
this.className = className;
|
|
1685
|
+
this.matches = matches;
|
|
1686
|
+
}
|
|
1687
|
+
return RowClass;
|
|
1688
|
+
}());
|
|
1682
1689
|
/**
|
|
1683
1690
|
* Example:
|
|
1684
1691
|
* @example
|
|
@@ -1699,7 +1706,7 @@ var SelectionColumnModel = /** @class */ (function (_super) {
|
|
|
1699
1706
|
* }
|
|
1700
1707
|
* const colorsNames: ListModel<string> = ...;
|
|
1701
1708
|
* const model = TableModel.fromList(heroList, table => {
|
|
1702
|
-
* table.pluck("firstName").cellEditor(StringInputComponent); <-- interface CellEditor { valueModel:
|
|
1709
|
+
* table.pluck("firstName").cellEditor(StringInputComponent); <-- interface CellEditor { valueModel: DirtyTrackingForm.ValueModel<string> | ValueModel<string>; }
|
|
1703
1710
|
* table.pluck("lastName").cellEditor(StringInputComponent, {
|
|
1704
1711
|
* validators: [Validator.present("We need a last name")]
|
|
1705
1712
|
* });
|
|
@@ -1728,7 +1735,7 @@ var SelectionColumnModel = /** @class */ (function (_super) {
|
|
|
1728
1735
|
* // configure your component with what ever you need.
|
|
1729
1736
|
* });
|
|
1730
1737
|
* .cellRenderer(CellRendererComponent) // <-- interface CellEditor { value: string; }
|
|
1731
|
-
* .cellEditor(CellEditorComponent.); // <-- interface CellEditor { valueModel:
|
|
1738
|
+
* .cellEditor(CellEditorComponent.); // <-- interface CellEditor { valueModel: DirtyTrackingForm.ValueModel<string> | ValueModel<string>; }
|
|
1732
1739
|
* table.addCustomColumn("fullName", hero => `${hero.firstName} ${hero.lastName}`);
|
|
1733
1740
|
* });
|
|
1734
1741
|
*
|
|
@@ -1751,11 +1758,13 @@ var SelectionColumnModel = /** @class */ (function (_super) {
|
|
|
1751
1758
|
*/
|
|
1752
1759
|
var TableModel = /** @class */ (function () {
|
|
1753
1760
|
function TableModel(sourceOfTruth) {
|
|
1761
|
+
var _this = this;
|
|
1754
1762
|
this.sourceOfTruth = sourceOfTruth;
|
|
1755
1763
|
this._garbage = new GarbageCollector();
|
|
1756
1764
|
this._columns = new MutableListModel();
|
|
1757
1765
|
this._editorSessions = new MutableListModel();
|
|
1758
|
-
this.
|
|
1766
|
+
this.rowClassNamePredicates = [];
|
|
1767
|
+
this._createForm = function (row) { return new DirtyTrackingForm(); };
|
|
1759
1768
|
this.identityOf = sourceOfTruth.identityOf;
|
|
1760
1769
|
var _a = Dsl.disposeWith(this._garbage), chain = _a.chain, valueOf = _a.valueOf, before = _a.before, when = _a.when, after = _a.after, observe = _a.observe, switchOn = _a.switchOn;
|
|
1761
1770
|
this._columnsById = chain(this._columns).indexBy('columnId');
|
|
@@ -1767,6 +1776,7 @@ var TableModel = /** @class */ (function () {
|
|
|
1767
1776
|
this.dataSource = chain(this.sourceOfTruth).replaceAll(this.rowsBeingEdited);
|
|
1768
1777
|
this.firstEditableColumn = chain(this.columns).select(function (c) { return c.hasEditorPortal(); }).first();
|
|
1769
1778
|
this.hasColumnsWithRowSelectionExplicitlyEnabled = chain(this._columns).findIndex(function (column) { return column.isRowSelectionExplicitlyEnabled(); }).isGreaterThanOrEqualTo(0);
|
|
1779
|
+
this.addRowClass("enable-hover", function () { return _this.isRowSelectionEnabled(); });
|
|
1770
1780
|
}
|
|
1771
1781
|
TableModel_1 = TableModel;
|
|
1772
1782
|
TableModel.fromList = function (sourceOfTruth, builder) {
|
|
@@ -1815,6 +1825,18 @@ var TableModel = /** @class */ (function () {
|
|
|
1815
1825
|
TableModel.prototype.addTemplateColumn = function (columnId) {
|
|
1816
1826
|
return this.addColumn(new CustomTemplateColumnModel(columnId, this));
|
|
1817
1827
|
};
|
|
1828
|
+
TableModel.prototype.addRowClass = function (className, predicate) {
|
|
1829
|
+
this.rowClassNamePredicates.push(new RowClass(className, predicate));
|
|
1830
|
+
};
|
|
1831
|
+
TableModel.prototype.getRowClasses = function (row) {
|
|
1832
|
+
var classNames = [];
|
|
1833
|
+
this.rowClassNamePredicates.forEach(function (i) {
|
|
1834
|
+
if (i.matches(row)) {
|
|
1835
|
+
classNames.push(i.className);
|
|
1836
|
+
}
|
|
1837
|
+
});
|
|
1838
|
+
return classNames;
|
|
1839
|
+
};
|
|
1818
1840
|
TableModel.prototype.useFormFactory = function (factory) {
|
|
1819
1841
|
this._createForm = factory;
|
|
1820
1842
|
return this;
|
|
@@ -1951,7 +1973,7 @@ var TableComponent = /** @class */ (function (_super) {
|
|
|
1951
1973
|
TableComponent = __decorate([
|
|
1952
1974
|
Component({
|
|
1953
1975
|
selector: 'aup-table',
|
|
1954
|
-
template: "<table mat-table [dataSource]=\"tableModel.dataSource.value\" [trackBy]=\"tableModel.getTrackByFunction()\">\n\n <ng-container *ngFor=\"let column of columns.value; index as index; first as first; last as last\" matColumnDef=\"{{column.columnId}}\">\n <th mat-header-cell *matHeaderCellDef>\n <aup-table-header-cell-renderer [column]=\"column\"\n [attr.column-index]=\"index\"\n [class.first-column]=\"first\"\n [class.last-column]=\"last\"\n ></aup-table-header-cell-renderer>\n </th>\n <td mat-cell *matCellDef=\"let row\" (click)=\"onCellClicked(column, row)\" [class.enable-cursor]=\"tableModel.isRowSelectionEnabledFor(column)\">\n <aup-table-cell-renderer [column]=\"column\"\n [row]=\"row\"\n [tableModel]=\"tableModel\"\n [editSession]=\"tableModel.getEditSessionFor(row)\"\n [attr.column-index]=\"index\"\n [class.first-column]=\"first\"\n [class.last-column]=\"last\"\n ></aup-table-cell-renderer>\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef=\"columnIds.value\"></tr>\n <tr mat-row *matRowDef=\"let row; columns: columnIds.value;\"
|
|
1976
|
+
template: "<table mat-table [dataSource]=\"tableModel.dataSource.value\" [trackBy]=\"tableModel.getTrackByFunction()\">\n\n <ng-container *ngFor=\"let column of columns.value; index as index; first as first; last as last\" matColumnDef=\"{{column.columnId}}\">\n <th mat-header-cell *matHeaderCellDef>\n <aup-table-header-cell-renderer [column]=\"column\"\n [attr.column-index]=\"index\"\n [class.first-column]=\"first\"\n [class.last-column]=\"last\"\n ></aup-table-header-cell-renderer>\n </th>\n <td mat-cell *matCellDef=\"let row\" (click)=\"onCellClicked(column, row)\" [class.enable-cursor]=\"tableModel.isRowSelectionEnabledFor(column)\">\n <aup-table-cell-renderer [column]=\"column\"\n [row]=\"row\"\n [tableModel]=\"tableModel\"\n [editSession]=\"tableModel.getEditSessionFor(row)\"\n [attr.column-index]=\"index\"\n [class.first-column]=\"first\"\n [class.last-column]=\"last\"\n ></aup-table-cell-renderer>\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef=\"columnIds.value\"></tr>\n <tr mat-row *matRowDef=\"let row; columns: columnIds.value;\"\n [ngClass]=\"tableModel.getRowClasses(row)\"\n ></tr>\n\n</table>\n",
|
|
1955
1977
|
styles: [":host{display:flex;flex-direction:column;align-items:stretch}:host table{flex:1}"]
|
|
1956
1978
|
}),
|
|
1957
1979
|
__metadata("design:paramtypes", [])
|
|
@@ -2274,38 +2296,41 @@ var MultipleSelectInputComponent = /** @class */ (function (_super) {
|
|
|
2274
2296
|
var IconComponent = /** @class */ (function () {
|
|
2275
2297
|
function IconComponent() {
|
|
2276
2298
|
}
|
|
2277
|
-
IconComponent.prototype
|
|
2278
|
-
|
|
2279
|
-
return this.
|
|
2280
|
-
}
|
|
2281
|
-
|
|
2282
|
-
|
|
2283
|
-
|
|
2284
|
-
|
|
2285
|
-
|
|
2286
|
-
|
|
2287
|
-
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
|
|
2291
|
-
|
|
2292
|
-
|
|
2293
|
-
|
|
2294
|
-
|
|
2295
|
-
|
|
2296
|
-
|
|
2297
|
-
|
|
2299
|
+
Object.defineProperty(IconComponent.prototype, "icon", {
|
|
2300
|
+
get: function () {
|
|
2301
|
+
return this._icon;
|
|
2302
|
+
},
|
|
2303
|
+
set: function (iconName) {
|
|
2304
|
+
this._icon = iconName;
|
|
2305
|
+
if (!iconName) {
|
|
2306
|
+
this.errorMessage = 'icon is nil';
|
|
2307
|
+
this.prefix = undefined;
|
|
2308
|
+
return;
|
|
2309
|
+
}
|
|
2310
|
+
var colonIndex = iconName.indexOf(':');
|
|
2311
|
+
if (colonIndex > 0) {
|
|
2312
|
+
this.prefix = this.icon.slice(0, colonIndex);
|
|
2313
|
+
this.suffix = this.icon.slice(colonIndex + 1);
|
|
2314
|
+
}
|
|
2315
|
+
if (this.prefix) {
|
|
2316
|
+
this.errorMessage = "Unknown icon \"" + iconName + "\"";
|
|
2317
|
+
}
|
|
2318
|
+
this.errorMessage = "Unknown icon prefix \"" + this.prefix + "\"";
|
|
2319
|
+
},
|
|
2320
|
+
enumerable: true,
|
|
2321
|
+
configurable: true
|
|
2322
|
+
});
|
|
2298
2323
|
__decorate([
|
|
2299
2324
|
Input(),
|
|
2300
|
-
__metadata("design:type", String)
|
|
2301
|
-
|
|
2325
|
+
__metadata("design:type", String),
|
|
2326
|
+
__metadata("design:paramtypes", [String])
|
|
2327
|
+
], IconComponent.prototype, "icon", null);
|
|
2302
2328
|
IconComponent = __decorate([
|
|
2303
2329
|
Component({
|
|
2304
2330
|
selector: 'aup-icon',
|
|
2305
|
-
template: "<mat-icon *
|
|
2306
|
-
styles: [":host{display:inline-flex;width:24px}fa-icon{
|
|
2307
|
-
})
|
|
2308
|
-
__metadata("design:paramtypes", [])
|
|
2331
|
+
template: "<ng-container [ngSwitch]=\"prefix\">\n\n <mat-icon *ngSwitchCase=\"'svg'\"\n [svgIcon]=\"suffix\"\n class=\"svgIcon\">\n </mat-icon>\n\n <mat-icon *ngSwitchCase=\"'mat'\">\n {{suffix}}\n </mat-icon>\n\n <div *ngSwitchCase=\"'fab'\"\n class=\"faIconWrapper\">\n <fa-icon [icon]=\"suffix\">\n </fa-icon>\n </div>\n\n <mat-icon *ngSwitchDefault\n [matTooltip]=\"errorMessage\">\n bug_report\n </mat-icon>\n\n</ng-container>\n\n",
|
|
2332
|
+
styles: [":host{display:inline-flex;width:24px}fa-icon{vertical-align:middle}.faIconWrapper{text-align:center;width:24px;height:24px}.svgIcon{width:24px;height:24px}:host(.mat-chip-remove) mat-icon{font-size:18px}mat-icon{width:inherit;height:inherit}"]
|
|
2333
|
+
})
|
|
2309
2334
|
], IconComponent);
|
|
2310
2335
|
return IconComponent;
|
|
2311
2336
|
}());
|
|
@@ -2366,7 +2391,8 @@ var ComponentsModule = /** @class */ (function () {
|
|
|
2366
2391
|
MatTableModule,
|
|
2367
2392
|
PortalModule,
|
|
2368
2393
|
CdkScrollableModule,
|
|
2369
|
-
FontAwesomeModule
|
|
2394
|
+
FontAwesomeModule,
|
|
2395
|
+
MatTooltipModule
|
|
2370
2396
|
],
|
|
2371
2397
|
exports: [
|
|
2372
2398
|
NumberInputComponent,
|
|
@@ -3259,6 +3285,15 @@ var InPlaceInteractionContextComponent = /** @class */ (function (_super) {
|
|
|
3259
3285
|
return InPlaceInteractionContextComponent;
|
|
3260
3286
|
}(DisposableComponent));
|
|
3261
3287
|
|
|
3288
|
+
/**
|
|
3289
|
+
* Css Vars.
|
|
3290
|
+
* --link-color
|
|
3291
|
+
* --link-color-hover
|
|
3292
|
+
* --link-background
|
|
3293
|
+
* --link-background-hover
|
|
3294
|
+
* --link-border-radius
|
|
3295
|
+
* --link-padding
|
|
3296
|
+
*/
|
|
3262
3297
|
var AddItemInteractionContextComponent = /** @class */ (function (_super) {
|
|
3263
3298
|
__extends(AddItemInteractionContextComponent, _super);
|
|
3264
3299
|
function AddItemInteractionContextComponent() {
|
|
@@ -3327,7 +3362,7 @@ var AddItemInteractionContextComponent = /** @class */ (function (_super) {
|
|
|
3327
3362
|
Component({
|
|
3328
3363
|
selector: 'aup-add-item-interaction-context',
|
|
3329
3364
|
template: "<aup-in-place-interaction-context [animateFirstActivity]=\"false\">\n <a part=\"link\" class=\"link\" [pectinCommand]=\"clickCommand\"><aup-icon [icon]=\"icon\"></aup-icon> {{label}}</a>\n</aup-in-place-interaction-context>\n",
|
|
3330
|
-
styles: [":host{--def-link-color:var(--link-color, currentColor);--def-link-color-hover:var(--link-color-hover, currentColor);--def-link-
|
|
3365
|
+
styles: [":host{--def-link-color:var(--link-color, currentColor);--def-link-color-hover:var(--link-color-hover, currentColor);--def-link-background:var(--link-background, transparent);--def-link-background-hover:var(--link-background-hover, rgba(0, 0, 0, 0.05));--def-link-border-radius:var(--link-border-radius, 4px);--def-link-padding:var(--link-padding, calc(var(--aup-default-padding) / 2));display:flex;flex-direction:column;border-radius:var(--def-link-border-radius);box-sizing:border-box;outline:0}:host:hover a.link{color:var(--def-link-color-hover);background-color:var(--def-link-background-hover)}aup-in-place-interaction-context{border-radius:var(--def-link-border-radius)}a.link{display:flex;flex-direction:row;align-items:center;border-radius:var(--def-link-border-radius);color:var(--def-link-color);background:var(--def-link-background);padding:var(--def-link-padding);cursor:pointer;text-decoration:none}a.link mat-icon{margin-right:8px}"]
|
|
3331
3366
|
}),
|
|
3332
3367
|
__metadata("design:paramtypes", [])
|
|
3333
3368
|
], AddItemInteractionContextComponent);
|
|
@@ -3536,7 +3571,7 @@ var AbstractInputActivity = /** @class */ (function (_super) {
|
|
|
3536
3571
|
var _this = _super.call(this) || this;
|
|
3537
3572
|
_this.data = data;
|
|
3538
3573
|
_this.class = 'aup-input-activity';
|
|
3539
|
-
var form = new
|
|
3574
|
+
var form = new DirtyTrackingForm();
|
|
3540
3575
|
_this.valueModel = form.valueModel(_this.data.initialValue);
|
|
3541
3576
|
_this.valueModel.validateUsing(data.validators || []);
|
|
3542
3577
|
_this.confirmCommand = Command.create(function () {
|
|
@@ -6050,7 +6085,7 @@ var SidePlaceNavigationComponent = /** @class */ (function (_super) {
|
|
|
6050
6085
|
SidePlaceNavigationComponent = __decorate([
|
|
6051
6086
|
Component({
|
|
6052
6087
|
selector: 'aup-side-place-navigation',
|
|
6053
|
-
template: "<mat-nav-list>\n <a mat-list-item (click)=\"toggleMenu()\" class=\"home\">\n <aup-icon class=\"collapsed-only\" icon=\"menu\"></aup-icon>\n <aup-icon class=\"expanded-only\" icon=\"arrow_back\"></aup-icon>\n <span class=\"expanded-only\">Menu</span>\n </a>\n <a mat-list-item *ngFor=\"let placeDefinition of placeDefinitions.value\"\n [pectinCommand]=\"commandFactory.create(placeDefinition)\"\n [class.active]=\"isActive(placeDefinition)\"\n [matTooltip]=\"getNav(placeDefinition).tooltip()\">\n <aup-icon *ngIf=\"getNav(placeDefinition).icon()\" [icon]=\"getNav(placeDefinition).icon()\"></aup-icon>\n <span\n class=\"expanded-only\">{{getNav(placeDefinition).title()}}</span>\n </a>\n <span [style.flex]=\"1\"></span>\n <ng-container *ngIf=\"navEndTemplate\" [ngTemplateOutlet]=\"navEndTemplate\"></ng-container>\n</mat-nav-list>\n",
|
|
6088
|
+
template: "<mat-nav-list>\n <a mat-list-item (click)=\"toggleMenu()\" class=\"home\">\n <aup-icon class=\"collapsed-only\" icon=\"mat:menu\"></aup-icon>\n <aup-icon class=\"expanded-only\" icon=\"mat:arrow_back\"></aup-icon>\n <span class=\"expanded-only\">Menu</span>\n </a>\n <a mat-list-item *ngFor=\"let placeDefinition of placeDefinitions.value\"\n [pectinCommand]=\"commandFactory.create(placeDefinition)\"\n [class.active]=\"isActive(placeDefinition)\"\n [matTooltip]=\"getNav(placeDefinition).tooltip()\">\n <aup-icon *ngIf=\"getNav(placeDefinition).icon()\" [icon]=\"getNav(placeDefinition).icon()\"></aup-icon>\n <span\n class=\"expanded-only\">{{getNav(placeDefinition).title()}}</span>\n </a>\n <span [style.flex]=\"1\"></span>\n <ng-container *ngIf=\"navEndTemplate\" [ngTemplateOutlet]=\"navEndTemplate\"></ng-container>\n</mat-nav-list>\n",
|
|
6054
6089
|
styles: [":host{display:flex;flex-direction:column;--resolved-nav-item-width:var(--nav-width, 56px);--resolved-nav-item-height:var(--nav-item-height, var(--resolved-nav-item-width));--resolved-expanded-width:var(--nav-expanded-width, 235px);--resolved-color:var(--nav-color, rgba(255, 255, 255, 0.9));--resolved-background-color:var(--nav-background-color, #555);width:var(--resolved-nav-item-width);transition:width 125ms linear;background-color:var(--resolved-background-color);color:var(--resolved-color)}:host.expanded{width:var(--resolved-expanded-width);max-width:var(--resolved-expanded-width)}:host-context(.expanded) .expanded-only{max-width:100%}:host-context(.expanded) .collapsed-only{max-width:0}:host-context(.expanded) .mat-list-item aup-icon:not(.collapsed-only){margin-right:12px}:host-context(.expanded) .mat-list-item span{text-wrap:none;white-space:nowrap}.expanded-only{max-width:0;overflow:hidden}.collapsed-only{max-width:100%;overflow:hidden}mat-nav-list{flex:1;display:flex;flex-direction:column}.mat-list-item{width:var(--resolved-nav-item-width);height:var(--resolved-nav-item-height);color:inherit}.mat-list-item.active{background-color:#444}.mat-list-item.home{text-align:left}mat-icon{color:inherit}mat-icon.flip-horizontal{transform:scaleX(-1)}"]
|
|
6055
6090
|
}),
|
|
6056
6091
|
__metadata("design:paramtypes", [Router, PlaceRouter])
|