@snabcentr/client-ui 0.18.0 → 0.19.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,9 +1,9 @@
1
1
  import * as i0 from '@angular/core';
2
2
  import { EventEmitter, Component, ChangeDetectionStrategy, Inject, Input, Output, NgModule, Directive, HostBinding, ContentChild, ViewChild, Injectable, ElementRef, ContentChildren, HostListener, ChangeDetectorRef, Optional, Self, inject, InjectionToken, SkipSelf, forwardRef } from '@angular/core';
3
- import * as i10 from 'rxjs';
4
- import { Subject, filter, map, switchMap, tap, catchError, of, finalize, startWith, share, timer, scan, takeWhile, endWith, distinctUntilChanged, shareReplay, interval, takeUntil, skip, debounceTime, merge, throwError, combineLatest } from 'rxjs';
5
3
  import * as i1 from '@snabcentr/client-core';
6
4
  import { ScUserMetrikaGoalsEnum, SC_URLS, SC_PATH_IMAGE_NOT_FOUND, SEARCH_TERM, SEARCH_TERM_PROVIDERS, ScCatalogService, ScCartService, ScAuthService, ScISuggestionType, ScOpfList, ScIconTypesEnum, ScUserService } from '@snabcentr/client-core';
5
+ import * as i10 from 'rxjs';
6
+ import { Subject, filter, map, switchMap, tap, catchError, of, finalize, startWith, share, timer, scan, takeWhile, endWith, distinctUntilChanged, shareReplay, interval, takeUntil, skip, debounceTime, merge, throwError, combineLatest } from 'rxjs';
7
7
  import * as i2 from '@angular/common';
8
8
  import { CommonModule } from '@angular/common';
9
9
  import * as i4 from '@taiga-ui/core';
@@ -294,11 +294,9 @@ class ScSignInFormByPhoneComponent {
294
294
  * Инициализирует экземпляр класса {@link ScSignInFormByPhoneComponent}.
295
295
  *
296
296
  * @param authService Сервис аутентификации.
297
- * @param userMetrikaService Сервис для сбора метрик о действиях пользователей.
298
297
  */
299
- constructor(authService, userMetrikaService) {
298
+ constructor(authService) {
300
299
  this.authService = authService;
301
- this.userMetrikaService = userMetrikaService;
302
300
  /**
303
301
  * Наличие кода подтверждения у пользователя.
304
302
  */
@@ -333,22 +331,13 @@ class ScSignInFormByPhoneComponent {
333
331
  */
334
332
  this.loading$ = this.request$.pipe(map(tuiIsFalsy));
335
333
  }
336
- /** @inheritDoc */
337
- ngOnInit() {
338
- this.userMetrikaService.emitUserMetrikaEvent({
339
- target: ScUserMetrikaGoalsEnum.signInShow,
340
- params: {
341
- type: 'phone',
342
- },
343
- });
344
- }
345
334
  }
346
- ScSignInFormByPhoneComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ScSignInFormByPhoneComponent, deps: [{ token: i1.ScAuthService }, { token: i1.ScUserMetrikaService }], target: i0.ɵɵFactoryTarget.Component });
335
+ ScSignInFormByPhoneComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ScSignInFormByPhoneComponent, deps: [{ token: i1.ScAuthService }], target: i0.ɵɵFactoryTarget.Component });
347
336
  ScSignInFormByPhoneComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: ScSignInFormByPhoneComponent, selector: "sc-sign-in-form-by-phone", ngImport: i0, template: "<form [formGroup]=\"form\" *tuiLet=\"!!(loading$ | async) as loading\" (ngSubmit)=\"onSubmit.next()\" class=\"flex flex-col gap-4 items-center mb-4\">\n <sc-verification-phone-check-form [(haveCode)]=\"haveCode\" [shouldBeBusy]=\"true\" [shouldBeConfirmed]=\"true\" class=\"w-full\"></sc-verification-phone-check-form>\n <button *ngIf=\"haveCode\" tuiButton type=\"submit\" [showLoader]=\"loading\" [disabled]=\"form.invalid || loading\" icon=\"scIconLogIn\">\u0412\u043E\u0439\u0442\u0438</button>\n</form>\n", dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i4.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { kind: "directive", type: i6.TuiLetDirective, selector: "[tuiLet]", inputs: ["tuiLet"] }, { kind: "component", type: ScVerificationPhoneCheckFormComponent, selector: "sc-verification-phone-check-form", inputs: ["showCodeFields", "readOnly", "shouldBeBusy", "shouldBeConfirmed", "haveCode"], outputs: ["haveCodeChange"] }, { kind: "pipe", type: i2.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
348
337
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ScSignInFormByPhoneComponent, decorators: [{
349
338
  type: Component,
350
339
  args: [{ selector: 'sc-sign-in-form-by-phone', changeDetection: ChangeDetectionStrategy.OnPush, template: "<form [formGroup]=\"form\" *tuiLet=\"!!(loading$ | async) as loading\" (ngSubmit)=\"onSubmit.next()\" class=\"flex flex-col gap-4 items-center mb-4\">\n <sc-verification-phone-check-form [(haveCode)]=\"haveCode\" [shouldBeBusy]=\"true\" [shouldBeConfirmed]=\"true\" class=\"w-full\"></sc-verification-phone-check-form>\n <button *ngIf=\"haveCode\" tuiButton type=\"submit\" [showLoader]=\"loading\" [disabled]=\"form.invalid || loading\" icon=\"scIconLogIn\">\u0412\u043E\u0439\u0442\u0438</button>\n</form>\n" }]
351
- }], ctorParameters: function () { return [{ type: i1.ScAuthService }, { type: i1.ScUserMetrikaService }]; } });
340
+ }], ctorParameters: function () { return [{ type: i1.ScAuthService }]; } });
352
341
 
