@coolon/angular-ui-powerups 3.7.0-alpha.0 → 3.7.0-alpha.10
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 +71 -0
- package/bundles/coolon-angular-ui-powerups.umd.js +423 -667
- 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/commands/command/command.component.js +15 -12
- 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/commands/flex.component.js +2 -9
- package/esm2015/lib/components/commands/flex.component.js.map +1 -1
- package/esm2015/lib/components/commands/flex.component.metadata.json +1 -1
- package/esm2015/lib/components/commands/group/command-container.js +21 -0
- package/esm2015/lib/components/commands/group/command-container.js.map +1 -0
- package/esm2015/lib/components/commands/group/command-container.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-aware.component.js +26 -0
- package/esm2015/lib/components/commands/group/popup-aware.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-aware.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-container.js +3 -0
- package/esm2015/lib/components/commands/group/popup-container.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-container.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/abstract-popup-menu.component.js +65 -0
- package/esm2015/lib/components/commands/group/popup-menu/abstract-popup-menu.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/abstract-popup-menu.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/abstract-popup-menu.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/more-menu.component.js +47 -0
- package/esm2015/lib/components/commands/group/popup-menu/more-menu.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/more-menu.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/more-menu.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.js +90 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu.component.js +42 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu.component.js.map +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu.component.metadata.json +1 -0
- package/esm2015/lib/components/commands/group/popup-menu/popup-menu.component.ngfactory.js.map +1 -0
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.js +12 -15
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.js.map +1 -1
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.metadata.json +1 -1
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.scss.ngstyle.js.map +1 -0
- package/esm2015/lib/components/commands/separator.component.js +25 -14
- package/esm2015/lib/components/commands/separator.component.js.map +1 -1
- package/esm2015/lib/components/commands/separator.component.metadata.json +1 -1
- package/esm2015/lib/components/components.module.js +6 -9
- 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/exports.js +7 -8
- package/esm2015/lib/components/exports.js.map +1 -1
- package/esm2015/lib/components/exports.metadata.json +1 -1
- package/esm2015/lib/interaction/interaction.module.ngfactory.js.map +1 -1
- package/esm2015/lib/place/components/place-outlet/place-outlet.component.js +12 -1
- package/esm2015/lib/place/components/place-outlet/place-outlet.component.js.map +1 -1
- package/esm2015/lib/place/components/place-outlet/place-outlet.component.metadata.json +1 -1
- package/esm2015/lib/place/guards/place.guard.js +31 -41
- package/esm2015/lib/place/guards/place.guard.js.map +1 -1
- package/esm2015/lib/place/guards/place.guard.metadata.json +1 -1
- package/esm2015/lib/place/place-auth-service.js.map +1 -1
- package/esm2015/lib/place/place-auth-service.metadata.json +1 -1
- package/esm2015/lib/place/place.module.ngfactory.js.map +1 -1
- package/fesm2015/coolon-angular-ui-powerups.js +361 -562
- package/fesm2015/coolon-angular-ui-powerups.js.map +1 -1
- package/lib/components/commands/command/command.component.d.ts +7 -6
- package/lib/components/commands/flex.component.d.ts +1 -3
- package/lib/components/commands/group/command-container.d.ts +16 -0
- package/lib/components/commands/group/popup-aware.component.d.ts +12 -0
- package/lib/components/commands/group/popup-container.d.ts +6 -0
- package/lib/components/commands/group/popup-menu/abstract-popup-menu.component.d.ts +25 -0
- package/lib/components/commands/group/popup-menu/more-menu.component.d.ts +12 -0
- package/lib/components/commands/group/popup-menu/popup-menu-renderer/popup-menu-renderer.component.d.ts +33 -0
- package/lib/components/commands/group/popup-menu/popup-menu.component.d.ts +13 -0
- package/lib/components/commands/group/tool-bar/tool-bar.component.d.ts +4 -5
- package/lib/components/commands/separator.component.d.ts +8 -7
- package/lib/components/exports.d.ts +7 -8
- package/lib/place/components/place-outlet/place-outlet.component.d.ts +3 -1
- package/lib/place/guards/place.guard.d.ts +2 -1
- package/lib/place/place-auth-service.d.ts +4 -4
- package/package.json +2 -2
- package/schematics/place-routes/index.d.ts +1 -1
- package/schematics/place-routes/index.js +9 -14
- package/schematics/place-routes/index.js.map +1 -1
- package/schematics/place-routes/place-builder.d.ts +3 -5
- package/schematics/place-routes/place-builder.js +4 -23
- package/schematics/place-routes/place-builder.js.map +1 -1
- package/schematics/place-routes/place-class-scanner.d.ts +3 -2
- package/schematics/place-routes/place-class-scanner.js.map +1 -1
- package/schematics/place-routes/place-def.d.ts +3 -2
- package/schematics/place-routes/place-def.js.map +1 -1
- package/schematics/utils/build-context.js +1 -1
- package/schematics/utils/build-context.js.map +1 -1
- package/schematics/utils/schematic-tree-file-system.d.ts +3 -2
- package/schematics/utils/schematic-tree-file-system.js +11 -2
- package/schematics/utils/schematic-tree-file-system.js.map +1 -1
- package/esm2015/lib/components/commands/group/command-group/command-group.component.js +0 -43
- package/esm2015/lib/components/commands/group/command-group/command-group.component.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group/command-group.component.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/command-group/command-group.component.ngfactory.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.js +0 -46
- package/esm2015/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.ngfactory.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.js +0 -39
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.ngfactory.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group-renderer/command-group-renderer.component.scss.shim.ngstyle.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group.js +0 -103
- package/esm2015/lib/components/commands/group/command-group.js.map +0 -1
- package/esm2015/lib/components/commands/group/command-group.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/more-menu.component.js +0 -53
- package/esm2015/lib/components/commands/group/more-menu.component.js.map +0 -1
- package/esm2015/lib/components/commands/group/more-menu.component.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/more-menu.component.ngfactory.js.map +0 -1
- package/esm2015/lib/components/commands/group/popup-menu.component.js +0 -52
- package/esm2015/lib/components/commands/group/popup-menu.component.js.map +0 -1
- package/esm2015/lib/components/commands/group/popup-menu.component.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/popup-menu.component.ngfactory.js.map +0 -1
- package/esm2015/lib/components/commands/group/registration.js +0 -58
- package/esm2015/lib/components/commands/group/registration.js.map +0 -1
- package/esm2015/lib/components/commands/group/registration.metadata.json +0 -1
- package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.scss.shim.ngstyle.js.map +0 -1
- package/esm2015/lib/components/commands/group/view-data.js +0 -113
- package/esm2015/lib/components/commands/group/view-data.js.map +0 -1
- package/esm2015/lib/components/commands/group/view-data.metadata.json +0 -1
- package/lib/components/commands/group/command-group/command-group.component.d.ts +0 -12
- package/lib/components/commands/group/command-group-menu-renderer/command-group-menu-renderer.component.d.ts +0 -21
- package/lib/components/commands/group/command-group-renderer/command-group-renderer.component.d.ts +0 -13
- package/lib/components/commands/group/command-group.d.ts +0 -42
- package/lib/components/commands/group/more-menu.component.d.ts +0 -14
- package/lib/components/commands/group/popup-menu.component.d.ts +0 -17
- package/lib/components/commands/group/registration.d.ts +0 -32
- package/lib/components/commands/group/view-data.d.ts +0 -41
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"registration.js","sourceRoot":"","sources":["../../../../../../../../libs/angular-ui-powerups/src/lib/components/commands/group/registration.ts"],"names":[],"mappings":"AACA,OAAO,EAAW,gBAAgB,EAAyB,MAAM,gBAAgB,CAAC;AAElF,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAGvC,MAAM,OAAgB,YAAa,SAAQ,gBAAgB;CAE1D;AAED,WAAiB,YAAY;IAE3B,MAAsB,gBAAiB,SAAQ,YAAY;QACzD,YAA+B,aAAqC;YAClE,KAAK,EAAE,CAAC;YADqB,kBAAa,GAAb,aAAa,CAAwB;QAEpE,CAAC;KACF;IAJqB,6BAAg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OAAO,CAAC,KAAmB;QACzC,OAAO,KAAK,YAAY,mBAAmB,IAAI,KAAK,YAAY,iBAAiB,CAAC;IACpF,CAAC;IAFe,oBAAO,UAEtB,CAAA;AAEH,CAAC,EArDgB,YAAY,KAAZ,YAAY,QAqD5B","sourcesContent":["\nimport { Command, GarbageCollector, ListModel, ValueModel } from '@coolon/pectin';\nimport { CommandGroup } from './command-group';\nimport { ViewData } from './view-data';\nimport { CommandFace } from '../command-face';\n\nexport abstract class Registration extends GarbageCollector {\n abstract toTemplate(): ViewData;\n}\n\nexport namespace Registration {\n\n export abstract class FaceRegistration extends Registration {\n protected constructor(readonly faceListModel: ListModel<CommandFace>) {\n super();\n }\n }\n\n export class CommandRegistration extends FaceRegistration {\n constructor(readonly command: Command<unknown>, faceListModel: ListModel<CommandFace>) {\n super(faceListModel);\n }\n\n toTemplate(): ViewData.CommandData {\n return new ViewData.CommandData(this.command, this.faceListModel.value);\n }\n }\n\n export class GroupRegistration extends FaceRegistration {\n constructor(faceModel: ListModel<CommandFace>, readonly group: CommandGroup) {\n super(faceModel);\n }\n\n toTemplate(): ViewData.GroupData {\n return new ViewData.GroupData(this.faceListModel.value,\n this.group.xPosition,\n this.group.yPosition,\n this.group.registrations.value.map(r => r.toTemplate())\n );\n }\n\n }\n\n export class SeparatorRegistration extends Registration {\n private readonly template = new ViewData.SeparatorData();\n\n toTemplate(): ViewData.SeparatorData {\n return this.template;\n }\n }\n\n export class FlexRegistration extends Registration {\n private readonly template = new ViewData.FlexData();\n\n toTemplate(): ViewData.FlexData {\n return this.template;\n }\n }\n\n export function hasFace(entry: Registration): entry is FaceRegistration {\n return entry instanceof CommandRegistration || entry instanceof GroupRegistration;\n }\n\n}\n\n\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
[{"__symbolic":"module","version":4,"metadata":{"Registration":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"@coolon/pectin","name":"GarbageCollector","line":6,"character":43},"members":{"toTemplate":[{"__symbolic":"method"}]}}}}]
|
package/esm2015/lib/components/commands/group/tool-bar/tool-bar.component.scss.shim.ngstyle.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"tool-bar.component.scss.shim.ngstyle.js","sourceRoot":"","sources":["../../../../../../../../../libs/angular-ui-powerups/src/lib/components/commands/group/tool-bar/tool-bar.component.scss.shim.ngstyle.ts"],"names":[],"mappings":"","sourcesContent":["import * as i0 from '@angular/core';\ni0.ComponentFactory;\n"]}
|
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
import { __decorate, __metadata } from "tslib";
|
|
2
|
-
import { lang, assert } from '@coolon/pectin';
|
|
3
|
-
import { Memoize } from '@typescript-plus/fast-memoize-decorator/dist/src';
|
|
4
|
-
import { CommandFace } from '../command-face';
|
|
5
|
-
export class ViewData {
|
|
6
|
-
}
|
|
7
|
-
(function (ViewData) {
|
|
8
|
-
class FaceData extends ViewData {
|
|
9
|
-
constructor(faces) {
|
|
10
|
-
super();
|
|
11
|
-
this.faces = faces;
|
|
12
|
-
assert.notNil(faces);
|
|
13
|
-
}
|
|
14
|
-
get activeFaceAdapter() {
|
|
15
|
-
return new CommandFace.Adapter(this.faces.length > 0 ? this.faces[0] : undefined);
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
__decorate([
|
|
19
|
-
Memoize(),
|
|
20
|
-
__metadata("design:type", CommandFace.Adapter),
|
|
21
|
-
__metadata("design:paramtypes", [])
|
|
22
|
-
], FaceData.prototype, "activeFaceAdapter", null);
|
|
23
|
-
ViewData.FaceData = FaceData;
|
|
24
|
-
class GroupData extends FaceData {
|
|
25
|
-
constructor(faces, xPosition, yPosition, children) {
|
|
26
|
-
super(faces);
|
|
27
|
-
this.xPosition = xPosition;
|
|
28
|
-
this.yPosition = yPosition;
|
|
29
|
-
this.children = children;
|
|
30
|
-
}
|
|
31
|
-
get hasMixedIcons() {
|
|
32
|
-
const hasFaces = this.children.filter(c => ViewData.hasFace(c));
|
|
33
|
-
const iconCount = hasFaces.filter(c => !!c.activeFaceAdapter.icon).length;
|
|
34
|
-
return iconCount > 0 && hasFaces.length !== iconCount;
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
__decorate([
|
|
38
|
-
Memoize(),
|
|
39
|
-
__metadata("design:type", Boolean),
|
|
40
|
-
__metadata("design:paramtypes", [])
|
|
41
|
-
], GroupData.prototype, "hasMixedIcons", null);
|
|
42
|
-
ViewData.GroupData = GroupData;
|
|
43
|
-
class CommandData extends FaceData {
|
|
44
|
-
constructor(command, faces) {
|
|
45
|
-
super(faces);
|
|
46
|
-
this.command = command;
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
ViewData.CommandData = CommandData;
|
|
50
|
-
class SeparatorData extends ViewData {
|
|
51
|
-
}
|
|
52
|
-
ViewData.SeparatorData = SeparatorData;
|
|
53
|
-
class FlexData extends ViewData {
|
|
54
|
-
}
|
|
55
|
-
ViewData.FlexData = FlexData;
|
|
56
|
-
function as(type, viewData) {
|
|
57
|
-
return viewData instanceof type ? viewData : lang.illegalState(`expected instance of ${type.name}, got ${viewData.constructor.name}`);
|
|
58
|
-
}
|
|
59
|
-
ViewData.as = as;
|
|
60
|
-
function getCommand(data) {
|
|
61
|
-
return as(CommandData, data).command;
|
|
62
|
-
}
|
|
63
|
-
ViewData.getCommand = getCommand;
|
|
64
|
-
function getTooltip(data) {
|
|
65
|
-
return as(FaceData, data).activeFaceAdapter.tooltip;
|
|
66
|
-
}
|
|
67
|
-
ViewData.getTooltip = getTooltip;
|
|
68
|
-
function getStyle(data) {
|
|
69
|
-
return as(FaceData, data).activeFaceAdapter.style;
|
|
70
|
-
}
|
|
71
|
-
ViewData.getStyle = getStyle;
|
|
72
|
-
function getColor(data) {
|
|
73
|
-
return as(FaceData, data).activeFaceAdapter.color;
|
|
74
|
-
}
|
|
75
|
-
ViewData.getColor = getColor;
|
|
76
|
-
function hasText(data) {
|
|
77
|
-
return !!as(FaceData, data).activeFaceAdapter.text;
|
|
78
|
-
}
|
|
79
|
-
ViewData.hasText = hasText;
|
|
80
|
-
function getFaces(data) {
|
|
81
|
-
return as(FaceData, data).faces;
|
|
82
|
-
}
|
|
83
|
-
ViewData.getFaces = getFaces;
|
|
84
|
-
function asGroup(viewData) {
|
|
85
|
-
return as(GroupData, viewData);
|
|
86
|
-
}
|
|
87
|
-
ViewData.asGroup = asGroup;
|
|
88
|
-
function hasMixedIcons(data) {
|
|
89
|
-
return as(GroupData, data).hasMixedIcons;
|
|
90
|
-
}
|
|
91
|
-
ViewData.hasMixedIcons = hasMixedIcons;
|
|
92
|
-
function isGroup(data) {
|
|
93
|
-
return data instanceof GroupData;
|
|
94
|
-
}
|
|
95
|
-
ViewData.isGroup = isGroup;
|
|
96
|
-
function hasFace(data) {
|
|
97
|
-
return data instanceof FaceData;
|
|
98
|
-
}
|
|
99
|
-
ViewData.hasFace = hasFace;
|
|
100
|
-
function isCommand(data) {
|
|
101
|
-
return data instanceof CommandData;
|
|
102
|
-
}
|
|
103
|
-
ViewData.isCommand = isCommand;
|
|
104
|
-
function isSeparator(data) {
|
|
105
|
-
return data instanceof SeparatorData;
|
|
106
|
-
}
|
|
107
|
-
ViewData.isSeparator = isSeparator;
|
|
108
|
-
function isFlex(data) {
|
|
109
|
-
return data instanceof FlexData;
|
|
110
|
-
}
|
|
111
|
-
ViewData.isFlex = isFlex;
|
|
112
|
-
})(ViewData || (ViewData = {}));
|
|
113
|
-
//# sourceMappingURL=view-data.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"view-data.js","sourceRoot":"","sources":["../../../../../../../../libs/angular-ui-powerups/src/lib/components/commands/group/view-data.ts"],"names":[],"mappings":";AACA,OAAO,EAA0B,IAAI,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AACtE,OAAO,EAAE,OAAO,EAAE,MAAM,kDAAkD,CAAC;AAC3E,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAG9C,MAAM,OAAO,QAAQ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gBAAO,UAEtB,CAAA;IAED,SAAgB,QAAQ,CAAC,IAAc;QACrC,OAAO,EAAE,CAAC,QAAQ,EAAE,IAAI,CAAC,CAAC,KAAK,CAAC;IAClC,CAAC;IAFe,iBAAQ,WAEvB,CAAA;IAED,SAAgB,OAAO,CAAC,QAAkB;QACxC,OAAO,EAAE,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;IACjC,CAAC;IAFe,gBAAO,UAEtB,CAAA;IAED,SAAgB,aAAa,CAAC,IAAc;QAC1C,OAAO,EAAE,CAAC,SAAS,EAAE,IAAI,CAAC,CAAC,aAAa,CAAC;IAC3C,CAAC;IAFe,sBAAa,gBAE5B,CAAA;IAED,SAAgB,OAAO,CAAC,IAAc;QACpC,OAAO,IAAI,YAAY,SAAS,CAAC;IACnC,CAAC;IAFe,gBAAO,UAEtB,CAAA;IAED,SAAgB,OAAO,CAAC,IAAc;QACpC,OAAO,IAAI,YAAY,QAAQ,CAAC;IAClC,CAAC;IAFe,gBAAO,UAEtB,CAAA;IAED,SAAgB,SAAS,CAAC,IAAc;QACtC,OAAO,IAAI,YAAY,WAAW,CAAC;IACrC,CAAC;IAFe,kBAAS,YAExB,CAAA;IAED,SAAgB,WAAW,CAAC,IAAc;QACxC,OAAO,IAAI,YAAY,aAAa,CAAC;IACvC,CAAC;IAFe,oBAAW,cAE1B,CAAA;IAED,SAAgB,MAAM,CAAC,IAAc;QACnC,OAAO,IAAI,YAAY,QAAQ,CAAC;IAClC,CAAC;IAFe,eAAM,SAErB,CAAA;AAGH,CAAC,EArGgB,QAAQ,KAAR,QAAQ,QAqGxB","sourcesContent":["import { ThemePalette } from '@angular/material/core';\nimport { Command, Constructable, lang, assert } from '@coolon/pectin';\nimport { Memoize } from '@typescript-plus/fast-memoize-decorator/dist/src';\nimport { CommandFace } from '../command-face';\n\n\nexport class ViewData {\n}\n\nexport namespace ViewData {\n\n export class FaceData extends ViewData {\n\n constructor(readonly faces: CommandFace[]) {\n super();\n assert.notNil(faces);\n }\n\n @Memoize()\n get activeFaceAdapter(): CommandFace.Adapter {\n return new CommandFace.Adapter(this.faces.length > 0 ? this.faces[0] : undefined)\n }\n }\n\n export class GroupData extends FaceData {\n constructor(faces: CommandFace[],\n readonly xPosition,\n readonly yPosition,\n readonly children: ViewData[]) {\n super(faces);\n }\n\n @Memoize()\n get hasMixedIcons(): boolean {\n const hasFaces = this.children.filter(c => ViewData.hasFace(c)) as ViewData.FaceData[]\n const iconCount = hasFaces.filter(c => !!c.activeFaceAdapter.icon).length;\n return iconCount > 0 && hasFaces.length !== iconCount;\n }\n }\n\n export class CommandData extends FaceData {\n constructor(readonly command: Command<unknown>, faces: CommandFace[]) {\n super(faces);\n }\n }\n\n export class SeparatorData extends ViewData {\n }\n\n export class FlexData extends ViewData {\n }\n\n\n export function as<T extends ViewData>(type: Constructable<T>, viewData: ViewData): T {\n return viewData instanceof type ? viewData : lang.illegalState(`expected instance of ${type.name}, got ${viewData.constructor.name}`);\n }\n\n export function getCommand(data: ViewData): Command<unknown> {\n return as(CommandData, data).command;\n }\n\n export function getTooltip(data: ViewData): string {\n return as(FaceData, data).activeFaceAdapter.tooltip;\n }\n\n export function getStyle(data: ViewData): string {\n return as(FaceData, data).activeFaceAdapter.style;\n }\n\n export function getColor(data: ViewData): ThemePalette {\n return as(FaceData, data).activeFaceAdapter.color as ThemePalette;\n }\n\n export function hasText(data: ViewData): boolean {\n return !!as(FaceData, data).activeFaceAdapter.text;\n }\n\n export function getFaces(data: ViewData): CommandFace[] {\n return as(FaceData, data).faces;\n }\n\n export function asGroup(viewData: ViewData): ViewData.GroupData {\n return as(GroupData, viewData);\n }\n\n export function hasMixedIcons(data: ViewData): boolean {\n return as(GroupData, data).hasMixedIcons;\n }\n\n export function isGroup(data: ViewData): data is GroupData {\n return data instanceof GroupData;\n }\n\n export function hasFace(data: ViewData): data is FaceData {\n return data instanceof FaceData;\n }\n\n export function isCommand(data: ViewData): data is CommandData {\n return data instanceof CommandData;\n }\n\n export function isSeparator(data: ViewData): data is SeparatorData {\n return data instanceof SeparatorData;\n }\n\n export function isFlex(data: ViewData): data is FlexData {\n return data instanceof FlexData;\n }\n\n\n}\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
[{"__symbolic":"module","version":4,"metadata":{"ViewData":{"__symbolic":"class"}}}]
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { ListModel, ValueModel } from '@coolon/pectin';
|
|
2
|
-
import { CommandFace } from '../../command-face';
|
|
3
|
-
import { CommandGroup } from '../command-group';
|
|
4
|
-
export declare class CommandGroupComponent extends CommandGroup {
|
|
5
|
-
readonly parent: CommandGroup;
|
|
6
|
-
faceModel: ValueModel<CommandFace>;
|
|
7
|
-
readonly faceListModel: ListModel<CommandFace>;
|
|
8
|
-
face: CommandFace;
|
|
9
|
-
xPosition: 'before' | 'after';
|
|
10
|
-
yPosition: 'above' | 'below';
|
|
11
|
-
constructor(parent: CommandGroup);
|
|
12
|
-
}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { EventEmitter, QueryList } from '@angular/core';
|
|
2
|
-
import { MatMenu, MatMenuTrigger } from '@angular/material/menu';
|
|
3
|
-
import { ListModelChain, ValueModelChain } from '@coolon/pectin';
|
|
4
|
-
import { DisposableComponent } from '../../../disposable-component';
|
|
5
|
-
import { TrackBy } from '../../../track-by';
|
|
6
|
-
import { Registration } from '../registration';
|
|
7
|
-
import { ViewData } from '../view-data';
|
|
8
|
-
export declare class CommandGroupMenuRendererComponent extends DisposableComponent {
|
|
9
|
-
readonly parent?: CommandGroupMenuRendererComponent;
|
|
10
|
-
menuComponent: MatMenu;
|
|
11
|
-
private readonly groupViewDataModel;
|
|
12
|
-
groupViewData: ViewData.GroupData;
|
|
13
|
-
commandFired: EventEmitter<any>;
|
|
14
|
-
triggers: QueryList<MatMenuTrigger>;
|
|
15
|
-
readonly children: ListModelChain<Registration>;
|
|
16
|
-
readonly hasMixedIcons: ValueModelChain<boolean>;
|
|
17
|
-
readonly ViewData: typeof ViewData;
|
|
18
|
-
TrackBy: typeof TrackBy;
|
|
19
|
-
constructor(parent?: CommandGroupMenuRendererComponent);
|
|
20
|
-
getCommand(data: ViewData): import("@coolon/pectin").Command<unknown>;
|
|
21
|
-
}
|
package/lib/components/commands/group/command-group-renderer/command-group-renderer.component.d.ts
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { ListModelChain, ValueModel } from '@coolon/pectin';
|
|
2
|
-
import { DisposableComponent } from '../../../disposable-component';
|
|
3
|
-
import { ViewData } from '../view-data';
|
|
4
|
-
import { TrackBy } from '../../../track-by';
|
|
5
|
-
export declare class CommandGroupRendererComponent extends DisposableComponent {
|
|
6
|
-
groupViewDataModel: ValueModel<ViewData.GroupData>;
|
|
7
|
-
groupViewData: ViewData.GroupData;
|
|
8
|
-
renderRootNode: boolean;
|
|
9
|
-
readonly ViewData: typeof ViewData;
|
|
10
|
-
readonly childViewDataModels: ListModelChain<ViewData>;
|
|
11
|
-
TrackBy: typeof TrackBy;
|
|
12
|
-
constructor();
|
|
13
|
-
}
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import { Command, Disposable, GarbageCollector, ListModel, ListModelChain, ValueModel } from '@coolon/pectin';
|
|
2
|
-
import { CommandFace } from '../command-face';
|
|
3
|
-
import { FlexComponent } from '../flex.component';
|
|
4
|
-
import { SeparatorComponent } from '../separator.component';
|
|
5
|
-
import { Registration } from './registration';
|
|
6
|
-
import { ViewData } from './view-data';
|
|
7
|
-
export declare abstract class CommandGroup extends GarbageCollector {
|
|
8
|
-
readonly parent?: CommandGroup;
|
|
9
|
-
abstract faceListModel: ListModel<CommandFace>;
|
|
10
|
-
abstract xPosition: 'before' | 'after';
|
|
11
|
-
abstract yPosition: 'above' | 'below';
|
|
12
|
-
private readonly _rootTemplate;
|
|
13
|
-
private readonly _registrations;
|
|
14
|
-
readonly childTemplates: ListModelChain<ViewData>;
|
|
15
|
-
private initialised;
|
|
16
|
-
constructor(parent?: CommandGroup);
|
|
17
|
-
initialise(): void;
|
|
18
|
-
get rootTemplate(): ValueModel<ViewData.GroupData>;
|
|
19
|
-
get registrations(): ListModel<Registration>;
|
|
20
|
-
notifyChanged(): void;
|
|
21
|
-
private notifyChildFaceChanged;
|
|
22
|
-
private rebuildTemplates;
|
|
23
|
-
get depth(): number;
|
|
24
|
-
isRoot(): boolean;
|
|
25
|
-
registerCommand(command: Command<unknown>, faceListModel: ListModel<CommandFace>): Disposable;
|
|
26
|
-
registerGroup(group: CommandGroup, faceModel: ListModel<CommandFace>): Disposable;
|
|
27
|
-
registerFlex(component: FlexComponent): Disposable;
|
|
28
|
-
registerSeparator(component: SeparatorComponent): Disposable;
|
|
29
|
-
protected register(registration: Registration): Registration;
|
|
30
|
-
}
|
|
31
|
-
export declare namespace CommandGroup {
|
|
32
|
-
class Root extends CommandGroup {
|
|
33
|
-
faceListModel: ListModel<CommandFace>;
|
|
34
|
-
xPositionModel: ValueModel<'before' | 'after'>;
|
|
35
|
-
xPosition: 'before' | 'after';
|
|
36
|
-
yPositionModel: ValueModel<'above' | 'below'>;
|
|
37
|
-
yPosition: 'above' | 'below';
|
|
38
|
-
constructor();
|
|
39
|
-
isRoot(): boolean;
|
|
40
|
-
}
|
|
41
|
-
function factory(): Root;
|
|
42
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { AfterContentInit, OnInit } from '@angular/core';
|
|
2
|
-
import { DisposableComponent } from '../../disposable-component';
|
|
3
|
-
import { CommandGroup } from './command-group';
|
|
4
|
-
/**
|
|
5
|
-
*
|
|
6
|
-
*/
|
|
7
|
-
export declare class MoreMenuComponent extends DisposableComponent implements OnInit, AfterContentInit {
|
|
8
|
-
readonly group: CommandGroup;
|
|
9
|
-
private tooltipModel;
|
|
10
|
-
tooltip: string;
|
|
11
|
-
constructor(group: CommandGroup);
|
|
12
|
-
ngOnInit(): void;
|
|
13
|
-
ngAfterContentInit(): void;
|
|
14
|
-
}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { AfterContentInit, AfterViewInit, OnInit } from '@angular/core';
|
|
2
|
-
import { ValueModel } from '@coolon/pectin';
|
|
3
|
-
import { DisposableComponent } from '../../disposable-component';
|
|
4
|
-
import { CommandFace } from '../command-face';
|
|
5
|
-
import { CommandGroup } from './command-group';
|
|
6
|
-
/**
|
|
7
|
-
*
|
|
8
|
-
*/
|
|
9
|
-
export declare class PopupMenuComponent extends DisposableComponent implements OnInit, AfterContentInit, AfterViewInit {
|
|
10
|
-
readonly group: CommandGroup;
|
|
11
|
-
faceModel: ValueModel<CommandFace>;
|
|
12
|
-
face: CommandFace;
|
|
13
|
-
constructor(group: CommandGroup);
|
|
14
|
-
ngOnInit(): void;
|
|
15
|
-
ngAfterContentInit(): void;
|
|
16
|
-
ngAfterViewInit(): void;
|
|
17
|
-
}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { Command, GarbageCollector, ListModel } from '@coolon/pectin';
|
|
2
|
-
import { CommandGroup } from './command-group';
|
|
3
|
-
import { ViewData } from './view-data';
|
|
4
|
-
import { CommandFace } from '../command-face';
|
|
5
|
-
export declare abstract class Registration extends GarbageCollector {
|
|
6
|
-
abstract toTemplate(): ViewData;
|
|
7
|
-
}
|
|
8
|
-
export declare namespace Registration {
|
|
9
|
-
abstract class FaceRegistration extends Registration {
|
|
10
|
-
readonly faceListModel: ListModel<CommandFace>;
|
|
11
|
-
protected constructor(faceListModel: ListModel<CommandFace>);
|
|
12
|
-
}
|
|
13
|
-
class CommandRegistration extends FaceRegistration {
|
|
14
|
-
readonly command: Command<unknown>;
|
|
15
|
-
constructor(command: Command<unknown>, faceListModel: ListModel<CommandFace>);
|
|
16
|
-
toTemplate(): ViewData.CommandData;
|
|
17
|
-
}
|
|
18
|
-
class GroupRegistration extends FaceRegistration {
|
|
19
|
-
readonly group: CommandGroup;
|
|
20
|
-
constructor(faceModel: ListModel<CommandFace>, group: CommandGroup);
|
|
21
|
-
toTemplate(): ViewData.GroupData;
|
|
22
|
-
}
|
|
23
|
-
class SeparatorRegistration extends Registration {
|
|
24
|
-
private readonly template;
|
|
25
|
-
toTemplate(): ViewData.SeparatorData;
|
|
26
|
-
}
|
|
27
|
-
class FlexRegistration extends Registration {
|
|
28
|
-
private readonly template;
|
|
29
|
-
toTemplate(): ViewData.FlexData;
|
|
30
|
-
}
|
|
31
|
-
function hasFace(entry: Registration): entry is FaceRegistration;
|
|
32
|
-
}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { ThemePalette } from '@angular/material/core';
|
|
2
|
-
import { Command, Constructable } from '@coolon/pectin';
|
|
3
|
-
import { CommandFace } from '../command-face';
|
|
4
|
-
export declare class ViewData {
|
|
5
|
-
}
|
|
6
|
-
export declare namespace ViewData {
|
|
7
|
-
class FaceData extends ViewData {
|
|
8
|
-
readonly faces: CommandFace[];
|
|
9
|
-
constructor(faces: CommandFace[]);
|
|
10
|
-
get activeFaceAdapter(): CommandFace.Adapter;
|
|
11
|
-
}
|
|
12
|
-
class GroupData extends FaceData {
|
|
13
|
-
readonly xPosition: any;
|
|
14
|
-
readonly yPosition: any;
|
|
15
|
-
readonly children: ViewData[];
|
|
16
|
-
constructor(faces: CommandFace[], xPosition: any, yPosition: any, children: ViewData[]);
|
|
17
|
-
get hasMixedIcons(): boolean;
|
|
18
|
-
}
|
|
19
|
-
class CommandData extends FaceData {
|
|
20
|
-
readonly command: Command<unknown>;
|
|
21
|
-
constructor(command: Command<unknown>, faces: CommandFace[]);
|
|
22
|
-
}
|
|
23
|
-
class SeparatorData extends ViewData {
|
|
24
|
-
}
|
|
25
|
-
class FlexData extends ViewData {
|
|
26
|
-
}
|
|
27
|
-
function as<T extends ViewData>(type: Constructable<T>, viewData: ViewData): T;
|
|
28
|
-
function getCommand(data: ViewData): Command<unknown>;
|
|
29
|
-
function getTooltip(data: ViewData): string;
|
|
30
|
-
function getStyle(data: ViewData): string;
|
|
31
|
-
function getColor(data: ViewData): ThemePalette;
|
|
32
|
-
function hasText(data: ViewData): boolean;
|
|
33
|
-
function getFaces(data: ViewData): CommandFace[];
|
|
34
|
-
function asGroup(viewData: ViewData): ViewData.GroupData;
|
|
35
|
-
function hasMixedIcons(data: ViewData): boolean;
|
|
36
|
-
function isGroup(data: ViewData): data is GroupData;
|
|
37
|
-
function hasFace(data: ViewData): data is FaceData;
|
|
38
|
-
function isCommand(data: ViewData): data is CommandData;
|
|
39
|
-
function isSeparator(data: ViewData): data is SeparatorData;
|
|
40
|
-
function isFlex(data: ViewData): data is FlexData;
|
|
41
|
-
}
|