@leav/ui 0.3.6-7be4667 → 0.3.6-810391e

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 (112) hide show
  1. package/dist/__mocks__/common/form.d.ts +10 -5
  2. package/dist/__mocks__/common/record.d.ts +13 -2
  3. package/dist/__mocks__/common/record.js.map +1 -1
  4. package/dist/_gqlTypes/index.d.ts +53 -18
  5. package/dist/_gqlTypes/index.js +1057 -1038
  6. package/dist/_gqlTypes/index.js.map +1 -1
  7. package/dist/components/Explorer/DataView.d.ts +2 -1
  8. package/dist/components/Explorer/DataView.js +9 -34
  9. package/dist/components/Explorer/DataView.js.map +1 -1
  10. package/dist/components/Explorer/Explorer.d.ts +8 -4
  11. package/dist/components/Explorer/Explorer.js +24 -9
  12. package/dist/components/Explorer/Explorer.js.map +1 -1
  13. package/dist/components/Explorer/ExplorerTitle.d.ts +7 -0
  14. package/dist/components/Explorer/ExplorerTitle.js +30 -0
  15. package/dist/components/Explorer/ExplorerTitle.js.map +1 -0
  16. package/dist/components/Explorer/IdCard.d.ts +7 -0
  17. package/dist/components/Explorer/IdCard.js +15 -0
  18. package/dist/components/Explorer/IdCard.js.map +1 -0
  19. package/dist/components/Explorer/TableCell.d.ts +8 -0
  20. package/dist/components/Explorer/TableCell.js +63 -0
  21. package/dist/components/Explorer/TableCell.js.map +1 -0
  22. package/dist/components/Explorer/TableTagGroup.d.ts +6 -0
  23. package/dist/components/Explorer/TableTagGroup.js +22 -0
  24. package/dist/components/Explorer/TableTagGroup.js.map +1 -0
  25. package/dist/components/Explorer/_queries/useExplorerData.d.ts +2 -2
  26. package/dist/components/Explorer/_queries/useExplorerData.js +35 -14
  27. package/dist/components/Explorer/_queries/useExplorerData.js.map +1 -1
  28. package/dist/components/Explorer/_types.d.ts +16 -3
  29. package/dist/components/Explorer/index.d.ts +1 -3
  30. package/dist/components/Explorer/index.js +1 -3
  31. package/dist/components/Explorer/index.js.map +1 -1
  32. package/dist/components/Explorer/{edit-settings → manage-view-settings/_shared}/ColumnItem.d.ts +1 -0
  33. package/dist/components/Explorer/{edit-settings → manage-view-settings/_shared}/ColumnItem.js +17 -1
  34. package/dist/components/Explorer/manage-view-settings/_shared/ColumnItem.js.map +1 -0
  35. package/dist/components/Explorer/{edit-settings → manage-view-settings/_shared}/useGetLibraryColumns.d.ts +1 -1
  36. package/dist/components/Explorer/{edit-settings → manage-view-settings/_shared}/useGetLibraryColumns.js +6 -6
  37. package/dist/components/Explorer/manage-view-settings/_shared/useGetLibraryColumns.js.map +1 -0
  38. package/dist/components/Explorer/manage-view-settings/configure-display/ConfigureDisplay.d.ts +6 -0
  39. package/dist/components/Explorer/manage-view-settings/configure-display/ConfigureDisplay.js +28 -0
  40. package/dist/components/Explorer/manage-view-settings/configure-display/ConfigureDisplay.js.map +1 -0
  41. package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.d.ts +6 -0
  42. package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.js +89 -0
  43. package/dist/components/Explorer/manage-view-settings/configure-display/attributes/SelectVisibleAttributes.js.map +1 -0
  44. package/dist/components/Explorer/manage-view-settings/configure-display/view-type/SelectViewType.d.ts +8 -0
  45. package/dist/components/Explorer/manage-view-settings/configure-display/view-type/SelectViewType.js +12 -0
  46. package/dist/components/Explorer/manage-view-settings/configure-display/view-type/SelectViewType.js.map +1 -0
  47. package/dist/components/Explorer/manage-view-settings/index.d.ts +8 -0
  48. package/dist/components/Explorer/manage-view-settings/index.js +11 -0
  49. package/dist/components/Explorer/manage-view-settings/index.js.map +1 -0
  50. package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/EditSettingsContext.d.ts +1 -0
  51. package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/EditSettingsContext.js +1 -0
  52. package/dist/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContext.js.map +1 -0
  53. package/dist/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContextProvider.d.ts +7 -0
  54. package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/EditSettingsContextProvider.js +2 -1
  55. package/dist/components/Explorer/manage-view-settings/open-view-settings/EditSettingsContextProvider.js.map +1 -0
  56. package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/SidePanel.js +1 -1
  57. package/dist/components/Explorer/manage-view-settings/open-view-settings/SidePanel.js.map +1 -0
  58. package/dist/components/Explorer/manage-view-settings/open-view-settings/useEditSettings.js.map +1 -0
  59. package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/useOpenSettings.js +2 -2
  60. package/dist/components/Explorer/manage-view-settings/open-view-settings/useOpenSettings.js.map +1 -0
  61. package/dist/components/Explorer/manage-view-settings/router-menu/SettingItem.js.map +1 -0
  62. package/dist/components/Explorer/{edit-settings → manage-view-settings/router-menu}/SettingsPanel.d.ts +1 -1
  63. package/dist/components/Explorer/{edit-settings → manage-view-settings/router-menu}/SettingsPanel.js +7 -7
  64. package/dist/components/Explorer/manage-view-settings/router-menu/SettingsPanel.js.map +1 -0
  65. package/dist/components/Explorer/manage-view-settings/store-view-settings/ViewSettingsContext.d.ts +6 -0
  66. package/dist/components/Explorer/manage-view-settings/store-view-settings/ViewSettingsContext.js +11 -0
  67. package/dist/components/Explorer/manage-view-settings/store-view-settings/ViewSettingsContext.js.map +1 -0
  68. package/dist/components/Explorer/manage-view-settings/store-view-settings/useViewSettingsContext.d.ts +4 -0
  69. package/dist/components/Explorer/manage-view-settings/store-view-settings/useViewSettingsContext.js +7 -0
  70. package/dist/components/Explorer/manage-view-settings/store-view-settings/useViewSettingsContext.js.map +1 -0
  71. package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsInitialState.d.ts +2 -0
  72. package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsInitialState.js +5 -0
  73. package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsInitialState.js.map +1 -0
  74. package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsReducer.d.ts +43 -0
  75. package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsReducer.js +57 -0
  76. package/dist/components/Explorer/manage-view-settings/store-view-settings/viewSettingsReducer.js.map +1 -0
  77. package/dist/components/Explorer/{useCreateMainAction.d.ts → useCreateAction.d.ts} +3 -3
  78. package/dist/components/Explorer/{useCreateMainAction.js → useCreateAction.js} +11 -7
  79. package/dist/components/Explorer/useCreateAction.js.map +1 -0
  80. package/dist/components/Explorer/useEditAction.js +1 -1
  81. package/dist/components/Explorer/useEditAction.js.map +1 -1
  82. package/dist/components/Explorer/usePrimaryActions.d.ts +20 -0
  83. package/dist/components/Explorer/usePrimaryActions.js +29 -0
  84. package/dist/components/Explorer/usePrimaryActions.js.map +1 -0
  85. package/dist/components/RecordEdition/EditRecord/EditRecord.js +1 -1
  86. package/dist/components/RecordEdition/EditRecord/EditRecord.js.map +1 -1
  87. package/dist/locales/en/shared.json +9 -7
  88. package/dist/locales/fr/shared.json +9 -7
  89. package/package.json +3 -1
  90. package/dist/components/Explorer/edit-settings/ColumnItem.js.map +0 -1
  91. package/dist/components/Explorer/edit-settings/DisplayMode.d.ts +0 -6
  92. package/dist/components/Explorer/edit-settings/DisplayMode.js +0 -28
  93. package/dist/components/Explorer/edit-settings/DisplayMode.js.map +0 -1
  94. package/dist/components/Explorer/edit-settings/DisplayModeTable.d.ts +0 -6
  95. package/dist/components/Explorer/edit-settings/DisplayModeTable.js +0 -77
  96. package/dist/components/Explorer/edit-settings/DisplayModeTable.js.map +0 -1
  97. package/dist/components/Explorer/edit-settings/EditSettingsContext.js.map +0 -1
  98. package/dist/components/Explorer/edit-settings/EditSettingsContextProvider.d.ts +0 -2
  99. package/dist/components/Explorer/edit-settings/EditSettingsContextProvider.js.map +0 -1
  100. package/dist/components/Explorer/edit-settings/SettingItem.js.map +0 -1
  101. package/dist/components/Explorer/edit-settings/SettingsPanel.js.map +0 -1
  102. package/dist/components/Explorer/edit-settings/SidePanel.js.map +0 -1
  103. package/dist/components/Explorer/edit-settings/useEditSettings.js.map +0 -1
  104. package/dist/components/Explorer/edit-settings/useGetLibraryColumns.js.map +0 -1
  105. package/dist/components/Explorer/edit-settings/useOpenSettings.js.map +0 -1
  106. package/dist/components/Explorer/useCreateMainAction.js.map +0 -1
  107. /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/SidePanel.d.ts +0 -0
  108. /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/useEditSettings.d.ts +0 -0
  109. /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/useEditSettings.js +0 -0
  110. /package/dist/components/Explorer/{edit-settings → manage-view-settings/open-view-settings}/useOpenSettings.d.ts +0 -0
  111. /package/dist/components/Explorer/{edit-settings → manage-view-settings/router-menu}/SettingItem.d.ts +0 -0
  112. /package/dist/components/Explorer/{edit-settings → manage-view-settings/router-menu}/SettingItem.js +0 -0
