1import { 2 ESTIMATEDOCSNOFILENAME, 3 SaasDefaultCustomerService 4} from "./chunk-4S4FYMCG.js"; 5import { 6 EmailTemplatesService 7} from "./chunk-2IMPMBNY.js"; 8import "./chunk-2KEYDIYK.js"; 9import "./chunk-SLCXQQWT.js"; 10import "./chunk-2CCCNCPC.js"; 11import "./chunk-BGLYM6VR.js"; 12import "./chunk-LBGBXT4D.js"; 13import "./chunk-4KEJXY5F.js"; 14import "./chunk-Z5IRBYN6.js"; 15import "./chunk-4E4JS6NY.js"; 16import { 17 GoogleMap, 18 GoogleMapsModule, 19 MapMarker, 20 PhoneNumberUIComponent, 21 PhoneNumberUIModule 22} from "./chunk-XPXJUOXM.js"; 23import { 24 AddressAutocompleteModule, 25 AddressInputComponent 26} from "./chunk-A3CX4FLW.js"; 27import "./chunk-JF3SKOWW.js"; 28import { 29 ConfirmDialogComponent, 30 CurrencyInputModule, 31 MatCheckbox, 32 MatCheckboxModule, 33 MatInput, 34 MatInputModule 35} from "./chunk-EAXUISJ5.js"; 36import { 37 AppUsersService, 38 DefaultFlexDirective, 39 DefaultLayoutAlignDirective, 40 DefaultLayoutDirective, 41 DefaultValueAccessor, 42 FlexLayoutModule, 43 FormControl, 44 FormControlName, 45 FormGroup, 46 FormGroupDirective, 47 MatDialog, 48 MatError, 49 MatFormField, 50 MatFormFieldModule, 51 MatHint, 52 MatIcon, 53 MatIconModule, 54 MatLabel, 55 MatSuffix, 56 NgControlStatus, 57 NgControlStatusGroup, 58 ReactiveFormsModule, 59 SaasCustomerService, 60 StorageService, 61 TeamsService, 62 Validators, 63 ɵNgNoValidate 64} from "./chunk-JDKRZWNO.js"; 65import { 66 MatCardModule 67} from "./chunk-CRRCTP4S.js"; 68import { 69 AuthenticationService, 70 CONSTANTS, 71 MatButton, 72 MatButtonModule, 73 MatIconButton, 74 QUOTE_CONSTANTS, 75 SignedOutGuard, 76 stateLookup 77} from "./chunk-VC4FNO6F.js"; 78import { 79 ActivatedRoute, 80 AsyncPipe, 81 CommonModule, 82 HttpClient, 83 NgIf, 84 Router, 85 RouterModule, 86 Subscription, 87 debounceTime, 88 distinctUntilChanged, 89 filter, 90 first, 91 firstValueFrom, 92 map, 93 switchMap, 94 ɵsetClassDebugInfo, 95 ɵɵadvance, 96 ɵɵattribute, 97 ɵɵdefineComponent, 98 ɵɵdefineInjector, 99 ɵɵdefineNgModule, 100 ɵɵdirectiveInject, 101 ɵɵelement, 102 ɵɵelementEnd, 103 ɵɵelementStart, 104 ɵɵgetCurrentView, 105 ɵɵlistener, 106 ɵɵnextContext, 107 ɵɵpipe, 108 ɵɵpipeBind1, 109 ɵɵproperty, 110 ɵɵpropertyInterpolate1, 111 ɵɵpureFunction0, 112 ɵɵreference, 113 ɵɵresetView, 114 ɵɵrestoreView, 115 ɵɵtemplate, 116 ɵɵtext, 117 ɵɵtextInterpolate, 118 ɵɵtextInterpolate1 119} from "./chunk-OKGTPDCW.js"; 120import "./chunk-62DANBNQ.js"; 121import "./chunk-UB6GWKOL.js"; 122import "./chunk-FDRCZZC4.js"; 123import "./chunk-GOBARW2P.js"; 124import "./chunk-3I5YKWCP.js"; 125import "./chunk-2S57T3GS.js"; 126import "./chunk-R4QHACMO.js"; 127import "./chunk-RIBVNXHQ.js"; 128import "./chunk-734QBUPT.js"; 129import "./chunk-4W2XO25E.js"; 130import "./chunk-FW3QMLWW.js"; 131import "./chunk-T4GYAOTA.js"; 132import "./chunk-2VHYZHLL.js"; 133import "./chunk-NC6QH5UF.js"; 134import "./chunk-4CMTUTAC.js"; 135import "./chunk-742TDVDI.js"; 136import "./chunk-MIOLVGSM.js"; 137import "./chunk-36T2BHYJ.js"; 138import "./chunk-KQRPAB76.js"; 139import "./chunk-ANQS3TYJ.js"; 140import "./chunk-5U2J5COB.js"; 141import "./chunk-7NVARB6X.js"; 142import { 143 firebase 144} from "./chunk-RANIOMIS.js"; 145import "./chunk-6Z4GBV7P.js"; 146import "./chunk-YQJK33YP.js"; 147import "./chunk-EB3GZKNJ.js"; 148import "./chunk-7LRYXUKF.js"; 149import "./chunk-BXJDQZJK.js"; 150import "./chunk-R6JLIESI.js"; 151import "./chunk-4EY2T3E2.js"; 152import "./chunk-EO547IX6.js"; 153import "./chunk-OJO5RD3M.js"; 154import "./chunk-XTS6MP7Q.js"; 155import { 156 __async 157} from "./chunk-K2M74TSM.js"; 158
159// libs/saas-account-signup/src/lib/saas-account-signup/saas-account-signup.component.ts 160var _c0 = () => ({ label: "A" }); 161function SaasAccountSignupComponent_form_21_mat_error_11_Template(rf, ctx) { 162 if (rf & 1) { 163 \u0275\u0275elementStart(0, "mat-error"); 164 \u0275\u0275text(1, "Must be a valid email address "); 165 \u0275\u0275elementEnd(); 166 } 167} 168function SaasAccountSignupComponent_form_21_mat_error_12_Template(rf, ctx) { 169 if (rf & 1) { 170 \u0275\u0275elementStart(0, "mat-error"); 171 \u0275\u0275text(1, "An email address is required "); 172 \u0275\u0275elementEnd(); 173 } 174} 175function SaasAccountSignupComponent_form_21_mat_error_17_Template(rf, ctx) { 176 if (rf & 1) { 177 \u0275\u0275elementStart(0, "mat-error"); 178 \u0275\u0275text(1, "Must be a valid email address "); 179 \u0275\u0275elementEnd(); 180 } 181} 182function SaasAccountSignupComponent_form_21_mat_error_18_Template(rf, ctx) { 183 if (rf & 1) { 184 \u0275\u0275elementStart(0, "mat-error"); 185 \u0275\u0275text(1, "An email address is required "); 186 \u0275\u0275elementEnd(); 187 } 188} 189function SaasAccountSignupComponent_form_21_mat_error_19_Template(rf, ctx) { 190 if (rf & 1) { 191 \u0275\u0275elementStart(0, "mat-error"); 192 \u0275\u0275text(1, "Email addresses don't match! "); 193 \u0275\u0275elementEnd(); 194 } 195} 196function SaasAccountSignupComponent_form_21_mat_error_27_Template(rf, ctx) { 197 if (rf & 1) { 198 \u0275\u0275elementStart(0, "mat-error"); 199 \u0275\u0275text(1, "A password is required "); 200 \u0275\u0275elementEnd(); 201 } 202} 203function SaasAccountSignupComponent_form_21_mat_error_28_Template(rf, ctx) { 204 if (rf & 1) { 205 \u0275\u0275elementStart(0, "mat-error"); 206 \u0275\u0275text(1, "Password must be at least 8 characters long"); 207 \u0275\u0275elementEnd(); 208 } 209} 210function SaasAccountSignupComponent_form_21_mat_error_33_Template(rf, ctx) { 211 if (rf & 1) { 212 \u0275\u0275elementStart(0, "mat-error"); 213 \u0275\u0275text(1, "Please enter your first name "); 214 \u0275\u0275elementEnd(); 215 } 216} 217function SaasAccountSignupComponent_form_21_mat_error_38_Template(rf, ctx) { 218 if (rf & 1) { 219 \u0275\u0275elementStart(0, "mat-error"); 220 \u0275\u0275text(1, "Please enter your last name "); 221 \u0275\u0275elementEnd(); 222 } 223} 224function SaasAccountSignupComponent_form_21_mat_error_50_Template(rf, ctx) { 225 if (rf & 1) { 226 \u0275\u0275elementStart(0, "mat-error"); 227 \u0275\u0275text(1, "Company name is required "); 228 \u0275\u0275elementEnd(); 229 } 230} 231function SaasAccountSignupComponent_form_21_mat_error_51_Template(rf, ctx) { 232 if (rf & 1) { 233 \u0275\u0275elementStart(0, "mat-error"); 234 \u0275\u0275text(1, "Company name must be at least 3 characters long"); 235 \u0275\u0275elementEnd(); 236 } 237} 238function SaasAccountSignupComponent_form_21_mat_error_54_Template(rf, ctx) { 239 if (rf & 1) { 240 \u0275\u0275elementStart(0, "mat-error"); 241 \u0275\u0275text(1, "Name link is unavailable "); 242 \u0275\u0275elementEnd(); 243 } 244} 245function SaasAccountSignupComponent_form_21_mat_error_55_Template(rf, ctx) { 246 if (rf & 1) { 247 \u0275\u0275elementStart(0, "mat-error"); 248 \u0275\u0275text(1, " Name link can only contain letters, numbers, and dashes"); 249 \u0275\u0275elementEnd(); 250 } 251} 252function SaasAccountSignupComponent_form_21_mat_error_56_Template(rf, ctx) { 253 if (rf & 1) { 254 \u0275\u0275elementStart(0, "mat-error"); 255 \u0275\u0275text(1); 256 \u0275\u0275elementEnd(); 257 } 258 if (rf & 2) { 259 let tmp_3_0; 260 const ctx_r1 = \u0275\u0275nextContext(2); 261 \u0275\u0275advance(); 262 \u0275\u0275textInterpolate1("Name link must be at least ", (tmp_3_0 = ctx_r1.createAccountForm.get("companyNameLink")) == null ? null : tmp_3_0.getError("minlength").requiredLength, " characters long "); 263 } 264} 265function SaasAccountSignupComponent_form_21_mat_error_57_Template(rf, ctx) { 266 if (rf & 1) { 267 \u0275\u0275elementStart(0, "mat-error"); 268 \u0275\u0275text(1, "Name link is required "); 269 \u0275\u0275elementEnd(); 270 } 271} 272function SaasAccountSignupComponent_form_21_mat_error_62_Template(rf, ctx) { 273 if (rf & 1) { 274 \u0275\u0275elementStart(0, "mat-error"); 275 \u0275\u0275text(1, "Email is required"); 276 \u0275\u0275elementEnd(); 277 } 278} 279function SaasAccountSignupComponent_form_21_google_map_65_map_marker_2_Template(rf, ctx) { 280 if (rf & 1) { 281 \u0275\u0275element(0, "map-marker", 35); 282 } 283 if (rf & 2) { 284 const ctx_r1 = \u0275\u0275nextContext(3); 285 \u0275\u0275property("position", ctx_r1.markerPosition)("options", \u0275\u0275pureFunction0(2, _c0)); 286 } 287} 288function SaasAccountSignupComponent_form_21_google_map_65_Template(rf, ctx) { 289 if (rf & 1) { 290 \u0275\u0275elementStart(0, "google-map", 33, 1); 291 \u0275\u0275template(2, SaasAccountSignupComponent_form_21_google_map_65_map_marker_2_Template, 1, 3, "map-marker", 34); 292 \u0275\u0275elementEnd(); 293 } 294 if (rf & 2) { 295 const ctx_r1 = \u0275\u0275nextContext(2); 296 \u0275\u0275propertyInterpolate1("height", "", ctx_r1.mapHeight, "px"); 297 \u0275\u0275property("options", ctx_r1.mapOptions); 298 \u0275\u0275advance(2); 299 \u0275\u0275property("ngIf", ctx_r1.showSingleMarker); 300 } 301} 302function SaasAccountSignupComponent_form_21_Template(rf, ctx) { 303 if (rf & 1) { 304 const _r1 = \u0275\u0275getCurrentView(); 305 \u0275\u0275elementStart(0, "form", 12); 306 \u0275\u0275listener("ngSubmit", function SaasAccountSignupComponent_form_21_Template_form_ngSubmit_0_listener() { 307 \u0275\u0275restoreView(_r1); 308 const ctx_r1 = \u0275\u0275nextContext();
309 return \u0275\u0275resetView(ctx_r1.onFormSubmit()); 310 }); 311 \u0275\u0275elementStart(1, "div", 13); 312 \u0275\u0275element(2, "div", 8); 313 \u0275\u0275elementStart(3, "div", 14)(4, "p", 15)(5, "strong"); 314 \u0275\u0275text(6, " User Login: "); 315 \u0275\u0275elementEnd()(); 316 \u0275\u0275elementStart(7, "mat-form-field", 15)(8, "mat-label"); 317 \u0275\u0275text(9, "Login Email Address"); 318 \u0275\u0275elementEnd(); 319 \u0275\u0275element(10, "input", 16); 320 \u0275\u0275template(11, SaasAccountSignupComponent_form_21_mat_error_11_Template, 2, 0, "mat-error", 17)(12, SaasAccountSignupComponent_form_21_mat_error_12_Template, 2, 0, "mat-error", 17); 321 \u0275\u0275elementEnd(); 322 \u0275\u0275elementStart(13, "mat-form-field", 15)(14, "mat-label"); 323 \u0275\u0275text(15, "Confirm Email Address"); 324 \u0275\u0275elementEnd(); 325 \u0275\u0275element(16, "input", 18); 326 \u0275\u0275template(17, SaasAccountSignupComponent_form_21_mat_error_17_Template, 2, 0, "mat-error", 17)(18, SaasAccountSignupComponent_form_21_mat_error_18_Template, 2, 0, "mat-error", 17)(19, SaasAccountSignupComponent_form_21_mat_error_19_Template, 2, 0, "mat-error", 17); 327 \u0275\u0275elementEnd(); 328 \u0275\u0275elementStart(20, "mat-form-field", 15)(21, "mat-label"); 329 \u0275\u0275text(22, "Password (min 8 chars)"); 330 \u0275\u0275elementEnd(); 331 \u0275\u0275element(23, "input", 19); 332 \u0275\u0275elementStart(24, "button", 20); 333 \u0275\u0275listener("click", function SaasAccountSignupComponent_form_21_Template_button_click_24_listener() { 334 \u0275\u0275restoreView(_r1); 335 const ctx_r1 = \u0275\u0275nextContext(); 336 return \u0275\u0275resetView(ctx_r1.showPassword = !ctx_r1.showPassword); 337 }); 338 \u0275\u0275elementStart(25, "mat-icon"); 339 \u0275\u0275text(26); 340 \u0275\u0275elementEnd()(); 341 \u0275\u0275template(27, SaasAccountSignupComponent_form_21_mat_error_27_Template, 2, 0, "mat-error", 17)(28, SaasAccountSignupComponent_form_21_mat_error_28_Template, 2, 0, "mat-error", 17); 342 \u0275\u0275elementEnd(); 343 \u0275\u0275elementStart(29, "mat-form-field", 15)(30, "mat-label"); 344 \u0275\u0275text(31, "First Name"); 345 \u0275\u0275elementEnd(); 346 \u0275\u0275element(32, "input", 21); 347 \u0275\u0275template(33, SaasAccountSignupComponent_form_21_mat_error_33_Template, 2, 0, "mat-error", 17); 348 \u0275\u0275elementEnd(); 349 \u0275\u0275elementStart(34, "mat-form-field", 15)(35, "mat-label"); 350 \u0275\u0275text(36, "Last Name"); 351 \u0275\u0275elementEnd(); 352 \u0275\u0275element(37, "input", 22); 353 \u0275\u0275template(38, SaasAccountSignupComponent_form_21_mat_error_38_Template, 2, 0, "mat-error", 17); 354 \u0275\u0275elementEnd(); 355 \u0275\u0275elementStart(39, "div", 15)(40, "md-apps-phone-number-ui", 23); 356 \u0275\u0275listener("update", function SaasAccountSignupComponent_form_21_Template_md_apps_phone_number_ui_update_40_listener($event) { 357 \u0275\u0275restoreView(_r1); 358 const ctx_r1 = \u0275\u0275nextContext(); 359 return \u0275\u0275resetView(ctx_r1.personalPhone.setValue($event)); 360 })("validNumber", function SaasAccountSignupComponent_form_21_Template_md_apps_phone_number_ui_validNumber_40_listener($event) { 361 \u0275\u0275restoreView(_r1); 362 const ctx_r1 = \u0275\u0275nextContext(); 363 return \u0275\u0275resetView($event ? ctx_r1.personalPhone.setErrors(null) : ctx_r1.personalPhone.setErrors({ "invalid number": true })); 364 }); 365 \u0275\u0275elementEnd()()(); 366 \u0275\u0275element(41, "div", 8); 367 \u0275\u0275elementEnd(); 368 \u0275\u0275elementStart(42, "div", 13); 369 \u0275\u0275element(43, "div", 8); 370 \u0275\u0275elementStart(44, "div", 14)(45, "p", 15)(46, "strong"); 371 \u0275\u0275text(47, " Company Info: "); 372 \u0275\u0275elementEnd()(); 373 \u0275\u0275elementStart(48, "mat-form-field", 3); 374 \u0275\u0275element(49, "input", 24); 375 \u0275\u0275template(50, SaasAccountSignupComponent_form_21_mat_error_50_Template, 2, 0, "mat-error", 17)(51, SaasAccountSignupComponent_form_21_mat_error_51_Template, 2, 0, "mat-error", 17); 376 \u0275\u0275elementEnd(); 377 \u0275\u0275elementStart(52, "mat-form-field", 3); 378 \u0275\u0275element(53, "input", 25); 379 \u0275\u0275template(54, SaasAccountSignupComponent_form_21_mat_error_54_Template, 2, 0, "mat-error", 17)(55, SaasAccountSignupComponent_form_21_mat_error_55_Template, 2, 0, "mat-error", 17)(56, SaasAccountSignupComponent_form_21_mat_error_56_Template, 2, 1, "mat-error", 17)(57, SaasAccountSignupComponent_form_21_mat_error_57_Template, 2, 0, "mat-error", 17); 380 \u0275\u0275elementStart(58, "mat-hint"); 381 \u0275\u0275text(59); 382 \u0275\u0275elementEnd()(); 383 \u0275\u0275elementStart(60, "mat-form-field", 3); 384 \u0275\u0275element(61, "input", 26); 385 \u0275\u0275template(62, SaasAccountSignupComponent_form_21_mat_error_62_Template, 2, 0, "mat-error", 17); 386 \u0275\u0275elementEnd(); 387 \u0275\u0275elementStart(63, "md-apps-phone-number-ui", 23); 388 \u0275\u0275listener("update", function SaasAccountSignupComponent_form_21_Template_md_apps_phone_number_ui_update_63_listener($event) { 389 let tmp_3_0; 390 \u0275\u0275restoreView(_r1); 391 const ctx_r1 = \u0275\u0275nextContext();
392 return \u0275\u0275resetView((tmp_3_0 = ctx_r1.createAccountForm.get("phone")) == null ? null : tmp_3_0.setValue($event)); 393 })("validNumber", function SaasAccountSignupComponent_form_21_Template_md_apps_phone_number_ui_validNumber_63_listener($event) { 394 \u0275\u0275restoreView(_r1); 395 const ctx_r1 = \u0275\u0275nextContext(); 396 return \u0275\u0275resetView($event ? ctx_r1.createAccountForm.setErrors(null) : ctx_r1.createAccountForm.setErrors({ "invalid number": true })); 397 }); 398 \u0275\u0275elementEnd(); 399 \u0275\u0275elementStart(64, "md-apps-address-autocomplete", 27); 400 \u0275\u0275listener("autocompleteSelected", function SaasAccountSignupComponent_form_21_Template_md_apps_address_autocomplete_autocompleteSelected_64_listener($event) { 401 \u0275\u0275restoreView(_r1); 402 const ctx_r1 = \u0275\u0275nextContext(); 403 return \u0275\u0275resetView(ctx_r1.onAutoCompleteSelected($event)); 404 }); 405 \u0275\u0275elementEnd(); 406 \u0275\u0275template(65, SaasAccountSignupComponent_form_21_google_map_65_Template, 3, 4, "google-map", 28); 407 \u0275\u0275elementEnd(); 408 \u0275\u0275element(66, "div", 8); 409 \u0275\u0275elementEnd(); 410 \u0275\u0275elementStart(67, "div", 29); 411 \u0275\u0275element(68, "div", 8); 412 \u0275\u0275elementStart(69, "div", 14)(70, "p"); 413 \u0275\u0275text(71, " You must agree to the Move Details "); 414 \u0275\u0275elementStart(72, "a", 30); 415 \u0275\u0275text(73, "Privacy Policy"); 416 \u0275\u0275elementEnd(); 417 \u0275\u0275text(74, " and "); 418 \u0275\u0275elementStart(75, "a", 31); 419 \u0275\u0275text(76, "Terms and Conditions"); 420 \u0275\u0275elementEnd(); 421 \u0275\u0275text(77, " in order to create your account. "); 422 \u0275\u0275elementEnd()(); 423 \u0275\u0275element(78, "div", 8); 424 \u0275\u0275elementEnd(); 425 \u0275\u0275elementStart(79, "div", 5); 426 \u0275\u0275element(80, "div", 8); 427 \u0275\u0275elementStart(81, "div", 14)(82, "mat-checkbox", null, 0); 428 \u0275\u0275text(84, "I Agree to Terms and Privacy Policies"); 429 \u0275\u0275elementEnd()(); 430 \u0275\u0275element(85, "div", 8); 431 \u0275\u0275elementEnd(); 432 \u0275\u0275elementStart(86, "div", 5); 433 \u0275\u0275element(87, "div", 8); 434 \u0275\u0275elementStart(88, "div", 14)(89, "button", 32); 435 \u0275\u0275text(90, " Setup Account "); 436 \u0275\u0275elementEnd()(); 437 \u0275\u0275element(91, "div", 8); 438 \u0275\u0275elementEnd()(); 439 } 440 if (rf & 2) { 441 let tmp_3_0; 442 let tmp_4_0; 443 let tmp_5_0; 444 let tmp_6_0; 445 let tmp_12_0; 446 let tmp_13_0; 447 let tmp_14_0; 448 let tmp_15_0; 449 let tmp_18_0; 450 let tmp_19_0; 451 let tmp_20_0; 452 let tmp_21_0; 453 let tmp_22_0; 454 let tmp_23_0; 455 let tmp_26_0; 456 const termsAgree_r3 = \u0275\u0275reference(83); 457 const ctx_r1 = \u0275\u0275nextContext(); 458 \u0275\u0275property("formGroup", ctx_r1.createAccountForm); 459 \u0275\u0275advance(11); 460 \u0275\u0275property("ngIf", (tmp_3_0 = ctx_r1.createAccountForm.get("email")) == null ? null : tmp_3_0.hasError("email")); 461 \u0275\u0275advance(); 462 \u0275\u0275property("ngIf", (tmp_4_0 = ctx_r1.createAccountForm.get("email")) == null ? null : tmp_4_0.hasError("required")); 463 \u0275\u0275advance(5); 464 \u0275\u0275property("ngIf", (tmp_5_0 = ctx_r1.createAccountForm.get("email")) == null ? null : tmp_5_0.hasError("email")); 465 \u0275\u0275advance(); 466 \u0275\u0275property("ngIf", (tmp_6_0 = ctx_r1.createAccountForm.get("email")) == null ? null : tmp_6_0.hasError("required")); 467 \u0275\u0275advance(); 468 \u0275\u0275property("ngIf", ctx_r1.createAccountForm.hasError("invalidEmailConfirmation")); 469 \u0275\u0275advance(4); 470 \u0275\u0275property("type", ctx_r1.showPassword ? "text" : "password"); 471 \u0275\u0275advance(); 472 \u0275\u0275attribute("aria-label", "Hide password")("aria-pressed", !ctx_r1.showPassword); 473 \u0275\u0275advance(2); 474 \u0275\u0275textInterpolate(!ctx_r1.showPassword ? "visibility_off" : "visibility"); 475 \u0275\u0275advance(); 476 \u0275\u0275property("ngIf", (tmp_12_0 = ctx_r1.createAccountForm.get("password")) == null ? null : tmp_12_0.hasError("required")); 477 \u0275\u0275advance(); 478 \u0275\u0275property("ngIf", (tmp_13_0 = ctx_r1.createAccountForm.get("password")) == null ? null : tmp_13_0.hasError("minlength")); 479 \u0275\u0275advance(5); 480 \u0275\u0275property("ngIf", (tmp_14_0 = ctx_r1.createAccountForm.get("firstName")) == null ? null : tmp_14_0.hasError("required")); 481 \u0275\u0275advance(5); 482 \u0275\u0275property("ngIf", (tmp_15_0 = ctx_r1.createAccountForm.get("lastName")) == null ? null : tmp_15_0.hasError("required")); 483 \u0275\u0275advance(2); 484 \u0275\u0275property("value", ctx_r1.personalPhone.value)("customLabel", "Phone number"); 485 \u0275\u0275advance(10); 486 \u0275\u0275property("ngIf", (tmp_18_0 = ctx_r1.createAccountForm.get("companyName")) == null ? null : tmp_18_0.hasError("required")); 487 \u0275\u0275advance(); 488 \u0275\u0275property("ngIf", (tmp_19_0 = ctx_r1.createAccountForm.get("companyName")) == null ? null : tmp_19_0.hasError("minlength")); 489 \u0275\u0275advance(3); 490 \u0275\u0275property("ngIf", (tmp_20_0 = ctx_r1.createAccountForm.get("companyNameLink")) == null ? null : tmp_20_0.hasError("unavailable")); 491 \u0275\u0275advance(); 492 \u0275\u0275property("ngIf", (tmp_21_0 = ctx_r1.createAccountForm.get("companyNameLink")) == null ? null : tmp_21_0.hasError("invalidCharacter")); 493 \u0275\u0275advance(); 494 \u0275\u0275property("ngIf", (tmp_22_0 = ctx_r1.createAccountForm.get("companyNameLink")) == null ? null : tmp_22_0.hasError("minlength")); 495 \u0275\u0275advance(); 496 \u0275\u0275property("ngIf", (tmp_23_0 = ctx_r1.createAccountForm.get("companyNameLink")) == null ? null : tmp_23_0.hasError("required")); 497 \u0275\u0275advance(2); 498 \u0275\u0275textInterpolate1("Your URL (example: app.movedetails.com/", ctx_r1.companyNameLink.value ? ctx_r1.companyNameLink.value : "namelink", ")"); 499 \u0275\u0275advance(3); 500 \u0275\u0275property("ngIf", ctx_r1.estimateEmailInvalid()); 501 \u0275\u0275advance(); 502 \u0275\u0275property("value", (tmp_26_0 = ctx_r1.createAccountForm.get("phone")) == null ? null : tmp_26_0.value)("customLabel", "Phone number to show on estimates"); 503 \u0275\u0275advance(); 504 \u0275\u0275property("includeAddressComponents", true)("addressInputFormControl", ctx_r1.address); 505 \u0275\u0275advance(); 506 \u0275\u0275property("ngIf", ctx_r1.mapOptions); 507 \u0275\u0275advance(24); 508 \u0275\u0275property("disabled", ctx_r1.createAccountForm.invali
508d || !termsAgree_r3.checked); 509 } 510} 511var SaasAccountSignupComponent = class _SaasAccountSignupComponent { 512 authService; 513 appUsersService; 514 saasCustomerService; 515 saasDefaultCustomerService; 516 router; 517 storageService; 518 teamsService; 519 http; 520 matDialog; 521 environment; 522 createAccountForm; 523 phonemask = CONSTANTS.phonemask; 524 mapOptions; 525 mapHeight = 300; 526 markerPosition; 527 showSingleMarker = false; 528 coordinate; 529 timezone; 530 state; 531 showPassword = false; 532 validNameLinkHash = {}; 533 availableNameLinkHash = {}; 534 subscriptions = new Subscription(); 535 constructor(authService, appUsersService, saasCustomerService, saasDefaultCustomerService, router, storageService, teamsService, http, matDialog, environment) { 536 this.authService = authService; 537 this.appUsersService = appUsersService; 538 this.saasCustomerService = saasCustomerService; 539 this.saasDefaultCustomerService = saasDefaultCustomerService; 540 this.router = router; 541 this.storageService = storageService; 542 this.teamsService = teamsService; 543 this.http = http; 544 this.matDialog = matDialog; 545 this.environment = environment; 546 } 547 ngOnInit() { 548 this.createAccountForm = new FormGroup({ 549 firstName: new FormControl("", Validators.required), 550 lastName: new FormControl("", Validators.required), 551 personalPhone: new FormControl("", [ 552 Validators.required 553 // Validators.pattern(CONSTANTS.PHONEREGEX), 554 ]), 555 email: new FormControl("", [Validators.email, Validators.required]), 556 confirmEmail: new FormControl("", [ 557 Validators.email, 558 Validators.required 559 ]), 560 password: new FormControl("", [ 561 Validators.minLength(8), 562 Validators.required 563 ]), 564 companyName: new FormControl("", [ 565 Validators.required, 566 Validators.minLength(3) 567 ]), 568 companyNameLink: new FormControl("", [ 569 Validators.required, 570 Validators.minLength(3) 571 ]), 572 estimateEmail: new FormControl("", [ 573 Validators.required, 574 Validators.pattern(CONSTANTS.EMAILREGEX) 575 ]), 576 address: new FormControl("", [Validators.required]), 577 phone: new FormControl("", [ 578 Validators.required 579 // Validators.pattern(CONSTANTS.PHONEREGEX), 580 ]), 581 dispatchName: new FormControl("", [ 582 Validators.required, 583 Validators.minLength(2) 584 ]), 585 dispatchShortName: new FormControl("", [ 586 Validators.required, 587 Validators.minLength(2), 588 Validators.maxLength(4) 589 ]), 590 calendarName: new FormControl("", [ 591 Validators.required, 592 Validators.minLength(3) 593 ]) 594 }
594, { validators: this.confirmationEmailValidator }); 595 this.subscriptions.add(this.createAccountForm.get("email")?.valueChanges.subscribe((emailValue) => { 596 if (this.createAccountForm.get("email")?.valid) { 597 this.createAccountForm.get("estimateEmail")?.setValue(emailValue); 598 } 599 })); 600 this.subscriptions.add(this.createAccountForm.controls["dispatchName"].valueChanges.subscribe((v) => { 601 this.createAccountForm.controls["calendarName"].setValue(`${v}`); 602 })); 603 this.subscriptions.add(this.companyName.valueChanges.subscribe((companyNameValue) => { 604 if (companyNameValue.length > 2 && this.companyNameLink.pristine) { 605 this.companyNameLink.setValue(this.stringToNameLink(companyNameValue)); 606 } 607 })); 608 this.subscriptions.add(this.createAccountForm.controls["companyNameLink"].valueChanges.pipe(debounceTime(750), distinctUntilChanged()).subscribe((nameLinkValue) => { 609 const formControl = this.createAccountForm.get("companyNameLink"); 610 this.isCompanyLinkValid(nameLinkValue); 611 if (!this.validNameLinkHash[nameLinkValue]) { 612 console.log("Invalid character!"); 613 formControl?.setErrors({ invalidCharacter: true }); 614 return; 615 } 616 if (nameLinkValue?.length < 3) { 617 return; 618 } 619 this.isCompanyLinkAvailable(nameLinkValue).then(() => { 620 if (!this.availableNameLinkHash[nameLinkValue]) { 621 console.log("unavailable!"); 622 formControl?.setErrors({ unavailable: true }); 623 } 624 }); 625 })); 626 } 627 ngOnDestroy() { 628 this.subscriptions.unsubscribe(); 629 } 630 get firstName() { 631 return this.createAccountForm.get("firstName"); 632 } 633 get lastName() { 634 return this.createAccountForm.get("lastName"); 635 } 636 get personalPhone() { 637 return this.createAccountForm.get("personalPhone"); 638 } 639 get companyName() { 640 return this.createAccountForm.get("companyName"); 641 } 642 get companyNameLink() { 643 return this.createAccountForm.get("companyNameLink"); 644 } 645 get address() { 646 return this.createAccountForm.get("address"); 647 } 648 get dispatchName() { 649 return this.createAccountForm.get("dispatchName"); 650 } 651 get dispatchShortName() { 652 return this.createAccountForm.get("dispatchShortName"); 653 } 654 get standardPay() { 655 return this.createAccountForm.get("standardPay"); 656 } 657 get leadPay() { 658 return this.createAccountForm.get("leadPay"); 659 } 660 get customerLaborRate() { 661 return this.createAccountForm.get("customerLaborRate"); 662 } 663 get truckFuelCost() { 664 return this.createAccountForm.get("truckFuelCost"); 665 } 666 get truckCustomerHourlyRate() { 667 return this.createAccountForm.get("truckCustomerHourlyRate"); 668 } 669 onFormSubmit() { 670 return __async(this, null, function* () { 671 let progressModal = this.matDialog.open(ConfirmDialogComponent, { 672 data: { 673 suppressButtons: true, 674 showProgressBar: true, 675 headerText: "Creating Account", 676 messageContent: "Please wait while we set up your account..." 677 }, 678 disableClose: true 679 }); 680 const fbUser = yield this.createUserAccount(); 681 if (fbUser) { 682 yield this.saasDefaultCustomerService.registerNewSaasAccount(fbUser); 683 const agu = yield firstValueFrom(this.appUsersService.aggregatedUser$.pipe(filter((agu2) => !!agu2 && !!agu2.saasCustomerId && !!agu2.userId && !!agu2.userRoles))); 684 console.log("AGU Object Complete"); 685 if (agu?.saasCustomerId) { 686 const aguUpdate = { 687 firstName: this.firstName.value, 688 lastName: this.lastName.value, 689 phone: this.personalPhone.value 690 }; 691 yield this.appUsersService.updateAppUserFields(agu.saasCustomerId, agu.userId, aguUpdate); 692 console.log("Administrator user first and last names updated"); 693 progressModal.close(); 694 progressModal = this.matDialog.open(ConfirmDialogComponent, { 695 data: { 696 suppressButtons: true, 697 showProgressBar: true, 698 headerText: "Configuring Account", 699 messageContent: "Please wait while we set up your account... this can take a little while, so please be patient..." 700 }, 701 disableClose: true 702 }); 703 yield this.submitInitialSettings(agu.saasCustomerId); 704 this.saasCustomerService.setNewSaasCustomerIdObservable({ 705 agu$: this.appUsersService.aggregatedUser$ 706 }); 707 console.log("Watching for name link creation..."); 708 const nameLinkSubscription = this.saasCustomerService.saasCustomerNameLink$().subscribe((nameLink) => { 709 console.log("Name Link Subscription fired", nameLink); 710 if (nameLink?.nameLink) { 711 console.log("Name Link exists"); 712 nameLinkSubscription.unsubscribe(); 713 progressModal.close(); 714 this.router.navigate(["/", nameLink.nameLink, "admin-oauth"]); 715 } 716 }); 717 return; 718 } 719 } 720 alert("An error occured while trying to create your user account. Please reload the page and try again. If the problem persists, please contact Move Details for assistance."); 721 }); 722 } 723 createUserAccount() { 724 return __async(this, null, function* () { 725 const userCredential = yield this.authService.registerNewUser(this.createAccountForm.value.email, this.createAccountForm.value.password); 726 console.log({ userCredential }); 727 const fbUser = yield firstValueFrom(this.authService.authState$()); 728 console.log({ fbUser }); 729 return fbUser;
730 }); 731 } 732 onAutoCompleteSelected(data) { 733 this.setMapWithSingleMarker({ 734 lat: data.coordinate?.lat || 0, 735 lng: data.coordinate?.lng || 0 736 }); 737 const mapMarker = new firebase.firestore.GeoPoint(data.coordinate?.lat || 0, data.coordinate?.lng || 0); 738 this.createAccountForm.controls["address"].setValue(data.address); 739 this.coordinate = { 740 lat: data.coordinate?.lat || 0, 741 lng: data.coordinate?.lng || 0 742 }; 743 const stateList = data.addressComponents?.map((ac) => stateLookup[ac.longText || ""]).filter((n) => n); 744 if (stateList?.length) { 745 this.state = stateList[0]; 746 } 747 this.teamsService.getTimezone(mapMarker).then((timezone) => this.timezone = timezone); 748 const locality = data.addressComponents?.find((comp) => comp.types.includes("locality")); 749 const sublocality = data.addressComponents?.find((comp) => comp.types.includes("sublocality")); 750 console.log({ locality, sublocality }); 751 const cityName = (locality || sublocality)?.longText; 752 if (cityName) { 753 console.log("Setting dispatch name to:", cityName); 754 this.dispatchName.setValue(cityName); 755 console.log("Setting Dispatch abbreviation to:", this.stringToNameLink(`${(locality || sublocality)?.shortText}`).slice(0, 3).toUpperCase()); 756 this.dispatchShortName.setValue(this.stringToNameLink(`${(locality || sublocality)?.shortText}`).slice(0, 3).toUpperCase()); 757 } 758 } 759 setMapWithSingleMarker(center) { 760 setTimeout(() => { 761 this.mapOptions = { 762 center, 763 zoom: 14, 764 gestureHandling: "cooperative" 765 }; 766 this.showSingleMarker = true; 767 this.markerPosition = { lat: center.lat, lng: center.lng }; 768 }, 200); 769 } 770 setDefaultMap() { 771 setTimeout(() => { 772 this.mapOptions = { 773 center: { lat: 39.5, lng: -98.35 }, 774 zoom: 3, 775 gestureHandling: "cooperative" 776 }; 777 this.showSingleMarker = false;
778 console.log("setMapWithSingleMarker: this.mapOptions = ", this.mapOptions); 779 }, 200); 780 } 781 companyNameInvalid() { 782 const companyName = this.createAccountForm.get("companyName"); 783 return companyName && companyName.touched && companyName.invalid; 784 } 785 isCompanyLinkValid(companyNameLink) { 786 const strippedLink = this.stringToNameLink(companyNameLink); 787 if (strippedLink !== companyNameLink) { 788 return; 789 } 790 this.validNameLinkHash[strippedLink] = true; 791 } 792 isCompanyLinkAvailable(companyNameLink) { 793 return __async(this, null, function* () { 794 const strippedLink = this.stringToNameLink(companyNameLink); 795 const duplicateNameLink = yield firstValueFrom(this.saasCustomerService.saasCompanyNameLinkFromLink$(strippedLink)); 796 console.log({ duplicateNameLink }); 797 if (duplicateNameLink) { 798 return; 799 } 800 this.availableNameLinkHash[strippedLink] = true; 801 }); 802 } 803 companyLinkHasError() { 804 const companyNameLink = this.createAccountForm.get("companyNameLink"); 805 return companyNameLink && companyNameLink.touched && (companyNameLink.hasError("unavailable") || companyNameLink.hasError("invalidCharacter") || companyNameLink.hasError("minlength") || companyNameLink.hasError("required")); 806 } 807 estimateEmailInvalid() { 808 const estimateEmail = this.createAccountForm.get("estimateEmail"); 809 return estimateEmail && estimateEmail.touched && estimateEmail.invalid; 810 } 811 phoneInvalid() { 812 const phone = this.createAccountForm.get("phone"); 813 return phone && phone.touched && phone.invalid; 814 } 815 dispatchNameInvalid() { 816 const dispatchName = this.createAccountForm.get("dispatchName"); 817 return dispatchName && dispatchName.touched && dispatchName.invalid; 818 } 819 dispatchShortNameInvalid() { 820 const dispatchShortName = this.createAccountForm.get("dispatchShortName"); 821 return dispatchShortName && dispatchShortName.touched && dispatchShortName.invalid; 822 } 823 calendarNameInvalid() { 824 const calendarName = this.createAccountForm.get("calendarName"); 825 return calendarName && calendarName.touched && calendarName.invalid; 826 } 827 dispatchNameChange() { 828 console.log("dispatchName value = ", this.createAccountForm.controls["dispatchName"].value); 829 this.createAccountForm.controls["calendarName"].setValue(`MD ${this.createAccountForm.controls["dispatchName"].value}`); 830 } 831 submitInitialSettings(companyId) { 832 return __async(this, null, function* () { 833 if (companyId) { 834 console.log("this.createAccountForm.value = ", this.createAccountForm.value); 835 console.log("Beginning file uploads", { companyId }); 836 const mobileLogoFileName = yield this.uploadFileToStorage(companyId, "images", "logos", "md-mobile-logo.png", "mobile"); 837 console.log("Moblie Logo uploaded"); 838 const desktopLogoFileName = yield this.uploadFileToStorage(companyId, "images", "logos", "md-desktop-logo.png", "desktop"); 839 console.log("Desktop Logo uploaded"); 840 const valuationFileName = yield this.uploadFileToStorage(companyId, "documents", "estimates", "valuation.pdf"); 841 console.log("Valuation PDF uploaded"); 842 console.log("Terms PDF uploaded"); 843 const mobileLogo = { 844 type: "mobile", 845 fileName: mobileLogoFileName, 846 created: firebase.firestore.Timestamp.now() 847 }; 848 const desktopLogo = { 849 type: "desktop", 850 fileName: desktopLogoFileName, 851 created: firebase.firestore.Timestamp.now() 852 }; 853 const estimateDocs = ESTIMATEDOCSNOFILENAME; 854 estimateDocs[0].fileName = valuationFileName; 855 const initialSettings = { 856 companyName: this.createAccountForm.value["companyName"], 857 companyNameLink: this.createAccountForm.value["companyNameLink"], 858 estimateEmail: this.createAccountForm.value["estimateEmail"], 859 mobileLogo, 860 desktopLogo 861 }; 862 const initialTeam = { 863 address: this.createAccountForm.value["address"], 864 phone: this.createAccountForm.value["phone"], 865 name: this.createAccountForm.value["dispatchName"], 866 calendarName: `${this.createAccountForm.value["dispatchShortName"].toUpperCase()} TEAM`, 867 state: this.state, 868 timezone: this.timezone, 869 coordinate: this.coordinate, 870 shortName: this.createAccountForm.value["dispatchShortName"].toUpperCase(), 871 standardPay: QUOTE_CONSTANTS.teamMemberRate, 872 leadPay: QUOTE_CONSTANTS.teamLeaderRate, 873 customerLaborRate: QUOTE_CONSTANTS.customerLaborRate, 874 truckFuelCost: QUOTE_CONSTANTS.truckFuelCost, 875 truckCustomerHourlyRate: QUOTE_CONSTANTS.truckCustomerHourlyRate, 876 minimumHoursForJob: QUOTE_CONSTANTS.minimumHoursForJob 877 }; 878 this.saasDefaultCustomerService.createNewDefaultSaasCustomerSettings(initialSettings, estimateDocs, c
878ompanyId).then(() => { 879 this.saasDefaultCustomerService.createNewDefaultSaasCustomerTeam(initialTeam, companyId).then((team) => { 880 console.log("team = ", team); 881 this.authService.authState$().pipe(first()).subscribe((fbUser) => { 882 if (fbUser) { 883 this.teamsService.createTeamMembership(fbUser, team.id); 884 } 885 }); 886 }).catch((error) => console.log("error save new default team: ", error)); 887 }).catch((error) => console.log("error save new default customer settings: ", error)); 888 } 889 }); 890 } 891 uploadFileToStorage(saasCustomerId, fileType, folder, assetFileName, filenamePrefix) { 892 return __async(this, null, function* () { 893 console.log(`Loading file "${assetFileName}" from assets...`); 894 const filename = yield firstValueFrom(this.http.get(`assets/${fileType}/${assetFileName}`, { responseType: "blob" }).pipe(map((data) => __async(this, null, function* () { 895 console.log("File loaded"); 896 const reader = new FileReader(); 897 reader.readAsDataURL(data); 898 const fileId = this.storageService.createImageId(); 899 const filename2 = filenamePrefix ? filenamePrefix : fileId; 900 console.log("Uploading..."); 901 yield this.storageService.saasUploadFileFromInput(saasCustomerId, fileType, folder, filename2, data); 902 console.log("Finished uploading", filename2); 903 return filename2; 904 })))); 905 console.log("Returning file name:", filename); 906 return filename; 907 }); 908 } 909 stringToNameLink(input) { 910 return (input || "").replace(/[^a-z0-9-]/gi, "").toLowerCase(); 911 } 912 getPhone() { 913 return this.createAccountForm.get("phone"); 914 } 915 confirmationEmailValidator(control) { 916 const emailControl = control.get("email"); 917 const confirmEmailControl = control.get("confirmEmail"); 918 if (emailControl?.valid) { 919 if (emailControl.value !== confirmEmailControl?.value) { 920 confirmEmailControl?.setErrors({ invalidEmailConfirmation: true }); 921 console.log("Setting Error:", confirmEmailControl); 922 return { invalidEmailConfirmation: true }; 923 } 924 } 925 return null; 926 } 927 static \u0275fac = function SaasAccountSignupComponent_Factory(__ngFactoryType__) { 928 return new (__ngFactoryType__ || _SaasAccountSignupComponent)(\u0275\u0275directiveInject(AuthenticationService), \u0275\u0275directiveInject(AppUsersService), \u0275\u0275directiveInject(SaasCustomerService), \u0275\u0275directiveInject(SaasDefaultCustomerService), \u0275\u0275directiveInject(Router), \u0275\u0275directiveInject(StorageService), \u0275\u0275directiveInject(TeamsService), \u0275\u0275directiveInject(HttpClient), \u0275\u0275directiveInject(MatDialog), \u0275\u0275directiveInject("environment")); 929 }; 930 static \u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _SaasAccountSignupComponent, selectors: [["md-apps-saas-account-signup"]], decls: 23, vars: 1, consts: [["termsAgree", ""], ["googleMap", ""], ["fxLayout", "row", "fxLayoutAlign", "start start", 1, "content-area"], ["fxFlex", ""], ["fxFlex", "0 1 450px"], ["fxLayout", "row"], ["fxFlex", "25"], ["src", "assets/images/md-desktop-logo.png"], ["fxFlex", "5"], ["fxFlex", "auto", "fxLayout", "column", 1, "centered-text"], ["href", "/"], [3, "formGroup", "ngSubmit", 4, "ngIf"], [3, "ngSubmit", "formGroup"], ["fxLayout", "row", 1, "form-subsection", "space-above"], ["fxFlex", "auto", "fxLayout", "column"], ["fxFlex", "auto"], ["matInput", "", "formControlName", "email", "type", "email"], [4, "ngIf"], ["matInput", "", "formControlName", "confirmEmail", "type", "email"], ["matInput", "", "formControlName", "password", 3, "type"], ["mat-icon-button", "", "matSuffix", "", "type", "button", 3, "click"], ["matInput", "", "formControlName", "firstName"], ["matInput", "", "formControlName", "lastName"], [2, "width", "100%", 3, "update", "validNumber", "value", "customLabel"], ["matInput", "", "placeholder", "Company Name", "formControlName", "companyName"], ["matInput", "", "placeholder", "Name link (min 3 chars, all lower case)", "formControlName", "companyNameLink"], ["matInput", "", "placeholder", "Email to show on estimates", "formControlName", "estimateEmail"], ["fxFlex", "auto", 3, "autocompleteSelected", "includeAddressComponents", "addressInputFormControl"], ["fxFlex", "auto", "width", "100%", 3, "options", "height", 4, "ngIf"], ["fxLayout", "row", 1, "space-above"], ["href", "https://movedetails.com/privacy-policy/", "target", "_blank"], ["href", "https://movedetails.com/terms-and-conditions/", "target", "_blank"], ["fxFlex", "auto", "mat-raised-button", "", "color", "primary", 1, "setup-button", 3, "disabled"], ["fxFlex", "auto", "width", "100%", 3, "options", "height"], [3, "position", "options", 4, "ngIf"], [3, "position", "options"]], template: function SaasAccountSignupComponent_Template(rf, ctx) { 931 if (rf & 1) { 932 \u0275\u0275elementStart(0, "div", 2); 933 \u0275\u0275element(1, "div", 3); 934 \u0275\u0275elementStart(2, "div", 4)(3, "div", 5); 935 \u0275\u0275element(4, "div", 6); 936 \u0275\u0275elementStart(5, "div", 3); 937 \u0275\u0275element(6, "img", 7); 938 \u0275\u0275elementEnd(); 939 \u0275\u0275element(7, "div", 6); 940 \u0275\u0275elementEnd(); 941 \u0275\u0275elementStart(8, "div", 5); 942 \u0275\u0275element(9, "div", 8); 943 \u0275\u0275elementStart(10, "div", 9)(11, "h4"); 944 \u0275\u0275text(12, "Create New Account"); 945 \u0275\u0275elementEnd()(); 946 \u0275\u0275element(13, "div", 8); 947 \u0275\u0275elementEnd(); 948 \u0275\u0275elementStart(14, "div", 5); 949 \u0275\u0275element(15, "div", 8); 950 \u0275\u0275elementStart(16, "div", 9)(17, "h6")(18, "a", 10); 951 \u0275\u0275text(19, "Existing user? Log in here."); 952 \u0275\u0275elementEnd()()();
953 \u0275\u0275element(20, "div", 8); 954 \u0275\u0275elementEnd(); 955 \u0275\u0275template(21, SaasAccountSignupComponent_form_21_Template, 92, 30, "form", 11); 956 \u0275\u0275elementEnd(); 957 \u0275\u0275element(22, "div", 3); 958 \u0275\u0275elementEnd(); 959 } 960 if (rf & 2) { 961 \u0275\u0275advance(21); 962 \u0275\u0275property("ngIf", ctx.createAccountForm); 963 } 964 }, dependencies: [NgIf, \u0275NgNoValidate, DefaultValueAccessor, NgControlStatus, NgControlStatusGroup, FormGroupDirective, FormControlName, DefaultLayoutDirective, DefaultLayoutAlignDirective, DefaultFlexDirective, MatFormField, MatLabel, MatHint, MatError, MatSuffix, MatInput, MatButton, MatIconButton, GoogleMap, MapMarker, AddressInputComponent, PhoneNumberUIComponent, MatIcon, MatCheckbox], styles: ["\n\n.content-area[_ngcontent-%COMP%] {\n background-color: #fff;\n height: 100%;\n margin-left: auto;\n margin-right: auto;\n}\n.setup-button[_ngcontent-%COMP%] {\n margin-top: 28px;\n margin-bottom: 32px;\n}\nimg[_ngcontent-%COMP%] {\n transform: scale(0.7);\n}\n.nameLinkNoError[_ngcontent-%COMP%] {\n font-size: 0.8rem;\n margin-top: -1rem;\n}\n.nameLinkHasError[_ngcontent-%COMP%] {\n font-size: 0.8rem;\n}\n.centered-text[_ngcontent-%COMP%] {\n text-align: center;\n}\n.form-subsection[_ngcontent-%COMP%] {\n margin: 0px 4px;\n padding-top: 4px;\n border-radius: 5px;\n border: lightgray;\n border-style: solid;\n border-width: 1px;\n}\n.space-above[_ngcontent-%COMP%] {\n margin-top: 10px;\n}"] }); 965}; 966(() => { 967 (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(SaasAccountSignupComponent, { className: "SaasAccountSignupComponent" }); 968})(); 969
970// libs/saas-account-signup/src/lib/saas-account-signup.routing.ts 971var routes = [ 972 // { 973 // path: 'success', 974 // component: SuccessComponent, 975 // }, 976 { 977 path: "", 978 component: SaasAccountSignupComponent, 979 canActivate: [] 980 } 981]; 982var SaasAccountSignupRoutingModule = class _SaasAccountSignupRoutingModule { 983 static \u0275fac = function SaasAccountSignupRoutingModule_Factory(__ngFactoryType__) { 984 return new (__ngFactoryType__ || _SaasAccountSignupRoutingModule)(); 985 }; 986 static \u0275mod = /* @__PURE__ */ \u0275\u0275defineNgModule({ type: _SaasAccountSignupRoutingModule }); 987 static \u0275inj = /* @__PURE__ */ \u0275\u0275defineInjector({ imports: [RouterModule.forChild(routes), RouterModule] }); 988}; 989
990// libs/saas-account-signup/src/lib/success/success.component.ts 991function SuccessComponent_p_19_span_4_span_1_Template(rf, ctx) { 992 if (rf & 1) { 993 \u0275\u0275elementStart(0, "span"); 994 \u0275\u0275text(1, " and "); 995 \u0275\u0275elementStart(2, "strong"); 996 \u0275\u0275text(3); 997 \u0275\u0275elementEnd()(); 998 } 999 if (rf & 2) { 1000 const saasSettings_r1 = \u0275\u0275nextContext().ngIf; 1001 \u0275\u0275advance(3); 1002 \u0275\u0275textInterpolate(saasSettings_r1.estimateEmail); 1003 } 1004} 1005function SuccessComponent_p_19_span_4_Template(rf, ctx) { 1006 if (rf & 1) { 1007 \u0275\u0275elementStart(0, "span"); 1008 \u0275\u0275template(1, SuccessComponent_p_19_span_4_span_1_Template, 4, 1, "span", 10); 1009 \u0275\u0275elementEnd(); 1010 } 1011 if (rf & 2) { 1012 const saasSettings_r1 = ctx.ngIf; 1013 const agu_r2 = \u0275\u0275nextContext().ngIf; 1014 \u0275\u0275advance(); 1015 \u0275\u0275property("ngIf", saasSettings_r1.estimateEmail !== agu_r2.appUser.email); 1016 } 1017} 1018function SuccessComponent_p_19_Template(rf, ctx) { 1019 if (rf & 1) { 1020 \u0275\u0275elementStart(0, "p"); 1021 \u0275\u0275text(1, "An email has been sent to "); 1022 \u0275\u0275elementStart(2, "strong"); 1023 \u0275\u0275text(3); 1024 \u0275\u0275elementEnd(); 1025 \u0275\u0275template(4, SuccessComponent_p_19_span_4_Template, 2, 1, "span", 10); 1026 \u0275\u0275pipe(5, "async"); 1027 \u0275\u0275text(6, " with some basic instructions on how to use the application. You will also find useful help videos on most pages of the app by clicking the circular question mark icon at the bottom right of the page. "); 1028 \u0275\u0275elementEnd(); 1029 } 1030 if (rf & 2) { 1031 const agu_r2 = ctx.ngIf; 1032 const ctx_r2 = \u0275\u0275nextContext(); 1033 \u0275\u0275advance(3); 1034 \u0275\u0275textInterpolate(agu_r2.appUser.email); 1035 \u0275\u0275advance(); 1036 \u0275\u0275property("ngIf", \u0275\u0275pipeBind1(5, 2, ctx_r2.saasSettings$)); 1037 } 1038} 1039var SuccessComponent = class _SuccessComponent { 1040 appUsersService; 1041 saasCustomerService; 1042 emailTemplatesService; 1043 activatedRoute; 1044 router; 1045 agu$; 1046 saasSettings$; 1047 constructor(appUsersService, saasCustomerService, emailTemplatesService, activatedRoute, router) { 1048 this.appUsersService = appUsersService; 1049 this.saasCustomerService = saasCustomerService; 1050 this.emailTemplatesService = emailTemplatesService; 1051 this.activatedRoute = activatedRoute; 1052 this.router = router; 1053 } 1054 ngOnInit() { 1055 console.log("Success Component"); 1056 this.agu$ = this.appUsersService.aggregatedUser$; 1057 this.saasCustomerService.setNewSaasCustomerIdObservable({ 1058 paramMap$: this.activatedRoute.paramMap, 1059 agu$: this.agu$ 1060 }); 1061 this.saasSettings$ = this.saasCustomerService.saasCustomerSettings$(); 1062 this.emailTemplatesService.updateTemplateUrls(); 1063 } 1064 navigateToSettings() { 1065 console.log("NTS"); 1066 this.agu$.pipe(switchMap((agu) => this.saasCustomerService.saasCompanyNameLinkFromId$(`${agu.saasCustomerId}`)), first()).subscribe((nameLink) => this.router.navigate(["/", nameLink.nameLink, "admin-oauth"])); 1067 } 1068 static \u0275fac = function SuccessComponent_Factory(__ngFactoryType__) { 1069 return new (__ngFactoryType__ || _SuccessComponent)(\u0275\u0275directiveInject(AppUsersService), \u0275\u0275directiveInject(SaasCustomerService), \u0275\u0275directiveInject(EmailTemplatesService), \u0275\u0275directiveInject(ActivatedRoute), \u0275\u0275directiveInject(Router)); 1070 }; 1071 static \u0275cmp = /* @__PURE__ */ \u0275\u0275defineComponent({ type: _SuccessComponent, selectors: [["md-apps-success"]], decls: 37, vars: 3, consts: [["fxLayout", "row", "fxLayoutAlign", "start start", 1, "content-area"], ["fxFlex.gt-md", "30", "fxFlex.gt-sm", "20", "fxFlex.gt-sm", "10"], ["fxFlex", "auto"], ["fxLayout", "row"], ["fxFlex", "25"], ["fxFlex", ""], ["src", "assets/images/md-desktop-logo.png"], ["fxFlex", "5"], ["fxFlex", "auto", "fxLayout", "column", 1, "centered-text"], ["fxFlex", "auto", "fxLayout", "column"], [4, "ngIf"], ["mat-raised-button", "", "color", "primary", 3, "click"]], template: function SuccessComponent_Template(rf, ctx) { 1072 if (rf & 1) { 1073 \u0275\u0275elementStart(0, "div", 0); 1074 \u0275\u0275element(1, "div", 1); 1075 \u0275\u0275elementStart(2, "div", 2)(3, "div", 3); 1076 \u0275\u0275element(4, "div", 4); 1077 \u0275\u0275elementStart(5, "div", 5); 1078 \u0275\u0275element(6, "img", 6); 1079 \u0275\u0275elementEnd(); 1080 \u0275\u0275element(7, "div", 4); 1081 \u0275\u0275elementEnd(); 1082 \u0275\u0275elementStart(8, "div", 3); 1083 \u0275\u0275element(9, "div", 7); 1084 \u0275\u0275elementStart(10, "div", 8)(11, "h1"); 1085 \u0275\u0275text(12, "Congratulations!"); 1086 \u0275\u0275elementEnd()(); 1087 \u0275\u0275element(13, "div", 7); 1088 \u0275\u0275elementEnd(); 1089 \u0275\u0275elementStart(14, "div", 3); 1090 \u0275\u0275element(15, "div", 7); 1091 \u0275\u0275elementStart(16, "div", 9)(17, "h3"); 1092 \u0275\u0275text(18, "Your Move Details account has been created!"); 1093 \u0275\u0275elementEnd(); 1094 \u0275\u0275template(19, SuccessComponent_p_19_Template, 7, 4, "p", 10); 1095 \u0275\u0275pipe(20, "async"); 1096 \u0275\u0275elementStart(21, "h2"); 1097 \u0275\u0275text(22, "First Steps"); 1098 \u0275\u0275elementEnd(); 1099 \u0275\u0275elementStart(23, "h3"); 1100 \u0275\u0275text(24, "Authenticate Master Google Account"); 1101 \u0275\u0275elementEnd(); 1102 \u0275\u0275elementStart(25, "p"); 1103 \u0275\u0275text(26, "Before doing anything else, we suggest you go to your account settings page to authenticate your Google account. We use this to send emails on your behalf. Additionally, we populate this account's Google Calendar with all of your pending and booked jobs."); 1104 \u0275\u0275elementEnd(); 1105 \u0275\u0275elementStart(27, "h3"); 1106 \u0275\u0275text(28, "Connect to Stripe"); 1107 \u0275\u0275elementEnd(); 1108 \u0275\u0275elementStart(29, "p"); 1109 \u0275\u0275text(30, "While on your settings page, we also suggest connecting a Stripe account so that you'll be able to accept payments from your customers using Move Details."); 1110 \u0275\u0275elementEnd(); 1111 \u0275\u0275elementStart(31, "h3"); 1112 \u0275\u0275text(32, "Click the button to go to your account settings..."); 1113 \u0275\u0275elementEnd(); 1114 \u0275\u0275elementStart(33, "button", 11); 1115 \u0275\u0275listener("click", function SuccessComponent_Template_button_click_33_listener() { 1116 return ctx.navigateToSettings(); 1117 }); 1118 \u0275\u0275text(34, "Account Settings"); 1119 \u0275\u0275elementEnd()(); 1120 \u0275\u0275element(35, "div", 7); 1121 \u0275\u0275elementEnd()(); 1122 \u0275\u0275element(36, "div", 1); 1123 \u0275\u0275elementEnd(); 1124 } 1125 if (rf & 2) { 1126 \u0275\u0275advance(19); 1127 \u0275\u0275property("ngIf", \u0275\u0275pipeBind1(20, 1, ctx.agu$)); 1128 } 1129 }, dependencies: [NgIf, DefaultLayoutDirective, DefaultLayoutAlignDirective, DefaultFlexDirective, MatButton, AsyncPipe], styles: ["\n\n.content-area[_ngcontent-%COMP%] {\n background-color: #fff;\n height: 100%;\n}\n.setup-button[_ngcontent-%COMP%] {\n margin-top: 48px;\n margin-bottom: 32px;\n}\nimg[_ngcontent-%COMP%] {\n transform: scale(0.7);\n}\n.nameLinkNoError[_ngcontent-%COMP%] {\n font-size: 0.8rem;\n margin-top: -1rem;\n}\n.nameLinkHasError[_ngcontent-%COMP%] {\n font-size: 0.8rem;\n}\n.centered-text[_ngcontent-%COMP%] {\n text-align: center;\n}\n.form-subsection[_ngcontent-%COMP%] {\n margin: 0px 10px;\n padding-top: 10px;\n border-radius: 5px;\n border: lightgray;\n border-style: solid;\n border-width: 1px;\n}\n.space-above[_ngcontent-%COMP%] {\n margin-top: 15px;\n}"] }); 1130}; 1131(() => { 1132 (typeof ngDevMode === "undefined" || ngDevMode) && \u0275setClassDebugInfo(SuccessComponent, { className: "SuccessComponent" }); 1133})(); 1134
1135// libs/saas-account-signup/src/lib/saas-account-signup.module.ts 1136var SaasAccountSignupModule = class _SaasAccountSignupModule { 1137 static \u0275fac = function SaasAccountSignupModule_Factory(__ngFactoryType__) { 1138 return new (__ngFactoryType__ || _SaasAccountSignupModule)(); 1139 }; 1140 static \u0275mod = /* @__PURE__ */ \u0275\u0275defineNgModule({ type: _SaasAccountSignupModule }); 1141 static \u0275inj = /* @__PURE__ */ \u0275\u0275defineInjector({ providers: [SignedOutGuard], imports: [ 1142 CommonModule, 1143 SaasAccountSignupRoutingModule, 1144 ReactiveFormsModule, 1145 FlexLayoutModule, 1146 MatCardModule, 1147 MatFormFieldModule, 1148 MatInputModule, 1149 MatButtonModule, 1150 GoogleMapsModule, 1151 AddressAutocompleteModule, 1152 CurrencyInputModule, 1153 PhoneNumberUIModule, 1154 MatIconModule, 1155 MatCheckboxModule 1156 ] }); 1157}; 1158export { 1159 SaasAccountSignupModule 1160};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.