tf-checkout-react 1.0.87 → 1.0.91
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/components/billing-info-container/index.d.ts +4 -1
- package/dist/components/paymentContainer/index.d.ts +4 -2
- package/dist/components/ticketsContainer/index.d.ts +2 -1
- package/dist/components/timerWidget/index.d.ts +15 -0
- package/dist/tf-checkout-react.cjs.development.js +260 -87
- 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 +261 -88
- package/dist/tf-checkout-react.esm.js.map +1 -1
- package/dist/tf-checkout-styles.css +1 -1
- package/dist/utils/createCheckoutDataBodyWithDefaultHolder.d.ts +1 -1
- package/dist/utils/showZero.d.ts +1 -0
- package/package.json +2 -1
- package/src/components/billing-info-container/index.tsx +72 -14
- package/src/components/loginModal/index.tsx +8 -0
- package/src/components/loginModal/style.css +9 -0
- package/src/components/paymentContainer/index.tsx +30 -10
- package/src/components/ticketsContainer/TicketRow.tsx +3 -9
- package/src/components/ticketsContainer/TicketsSection.tsx +11 -16
- package/src/components/ticketsContainer/index.tsx +6 -6
- package/src/components/timerWidget/index.tsx +70 -0
- package/src/components/timerWidget/style.css +26 -0
- package/src/utils/createCheckoutDataBodyWithDefaultHolder.ts +9 -1
- package/src/utils/showZero.tsx +10 -0
|
@@ -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}.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}.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}.register-container{margin:0 auto;max-width:800px}.register-container .is-half{width:49%}.register-container__twoFields{display:flex;justify-content:space-between;margin-top:15px}.register-container__singleField{margin-top:15px}button{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}.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}.countdown p{margin:0}.countdown .title{font-weight:700}.countdown .message{font-weight:700;margin-top:20px}.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%}.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 .download-button{background-color:#212529;border:1px solid #fff;border-radius:0;color:#fff;cursor:pointer;display:block;font-family:Bebas Neue;font-size:16px;font-weight:400;line-height:normal;margin-bottom:20px;margin-top:20px;min-height:auto;outline:none;overflow:hidden;padding:12px 0;position:relative;text-align:center;text-decoration:none;text-overflow:ellipsis;text-transform:uppercase;width:100%}.order-details .download-button:hover{background-color:#505050}.order-details .personal-link{padding:20px 0}
|
|
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}.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}.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}.register-container{margin:0 auto;max-width:800px}.register-container .is-half{width:49%}.register-container__twoFields{display:flex;justify-content:space-between;margin-top:15px}.register-container__singleField{margin-top:15px}button{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{border:none;font-size:18px;margin-top:5px;outline:none;width:100%}.timer,.zip_element input{background-color:#000;color:#fff}.timer{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;margin:0 0 6px;max-width:300px;overflow:hidden;padding:15px 15px 15px 50px;pointer-events:auto;position:absolute;right:15px;width:300px}.timer .countdown{font-weight:700;margin-top:10px}.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}.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}.countdown p{margin:0}.countdown .title{font-weight:700}.countdown .message{font-weight:700;margin-top:20px}.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%}.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 .download-button{background-color:#212529;border:1px solid #fff;border-radius:0;color:#fff;cursor:pointer;display:block;font-family:Bebas Neue;font-size:16px;font-weight:400;line-height:normal;margin-bottom:20px;margin-top:20px;min-height:auto;outline:none;overflow:hidden;padding:12px 0;position:relative;text-align:center;text-decoration:none;text-overflow:ellipsis;text-transform:uppercase;width:100%}.order-details .download-button:hover{background-color:#505050}.order-details .personal-link{padding:20px 0}
|
|
@@ -3,5 +3,5 @@ interface ICheckoutBody {
|
|
|
3
3
|
[key: string]: any;
|
|
4
4
|
};
|
|
5
5
|
}
|
|
6
|
-
export declare const createCheckoutDataBodyWithDefaultHolder: (ticketsQuantity: number, logedInValues: {}) => ICheckoutBody;
|
|
6
|
+
export declare const createCheckoutDataBodyWithDefaultHolder: (ticketsQuantity: number, logedInValues: {}, includeDob?: boolean) => ICheckoutBody;
|
|
7
7
|
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const showZero: (value?: number) => string | number | null;
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "1.0.
|
|
2
|
+
"version": "1.0.91",
|
|
3
3
|
"license": "MIT",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"typings": "dist/index.d.ts",
|
|
@@ -81,6 +81,7 @@
|
|
|
81
81
|
"nanoid": "^3.1.30",
|
|
82
82
|
"prop-types": "^15.7.2",
|
|
83
83
|
"react-bootstrap": "^2.0.2",
|
|
84
|
+
"react-countdown": "^2.3.2",
|
|
84
85
|
"react-inlinesvg": "^2.3.0",
|
|
85
86
|
"react-share": "^4.4.0"
|
|
86
87
|
}
|
|
@@ -40,6 +40,7 @@ import {
|
|
|
40
40
|
getValidateFunctions,
|
|
41
41
|
setLoggedUserData,
|
|
42
42
|
} from './utils'
|
|
43
|
+
import { createCheckoutDataBodyWithDefaultHolder } from '../../utils'
|
|
43
44
|
import { CustomField } from '../common/CustomField'
|
|
44
45
|
import axios from 'axios'
|
|
45
46
|
import { CheckboxField } from '../common/CheckboxField'
|
|
@@ -51,6 +52,7 @@ import { ErrorFocus } from '../../utils/formikErrorFocus'
|
|
|
51
52
|
import { FormikPhoneNumberField } from '../common/FormikPhoneNumberField'
|
|
52
53
|
import { ThemeProvider, createTheme } from '@mui/material/styles'
|
|
53
54
|
import { CSSProperties } from '@mui/styles'
|
|
55
|
+
import Backdrop from '@mui/material/Backdrop'
|
|
54
56
|
|
|
55
57
|
export interface IBillingInfoPage {
|
|
56
58
|
data?: IBillingInfoData[];
|
|
@@ -90,7 +92,10 @@ export interface IBillingInfoPage {
|
|
|
90
92
|
input?: CSSProperties;
|
|
91
93
|
checkbox?: CSSProperties;
|
|
92
94
|
};
|
|
93
|
-
hideErrorsAlertSection?: boolean
|
|
95
|
+
hideErrorsAlertSection?: boolean;
|
|
96
|
+
onSkipBillingPage: (data: any) => void;
|
|
97
|
+
skipPage?: boolean;
|
|
98
|
+
canSkipHolderNames?: boolean;
|
|
94
99
|
}
|
|
95
100
|
|
|
96
101
|
const LogicRunner: FC<{
|
|
@@ -202,7 +207,10 @@ export const BillingInfoContainer = ({
|
|
|
202
207
|
hideLogo,
|
|
203
208
|
themeOptions,
|
|
204
209
|
onErrorClose = () => {},
|
|
205
|
-
hideErrorsAlertSection = false
|
|
210
|
+
hideErrorsAlertSection = false,
|
|
211
|
+
onSkipBillingPage = () => {},
|
|
212
|
+
skipPage = false,
|
|
213
|
+
canSkipHolderNames = false
|
|
206
214
|
}: IBillingInfoPage) => {
|
|
207
215
|
const themeMui = createTheme(themeOptions)
|
|
208
216
|
const isWindowDefined = typeof window !== 'undefined'
|
|
@@ -241,6 +249,7 @@ export const BillingInfoContainer = ({
|
|
|
241
249
|
state: '',
|
|
242
250
|
zip: '',
|
|
243
251
|
})
|
|
252
|
+
const [loading, setLoading] = useState(true)
|
|
244
253
|
const [error, setError] = useState(null)
|
|
245
254
|
const emailLogged =
|
|
246
255
|
_get(userData, 'email', '') || _get(userValues, 'email', '')
|
|
@@ -249,6 +258,7 @@ export const BillingInfoContainer = ({
|
|
|
249
258
|
const lastNameLogged =
|
|
250
259
|
_get(userData, 'last_name', '') || _get(userValues, 'last_name', '')
|
|
251
260
|
const showDOB = getQueryVariable('age_required') === 'true'
|
|
261
|
+
const showTicketHolders = getQueryVariable('names_required') === 'true'
|
|
252
262
|
const eventId = getQueryVariable('event_id')
|
|
253
263
|
const optedInFieldValue: boolean = _get(cartInfoData, 'optedIn', false)
|
|
254
264
|
const ttfOptIn: boolean = Boolean(_get(cartInfoData, 'ttfOptIn', false))
|
|
@@ -349,6 +359,62 @@ export const BillingInfoContainer = ({
|
|
|
349
359
|
useEffect(() => {
|
|
350
360
|
fetchUserData(access_token)
|
|
351
361
|
}, [access_token])
|
|
362
|
+
|
|
363
|
+
useEffect(() => {
|
|
364
|
+
const collectPaymentData = async () => {
|
|
365
|
+
if (skipPage && !_isEmpty(ticketsQuantity)) {
|
|
366
|
+
setLoading(true)
|
|
367
|
+
const checkoutBody = createCheckoutDataBodyWithDefaultHolder(
|
|
368
|
+
ticketsQuantity.length,
|
|
369
|
+
userData
|
|
370
|
+
)
|
|
371
|
+
|
|
372
|
+
try {
|
|
373
|
+
const res = await postOnCheckout(checkoutBody, access_token)
|
|
374
|
+
onSkipBillingPage(_get(res, 'data.data.attributes'))
|
|
375
|
+
setLoading(false)
|
|
376
|
+
} catch (e) {
|
|
377
|
+
onSubmitError(e)
|
|
378
|
+
}
|
|
379
|
+
} else {
|
|
380
|
+
setLoading(false)
|
|
381
|
+
}
|
|
382
|
+
}
|
|
383
|
+
collectPaymentData()
|
|
384
|
+
}, [skipPage, ticketsQuantity])
|
|
385
|
+
|
|
386
|
+
|
|
387
|
+
const collectCheckoutBody = (values: object): object => {
|
|
388
|
+
let checkoutBody = {}
|
|
389
|
+
|
|
390
|
+
// Auto collect ticket holders name when it was skipped optionally
|
|
391
|
+
if (showDOB && !showTicketHolders && canSkipHolderNames) {
|
|
392
|
+
checkoutBody = createCheckoutDataBodyWithDefaultHolder(
|
|
393
|
+
ticketsQuantity.length,
|
|
394
|
+
values,
|
|
395
|
+
true
|
|
396
|
+
)
|
|
397
|
+
} else {
|
|
398
|
+
checkoutBody = createCheckoutDataBody(
|
|
399
|
+
ticketsQuantity.length,
|
|
400
|
+
values,
|
|
401
|
+
{ emailLogged, firstNameLogged, lastNameLogged },
|
|
402
|
+
showDOB
|
|
403
|
+
)
|
|
404
|
+
}
|
|
405
|
+
|
|
406
|
+
return checkoutBody
|
|
407
|
+
}
|
|
408
|
+
|
|
409
|
+
// Displaying loader
|
|
410
|
+
if (loading) {
|
|
411
|
+
return (
|
|
412
|
+
<Backdrop sx={{ color: '#fff' }} open={true}>
|
|
413
|
+
<CircularProgress color="inherit" />
|
|
414
|
+
</Backdrop>
|
|
415
|
+
)
|
|
416
|
+
}
|
|
417
|
+
|
|
352
418
|
return (
|
|
353
419
|
<ThemeProvider theme={themeMui}>
|
|
354
420
|
<Formik
|
|
@@ -378,12 +444,8 @@ export const BillingInfoContainer = ({
|
|
|
378
444
|
)
|
|
379
445
|
}
|
|
380
446
|
}
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
values,
|
|
384
|
-
{ emailLogged, firstNameLogged, lastNameLogged },
|
|
385
|
-
showDOB
|
|
386
|
-
)
|
|
447
|
+
|
|
448
|
+
const checkoutBody = collectCheckoutBody(values)
|
|
387
449
|
const res = await postOnCheckout(checkoutBody, access_token)
|
|
388
450
|
await getPaymentData(res.data.data.attributes.hash)
|
|
389
451
|
handleSubmit(
|
|
@@ -452,12 +514,8 @@ export const BillingInfoContainer = ({
|
|
|
452
514
|
JSON.stringify(profileDataObj)
|
|
453
515
|
)
|
|
454
516
|
}
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
values,
|
|
458
|
-
{ emailLogged, firstNameLogged, lastNameLogged },
|
|
459
|
-
showDOB
|
|
460
|
-
)
|
|
517
|
+
|
|
518
|
+
const checkoutBody = collectCheckoutBody(values)
|
|
461
519
|
const res = await postOnCheckout(
|
|
462
520
|
checkoutBody,
|
|
463
521
|
access_token_register
|
|
@@ -51,6 +51,11 @@ export const LoginModal: FC<Props> = ({
|
|
|
51
51
|
modalClassname = '',
|
|
52
52
|
}) => {
|
|
53
53
|
const [error, setError] = useState('')
|
|
54
|
+
const handleForgotPassword = () => {
|
|
55
|
+
if (typeof window !== 'undefined') {
|
|
56
|
+
window.open(`${CONFIGS.BASE_URL}/password-restore/`)
|
|
57
|
+
}
|
|
58
|
+
}
|
|
54
59
|
return (
|
|
55
60
|
<Modal
|
|
56
61
|
open={true}
|
|
@@ -190,6 +195,9 @@ export const LoginModal: FC<Props> = ({
|
|
|
190
195
|
<div className="login-action-button">
|
|
191
196
|
<button type="submit">Login</button>
|
|
192
197
|
</div>
|
|
198
|
+
<div className='forgot-password'>
|
|
199
|
+
<span onClick={handleForgotPassword}>Forgot password?</span>
|
|
200
|
+
</div>
|
|
193
201
|
</div>
|
|
194
202
|
</Form>
|
|
195
203
|
)}
|
|
@@ -4,7 +4,11 @@ import Container from '@mui/material/Container'
|
|
|
4
4
|
import CircularProgress from '@mui/material/CircularProgress'
|
|
5
5
|
import Alert from '@mui/material/Alert'
|
|
6
6
|
import { Elements } from '@stripe/react-stripe-js'
|
|
7
|
-
import {
|
|
7
|
+
import {
|
|
8
|
+
loadStripe,
|
|
9
|
+
StripeConstructorOptions,
|
|
10
|
+
StripeElementsOptions,
|
|
11
|
+
} from '@stripe/stripe-js'
|
|
8
12
|
import _map from 'lodash/map'
|
|
9
13
|
import _get from 'lodash/get'
|
|
10
14
|
import _identity from 'lodash/identity'
|
|
@@ -20,15 +24,14 @@ import { getPaymentData, handlePaymentSuccess, getConditions } from '../../api'
|
|
|
20
24
|
import { StripeCardNumberElementOptions } from '@stripe/stripe-js'
|
|
21
25
|
import { ThemeProvider, createTheme } from '@mui/material/styles'
|
|
22
26
|
import { ThemeOptions } from '@mui/material'
|
|
23
|
-
import { CSSProperties } from
|
|
27
|
+
import { CSSProperties } from '@mui/styles'
|
|
28
|
+
import TimerWidget from '../timerWidget'
|
|
24
29
|
|
|
25
30
|
const publishableKey = CONFIGS.STRIPE_PUBLISHABLE_KEY || ''
|
|
26
31
|
|
|
27
32
|
const getStripePromise = (reviewData: any) => {
|
|
28
|
-
const stripePublishableKey =
|
|
29
|
-
reviewData,
|
|
30
|
-
'payment_method.stripe_publishable_key'
|
|
31
|
-
) || publishableKey
|
|
33
|
+
const stripePublishableKey =
|
|
34
|
+
_get(reviewData, 'payment_method.stripe_publishable_key') || publishableKey
|
|
32
35
|
const stripeAccount = _get(
|
|
33
36
|
reviewData,
|
|
34
37
|
'payment_method.stripe_connected_account'
|
|
@@ -61,8 +64,13 @@ export interface IPaymentPage {
|
|
|
61
64
|
onPaymentError: (value: AxiosError) => void;
|
|
62
65
|
stripeCardOptions?: StripeCardNumberElementOptions;
|
|
63
66
|
disableZipSection: boolean;
|
|
64
|
-
themeOptions?: ThemeOptions & {
|
|
65
|
-
|
|
67
|
+
themeOptions?: ThemeOptions & {
|
|
68
|
+
input?: CSSProperties;
|
|
69
|
+
checkbox?: CSSProperties;
|
|
70
|
+
};
|
|
71
|
+
elementsOptions?: StripeElementsOptions;
|
|
72
|
+
onCountdownFinish?: () => void;
|
|
73
|
+
enableTimer?: boolean;
|
|
66
74
|
}
|
|
67
75
|
|
|
68
76
|
const initialOrderValues: IOrderData = {
|
|
@@ -96,7 +104,9 @@ export const PaymentContainer = ({
|
|
|
96
104
|
stripeCardOptions = {},
|
|
97
105
|
disableZipSection = false,
|
|
98
106
|
themeOptions,
|
|
99
|
-
elementsOptions
|
|
107
|
+
elementsOptions,
|
|
108
|
+
onCountdownFinish = () => {},
|
|
109
|
+
enableTimer = false,
|
|
100
110
|
}: IPaymentPage) => {
|
|
101
111
|
const [reviewData, setReviewData] = useState(initialReviewValues)
|
|
102
112
|
const [orderData, setOrderData] = useState(initialOrderValues)
|
|
@@ -193,6 +203,13 @@ export const PaymentContainer = ({
|
|
|
193
203
|
return (
|
|
194
204
|
<ThemeProvider theme={themeMui}>
|
|
195
205
|
<div className="payment_page">
|
|
206
|
+
{!paymentIsLoading && !error && enableTimer && (
|
|
207
|
+
<TimerWidget
|
|
208
|
+
expires_at={_get(reviewData, 'expires_at', 0)}
|
|
209
|
+
buyLoading={paymentIsLoading}
|
|
210
|
+
onCountdownFinish={onCountdownFinish}
|
|
211
|
+
/>
|
|
212
|
+
)}
|
|
196
213
|
{error && (
|
|
197
214
|
<Alert severity="error" onClose={onErrorClose} variant="filled">
|
|
198
215
|
{error}
|
|
@@ -229,7 +246,10 @@ export const PaymentContainer = ({
|
|
|
229
246
|
<p className="payment_info__error">{errorText}</p>
|
|
230
247
|
)}
|
|
231
248
|
<div>
|
|
232
|
-
<Elements
|
|
249
|
+
<Elements
|
|
250
|
+
stripe={getStripePromise(reviewData)}
|
|
251
|
+
options={elementsOptions}
|
|
252
|
+
>
|
|
233
253
|
<StripePayment
|
|
234
254
|
stripe_client_secret={_get(
|
|
235
255
|
reviewData,
|
|
@@ -25,18 +25,15 @@ export const TicketRow = ({
|
|
|
25
25
|
const soldOutMessage = ticketTier.soldOutMessage
|
|
26
26
|
? `${ticketTier.soldOutMessage}`.toUpperCase()
|
|
27
27
|
: 'SOLD OUT'
|
|
28
|
-
const isSalesClosed =
|
|
29
|
-
!ticketTier.salesStarted ||
|
|
30
|
-
ticketTier.salesEnded ||
|
|
31
|
-
!_has(ticketTier, 'maxQuantity') ||
|
|
32
|
-
ticketTier.maxQuantity === 0
|
|
28
|
+
const isSalesClosed = !ticketTier.salesStarted || ticketTier.salesEnded
|
|
33
29
|
const options = getTicketSelectOptions(
|
|
34
30
|
ticketTier.maxQuantity,
|
|
35
31
|
ticketTier.minQuantity,
|
|
36
32
|
ticketTier.multiplier
|
|
37
33
|
)
|
|
34
|
+
const ticketsClosedMessage = !ticketTier.salesStarted ? 'Sales not started' : 'Sales Ended'
|
|
38
35
|
|
|
39
|
-
const onSaleContent = isSalesClosed ?
|
|
36
|
+
const onSaleContent = isSalesClosed ? ticketsClosedMessage : (
|
|
40
37
|
<div className="get-tickets">
|
|
41
38
|
<Box className="get-tickets__selectbox">
|
|
42
39
|
<FormControl fullWidth>
|
|
@@ -75,9 +72,6 @@ export const TicketRow = ({
|
|
|
75
72
|
if (ticketTier.sold_out || !ticketTier.displayTicket || ticketTier.soldOut) {
|
|
76
73
|
returnValue = soldOutMessage
|
|
77
74
|
}
|
|
78
|
-
if (!+ticketTier.cost && !+ticketTier.price) {
|
|
79
|
-
returnValue = 'FREE'
|
|
80
|
-
}
|
|
81
75
|
if (ticketTier.displayTicket) {
|
|
82
76
|
returnValue = onSaleContent
|
|
83
77
|
}
|
|
@@ -38,6 +38,9 @@ export const TicketsSection = ({
|
|
|
38
38
|
ticketIsDiscounted = true
|
|
39
39
|
}
|
|
40
40
|
|
|
41
|
+
const ticketIsFree = (+ticket.cost || +ticket.price) === 0
|
|
42
|
+
const ticketPrice = isSoldOut ? 'SOLD OUT' : ticketIsFree ? 'FREE' : `$ ${(+ticket.cost || +ticket.price).toFixed(2)}`
|
|
43
|
+
|
|
41
44
|
return (
|
|
42
45
|
<div
|
|
43
46
|
key={ticket.id || ticket.name}
|
|
@@ -51,12 +54,8 @@ export const TicketsSection = ({
|
|
|
51
54
|
{ticketIsDiscounted && (
|
|
52
55
|
<p className="old-price">$ {(+ticket.oldPrice).toFixed(2)}</p>
|
|
53
56
|
)}
|
|
54
|
-
<p>
|
|
55
|
-
|
|
56
|
-
? 'SOLD OUT'
|
|
57
|
-
: `$ ${(+ticket.cost || +ticket.price).toFixed(2)}`}
|
|
58
|
-
</p>
|
|
59
|
-
{!isSoldOut && (
|
|
57
|
+
<p>{ticketPrice}</p>
|
|
58
|
+
{!isSoldOut && !ticketIsFree && (
|
|
60
59
|
<p className="fees">
|
|
61
60
|
{ticket.taxesIncluded ? '(incl. Fees)' : '(excl. Fees)'}
|
|
62
61
|
</p>
|
|
@@ -66,16 +65,12 @@ export const TicketsSection = ({
|
|
|
66
65
|
className="event-detail__tier-state"
|
|
67
66
|
style={{ minWidth: 55 }}
|
|
68
67
|
>
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
/>
|
|
76
|
-
) : (
|
|
77
|
-
<p className='ticket-not-started-message'>Sales not started</p>
|
|
78
|
-
)}
|
|
68
|
+
<TicketRow
|
|
69
|
+
ticketTier={ticket}
|
|
70
|
+
prevTicketTier={arr[i - 1]}
|
|
71
|
+
selectedTickets={selectedTickets}
|
|
72
|
+
handleTicketSelect={ticketSelect}
|
|
73
|
+
/>
|
|
79
74
|
</div>
|
|
80
75
|
</div>
|
|
81
76
|
</div>
|
|
@@ -59,6 +59,7 @@ export interface IGetTickets {
|
|
|
59
59
|
themeOptions?: ThemeOptions & { input?: CSSProperties; checkbox?: CSSProperties }
|
|
60
60
|
isAccessCodeEnabled?: boolean;
|
|
61
61
|
hideSessionButtons?: boolean;
|
|
62
|
+
hideWaitingList?: boolean;
|
|
62
63
|
}
|
|
63
64
|
|
|
64
65
|
export interface ITicket {
|
|
@@ -84,7 +85,8 @@ export const TicketsContainer = ({
|
|
|
84
85
|
isPromotionsEnabled = true,
|
|
85
86
|
themeOptions,
|
|
86
87
|
isAccessCodeEnabled = false,
|
|
87
|
-
hideSessionButtons = false
|
|
88
|
+
hideSessionButtons = false,
|
|
89
|
+
hideWaitingList = false
|
|
88
90
|
}: IGetTickets) => {
|
|
89
91
|
const [selectedTickets, setSelectedTickets] = useState(
|
|
90
92
|
{} as ISelectedTickets
|
|
@@ -118,7 +120,7 @@ export const TicketsContainer = ({
|
|
|
118
120
|
}, [])
|
|
119
121
|
|
|
120
122
|
useEffect(() => {
|
|
121
|
-
getTicketsApi()
|
|
123
|
+
!!eventId && getTicketsApi()
|
|
122
124
|
}, [eventId, promoCodeUpdated])
|
|
123
125
|
|
|
124
126
|
const handleLogout = () => {
|
|
@@ -244,10 +246,8 @@ export const TicketsContainer = ({
|
|
|
244
246
|
? window.localStorage.getItem('access_token') || ''
|
|
245
247
|
: ''
|
|
246
248
|
|
|
247
|
-
const ticketsQuantity = Object.keys(selectedTickets).length
|
|
248
|
-
|
|
249
249
|
const checkoutBody = createCheckoutDataBodyWithDefaultHolder(
|
|
250
|
-
|
|
250
|
+
ticketQuantity,
|
|
251
251
|
userData
|
|
252
252
|
)
|
|
253
253
|
|
|
@@ -337,7 +337,7 @@ export const TicketsContainer = ({
|
|
|
337
337
|
callback={updateTickets}
|
|
338
338
|
/>
|
|
339
339
|
) : null}
|
|
340
|
-
{showWaitingList && event.salesStarted && (
|
|
340
|
+
{showWaitingList && event.salesStarted && !hideWaitingList && (
|
|
341
341
|
<WaitingList tickets={tickets} eventId={eventId} />
|
|
342
342
|
)}
|
|
343
343
|
<PromoCodeSection
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import React, { useState } from 'react'
|
|
2
|
+
import Countdown from 'react-countdown'
|
|
3
|
+
import { showZero } from '../../utils/showZero'
|
|
4
|
+
import './style.css'
|
|
5
|
+
|
|
6
|
+
export interface ITimerWidgetPage {
|
|
7
|
+
expires_at: number;
|
|
8
|
+
buyLoading?: boolean;
|
|
9
|
+
onCountdownFinish?: () => void;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export interface IRenderer {
|
|
13
|
+
minutes: number;
|
|
14
|
+
seconds: number;
|
|
15
|
+
completed: number;
|
|
16
|
+
handleCountdownFinish: () => void;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
const TimerWidget = ({
|
|
20
|
+
expires_at,
|
|
21
|
+
buyLoading,
|
|
22
|
+
onCountdownFinish = () => {},
|
|
23
|
+
}: ITimerWidgetPage) => {
|
|
24
|
+
const [showTimer, setShowTimer] = useState(true)
|
|
25
|
+
|
|
26
|
+
const handleCountdownFinish = () => {
|
|
27
|
+
setShowTimer(false)
|
|
28
|
+
if (!buyLoading) {
|
|
29
|
+
onCountdownFinish()
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
const renderer = ({
|
|
34
|
+
minutes,
|
|
35
|
+
seconds,
|
|
36
|
+
completed,
|
|
37
|
+
handleCountdownFinish,
|
|
38
|
+
}: IRenderer) => {
|
|
39
|
+
if (completed) {
|
|
40
|
+
handleCountdownFinish()
|
|
41
|
+
return null
|
|
42
|
+
}
|
|
43
|
+
return (
|
|
44
|
+
<span>
|
|
45
|
+
{showZero(minutes)}:{showZero(seconds)}
|
|
46
|
+
</span>
|
|
47
|
+
)
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
return showTimer && !!expires_at ? (
|
|
51
|
+
<div className="timer">
|
|
52
|
+
<div className="toast-message">
|
|
53
|
+
<p>Please complete your purchase before the timer reaches zero.</p>
|
|
54
|
+
<p className="countdown">
|
|
55
|
+
<Countdown
|
|
56
|
+
date={Date.now() + expires_at * 1000}
|
|
57
|
+
renderer={(props: any) =>
|
|
58
|
+
renderer({
|
|
59
|
+
...props,
|
|
60
|
+
handleCountdownFinish,
|
|
61
|
+
})
|
|
62
|
+
}
|
|
63
|
+
/>
|
|
64
|
+
</p>
|
|
65
|
+
</div>
|
|
66
|
+
</div>
|
|
67
|
+
) : null
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
export default TimerWidget
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
.timer {
|
|
2
|
+
position: absolute;
|
|
3
|
+
pointer-events: auto;
|
|
4
|
+
background-color: #000000;
|
|
5
|
+
overflow: hidden;
|
|
6
|
+
margin: 0 0 6px;
|
|
7
|
+
padding: 15px 15px 15px 50px;
|
|
8
|
+
width: 300px;
|
|
9
|
+
-moz-border-radius: 3px;
|
|
10
|
+
-webkit-border-radius: 3px;
|
|
11
|
+
border-radius: 3px;
|
|
12
|
+
background-position: 15px center;
|
|
13
|
+
background-repeat: no-repeat;
|
|
14
|
+
-moz-box-shadow: 0 0 12px #999;
|
|
15
|
+
-webkit-box-shadow: 0 0 12px #999;
|
|
16
|
+
box-shadow: 0 0 12px #999;
|
|
17
|
+
max-width: 300px;
|
|
18
|
+
color: #fff;
|
|
19
|
+
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGwSURBVEhLtZa9SgNBEMc9sUxxRcoUKSzSWIhXpFMhhYWFhaBg4yPYiWCXZxBLERsLRS3EQkEfwCKdjWJAwSKCgoKCcudv4O5YLrt7EzgXhiU3/4+b2ckmwVjJSpKkQ6wAi4gwhT+z3wRBcEz0yjSseUTrcRyfsHsXmD0AmbHOC9Ii8VImnuXBPglHpQ5wwSVM7sNnTG7Za4JwDdCjxyAiH3nyA2mtaTJufiDZ5dCaqlItILh1NHatfN5skvjx9Z38m69CgzuXmZgVrPIGE763Jx9qKsRozWYw6xOHdER+nn2KkO+Bb+UV5CBN6WC6QtBgbRVozrahAbmm6HtUsgtPC19tFdxXZYBOfkbmFJ1VaHA1VAHjd0pp70oTZzvR+EVrx2Ygfdsq6eu55BHYR8hlcki+n+kERUFG8BrA0BwjeAv2M8WLQBtcy+SD6fNsmnB3AlBLrgTtVW1c2QN4bVWLATaIS60J2Du5y1TiJgjSBvFVZgTmwCU+dAZFoPxGEEs8nyHC9Bwe2GvEJv2WXZb0vjdyFT4Cxk3e/kIqlOGoVLwwPevpYHT+00T+hWwXDf4AJAOUqWcDhbwAAAAASUVORK5CYII=);
|
|
20
|
+
right: 15px;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.timer .countdown {
|
|
24
|
+
font-weight: bold;
|
|
25
|
+
margin-top: 10px;
|
|
26
|
+
}
|
|
@@ -15,7 +15,8 @@ interface IticketHolder {
|
|
|
15
15
|
|
|
16
16
|
export const createCheckoutDataBodyWithDefaultHolder = (
|
|
17
17
|
ticketsQuantity: number,
|
|
18
|
-
logedInValues: {}
|
|
18
|
+
logedInValues: {},
|
|
19
|
+
includeDob: boolean = false
|
|
19
20
|
): ICheckoutBody => {
|
|
20
21
|
const ticket_holders: IticketHolder[] = []
|
|
21
22
|
|
|
@@ -47,5 +48,12 @@ export const createCheckoutDataBodyWithDefaultHolder = (
|
|
|
47
48
|
},
|
|
48
49
|
}
|
|
49
50
|
|
|
51
|
+
if (includeDob) {
|
|
52
|
+
const holderAgeDate = new Date(_get(logedInValues, 'holderAge', ''))
|
|
53
|
+
body.attributes.dob_day = holderAgeDate.getDate()
|
|
54
|
+
body.attributes.dob_month = holderAgeDate.getMonth() + 1
|
|
55
|
+
body.attributes.dob_year = holderAgeDate.getFullYear()
|
|
56
|
+
}
|
|
57
|
+
|
|
50
58
|
return body
|
|
51
59
|
}
|