@dropins/storefront-company-management 1.3.0-beta.0 → 1.3.0-beta.2

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.
Files changed (42) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/api/assignChildCompany/assignChildCompany.d.ts +12 -0
  3. package/api/assignChildCompany/graphql/assignChildCompany.graphql.d.ts +18 -0
  4. package/api/assignChildCompany/index.d.ts +18 -0
  5. package/api/getCompanyHierarchy/getCompanyHierarchy.d.ts +10 -0
  6. package/api/getCompanyHierarchy/graphql/getCompanyHierarchy.graphql.d.ts +18 -0
  7. package/api/getCompanyHierarchy/index.d.ts +18 -0
  8. package/api/graphql/CompanyHierarchyFragment.graphql.d.ts +18 -0
  9. package/api/index.d.ts +3 -0
  10. package/api/unassignChildCompany/graphql/unassignChildCompany.graphql.d.ts +18 -0
  11. package/api/unassignChildCompany/index.d.ts +18 -0
  12. package/api/unassignChildCompany/unassignChildCompany.d.ts +11 -0
  13. package/api.js +105 -46
  14. package/api.js.map +1 -1
  15. package/chunks/components.js +1 -1
  16. package/chunks/components.js.map +1 -1
  17. package/components/CompanyHierarchyContent/CompanyHierarchyContent.d.ts +10 -0
  18. package/components/CompanyHierarchyContent/index.d.ts +19 -0
  19. package/components/Tree/Tree.d.ts +1 -0
  20. package/components/index.d.ts +1 -0
  21. package/containers/CompanyCredit.js +1 -1
  22. package/containers/CompanyHierarchy/CompanyHierarchy.d.ts +5 -0
  23. package/containers/CompanyHierarchy/index.d.ts +19 -0
  24. package/containers/CompanyHierarchy.d.ts +3 -0
  25. package/containers/CompanyHierarchy.js +4 -0
  26. package/containers/CompanyHierarchy.js.map +1 -0
  27. package/containers/index.d.ts +1 -0
  28. package/data/transforms/index.d.ts +1 -0
  29. package/data/transforms/transform-company-hierarchy.d.ts +34 -0
  30. package/hooks/index.d.ts +1 -0
  31. package/hooks/useCompanyHierarchy.d.ts +31 -0
  32. package/i18n/en_US.json.d.ts +13 -0
  33. package/package.json +1 -1
  34. package/render.js +2 -2
  35. package/render.js.map +1 -1
  36. package/types/api/assignChildCompany.types.d.ts +21 -0
  37. package/types/api/companyBasicInfo.types.d.ts +28 -0
  38. package/types/api/getCompanyHierarchy.types.d.ts +47 -0
  39. package/types/api/unassignChildCompany.types.d.ts +20 -0
  40. package/types/companyHierarchy.types.d.ts +71 -0
  41. package/types/companyPermission.types.d.ts +1 -0
  42. package/types/index.d.ts +5 -0
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @dropins/storefront-company-management
2
2
 
3
+ ## 1.3.0-beta.2
4
+
5
+ ### Patch Changes
6
+
7
+ - 931c25f: Bump @adobe-commerce/elsie to v1.9.0-beta.3
8
+
9
+ ## 1.3.0-beta.1
10
+
11
+ ### Minor Changes
12
+
13
+ - 812978b: Implemented company hierarchy functionality with tree view displaying parent-child relationships and drag-and-drop support for structure management. Added GraphQL APIs for retrieving hierarchy (getCompanyHierarchy), assigning (assignChildCompany), and unassigning (unassignChildCompany) child companies. Integrated permission checks with visual distinction between root and child companies, expand/collapse node support, and loading/error state handling.
14
+
3
15
  ## 1.3.0-beta.0
4
16
 
5
17
  ### Minor Changes
