sales-frontend-components 0.0.127 → 0.0.129

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/dist/index.d.ts CHANGED
@@ -466,7 +466,7 @@ interface RivUrlParams {
466
466
  nationalityType?: 'D' | 'F';
467
467
  }
468
468
  interface RemoteIdentityVerificationSuccess {
469
- rivsRqstId: string;
469
+ rivsRequestId: string;
470
470
  }
471
471
  interface UseRemoteIdentityVerificationProps {
472
472
  rivEnv?: 'prd' | 'stg' | 'dev';
@@ -486,9 +486,9 @@ interface UseRemoteIdentityVerificationProps {
486
486
  declare const useRemoteIdentityVerification: ({ rivEnv, rivOrigin, tokenRequestParams, apiConfig, onCancel, onError, onSuccess, rivSearchParams }: UseRemoteIdentityVerificationProps) => {
487
487
  createRemoteIdentityVerificationUrl: () => Promise<{
488
488
  fullUrl: string;
489
- rivsRqstId: string;
489
+ rivsRequestId: string;
490
490
  }>;
491
- createMessageHandler: ({ rivsRqstId }: RemoteIdentityVerificationSuccess, cleanup?: () => void) => (event: MessageEvent) => void;
491
+ createMessageHandler: ({ rivsRequestId }: RemoteIdentityVerificationSuccess, cleanup?: () => void) => (event: MessageEvent) => void;
492
492
  };
493
493
  /**
494
494
  * Iframe용 비대면인증시스템 훅
package/dist/index.esm.js CHANGED
@@ -3917,9 +3917,9 @@ const useRemoteIdentityVerification = ({
3917
3917
  rivsRqstId: remoteIdentityVerificationSystemRequestId,
3918
3918
  ...rivSearchParams
3919
3919
  });
3920
- return { fullUrl: `${rivHost}/?${urlParams.toString()}`, rivsRqstId: remoteIdentityVerificationSystemRequestId };
3920
+ return { fullUrl: `${rivHost}/?${urlParams.toString()}`, rivsRequestId: remoteIdentityVerificationSystemRequestId };
3921
3921
  };
3922
- const createMessageHandler = ({ rivsRqstId }, cleanup) => {
3922
+ const createMessageHandler = ({ rivsRequestId }, cleanup) => {
3923
3923
  return (event) => {
3924
3924
  try {
3925
3925
  const response = typeof event.data === "string" ? JSON.parse(decodeURIComponent(event.data)) : event.data;
@@ -3938,12 +3938,12 @@ const useRemoteIdentityVerification = ({
3938
3938
  case VERIFICATION_CODES.ATTEMPT_EXCEEDED:
3939
3939
  case VERIFICATION_CODES.SERVER_ERROR:
3940
3940
  console.log("=====\uBE44\uB300\uBA74\uC778\uC99D \uC2E4\uD328!=====", { result, code });
3941
- onError?.({ result, code }, { rivsRqstId });
3941
+ onError?.({ result, code }, { rivsRequestId });
3942
3942
  cleanup?.();
3943
3943
  break;
3944
3944
  case VERIFICATION_CODES.SUCCESS:
3945
3945
  console.log("=====\uBE44\uB300\uBA74\uC778\uC99D \uC131\uACF5!=====", { result, code });
3946
- onSuccess?.({ result, code }, { rivsRqstId });
3946
+ onSuccess?.({ result, code }, { rivsRequestId });
3947
3947
  cleanup?.();
3948
3948
  break;
3949
3949
  default:
@@ -3963,7 +3963,7 @@ const useRemoteIdentityVerificationIframe = (config) => {
3963
3963
  const { createMessageHandler, createRemoteIdentityVerificationUrl } = useRemoteIdentityVerification(config);
3964
3964
  const { isOpen, openModal, closeModal } = useModalState();
3965
3965
  const [remoteIdentityVerificationUrl, setRemoteIdentityVerificationUrl] = useState("");
3966
- const [rivsRqstId, setRivsRqstId] = useState("");
3966
+ const [rivsRequestId, setRivsRequestId] = useState("");
3967
3967
  const [isCreatingUrl, setIsCreatingUrl] = useState(false);
3968
3968
  const [isIframeLoaded, setIsIframeLoaded] = useState(false);
3969
3969
  const createIframeUrl = async () => {
@@ -3973,9 +3973,9 @@ const useRemoteIdentityVerificationIframe = (config) => {
3973
3973
  setIsCreatingUrl(true);
3974
3974
  setIsIframeLoaded(false);
3975
3975
  try {
3976
- const { fullUrl, rivsRqstId: rivsRqstId2 } = await createRemoteIdentityVerificationUrl();
3976
+ const { fullUrl, rivsRequestId: rivsRequestId2 } = await createRemoteIdentityVerificationUrl();
3977
3977
  setRemoteIdentityVerificationUrl(fullUrl);
3978
- setRivsRqstId(rivsRqstId2);
3978
+ setRivsRequestId(rivsRequestId2);
3979
3979
  } catch (error) {
3980
3980
  console.error("Failed to create URL:", error);
3981
3981
  throw error;
@@ -3995,13 +3995,13 @@ const useRemoteIdentityVerificationIframe = (config) => {
3995
3995
  result: "N",
3996
3996
  code: VERIFICATION_CODES.TOKEN_ERROR
3997
3997
  },
3998
- { rivsRqstId: "" }
3998
+ { rivsRequestId: "" }
3999
3999
  );
4000
4000
  }
4001
4001
  };
4002
4002
  const closeRivIframe = () => {
4003
4003
  setRemoteIdentityVerificationUrl("");
4004
- setRivsRqstId("");
4004
+ setRivsRequestId("");
4005
4005
  setIsIframeLoaded(false);
4006
4006
  closeModal();
4007
4007
  };
@@ -4009,10 +4009,10 @@ const useRemoteIdentityVerificationIframe = (config) => {
4009
4009
  if (!remoteIdentityVerificationUrl) {
4010
4010
  return;
4011
4011
  }
4012
- const messageHandler = createMessageHandler({ rivsRqstId }, closeRivIframe);
4012
+ const messageHandler = createMessageHandler({ rivsRequestId }, closeRivIframe);
4013
4013
  MessageEventManager.getInstance().registerHandler("riv-iframe-handler", messageHandler);
4014
4014
  return () => MessageEventManager.getInstance().unregisterHandler("riv-iframe-handler");
4015
- }, [remoteIdentityVerificationUrl, rivsRqstId]);
4015
+ }, [remoteIdentityVerificationUrl, rivsRequestId]);
4016
4016
  const RivIframe = ({
4017
4017
  width = "100%",
4018
4018
  height = "100%",
@@ -4070,7 +4070,7 @@ const useRemoteIdentityVerificationIframe = (config) => {
4070
4070
  const useRemoteIdentityVerificationPopup = (config) => {
4071
4071
  const { createRemoteIdentityVerificationUrl, createMessageHandler } = useRemoteIdentityVerification(config);
4072
4072
  const [isCreatingUrl, setIsCreatingUrl] = useState(false);
4073
- const [rivsRqstId, setRivsRqstId] = useState("");
4073
+ const [rivsRequestId, setRivsRequestId] = useState("");
4074
4074
  const popupRef = useRef(null);
4075
4075
  const openPopup = async (target = "_blank", features) => {
4076
4076
  if (popupRef.current && !popupRef.current.closed) {
@@ -4078,13 +4078,13 @@ const useRemoteIdentityVerificationPopup = (config) => {
4078
4078
  }
4079
4079
  setIsCreatingUrl(true);
4080
4080
  try {
4081
- const { fullUrl, rivsRqstId: rivsRqstId2 } = await createRemoteIdentityVerificationUrl();
4081
+ const { fullUrl, rivsRequestId: rivsRequestId2 } = await createRemoteIdentityVerificationUrl();
4082
4082
  const popup = window.open(fullUrl, target, features);
4083
4083
  if (!popup) {
4084
4084
  await ModalUtils.alert("\uD31D\uC5C5\uC774 \uCC28\uB2E8\uB418\uC5C8\uC2B5\uB2C8\uB2E4. \uD31D\uC5C5\uC744 \uD5C8\uC6A9\uD574\uC8FC\uC138\uC694.");
4085
4085
  return;
4086
4086
  }
4087
- setRivsRqstId(rivsRqstId2);
4087
+ setRivsRequestId(rivsRequestId2);
4088
4088
  popupRef.current = popup;
4089
4089
  } catch (error) {
4090
4090
  console.error("openPopup error::", error);
@@ -4097,10 +4097,10 @@ const useRemoteIdentityVerificationPopup = (config) => {
4097
4097
  popupRef.current = null;
4098
4098
  };
4099
4099
  useEffect(() => {
4100
- const messageHandler = createMessageHandler({ rivsRqstId }, cleanPopup);
4100
+ const messageHandler = createMessageHandler({ rivsRequestId }, cleanPopup);
4101
4101
  MessageEventManager.getInstance().registerHandler("riv-popup-handler", messageHandler);
4102
4102
  return () => MessageEventManager.getInstance().unregisterHandler("riv-popup-handler");
4103
- }, [rivsRqstId]);
4103
+ }, [rivsRequestId]);
4104
4104
  return {
4105
4105
  openPopup,
4106
4106
  isCreatingUrl