@hiver/connector-admin 4.18.0-multiStore-beta.0 → 4.18.0-multiStore-beta.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hiver/connector-admin",
3
- "version": "4.18.0-multiStore-beta.0",
3
+ "version": "4.18.0-multiStore-beta.1",
4
4
  "main": "index.es.js",
5
5
  "module": "index.es.js",
6
6
  "types": "index.d.ts",
@@ -1,7 +1,9 @@
1
1
  import { IConnectorDetails } from '../../../../../types/connector';
2
2
  interface AuthSettings {
3
3
  connectorData: IConnectorDetails | null;
4
+ storeName?: string;
5
+ parentConnectorId?: string;
4
6
  }
5
- export declare const AuthSettings: ({ connectorData }: AuthSettings) => import("react/jsx-runtime").JSX.Element;
7
+ export declare const AuthSettings: ({ connectorData, storeName, parentConnectorId }: AuthSettings) => import("react/jsx-runtime").JSX.Element;
6
8
  export {};
7
9
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../src/v2/app/connectors/pages/settings/auth/index.tsx"],"names":[],"mappings":"AAqCA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAE9D,UAAU,YAAY;IACpB,aAAa,EAAE,iBAAiB,GAAG,IAAI,CAAC;CACzC;AAED,eAAO,MAAM,YAAY,sBAAuB,YAAY,4CAyN3D,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../src/v2/app/connectors/pages/settings/auth/index.tsx"],"names":[],"mappings":"AAqCA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAE9D,UAAU,YAAY;IACpB,aAAa,EAAE,iBAAiB,GAAG,IAAI,CAAC;IAIxC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B;AAED,eAAO,MAAM,YAAY,oDAAqD,YAAY,4CA2NzF,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/v2/app/connectors/pages/settings/index.tsx"],"names":[],"mappings":"AA6CA,eAAO,MAAM,QAAQ,+CA8IpB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/v2/app/connectors/pages/settings/index.tsx"],"names":[],"mappings":"AA6CA,eAAO,MAAM,QAAQ,+CAqJpB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/v2/features/add-new-store/components/add-new-store-button/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAGxC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAmB9D,MAAM,WAAW,uBAAuB;IACtC,gBAAgB,EAAE,iBAAiB,GAAG,IAAI,CAAC;CAC5C;AAED,eAAO,MAAM,iBAAiB,EAAE,KAAK,CAAC,EAAE,CAAC,uBAAuB,CA2I/D,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/v2/features/add-new-store/components/add-new-store-button/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAIxC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAQ9D,MAAM,WAAW,uBAAuB;IACtC,gBAAgB,EAAE,iBAAiB,GAAG,IAAI,CAAC;CAC5C;AAED,eAAO,MAAM,iBAAiB,EAAE,KAAK,CAAC,EAAE,CAAC,uBAAuB,CA8G/D,CAAC"}
@@ -1,18 +1,7 @@
1
- import { IAuthDetails } from '../../../types/connector';
2
- import { AuthRequest, ValidateStoreReason } from '../../auth/types/request';
1
+ import { ValidateStoreReason } from '../../auth/types/request';
3
2
  /**
4
3
  * Maps a `validateNewStore` failure reason to the inline message surfaced under
5
4
  * the modal input. Unknown/absent reasons fall back to a generic error.
6
5
  */
7
6
  export declare const getValidateErrorMessage: (reason?: ValidateStoreReason) => string;
8
- /**
9
- * Builds the `authDetails` for the create-store POST from the parent
10
- * connector's own auth config. A store is cloned from its parent, so the
11
- * backend (given `parentConnectorId`) sources the real credentials from the
12
- * parent; the shape we send here mainly carries the `authType`, which drives
13
- * `useAuthDetailsMutation`'s response normalization (OAuth2 → popup URL,
14
- * non-OAuth → immediate success). Missing OAuth2 credential values (secrets are
15
- * redacted off the fetched connector) default to empty strings.
16
- */
17
- export declare const getStoreAuthDetails: (details?: IAuthDetails) => AuthRequest["authDetails"];
18
7
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/add-new-store/utils/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AACzD,OAAO,KAAK,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AAIzF;;;GAGG;AACH,eAAO,MAAM,uBAAuB,YAAa,mBAAmB,KAAG,MAKtE,CAAC;AAEF;;;;;;;;GAQG;AACH,eAAO,MAAM,mBAAmB,aAAc,YAAY,KAAG,WAAW,CAAC,aAAa,CA+DrF,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/add-new-store/utils/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AAI5E;;;GAGG;AACH,eAAO,MAAM,uBAAuB,YAAa,mBAAmB,KAAG,MAKtE,CAAC"}
@@ -10,7 +10,9 @@ interface IAuthForm {
10
10
  isAuthPending: boolean;
11
11
  authStatus: IAUTH_STATUS;
12
12
  authMutate: UseMutateFunction<AuthMutationResponse, Error, AuthMutationPayload>;
13
+ storeName?: string;
14
+ parentConnectorId?: string;
13
15
  }
