@coolon/angular-ui-powerups 12.3.1 → 12.4.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/coolon-angular-ui-powerups-cypress.umd.js +299 -93
- package/bundles/coolon-angular-ui-powerups-cypress.umd.js.map +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.js +315 -200
- package/bundles/coolon-angular-ui-powerups.umd.js.map +1 -1
- package/coolon-angular-ui-powerups.metadata.json +1 -1
- package/cypress/components/aup-command-face.d.ts +2 -5
- package/cypress/components/aup-command.d.ts +18 -4
- package/cypress/components/aup-navigation.d.ts +0 -1
- package/cypress/components/aup-popup-menu.d.ts +2 -0
- package/cypress/components/aup-table.d.ts +19 -0
- package/cypress/components/button-mixin.d.ts +17 -0
- package/cypress/components/button.d.ts +17 -3
- package/cypress/coolon-angular-ui-powerups-cypress.d.ts +1 -0
- package/cypress/coolon-angular-ui-powerups-cypress.metadata.json +1 -1
- package/cypress/exports.d.ts +3 -0
- package/cypress/page-element.d.ts +11 -2
- package/cypress/page.d.ts +20 -13
- package/cypress/path.d.ts +26 -0
- package/cypress/section.d.ts +8 -1
- package/esm2015/cypress/components/aup-command-face.js +20 -11
- package/esm2015/cypress/components/aup-command-face.js.map +1 -1
- package/esm2015/cypress/components/aup-command-face.metadata.json +1 -1
- package/esm2015/cypress/components/aup-command.js +10 -7
- package/esm2015/cypress/components/aup-command.js.map +1 -1
- package/esm2015/cypress/components/aup-command.metadata.json +1 -1
- package/esm2015/cypress/components/aup-more-menu.js +1 -2
- package/esm2015/cypress/components/aup-more-menu.js.map +1 -1
- package/esm2015/cypress/components/aup-more-menu.metadata.json +1 -1
- package/esm2015/cypress/components/aup-navigation.js +1 -5
- package/esm2015/cypress/components/aup-navigation.js.map +1 -1
- package/esm2015/cypress/components/aup-popup-menu.js +12 -3
- package/esm2015/cypress/components/aup-popup-menu.js.map +1 -1
- package/esm2015/cypress/components/aup-popup-menu.metadata.json +1 -1
- package/esm2015/cypress/components/aup-table.js +36 -0
- package/esm2015/cypress/components/aup-table.js.map +1 -0
- package/esm2015/cypress/components/aup-table.metadata.json +1 -0
- package/esm2015/cypress/components/button-mixin.js +15 -0
- package/esm2015/cypress/components/button-mixin.js.map +1 -0
- package/esm2015/cypress/components/button-mixin.metadata.json +1 -0
- package/esm2015/cypress/components/button.js +11 -7
- package/esm2015/cypress/components/button.js.map +1 -1
- package/esm2015/cypress/components/button.metadata.json +1 -1
- package/esm2015/cypress/coolon-angular-ui-powerups-cypress.js.map +1 -1
- package/esm2015/cypress/coolon-angular-ui-powerups-cypress.metadata.json +1 -1
- package/esm2015/cypress/exports.js +3 -0
- package/esm2015/cypress/exports.js.map +1 -1
- package/esm2015/cypress/exports.metadata.json +1 -1
- package/esm2015/cypress/page-element.js +21 -5
- package/esm2015/cypress/page-element.js.map +1 -1
- package/esm2015/cypress/page-element.metadata.json +1 -1
- package/esm2015/cypress/page.js +34 -22
- package/esm2015/cypress/page.js.map +1 -1
- package/esm2015/cypress/page.metadata.json +1 -1
- package/esm2015/cypress/path.js +61 -0
- package/esm2015/cypress/path.js.map +1 -0
- package/esm2015/cypress/path.metadata.json +1 -0
- package/esm2015/cypress/section.js +20 -10
- package/esm2015/cypress/section.js.map +1 -1
- package/esm2015/lib/components/switch-case/switch-case.component.js +7 -0
- package/esm2015/lib/components/switch-case/switch-case.component.js.map +1 -1
- package/esm2015/lib/components/switch-case/switch-case.component.metadata.json +1 -1
- package/esm2015/lib/components/tables/table/table.component.js +1 -1
- package/esm2015/lib/components/tables/table/table.component.js.map +1 -1
- package/esm2015/lib/components/tables/table/table.component.metadata.json +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-table-component.js +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-table-component.js.map +1 -1
- package/esm2015/lib/components/tables/tree-table/tree-table-component.metadata.json +1 -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/consolidated-param-map.js +7 -2
- package/esm2015/lib/place/guards/consolidated-param-map.js.map +1 -1
- package/esm2015/lib/place/guards/consolidated-param-map.metadata.json +1 -1
- package/esm2015/lib/place/guards/place.guard.js +1 -22
- package/esm2015/lib/place/guards/place.guard.js.map +1 -1
- package/esm2015/lib/place/navigation/place-component-deactivation-handler.js +15 -11
- package/esm2015/lib/place/navigation/place-component-deactivation-handler.js.map +1 -1
- package/esm2015/lib/place/navigation/place-component-deactivation-handler.metadata.json +1 -1
- package/esm2015/lib/place/navigation/session/interactions/synchronise-interaction-context-ids-with-route.js.map +1 -1
- package/esm2015/lib/place/navigation/session/interactions/synchronise-interaction-context-ids-with-route.metadata.json +1 -1
- package/esm2015/lib/place/place-component.js +67 -5
- 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-definition.js +3 -3
- package/esm2015/lib/place/place-definition.js.map +1 -1
- package/esm2015/lib/place/place-router.js +9 -4
- package/esm2015/lib/place/place-router.js.map +1 -1
- package/esm2015/lib/place/place-router.metadata.json +1 -1
- package/esm2015/lib/place/route/parameter-decorators.js +13 -14
- package/esm2015/lib/place/route/parameter-decorators.js.map +1 -1
- package/esm2015/lib/place/route/parameter-decorators.metadata.json +1 -1
- package/esm2015/lib/place/route/parameter-definition.js +21 -3
- package/esm2015/lib/place/route/parameter-definition.js.map +1 -1
- package/esm2015/lib/place/route/parameter-definition.metadata.json +1 -1
- package/esm2015/lib/place/route/visit-sanitiser.js +1 -1
- package/esm2015/lib/place/route/visit-sanitiser.js.map +1 -1
- package/esm2015/lib/place/url-snapshot.js +30 -7
- package/esm2015/lib/place/url-snapshot.js.map +1 -1
- package/esm2015/lib/place/url-snapshot.metadata.json +1 -1
- package/esm2015/lib/place/visit.js +7 -7
- package/esm2015/lib/place/visit.js.map +1 -1
- package/esm2015/lib/place/visit.metadata.json +1 -1
- package/fesm2015/coolon-angular-ui-powerups-cypress.js +237 -74
- package/fesm2015/coolon-angular-ui-powerups-cypress.js.map +1 -1
- package/fesm2015/coolon-angular-ui-powerups.js +275 -180
- package/fesm2015/coolon-angular-ui-powerups.js.map +1 -1
- package/lib/components/switch-case/switch-case.component.d.ts +7 -0
- package/lib/place/guards/consolidated-param-map.d.ts +2 -2
- package/lib/place/navigation/place-component-deactivation-handler.d.ts +3 -1
- package/lib/place/place-component.d.ts +26 -3
- package/lib/place/route/parameter-definition.d.ts +8 -0
- package/lib/place/url-snapshot.d.ts +1 -0
- package/lib/place/visit.d.ts +4 -4
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
[{"__symbolic":"module","version":4,"metadata":{"ButtonMixin":{"__symbolic":"function","parameters":["Base"],"value":{"__symbolic":"class"}}}}]
|
|
@@ -1,11 +1,15 @@
|
|
|
1
1
|
import { PageElement } from '../page-element';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
2
|
+
import { ButtonMixin } from './button-mixin';
|
|
3
|
+
export class Button extends ButtonMixin(PageElement) {
|
|
4
|
+
constructor(parentElementAccessor, buttonText) {
|
|
5
|
+
super(parentElementAccessor, {
|
|
6
|
+
findIn(parent) {
|
|
7
|
+
return parent.contains('button', buttonText);
|
|
8
|
+
},
|
|
9
|
+
shouldNotExist(parent) {
|
|
10
|
+
return parent.should('not.contain', buttonText);
|
|
11
|
+
}
|
|
12
|
+
});
|
|
9
13
|
}
|
|
10
14
|
}
|
|
11
15
|
//# sourceMappingURL=button.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"button.js","sourceRoot":"","sources":["../../../../../../libs/angular-ui-powerups/cypress/src/components/button.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"button.js","sourceRoot":"","sources":["../../../../../../libs/angular-ui-powerups/cypress/src/components/button.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAC9C,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,MAAM,OAAO,MAAO,SAAQ,WAAW,CAAC,WAAW,CAAC;IAElD,YAAY,qBAAsD,EAAE,UAAkB;QACpF,KAAK,CAAC,qBAAqB,EAAE;YAC3B,MAAM,CAAC,MAAiC;gBACtC,OAAO,MAAM,CAAC,QAAQ,CAAC,QAAQ,EAAE,UAAU,CAAC,CAAC;YAC/C,CAAC;YACD,cAAc,CAAC,MAAiC;gBAC9C,OAAO,MAAM,CAAC,MAAM,CAAC,aAAa,EAAE,UAAU,CAAC,CAAC;YAClD,CAAC;SACF,CAAC,CAAC;IACL,CAAC;CAEF","sourcesContent":["import { PageElement } from '../page-element';\nimport { ButtonMixin } from './button-mixin';\n\nexport class Button extends ButtonMixin(PageElement) {\n\n constructor(parentElementAccessor: () => Cypress.Chainable<JQuery>, buttonText: string) {\n super(parentElementAccessor, {\n findIn(parent: Cypress.Chainable<JQuery>): Cypress.Chainable<JQuery> {\n return parent.contains('button', buttonText);\n },\n shouldNotExist(parent: Cypress.Chainable<JQuery>) {\n return parent.should('not.contain', buttonText);\n }\n });\n }\n\n}\n\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"__symbolic":"module","version":4,"metadata":{"Button":{"__symbolic":"class","extends":{"__symbolic":"
|
|
1
|
+
[{"__symbolic":"module","version":4,"metadata":{"Button":{"__symbolic":"class","extends":{"__symbolic":"error","message":"Symbol reference expected","line":3,"character":28},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"error","message":"Expression form not supported","line":5,"character":37},{"__symbolic":"reference","name":"string"}]}]}}}}]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coolon-angular-ui-powerups-cypress.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/cypress/src/coolon-angular-ui-powerups-cypress.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,cAAc,WAAW,CAAC","sourcesContent":["/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './exports';\n"]}
|
|
1
|
+
{"version":3,"file":"coolon-angular-ui-powerups-cypress.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/cypress/src/coolon-angular-ui-powerups-cypress.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,cAAc,WAAW,CAAC","sourcesContent":["/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './exports';\n\nexport {Types as ɵa} from './components/types';"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"__symbolic":"module","version":4,"metadata":{},"exports":[{"from":"./exports"}]}]
|
|
1
|
+
[{"__symbolic":"module","version":4,"metadata":{},"exports":[{"from":"./exports"},{"from":"./components/types","export":[{"name":"Types","as":"ɵa"}]}]}]
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export * from "./page-element";
|
|
5
5
|
export * from "./page";
|
|
6
|
+
export * from "./path";
|
|
6
7
|
export * from "./section";
|
|
7
8
|
export * from "./components/aup-command-face";
|
|
8
9
|
export * from "./components/aup-command-group";
|
|
@@ -11,7 +12,9 @@ export * from "./components/aup-input";
|
|
|
11
12
|
export * from "./components/aup-more-menu";
|
|
12
13
|
export * from "./components/aup-navigation";
|
|
13
14
|
export * from "./components/aup-popup-menu";
|
|
15
|
+
export * from "./components/aup-table";
|
|
14
16
|
export * from "./components/aup-tool-bar";
|
|
17
|
+
export * from "./components/button-mixin";
|
|
15
18
|
export * from "./components/button";
|
|
16
19
|
export * from "./components/types";
|
|
17
20
|
//# sourceMappingURL=exports.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exports.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/cypress/src/exports.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,cAAc,gBAAgB,CAAC;AAC/B,cAAc,QAAQ,CAAC;AACvB,cAAc,WAAW,CAAC;AAC1B,cAAc,+BAA+B,CAAC;AAC9C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,0BAA0B,CAAC;AACzC,cAAc,wBAAwB,CAAC;AACvC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC","sourcesContent":["/**\n * @file Automatically generated by barrelsby.\n */\n\nexport * from \"./page-element\";\nexport * from \"./page\";\nexport * from \"./section\";\nexport * from \"./components/aup-command-face\";\nexport * from \"./components/aup-command-group\";\nexport * from \"./components/aup-command\";\nexport * from \"./components/aup-input\";\nexport * from \"./components/aup-more-menu\";\nexport * from \"./components/aup-navigation\";\nexport * from \"./components/aup-popup-menu\";\nexport * from \"./components/aup-tool-bar\";\nexport * from \"./components/button\";\nexport * from \"./components/types\";\n"]}
|
|
1
|
+
{"version":3,"file":"exports.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/cypress/src/exports.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,cAAc,gBAAgB,CAAC;AAC/B,cAAc,QAAQ,CAAC;AACvB,cAAc,QAAQ,CAAC;AACvB,cAAc,WAAW,CAAC;AAC1B,cAAc,+BAA+B,CAAC;AAC9C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,0BAA0B,CAAC;AACzC,cAAc,wBAAwB,CAAC;AACvC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,wBAAwB,CAAC;AACvC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC","sourcesContent":["/**\n * @file Automatically generated by barrelsby.\n */\n\nexport * from \"./page-element\";\nexport * from \"./page\";\nexport * from \"./path\";\nexport * from \"./section\";\nexport * from \"./components/aup-command-face\";\nexport * from \"./components/aup-command-group\";\nexport * from \"./components/aup-command\";\nexport * from \"./components/aup-input\";\nexport * from \"./components/aup-more-menu\";\nexport * from \"./components/aup-navigation\";\nexport * from \"./components/aup-popup-menu\";\nexport * from \"./components/aup-table\";\nexport * from \"./components/aup-tool-bar\";\nexport * from \"./components/button-mixin\";\nexport * from \"./components/button\";\nexport * from \"./components/types\";\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"__symbolic":"module","version":4,"metadata":{},"exports":[{"from":"./page-element"},{"from":"./page"},{"from":"./section"},{"from":"./components/aup-command-face"},{"from":"./components/aup-command-group"},{"from":"./components/aup-command"},{"from":"./components/aup-input"},{"from":"./components/aup-more-menu"},{"from":"./components/aup-navigation"},{"from":"./components/aup-popup-menu"},{"from":"./components/aup-tool-bar"},{"from":"./components/button"},{"from":"./components/types"}]}]
|
|
1
|
+
[{"__symbolic":"module","version":4,"metadata":{},"exports":[{"from":"./page-element"},{"from":"./page"},{"from":"./path"},{"from":"./section"},{"from":"./components/aup-command-face"},{"from":"./components/aup-command-group"},{"from":"./components/aup-command"},{"from":"./components/aup-input"},{"from":"./components/aup-more-menu"},{"from":"./components/aup-navigation"},{"from":"./components/aup-popup-menu"},{"from":"./components/aup-table"},{"from":"./components/aup-tool-bar"},{"from":"./components/button-mixin"},{"from":"./components/button"},{"from":"./components/types"}]}]
|
|
@@ -1,9 +1,22 @@
|
|
|
1
|
+
import * as _ from 'lodash';
|
|
2
|
+
import { lang } from '@coolon/typescript-utilities';
|
|
1
3
|
export class PageElement {
|
|
2
|
-
constructor(
|
|
3
|
-
this.
|
|
4
|
+
constructor(parent, selector) {
|
|
5
|
+
this.parentElementAccessor = parent instanceof PageElement ? () => parent.element() : parent;
|
|
6
|
+
this.elementAccessStrategy = _.isString(selector) ? {
|
|
7
|
+
findIn: p => p.find(selector),
|
|
8
|
+
shouldNotExist: (p) => p.should('not.have', selector)
|
|
9
|
+
} : selector;
|
|
4
10
|
}
|
|
5
11
|
element() {
|
|
6
|
-
|
|
12
|
+
const parent = this.getParentElement();
|
|
13
|
+
return parent ? this.elementAccessStrategy.findIn(parent) : undefined;
|
|
14
|
+
}
|
|
15
|
+
getParentElement() {
|
|
16
|
+
return this.parentElementAccessor ? this.parentElementAccessor() : undefined;
|
|
17
|
+
}
|
|
18
|
+
find(selector) {
|
|
19
|
+
return new PageElement(() => this.element(), selector);
|
|
7
20
|
}
|
|
8
21
|
click(text) {
|
|
9
22
|
text ? this.element().contains(text).click() : this.element().click();
|
|
@@ -12,10 +25,13 @@ export class PageElement {
|
|
|
12
25
|
return this.element().should;
|
|
13
26
|
}
|
|
14
27
|
shouldBeVisible() {
|
|
15
|
-
this.should(
|
|
28
|
+
this.should('be.visible');
|
|
16
29
|
}
|
|
17
30
|
shouldNotBeVisible() {
|
|
18
|
-
this.
|
|
31
|
+
if (!this.elementAccessStrategy.shouldNotExist) {
|
|
32
|
+
lang.abstractMethod(this.constructor);
|
|
33
|
+
}
|
|
34
|
+
this.elementAccessStrategy.shouldNotExist(this.getParentElement());
|
|
19
35
|
}
|
|
20
36
|
}
|
|
21
37
|
//# sourceMappingURL=page-element.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"page-element.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/cypress/src/page-element.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"page-element.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/cypress/src/page-element.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAC5B,OAAO,EAAE,IAAI,EAAE,MAAM,8BAA8B,CAAC;AAEpD,MAAM,OAAO,WAAW;IAKtB,YAAY,MAAuD,EAAE,QAAuC;QAE1G,IAAI,CAAC,qBAAqB,GAAG,MAAM,YAAY,WAAW,CAAC,CAAC,CAAC,GAAG,EAAE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AI,CAAC,qBAAqB,CAAC,cAAc,EAAE;YAC9C,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;SACvC;QACD,IAAI,CAAC,qBAAqB,CAAC,cAAc,CAAC,IAAI,CAAC,gBAAgB,EAAE,CAAC,CAAA;IACpE,CAAC;CACF","sourcesContent":["import Chainable = Cypress.Chainable;\nimport * as _ from 'lodash';\nimport { lang } from '@coolon/typescript-utilities';\n\nexport class PageElement {\n\n readonly elementAccessStrategy: PageElement.Accessor;\n readonly parentElementAccessor: () => Cypress.Chainable<JQuery>;\n\n constructor(parent: PageElement | (() => Cypress.Chainable<JQuery>), selector: string | PageElement.Accessor) {\n\n this.parentElementAccessor = parent instanceof PageElement ? () => parent.element() : parent;\n this.elementAccessStrategy = _.isString(selector) ? {\n findIn: p => p.find(selector),\n shouldNotExist: (p: Cypress.Chainable<JQuery>) => p.should('not.have', selector)\n } : selector\n }\n\n element(): Chainable<JQuery> {\n const parent = this.getParentElement();\n return parent ? this.elementAccessStrategy.findIn(parent) : undefined;\n }\n\n getParentElement(): Cypress.Chainable<JQuery> {\n return this.parentElementAccessor ? this.parentElementAccessor() : undefined;\n }\n\n find(selector: string): PageElement {\n return new PageElement(() => this.element(), selector);\n }\n\n click(text?: string) {\n text ? this.element().contains(text).click() : this.element().click();\n }\n\n get should() {\n return this.element().should;\n }\n\n shouldBeVisible() {\n this.should('be.visible');\n }\n\n shouldNotBeVisible() {\n if (!this.elementAccessStrategy.shouldNotExist) {\n lang.abstractMethod(this.constructor);\n }\n this.elementAccessStrategy.shouldNotExist(this.getParentElement())\n }\n}\n\nexport namespace PageElement {\n export interface Accessor {\n findIn(parent: Cypress.Chainable<JQuery>): Cypress.Chainable<JQuery>;\n shouldNotExist?(parent: Cypress.Chainable<JQuery>);\n }\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"__symbolic":"module","version":4,"metadata":{"PageElement":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"error","message":"Expression form not supported","line":
|
|
1
|
+
[{"__symbolic":"module","version":4,"metadata":{"PageElement":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"error","message":"Expression form not supported","line":9,"character":36},{"__symbolic":"select","expression":{"__symbolic":"reference","name":"PageElement"},"member":"Accessor"}]}],"element":[{"__symbolic":"method"}],"getParentElement":[{"__symbolic":"method"}],"find":[{"__symbolic":"method"}],"click":[{"__symbolic":"method"}],"shouldBeVisible":[{"__symbolic":"method"}],"shouldNotBeVisible":[{"__symbolic":"method"}]}}}}]
|
package/esm2015/cypress/page.js
CHANGED
|
@@ -1,21 +1,25 @@
|
|
|
1
1
|
import { Mixin } from '@coolon/typescript-utilities';
|
|
2
|
+
import * as _ from 'lodash';
|
|
2
3
|
import { PageElement } from './page-element';
|
|
4
|
+
import { Path } from './path';
|
|
3
5
|
import { Section } from './section';
|
|
4
6
|
export class Page extends PageElement {
|
|
5
7
|
constructor(path) {
|
|
6
|
-
super();
|
|
8
|
+
super(undefined, undefined);
|
|
7
9
|
this.path = path;
|
|
8
10
|
this.rootElementSelector = 'body';
|
|
9
11
|
}
|
|
10
12
|
element() {
|
|
11
13
|
return cy.get(this.rootElementSelector);
|
|
12
14
|
}
|
|
13
|
-
visit() {
|
|
14
|
-
this.tryAndVisit();
|
|
15
|
-
this.shouldBeActive();
|
|
15
|
+
visit(visitParams, queryParams) {
|
|
16
|
+
this.tryAndVisit(visitParams, queryParams);
|
|
17
|
+
this.shouldBeActive(visitParams);
|
|
16
18
|
}
|
|
17
|
-
tryAndVisit() {
|
|
18
|
-
|
|
19
|
+
tryAndVisit(params, queryParams) {
|
|
20
|
+
const path = this.path.toUrl(params !== null && params !== void 0 ? params : {});
|
|
21
|
+
const queryString = queryParams ? `?${new URLSearchParams(queryParams).toString()}` : '';
|
|
22
|
+
cy.visit(`/${path}${queryString}`);
|
|
19
23
|
}
|
|
20
24
|
shouldHaveActivityIds(...ids) {
|
|
21
25
|
cy.location('search').should('contain', `?aup-interactions=${ids.join('--')}`);
|
|
@@ -23,35 +27,43 @@ export class Page extends PageElement {
|
|
|
23
27
|
shouldNotHaveActivityIds() {
|
|
24
28
|
cy.location('search').should('not.contain', `?aup-interactions`);
|
|
25
29
|
}
|
|
26
|
-
|
|
30
|
+
shouldHaveTitle(title) {
|
|
31
|
+
cy.title().should('eq', title);
|
|
32
|
+
}
|
|
33
|
+
shouldBeActive(withParameters) {
|
|
27
34
|
// Note: cy.window() doesn't return a promise... it's a chainable.
|
|
28
35
|
cy.window().then(window => {
|
|
29
36
|
cy['waitUntil'](() => {
|
|
30
37
|
return window['aup.PlaceRouter'] && !window['aup.PlaceRouter'].isNavigating();
|
|
31
38
|
});
|
|
32
39
|
});
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
if (options && options.withTitle) {
|
|
43
|
-
cy.title().should('eq', options.withTitle);
|
|
40
|
+
if (withParameters) {
|
|
41
|
+
cy.location('pathname').then(path => {
|
|
42
|
+
const urlParams = Path.extractVisitParameters(path);
|
|
43
|
+
Object.keys(withParameters).forEach(param => {
|
|
44
|
+
const expected = withParameters[param];
|
|
45
|
+
// @ts-ignore
|
|
46
|
+
expect(urlParams[param]).to.equal(expected);
|
|
47
|
+
});
|
|
48
|
+
});
|
|
44
49
|
}
|
|
45
50
|
}
|
|
46
51
|
}
|
|
47
52
|
(function (Page) {
|
|
48
|
-
function create(
|
|
49
|
-
const
|
|
53
|
+
function create(pathOrPathBuilder, page) {
|
|
54
|
+
const pathBuilder = new Path.Builder();
|
|
55
|
+
if (_.isString(pathOrPathBuilder)) {
|
|
56
|
+
pathOrPathBuilder.split("/").filter(p => !_.isEmpty(p)).forEach(p => pathBuilder.segment(p));
|
|
57
|
+
}
|
|
58
|
+
else {
|
|
59
|
+
pathOrPathBuilder(pathBuilder);
|
|
60
|
+
}
|
|
61
|
+
const builder = new PageBuilder(pathBuilder.getPath());
|
|
50
62
|
return Mixin.createProxy(page(builder), builder);
|
|
51
63
|
}
|
|
52
64
|
Page.create = create;
|
|
53
|
-
class
|
|
65
|
+
class PageBuilder extends Section.Mixin(Page) {
|
|
54
66
|
}
|
|
55
|
-
Page.
|
|
67
|
+
Page.PageBuilder = PageBuilder;
|
|
56
68
|
})(Page || (Page = {}));
|
|
57
69
|
//# sourceMappingURL=page.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"page.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/cypress/src/page.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,8BAA8B,CAAC;AACrD,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC,MAAM,OAAO,IAAK,SAAQ,WAAW;IAInC,YAAqB,
|
|
1
|
+
{"version":3,"file":"page.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/cypress/src/page.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,8BAA8B,CAAC;AACrD,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAC5B,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC,MAAM,OAAO,IAAK,SAAQ,WAAW;IAInC,YAAqB,IAAU;QAC7B,KAAK,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC;QADT,SAAI,GAAJ,IAAI,CAAM;QAFrB,wBAAmB,GAAG,MAAM,CAAC;IAIvC,CAAC;IAED,OAAO;QACL,OAAO,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,mBAAmB,CAAC,CAAC;IAC1C,C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AAC,IAAI,CAAC;KACnD;IADY,gBAAW,cACvB,CAAA;AAEH,CAAC,EArBgB,IAAI,KAAJ,IAAI,QAqBpB","sourcesContent":["import { Mixin } from '@coolon/typescript-utilities';\nimport * as _ from 'lodash';\nimport { PageElement } from './page-element';\nimport { Path } from './path';\nimport { Section } from './section';\n\nexport class Page extends PageElement {\n\n protected rootElementSelector = 'body';\n\n constructor(readonly path: Path) {\n super(undefined, undefined);\n }\n\n element(): Cypress.Chainable<JQuery<HTMLElement>> {\n return cy.get(this.rootElementSelector);\n }\n\n visit(visitParams?: object, queryParams?: {[key:string]:string}) {\n this.tryAndVisit(visitParams, queryParams);\n this.shouldBeActive(visitParams);\n }\n\n tryAndVisit(params?: object, queryParams?: {[key:string]:string}) {\n const path = this.path.toUrl(params ?? {});\n const queryString = queryParams ? `?${new URLSearchParams(queryParams).toString()}` : '';\n cy.visit(`/${path}${queryString}`);\n }\n shouldHaveActivityIds(...ids: string[]) {\n cy.location('search').should('contain', `?aup-interactions=${ids.join('--')}`);\n }\n\n shouldNotHaveActivityIds() {\n cy.location('search').should('not.contain', `?aup-interactions`);\n }\n\n shouldHaveTitle(title: string) {\n cy.title().should('eq', title);\n }\n\n shouldBeActive(withParameters?: object) {\n // Note: cy.window() doesn't return a promise... it's a chainable.\n cy.window().then(window => {\n cy['waitUntil'](() => {\n return window['aup.PlaceRouter'] && !window['aup.PlaceRouter'].isNavigating();\n });\n });\n\n\n if (withParameters) {\n cy.location('pathname').then(path => {\n const urlParams = Path.extractVisitParameters(path);\n Object.keys(withParameters).forEach(param => {\n const expected = withParameters[param];\n // @ts-ignore\n expect(urlParams[param]).to.equal(expected);\n })\n });\n }\n }\n\n}\n\n\nexport namespace Page {\n\n\n export function create<T extends object>(path: string, page: (page: PageBuilder) => T): T & Page\n // tslint:disable-next-line:unified-signatures\n export function create<T extends object>(pathBuilder: ((pathBuilder: Path.Builder) => void), page: (page: PageBuilder) => T): T & Page\n export function create<T extends object>(pathOrPathBuilder: string | ((pathBuilder: Path.Builder) => void), page: (page: PageBuilder) => T): T & Page {\n const pathBuilder = new Path.Builder();\n if (_.isString(pathOrPathBuilder)) {\n pathOrPathBuilder.split(\"/\").filter(p => !_.isEmpty(p)).forEach(p => pathBuilder.segment(p))\n } else {\n pathOrPathBuilder(pathBuilder)\n }\n const builder = new PageBuilder(pathBuilder.getPath());\n return Mixin.createProxy(page(builder), builder) as T & Page;\n }\n\n\n export class PageBuilder extends Section.Mixin(Page) {\n }\n\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"__symbolic":"module","version":4,"metadata":{"Page":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"./page-element","name":"PageElement","line":
|
|
1
|
+
[{"__symbolic":"module","version":4,"metadata":{"Page":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"./page-element","name":"PageElement","line":6,"character":26},"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"./path","name":"Path","line":10,"character":29}]}],"element":[{"__symbolic":"method"}],"visit":[{"__symbolic":"method"}],"tryAndVisit":[{"__symbolic":"method"}],"shouldHaveActivityIds":[{"__symbolic":"method"}],"shouldNotHaveActivityIds":[{"__symbolic":"method"}],"shouldHaveTitle":[{"__symbolic":"method"}],"shouldBeActive":[{"__symbolic":"method"}]}}}}]
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { DefaultUrlSerializer } from '@angular/router';
|
|
2
|
+
let urlSerialiser = new DefaultUrlSerializer();
|
|
3
|
+
export class Path {
|
|
4
|
+
constructor(segments) {
|
|
5
|
+
this.segments = segments;
|
|
6
|
+
}
|
|
7
|
+
static extractVisitParameters(url) {
|
|
8
|
+
let result = {};
|
|
9
|
+
const urlTree = urlSerialiser.parse(url);
|
|
10
|
+
urlTree.root.children.primary.segments.forEach(s => {
|
|
11
|
+
result = Object.assign(Object.assign({}, result), s.parameters);
|
|
12
|
+
});
|
|
13
|
+
return result;
|
|
14
|
+
}
|
|
15
|
+
toUrl(matrixParams) {
|
|
16
|
+
return this.segments.map(s => s.toUrlPart(matrixParams)).join('/');
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
(function (Path) {
|
|
20
|
+
function setUrlSerialiser(serialiser) {
|
|
21
|
+
urlSerialiser = serialiser;
|
|
22
|
+
}
|
|
23
|
+
Path.setUrlSerialiser = setUrlSerialiser;
|
|
24
|
+
class Segment {
|
|
25
|
+
constructor(path, params = {}) {
|
|
26
|
+
var _a;
|
|
27
|
+
this.path = path;
|
|
28
|
+
this.routeId = params === null || params === void 0 ? void 0 : params.routeId;
|
|
29
|
+
this.visitParams = (_a = params === null || params === void 0 ? void 0 : params.visitParams) !== null && _a !== void 0 ? _a : [];
|
|
30
|
+
}
|
|
31
|
+
toUrlPart(params) {
|
|
32
|
+
let path = this.path;
|
|
33
|
+
this.visitParams.forEach(p => {
|
|
34
|
+
const value = params[p];
|
|
35
|
+
if (value) {
|
|
36
|
+
path = `${path};${p}=${value}`;
|
|
37
|
+
}
|
|
38
|
+
});
|
|
39
|
+
if (this.routeId && params[this.routeId]) {
|
|
40
|
+
path = path + '/' + params[this.routeId];
|
|
41
|
+
}
|
|
42
|
+
return path;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
Path.Segment = Segment;
|
|
46
|
+
class Builder {
|
|
47
|
+
constructor() {
|
|
48
|
+
this.segments = [];
|
|
49
|
+
}
|
|
50
|
+
segment(name, params) {
|
|
51
|
+
const builder = new Segment(name, params);
|
|
52
|
+
this.segments.push(builder);
|
|
53
|
+
return this;
|
|
54
|
+
}
|
|
55
|
+
getPath() {
|
|
56
|
+
return new Path(this.segments);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
Path.Builder = Builder;
|
|
60
|
+
})(Path || (Path = {}));
|
|
61
|
+
//# sourceMappingURL=path.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"path.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/cypress/src/path.ts"],"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AAC,IAAI,CAAC;YAC7B,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE;gBAC3B,MAAM,KAAK,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;gBACxB,IAAI,KAAK,EAAE;oBACT,IAAI,GAAG,GAAG,IAAI,IAAI,CAAC,IAAI,KAAK,EAAE,CAAC;iBAChC;YACH,CAAC,CAAC,CAAC;YACH,IAAI,IAAI,CAAC,OAAO,IAAI,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE;gBACxC,IAAI,GAAG,IAAI,GAAG,GAAG,GAAG,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;aAC1C;YACD,OAAO,IAAI,CAAC;QACd,CAAC;KAEF;IAxBY,YAAO,UAwBnB,CAAA;IAED,MAAa,OAAO;QAApB;YAEU,aAAQ,GAAc,EAAE,CAAC;QAWnC,CAAC;QATC,OAAO,CAAC,IAAY,EAAE,MAAsB;YAC1C,MAAM,OAAO,GAAG,IAAI,OAAO,CAAC,IAAI,EAAE,MAAM,CAAC,CAAC;YAC1C,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;YAC5B,OAAO,IAAI,CAAC;QACd,CAAC;QAED,OAAO;YACL,OAAO,IAAI,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;QACjC,CAAC;KACF;IAbY,YAAO,UAanB,CAAA;AAMH,CAAC,EAnDgB,IAAI,KAAJ,IAAI,QAmDpB","sourcesContent":["import { DefaultUrlSerializer, UrlSerializer } from '@angular/router';\n\nlet urlSerialiser: UrlSerializer = new DefaultUrlSerializer();\n\nexport class Path {\n\n constructor(readonly segments: Path.Segment[]) {\n }\n\n static extractVisitParameters(url: string): object {\n let result = {};\n const urlTree = urlSerialiser.parse(url);\n urlTree.root.children.primary.segments.forEach(s => {\n result = { ...result, ...s.parameters }\n });\n return result;\n }\n\n toUrl(matrixParams: object): string {\n return this.segments.map(s => s.toUrlPart(matrixParams)).join('/');\n }\n\n}\n\nexport namespace Path {\n\n export function setUrlSerialiser(serialiser: UrlSerializer) {\n urlSerialiser = serialiser;\n }\n\n export class Segment {\n\n private routeId: string | undefined;\n private visitParams: string[];\n\n constructor(readonly path: string, params: SegmentParams = {}) {\n this.routeId = params?.routeId;\n this.visitParams = params?.visitParams ?? [];\n }\n\n toUrlPart(params: object) {\n let path: string = this.path;\n this.visitParams.forEach(p => {\n const value = params[p];\n if (value) {\n path = `${path};${p}=${value}`;\n }\n });\n if (this.routeId && params[this.routeId]) {\n path = path + '/' + params[this.routeId];\n }\n return path;\n }\n\n }\n\n export class Builder {\n\n private segments: Segment[] = [];\n\n segment(name: string, params?: SegmentParams): this {\n const builder = new Segment(name, params);\n this.segments.push(builder);\n return this;\n }\n\n getPath(): Path {\n return new Path(this.segments);\n }\n }\n\n export interface SegmentParams {\n routeId?: string;\n visitParams?: string[]\n }\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
[{"__symbolic":"module","version":4,"metadata":{"Path":{"__symbolic":"class","members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"Array","arguments":[{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Path"},"member":"Segment"}]}]}],"toUrl":[{"__symbolic":"method"}]}}}}]
|
|
@@ -2,6 +2,7 @@ import { Mixin as CreateMixin } from '@coolon/typescript-utilities';
|
|
|
2
2
|
import { AupCommand } from './components/aup-command';
|
|
3
3
|
import { AupInput } from './components/aup-input';
|
|
4
4
|
import { AupNavigation } from './components/aup-navigation';
|
|
5
|
+
import { AupTable } from './components/aup-table';
|
|
5
6
|
import { Button } from './components/button';
|
|
6
7
|
import { PageElement } from './page-element';
|
|
7
8
|
export var Section;
|
|
@@ -9,35 +10,44 @@ export var Section;
|
|
|
9
10
|
function Mixin(Base) {
|
|
10
11
|
return class extends Base {
|
|
11
12
|
section(selector, section) {
|
|
12
|
-
const impl = new Impl(() => this.element()
|
|
13
|
+
const impl = new Impl(() => this.element(), selector);
|
|
13
14
|
return CreateMixin.createProxy(section(impl), impl);
|
|
14
15
|
}
|
|
16
|
+
find(selector) {
|
|
17
|
+
return new PageElement(() => this.element(), selector);
|
|
18
|
+
}
|
|
15
19
|
contains(text) {
|
|
16
|
-
return new PageElement(() => this.element()
|
|
20
|
+
return new PageElement(() => this.element(), {
|
|
21
|
+
findIn: parent => parent.contains(text),
|
|
22
|
+
shouldNotExist: (parent) => parent.should("not.contain", text)
|
|
23
|
+
});
|
|
17
24
|
}
|
|
18
25
|
button(text) {
|
|
19
|
-
return new Button(() => this.element()
|
|
26
|
+
return new Button(() => this.element(), text);
|
|
20
27
|
}
|
|
21
28
|
aupStringInput(selector) {
|
|
22
|
-
return new AupInput.HtmlInput(() => this.element()
|
|
29
|
+
return new AupInput.HtmlInput(() => this.element(), selector !== null && selector !== void 0 ? selector : 'aup-string-input');
|
|
23
30
|
}
|
|
24
31
|
aupTextInput(selector) {
|
|
25
|
-
return new AupInput.TextAreaInput(() => this.element()
|
|
32
|
+
return new AupInput.TextAreaInput(() => this.element(), selector !== null && selector !== void 0 ? selector : 'aup-text-input');
|
|
26
33
|
}
|
|
27
34
|
aupPasswordInput(selector) {
|
|
28
|
-
return new AupInput.HtmlInput(() => this.element()
|
|
35
|
+
return new AupInput.HtmlInput(() => this.element(), selector !== null && selector !== void 0 ? selector : 'aup-password-input');
|
|
29
36
|
}
|
|
30
37
|
aupNumberInput(selector) {
|
|
31
|
-
return new AupInput.HtmlInput(() => this.element()
|
|
38
|
+
return new AupInput.HtmlInput(() => this.element(), selector !== null && selector !== void 0 ? selector : 'aup-number-input');
|
|
32
39
|
}
|
|
33
40
|
aupCommand(face) {
|
|
34
|
-
return AupCommand.
|
|
41
|
+
return new AupCommand(() => this.element(), face);
|
|
35
42
|
}
|
|
36
43
|
aupTabbedNavigation() {
|
|
37
|
-
return AupNavigation.
|
|
44
|
+
return new AupNavigation(() => this.element(), 'aup-tabbed-place-navigation');
|
|
38
45
|
}
|
|
39
46
|
aupSideNavigation() {
|
|
40
|
-
return AupNavigation.
|
|
47
|
+
return new AupNavigation(() => this.element(), 'aup-list-place-nav');
|
|
48
|
+
}
|
|
49
|
+
aupTable(selector) {
|
|
50
|
+
return new AupTable(() => this.element(), selector !== null && selector !== void 0 ? selector : 'aup-table');
|
|
41
51
|
}
|
|
42
52
|
};
|
|
43
53
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"section.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/cypress/src/section.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,IAAI,WAAW,EAAE,MAAM,8BAA8B,CAAC;AACpE,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AACtD,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAClD,OAAO,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAE7C,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"section.js","sourceRoot":"","sources":["../../../../../libs/angular-ui-powerups/cypress/src/section.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,IAAI,WAAW,EAAE,MAAM,8BAA8B,CAAC;AACpE,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AACtD,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAClD,OAAO,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAC;AAC5D,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAClD,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAE7C,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAoC7C,MAAM,KAAW,OAAO,CA+EvB;AA/ED,WAAiB,OAAO;IAEtB,SAAgB,KAAK,CAAwC,IAAQ;QAEnE,O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AAC;YAED,gBAAgB,CAAC,QAAiB;gBAChC,OAAO,IAAI,QAAQ,CAAC,SAAS,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,OAAO,EAAE,EAAE,QAAQ,aAAR,QAAQ,cAAR,QAAQ,GAAI,oBAAoB,CAAC,CAAC;YACxF,CAAC;YAED,cAAc,CAAC,QAAiB;gBAC9B,OAAO,IAAI,QAAQ,CAAC,SAAS,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,OAAO,EAAE,EAAE,QAAQ,aAAR,QAAQ,cAAR,QAAQ,GAAI,kBAAkB,CAAC,CAAC;YACtF,CAAC;YAED,UAAU,CAAC,IAAuB;gBAChC,OAAO,IAAI,UAAU,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,OAAO,EAAE,EAAE,IAAI,CAAC,CAAC;YACpD,CAAC;YAED,mBAAmB;gBACjB,OAAO,IAAI,aAAa,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,OAAO,EAAE,EAAE,6BAA6B,CAAC,CAAC;YAChF,CAAC;YAED,iBAAiB;gBACf,OAAO,IAAI,aAAa,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,OAAO,EAAE,EAAE,oBAAoB,CAAC,CAAC;YACvE,CAAC;YAED,QAAQ,CAAC,QAAiB;gBACxB,OAAO,IAAI,QAAQ,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,OAAO,EAAE,EAAE,QAAQ,aAAR,QAAQ,cAAR,QAAQ,GAAI,WAAW,CAAC,CAAC;YACrE,CAAC;SAgBF,CAAC;IACJ,CAAC;IAvEe,aAAK,QAuEpB,CAAA;IAED,MAAM,IAAK,SAAQ,KAAK,CAAC,WAAW,CAAC;KACpC;AAGH,CAAC,EA/EgB,OAAO,KAAP,OAAO,QA+EvB","sourcesContent":["import { Constructable } from '@coolon/pectin';\nimport { Mixin as CreateMixin } from '@coolon/typescript-utilities';\nimport { AupCommand } from './components/aup-command';\nimport { AupInput } from './components/aup-input';\nimport { AupNavigation } from './components/aup-navigation';\nimport { AupTable } from './components/aup-table';\nimport { Button } from './components/button';\nimport { Types } from './components/types';\nimport { PageElement } from './page-element';\n\nexport interface Section {\n section<T extends object>(selector: string, section: (section: Section) => T): T & PageElement;\n\n find(selector: string): PageElement;\n\n contains(text: string): PageElement;\n\n button(text: string): Button;\n\n aupStringInput(selector?: string): AupInput<string>;\n\n aupTextInput(selector?: string): AupInput<string>;\n\n aupPasswordInput(selector?: string): AupInput<string>;\n\n aupNumberInput(selector?: string): AupInput<number>;\n\n aupCommand(face: Types.CommandFace): AupCommand;\n\n // aupToolbar<T extends object>(builder: () => T): AupToolBar & T\n //\n // aupToolbar<T extends object>(selector: string, builder: () => T): AupToolBar & T\n //\n // aupToolbar<T extends object>(selectorOrBuilder: string | (() => T), builder?: () => T): AupToolBar & T\n //\n // aupPopupMenu<T extends object>(face: CommandFace, builder: () => T): AupPopupMenu & T\n\n aupTabbedNavigation<T extends object>(): AupNavigation;\n aupSideNavigation<T extends object>(): AupNavigation;\n aupTable(selector?: string):AupTable;\n\n}\n\n\nexport namespace Section {\n\n export function Mixin<BC extends Constructable<PageElement>>(Base: BC) {\n\n return class extends Base implements Section {\n\n section<T extends object>(selector: string, section: (section: Section) => T): T & PageElement {\n const impl = new Impl(() => this.element(), selector);\n return CreateMixin.createProxy(section(impl), impl);\n }\n\n find(selector: string): PageElement {\n return new PageElement(() => this.element(), selector);\n }\n\n contains(text: string): PageElement {\n return new PageElement(() => this.element(), {\n findIn: parent => parent.contains(text),\n shouldNotExist: (parent: Cypress.Chainable<JQuery>) => parent.should(\"not.contain\", text)\n });\n }\n\n button(text: string): Button {\n return new Button(() => this.element(), text);\n }\n\n aupStringInput(selector?: string): AupInput<string> {\n return new AupInput.HtmlInput(() => this.element(), selector ?? 'aup-string-input');\n }\n\n aupTextInput(selector?: string): AupInput<string> {\n return new AupInput.TextAreaInput(() => this.element(), selector ?? 'aup-text-input');\n }\n\n aupPasswordInput(selector?: string): AupInput<string> {\n return new AupInput.HtmlInput(() => this.element(), selector ?? 'aup-password-input');\n }\n\n aupNumberInput(selector?: string): AupInput<number> {\n return new AupInput.HtmlInput(() => this.element(), selector ?? 'aup-number-input');\n }\n\n aupCommand(face: Types.CommandFace): AupCommand {\n return new AupCommand(() => this.element(), face);\n }\n\n aupTabbedNavigation<T extends object>(): AupNavigation {\n return new AupNavigation(() => this.element(), 'aup-tabbed-place-navigation');\n }\n\n aupSideNavigation<T extends object>(): AupNavigation {\n return new AupNavigation(() => this.element(), 'aup-list-place-nav');\n }\n\n aupTable(selector?: string):AupTable {\n return new AupTable(() => this.element(), selector ?? 'aup-table');\n }\n\n // aupToolbar<T extends object>(builder: () => T): AupToolBar\n // aupToolbar<T extends object>(selector: string, builder: () => T): AupToolBar\n // aupToolbar<T extends object>(selectorOrBuilder: string | (() => T), builder?: () => T): AupToolBar {\n // return lang.notImplemented();\n // }\n //\n // aupPopupMenu<T extends object>(face: CommandFace, builder: () => T): AupPopupMenu & T {\n // return lang.notImplemented();\n // }\n //\n // aupMoreMenu<T extends object>(builder: () => T): AupPopupMenu & T {\n // return lang.notImplemented();\n // }\n\n };\n }\n\n class Impl extends Mixin(PageElement) {\n }\n\n\n}\n"]}
|
|
@@ -49,6 +49,13 @@ SwitchCaseDefaultDirective.decorators = [
|
|
|
49
49
|
SwitchCaseDefaultDirective.ctorParameters = () => [
|
|
50
50
|
{ type: TemplateRef }
|
|
51
51
|
];
|
|
52
|
+
/**
|
|
53
|
+
* @example
|
|
54
|
+
* <aup-switch-case [switchModel]="booleanModel">
|
|
55
|
+
* <div *aupSwitchCaseWhen="true"></div>
|
|
56
|
+
* <div *aupSwitchCaseDefault>The default content</div>
|
|
57
|
+
* </aup-switch-case>
|
|
58
|
+
*/
|
|
52
59
|
export class SwitchCaseComponent extends DisposableComponent {
|
|
53
60
|
constructor(cdr) {
|
|
54
61
|
super();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"switch-case.component.js","sourceRoot":"","sources":["../../../../../../../lib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0B,EAAE,CAAC;aACpF;;;YAzCC,WAAW;;
|
|
1
|
+
{"version":3,"file":"switch-case.component.js","sourceRoot":"","sources":["../../../../../../../libs/angular-ui-powerups/src/lib/components/switch-case/switch-case.component.ts"],"names":[],"mappings":";AAAA,OAAO,EAEL,iBAAiB,EACjB,SAAS,EACT,eAAe,EACf,SAAS,EACT,KAAK,EAEL,SAAS,EACT,WAAW,EACZ,MAAM,eAAe,CAAC;AAEvB,OAAO,EAAE,GAAG,EAAE,iBAAiB,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AACnF,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAG9D,MAAM,OAAgB,gBAAgB;IAIpC,YAAqB,WAAgC;QAAhC,gBAAW,GAAX,WAAW,CAAqB;IACrD,CAAC;IAED,IAAI,IAAI;QACN,OAAO,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC;IAC/B,CAAC;CAGF;AAMD,MAAM,OAAO,uBAA2B,SAAQ,gBAAmB;IAIjE,YAAY,WAAgC;QAC1C,KAAK,CAAC,WAAW,CAAC,CAAC;QAHZ,cAAS,GAAG,KAAK,CAAC;IAI3B,CAAC;IAED,OAAO,CAAC,KAAQ;QACd,OAAO,IAAI,CAAC,iBAAiB,KAAK,KAAK,CAAC;IAC1C,CAAC;;;YAdF,SAAS,SAAC;gBACT,QAAQ,EAAE,qBAAqB;gBAC/B,SAAS,EAAE,CAAC,EAAE,OAAO,EAAE,gBAAgB,EAAE,WAAW,EAAE,uBAAuB,EAAE,CAAC;aACjF;;;YAxBC,WAAW;;;gCA0BV,KAAK;;AAgBR,MAAM,OAAO,0BAA8B,SAAQ,gBAAmB;IAGpE,YAAY,WAAgC;QAC1C,KAAK,CAAC,WAAW,CAAC,CAAC;QAHZ,cAAS,GAAG,IAAI,CAAC;IAI1B,CAAC;IAED,OAAO,CAAC,KAAQ;QACd,OAAO,KAAK,CAAC;IACf,CAAC;;;YAbF,SAAS,SAAC;gB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AAO,CAAC,IAAI,CAAC,SAAS,gBAAgB,CAAC,MAAM,8CAA8C,CAAC,CAAC;SAC9F;QACD,IAAI,gBAAgB,CAAC,MAAM,KAAK,CAAC,EAAE;YACjC,IAAI,CAAC,iBAAiB,CAAC,OAAO,CAAC,CAAC,MAAM,EAAE,KAAK,EAAE,EAAE;gBAC/C,IAAI,MAAM,CAAC,SAAS,EAAE;oBACpB,gBAAgB,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;iBAC9B;YACH,CAAC,CAAC,CAAC;YACH,IAAI,gBAAgB,CAAC,MAAM,GAAG,CAAC,EAAE;gBAC/B,OAAO,CAAC,IAAI,CAAC,SAAS,gBAAgB,CAAC,MAAM,6CAA6C,CAAC,CAAC;aAC7F;SACF;QACD,IAAI,gBAAgB,CAAC,MAAM,GAAG,CAAC,EAAE;YAC/B,IAAI,CAAC,aAAa,GAAG,gBAAgB,CAAC,CAAC,CAAC,CAAC;SAC1C;aAAM;YACL,OAAO,CAAC,IAAI,CAAC,2CAA2C,CAAC,CAAC;YAC1D,IAAI,CAAC,aAAa,GAAG,CAAC,CAAC,CAAC;SACzB;IACH,CAAC;;;YA3DF,SAAS,SAAC;gBACT,QAAQ,EAAE,iBAAiB;gBAC3B,+RAA2C;;aAE5C;;;YAxEC,iBAAiB;;;0BA2EhB,KAAK;qBAGL,KAAK;gCAGL,eAAe,SAAC,gBAAgB;;AALjC;IADU,aAAa,EAAE;8BACZ,UAAU;wDAAI;AAG3B;IADU,iBAAiB,CAAC,aAAa,CAAC;;mDAChC","sourcesContent":["import {\n AfterContentInit,\n ChangeDetectorRef,\n Component,\n ContentChildren,\n Directive,\n Input,\n OnInit,\n QueryList,\n TemplateRef\n} from '@angular/core';\n\nimport { Dsl, StoreInValueModel, TrackExternal, ValueModel } from '@coolon/pectin';\nimport { DisposableComponent } from '../disposable-component';\n\n\nexport abstract class SwitchCaseOption<T> {\n\n abstract readonly isDefault: boolean;\n\n constructor(readonly templateRef: TemplateRef<Object>) {\n }\n\n get name() {\n return this.constructor.name;\n }\n\n abstract matches(value: T): boolean;\n}\n\n@Directive({\n selector: '[aupSwitchCaseWhen]',\n providers: [{ provide: SwitchCaseOption, useExisting: SwitchCaseWhenDirective }]\n})\nexport class SwitchCaseWhenDirective<T> extends SwitchCaseOption<T> {\n @Input() aupSwitchCaseWhen: T;\n readonly isDefault = false;\n\n constructor(templateRef: TemplateRef<Object>) {\n super(templateRef);\n }\n\n matches(value: T): boolean {\n return this.aupSwitchCaseWhen === value;\n }\n}\n\n@Directive({\n selector: '[aupSwitchCaseDefault]',\n providers: [{ provide: SwitchCaseOption, useExisting: SwitchCaseDefaultDirective }]\n})\nexport class SwitchCaseDefaultDirective<T> extends SwitchCaseOption<T> {\n readonly isDefault = true;\n\n constructor(templateRef: TemplateRef<Object>) {\n super(templateRef);\n }\n\n matches(value: T): boolean {\n return false;\n }\n}\n\n/**\n * @example\n * <aup-switch-case [switchModel]=\"booleanModel\">\n * <div *aupSwitchCaseWhen=\"true\"></div>\n * <div *aupSwitchCaseDefault>The default content</div>\n * </aup-switch-case>\n */\n@Component({\n selector: 'aup-switch-case',\n templateUrl: './switch-case.component.html',\n styleUrls: ['./switch-case.component.scss']\n})\nexport class SwitchCaseComponent<T> extends DisposableComponent implements OnInit, AfterContentInit {\n\n @Input() @TrackExternal()\n switchModel: ValueModel<T>;\n\n @Input() @StoreInValueModel('switchModel')\n switch: T;\n\n @ContentChildren(SwitchCaseOption)\n switchCaseOptions: QueryList<SwitchCaseOption<T>>;\n\n selectedIndex = 0;\n\n constructor(private cdr: ChangeDetectorRef) {\n super();\n }\n\n ngOnInit(): void {\n }\n\n ngAfterContentInit(): void {\n const subscription = this.switchCaseOptions.changes.subscribe(change => this.updateSelection());\n this.onDispose(() => subscription.unsubscribe());\n const { chain, when } = Dsl.disposeWith(this);\n when(this.switchModel).changes(() => this.updateSelection(), { initialValue: 'triggerChange' });\n this.cdr.detectChanges();\n }\n\n private updateSelection() {\n const matchingIndicies = [];\n this.switchCaseOptions.forEach((option, index) => {\n if (option.matches(this.switchModel.value)) {\n matchingIndicies.push(index);\n }\n });\n if (matchingIndicies.length > 1) {\n console.warn(`found ${matchingIndicies.length} matching case values, displaying the first.`);\n }\n if (matchingIndicies.length === 0) {\n this.switchCaseOptions.forEach((option, index) => {\n if (option.isDefault) {\n matchingIndicies.push(index);\n }\n });\n if (matchingIndicies.length > 1) {\n console.warn(`found ${matchingIndicies.length} default case values, displaying the first.`);\n }\n }\n if (matchingIndicies.length > 0) {\n this.selectedIndex = matchingIndicies[0];\n } else {\n console.warn(`found no matching or default case values.`);\n this.selectedIndex = -1;\n }\n }\n}\n\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
[{"__symbolic":"module","version":4,"metadata":{"SwitchCaseOption":{"__symbolic":"class","arity":1,"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"TemplateRef","line":20,"character":36,"arguments":[{"__symbolic":"reference","name":"Object"}]}]}],"matches":[{"__symbolic":"method"}]}},"SwitchCaseWhenDirective":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"SwitchCaseOption"},"arity":1,"decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Directive","line":30,"character":1},"arguments":[{"selector":"[aupSwitchCaseWhen]","providers":[{"provide":{"__symbolic":"reference","name":"SwitchCaseOption"},"useExisting":{"__symbolic":"reference","name":"SwitchCaseWhenDirective"}}]}]}],"members":{"aupSwitchCaseWhen":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":35,"character":3}}]}],"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"TemplateRef","line":20,"character":36,"arguments":[{"__symbolic":"reference","name":"Object"}]}]}],"matches":[{"__symbolic":"method"}]}},"SwitchCaseDefaultDirective":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"SwitchCaseOption"},"arity":1,"decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Directive","line":47,"character":1},"arguments":[{"selector":"[aupSwitchCaseDefault]","providers":[{"provide":{"__symbolic":"reference","name":"SwitchCaseOption"},"useExisting":{"__symbolic":"reference","name":"SwitchCaseDefaultDirective"}}]}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"TemplateRef","line":20,"character":36,"arguments":[{"__symbolic":"reference","name":"Object"}]}]}],"matches":[{"__symbolic":"method"}]}},"SwitchCaseComponent":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"../disposable-component","name":"DisposableComponent","line":
|
|
1
|
+
[{"__symbolic":"module","version":4,"metadata":{"SwitchCaseOption":{"__symbolic":"class","arity":1,"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"TemplateRef","line":20,"character":36,"arguments":[{"__symbolic":"reference","name":"Object"}]}]}],"matches":[{"__symbolic":"method"}]}},"SwitchCaseWhenDirective":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"SwitchCaseOption"},"arity":1,"decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Directive","line":30,"character":1},"arguments":[{"selector":"[aupSwitchCaseWhen]","providers":[{"provide":{"__symbolic":"reference","name":"SwitchCaseOption"},"useExisting":{"__symbolic":"reference","name":"SwitchCaseWhenDirective"}}]}]}],"members":{"aupSwitchCaseWhen":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":35,"character":3}}]}],"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"TemplateRef","line":20,"character":36,"arguments":[{"__symbolic":"reference","name":"Object"}]}]}],"matches":[{"__symbolic":"method"}]}},"SwitchCaseDefaultDirective":{"__symbolic":"class","extends":{"__symbolic":"reference","name":"SwitchCaseOption"},"arity":1,"decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Directive","line":47,"character":1},"arguments":[{"selector":"[aupSwitchCaseDefault]","providers":[{"provide":{"__symbolic":"reference","name":"SwitchCaseOption"},"useExisting":{"__symbolic":"reference","name":"SwitchCaseDefaultDirective"}}]}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"TemplateRef","line":20,"character":36,"arguments":[{"__symbolic":"reference","name":"Object"}]}]}],"matches":[{"__symbolic":"method"}]}},"SwitchCaseComponent":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"../disposable-component","name":"DisposableComponent","line":75,"character":44},"arity":1,"decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component","line":70,"character":1},"arguments":[{"selector":"aup-switch-case","template":"<mat-tab-group class=\"content-wrapper\" no-tab-header full-height-tabs [selectedIndex]=\"selectedIndex\">\n <mat-tab *ngFor=\"let option of switchCaseOptions\">\n <ng-template [ngTemplateOutlet]=\"option.templateRef\"></ng-template>\n </mat-tab>\n</mat-tab-group>\n\n\n","styles":[":host{display:flex;flex-direction:column;align-items:stretch}mat-tab-group{flex:1}"]}]}],"members":{"switchModel":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":77,"character":3}},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@coolon/pectin","name":"TrackExternal","line":77,"character":12}}]}],"switch":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":80,"character":3}},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@coolon/pectin","name":"StoreInValueModel","line":80,"character":12},"arguments":["switchModel"]}]}],"switchCaseOptions":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"ContentChildren","line":83,"character":3},"arguments":[{"__symbolic":"reference","name":"SwitchCaseOption"}]}]}],"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/core","name":"ChangeDetectorRef","line":88,"character":27}]}],"ngOnInit":[{"__symbolic":"method"}],"ngAfterContentInit":[{"__symbolic":"method"}],"updateSelection":[{"__symbolic":"method"}]}}}}]
|
|
@@ -73,7 +73,7 @@ export class TableComponent extends AbstractTableComponent {
|
|
|
73
73
|
TableComponent.decorators = [
|
|
74
74
|
{ type: Component, args: [{
|
|
75
75
|
selector: 'aup-table',
|
|
76
|
-
template: "<div class=\"scroll-container\">\n <table mat-table [dataSource]=\"getModel().dataSource.value\" [trackBy]=\"getModel().trackBy\">\n\n <ng-container *ngFor=\"let column of columns.value; index as index; first as first; last as last\"\n matColumnDef=\"{{column.columnId}}\">\n <th mat-header-cell *matHeaderCellDef [class.flex]=\"column.isFlex()\" [class.hide]=\"!column.isVisible()\">\n <aup-table-header-cell-renderer [column]=\"column\"\n [attr.column-index]=\"index\"\n [attr.column-id]=\"column.columnId\"\n [class]=\"getColumnClasses(column.columnId)\"\n ></aup-table-header-cell-renderer>\n </th>\n <td mat-cell *matCellDef=\"let row\" (click)=\"notifyCellClicked(column, row)\"\n [class.enable-cursor]=\"getModel().isCursorEnabled(column)\"\n [class.flex]=\"column.isFlex()\"\n [class.hide]=\"!column.isVisible()\"\n >\n <aup-table-cell-renderer [column]=\"column\"\n [row]=\"row\"\n [tableModel]=\"getModel()\"\n [editSession]=\"getModel().getEditSessionFor(row)\"\n [attr.column-index]=\"index\"\n [attr.column-id]=\"column.columnId\"\n [class]=\"getColumnClasses(column.columnId)\"\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; let i = index\"\n [ngClass]=\"getModel().getRowClasses(row)\" [class.enable-hover]=\"getModel().isHoverEnabled()\"\n [attr.
|
|
76
|
+
template: "<div class=\"scroll-container\">\n <table mat-table [dataSource]=\"getModel().dataSource.value\" [trackBy]=\"getModel().trackBy\">\n\n <ng-container *ngFor=\"let column of columns.value; index as index; first as first; last as last\"\n matColumnDef=\"{{column.columnId}}\">\n <th mat-header-cell *matHeaderCellDef [class.flex]=\"column.isFlex()\" [class.hide]=\"!column.isVisible()\">\n <aup-table-header-cell-renderer [column]=\"column\"\n [attr.column-index]=\"index\"\n [attr.column-id]=\"column.columnId\"\n [class]=\"getColumnClasses(column.columnId)\"\n ></aup-table-header-cell-renderer>\n </th>\n <td mat-cell *matCellDef=\"let row\" (click)=\"notifyCellClicked(column, row)\"\n [class.enable-cursor]=\"getModel().isCursorEnabled(column)\"\n [class.flex]=\"column.isFlex()\"\n [class.hide]=\"!column.isVisible()\"\n >\n <aup-table-cell-renderer [column]=\"column\"\n [row]=\"row\"\n [tableModel]=\"getModel()\"\n [editSession]=\"getModel().getEditSessionFor(row)\"\n [attr.column-index]=\"index\"\n [attr.column-id]=\"column.columnId\"\n [class]=\"getColumnClasses(column.columnId)\"\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; let i = index\"\n [ngClass]=\"getModel().getRowClasses(row)\" [class.enable-hover]=\"getModel().isHoverEnabled()\"\n [attr.aup-row-id]=\"getModel().trackBy(i, row)\"\n ></tr>\n\n </table>\n</div>\n",
|
|
77
77
|
providers: [
|
|
78
78
|
{ provide: AbstractTableComponent, useExisting: TableComponent }
|
|
79
79
|
],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"table.component.js","sourceRoot":"","sources":["../../../../../../../../libs/angular-ui-powerups/src/lib/components/tables/table/table.component.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AACrE,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAC/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AAErE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0DG;AASH,MAAM,OAAO,cAAoB,SAAQ,sBAA2B;IAMlE,YAAY,UAAsB,EAAE,MAAc;QAChD,KAAK,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC;IAC5B,CAAC;IAED,QAAQ;QACN,OAAO,IAAI,CAAC,UAAU,CAAC;IACzB,CAAC;;;YApBF,SAAS,SAAC;gBACT,QAAQ,EAAE,WAAW;gBACrB
|
|
1
|
+
{"version":3,"file":"table.component.js","sourceRoot":"","sources":["../../../../../../../../libs/angular-ui-powerups/src/lib/components/tables/table/table.component.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AACrE,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAC/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AAErE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0DG;AASH,MAAM,OAAO,cAAoB,SAAQ,sBAA2B;IAMlE,YAAY,UAAsB,EAAE,MAAc;QAChD,KAAK,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC;IAC5B,CAAC;IAED,QAAQ;QACN,OAAO,IAAI,CAAC,UAAU,CAAC;IACzB,CAAC;;;YApBF,SAAS,SAAC;gBACT,QAAQ,EAAE,WAAW;gBACrB,k4DAAsC;gBAEtC,SAAS,EAAE;oBACT,EAAC,OAAO,EAAE,sBAAsB,EAAE,WAAW,EAAE,cAAc,EAAC;iBAC/D;;aACF;;;YAvEmB,UAAU;YAAS,MAAM;;;yBA0E1C,KAAK;;AAEN;IADC,aAAa,EAAE;8BACJ,kBAAkB;kDAAM","sourcesContent":["import { Component, ElementRef, Input, NgZone } from '@angular/core';\nimport { TrackExternal } from '@coolon/pectin';\nimport { AbstractTableModel } from '../abstract-table-model';\nimport { AbstractTableComponent } from '../abstract-table.component';\n\n/**\n * Create your model:\n * @example\n * this.heroTableModel = TableModel.fromList(heroList, table => {\n * table.pluck(\"firstName\");\n * table.pluck(\"lastName\");\n * table.addCustomColumn(\"fullName\", hero => `${hero.firstName} ${hero.lastName}`);\n * });\n *\n * Create your table\n * @example\n * <aup-table [tableModel]=\"heroTableModel\"></aup-table>\n *\n * Column templates\n * @example\n * this.heroTableModel = TableModel.fromList(heroList, table => {\n * table.pluck(\"firstName\");\n * table.pluck(\"lastName\");\n * table.addTemplateColumn(\"specialColumn\");\n * });\n * <aup-table [tableModel]=\"heroTableModel\">\n * <div *aupColumnTemplate=\"let hero; columnId: 'specialColumn'; fillCell: true; padChild:false\">\n * {{hero.name}}\n * </div>\n * </aup-table>\n *\n * Styling\n * @example\n * // global settings\n * :root {\n * --aup-table-column-gap: 10px; // defaults to 24px\n * --aup-table-row-hover-background-color, rgba(0, 0, 0, 0.05)\n * --aup-table-row-selected-background-color: rebeccapurple; // defaults to transparent\n * --aup-table-first-column-padding-left: 18px // defaults to --column-gap\n * --aup-table-last-column-padding-right: 18px // defaults to --column-gap\n * }\n *\n * // per table settings.\n * aup-table {\n * --column-gap: 10px; // defaults to 24px\n * --row-hover-background-color, rgba(0, 0, 0, 0.05)\n * --row-selected-background-color: rebeccapurple; // defaults to transparent\n * --first-column-padding-left: 18px // defaults to --column-gap\n * --last-column-padding-right: 18px // defaults to --column-gap\n *\n * aup-table-header-cell-renderer,\n * aup-table-cell-renderer {\n * &.aup-col-my-dasherised-column-id {\n * // do stuff\n * }\n * &.first-visible-column {\n * // do stuff\n * }\n * &.last-visible-column {\n * // do stuff\n * }\n * }\n * }\n */\n@Component({\n selector: 'aup-table',\n templateUrl: '../table.component.html',\n styleUrls: ['../table.component.scss'],\n providers: [\n {provide: AbstractTableComponent, useExisting: TableComponent}\n ]\n})\nexport class TableComponent<Row> extends AbstractTableComponent<Row> {\n\n @Input()\n @TrackExternal()\n tableModel: AbstractTableModel<Row>;\n\n constructor(elementRef: ElementRef, ngZone: NgZone) {\n super(elementRef, ngZone);\n }\n\n getModel(): AbstractTableModel<Row> {\n return this.tableModel;\n }\n\n}\n"]}
|