@@ -11,11 +11,16 @@ export declare const mockLinkValue: {
11
11
  id: string;
12
12
  whoAmI: {
13
13
  id: string;
14
- label?: string | null;
15
- subLabel?: string | null;
16
- color?: string | null;
17
- library: import("../..").IRecordIdentityLibrary;
18
- preview?: import("@leav/utils").IPreviewScalar | null;
14
+ label: string;
15
+ subLabel: string;
16
+ library: {
17
+ id: string;
18
+ label: {
19
+ fr: string;
20
+ };
21
+ };
22
+ preview: import("@leav/utils").IPreviewScalar;
23
+ color: string;
19
24
  };
20
25
  };
21
26
  created_at: number;
@@ -1,4 +1,15 @@
1
1
  import { IPreviewScalar } from '@leav/utils';
2
- import { IRecordIdentityWhoAmI } from '../../types/records';
3
2
  export declare const mockPreviews: IPreviewScalar;
4
- export declare const mockRecord: IRecordIdentityWhoAmI;
3
+ export declare const mockRecord: {
4
+ id: string;
5
+ label: string;
6
+ subLabel: string;
7
+ library: {
8
+ id: string;
9
+ label: {
10
+ fr: string;
11
+ };
12
+ };
13
+ preview: IPreviewScalar;
14
+ color: string;
15
+ };
@@ -1 +1 @@
1
- {"version":3,"file":"record.js","sourceRoot":"","sources":["../../../src/__mocks__/common/record.ts"],"names":[],"mappings":"AAMA,MAAM,CAAC,MAAM,YAAY,GAAmB;IACxC,IAAI,EAAE,oBAAoB;IAC1B,KAAK,EAAE,qBAAqB;IAC5B,MAAM,EAAE,sBAAsB;IAC9B,GAAG,EAAE,mBAAmB;IACxB,IAAI,EAAE,oBAAoB;IAC1B,QAAQ,EAAE,wBAAwB;IAClC,IAAI,EAAE,IAAI;CACb,CAAC;AAEF,MAAM,CAAC,MAAM,UAAU,GAA0B;IAC7C,EAAE,EAAE,QAAQ;IACZ,KAAK,EAAE,cAAc;IACrB,QAAQ,EAAE,iBAAiB;IAC3B,OAAO,EAAE;QACL,EAAE,EAAE,YAAY;QAChB,KAAK,EAAE,EAAC,EAAE,EAAE,UAAU,EAAC;KAC1B;IACD,OAAO,EAAE,YAAY;IACrB,KAAK,EAAE,MAAM;CAChB,CAAC"}
1
+ {"version":3,"file":"record.js","sourceRoot":"","sources":["../../../src/__mocks__/common/record.ts"],"names":[],"mappings":"AAMA,MAAM,CAAC,MAAM,YAAY,GAAmB;IACxC,IAAI,EAAE,oBAAoB;IAC1B,KAAK,EAAE,qBAAqB;IAC5B,MAAM,EAAE,sBAAsB;IAC9B,GAAG,EAAE,mBAAmB;IACxB,IAAI,EAAE,oBAAoB;IAC1B,QAAQ,EAAE,wBAAwB;IAClC,IAAI,EAAE,IAAI;CACb,CAAC;AAEF,MAAM,CAAC,MAAM,UAAU,GAAG;IACtB,EAAE,EAAE,QAAQ;IACZ,KAAK,EAAE,cAAc;IACrB,QAAQ,EAAE,iBAAiB;IAC3B,OAAO,EAAE;QACL,EAAE,EAAE,YAAY;QAChB,KAAK,EAAE,EAAC,EAAE,EAAE,UAAU,EAAC;KAC1B;IACD,OAAO,EAAE,YAAY;IACrB,KAAK,EAAE,MAAM;CACgB,CAAC"}
@@ -160,6 +160,7 @@ export declare enum AttributeType {
160
160
  export type AttributesFiltersInput = {
161
161
  format?: InputMaybe<Array<InputMaybe<AttributeFormat>>>;
162
162
  id?: InputMaybe<Scalars['ID']>;
163
+ ids?: InputMaybe<Array<Scalars['ID']>>;
163
164
  label?: InputMaybe<Scalars['String']>;
164
165
  libraries?: InputMaybe<Array<InputMaybe<Scalars['String']>>>;
165
166
  librariesExcluded?: InputMaybe<Array<InputMaybe<Scalars['String']>>>;
@@ -2523,6 +2524,13 @@ export type ViewDetailsFragment = {
2523
2524
  value?: any | null;
2524
2525
  }> | null;
2525
2526
  };
2527
+ export type AttributePropertiesFragment = {
2528
+ id: string;
2529
+ label?: any | null;
2530
+ type: AttributeType;
2531
+ format?: AttributeFormat | null;
2532
+ multiple_values: boolean;
2533
+ };
2526
2534
  export type PropertyValueLinkValueFragment = {
2527
2535
  linkPayload?: {
2528
2536
  id: string;
@@ -2538,9 +2546,6 @@ export type PropertyValueLinkValueFragment = {
2538
2546
  };
2539
2547
  };
2540
2548
  } | null;
2541
- attribute: {
2542
- type: AttributeType;
2543
- };
2544
2549
  };
