summit-registration-lite 2.0.0 → 2.0.3
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/.editorconfig +40 -0
- package/.nvmrc +1 -1
- package/.prettierrc +6 -0
- package/README.md +6 -0
- package/dist/index.css +6 -6
- package/dist/index.js +401 -155
- package/package.json +4 -3
package/.editorconfig
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# http://editorConfig.org
|
|
2
|
+
|
|
3
|
+
root = true
|
|
4
|
+
|
|
5
|
+
[*]
|
|
6
|
+
charset = utf-8
|
|
7
|
+
end_of_line = lf
|
|
8
|
+
indent_style = space
|
|
9
|
+
insert_final_newline = true
|
|
10
|
+
tab_width = 4
|
|
11
|
+
trim_trailing_whitespace = true
|
|
12
|
+
|
|
13
|
+
[{*.css,*.scss}]
|
|
14
|
+
indent_size = 2
|
|
15
|
+
|
|
16
|
+
[{*.js,*.jsx,*.tsx,*.ts,*.mjs}]
|
|
17
|
+
indent_size = 4
|
|
18
|
+
|
|
19
|
+
[*.json]
|
|
20
|
+
indent_size = 2
|
|
21
|
+
|
|
22
|
+
[*.md,*.mdx]
|
|
23
|
+
indent_size = 4
|
|
24
|
+
trim_trailing_whitespace = false
|
|
25
|
+
|
|
26
|
+
[*.mdx]
|
|
27
|
+
indent_size = 2
|
|
28
|
+
trim_trailing_whitespace = false
|
|
29
|
+
|
|
30
|
+
[.*rc]
|
|
31
|
+
indent_size = 2
|
|
32
|
+
|
|
33
|
+
[*.{yml,yaml}]
|
|
34
|
+
indent_size = 2
|
|
35
|
+
|
|
36
|
+
[Makefile]
|
|
37
|
+
indent_style = tab
|
|
38
|
+
|
|
39
|
+
[Dockerfile]
|
|
40
|
+
indent_size = 2
|
package/.nvmrc
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
14.19.1
|
package/.prettierrc
ADDED
package/README.md
CHANGED
|
@@ -14,6 +14,10 @@ React component for the summit registration lite widget
|
|
|
14
14
|
|
|
15
15
|
**supportEmail** = string with the email address for support
|
|
16
16
|
|
|
17
|
+
**allowsNativeAuth** = boolean to show/hide native auth
|
|
18
|
+
|
|
19
|
+
**allowsOtpAuth** = boolean to show/hide OTP auth
|
|
20
|
+
|
|
17
21
|
**loginOptions** = array with the options to show on the login screen
|
|
18
22
|
|
|
19
23
|
**loading** = boolean to show/hide a loader on the widget
|
|
@@ -42,6 +46,8 @@ React component for the summit registration lite widget
|
|
|
42
46
|
**loginWithCode** = method passed that will be called when the user tries to login with a code
|
|
43
47
|
|
|
44
48
|
**onPurchaseComplete** = method passed that will be called after the purchase of a ticket it's completed
|
|
49
|
+
|
|
50
|
+
**handleCompanyError** = method passed that will be called if the company dropdown can't be fetched
|
|
45
51
|
|
|
46
52
|
|
|
47
53
|
## PUBLISH TO NPM:
|
package/dist/index.css
CHANGED
|
@@ -2,17 +2,17 @@
|
|
|
2
2
|
|
|
3
3
|
:root{--color_primary: lightgray;--color_primary50: lightgray;--color_primary_contrast: #fff;--color_primary_contrast50: #ffffff50;--color_secondary: lightgray;--color_secondary_contrast: lightgray;--color_text_dark: #212121;--color_text_light: #ffffff;--color_text_input_hints: #212121}.step-wrapper{padding:10px;margin:10px;border:1px solid lightgray;border-radius:5px}.summit-registration-lite{color:var(--color_text_dark);font-size:15px}input{outline:none}
|
|
4
4
|
|
|
5
|
-
.loginWrapper___sxUEn{display:flex;justify-content:center;font-weight:bold;text-align:center;padding:20px 0 30px}.innerWrapper___GQRkq{display:flex;flex-direction:column;justify-content:center;width:300px}.innerWrapper___GQRkq span{margin:10px 0}.button___QMZPu{padding:10px 30px;background-color:red;color:white;font-weight:normal;display:inline-flex;justify-content:center;margin:5px 0;border-radius:5px;cursor:pointer;background-position:28px center;background-repeat:no-repeat;background-size:16px;line-height:1.4}.loginCode___dDBup{margin-bottom:10px;font-size:16px}.loginCode___dDBup>div{margin-top:10px}.loginCode___dDBup span{display:inline-block;font-weight:normal;font-size:14px;color:#e5424d}.input___QR9sA{display:flex;height:40px;margin-top:5px}.input___QR9sA input{border:1px solid var(--color_primary);border-radius:5px;padding:5px;width:100%}.input___QR9sA input::placeholder{color:var(--color_text_input_hints)}.input___QR9sA button{margin-left:5px;background-color:var(--color_secondary_contrast);padding:0px 15px;border:1px solid var(--color_secondary_contrast);color:#fff;box-shadow:none;text-align:center;white-space:nowrap;font-weight:bold;border-radius:5px;cursor:pointer;display:flex;align-items:center;justify-content:center}
|
|
5
|
+
.loginWrapper___sxUEn{display:flex;justify-content:center;font-weight:bold;text-align:center;padding:20px 0 30px}.innerWrapper___GQRkq{display:flex;flex-direction:column;justify-content:center;width:300px}.innerWrapper___GQRkq span{margin:10px 0}.button___QMZPu{padding:10px 30px;background-color:red;color:white;font-weight:normal;display:inline-flex;justify-content:center;margin:5px 0;border-radius:5px;cursor:pointer;background-position:28px center;background-repeat:no-repeat;background-size:16px;line-height:1.4;box-shadow:0px 3px 1px -2px rgba(0,0,0,0.2),0px 2px 2px 0px rgba(0,0,0,0.14),0px 1px 5px 0px rgba(0,0,0,0.12)}.button___QMZPu:hover{box-shadow:0px 2px 4px -1px rgba(0,0,0,0.2),0px 4px 5px 0px rgba(0,0,0,0.14),0px 1px 10px 0px rgba(0,0,0,0.12)}.loginCode___dDBup{margin-bottom:10px;font-size:16px}.loginCode___dDBup>div{margin-top:10px}.loginCode___dDBup span{display:inline-block;font-weight:normal;font-size:14px;color:#e5424d}.input___QR9sA{display:flex;height:40px;margin-top:5px}.input___QR9sA input{border:1px solid var(--color_primary);border-radius:5px;padding:5px;width:100%}.input___QR9sA input::placeholder{color:var(--color_text_input_hints)}.input___QR9sA button{margin-left:5px;background-color:var(--color_secondary_contrast);padding:0px 15px;border:1px solid var(--color_secondary_contrast);color:#fff;box-shadow:none;text-align:center;white-space:nowrap;font-weight:bold;border-radius:5px;cursor:pointer;display:flex;align-items:center;justify-content:center}
|
|
6
6
|
|
|
7
7
|
.title___LksVm{font-weight:bold;cursor:pointer}.form___v5GIx{display:flex;flex-wrap:wrap;justify-content:space-between;margin:10px 0}.form___v5GIx div.fieldWrapper___Eoe61{width:48%;border-radius:5px;background-color:#e6f3ff;border:1px solid #3fa2f7;height:36px;padding:5px;display:flex;justify-content:space-between;align-items:center;margin-bottom:5px}.form___v5GIx div.fieldWrapper___Eoe61:first-of-type{width:100%}.form___v5GIx div.fieldWrapper___Eoe61 input{width:100%;background-color:transparent;border:none}.form___v5GIx div.fieldWrapper___Eoe61 input:focus-visible{outline:none}.form___v5GIx div.fieldWrapper___Eoe61 i{position:relative;padding-right:5px}.form___v5GIx div.fieldWrapper___Eoe61>div{width:100%;padding-left:5px}.form___v5GIx div.fieldWrapper___Eoe61>div:first-of-type{width:95%}.form___v5GIx input{width:48%;border-radius:5px;border:1px solid #3fa2f7;color:#3486cd;font-size:16px;background-color:#e6f3ff;height:36px;padding:5px;display:flex;justify-content:space-between;align-items:center;margin-bottom:5px;font-weight:bold}.form___v5GIx input::placeholder{color:#3486cd}
|
|
8
8
|
|
|
9
|
-
.form___DoT3x{display:flex;flex-wrap:wrap;justify-content:space-between;margin:10px 0}.form___DoT3x div.fieldWrapper___wa1Ks{display:flex;width:48%;border-radius:5px;border:1px solid var(--color_primary);height:36px;padding:5px;display:flex;justify-content:space-between;align-items:center;margin-bottom:5px}.form___DoT3x div.fieldWrapper___wa1Ks:first-of-type{width:100%}.form___DoT3x div.fieldWrapper___wa1Ks:last-of-type{flex-direction:column}.form___DoT3x div.fieldWrapper___wa1Ks input{width:100%;background-color:transparent;border:none}.form___DoT3x div.fieldWrapper___wa1Ks input:focus-visible{outline:none}.form___DoT3x div.fieldWrapper___wa1Ks i{position:relative;padding-right:5px}.form___DoT3x div.fieldWrapper___wa1Ks>div{width:100%;padding-left:5px}.form___DoT3x div.fieldWrapper___wa1Ks>div:first-of-type{width:95%}.form___DoT3x div.fieldWrapper___wa1Ks span{display:inline-block;color:#e5424d;font-size:14px;align-self:flex-start}.form___DoT3x input{width:48%;border-radius:5px;color:#3486cd;font-size:16px;height:36px;padding:5px;display:flex;justify-content:space-between;align-items:center;margin-bottom:5px}.form___DoT3x input::placeholder{color:var(--color_text_input_hints);font-size:16px}
|
|
9
|
+
.form___DoT3x{display:flex;flex-wrap:wrap;justify-content:space-between;margin:10px 0}.form___DoT3x div.fieldWrapper___wa1Ks{display:flex;width:48%;border-radius:5px;border:1px solid var(--color_primary);height:36px;padding:5px;display:flex;justify-content:space-between;align-items:center;margin-bottom:5px}.form___DoT3x div.fieldWrapper___wa1Ks:first-of-type{width:100%}.form___DoT3x div.fieldWrapper___wa1Ks:last-of-type{flex-direction:column}.form___DoT3x div.fieldWrapper___wa1Ks input{width:100%;background-color:transparent;border:none;padding:0}.form___DoT3x div.fieldWrapper___wa1Ks input:focus-visible{outline:none}.form___DoT3x div.fieldWrapper___wa1Ks i{position:relative;padding-right:5px}.form___DoT3x div.fieldWrapper___wa1Ks>div{width:100%;padding-left:5px}.form___DoT3x div.fieldWrapper___wa1Ks>div:first-of-type{width:95%}.form___DoT3x div.fieldWrapper___wa1Ks span{display:inline-block;color:#e5424d;font-size:14px;align-self:flex-start}.form___DoT3x input{width:48%;border-radius:5px;color:#3486cd;font-size:16px;height:36px;padding:5px;display:flex;justify-content:space-between;align-items:center;margin-bottom:5px}.form___DoT3x input::placeholder{color:var(--color_text_input_hints);font-size:16px}
|
|
10
10
|
|
|
11
|
-
.title___ECoNz{font-weight:bold;cursor:pointer;display:flex;justify-content:space-between}.title___ECoNz div{font-weight:normal}.form___lDFka{display:flex;flex-wrap:wrap;justify-content:space-between;margin:10px 0}.form___lDFka
|
|
11
|
+
.title___ECoNz{font-weight:bold;cursor:pointer;display:flex;justify-content:space-between}.title___ECoNz div{font-weight:normal}.form___lDFka{display:flex;flex-wrap:wrap;justify-content:space-between;margin:10px 0 0}.form___lDFka>div{width:48%}.form___lDFka>div input{width:100%;border-radius:5px;border:1px solid var(--color_primary);height:36px;padding:5px;display:flex;justify-content:space-between;align-items:center;font-size:15px}.form___lDFka>div input::placeholder{color:var(--color_text_input_hints)}.form___lDFka>div .readOnly___WRazF{opacity:0.6;cursor:default}.form___lDFka>div span{display:inline-block;color:#e5424d}.form___lDFka>div>:last-child{margin-bottom:5px}.form___lDFka .companies___kmGFB{width:48%}.form___lDFka .companies___kmGFB>div{position:relative;width:100%;border-radius:5px;display:flex;justify-content:space-between;align-items:center;font-size:15px}.form___lDFka .companies___kmGFB>div::placeholder{color:var(--color_text_input_hints)}.form___lDFka .companies___kmGFB>div>div{height:100%;width:100%}.form___lDFka .companies___kmGFB>div>div>div{height:36px;padding:0px;border:1px solid var(--color_primary)}.form___lDFka .companies___kmGFB>div>div>div>div{height:36px}.form___lDFka .companies___kmGFB>div input{padding:5px;border:1px solid var(--color_primary);padding-right:0px !important;background-color:transparent}.form___lDFka .companies___kmGFB>div i{right:10px !important}.moreInfo___cQYdZ{display:inline-block;margin-top:10px}.moreInfoTooltip___lslgT{max-width:280px}.formErrors___dQQMe{margin-top:10px}.formErrors___dQQMe div+div{margin-top:10px}
|
|
12
12
|
|
|
13
|
-
.title___DNZyl{font-weight:bold;cursor:pointer;display:flex;justify-content:space-between}.summary___quWdZ{text-align:right}.crossOut___QZ7dy{text-decoration:line-through}.discount___sEK_Q{color:green}.promo___F8lPO{font-weight:bold;display:flex;justify-content:flex-end}.
|
|
13
|
+
.title___DNZyl{font-weight:bold;cursor:pointer;display:flex;justify-content:space-between}.summary___quWdZ{text-align:right}.crossOut___QZ7dy{text-decoration:line-through}.discount___sEK_Q{color:green}.promo___F8lPO{font-weight:bold;display:flex;justify-content:flex-end}.form___aoo7w{display:flex;gap:10px;margin-top:10px}.dropdown____HWg0{flex:1 1 auto}.quantity___SIEQZ{flex-shrink:0}.quantity___SIEQZ input,.quantity___SIEQZ button{height:36px;text-align:center;border:1px solid var(--color_primary)}.quantity___SIEQZ input{padding:0 8px;width:48px !important}.quantity___SIEQZ input,.quantity___SIEQZ input:read-only{color:inherit;background-color:#fff;border:1px solid var(--color_primary)}.quantity___SIEQZ button{display:flex;align-items:center}.quantity___SIEQZ button:disabled,.quantity___SIEQZ button:disabled:hover{opacity:0.65;background:#dedede;border-color:#bebebe}.soldOut___Hatfr{height:36px;padding:0 16px;line-height:34px;font-weight:700px;background:#dedede;border:solid 1px #bebebe;border-radius:5px;opacity:0.65;font-weight:700;flex-shrink:0}.moreInfo___LmwOe{display:inline-block;margin-top:10px}.moreInfoTooltip___nOBf1{max-width:280px}.inPersonDisclaimer___PXGTz{margin-top:15px}
|
|
14
14
|
|
|
15
|
-
.placeholder___pcdCn{border-radius:5px;width:100%;border:1px solid var(--color_primary);background-color:var(--color_primary50);padding:5px;cursor:pointer;display:flex;justify-content:space-between;align-items:center;
|
|
15
|
+
.placeholder___pcdCn{border-radius:5px;width:100%;border:1px solid var(--color_primary);background-color:var(--color_primary50);padding:5px;cursor:pointer;display:flex;justify-content:space-between;align-items:center;height:36px}.placeholder___pcdCn i{padding:2px 5px;border-left:1px solid var(--color_primary)}.inPersonDisclaimer___z_DzO{padding:4px}.dropdown___mfbPG{margin-top:10px;border-radius:5px;width:100%;border:1px solid var(--color_primary);cursor:pointer}.dropdown___mfbPG div{padding:5px}.dropdown___mfbPG div:hover{background-color:var(--color_primary);color:#fff}.soldOut___rBLC0,.soldOut___rBLC0:hover,.soldOut___rBLC0:focus{color:inherit !important;background-color:#dedede !important;opacity:0.65;cursor:not-allowed}
|
|
16
16
|
|
|
17
17
|
.button___MZBIY{background-color:var(--color_secondary_contrast) !important;color:#fff !important;border:none !important;font-weight:bold !important;font-size:1em !important;cursor:pointer !important}.button___MZBIY[disabled]{background-color:var(--color_secondary_contrast) !important}.button___MZBIY:hover{color:#fff !important}.button___MZBIY:active,.button___MZBIY:focus{color:#fff !important}.outerWrapper___XRnaq{padding:10px 0px 10px 10px;margin:10px}.outerWrapper___XRnaq .innerWrapper___LFsOH{display:flex;justify-content:space-between;align-items:center}.outerWrapper___XRnaq .innerWrapper___LFsOH span{font-size:14px}.outerWrapper___XRnaq .innerWrapper___LFsOH .registration___jdf6T{cursor:pointer;color:var(--color_primary);text-decoration:underline}.outerWrapper___XRnaq .innerWrapper___LFsOH .actions___Gsf0y{display:flex}.outerWrapper___XRnaq .innerWrapper___LFsOH .actions___Gsf0y button{margin-left:10px}
|
|
18
18
|
|
|
@@ -20,5 +20,5 @@
|
|
|
20
20
|
|
|
21
21
|
.passwordlessWrapper___BRQ_s{height:400px;display:flex;justify-content:center;align-items:center;flex-direction:column}.passwordlessWrapper___BRQ_s .innerWrapper___nRLDi{text-align:center;font-weight:bold;height:100%;width:300px;display:flex;flex-direction:column;justify-content:center}.passwordlessWrapper___BRQ_s .innerWrapper___nRLDi .digits___Vu5iy{margin-top:15px;display:inline-block}.passwordlessWrapper___BRQ_s .innerWrapper___nRLDi .codeInput___LnTZe{margin-top:20px;display:flex;justify-content:center}.passwordlessWrapper___BRQ_s .innerWrapper___nRLDi .codeInput___LnTZe input{height:56px;width:56px;font-size:42px;background-color:var(--color_primary50);border:1px solid var(--color_primary);border-radius:5px;padding:5px;display:inline-flex;text-transform:uppercase;text-align:center;margin:0 5px}.passwordlessWrapper___BRQ_s .innerWrapper___nRLDi .error___wZflZ{margin-top:10px;color:#e5424d;font-size:14px}.passwordlessWrapper___BRQ_s .innerWrapper___nRLDi .verify___IBgMl{margin-top:20px}.passwordlessWrapper___BRQ_s .innerWrapper___nRLDi .verify___IBgMl .button___nBhtQ{padding:10px 30px;font-weight:normal;justify-content:center;margin:5px 0;border-radius:5px;cursor:pointer;background-color:var(--color_secondary_contrast);color:#FFFFFF;width:100%;font-size:1em}.passwordlessWrapper___BRQ_s .innerWrapper___nRLDi .verify___IBgMl .link___f6fDT{color:var(--color_primary);text-decoration:underline;cursor:pointer}.passwordlessWrapper___BRQ_s .resend___Nma1U{margin:auto 0 0 0;font-weight:normal;font-size:14px}.passwordlessWrapper___BRQ_s .resend___Nma1U span{color:var(--color_primary);text-decoration:underline;cursor:pointer}
|
|
22
22
|
|
|
23
|
-
.
|
|
23
|
+
.ticketOwnedWrapper___nhkDY{margin:10px}.alert___c49oP{margin:0 !important}
|
|
24
24
|
|
package/dist/index.js
CHANGED
|
@@ -81,12 +81,16 @@ const storage_namespaceObject = require("redux-persist/es/storage");
|
|
|
81
81
|
var storage_default = /*#__PURE__*/__webpack_require__.n(storage_namespaceObject);
|
|
82
82
|
;// CONCATENATED MODULE: external "openstack-uicore-foundation/lib/utils/actions"
|
|
83
83
|
const actions_namespaceObject = require("openstack-uicore-foundation/lib/utils/actions");
|
|
84
|
-
;// CONCATENATED MODULE: external "openstack-uicore-foundation/lib/utils/methods"
|
|
85
|
-
const methods_namespaceObject = require("openstack-uicore-foundation/lib/utils/methods");
|
|
86
84
|
;// CONCATENATED MODULE: external "sweetalert2"
|
|
87
85
|
const external_sweetalert2_namespaceObject = require("sweetalert2");
|
|
88
86
|
var external_sweetalert2_default = /*#__PURE__*/__webpack_require__.n(external_sweetalert2_namespaceObject);
|
|
89
87
|
;// CONCATENATED MODULE: ./src/actions.js
|
|
88
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
89
|
+
|
|
90
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
91
|
+
|
|
92
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
93
|
+
|
|
90
94
|
/**
|
|
91
95
|
* Copyright 2020 OpenStack Foundation
|
|
92
96
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
@@ -130,8 +134,8 @@ const loadSession = settings => dispatch => {
|
|
|
130
134
|
/* TICKETS */
|
|
131
135
|
|
|
132
136
|
/*********************************************************************************/
|
|
133
|
-
// api/v1/summits/{id}/ticket-types
|
|
134
|
-
// api/v1/summits/{id}/tax-types
|
|
137
|
+
// api/v1/summits/{id}/ticket-types
|
|
138
|
+
// api/v1/summits/{id}/tax-types
|
|
135
139
|
|
|
136
140
|
const getTicketTypes = summitId => async (dispatch, getState, {
|
|
137
141
|
apiBaseUrl,
|
|
@@ -144,7 +148,7 @@ const getTicketTypes = summitId => async (dispatch, getState, {
|
|
|
144
148
|
access_token: accessToken
|
|
145
149
|
};
|
|
146
150
|
dispatch(startWidgetLoading());
|
|
147
|
-
return (0,actions_namespaceObject.getRequest)(null, (0,actions_namespaceObject.createAction)(GET_TICKET_TYPES), `${apiBaseUrl}/api/v1/summits/${summitId}/ticket-types`,
|
|
151
|
+
return (0,actions_namespaceObject.getRequest)(null, (0,actions_namespaceObject.createAction)(GET_TICKET_TYPES), `${apiBaseUrl}/api/v1/summits/${summitId}/ticket-types`, actions_namespaceObject.authErrorHandler)(params)(dispatch).then(() => {
|
|
148
152
|
dispatch(stopWidgetLoading());
|
|
149
153
|
});
|
|
150
154
|
} catch (e) {
|
|
@@ -161,14 +165,20 @@ const getTaxesTypes = summitId => async (dispatch, getState, {
|
|
|
161
165
|
access_token: accessToken
|
|
162
166
|
};
|
|
163
167
|
dispatch(startWidgetLoading());
|
|
164
|
-
return (0,actions_namespaceObject.getRequest)(null, (0,actions_namespaceObject.createAction)(GET_TAX_TYPES), `${apiBaseUrl}/api/v1/summits/${summitId}/tax-types`,
|
|
168
|
+
return (0,actions_namespaceObject.getRequest)(null, (0,actions_namespaceObject.createAction)(GET_TAX_TYPES), `${apiBaseUrl}/api/v1/summits/${summitId}/tax-types`, actions_namespaceObject.authErrorHandler)(params)(dispatch).then(() => {
|
|
165
169
|
dispatch(stopWidgetLoading());
|
|
166
170
|
});
|
|
167
171
|
} catch (e) {
|
|
168
172
|
return Promise.reject();
|
|
169
173
|
}
|
|
170
174
|
};
|
|
171
|
-
const reserveTicket = (
|
|
175
|
+
const reserveTicket = ({
|
|
176
|
+
personalInformation,
|
|
177
|
+
ticket,
|
|
178
|
+
ticketQuantity
|
|
179
|
+
}, {
|
|
180
|
+
onError
|
|
181
|
+
}) => async (dispatch, getState, {
|
|
172
182
|
apiBaseUrl,
|
|
173
183
|
getAccessToken
|
|
174
184
|
}) => {
|
|
@@ -188,24 +198,31 @@ const reserveTicket = (personalInformation, ticket) => async (dispatch, getState
|
|
|
188
198
|
} = personalInformation;
|
|
189
199
|
dispatch(startWidgetLoading());
|
|
190
200
|
const access_token = await getAccessToken();
|
|
201
|
+
const tickets = [...Array(ticketQuantity)].map(() => ({
|
|
202
|
+
type_id: ticket.id,
|
|
203
|
+
promo_code: promoCode || null,
|
|
204
|
+
attendee_first_name: firstName,
|
|
205
|
+
attendee_last_name: lastName,
|
|
206
|
+
attendee_email: email
|
|
207
|
+
}));
|
|
191
208
|
let params = {
|
|
192
209
|
access_token,
|
|
193
210
|
expand: 'tickets,tickets.owner,tickets.ticket_type,tickets.ticket_type.taxes'
|
|
194
211
|
};
|
|
195
|
-
|
|
212
|
+
const normalizedEntity = normalizeReservation({
|
|
196
213
|
owner_email: email,
|
|
197
214
|
owner_first_name: firstName,
|
|
198
215
|
owner_last_name: lastName,
|
|
199
216
|
owner_company: company,
|
|
200
|
-
tickets
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
}]
|
|
217
|
+
tickets
|
|
218
|
+
});
|
|
219
|
+
|
|
220
|
+
const errorHandler = (err, res) => (dispatch, state) => {
|
|
221
|
+
if (res && res.statusCode === 412 && onError) return onError(err, res);
|
|
222
|
+
return (0,actions_namespaceObject.authErrorHandler)(err, res);
|
|
207
223
|
};
|
|
208
|
-
|
|
224
|
+
|
|
225
|
+
return (0,actions_namespaceObject.postRequest)((0,actions_namespaceObject.createAction)(CREATE_RESERVATION), (0,actions_namespaceObject.createAction)(CREATE_RESERVATION_SUCCESS), `${apiBaseUrl}/api/v1/summits/${summitId}/orders/reserve`, normalizedEntity, errorHandler // entity
|
|
209
226
|
)(params)(dispatch).then(payload => {
|
|
210
227
|
dispatch(stopWidgetLoading());
|
|
211
228
|
payload.response.promo_code = promoCode || null;
|
|
@@ -243,7 +260,7 @@ const removeReservedTicket = () => async (dispatch, getState, {
|
|
|
243
260
|
expand: 'tickets,tickets.owner'
|
|
244
261
|
};
|
|
245
262
|
dispatch(startWidgetLoading());
|
|
246
|
-
return (0,actions_namespaceObject.deleteRequest)((0,actions_namespaceObject.createAction)(DELETE_RESERVATION), (0,actions_namespaceObject.createAction)(DELETE_RESERVATION_SUCCESS), `${apiBaseUrl}/api/v1/summits/${summitId}/orders/${hash}`, {},
|
|
263
|
+
return (0,actions_namespaceObject.deleteRequest)((0,actions_namespaceObject.createAction)(DELETE_RESERVATION), (0,actions_namespaceObject.createAction)(DELETE_RESERVATION_SUCCESS), `${apiBaseUrl}/api/v1/summits/${summitId}/orders/${hash}`, {}, actions_namespaceObject.authErrorHandler // entity
|
|
247
264
|
)(params)(dispatch).then(payload => {
|
|
248
265
|
dispatch(stopWidgetLoading());
|
|
249
266
|
dispatch(changeStep(1));
|
|
@@ -295,13 +312,13 @@ const payTicket = (token = null, stripe = null, zipCode = null) => async (dispat
|
|
|
295
312
|
}
|
|
296
313
|
}).then(result => {
|
|
297
314
|
if (result.error) {
|
|
298
|
-
// Reserve error.message in your UI.
|
|
315
|
+
// Reserve error.message in your UI.
|
|
299
316
|
external_sweetalert2_default().fire(result.error.message, "Please retry purchase.", "warning");
|
|
300
317
|
dispatch(changeStep(1));
|
|
301
318
|
dispatch(removeReservedTicket());
|
|
302
319
|
dispatch(stopWidgetLoading());
|
|
303
320
|
} else {
|
|
304
|
-
return (0,actions_namespaceObject.putRequest)(null, (0,actions_namespaceObject.createAction)(PAY_RESERVATION), `${apiBaseUrl}/api/v1/summits/${summitId}/orders/${reservation.hash}/checkout`, normalizedEntity,
|
|
321
|
+
return (0,actions_namespaceObject.putRequest)(null, (0,actions_namespaceObject.createAction)(PAY_RESERVATION), `${apiBaseUrl}/api/v1/summits/${summitId}/orders/${reservation.hash}/checkout`, normalizedEntity, actions_namespaceObject.authErrorHandler // entity
|
|
305
322
|
)(params)(dispatch).then(payload => {
|
|
306
323
|
dispatch(stopWidgetLoading());
|
|
307
324
|
dispatch((0,actions_namespaceObject.createAction)(CLEAR_RESERVATION)({}));
|
|
@@ -320,7 +337,7 @@ const payTicket = (token = null, stripe = null, zipCode = null) => async (dispat
|
|
|
320
337
|
});
|
|
321
338
|
} else {
|
|
322
339
|
// FREE TICKET
|
|
323
|
-
return (0,actions_namespaceObject.putRequest)(null, (0,actions_namespaceObject.createAction)(PAY_RESERVATION), `${apiBaseUrl}/api/v1/summits/${summitId}/orders/${reservation.hash}/checkout`, normalizedEntity,
|
|
340
|
+
return (0,actions_namespaceObject.putRequest)(null, (0,actions_namespaceObject.createAction)(PAY_RESERVATION), `${apiBaseUrl}/api/v1/summits/${summitId}/orders/${reservation.hash}/checkout`, normalizedEntity, actions_namespaceObject.authErrorHandler // entity
|
|
324
341
|
)(params)(dispatch).then(payload => {
|
|
325
342
|
dispatch(stopWidgetLoading());
|
|
326
343
|
dispatch((0,actions_namespaceObject.createAction)(CLEAR_RESERVATION)({}));
|
|
@@ -384,12 +401,25 @@ const isInPersonTicketType = ticketType => {
|
|
|
384
401
|
|
|
385
402
|
return false;
|
|
386
403
|
};
|
|
404
|
+
|
|
405
|
+
const normalizeReservation = entity => {
|
|
406
|
+
const normalizedEntity = _objectSpread({}, entity);
|
|
407
|
+
|
|
408
|
+
if (!entity.owner_company.id) {
|
|
409
|
+
normalizedEntity['owner_company'] = entity.owner_company.name;
|
|
410
|
+
} else {
|
|
411
|
+
delete normalizedEntity['owner_company'];
|
|
412
|
+
normalizedEntity['owner_company_id'] = entity.owner_company.id;
|
|
413
|
+
}
|
|
414
|
+
|
|
415
|
+
return normalizedEntity;
|
|
416
|
+
};
|
|
387
417
|
;// CONCATENATED MODULE: ./src/reducer.js
|
|
388
|
-
function
|
|
418
|
+
function reducer_ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
389
419
|
|
|
390
|
-
function
|
|
420
|
+
function reducer_objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? reducer_ownKeys(Object(source), !0).forEach(function (key) { reducer_defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : reducer_ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
391
421
|
|
|
392
|
-
function
|
|
422
|
+
function reducer_defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
393
423
|
|
|
394
424
|
/**
|
|
395
425
|
* Copyright 2020 OpenStack Foundation
|
|
@@ -434,14 +464,14 @@ const RegistrationLiteReducer = (state = DEFAULT_STATE, action) => {
|
|
|
434
464
|
switch (type) {
|
|
435
465
|
case START_WIDGET_LOADING:
|
|
436
466
|
{
|
|
437
|
-
return
|
|
467
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
438
468
|
widgetLoading: true
|
|
439
469
|
});
|
|
440
470
|
}
|
|
441
471
|
|
|
442
472
|
case STOP_WIDGET_LOADING:
|
|
443
473
|
{
|
|
444
|
-
return
|
|
474
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
445
475
|
widgetLoading: false
|
|
446
476
|
});
|
|
447
477
|
}
|
|
@@ -459,11 +489,11 @@ const RegistrationLiteReducer = (state = DEFAULT_STATE, action) => {
|
|
|
459
489
|
document.documentElement.style.setProperty(`--${setting}50`, `${marketingData[setting]}50`);
|
|
460
490
|
}
|
|
461
491
|
});
|
|
462
|
-
return
|
|
492
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
463
493
|
reservation: null,
|
|
464
494
|
checkout: null,
|
|
465
|
-
passwordless:
|
|
466
|
-
settings:
|
|
495
|
+
passwordless: reducer_objectSpread({}, DEFAULT_STATE.passwordless),
|
|
496
|
+
settings: reducer_objectSpread(reducer_objectSpread({}, DEFAULT_STATE.settings), {}, {
|
|
467
497
|
marketingData: marketingData,
|
|
468
498
|
summitId: summitData.id,
|
|
469
499
|
userProfile: profileData,
|
|
@@ -473,29 +503,29 @@ const RegistrationLiteReducer = (state = DEFAULT_STATE, action) => {
|
|
|
473
503
|
|
|
474
504
|
case CHANGE_STEP:
|
|
475
505
|
{
|
|
476
|
-
return
|
|
506
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
477
507
|
step: payload
|
|
478
508
|
});
|
|
479
509
|
}
|
|
480
510
|
|
|
481
511
|
case GET_TICKET_TYPES:
|
|
482
512
|
{
|
|
483
|
-
return
|
|
513
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
484
514
|
ticketTypes: payload.response.data
|
|
485
515
|
});
|
|
486
516
|
}
|
|
487
517
|
|
|
488
518
|
case GET_TAX_TYPES:
|
|
489
519
|
{
|
|
490
|
-
return
|
|
520
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
491
521
|
taxTypes: payload.response.data
|
|
492
522
|
});
|
|
493
523
|
}
|
|
494
524
|
|
|
495
525
|
case GO_TO_LOGIN:
|
|
496
526
|
{
|
|
497
|
-
return
|
|
498
|
-
passwordless:
|
|
527
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
528
|
+
passwordless: reducer_objectSpread(reducer_objectSpread({}, state.passwordless), {}, {
|
|
499
529
|
code_sent: false,
|
|
500
530
|
error: false
|
|
501
531
|
})
|
|
@@ -504,8 +534,8 @@ const RegistrationLiteReducer = (state = DEFAULT_STATE, action) => {
|
|
|
504
534
|
|
|
505
535
|
case SET_PASSWORDLESS_LOGIN:
|
|
506
536
|
{
|
|
507
|
-
return
|
|
508
|
-
passwordless:
|
|
537
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
538
|
+
passwordless: reducer_objectSpread(reducer_objectSpread({}, state.passwordless), {}, {
|
|
509
539
|
email: payload,
|
|
510
540
|
error: false
|
|
511
541
|
})
|
|
@@ -517,8 +547,8 @@ const RegistrationLiteReducer = (state = DEFAULT_STATE, action) => {
|
|
|
517
547
|
const {
|
|
518
548
|
otp_length
|
|
519
549
|
} = payload;
|
|
520
|
-
return
|
|
521
|
-
passwordless:
|
|
550
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
551
|
+
passwordless: reducer_objectSpread(reducer_objectSpread({}, state.passwordless), {}, {
|
|
522
552
|
otp_length,
|
|
523
553
|
code_sent: true,
|
|
524
554
|
error: false
|
|
@@ -528,8 +558,8 @@ const RegistrationLiteReducer = (state = DEFAULT_STATE, action) => {
|
|
|
528
558
|
|
|
529
559
|
case SET_PASSWORDLESS_ERROR:
|
|
530
560
|
{
|
|
531
|
-
return
|
|
532
|
-
passwordless:
|
|
561
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
562
|
+
passwordless: reducer_objectSpread(reducer_objectSpread({}, state.passwordless), {}, {
|
|
533
563
|
error: true
|
|
534
564
|
})
|
|
535
565
|
});
|
|
@@ -538,26 +568,26 @@ const RegistrationLiteReducer = (state = DEFAULT_STATE, action) => {
|
|
|
538
568
|
case CREATE_RESERVATION_SUCCESS:
|
|
539
569
|
{
|
|
540
570
|
const reservation = payload.response;
|
|
541
|
-
return
|
|
571
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
542
572
|
reservation
|
|
543
573
|
});
|
|
544
574
|
}
|
|
545
575
|
|
|
546
576
|
case DELETE_RESERVATION_SUCCESS:
|
|
547
|
-
return
|
|
577
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
548
578
|
reservation: null
|
|
549
579
|
});
|
|
550
580
|
|
|
551
581
|
case CLEAR_RESERVATION:
|
|
552
582
|
{
|
|
553
|
-
return
|
|
583
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
554
584
|
reservation: null
|
|
555
585
|
});
|
|
556
586
|
}
|
|
557
587
|
|
|
558
588
|
case PAY_RESERVATION:
|
|
559
589
|
{
|
|
560
|
-
return
|
|
590
|
+
return reducer_objectSpread(reducer_objectSpread({}, state), {}, {
|
|
561
591
|
checkout: payload.response,
|
|
562
592
|
reservation: null,
|
|
563
593
|
userProfile: null
|
|
@@ -653,7 +683,8 @@ const stripe_js_namespaceObject = require("@stripe/stripe-js");
|
|
|
653
683
|
|
|
654
684
|
const LoginComponent = ({
|
|
655
685
|
options,
|
|
656
|
-
|
|
686
|
+
allowsNativeAuth,
|
|
687
|
+
allowsOtpAuthlogin,
|
|
657
688
|
getLoginCode,
|
|
658
689
|
getPasswordlessCode
|
|
659
690
|
}) => {
|
|
@@ -694,23 +725,52 @@ const LoginComponent = ({
|
|
|
694
725
|
}, ">"), /*#__PURE__*/external_react_default().createElement("br", null)), emailError && /*#__PURE__*/external_react_default().createElement("span", {
|
|
695
726
|
"data-testid": "email-error"
|
|
696
727
|
}, "Please enter a valid email adress")), /*#__PURE__*/external_react_default().createElement("span", null, "Or you may signup or login with a social provider:"), options.map((o, index) => {
|
|
697
|
-
return /*#__PURE__*/external_react_default().createElement("div", {
|
|
728
|
+
return o.provider_param ? /*#__PURE__*/external_react_default().createElement("div", {
|
|
698
729
|
className: `${index_module.button}`,
|
|
699
|
-
key: `provider-${o.provider_param
|
|
730
|
+
key: `provider-${o.provider_param}`,
|
|
700
731
|
"data-testid": "login-button",
|
|
701
732
|
style: {
|
|
702
733
|
color: o.button_border_color ? o.button_border_color : '#ffffff',
|
|
703
734
|
border: `thin solid ${o.button_border_color ? o.button_border_color : o.button_color}`,
|
|
704
735
|
backgroundColor: o.button_color,
|
|
736
|
+
color: o.font_color,
|
|
705
737
|
backgroundImage: o.provider_logo ? `url(${o.provider_logo})` : 'none',
|
|
706
738
|
backgroundSize: o.provider_logo_size ? o.provider_logo_size : ''
|
|
707
739
|
},
|
|
708
740
|
onClick: () => login(o.provider_param)
|
|
709
|
-
}, o.provider_label)
|
|
710
|
-
|
|
741
|
+
}, o.provider_label) : allowsNativeAuth ? /*#__PURE__*/external_react_default().createElement("div", {
|
|
742
|
+
className: `${index_module.button}`,
|
|
743
|
+
key: `provider-fnid`,
|
|
744
|
+
"data-testid": "login-button",
|
|
745
|
+
style: {
|
|
746
|
+
color: o.button_border_color ? o.button_border_color : '#ffffff',
|
|
747
|
+
border: `thin solid ${o.button_border_color ? o.button_border_color : o.button_color}`,
|
|
748
|
+
backgroundColor: o.button_color,
|
|
749
|
+
color: o.font_color,
|
|
750
|
+
backgroundImage: o.provider_logo ? `url(${o.provider_logo})` : 'none',
|
|
751
|
+
backgroundSize: o.provider_logo_size ? o.provider_logo_size : ''
|
|
752
|
+
},
|
|
753
|
+
onClick: () => login(o.provider_param)
|
|
754
|
+
}, o.provider_label) : null;
|
|
755
|
+
}), allowsOtpAuthlogin && /*#__PURE__*/external_react_default().createElement("div", {
|
|
756
|
+
className: index_module.loginCode
|
|
757
|
+
}, "or get a login code emailed to you", /*#__PURE__*/external_react_default().createElement("div", {
|
|
758
|
+
className: index_module.input
|
|
759
|
+
}, /*#__PURE__*/external_react_default().createElement("input", {
|
|
760
|
+
placeholder: "youremail@example.com",
|
|
761
|
+
value: email,
|
|
762
|
+
onChange: e => setEmail(e.target.value),
|
|
763
|
+
onKeyPress: ev => ev.key === 'Enter' ? loginCode() : null,
|
|
764
|
+
"data-testid": "email-input"
|
|
765
|
+
}), /*#__PURE__*/external_react_default().createElement("button", {
|
|
766
|
+
onClick: () => loginCode(),
|
|
767
|
+
"data-testid": "email-button"
|
|
768
|
+
}, ">"), /*#__PURE__*/external_react_default().createElement("br", null)), emailError && /*#__PURE__*/external_react_default().createElement("span", {
|
|
769
|
+
"data-testid": "email-error"
|
|
770
|
+
}, "Please enter a valid email adress")))));
|
|
711
771
|
};
|
|
712
772
|
|
|
713
|
-
/* harmony default export */ const
|
|
773
|
+
/* harmony default export */ const components_login = (LoginComponent);
|
|
714
774
|
;// CONCATENATED MODULE: external "prop-types"
|
|
715
775
|
const external_prop_types_namespaceObject = require("prop-types");
|
|
716
776
|
;// CONCATENATED MODULE: external "@stripe/react-stripe-js"
|
|
@@ -924,11 +984,24 @@ const PaymentComponent = ({
|
|
|
924
984
|
};
|
|
925
985
|
|
|
926
986
|
/* harmony default export */ const payment = (PaymentComponent);
|
|
987
|
+
;// CONCATENATED MODULE: external "openstack-uicore-foundation/lib/components"
|
|
988
|
+
const components_namespaceObject = require("openstack-uicore-foundation/lib/components");
|
|
927
989
|
;// CONCATENATED MODULE: external "react-hook-form"
|
|
928
990
|
const external_react_hook_form_namespaceObject = require("react-hook-form");
|
|
991
|
+
;// CONCATENATED MODULE: external "react-tooltip"
|
|
992
|
+
const external_react_tooltip_namespaceObject = require("react-tooltip");
|
|
993
|
+
var external_react_tooltip_default = /*#__PURE__*/__webpack_require__.n(external_react_tooltip_namespaceObject);
|
|
994
|
+
;// CONCATENATED MODULE: ./src/helpers/capitalizeFirstLetter.js
|
|
995
|
+
const capitalizeFirstLetter = string => string.charAt(0).toUpperCase() + string.slice(1);
|
|
996
|
+
;// CONCATENATED MODULE: ./src/helpers/formatErrorMessage.js
|
|
997
|
+
|
|
998
|
+
const formatErrorMessage = string => {
|
|
999
|
+
const errorMessage = capitalizeFirstLetter(string);
|
|
1000
|
+
return `${errorMessage}${errorMessage.endsWith('.') ? '' : '.'}`;
|
|
1001
|
+
};
|
|
929
1002
|
;// CONCATENATED MODULE: ./src/components/personal-information/index.module.scss
|
|
930
1003
|
// extracted by mini-css-extract-plugin
|
|
931
|
-
/* harmony default export */ const personal_information_index_module = ({"title":"title___ECoNz","form":"form___lDFka","readOnly":"readOnly___WRazF"});
|
|
1004
|
+
/* harmony default export */ const personal_information_index_module = ({"title":"title___ECoNz","form":"form___lDFka","readOnly":"readOnly___WRazF","companies":"companies___kmGFB","moreInfo":"moreInfo___cQYdZ","moreInfoTooltip":"moreInfoTooltip___lslgT","formErrors":"formErrors___dQQMe"});
|
|
932
1005
|
;// CONCATENATED MODULE: ./src/components/personal-information/index.js
|
|
933
1006
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
934
1007
|
|
|
@@ -957,11 +1030,17 @@ function personal_information_defineProperty(obj, key, value) { if (key in obj)
|
|
|
957
1030
|
|
|
958
1031
|
|
|
959
1032
|
|
|
1033
|
+
|
|
1034
|
+
|
|
1035
|
+
|
|
960
1036
|
const PersonalInfoComponent = ({
|
|
961
1037
|
isActive,
|
|
962
1038
|
changeForm,
|
|
963
1039
|
reservation,
|
|
964
|
-
userProfile
|
|
1040
|
+
userProfile,
|
|
1041
|
+
summitId,
|
|
1042
|
+
handleCompanyError,
|
|
1043
|
+
formErrors
|
|
965
1044
|
}) => {
|
|
966
1045
|
var _errors$email, _errors$email2;
|
|
967
1046
|
|
|
@@ -969,9 +1048,13 @@ const PersonalInfoComponent = ({
|
|
|
969
1048
|
firstName: userProfile.given_name || '',
|
|
970
1049
|
lastName: userProfile.family_name || '',
|
|
971
1050
|
email: userProfile.email || '',
|
|
972
|
-
company:
|
|
1051
|
+
company: {
|
|
1052
|
+
id: null,
|
|
1053
|
+
name: userProfile.company || ''
|
|
1054
|
+
},
|
|
973
1055
|
promoCode: ''
|
|
974
1056
|
});
|
|
1057
|
+
const [companyError, setCompanyError] = (0,external_react_namespaceObject.useState)(false);
|
|
975
1058
|
const {
|
|
976
1059
|
register,
|
|
977
1060
|
handleSubmit,
|
|
@@ -985,14 +1068,30 @@ const PersonalInfoComponent = ({
|
|
|
985
1068
|
firstName: reservation.owner_first_name ? reservation.owner_first_name : personalInfo.firstName,
|
|
986
1069
|
lastName: reservation.owner_last_name ? reservation.owner_last_name : personalInfo.lastName,
|
|
987
1070
|
email: reservation.owner_email ? reservation.owner_email : personalInfo.email,
|
|
988
|
-
company:
|
|
1071
|
+
company: {
|
|
1072
|
+
id: null,
|
|
1073
|
+
name: reservation.owner_company ? reservation.owner_company : personalInfo.company
|
|
1074
|
+
}
|
|
989
1075
|
});
|
|
990
1076
|
}
|
|
991
1077
|
}, []);
|
|
992
1078
|
|
|
1079
|
+
const onCompanyChange = ev => {
|
|
1080
|
+
const newCompany = ev.target.value;
|
|
1081
|
+
setCompanyError(false);
|
|
1082
|
+
setPersonalInfo(personal_information_objectSpread(personal_information_objectSpread({}, personalInfo), {}, {
|
|
1083
|
+
company: newCompany
|
|
1084
|
+
}));
|
|
1085
|
+
};
|
|
1086
|
+
|
|
993
1087
|
const onSubmit = data => {
|
|
994
|
-
|
|
995
|
-
|
|
1088
|
+
if (!personalInfo.company.name) {
|
|
1089
|
+
setCompanyError(true);
|
|
1090
|
+
return;
|
|
1091
|
+
}
|
|
1092
|
+
|
|
1093
|
+
setPersonalInfo(personal_information_objectSpread(personal_information_objectSpread({}, personalInfo), data));
|
|
1094
|
+
changeForm(personal_information_objectSpread(personal_information_objectSpread({}, personalInfo), data));
|
|
996
1095
|
};
|
|
997
1096
|
|
|
998
1097
|
const [ref, {
|
|
@@ -1008,8 +1107,7 @@ const PersonalInfoComponent = ({
|
|
|
1008
1107
|
},
|
|
1009
1108
|
to: {
|
|
1010
1109
|
opacity: 1,
|
|
1011
|
-
height: isActive ? height + 10 : 0
|
|
1012
|
-
marginBottom: isActive ? 5 : 0
|
|
1110
|
+
height: isActive ? height + 10 : 0
|
|
1013
1111
|
}
|
|
1014
1112
|
});
|
|
1015
1113
|
return /*#__PURE__*/external_react_default().createElement("div", {
|
|
@@ -1020,7 +1118,7 @@ const PersonalInfoComponent = ({
|
|
|
1020
1118
|
className: personal_information_index_module.title
|
|
1021
1119
|
}, /*#__PURE__*/external_react_default().createElement("span", null, "Personal Information"), !isActive && /*#__PURE__*/external_react_default().createElement("div", {
|
|
1022
1120
|
"data-testid": "personal-info"
|
|
1023
|
-
}, /*#__PURE__*/external_react_default().createElement("span", null, `${personalInfo.firstName} ${personalInfo.lastName} ${personalInfo.company ? `- ${personalInfo.company}` : ''}`), /*#__PURE__*/external_react_default().createElement("br", null), /*#__PURE__*/external_react_default().createElement("span", null, personalInfo.email))), /*#__PURE__*/external_react_default().createElement(external_react_spring_namespaceObject.animated.div, {
|
|
1121
|
+
}, /*#__PURE__*/external_react_default().createElement("span", null, `${personalInfo.firstName} ${personalInfo.lastName} ${personalInfo.company.name ? `- ${personalInfo.company.name}` : ''}`), /*#__PURE__*/external_react_default().createElement("br", null), /*#__PURE__*/external_react_default().createElement("span", null, personalInfo.email))), /*#__PURE__*/external_react_default().createElement(external_react_spring_namespaceObject.animated.div, {
|
|
1024
1122
|
style: personal_information_objectSpread({
|
|
1025
1123
|
overflow: 'hidden'
|
|
1026
1124
|
}, toggleAnimation)
|
|
@@ -1068,20 +1166,35 @@ const PersonalInfoComponent = ({
|
|
|
1068
1166
|
"data-testid": "email-error-required"
|
|
1069
1167
|
}, "This field is required"), ((_errors$email2 = errors.email) === null || _errors$email2 === void 0 ? void 0 : _errors$email2.type) === 'pattern' && /*#__PURE__*/external_react_default().createElement("span", {
|
|
1070
1168
|
"data-testid": "email-error-invalid"
|
|
1071
|
-
}, "The email is invalid")), /*#__PURE__*/external_react_default().createElement("div",
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
})
|
|
1169
|
+
}, "The email is invalid")), /*#__PURE__*/external_react_default().createElement("div", {
|
|
1170
|
+
className: personal_information_index_module.companies
|
|
1171
|
+
}, /*#__PURE__*/external_react_default().createElement(components_namespaceObject.RegistrationCompanyInput, {
|
|
1172
|
+
id: "company",
|
|
1173
|
+
summitId: summitId,
|
|
1174
|
+
onChange: onCompanyChange,
|
|
1175
|
+
onError: handleCompanyError,
|
|
1176
|
+
value: personalInfo.company
|
|
1177
|
+
}), companyError && /*#__PURE__*/external_react_default().createElement("span", {
|
|
1080
1178
|
"data-testid": "company-error"
|
|
1081
1179
|
}, "This field is required")), /*#__PURE__*/external_react_default().createElement("div", null, /*#__PURE__*/external_react_default().createElement("input", _extends({
|
|
1082
1180
|
type: "text",
|
|
1083
1181
|
placeholder: "Promo Code"
|
|
1084
|
-
}, register("promoCode"))))))
|
|
1182
|
+
}, register("promoCode"))))), /*#__PURE__*/external_react_default().createElement("a", {
|
|
1183
|
+
className: personal_information_index_module.moreInfo,
|
|
1184
|
+
"data-tip": true,
|
|
1185
|
+
"data-for": "promo-code-info"
|
|
1186
|
+
}, /*#__PURE__*/external_react_default().createElement("i", {
|
|
1187
|
+
className: "glyphicon glyphicon-info-sign",
|
|
1188
|
+
"aria-hidden": "true"
|
|
1189
|
+
}), ` `, "Have multiple promo codes?"), /*#__PURE__*/external_react_default().createElement((external_react_tooltip_default()), {
|
|
1190
|
+
id: "promo-code-info"
|
|
1191
|
+
}, /*#__PURE__*/external_react_default().createElement("div", {
|
|
1192
|
+
className: personal_information_index_module.moreInfoTooltip
|
|
1193
|
+
}, "In order to use multiple promo codes, you may place a new registration order with the new promo code after you complete this order. This promo code will be applied to all tickets in this order.")), formErrors.length > 0 && /*#__PURE__*/external_react_default().createElement("div", {
|
|
1194
|
+
className: `${personal_information_index_module.formErrors} alert alert-danger`
|
|
1195
|
+
}, formErrors.map((error, index) => /*#__PURE__*/external_react_default().createElement("div", {
|
|
1196
|
+
key: index
|
|
1197
|
+
}, formatErrorMessage(error)))))))));
|
|
1085
1198
|
};
|
|
1086
1199
|
|
|
1087
1200
|
/* harmony default export */ const personal_information = (PersonalInfoComponent);
|
|
@@ -1090,10 +1203,12 @@ const raw_html_namespaceObject = require("openstack-uicore-foundation/lib/compon
|
|
|
1090
1203
|
var raw_html_default = /*#__PURE__*/__webpack_require__.n(raw_html_namespaceObject);
|
|
1091
1204
|
;// CONCATENATED MODULE: ./src/components/ticket-type/index.module.scss
|
|
1092
1205
|
// extracted by mini-css-extract-plugin
|
|
1093
|
-
/* harmony default export */ const ticket_type_index_module = ({"title":"title___DNZyl","summary":"summary___quWdZ","crossOut":"crossOut___QZ7dy","discount":"discount___sEK_Q","promo":"promo___F8lPO","dropdown":"dropdown____HWg0","inPersonDisclaimer":"inPersonDisclaimer___PXGTz"});
|
|
1206
|
+
/* harmony default export */ const ticket_type_index_module = ({"title":"title___DNZyl","summary":"summary___quWdZ","crossOut":"crossOut___QZ7dy","discount":"discount___sEK_Q","promo":"promo___F8lPO","form":"form___aoo7w","dropdown":"dropdown____HWg0","quantity":"quantity___SIEQZ","soldOut":"soldOut___Hatfr","moreInfo":"moreInfo___LmwOe","moreInfoTooltip":"moreInfoTooltip___nOBf1","inPersonDisclaimer":"inPersonDisclaimer___PXGTz"});
|
|
1207
|
+
;// CONCATENATED MODULE: ./src/helpers/getTicketMaxQuantity.js
|
|
1208
|
+
const getTicketMaxQuantity = ticket => ticket ? Math.min((ticket.quantity_2_sell || Number.MAX_SAFE_INTEGER) - ticket.quantity_sold, ticket.max_quantity_per_order || Number.MAX_SAFE_INTEGER) : 0;
|
|
1094
1209
|
;// CONCATENATED MODULE: ./src/components/ticket-dropdown/index.module.scss
|
|
1095
1210
|
// extracted by mini-css-extract-plugin
|
|
1096
|
-
/* harmony default export */ const ticket_dropdown_index_module = ({"placeholder":"placeholder___pcdCn","inPersonDisclaimer":"inPersonDisclaimer___z_DzO","dropdown":"dropdown___mfbPG"});
|
|
1211
|
+
/* harmony default export */ const ticket_dropdown_index_module = ({"placeholder":"placeholder___pcdCn","inPersonDisclaimer":"inPersonDisclaimer___z_DzO","dropdown":"dropdown___mfbPG","soldOut":"soldOut___rBLC0"});
|
|
1097
1212
|
;// CONCATENATED MODULE: ./src/components/ticket-dropdown/index.js
|
|
1098
1213
|
/**
|
|
1099
1214
|
* Copyright 2020 OpenStack Foundation
|
|
@@ -1111,6 +1226,7 @@ var raw_html_default = /*#__PURE__*/__webpack_require__.n(raw_html_namespaceObje
|
|
|
1111
1226
|
|
|
1112
1227
|
|
|
1113
1228
|
|
|
1229
|
+
|
|
1114
1230
|
const TicketDropdownComponent = ({
|
|
1115
1231
|
selectedTicket,
|
|
1116
1232
|
ticketTypes,
|
|
@@ -1143,16 +1259,52 @@ const TicketDropdownComponent = ({
|
|
|
1143
1259
|
className: ticket_dropdown_index_module.dropdown,
|
|
1144
1260
|
"data-testid": "ticket-list"
|
|
1145
1261
|
}, ticketTypes.map(t => {
|
|
1146
|
-
|
|
1262
|
+
const maxQuantity = getTicketMaxQuantity(t);
|
|
1263
|
+
const isTicketSoldOut = maxQuantity < 1;
|
|
1264
|
+
|
|
1265
|
+
if (t.sales_start_date === null && t.sales_end_date === null || now_utc >= t.sales_start_date && now_utc <= t.sales_end_date) {
|
|
1147
1266
|
return /*#__PURE__*/external_react_default().createElement("div", {
|
|
1148
1267
|
key: t.id,
|
|
1149
|
-
|
|
1150
|
-
|
|
1268
|
+
className: isTicketSoldOut ? ticket_dropdown_index_module.soldOut : '',
|
|
1269
|
+
onClick: () => {
|
|
1270
|
+
if (isTicketSoldOut) return;
|
|
1271
|
+
ticketSelect(t);
|
|
1272
|
+
}
|
|
1273
|
+
}, t.name, " -", ` `, !isTicketSoldOut && /*#__PURE__*/external_react_default().createElement((external_react_default()).Fragment, null, "$", t.cost, " ", t.currency), isTicketSoldOut && /*#__PURE__*/external_react_default().createElement((external_react_default()).Fragment, null, "Sold Out"));
|
|
1151
1274
|
}
|
|
1152
1275
|
})));
|
|
1153
1276
|
};
|
|
1154
1277
|
|
|
1155
1278
|
/* harmony default export */ const ticket_dropdown = (TicketDropdownComponent);
|
|
1279
|
+
;// CONCATENATED MODULE: ./src/helpers/formatCurrency.js
|
|
1280
|
+
const _excluded = ["locale"];
|
|
1281
|
+
|
|
1282
|
+
function formatCurrency_ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
1283
|
+
|
|
1284
|
+
function formatCurrency_objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? formatCurrency_ownKeys(Object(source), !0).forEach(function (key) { formatCurrency_defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : formatCurrency_ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
1285
|
+
|
|
1286
|
+
function formatCurrency_defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
1287
|
+
|
|
1288
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
1289
|
+
|
|
1290
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
1291
|
+
|
|
1292
|
+
const formatCurrency = (value, _ref) => {
|
|
1293
|
+
let {
|
|
1294
|
+
locale = 'en-US'
|
|
1295
|
+
} = _ref,
|
|
1296
|
+
options = _objectWithoutProperties(_ref, _excluded);
|
|
1297
|
+
|
|
1298
|
+
const defaultOptions = {
|
|
1299
|
+
currency: 'USD',
|
|
1300
|
+
minimumFractionDigits: 0,
|
|
1301
|
+
maximumFractionDigits: 0
|
|
1302
|
+
};
|
|
1303
|
+
const formatter = new Intl.NumberFormat(locale, formatCurrency_objectSpread(formatCurrency_objectSpread({
|
|
1304
|
+
style: 'currency'
|
|
1305
|
+
}, defaultOptions), options));
|
|
1306
|
+
return formatter.format(value);
|
|
1307
|
+
};
|
|
1156
1308
|
;// CONCATENATED MODULE: ./src/components/ticket-type/index.js
|
|
1157
1309
|
function ticket_type_ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
1158
1310
|
|
|
@@ -1180,15 +1332,20 @@ function ticket_type_defineProperty(obj, key, value) { if (key in obj) { Object.
|
|
|
1180
1332
|
|
|
1181
1333
|
|
|
1182
1334
|
|
|
1335
|
+
|
|
1336
|
+
|
|
1337
|
+
|
|
1183
1338
|
const TicketTypeComponent = ({
|
|
1184
1339
|
ticketTypes,
|
|
1185
|
-
taxTypes,
|
|
1186
1340
|
isActive,
|
|
1187
1341
|
changeForm,
|
|
1188
1342
|
reservation,
|
|
1189
1343
|
inPersonDisclaimer
|
|
1190
1344
|
}) => {
|
|
1191
1345
|
const [ticket, setTicket] = (0,external_react_namespaceObject.useState)(null);
|
|
1346
|
+
const [quantity, setQuantity] = (0,external_react_namespaceObject.useState)(1);
|
|
1347
|
+
const minQuantity = 1;
|
|
1348
|
+
const maxQuantity = getTicketMaxQuantity(ticket);
|
|
1192
1349
|
const [ref, {
|
|
1193
1350
|
height
|
|
1194
1351
|
}] = (0,external_react_use_namespaceObject.useMeasure)();
|
|
@@ -1202,8 +1359,7 @@ const TicketTypeComponent = ({
|
|
|
1202
1359
|
},
|
|
1203
1360
|
to: {
|
|
1204
1361
|
opacity: 1,
|
|
1205
|
-
height: isActive ? height + 10 : 0
|
|
1206
|
-
marginBottom: isActive ? 5 : 0
|
|
1362
|
+
height: isActive ? height + 10 : 0
|
|
1207
1363
|
}
|
|
1208
1364
|
});
|
|
1209
1365
|
(0,external_react_namespaceObject.useEffect)(() => {
|
|
@@ -1214,39 +1370,97 @@ const TicketTypeComponent = ({
|
|
|
1214
1370
|
}
|
|
1215
1371
|
}, []);
|
|
1216
1372
|
(0,external_react_namespaceObject.useEffect)(() => {
|
|
1217
|
-
changeForm(
|
|
1218
|
-
|
|
1373
|
+
changeForm({
|
|
1374
|
+
ticketType: ticket,
|
|
1375
|
+
ticketQuantity: quantity
|
|
1376
|
+
});
|
|
1377
|
+
}, [ticket, quantity]);
|
|
1219
1378
|
|
|
1220
|
-
const
|
|
1379
|
+
const handleTicketChange = t => {
|
|
1221
1380
|
setTicket(t);
|
|
1381
|
+
setQuantity(minQuantity);
|
|
1222
1382
|
};
|
|
1223
1383
|
|
|
1384
|
+
const incrementQuantity = () => setQuantity(quantity + 1);
|
|
1385
|
+
|
|
1386
|
+
const decrementQuantity = () => setQuantity(quantity - 1);
|
|
1387
|
+
|
|
1224
1388
|
return /*#__PURE__*/external_react_default().createElement("div", {
|
|
1225
1389
|
className: `${ticket_type_index_module.outerWrapper} step-wrapper`
|
|
1226
1390
|
}, /*#__PURE__*/external_react_default().createElement((external_react_default()).Fragment, null, /*#__PURE__*/external_react_default().createElement("div", {
|
|
1227
|
-
className:
|
|
1391
|
+
className: ticket_type_index_module.innerWrapper
|
|
1228
1392
|
}, /*#__PURE__*/external_react_default().createElement("div", {
|
|
1229
1393
|
className: ticket_type_index_module.title
|
|
1230
|
-
}, /*#__PURE__*/external_react_default().createElement("span", null, "Ticket
|
|
1394
|
+
}, /*#__PURE__*/external_react_default().createElement("span", null, "Ticket"), /*#__PURE__*/external_react_default().createElement("div", {
|
|
1231
1395
|
className: ticket_type_index_module.summary
|
|
1232
|
-
}, !isActive && (reservation === null || reservation === void 0 ? void 0 : reservation.discount_amount) > 0
|
|
1396
|
+
}, /*#__PURE__*/external_react_default().createElement("span", null, ticket && /*#__PURE__*/external_react_default().createElement((external_react_default()).Fragment, null, ticket.name, ` `, "(", quantity, "):", ` `, !isActive && (reservation === null || reservation === void 0 ? void 0 : reservation.discount_amount) > 0 && /*#__PURE__*/external_react_default().createElement((external_react_default()).Fragment, null, /*#__PURE__*/external_react_default().createElement("span", {
|
|
1233
1397
|
className: ticket_type_index_module.crossOut
|
|
1234
|
-
},
|
|
1398
|
+
}, formatCurrency(ticket.cost * quantity, {
|
|
1399
|
+
currency: ticket.currency
|
|
1400
|
+
})), ` `, /*#__PURE__*/external_react_default().createElement("span", {
|
|
1235
1401
|
className: ticket_type_index_module.discount
|
|
1236
|
-
},
|
|
1402
|
+
}, formatCurrency(reservation.raw_amount - reservation.discount_amount, {
|
|
1403
|
+
currency: ticket.currency
|
|
1404
|
+
})), ` `), !(reservation !== null && reservation !== void 0 && reservation.discount_amount) && /*#__PURE__*/external_react_default().createElement((external_react_default()).Fragment, null, formatCurrency(ticket.cost * quantity, {
|
|
1405
|
+
currency: ticket.currency
|
|
1406
|
+
}), ` `), ticket.currency, !isActive && (reservation === null || reservation === void 0 ? void 0 : reservation.discount_amount) > 0 && /*#__PURE__*/external_react_default().createElement("span", {
|
|
1237
1407
|
className: ticket_type_index_module.promo
|
|
1238
|
-
}, "Promo code applied")
|
|
1408
|
+
}, "Promo code applied"), !isActive && (reservation === null || reservation === void 0 ? void 0 : reservation.taxes_amount) > 0 && /*#__PURE__*/external_react_default().createElement((external_react_default()).Fragment, null, /*#__PURE__*/external_react_default().createElement("br", null), "Taxes: $", reservation === null || reservation === void 0 ? void 0 : reservation.taxes_amount, " ", ticket === null || ticket === void 0 ? void 0 : ticket.currency)), !ticket && /*#__PURE__*/external_react_default().createElement((external_react_default()).Fragment, null, "No ticket selected")))), /*#__PURE__*/external_react_default().createElement(external_react_spring_namespaceObject.animated.div, {
|
|
1239
1409
|
style: ticket_type_objectSpread({
|
|
1240
1410
|
overflow: 'hidden'
|
|
1241
1411
|
}, toggleAnimation)
|
|
1242
1412
|
}, /*#__PURE__*/external_react_default().createElement("div", {
|
|
1243
|
-
ref: ref
|
|
1413
|
+
ref: ref
|
|
1414
|
+
}, /*#__PURE__*/external_react_default().createElement("div", {
|
|
1415
|
+
className: ticket_type_index_module.form
|
|
1416
|
+
}, /*#__PURE__*/external_react_default().createElement("div", {
|
|
1244
1417
|
className: ticket_type_index_module.dropdown
|
|
1245
1418
|
}, /*#__PURE__*/external_react_default().createElement(ticket_dropdown, {
|
|
1246
1419
|
selectedTicket: ticket,
|
|
1247
1420
|
ticketTypes: ticketTypes,
|
|
1248
|
-
onTicketSelect:
|
|
1249
|
-
}))
|
|
1421
|
+
onTicketSelect: handleTicketChange
|
|
1422
|
+
})), ticket && /*#__PURE__*/external_react_default().createElement("div", {
|
|
1423
|
+
className: ticket_type_index_module.quantity
|
|
1424
|
+
}, /*#__PURE__*/external_react_default().createElement("div", {
|
|
1425
|
+
className: "input-group"
|
|
1426
|
+
}, /*#__PURE__*/external_react_default().createElement("span", {
|
|
1427
|
+
className: "input-group-btn"
|
|
1428
|
+
}, /*#__PURE__*/external_react_default().createElement("button", {
|
|
1429
|
+
"aria-label": "remove a ticket",
|
|
1430
|
+
className: "btn btn-default",
|
|
1431
|
+
onClick: decrementQuantity,
|
|
1432
|
+
disabled: maxQuantity === 0 || quantity === minQuantity
|
|
1433
|
+
}, /*#__PURE__*/external_react_default().createElement("i", {
|
|
1434
|
+
className: "fa fa-minus"
|
|
1435
|
+
}))), /*#__PURE__*/external_react_default().createElement("input", {
|
|
1436
|
+
className: "form-control",
|
|
1437
|
+
"aria-label": "ticket quanity",
|
|
1438
|
+
name: "ticket_quantity",
|
|
1439
|
+
type: "text",
|
|
1440
|
+
value: quantity,
|
|
1441
|
+
readOnly: true,
|
|
1442
|
+
disabled: maxQuantity === 0
|
|
1443
|
+
}), /*#__PURE__*/external_react_default().createElement("span", {
|
|
1444
|
+
className: "input-group-btn"
|
|
1445
|
+
}, /*#__PURE__*/external_react_default().createElement("button", {
|
|
1446
|
+
"aria-label": "add a ticket",
|
|
1447
|
+
className: "btn btn-default",
|
|
1448
|
+
onClick: incrementQuantity,
|
|
1449
|
+
disabled: maxQuantity === 0 || quantity >= maxQuantity
|
|
1450
|
+
}, /*#__PURE__*/external_react_default().createElement("i", {
|
|
1451
|
+
className: "glyphicon glyphicon-plus"
|
|
1452
|
+
})))))), /*#__PURE__*/external_react_default().createElement("a", {
|
|
1453
|
+
className: ticket_type_index_module.moreInfo,
|
|
1454
|
+
"data-tip": true,
|
|
1455
|
+
"data-for": "ticket-quantity-info"
|
|
1456
|
+
}, /*#__PURE__*/external_react_default().createElement("i", {
|
|
1457
|
+
className: "glyphicon glyphicon-info-sign",
|
|
1458
|
+
"aria-hidden": "true"
|
|
1459
|
+
}), ` `, "Need multiple ticket types?"), /*#__PURE__*/external_react_default().createElement((external_react_tooltip_default()), {
|
|
1460
|
+
id: "ticket-quantity-info"
|
|
1461
|
+
}, /*#__PURE__*/external_react_default().createElement("div", {
|
|
1462
|
+
className: ticket_type_index_module.moreInfoTooltip
|
|
1463
|
+
}, "In order to select multiple tickets of a different type, you may place a new registration order after you complete this order.")))), inPersonDisclaimer && ticket && isInPersonTicketType(ticket) && /*#__PURE__*/external_react_default().createElement("div", {
|
|
1250
1464
|
className: ticket_type_index_module.inPersonDisclaimer
|
|
1251
1465
|
}, /*#__PURE__*/external_react_default().createElement((raw_html_default()), null, inPersonDisclaimer)))));
|
|
1252
1466
|
};
|
|
@@ -1275,24 +1489,21 @@ const TicketTypeComponent = ({
|
|
|
1275
1489
|
const ButtonBarComponent = ({
|
|
1276
1490
|
step,
|
|
1277
1491
|
changeStep,
|
|
1278
|
-
|
|
1492
|
+
formValues,
|
|
1279
1493
|
removeReservedTicket,
|
|
1280
|
-
inPersonDisclaimer
|
|
1281
|
-
goToRegistration
|
|
1494
|
+
inPersonDisclaimer
|
|
1282
1495
|
}) => {
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1496
|
+
const {
|
|
1497
|
+
ticketType
|
|
1498
|
+
} = formValues || {};
|
|
1499
|
+
const nextButtonText = inPersonDisclaimer && ticketType && isInPersonTicketType(ticketType) ? 'Accept' : 'Next';
|
|
1286
1500
|
return /*#__PURE__*/external_react_default().createElement("div", {
|
|
1287
1501
|
className: `${button_bar_index_module.outerWrapper}`
|
|
1288
1502
|
}, step !== 3 && /*#__PURE__*/external_react_default().createElement((external_react_default()).Fragment, null, /*#__PURE__*/external_react_default().createElement("div", {
|
|
1289
1503
|
className: `${button_bar_index_module.innerWrapper}`
|
|
1290
1504
|
}, /*#__PURE__*/external_react_default().createElement("div", {
|
|
1291
1505
|
className: button_bar_index_module.required
|
|
1292
|
-
}, step !== 0 && /*#__PURE__*/external_react_default().createElement("span", null, "* Required fields ", /*#__PURE__*/external_react_default().createElement("br", null), " "), /*#__PURE__*/external_react_default().createElement("
|
|
1293
|
-
className: button_bar_index_module.registration,
|
|
1294
|
-
onClick: () => goToRegistration()
|
|
1295
|
-
}, "Need multiple tickets?")), /*#__PURE__*/external_react_default().createElement("div", {
|
|
1506
|
+
}, step !== 0 && /*#__PURE__*/external_react_default().createElement("span", null, "* Required fields ", /*#__PURE__*/external_react_default().createElement("br", null), " ")), /*#__PURE__*/external_react_default().createElement("div", {
|
|
1296
1507
|
className: button_bar_index_module.actions
|
|
1297
1508
|
}, step !== 0 && step !== 2 && /*#__PURE__*/external_react_default().createElement("button", {
|
|
1298
1509
|
className: `${button_bar_index_module.button} button`,
|
|
@@ -1301,14 +1512,14 @@ const ButtonBarComponent = ({
|
|
|
1301
1512
|
className: `${button_bar_index_module.button} button`,
|
|
1302
1513
|
onClick: () => removeReservedTicket()
|
|
1303
1514
|
}, "< Back"), step === 0 && /*#__PURE__*/external_react_default().createElement("button", {
|
|
1304
|
-
disabled: !
|
|
1515
|
+
disabled: !ticketType,
|
|
1305
1516
|
className: `${button_bar_index_module.button} button`,
|
|
1306
1517
|
onClick: () => changeStep(step + 1)
|
|
1307
|
-
}, nextButtonText), step === 1 && (
|
|
1518
|
+
}, nextButtonText), step === 1 && (ticketType === null || ticketType === void 0 ? void 0 : ticketType.cost) === 0 && /*#__PURE__*/external_react_default().createElement("button", {
|
|
1308
1519
|
className: `${button_bar_index_module.button} button`,
|
|
1309
1520
|
type: "submit",
|
|
1310
1521
|
form: "personal-info-form"
|
|
1311
|
-
}, "Get Ticket"), step === 1 && (
|
|
1522
|
+
}, "Get Ticket"), step === 1 && (ticketType === null || ticketType === void 0 ? void 0 : ticketType.cost) > 0 && /*#__PURE__*/external_react_default().createElement("button", {
|
|
1312
1523
|
className: `${button_bar_index_module.button} button`,
|
|
1313
1524
|
type: "submit",
|
|
1314
1525
|
form: "personal-info-form"
|
|
@@ -1323,6 +1534,8 @@ const ButtonBarComponent = ({
|
|
|
1323
1534
|
;// CONCATENATED MODULE: ./src/components/purchase-complete/index.module.scss
|
|
1324
1535
|
// extracted by mini-css-extract-plugin
|
|
1325
1536
|
/* harmony default export */ const purchase_complete_index_module = ({"button":"button___XMN8a","wrapper":"wrapper___Jd5Xg","circle":"circle___lcN86","complete":"complete___HAHzl","actions":"actions___jJdPX","footer":"footer___FL9TW"});
|
|
1537
|
+
;// CONCATENATED MODULE: external "openstack-uicore-foundation/lib/utils/methods"
|
|
1538
|
+
const methods_namespaceObject = require("openstack-uicore-foundation/lib/utils/methods");
|
|
1326
1539
|
;// CONCATENATED MODULE: ./src/components/purchase-complete/index.js
|
|
1327
1540
|
/**
|
|
1328
1541
|
* Copyright 2020 OpenStack Foundation
|
|
@@ -1489,7 +1702,7 @@ const PasswordlessLoginComponent = ({
|
|
|
1489
1702
|
/* harmony default export */ const login_passwordless = (PasswordlessLoginComponent);
|
|
1490
1703
|
;// CONCATENATED MODULE: ./src/components/ticket-owned/index.module.scss
|
|
1491
1704
|
// extracted by mini-css-extract-plugin
|
|
1492
|
-
/* harmony default export */ const ticket_owned_index_module = ({"
|
|
1705
|
+
/* harmony default export */ const ticket_owned_index_module = ({"ticketOwnedWrapper":"ticketOwnedWrapper___nhkDY","alert":"alert___c49oP"});
|
|
1493
1706
|
;// CONCATENATED MODULE: ./src/components/ticket-owned/index.js
|
|
1494
1707
|
/**
|
|
1495
1708
|
* Copyright 2020 OpenStack Foundation
|
|
@@ -1507,26 +1720,25 @@ const PasswordlessLoginComponent = ({
|
|
|
1507
1720
|
|
|
1508
1721
|
|
|
1509
1722
|
const TicketOwnedComponent = ({
|
|
1510
|
-
|
|
1723
|
+
ownedTickets,
|
|
1724
|
+
ticketTypes
|
|
1511
1725
|
}) => {
|
|
1726
|
+
const ownedTicketsString = (0,external_react_namespaceObject.useMemo)(() => ownedTickets.reduce((acc, ownedTicket) => {
|
|
1727
|
+
const ticketType = ticketTypes.find(type => type.id === ownedTicket.type_id);
|
|
1728
|
+
if (!ticketType) return acc;
|
|
1729
|
+
return `${acc}${acc ? ', ' : ''}${ownedTicket.qty} ${ticketType.name}${!ticketType.name.toLowerCase().endsWith('ticket') ? ' ticket' : ''}${ownedTicket.qty > 1 ? 's' : ''}`;
|
|
1730
|
+
}, ''), [ownedTickets, ticketTypes]);
|
|
1512
1731
|
return /*#__PURE__*/external_react_default().createElement("div", {
|
|
1513
|
-
className:
|
|
1514
|
-
}, /*#__PURE__*/external_react_default().createElement(
|
|
1515
|
-
className: ticket_owned_index_module.
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
})), /*#__PURE__*/external_react_default().createElement("span", {
|
|
1519
|
-
className: ticket_owned_index_module.complete
|
|
1520
|
-
}, "Our records show you have a ticket(s) to this event."), /*#__PURE__*/external_react_default().createElement("span", {
|
|
1521
|
-
className: ticket_owned_index_module.complete
|
|
1522
|
-
}, "If you would like to purchase more, ", /*#__PURE__*/external_react_default().createElement("a", {
|
|
1523
|
-
onClick: () => goToRegistration()
|
|
1524
|
-
}, "click here"), ".")));
|
|
1732
|
+
className: ticket_owned_index_module.ticketOwnedWrapper
|
|
1733
|
+
}, /*#__PURE__*/external_react_default().createElement("div", {
|
|
1734
|
+
className: `${ticket_owned_index_module.alert} alert alert-warning`,
|
|
1735
|
+
role: "alert"
|
|
1736
|
+
}, "You have already ordered ", ownedTicketsString, ". If you would like to order more tickets, please do so below."));
|
|
1525
1737
|
};
|
|
1526
1738
|
|
|
1527
1739
|
/* harmony default export */ const ticket_owned = (TicketOwnedComponent);
|
|
1528
1740
|
;// CONCATENATED MODULE: ./src/components/registration-lite.js
|
|
1529
|
-
const
|
|
1741
|
+
const registration_lite_excluded = ["loadSession", "setMarketingSettings", "changeStep", "removeReservedTicket", "reserveTicket", "payTicket", "onPurchaseComplete", "getTicketTypes", "getTaxesTypes", "getLoginCode", "passwordlessLogin", "goToLogin", "loginOptions", "allowsNativeAuth", "allowsOtpAuth", "reservation", "checkout", "ticketTypes", "taxTypes", "step", "passwordlessCodeSent", "passwordlessEmail", "passwordlessCode", "getPasswordlessCode", "passwordlessCodeError", "loginWithCode", "goToExtraQuestions", "goToEvent", "goToRegistration", "profileData", "summitData", "supportEmail", "ticketOwned", "ownedTickets", "widgetLoading", "loading", "inPersonDisclaimer", "userProfile", "handleCompanyError"];
|
|
1530
1742
|
|
|
1531
1743
|
function registration_lite_ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
1532
1744
|
|
|
@@ -1534,9 +1746,9 @@ function registration_lite_objectSpread(target) { for (var i = 1; i < arguments.
|
|
|
1534
1746
|
|
|
1535
1747
|
function registration_lite_defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
1536
1748
|
|
|
1537
|
-
function
|
|
1749
|
+
function registration_lite_objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = registration_lite_objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
1538
1750
|
|
|
1539
|
-
function
|
|
1751
|
+
function registration_lite_objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
1540
1752
|
|
|
1541
1753
|
/**
|
|
1542
1754
|
* Copyright 2020 OpenStack Foundation
|
|
@@ -1569,7 +1781,7 @@ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) r
|
|
|
1569
1781
|
|
|
1570
1782
|
|
|
1571
1783
|
const RegistrationLite = _ref => {
|
|
1572
|
-
var
|
|
1784
|
+
var _formValues$ticketTyp, _formValues$ticketTyp2;
|
|
1573
1785
|
|
|
1574
1786
|
let {
|
|
1575
1787
|
loadSession,
|
|
@@ -1585,6 +1797,8 @@ const RegistrationLite = _ref => {
|
|
|
1585
1797
|
passwordlessLogin,
|
|
1586
1798
|
goToLogin,
|
|
1587
1799
|
loginOptions,
|
|
1800
|
+
allowsNativeAuth,
|
|
1801
|
+
allowsOtpAuth,
|
|
1588
1802
|
reservation,
|
|
1589
1803
|
checkout,
|
|
1590
1804
|
ticketTypes,
|
|
@@ -1603,18 +1817,37 @@ const RegistrationLite = _ref => {
|
|
|
1603
1817
|
summitData,
|
|
1604
1818
|
supportEmail,
|
|
1605
1819
|
ticketOwned,
|
|
1820
|
+
ownedTickets,
|
|
1606
1821
|
widgetLoading,
|
|
1607
1822
|
loading,
|
|
1608
1823
|
inPersonDisclaimer,
|
|
1609
|
-
userProfile
|
|
1824
|
+
userProfile,
|
|
1825
|
+
handleCompanyError
|
|
1610
1826
|
} = _ref,
|
|
1611
|
-
rest =
|
|
1827
|
+
rest = registration_lite_objectWithoutProperties(_ref, registration_lite_excluded);
|
|
1612
1828
|
|
|
1613
1829
|
const [registrationForm, setRegistrationForm] = (0,external_react_namespaceObject.useState)({
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
|
|
1830
|
+
values: {
|
|
1831
|
+
ticketType: null,
|
|
1832
|
+
ticketQuantity: 1,
|
|
1833
|
+
personalInformation: null,
|
|
1834
|
+
paymentInformation: null
|
|
1835
|
+
},
|
|
1836
|
+
errors: []
|
|
1617
1837
|
});
|
|
1838
|
+
const {
|
|
1839
|
+
values: formValues,
|
|
1840
|
+
errors: formErrors
|
|
1841
|
+
} = registrationForm;
|
|
1842
|
+
|
|
1843
|
+
const setFormValues = values => setRegistrationForm(registration_lite_objectSpread(registration_lite_objectSpread({}, registrationForm), {}, {
|
|
1844
|
+
values
|
|
1845
|
+
}));
|
|
1846
|
+
|
|
1847
|
+
const setFormErrors = errors => setRegistrationForm(registration_lite_objectSpread(registration_lite_objectSpread({}, registrationForm), {}, {
|
|
1848
|
+
errors
|
|
1849
|
+
}));
|
|
1850
|
+
|
|
1618
1851
|
let publicKey = null;
|
|
1619
1852
|
|
|
1620
1853
|
for (let profile of summitData.payment_profiles) {
|
|
@@ -1625,11 +1858,6 @@ const RegistrationLite = _ref => {
|
|
|
1625
1858
|
}
|
|
1626
1859
|
|
|
1627
1860
|
const stripePromise = (0,external_react_namespaceObject.useMemo)(() => (0,stripe_js_namespaceObject.loadStripe)(publicKey), [publicKey]);
|
|
1628
|
-
|
|
1629
|
-
const ticketReservation = () => {
|
|
1630
|
-
reserveTicket(registrationForm.personalInformation, registrationForm.ticketType);
|
|
1631
|
-
};
|
|
1632
|
-
|
|
1633
1861
|
(0,external_react_namespaceObject.useEffect)(() => {
|
|
1634
1862
|
loadSession(registration_lite_objectSpread(registration_lite_objectSpread({}, rest), {}, {
|
|
1635
1863
|
summitData,
|
|
@@ -1646,14 +1874,23 @@ const RegistrationLite = _ref => {
|
|
|
1646
1874
|
}
|
|
1647
1875
|
}, [summitData, profileData]);
|
|
1648
1876
|
(0,external_react_namespaceObject.useEffect)(() => {
|
|
1649
|
-
if (step === 1 &&
|
|
1650
|
-
|
|
1877
|
+
if (step === 1 && formValues !== null && formValues !== void 0 && formValues.ticketType && formValues !== null && formValues !== void 0 && formValues.personalInformation) {
|
|
1878
|
+
reserveTicket({
|
|
1879
|
+
personalInformation: formValues === null || formValues === void 0 ? void 0 : formValues.personalInformation,
|
|
1880
|
+
ticket: formValues === null || formValues === void 0 ? void 0 : formValues.ticketType,
|
|
1881
|
+
ticketQuantity: formValues === null || formValues === void 0 ? void 0 : formValues.ticketQuantity
|
|
1882
|
+
}, {
|
|
1883
|
+
onError: (err, res) => setFormErrors(res.body.errors)
|
|
1884
|
+
});
|
|
1651
1885
|
}
|
|
1652
1886
|
|
|
1653
|
-
if (step > 0 && !
|
|
1887
|
+
if (step > 0 && !(formValues !== null && formValues !== void 0 && formValues.ticketType)) {
|
|
1654
1888
|
changeStep(0);
|
|
1655
1889
|
}
|
|
1656
|
-
}, [
|
|
1890
|
+
}, [formValues]);
|
|
1891
|
+
(0,external_react_namespaceObject.useEffect)(() => {
|
|
1892
|
+
setFormErrors([]);
|
|
1893
|
+
}, [step]);
|
|
1657
1894
|
const [ref, {
|
|
1658
1895
|
height
|
|
1659
1896
|
}] = (0,external_react_use_namespaceObject.useMeasure)();
|
|
@@ -1662,10 +1899,18 @@ const RegistrationLite = _ref => {
|
|
|
1662
1899
|
bounce: 0
|
|
1663
1900
|
}, external_react_spring_namespaceObject.config.stiff),
|
|
1664
1901
|
to: {
|
|
1665
|
-
opacity: ((
|
|
1666
|
-
height: ((
|
|
1902
|
+
opacity: (formValues === null || formValues === void 0 ? void 0 : (_formValues$ticketTyp = formValues.ticketType) === null || _formValues$ticketTyp === void 0 ? void 0 : _formValues$ticketTyp.cost) === 0 ? 0 : 1,
|
|
1903
|
+
height: (formValues === null || formValues === void 0 ? void 0 : (_formValues$ticketTyp2 = formValues.ticketType) === null || _formValues$ticketTyp2 === void 0 ? void 0 : _formValues$ticketTyp2.cost) === 0 ? 0 : height
|
|
1667
1904
|
}
|
|
1668
1905
|
});
|
|
1906
|
+
|
|
1907
|
+
const handleCloseClick = () => {
|
|
1908
|
+
// Reset the step when closed to avoid unexpected behavior from `useEffect`s w/in other steps.
|
|
1909
|
+
// (i.e., recalling `onPurchaseComplete` after a user completes one order, closes the window, and then reopens the registration widget)
|
|
1910
|
+
changeStep(0);
|
|
1911
|
+
rest.closeWidget();
|
|
1912
|
+
};
|
|
1913
|
+
|
|
1669
1914
|
return /*#__PURE__*/external_react_default().createElement("div", {
|
|
1670
1915
|
id: "modal",
|
|
1671
1916
|
className: "modal is-active"
|
|
@@ -1680,22 +1925,20 @@ const RegistrationLite = _ref => {
|
|
|
1680
1925
|
size: 80
|
|
1681
1926
|
}), /*#__PURE__*/external_react_default().createElement("div", {
|
|
1682
1927
|
className: `${general_module.outerWrapper} summit-registration-lite`
|
|
1683
|
-
}, /*#__PURE__*/external_react_default().createElement(
|
|
1684
|
-
className:
|
|
1928
|
+
}, /*#__PURE__*/external_react_default().createElement("div", {
|
|
1929
|
+
className: general_module.innerWrapper
|
|
1685
1930
|
}, /*#__PURE__*/external_react_default().createElement("div", {
|
|
1686
1931
|
className: general_module.title
|
|
1687
1932
|
}, /*#__PURE__*/external_react_default().createElement("span", null, summitData.name), /*#__PURE__*/external_react_default().createElement("i", {
|
|
1688
1933
|
className: "fa fa-close",
|
|
1689
1934
|
"aria-label": "close",
|
|
1690
|
-
onClick:
|
|
1691
|
-
})),
|
|
1692
|
-
className: general_module.stepsWrapper
|
|
1693
|
-
}, /*#__PURE__*/external_react_default().createElement(ticket_owned, {
|
|
1694
|
-
goToRegistration: goToRegistration
|
|
1695
|
-
})), !ticketOwned && /*#__PURE__*/external_react_default().createElement("div", {
|
|
1935
|
+
onClick: handleCloseClick
|
|
1936
|
+
})), /*#__PURE__*/external_react_default().createElement("div", {
|
|
1696
1937
|
className: general_module.stepsWrapper
|
|
1697
|
-
}, !profileData && !passwordlessCodeSent && /*#__PURE__*/external_react_default().createElement(
|
|
1938
|
+
}, !profileData && !passwordlessCodeSent && /*#__PURE__*/external_react_default().createElement(components_login, {
|
|
1698
1939
|
options: loginOptions,
|
|
1940
|
+
allowsNativeAuth: allowsNativeAuth,
|
|
1941
|
+
allowsOtpAuth: allowsOtpAuth,
|
|
1699
1942
|
login: provider => rest.authUser(provider),
|
|
1700
1943
|
getLoginCode: getLoginCode,
|
|
1701
1944
|
getPasswordlessCode: getPasswordlessCode
|
|
@@ -1708,22 +1951,26 @@ const RegistrationLite = _ref => {
|
|
|
1708
1951
|
goToLogin: goToLogin,
|
|
1709
1952
|
getLoginCode: getLoginCode,
|
|
1710
1953
|
getPasswordlessCode: getPasswordlessCode
|
|
1711
|
-
}), profileData && step !== 3 && ticketTypes.length > 0 && /*#__PURE__*/external_react_default().createElement((external_react_default()).Fragment, null, /*#__PURE__*/external_react_default().createElement(
|
|
1954
|
+
}), profileData && step !== 3 && ticketTypes.length > 0 && /*#__PURE__*/external_react_default().createElement((external_react_default()).Fragment, null, ticketOwned && /*#__PURE__*/external_react_default().createElement(ticket_owned, {
|
|
1955
|
+
ownedTickets: ownedTickets,
|
|
1956
|
+
ticketTypes: ticketTypes
|
|
1957
|
+
}), /*#__PURE__*/external_react_default().createElement(ticket_type, {
|
|
1712
1958
|
ticketTypes: ticketTypes,
|
|
1713
1959
|
inPersonDisclaimer: inPersonDisclaimer,
|
|
1714
1960
|
taxTypes: taxTypes,
|
|
1715
1961
|
reservation: reservation,
|
|
1716
1962
|
isActive: step === 0,
|
|
1717
|
-
changeForm:
|
|
1718
|
-
ticketType: t
|
|
1719
|
-
}))
|
|
1963
|
+
changeForm: ticketForm => setFormValues(registration_lite_objectSpread(registration_lite_objectSpread({}, formValues), ticketForm))
|
|
1720
1964
|
}), /*#__PURE__*/external_react_default().createElement(personal_information, {
|
|
1721
1965
|
isActive: step === 1,
|
|
1722
1966
|
reservation: reservation,
|
|
1723
1967
|
userProfile: profileData,
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
1968
|
+
summitId: summitData.id,
|
|
1969
|
+
changeForm: personalInformation => setFormValues(registration_lite_objectSpread(registration_lite_objectSpread({}, formValues), {}, {
|
|
1970
|
+
personalInformation
|
|
1971
|
+
})),
|
|
1972
|
+
handleCompanyError: handleCompanyError,
|
|
1973
|
+
formErrors: formErrors
|
|
1727
1974
|
}), /*#__PURE__*/external_react_default().createElement(external_react_spring_namespaceObject.animated.div, {
|
|
1728
1975
|
style: registration_lite_objectSpread({}, toggleAnimation)
|
|
1729
1976
|
}, /*#__PURE__*/external_react_default().createElement("div", {
|
|
@@ -1741,14 +1988,13 @@ const RegistrationLite = _ref => {
|
|
|
1741
1988
|
supportEmail: supportEmail,
|
|
1742
1989
|
goToEvent: goToEvent,
|
|
1743
1990
|
goToExtraQuestions: goToExtraQuestions
|
|
1744
|
-
})), profileData &&
|
|
1991
|
+
})), profileData && step !== 3 && /*#__PURE__*/external_react_default().createElement(button_bar, {
|
|
1745
1992
|
step: step,
|
|
1746
1993
|
inPersonDisclaimer: inPersonDisclaimer,
|
|
1747
|
-
|
|
1748
|
-
goToRegistration: goToRegistration,
|
|
1994
|
+
formValues: formValues,
|
|
1749
1995
|
removeReservedTicket: removeReservedTicket,
|
|
1750
1996
|
changeStep: changeStep
|
|
1751
|
-
})))))
|
|
1997
|
+
})))));
|
|
1752
1998
|
};
|
|
1753
1999
|
|
|
1754
2000
|
const registration_lite_mapStateToProps = ({
|
package/package.json
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "summit-registration-lite",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.3",
|
|
4
4
|
"description": "Summit Registration Lite",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|
|
7
|
+
"clean": "find . -name \"node_modules\" -type d -prune -exec rm -rf '{}' + && yarn install",
|
|
7
8
|
"build-dev": "./node_modules/.bin/webpack --config webpack.dev.js",
|
|
8
9
|
"build": "./node_modules/.bin/webpack --config webpack.prod.js",
|
|
9
10
|
"serve": "webpack-dev-server --open --port=8888 --https --config webpack.dev.js",
|
|
@@ -58,7 +59,7 @@
|
|
|
58
59
|
"moment": "^2.22.2",
|
|
59
60
|
"moment-timezone": "^0.5.21",
|
|
60
61
|
"node-sass": "^7.0.1",
|
|
61
|
-
"openstack-uicore-foundation": "^4.0.
|
|
62
|
+
"openstack-uicore-foundation": "^4.0.18",
|
|
62
63
|
"optimize-css-assets-webpack-plugin": "^6.0.1",
|
|
63
64
|
"path": "^0.12.7",
|
|
64
65
|
"react": "^16.8.4",
|
|
@@ -102,7 +103,7 @@
|
|
|
102
103
|
"lodash": "^4.17.14",
|
|
103
104
|
"moment": "^2.22.2",
|
|
104
105
|
"moment-timezone": "^0.5.21",
|
|
105
|
-
"openstack-uicore-foundation": "^4.0.
|
|
106
|
+
"openstack-uicore-foundation": "^4.0.18",
|
|
106
107
|
"react": "^16.8.4",
|
|
107
108
|
"react-bootstrap": "^0.31.5",
|
|
108
109
|
"react-datetime": "^2.16.2",
|