Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Hierarchy builder: Add base class grouping and merge groupings into s…
…ingle operator (#321) * Add baseClassGrouping * Add baseClassGrouping * Fix merge git crap * Add latest updates * Add base class grouping and hiding * Add check for relationship and entity class * test coverage * Remove commented code * Add changeset * BaseClassGroupingNodeKey removal and sortByBaseClass reduce time complexity to O(n^2) * Fix group hiding * Merge schemaName and className into fullClassName * Move createGroupingHandlers to Grouping.ts * move grouping merge params to separate function * Add new line after file header * fix formatting * Remove @beta tags from non exported apis * Use sortNodesByLabel in sortNodesByLabelOperator * Raname GroupingHandlerReturn to GroupingHandlerResult * Rename GroupingHandlerType to GroupingHandler * remove export * Remove export * Remove allNodes and use nodes instead * Add comment * add internal tag * Move label grouping creation to a function * Use Promise.all to save time * Add createBaseClassGroupingHandlers * Add !classNameIsInNodeBaseClassList check * Remove redundant check * Remove checking if grouped node * Remove 3 similar functions for one * run pnpm extract api * Fix import * Fix group hiding * Remove isGrouping check, it is not used * Code cleanup * Update packages/hierarchy-builder/src/hierarchy-builder/queries/NodeSelectClauseFactory.ts Co-authored-by: Grigas <[email protected]> * Update packages/hierarchy-builder/src/hierarchy-builder/internal/Common.ts Co-authored-by: Grigas <[email protected]> * Update packages/hierarchy-builder/src/hierarchy-builder/internal/Common.ts Co-authored-by: Grigas <[email protected]> * Update packages/hierarchy-builder/src/hierarchy-builder/internal/operators/Grouping.ts Co-authored-by: Grigas <[email protected]> * Update packages/hierarchy-builder/src/hierarchy-builder/internal/operators/grouping/BaseClassGrouping.ts Co-authored-by: Grigas <[email protected]> * Update packages/hierarchy-builder/src/hierarchy-builder/internal/operators/grouping/BaseClassGrouping.ts Co-authored-by: Grigas <[email protected]> * Update packages/hierarchy-builder/src/hierarchy-builder/internal/operators/grouping/BaseClassGrouping.ts Co-authored-by: Grigas <[email protected]> * Renaming changes * Add grouping result under grouping attribute * Remove redundant code * Remove groupNodesFromHandlerCreator * Add ungroupedNodes * Add assert to avoid check if array * Add docs to @beta * Remove root subject from tests * Show correct label for base class grouping node * Rename describe blocks * Move createProvider to IModelUtils * Cleanup baseClassGrouping * base class grouping test cleanup * group hiding add full stack tests * Remove for loop * Add better explanation * Remove allNodes and rename to grouped and ungrouped * Update packages/hierarchy-builder/src/hierarchy-builder/HierarchyNode.ts Co-authored-by: Grigas <[email protected]> * Simplify the api * Update packages/hierarchy-builder/src/hierarchy-builder/HierarchyNode.ts Co-authored-by: Grigas <[email protected]> * Apply suggestion * Update packages/hierarchy-builder/src/hierarchy-builder/internal/operators/Grouping.ts Co-authored-by: Grigas <[email protected]> * Update packages/hierarchy-builder/src/hierarchy-builder/internal/operators/grouping/GroupHiding.ts Co-authored-by: Grigas <[email protected]> * Remove redundant code * Move createProvider to hierarchy-builder/Utils.ts * Update packages/full-stack-tests/src/hierarchy-builder/grouping/GroupHiding.test.ts Co-authored-by: Grigas <[email protected]> * Update imports * simplify test cases * Remove userLabel from tests which don't need it * Update tests to use one function to create hierarchy * Prettier change * Simplify unit tests * Update packages/hierarchy-builder/src/test/internal/operators/grouping/LabelGrouping.test.ts Co-authored-by: Grigas <[email protected]> * Update grouping to not use groupNodes() twice * Define ecClass in tests that need it * Rename base classes * Update packages/hierarchy-builder/src/test/internal/operators/Grouping.test.ts Co-authored-by: Grigas <[email protected]> * Remove grouping params where it's not necessary * Check what applyGroupingHidingParamsStub got called with * Add check that createBaseClassGroupingHandlersStub receives input nodes * Remove .only * Increase test coverage --------- Co-authored-by: Grigas <[email protected]>
- Loading branch information