14
- export declare const AuthForm: ({ isEdit, connectorId, isLoading, connectorData, isAuthPending, authStatus, authMutate }: IAuthForm) => import("react/jsx-runtime").JSX.Element;
16
+ export declare const AuthForm: ({ isEdit, connectorId, isLoading, connectorData, isAuthPending, authStatus, authMutate, storeName, parentConnectorId }: IAuthForm) => import("react/jsx-runtime").JSX.Element;
15
17
  export {};
16
18
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/v2/features/auth/components/auth-form/index.tsx"],"names":[],"mappings":"AAwDA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAC9D,OAAO,KAAK,EAAE,mBAAmB,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AAG/F,UAAU,SAAS;IACjB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,aAAa,CAAC,EAAE,iBAAiB,GAAG,IAAI,CAAC;IACzC,aAAa,EAAE,OAAO,CAAC;IACvB,UAAU,EAAE,YAAY,CAAC;IACzB,UAAU,EAAE,iBAAiB,CAAC,oBAAoB,EAAE,KAAK,EAAE,mBAAmB,CAAC,CAAC;CACjF;AAED,eAAO,MAAM,QAAQ,6FAQlB,SAAS,4CAuVX,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/v2/features/auth/components/auth-form/index.tsx"],"names":[],"mappings":"AAwDA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAC9D,OAAO,KAAK,EAAE,mBAAmB,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AAG/F,UAAU,SAAS;IACjB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,aAAa,CAAC,EAAE,iBAAiB,GAAG,IAAI,CAAC;IACzC,aAAa,EAAE,OAAO,CAAC;IACvB,UAAU,EAAE,YAAY,CAAC;IACzB,UAAU,EAAE,iBAAiB,CAAC,oBAAoB,EAAE,KAAK,EAAE,mBAAmB,CAAC,CAAC;IAIhF,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B;AAED,eAAO,MAAM,QAAQ,2HAUlB,SAAS,4CAyVX,CAAC"}
@@ -11,12 +11,14 @@ export declare const getFormConfigs: (configs: IFormConfig[], advancedFields: st
11
11
  basicFields: FormFieldProps[];
12
12
  advancedConfigs: IFormConfig[];
13
13
  };
14
- export declare const getAuthRequestBody: ({ isEdit, templateId, values, formFields, predicates }: {
14
+ export declare const getAuthRequestBody: ({ isEdit, templateId, values, formFields, predicates, name, parentConnectorId }: {
15
15
  isEdit: boolean;
16
16
  templateId?: string;
17
17
  values: AuthFormState["values"];
18
18
  formFields: Partial<Record<AuthFieldKeys, FormFieldProps>>;
19
19
  predicates: Predicates;
20
+ name?: string;
21
+ parentConnectorId?: string;
20
22
  }) => AuthRequest | EditAuthRequest;
21
23
  export declare function mapAuthApiDataToStateData(authData: IAuthDetails): Partial<Record<AuthFieldKeys, FieldValue>>;
22
24
  export declare const getVariablesRequestData: (variablesConfig: FormFieldProps[], values: {
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/auth/utils/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,eAAe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d,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B,KAAG,WAAW,GAAG,eAuEjB,CAAC;AAEF,wBAAgB,yBAAyB,CAAC,QAAQ,EAAE,YAAY,GAAG,OAAO,CAAC,MAAM,CAAC,aAAa,EAAE,UAAU,CAAC,CAAC,CAiC5G;AAED,eAAO,MAAM,uBAAuB,oBAAqB,cAAc,EAAE,UAAU;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,CAAA;CAAE;;CAQ/G,CAAC;AAIF,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAEpD,eAAO,MAAM,SAAS,cAAe,MAAM,uaAa1C,CAAC;AAEF,eAAO,MAAM,iBAAiB,cAAe,MAAM,QAalD,CAAC;AAIF,eAAO,MAAM,eAAe,aAAc,MAAM,UAAU,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,WAI/E,CAAC;AAeF,eAAO,MAAM,yBAAyB,aAAc,MAAM,UAAU,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,KAAG,MAAM,GAAG,IAIrG,CAAC;AAEF,eAAO,MAAM,uBAAuB,cAAe,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,6BAYxE,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../../../../src/v2/testing/mocks/handlers/auth.ts"],"names":[],"mappings":"AA+EA,eAAO,MAAM,QAAQ,6BAA0E,CAAC"}
1
+ {"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../../../../src/v2/testing/mocks/handlers/auth.ts"],"names":[],"mappings":"AA0FA,eAAO,MAAM,QAAQ,6BAA4F,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"connector-template.d.ts","sourceRoot":"","sources":["../../../../../src/v2/testing/mocks/handlers/connector-template.ts"],"names":[],"mappings":"AA0UA,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAAyB,CAAC;AAwErD,eAAO,MAAM,QAAQ,6BAYpB,CAAC"}
1
+ {"version":3,"file":"connector-template.d.ts","sourceRoot":"","sources":["../../../../../src/v2/testing/mocks/handlers/connector-template.ts"],"names":[],"mappings":"AAwVA,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAAyB,CAAC;AAwErD,eAAO,MAAM,QAAQ,6BAYpB,CAAC"}