@hmcts/ccd-case-ui-toolkit 5.0.25-case-file-view-document-count → 5.0.25-case-file-view-all-document-count
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/hmcts-ccd-case-ui-toolkit.umd.js +107 -473
- package/bundles/hmcts-ccd-case-ui-toolkit.umd.js.map +1 -1
- package/bundles/hmcts-ccd-case-ui-toolkit.umd.min.js +1 -1
- package/bundles/hmcts-ccd-case-ui-toolkit.umd.min.js.map +1 -1
- package/esm2015/lib/shared/components/palette/case-file-view/components/case-file-view-folder/case-file-view-folder.component.js +51 -129
- package/esm2015/lib/shared/components/palette/case-file-view/components/index.js +1 -4
- package/esm2015/lib/shared/components/palette/palette.module.js +4 -20
- package/esm2015/lib/shared/domain/case-file-view/document-tree-node/document-tree-node.model.js +1 -66
- package/esm2015/public-api.js +3 -1
- package/fesm2015/hmcts-ccd-case-ui-toolkit.js +96 -425
- package/fesm2015/hmcts-ccd-case-ui-toolkit.js.map +1 -1
- package/lib/shared/components/palette/case-file-view/components/case-file-view-folder/case-file-view-folder.component.d.ts +2 -6
- package/lib/shared/components/palette/case-file-view/components/case-file-view-folder/case-file-view-folder.component.d.ts.map +1 -1
- package/lib/shared/components/palette/case-file-view/components/index.d.ts +0 -3
- package/lib/shared/components/palette/case-file-view/components/index.d.ts.map +1 -1
- package/lib/shared/components/palette/palette.module.d.ts +22 -26
- package/lib/shared/components/palette/palette.module.d.ts.map +1 -1
- package/lib/shared/domain/case-file-view/document-tree-node/document-tree-node.model.d.ts +0 -3
- package/lib/shared/domain/case-file-view/document-tree-node/document-tree-node.model.d.ts.map +1 -1
- package/package.json +1 -1
- package/public-api.d.ts +2 -0
- package/public-api.d.ts.map +1 -1
- package/esm2015/lib/shared/components/palette/case-file-view/components/case-file-view-folder/case-file-view-folder-document-actions/case-file-view-folder-document-actions.component.js +0 -46
- package/esm2015/lib/shared/components/palette/case-file-view/components/case-file-view-folder/case-file-view-folder-sort/case-file-view-folder-sort.component.js +0 -38
- package/esm2015/lib/shared/components/palette/case-file-view/components/shared/case-file-view-overlay-menu/case-file-view-overlay-menu-item.model.js +0 -2
- package/esm2015/lib/shared/components/palette/case-file-view/components/shared/case-file-view-overlay-menu/case-file-view-overlay-menu.component.js +0 -100
- package/esm2015/lib/shared/components/palette/case-file-view/components/shared/index.js +0 -2
- package/lib/shared/components/palette/case-file-view/components/case-file-view-folder/case-file-view-folder-document-actions/case-file-view-folder-document-actions.component.d.ts +0 -15
- package/lib/shared/components/palette/case-file-view/components/case-file-view-folder/case-file-view-folder-document-actions/case-file-view-folder-document-actions.component.d.ts.map +0 -1
- package/lib/shared/components/palette/case-file-view/components/case-file-view-folder/case-file-view-folder-sort/case-file-view-folder-sort.component.d.ts +0 -13
- package/lib/shared/components/palette/case-file-view/components/case-file-view-folder/case-file-view-folder-sort/case-file-view-folder-sort.component.d.ts.map +0 -1
- package/lib/shared/components/palette/case-file-view/components/shared/case-file-view-overlay-menu/case-file-view-overlay-menu-item.model.d.ts +0 -6
- package/lib/shared/components/palette/case-file-view/components/shared/case-file-view-overlay-menu/case-file-view-overlay-menu-item.model.d.ts.map +0 -1
- package/lib/shared/components/palette/case-file-view/components/shared/case-file-view-overlay-menu/case-file-view-overlay-menu.component.d.ts +0 -13
- package/lib/shared/components/palette/case-file-view/components/shared/case-file-view-overlay-menu/case-file-view-overlay-menu.component.d.ts.map +0 -1
- package/lib/shared/components/palette/case-file-view/components/shared/index.d.ts +0 -2
- package/lib/shared/components/palette/case-file-view/components/shared/index.d.ts.map +0 -1
package/esm2015/lib/shared/domain/case-file-view/document-tree-node/document-tree-node.model.js
CHANGED
|
@@ -15,71 +15,6 @@ export class DocumentTreeNode {
|
|
|
15
15
|
};
|
|
16
16
|
return countChildren(this.children);
|
|
17
17
|
}
|
|
18
|
-
sortChildrenAscending() {
|
|
19
|
-
var _a, _b;
|
|
20
|
-
const sortAscending = () => {
|
|
21
|
-
return (a, b) => {
|
|
22
|
-
const nameA = a.name.toUpperCase(); // ignore upper and lowercase
|
|
23
|
-
const nameB = b.name.toUpperCase(); // ignore upper and lowercase
|
|
24
|
-
if (a.type === 'category' || b.type === 'category') {
|
|
25
|
-
return 0;
|
|
26
|
-
}
|
|
27
|
-
if (nameA < nameB) {
|
|
28
|
-
return -1;
|
|
29
|
-
}
|
|
30
|
-
if (nameA > nameB) {
|
|
31
|
-
return 1;
|
|
32
|
-
}
|
|
33
|
-
};
|
|
34
|
-
};
|
|
35
|
-
(_a = this.children) === null || _a === void 0 ? void 0 : _a.sort(sortAscending());
|
|
36
|
-
(_b = this.children) === null || _b === void 0 ? void 0 : _b.forEach((childNodes) => {
|
|
37
|
-
childNodes.sortChildrenAscending();
|
|
38
|
-
});
|
|
39
|
-
}
|
|
40
|
-
sortChildrenDescending() {
|
|
41
|
-
var _a, _b;
|
|
42
|
-
const sortDescending = () => {
|
|
43
|
-
return (a, b) => {
|
|
44
|
-
const nameA = a.name.toUpperCase(); // ignore upper and lowercase
|
|
45
|
-
const nameB = b.name.toUpperCase(); // ignore upper and lowercase
|
|
46
|
-
if (a.type === 'category' || b.type === 'category') {
|
|
47
|
-
return 0;
|
|
48
|
-
}
|
|
49
|
-
if (nameA > nameB) {
|
|
50
|
-
return -1;
|
|
51
|
-
}
|
|
52
|
-
if (nameA < nameB) {
|
|
53
|
-
return 1;
|
|
54
|
-
}
|
|
55
|
-
};
|
|
56
|
-
};
|
|
57
|
-
(_a = this.children) === null || _a === void 0 ? void 0 : _a.sort(sortDescending());
|
|
58
|
-
(_b = this.children) === null || _b === void 0 ? void 0 : _b.forEach((childNodes) => {
|
|
59
|
-
childNodes.sortChildrenDescending();
|
|
60
|
-
});
|
|
61
|
-
}
|
|
62
|
-
get flattenedAll() {
|
|
63
|
-
var _a;
|
|
64
|
-
const flattenChildren = (nodeChild) => {
|
|
65
|
-
var _a;
|
|
66
|
-
const flattenedNodes = [];
|
|
67
|
-
flattenedNodes.push(nodeChild);
|
|
68
|
-
if (((_a = nodeChild.children) === null || _a === void 0 ? void 0 : _a.length) > 0) {
|
|
69
|
-
// flattenedNodes.push(nodeChild);
|
|
70
|
-
nodeChild.children.forEach((child) => {
|
|
71
|
-
flattenedNodes.push(flattenChildren(child));
|
|
72
|
-
});
|
|
73
|
-
}
|
|
74
|
-
return flattenedNodes.flat();
|
|
75
|
-
};
|
|
76
|
-
return [
|
|
77
|
-
this,
|
|
78
|
-
...(_a = this.children) === null || _a === void 0 ? void 0 : _a.map(item => {
|
|
79
|
-
return flattenChildren(item);
|
|
80
|
-
}).flat()
|
|
81
|
-
];
|
|
82
|
-
}
|
|
83
18
|
}
|
|
84
19
|
__decorate([
|
|
85
20
|
Type(() => DocumentTreeNode),
|
|
@@ -90,4 +25,4 @@ __decorate([
|
|
|
90
25
|
__metadata("design:type", Object),
|
|
91
26
|
__metadata("design:paramtypes", [])
|
|
92
27
|
], DocumentTreeNode.prototype, "childDocumentCount", null);
|
|
93
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
28
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZG9jdW1lbnQtdHJlZS1ub2RlLm1vZGVsLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvY2NkLWNhc2UtdWktdG9vbGtpdC9zcmMvbGliL3NoYXJlZC9kb21haW4vY2FzZS1maWxlLXZpZXcvZG9jdW1lbnQtdHJlZS1ub2RlL2RvY3VtZW50LXRyZWUtbm9kZS5tb2RlbC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQUEsT0FBTyxFQUFFLE1BQU0sRUFBRSxJQUFJLEVBQUUsTUFBTSxtQkFBbUIsQ0FBQztBQUVqRCxNQUFNLE9BQU8sZ0JBQWdCO0lBTzNCLElBQVcsa0JBQWtCO1FBQzNCLE1BQU0sYUFBYSxHQUFHLENBQUMsVUFBMEMsRUFB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sZERvY3VtZW50Q291bnQoKSB7XG4gICAgY29uc3QgY291bnRDaGlsZHJlbiA9IChjaGlsZE5vZGVzOiBEb2N1bWVudFRyZWVOb2RlW10gfCB1bmRlZmluZWQpID0+IHtcbiAgICAgIGxldCBjb3VudCA9IDA7XG4gICAgICBpZiAoY2hpbGROb2Rlcz8ubGVuZ3RoKSB7XG4gICAgICAgIGNvbnN0IGRvY3VtZW50cyA9IGNoaWxkTm9kZXMuZmlsdGVyKGl0ZW0gPT4gaXRlbS50eXBlID09PSAnZG9jdW1lbnQnKTtcbiAgICAgICAgY291bnQgKz0gZG9jdW1lbnRzLmxlbmd0aDtcbiAgICAgICAgY2hpbGROb2Rlcy5mb3JFYWNoKChjaGlsZHJlbikgPT4ge1xuICAgICAgICAgIGNvdW50ICs9IGNvdW50Q2hpbGRyZW4oY2hpbGRyZW4uY2hpbGRyZW4pO1xuICAgICAgICB9KTtcbiAgICAgIH1cblxuICAgICAgcmV0dXJuIGNvdW50O1xuICAgIH07XG5cbiAgICByZXR1cm4gY291bnRDaGlsZHJlbih0aGlzLmNoaWxkcmVuKTtcbiAgfVxufVxuIl19
|
package/esm2015/public-api.js
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
export * from './lib/components';
|
|
2
2
|
export * from './lib/shared';
|
|
3
3
|
export * from './lib/app.config';
|
|
4
|
-
|
|
4
|
+
export * from './lib/shared/components/palette/case-file-view/case-file-view-field.component';
|
|
5
|
+
export * from './lib/shared/components/palette/case-file-view/components/case-file-view-folder/case-file-view-folder.component';
|
|
6
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljLWFwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3Byb2plY3RzL2NjZC1jYXNlLXVpLXRvb2xraXQvc3JjL3B1YmxpYy1hcGkudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsY0FBYyxrQkFBa0IsQ0FBQztBQUNqQyxjQUFjLGNBQWMsQ0FBQztBQUM3QixjQUFjLGtCQUFrQixDQUFDO0FBQ2pDLGNBQWMsK0VBQStFLENBQUM7QUFDOUYsY0FBYyxpSEFBaUgsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCAqIGZyb20gJy4vbGliL2NvbXBvbmVudHMnO1xuZXhwb3J0ICogZnJvbSAnLi9saWIvc2hhcmVkJztcbmV4cG9ydCAqIGZyb20gJy4vbGliL2FwcC5jb25maWcnO1xuZXhwb3J0ICogZnJvbSAnLi9saWIvc2hhcmVkL2NvbXBvbmVudHMvcGFsZXR0ZS9jYXNlLWZpbGUtdmlldy9jYXNlLWZpbGUtdmlldy1maWVsZC5jb21wb25lbnQnO1xuZXhwb3J0ICogZnJvbSAnLi9saWIvc2hhcmVkL2NvbXBvbmVudHMvcGFsZXR0ZS9jYXNlLWZpbGUtdmlldy9jb21wb25lbnRzL2Nhc2UtZmlsZS12aWV3LWZvbGRlci9jYXNlLWZpbGUtdmlldy1mb2xkZXIuY29tcG9uZW50JztcbiJdfQ==
|