@coolon/angular-ui-powerups 11.0.0-alpha.17 → 11.0.0-alpha.3
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/assets/table.scss +6 -13
- package/bundles/coolon-angular-ui-powerups.umd.js +62 -185
- package/bundles/coolon-angular-ui-powerups.umd.js.map +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.min.js +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.min.js.map +1 -1
- package/coolon-angular-ui-powerups.metadata.json +1 -1
- package/esm2015/lib/angular-ui-powerups.module.ngfactory.js.map +1 -1
- package/esm2015/lib/components/card-container/card-container.component.js +1 -1
- package/esm2015/lib/components/card-container/card-container.component.metadata.json +1 -1
- package/esm2015/lib/components/commands/command/command.component.js +1 -5
- package/esm2015/lib/components/commands/command/command.component.js.map +1 -1
- package/esm2015/lib/components/commands/command/command.component.metadata.json +1 -1
- package/esm2015/lib/components/components.module.js +3 -0
- 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/table/column-model.js +1 -2
- 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/default-cell-renderer/default-cell-renderer.component.js +1 -1
- package/esm2015/lib/components/table/default-cell-renderer/default-cell-renderer.component.js.map +1 -1
- package/esm2015/lib/components/table/default-cell-renderer/default-cell-renderer.component.metadata.json +1 -1
- package/esm2015/lib/components/table/table-cell-renderer/table-cell-renderer.component.js.map +1 -1
- package/esm2015/lib/components/table/table-cell-renderer/table-cell-renderer.component.metadata.json +1 -1
- package/esm2015/lib/components/table/table-model.js +0 -9
- 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 +3 -30
- 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/components/track-by.js +1 -5
- package/esm2015/lib/components/track-by.js.map +1 -1
- package/esm2015/lib/components/tree-table/decorated-tree-node.js +22 -19
- package/esm2015/lib/components/tree-table/decorated-tree-node.js.map +1 -1
- package/esm2015/lib/components/tree-table/tree-table-component.js +4 -21
- package/esm2015/lib/components/tree-table/tree-table-component.js.map +1 -1
- package/esm2015/lib/components/tree-table/tree-table-component.metadata.json +1 -1
- package/esm2015/lib/directives/directives.module.js +2 -8
- package/esm2015/lib/directives/directives.module.js.map +1 -1
- package/esm2015/lib/directives/directives.module.metadata.json +1 -1
- package/esm2015/lib/directives/directives.module.ngfactory.js.map +1 -1
- package/esm2015/lib/directives/exports.js +0 -2
- package/esm2015/lib/directives/exports.js.map +1 -1
- package/esm2015/lib/directives/exports.metadata.json +1 -1
- package/esm2015/lib/interaction/interaction.module.ngfactory.js.map +1 -1
- package/esm2015/lib/place/components/abstract-place-navigation.component.js +9 -18
- package/esm2015/lib/place/components/abstract-place-navigation.component.js.map +1 -1
- package/esm2015/lib/place/components/abstract-place-navigation.component.metadata.json +1 -1
- package/esm2015/lib/place/components/list-place-nav/list-place-nav.component.js +1 -1
- package/esm2015/lib/place/components/list-place-nav/list-place-nav.component.js.map +1 -1
- package/esm2015/lib/place/components/list-place-nav/list-place-nav.component.metadata.json +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/components/tabbed-place-navigation/tabbed-place-navigation.component.js +1 -1
- package/esm2015/lib/place/components/tabbed-place-navigation/tabbed-place-navigation.component.js.map +1 -1
- package/esm2015/lib/place/components/tabbed-place-navigation/tabbed-place-navigation.component.metadata.json +1 -1
- package/esm2015/lib/place/place-component.js +3 -1
- package/esm2015/lib/place/place-component.js.map +1 -1
- package/esm2015/lib/place/place-component.metadata.json +1 -1
- package/esm2015/lib/place/place.module.ngfactory.js.map +1 -1
- package/fesm2015/coolon-angular-ui-powerups.js +55 -177
- package/fesm2015/coolon-angular-ui-powerups.js.map +1 -1
- package/lib/components/commands/command/command.component.d.ts +1 -2
- package/lib/components/table/column-model.d.ts +0 -1
- package/lib/components/table/table-model.d.ts +0 -9
- package/lib/components/table/table.component.d.ts +6 -24
- package/lib/components/track-by.d.ts +1 -3
- package/lib/components/tree-table/tree-table-component.d.ts +0 -9
- package/lib/directives/exports.d.ts +0 -2
- package/lib/place/components/abstract-place-navigation.component.d.ts +2 -9
- package/lib/place/place-component.d.ts +1 -1
- package/package.json +1 -1
- package/schematics/aup-i18n/index.js +28 -8
- package/schematics/aup-i18n/index.js.map +1 -1
- package/schematics/aup-i18n/templates/i18n/aup/components.yml.template +69 -0
- package/schematics/bootstrap-app/index.js +4 -5
- package/schematics/bootstrap-app/index.js.map +1 -1
- package/schematics/bootstrap-app/templates/{i18n.config.json.template → i18n/config.json.template} +0 -2
- package/schematics/bootstrap-app/templates/i18n/notifications.yml.template +19 -0
- package/schematics/ng-add/index.js +2 -2
- package/schematics/ng-add/index.js.map +1 -1
- package/schematics/place-add/index.js +5 -4
- package/schematics/place-add/index.js.map +1 -1
- package/schematics/place-add/templates/component/__name@dasherize__.component.ts.template +1 -3
- package/schematics/place-add/templates/files/i18n/places/__name@dasherize__.yml.template +7 -0
- package/esm2015/lib/directives/highlight-text-model.directive.js +0 -20
- package/esm2015/lib/directives/highlight-text-model.directive.js.map +0 -1
- package/esm2015/lib/directives/highlight-text-model.directive.metadata.json +0 -1
- package/esm2015/lib/directives/highlight-text-model.directive.ngfactory.js.map +0 -1
- package/esm2015/lib/directives/highlight.pipe.js +0 -43
- package/esm2015/lib/directives/highlight.pipe.js.map +0 -1
- package/esm2015/lib/directives/highlight.pipe.metadata.json +0 -1
- package/esm2015/lib/directives/highlight.pipe.ngfactory.js.map +0 -1
- package/lib/directives/highlight-text-model.directive.d.ts +0 -5
- package/lib/directives/highlight.pipe.d.ts +0 -11
- package/schematics/aup-i18n/templates/app/aup.i18n.yml.template +0 -80
- package/schematics/place-add/templates/component/__name@dasherize__.i18n.yml.template +0 -5
- /package/schematics/bootstrap-app/templates/{src/app → app}/app-routing.module.ts.template +0 -0
- /package/schematics/bootstrap-app/templates/{src/app → app}/app.component.html.template +0 -0
- /package/schematics/bootstrap-app/templates/{src/app → app}/app.component.scss.template +0 -0
- /package/schematics/bootstrap-app/templates/{src/app → app}/app.component.ts.template +0 -0
- /package/schematics/bootstrap-app/templates/{src/app → app}/app.module.ts.template +0 -0
- /package/schematics/bootstrap-app/templates/{src/app → app}/i18n.ts.template +0 -0
- /package/schematics/bootstrap-app/templates/{src/assets → assets}/fonts/material-design-icons/MaterialIcons-Regular.eot +0 -0
- /package/schematics/bootstrap-app/templates/{src/assets → assets}/fonts/material-design-icons/MaterialIcons-Regular.ijmap +0 -0
- /package/schematics/bootstrap-app/templates/{src/assets → assets}/fonts/material-design-icons/MaterialIcons-Regular.svg +0 -0
- /package/schematics/bootstrap-app/templates/{src/assets → assets}/fonts/material-design-icons/MaterialIcons-Regular.ttf +0 -0
- /package/schematics/bootstrap-app/templates/{src/assets → assets}/fonts/material-design-icons/MaterialIcons-Regular.woff +0 -0
- /package/schematics/bootstrap-app/templates/{src/assets → assets}/fonts/material-design-icons/MaterialIcons-Regular.woff2 +0 -0
- /package/schematics/bootstrap-app/templates/{src/assets → assets}/fonts/material-design-icons/README.md +0 -0
- /package/schematics/bootstrap-app/templates/{src/assets → assets}/fonts/material-design-icons/codepoints +0 -0
- /package/schematics/bootstrap-app/templates/{src/assets → assets}/fonts/material-design-icons/material-icons.css +0 -0
- /package/schematics/bootstrap-app/templates/{src/index.html.template → index.html.template} +0 -0
- /package/schematics/bootstrap-app/templates/{src/styles → styles}/global-variables.scss.template +0 -0
- /package/schematics/bootstrap-app/templates/{src/styles.scss.template → styles.scss.template} +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { AfterViewInit, ElementRef, OnInit } from '@angular/core';
|
|
2
|
-
import {
|
|
2
|
+
import { Command, ListModelChain, ValueModel, ValueModelChain } from '@coolon/pectin';
|
|
3
3
|
import { CommandFace } from '../command-face';
|
|
4
4
|
import { PopupAwareComponent } from '../group/popup-aware.component';
|
|
5
5
|
import { PopupContainer } from '../group/popup-container';
|
|
@@ -17,7 +17,6 @@ export declare class CommandComponent extends PopupAwareComponent implements OnI
|
|
|
17
17
|
readonly buttonStyle: ValueModelChain<string>;
|
|
18
18
|
readonly colorModel: ValueModelChain<'primary' | 'accent' | 'warn' | undefined>;
|
|
19
19
|
private activeFace;
|
|
20
|
-
readonly iconOnly: BooleanValueModelChain;
|
|
21
20
|
constructor(element: ElementRef, parent?: PopupContainer);
|
|
22
21
|
isActive(face: CommandFace): boolean;
|
|
23
22
|
ngOnInit(): void;
|
|
@@ -32,7 +32,6 @@ export declare class ColumnModel<Row> {
|
|
|
32
32
|
private _selectRowOnClick;
|
|
33
33
|
private _flex;
|
|
34
34
|
private _visibleModel;
|
|
35
|
-
readonly dasherisedColumnId: string;
|
|
36
35
|
constructor(columnId: string, textPropertiesProvider: ColumnModel.TextPropertiesProvider);
|
|
37
36
|
protected installHeaderRenderer(): void;
|
|
38
37
|
getHeaderText(): string;
|
|
@@ -54,15 +54,6 @@ import { SelectionColumnModel } from './column-model';
|
|
|
54
54
|
* table.addCustomColumn("fullName", hero => `${hero.firstName} ${hero.lastName}`);
|
|
55
55
|
* });
|
|
56
56
|
*
|
|
57
|
-
* Template columns
|
|
58
|
-
* @example
|
|
59
|
-
* const model = TableModel.fromList(heroList, table => {
|
|
60
|
-
* table.addSelectionColumn(selectionModel); // <- can be single or multiple selection model
|
|
61
|
-
* table.addTemplateColumn("myTemplate");
|
|
62
|
-
* });
|
|
63
|
-
*
|
|
64
|
-
* <div *aupColumnTemplate="let hero; columnId: 'myTemplate'">{{hero.age}}</div>
|
|
65
|
-
*
|
|
66
57
|
* I18n
|
|
67
58
|
* @example
|
|
68
59
|
* [table.yml]
|
|
@@ -31,32 +31,15 @@ import { ColumnModel } from './column-model';
|
|
|
31
31
|
*
|
|
32
32
|
* Styling
|
|
33
33
|
* @example
|
|
34
|
-
* // global settings
|
|
35
|
-
* :root {
|
|
36
|
-
* --aup-table-column-gap: 10px; // defaults to 24px
|
|
37
|
-
* --aup-table-row-hover-background-color, rgba(0, 0, 0, 0.05)
|
|
38
|
-
* --aup-table-row-selected-background-color: rebeccapurple; // defaults to transparent
|
|
39
|
-
* --aup-table-first-column-padding-left: 18px // defaults to --column-gap
|
|
40
|
-
* --aup-table-last-column-padding-right: 18px // defaults to --column-gap
|
|
41
|
-
* }
|
|
42
|
-
*
|
|
43
|
-
* // per table settings.
|
|
44
34
|
* aup-table {
|
|
45
35
|
* --column-gap: 10px; // defaults to 24px
|
|
46
36
|
* --row-hover-background-color, rgba(0, 0, 0, 0.05)
|
|
47
37
|
* --row-selected-background-color: rebeccapurple; // defaults to transparent
|
|
48
|
-
* --first-column-padding-left: 18px // defaults to --column-gap
|
|
49
|
-
* --last-column-padding-right: 18px // defaults to --column-gap
|
|
50
|
-
*
|
|
51
|
-
* aup-table-header-cell-renderer,
|
|
52
38
|
* aup-table-cell-renderer {
|
|
53
|
-
*
|
|
39
|
+
* &:first-column {
|
|
54
40
|
* // do stuff
|
|
55
41
|
* }
|
|
56
|
-
*
|
|
57
|
-
* // do stuff
|
|
58
|
-
* }
|
|
59
|
-
* &.last-visible-column {
|
|
42
|
+
* &:last-column {
|
|
60
43
|
* // do stuff
|
|
61
44
|
* }
|
|
62
45
|
* }
|
|
@@ -66,16 +49,16 @@ export declare class TableComponent<Row> extends ResizeAwareComponent implements
|
|
|
66
49
|
tableModel: AbstractTableModel<Row>;
|
|
67
50
|
showHeaderModel: ValueModel<boolean>;
|
|
68
51
|
showHeader: boolean;
|
|
52
|
+
columns: ListModelChain<ColumnModel<Row>>;
|
|
53
|
+
columnIds: ListModelChain<string>;
|
|
54
|
+
private columnsById;
|
|
55
|
+
readonly visibleRowCount: ValueModel<number>;
|
|
69
56
|
/**
|
|
70
57
|
* Set to true to enable scrolling. Once enabled the table will have 0 implicit height. You will either
|
|
71
58
|
* need to set it explicitly e.g. height: 400px; or by using flex or grid layout to make it fill it's
|
|
72
59
|
* containment area.
|
|
73
60
|
*/
|
|
74
61
|
enableScrolling: boolean;
|
|
75
|
-
columns: ListModelChain<ColumnModel<Row>>;
|
|
76
|
-
columnIds: ListModelChain<string>;
|
|
77
|
-
private columnsById;
|
|
78
|
-
readonly visibleRowCount: ValueModel<number>;
|
|
79
62
|
private readonly headerHeight;
|
|
80
63
|
private readonly rowHeight;
|
|
81
64
|
constructor(elementRef: ElementRef, ngZone: NgZone);
|
|
@@ -86,5 +69,4 @@ export declare class TableComponent<Row> extends ResizeAwareComponent implements
|
|
|
86
69
|
notifyCellClicked(columnModel: ColumnModel<Row>, row: Row): void;
|
|
87
70
|
isFirstVisibleColumn(columnId: string): boolean;
|
|
88
71
|
isLastVisibleColumn(columnId: string): boolean;
|
|
89
|
-
getColumnClasses(columnId: string): string[];
|
|
90
72
|
}
|
|
@@ -1,16 +1,7 @@
|
|
|
1
|
-
import { ValueModel } from '@coolon/pectin';
|
|
2
1
|
import { DisposableComponent } from '../disposable-component';
|
|
3
2
|
import { TreeNode } from './tree-node';
|
|
4
3
|
import { TreeTableModel } from './tree-table-model';
|
|
5
4
|
export declare class TreeTableComponent<T extends TreeNode<T>> extends DisposableComponent {
|
|
6
5
|
treeTableModel: TreeTableModel<T>;
|
|
7
|
-
showHeaderModel: ValueModel<boolean>;
|
|
8
|
-
showHeader: boolean;
|
|
9
|
-
/**
|
|
10
|
-
* Set to true to enable scrolling. Once enabled the table will have 0 implicit height. You will either
|
|
11
|
-
* need to set it explicitly e.g. height: 400px; or by using flex or grid layout to make it fill it's
|
|
12
|
-
* containment area.
|
|
13
|
-
*/
|
|
14
|
-
enableScrolling: boolean;
|
|
15
6
|
constructor();
|
|
16
7
|
}
|
|
@@ -6,25 +6,18 @@ import { PlaceComponent } from '../place-component';
|
|
|
6
6
|
import { PlaceDefinition } from '../place-definition';
|
|
7
7
|
import { PlaceRouter } from '../place-router';
|
|
8
8
|
import { PlaceOutletComponent } from './place-outlet/place-outlet.component';
|
|
9
|
-
interface MenuItem {
|
|
10
|
-
active: boolean;
|
|
11
|
-
place: PlaceDefinition;
|
|
12
|
-
}
|
|
13
9
|
export declare class AbstractPlaceNavigationComponent extends DisposableComponent implements OnInit {
|
|
14
10
|
readonly placeRouter: PlaceRouter;
|
|
15
11
|
places: Constructable<PlaceComponent>[];
|
|
16
12
|
placesModel: ListModel<Constructable<PlaceComponent>>;
|
|
17
13
|
placeOutlet: PlaceOutletComponent;
|
|
18
14
|
placeOutletModel: ValueModel<PlaceOutletComponent>;
|
|
19
|
-
|
|
20
|
-
readonly menuItems: ListModelChain<MenuItem>;
|
|
15
|
+
readonly placeDefinitions: ListModelChain<PlaceDefinition>;
|
|
21
16
|
readonly commandFactory: Command.Factory<PlaceDefinition, void>;
|
|
22
17
|
readonly _activePlaceComponent: DelegatingValueModel<PlaceComponent>;
|
|
23
18
|
private activePlaceDefinition;
|
|
24
|
-
readonly trackByPlaceDef: (data: MenuItem) => PlaceDefinition;
|
|
25
19
|
constructor(placeRouter: PlaceRouter);
|
|
26
|
-
protected handlePlaceOutLetChanged(outlet: PlaceOutletComponent): void;
|
|
27
20
|
getNavigationFace(placeDef: PlaceDefinition): CommandFace;
|
|
21
|
+
isActive(place: PlaceDefinition): boolean;
|
|
28
22
|
ngOnInit(): void;
|
|
29
23
|
}
|
|
30
|
-
export {};
|
|
@@ -13,7 +13,6 @@ export declare class PlaceComponent extends DisposableComponent {
|
|
|
13
13
|
private _inVisitUpdate;
|
|
14
14
|
private _active;
|
|
15
15
|
interactionContext?: InteractionContext;
|
|
16
|
-
readonly childPlaces: ReadonlyArray<Constructable<PlaceComponent>>;
|
|
17
16
|
canDeactivate?(interactionContext: InteractionContext): boolean | Promise<boolean>;
|
|
18
17
|
constructor();
|
|
19
18
|
initialiseVisit(visit: Visit, notifyVisitChanged: (current: Visit, previous: Visit) => void): void;
|
|
@@ -21,6 +20,7 @@ export declare class PlaceComponent extends DisposableComponent {
|
|
|
21
20
|
isInitialised(): boolean;
|
|
22
21
|
private installBinding;
|
|
23
22
|
get placeDefinition(): PlaceDefinition;
|
|
23
|
+
get childPlaces(): Constructable<PlaceComponent>[];
|
|
24
24
|
get active(): import("@coolon/pectin").ValueModel<boolean>;
|
|
25
25
|
/**
|
|
26
26
|
* Called by the router when the place is ready to interact after any animations have run.
|
package/package.json
CHANGED
|
@@ -4,7 +4,6 @@ exports.applyWithOverwrite = exports.run = void 0;
|
|
|
4
4
|
const core_1 = require("@angular-devkit/core");
|
|
5
5
|
const schematics_1 = require("@angular-devkit/schematics");
|
|
6
6
|
const workspace_1 = require("../utils/workspace");
|
|
7
|
-
const package_util_1 = require("../package-util");
|
|
8
7
|
// @see https://javascript-conference.com/blog/how-to-create-your-own-angular-schematics/
|
|
9
8
|
function run(_options) {
|
|
10
9
|
return (tree, _context) => {
|
|
@@ -14,17 +13,38 @@ function run(_options) {
|
|
|
14
13
|
schematics_1.applyTemplates(Object.assign(Object.assign({}, _options), core_1.strings)),
|
|
15
14
|
schematics_1.move(buildContext.sourceRoot)
|
|
16
15
|
]);
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
}
|
|
23
|
-
|
|
16
|
+
const rules = [templateSource];
|
|
17
|
+
// if (_options.initialPlaceName) {
|
|
18
|
+
// rules.push(externalSchematic('@coolon/angular-ui-powerups', 'place-add', {
|
|
19
|
+
// project: _options.project,
|
|
20
|
+
// name: `places/${_options.initialPlaceName}`
|
|
21
|
+
// })
|
|
22
|
+
// );
|
|
23
|
+
// }
|
|
24
24
|
return schematics_1.chain(rules)(tree, _context);
|
|
25
25
|
};
|
|
26
26
|
}
|
|
27
27
|
exports.run = run;
|
|
28
|
+
// function updatePackageJsonScripts(_options: Schema): Rule {
|
|
29
|
+
// return (tree: Tree, _: SchematicContext): Tree => {
|
|
30
|
+
// return updatePackageJson(tree, draft => {
|
|
31
|
+
// draft.scripts = {
|
|
32
|
+
// ...draft.scripts,
|
|
33
|
+
// [`i18n:${_options.project}`]: `i18n-resource-generator apps/${_options.project}/src/i18n apps/${_options.project}/src/app`,
|
|
34
|
+
// [`place-routes:${_options.project}`]: `ng generate @coolon/angular-ui-powerups:place-routes --project ${_options.project}`,
|
|
35
|
+
// [`build:${_options.project}`]: `nx build --prod --project ${_options.project}`,
|
|
36
|
+
// [`start:${_options.project}`]: `nx serve --project ${_options.project}`
|
|
37
|
+
// };
|
|
38
|
+
// draft.watch = {
|
|
39
|
+
// ...draft.watch,
|
|
40
|
+
// [`i18n:${_options.project}`]: {
|
|
41
|
+
// "patterns": [`apps/${_options.project}/src/i18n`],
|
|
42
|
+
// "extensions": "yml"
|
|
43
|
+
// }
|
|
44
|
+
// }
|
|
45
|
+
// });
|
|
46
|
+
// };
|
|
47
|
+
// }
|
|
28
48
|
// See https://stackoverflow.com/a/53230034
|
|
29
49
|
function applyWithOverwrite(source, rules) {
|
|
30
50
|
return (tree, _context) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/schematics/aup-i18n/index.ts"],"names":[],"mappings":";;;AAAA,+CAA6D;AAC7D,2DAaoC;AACpC,kDAA+C;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/schematics/aup-i18n/index.ts"],"names":[],"mappings":";;;AAAA,+CAA6D;AAC7D,2DAaoC;AACpC,kDAA+C;AAG/C,yFAAyF;AAEzF,SAAgB,GAAG,CAAC,QAAgB;IAElC,OAAO,CAAC,IAAU,EAAE,QAA0B,EAAE,EAAE;QAEhD,MAAM,SAAS,GAAG,qBAAS,CAAC,IAAI,CAA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OAAO,IAAI,CAAC;iBACb;gBACD,OAAO,SAAS,CAAC;YACnB,CAAC,CAAC;SACH,CAAC,CACH,CAAC;QAEF,OAAO,IAAI,CAAC,IAAI,EAAE,QAAQ,CAAC,CAAC;IAC9B,CAAC,CAAC;AACJ,CAAC;AAjBD,gDAiBC;AAGD,6CAA6C;AAC7C,+DAA+D;AAC/D,YAAY;AACZ,wBAAwB;AACxB,uBAAuB;AACvB,qBAAqB;AACrB,qBAAqB;AACrB,0BAA0B;AAC1B,4BAA4B;AAC5B,QAAQ;AACR,IAAI;AAGJ,kDAAkD;AAClD,gCAAgC;AAChC,EAAE;AACF,yDAAyD;AACzD,EAAE;AACF,qDAAqD;AACrD,8CAA8C;AAC9C,UAAU;AACV,4EAA4E;AAC5E,EAAE;AACF,2BAA2B;AAC3B,kBAAkB;AAClB,UAAU;AACV,EAAE;AACF,2CAA2C;AAC3C,OAAO;AACP,IAAI;AAGJ,oDAAoD;AACpD,yDAAyD;AACzD,2EAA2E;AAC3E,mBAAmB;AACnB,OAAO;AACP,IAAI;AACJ,EAAE;AACF,qDAAqD;AACrD,yDAAyD;AACzD,oEAAoE;AACpE,mBAAmB;AACnB,OAAO;AACP,IAAI"}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
aup:
|
|
2
|
+
components:
|
|
3
|
+
activityActions:
|
|
4
|
+
styles(Enum):
|
|
5
|
+
okCancel:
|
|
6
|
+
confirm(CommandFace):
|
|
7
|
+
text: Ok
|
|
8
|
+
cancel(CommandFace):
|
|
9
|
+
text: Cancel
|
|
10
|
+
okCancelStrokedPrimary:
|
|
11
|
+
confirm(CommandFace):
|
|
12
|
+
text: Ok
|
|
13
|
+
style: stroked
|
|
14
|
+
color: primary
|
|
15
|
+
cancel(CommandFace):
|
|
16
|
+
text: Cancel
|
|
17
|
+
okCancelRaisedPrimary:
|
|
18
|
+
confirm(CommandFace):
|
|
19
|
+
text: Ok
|
|
20
|
+
style: raised
|
|
21
|
+
color: primary
|
|
22
|
+
cancel(CommandFace):
|
|
23
|
+
text: Cancel
|
|
24
|
+
okCancelIcons:
|
|
25
|
+
confirm(CommandFace):
|
|
26
|
+
icon: mat:done
|
|
27
|
+
cancel(CommandFace):
|
|
28
|
+
icon: mat:clear
|
|
29
|
+
|
|
30
|
+
doneCancel:
|
|
31
|
+
confirm(CommandFace):
|
|
32
|
+
text: Done
|
|
33
|
+
cancel(CommandFace):
|
|
34
|
+
text: Cancel
|
|
35
|
+
doneCancelStrokedPrimary:
|
|
36
|
+
confirm(CommandFace):
|
|
37
|
+
text: Done
|
|
38
|
+
style: stroked
|
|
39
|
+
color: primary
|
|
40
|
+
cancel(CommandFace):
|
|
41
|
+
text: Cancel
|
|
42
|
+
doneCancelRaisedPrimary:
|
|
43
|
+
confirm(CommandFace):
|
|
44
|
+
text: Done
|
|
45
|
+
style: raised
|
|
46
|
+
color: primary
|
|
47
|
+
cancel(CommandFace):
|
|
48
|
+
text: Cancel
|
|
49
|
+
|
|
50
|
+
saveCancel:
|
|
51
|
+
confirm(CommandFace):
|
|
52
|
+
text: Save
|
|
53
|
+
cancel(CommandFace):
|
|
54
|
+
text: Cancel
|
|
55
|
+
saveCancelStrokedPrimary:
|
|
56
|
+
confirm(CommandFace):
|
|
57
|
+
text: Save
|
|
58
|
+
style: stroked
|
|
59
|
+
color: primary
|
|
60
|
+
cancel(CommandFace):
|
|
61
|
+
text: Cancel
|
|
62
|
+
saveCancelRaisedPrimary:
|
|
63
|
+
confirm(CommandFace):
|
|
64
|
+
text: Save
|
|
65
|
+
style: raised
|
|
66
|
+
color: primary
|
|
67
|
+
cancel(CommandFace):
|
|
68
|
+
text: Cancel
|
|
69
|
+
|
|
@@ -12,7 +12,7 @@ function bootstrapApp(_options) {
|
|
|
12
12
|
const buildContext = workspace.getApplicationOrDefault(_options.project);
|
|
13
13
|
const templateSource = applyWithOverwrite(schematics_1.url('./templates'), [
|
|
14
14
|
schematics_1.applyTemplates(Object.assign(Object.assign({}, _options), core_1.strings)),
|
|
15
|
-
schematics_1.move(buildContext.
|
|
15
|
+
schematics_1.move(buildContext.sourceRoot)
|
|
16
16
|
]);
|
|
17
17
|
const rules = [
|
|
18
18
|
templateSource,
|
|
@@ -39,11 +39,10 @@ exports.bootstrapApp = bootstrapApp;
|
|
|
39
39
|
function updatePackageJsonScripts(context) {
|
|
40
40
|
return (tree, _) => {
|
|
41
41
|
return package_util_1.updatePackageJson(tree, draft => {
|
|
42
|
-
draft.scripts = Object.assign(Object.assign({}, draft.scripts), { [`i18n:${context.projectName}`]: `i18n-resource-generator ${context.
|
|
42
|
+
draft.scripts = Object.assign(Object.assign({}, draft.scripts), { [`i18n:${context.projectName}`]: `i18n-resource-generator ${context.sourceRoot}/i18n ${context.sourceCodeRoot}`, [`place-routes:${context.projectName}`]: `ng generate @coolon/angular-ui-powerups:place-routes --project ${context.projectName} places`, [`build:${context.projectName}`]: `nx build --prod --project ${context.projectName}`, [`start:${context.projectName}`]: `nx serve --project ${context.projectName}`, [`e2e:${context.projectName}-e2e`]: `nx e2e --watch --project ${context.projectName}-e2e`, [`e2e-headless:${context.projectName}-e2e`]: `nx e2e --headless --project ${context.projectName}-e2e` });
|
|
43
43
|
draft.watch = Object.assign(Object.assign({}, draft.watch), { [`i18n:${context.projectName}`]: {
|
|
44
|
-
"
|
|
45
|
-
"
|
|
46
|
-
"extensions": "i18n.yml"
|
|
44
|
+
"patterns": [`${context.sourceRoot}/i18n`],
|
|
45
|
+
"extensions": "yml"
|
|
47
46
|
} });
|
|
48
47
|
});
|
|
49
48
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/schematics/bootstrap-app/index.ts"],"names":[],"mappings":";;;AAAA,+CAA6D;AAC7D,2DAaoC;AACpC,kDAAoD;AAEpD,kDAA+C;AAG/C,yFAAyF;AAEzF,SAAgB,YAAY,CAAC,QAAgB;IAE3C,OAAO,CAAC,IAAU,EAAE,QAA0B,EAAE,E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Yikes, this is a bit embarrassing, we've had an error condition we weren't expecting."
|
|
5
|
+
- "It's with great shame an loathing that we can only suggest reloading the page to see if that helps..."
|
|
6
|
+
ok: "Ok, try reloading it..."
|
|
7
|
+
not_implemented:
|
|
8
|
+
content:
|
|
9
|
+
- "We haven't got around to doing this yet."
|
|
10
|
+
ok: "Bugger"
|
|
11
|
+
|
|
12
|
+
confirm(Confirm[]):
|
|
13
|
+
leave_this_page:
|
|
14
|
+
content:
|
|
15
|
+
- "Would you like to go to {name}?"
|
|
16
|
+
ok: "Yep"
|
|
17
|
+
cancel: "Nope"
|
|
18
|
+
|
|
19
|
+
|
|
@@ -19,8 +19,8 @@ function installDependencies(_options) {
|
|
|
19
19
|
return (tree, _) => {
|
|
20
20
|
return package_util_1.updatePackageJson(tree, draft => {
|
|
21
21
|
draft.scripts = Object.assign(Object.assign({}, draft.scripts), { "place-routes": "run-s place-routes:**", "i18n": "run-s i18n:**", "watch": "npm-watch" });
|
|
22
|
-
draft.dependencies = Object.assign(Object.assign({}, draft.dependencies), { "@coolon/pectin": "^3.10.1", "@coolon/typescript-utilities": "^2.0.2", "roboto-fontface": "^0.10.0", "@js-joda/core": "^3.2.0", "@js-joda/locale": "^3.2.0", "@js-joda/timezone": "^2.3.0", "immer": "^7.0.5", "typescript-string-enums": "^1.0.0", "format-message-interpret": "^6.2.3", "moment": "^2.18.1" });
|
|
23
|
-
draft.devDependencies = Object.assign(Object.assign({}, draft.devDependencies), { "husky": "^4.2.0", "cypress-wait-until": "^1.6.1", "barrelsby": "^2.1.1", "dotenv": "6.2.0", "cz-conventional-changelog": "^3.1.0", "@commitlint/cli": "^8.3.5", "git-is-clean": "^3.0.1", "shx": "^0.3.2", 'standard-version': '^8.0.0', "npm-watch": "^0.7.0" });
|
|
22
|
+
draft.dependencies = Object.assign(Object.assign({}, draft.dependencies), { "@coolon/pectin": "^3.10.1", "@coolon/typescript-utilities": "^2.0.2", "roboto-fontface": "^0.10.0", "@js-joda/core": "^3.2.0", "@js-joda/locale": "^3.2.0", "@js-joda/timezone": "^2.3.0", "cldr-data": "^36.0.0", "cldrjs": "^0.5.4", "immer": "^7.0.5", "typescript-string-enums": "^1.0.0", "format-message-interpret": "^6.2.3", "moment": "^2.18.1" });
|
|
23
|
+
draft.devDependencies = Object.assign(Object.assign({}, draft.devDependencies), { "husky": "^4.2.0", "@coolon/i18n-resource-generator": "^2.0.13", "cypress-wait-until": "^1.6.1", "barrelsby": "^2.1.1", "dotenv": "6.2.0", "cz-conventional-changelog": "^3.1.0", "@commitlint/cli": "^8.3.5", "git-is-clean": "^3.0.1", "shx": "^0.3.2", 'standard-version': '^8.0.0', "npm-watch": "^0.7.0" });
|
|
24
24
|
draft.watch = Object.assign({}, draft.watch);
|
|
25
25
|
draft.config = Object.assign(Object.assign({}, draft.config), { commitizen: {
|
|
26
26
|
path: './node_modules/cz-conventional-changelog'
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/schematics/ng-add/index.ts"],"names":[],"mappings":";;;AAAA,2DAAiF;AACjF,4DAA0E;AAC1E,kDAAoD;AAEpD,uBAAuB;AACvB,SAAgB,KAAK,CAAC,QAAa;IACjC,OAAO,kBAAK,CAAC;QACX,CAAC,IAAU,EAAE,QAA0B,EAAE,EAAE;YACzC,QAAQ,CAAC,OAAO,CAAC,IAAI,8BAAsB,EAAE,CAAC,CAAC;YAC/C,OAAO,IAAI,CAAC;QACd,CAAC;QACD,mBAAmB,CAAC,QAAQ,CAAC;KAC9B,CAAC,CAAC;AACL,CAAC;AARD,sBAQC;AAED,SAAgB,mBAAmB,CAAC,QAAa;IAC/C,OAAO,CAAC,IAAU,EAAE,CAAmB,EAAQ,EAAE;QAC/C,OAAO,gCAAiB,CAAC,IAAI,EAAE,KAAK,CAAC,EAAE;YACrC,KAAK,CAAC,OAAO,mCACR,KAAK,CAAC,OAAO,KAChB,cAAc,EAAE,uBAAuB,EACvC,MAAM,EAAE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;YAEF,KAAK,CAAC,KAAK,qBACN,KAAK,CAAC,KAAK,CACf,CAAA;YAED,KAAK,CAAC,MAAM,mCACP,KAAK,CAAC,MAAM,KACf,UAAU,EAAE;oBACV,IAAI,EAAE,0CAA0C;iBACjD,GACF,CAAC;YAEF,KAAK,CAAC,KAAK,GAAG;gBACZ,OAAO,EAAE;oBACP,YAAY,EAAE,gCAAgC;iBAC/C;aACF,CAAC;QAEJ,CAAC,CAAC,CAAC;IACL,CAAC,CAAC;AACJ,CAAC;AA5DD,kDA4DC"}
|
|
@@ -22,14 +22,15 @@ function addPlace(_options) {
|
|
|
22
22
|
name: _options.name,
|
|
23
23
|
module: placeModulePath.slice(buildContext.sourceCodeRoot.length)
|
|
24
24
|
});
|
|
25
|
-
const i18nNamespace = `I18n.${componentPathParts.concat(componentName).join('.')}`;
|
|
26
25
|
const componentFiles = template_utilities_1.applyTemplatesWithOverwrite(tree, 'templates/component', {
|
|
27
26
|
name: componentName,
|
|
28
27
|
selectorPrefix: buildContext.selectorPrefix,
|
|
29
|
-
pathToRoot: pathToSourceRoot.map(p => '..').join('/')
|
|
30
|
-
i18nNamespace
|
|
28
|
+
pathToRoot: pathToSourceRoot.map(p => '..').join('/')
|
|
31
29
|
}, `${(pathToSourceRoot.join('/'))}/${componentName}`);
|
|
32
|
-
|
|
30
|
+
const additionalFiles = template_utilities_1.applyTemplatesWithOverwrite(tree, 'templates/files', {
|
|
31
|
+
name: componentName
|
|
32
|
+
}, buildContext.sourceRoot);
|
|
33
|
+
return schematics_1.chain([updateModule, componentFiles, additionalFiles])(tree, context);
|
|
33
34
|
};
|
|
34
35
|
}
|
|
35
36
|
exports.addPlace = addPlace;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/schematics/place-add/index.ts"],"names":[],"mappings":";;;AAAA,2DAAoG;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../libs/angular-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AI,EAAE,aAAa;YACnB,cAAc,EAAE,YAAY,CAAC,cAAc;YAC3C,UAAU,EAAE,gBAAgB,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC;SACtD,EACD,GAAG,CAAC,gBAAgB,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,IAAI,aAAa,EAAE,CACnD,CAAC;QAGF,MAAM,eAAe,GAAG,gDAA2B,CACjD,IAAI,EACJ,iBAAiB,EACjB;YACE,IAAI,EAAE,aAAa;SACpB,EACD,YAAY,CAAC,UAAU,CAAC,CAAC;QAE3B,OAAO,kBAAK,CAAC,CAAC,YAAY,EAAE,cAAc,EAAE,eAAe,CAAC,CAAC,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAE/E,CAAC,CAAC;AAEJ,CAAC;AA9CD,4BA8CC"}
|
|
@@ -8,7 +8,7 @@ import { I18n } from '<%=pathToRoot%>/i18n';
|
|
|
8
8
|
@Place({
|
|
9
9
|
path: '<%=dasherize(name)%>',
|
|
10
10
|
data: {
|
|
11
|
-
nav:
|
|
11
|
+
nav: I18n.places.<%=camelize(name)%>.nav
|
|
12
12
|
},
|
|
13
13
|
authenticate: true
|
|
14
14
|
})
|
|
@@ -19,8 +19,6 @@ import { I18n } from '<%=pathToRoot%>/i18n';
|
|
|
19
19
|
})
|
|
20
20
|
export class <%=capitalize(camelize(name))%>Component extends PlaceComponent implements OnInit {
|
|
21
21
|
|
|
22
|
-
readonly i18n = <%=i18nNamespace%>;
|
|
23
|
-
|
|
24
22
|
constructor() {
|
|
25
23
|
super();
|
|
26
24
|
}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { __decorate, __metadata } from "tslib";
|
|
2
|
-
import { Directive, Input } from '@angular/core';
|
|
3
|
-
import { TrackExternal, ValueModel } from '@coolon/pectin';
|
|
4
|
-
export class HighlightTextModelDirective {
|
|
5
|
-
constructor() { }
|
|
6
|
-
}
|
|
7
|
-
HighlightTextModelDirective.decorators = [
|
|
8
|
-
{ type: Directive, args: [{
|
|
9
|
-
selector: '[aupHighlightTextModel]'
|
|
10
|
-
},] }
|
|
11
|
-
];
|
|
12
|
-
HighlightTextModelDirective.ctorParameters = () => [];
|
|
13
|
-
HighlightTextModelDirective.propDecorators = {
|
|
14
|
-
aupHighlightTextModel: [{ type: Input }]
|
|
15
|
-
};
|
|
16
|
-
__decorate([
|
|
17
|
-
TrackExternal(),
|
|
18
|
-
__metadata("design:type", ValueModel)
|
|
19
|
-
], HighlightTextModelDirective.prototype, "aupHighlightTextModel", void 0);
|
|
20
|
-
//# sourceMappingURL=highlight-text-model.directive.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"highlight-text-model.directive.js","sourceRoot":"","sources":["../../../../../../libs/angular-ui-powerups/src/lib/directives/highlight-text-model.directive.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAK3D,MAAM,OAAO,2BAA2B;IAMtC,gBAAgB,CAAC;;;YATlB,SAAS,SAAC;gBACT,QAAQ,EAAE,yBAAyB;aACpC;;;;oCAGE,KAAK;;AAEN;IADC,aAAa,EAAE;8BACO,UAAU;0EAAS","sourcesContent":["import { Directive, Input } from '@angular/core';\nimport { TrackExternal, ValueModel } from '@coolon/pectin';\n\n@Directive({\n selector: '[aupHighlightTextModel]'\n})\nexport class HighlightTextModelDirective {\n\n @Input()\n @TrackExternal()\n aupHighlightTextModel: ValueModel<string>;\n\n constructor() { }\n\n}\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
[{"__symbolic":"module","version":4,"metadata":{"HighlightTextModelDirective":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Directive","line":3,"character":1},"arguments":[{"selector":"[aupHighlightTextModel]"}]}],"members":{"aupHighlightTextModel":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":8,"character":3}},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@coolon/pectin","name":"TrackExternal","line":9,"character":3}}]}],"__ctor__":[{"__symbolic":"constructor"}]}}}}]
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"highlight-text-model.directive.ngfactory.js","sourceRoot":"","sources":["../../../../../../libs/angular-ui-powerups/src/lib/directives/highlight-text-model.directive.ngfactory.ts"],"names":[],"mappings":"","sourcesContent":["import * as i0 from '@angular/core';\ni0.ComponentFactory;\n"]}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { Optional, Pipe } from '@angular/core';
|
|
2
|
-
import { DomSanitizer } from '@angular/platform-browser';
|
|
3
|
-
import { GarbageCollector } from '@coolon/pectin';
|
|
4
|
-
import _ from 'lodash';
|
|
5
|
-
import { HighlightTextModelDirective } from './highlight-text-model.directive';
|
|
6
|
-
export class HighlightPipe extends GarbageCollector {
|
|
7
|
-
constructor(sanitizer, highlightContext) {
|
|
8
|
-
super();
|
|
9
|
-
this.sanitizer = sanitizer;
|
|
10
|
-
this.highlightContext = highlightContext;
|
|
11
|
-
}
|
|
12
|
-
ngOnDestroy() {
|
|
13
|
-
this.dispose();
|
|
14
|
-
}
|
|
15
|
-
transform(value, searchModel) {
|
|
16
|
-
var _a;
|
|
17
|
-
const model = searchModel !== null && searchModel !== void 0 ? searchModel : (_a = this.highlightContext) === null || _a === void 0 ? void 0 : _a.aupHighlightTextModel;
|
|
18
|
-
const searchText = model === null || model === void 0 ? void 0 : model.value;
|
|
19
|
-
if (_.isEmpty(searchText) || !_.isString(value)) {
|
|
20
|
-
return value;
|
|
21
|
-
}
|
|
22
|
-
// Match in a case insensitive manner
|
|
23
|
-
const re = new RegExp(searchText, 'gi');
|
|
24
|
-
const match = value.match(re);
|
|
25
|
-
// If there's no match, just return the original value.
|
|
26
|
-
if (!match) {
|
|
27
|
-
return value;
|
|
28
|
-
}
|
|
29
|
-
const result = value.replace(re, '<mark>' + match[0] + '</mark>');
|
|
30
|
-
return this.sanitizer.bypassSecurityTrustHtml(result);
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
HighlightPipe.decorators = [
|
|
34
|
-
{ type: Pipe, args: [{
|
|
35
|
-
name: 'aupHighlight',
|
|
36
|
-
pure: false
|
|
37
|
-
},] }
|
|
38
|
-
];
|
|
39
|
-
HighlightPipe.ctorParameters = () => [
|
|
40
|
-
{ type: DomSanitizer },
|
|
41
|
-
{ type: HighlightTextModelDirective, decorators: [{ type: Optional }] }
|
|
42
|
-
];
|
|
43
|
-
//# sourceMappingURL=highlight.pipe.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"highlight.pipe.js","sourceRoot":"","sources":["../../../../../../libs/angular-ui-powerups/src/lib/directives/highlight.pipe.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgC,QAAQ,EAAE,IAAI,EAAiB,MAAM,eAAe,CAAC;AAC5F,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AACzD,OAAO,EAAE,gBAAgB,EAAc,MAAM,gBAAgB,CAAC;AAC9D,OAAO,CAAC,MAAM,QAAQ,CAAC;AACvB,OAAO,EAAE,2BAA2B,EAAE,MAAM,kCAAkC,CAAC;AAO/E,MAAM,OAAO,aAAc,SAAQ,gBAAgB;IAEjD,YAAoB,SAAuB,EACF,gBAA8C;QACrF,KAAK,EAAE,CAAC;QAFU,cAAS,GAAT,SAAS,CAAc;QACF,qBAAgB,GAAhB,gBAAgB,CAA8B;IAEvF,CAAC;IAED,WAAW;QACT,IAAI,CAAC,OAAO,EAAE,CAAC;IACjB,CAAC;IAED,SAAS,CAAC,KAAU,EAAE,WAAgC;;QAEpD,MAAM,KAAK,GAAG,WAAW,aAAX,WAAW,cAAX,WAAW,SAAI,IAAI,CAAC,gBAAgB,0CAAE,qBAAqB,CAAC;QAE1E,MAAM,UAAU,GAAW,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,KAAK,CAAC;QAExC,IAAI,CAAC,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE;YAC/C,OAAO,KAAK,CAAC;SACd;QAED,qCAAqC;QACrC,MAAM,EAAE,GAAG,IAAI,MAAM,CAAC,UAAU,EAAE,IAAI,CAAC,CAAC;QACxC,MAAM,KAAK,GAAG,KAAK,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;QAE9B,uDAAuD;QACvD,IAAI,CAAC,KAAK,EAAE;YACV,OAAO,KAAK,CAAC;SACd;QAED,MAAM,MAAM,GAAG,KAAK,CAAC,OAAO,CAAC,EAAE,EAAE,QAAQ,GAAG,KAAK,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC,CAAC;QAClE,OAAO,IAAI,CAAC,SAAS,CAAC,uBAAuB,CAAC,MAAM,CAAC,CAAC;IACxD,CAAC;;;YApCF,IAAI,SAAC;gBACJ,IAAI,EAAE,cAAc;gBACpB,IAAI,EAAE,KAAK;aACZ;;;YATQ,YAAY;YAGZ,2BAA2B,uBAUrB,QAAQ","sourcesContent":["import { ChangeDetectorRef, OnDestroy, Optional, Pipe, PipeTransform } from '@angular/core';\nimport { DomSanitizer } from '@angular/platform-browser';\nimport { GarbageCollector, ValueModel } from '@coolon/pectin';\nimport _ from 'lodash';\nimport { HighlightTextModelDirective } from './highlight-text-model.directive';\n\n\n@Pipe({\n name: 'aupHighlight',\n pure: false\n})\nexport class HighlightPipe extends GarbageCollector implements PipeTransform, OnDestroy {\n\n constructor(private sanitizer: DomSanitizer,\n @Optional() private readonly highlightContext?: HighlightTextModelDirective) {\n super();\n }\n\n ngOnDestroy(): void {\n this.dispose();\n }\n\n transform(value: any, searchModel?: ValueModel<string>): any {\n\n const model = searchModel ?? this.highlightContext?.aupHighlightTextModel;\n\n const searchText: string = model?.value;\n\n if (_.isEmpty(searchText) || !_.isString(value)) {\n return value;\n }\n\n // Match in a case insensitive manner\n const re = new RegExp(searchText, 'gi');\n const match = value.match(re);\n\n // If there's no match, just return the original value.\n if (!match) {\n return value;\n }\n\n const result = value.replace(re, '<mark>' + match[0] + '</mark>');\n return this.sanitizer.bypassSecurityTrustHtml(result);\n }\n}\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
[{"__symbolic":"module","version":4,"metadata":{"HighlightPipe":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"@coolon/pectin","name":"GarbageCollector","line":11,"character":35},"decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Pipe","line":7,"character":1},"arguments":[{"name":"aupHighlight","pure":false}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[null,[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Optional","line":14,"character":15}}]],"parameters":[{"__symbolic":"reference","module":"@angular/platform-browser","name":"DomSanitizer","line":13,"character":33},{"__symbolic":"reference","module":"./highlight-text-model.directive","name":"HighlightTextModelDirective","line":14,"character":62}]}],"ngOnDestroy":[{"__symbolic":"method"}],"transform":[{"__symbolic":"method"}]}}}}]
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"highlight.pipe.ngfactory.js","sourceRoot":"","sources":["../../../../../../libs/angular-ui-powerups/src/lib/directives/highlight.pipe.ngfactory.ts"],"names":[],"mappings":"","sourcesContent":["import * as i0 from '@angular/core';\ni0.ComponentFactory;\n"]}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { OnDestroy, PipeTransform } from '@angular/core';
|
|
2
|
-
import { DomSanitizer } from '@angular/platform-browser';
|
|
3
|
-
import { GarbageCollector, ValueModel } from '@coolon/pectin';
|
|
4
|
-
import { HighlightTextModelDirective } from './highlight-text-model.directive';
|
|
5
|
-
export declare class HighlightPipe extends GarbageCollector implements PipeTransform, OnDestroy {
|
|
6
|
-
private sanitizer;
|
|
7
|
-
private readonly highlightContext?;
|
|
8
|
-
constructor(sanitizer: DomSanitizer, highlightContext?: HighlightTextModelDirective);
|
|
9
|
-
ngOnDestroy(): void;
|
|
10
|
-
transform(value: any, searchModel?: ValueModel<string>): any;
|
|
11
|
-
}
|