@@ -0,0 +1,12 @@
1
+ import { Company } from '../../types';
2
+
3
+ /**
4
+ * Assign a child company to a parent company within the company relation hierarchy
5
+ *
6
+ * @param parentCompanyId - The unique ID of the parent company
7
+ * @param childCompanyId - The unique ID of the child company
8
+ * @returns Promise resolving to array of Company objects representing the updated hierarchy
9
+ * @throws {Error} When network errors or GraphQL errors occur
10
+ */
11
+ export declare function assignChildCompany(parentCompanyId: string, childCompanyId: string): Promise<Company[]>;
12
+ //# sourceMappingURL=assignChildCompany.d.ts.map
@@ -0,0 +1,18 @@
1
+ /********************************************************************
2
+ * ADOBE CONFIDENTIAL
3
+ * __________________
4
+ *
5
+ * Copyright 2026 Adobe
6
+ * All Rights Reserved.
7
+ *
8
+ * NOTICE: All information contained herein is, and remains
9
+ * the property of Adobe and its suppliers, if any. The intellectual
10
+ * and technical concepts contained herein are proprietary to Adobe
11
+ * and its suppliers and are protected by all applicable intellectual
12
+ * property laws, including trade secret and copyright laws.
13
+ * Dissemination of this information or reproduction of this material
14
+ * is strictly forbidden unless prior written permission is obtained
15
+ * from Adobe.
16
+ *******************************************************************/
17
+ export declare const ASSIGN_CHILD_COMPANY: string;
18
+ //# sourceMappingURL=assignChildCompany.graphql.d.ts.map
@@ -0,0 +1,18 @@
1
+ /********************************************************************
2
+ * ADOBE CONFIDENTIAL
3
+ * __________________
4
+ *
5
+ * Copyright 2026 Adobe
6
+ * All Rights Reserved.
7
+ *
8
+ * NOTICE: All information contained herein is, and remains
9
+ * the property of Adobe and its suppliers, if any. The intellectual
10
+ * and technical concepts contained herein are proprietary to Adobe
11
+ * and its suppliers and are protected by all applicable intellectual
12
+ * property laws, including trade secret and copyright laws.
13
+ * Dissemination of this information or reproduction of this material
14
+ * is strictly forbidden unless prior written permission is obtained
15
+ * from Adobe.
16
+ *******************************************************************/
17
+ export * from './assignChildCompany';
18
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1,10 @@
1
+ import { Company } from '../../types';
2
+
3
+ /**
4
+ * Retrieves the company hierarchy with parent-child relationships
5
+ *
6
+ * @returns Promise resolving to array of Company objects representing the company hierarchy
7
+ * @throws {Error} When network errors or GraphQL errors occur
8
+ */
9
+ export declare function getCompanyHierarchy(): Promise<Company[]>;
10
+ //# sourceMappingURL=getCompanyHierarchy.d.ts.map
@@ -0,0 +1,18 @@
1
+ /********************************************************************
2
+ * ADOBE CONFIDENTIAL
3
+ * __________________
4
+ *
5
+ * Copyright 2025 Adobe
6
+ * All Rights Reserved.
7
+ *
8
+ * NOTICE: All information contained herein is, and remains
9
+ * the property of Adobe and its suppliers, if any. The intellectual
10
+ * and technical concepts contained herein are proprietary to Adobe
11
+ * and its suppliers and are protected by all applicable intellectual
12
+ * property laws, including trade secret and copyright laws.
13
+ * Dissemination of this information or reproduction of this material
14
+ * is strictly forbidden unless prior written permission is obtained
15
+ * from Adobe.
16
+ *******************************************************************/
17
+ export declare const GET_COMPANY_HIERARCHY: string;
18
+ //# sourceMappingURL=getCompanyHierarchy.graphql.d.ts.map
@@ -0,0 +1,18 @@
1
+ /********************************************************************
2
+ * ADOBE CONFIDENTIAL
3
+ * __________________
4
+ *
5
+ * Copyright 2025 Adobe
6
+ * All Rights Reserved.
7
+ *
8
+ * NOTICE: All information contained herein is, and remains
9
+ * the property of Adobe and its suppliers, if any. The intellectual
10
+ * and technical concepts contained herein are proprietary to Adobe
11
+ * and its suppliers and are protected by all applicable intellectual
12
+ * property laws, including trade secret and copyright laws.
13
+ * Dissemination of this information or reproduction of this material
14
+ * is strictly forbidden unless prior written permission is obtained
15
+ * from Adobe.
16
+ *******************************************************************/
17
+ export * from './getCompanyHierarchy';
18
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1,18 @@
1
+ /********************************************************************
2
+ * ADOBE CONFIDENTIAL
3
+ * __________________
4
+ *
5
+ * Copyright 2025 Adobe
6
+ * All Rights Reserved.
7
+ *
8
+ * NOTICE: All information contained herein is, and remains
9
+ * the property of Adobe and its suppliers, if any. The intellectual
10
+ * and technical concepts contained herein are proprietary to Adobe
11
+ * and its suppliers and are protected by all applicable intellectual
12
+ * property laws, including trade secret and copyright laws.
13
+ * Dissemination of this information or reproduction of this material
14
+ * is strictly forbidden unless prior written permission is obtained
15
+ * from Adobe.
16
+ *******************************************************************/
17
+ export declare const COMPANY_HIERARCHY_ITEM_FRAGMENT = "\n fragment COMPANY_HIERARCHY_ITEM_FRAGMENT on CompanyBasicInfo {\n id\n is_admin\n legal_name\n name\n status\n __typename\n }\n";
18
+ //# sourceMappingURL=CompanyHierarchyFragment.graphql.d.ts.map
package/api/index.d.ts CHANGED
@@ -19,6 +19,7 @@ export * from './fetch-graphql';
19
19
  export * from './fetchUserPermissions';
