tf-checkout-react 1.3.49 → 1.3.50-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/dist/api/index.d.ts +8 -0
- package/dist/components/addonsContainer/index.d.ts +2 -1
- package/dist/components/billing-info-container/index.d.ts +2 -1
- package/dist/components/common/ModalComponent/index.d.ts +16 -0
- package/dist/components/idVerificationContainer/VerificationPendingModal.d.ts +10 -0
- package/dist/components/idVerificationContainer/constants.d.ts +14 -0
- package/dist/components/idVerificationContainer/index.d.ts +16 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/components/ticketsContainer/index.d.ts +2 -1
- package/dist/components/timerWidget/index.d.ts +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/tf-checkout-react.cjs.development.js +3024 -3962
- package/dist/tf-checkout-react.cjs.development.js.map +1 -1
- package/dist/tf-checkout-react.cjs.production.min.js +1 -1
- package/dist/tf-checkout-react.cjs.production.min.js.map +1 -1
- package/dist/tf-checkout-react.esm.js +3022 -3967
- package/dist/tf-checkout-react.esm.js.map +1 -1
- package/dist/tf-checkout-styles.css +1 -1
- package/dist/types/verification.d.ts +11 -0
- package/dist/utils/index.d.ts +1 -0
- package/dist/utils/jsonUtils.d.ts +1 -0
- package/package.json +7 -6
- package/src/.d.ts +1 -0
- package/src/api/index.ts +40 -0
- package/src/components/addonsContainer/index.tsx +20 -4
- package/src/components/billing-info-container/index.tsx +25 -2
- package/src/components/common/ModalComponent/index.tsx +68 -0
- package/src/components/common/dist/PhoneNumberField.js +96 -0
- package/src/components/idVerificationContainer/VerificationPendingModal.tsx +47 -0
- package/src/components/idVerificationContainer/constants.ts +17 -0
- package/src/components/idVerificationContainer/index.tsx +228 -0
- package/src/components/index.ts +2 -1
- package/src/components/ticketResaleModal/index.tsx +4 -3
- package/src/components/ticketsContainer/PromoCodeSection.tsx +4 -3
- package/src/components/ticketsContainer/index.tsx +13 -1
- package/src/components/timerWidget/index.tsx +9 -7
- package/src/index.ts +3 -1
- package/src/types/verification.ts +11 -0
- package/src/utils/index.ts +1 -0
- package/src/utils/jsonUtils.ts +8 -0
- package/dist/.DS_Store +0 -0
- package/src/.DS_Store +0 -0
- package/src/assets/.DS_Store +0 -0
- package/src/components/confirmModal/style.css +0 -21
|
@@ -1 +1 @@
|
|
|
1
|
-
.button-container{display:flex;justify-content:center;padding:20px}.billing-info-container{margin:0 auto;max-width:800px}.billing-info-container .is-half{width:49%}.billing-info-container p{color:#000}.billing-info-container .main-header{font-size:2rem;font-weight:600}.billing-info-container__twoFields{display:flex;justify-content:space-between;margin-top:15px}.billing-info-container__singleField{margin-top:15px}button{margin-top:10px}.account-actions-block{color:#182026;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Open Sans,Helvetica Neue,Icons16,sans-serif;margin-top:10px}.login-register-button,.MuiButtonBase-root.MuiButton-root,.MuiButtonBase-root.MuiButton-root:hover{background-color:#212529;border:#f28051;border-radius:5px;color:#fff;cursor:pointer;display:block;font-family:Inter-Bold;font-size:26px;font-weight:700;line-height:1.15;margin-top:10px;min-height:46px;outline:none;overflow:hidden;padding:14px 12px 12px;position:relative;text-align:center;text-overflow:ellipsis;text-transform:uppercase;width:49%}.logo-image-container{margin-top:5px;text-align:center;width:49%}.logo-image-container img{height:30px}.login-block{align-items:center;display:flex;flex-direction:column}.login-register-button:hover{background-color:#505050!important;border-color:#505050!important}.login-register-block{display:flex;justify-content:space-between}@media only screen and (max-width:820px){.billing-info-container{width:90%}.billing-info-container .main-header{font-size:1.5rem}}.email-checking{margin-bottom:15px}.forgot-password-modal .forgot-password-container{margin:0 auto;max-width:800px}.forgot-password-modal .title{background-color:#fff;font-family:Inter;font-size:18px;font-weight:700}.forgot-password-modal .forgot-password-container__singleField{margin-top:15px}.forgot-password-modal .forgot-password-action-button button{background-color:#212529;border:none;border-radius:0;color:#fff;cursor:pointer;font-size:26px;font-weight:600;height:45px;line-height:18px;margin-top:10px;outline:none;padding:10px;text-transform:uppercase;width:100%}.forgot-password-modal .forgot-password-action-button button:hover:enabled{background-color:#505050;border-color:#505050}.forgot-password-modal .login{margin-top:10px;text-align:center}.forgot-password-modal .login span{cursor:pointer}.forgot-password-modal .login span:hover{text-decoration:underline}.forgot-password-modal button[disabled]{cursor:unset;opacity:.7}.modal-title{align-items:center;background-color:#fff;display:flex;font-family:Inter;font-size:18px;font-weight:700;height:49px;line-height:22px;padding-left:25px;position:relative}.login-modal-body{padding:15px 25px}.login-modal-body input{background:#fff!important}.login-modal-body__email,.login-modal-body__password{margin-bottom:20px}.login-action-button button{background-color:#212529;border:none;border-radius:0;color:#fff;cursor:pointer;font-size:26px;font-weight:600;height:45px;line-height:18px;margin:10px 0;outline:none;padding:10px;width:100%}.login-action-button button:hover{background-color:#505050;border-color:#505050}.server_auth__error{color:red;font-family:Inter;font-size:12px;font-style:normal;padding-left:25px;padding-top:15px}.info-text-for-login{font-size:14px;margin-bottom:4px;padding-left:10px}.forgot-password{text-align:center}.forgot-password span{cursor:pointer}.forgot-password span:hover{text-decoration:underline}.signup-modal .signup-container{margin:0 auto;max-width:800px}.signup-modal .title{background-color:#fff;font-family:Inter;font-size:18px;font-weight:700}.signup-modal .signup-container .is-half{width:49%}.signup-modal .signup-container__twoFields{display:flex;justify-content:space-between;margin-top:15px}.signup-modal .signup-container__singleField{margin-top:15px}.signup-modal button{margin-top:10px}.signup-modal .signup-action-button button{background-color:#212529;border:none;border-radius:0;color:#fff;cursor:pointer;font-size:26px;font-weight:600;height:45px;line-height:18px;margin-top:10px;outline:none;padding:10px;text-transform:uppercase;width:100%}.signup-modal .signup-action-button button:hover:enabled{background-color:#505050;border-color:#505050}.signup-modal .login{margin-top:10px;text-align:center}.signup-modal .login span{cursor:pointer}.signup-modal .login span:hover{text-decoration:underline}.signup-modal button[disabled]{cursor:unset;opacity:.7}.timer{background-color:#000;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGwSURBVEhLtZa9SgNBEMc9sUxxRcoUKSzSWIhXpFMhhYWFhaBg4yPYiWCXZxBLERsLRS3EQkEfwCKdjWJAwSKCgoKCcudv4O5YLrt7EzgXhiU3/4+b2ckmwVjJSpKkQ6wAi4gwhT+z3wRBcEz0yjSseUTrcRyfsHsXmD0AmbHOC9Ii8VImnuXBPglHpQ5wwSVM7sNnTG7Za4JwDdCjxyAiH3nyA2mtaTJufiDZ5dCaqlItILh1NHatfN5skvjx9Z38m69CgzuXmZgVrPIGE763Jx9qKsRozWYw6xOHdER+nn2KkO+Bb+UV5CBN6WC6QtBgbRVozrahAbmm6HtUsgtPC19tFdxXZYBOfkbmFJ1VaHA1VAHjd0pp70oTZzvR+EVrx2Ygfdsq6eu55BHYR8hlcki+n+kERUFG8BrA0BwjeAv2M8WLQBtcy+SD6fNsmnB3AlBLrgTtVW1c2QN4bVWLATaIS60J2Du5y1TiJgjSBvFVZgTmwCU+dAZFoPxGEEs8nyHC9Bwe2GvEJv2WXZb0vjdyFT4Cxk3e/kIqlOGoVLwwPevpYHT+00T+hWwXDf4AJAOUqWcDhbwAAAAASUVORK5CYII=);background-position:15px;background-repeat:no-repeat;-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;-moz-box-shadow:0 0 12px #999;-webkit-box-shadow:0 0 12px #999;box-shadow:0 0 12px #999;color:#fff;margin:0 0 6px;max-width:300px;overflow:hidden;padding:15px 15px 15px 50px;pointer-events:auto;position:absolute;right:15px;width:300px}.timer .close-icon{cursor:pointer;display:flex;position:absolute;right:10px;top:10px}.timer .countdown{font-weight:700;margin-top:10px}.payment_page{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Open Sans,Helvetica Neue,Icons16,sans-serif}.payment_page .order_info_section{padding:15px 0}.payment_page .order_info_section .order_info_block{padding-bottom:15px;padding-top:15px}.payment_page .order_info_section .order_info_block .field-underline{border-bottom:1px solid #000;padding-bottom:15px}.payment_page .order_info_section .order_info_block .order_info_title{font-size:14px;font-weight:700;padding-bottom:3px}.payment_page .order_info_section .order_info_block .order_info_text{font-size:16px;line-height:1.15;outline:none}.payment_page .MuiBox-root{margin-left:auto;margin-right:auto;padding:20px;text-align:center}.payment_page .payment_info_label{padding:20px 0;text-align:center}.payment_page .payment_form{color:#fff;padding:20px}.payment_page .payment_form input,.payment_page .payment_form label{color:#fff}.payment_page .payment_button{padding-top:20px;text-align:center}.card_form_inner{background:#232323;border-radius:8px;margin:0 auto 20px;min-width:325px;padding:15px;width:50%}.card_form_inner .card_label_text{color:#fff}.card_form_inner .StripeElement{margin:5px 0 10px}.card_label_text{color:#fff}.payment_button{padding-top:15px;text-align:center}.payment_button button{background-color:#212529;border-radius:8px;color:#fff;cursor:pointer;font-size:26px;padding:15px 30px;transition:opacity .5s;width:200px}.payment_button button:hover{opacity:.7}.disabled-payment-button button{opacity:.3;pointer-events:none;user-select:none}.checkout_error_block{color:#e53935;font-weight:600;padding:15px 0}.zip_element p{margin-bottom:0}.zip_element input{background-color:#000;border:none;color:#fff;font-size:18px;margin-top:5px;outline:none;width:100%}.confirmation-page{margin:0 auto;max-width:1024px}.confirmation-page button{margin-top:inherit}.confirmation-page .strong-text{font-weight:700}.confirmation-page .title{color:#333;font-size:24px;font-weight:600}.confirmation-page .share-message-section{background:#dff0d8;border:1px solid #d6e9c6;border-radius:5px;color:#2c7221;display:flex;flex-direction:column;margin:20px 0;padding:15px}.confirmation-page .main{font-size:15px;font-weight:700}.confirmation-page .helper,.confirmation-page .main{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Open Sans,Helvetica Neue,Icons16,sans-serif}.confirmation-page .helper{font-size:14px;margin-top:5px}.confirmation-page .referral_text_image_section{align-items:center;display:flex;flex-wrap:wrap;justify-content:space-between;margin:20px 0}.confirmation-page .referral_text_section{margin:10px}.confirmation-page .referral_title_text{color:#f08057;font-size:28px;padding-bottom:10px}.confirmation-page .referral_text{font-size:18px}.confirmation-page .referral_text_image_section img{margin:10px;max-width:200px}.confirmation-page .share_wrapper{column-gap:5rem;display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));margin:10px}.confirmation-page .invitation_title{font-size:22px;padding-bottom:12px;padding-top:12px}.confirmation-page .share_section{display:flex;flex-wrap:wrap;justify-content:space-between;margin:0 -10px}.confirmation-page .invitation_section{flex:1 1;padding:0 5px}.confirmation-page .share_buttons{display:grid;flex-wrap:wrap;margin:0 -7px}.confirmation-page .convenient_buttons{margin-top:10px}.confirmation-page .social-media-btns{grid-gap:5px;display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr))}.confirmation-page .sharing-btn{background-color:#000;flex:1 1;min-width:130px}.confirmation-page .sharing-btn a{text-decoration:none}.confirmation-page .share-by-link{background:#000;color:#fff;padding:10px}.confirmation-page .share-by-link.label{margin:0;padding:0;text-align:left}.confirmation-page .share-btn-inner{align-items:center;background-color:#000;box-sizing:border-box;color:#fff;cursor:pointer;display:inline-flex;padding:0;text-align:left;width:100%}.confirmation-page .share-input{background-color:#fff;border:none;outline:none;padding:5px;text-align:left;width:300px}.confirmation-page .share-text{display:block;font-size:13px;font-weight:600;padding-top:8px;width:100%}.confirmation-page .pricing-section_wrapper{background:#e3e3e3;border:1px solid #dcdcdc;display:grid;grid-template-columns:1fr 1fr;margin:10px 0;padding:15px}.confirmation-page .pricing-section_label{font-weight:600}.confirmation-page .pricing-section_sublabel{font-size:14px;font-weight:100}.confirmation-page .pricing-section_price{font-weight:600;text-align:right}.confirmation-page .share-by-link-copy-icon{align-items:center;background-color:#32325d;border-radius:4px;color:#fff;cursor:pointer;display:flex;justify-content:center;margin-left:8px;padding:10px;transition:all .15s ease}.confirmation-page .share-by-link-copy-icon:hover{background-color:#505050}.confirmation-page .share-by-link-copy-icon img{width:14px}.confirmation-page .social-media-sharing{background-color:#000;color:#fff;cursor:pointer;padding:10px;text-align:center}.confirmation-page .share-icon{border-radius:4px;display:inline-flex}@media only screen and (max-width:1050px){.confirmation-page .share_wrapper{column-gap:0;display:grid;grid-template-columns:unset;margin:15px}}@media only screen and (max-width:480px){.confirmation-page .social-media-btns{grid-template-columns:unset}.confirmation-page .share-input{width:250px}}body{margin:0;padding:0}.get-tickets-page{width:100%}.event-detail__tier{background-color:#fff;padding:17px 35px 20px}.event-detail__tier-name{color:#000;font-family:Inter-Bold;font-family:Bebas Neue;font-size:.85rem;font-weight:700;letter-spacing:.2em;line-height:1.3;margin-bottom:8px;margin-top:16px;padding-right:20%;text-transform:uppercase}.event-detail__tier-status{align-items:center;display:flex;flex-direction:row;flex-wrap:wrap;justify-content:space-between;margin-top:8px;width:100%}.event-detail__tier-status.ticket-button{background-color:#212529;border:3px solid #000;border-radius:0;color:#fff;cursor:pointer;font-weight:700;letter-spacing:.2em;line-height:1.5;margin-bottom:10px;width:200px}.event-tickets-container{align-items:center;display:flex;justify-content:space-between}.event-detail__tier-status.ticket-button.true{background-color:#c1c3c6;border-color:#afb0b1}.event-detail__tier-price{color:#000;font-family:Inter-Bold;font-size:1.5rem;line-height:1;text-align:center}.event-detail__tier-price p{margin:0}.event-detail__tier-price .fees{font-size:14px;margin-top:4px;text-align:left}.event-detail__tier-price .old-price{color:red;font-size:1.3rem;margin-bottom:5px;text-decoration:line-through}.alert-info{align-items:center;background-color:#d9edf7;border:1px solid #bce8f1;border-radius:4px;color:#3a87ad;display:flex;font-size:1em;justify-content:center;margin:0 35px;padding:8px 15px;text-shadow:0 1px 0 hsla(0,0%,100%,.5)}.alert-info svg{margin-right:4px}.event-detail__tier-state{color:#30bc9d;font-family:Inter-Bold;font-size:.75rem;font-weight:300;line-height:1;text-align:right;text-transform:uppercase}.event-detail__tier-state .ticket-not-started-message{color:#000;text-align:left;text-transform:none;width:50px}.promo-code-block input{font-size:14px;padding:1px 8px}.book-button{background-color:#212529;border:3px solid #000;border-radius:0;color:#fff;cursor:pointer;display:block;font-size:26px;font-weight:700;height:50px;letter-spacing:.2em;line-height:1.5;margin:25px auto 10px;text-align:center;width:100%}.book-button:hover{background-color:#505050;border-color:#505050}.loader-container{align-items:center;display:flex;height:100%;justify-content:center;width:100%}.get-tickets-paper::-webkit-scrollbar{width:5px}.get-tickets-paper::-webkit-scrollbar-track{background:#f1f1f1}.get-tickets-paper::-webkit-scrollbar-thumb{background:#888}.get-tickets-paper::-webkit-scrollbar-thumb:hover{background:#555}.get-tickets .get-tickets__selectbox{width:100%}.disabled{pointer-events:none;user-select:none}.hidden{display:none}.event-closed-message{font-family:Bebas Neue;letter-spacing:.5px}.countdown p{margin:0}.countdown .title{font-weight:700}.countdown .message{font-weight:700;margin-top:20px}.waiting-list{padding:17px 35px 20px}.waiting-list .field-item{margin-bottom:30px}.waiting-list .waiting-list-button{width:100%!important}.waiting-list .waiting-list-button:hover{background-color:#505050}.waiting-list .success-message{margin-bottom:15px;text-align:center}.waiting-list .success-message p{margin:0}.waiting-list .no-tickets-text{font-weight:700;text-align:center}.waiting-list .added-success-message{font-size:22px;margin-bottom:10px}.my-ticket{padding:30px}.my-ticket-table{margin-top:30px}.my-ticket .loading{background-color:rgba(0,0,0,.4);height:100vh;justify-content:center;left:0;position:fixed;top:0;width:100%}.my-ticket .event-info,.my-ticket .loading{align-items:center;display:flex}.my-ticket thead th{font-weight:700}.my-ticket .event-info img{margin-right:10px;width:50px}.my-ticket .order-details-button{background-color:#32325d;border:none;border-radius:4px;color:#fff;cursor:pointer;padding:10px 14px;transition:all .15s ease}.my-ticket .order-details-button:hover{background-color:#505050}.order-details{margin:0 auto;max-width:940px}.order-details .loading{align-items:center;background-color:rgba(0,0,0,.4);display:flex;height:100vh;justify-content:center;left:0;position:fixed;top:0;width:100%;z-index:1400}.order-details .layout-title{font-size:24px;font-weight:400}.order-details .sub-title{font-size:18px;font-weight:400;margin:10px 0}.order-details .order-summary-box{margin-top:30px}.order-details .total-row td,.order-details th{color:#fff;font-weight:700}.order-details .tickets-box{margin-top:30px}.order-details .ticket-add-on-table{background-color:#fcf8e3}.order-details .action-button{background-color:#212529;border:1px solid #fff;border-radius:0;color:#fff;cursor:pointer;display:block;font-family:Bebas Neue;font-size:14px;font-weight:400;line-height:normal;margin-bottom:20px;margin-top:20px;min-height:auto;outline:none;overflow:hidden;padding:12px;position:relative;text-align:center;text-decoration:none;text-overflow:ellipsis;text-transform:uppercase;width:max-content}.order-details .download-button:hover{background-color:#505050}.order-details .personal-link{padding:20px 0}.order-details .total-referrer{padding:0 0 20px}.resale-modal .field-box{display:flex;margin-bottom:10px}.resale-modal .field-box .icon{align-items:center;display:flex;height:56px;justify-content:center;min-width:44px}.resale-modal .field-box .empty-box{min-width:44px}.resale-modal .resale-action-button button{background-color:#212529;color:#fff;cursor:pointer;width:100%}.resale-modal .resale-action-button button[disabled]{opacity:.7}.resale-modal .resale-action-button button:hover{background-color:#505050;border-color:#505050;width:100%}.reset-password{margin:0 auto;max-width:300px;padding:14px}.reset-password .title{font-size:20px;font-weight:700}.reset-password .field-item{margin-top:14px}.reset-password .action-button button{background-color:#212529;border:none;border-radius:0;color:#fff;cursor:pointer;font-size:26px;font-weight:600;height:45px;line-height:18px;margin-top:14px;outline:none;padding:10px;text-transform:uppercase;width:100%}.reset-password .action-button button:hover:enabled{background-color:#505050;border-color:#505050}.reset-password .action-button button[disabled]{cursor:unset;opacity:.7}
|
|
1
|
+
.button-container{display:flex;justify-content:center;padding:20px}.billing-info-container{margin:0 auto;max-width:800px}.billing-info-container .is-half{width:49%}.billing-info-container p{color:#000}.billing-info-container .main-header{font-size:2rem;font-weight:600}.billing-info-container__twoFields{display:flex;justify-content:space-between;margin-top:15px}.billing-info-container__singleField{margin-top:15px}button{margin-top:10px}.account-actions-block{color:#182026;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Open Sans,Helvetica Neue,Icons16,sans-serif;margin-top:10px}.MuiButtonBase-root.MuiButton-root,.MuiButtonBase-root.MuiButton-root:hover,.login-register-button{background-color:#212529;border:#f28051;border-radius:5px;color:#fff;cursor:pointer;display:block;font-family:Inter-Bold;font-size:26px;font-weight:700;line-height:1.15;margin-top:10px;min-height:46px;outline:none;overflow:hidden;padding:14px 12px 12px;position:relative;text-align:center;text-overflow:ellipsis;text-transform:uppercase;width:49%}.logo-image-container{margin-top:5px;text-align:center;width:49%}.logo-image-container img{height:30px}.login-block{align-items:center;display:flex;flex-direction:column}.login-register-button:hover{background-color:#505050!important;border-color:#505050!important}.login-register-block{display:flex;justify-content:space-between}@media only screen and (max-width:820px){.billing-info-container{width:90%}.billing-info-container .main-header{font-size:1.5rem}}.email-checking{margin-bottom:15px}.forgot-password-modal .forgot-password-container{margin:0 auto;max-width:800px}.forgot-password-modal .title{background-color:#fff;font-family:Inter;font-size:18px;font-weight:700}.forgot-password-modal .forgot-password-container__singleField{margin-top:15px}.forgot-password-modal .forgot-password-action-button button{background-color:#212529;border:none;border-radius:0;color:#fff;cursor:pointer;font-size:26px;font-weight:600;height:45px;line-height:18px;margin-top:10px;outline:none;padding:10px;text-transform:uppercase;width:100%}.forgot-password-modal .forgot-password-action-button button:hover:enabled{background-color:#505050;border-color:#505050}.forgot-password-modal .login{margin-top:10px;text-align:center}.forgot-password-modal .login span{cursor:pointer}.forgot-password-modal .login span:hover{text-decoration:underline}.forgot-password-modal button[disabled]{cursor:unset;opacity:.7}.modal-title{align-items:center;background-color:#fff;display:flex;font-family:Inter;font-size:18px;font-weight:700;height:49px;line-height:22px;padding-left:25px;position:relative}.login-modal-body{padding:15px 25px}.login-modal-body input{background:#fff!important}.login-modal-body__email,.login-modal-body__password{margin-bottom:20px}.login-action-button button{background-color:#212529;border:none;border-radius:0;color:#fff;cursor:pointer;font-size:26px;font-weight:600;height:45px;line-height:18px;margin:10px 0;outline:none;padding:10px;width:100%}.login-action-button button:hover{background-color:#505050;border-color:#505050}.server_auth__error{color:red;font-family:Inter;font-size:12px;font-style:normal;padding-left:25px;padding-top:15px}.info-text-for-login{font-size:14px;margin-bottom:4px;padding-left:10px}.forgot-password{text-align:center}.forgot-password span{cursor:pointer}.forgot-password span:hover{text-decoration:underline}.signup-modal .signup-container{margin:0 auto;max-width:800px}.signup-modal .title{background-color:#fff;font-family:Inter;font-size:18px;font-weight:700}.signup-modal .signup-container .is-half{width:49%}.signup-modal .signup-container__twoFields{display:flex;justify-content:space-between;margin-top:15px}.signup-modal .signup-container__singleField{margin-top:15px}.signup-modal button{margin-top:10px}.signup-modal .signup-action-button button{background-color:#212529;border:none;border-radius:0;color:#fff;cursor:pointer;font-size:26px;font-weight:600;height:45px;line-height:18px;margin-top:10px;outline:none;padding:10px;text-transform:uppercase;width:100%}.signup-modal .signup-action-button button:hover:enabled{background-color:#505050;border-color:#505050}.signup-modal .login{margin-top:10px;text-align:center}.signup-modal .login span{cursor:pointer}.signup-modal .login span:hover{text-decoration:underline}.signup-modal button[disabled]{cursor:unset;opacity:.7}.timer{background-color:#000;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGwSURBVEhLtZa9SgNBEMc9sUxxRcoUKSzSWIhXpFMhhYWFhaBg4yPYiWCXZxBLERsLRS3EQkEfwCKdjWJAwSKCgoKCcudv4O5YLrt7EzgXhiU3/4+b2ckmwVjJSpKkQ6wAi4gwhT+z3wRBcEz0yjSseUTrcRyfsHsXmD0AmbHOC9Ii8VImnuXBPglHpQ5wwSVM7sNnTG7Za4JwDdCjxyAiH3nyA2mtaTJufiDZ5dCaqlItILh1NHatfN5skvjx9Z38m69CgzuXmZgVrPIGE763Jx9qKsRozWYw6xOHdER+nn2KkO+Bb+UV5CBN6WC6QtBgbRVozrahAbmm6HtUsgtPC19tFdxXZYBOfkbmFJ1VaHA1VAHjd0pp70oTZzvR+EVrx2Ygfdsq6eu55BHYR8hlcki+n+kERUFG8BrA0BwjeAv2M8WLQBtcy+SD6fNsmnB3AlBLrgTtVW1c2QN4bVWLATaIS60J2Du5y1TiJgjSBvFVZgTmwCU+dAZFoPxGEEs8nyHC9Bwe2GvEJv2WXZb0vjdyFT4Cxk3e/kIqlOGoVLwwPevpYHT+00T+hWwXDf4AJAOUqWcDhbwAAAAASUVORK5CYII=);background-position:15px;background-repeat:no-repeat;-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;-moz-box-shadow:0 0 12px #999;-webkit-box-shadow:0 0 12px #999;box-shadow:0 0 12px #999;color:#fff;margin:0 0 6px;max-width:300px;overflow:hidden;padding:15px 15px 15px 50px;pointer-events:auto;position:absolute;right:15px;width:300px}.timer .close-icon{cursor:pointer;display:flex;position:absolute;right:10px;top:10px}.timer .countdown{font-weight:700;margin-top:10px}.payment_page{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Open Sans,Helvetica Neue,Icons16,sans-serif}.payment_page .order_info_section{padding:15px 0}.payment_page .order_info_section .order_info_block{padding-bottom:15px;padding-top:15px}.payment_page .order_info_section .order_info_block .field-underline{border-bottom:1px solid #000;padding-bottom:15px}.payment_page .order_info_section .order_info_block .order_info_title{font-size:14px;font-weight:700;padding-bottom:3px}.payment_page .order_info_section .order_info_block .order_info_text{font-size:16px;line-height:1.15;outline:none}.payment_page .MuiBox-root{margin-left:auto;margin-right:auto;padding:20px;text-align:center}.payment_page .payment_info_label{padding:20px 0;text-align:center}.payment_page .payment_form{color:#fff;padding:20px}.payment_page .payment_form input,.payment_page .payment_form label{color:#fff}.payment_page .payment_button{padding-top:20px;text-align:center}.card_form_inner{background:#232323;border-radius:8px;margin:0 auto 20px;min-width:325px;padding:15px;width:50%}.card_form_inner .card_label_text{color:#fff}.card_form_inner .StripeElement{margin:5px 0 10px}.card_label_text{color:#fff}.payment_button{padding-top:15px;text-align:center}.payment_button button{background-color:#212529;border-radius:8px;color:#fff;cursor:pointer;font-size:26px;padding:15px 30px;transition:opacity .5s;width:200px}.payment_button button:hover{opacity:.7}.disabled-payment-button button{opacity:.3;pointer-events:none;user-select:none}.checkout_error_block{color:#e53935;font-weight:600;padding:15px 0}.zip_element p{margin-bottom:0}.zip_element input{background-color:#000;border:none;color:#fff;font-size:18px;margin-top:5px;outline:none;width:100%}.confirmation-page{margin:0 auto;max-width:1024px}.confirmation-page button{margin-top:inherit}.confirmation-page .strong-text{font-weight:700}.confirmation-page .title{color:#333;font-size:24px;font-weight:600}.confirmation-page .share-message-section{background:#dff0d8;border:1px solid #d6e9c6;border-radius:5px;color:#2c7221;display:flex;flex-direction:column;margin:20px 0;padding:15px}.confirmation-page .main{font-size:15px;font-weight:700}.confirmation-page .helper,.confirmation-page .main{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Open Sans,Helvetica Neue,Icons16,sans-serif}.confirmation-page .helper{font-size:14px;margin-top:5px}.confirmation-page .referral_text_image_section{align-items:center;display:flex;flex-wrap:wrap;justify-content:space-between;margin:20px 0}.confirmation-page .referral_text_section{margin:10px}.confirmation-page .referral_title_text{color:#f08057;font-size:28px;padding-bottom:10px}.confirmation-page .referral_text{font-size:18px}.confirmation-page .referral_text_image_section img{margin:10px;max-width:200px}.confirmation-page .share_wrapper{column-gap:5rem;display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));margin:10px}.confirmation-page .invitation_title{font-size:22px;padding-bottom:12px;padding-top:12px}.confirmation-page .share_section{display:flex;flex-wrap:wrap;justify-content:space-between;margin:0 -10px}.confirmation-page .invitation_section{flex:1 1;padding:0 5px}.confirmation-page .share_buttons{display:grid;flex-wrap:wrap;margin:0 -7px}.confirmation-page .convenient_buttons{margin-top:10px}.confirmation-page .social-media-btns{grid-gap:5px;display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr))}.confirmation-page .sharing-btn{background-color:#000;flex:1 1;min-width:130px}.confirmation-page .sharing-btn a{text-decoration:none}.confirmation-page .share-by-link{background:#000;color:#fff;padding:10px}.confirmation-page .share-by-link.label{margin:0;padding:0;text-align:left}.confirmation-page .share-btn-inner{align-items:center;background-color:#000;box-sizing:border-box;color:#fff;cursor:pointer;display:inline-flex;padding:0;text-align:left;width:100%}.confirmation-page .share-input{background-color:#fff;border:none;outline:none;padding:5px;text-align:left;width:300px}.confirmation-page .share-text{display:block;font-size:13px;font-weight:600;padding-top:8px;width:100%}.confirmation-page .pricing-section_wrapper{background:#e3e3e3;border:1px solid #dcdcdc;display:grid;grid-template-columns:1fr 1fr;margin:10px 0;padding:15px}.confirmation-page .pricing-section_label{font-weight:600}.confirmation-page .pricing-section_sublabel{font-size:14px;font-weight:100}.confirmation-page .pricing-section_price{font-weight:600;text-align:right}.confirmation-page .share-by-link-copy-icon{align-items:center;background-color:#32325d;border-radius:4px;color:#fff;cursor:pointer;display:flex;justify-content:center;margin-left:8px;padding:10px;transition:all .15s ease}.confirmation-page .share-by-link-copy-icon:hover{background-color:#505050}.confirmation-page .share-by-link-copy-icon img{width:14px}.confirmation-page .social-media-sharing{background-color:#000;color:#fff;cursor:pointer;padding:10px;text-align:center}.confirmation-page .share-icon{border-radius:4px;display:inline-flex}@media only screen and (max-width:1050px){.confirmation-page .share_wrapper{column-gap:0;display:grid;grid-template-columns:unset;margin:15px}}@media only screen and (max-width:480px){.confirmation-page .social-media-btns{grid-template-columns:unset}.confirmation-page .share-input{width:250px}}body{margin:0;padding:0}.get-tickets-page{width:100%}.event-detail__tier{background-color:#fff;padding:17px 35px 20px}.event-detail__tier-name{color:#000;font-family:Inter-Bold;font-family:Bebas Neue;font-size:.85rem;font-weight:700;letter-spacing:.2em;line-height:1.3;margin-bottom:8px;margin-top:16px;padding-right:20%;text-transform:uppercase}.event-detail__tier-status{align-items:center;display:flex;flex-direction:row;flex-wrap:wrap;justify-content:space-between;margin-top:8px;width:100%}.event-detail__tier-status.ticket-button{background-color:#212529;border:3px solid #000;border-radius:0;color:#fff;cursor:pointer;font-weight:700;letter-spacing:.2em;line-height:1.5;margin-bottom:10px;width:200px}.event-tickets-container{align-items:center;display:flex;justify-content:space-between}.event-detail__tier-status.ticket-button.true{background-color:#c1c3c6;border-color:#afb0b1}.event-detail__tier-price{color:#000;font-family:Inter-Bold;font-size:1.5rem;line-height:1;text-align:center}.event-detail__tier-price p{margin:0}.event-detail__tier-price .fees{font-size:14px;margin-top:4px;text-align:left}.event-detail__tier-price .old-price{color:red;font-size:1.3rem;margin-bottom:5px;text-decoration:line-through}.alert-info{align-items:center;background-color:#d9edf7;border:1px solid #bce8f1;border-radius:4px;color:#3a87ad;display:flex;font-size:1em;justify-content:center;margin:0 35px;padding:8px 15px;text-shadow:0 1px 0 hsla(0,0%,100%,.5)}.alert-info svg{margin-right:4px}.event-detail__tier-state{color:#30bc9d;font-family:Inter-Bold;font-size:.75rem;font-weight:300;line-height:1;text-align:right;text-transform:uppercase}.event-detail__tier-state .ticket-not-started-message{color:#000;text-align:left;text-transform:none;width:50px}.promo-code-block input{font-size:14px;padding:1px 8px}.book-button{background-color:#212529;border:3px solid #000;border-radius:0;color:#fff;cursor:pointer;display:block;font-size:26px;font-weight:700;height:50px;letter-spacing:.2em;line-height:1.5;margin:25px auto 10px;text-align:center;width:100%}.book-button:hover{background-color:#505050;border-color:#505050}.loader-container{align-items:center;display:flex;height:100%;justify-content:center;width:100%}.get-tickets-paper::-webkit-scrollbar{width:5px}.get-tickets-paper::-webkit-scrollbar-track{background:#f1f1f1}.get-tickets-paper::-webkit-scrollbar-thumb{background:#888}.get-tickets-paper::-webkit-scrollbar-thumb:hover{background:#555}.get-tickets .get-tickets__selectbox{width:100%}.disabled{pointer-events:none;user-select:none}.hidden{display:none}.event-closed-message{font-family:Bebas Neue;letter-spacing:.5px}.countdown p{margin:0}.countdown .title{font-weight:700}.countdown .message{font-weight:700;margin-top:20px}.waiting-list{padding:17px 35px 20px}.waiting-list .field-item{margin-bottom:30px}.waiting-list .waiting-list-button{width:100%!important}.waiting-list .waiting-list-button:hover{background-color:#505050}.waiting-list .success-message{margin-bottom:15px;text-align:center}.waiting-list .success-message p{margin:0}.waiting-list .no-tickets-text{font-weight:700;text-align:center}.waiting-list .added-success-message{font-size:22px;margin-bottom:10px}.my-ticket{padding:30px}.my-ticket-table{margin-top:30px}.my-ticket .loading{background-color:rgba(0,0,0,.4);height:100vh;justify-content:center;left:0;position:fixed;top:0;width:100%}.my-ticket .event-info,.my-ticket .loading{align-items:center;display:flex}.my-ticket thead th{font-weight:700}.my-ticket .event-info img{margin-right:10px;width:50px}.my-ticket .order-details-button{background-color:#32325d;border:none;border-radius:4px;color:#fff;cursor:pointer;padding:10px 14px;transition:all .15s ease}.my-ticket .order-details-button:hover{background-color:#505050}.order-details{margin:0 auto;max-width:940px}.order-details .loading{align-items:center;background-color:rgba(0,0,0,.4);display:flex;height:100vh;justify-content:center;left:0;position:fixed;top:0;width:100%;z-index:1400}.order-details .layout-title{font-size:24px;font-weight:400}.order-details .sub-title{font-size:18px;font-weight:400;margin:10px 0}.order-details .order-summary-box{margin-top:30px}.order-details .total-row td,.order-details th{color:#fff;font-weight:700}.order-details .tickets-box{margin-top:30px}.order-details .ticket-add-on-table{background-color:#fcf8e3}.order-details .action-button{background-color:#212529;border:1px solid #fff;border-radius:0;color:#fff;cursor:pointer;display:block;font-family:Bebas Neue;font-size:14px;font-weight:400;line-height:normal;margin-bottom:20px;margin-top:20px;min-height:auto;outline:none;overflow:hidden;padding:12px;position:relative;text-align:center;text-decoration:none;text-overflow:ellipsis;text-transform:uppercase;width:max-content}.order-details .download-button:hover{background-color:#505050}.order-details .personal-link{padding:20px 0}.order-details .total-referrer{padding:0 0 20px}.resale-modal .field-box{display:flex;margin-bottom:10px}.resale-modal .field-box .icon{align-items:center;display:flex;height:56px;justify-content:center;min-width:44px}.resale-modal .field-box .empty-box{min-width:44px}.resale-modal .resale-action-button button{background-color:#212529;color:#fff;cursor:pointer;width:100%}.resale-modal .resale-action-button button[disabled]{opacity:.7}.resale-modal .resale-action-button button:hover{background-color:#505050;border-color:#505050;width:100%}.reset-password{margin:0 auto;max-width:300px;padding:14px}.reset-password .title{font-size:20px;font-weight:700}.reset-password .field-item{margin-top:14px}.reset-password .action-button button{background-color:#212529;border:none;border-radius:0;color:#fff;cursor:pointer;font-size:26px;font-weight:600;height:45px;line-height:18px;margin-top:14px;outline:none;padding:10px;text-transform:uppercase;width:100%}.reset-password .action-button button:hover:enabled{background-color:#505050;border-color:#505050}.reset-password .action-button button[disabled]{cursor:unset;opacity:.7}
|
package/dist/utils/index.d.ts
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const isJson: (value: any) => boolean;
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "1.3.
|
|
2
|
+
"version": "1.3.50-beta.1",
|
|
3
3
|
"license": "MIT",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"typings": "dist/index.d.ts",
|
|
@@ -54,11 +54,11 @@
|
|
|
54
54
|
"@types/lodash": "^4.14.176",
|
|
55
55
|
"@types/react": "^17.0.34",
|
|
56
56
|
"@types/react-dom": "^17.0.11",
|
|
57
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
57
|
+
"@typescript-eslint/eslint-plugin": "^5.48.1",
|
|
58
58
|
"@typescript-eslint/parser": "5.4.0",
|
|
59
|
-
"eslint": "^
|
|
60
|
-
"eslint-config-react-app": "^
|
|
61
|
-
"eslint-plugin-flowtype": "^
|
|
59
|
+
"eslint": "^8.32.0",
|
|
60
|
+
"eslint-config-react-app": "^7.0.1",
|
|
61
|
+
"eslint-plugin-flowtype": "^8.0.3",
|
|
62
62
|
"eslint-plugin-import": "^2.22.1",
|
|
63
63
|
"eslint-plugin-jsx-a11y": "^6.4.1",
|
|
64
64
|
"eslint-plugin-react": "^7.23.2",
|
|
@@ -74,7 +74,7 @@
|
|
|
74
74
|
"size-limit": "^6.0.4",
|
|
75
75
|
"tsdx": "^0.14.1",
|
|
76
76
|
"tslib": "^2.3.1",
|
|
77
|
-
"typescript": "^4.
|
|
77
|
+
"typescript": "^4.9.4"
|
|
78
78
|
},
|
|
79
79
|
"dependencies": {
|
|
80
80
|
"@emotion/react": "^11.7.0",
|
|
@@ -98,6 +98,7 @@
|
|
|
98
98
|
"react-countdown": "^2.3.2",
|
|
99
99
|
"react-inlinesvg": "^2.3.0",
|
|
100
100
|
"react-share": "^4.4.0",
|
|
101
|
+
"rollup-plugin-svg": "^2.0.0",
|
|
101
102
|
"yup": "^0.32.11"
|
|
102
103
|
}
|
|
103
104
|
}
|
package/src/.d.ts
CHANGED
package/src/api/index.ts
CHANGED
|
@@ -2,6 +2,11 @@ import { AxiosRequestConfig, AxiosResponse } from 'axios'
|
|
|
2
2
|
import _get from 'lodash/get'
|
|
3
3
|
|
|
4
4
|
import { pageOptions } from '../hooks/usePixel'
|
|
5
|
+
import {
|
|
6
|
+
GetNetverifyUrlResponseData,
|
|
7
|
+
UpdateVerificationStatusResponseData,
|
|
8
|
+
VerificationStatusResponseData,
|
|
9
|
+
} from '../types/verification'
|
|
5
10
|
import { CONFIGS, getCookieByName, setCustomCookie } from '../utils'
|
|
6
11
|
import { getQueryVariable } from '../utils/getQueryVariable'
|
|
7
12
|
import { publicRequest, ttfHeaders } from '../utils/setConfigs'
|
|
@@ -419,3 +424,38 @@ export function getPixelScript(id: string | number, pageOptions: pageOptions) {
|
|
|
419
424
|
})
|
|
420
425
|
return response
|
|
421
426
|
}
|
|
427
|
+
|
|
428
|
+
// ID Verification
|
|
429
|
+
export const getNetverifyUrl = async (): Promise<GetNetverifyUrlResponseData> => {
|
|
430
|
+
const response: AxiosResponse<
|
|
431
|
+
GetNetverifyUrlResponseData,
|
|
432
|
+
AxiosRequestConfig
|
|
433
|
+
> = await publicRequest.get('v1/authenticate/verify')
|
|
434
|
+
return response.data
|
|
435
|
+
}
|
|
436
|
+
|
|
437
|
+
export const checkVerificationStatus = async (): Promise<{
|
|
438
|
+
data: VerificationStatusResponseData;
|
|
439
|
+
}> => {
|
|
440
|
+
const response: AxiosResponse<
|
|
441
|
+
{ data: VerificationStatusResponseData },
|
|
442
|
+
AxiosRequestConfig
|
|
443
|
+
> = await publicRequest.get('v1/authenticate/get-verification-info')
|
|
444
|
+
return response.data
|
|
445
|
+
}
|
|
446
|
+
|
|
447
|
+
export const updateVerificationStatus = async (): Promise<{
|
|
448
|
+
data: UpdateVerificationStatusResponseData;
|
|
449
|
+
}> => {
|
|
450
|
+
const response: AxiosResponse<
|
|
451
|
+
{ data: UpdateVerificationStatusResponseData },
|
|
452
|
+
AxiosRequestConfig
|
|
453
|
+
> = await publicRequest.patch('v1/authenticate/verify', {
|
|
454
|
+
data: {
|
|
455
|
+
verification: {
|
|
456
|
+
verificationStatus: 'PENDING',
|
|
457
|
+
},
|
|
458
|
+
},
|
|
459
|
+
})
|
|
460
|
+
return response.data
|
|
461
|
+
}
|
|
@@ -19,6 +19,7 @@ import {
|
|
|
19
19
|
createMarkup,
|
|
20
20
|
getQueryVariable,
|
|
21
21
|
} from '../../utils'
|
|
22
|
+
import { VerificationPendingModal } from '../idVerificationContainer/VerificationPendingModal'
|
|
22
23
|
import TimerWidget from '../timerWidget'
|
|
23
24
|
import { addonsWithGroupsAdapter, cartAdapter } from './adapters'
|
|
24
25
|
import AddonComponent from './AddonComponent'
|
|
@@ -42,6 +43,7 @@ export interface IAddonContainterProps {
|
|
|
42
43
|
onConfirmSelectionSuccess?: (res: any) => void;
|
|
43
44
|
onConfirmSelectionError?: (error: any) => void;
|
|
44
45
|
onCountdownFinish?: () => void;
|
|
46
|
+
onPendingVerification?: () => void;
|
|
45
47
|
}
|
|
46
48
|
|
|
47
49
|
export interface ObjectLiteral {
|
|
@@ -59,6 +61,7 @@ export const AddonsContainter = ({
|
|
|
59
61
|
onConfirmSelectionSuccess = _identity,
|
|
60
62
|
onConfirmSelectionError = _identity,
|
|
61
63
|
onCountdownFinish = _identity,
|
|
64
|
+
onPendingVerification = _identity,
|
|
62
65
|
}: IAddonContainterProps) => {
|
|
63
66
|
const eventId = getQueryVariable('event_id')
|
|
64
67
|
const [addons, setAddons] = useState<any>([])
|
|
@@ -72,6 +75,7 @@ export const AddonsContainter = ({
|
|
|
72
75
|
] = useState<any>({})
|
|
73
76
|
const [loading, setLoading] = useState(true)
|
|
74
77
|
const [cartExpirationTime, setCartExpirationTime] = useState(0)
|
|
78
|
+
const [pendingVerificationMessage, setPendingVerificationMessage] = useState()
|
|
75
79
|
|
|
76
80
|
useEffect(() => {
|
|
77
81
|
const getAddonsPageInfo = async () => {
|
|
@@ -209,8 +213,10 @@ export const AddonsContainter = ({
|
|
|
209
213
|
const phoneIsRequired = pageConfigsData.phone_required ?? false
|
|
210
214
|
const hasAddOn = pageConfigsData.has_add_on ?? false
|
|
211
215
|
const freeTicket = pageConfigsData.free_ticket ?? false
|
|
212
|
-
const collectOptionalWalletAddress =
|
|
213
|
-
|
|
216
|
+
const collectOptionalWalletAddress =
|
|
217
|
+
pageConfigsData.collect_optional_wallet_address ?? false
|
|
218
|
+
const collectMandatoryWalletAddress =
|
|
219
|
+
pageConfigsData.collect_mandatory_wallet_address ?? false
|
|
214
220
|
|
|
215
221
|
if (skipBillingPage && enableBillingInfoAutoCreate) {
|
|
216
222
|
const ticketsQuantity = window.localStorage.getItem('quantity')
|
|
@@ -252,8 +258,12 @@ export const AddonsContainter = ({
|
|
|
252
258
|
collect_mandatory_wallet_address: collectMandatoryWalletAddress,
|
|
253
259
|
})
|
|
254
260
|
} catch (error) {
|
|
255
|
-
|
|
256
|
-
|
|
261
|
+
if (error.response?.data?.data?.hasUnverifiedOrder) {
|
|
262
|
+
setPendingVerificationMessage(error.response?.data?.message)
|
|
263
|
+
} else {
|
|
264
|
+
onPostCheckoutError(error)
|
|
265
|
+
onConfirmSelectionError(error)
|
|
266
|
+
}
|
|
257
267
|
}
|
|
258
268
|
} else {
|
|
259
269
|
if (isWindowDefined) {
|
|
@@ -435,6 +445,12 @@ export const AddonsContainter = ({
|
|
|
435
445
|
</Formik>
|
|
436
446
|
</div>
|
|
437
447
|
</div>
|
|
448
|
+
<VerificationPendingModal
|
|
449
|
+
message={pendingVerificationMessage}
|
|
450
|
+
onClose={() => {
|
|
451
|
+
onPendingVerification()
|
|
452
|
+
}}
|
|
453
|
+
/>
|
|
438
454
|
</>
|
|
439
455
|
)
|
|
440
456
|
}
|
|
@@ -46,6 +46,7 @@ import { getQueryVariable } from '../../utils/getQueryVariable'
|
|
|
46
46
|
import { combineValidators, requiredValidator } from '../../validators'
|
|
47
47
|
import SnackbarAlert from '../common/SnackbarAlert'
|
|
48
48
|
import { ForgotPasswordModal } from '../forgotPasswordModal'
|
|
49
|
+
import { VerificationPendingModal } from '../idVerificationContainer/VerificationPendingModal'
|
|
49
50
|
import { LoginModal } from '../loginModal'
|
|
50
51
|
import { SignupModal } from '../signupModal'
|
|
51
52
|
import TimerWidget from '../timerWidget'
|
|
@@ -110,6 +111,8 @@ export interface IBillingInfoPage {
|
|
|
110
111
|
brandOptIn?: boolean;
|
|
111
112
|
showPoweredByImage?: boolean;
|
|
112
113
|
isCountryCodeEditable?: boolean;
|
|
114
|
+
|
|
115
|
+
onPendingVerification?: () => void;
|
|
113
116
|
}
|
|
114
117
|
|
|
115
118
|
const LogicRunner: FC<{
|
|
@@ -249,6 +252,7 @@ export const BillingInfoContainer = React.memo(
|
|
|
249
252
|
brandOptIn = false,
|
|
250
253
|
showPoweredByImage = false,
|
|
251
254
|
isCountryCodeEditable = true,
|
|
255
|
+
onPendingVerification = _identity,
|
|
252
256
|
}: IBillingInfoPage) => {
|
|
253
257
|
const [isNewUser, setIsNewUser] = useState(false)
|
|
254
258
|
const themeMui = createTheme(themeOptions)
|
|
@@ -326,6 +330,11 @@ export const BillingInfoContainer = React.memo(
|
|
|
326
330
|
const hideWalletAddressField =
|
|
327
331
|
!collectOptionalWalletAddress && !collectMandatoryWalletAddress
|
|
328
332
|
|
|
333
|
+
const [
|
|
334
|
+
pendingVerificationMessage,
|
|
335
|
+
setPendingVerificationMessage,
|
|
336
|
+
] = useState()
|
|
337
|
+
|
|
329
338
|
// Get prevProps
|
|
330
339
|
const prevData = useRef(data)
|
|
331
340
|
|
|
@@ -455,6 +464,9 @@ export const BillingInfoContainer = React.memo(
|
|
|
455
464
|
setLoading(false)
|
|
456
465
|
} catch (e) {
|
|
457
466
|
onSubmitError(e)
|
|
467
|
+
if (e.response?.data?.data?.hasUnverifiedOrder) {
|
|
468
|
+
setPendingVerificationMessage(e.response?.data?.message)
|
|
469
|
+
}
|
|
458
470
|
}
|
|
459
471
|
} else {
|
|
460
472
|
setLoading(false)
|
|
@@ -625,7 +637,10 @@ export const BillingInfoContainer = React.memo(
|
|
|
625
637
|
})
|
|
626
638
|
} catch (e) {
|
|
627
639
|
setLoading(false)
|
|
628
|
-
|
|
640
|
+
|
|
641
|
+
if (e.response?.data?.data?.hasUnverifiedOrder) {
|
|
642
|
+
setPendingVerificationMessage(e.response?.data?.message)
|
|
643
|
+
} else if (axios.isAxiosError(e)) {
|
|
629
644
|
const error = e?.response?.data?.message
|
|
630
645
|
if (_includes(error, 'You must be aged')) {
|
|
631
646
|
formikHelpers.setFieldError('holderAge', error)
|
|
@@ -684,7 +699,9 @@ export const BillingInfoContainer = React.memo(
|
|
|
684
699
|
)
|
|
685
700
|
} catch (e) {
|
|
686
701
|
setLoading(false)
|
|
687
|
-
if (
|
|
702
|
+
if (e.response?.data?.data?.hasUnverifiedOrder) {
|
|
703
|
+
setPendingVerificationMessage(e.response?.data?.message)
|
|
704
|
+
} else if (axios.isAxiosError(e)) {
|
|
688
705
|
if (
|
|
689
706
|
e.response?.status === 401 ||
|
|
690
707
|
e.response?.data?.error === 'invalid_token'
|
|
@@ -1058,6 +1075,12 @@ export const BillingInfoContainer = React.memo(
|
|
|
1058
1075
|
showPoweredByImage={showPoweredByImage}
|
|
1059
1076
|
/>
|
|
1060
1077
|
)}
|
|
1078
|
+
<VerificationPendingModal
|
|
1079
|
+
message={pendingVerificationMessage}
|
|
1080
|
+
onClose={() => {
|
|
1081
|
+
onPendingVerification()
|
|
1082
|
+
}}
|
|
1083
|
+
/>
|
|
1061
1084
|
</ThemeProvider>
|
|
1062
1085
|
)
|
|
1063
1086
|
}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { Modal as MuiModal } from '@mui/material'
|
|
2
|
+
import Box from '@mui/material/Box'
|
|
3
|
+
import Button from '@mui/material/Button'
|
|
4
|
+
import CircularProgress from '@mui/material/CircularProgress'
|
|
5
|
+
import _map from 'lodash/map'
|
|
6
|
+
import React, { FC } from 'react'
|
|
7
|
+
|
|
8
|
+
export interface Action {
|
|
9
|
+
id: string;
|
|
10
|
+
label: string;
|
|
11
|
+
onClick: () => void;
|
|
12
|
+
disabled?: boolean;
|
|
13
|
+
loading?: boolean;
|
|
14
|
+
variant?: "text" | "contained" | "outlined";
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
interface Props {
|
|
18
|
+
onClose?: () => void;
|
|
19
|
+
actions: Action[];
|
|
20
|
+
modalClassName?: string;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
const style: React.CSSProperties = {
|
|
24
|
+
position: 'absolute',
|
|
25
|
+
top: '50%',
|
|
26
|
+
left: '50%',
|
|
27
|
+
transform: 'translate(-50%, -50%)',
|
|
28
|
+
minWidth: 480,
|
|
29
|
+
backgroundColor: '#e3e3e3',
|
|
30
|
+
border: '1px solid white',
|
|
31
|
+
outline: 'none',
|
|
32
|
+
padding: '14px',
|
|
33
|
+
maxHeight: '85vh',
|
|
34
|
+
overflow: 'auto',
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
const Modal: FC<Props> = ({
|
|
38
|
+
onClose,
|
|
39
|
+
actions = [],
|
|
40
|
+
children,
|
|
41
|
+
modalClassName = '',
|
|
42
|
+
}) => (
|
|
43
|
+
<MuiModal
|
|
44
|
+
open={true}
|
|
45
|
+
onClose={onClose}
|
|
46
|
+
aria-labelledby="modal-modal-title"
|
|
47
|
+
aria-describedby="modal-modal-description"
|
|
48
|
+
className={`confirm-modal ${modalClassName}`}
|
|
49
|
+
>
|
|
50
|
+
<Box style={style}>
|
|
51
|
+
<div className="modal-body">{children}</div>
|
|
52
|
+
<div className="footer">
|
|
53
|
+
{_map(actions, (action: Action) => (
|
|
54
|
+
<Button
|
|
55
|
+
key={action.id}
|
|
56
|
+
onClick={action.onClick}
|
|
57
|
+
disabled={action.disabled || action.loading}
|
|
58
|
+
variant={action.variant || "text"}
|
|
59
|
+
>
|
|
60
|
+
{action.loading ? <CircularProgress size="22px" /> : action.label}
|
|
61
|
+
</Button>
|
|
62
|
+
))}
|
|
63
|
+
</div>
|
|
64
|
+
</Box>
|
|
65
|
+
</MuiModal>
|
|
66
|
+
)
|
|
67
|
+
|
|
68
|
+
export default Modal
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __assign = (this && this.__assign) || function () {
|
|
3
|
+
__assign = Object.assign || function(t) {
|
|
4
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
5
|
+
s = arguments[i];
|
|
6
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
7
|
+
t[p] = s[p];
|
|
8
|
+
}
|
|
9
|
+
return t;
|
|
10
|
+
};
|
|
11
|
+
return __assign.apply(this, arguments);
|
|
12
|
+
};
|
|
13
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
14
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
15
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
16
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
17
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
18
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
19
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
20
|
+
});
|
|
21
|
+
};
|
|
22
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
23
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
24
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
25
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
26
|
+
function step(op) {
|
|
27
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
28
|
+
while (_) try {
|
|
29
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
30
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
31
|
+
switch (op[0]) {
|
|
32
|
+
case 0: case 1: t = op; break;
|
|
33
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
34
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
35
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
36
|
+
default:
|
|
37
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
38
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
39
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
40
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
41
|
+
if (t[2]) _.ops.pop();
|
|
42
|
+
_.trys.pop(); continue;
|
|
43
|
+
}
|
|
44
|
+
op = body.call(thisArg, _);
|
|
45
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
46
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
exports.__esModule = true;
|
|
50
|
+
exports.PhoneNumberField = void 0;
|
|
51
|
+
var TextField_1 = require("@mui/material/TextField");
|
|
52
|
+
var debounce_1 = require("lodash/debounce");
|
|
53
|
+
var get_1 = require("lodash/get");
|
|
54
|
+
var react_1 = require("react");
|
|
55
|
+
var api_1 = require("../../api");
|
|
56
|
+
exports.PhoneNumberField = function (_a) {
|
|
57
|
+
var label = _a.label, _b = _a.type, type = _b === void 0 ? 'text' : _b, field = _a.field, _c = _a.form, errors = _c.errors, setFieldError = _c.setFieldError, setStatus = _c.setStatus;
|
|
58
|
+
var error = get_1["default"](errors, field.name);
|
|
59
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
60
|
+
var debounceCb = react_1.useCallback(debounce_1["default"](function (cb) { return void cb(); }, 1000), []);
|
|
61
|
+
react_1.useEffect(function () {
|
|
62
|
+
var _a;
|
|
63
|
+
if (field.value) {
|
|
64
|
+
setStatus((_a = {}, _a[field.name] = true, _a));
|
|
65
|
+
}
|
|
66
|
+
debounceCb(function () { return __awaiter(void 0, void 0, void 0, function () {
|
|
67
|
+
var error_1, message;
|
|
68
|
+
var _a;
|
|
69
|
+
return __generator(this, function (_b) {
|
|
70
|
+
switch (_b.label) {
|
|
71
|
+
case 0:
|
|
72
|
+
_b.trys.push([0, 3, 4, 5]);
|
|
73
|
+
if (!field.value) return [3 /*break*/, 2];
|
|
74
|
+
return [4 /*yield*/, api_1.validatePhoneNumber(field.value)];
|
|
75
|
+
case 1:
|
|
76
|
+
_b.sent();
|
|
77
|
+
_b.label = 2;
|
|
78
|
+
case 2:
|
|
79
|
+
setFieldError(field.name, '');
|
|
80
|
+
return [3 /*break*/, 5];
|
|
81
|
+
case 3:
|
|
82
|
+
error_1 = _b.sent();
|
|
83
|
+
message = get_1["default"](error_1, 'response.data.message', 'Invalid phone number');
|
|
84
|
+
setFieldError(field.name, message);
|
|
85
|
+
return [3 /*break*/, 5];
|
|
86
|
+
case 4:
|
|
87
|
+
setStatus((_a = {}, _a[field.name] = false, _a));
|
|
88
|
+
return [7 /*endfinally*/];
|
|
89
|
+
case 5: return [2 /*return*/];
|
|
90
|
+
}
|
|
91
|
+
});
|
|
92
|
+
}); });
|
|
93
|
+
// eslint-disable-next-line
|
|
94
|
+
}, [field.value]);
|
|
95
|
+
return (react_1["default"].createElement(TextField_1["default"], __assign({}, field, { id: field.name, label: label, type: type, fullWidth: true, error: !!error, helperText: error, value: field.value || '', inputProps: { pattern: '[+0-9]/d+' } })));
|
|
96
|
+
};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import React, { useEffect, useState } from 'react'
|
|
2
|
+
|
|
3
|
+
import Modal, { Action } from '../common/ModalComponent'
|
|
4
|
+
|
|
5
|
+
interface IDVerificationProps {
|
|
6
|
+
message?: string | null;
|
|
7
|
+
displayModal?: boolean;
|
|
8
|
+
actions?: Action[];
|
|
9
|
+
onClose?: () => void;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export const VerificationPendingModal = (props: IDVerificationProps) => {
|
|
13
|
+
const { message, displayModal, actions, onClose } = props
|
|
14
|
+
const [showModal, setShowModal] = useState(false)
|
|
15
|
+
|
|
16
|
+
useEffect(() => {
|
|
17
|
+
if (displayModal === undefined) {
|
|
18
|
+
setShowModal(Boolean(message))
|
|
19
|
+
}
|
|
20
|
+
}, [message, displayModal])
|
|
21
|
+
|
|
22
|
+
return showModal || displayModal ? (
|
|
23
|
+
<div>
|
|
24
|
+
<Modal
|
|
25
|
+
modalClassName="id-verification-modal"
|
|
26
|
+
actions={
|
|
27
|
+
actions || [
|
|
28
|
+
{
|
|
29
|
+
id: 'okay',
|
|
30
|
+
label: 'OK',
|
|
31
|
+
variant: 'contained',
|
|
32
|
+
onClick: () => {
|
|
33
|
+
setShowModal(false)
|
|
34
|
+
|
|
35
|
+
if (onClose) {
|
|
36
|
+
onClose()
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
]
|
|
41
|
+
}
|
|
42
|
+
>
|
|
43
|
+
<div>{message}</div>
|
|
44
|
+
</Modal>
|
|
45
|
+
</div>
|
|
46
|
+
) : null
|
|
47
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/* eslint-disable max-len */
|
|
2
|
+
export const VERIFICATION_STATUSES = {
|
|
3
|
+
PENDING: 'PENDING',
|
|
4
|
+
APPROVED: 'APPROVED_VERIFIED',
|
|
5
|
+
FAILED: 'FAILED',
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
export const TRANSACTION_STATUSES = {
|
|
9
|
+
ERROR: 'ERROR',
|
|
10
|
+
SUCCESS: 'SUCCESS',
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export const VERIFICATION_MESSAGES = {
|
|
14
|
+
PENDING: 'Your ID verification is currently being processed. We will notify you as soon as it is completed. Thank you for your patience.',
|
|
15
|
+
APPROVED: 'Your ID verification is approved!',
|
|
16
|
+
FAILED: 'Unfortunately your ID verification has failed. Please try again.',
|
|
17
|
+
}
|