finance-shared 0.0.21 → 0.0.23

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.
@@ -25976,6 +25976,13 @@ const PDFPreviewForTheSignature = ({
25976
25976
  applicationDetailsData
25977
25977
  );
25978
25978
  const [isTermsConfirmed, setIsTermsConfirmed] = useState(false);
25979
+ const isMobileWebView = (() => {
25980
+ try {
25981
+ return localStorage.getItem("isMobileView") === "true";
25982
+ } catch {
25983
+ return false;
25984
+ }
25985
+ })();
25979
25986
  return /* @__PURE__ */ jsx(Dialog$1, { open, onClose, maxWidth: "lg", fullWidth: true, ...props, children: /* @__PURE__ */ jsxs(DialogContent$1, { className: "p-0", children: [
25980
25987
  !pdfOnly && (dialogTitle || financeCalculation) && /* @__PURE__ */ jsxs("div", { className: "px-16 pt-12 pb-16", children: [
25981
25988
  dialogTitle && /* @__PURE__ */ jsx(Typography$1, { variant: "h6", className: "font-semibold mb-12", children: dialogTitle }),
@@ -26048,7 +26055,21 @@ const PDFPreviewForTheSignature = ({
26048
26055
  ] }) })
26049
26056
  ] })
26050
26057
  ] }),
26051
- /* @__PURE__ */ jsx("div", { className: "px-16 py-12", children: /* @__PURE__ */ jsx(
26058
+ /* @__PURE__ */ jsx("div", { className: "px-16 py-12", children: isMobileWebView ? (
26059
+ // The embedded app WebView has no native PDF plugin, so a plain
26060
+ // <embed> renders blank there. Route through Google's viewer
26061
+ // instead, which fetches and rasterizes the PDF itself — regular
26062
+ // browsers (desktop and mobile) keep the native <embed> below.
26063
+ /* @__PURE__ */ jsx(
26064
+ "iframe",
26065
+ {
26066
+ src: `https://docs.google.com/viewer?embedded=true&url=${encodeURIComponent(filePath)}`,
26067
+ width: "100%",
26068
+ style: { height: pdfOnly ? "85vh" : "70vh", border: "none" },
26069
+ title: "PDF preview"
26070
+ }
26071
+ )
26072
+ ) : /* @__PURE__ */ jsx(
26052
26073
  "embed",
26053
26074
  {
26054
26075
  src: filePath,
@@ -26218,7 +26239,7 @@ function DocumentSigningDialog({
26218
26239
  showConfirmCheckbox = false,
26219
26240
  showTitle = true,
26220
26241
  requireAuthFactor = false,
26221
- isOfficer
26242
+ isOfficer = false
26222
26243
  }) {
26223
26244
  const { t: t2 } = useTranslation("Dialog");
26224
26245
  const open = useSelector(getIsDocumentSignatureDialogOpen);