@memberjunction/ng-conversations 5.11.0 → 5.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/components/active-tasks/active-tasks-panel.component.js +2 -2
- package/dist/lib/components/active-tasks/active-tasks-panel.component.js.map +1 -1
- package/dist/lib/components/artifact/artifact-share-modal.component.js +2 -2
- package/dist/lib/components/attachment/image-viewer.component.js +2 -2
- package/dist/lib/components/collection/artifact-collection-picker-modal.component.js +4 -4
- package/dist/lib/components/collection/artifact-collection-picker-modal.component.js.map +1 -1
- package/dist/lib/components/collection/artifact-create-modal.component.js +2 -2
- package/dist/lib/components/collection/artifact-create-modal.component.js.map +1 -1
- package/dist/lib/components/collection/collection-artifact-card.component.js +2 -2
- package/dist/lib/components/collection/collection-artifact-card.component.js.map +1 -1
- package/dist/lib/components/collection/collection-form-modal.component.js +2 -2
- package/dist/lib/components/collection/collection-form-modal.component.js.map +1 -1
- package/dist/lib/components/collection/collection-share-modal.component.js +2 -2
- package/dist/lib/components/collection/collection-tree.component.js +2 -2
- package/dist/lib/components/collection/collection-tree.component.js.map +1 -1
- package/dist/lib/components/collection/collection-view.component.js +2 -2
- package/dist/lib/components/collection/collection-view.component.js.map +1 -1
- package/dist/lib/components/collection/collections-full-view.component.js +2 -2
- package/dist/lib/components/collection/collections-full-view.component.js.map +1 -1
- package/dist/lib/components/conversation/conversation-chat-area.component.d.ts +9 -1
- package/dist/lib/components/conversation/conversation-chat-area.component.d.ts.map +1 -1
- package/dist/lib/components/conversation/conversation-chat-area.component.js +32 -6
- package/dist/lib/components/conversation/conversation-chat-area.component.js.map +1 -1
- package/dist/lib/components/conversation/conversation-empty-state.component.d.ts +6 -0
- package/dist/lib/components/conversation/conversation-empty-state.component.d.ts.map +1 -1
- package/dist/lib/components/conversation/conversation-empty-state.component.js +26 -5
- package/dist/lib/components/conversation/conversation-empty-state.component.js.map +1 -1
- package/dist/lib/components/conversation/conversation-list.component.js +2 -2
- package/dist/lib/components/conversation/conversation-list.component.js.map +1 -1
- package/dist/lib/components/export/export-modal.component.d.ts.map +1 -1
- package/dist/lib/components/export/export-modal.component.js +3 -3
- package/dist/lib/components/export/export-modal.component.js.map +1 -1
- package/dist/lib/components/global-tasks/global-tasks-panel.component.js +2 -2
- package/dist/lib/components/global-tasks/global-tasks-panel.component.js.map +1 -1
- package/dist/lib/components/mention/mention-dropdown.component.js +2 -2
- package/dist/lib/components/mention/mention-editor.component.js +2 -2
- package/dist/lib/components/message/actionable-commands.component.js +2 -2
- package/dist/lib/components/message/conversation-message-rating.component.js +2 -2
- package/dist/lib/components/message/conversation-message-rating.component.js.map +1 -1
- package/dist/lib/components/message/message-input-box.component.js +2 -2
- package/dist/lib/components/message/message-input.component.js +2 -2
- package/dist/lib/components/message/message-item.component.d.ts +5 -4
- package/dist/lib/components/message/message-item.component.d.ts.map +1 -1
- package/dist/lib/components/message/message-item.component.js +33 -123
- package/dist/lib/components/message/message-item.component.js.map +1 -1
- package/dist/lib/components/message/message-list.component.js +2 -2
- package/dist/lib/components/message/suggested-responses.component.js +2 -2
- package/dist/lib/components/search/search-panel.component.js +2 -2
- package/dist/lib/components/sidebar/conversation-sidebar.component.js +2 -2
- package/dist/lib/components/sidebar/conversation-sidebar.component.js.map +1 -1
- package/dist/lib/components/task/tasks-full-view.component.js +2 -2
- package/dist/lib/components/task/tasks-full-view.component.js.map +1 -1
- package/dist/lib/components/tasks/task-widget.component.js +2 -2
- package/dist/lib/components/tasks/task-widget.component.js.map +1 -1
- package/dist/lib/components/tasks/tasks-dropdown.component.d.ts.map +1 -1
- package/dist/lib/components/tasks/tasks-dropdown.component.js +3 -3
- package/dist/lib/components/tasks/tasks-dropdown.component.js.map +1 -1
- package/dist/lib/components/thread/thread-panel.component.js +2 -2
- package/dist/lib/components/toast/toast.component.js +2 -2
- package/dist/lib/components/toast/toast.component.js.map +1 -1
- package/dist/lib/components/workspace/conversation-workspace.component.js +2 -2
- package/dist/lib/conversations.module.d.ts +61 -62
- package/dist/lib/conversations.module.d.ts.map +1 -1
- package/dist/lib/conversations.module.js +4 -8
- package/dist/lib/conversations.module.js.map +1 -1
- package/package.json +18 -17
- package/dist/lib/components/message/agent-response-form.component.d.ts +0 -90
- package/dist/lib/components/message/agent-response-form.component.d.ts.map +0 -1
- package/dist/lib/components/message/agent-response-form.component.js +0 -435
- package/dist/lib/components/message/agent-response-form.component.js.map +0 -1
- package/dist/lib/components/message/form-question.component.d.ts +0 -105
- package/dist/lib/components/message/form-question.component.d.ts.map +0 -1
- package/dist/lib/components/message/form-question.component.js +0 -638
- package/dist/lib/components/message/form-question.component.js.map +0 -1
|
@@ -1,638 +0,0 @@
|
|
|
1
|
-
import { Component, Input, forwardRef } from '@angular/core';
|
|
2
|
-
import { NG_VALUE_ACCESSOR } from '@angular/forms';
|
|
3
|
-
import * as i0 from "@angular/core";
|
|
4
|
-
import * as i1 from "@angular/common";
|
|
5
|
-
import * as i2 from "@angular/forms";
|
|
6
|
-
import * as i3 from "@progress/kendo-angular-buttons";
|
|
7
|
-
import * as i4 from "@progress/kendo-angular-inputs";
|
|
8
|
-
import * as i5 from "@progress/kendo-angular-dateinputs";
|
|
9
|
-
function FormQuestionComponent_Conditional_1_Conditional_2_Template(rf, ctx) { if (rf & 1) {
|
|
10
|
-
i0.ɵɵelementStart(0, "span", 18);
|
|
11
|
-
i0.ɵɵtext(1, "*");
|
|
12
|
-
i0.ɵɵelementEnd();
|
|
13
|
-
} }
|
|
14
|
-
function FormQuestionComponent_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
15
|
-
i0.ɵɵelementStart(0, "label", 1);
|
|
16
|
-
i0.ɵɵtext(1);
|
|
17
|
-
i0.ɵɵconditionalCreate(2, FormQuestionComponent_Conditional_1_Conditional_2_Template, 2, 0, "span", 18);
|
|
18
|
-
i0.ɵɵelementEnd();
|
|
19
|
-
} if (rf & 2) {
|
|
20
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
21
|
-
i0.ɵɵadvance();
|
|
22
|
-
i0.ɵɵtextInterpolate1(" ", ctx_r0.question.label, " ");
|
|
23
|
-
i0.ɵɵadvance();
|
|
24
|
-
i0.ɵɵconditional(ctx_r0.question.required ? 2 : -1);
|
|
25
|
-
} }
|
|
26
|
-
function FormQuestionComponent_Conditional_2_Template(rf, ctx) { if (rf & 1) {
|
|
27
|
-
i0.ɵɵelementStart(0, "div", 2);
|
|
28
|
-
i0.ɵɵtext(1);
|
|
29
|
-
i0.ɵɵelementEnd();
|
|
30
|
-
} if (rf & 2) {
|
|
31
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
32
|
-
i0.ɵɵadvance();
|
|
33
|
-
i0.ɵɵtextInterpolate1(" ", ctx_r0.question.helpText, " ");
|
|
34
|
-
} }
|
|
35
|
-
function FormQuestionComponent_Conditional_4_Template(rf, ctx) { if (rf & 1) {
|
|
36
|
-
const _r2 = i0.ɵɵgetCurrentView();
|
|
37
|
-
i0.ɵɵelementStart(0, "input", 19);
|
|
38
|
-
i0.ɵɵlistener("input", function FormQuestionComponent_Conditional_4_Template_input_input_0_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onValueChange($event.target.value)); });
|
|
39
|
-
i0.ɵɵelementEnd();
|
|
40
|
-
} if (rf & 2) {
|
|
41
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
42
|
-
i0.ɵɵproperty("value", ctx_r0.value || "")("placeholder", ctx_r0.placeholder)("disabled", ctx_r0.disabled);
|
|
43
|
-
} }
|
|
44
|
-
function FormQuestionComponent_Conditional_5_Template(rf, ctx) { if (rf & 1) {
|
|
45
|
-
const _r3 = i0.ɵɵgetCurrentView();
|
|
46
|
-
i0.ɵɵelementStart(0, "input", 20);
|
|
47
|
-
i0.ɵɵlistener("input", function FormQuestionComponent_Conditional_5_Template_input_input_0_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onValueChange($event.target.value)); });
|
|
48
|
-
i0.ɵɵelementEnd();
|
|
49
|
-
} if (rf & 2) {
|
|
50
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
51
|
-
i0.ɵɵproperty("value", ctx_r0.value || "")("placeholder", ctx_r0.placeholder)("disabled", ctx_r0.disabled);
|
|
52
|
-
} }
|
|
53
|
-
function FormQuestionComponent_Conditional_6_Template(rf, ctx) { if (rf & 1) {
|
|
54
|
-
const _r4 = i0.ɵɵgetCurrentView();
|
|
55
|
-
i0.ɵɵelementStart(0, "textarea", 21);
|
|
56
|
-
i0.ɵɵlistener("input", function FormQuestionComponent_Conditional_6_Template_textarea_input_0_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onValueChange($event.target.value)); });
|
|
57
|
-
i0.ɵɵelementEnd();
|
|
58
|
-
} if (rf & 2) {
|
|
59
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
60
|
-
i0.ɵɵproperty("value", ctx_r0.value || "")("placeholder", ctx_r0.placeholder)("disabled", ctx_r0.disabled);
|
|
61
|
-
} }
|
|
62
|
-
function FormQuestionComponent_Conditional_7_Template(rf, ctx) { if (rf & 1) {
|
|
63
|
-
const _r5 = i0.ɵɵgetCurrentView();
|
|
64
|
-
i0.ɵɵelementStart(0, "kendo-numerictextbox", 22);
|
|
65
|
-
i0.ɵɵlistener("valueChange", function FormQuestionComponent_Conditional_7_Template_kendo_numerictextbox_valueChange_0_listener($event) { i0.ɵɵrestoreView(_r5); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onValueChange($event)); });
|
|
66
|
-
i0.ɵɵelementEnd();
|
|
67
|
-
} if (rf & 2) {
|
|
68
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
69
|
-
i0.ɵɵproperty("value", ctx_r0.value)("min", ctx_r0.min || 0)("max", ctx_r0.max || 999999999)("step", ctx_r0.step || 1)("disabled", ctx_r0.disabled);
|
|
70
|
-
} }
|
|
71
|
-
function FormQuestionComponent_Conditional_8_Template(rf, ctx) { if (rf & 1) {
|
|
72
|
-
const _r6 = i0.ɵɵgetCurrentView();
|
|
73
|
-
i0.ɵɵelementStart(0, "kendo-numerictextbox", 23);
|
|
74
|
-
i0.ɵɵlistener("valueChange", function FormQuestionComponent_Conditional_8_Template_kendo_numerictextbox_valueChange_0_listener($event) { i0.ɵɵrestoreView(_r6); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onValueChange($event)); });
|
|
75
|
-
i0.ɵɵelementEnd();
|
|
76
|
-
} if (rf & 2) {
|
|
77
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
78
|
-
i0.ɵɵproperty("value", ctx_r0.value)("min", ctx_r0.min || 0)("max", ctx_r0.max || 999999999)("step", ctx_r0.step || 0.01)("format", "c2")("disabled", ctx_r0.disabled);
|
|
79
|
-
} }
|
|
80
|
-
function FormQuestionComponent_Conditional_9_Template(rf, ctx) { if (rf & 1) {
|
|
81
|
-
const _r7 = i0.ɵɵgetCurrentView();
|
|
82
|
-
i0.ɵɵelementStart(0, "kendo-datepicker", 24);
|
|
83
|
-
i0.ɵɵlistener("valueChange", function FormQuestionComponent_Conditional_9_Template_kendo_datepicker_valueChange_0_listener($event) { i0.ɵɵrestoreView(_r7); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onValueChange($event)); });
|
|
84
|
-
i0.ɵɵelementEnd();
|
|
85
|
-
} if (rf & 2) {
|
|
86
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
87
|
-
i0.ɵɵproperty("value", ctx_r0.value)("disabled", ctx_r0.disabled);
|
|
88
|
-
} }
|
|
89
|
-
function FormQuestionComponent_Conditional_10_Template(rf, ctx) { if (rf & 1) {
|
|
90
|
-
const _r8 = i0.ɵɵgetCurrentView();
|
|
91
|
-
i0.ɵɵelementStart(0, "kendo-datetimepicker", 24);
|
|
92
|
-
i0.ɵɵlistener("valueChange", function FormQuestionComponent_Conditional_10_Template_kendo_datetimepicker_valueChange_0_listener($event) { i0.ɵɵrestoreView(_r8); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onValueChange($event)); });
|
|
93
|
-
i0.ɵɵelementEnd();
|
|
94
|
-
} if (rf & 2) {
|
|
95
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
96
|
-
i0.ɵɵproperty("value", ctx_r0.value)("disabled", ctx_r0.disabled);
|
|
97
|
-
} }
|
|
98
|
-
function FormQuestionComponent_Conditional_11_For_2_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
99
|
-
i0.ɵɵelement(0, "i", 28);
|
|
100
|
-
} if (rf & 2) {
|
|
101
|
-
const option_r10 = i0.ɵɵnextContext().$implicit;
|
|
102
|
-
i0.ɵɵclassMap(i0.ɵɵinterpolate1("fa ", option_r10.icon));
|
|
103
|
-
} }
|
|
104
|
-
function FormQuestionComponent_Conditional_11_For_2_Template(rf, ctx) { if (rf & 1) {
|
|
105
|
-
const _r9 = i0.ɵɵgetCurrentView();
|
|
106
|
-
i0.ɵɵelementStart(0, "button", 26);
|
|
107
|
-
i0.ɵɵlistener("click", function FormQuestionComponent_Conditional_11_For_2_Template_button_click_0_listener() { const option_r10 = i0.ɵɵrestoreView(_r9).$implicit; const ctx_r0 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r0.onValueChange(option_r10.value)); });
|
|
108
|
-
i0.ɵɵconditionalCreate(1, FormQuestionComponent_Conditional_11_For_2_Conditional_1_Template, 1, 3, "i", 27);
|
|
109
|
-
i0.ɵɵtext(2);
|
|
110
|
-
i0.ɵɵelementEnd();
|
|
111
|
-
} if (rf & 2) {
|
|
112
|
-
const option_r10 = ctx.$implicit;
|
|
113
|
-
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
114
|
-
i0.ɵɵproperty("toggleable", true)("selected", ctx_r0.value === option_r10.value)("disabled", ctx_r0.disabled);
|
|
115
|
-
i0.ɵɵadvance();
|
|
116
|
-
i0.ɵɵconditional(option_r10.icon ? 1 : -1);
|
|
117
|
-
i0.ɵɵadvance();
|
|
118
|
-
i0.ɵɵtextInterpolate1(" ", option_r10.label, " ");
|
|
119
|
-
} }
|
|
120
|
-
function FormQuestionComponent_Conditional_11_Template(rf, ctx) { if (rf & 1) {
|
|
121
|
-
i0.ɵɵelementStart(0, "kendo-buttongroup", 10);
|
|
122
|
-
i0.ɵɵrepeaterCreate(1, FormQuestionComponent_Conditional_11_For_2_Template, 3, 5, "button", 25, i0.ɵɵcomponentInstance().trackByValue, true);
|
|
123
|
-
i0.ɵɵelementEnd();
|
|
124
|
-
} if (rf & 2) {
|
|
125
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
126
|
-
i0.ɵɵproperty("selection", "single");
|
|
127
|
-
i0.ɵɵadvance();
|
|
128
|
-
i0.ɵɵrepeater(ctx_r0.options);
|
|
129
|
-
} }
|
|
130
|
-
function FormQuestionComponent_Conditional_12_For_2_Conditional_3_Template(rf, ctx) { if (rf & 1) {
|
|
131
|
-
i0.ɵɵelement(0, "i", 28);
|
|
132
|
-
} if (rf & 2) {
|
|
133
|
-
const option_r12 = i0.ɵɵnextContext().$implicit;
|
|
134
|
-
i0.ɵɵclassMap(i0.ɵɵinterpolate1("fa ", option_r12.icon));
|
|
135
|
-
} }
|
|
136
|
-
function FormQuestionComponent_Conditional_12_For_2_Template(rf, ctx) { if (rf & 1) {
|
|
137
|
-
const _r11 = i0.ɵɵgetCurrentView();
|
|
138
|
-
i0.ɵɵelementStart(0, "div", 29)(1, "input", 30);
|
|
139
|
-
i0.ɵɵlistener("change", function FormQuestionComponent_Conditional_12_For_2_Template_input_change_1_listener() { const option_r12 = i0.ɵɵrestoreView(_r11).$implicit; const ctx_r0 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r0.onValueChange(option_r12.value)); });
|
|
140
|
-
i0.ɵɵelementEnd();
|
|
141
|
-
i0.ɵɵelementStart(2, "label", 31);
|
|
142
|
-
i0.ɵɵconditionalCreate(3, FormQuestionComponent_Conditional_12_For_2_Conditional_3_Template, 1, 3, "i", 27);
|
|
143
|
-
i0.ɵɵtext(4);
|
|
144
|
-
i0.ɵɵelementEnd()();
|
|
145
|
-
} if (rf & 2) {
|
|
146
|
-
const option_r12 = ctx.$implicit;
|
|
147
|
-
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
148
|
-
i0.ɵɵadvance();
|
|
149
|
-
i0.ɵɵproperty("name", ctx_r0.question.id)("value", option_r12.value)("checked", ctx_r0.value === option_r12.value)("disabled", ctx_r0.disabled)("id", ctx_r0.question.id + "_" + option_r12.value);
|
|
150
|
-
i0.ɵɵadvance();
|
|
151
|
-
i0.ɵɵproperty("for", ctx_r0.question.id + "_" + option_r12.value);
|
|
152
|
-
i0.ɵɵadvance();
|
|
153
|
-
i0.ɵɵconditional(option_r12.icon ? 3 : -1);
|
|
154
|
-
i0.ɵɵadvance();
|
|
155
|
-
i0.ɵɵtextInterpolate1(" ", option_r12.label, " ");
|
|
156
|
-
} }
|
|
157
|
-
function FormQuestionComponent_Conditional_12_Template(rf, ctx) { if (rf & 1) {
|
|
158
|
-
i0.ɵɵelementStart(0, "div", 11);
|
|
159
|
-
i0.ɵɵrepeaterCreate(1, FormQuestionComponent_Conditional_12_For_2_Template, 5, 8, "div", 29, i0.ɵɵcomponentInstance().trackByValue, true);
|
|
160
|
-
i0.ɵɵelementEnd();
|
|
161
|
-
} if (rf & 2) {
|
|
162
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
163
|
-
i0.ɵɵadvance();
|
|
164
|
-
i0.ɵɵrepeater(ctx_r0.options);
|
|
165
|
-
} }
|
|
166
|
-
function FormQuestionComponent_Conditional_13_For_4_Template(rf, ctx) { if (rf & 1) {
|
|
167
|
-
i0.ɵɵelementStart(0, "option", 33);
|
|
168
|
-
i0.ɵɵtext(1);
|
|
169
|
-
i0.ɵɵelementEnd();
|
|
170
|
-
} if (rf & 2) {
|
|
171
|
-
const option_r13 = ctx.$implicit;
|
|
172
|
-
i0.ɵɵproperty("value", option_r13.value);
|
|
173
|
-
i0.ɵɵadvance();
|
|
174
|
-
i0.ɵɵtextInterpolate1(" ", option_r13.label, " ");
|
|
175
|
-
} }
|
|
176
|
-
function FormQuestionComponent_Conditional_13_Template(rf, ctx) { if (rf & 1) {
|
|
177
|
-
i0.ɵɵelementStart(0, "select", 12)(1, "option", 32);
|
|
178
|
-
i0.ɵɵtext(2, "Select an option...");
|
|
179
|
-
i0.ɵɵelementEnd();
|
|
180
|
-
i0.ɵɵrepeaterCreate(3, FormQuestionComponent_Conditional_13_For_4_Template, 2, 2, "option", 33, i0.ɵɵcomponentInstance().trackByValue, true);
|
|
181
|
-
i0.ɵɵelementEnd();
|
|
182
|
-
} if (rf & 2) {
|
|
183
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
184
|
-
i0.ɵɵproperty("formControl", ctx_r0.control)("disabled", ctx_r0.disabled);
|
|
185
|
-
i0.ɵɵadvance(3);
|
|
186
|
-
i0.ɵɵrepeater(ctx_r0.options);
|
|
187
|
-
} }
|
|
188
|
-
function FormQuestionComponent_Conditional_14_Template(rf, ctx) { if (rf & 1) {
|
|
189
|
-
const _r14 = i0.ɵɵgetCurrentView();
|
|
190
|
-
i0.ɵɵelementStart(0, "div", 13)(1, "kendo-slider", 34);
|
|
191
|
-
i0.ɵɵlistener("valueChange", function FormQuestionComponent_Conditional_14_Template_kendo_slider_valueChange_1_listener($event) { i0.ɵɵrestoreView(_r14); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onValueChange($event)); });
|
|
192
|
-
i0.ɵɵelementEnd();
|
|
193
|
-
i0.ɵɵelementStart(2, "div", 35);
|
|
194
|
-
i0.ɵɵtext(3);
|
|
195
|
-
i0.ɵɵelementEnd()();
|
|
196
|
-
} if (rf & 2) {
|
|
197
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
198
|
-
i0.ɵɵadvance();
|
|
199
|
-
i0.ɵɵproperty("min", ctx_r0.getSliderConfig().min)("max", ctx_r0.getSliderConfig().max)("smallStep", ctx_r0.getSliderConfig().step || 1)("value", ctx_r0.value || ctx_r0.getSliderConfig().min)("disabled", ctx_r0.disabled);
|
|
200
|
-
i0.ɵɵadvance(2);
|
|
201
|
-
i0.ɵɵtextInterpolate2(" ", ctx_r0.value || ctx_r0.getSliderConfig().min, "", ctx_r0.getSliderConfig().suffix || "", " ");
|
|
202
|
-
} }
|
|
203
|
-
function FormQuestionComponent_Conditional_15_Template(rf, ctx) { if (rf & 1) {
|
|
204
|
-
const _r15 = i0.ɵɵgetCurrentView();
|
|
205
|
-
i0.ɵɵelementStart(0, "div", 14)(1, "kendo-datepicker", 36);
|
|
206
|
-
i0.ɵɵlistener("valueChange", function FormQuestionComponent_Conditional_15_Template_kendo_datepicker_valueChange_1_listener($event) { i0.ɵɵrestoreView(_r15); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onDateRangeStartChange($event)); });
|
|
207
|
-
i0.ɵɵelementEnd();
|
|
208
|
-
i0.ɵɵelementStart(2, "span", 37);
|
|
209
|
-
i0.ɵɵtext(3, "to");
|
|
210
|
-
i0.ɵɵelementEnd();
|
|
211
|
-
i0.ɵɵelementStart(4, "kendo-datepicker", 38);
|
|
212
|
-
i0.ɵɵlistener("valueChange", function FormQuestionComponent_Conditional_15_Template_kendo_datepicker_valueChange_4_listener($event) { i0.ɵɵrestoreView(_r15); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onDateRangeEndChange($event)); });
|
|
213
|
-
i0.ɵɵelementEnd()();
|
|
214
|
-
} if (rf & 2) {
|
|
215
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
216
|
-
i0.ɵɵadvance();
|
|
217
|
-
i0.ɵɵproperty("value", ctx_r0.value == null ? null : ctx_r0.value.start)("disabled", ctx_r0.disabled);
|
|
218
|
-
i0.ɵɵadvance(3);
|
|
219
|
-
i0.ɵɵproperty("value", ctx_r0.value == null ? null : ctx_r0.value.end)("disabled", ctx_r0.disabled);
|
|
220
|
-
} }
|
|
221
|
-
function FormQuestionComponent_Conditional_16_Template(rf, ctx) { if (rf & 1) {
|
|
222
|
-
const _r16 = i0.ɵɵgetCurrentView();
|
|
223
|
-
i0.ɵɵelementStart(0, "kendo-timepicker", 39);
|
|
224
|
-
i0.ɵɵlistener("valueChange", function FormQuestionComponent_Conditional_16_Template_kendo_timepicker_valueChange_0_listener($event) { i0.ɵɵrestoreView(_r16); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onValueChange($event)); });
|
|
225
|
-
i0.ɵɵelementEnd();
|
|
226
|
-
} if (rf & 2) {
|
|
227
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
228
|
-
i0.ɵɵproperty("value", ctx_r0.value)("disabled", ctx_r0.disabled)("format", "h:mm a");
|
|
229
|
-
} }
|
|
230
|
-
function FormQuestionComponent_Conditional_17_For_2_Conditional_3_Template(rf, ctx) { if (rf & 1) {
|
|
231
|
-
i0.ɵɵelement(0, "i", 28);
|
|
232
|
-
} if (rf & 2) {
|
|
233
|
-
const option_r18 = i0.ɵɵnextContext().$implicit;
|
|
234
|
-
i0.ɵɵclassMap(i0.ɵɵinterpolate1("fa ", option_r18.icon));
|
|
235
|
-
} }
|
|
236
|
-
function FormQuestionComponent_Conditional_17_For_2_Template(rf, ctx) { if (rf & 1) {
|
|
237
|
-
const _r17 = i0.ɵɵgetCurrentView();
|
|
238
|
-
i0.ɵɵelementStart(0, "div", 40)(1, "input", 41);
|
|
239
|
-
i0.ɵɵlistener("change", function FormQuestionComponent_Conditional_17_For_2_Template_input_change_1_listener() { const option_r18 = i0.ɵɵrestoreView(_r17).$implicit; const ctx_r0 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r0.toggleCheckbox(option_r18)); });
|
|
240
|
-
i0.ɵɵelementEnd();
|
|
241
|
-
i0.ɵɵelementStart(2, "label", 42);
|
|
242
|
-
i0.ɵɵconditionalCreate(3, FormQuestionComponent_Conditional_17_For_2_Conditional_3_Template, 1, 3, "i", 27);
|
|
243
|
-
i0.ɵɵtext(4);
|
|
244
|
-
i0.ɵɵelementEnd()();
|
|
245
|
-
} if (rf & 2) {
|
|
246
|
-
const option_r18 = ctx.$implicit;
|
|
247
|
-
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
248
|
-
i0.ɵɵadvance();
|
|
249
|
-
i0.ɵɵproperty("checked", ctx_r0.isChecked(option_r18))("disabled", ctx_r0.disabled)("id", ctx_r0.question.id + "_" + option_r18.value);
|
|
250
|
-
i0.ɵɵadvance();
|
|
251
|
-
i0.ɵɵproperty("for", ctx_r0.question.id + "_" + option_r18.value);
|
|
252
|
-
i0.ɵɵadvance();
|
|
253
|
-
i0.ɵɵconditional(option_r18.icon ? 3 : -1);
|
|
254
|
-
i0.ɵɵadvance();
|
|
255
|
-
i0.ɵɵtextInterpolate1(" ", option_r18.label, " ");
|
|
256
|
-
} }
|
|
257
|
-
function FormQuestionComponent_Conditional_17_Template(rf, ctx) { if (rf & 1) {
|
|
258
|
-
i0.ɵɵelementStart(0, "div", 16);
|
|
259
|
-
i0.ɵɵrepeaterCreate(1, FormQuestionComponent_Conditional_17_For_2_Template, 5, 6, "div", 40, i0.ɵɵcomponentInstance().trackByValue, true);
|
|
260
|
-
i0.ɵɵelementEnd();
|
|
261
|
-
} if (rf & 2) {
|
|
262
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
263
|
-
i0.ɵɵadvance();
|
|
264
|
-
i0.ɵɵrepeater(ctx_r0.options);
|
|
265
|
-
} }
|
|
266
|
-
function FormQuestionComponent_Conditional_18_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
267
|
-
i0.ɵɵelementStart(0, "span");
|
|
268
|
-
i0.ɵɵtext(1, "This field is required");
|
|
269
|
-
i0.ɵɵelementEnd();
|
|
270
|
-
} }
|
|
271
|
-
function FormQuestionComponent_Conditional_18_Conditional_2_Template(rf, ctx) { if (rf & 1) {
|
|
272
|
-
i0.ɵɵelementStart(0, "span");
|
|
273
|
-
i0.ɵɵtext(1, "Please enter a valid email address");
|
|
274
|
-
i0.ɵɵelementEnd();
|
|
275
|
-
} }
|
|
276
|
-
function FormQuestionComponent_Conditional_18_Conditional_3_Template(rf, ctx) { if (rf & 1) {
|
|
277
|
-
i0.ɵɵelementStart(0, "span");
|
|
278
|
-
i0.ɵɵtext(1);
|
|
279
|
-
i0.ɵɵelementEnd();
|
|
280
|
-
} if (rf & 2) {
|
|
281
|
-
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
282
|
-
i0.ɵɵadvance();
|
|
283
|
-
i0.ɵɵtextInterpolate1("Value must be at least ", ctx_r0.min);
|
|
284
|
-
} }
|
|
285
|
-
function FormQuestionComponent_Conditional_18_Conditional_4_Template(rf, ctx) { if (rf & 1) {
|
|
286
|
-
i0.ɵɵelementStart(0, "span");
|
|
287
|
-
i0.ɵɵtext(1);
|
|
288
|
-
i0.ɵɵelementEnd();
|
|
289
|
-
} if (rf & 2) {
|
|
290
|
-
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
291
|
-
i0.ɵɵadvance();
|
|
292
|
-
i0.ɵɵtextInterpolate1("Value must be at most ", ctx_r0.max);
|
|
293
|
-
} }
|
|
294
|
-
function FormQuestionComponent_Conditional_18_Template(rf, ctx) { if (rf & 1) {
|
|
295
|
-
i0.ɵɵelementStart(0, "div", 17);
|
|
296
|
-
i0.ɵɵconditionalCreate(1, FormQuestionComponent_Conditional_18_Conditional_1_Template, 2, 0, "span");
|
|
297
|
-
i0.ɵɵconditionalCreate(2, FormQuestionComponent_Conditional_18_Conditional_2_Template, 2, 0, "span");
|
|
298
|
-
i0.ɵɵconditionalCreate(3, FormQuestionComponent_Conditional_18_Conditional_3_Template, 2, 1, "span");
|
|
299
|
-
i0.ɵɵconditionalCreate(4, FormQuestionComponent_Conditional_18_Conditional_4_Template, 2, 1, "span");
|
|
300
|
-
i0.ɵɵelementEnd();
|
|
301
|
-
} if (rf & 2) {
|
|
302
|
-
const ctx_r0 = i0.ɵɵnextContext();
|
|
303
|
-
i0.ɵɵadvance();
|
|
304
|
-
i0.ɵɵconditional((ctx_r0.control.errors == null ? null : ctx_r0.control.errors["required"]) ? 1 : -1);
|
|
305
|
-
i0.ɵɵadvance();
|
|
306
|
-
i0.ɵɵconditional((ctx_r0.control.errors == null ? null : ctx_r0.control.errors["email"]) ? 2 : -1);
|
|
307
|
-
i0.ɵɵadvance();
|
|
308
|
-
i0.ɵɵconditional((ctx_r0.control.errors == null ? null : ctx_r0.control.errors["min"]) ? 3 : -1);
|
|
309
|
-
i0.ɵɵadvance();
|
|
310
|
-
i0.ɵɵconditional((ctx_r0.control.errors == null ? null : ctx_r0.control.errors["max"]) ? 4 : -1);
|
|
311
|
-
} }
|
|
312
|
-
/**
|
|
313
|
-
* Component for rendering individual form questions with various input types
|
|
314
|
-
* Implements ControlValueAccessor for seamless integration with Angular forms
|
|
315
|
-
*/
|
|
316
|
-
export class FormQuestionComponent {
|
|
317
|
-
question;
|
|
318
|
-
control;
|
|
319
|
-
value = null;
|
|
320
|
-
disabled = false;
|
|
321
|
-
onChange = () => { };
|
|
322
|
-
onTouched = () => { };
|
|
323
|
-
ngOnInit() {
|
|
324
|
-
// Debug logging for dropdown issues
|
|
325
|
-
if (this.questionType === 'dropdown') {
|
|
326
|
-
console.log('[FormQuestion] Dropdown initialized:', {
|
|
327
|
-
questionId: this.question.id,
|
|
328
|
-
hasControl: !!this.control,
|
|
329
|
-
controlValue: this.control?.value,
|
|
330
|
-
options: this.options,
|
|
331
|
-
value: this.value
|
|
332
|
-
});
|
|
333
|
-
}
|
|
334
|
-
}
|
|
335
|
-
/**
|
|
336
|
-
* Get the question type (handles both simple string and complex types)
|
|
337
|
-
*/
|
|
338
|
-
get questionType() {
|
|
339
|
-
return typeof this.question.type === 'string'
|
|
340
|
-
? this.question.type
|
|
341
|
-
: this.question.type.type;
|
|
342
|
-
}
|
|
343
|
-
/**
|
|
344
|
-
* Check if this is a choice-based question (buttongroup, radio, dropdown, checkbox)
|
|
345
|
-
*/
|
|
346
|
-
get isChoiceQuestion() {
|
|
347
|
-
const type = this.questionType;
|
|
348
|
-
return ['buttongroup', 'radio', 'dropdown', 'checkbox'].includes(type);
|
|
349
|
-
}
|
|
350
|
-
/**
|
|
351
|
-
* Get options for choice questions
|
|
352
|
-
*/
|
|
353
|
-
get options() {
|
|
354
|
-
if (typeof this.question.type === 'object' && 'options' in this.question.type) {
|
|
355
|
-
return this.question.type.options;
|
|
356
|
-
}
|
|
357
|
-
return [];
|
|
358
|
-
}
|
|
359
|
-
/**
|
|
360
|
-
* Check if multiple selections are allowed (for checkbox type)
|
|
361
|
-
*/
|
|
362
|
-
get allowMultiple() {
|
|
363
|
-
return this.questionType === 'checkbox' ||
|
|
364
|
-
(typeof this.question.type === 'object' && 'multiple' in this.question.type && !!this.question.type.multiple);
|
|
365
|
-
}
|
|
366
|
-
/**
|
|
367
|
-
* Get CSS class for field width based on widthHint or intelligent defaults
|
|
368
|
-
*/
|
|
369
|
-
get widthClass() {
|
|
370
|
-
// If explicit widthHint provided, use it
|
|
371
|
-
if (this.question.widthHint) {
|
|
372
|
-
return `width-${this.question.widthHint}`;
|
|
373
|
-
}
|
|
374
|
-
// Otherwise, apply intelligent defaults based on question type
|
|
375
|
-
const type = this.questionType;
|
|
376
|
-
// Narrow fields
|
|
377
|
-
if (['number', 'currency', 'date', 'datetime', 'time'].includes(type)) {
|
|
378
|
-
return 'width-narrow';
|
|
379
|
-
}
|
|
380
|
-
// Wide fields for choice-based controls (need space for multiple options)
|
|
381
|
-
if (['buttongroup', 'radio', 'checkbox'].includes(type)) {
|
|
382
|
-
return 'width-wide';
|
|
383
|
-
}
|
|
384
|
-
// Auto-width for dropdowns
|
|
385
|
-
if (type === 'dropdown') {
|
|
386
|
-
return 'width-auto';
|
|
387
|
-
}
|
|
388
|
-
// Full-width fields
|
|
389
|
-
if (type === 'textarea') {
|
|
390
|
-
return 'width-full';
|
|
391
|
-
}
|
|
392
|
-
// Wide fields
|
|
393
|
-
if (type === 'email') {
|
|
394
|
-
return 'width-wide';
|
|
395
|
-
}
|
|
396
|
-
// Default to medium for text and other types
|
|
397
|
-
return 'width-medium';
|
|
398
|
-
}
|
|
399
|
-
/**
|
|
400
|
-
* Get placeholder text for text inputs
|
|
401
|
-
*/
|
|
402
|
-
get placeholder() {
|
|
403
|
-
if (typeof this.question.type === 'object' && 'placeholder' in this.question.type) {
|
|
404
|
-
return this.question.type.placeholder;
|
|
405
|
-
}
|
|
406
|
-
return undefined;
|
|
407
|
-
}
|
|
408
|
-
/**
|
|
409
|
-
* Get min value for number/currency inputs
|
|
410
|
-
*/
|
|
411
|
-
get min() {
|
|
412
|
-
if (typeof this.question.type === 'object' && 'min' in this.question.type) {
|
|
413
|
-
return this.question.type.min;
|
|
414
|
-
}
|
|
415
|
-
return undefined;
|
|
416
|
-
}
|
|
417
|
-
/**
|
|
418
|
-
* Get max value for number/currency inputs
|
|
419
|
-
*/
|
|
420
|
-
get max() {
|
|
421
|
-
if (typeof this.question.type === 'object' && 'max' in this.question.type) {
|
|
422
|
-
return this.question.type.max;
|
|
423
|
-
}
|
|
424
|
-
return undefined;
|
|
425
|
-
}
|
|
426
|
-
/**
|
|
427
|
-
* Get step value for number/currency inputs
|
|
428
|
-
*/
|
|
429
|
-
get step() {
|
|
430
|
-
if (typeof this.question.type === 'object' && 'step' in this.question.type) {
|
|
431
|
-
return this.question.type.step;
|
|
432
|
-
}
|
|
433
|
-
return undefined;
|
|
434
|
-
}
|
|
435
|
-
/**
|
|
436
|
-
* Get prefix for currency inputs
|
|
437
|
-
*/
|
|
438
|
-
get prefix() {
|
|
439
|
-
if (typeof this.question.type === 'object' && 'prefix' in this.question.type) {
|
|
440
|
-
return this.question.type.prefix;
|
|
441
|
-
}
|
|
442
|
-
return undefined;
|
|
443
|
-
}
|
|
444
|
-
/**
|
|
445
|
-
* Get suffix for currency inputs
|
|
446
|
-
*/
|
|
447
|
-
get suffix() {
|
|
448
|
-
if (typeof this.question.type === 'object' && 'suffix' in this.question.type) {
|
|
449
|
-
return this.question.type.suffix;
|
|
450
|
-
}
|
|
451
|
-
return undefined;
|
|
452
|
-
}
|
|
453
|
-
/**
|
|
454
|
-
* Handle value changes
|
|
455
|
-
*/
|
|
456
|
-
onValueChange(newValue) {
|
|
457
|
-
this.value = newValue;
|
|
458
|
-
this.onChange(newValue);
|
|
459
|
-
this.onTouched();
|
|
460
|
-
}
|
|
461
|
-
/**
|
|
462
|
-
* Handle checkbox toggle for multiple selection
|
|
463
|
-
*/
|
|
464
|
-
toggleCheckbox(option) {
|
|
465
|
-
if (!this.allowMultiple) {
|
|
466
|
-
// Single selection mode
|
|
467
|
-
this.onValueChange(option.value);
|
|
468
|
-
}
|
|
469
|
-
else {
|
|
470
|
-
// Multiple selection mode
|
|
471
|
-
const currentValues = Array.isArray(this.value) ? this.value : [];
|
|
472
|
-
const index = currentValues.indexOf(option.value);
|
|
473
|
-
let newValues;
|
|
474
|
-
if (index > -1) {
|
|
475
|
-
// Remove if already selected
|
|
476
|
-
newValues = currentValues.filter((v) => v !== option.value);
|
|
477
|
-
}
|
|
478
|
-
else {
|
|
479
|
-
// Add if not selected
|
|
480
|
-
newValues = [...currentValues, option.value];
|
|
481
|
-
}
|
|
482
|
-
this.onValueChange(newValues);
|
|
483
|
-
}
|
|
484
|
-
}
|
|
485
|
-
/**
|
|
486
|
-
* Check if a checkbox option is selected
|
|
487
|
-
*/
|
|
488
|
-
isChecked(option) {
|
|
489
|
-
if (!this.allowMultiple) {
|
|
490
|
-
return this.value === option.value;
|
|
491
|
-
}
|
|
492
|
-
else {
|
|
493
|
-
return Array.isArray(this.value) && this.value.includes(option.value);
|
|
494
|
-
}
|
|
495
|
-
}
|
|
496
|
-
// ControlValueAccessor implementation
|
|
497
|
-
writeValue(value) {
|
|
498
|
-
this.value = value;
|
|
499
|
-
}
|
|
500
|
-
registerOnChange(fn) {
|
|
501
|
-
this.onChange = fn;
|
|
502
|
-
}
|
|
503
|
-
registerOnTouched(fn) {
|
|
504
|
-
this.onTouched = fn;
|
|
505
|
-
}
|
|
506
|
-
setDisabledState(isDisabled) {
|
|
507
|
-
this.disabled = isDisabled;
|
|
508
|
-
}
|
|
509
|
-
/**
|
|
510
|
-
* Debug handler for dropdown changes
|
|
511
|
-
*/
|
|
512
|
-
onDropdownChange(value) {
|
|
513
|
-
console.log('[FormQuestion] Dropdown value changed:', {
|
|
514
|
-
questionId: this.question.id,
|
|
515
|
-
newValue: value,
|
|
516
|
-
controlValue: this.control?.value,
|
|
517
|
-
optionsCount: this.options.length
|
|
518
|
-
});
|
|
519
|
-
}
|
|
520
|
-
/**
|
|
521
|
-
* Get slider configuration
|
|
522
|
-
*/
|
|
523
|
-
getSliderConfig() {
|
|
524
|
-
if (typeof this.question.type === 'object' && this.question.type.type === 'slider') {
|
|
525
|
-
return {
|
|
526
|
-
min: this.question.type.min,
|
|
527
|
-
max: this.question.type.max,
|
|
528
|
-
step: this.question.type.step,
|
|
529
|
-
suffix: this.question.type.suffix
|
|
530
|
-
};
|
|
531
|
-
}
|
|
532
|
-
return { min: 0, max: 100, step: 1 };
|
|
533
|
-
}
|
|
534
|
-
/**
|
|
535
|
-
* Handle date range start date change
|
|
536
|
-
*/
|
|
537
|
-
onDateRangeStartChange(value) {
|
|
538
|
-
const current = this.value || {};
|
|
539
|
-
this.onValueChange({ ...current, start: value });
|
|
540
|
-
}
|
|
541
|
-
/**
|
|
542
|
-
* Handle date range end date change
|
|
543
|
-
*/
|
|
544
|
-
onDateRangeEndChange(value) {
|
|
545
|
-
const current = this.value || {};
|
|
546
|
-
this.onValueChange({ ...current, end: value });
|
|
547
|
-
}
|
|
548
|
-
/**
|
|
549
|
-
* Track by function for options list
|
|
550
|
-
*/
|
|
551
|
-
trackByValue(index, option) {
|
|
552
|
-
return option.value;
|
|
553
|
-
}
|
|
554
|
-
static ɵfac = function FormQuestionComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || FormQuestionComponent)(); };
|
|
555
|
-
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: FormQuestionComponent, selectors: [["mj-form-question"]], inputs: { question: "question", control: "control" }, standalone: false, features: [i0.ɵɵProvidersFeature([
|
|
556
|
-
{
|
|
557
|
-
provide: NG_VALUE_ACCESSOR,
|
|
558
|
-
useExisting: forwardRef(() => FormQuestionComponent),
|
|
559
|
-
multi: true
|
|
560
|
-
}
|
|
561
|
-
])], decls: 19, vars: 20, consts: [[1, "form-question"], [1, "question-label"], [1, "help-text"], [1, "input-container", 3, "ngClass"], ["type", "text", "kendoTextBox", "", 1, "question-input", 3, "value", "placeholder", "disabled"], ["type", "email", "kendoTextBox", "", 1, "question-input", 3, "value", "placeholder", "disabled"], ["kendoTextArea", "", "rows", "5", 1, "question-textarea", 3, "value", "placeholder", "disabled"], [1, "question-input", 3, "value", "min", "max", "step", "disabled"], [1, "question-input", 3, "value", "min", "max", "step", "format", "disabled"], [1, "question-input", 3, "value", "disabled"], [1, "question-buttongroup", 3, "selection"], [1, "question-radio-group"], [1, "question-dropdown", 3, "formControl", "disabled"], [1, "question-slider-container"], [1, "question-daterange"], [1, "question-input", 3, "value", "disabled", "format"], [1, "question-checkbox-group"], [1, "validation-error"], [1, "required-indicator"], ["type", "text", "kendoTextBox", "", 1, "question-input", 3, "input", "value", "placeholder", "disabled"], ["type", "email", "kendoTextBox", "", 1, "question-input", 3, "input", "value", "placeholder", "disabled"], ["kendoTextArea", "", "rows", "5", 1, "question-textarea", 3, "input", "value", "placeholder", "disabled"], [1, "question-input", 3, "valueChange", "value", "min", "max", "step", "disabled"], [1, "question-input", 3, "valueChange", "value", "min", "max", "step", "format", "disabled"], [1, "question-input", 3, "valueChange", "value", "disabled"], ["kendoButton", "", 1, "buttongroup-option", 3, "toggleable", "selected", "disabled"], ["kendoButton", "", 1, "buttongroup-option", 3, "click", "toggleable", "selected", "disabled"], ["aria-hidden", "true", 3, "class"], ["aria-hidden", "true"], [1, "radio-option"], ["type", "radio", "kendoRadioButton", "", 3, "change", "name", "value", "checked", "disabled", "id"], [1, "radio-label", 3, "for"], ["value", ""], [3, "value"], [1, "question-slider", 3, "valueChange", "min", "max", "smallStep", "value", "disabled"], [1, "slider-value"], ["placeholder", "Start Date", 1, "daterange-start", 3, "valueChange", "value", "disabled"], [1, "daterange-separator"], ["placeholder", "End Date", 1, "daterange-end", 3, "valueChange", "value", "disabled"], [1, "question-input", 3, "valueChange", "value", "disabled", "format"], [1, "checkbox-option"], ["type", "checkbox", "kendoCheckBox", "", 3, "change", "checked", "disabled", "id"], [1, "checkbox-label", 3, "for"]], template: function FormQuestionComponent_Template(rf, ctx) { if (rf & 1) {
|
|
562
|
-
i0.ɵɵelementStart(0, "div", 0);
|
|
563
|
-
i0.ɵɵconditionalCreate(1, FormQuestionComponent_Conditional_1_Template, 3, 2, "label", 1);
|
|
564
|
-
i0.ɵɵconditionalCreate(2, FormQuestionComponent_Conditional_2_Template, 2, 1, "div", 2);
|
|
565
|
-
i0.ɵɵelementStart(3, "div", 3);
|
|
566
|
-
i0.ɵɵconditionalCreate(4, FormQuestionComponent_Conditional_4_Template, 1, 3, "input", 4);
|
|
567
|
-
i0.ɵɵconditionalCreate(5, FormQuestionComponent_Conditional_5_Template, 1, 3, "input", 5);
|
|
568
|
-
i0.ɵɵconditionalCreate(6, FormQuestionComponent_Conditional_6_Template, 1, 3, "textarea", 6);
|
|
569
|
-
i0.ɵɵconditionalCreate(7, FormQuestionComponent_Conditional_7_Template, 1, 5, "kendo-numerictextbox", 7);
|
|
570
|
-
i0.ɵɵconditionalCreate(8, FormQuestionComponent_Conditional_8_Template, 1, 6, "kendo-numerictextbox", 8);
|
|
571
|
-
i0.ɵɵconditionalCreate(9, FormQuestionComponent_Conditional_9_Template, 1, 2, "kendo-datepicker", 9);
|
|
572
|
-
i0.ɵɵconditionalCreate(10, FormQuestionComponent_Conditional_10_Template, 1, 2, "kendo-datetimepicker", 9);
|
|
573
|
-
i0.ɵɵconditionalCreate(11, FormQuestionComponent_Conditional_11_Template, 3, 1, "kendo-buttongroup", 10);
|
|
574
|
-
i0.ɵɵconditionalCreate(12, FormQuestionComponent_Conditional_12_Template, 3, 0, "div", 11);
|
|
575
|
-
i0.ɵɵconditionalCreate(13, FormQuestionComponent_Conditional_13_Template, 5, 2, "select", 12);
|
|
576
|
-
i0.ɵɵconditionalCreate(14, FormQuestionComponent_Conditional_14_Template, 4, 7, "div", 13);
|
|
577
|
-
i0.ɵɵconditionalCreate(15, FormQuestionComponent_Conditional_15_Template, 5, 4, "div", 14);
|
|
578
|
-
i0.ɵɵconditionalCreate(16, FormQuestionComponent_Conditional_16_Template, 1, 3, "kendo-timepicker", 15);
|
|
579
|
-
i0.ɵɵconditionalCreate(17, FormQuestionComponent_Conditional_17_Template, 3, 0, "div", 16);
|
|
580
|
-
i0.ɵɵelementEnd();
|
|
581
|
-
i0.ɵɵconditionalCreate(18, FormQuestionComponent_Conditional_18_Template, 5, 4, "div", 17);
|
|
582
|
-
i0.ɵɵelementEnd();
|
|
583
|
-
} if (rf & 2) {
|
|
584
|
-
i0.ɵɵclassProp("required", ctx.question.required);
|
|
585
|
-
i0.ɵɵadvance();
|
|
586
|
-
i0.ɵɵconditional(ctx.question.label ? 1 : -1);
|
|
587
|
-
i0.ɵɵadvance();
|
|
588
|
-
i0.ɵɵconditional(ctx.question.helpText ? 2 : -1);
|
|
589
|
-
i0.ɵɵadvance();
|
|
590
|
-
i0.ɵɵproperty("ngClass", ctx.widthClass);
|
|
591
|
-
i0.ɵɵadvance();
|
|
592
|
-
i0.ɵɵconditional(ctx.questionType === "text" ? 4 : -1);
|
|
593
|
-
i0.ɵɵadvance();
|
|
594
|
-
i0.ɵɵconditional(ctx.questionType === "email" ? 5 : -1);
|
|
595
|
-
i0.ɵɵadvance();
|
|
596
|
-
i0.ɵɵconditional(ctx.questionType === "textarea" ? 6 : -1);
|
|
597
|
-
i0.ɵɵadvance();
|
|
598
|
-
i0.ɵɵconditional(ctx.questionType === "number" ? 7 : -1);
|
|
599
|
-
i0.ɵɵadvance();
|
|
600
|
-
i0.ɵɵconditional(ctx.questionType === "currency" ? 8 : -1);
|
|
601
|
-
i0.ɵɵadvance();
|
|
602
|
-
i0.ɵɵconditional(ctx.questionType === "date" ? 9 : -1);
|
|
603
|
-
i0.ɵɵadvance();
|
|
604
|
-
i0.ɵɵconditional(ctx.questionType === "datetime" ? 10 : -1);
|
|
605
|
-
i0.ɵɵadvance();
|
|
606
|
-
i0.ɵɵconditional(ctx.questionType === "buttongroup" ? 11 : -1);
|
|
607
|
-
i0.ɵɵadvance();
|
|
608
|
-
i0.ɵɵconditional(ctx.questionType === "radio" ? 12 : -1);
|
|
609
|
-
i0.ɵɵadvance();
|
|
610
|
-
i0.ɵɵconditional(ctx.questionType === "dropdown" ? 13 : -1);
|
|
611
|
-
i0.ɵɵadvance();
|
|
612
|
-
i0.ɵɵconditional(ctx.questionType === "slider" ? 14 : -1);
|
|
613
|
-
i0.ɵɵadvance();
|
|
614
|
-
i0.ɵɵconditional(ctx.questionType === "daterange" ? 15 : -1);
|
|
615
|
-
i0.ɵɵadvance();
|
|
616
|
-
i0.ɵɵconditional(ctx.questionType === "time" ? 16 : -1);
|
|
617
|
-
i0.ɵɵadvance();
|
|
618
|
-
i0.ɵɵconditional(ctx.questionType === "checkbox" ? 17 : -1);
|
|
619
|
-
i0.ɵɵadvance();
|
|
620
|
-
i0.ɵɵconditional(ctx.control.invalid && ctx.control.touched ? 18 : -1);
|
|
621
|
-
} }, dependencies: [i1.NgClass, i2.NgSelectOption, i2.ɵNgSelectMultipleOption, i2.SelectControlValueAccessor, i2.NgControlStatus, i2.FormControlDirective, i3.ButtonComponent, i3.ButtonGroupComponent, i4.TextBoxDirective, i4.NumericTextBoxComponent, i4.TextAreaDirective, i4.CheckBoxDirective, i4.RadioButtonDirective, i4.SliderComponent, i5.DatePickerComponent, i5.DateTimePickerComponent, i5.TimePickerComponent], styles: [".form-question[_ngcontent-%COMP%] {\n margin-bottom: 16px;\n}\n\n.question-label[_ngcontent-%COMP%] {\n display: block;\n font-weight: 500;\n margin-bottom: 6px;\n color: #333;\n font-size: 14px;\n}\n\n.required-indicator[_ngcontent-%COMP%] {\n color: #d9534f;\n margin-left: 2px;\n}\n\n.help-text[_ngcontent-%COMP%] {\n font-size: 12px;\n color: #666;\n margin-bottom: 8px;\n font-style: italic;\n}\n\n\n\n.question-input[_ngcontent-%COMP%], \n.question-textarea[_ngcontent-%COMP%], \n.question-dropdown[_ngcontent-%COMP%] {\n width: 100%;\n max-width: 100%;\n}\n\n.question-dropdown[_ngcontent-%COMP%] {\n padding: 8px 12px;\n border: 1px solid #d1d5db;\n border-radius: 4px;\n font-size: 14px;\n font-family: inherit;\n background-color: white;\n background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 9L1 4h10z'/%3E%3C/svg%3E\");\n background-repeat: no-repeat;\n background-position: right 8px center;\n background-size: 12px;\n padding-right: 32px;\n cursor: pointer;\n transition: border-color 0.2s ease, box-shadow 0.2s ease;\n appearance: none;\n -webkit-appearance: none;\n -moz-appearance: none;\n}\n\n.question-dropdown[_ngcontent-%COMP%]:hover {\n border-color: #9ca3af;\n}\n\n.question-dropdown[_ngcontent-%COMP%]:focus {\n outline: none;\n border-color: #667eea;\n box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);\n}\n\n.question-dropdown[_ngcontent-%COMP%]:disabled {\n background-color: #f3f4f6;\n cursor: not-allowed;\n opacity: 0.6;\n}\n\n.question-textarea[_ngcontent-%COMP%] {\n resize: vertical;\n min-height: 100px;\n}\n\n.question-buttongroup[_ngcontent-%COMP%] {\n display: flex;\n flex-wrap: nowrap;\n gap: 8px;\n overflow-x: auto;\n overflow-y: hidden;\n -webkit-overflow-scrolling: touch;\n scrollbar-width: thin;\n scrollbar-color: rgba(16, 185, 129, 0.3) transparent;\n}\n\n.question-buttongroup[_ngcontent-%COMP%]::-webkit-scrollbar {\n height: 6px;\n}\n\n.question-buttongroup[_ngcontent-%COMP%]::-webkit-scrollbar-track {\n background: transparent;\n}\n\n.question-buttongroup[_ngcontent-%COMP%]::-webkit-scrollbar-thumb {\n background: rgba(16, 185, 129, 0.3);\n border-radius: 3px;\n}\n\n.question-buttongroup[_ngcontent-%COMP%]::-webkit-scrollbar-thumb:hover {\n background: rgba(16, 185, 129, 0.5);\n}\n\n.buttongroup-option[_ngcontent-%COMP%] {\n flex: 0 0 auto;\n white-space: nowrap;\n}\n\n.buttongroup-option[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n margin-right: 6px;\n}\n\n.question-radio-group[_ngcontent-%COMP%], \n.question-checkbox-group[_ngcontent-%COMP%] {\n display: flex;\n flex-wrap: wrap;\n gap: 12px 16px;\n}\n\n.radio-option[_ngcontent-%COMP%], \n.checkbox-option[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 8px;\n min-width: 120px;\n flex: 0 0 auto;\n}\n\n.radio-label[_ngcontent-%COMP%], \n.checkbox-label[_ngcontent-%COMP%] {\n cursor: pointer;\n user-select: none;\n margin: 0;\n display: flex;\n align-items: center;\n gap: 6px;\n}\n\n.radio-label[_ngcontent-%COMP%] i[_ngcontent-%COMP%], \n.checkbox-label[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n color: #666;\n}\n\n.validation-error[_ngcontent-%COMP%] {\n color: #d9534f;\n font-size: 12px;\n margin-top: 4px;\n}\n\n\n\n.form-question.required[_ngcontent-%COMP%] .question-label[_ngcontent-%COMP%] {\n font-weight: 600;\n}\n\n\n\n.question-slider-container[_ngcontent-%COMP%] {\n width: 100%;\n}\n\n.question-slider[_ngcontent-%COMP%] {\n width: 100%;\n margin-bottom: 8px;\n}\n\n.slider-value[_ngcontent-%COMP%] {\n text-align: center;\n font-size: 16px;\n font-weight: 600;\n color: #10b981;\n padding: 4px 0;\n}\n\n\n\n.question-daterange[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 12px;\n flex-wrap: wrap;\n}\n\n.daterange-start[_ngcontent-%COMP%], \n.daterange-end[_ngcontent-%COMP%] {\n flex: 1;\n min-width: 150px;\n}\n\n.daterange-separator[_ngcontent-%COMP%] {\n font-weight: 500;\n color: #666;\n white-space: nowrap;\n}\n\n\n\n@media (max-width: 480px) {\n .question-daterange[_ngcontent-%COMP%] {\n flex-direction: column;\n align-items: stretch;\n }\n\n .daterange-separator[_ngcontent-%COMP%] {\n text-align: center;\n padding: 4px 0;\n }\n}\n\n\n\n\n\n\n.input-container[_ngcontent-%COMP%] {\n display: block;\n}\n\n\n\n.input-container.width-narrow[_ngcontent-%COMP%] {\n max-width: 200px;\n}\n\n.input-container.width-narrow[_ngcontent-%COMP%] .question-input[_ngcontent-%COMP%], \n.input-container.width-narrow[_ngcontent-%COMP%] .question-dropdown[_ngcontent-%COMP%] {\n width: 100%;\n}\n\n\n\n.input-container.width-medium[_ngcontent-%COMP%] {\n max-width: 450px;\n}\n\n.input-container.width-medium[_ngcontent-%COMP%] .question-input[_ngcontent-%COMP%], \n.input-container.width-medium[_ngcontent-%COMP%] .question-dropdown[_ngcontent-%COMP%] {\n width: 100%;\n}\n\n\n\n.input-container.width-wide[_ngcontent-%COMP%] {\n max-width: 100%;\n}\n\n.input-container.width-wide[_ngcontent-%COMP%] .question-input[_ngcontent-%COMP%], \n.input-container.width-wide[_ngcontent-%COMP%] .question-dropdown[_ngcontent-%COMP%] {\n width: 100%;\n}\n\n\n\n.input-container.width-full[_ngcontent-%COMP%] {\n max-width: 100%;\n}\n\n.input-container.width-full[_ngcontent-%COMP%] .question-input[_ngcontent-%COMP%], \n.input-container.width-full[_ngcontent-%COMP%] .question-textarea[_ngcontent-%COMP%], \n.input-container.width-full[_ngcontent-%COMP%] .question-dropdown[_ngcontent-%COMP%] {\n width: 100%;\n}\n\n\n\n.input-container.width-auto[_ngcontent-%COMP%] {\n max-width: 350px;\n min-width: 150px;\n width: auto;\n}\n\n.input-container.width-auto[_ngcontent-%COMP%] .question-dropdown[_ngcontent-%COMP%] {\n width: 100%;\n}\n\n\n\n@media (max-width: 600px) {\n .input-container.width-narrow[_ngcontent-%COMP%], \n .input-container.width-medium[_ngcontent-%COMP%], \n .input-container.width-wide[_ngcontent-%COMP%], \n .input-container.width-auto[_ngcontent-%COMP%] {\n max-width: 100%;\n }\n}"] });
|
|
622
|
-
}
|
|
623
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(FormQuestionComponent, [{
|
|
624
|
-
type: Component,
|
|
625
|
-
args: [{ standalone: false, selector: 'mj-form-question', providers: [
|
|
626
|
-
{
|
|
627
|
-
provide: NG_VALUE_ACCESSOR,
|
|
628
|
-
useExisting: forwardRef(() => FormQuestionComponent),
|
|
629
|
-
multi: true
|
|
630
|
-
}
|
|
631
|
-
], template: "<div class=\"form-question\" [class.required]=\"question.required\">\n <!-- Label -->\n @if (question.label) {\n <label class=\"question-label\">\n {{ question.label }}\n @if (question.required) {\n <span class=\"required-indicator\">*</span>\n }\n </label>\n }\n\n <!-- Help Text -->\n @if (question.helpText) {\n <div class=\"help-text\">\n {{ question.helpText }}\n </div>\n }\n\n <!-- Input Container with width class -->\n <div class=\"input-container\" [ngClass]=\"widthClass\">\n\n <!-- Text Input -->\n @if (questionType === 'text') {\n <input\n type=\"text\"\n kendoTextBox\n [value]=\"value || ''\"\n [placeholder]=\"placeholder\"\n [disabled]=\"disabled\"\n (input)=\"onValueChange($any($event.target).value)\"\n class=\"question-input\"\n />\n }\n\n <!-- Email Input -->\n @if (questionType === 'email') {\n <input\n type=\"email\"\n kendoTextBox\n [value]=\"value || ''\"\n [placeholder]=\"placeholder\"\n [disabled]=\"disabled\"\n (input)=\"onValueChange($any($event.target).value)\"\n class=\"question-input\"\n />\n }\n\n <!-- Textarea -->\n @if (questionType === 'textarea') {\n <textarea\n kendoTextArea\n [value]=\"value || ''\"\n [placeholder]=\"placeholder\"\n [disabled]=\"disabled\"\n (input)=\"onValueChange($any($event.target).value)\"\n class=\"question-textarea\"\n rows=\"5\"\n ></textarea>\n }\n\n <!-- Number Input -->\n @if (questionType === 'number') {\n <kendo-numerictextbox\n [value]=\"value\"\n [min]=\"min || 0\"\n [max]=\"max || 999999999\"\n [step]=\"step || 1\"\n [disabled]=\"disabled\"\n (valueChange)=\"onValueChange($event)\"\n class=\"question-input\"\n ></kendo-numerictextbox>\n }\n\n <!-- Currency Input -->\n @if (questionType === 'currency') {\n <kendo-numerictextbox\n [value]=\"value\"\n [min]=\"min || 0\"\n [max]=\"max || 999999999\"\n [step]=\"step || 0.01\"\n [format]=\"'c2'\"\n [disabled]=\"disabled\"\n (valueChange)=\"onValueChange($event)\"\n class=\"question-input\"\n ></kendo-numerictextbox>\n }\n\n <!-- Date Picker -->\n @if (questionType === 'date') {\n <kendo-datepicker\n [value]=\"value\"\n [disabled]=\"disabled\"\n (valueChange)=\"onValueChange($event)\"\n class=\"question-input\"\n ></kendo-datepicker>\n }\n\n <!-- DateTime Picker -->\n @if (questionType === 'datetime') {\n <kendo-datetimepicker\n [value]=\"value\"\n [disabled]=\"disabled\"\n (valueChange)=\"onValueChange($event)\"\n class=\"question-input\"\n ></kendo-datetimepicker>\n }\n\n <!-- Button Group -->\n @if (questionType === 'buttongroup') {\n <kendo-buttongroup\n [selection]=\"'single'\"\n class=\"question-buttongroup\"\n >\n @for (option of options; track trackByValue($index, option)) {\n <button\n kendoButton\n [toggleable]=\"true\"\n [selected]=\"value === option.value\"\n [disabled]=\"disabled\"\n (click)=\"onValueChange(option.value)\"\n class=\"buttongroup-option\"\n >\n @if (option.icon) {\n <i class=\"fa {{ option.icon }}\" aria-hidden=\"true\"></i>\n }\n {{ option.label }}\n </button>\n }\n </kendo-buttongroup>\n }\n\n <!-- Radio Buttons -->\n @if (questionType === 'radio') {\n <div class=\"question-radio-group\">\n @for (option of options; track trackByValue($index, option)) {\n <div class=\"radio-option\">\n <input\n type=\"radio\"\n kendoRadioButton\n [name]=\"question.id\"\n [value]=\"option.value\"\n [checked]=\"value === option.value\"\n [disabled]=\"disabled\"\n (change)=\"onValueChange(option.value)\"\n [id]=\"question.id + '_' + option.value\"\n />\n <label [for]=\"question.id + '_' + option.value\" class=\"radio-label\">\n @if (option.icon) {\n <i class=\"fa {{ option.icon }}\" aria-hidden=\"true\"></i>\n }\n {{ option.label }}\n </label>\n </div>\n }\n </div>\n }\n\n <!-- Dropdown -->\n @if (questionType === 'dropdown') {\n <select\n [formControl]=\"control\"\n [disabled]=\"disabled\"\n class=\"question-dropdown\"\n >\n <option value=\"\">Select an option...</option>\n @for (option of options; track trackByValue($index, option)) {\n <option [value]=\"option.value\">\n {{ option.label }}\n </option>\n }\n </select>\n }\n\n <!-- Slider -->\n @if (questionType === 'slider') {\n <div class=\"question-slider-container\">\n <kendo-slider\n [min]=\"getSliderConfig().min\"\n [max]=\"getSliderConfig().max\"\n [smallStep]=\"getSliderConfig().step || 1\"\n [value]=\"value || getSliderConfig().min\"\n [disabled]=\"disabled\"\n (valueChange)=\"onValueChange($event)\"\n class=\"question-slider\"\n ></kendo-slider>\n <div class=\"slider-value\">\n {{ value || getSliderConfig().min }}{{ getSliderConfig().suffix || '' }}\n </div>\n </div>\n }\n\n <!-- Date Range -->\n @if (questionType === 'daterange') {\n <div class=\"question-daterange\">\n <kendo-datepicker\n [value]=\"value?.start\"\n [disabled]=\"disabled\"\n (valueChange)=\"onDateRangeStartChange($event)\"\n placeholder=\"Start Date\"\n class=\"daterange-start\"\n ></kendo-datepicker>\n <span class=\"daterange-separator\">to</span>\n <kendo-datepicker\n [value]=\"value?.end\"\n [disabled]=\"disabled\"\n (valueChange)=\"onDateRangeEndChange($event)\"\n placeholder=\"End Date\"\n class=\"daterange-end\"\n ></kendo-datepicker>\n </div>\n }\n\n <!-- Time Picker -->\n @if (questionType === 'time') {\n <kendo-timepicker\n [value]=\"value\"\n [disabled]=\"disabled\"\n (valueChange)=\"onValueChange($event)\"\n [format]=\"'h:mm a'\"\n class=\"question-input\"\n ></kendo-timepicker>\n }\n\n <!-- Checkboxes -->\n @if (questionType === 'checkbox') {\n <div class=\"question-checkbox-group\">\n @for (option of options; track trackByValue($index, option)) {\n <div class=\"checkbox-option\">\n <input\n type=\"checkbox\"\n kendoCheckBox\n [checked]=\"isChecked(option)\"\n [disabled]=\"disabled\"\n (change)=\"toggleCheckbox(option)\"\n [id]=\"question.id + '_' + option.value\"\n />\n <label [for]=\"question.id + '_' + option.value\" class=\"checkbox-label\">\n @if (option.icon) {\n <i class=\"fa {{ option.icon }}\" aria-hidden=\"true\"></i>\n }\n {{ option.label }}\n </label>\n </div>\n }\n </div>\n }\n </div><!-- end input-container -->\n\n <!-- Validation Error -->\n @if (control.invalid && control.touched) {\n <div class=\"validation-error\">\n @if (control.errors?.['required']) {\n <span>This field is required</span>\n }\n @if (control.errors?.['email']) {\n <span>Please enter a valid email address</span>\n }\n @if (control.errors?.['min']) {\n <span>Value must be at least {{ min }}</span>\n }\n @if (control.errors?.['max']) {\n <span>Value must be at most {{ max }}</span>\n }\n </div>\n }\n</div>\n", styles: [".form-question {\n margin-bottom: 16px;\n}\n\n.question-label {\n display: block;\n font-weight: 500;\n margin-bottom: 6px;\n color: #333;\n font-size: 14px;\n}\n\n.required-indicator {\n color: #d9534f;\n margin-left: 2px;\n}\n\n.help-text {\n font-size: 12px;\n color: #666;\n margin-bottom: 8px;\n font-style: italic;\n}\n\n/* Default widths - controlled by input-container width classes */\n.question-input,\n.question-textarea,\n.question-dropdown {\n width: 100%;\n max-width: 100%;\n}\n\n.question-dropdown {\n padding: 8px 12px;\n border: 1px solid #d1d5db;\n border-radius: 4px;\n font-size: 14px;\n font-family: inherit;\n background-color: white;\n background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 9L1 4h10z'/%3E%3C/svg%3E\");\n background-repeat: no-repeat;\n background-position: right 8px center;\n background-size: 12px;\n padding-right: 32px;\n cursor: pointer;\n transition: border-color 0.2s ease, box-shadow 0.2s ease;\n appearance: none;\n -webkit-appearance: none;\n -moz-appearance: none;\n}\n\n.question-dropdown:hover {\n border-color: #9ca3af;\n}\n\n.question-dropdown:focus {\n outline: none;\n border-color: #667eea;\n box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);\n}\n\n.question-dropdown:disabled {\n background-color: #f3f4f6;\n cursor: not-allowed;\n opacity: 0.6;\n}\n\n.question-textarea {\n resize: vertical;\n min-height: 100px;\n}\n\n.question-buttongroup {\n display: flex;\n flex-wrap: nowrap;\n gap: 8px;\n overflow-x: auto;\n overflow-y: hidden;\n -webkit-overflow-scrolling: touch;\n scrollbar-width: thin;\n scrollbar-color: rgba(16, 185, 129, 0.3) transparent;\n}\n\n.question-buttongroup::-webkit-scrollbar {\n height: 6px;\n}\n\n.question-buttongroup::-webkit-scrollbar-track {\n background: transparent;\n}\n\n.question-buttongroup::-webkit-scrollbar-thumb {\n background: rgba(16, 185, 129, 0.3);\n border-radius: 3px;\n}\n\n.question-buttongroup::-webkit-scrollbar-thumb:hover {\n background: rgba(16, 185, 129, 0.5);\n}\n\n.buttongroup-option {\n flex: 0 0 auto;\n white-space: nowrap;\n}\n\n.buttongroup-option i {\n margin-right: 6px;\n}\n\n.question-radio-group,\n.question-checkbox-group {\n display: flex;\n flex-wrap: wrap;\n gap: 12px 16px;\n}\n\n.radio-option,\n.checkbox-option {\n display: flex;\n align-items: center;\n gap: 8px;\n min-width: 120px;\n flex: 0 0 auto;\n}\n\n.radio-label,\n.checkbox-label {\n cursor: pointer;\n user-select: none;\n margin: 0;\n display: flex;\n align-items: center;\n gap: 6px;\n}\n\n.radio-label i,\n.checkbox-label i {\n color: #666;\n}\n\n.validation-error {\n color: #d9534f;\n font-size: 12px;\n margin-top: 4px;\n}\n\n/* Required field styling */\n.form-question.required .question-label {\n font-weight: 600;\n}\n\n/* Slider styling */\n.question-slider-container {\n width: 100%;\n}\n\n.question-slider {\n width: 100%;\n margin-bottom: 8px;\n}\n\n.slider-value {\n text-align: center;\n font-size: 16px;\n font-weight: 600;\n color: #10b981;\n padding: 4px 0;\n}\n\n/* Date range styling */\n.question-daterange {\n display: flex;\n align-items: center;\n gap: 12px;\n flex-wrap: wrap;\n}\n\n.daterange-start,\n.daterange-end {\n flex: 1;\n min-width: 150px;\n}\n\n.daterange-separator {\n font-weight: 500;\n color: #666;\n white-space: nowrap;\n}\n\n/* Mobile adjustments for date range */\n@media (max-width: 480px) {\n .question-daterange {\n flex-direction: column;\n align-items: stretch;\n }\n\n .daterange-separator {\n text-align: center;\n padding: 4px 0;\n }\n}\n\n/* ===== Semantic Width Classes ===== */\n/* Controls field width based on expected content length */\n\n.input-container {\n display: block;\n}\n\n/* Narrow fields - for numbers, dates, times, short codes */\n.input-container.width-narrow {\n max-width: 200px;\n}\n\n.input-container.width-narrow .question-input,\n.input-container.width-narrow .question-dropdown {\n width: 100%;\n}\n\n/* Medium fields - for names, cities, phone numbers (DEFAULT) */\n.input-container.width-medium {\n max-width: 450px;\n}\n\n.input-container.width-medium .question-input,\n.input-container.width-medium .question-dropdown {\n width: 100%;\n}\n\n/* Wide fields - for emails, URLs, long text */\n.input-container.width-wide {\n max-width: 100%;\n}\n\n.input-container.width-wide .question-input,\n.input-container.width-wide .question-dropdown {\n width: 100%;\n}\n\n/* Full width - for textarea, search fields */\n.input-container.width-full {\n max-width: 100%;\n}\n\n.input-container.width-full .question-input,\n.input-container.width-full .question-textarea,\n.input-container.width-full .question-dropdown {\n width: 100%;\n}\n\n/* Auto-width - for dropdowns, radio, checkbox (sizes to content) */\n.input-container.width-auto {\n max-width: 350px;\n min-width: 150px;\n width: auto;\n}\n\n.input-container.width-auto .question-dropdown {\n width: 100%;\n}\n\n/* Responsive adjustments for smaller screens */\n@media (max-width: 600px) {\n .input-container.width-narrow,\n .input-container.width-medium,\n .input-container.width-wide,\n .input-container.width-auto {\n max-width: 100%;\n }\n}\n"] }]
|
|
632
|
-
}], null, { question: [{
|
|
633
|
-
type: Input
|
|
634
|
-
}], control: [{
|
|
635
|
-
type: Input
|
|
636
|
-
}] }); })();
|
|
637
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(FormQuestionComponent, { className: "FormQuestionComponent", filePath: "src/lib/components/message/form-question.component.ts", lineNumber: 22 }); })();
|
|
638
|
-
//# sourceMappingURL=form-question.component.js.map
|