353
342
  /**
354
343
  * Компонент аутентификации по адресу электронной почты и паролю.
@@ -358,11 +347,9 @@ class ScSignInFormByEmailComponent {
358
347
  * Инициализирует экземпляр класса {@link ScSignInFormByEmailComponent}.
359
348
  *
360
349
  * @param authService Сервис аутентификации.
361
- * @param userMetrikaService Сервис для сбора метрик о действиях пользователей.
362
350
  */
363
- constructor(authService, userMetrikaService) {
351
+ constructor(authService) {
364
352
  this.authService = authService;
365
- this.userMetrikaService = userMetrikaService;
366
353
  /**
367
354
  * Группа полей ввода для формы «Вход на сайт».
368
355
  */
@@ -397,22 +384,13 @@ class ScSignInFormByEmailComponent {
397
384
  */
398
385
  this.forgotPassword = new EventEmitter();
399
386
  }
400
- /** @inheritDoc */
401
- ngOnInit() {
402
- this.userMetrikaService.emitUserMetrikaEvent({
403
- target: ScUserMetrikaGoalsEnum.signInShow,
404
- params: {
405
- type: 'email',
406
- },
407
- });
408
- }
409
387
  }
410
- ScSignInFormByEmailComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ScSignInFormByEmailComponent, deps: [{ token: i1.ScAuthService }, { token: i1.ScUserMetrikaService }], target: i0.ɵɵFactoryTarget.Component });
388
+ ScSignInFormByEmailComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ScSignInFormByEmailComponent, deps: [{ token: i1.ScAuthService }], target: i0.ɵɵFactoryTarget.Component });
411
389
  ScSignInFormByEmailComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: ScSignInFormByEmailComponent, selector: "sc-sign-in-form-by-email", outputs: { forgotPassword: "forgotPassword" }, ngImport: i0, template: "<form [formGroup]=\"formByEmail\" (ngSubmit)=\"onSubmit.next()\">\n <div class=\"flex flex-col gap-4 mb-8\">\n <label tuiLabel=\"\u0410\u0434\u0440\u0435\u0441 \u044D\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u043E\u0439 \u043F\u043E\u0447\u0442\u044B\">\n <tui-input formControlName=\"login\">\n \u0410\u0434\u0440\u0435\u0441 \u044D\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u043E\u0439 \u043F\u043E\u0447\u0442\u044B\n <input tuiTextfield autocomplete=\"email\" />\n </tui-input>\n <tui-error formControlName=\"login\" [error]=\"[] | tuiFieldError | async\"></tui-error>\n </label>\n <label tuiLabel=\"\u041F\u0430\u0440\u043E\u043B\u044C\">\n <tui-input-password formControlName=\"password\">\n \u041F\u0430\u0440\u043E\u043B\u044C\n <input tuiTextfield autocomplete=\"current-password\" />\n </tui-input-password>\n <tui-error formControlName=\"password\" [error]=\"[] | tuiFieldError | async\"></tui-error>\n </label>\n <tui-error [error]=\"[] | tuiFieldError | async\"></tui-error>\n </div>\n <div class=\"flex flex-col gap-4 items-center mb-4\">\n <a tuiLink [pseudo]=\"true\" (click)=\"forgotPassword.emit()\" class=\"text-base\">\u0417\u0430\u0431\u044B\u043B\u0438 \u043F\u0430\u0440\u043E\u043B\u044C?</a>\n <button tuiButton type=\"submit\" [showLoader]=\"!!(loadingEmailAuth$ | async)\" [disabled]=\"formByEmail.invalid || !!(loadingEmailAuth$ | async)\" icon=\"scIconLogIn\">\n \u0412\u043E\u0439\u0442\u0438\n </button>\n </div>\n</form>\n", dependencies: [{ kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i4$1.TuiInputPasswordComponent, selector: "tui-input-password" }, { kind: "directive", type: i4$1.TuiInputPasswordDirective, selector: "tui-input-password" }, { kind: "component", type: i4.TuiTextfieldComponent, selector: "input[tuiTextfield], textarea[tuiTextfield]" }, { kind: "component", type: i4$1.TuiInputComponent, selector: "tui-input" }, { kind: "directive", type: i4$1.TuiInputDirective, selector: "tui-input" }, { kind: "component", type: i4.TuiLinkComponent, selector: "a[tuiLink], button[tuiLink]", inputs: ["pseudo", "icon", "iconAlign", "iconRotated", "mode"], exportAs: ["tuiLink"] }, { kind: "component", type: i4.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { kind: "component", type: i4.TuiLabelComponent, selector: "label[tuiLabel]", inputs: ["tuiLabel", "context"] }, { kind: "component", type: i4.TuiErrorComponent, selector: "tui-error", inputs: ["error"] }, { kind: "pipe", type: i2.AsyncPipe, name: "async" }, { kind: "pipe", type: i4$1.TuiFieldErrorPipe, name: "tuiFieldError" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
412
390
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ScSignInFormByEmailComponent, decorators: [{
413
391
  type: Component,
414
392
  args: [{ selector: 'sc-sign-in-form-by-email', changeDetection: ChangeDetectionStrategy.OnPush, template: "<form [formGroup]=\"formByEmail\" (ngSubmit)=\"onSubmit.next()\">\n <div class=\"flex flex-col gap-4 mb-8\">\n <label tuiLabel=\"\u0410\u0434\u0440\u0435\u0441 \u044D\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u043E\u0439 \u043F\u043E\u0447\u0442\u044B\">\n <tui-input formControlName=\"login\">\n \u0410\u0434\u0440\u0435\u0441 \u044D\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u043E\u0439 \u043F\u043E\u0447\u0442\u044B\n <input tuiTextfield autocomplete=\"email\" />\n </tui-input>\n <tui-error formControlName=\"login\" [error]=\"[] | tuiFieldError | async\"></tui-error>\n </label>\n <label tuiLabel=\"\u041F\u0430\u0440\u043E\u043B\u044C\">\n <tui-input-password formControlName=\"password\">\n \u041F\u0430\u0440\u043E\u043B\u044C\n <input tuiTextfield autocomplete=\"current-password\" />\n </tui-input-password>\n <tui-error formControlName=\"password\" [error]=\"[] | tuiFieldError | async\"></tui-error>\n </label>\n <tui-error [error]=\"[] | tuiFieldError | async\"></tui-error>\n </div>\n <div class=\"flex flex-col gap-4 items-center mb-4\">\n <a tuiLink [pseudo]=\"true\" (click)=\"forgotPassword.emit()\" class=\"text-base\">\u0417\u0430\u0431\u044B\u043B\u0438 \u043F\u0430\u0440\u043E\u043B\u044C?</a>\n <button tuiButton type=\"submit\" [showLoader]=\"!!(loadingEmailAuth$ | async)\" [disabled]=\"formByEmail.invalid || !!(loadingEmailAuth$ | async)\" icon=\"scIconLogIn\">\n \u0412\u043E\u0439\u0442\u0438\n </button>\n </div>\n</form>\n" }]
415
- }], ctorParameters: function () { return [{ type: i1.ScAuthService }, { type: i1.ScUserMetrikaService }]; }, propDecorators: { forgotPassword: [{
393
+ }], ctorParameters: function () { return [{ type: i1.ScAuthService }]; }, propDecorators: { forgotPassword: [{
416
394
  type: Output
417
395
  }] } });
418
396
 
@@ -424,9 +402,11 @@ class ScSignInFormComponent {
424
402
  * Инициализирует экземпляр класса {@link ScSignInFormComponent}.
425
403
  *
426
404
  * @param authService Сервис аутентификации.
405
+ * @param userMetrikaService Сервис для сбора метрик о действиях пользователей.
427
406
  */
428
- constructor(authService) {
407
+ constructor(authService, userMetrikaService) {
429
408
  this.authService = authService;
409
+ this.userMetrikaService = userMetrikaService;
430
410
  /**
431
411
  * Выбранный способ аутентификации.
432
412
  */
@@ -448,6 +428,15 @@ class ScSignInFormComponent {
448
428
  */
449
429
  this.successAuth = this.authService.getAuthChange().pipe(filter((state) => state));
450
430
  }
431
+ /** @inheritDoc */
432
+ ngOnInit() {
433
+ this.userMetrikaService.emitUserMetrikaEvent({
434
+ target: ScUserMetrikaGoalsEnum.signInShow,
435
+ params: {
436
+ type: this.authMethod,
437
+ },
438
+ });
439
+ }
451
440
  /**
452
441
  * Осуществляет переключение способов аутентификации.
453
442
  *
@@ -455,6 +444,12 @@ class ScSignInFormComponent {
455
444
  */
456
445
  switchAuth(authMethod) {
457
446
  this.authMethod = authMethod;
447
+ this.userMetrikaService.emitUserMetrikaEvent({
448
+ target: ScUserMetrikaGoalsEnum.signInShow,
449
+ params: {
450
+ type: authMethod,
451
+ },
452
+ });
458
453
  }
459
454
  /**
460
455
  * Обрабатывает нажатие на кнопку "Забыли пароль" и выдает сигнал об этом.
@@ -463,12 +458,12 @@ class ScSignInFormComponent {
463
458
  this.forgotPassword.emit();
464
459
  }
465
460
  }
466
- ScSignInFormComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ScSignInFormComponent, deps: [{ token: i1.ScAuthService }], target: i0.ɵɵFactoryTarget.Component });
467
- ScSignInFormComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: ScSignInFormComponent, selector: "sc-sign-in-form", inputs: { authMethod: "authMethod" }, outputs: { forgotPassword: "forgotPassword", signUp: "signUp", successAuth: "successAuth" }, ngImport: i0, template: "<div class=\"flex justify-center mb-4\">\n <button\n tuiButton\n [tuiMode]=\"authMethod === 'by_phone' ? null : 'onLight'\"\n [appearance]=\"authMethod === 'by_phone' ? 'primary' : 'secondary'\"\n (click)=\"switchAuth(method.byPhone)\"\n class=\"tui-space_right-3 tui-space_bottom-3 !font-bold\"\n >\n \u041F\u043E \u0442\u0435\u043B\u0435\u0444\u043E\u043D\u0443\n </button>\n\n <button\n tuiButton\n [tuiMode]=\"authMethod === 'by_email' ? null : 'onLight'\"\n [appearance]=\"authMethod === 'by_email' ? 'primary' : 'secondary'\"\n (click)=\"switchAuth(method.byEmail)\"\n class=\"tui-space_left-3 tui-space_bottom-3 !font-bold\"\n >\n \u041F\u043E e-mail\n </button>\n</div>\n\n<sc-sign-in-form-by-email *ngIf=\"authMethod === 'by_email'\" (forgotPassword)=\"onForgotPassword()\"></sc-sign-in-form-by-email>\n\n<sc-sign-in-form-by-phone [class.hidden]=\"authMethod !== 'by_phone'\"></sc-sign-in-form-by-phone>\n\n<div class=\"flex flex-col gap-4 items-center\">\n <span class=\"font-medium text-tui-text-02\">\u0415\u0449\u0435 \u043D\u0435 \u0437\u0430\u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u043E\u0432\u0430\u043D\u044B?</span>\n <button tuiButton tuiMode=\"onLight\" (click)=\"signUp.emit()\" type=\"button\" icon=\"scIconAddProfile\" appearance=\"secondary\">\u0417\u0430\u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u043E\u0432\u0430\u0442\u044C\u0441\u044F</button>\n</div>\n", dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i4.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { kind: "directive", type: i4.TuiModeDirective, selector: "[tuiMode]", inputs: ["tuiMode"] }, { kind: "component", type: ScSignInFormByPhoneComponent, selector: "sc-sign-in-form-by-phone" }, { kind: "component", type: ScSignInFormByEmailComponent, selector: "sc-sign-in-form-by-email", outputs: ["forgotPassword"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
461
+ ScSignInFormComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ScSignInFormComponent, deps: [{ token: i1.ScAuthService }, { token: i1.ScUserMetrikaService }], target: i0.ɵɵFactoryTarget.Component });
462
+ ScSignInFormComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: ScSignInFormComponent, selector: "sc-sign-in-form", inputs: { authMethod: "authMethod" }, outputs: { forgotPassword: "forgotPassword", signUp: "signUp", successAuth: "successAuth" }, ngImport: i0, template: "<div class=\"mb-4 flex justify-center\">\n <button\n tuiButton\n [tuiMode]=\"authMethod === 'by_phone' ? null : 'onLight'\"\n [appearance]=\"authMethod === 'by_phone' ? 'primary' : 'secondary'\"\n (click)=\"switchAuth(method.byPhone)\"\n class=\"tui-space_right-3 tui-space_bottom-3 !font-bold\"\n >\n \u041F\u043E \u0442\u0435\u043B\u0435\u0444\u043E\u043D\u0443\n </button>\n\n <button\n tuiButton\n [tuiMode]=\"authMethod === 'by_email' ? null : 'onLight'\"\n [appearance]=\"authMethod === 'by_email' ? 'primary' : 'secondary'\"\n (click)=\"switchAuth(method.byEmail)\"\n class=\"tui-space_left-3 tui-space_bottom-3 !font-bold\"\n >\n \u041F\u043E e-mail\n </button>\n</div>\n\n<sc-sign-in-form-by-email\n *ngIf=\"authMethod === 'by_email'\"\n (forgotPassword)=\"onForgotPassword()\"\n></sc-sign-in-form-by-email>\n\n<sc-sign-in-form-by-phone [class.hidden]=\"authMethod !== 'by_phone'\"></sc-sign-in-form-by-phone>\n\n<div class=\"flex flex-col items-center gap-4\">\n <span class=\"font-medium text-tui-text-02\">\u0415\u0449\u0435 \u043D\u0435 \u0437\u0430\u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u043E\u0432\u0430\u043D\u044B?</span>\n <button\n tuiButton\n tuiMode=\"onLight\"\n (click)=\"signUp.emit()\"\n type=\"button\"\n icon=\"scIconAddProfile\"\n appearance=\"secondary\"\n >\n \u0417\u0430\u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u043E\u0432\u0430\u0442\u044C\u0441\u044F\n </button>\n</div>\n", dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i4.TuiButtonComponent, selector: "button[tuiButton], button[tuiIconButton], a[tuiButton], a[tuiIconButton]", inputs: ["appearance", "disabled", "icon", "iconRight", "shape", "showLoader", "size"] }, { kind: "directive", type: i4.TuiModeDirective, selector: "[tuiMode]", inputs: ["tuiMode"] }, { kind: "component", type: ScSignInFormByPhoneComponent, selector: "sc-sign-in-form-by-phone" }, { kind: "component", type: ScSignInFormByEmailComponent, selector: "sc-sign-in-form-by-email", outputs: ["forgotPassword"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
468
463
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ScSignInFormComponent, decorators: [{
469
464
  type: Component,
470
- args: [{ selector: 'sc-sign-in-form', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"flex justify-center mb-4\">\n <button\n tuiButton\n [tuiMode]=\"authMethod === 'by_phone' ? null : 'onLight'\"\n [appearance]=\"authMethod === 'by_phone' ? 'primary' : 'secondary'\"\n (click)=\"switchAuth(method.byPhone)\"\n class=\"tui-space_right-3 tui-space_bottom-3 !font-bold\"\n >\n \u041F\u043E \u0442\u0435\u043B\u0435\u0444\u043E\u043D\u0443\n </button>\n\n <button\n tuiButton\n [tuiMode]=\"authMethod === 'by_email' ? null : 'onLight'\"\n [appearance]=\"authMethod === 'by_email' ? 'primary' : 'secondary'\"\n (click)=\"switchAuth(method.byEmail)\"\n class=\"tui-space_left-3 tui-space_bottom-3 !font-bold\"\n >\n \u041F\u043E e-mail\n </button>\n</div>\n\n<sc-sign-in-form-by-email *ngIf=\"authMethod === 'by_email'\" (forgotPassword)=\"onForgotPassword()\"></sc-sign-in-form-by-email>\n\n<sc-sign-in-form-by-phone [class.hidden]=\"authMethod !== 'by_phone'\"></sc-sign-in-form-by-phone>\n\n<div class=\"flex flex-col gap-4 items-center\">\n <span class=\"font-medium text-tui-text-02\">\u0415\u0449\u0435 \u043D\u0435 \u0437\u0430\u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u043E\u0432\u0430\u043D\u044B?</span>\n <button tuiButton tuiMode=\"onLight\" (click)=\"signUp.emit()\" type=\"button\" icon=\"scIconAddProfile\" appearance=\"secondary\">\u0417\u0430\u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u043E\u0432\u0430\u0442\u044C\u0441\u044F</button>\n</div>\n" }]
471
- }], ctorParameters: function () { return [{ type: i1.ScAuthService }]; }, propDecorators: { authMethod: [{
465
+ args: [{ selector: 'sc-sign-in-form', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"mb-4 flex justify-center\">\n <button\n tuiButton\n [tuiMode]=\"authMethod === 'by_phone' ? null : 'onLight'\"\n [appearance]=\"authMethod === 'by_phone' ? 'primary' : 'secondary'\"\n (click)=\"switchAuth(method.byPhone)\"\n class=\"tui-space_right-3 tui-space_bottom-3 !font-bold\"\n >\n \u041F\u043E \u0442\u0435\u043B\u0435\u0444\u043E\u043D\u0443\n </button>\n\n <button\n tuiButton\n [tuiMode]=\"authMethod === 'by_email' ? null : 'onLight'\"\n [appearance]=\"authMethod === 'by_email' ? 'primary' : 'secondary'\"\n (click)=\"switchAuth(method.byEmail)\"\n class=\"tui-space_left-3 tui-space_bottom-3 !font-bold\"\n >\n \u041F\u043E e-mail\n </button>\n</div>\n\n<sc-sign-in-form-by-email\n *ngIf=\"authMethod === 'by_email'\"\n (forgotPassword)=\"onForgotPassword()\"\n></sc-sign-in-form-by-email>\n\n<sc-sign-in-form-by-phone [class.hidden]=\"authMethod !== 'by_phone'\"></sc-sign-in-form-by-phone>\n\n<div class=\"flex flex-col items-center gap-4\">\n <span class=\"font-medium text-tui-text-02\">\u0415\u0449\u0435 \u043D\u0435 \u0437\u0430\u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u043E\u0432\u0430\u043D\u044B?</span>\n <button\n tuiButton\n tuiMode=\"onLight\"\n (click)=\"signUp.emit()\"\n type=\"button\"\n icon=\"scIconAddProfile\"\n appearance=\"secondary\"\n >\n \u0417\u0430\u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u043E\u0432\u0430\u0442\u044C\u0441\u044F\n </button>\n</div>\n" }]
466
+ }], ctorParameters: function () { return [{ type: i1.ScAuthService }, { type: i1.ScUserMetrikaService }]; }, propDecorators: { authMethod: [{
472
467
  type: Input
473
468
  }], forgotPassword: [{
474
469
  type: Output
@@ -903,7 +898,9 @@ let ScBannerComponent = class ScBannerComponent {
903
898
  onClick(banner) {
904
899
  this.userMetrikaService.emitUserMetrikaEvent({
905
900
  target: ScUserMetrikaGoalsEnum.bannerClick,
906
- params: { banner_id: banner.id },
901
+ params: {
902
+ banner_id: banner.id,
903
+ },
907
904
  });
908
905
  if (banner.url) {
909
906
  this.clickBannerEvent.emit(banner);