@worldcoin/idkit 1.1.4 → 1.2.0

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.
@@ -45,11 +45,6 @@ var useIDKitStore = createWithEqualityFn()(
45
45
  verifyCallbacks: {},
46
46
  successCallbacks: {},
47
47
  stage: "WORLD_ID" /* WORLD_ID */,
48
- computed: {
49
- canGoBack: (stage) => {
50
- return stage == "PRIVACY" /* PRIVACY */;
51
- }
52
- },
53
48
  setStage: (stage) => set({ stage }),
54
49
  setErrorState: (errorState) => set({ errorState }),
55
50
  setProcessing: (processing) => set({ processing }),
@@ -2,7 +2,6 @@ import { IDKitConfig, ISuccessResult, IErrorState } from '@worldcoin/idkit-core'
2
2
 
3
3
  declare enum IDKITStage {
4
4
  WORLD_ID = "WORLD_ID",
5
- PRIVACY = "PRIVACY",
6
5
  SUCCESS = "SUCCESS",
7
6
  ERROR = "ERROR",
8
7
  HOST_APP_VERIFICATION = "HOST_APP_VERIFICATION"
package/build/index.d.ts CHANGED
@@ -1,7 +1,8 @@
1
- import { C as Config, W as WidgetProps } from './config-71e4be16.js';
1
+ import { C as Config, W as WidgetProps } from './config-19dfed99.js';
2
2
  import * as react from 'react';
3
3
  export { IErrorState, ISuccessResult, VerificationLevel } from '@worldcoin/idkit-core';
4
4
  export { solidityEncode } from '@worldcoin/idkit-core/hashing';
5
+ export { IVerifyResponse, verifyCloudProof } from '@worldcoin/idkit-core/backend';
5
6
 
6
7
  type HookConfig = Partial<Pick<Config, 'handleVerify' | 'onSuccess'>>;
7
8
  declare const useIDKit: ({ handleVerify, onSuccess }?: HookConfig) => {
package/build/index.js CHANGED
@@ -2,7 +2,7 @@ import {
2
2
  QRCode_default,
3
3
  __,
4
4
  idkit_default
5
- } from "./chunk-JCPD6J62.js";
5
+ } from "./chunk-YVDL3YIJ.js";
6
6
 
7
7
  // src/hooks/useIDKit.ts
8
8
  import { useEffect } from "react";
@@ -47,11 +47,6 @@ var useMedia = () => {
47
47
  };
48
48
  var useMedia_default = useMedia;
49
49
 
50
- // src/lib/utils.ts
51
- var classNames = (...classes) => {
52
- return classes.filter(Boolean).join(" ");
53
- };
54
-
55
50
  // src/styles/styles.css
56
51
  var styles_default = `/* TODO: Use an alternative to avoid the extra request to Google (e.g. hosting ourselves, or local file) */
57
52
  @import url('https://fonts.googleapis.com/css2?family=Rubik:wght@400;600;700&family=Sora:wght@600&display=swap');
@@ -621,48 +616,9 @@ select{
621
616
  --tw-backdrop-saturate: ;
622
617
  --tw-backdrop-sepia: ;
623
618
  }
624
- .container{
625
- width: 100%;
626
- }
627
- @media (min-width: 414px){
628
- .container{
629
- max-width: 414px;
630
- }
631
- }
632
- @media (min-width: 640px){
633
- .container{
634
- max-width: 640px;
635
- }
636
- }
637
- @media (min-width: 768px){
638
- .container{
639
- max-width: 768px;
640
- }
641
- }
642
- @media (min-width: 1024px){
643
- .container{
644
- max-width: 1024px;
645
- }
646
- }
647
- @media (min-width: 1280px){
648
- .container{
649
- max-width: 1280px;
650
- }
651
- }
652
- @media (min-width: 1536px){
653
- .container{
654
- max-width: 1536px;
655
- }
656
- }
657
- .pointer-events-none{
658
- pointer-events: none;
659
- }
660
619
  .visible{
661
620
  visibility: visible;
662
621
  }
663
- .invisible{
664
- visibility: hidden;
665
- }
666
622
  .fixed{
667
623
  position: fixed;
668
624
  }
@@ -675,12 +631,6 @@ select{
675
631
  .inset-0{
676
632
  inset: 0;
677
633
  }
678
- .left-1\\/2{
679
- left: 50%;
680
- }
681
- .top-1\\/2{
682
- top: 50%;
683
- }
684
634
  .z-10{
685
635
  z-index: 10;
686
636
  }
@@ -695,18 +645,12 @@ select{
695
645
  margin-left: auto;
696
646
  margin-right: auto;
697
647
  }
698
- .-ml-4{
699
- margin-left: -16px;
700
- }
701
648
  .-mt-5{
702
649
  margin-top: -20px;
703
650
  }
704
651
  .-mt-6{
705
652
  margin-top: -24px;
706
653
  }
707
- .-mt-\\[2px\\]{
708
- margin-top: -2px;
709
- }
710
654
  .mb-10{
711
655
  margin-bottom: 40px;
712
656
  }
@@ -734,9 +678,6 @@ select{
734
678
  .mt-4{
735
679
  margin-top: 16px;
736
680
  }
737
- .mt-\\[2px\\]{
738
- margin-top: 2px;
739
- }
740
681
  .flex{
741
682
  display: flex;
742
683
  }
@@ -746,33 +687,18 @@ select{
746
687
  .hidden{
747
688
  display: none;
748
689
  }
749
- .aspect-square{
750
- aspect-ratio: 1 / 1;
751
- }
752
690
  .h-10{
753
691
  height: 40px;
754
692
  }
755
- .h-12{
756
- height: 48px;
757
- }
758
693
  .h-24{
759
694
  height: 96px;
760
695
  }
761
- .h-3{
762
- height: 12px;
763
- }
764
- .h-4{
765
- height: 16px;
766
- }
767
696
  .h-5{
768
697
  height: 20px;
769
698
  }
770
699
  .h-6{
771
700
  height: 24px;
772
701
  }
773
- .h-8{
774
- height: 32px;
775
- }
776
702
  .h-\\[244px\\]{
777
703
  height: 244px;
778
704
  }
@@ -782,15 +708,9 @@ select{
782
708
  .min-h-screen{
783
709
  min-height: 100vh;
784
710
  }
785
- .w-12{
786
- width: 48px;
787
- }
788
711
  .w-24{
789
712
  width: 96px;
790
713
  }
791
- .w-3{
792
- width: 12px;
793
- }
794
714
  .w-4{
795
715
  width: 16px;
796
716
  }
@@ -800,15 +720,9 @@ select{
800
720
  .w-6{
801
721
  width: 24px;
802
722
  }
803
- .w-8{
804
- width: 32px;
805
- }
806
723
  .w-\\[244px\\]{
807
724
  width: 244px;
808
725
  }
809
- .w-\\[34px\\]{
810
- width: 34px;
811
- }
812
726
  .w-full{
813
727
  width: 100%;
814
728
  }
@@ -818,17 +732,6 @@ select{
818
732
  .flex-1{
819
733
  flex: 1 1 0%;
820
734
  }
821
- .-translate-x-1\\/2{
822
- --tw-translate-x: -50%;
823
- transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
824
- }
825
- .-translate-y-1\\/2{
826
- --tw-translate-y: -50%;
827
- transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
828
- }
829
- .transform{
830
- transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
831
- }
832
735
  @keyframes pulse{
833
736
  50%{
834
737
  opacity: .5;
@@ -848,9 +751,6 @@ select{
848
751
  .cursor-pointer{
849
752
  cursor: pointer;
850
753
  }
851
- .list-disc{
852
- list-style-type: disc;
853
- }
854
754
  .flex-col{
855
755
  flex-direction: column;
856
756
  }
@@ -874,31 +774,16 @@ select{
874
774
  margin-right: calc(8px * var(--tw-space-x-reverse));
875
775
  margin-left: calc(8px * calc(1 - var(--tw-space-x-reverse)));
876
776
  }
877
- .space-x-3 > :not([hidden]) ~ :not([hidden]){
878
- --tw-space-x-reverse: 0;
879
- margin-right: calc(12px * var(--tw-space-x-reverse));
880
- margin-left: calc(12px * calc(1 - var(--tw-space-x-reverse)));
881
- }
882
777
  .space-x-4 > :not([hidden]) ~ :not([hidden]){
883
778
  --tw-space-x-reverse: 0;
884
779
  margin-right: calc(16px * var(--tw-space-x-reverse));
885
780
  margin-left: calc(16px * calc(1 - var(--tw-space-x-reverse)));
886
781
  }
887
- .space-x-6 > :not([hidden]) ~ :not([hidden]){
888
- --tw-space-x-reverse: 0;
889
- margin-right: calc(24px * var(--tw-space-x-reverse));
890
- margin-left: calc(24px * calc(1 - var(--tw-space-x-reverse)));
891
- }
892
782
  .space-y-10 > :not([hidden]) ~ :not([hidden]){
893
783
  --tw-space-y-reverse: 0;
894
784
  margin-top: calc(40px * calc(1 - var(--tw-space-y-reverse)));
895
785
  margin-bottom: calc(40px * var(--tw-space-y-reverse));
896
786
  }
897
- .space-y-3 > :not([hidden]) ~ :not([hidden]){
898
- --tw-space-y-reverse: 0;
899
- margin-top: calc(12px * calc(1 - var(--tw-space-y-reverse)));
900
- margin-bottom: calc(12px * var(--tw-space-y-reverse));
901
- }
902
787
  .space-y-4 > :not([hidden]) ~ :not([hidden]){
903
788
  --tw-space-y-reverse: 0;
904
789
  margin-top: calc(16px * calc(1 - var(--tw-space-y-reverse)));
@@ -917,9 +802,6 @@ select{
917
802
  .overflow-y-hidden{
918
803
  overflow-y: hidden;
919
804
  }
920
- .whitespace-nowrap{
921
- white-space: nowrap;
922
- }
923
805
  .rounded-2xl{
924
806
  border-radius: 1rem;
925
807
  }
@@ -929,9 +811,6 @@ select{
929
811
  .rounded-lg{
930
812
  border-radius: 0.5rem;
931
813
  }
932
- .rounded-md{
933
- border-radius: 0.375rem;
934
- }
935
814
  .border{
936
815
  border-width: 1px;
937
816
  }
@@ -960,17 +839,6 @@ select{
960
839
  .bg-black\\/50{
961
840
  background-color: rgb(0 0 0 / 0.5);
962
841
  }
963
- .bg-d3dfea\\/30{
964
- background-color: rgb(211 223 234 / 0.3);
965
- }
966
- .bg-gray-100{
967
- --tw-bg-opacity: 1;
968
- background-color: rgb(243 244 246 / var(--tw-bg-opacity));
969
- }
970
- .bg-indigo-600{
971
- --tw-bg-opacity: 1;
972
- background-color: rgb(79 70 229 / var(--tw-bg-opacity));
973
- }
974
842
  .bg-transparent{
975
843
  background-color: transparent;
976
844
  }
@@ -987,10 +855,6 @@ select{
987
855
  .p-7{
988
856
  padding: 28px;
989
857
  }
990
- .px-12{
991
- padding-left: 48px;
992
- padding-right: 48px;
993
- }
994
858
  .px-2{
995
859
  padding-left: 8px;
996
860
  padding-right: 8px;
@@ -1007,10 +871,6 @@ select{
1007
871
  padding-top: 4px;
1008
872
  padding-bottom: 4px;
1009
873
  }
1010
- .py-2{
1011
- padding-top: 8px;
1012
- padding-bottom: 8px;
1013
- }
1014
874
  .py-3{
1015
875
  padding-top: 12px;
1016
876
  padding-bottom: 12px;
@@ -1022,9 +882,6 @@ select{
1022
882
  .pt-6{
1023
883
  padding-top: 24px;
1024
884
  }
1025
- .text-left{
1026
- text-align: left;
1027
- }
1028
885
  .text-center{
1029
886
  text-align: center;
1030
887
  }
@@ -1056,15 +913,9 @@ select{
1056
913
  .font-medium{
1057
914
  font-weight: 500;
1058
915
  }
1059
- .font-normal{
1060
- font-weight: 400;
1061
- }
1062
916
  .font-semibold{
1063
917
  font-weight: 600;
1064
918
  }
1065
- .uppercase{
1066
- text-transform: uppercase;
1067
- }
1068
919
  .text-0d151d{
1069
920
  --tw-text-opacity: 1;
1070
921
  color: rgb(13 21 29 / var(--tw-text-opacity));
@@ -1077,10 +928,6 @@ select{
1077
928
  --tw-text-opacity: 1;
1078
929
  color: rgb(60 66 75 / var(--tw-text-opacity));
1079
930
  }
1080
- .text-4940e0{
1081
- --tw-text-opacity: 1;
1082
- color: rgb(73 64 224 / var(--tw-text-opacity));
1083
- }
1084
931
  .text-657080{
1085
932
  --tw-text-opacity: 1;
1086
933
  color: rgb(101 112 128 / var(--tw-text-opacity));
@@ -1155,10 +1002,6 @@ input[type='number']::-webkit-inner-spin-button,
1155
1002
  -webkit-appearance: none;
1156
1003
  appearance: none;
1157
1004
  }
1158
- .hover\\:bg-indigo-700:hover{
1159
- --tw-bg-opacity: 1;
1160
- background-color: rgb(67 56 202 / var(--tw-bg-opacity));
1161
- }
1162
1005
  .hover\\:underline:hover{
1163
1006
  text-decoration-line: underline;
1164
1007
  }
@@ -1214,13 +1057,6 @@ input[type='number']::-webkit-inner-spin-button,
1214
1057
  --tw-bg-opacity: 1;
1215
1058
  background-color: rgb(13 21 29 / var(--tw-bg-opacity));
1216
1059
  }
1217
- :is(.dark .dark\\:bg-29343f){
1218
- --tw-bg-opacity: 1;
1219
- background-color: rgb(41 52 63 / var(--tw-bg-opacity));
1220
- }
1221
- :is(.dark .dark\\:bg-d3dfea\\/15){
1222
- background-color: rgb(211 223 234 / .15);
1223
- }
1224
1060
  :is(.dark .dark\\:bg-white){
1225
1061
  --tw-bg-opacity: 1;
1226
1062
  background-color: rgb(255 255 255 / var(--tw-bg-opacity));
@@ -1456,8 +1292,8 @@ var ErrorState = () => {
1456
1292
  return /* @__PURE__ */ jsxs3("div", { className: "space-y-8", children: [
1457
1293
  /* @__PURE__ */ jsx6("div", { className: "-mt-5 flex items-center justify-center", children: errorState?.code == AppErrorCodes.VerificationRejected ? /* @__PURE__ */ jsx6(WarningIcon_default, { className: "w-24" }) : /* @__PURE__ */ jsx6(ErrorIcon_default, { className: "w-24" }) }),
1458
1294
  /* @__PURE__ */ jsxs3("div", { children: [
1459
- /* @__PURE__ */ jsx6("p", { className: "text-center text-2xl font-semibold text-gray-900 dark:text-white", children: errorState?.code && ERROR_TITLES[errorState.code] || ERROR_TITLES[AppErrorCodes.GenericError] }),
1460
- /* @__PURE__ */ jsx6("p", { className: "mx-auto mt-2 max-w-[224px] text-center text-657080", children: errorState?.message || ERROR_MESSAGES[errorState?.code ?? AppErrorCodes.GenericError] })
1295
+ /* @__PURE__ */ jsx6("p", { className: "text-center text-2xl font-semibold text-gray-900 dark:text-white", children: (errorState?.code && ERROR_TITLES[errorState.code]) ?? ERROR_TITLES[AppErrorCodes.GenericError] }),
1296
+ /* @__PURE__ */ jsx6("p", { className: "mx-auto mt-2 max-w-[224px] text-center text-657080", children: errorState?.message ?? ERROR_MESSAGES[errorState?.code ?? AppErrorCodes.GenericError] })
1461
1297
  ] }),
1462
1298
  /* @__PURE__ */ jsx6("div", { className: "flex justify-center", children: /* @__PURE__ */ jsxs3(
1463
1299
  "button",
@@ -1478,84 +1314,10 @@ var ErrorState_default = ErrorState;
1478
1314
  // src/components/IDKitWidget/BaseWidget.tsx
1479
1315
  import * as Toast from "@radix-ui/react-toast";
1480
1316
 
1481
- // public/images/verified.webp
1482
- var verified_default = "./verified-O6D4JQCX.webp";
1483
-
1484
- // src/components/WorldIDIcon.tsx
1485
- import { Fragment, jsx as jsx7, jsxs as jsxs4 } from "react/jsx-runtime";
1486
- var WorldIDIcon = ({ border, size = "sm", ...props }) => {
1487
- const heightWidth = size === "md" ? 36 : 24;
1488
- return /* @__PURE__ */ jsxs4(Fragment, { children: [
1489
- border && /* @__PURE__ */ jsx7(
1490
- "svg",
1491
- {
1492
- className: classNames(
1493
- border,
1494
- "absolute left-1/2 top-1/2 w-[34px] -mt-[2px] transform -translate-x-1/2 -translate-y-1/2"
1495
- ),
1496
- xmlns: "http://www.w3.org/2000/svg",
1497
- fill: "currentColor",
1498
- viewBox: "0 0 26 26",
1499
- children: /* @__PURE__ */ jsx7("path", { d: "M8.382 2.244a6.938 6.938 0 0 1 9.236 0l1.626 1.451c.346.308.722.581 1.122.815l1.882 1.098a6.937 6.937 0 0 1 2.854 8.784l-.877 1.995c-.187.424-.33.866-.428 1.319l-.463 2.129a6.938 6.938 0 0 1-7.473 5.429l-2.168-.218a6.934 6.934 0 0 0-1.386 0l-2.168.218a6.938 6.938 0 0 1-7.473-5.429l-.463-2.13a6.937 6.937 0 0 0-.428-1.318l-.877-1.995a6.938 6.938 0 0 1 2.854-8.784L5.634 4.51c.4-.234.776-.507 1.122-.815l1.626-1.45Z" })
1500
- }
1501
- ),
1502
- /* @__PURE__ */ jsx7("img", { src: verified_default, ...props, alt: "Verified", width: heightWidth, height: heightWidth })
1503
- ] });
1504
- };
1505
- var WorldIDIcon_default = WorldIDIcon;
1506
-
1507
- // src/components/Icons/InfoIcon.tsx
1508
- import { jsx as jsx8 } from "react/jsx-runtime";
1509
- var InfoIcon = (props) => /* @__PURE__ */ jsx8("svg", { ...props, xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", children: /* @__PURE__ */ jsx8(
1510
- "path",
1511
- {
1512
- fill: "currentColor",
1513
- fillRule: "evenodd",
1514
- d: "M14.665 7.999a6.667 6.667 0 1 1-13.333 0 6.667 6.667 0 0 1 13.333 0Zm-6-3.334a.667.667 0 1 1-1.333 0 .667.667 0 0 1 1.333 0Zm-1.333 1.5a.5.5 0 0 0 0 1h.167v4.167a.5.5 0 1 0 1 0V6.665a.5.5 0 0 0-.5-.5h-.667Z",
1515
- clipRule: "evenodd"
1516
- }
1517
- ) });
1518
- var InfoIcon_default = InfoIcon;
1519
-
1520
- // src/components/IDKitWidget/States/PrivacyState.tsx
1521
- import { jsx as jsx9, jsxs as jsxs5 } from "react/jsx-runtime";
1522
- var PrivacyState = () => {
1523
- return /* @__PURE__ */ jsxs5("div", { className: "-mt-6 flex flex-col items-center justify-center space-y-6 font-sans text-sm", children: [
1524
- /* @__PURE__ */ jsx9(WorldIDIcon_default, { className: "h-12 w-12" }),
1525
- /* @__PURE__ */ jsx9("p", { className: "text-center text-2xl font-semibold dark:text-white", children: __("Privacy preserving to the core.") }),
1526
- /* @__PURE__ */ jsxs5("ul", { className: "text-9eafc0 mb-6 list-disc space-y-3 px-12 dark:text-white", children: [
1527
- /* @__PURE__ */ jsx9("li", { className: "text-left", children: __(
1528
- "World ID uses Zero-Knowledge Proofs to make it cryptographically impossible to track persons across applications."
1529
- ) }),
1530
- /* @__PURE__ */ jsx9("li", { className: "text-left", children: __("Orb biometrics analyzed by the Orb are not stored.") }),
1531
- /* @__PURE__ */ jsxs5("li", { className: "text-left ", children: [
1532
- __("Code and hardware are open source or source available on"),
1533
- " ",
1534
- /* @__PURE__ */ jsx9(
1535
- "a",
1536
- {
1537
- href: "https://github.com/worldcoin/idkit-js",
1538
- target: "_blank",
1539
- className: "text-4940e0",
1540
- rel: "noreferrer",
1541
- children: "GitHub"
1542
- }
1543
- ),
1544
- "."
1545
- ] })
1546
- ] }),
1547
- /* @__PURE__ */ jsxs5("div", { className: "text-9eafc0 dark:text-9eafc0 -ml-4 flex items-center space-x-3", children: [
1548
- /* @__PURE__ */ jsx9(InfoIcon_default, { className: "h-4 w-4 " }),
1549
- /* @__PURE__ */ jsx9("p", { className: "whitespace-nowrap text-sm font-medium", children: __("Biometrics are never shared.") })
1550
- ] })
1551
- ] });
1552
- };
1553
- var PrivacyState_default = PrivacyState;
1554
-
1555
1317
  // src/components/Icons/CheckIcon.tsx
1556
- import { jsx as jsx10, jsxs as jsxs6 } from "react/jsx-runtime";
1557
- var CheckIcon = (props) => /* @__PURE__ */ jsxs6("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 100 100", ...props, children: [
1558
- /* @__PURE__ */ jsx10(
1318
+ import { jsx as jsx7, jsxs as jsxs4 } from "react/jsx-runtime";
1319
+ var CheckIcon = (props) => /* @__PURE__ */ jsxs4("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 100 100", ...props, children: [
1320
+ /* @__PURE__ */ jsx7(
1559
1321
  "circle",
1560
1322
  {
1561
1323
  cx: "50",
@@ -1567,11 +1329,11 @@ var CheckIcon = (props) => /* @__PURE__ */ jsxs6("svg", { xmlns: "http://www.w3.
1567
1329
  strokeWidth: "1.25"
1568
1330
  }
1569
1331
  ),
1570
- /* @__PURE__ */ jsxs6("g", { filter: "url(#success-c)", children: [
1571
- /* @__PURE__ */ jsx10("circle", { cx: "50", cy: "50", r: "35", fill: "#fff" }),
1572
- /* @__PURE__ */ jsx10("circle", { cx: "50", cy: "50", r: "34.432", stroke: "#CCEBCC", strokeWidth: "1.136" })
1332
+ /* @__PURE__ */ jsxs4("g", { filter: "url(#success-c)", children: [
1333
+ /* @__PURE__ */ jsx7("circle", { cx: "50", cy: "50", r: "35", fill: "#fff" }),
1334
+ /* @__PURE__ */ jsx7("circle", { cx: "50", cy: "50", r: "34.432", stroke: "#CCEBCC", strokeWidth: "1.136" })
1573
1335
  ] }),
1574
- /* @__PURE__ */ jsx10(
1336
+ /* @__PURE__ */ jsx7(
1575
1337
  "path",
1576
1338
  {
1577
1339
  stroke: "#090",
@@ -1581,16 +1343,16 @@ var CheckIcon = (props) => /* @__PURE__ */ jsxs6("svg", { xmlns: "http://www.w3.
1581
1343
  d: "m41.25 52.5 4.375 4.375 13.125-13.75"
1582
1344
  }
1583
1345
  ),
1584
- /* @__PURE__ */ jsxs6("defs", { children: [
1585
- /* @__PURE__ */ jsxs6("linearGradient", { id: "success-a", x1: "50", x2: "50", y1: "0", y2: "100", gradientUnits: "userSpaceOnUse", children: [
1586
- /* @__PURE__ */ jsx10("stop", { stopColor: "#99D699" }),
1587
- /* @__PURE__ */ jsx10("stop", { offset: "1", stopColor: "#99D699", stopOpacity: "0" })
1346
+ /* @__PURE__ */ jsxs4("defs", { children: [
1347
+ /* @__PURE__ */ jsxs4("linearGradient", { id: "success-a", x1: "50", x2: "50", y1: "0", y2: "100", gradientUnits: "userSpaceOnUse", children: [
1348
+ /* @__PURE__ */ jsx7("stop", { stopColor: "#99D699" }),
1349
+ /* @__PURE__ */ jsx7("stop", { offset: "1", stopColor: "#99D699", stopOpacity: "0" })
1588
1350
  ] }),
1589
- /* @__PURE__ */ jsxs6("linearGradient", { id: "success-b", x1: "50", x2: "50", y1: "0", y2: "100", gradientUnits: "userSpaceOnUse", children: [
1590
- /* @__PURE__ */ jsx10("stop", { stopColor: "#99D699" }),
1591
- /* @__PURE__ */ jsx10("stop", { offset: ".713", stopColor: "#99D699", stopOpacity: "0" })
1351
+ /* @__PURE__ */ jsxs4("linearGradient", { id: "success-b", x1: "50", x2: "50", y1: "0", y2: "100", gradientUnits: "userSpaceOnUse", children: [
1352
+ /* @__PURE__ */ jsx7("stop", { stopColor: "#99D699" }),
1353
+ /* @__PURE__ */ jsx7("stop", { offset: ".713", stopColor: "#99D699", stopOpacity: "0" })
1592
1354
  ] }),
1593
- /* @__PURE__ */ jsxs6(
1355
+ /* @__PURE__ */ jsxs4(
1594
1356
  "filter",
1595
1357
  {
1596
1358
  id: "success-c",
@@ -1601,13 +1363,13 @@ var CheckIcon = (props) => /* @__PURE__ */ jsxs6("svg", { xmlns: "http://www.w3.
1601
1363
  colorInterpolationFilters: "sRGB",
1602
1364
  filterUnits: "userSpaceOnUse",
1603
1365
  children: [
1604
- /* @__PURE__ */ jsx10("feFlood", { floodOpacity: "0", result: "BackgroundImageFix" }),
1605
- /* @__PURE__ */ jsx10("feColorMatrix", { in: "SourceAlpha", result: "hardAlpha", values: "0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" }),
1606
- /* @__PURE__ */ jsx10("feOffset", { dy: "1.875" }),
1607
- /* @__PURE__ */ jsx10("feGaussianBlur", { stdDeviation: "1.875" }),
1608
- /* @__PURE__ */ jsx10("feColorMatrix", { values: "0 0 0 0 0.8 0 0 0 0 0.921569 0 0 0 0 0.8 0 0 0 0.45 0" }),
1609
- /* @__PURE__ */ jsx10("feBlend", { in2: "BackgroundImageFix", result: "effect1_dropShadow_39_712" }),
1610
- /* @__PURE__ */ jsx10("feBlend", { in: "SourceGraphic", in2: "effect1_dropShadow_39_712", result: "shape" })
1366
+ /* @__PURE__ */ jsx7("feFlood", { floodOpacity: "0", result: "BackgroundImageFix" }),
1367
+ /* @__PURE__ */ jsx7("feColorMatrix", { in: "SourceAlpha", result: "hardAlpha", values: "0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" }),
1368
+ /* @__PURE__ */ jsx7("feOffset", { dy: "1.875" }),
1369
+ /* @__PURE__ */ jsx7("feGaussianBlur", { stdDeviation: "1.875" }),
1370
+ /* @__PURE__ */ jsx7("feColorMatrix", { values: "0 0 0 0 0.8 0 0 0 0 0.921569 0 0 0 0 0.8 0 0 0 0.45 0" }),
1371
+ /* @__PURE__ */ jsx7("feBlend", { in2: "BackgroundImageFix", result: "effect1_dropShadow_39_712" }),
1372
+ /* @__PURE__ */ jsx7("feBlend", { in: "SourceGraphic", in2: "effect1_dropShadow_39_712", result: "shape" })
1611
1373
  ]
1612
1374
  }
1613
1375
  )
@@ -1616,13 +1378,13 @@ var CheckIcon = (props) => /* @__PURE__ */ jsxs6("svg", { xmlns: "http://www.w3.
1616
1378
  var CheckIcon_default = CheckIcon;
1617
1379
 
1618
1380
  // src/components/IDKitWidget/States/SuccessState.tsx
1619
- import { jsx as jsx11, jsxs as jsxs7 } from "react/jsx-runtime";
1381
+ import { jsx as jsx8, jsxs as jsxs5 } from "react/jsx-runtime";
1620
1382
  var SuccessState = () => {
1621
- return /* @__PURE__ */ jsxs7("div", { className: "space-y-6", children: [
1622
- /* @__PURE__ */ jsx11("div", { className: "-mt-5 flex items-center justify-center", children: /* @__PURE__ */ jsx11(CheckIcon_default, { className: "w-24 text-white" }) }),
1623
- /* @__PURE__ */ jsxs7("div", { children: [
1624
- /* @__PURE__ */ jsx11("p", { className: "text-center text-2xl font-semibold text-gray-900 dark:text-white", children: __("Successfully verified") }),
1625
- /* @__PURE__ */ jsx11("p", { className: "mx-auto mt-2 max-w-[224px] text-center text-lg text-657080", children: __("Your World ID verification was successful") })
1383
+ return /* @__PURE__ */ jsxs5("div", { className: "space-y-6", children: [
1384
+ /* @__PURE__ */ jsx8("div", { className: "-mt-5 flex items-center justify-center", children: /* @__PURE__ */ jsx8(CheckIcon_default, { className: "w-24 text-white" }) }),
1385
+ /* @__PURE__ */ jsxs5("div", { children: [
1386
+ /* @__PURE__ */ jsx8("p", { className: "text-center text-2xl font-semibold text-gray-900 dark:text-white", children: __("Successfully verified") }),
1387
+ /* @__PURE__ */ jsx8("p", { className: "mx-auto mt-2 max-w-[224px] text-center text-lg text-657080", children: __("Your World ID verification was successful") })
1626
1388
  ] })
1627
1389
  ] });
1628
1390
  };
@@ -1630,12 +1392,19 @@ var SuccessState_default = SuccessState;
1630
1392
 
1631
1393
  // src/components/IDKitWidget/States/WorldID/QRState.tsx
1632
1394
  import copy from "copy-to-clipboard";
1395
+
1396
+ // src/lib/utils.ts
1397
+ var classNames = (...classes) => {
1398
+ return classes.filter(Boolean).join(" ");
1399
+ };
1400
+
1401
+ // src/components/IDKitWidget/States/WorldID/QRState.tsx
1633
1402
  import { useCallback, useState as useState2 } from "react";
1634
1403
  import { AnimatePresence, motion } from "framer-motion";
1635
1404
 
1636
1405
  // src/components/Icons/WorldcoinIcon.tsx
1637
- import { jsx as jsx12 } from "react/jsx-runtime";
1638
- var WorldcoinIcon = (props) => /* @__PURE__ */ jsx12("svg", { ...props, xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 33 32", children: /* @__PURE__ */ jsx12(
1406
+ import { jsx as jsx9 } from "react/jsx-runtime";
1407
+ var WorldcoinIcon = (props) => /* @__PURE__ */ jsx9("svg", { ...props, xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 33 32", children: /* @__PURE__ */ jsx9(
1639
1408
  "path",
1640
1409
  {
1641
1410
  fill: "currentColor",
@@ -1645,9 +1414,9 @@ var WorldcoinIcon = (props) => /* @__PURE__ */ jsx12("svg", { ...props, xmlns: "
1645
1414
  var WorldcoinIcon_default = WorldcoinIcon;
1646
1415
 
1647
1416
  // src/components/Icons/QRPlaceholderIcon.tsx
1648
- import { jsx as jsx13, jsxs as jsxs8 } from "react/jsx-runtime";
1649
- var QRPlaceholderIcon = (props) => /* @__PURE__ */ jsxs8("svg", { ...props, xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 200 200", children: [
1650
- /* @__PURE__ */ jsx13(
1417
+ import { jsx as jsx10, jsxs as jsxs6 } from "react/jsx-runtime";
1418
+ var QRPlaceholderIcon = (props) => /* @__PURE__ */ jsxs6("svg", { ...props, xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 200 200", children: [
1419
+ /* @__PURE__ */ jsx10(
1651
1420
  "path",
1652
1421
  {
1653
1422
  fill: "#EBECEF",
@@ -1656,14 +1425,14 @@ var QRPlaceholderIcon = (props) => /* @__PURE__ */ jsxs8("svg", { ...props, xmln
1656
1425
  clipRule: "evenodd"
1657
1426
  }
1658
1427
  ),
1659
- /* @__PURE__ */ jsx13(
1428
+ /* @__PURE__ */ jsx10(
1660
1429
  "path",
1661
1430
  {
1662
1431
  fill: "#EBECEF",
1663
1432
  d: "M197.026 200c.789 0 1.545-.309 2.103-.86.558-.55.871-1.297.871-2.076v-17.616c0-.778-.313-1.525-.871-2.076a2.996 2.996 0 0 0-2.103-.86h-5.948c-.789 0-1.545.31-2.103.86a2.918 2.918 0 0 0-.871 2.076v8.808h-11.897v-11.744h-11.896v-23.487h11.896v8.808c0 .778.314 1.525.872 2.076.557.55 1.314.86 2.102.86h5.949c.788 0 1.545-.31 2.103-.86a2.922 2.922 0 0 0 .871-2.076v-8.808h8.922c.789 0 1.545-.309 2.103-.86a2.916 2.916 0 0 0 .871-2.076v-5.872c0-.779-.313-1.525-.871-2.076a2.992 2.992 0 0 0-2.103-.86h-29.741c-.789 0-1.545.309-2.103.86a2.916 2.916 0 0 0-.871 2.076v8.808h-23.792v-11.744h8.922c.789 0 1.545-.309 2.103-.86.558-.55.871-1.297.871-2.076v-5.872c0-.778-.313-1.525-.871-2.076a2.996 2.996 0 0 0-2.103-.86h-5.948c-.789 0-1.546.31-2.103.86a2.918 2.918 0 0 0-.871 2.076v8.808H119.7c-.789 0-1.545.309-2.103.86a2.916 2.916 0 0 0-.871 2.076v5.872c0 .779.313 1.525.871 2.076.558.551 1.314.86 2.103.86h20.819v8.808c0 .778.313 1.525.871 2.076.557.55 1.314.86 2.103.86h8.922v8.808c0 .778.313 1.525.871 2.076.558.55 1.314.859 2.103.859h8.922v11.744h-20.818c-.789 0-1.546.31-2.103.86a2.916 2.916 0 0 0-.871 2.076v5.872c0 .779.313 1.526.871 2.076a2.99 2.99 0 0 0 2.103.86h17.844c.789 0 1.545-.309 2.103-.86.558-.55.871-1.297.871-2.076v-8.808h11.896v8.808c0 .779.314 1.526.872 2.076a2.99 2.99 0 0 0 2.102.86h17.845Z"
1664
1433
  }
1665
1434
  ),
1666
- /* @__PURE__ */ jsx13(
1435
+ /* @__PURE__ */ jsx10(
1667
1436
  "path",
1668
1437
  {
1669
1438
  fill: "#EBECEF",
@@ -1672,14 +1441,14 @@ var QRPlaceholderIcon = (props) => /* @__PURE__ */ jsxs8("svg", { ...props, xmln
1672
1441
  clipRule: "evenodd"
1673
1442
  }
1674
1443
  ),
1675
- /* @__PURE__ */ jsx13(
1444
+ /* @__PURE__ */ jsx10(
1676
1445
  "path",
1677
1446
  {
1678
1447
  fill: "#EBECEF",
1679
1448
  d: "M6.05 89.68A6.05 6.05 0 0 0 0 95.73v9.252a6.05 6.05 0 0 0 6.05 6.05h9.253a6.05 6.05 0 0 0 6.05-6.05V95.73c0-.678-.112-1.33-.318-1.94.445.105.908.16 1.385.16h27.758a6.05 6.05 0 0 0 6.05-6.05v-9.252a6.05 6.05 0 0 0-6.05-6.05H22.42a6.05 6.05 0 0 0-6.05 6.05V87.9c0 .678.112 1.33.317 1.939a6.065 6.065 0 0 0-1.385-.16H6.05Zm102.135-40.926a6.05 6.05 0 0 1 6.05-6.05h9.253a6.05 6.05 0 0 1 6.049 6.05v9.253a6.05 6.05 0 0 1-6.049 6.05h-9.253a6.05 6.05 0 0 1-6.05-6.05v-9.253ZM67.616 184.698a6.05 6.05 0 0 1 6.05-6.05h9.252c.678 0 1.33.111 1.939.317a6.064 6.064 0 0 1-.16-1.385v-9.253a6.05 6.05 0 0 1 6.05-6.049H100a6.05 6.05 0 0 1 6.05 6.049v9.253a6.05 6.05 0 0 1-6.05 6.05h-9.253c-.678 0-1.33-.112-1.938-.317.104.444.159.908.159 1.385v9.252a6.05 6.05 0 0 1-6.05 6.05h-9.253a6.05 6.05 0 0 1-6.05-6.05v-9.252Zm78.291-120.285a6.05 6.05 0 0 1 6.05-6.05h41.993a6.05 6.05 0 0 1 6.05 6.05v9.252a6.05 6.05 0 0 1-6.05 6.05h-41.993a6.05 6.05 0 0 1-6.05-6.05v-9.252ZM95.018 0a6.05 6.05 0 0 0-6.05 6.05v17.082a6.05 6.05 0 0 0 6.05 6.05h9.252a6.05 6.05 0 0 0 6.05-6.05V6.05A6.05 6.05 0 0 0 104.27 0h-9.252Z"
1680
1449
  }
1681
1450
  ),
1682
- /* @__PURE__ */ jsx13(
1451
+ /* @__PURE__ */ jsx10(
1683
1452
  "path",
1684
1453
  {
1685
1454
  fill: "url(#a)",
@@ -1688,14 +1457,14 @@ var QRPlaceholderIcon = (props) => /* @__PURE__ */ jsxs8("svg", { ...props, xmln
1688
1457
  clipRule: "evenodd"
1689
1458
  }
1690
1459
  ),
1691
- /* @__PURE__ */ jsx13(
1460
+ /* @__PURE__ */ jsx10(
1692
1461
  "path",
1693
1462
  {
1694
1463
  fill: "url(#a)",
1695
1464
  d: "M197.026 200c.789 0 1.545-.309 2.103-.86.558-.55.871-1.297.871-2.076v-17.616c0-.778-.313-1.525-.871-2.076a2.996 2.996 0 0 0-2.103-.86h-5.948c-.789 0-1.545.31-2.103.86a2.918 2.918 0 0 0-.871 2.076v8.808h-11.897v-11.744h-11.896v-23.487h11.896v8.808c0 .778.314 1.525.872 2.076.557.55 1.314.86 2.102.86h5.949c.788 0 1.545-.31 2.103-.86a2.922 2.922 0 0 0 .871-2.076v-8.808h8.922c.789 0 1.545-.309 2.103-.86a2.916 2.916 0 0 0 .871-2.076v-5.872c0-.779-.313-1.525-.871-2.076a2.992 2.992 0 0 0-2.103-.86h-29.741c-.789 0-1.545.309-2.103.86a2.916 2.916 0 0 0-.871 2.076v8.808h-23.792v-11.744h8.922c.789 0 1.545-.309 2.103-.86.558-.55.871-1.297.871-2.076v-5.872c0-.778-.313-1.525-.871-2.076a2.996 2.996 0 0 0-2.103-.86h-5.948c-.789 0-1.546.31-2.103.86a2.918 2.918 0 0 0-.871 2.076v8.808H119.7c-.789 0-1.545.309-2.103.86a2.916 2.916 0 0 0-.871 2.076v5.872c0 .779.313 1.525.871 2.076.558.551 1.314.86 2.103.86h20.819v8.808c0 .778.313 1.525.871 2.076.557.55 1.314.86 2.103.86h8.922v8.808c0 .778.313 1.525.871 2.076.558.55 1.314.859 2.103.859h8.922v11.744h-20.818c-.789 0-1.546.31-2.103.86a2.916 2.916 0 0 0-.871 2.076v5.872c0 .779.313 1.526.871 2.076a2.99 2.99 0 0 0 2.103.86h17.844c.789 0 1.545-.309 2.103-.86.558-.55.871-1.297.871-2.076v-8.808h11.896v8.808c0 .779.314 1.526.872 2.076a2.99 2.99 0 0 0 2.102.86h17.845Z"
1696
1465
  }
1697
1466
  ),
1698
- /* @__PURE__ */ jsx13(
1467
+ /* @__PURE__ */ jsx10(
1699
1468
  "path",
1700
1469
  {
1701
1470
  fill: "url(#a)",
@@ -1704,7 +1473,7 @@ var QRPlaceholderIcon = (props) => /* @__PURE__ */ jsxs8("svg", { ...props, xmln
1704
1473
  clipRule: "evenodd"
1705
1474
  }
1706
1475
  ),
1707
- /* @__PURE__ */ jsx13(
1476
+ /* @__PURE__ */ jsx10(
1708
1477
  "path",
1709
1478
  {
1710
1479
  fill: "url(#a)",
@@ -1713,51 +1482,51 @@ var QRPlaceholderIcon = (props) => /* @__PURE__ */ jsxs8("svg", { ...props, xmln
1713
1482
  clipRule: "evenodd"
1714
1483
  }
1715
1484
  ),
1716
- /* @__PURE__ */ jsx13(
1485
+ /* @__PURE__ */ jsx10(
1717
1486
  "path",
1718
1487
  {
1719
1488
  fill: "url(#a)",
1720
1489
  d: "M6.05 89.68A6.05 6.05 0 0 0 0 95.73v9.252a6.05 6.05 0 0 0 6.05 6.05h9.253a6.05 6.05 0 0 0 6.05-6.05V95.73c0-.678-.112-1.33-.318-1.94.445.105.908.16 1.385.16h27.758a6.05 6.05 0 0 0 6.05-6.05v-9.252a6.05 6.05 0 0 0-6.05-6.05H22.42a6.05 6.05 0 0 0-6.05 6.05V87.9c0 .678.112 1.33.317 1.939a6.065 6.065 0 0 0-1.385-.16H6.05Z"
1721
1490
  }
1722
1491
  ),
1723
- /* @__PURE__ */ jsx13(
1492
+ /* @__PURE__ */ jsx10(
1724
1493
  "path",
1725
1494
  {
1726
1495
  fill: "url(#a)",
1727
1496
  d: "M108.185 48.754a6.05 6.05 0 0 1 6.05-6.05h9.253a6.05 6.05 0 0 1 6.049 6.05v9.253a6.05 6.05 0 0 1-6.049 6.05h-9.253a6.05 6.05 0 0 1-6.05-6.05v-9.253Z"
1728
1497
  }
1729
1498
  ),
1730
- /* @__PURE__ */ jsx13(
1499
+ /* @__PURE__ */ jsx10(
1731
1500
  "path",
1732
1501
  {
1733
1502
  fill: "url(#a)",
1734
1503
  d: "M67.616 184.698a6.05 6.05 0 0 1 6.05-6.05h9.252c.678 0 1.33.111 1.939.317a6.064 6.064 0 0 1-.16-1.385v-9.253a6.05 6.05 0 0 1 6.05-6.049H100a6.05 6.05 0 0 1 6.05 6.049v9.253a6.05 6.05 0 0 1-6.05 6.05h-9.253c-.678 0-1.33-.112-1.938-.317.104.444.159.908.159 1.385v9.252a6.05 6.05 0 0 1-6.05 6.05h-9.253a6.05 6.05 0 0 1-6.05-6.05v-9.252Z"
1735
1504
  }
1736
1505
  ),
1737
- /* @__PURE__ */ jsx13(
1506
+ /* @__PURE__ */ jsx10(
1738
1507
  "path",
1739
1508
  {
1740
1509
  fill: "url(#a)",
1741
1510
  d: "M145.907 64.413a6.05 6.05 0 0 1 6.05-6.05h41.993a6.05 6.05 0 0 1 6.05 6.05v9.252a6.05 6.05 0 0 1-6.05 6.05h-41.993a6.05 6.05 0 0 1-6.05-6.05v-9.252Z"
1742
1511
  }
1743
1512
  ),
1744
- /* @__PURE__ */ jsx13(
1513
+ /* @__PURE__ */ jsx10(
1745
1514
  "path",
1746
1515
  {
1747
1516
  fill: "url(#a)",
1748
1517
  d: "M95.018 0a6.05 6.05 0 0 0-6.05 6.05v17.082a6.05 6.05 0 0 0 6.05 6.05h9.252a6.05 6.05 0 0 0 6.05-6.05V6.05A6.05 6.05 0 0 0 104.27 0h-9.252Z"
1749
1518
  }
1750
1519
  ),
1751
- /* @__PURE__ */ jsx13("defs", { children: /* @__PURE__ */ jsxs8("linearGradient", { id: "a", x1: "0", x2: "200", y1: "0", y2: "200", gradientUnits: "userSpaceOnUse", children: [
1752
- /* @__PURE__ */ jsx13("stop", { offset: ".37", stopColor: "#fff", stopOpacity: "0" }),
1753
- /* @__PURE__ */ jsx13("stop", { offset: ".5", stopColor: "#fff", stopOpacity: ".85" }),
1754
- /* @__PURE__ */ jsx13("stop", { offset: ".63", stopColor: "#fff", stopOpacity: "0" })
1520
+ /* @__PURE__ */ jsx10("defs", { children: /* @__PURE__ */ jsxs6("linearGradient", { id: "a", x1: "0", x2: "200", y1: "0", y2: "200", gradientUnits: "userSpaceOnUse", children: [
1521
+ /* @__PURE__ */ jsx10("stop", { offset: ".37", stopColor: "#fff", stopOpacity: "0" }),
1522
+ /* @__PURE__ */ jsx10("stop", { offset: ".5", stopColor: "#fff", stopOpacity: ".85" }),
1523
+ /* @__PURE__ */ jsx10("stop", { offset: ".63", stopColor: "#fff", stopOpacity: "0" })
1755
1524
  ] }) })
1756
1525
  ] });
1757
1526
  var QRPlaceholderIcon_default = QRPlaceholderIcon;
1758
1527
 
1759
1528
  // src/components/IDKitWidget/States/WorldID/QRState.tsx
1760
- import { Fragment as Fragment2, jsx as jsx14, jsxs as jsxs9 } from "react/jsx-runtime";
1529
+ import { Fragment, jsx as jsx11, jsxs as jsxs7 } from "react/jsx-runtime";
1761
1530
  var QRState = ({ qrData, showQR, setShowQR }) => {
1762
1531
  const media = useMedia_default();
1763
1532
  const [copiedLink, setCopiedLink] = useState2(false);
@@ -1766,9 +1535,9 @@ var QRState = ({ qrData, showQR, setShowQR }) => {
1766
1535
  setCopiedLink(true);
1767
1536
  setTimeout(() => setCopiedLink(false), 2e3);
1768
1537
  }, [qrData]);
1769
- return /* @__PURE__ */ jsxs9(Fragment2, { children: [
1770
- /* @__PURE__ */ jsxs9("div", { className: "mb-10 space-y-4 md:hidden", children: [
1771
- /* @__PURE__ */ jsxs9(
1538
+ return /* @__PURE__ */ jsxs7(Fragment, { children: [
1539
+ /* @__PURE__ */ jsxs7("div", { className: "mb-10 space-y-4 md:hidden", children: [
1540
+ /* @__PURE__ */ jsxs7(
1772
1541
  motion.a,
1773
1542
  {
1774
1543
  href: qrData ?? "",
@@ -1781,8 +1550,8 @@ var QRState = ({ qrData, showQR, setShowQR }) => {
1781
1550
  "bg-0d151d dark:bg-white text-white dark:text-0d151d"
1782
1551
  ),
1783
1552
  children: [
1784
- /* @__PURE__ */ jsx14(WorldcoinIcon_default, { className: "h-5 w-5" }),
1785
- /* @__PURE__ */ jsx14(
1553
+ /* @__PURE__ */ jsx11(WorldcoinIcon_default, { className: "h-5 w-5" }),
1554
+ /* @__PURE__ */ jsx11(
1786
1555
  motion.span,
1787
1556
  {
1788
1557
  className: "flex-1 text-center",
@@ -1794,13 +1563,13 @@ var QRState = ({ qrData, showQR, setShowQR }) => {
1794
1563
  ]
1795
1564
  }
1796
1565
  ),
1797
- /* @__PURE__ */ jsxs9("div", { className: "space-y-4", children: [
1798
- /* @__PURE__ */ jsxs9("div", { className: "flex items-center space-x-4 ", children: [
1799
- /* @__PURE__ */ jsx14("hr", { className: "flex-1" }),
1800
- /* @__PURE__ */ jsx14("span", { className: "text-xs font-medium text-9ba3ae", children: "or" }),
1801
- /* @__PURE__ */ jsx14("hr", { className: "flex-1" })
1566
+ /* @__PURE__ */ jsxs7("div", { className: "space-y-4", children: [
1567
+ /* @__PURE__ */ jsxs7("div", { className: "flex items-center space-x-4 ", children: [
1568
+ /* @__PURE__ */ jsx11("hr", { className: "flex-1" }),
1569
+ /* @__PURE__ */ jsx11("span", { className: "text-xs font-medium text-9ba3ae", children: "or" }),
1570
+ /* @__PURE__ */ jsx11("hr", { className: "flex-1" })
1802
1571
  ] }),
1803
- /* @__PURE__ */ jsx14(
1572
+ /* @__PURE__ */ jsx11(
1804
1573
  motion.button,
1805
1574
  {
1806
1575
  className: "w-full rounded-2xl border border-ebecef p-4 text-lg font-medium text-3c424b",
@@ -1810,8 +1579,8 @@ var QRState = ({ qrData, showQR, setShowQR }) => {
1810
1579
  )
1811
1580
  ] })
1812
1581
  ] }),
1813
- (media == "desktop" || showQR) && /* @__PURE__ */ jsxs9(Fragment2, { children: [
1814
- /* @__PURE__ */ jsx14(AnimatePresence, { children: copiedLink && /* @__PURE__ */ jsx14(
1582
+ (media == "desktop" || showQR) && /* @__PURE__ */ jsxs7(Fragment, { children: [
1583
+ /* @__PURE__ */ jsx11(AnimatePresence, { children: copiedLink && /* @__PURE__ */ jsx11(
1815
1584
  motion.div,
1816
1585
  {
1817
1586
  className: "text-sm text-9eafc0",
@@ -1844,14 +1613,14 @@ var QRState = ({ qrData, showQR, setShowQR }) => {
1844
1613
  }
1845
1614
  }
1846
1615
  },
1847
- children: /* @__PURE__ */ jsx14("span", { className: "rounded-lg border border-f1f5f8 px-2 py-1 text-sm", children: __("QR Code copied") })
1616
+ children: /* @__PURE__ */ jsx11("span", { className: "rounded-lg border border-f1f5f8 px-2 py-1 text-sm", children: __("QR Code copied") })
1848
1617
  },
1849
1618
  "copied"
1850
1619
  ) }),
1851
- /* @__PURE__ */ jsx14("div", { className: "relative inline-flex items-center justify-center rounded-2xl border border-f1f5f8 p-2 dark:border-f1f5f8/10", children: /* @__PURE__ */ jsx14("div", { className: "text-29343f dark:text-white", children: qrData ? (
1620
+ /* @__PURE__ */ jsx11("div", { className: "relative inline-flex items-center justify-center rounded-2xl border border-f1f5f8 p-2 dark:border-f1f5f8/10", children: /* @__PURE__ */ jsx11("div", { className: "text-29343f dark:text-white", children: qrData ? (
1852
1621
  // eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions
1853
- /* @__PURE__ */ jsx14("div", { onClick: copyLink, className: "cursor-pointer", children: /* @__PURE__ */ jsx14(QRCode_default, { data: qrData, size: 244 }) })
1854
- ) : /* @__PURE__ */ jsx14("div", { className: "flex h-[244px] w-[244px] items-center justify-center", children: /* @__PURE__ */ jsx14(QRPlaceholderIcon_default, { className: "h-[244px] w-[244px] animate-pulse" }) }) }) })
1622
+ /* @__PURE__ */ jsx11("div", { onClick: copyLink, className: "cursor-pointer", children: /* @__PURE__ */ jsx11(QRCode_default, { data: qrData, size: 244 }) })
1623
+ ) : /* @__PURE__ */ jsx11("div", { className: "flex h-[244px] w-[244px] items-center justify-center", children: /* @__PURE__ */ jsx11(QRPlaceholderIcon_default, { className: "h-[244px] w-[244px] animate-pulse" }) }) }) })
1855
1624
  ] })
1856
1625
  ] });
1857
1626
  };
@@ -1889,8 +1658,8 @@ var useWorldBridge = (app_id, action, signal, bridge_url, verification_level, ac
1889
1658
  };
1890
1659
 
1891
1660
  // src/components/Icons/LoadingIcon.tsx
1892
- import { jsx as jsx15, jsxs as jsxs10 } from "react/jsx-runtime";
1893
- var LoadingIcon = ({ className, ...props }) => /* @__PURE__ */ jsxs10(
1661
+ import { jsx as jsx12, jsxs as jsxs8 } from "react/jsx-runtime";
1662
+ var LoadingIcon = ({ className, ...props }) => /* @__PURE__ */ jsxs8(
1894
1663
  "svg",
1895
1664
  {
1896
1665
  xmlns: "http://www.w3.org/2000/svg",
@@ -1899,8 +1668,8 @@ var LoadingIcon = ({ className, ...props }) => /* @__PURE__ */ jsxs10(
1899
1668
  className: `animate-spin motion-reduce:animate-[spin_1.5s_linear_infinite] ${className}`,
1900
1669
  ...props,
1901
1670
  children: [
1902
- /* @__PURE__ */ jsx15("circle", { cx: "12", cy: "12", r: "10.75", stroke: "#191C20", strokeOpacity: ".16", strokeWidth: "2.5" }),
1903
- /* @__PURE__ */ jsx15(
1671
+ /* @__PURE__ */ jsx12("circle", { cx: "12", cy: "12", r: "10.75", stroke: "#191C20", strokeOpacity: ".16", strokeWidth: "2.5" }),
1672
+ /* @__PURE__ */ jsx12(
1904
1673
  "path",
1905
1674
  {
1906
1675
  fill: "#191C20",
@@ -1914,7 +1683,7 @@ var LoadingIcon_default = LoadingIcon;
1914
1683
 
1915
1684
  // src/components/IDKitWidget/States/WorldIDState.tsx
1916
1685
  import { AppErrorCodes as AppErrorCodes2, VerificationState, VerificationLevel } from "@worldcoin/idkit-core";
1917
- import { jsx as jsx16, jsxs as jsxs11 } from "react/jsx-runtime";
1686
+ import { jsx as jsx13, jsxs as jsxs9 } from "react/jsx-runtime";
1918
1687
  var getOptions = (store) => ({
1919
1688
  signal: store.signal,
1920
1689
  app_id: store.app_id,
@@ -1965,25 +1734,25 @@ var WorldIDState = () => {
1965
1734
  return handleVerify(result);
1966
1735
  }
1967
1736
  }, [result, handleVerify, verificationState, setStage, errorCode, setErrorState, verification_level]);
1968
- return /* @__PURE__ */ jsxs11("div", { className: "-mt-6 space-y-10", children: [
1969
- /* @__PURE__ */ jsxs11("div", { children: [
1970
- /* @__PURE__ */ jsx16("div", { className: "mb-4 flex items-center justify-center", children: /* @__PURE__ */ jsx16(WorldcoinIcon_default, { className: "h-10 text-0d151d dark:text-white" }) }),
1971
- /* @__PURE__ */ jsx16("p", { className: "text-center font-sora text-2xl font-semibold text-gray-900 dark:text-white", children: __("Verify with World ID") }),
1972
- /* @__PURE__ */ jsx16("p", { className: "mt-3 text-center text-657080 dark:text-9eafc0 md:mt-2", children: "Please use your World App to scan the QR code" })
1737
+ return /* @__PURE__ */ jsxs9("div", { className: "-mt-6 space-y-10", children: [
1738
+ /* @__PURE__ */ jsxs9("div", { children: [
1739
+ /* @__PURE__ */ jsx13("div", { className: "mb-4 flex items-center justify-center", children: /* @__PURE__ */ jsx13(WorldcoinIcon_default, { className: "h-10 text-0d151d dark:text-white" }) }),
1740
+ /* @__PURE__ */ jsx13("p", { className: "text-center font-sora text-2xl font-semibold text-gray-900 dark:text-white", children: __("Verify with World ID") }),
1741
+ /* @__PURE__ */ jsx13("p", { className: "mt-3 text-center text-657080 dark:text-9eafc0 md:mt-2", children: "Please use your World App to scan the QR code" })
1973
1742
  ] }),
1974
- /* @__PURE__ */ jsxs11("div", { className: "relative", children: [
1975
- verificationState == VerificationState.WaitingForApp && /* @__PURE__ */ jsxs11("div", { className: "absolute inset-0 flex flex-col items-center justify-center space-y-6", children: [
1976
- /* @__PURE__ */ jsx16(LoadingIcon_default, { className: "h-6 w-6" }),
1977
- /* @__PURE__ */ jsxs11("div", { children: [
1978
- /* @__PURE__ */ jsx16("p", { className: "font-bold text-657080", children: "Verifying" }),
1979
- /* @__PURE__ */ jsx16("p", { className: "text-sm text-657080", children: "Please continue in app" })
1743
+ /* @__PURE__ */ jsxs9("div", { className: "relative", children: [
1744
+ verificationState == VerificationState.WaitingForApp && /* @__PURE__ */ jsxs9("div", { className: "absolute inset-0 flex flex-col items-center justify-center space-y-6", children: [
1745
+ /* @__PURE__ */ jsx13(LoadingIcon_default, { className: "h-6 w-6" }),
1746
+ /* @__PURE__ */ jsxs9("div", { children: [
1747
+ /* @__PURE__ */ jsx13("p", { className: "font-bold text-657080", children: "Verifying" }),
1748
+ /* @__PURE__ */ jsx13("p", { className: "text-sm text-657080", children: "Please continue in app" })
1980
1749
  ] })
1981
1750
  ] }),
1982
- /* @__PURE__ */ jsx16(
1751
+ /* @__PURE__ */ jsx13(
1983
1752
  "div",
1984
1753
  {
1985
1754
  className: verificationState === VerificationState.WaitingForApp ? "opacity-40 blur-lg transition duration-500 ease-in-out" : "transition duration-500 ease-in-out",
1986
- children: /* @__PURE__ */ jsx16(QRState_default, { showQR, setShowQR, qrData: connectorURI })
1755
+ children: /* @__PURE__ */ jsx13(QRState_default, { showQR, setShowQR, qrData: connectorURI })
1987
1756
  }
1988
1757
  )
1989
1758
  ] })
@@ -1993,51 +1762,37 @@ var WorldIDState_default = WorldIDState;
1993
1762
 
1994
1763
  // src/components/IDKitWidget/BaseWidget.tsx
1995
1764
  import * as Dialog from "@radix-ui/react-dialog";
1996
- import { Fragment as Fragment3, useEffect as useEffect5, useMemo } from "react";
1765
+ import { Fragment as Fragment2, useEffect as useEffect5, useMemo } from "react";
1997
1766
  import { AnimatePresence as AnimatePresence2, motion as motion2 } from "framer-motion";
1998
1767
 
1999
- // src/components/Icons/ArrowLongLeftIcon.tsx
2000
- import { jsx as jsx17 } from "react/jsx-runtime";
2001
- var ArrowLongLeftIcon = (props) => /* @__PURE__ */ jsx17(
2002
- "svg",
2003
- {
2004
- ...props,
2005
- fill: "none",
2006
- strokeWidth: 1.5,
2007
- viewBox: "0 0 24 24",
2008
- stroke: "currentColor",
2009
- xmlns: "http://www.w3.org/2000/svg",
2010
- children: /* @__PURE__ */ jsx17("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M6.75 15.75L3 12m0 0l3.75-3.75M3 12h18" })
2011
- }
2012
- );
2013
- var ArrowLongLeftIcon_default = ArrowLongLeftIcon;
2014
-
2015
1768
  // src/components/IDKitWidget/States/HostAppVerificationState.tsx
2016
1769
  import { memo } from "react";
2017
- import { jsx as jsx18, jsxs as jsxs12 } from "react/jsx-runtime";
1770
+ import { jsx as jsx14, jsxs as jsxs10 } from "react/jsx-runtime";
2018
1771
  var HostAppVerificationState = () => {
2019
- return /* @__PURE__ */ jsxs12("div", { className: "space-y-6", children: [
2020
- /* @__PURE__ */ jsx18("div", { className: "flex justify-center", children: /* @__PURE__ */ jsx18(LoadingIcon_default, { className: "h-24 w-24" }) }),
2021
- /* @__PURE__ */ jsx18("div", { className: "text-70868f mt-4", children: __("Transmitting verification to host app. Please wait...") })
1772
+ return /* @__PURE__ */ jsxs10("div", { className: "space-y-6", children: [
1773
+ /* @__PURE__ */ jsx14("div", { className: "flex justify-center", children: /* @__PURE__ */ jsx14(LoadingIcon_default, { className: "h-24 w-24" }) }),
1774
+ /* @__PURE__ */ jsx14("div", { className: "mt-4 text-70868f", children: __("Transmitting verification to host app. Please wait...") })
2022
1775
  ] });
2023
1776
  };
2024
1777
  var HostAppVerificationState_default = memo(HostAppVerificationState);
2025
1778
 
2026
1779
  // src/components/IDKitWidget/BaseWidget.tsx
2027
- import { jsx as jsx19, jsxs as jsxs13 } from "react/jsx-runtime";
2028
- var getParams2 = ({ open, processing, onOpenChange, stage, setStage, computed, setOptions }) => ({
1780
+ import { jsx as jsx15, jsxs as jsxs11 } from "react/jsx-runtime";
1781
+ var getParams2 = ({ open, processing, onOpenChange, stage, setStage, setOptions }) => ({
2029
1782
  stage,
2030
1783
  setStage,
2031
1784
  processing,
2032
1785
  setOptions,
2033
1786
  isOpen: open,
2034
- onOpenChange,
2035
- canGoBack: computed.canGoBack(stage)
1787
+ onOpenChange
2036
1788
  });
2037
1789
  var IDKitWidget = ({ children, ...config }) => {
2038
1790
  const media = useMedia_default();
2039
- const { isOpen, onOpenChange, stage, setStage, canGoBack, setOptions } = idkit_default(getParams2, shallow2);
1791
+ const { isOpen, onOpenChange, stage, setOptions } = idkit_default(getParams2, shallow2);
2040
1792
  useEffect5(() => {
1793
+ if (config.action === "") {
1794
+ throw new Error(__("Action cannot be an empty string."));
1795
+ }
2041
1796
  setOptions(config, "props" /* PROPS */);
2042
1797
  }, [config, setOptions]);
2043
1798
  const StageContent = useMemo(() => {
@@ -2048,20 +1803,18 @@ var IDKitWidget = ({ children, ...config }) => {
2048
1803
  return SuccessState_default;
2049
1804
  case "ERROR" /* ERROR */:
2050
1805
  return ErrorState_default;
2051
- case "PRIVACY" /* PRIVACY */:
2052
- return PrivacyState_default;
2053
1806
  case "HOST_APP_VERIFICATION" /* HOST_APP_VERIFICATION */:
2054
1807
  return HostAppVerificationState_default;
2055
1808
  default:
2056
1809
  throw new Error(__("Invalid IDKitStage :stage.", { stage }));
2057
1810
  }
2058
1811
  }, [stage]);
2059
- return /* @__PURE__ */ jsxs13(Dialog.Root, { open: isOpen, onOpenChange, children: [
1812
+ return /* @__PURE__ */ jsxs11(Dialog.Root, { open: isOpen, onOpenChange, children: [
2060
1813
  children?.({ open: () => onOpenChange(true) }),
2061
- /* @__PURE__ */ jsx19(Dialog.Portal, { forceMount: true, children: /* @__PURE__ */ jsx19(Fragment3, { children: /* @__PURE__ */ jsx19(AnimatePresence2, { children: isOpen && /* @__PURE__ */ jsxs13(root.div, { mode: "open", id: "idkit-widget", children: [
2062
- /* @__PURE__ */ jsx19(Styles_default, {}),
2063
- /* @__PURE__ */ jsxs13("div", { id: "modal", className: "fixed z-10 font-sans", children: [
2064
- /* @__PURE__ */ jsx19(Dialog.Overlay, { asChild: true, children: /* @__PURE__ */ jsx19(
1814
+ /* @__PURE__ */ jsx15(Dialog.Portal, { forceMount: true, children: /* @__PURE__ */ jsx15(Fragment2, { children: /* @__PURE__ */ jsx15(AnimatePresence2, { children: isOpen && /* @__PURE__ */ jsxs11(root.div, { mode: "open", id: "idkit-widget", children: [
1815
+ /* @__PURE__ */ jsx15(Styles_default, {}),
1816
+ /* @__PURE__ */ jsxs11("div", { id: "modal", className: "fixed z-10 font-sans", children: [
1817
+ /* @__PURE__ */ jsx15(Dialog.Overlay, { asChild: true, children: /* @__PURE__ */ jsx15(
2065
1818
  motion2.div,
2066
1819
  {
2067
1820
  initial: { opacity: 0 },
@@ -2070,7 +1823,7 @@ var IDKitWidget = ({ children, ...config }) => {
2070
1823
  className: "fixed inset-0 bg-black/50 backdrop-blur-lg"
2071
1824
  }
2072
1825
  ) }),
2073
- /* @__PURE__ */ jsx19("div", { className: "fixed inset-0 z-10 overflow-y-hidden md:overflow-y-auto", children: /* @__PURE__ */ jsx19("div", { className: "flex min-h-full items-end justify-center text-center md:items-center md:p-4", children: /* @__PURE__ */ jsx19(Dialog.Content, { asChild: true, children: /* @__PURE__ */ jsx19(
1826
+ /* @__PURE__ */ jsx15("div", { className: "fixed inset-0 z-10 overflow-y-hidden md:overflow-y-auto", children: /* @__PURE__ */ jsx15("div", { className: "flex min-h-full items-end justify-center text-center md:items-center md:p-4", children: /* @__PURE__ */ jsx15(Dialog.Content, { asChild: true, children: /* @__PURE__ */ jsx15(
2074
1827
  motion2.div,
2075
1828
  {
2076
1829
  layout: media == "mobile" ? "position" : true,
@@ -2085,26 +1838,12 @@ var IDKitWidget = ({ children, ...config }) => {
2085
1838
  },
2086
1839
  transition: { layout: { duration: 0.15 } },
2087
1840
  className: "relative z-50 flex min-h-screen w-full flex-col bg-white pt-6 shadow focus:outline-none focus-visible:ring focus-visible:ring-purple-500/75 dark:bg-0d151d md:min-h-[35rem] md:max-w-md md:rounded-2xl",
2088
- children: /* @__PURE__ */ jsxs13(Toast.Provider, { children: [
2089
- /* @__PURE__ */ jsx19(Toast.Viewport, { className: "flex justify-center" }),
2090
- /* @__PURE__ */ jsxs13("div", { className: "mx-6 mb-12 flex items-center justify-between", children: [
2091
- /* @__PURE__ */ jsx19(
2092
- "button",
2093
- {
2094
- onClick: () => setStage("WORLD_ID" /* WORLD_ID */),
2095
- disabled: !canGoBack,
2096
- className: classNames(
2097
- !canGoBack && "invisible pointer-events-none",
2098
- "dark:bg-d3dfea/15 flex h-8 w-8 items-center justify-center rounded-full bg-gray-100 dark:text-white"
2099
- ),
2100
- children: /* @__PURE__ */ jsx19(ArrowLongLeftIcon_default, { className: "w-4" })
2101
- }
2102
- ),
2103
- /* @__PURE__ */ jsx19(Dialog.Close, { className: "flex items-center justify-center rounded-full dark:text-white", children: /* @__PURE__ */ jsx19(XMarkIcon_default, { className: "h-5 w-5" }) })
2104
- ] }),
2105
- /* @__PURE__ */ jsx19("div", { className: "relative mx-6 mb-6 flex flex-1 flex-col items-center justify-center", children: /* @__PURE__ */ jsx19(StageContent, {}) }),
2106
- /* @__PURE__ */ jsxs13("div", { className: "flex items-center justify-between border-t border-f5f5f7 p-7 md:rounded-b-2xl", children: [
2107
- /* @__PURE__ */ jsxs13(
1841
+ children: /* @__PURE__ */ jsxs11(Toast.Provider, { children: [
1842
+ /* @__PURE__ */ jsx15(Toast.Viewport, { className: "flex justify-center" }),
1843
+ /* @__PURE__ */ jsx15("div", { className: "mx-6 mb-12 flex items-center justify-between", children: /* @__PURE__ */ jsx15(Dialog.Close, { className: "flex items-center justify-center rounded-full dark:text-white", children: /* @__PURE__ */ jsx15(XMarkIcon_default, { className: "h-5 w-5" }) }) }),
1844
+ /* @__PURE__ */ jsx15("div", { className: "relative mx-6 mb-6 flex flex-1 flex-col items-center justify-center", children: /* @__PURE__ */ jsx15(StageContent, {}) }),
1845
+ /* @__PURE__ */ jsxs11("div", { className: "flex items-center justify-between border-t border-f5f5f7 p-7 md:rounded-b-2xl", children: [
1846
+ /* @__PURE__ */ jsxs11(
2108
1847
  "a",
2109
1848
  {
2110
1849
  href: "https://worldcoin.org/world-id",
@@ -2112,12 +1851,12 @@ var IDKitWidget = ({ children, ...config }) => {
2112
1851
  rel: "noreferrer",
2113
1852
  className: "flex items-center gap-1 text-sm text-9eafc0",
2114
1853
  children: [
2115
- /* @__PURE__ */ jsx19(WorldcoinIcon_default, { className: "w-4 text-9eafc0 dark:text-white" }),
2116
- /* @__PURE__ */ jsx19("span", { children: __("Powered by Worldcoin") })
1854
+ /* @__PURE__ */ jsx15(WorldcoinIcon_default, { className: "w-4 text-9eafc0 dark:text-white" }),
1855
+ /* @__PURE__ */ jsx15("span", { children: __("Powered by Worldcoin") })
2117
1856
  ]
2118
1857
  }
2119
1858
  ),
2120
- /* @__PURE__ */ jsx19(
1859
+ /* @__PURE__ */ jsx15(
2121
1860
  "a",
2122
1861
  {
2123
1862
  href: "https://developer.worldcoin.org/privacy-statement",
@@ -2143,9 +1882,11 @@ var IDKitWidget_default = memo2(BaseWidget_default);
2143
1882
  // src/index.ts
2144
1883
  import { VerificationLevel as VerificationLevel2 } from "@worldcoin/idkit-core";
2145
1884
  import { solidityEncode } from "@worldcoin/idkit-core/hashing";
1885
+ import { verifyCloudProof } from "@worldcoin/idkit-core/backend";
2146
1886
  export {
2147
1887
  IDKitWidget_default as IDKitWidget,
2148
1888
  VerificationLevel2 as VerificationLevel,
2149
1889
  solidityEncode,
2150
- useIDKit_default as useIDKit
1890
+ useIDKit_default as useIDKit,
1891
+ verifyCloudProof
2151
1892
  };
@@ -1,7 +1,7 @@
1
1
  import * as react from 'react';
2
2
  import * as zustand_traditional from 'zustand/traditional';
3
3
  import * as zustand from 'zustand';
4
- import { I as IDKITStage, a as ConfigSource, b as CallbackFn, C as Config } from './config-71e4be16.js';
4
+ import { I as IDKITStage, a as ConfigSource, b as CallbackFn, C as Config } from './config-19dfed99.js';
5
5
  import { IDKitConfig, ISuccessResult, IErrorState } from '@worldcoin/idkit-core';
6
6
 
7
7
  type CleanWord<T> = T extends `${string}${' ' | ',' | '!' | '?' | '.' | '`'}${string}` ? never : T extends '' ? never : T;
@@ -36,9 +36,6 @@ type IDKitStore = {
36
36
  errorCallbacks: Record<ConfigSource, CallbackFn<IErrorState> | undefined> | Record<string, never>;
37
37
  verifyCallbacks: Record<ConfigSource, CallbackFn<ISuccessResult> | undefined> | Record<string, never>;
38
38
  successCallbacks: Record<ConfigSource, CallbackFn<ISuccessResult> | undefined> | Record<string, never>;
39
- computed: {
40
- canGoBack: (stage: IDKITStage) => boolean;
41
- };
42
39
  retryFlow: () => void;
43
40
  setStage: (stage: IDKITStage) => void;
44
41
  onOpenChange: (open: boolean) => void;
package/build/internal.js CHANGED
@@ -3,7 +3,7 @@ import {
3
3
  QRCode_default,
4
4
  __,
5
5
  idkit_default
6
- } from "./chunk-JCPD6J62.js";
6
+ } from "./chunk-YVDL3YIJ.js";
7
7
  export {
8
8
  ConfigSource,
9
9
  QRCode_default as QRCode,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@worldcoin/idkit",
3
- "version": "1.1.4",
3
+ "version": "1.2.0",
4
4
  "homepage": "https://docs.worldcoin.org/id/idkit",
5
5
  "license": "MIT",
6
6
  "private": false,
@@ -53,18 +53,15 @@
53
53
  "react-dom": ">18.0.0"
54
54
  },
55
55
  "dependencies": {
56
- "@fontsource/rubik": "^4.5.11",
57
- "@headlessui/react": "^1.7.4",
58
56
  "@radix-ui/react-dialog": "^1.0.3",
59
57
  "@radix-ui/react-toast": "^1.1.3",
60
58
  "@tailwindcss/forms": "^0.5.3",
61
59
  "copy-to-clipboard": "^3.3.3",
62
60
  "framer-motion": "^7.6.7",
63
- "posthog-js-lite": "2.4.0",
64
61
  "qrcode": "^1.5.1",
65
62
  "react-shadow": "^19.1.0",
66
- "zustand": "^4.3.3",
67
- "@worldcoin/idkit-core": "1.1.4"
63
+ "zustand": "^4.5",
64
+ "@worldcoin/idkit-core": "1.2.0"
68
65
  },
69
66
  "devDependencies": {
70
67
  "@types/node": "18.11.9",
package/src/index.ts CHANGED
@@ -3,7 +3,9 @@ import IDKitWidget from '@/components/IDKitWidget/index'
3
3
  import type { WidgetProps, Config } from '@/types/config'
4
4
  import { VerificationLevel } from '@worldcoin/idkit-core'
5
5
  import { solidityEncode } from '@worldcoin/idkit-core/hashing'
6
+ import { verifyCloudProof } from '@worldcoin/idkit-core/backend'
7
+ import type { IVerifyResponse } from '@worldcoin/idkit-core/backend'
6
8
  import type { ISuccessResult, IErrorState } from '@worldcoin/idkit-core'
7
9
 
8
- export { IDKitWidget, useIDKit, solidityEncode, VerificationLevel }
9
- export type { ISuccessResult, IErrorState, Config, WidgetProps }
10
+ export { IDKitWidget, useIDKit, solidityEncode, verifyCloudProof, VerificationLevel }
11
+ export type { ISuccessResult, IErrorState, IVerifyResponse, Config, WidgetProps }
Binary file