2545
2550
  export type PropertyValueTreeValueFragment = {
2546
2551
  treePayload?: {
@@ -2559,15 +2564,9 @@ export type PropertyValueTreeValueFragment = {
2559
2564
  };
2560
2565
  };
2561
2566
  } | null;
2562
- attribute: {
2563
- type: AttributeType;
2564
- };
2565
2567
  };
2566
2568
  export type PropertyValueValueFragment = {
2567
2569
  valuePayload?: any | null;
2568
- attribute: {
2569
- type: AttributeType;
2570
- };
2571
2570
  };
2572
2571
  export type PropertyValueFragment = PropertyValueLinkValueFragment | PropertyValueTreeValueFragment | PropertyValueValueFragment;
2573
2572
  export type CheckApplicationExistenceQueryVariables = Exact<{
@@ -5960,6 +5959,13 @@ export type ExplorerQuery = {
5960
5959
  };
5961
5960
  properties: Array<{
5962
5961
  attributeId: string;
5962
+ attributeProperties: {
5963
+ id: string;
5964
+ label?: any | null;
5965
+ type: AttributeType;
5966
+ format?: AttributeFormat | null;
5967
+ multiple_values: boolean;
5968
+ };
5963
5969
  values: Array<{
5964
5970
  linkPayload?: {
5965
5971
  id: string;
@@ -5975,9 +5981,6 @@ export type ExplorerQuery = {
5975
5981
  };
5976
5982
  };
5977
5983
  } | null;
5978
- attribute: {
5979
- type: AttributeType;
5980
- };
5981
5984
  } | {
5982
5985
  treePayload?: {
5983
5986
  record: {
@@ -5995,19 +5998,24 @@ export type ExplorerQuery = {
5995
5998
  };
5996
5999
  };
5997
6000
  } | null;
5998
- attribute: {
5999
- type: AttributeType;
6000
- };
6001
6001
  } | {
6002
6002
  valuePayload?: any | null;
6003
- attribute: {
6004
- type: AttributeType;
6005
- };
6006
6003
  }>;
6007
6004
  }>;
