@eric-emg/symphiq-components 1.2.385 → 1.2.387
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/fesm2022/symphiq-components.mjs +60 -103
- package/fesm2022/symphiq-components.mjs.map +1 -1
- package/index.d.ts +1 -4
- package/index.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -12,7 +12,7 @@ import * as i1$1 from '@angular/common';
|
|
|
12
12
|
import { NgClass, CommonModule, isPlatformBrowser, DOCUMENT } from '@angular/common';
|
|
13
13
|
import * as i2$1 from '@angular/forms';
|
|
14
14
|
import { FormsModule, FormBuilder, Validators, ReactiveFormsModule } from '@angular/forms';
|
|
15
|
-
import { trigger, transition, style, animate
|
|
15
|
+
import { trigger, transition, style, animate } from '@angular/animations';
|
|
16
16
|
import { toObservable, toSignal, takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
17
17
|
import { MarkdownComponent } from 'ngx-markdown';
|
|
18
18
|
import dayjs from 'dayjs';
|
|
@@ -88184,7 +88184,7 @@ function ShopProfileQuestionCardComponent_Conditional_8_For_2_Template(rf, ctx)
|
|
|
88184
88184
|
} if (rf & 2) {
|
|
88185
88185
|
const answerData_r3 = ctx.$implicit;
|
|
88186
88186
|
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
88187
|
-
i0.ɵɵproperty("
|
|
88187
|
+
i0.ɵɵproperty("ngClass", ctx_r0.answerChipClasses());
|
|
88188
88188
|
i0.ɵɵadvance();
|
|
88189
88189
|
i0.ɵɵproperty("ngClass", ctx_r0.answerTextClasses());
|
|
88190
88190
|
i0.ɵɵadvance();
|
|
@@ -88192,13 +88192,13 @@ function ShopProfileQuestionCardComponent_Conditional_8_For_2_Template(rf, ctx)
|
|
|
88192
88192
|
i0.ɵɵadvance();
|
|
88193
88193
|
i0.ɵɵproperty("viewMode", ctx_r0.viewMode())("user", answerData_r3.user);
|
|
88194
88194
|
i0.ɵɵadvance();
|
|
88195
|
-
i0.ɵɵproperty("
|
|
88195
|
+
i0.ɵɵproperty("ngClass", ctx_r0.answerDateClasses());
|
|
88196
88196
|
i0.ɵɵadvance();
|
|
88197
88197
|
i0.ɵɵtextInterpolate1(" Answered ", ctx_r0.formatAnswerDate(answerData_r3.answer.createdDate), " ");
|
|
88198
88198
|
} }
|
|
88199
88199
|
function ShopProfileQuestionCardComponent_Conditional_8_Template(rf, ctx) { if (rf & 1) {
|
|
88200
88200
|
i0.ɵɵelementStart(0, "div", 7);
|
|
88201
|
-
i0.ɵɵrepeaterCreate(1, ShopProfileQuestionCardComponent_Conditional_8_For_2_Template, 6,
|
|
88201
|
+
i0.ɵɵrepeaterCreate(1, ShopProfileQuestionCardComponent_Conditional_8_For_2_Template, 6, 7, null, null, _forTrack0$3);
|
|
88202
88202
|
i0.ɵɵelementEnd();
|
|
88203
88203
|
} if (rf & 2) {
|
|
88204
88204
|
const ctx_r0 = i0.ɵɵnextContext();
|
|
@@ -88242,8 +88242,6 @@ class ShopProfileQuestionCardComponent {
|
|
|
88242
88242
|
this.profileShopAnswers = input([], ...(ngDevMode ? [{ debugName: "profileShopAnswers" }] : []));
|
|
88243
88243
|
this.users = input([], ...(ngDevMode ? [{ debugName: "users" }] : []));
|
|
88244
88244
|
this.answerClick = output();
|
|
88245
|
-
this.knownAnswerIds = signal(new Set(), ...(ngDevMode ? [{ debugName: "knownAnswerIds" }] : []));
|
|
88246
|
-
this.newAnswerIds = signal(new Set(), ...(ngDevMode ? [{ debugName: "newAnswerIds" }] : []));
|
|
88247
88245
|
this.questionAnswers = computed(() => {
|
|
88248
88246
|
const questionId = this.question().id;
|
|
88249
88247
|
const answers = this.profileShopAnswers();
|
|
@@ -88267,30 +88265,6 @@ class ShopProfileQuestionCardComponent {
|
|
|
88267
88265
|
const q = this.question();
|
|
88268
88266
|
return q.focusAreaDomains || [];
|
|
88269
88267
|
}, ...(ngDevMode ? [{ debugName: "relatedFocusAreas" }] : []));
|
|
88270
|
-
effect(() => {
|
|
88271
|
-
const currentAnswers = this.questionAnswers();
|
|
88272
|
-
const currentIds = new Set(currentAnswers.map(a => a.answer.id).filter((id) => id !== undefined));
|
|
88273
|
-
const known = untracked(() => this.knownAnswerIds());
|
|
88274
|
-
if (known.size === 0) {
|
|
88275
|
-
this.knownAnswerIds.set(currentIds);
|
|
88276
|
-
this.newAnswerIds.set(new Set());
|
|
88277
|
-
}
|
|
88278
|
-
else {
|
|
88279
|
-
const newIds = new Set();
|
|
88280
|
-
currentIds.forEach(id => {
|
|
88281
|
-
if (!known.has(id)) {
|
|
88282
|
-
newIds.add(id);
|
|
88283
|
-
}
|
|
88284
|
-
});
|
|
88285
|
-
this.newAnswerIds.set(newIds);
|
|
88286
|
-
this.knownAnswerIds.set(currentIds);
|
|
88287
|
-
}
|
|
88288
|
-
});
|
|
88289
|
-
}
|
|
88290
|
-
getAnimationState(answerId) {
|
|
88291
|
-
if (!answerId)
|
|
88292
|
-
return 'existing';
|
|
88293
|
-
return this.newAnswerIds().has(answerId) ? 'new' : 'existing';
|
|
88294
88268
|
}
|
|
88295
88269
|
getFocusAreaTitle(focusArea) {
|
|
88296
88270
|
return FocusAreaDomainEnumUtil.title(focusArea);
|
|
@@ -88430,23 +88404,7 @@ class ShopProfileQuestionCardComponent {
|
|
|
88430
88404
|
i0.ɵɵproperty("ngClass", ctx.buttonClasses());
|
|
88431
88405
|
i0.ɵɵadvance(2);
|
|
88432
88406
|
i0.ɵɵtextInterpolate(ctx.isAnswered() ? "Edit Answer" : "Answer");
|
|
88433
|
-
} }, dependencies: [CommonModule, i1$1.NgClass, UserAvatarComponent], encapsulation: 2,
|
|
88434
|
-
trigger('answerAnimation', [
|
|
88435
|
-
state('existing', style({ opacity: 1, transform: 'scale(1)' })),
|
|
88436
|
-
state('new', style({ opacity: 1, transform: 'scale(1)' })),
|
|
88437
|
-
transition('void => new', [
|
|
88438
|
-
animate('500ms ease-out', keyframes([
|
|
88439
|
-
style({ opacity: 0, transform: 'scale(0.8)', boxShadow: '0 0 0 0 rgba(59, 130, 246, 0)', offset: 0 }),
|
|
88440
|
-
style({ opacity: 1, transform: 'scale(1.05)', boxShadow: '0 0 20px 4px rgba(59, 130, 246, 0.5)', offset: 0.5 }),
|
|
88441
|
-
style({ opacity: 1, transform: 'scale(1)', boxShadow: '0 0 0 0 rgba(59, 130, 246, 0)', offset: 1 })
|
|
88442
|
-
]))
|
|
88443
|
-
]),
|
|
88444
|
-
transition('void => existing', []),
|
|
88445
|
-
transition('* => void', [
|
|
88446
|
-
animate('300ms ease-in', style({ opacity: 0, transform: 'scale(0.8)' }))
|
|
88447
|
-
])
|
|
88448
|
-
])
|
|
88449
|
-
] }, changeDetection: 0 }); }
|
|
88407
|
+
} }, dependencies: [CommonModule, i1$1.NgClass, UserAvatarComponent], encapsulation: 2, changeDetection: 0 }); }
|
|
88450
88408
|
}
|
|
88451
88409
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ShopProfileQuestionCardComponent, [{
|
|
88452
88410
|
type: Component,
|
|
@@ -88455,23 +88413,6 @@ class ShopProfileQuestionCardComponent {
|
|
|
88455
88413
|
standalone: true,
|
|
88456
88414
|
imports: [CommonModule, UserAvatarComponent],
|
|
88457
88415
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
88458
|
-
animations: [
|
|
88459
|
-
trigger('answerAnimation', [
|
|
88460
|
-
state('existing', style({ opacity: 1, transform: 'scale(1)' })),
|
|
88461
|
-
state('new', style({ opacity: 1, transform: 'scale(1)' })),
|
|
88462
|
-
transition('void => new', [
|
|
88463
|
-
animate('500ms ease-out', keyframes([
|
|
88464
|
-
style({ opacity: 0, transform: 'scale(0.8)', boxShadow: '0 0 0 0 rgba(59, 130, 246, 0)', offset: 0 }),
|
|
88465
|
-
style({ opacity: 1, transform: 'scale(1.05)', boxShadow: '0 0 20px 4px rgba(59, 130, 246, 0.5)', offset: 0.5 }),
|
|
88466
|
-
style({ opacity: 1, transform: 'scale(1)', boxShadow: '0 0 0 0 rgba(59, 130, 246, 0)', offset: 1 })
|
|
88467
|
-
]))
|
|
88468
|
-
]),
|
|
88469
|
-
transition('void => existing', []),
|
|
88470
|
-
transition('* => void', [
|
|
88471
|
-
animate('300ms ease-in', style({ opacity: 0, transform: 'scale(0.8)' }))
|
|
88472
|
-
])
|
|
88473
|
-
])
|
|
88474
|
-
],
|
|
88475
88416
|
template: `
|
|
88476
88417
|
<div [ngClass]="containerClasses()" class="rounded-xl border-2 p-6 transition-all duration-200">
|
|
88477
88418
|
<!-- Question Header with Checkbox -->
|
|
@@ -88520,7 +88461,7 @@ class ShopProfileQuestionCardComponent {
|
|
|
88520
88461
|
<!-- Answered State - Show answer chips -->
|
|
88521
88462
|
<div class="flex flex-wrap gap-3">
|
|
88522
88463
|
@for (answerData of questionAnswers(); track answerData.answer.id) {
|
|
88523
|
-
<div [
|
|
88464
|
+
<div [ngClass]="answerChipClasses()" class="flex items-center gap-2 px-4 py-2.5 rounded-full">
|
|
88524
88465
|
<span [ngClass]="answerTextClasses()" class="text-sm font-medium">
|
|
88525
88466
|
{{ answerData.answer.answer }}
|
|
88526
88467
|
</span>
|
|
@@ -88530,7 +88471,7 @@ class ShopProfileQuestionCardComponent {
|
|
|
88530
88471
|
size="small"
|
|
88531
88472
|
/>
|
|
88532
88473
|
</div>
|
|
88533
|
-
<div [
|
|
88474
|
+
<div [ngClass]="answerDateClasses()" class="self-center text-xs -ml-1">
|
|
88534
88475
|
Answered {{ formatAnswerDate(answerData.answer.createdDate) }}
|
|
88535
88476
|
</div>
|
|
88536
88477
|
}
|
|
@@ -88574,8 +88515,8 @@ class ShopProfileQuestionCardComponent {
|
|
|
88574
88515
|
</div>
|
|
88575
88516
|
`
|
|
88576
88517
|
}]
|
|
88577
|
-
}],
|
|
88578
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ShopProfileQuestionCardComponent, { className: "ShopProfileQuestionCardComponent", filePath: "lib/components/profile-analysis-dashboard/cards/shop-profile-question-card.component.ts", lineNumber:
|
|
88518
|
+
}], null, { question: [{ type: i0.Input, args: [{ isSignal: true, alias: "question", required: true }] }], viewMode: [{ type: i0.Input, args: [{ isSignal: true, alias: "viewMode", required: false }] }], viewType: [{ type: i0.Input, args: [{ isSignal: true, alias: "viewType", required: false }] }], profileShopAnswers: [{ type: i0.Input, args: [{ isSignal: true, alias: "profileShopAnswers", required: false }] }], users: [{ type: i0.Input, args: [{ isSignal: true, alias: "users", required: false }] }], answerClick: [{ type: i0.Output, args: ["answerClick"] }] }); })();
|
|
88519
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ShopProfileQuestionCardComponent, { className: "ShopProfileQuestionCardComponent", filePath: "lib/components/profile-analysis-dashboard/cards/shop-profile-question-card.component.ts", lineNumber: 119 }); })();
|
|
88579
88520
|
|
|
88580
88521
|
const _c0$5 = ["scrollContainer"];
|
|
88581
88522
|
const _c1$2 = ["stickySentinel"];
|
|
@@ -88768,7 +88709,7 @@ function ShopProfileQuestionAnswerComponent_Conditional_31_Template(rf, ctx) { i
|
|
|
88768
88709
|
i0.ɵɵtext(1, "Save");
|
|
88769
88710
|
i0.ɵɵelementEnd();
|
|
88770
88711
|
} }
|
|
88771
|
-
function
|
|
88712
|
+
function ShopProfileQuestionAnswerComponent_Conditional_32_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
88772
88713
|
i0.ɵɵnamespaceSVG();
|
|
88773
88714
|
i0.ɵɵelementStart(0, "svg", 55);
|
|
88774
88715
|
i0.ɵɵelement(1, "circle", 56)(2, "path", 57);
|
|
@@ -88778,15 +88719,27 @@ function ShopProfileQuestionAnswerComponent_Conditional_33_Template(rf, ctx) { i
|
|
|
88778
88719
|
i0.ɵɵtext(4, "Saving...");
|
|
88779
88720
|
i0.ɵɵelementEnd();
|
|
88780
88721
|
} }
|
|
88781
|
-
function
|
|
88722
|
+
function ShopProfileQuestionAnswerComponent_Conditional_32_Conditional_2_Template(rf, ctx) { if (rf & 1) {
|
|
88782
88723
|
i0.ɵɵelementStart(0, "span");
|
|
88783
88724
|
i0.ɵɵtext(1, "Save & next unanswered");
|
|
88784
88725
|
i0.ɵɵelementEnd();
|
|
88785
88726
|
i0.ɵɵnamespaceSVG();
|
|
88786
|
-
i0.ɵɵelementStart(2, "svg",
|
|
88787
|
-
i0.ɵɵelement(3, "path",
|
|
88727
|
+
i0.ɵɵelementStart(2, "svg", 59);
|
|
88728
|
+
i0.ɵɵelement(3, "path", 60);
|
|
88788
88729
|
i0.ɵɵelementEnd();
|
|
88789
88730
|
} }
|
|
88731
|
+
function ShopProfileQuestionAnswerComponent_Conditional_32_Template(rf, ctx) { if (rf & 1) {
|
|
88732
|
+
const _r8 = i0.ɵɵgetCurrentView();
|
|
88733
|
+
i0.ɵɵelementStart(0, "button", 58);
|
|
88734
|
+
i0.ɵɵlistener("click", function ShopProfileQuestionAnswerComponent_Conditional_32_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r8); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.onSaveAndNext()); });
|
|
88735
|
+
i0.ɵɵconditionalCreate(1, ShopProfileQuestionAnswerComponent_Conditional_32_Conditional_1_Template, 5, 0)(2, ShopProfileQuestionAnswerComponent_Conditional_32_Conditional_2_Template, 4, 0);
|
|
88736
|
+
i0.ɵɵelementEnd();
|
|
88737
|
+
} if (rf & 2) {
|
|
88738
|
+
const ctx_r1 = i0.ɵɵnextContext();
|
|
88739
|
+
i0.ɵɵproperty("disabled", ctx_r1.saveButtonsDisabled())("ngClass", ctx_r1.saveAndNextButtonClasses());
|
|
88740
|
+
i0.ɵɵadvance();
|
|
88741
|
+
i0.ɵɵconditional(ctx_r1.isSaving() && ctx_r1.pendingSaveAction() === "saveAndNext" ? 1 : 2);
|
|
88742
|
+
} }
|
|
88790
88743
|
class ShopProfileQuestionAnswerComponent {
|
|
88791
88744
|
constructor() {
|
|
88792
88745
|
this.question = input.required(...(ngDevMode ? [{ debugName: "question" }] : []));
|
|
@@ -88869,6 +88822,9 @@ class ShopProfileQuestionAnswerComponent {
|
|
|
88869
88822
|
return 0;
|
|
88870
88823
|
return (this.answeredCount() / total) * 100;
|
|
88871
88824
|
}, ...(ngDevMode ? [{ debugName: "progressPercentage" }] : []));
|
|
88825
|
+
this.allQuestionsAnswered = computed(() => {
|
|
88826
|
+
return this.unansweredQuestions().length === 0;
|
|
88827
|
+
}, ...(ngDevMode ? [{ debugName: "allQuestionsAnswered" }] : []));
|
|
88872
88828
|
this.canAddCustomAnswers = computed(() => {
|
|
88873
88829
|
return this.customAnswerText().trim().length > 0;
|
|
88874
88830
|
}, ...(ngDevMode ? [{ debugName: "canAddCustomAnswers" }] : []));
|
|
@@ -89211,7 +89167,7 @@ class ShopProfileQuestionAnswerComponent {
|
|
|
89211
89167
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.stickySentinel = _t.first);
|
|
89212
89168
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.stickyHeader = _t.first);
|
|
89213
89169
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.questionTitle = _t.first);
|
|
89214
|
-
} }, inputs: { question: [1, "question"], viewMode: [1, "viewMode"], viewType: [1, "viewType"], selectedCategoryId: [1, "selectedCategoryId"], selectedFocusAreaId: [1, "selectedFocusAreaId"], filteredQuestions: [1, "filteredQuestions"], profileShopAnswers: [1, "profileShopAnswers"] }, outputs: { backClick: "backClick", saveClick: "saveClick", saveAndNextClick: "saveAndNextClick", navigateToList: "navigateToList", navigateToNextQuestion: "navigateToNextQuestion" }, decls:
|
|
89170
|
+
} }, inputs: { question: [1, "question"], viewMode: [1, "viewMode"], viewType: [1, "viewType"], selectedCategoryId: [1, "selectedCategoryId"], selectedFocusAreaId: [1, "selectedFocusAreaId"], filteredQuestions: [1, "filteredQuestions"], profileShopAnswers: [1, "profileShopAnswers"] }, outputs: { backClick: "backClick", saveClick: "saveClick", saveAndNextClick: "saveAndNextClick", navigateToList: "navigateToList", navigateToNextQuestion: "navigateToNextQuestion" }, decls: 33, vars: 27, consts: [["scrollContainer", ""], ["stickySentinel", ""], ["stickyHeader", ""], ["questionTitle", ""], [1, "flex", "flex-col", "h-full"], [1, "flex-1", "overflow-y-auto"], [1, "px-6", "py-4", "border-b", 3, "ngClass"], [1, "text-sm", "font-semibold", "mb-3", 3, "ngClass"], [1, "flex", "items-center", "gap-3"], [1, "flex-1"], [1, "h-2", "rounded-full", "overflow-hidden", 3, "ngClass"], [1, "h-full", "transition-all", "duration-500", "ease-out", "rounded-full", 3, "ngClass"], [1, "text-sm", "font-medium", "whitespace-nowrap", 3, "ngClass"], [1, "inline-block", "tabular-nums", "transition-transform", "duration-300"], [1, "h-0"], [1, "sticky", "top-0", "z-10", "px-6", "py-4", "transition-all", "duration-200", 3, "ngClass"], [1, "text-sm", "italic", "mb-2", 3, "ngClass"], [1, "space-y-2"], [1, "font-bold", "text-2xl", "[&.is-sticky]:text-lg", "transition-all", "duration-200", 3, "ngClass"], [1, "px-6"], [1, "mt-3", "space-y-2"], [1, "px-6", "py-6"], [1, "flex", "flex-col", "items-center", "justify-center", "py-12"], [1, "px-6", "py-4", "border-t", "sticky", "bottom-0", "z-10", 3, "ngClass"], [1, "flex", "items-center", "gap-4"], ["type", "button", 1, "px-5", "py-2.5", "rounded-lg", "font-medium", "text-sm", "transition-all", "duration-200", "disabled:opacity-50", "disabled:cursor-not-allowed", "hover:scale-[1.02]", "active:scale-95", "disabled:hover:scale-100", "flex", "items-center", "justify-center", "gap-2", "min-w-[80px]", 3, "click", "disabled", "ngClass"], ["type", "button", 1, "flex-1", "px-5", "py-2.5", "rounded-lg", "font-medium", "text-sm", "transition-all", "duration-200", "flex", "items-center", "justify-center", "gap-2", "disabled:opacity-50", "disabled:cursor-not-allowed", "hover:scale-[1.01]", "active:scale-[0.99]", "disabled:hover:scale-100", 3, "disabled", "ngClass"], [1, "h-7", "rounded", "w-3/4", "animate-pulse", 3, "ngClass"], [1, "h-7", "rounded", "w-1/2", "animate-pulse", 3, "ngClass"], [1, "h-4", "rounded", "w-full", "animate-pulse", 3, "ngClass"], [1, "h-4", "rounded", "w-5/6", "animate-pulse", 3, "ngClass"], [1, "text-sm", "leading-relaxed", "mt-3", 3, "ngClass"], [1, "mt-4"], [1, "flex", "items-center", "gap-2", "mb-2"], [1, "text-xs", "font-semibold", 3, "ngClass"], ["fill", "none", "stroke", "currentColor", "viewBox", "0 0 24 24", 1, "w-4", "h-4", 3, "ngClass"], ["stroke-linecap", "round", "stroke-linejoin", "round", "stroke-width", "2", "d", "M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"], [1, "flex", "flex-wrap", "gap-2"], [1, "px-3", "py-1.5", "rounded-full", "text-xs", "font-medium", 3, "ngClass"], ["size", "medium", 3, "viewMode"], [1, "mt-4", "text-sm", "font-medium", 3, "ngClass"], [1, "space-y-3", "mb-4"], [1, "flex", "items-start", "gap-3", "p-4", "rounded-lg", "cursor-pointer", "transition-all", "duration-200", "hover:scale-[1.01]", 3, "ngClass"], [1, "mb-6"], [1, "grid", "transition-[grid-template-rows]", "duration-300", "ease-in-out"], [1, "overflow-hidden", "min-h-0"], [1, "pb-4"], ["rows", "5", "placeholder", "Enter your answer(s) here, separated by returns.", 1, "w-full", "px-4", "py-3", "rounded-lg", "border-2", "text-sm", "resize-y", "transition-colors", "duration-200", "focus:ring-2", "focus:ring-offset-2", 3, "ngModelChange", "ngModel", "ngClass"], [1, "flex", "items-center", "gap-3", "mt-3"], ["type", "button", 1, "px-5", "py-2.5", "rounded-lg", "font-medium", "text-sm", "transition-all", "duration-200", "hover:scale-105", "active:scale-95", 3, "click", "ngClass"], ["type", "button", 1, "flex-1", "px-5", "py-2.5", "rounded-lg", "font-medium", "text-sm", "transition-all", "duration-200", "disabled:opacity-50", "disabled:cursor-not-allowed", "disabled:hover:scale-100", 3, "click", "disabled", "ngClass"], ["type", "button", 1, "w-full", "px-5", "py-3", "rounded-lg", "font-medium", "text-sm", "transition-all", "duration-200", "border-2", "hover:scale-[1.01]", "active:scale-[0.99]", 3, "ngClass"], ["type", "checkbox", 1, "mt-0.5", "w-5", "h-5", "rounded", "border-2", "cursor-pointer", "transition-all", "duration-200", "focus:ring-2", "focus:ring-offset-2", 3, "change", "checked", "ngClass"], [1, "text-base", "flex-1", 3, "ngClass"], ["type", "button", 1, "w-full", "px-5", "py-3", "rounded-lg", "font-medium", "text-sm", "transition-all", "duration-200", "border-2", "hover:scale-[1.01]", "active:scale-[0.99]", 3, "click", "ngClass"], ["xmlns", "http://www.w3.org/2000/svg", "fill", "none", "viewBox", "0 0 24 24", 1, "animate-spin", "h-4", "w-4"], ["cx", "12", "cy", "12", "r", "10", "stroke", "currentColor", "stroke-width", "4", 1, "opacity-25"], ["fill", "currentColor", "d", "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z", 1, "opacity-75"], ["type", "button", 1, "flex-1", "px-5", "py-2.5", "rounded-lg", "font-medium", "text-sm", "transition-all", "duration-200", "flex", "items-center", "justify-center", "gap-2", "disabled:opacity-50", "disabled:cursor-not-allowed", "hover:scale-[1.01]", "active:scale-[0.99]", "disabled:hover:scale-100", 3, "click", "disabled", "ngClass"], ["fill", "none", "stroke", "currentColor", "viewBox", "0 0 24 24", 1, "w-4", "h-4"], ["stroke-linecap", "round", "stroke-linejoin", "round", "stroke-width", "2", "d", "M9 5l7 7-7 7"]], template: function ShopProfileQuestionAnswerComponent_Template(rf, ctx) { if (rf & 1) {
|
|
89215
89171
|
const _r1 = i0.ɵɵgetCurrentView();
|
|
89216
89172
|
i0.ɵɵelementStart(0, "div", 4)(1, "div", 5, 0)(3, "div", 6)(4, "h4", 7);
|
|
89217
89173
|
i0.ɵɵtext(5, " Unanswered questions status ");
|
|
@@ -89239,10 +89195,8 @@ class ShopProfileQuestionAnswerComponent {
|
|
|
89239
89195
|
i0.ɵɵlistener("click", function ShopProfileQuestionAnswerComponent_Template_button_click_29_listener() { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.onSave()); });
|
|
89240
89196
|
i0.ɵɵconditionalCreate(30, ShopProfileQuestionAnswerComponent_Conditional_30_Template, 5, 0)(31, ShopProfileQuestionAnswerComponent_Conditional_31_Template, 2, 0, "span");
|
|
89241
89197
|
i0.ɵɵelementEnd();
|
|
89242
|
-
i0.ɵɵ
|
|
89243
|
-
i0.ɵɵ
|
|
89244
|
-
i0.ɵɵconditionalCreate(33, ShopProfileQuestionAnswerComponent_Conditional_33_Template, 5, 0)(34, ShopProfileQuestionAnswerComponent_Conditional_34_Template, 4, 0);
|
|
89245
|
-
i0.ɵɵelementEnd()()()();
|
|
89198
|
+
i0.ɵɵconditionalCreate(32, ShopProfileQuestionAnswerComponent_Conditional_32_Template, 3, 3, "button", 26);
|
|
89199
|
+
i0.ɵɵelementEnd()()();
|
|
89246
89200
|
} if (rf & 2) {
|
|
89247
89201
|
i0.ɵɵadvance(3);
|
|
89248
89202
|
i0.ɵɵproperty("ngClass", ctx.statusHeaderClasses());
|
|
@@ -89274,13 +89228,12 @@ class ShopProfileQuestionAnswerComponent {
|
|
|
89274
89228
|
i0.ɵɵadvance(2);
|
|
89275
89229
|
i0.ɵɵproperty("ngClass", ctx.footerClasses());
|
|
89276
89230
|
i0.ɵɵadvance(2);
|
|
89277
|
-
i0.ɵɵ
|
|
89231
|
+
i0.ɵɵclassProp("flex-1", ctx.allQuestionsAnswered())("border", !ctx.allQuestionsAnswered());
|
|
89232
|
+
i0.ɵɵproperty("disabled", ctx.saveButtonsDisabled())("ngClass", ctx.allQuestionsAnswered() ? ctx.saveAndNextButtonClasses() : ctx.saveButtonClasses());
|
|
89278
89233
|
i0.ɵɵadvance();
|
|
89279
89234
|
i0.ɵɵconditional(ctx.isSaving() && ctx.pendingSaveAction() === "save" ? 30 : 31);
|
|
89280
89235
|
i0.ɵɵadvance(2);
|
|
89281
|
-
i0.ɵɵ
|
|
89282
|
-
i0.ɵɵadvance();
|
|
89283
|
-
i0.ɵɵconditional(ctx.isSaving() && ctx.pendingSaveAction() === "saveAndNext" ? 33 : 34);
|
|
89236
|
+
i0.ɵɵconditional(!ctx.allQuestionsAnswered() ? 32 : -1);
|
|
89284
89237
|
} }, dependencies: [CommonModule, i1$1.NgClass, FormsModule, i2$1.DefaultValueAccessor, i2$1.NgControlStatus, i2$1.NgModel, IndeterminateSpinnerComponent], encapsulation: 2, data: { animation: [
|
|
89285
89238
|
trigger('fadeIn', [
|
|
89286
89239
|
transition(':enter', [
|
|
@@ -89479,8 +89432,10 @@ class ShopProfileQuestionAnswerComponent {
|
|
|
89479
89432
|
type="button"
|
|
89480
89433
|
(click)="onSave()"
|
|
89481
89434
|
[disabled]="saveButtonsDisabled()"
|
|
89482
|
-
[ngClass]="saveButtonClasses()"
|
|
89483
|
-
class
|
|
89435
|
+
[ngClass]="allQuestionsAnswered() ? saveAndNextButtonClasses() : saveButtonClasses()"
|
|
89436
|
+
[class.flex-1]="allQuestionsAnswered()"
|
|
89437
|
+
class="px-5 py-2.5 rounded-lg font-medium text-sm transition-all duration-200 disabled:opacity-50 disabled:cursor-not-allowed hover:scale-[1.02] active:scale-95 disabled:hover:scale-100 flex items-center justify-center gap-2 min-w-[80px]"
|
|
89438
|
+
[class.border]="!allQuestionsAnswered()">
|
|
89484
89439
|
@if (isSaving() && pendingSaveAction() === 'save') {
|
|
89485
89440
|
<svg class="animate-spin h-4 w-4" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24">
|
|
89486
89441
|
<circle class="opacity-25" cx="12" cy="12" r="10" stroke="currentColor" stroke-width="4"></circle>
|
|
@@ -89491,25 +89446,27 @@ class ShopProfileQuestionAnswerComponent {
|
|
|
89491
89446
|
<span>Save</span>
|
|
89492
89447
|
}
|
|
89493
89448
|
</button>
|
|
89494
|
-
|
|
89495
|
-
|
|
89496
|
-
|
|
89497
|
-
|
|
89498
|
-
|
|
89499
|
-
|
|
89500
|
-
|
|
89501
|
-
|
|
89502
|
-
<
|
|
89503
|
-
|
|
89504
|
-
|
|
89505
|
-
|
|
89506
|
-
|
|
89507
|
-
|
|
89508
|
-
|
|
89509
|
-
<
|
|
89510
|
-
|
|
89511
|
-
|
|
89512
|
-
|
|
89449
|
+
@if (!allQuestionsAnswered()) {
|
|
89450
|
+
<button
|
|
89451
|
+
type="button"
|
|
89452
|
+
(click)="onSaveAndNext()"
|
|
89453
|
+
[disabled]="saveButtonsDisabled()"
|
|
89454
|
+
[ngClass]="saveAndNextButtonClasses()"
|
|
89455
|
+
class="flex-1 px-5 py-2.5 rounded-lg font-medium text-sm transition-all duration-200 flex items-center justify-center gap-2 disabled:opacity-50 disabled:cursor-not-allowed hover:scale-[1.01] active:scale-[0.99] disabled:hover:scale-100">
|
|
89456
|
+
@if (isSaving() && pendingSaveAction() === 'saveAndNext') {
|
|
89457
|
+
<svg class="animate-spin h-4 w-4" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24">
|
|
89458
|
+
<circle class="opacity-25" cx="12" cy="12" r="10" stroke="currentColor" stroke-width="4"></circle>
|
|
89459
|
+
<path class="opacity-75" fill="currentColor" d="M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"></path>
|
|
89460
|
+
</svg>
|
|
89461
|
+
<span>Saving...</span>
|
|
89462
|
+
} @else {
|
|
89463
|
+
<span>Save & next unanswered</span>
|
|
89464
|
+
<svg class="w-4 h-4" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
|
89465
|
+
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 5l7 7-7 7"></path>
|
|
89466
|
+
</svg>
|
|
89467
|
+
}
|
|
89468
|
+
</button>
|
|
89469
|
+
}
|
|
89513
89470
|
</div>
|
|
89514
89471
|
</div>
|
|
89515
89472
|
</div>
|
|
@@ -89528,7 +89485,7 @@ class ShopProfileQuestionAnswerComponent {
|
|
|
89528
89485
|
type: ViewChild,
|
|
89529
89486
|
args: ['questionTitle']
|
|
89530
89487
|
}] }); })();
|
|
89531
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ShopProfileQuestionAnswerComponent, { className: "ShopProfileQuestionAnswerComponent", filePath: "lib/components/profile-analysis-dashboard/cards/shop-profile-question-answer.component.ts", lineNumber:
|
|
89488
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(ShopProfileQuestionAnswerComponent, { className: "ShopProfileQuestionAnswerComponent", filePath: "lib/components/profile-analysis-dashboard/cards/shop-profile-question-answer.component.ts", lineNumber: 264 }); })();
|
|
89532
89489
|
|
|
89533
89490
|
const _c0$4 = ["modalContent"];
|
|
89534
89491
|
const _c1$1 = ["modalWrapper"];
|