@volr/react-ui 0.1.119 → 0.1.120

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.cjs CHANGED
@@ -531,6 +531,7 @@ var en = {
531
531
  titleTouchId: "Set up Touch ID login",
532
532
  titleFaceId: "Set up Face ID login",
533
533
  titleFingerprint: "Set up fingerprint login",
534
+ titleQrCode: "Set up mobile login",
534
535
  // Short description
535
536
  description: "Sign in instantly, every time.",
536
537
  // Legacy keys for backward compatibility
@@ -560,6 +561,7 @@ var en = {
560
561
  outdatedSamsung: "Please update Samsung Internet to the latest version.",
561
562
  outdatedIOS: "iOS 17.4 or later is required. Please check for software updates in Settings.",
562
563
  firefoxNotSupported: "Secure login is not available in Firefox. Please use Chrome or Safari.",
564
+ whaleNotSupported: "Secure login is not available in Whale browser. Please use Chrome.",
563
565
  unknownBrowser: "Secure login may not work properly in this browser.",
564
566
  openInExternalBrowser: "Open in external browser",
565
567
  updateBrowser: "Update browser",
@@ -758,6 +760,7 @@ var ko = {
758
760
  titleTouchId: "Touch ID \uB85C\uADF8\uC778 \uC124\uC815",
759
761
  titleFaceId: "Face ID \uB85C\uADF8\uC778 \uC124\uC815",
760
762
  titleFingerprint: "\uC9C0\uBB38 \uB85C\uADF8\uC778 \uC124\uC815",
763
+ titleQrCode: "\uD734\uB300\uD3F0\uC73C\uB85C \uB85C\uADF8\uC778 \uC124\uC815",
761
764
  // Short description
762
765
  description: "\uD55C \uBC88 \uB4F1\uB85D\uD558\uBA74, \uB2E4\uC74C\uBD80\uD130 \uBC14\uB85C \uB85C\uADF8\uC778",
763
766
  // Legacy keys for backward compatibility
@@ -787,6 +790,7 @@ var ko = {
787
790
  outdatedSamsung: "Samsung Internet\uC744 \uCD5C\uC2E0 \uBC84\uC804\uC73C\uB85C \uC5C5\uB370\uC774\uD2B8\uD574\uC8FC\uC138\uC694.",
788
791
  outdatedIOS: "iOS 17.4 \uC774\uC0C1 \uBC84\uC804\uC774 \uD544\uC694\uD569\uB2C8\uB2E4. \uC124\uC815\uC5D0\uC11C \uC18C\uD504\uD2B8\uC6E8\uC5B4 \uC5C5\uB370\uC774\uD2B8\uB97C \uD655\uC778\uD574\uC8FC\uC138\uC694.",
789
792
  firefoxNotSupported: "Firefox\uC5D0\uC11C\uB294 \uBCF4\uC548 \uB85C\uADF8\uC778\uC744 \uC0AC\uC6A9\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. Chrome \uB610\uB294 Safari\uB97C \uC0AC\uC6A9\uD574\uC8FC\uC138\uC694.",
793
+ whaleNotSupported: "\uC6E8\uC77C \uBE0C\uB77C\uC6B0\uC800\uC5D0\uC11C\uB294 \uBCF4\uC548 \uB85C\uADF8\uC778\uC744 \uC0AC\uC6A9\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. Chrome\uC744 \uC0AC\uC6A9\uD574\uC8FC\uC138\uC694.",
790
794
  unknownBrowser: "\uC774 \uBE0C\uB77C\uC6B0\uC800\uC5D0\uC11C\uB294 \uBCF4\uC548 \uB85C\uADF8\uC778\uC774 \uC81C\uB300\uB85C \uC791\uB3D9\uD558\uC9C0 \uC54A\uC744 \uC218 \uC788\uC2B5\uB2C8\uB2E4.",
791
795
  openInExternalBrowser: "\uC678\uBD80 \uBE0C\uB77C\uC6B0\uC800\uC5D0\uC11C \uC5F4\uAE30",
792
796
  updateBrowser: "\uBE0C\uB77C\uC6B0\uC800 \uC5C5\uB370\uC774\uD2B8",
@@ -1371,13 +1375,21 @@ var ModalHeader = ({
1371
1375
 
1372
1376
  // src/components/features/passkey/utils/biometric.ts
1373
1377
  function getBiometricType() {
1378
+ if (typeof navigator === "undefined") return "fingerprint";
1374
1379
  const ua = navigator.userAgent;
1380
+ const platform = navigator.platform || "";
1375
1381
  if (/iPhone|iPad|iPod/.test(ua)) {
1376
1382
  return "faceId";
1377
1383
  }
1378
1384
  if (/Macintosh|MacIntel/.test(ua)) {
1385
+ if (navigator.maxTouchPoints > 1) {
1386
+ return "faceId";
1387
+ }
1379
1388
  return "touchId";
1380
1389
  }
1390
+ if (/Win/.test(platform)) {
1391
+ return "qrCode";
1392
+ }
1381
1393
  return "fingerprint";
1382
1394
  }
1383
1395
  function getUserFriendlyError(error, t) {
@@ -1625,12 +1637,44 @@ function FingerprintIcon({ size }) {
1625
1637
  }
1626
1638
  );
1627
1639
  }
1640
+ function QrCodeIcon({ size }) {
1641
+ const fill = "#f87171";
1642
+ return /* @__PURE__ */ jsxRuntime.jsxs(
1643
+ "svg",
1644
+ {
1645
+ width: size,
1646
+ height: size,
1647
+ viewBox: "0 0 24 24",
1648
+ fill: "none",
1649
+ xmlns: "http://www.w3.org/2000/svg",
1650
+ children: [
1651
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "3", y: "3", width: "7", height: "7", rx: "1", fill }),
1652
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "14", y: "3", width: "7", height: "7", rx: "1", fill }),
1653
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "3", y: "14", width: "7", height: "7", rx: "1", fill }),
1654
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "5", y: "5", width: "3", height: "3", fill: "white" }),
1655
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "16", y: "5", width: "3", height: "3", fill: "white" }),
1656
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "5", y: "16", width: "3", height: "3", fill: "white" }),
1657
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "14", y: "14", width: "2", height: "2", fill }),
1658
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "17", y: "14", width: "2", height: "2", fill }),
1659
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "14", y: "17", width: "2", height: "2", fill }),
1660
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "19", y: "17", width: "2", height: "2", fill }),
1661
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "17", y: "19", width: "2", height: "2", fill }),
1662
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "11", y: "3", width: "2", height: "2", fill }),
1663
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "11", y: "6", width: "2", height: "2", fill }),
1664
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "11", y: "11", width: "2", height: "2", fill }),
1665
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "3", y: "11", width: "2", height: "2", fill }),
1666
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "6", y: "11", width: "2", height: "2", fill })
1667
+ ]
1668
+ }
1669
+ );
1670
+ }
1628
1671
  function BiometricIcon({ type, size = 80, animate = false }) {
1629
1672
  const className = animate ? "volr:animate-pulse" : "";
1630
1673
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className, children: [
1631
1674
  type === "faceId" && /* @__PURE__ */ jsxRuntime.jsx(FaceIdIcon, { size }),
1632
1675
  type === "touchId" && /* @__PURE__ */ jsxRuntime.jsx(TouchIdIcon, { size }),
1633
- type === "fingerprint" && /* @__PURE__ */ jsxRuntime.jsx(FingerprintIcon, { size })
1676
+ type === "fingerprint" && /* @__PURE__ */ jsxRuntime.jsx(FingerprintIcon, { size }),
1677
+ type === "qrCode" && /* @__PURE__ */ jsxRuntime.jsx(QrCodeIcon, { size })
1634
1678
  ] });
1635
1679
  }
1636
1680
  var sizeMap = {
@@ -1965,13 +2009,16 @@ function PasskeyEnrollView({
1965
2009
  }
1966
2010
  };
1967
2011
  const getBiometricTitle = () => {
1968
- if (biometricType === "faceId") {
1969
- return t("passkey.titleFaceId");
1970
- }
1971
- if (biometricType === "touchId") {
1972
- return t("passkey.titleTouchId");
2012
+ switch (biometricType) {
2013
+ case "faceId":
2014
+ return t("passkey.titleFaceId");
2015
+ case "touchId":
2016
+ return t("passkey.titleTouchId");
2017
+ case "qrCode":
2018
+ return t("passkey.titleQrCode");
2019
+ default:
2020
+ return t("passkey.titleFingerprint");
1973
2021
  }
1974
- return t("passkey.titleFingerprint");
1975
2022
  };
1976
2023
  const getBiometricDescription = () => {
1977
2024
  return t("passkey.description");