6008
6005
  }>;
6009
6006
  };
6010
6007
  };
6008
+ export type ExplorerLibraryDataQueryVariables = Exact<{
6009
+ libraryId: Scalars['ID'];
6010
+ }>;
6011
+ export type ExplorerLibraryDataQuery = {
6012
+ libraries?: {
6013
+ list: Array<{
6014
+ id: string;
6015
+ label?: any | null;
6016
+ }>;
6017
+ } | null;
6018
+ };
6011
6019
  export declare const RecordIdentityFragmentDoc: Apollo.DocumentNode;
6012
6020
  export declare const DetailsApplicationFragmentDoc: Apollo.DocumentNode;
6013
6021
  export declare const AttributeDetailsFragmentDoc: Apollo.DocumentNode;
@@ -6027,6 +6035,7 @@ export declare const TreeDetailsFragmentDoc: Apollo.DocumentNode;
6027
6035
  export declare const TreeNodeChildFragmentDoc: Apollo.DocumentNode;
6028
6036
  export declare const ViewDetailsFragmentDoc: Apollo.DocumentNode;
6029
6037
  export declare const PropertyValueFragmentDoc: Apollo.DocumentNode;
6038
+ export declare const AttributePropertiesFragmentDoc: Apollo.DocumentNode;
6030
6039
  export declare const CheckApplicationExistenceDocument: Apollo.DocumentNode;