20
20
  export * from './acceptCompanyInvitation';
21
21
  export * from './allowCompanyRegistration';
22
+ export * from './assignChildCompany';
22
23
  export * from './checkCompanyCreditEnabled';
23
24
  export * from './companyEnabled';
24
25
  export * from './createCompany';
@@ -29,6 +30,7 @@ export * from './deleteCompanyUser';
29
30
  export * from './getCompany';
30
31
  export * from './getCompanyCredit';
31
32
  export * from './getCompanyCreditHistory';
33
+ export * from './getCompanyHierarchy';
32
34
  export * from './getCompanyStructure';
33
35
  export * from './getCompanyTeam';
34
36
  export * from './getCompanyUser';
@@ -44,6 +46,7 @@ export * from './updateCompanyStructure';
44
46
  export * from './updateCompanyTeam';
45
47
  export * from './updateCompanyUser';
46
48
  export * from './updateCompanyUserStatus';
49
+ export * from './unassignChildCompany';
47
50
  export * from './validateCompanyEmail';
48
51
  export * from './companyRoles';
49
52
  //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1,18 @@
1
+ /********************************************************************
2
+ * ADOBE CONFIDENTIAL
3
+ * __________________
4
+ *
5
+ * Copyright 2025 Adobe
6
+ * All Rights Reserved.
7
+ *
8
+ * NOTICE: All information contained herein is, and remains
9
+ * the property of Adobe and its suppliers, if any. The intellectual
10
+ * and technical concepts contained herein are proprietary to Adobe
11
+ * and its suppliers and are protected by all applicable intellectual
12
+ * property laws, including trade secret and copyright laws.
13
+ * Dissemination of this information or reproduction of this material
14
+ * is strictly forbidden unless prior written permission is obtained
15
+ * from Adobe.
16
+ *******************************************************************/
17
+ export declare const UNASSIGN_CHILD_COMPANY: string;
18
+ //# sourceMappingURL=unassignChildCompany.graphql.d.ts.map
@@ -0,0 +1,18 @@
1
+ /********************************************************************
2
+ * ADOBE CONFIDENTIAL
3
+ * __________________
4
+ *
5
+ * Copyright 2025 Adobe
6
+ * All Rights Reserved.
7
+ *
8
+ * NOTICE: All information contained herein is, and remains
9
+ * the property of Adobe and its suppliers, if any. The intellectual
10
+ * and technical concepts contained herein are proprietary to Adobe
11
+ * and its suppliers and are protected by all applicable intellectual
12
+ * property laws, including trade secret and copyright laws.
13
+ * Dissemination of this information or reproduction of this material
14
+ * is strictly forbidden unless prior written permission is obtained
15
+ * from Adobe.
16
+ *******************************************************************/
17
+ export * from './unassignChildCompany';
18
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1,11 @@
1
+ import { Company } from '../../types';
2
+
3
+ /**
4
+ * Unassign a child company from its parent company within the company relation hierarchy
5
+ *
6
+ * @param childCompanyId - The unique ID of the child company to unassign
7
+ * @returns Promise resolving to array of Company objects representing the updated hierarchy
8
+ * @throws {Error} When network errors or GraphQL errors occur
9
+ */
10
+ export declare function unassignChildCompany(childCompanyId: string): Promise<Company[]>;
11
+ //# sourceMappingURL=unassignChildCompany.d.ts.map