6031
6040
  /**
6032
6041
  * __useCheckApplicationExistenceQuery__
@@ -7469,3 +7478,29 @@ export declare function useExplorerLazyQuery(baseOptions?: Apollo.LazyQueryHookO
7469
7478
  export type ExplorerQueryHookResult = ReturnType<typeof useExplorerQuery>;
7470
7479
  export type ExplorerLazyQueryHookResult = ReturnType<typeof useExplorerLazyQuery>;
7471
7480
  export type ExplorerQueryResult = Apollo.QueryResult<ExplorerQuery, ExplorerQueryVariables>;
7481
+ export declare const ExplorerLibraryDataDocument: Apollo.DocumentNode;
7482
+ /**
7483
+ * __useExplorerLibraryDataQuery__
7484
+ *
7485
+ * To run a query within a React component, call `useExplorerLibraryDataQuery` and pass it any options that fit your needs.
7486
+ * When your component renders, `useExplorerLibraryDataQuery` returns an object from Apollo Client that contains loading, error, and data properties
7487
+ * you can use to render your UI.
7488
+ *
7489
+ * @param baseOptions options that will be passed into the query, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options;
7490
+ *
7491
+ * @example
7492
+ * const { data, loading, error } = useExplorerLibraryDataQuery({
7493
+ * variables: {
7494
+ * libraryId: // value for 'libraryId'
7495
+ * },
7496
+ * });
7497
+ */
7498
+ export declare function useExplorerLibraryDataQuery(baseOptions: Apollo.QueryHookOptions<ExplorerLibraryDataQuery, ExplorerLibraryDataQueryVariables>): Apollo.QueryResult<ExplorerLibraryDataQuery, Exact<{
7499
+ libraryId: Scalars["ID"];
7500
+ }>>;
7501
+ export declare function useExplorerLibraryDataLazyQuery(baseOptions?: Apollo.LazyQueryHookOptions<ExplorerLibraryDataQuery, ExplorerLibraryDataQueryVariables>): Apollo.LazyQueryResultTuple<ExplorerLibraryDataQuery, Exact<{
7502
+ libraryId: Scalars["ID"];
7503
+ }>>;
7504
+ export type ExplorerLibraryDataQueryHookResult = ReturnType<typeof useExplorerLibraryDataQuery>;
7505
+ export type ExplorerLibraryDataLazyQueryHookResult = ReturnType<typeof useExplorerLibraryDataLazyQuery>;
7506
+ export type ExplorerLibraryDataQueryResult = Apollo.QueryResult<ExplorerLibraryDataQuery, ExplorerLibraryDataQueryVariables>;