@memberjunction/ng-core-entity-forms 2.43.0 → 2.45.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.
Files changed (436) hide show
  1. package/README.md +65 -0
  2. package/dist/lib/custom/AIPrompts/ai-prompt-execution-dialog.component.d.ts +94 -0
  3. package/dist/lib/custom/AIPrompts/ai-prompt-execution-dialog.component.d.ts.map +1 -0
  4. package/dist/lib/custom/AIPrompts/ai-prompt-execution-dialog.component.js +814 -0
  5. package/dist/lib/custom/AIPrompts/ai-prompt-execution-dialog.component.js.map +1 -0
  6. package/dist/lib/custom/AIPrompts/ai-prompt-form.component.d.ts +199 -0
  7. package/dist/lib/custom/AIPrompts/ai-prompt-form.component.d.ts.map +1 -0
  8. package/dist/lib/custom/AIPrompts/ai-prompt-form.component.js +1874 -0
  9. package/dist/lib/custom/AIPrompts/ai-prompt-form.component.js.map +1 -0
  10. package/dist/lib/custom/Actions/actions-top-area-extended.js +2 -2
  11. package/dist/lib/custom/Entities/entities-form.component.js +2 -2
  12. package/dist/lib/custom/EntityActions/entityaction.form.component.js +2 -2
  13. package/dist/lib/custom/Templates/template-param-dialog.component.d.ts +48 -0
  14. package/dist/lib/custom/Templates/template-param-dialog.component.d.ts.map +1 -0
  15. package/dist/lib/custom/Templates/template-param-dialog.component.js +689 -0
  16. package/dist/lib/custom/Templates/template-param-dialog.component.js.map +1 -0
  17. package/dist/lib/custom/Templates/templates-form.component.d.ts +88 -0
  18. package/dist/lib/custom/Templates/templates-form.component.d.ts.map +1 -0
  19. package/dist/lib/custom/Templates/templates-form.component.js +767 -0
  20. package/dist/lib/custom/Templates/templates-form.component.js.map +1 -0
  21. package/dist/lib/custom/custom-forms.module.d.ts +22 -14
  22. package/dist/lib/custom/custom-forms.module.d.ts.map +1 -1
  23. package/dist/lib/custom/custom-forms.module.js +63 -10
  24. package/dist/lib/custom/custom-forms.module.js.map +1 -1
  25. package/dist/lib/generated/Entities/AIAction/aiaction.form.component.js +2 -2
  26. package/dist/lib/generated/Entities/AIAction/sections/details.component.js +2 -2
  27. package/dist/lib/generated/Entities/AIAgent/aiagent.form.component.js +18 -8
  28. package/dist/lib/generated/Entities/AIAgent/aiagent.form.component.js.map +1 -1
  29. package/dist/lib/generated/Entities/AIAgent/sections/details.component.d.ts.map +1 -1
  30. package/dist/lib/generated/Entities/AIAgent/sections/details.component.js +17 -6
  31. package/dist/lib/generated/Entities/AIAgent/sections/details.component.js.map +1 -1
  32. package/dist/lib/generated/Entities/AIAgentAction/aiagentaction.form.component.js +2 -2
  33. package/dist/lib/generated/Entities/AIAgentAction/sections/details.component.js +2 -2
  34. package/dist/lib/generated/Entities/AIAgentLearningCycle/aiagentlearningcycle.form.component.js +2 -2
  35. package/dist/lib/generated/Entities/AIAgentLearningCycle/sections/details.component.js +2 -2
  36. package/dist/lib/generated/Entities/AIAgentModel/aiagentmodel.form.component.js +2 -2
  37. package/dist/lib/generated/Entities/AIAgentModel/sections/details.component.js +2 -2
  38. package/dist/lib/generated/Entities/AIAgentNote/aiagentnote.form.component.js +2 -2
  39. package/dist/lib/generated/Entities/AIAgentNote/sections/details.component.js +2 -2
  40. package/dist/lib/generated/Entities/AIAgentNoteType/aiagentnotetype.form.component.js +2 -2
  41. package/dist/lib/generated/Entities/AIAgentNoteType/sections/details.component.js +2 -2
  42. package/dist/lib/generated/Entities/AIAgentPrompt/aiagentprompt.form.component.js +2 -2
  43. package/dist/lib/generated/Entities/AIAgentPrompt/sections/details.component.js +2 -2
  44. package/dist/lib/generated/Entities/AIAgentRequest/aiagentrequest.form.component.js +2 -2
  45. package/dist/lib/generated/Entities/AIAgentRequest/sections/details.component.js +2 -2
  46. package/dist/lib/generated/Entities/AIAgentRun/aiagentrun.form.component.d.ts +10 -0
  47. package/dist/lib/generated/Entities/AIAgentRun/aiagentrun.form.component.d.ts.map +1 -0
  48. package/dist/lib/generated/Entities/AIAgentRun/aiagentrun.form.component.js +92 -0
  49. package/dist/lib/generated/Entities/AIAgentRun/aiagentrun.form.component.js.map +1 -0
  50. package/dist/lib/generated/Entities/AIAgentRun/sections/details.component.d.ts +11 -0
  51. package/dist/lib/generated/Entities/AIAgentRun/sections/details.component.d.ts.map +1 -0
  52. package/dist/lib/generated/Entities/AIAgentRun/sections/details.component.js +196 -0
  53. package/dist/lib/generated/Entities/AIAgentRun/sections/details.component.js.map +1 -0
  54. package/dist/lib/generated/Entities/AIAgentRunStep/aiagentrunstep.form.component.d.ts +10 -0
  55. package/dist/lib/generated/Entities/AIAgentRunStep/aiagentrunstep.form.component.d.ts.map +1 -0
  56. package/dist/lib/generated/Entities/AIAgentRunStep/aiagentrunstep.form.component.js +61 -0
  57. package/dist/lib/generated/Entities/AIAgentRunStep/aiagentrunstep.form.component.js.map +1 -0
  58. package/dist/lib/generated/Entities/AIAgentRunStep/sections/details.component.d.ts +11 -0
  59. package/dist/lib/generated/Entities/AIAgentRunStep/sections/details.component.d.ts.map +1 -0
  60. package/dist/lib/generated/Entities/AIAgentRunStep/sections/details.component.js +181 -0
  61. package/dist/lib/generated/Entities/AIAgentRunStep/sections/details.component.js.map +1 -0
  62. package/dist/lib/generated/Entities/AIAgentType/aiagenttype.form.component.d.ts +10 -0
  63. package/dist/lib/generated/Entities/AIAgentType/aiagenttype.form.component.d.ts.map +1 -0
  64. package/dist/lib/generated/Entities/AIAgentType/aiagenttype.form.component.js +72 -0
  65. package/dist/lib/generated/Entities/AIAgentType/aiagenttype.form.component.js.map +1 -0
  66. package/dist/lib/generated/Entities/AIAgentType/sections/details.component.d.ts +11 -0
  67. package/dist/lib/generated/Entities/AIAgentType/sections/details.component.d.ts.map +1 -0
  68. package/dist/lib/generated/Entities/AIAgentType/sections/details.component.js +109 -0
  69. package/dist/lib/generated/Entities/AIAgentType/sections/details.component.js.map +1 -0
  70. package/dist/lib/generated/Entities/AIConfiguration/aiconfiguration.form.component.js +2 -2
  71. package/dist/lib/generated/Entities/AIConfiguration/sections/details.component.js +2 -2
  72. package/dist/lib/generated/Entities/AIConfigurationParam/aiconfigurationparam.form.component.js +2 -2
  73. package/dist/lib/generated/Entities/AIConfigurationParam/sections/details.component.js +2 -2
  74. package/dist/lib/generated/Entities/AIModel/aimodel.form.component.js +2 -2
  75. package/dist/lib/generated/Entities/AIModel/sections/details.component.js +2 -2
  76. package/dist/lib/generated/Entities/AIModelAction/aimodelaction.form.component.js +2 -2
  77. package/dist/lib/generated/Entities/AIModelAction/sections/details.component.js +2 -2
  78. package/dist/lib/generated/Entities/AIModelType/aimodeltype.form.component.js +2 -2
  79. package/dist/lib/generated/Entities/AIModelType/sections/details.component.js +2 -2
  80. package/dist/lib/generated/Entities/AIModelVendor/aimodelvendor.form.component.js +2 -2
  81. package/dist/lib/generated/Entities/AIModelVendor/sections/details.component.d.ts.map +1 -1
  82. package/dist/lib/generated/Entities/AIModelVendor/sections/details.component.js +26 -6
  83. package/dist/lib/generated/Entities/AIModelVendor/sections/details.component.js.map +1 -1
  84. package/dist/lib/generated/Entities/AIPrompt/aiprompt.form.component.js +21 -11
  85. package/dist/lib/generated/Entities/AIPrompt/aiprompt.form.component.js.map +1 -1
  86. package/dist/lib/generated/Entities/AIPrompt/sections/details.component.d.ts.map +1 -1
  87. package/dist/lib/generated/Entities/AIPrompt/sections/details.component.js +24 -6
  88. package/dist/lib/generated/Entities/AIPrompt/sections/details.component.js.map +1 -1
  89. package/dist/lib/generated/Entities/AIPromptCategory/aipromptcategory.form.component.js +2 -2
  90. package/dist/lib/generated/Entities/AIPromptCategory/sections/details.component.js +2 -2
  91. package/dist/lib/generated/Entities/AIPromptModel/aipromptmodel.form.component.js +2 -2
  92. package/dist/lib/generated/Entities/AIPromptModel/sections/details.component.js +2 -2
  93. package/dist/lib/generated/Entities/AIPromptRun/aipromptrun.form.component.js +15 -5
  94. package/dist/lib/generated/Entities/AIPromptRun/aipromptrun.form.component.js.map +1 -1
  95. package/dist/lib/generated/Entities/AIPromptRun/sections/details.component.d.ts.map +1 -1
  96. package/dist/lib/generated/Entities/AIPromptRun/sections/details.component.js +46 -6
  97. package/dist/lib/generated/Entities/AIPromptRun/sections/details.component.js.map +1 -1
  98. package/dist/lib/generated/Entities/AIPromptType/aiprompttype.form.component.js +2 -2
  99. package/dist/lib/generated/Entities/AIPromptType/sections/details.component.js +2 -2
  100. package/dist/lib/generated/Entities/AIResultCache/airesultcache.form.component.js +2 -2
  101. package/dist/lib/generated/Entities/AIResultCache/sections/details.component.js +2 -2
  102. package/dist/lib/generated/Entities/AIVendor/aivendor.form.component.js +2 -2
  103. package/dist/lib/generated/Entities/AIVendor/sections/details.component.js +2 -2
  104. package/dist/lib/generated/Entities/AIVendorType/aivendortype.form.component.js +2 -2
  105. package/dist/lib/generated/Entities/AIVendorType/sections/details.component.js +2 -2
  106. package/dist/lib/generated/Entities/AIVendorTypeDefinition/aivendortypedefinition.form.component.js +15 -5
  107. package/dist/lib/generated/Entities/AIVendorTypeDefinition/aivendortypedefinition.form.component.js.map +1 -1
  108. package/dist/lib/generated/Entities/AIVendorTypeDefinition/sections/details.component.js +2 -2
  109. package/dist/lib/generated/Entities/Action/action.form.component.js +2 -2
  110. package/dist/lib/generated/Entities/Action/sections/code.component.js +2 -2
  111. package/dist/lib/generated/Entities/Action/sections/details.component.js +2 -2
  112. package/dist/lib/generated/Entities/Action/sections/top.component.js +2 -2
  113. package/dist/lib/generated/Entities/ActionAuthorization/actionauthorization.form.component.js +2 -2
  114. package/dist/lib/generated/Entities/ActionAuthorization/sections/details.component.js +2 -2
  115. package/dist/lib/generated/Entities/ActionCategory/actioncategory.form.component.js +2 -2
  116. package/dist/lib/generated/Entities/ActionCategory/sections/details.component.js +2 -2
  117. package/dist/lib/generated/Entities/ActionContext/actioncontext.form.component.js +2 -2
  118. package/dist/lib/generated/Entities/ActionContext/sections/details.component.js +2 -2
  119. package/dist/lib/generated/Entities/ActionContextType/actioncontexttype.form.component.js +2 -2
  120. package/dist/lib/generated/Entities/ActionContextType/sections/details.component.js +2 -2
  121. package/dist/lib/generated/Entities/ActionExecutionLog/actionexecutionlog.form.component.js +2 -2
  122. package/dist/lib/generated/Entities/ActionExecutionLog/sections/details.component.js +2 -2
  123. package/dist/lib/generated/Entities/ActionFilter/actionfilter.form.component.js +2 -2
  124. package/dist/lib/generated/Entities/ActionFilter/sections/details.component.js +2 -2
  125. package/dist/lib/generated/Entities/ActionLibrary/actionlibrary.form.component.js +2 -2
  126. package/dist/lib/generated/Entities/ActionLibrary/sections/details.component.js +2 -2
  127. package/dist/lib/generated/Entities/ActionParam/actionparam.form.component.js +2 -2
  128. package/dist/lib/generated/Entities/ActionParam/sections/details.component.js +2 -2
  129. package/dist/lib/generated/Entities/ActionResultCode/actionresultcode.form.component.js +2 -2
  130. package/dist/lib/generated/Entities/ActionResultCode/sections/details.component.js +2 -2
  131. package/dist/lib/generated/Entities/Application/application.form.component.js +2 -2
  132. package/dist/lib/generated/Entities/Application/sections/details.component.js +2 -2
  133. package/dist/lib/generated/Entities/ApplicationEntity/applicationentity.form.component.js +2 -2
  134. package/dist/lib/generated/Entities/ApplicationEntity/sections/details.component.js +2 -2
  135. package/dist/lib/generated/Entities/ApplicationSetting/applicationsetting.form.component.js +2 -2
  136. package/dist/lib/generated/Entities/ApplicationSetting/sections/details.component.js +2 -2
  137. package/dist/lib/generated/Entities/ArtifactType/artifacttype.form.component.js +2 -2
  138. package/dist/lib/generated/Entities/ArtifactType/sections/details.component.js +2 -2
  139. package/dist/lib/generated/Entities/AuditLog/auditlog.form.component.js +2 -2
  140. package/dist/lib/generated/Entities/AuditLog/sections/details.component.js +2 -2
  141. package/dist/lib/generated/Entities/AuditLogType/auditlogtype.form.component.js +2 -2
  142. package/dist/lib/generated/Entities/AuditLogType/sections/details.component.js +2 -2
  143. package/dist/lib/generated/Entities/Authorization/authorization.form.component.js +2 -2
  144. package/dist/lib/generated/Entities/Authorization/sections/details.component.js +2 -2
  145. package/dist/lib/generated/Entities/AuthorizationRole/authorizationrole.form.component.js +2 -2
  146. package/dist/lib/generated/Entities/AuthorizationRole/sections/details.component.js +2 -2
  147. package/dist/lib/generated/Entities/CommunicationBaseMessageType/communicationbasemessagetype.form.component.js +2 -2
  148. package/dist/lib/generated/Entities/CommunicationBaseMessageType/sections/details.component.js +2 -2
  149. package/dist/lib/generated/Entities/CommunicationLog/communicationlog.form.component.js +2 -2
  150. package/dist/lib/generated/Entities/CommunicationLog/sections/details.component.js +2 -2
  151. package/dist/lib/generated/Entities/CommunicationProvider/communicationprovider.form.component.js +2 -2
  152. package/dist/lib/generated/Entities/CommunicationProvider/sections/details.component.js +2 -2
  153. package/dist/lib/generated/Entities/CommunicationProviderMessageType/communicationprovidermessagetype.form.component.js +2 -2
  154. package/dist/lib/generated/Entities/CommunicationProviderMessageType/sections/details.component.js +2 -2
  155. package/dist/lib/generated/Entities/CommunicationRun/communicationrun.form.component.js +2 -2
  156. package/dist/lib/generated/Entities/CommunicationRun/sections/details.component.js +2 -2
  157. package/dist/lib/generated/Entities/Company/company.form.component.js +2 -2
  158. package/dist/lib/generated/Entities/Company/sections/details.component.js +2 -2
  159. package/dist/lib/generated/Entities/CompanyIntegration/companyintegration.form.component.js +2 -2
  160. package/dist/lib/generated/Entities/CompanyIntegration/sections/details.component.js +2 -2
  161. package/dist/lib/generated/Entities/CompanyIntegrationRecordMap/companyintegrationrecordmap.form.component.js +2 -2
  162. package/dist/lib/generated/Entities/CompanyIntegrationRecordMap/sections/details.component.js +2 -2
  163. package/dist/lib/generated/Entities/CompanyIntegrationRun/companyintegrationrun.form.component.js +2 -2
  164. package/dist/lib/generated/Entities/CompanyIntegrationRun/sections/details.component.js +2 -2
  165. package/dist/lib/generated/Entities/CompanyIntegrationRunAPILog/companyintegrationrunapilog.form.component.js +2 -2
  166. package/dist/lib/generated/Entities/CompanyIntegrationRunAPILog/sections/details.component.js +2 -2
  167. package/dist/lib/generated/Entities/CompanyIntegrationRunDetail/companyintegrationrundetail.form.component.js +2 -2
  168. package/dist/lib/generated/Entities/CompanyIntegrationRunDetail/sections/details.component.js +2 -2
  169. package/dist/lib/generated/Entities/ContentFileType/contentfiletype.form.component.js +2 -2
  170. package/dist/lib/generated/Entities/ContentFileType/sections/details.component.js +2 -2
  171. package/dist/lib/generated/Entities/ContentItem/contentitem.form.component.js +2 -2
  172. package/dist/lib/generated/Entities/ContentItem/sections/details.component.js +2 -2
  173. package/dist/lib/generated/Entities/ContentItemAttribute/contentitemattribute.form.component.js +2 -2
  174. package/dist/lib/generated/Entities/ContentItemAttribute/sections/details.component.js +2 -2
  175. package/dist/lib/generated/Entities/ContentItemTag/contentitemtag.form.component.js +2 -2
  176. package/dist/lib/generated/Entities/ContentItemTag/sections/details.component.js +2 -2
  177. package/dist/lib/generated/Entities/ContentProcessRun/contentprocessrun.form.component.js +2 -2
  178. package/dist/lib/generated/Entities/ContentProcessRun/sections/details.component.js +2 -2
  179. package/dist/lib/generated/Entities/ContentSource/contentsource.form.component.js +2 -2
  180. package/dist/lib/generated/Entities/ContentSource/sections/details.component.js +2 -2
  181. package/dist/lib/generated/Entities/ContentSourceParam/contentsourceparam.form.component.js +2 -2
  182. package/dist/lib/generated/Entities/ContentSourceParam/sections/details.component.js +2 -2
  183. package/dist/lib/generated/Entities/ContentSourceType/contentsourcetype.form.component.js +2 -2
  184. package/dist/lib/generated/Entities/ContentSourceType/sections/details.component.js +2 -2
  185. package/dist/lib/generated/Entities/ContentSourceTypeParam/contentsourcetypeparam.form.component.js +2 -2
  186. package/dist/lib/generated/Entities/ContentSourceTypeParam/sections/details.component.js +2 -2
  187. package/dist/lib/generated/Entities/ContentType/contenttype.form.component.js +2 -2
  188. package/dist/lib/generated/Entities/ContentType/sections/details.component.js +2 -2
  189. package/dist/lib/generated/Entities/ContentTypeAttribute/contenttypeattribute.form.component.js +2 -2
  190. package/dist/lib/generated/Entities/ContentTypeAttribute/sections/details.component.js +2 -2
  191. package/dist/lib/generated/Entities/Conversation/conversation.form.component.js +14 -4
  192. package/dist/lib/generated/Entities/Conversation/conversation.form.component.js.map +1 -1
  193. package/dist/lib/generated/Entities/Conversation/sections/details.component.js +2 -2
  194. package/dist/lib/generated/Entities/ConversationArtifact/conversationartifact.form.component.js +2 -2
  195. package/dist/lib/generated/Entities/ConversationArtifact/sections/details.component.js +2 -2
  196. package/dist/lib/generated/Entities/ConversationArtifactPermission/conversationartifactpermission.form.component.js +2 -2
  197. package/dist/lib/generated/Entities/ConversationArtifactPermission/sections/details.component.js +2 -2
  198. package/dist/lib/generated/Entities/ConversationArtifactVersion/conversationartifactversion.form.component.js +2 -2
  199. package/dist/lib/generated/Entities/ConversationArtifactVersion/sections/details.component.js +2 -2
  200. package/dist/lib/generated/Entities/ConversationDetail/conversationdetail.form.component.js +2 -2
  201. package/dist/lib/generated/Entities/ConversationDetail/sections/details.component.js +2 -2
  202. package/dist/lib/generated/Entities/Dashboard/dashboard.form.component.js +2 -2
  203. package/dist/lib/generated/Entities/Dashboard/sections/details.component.js +5 -5
  204. package/dist/lib/generated/Entities/DashboardCategory/dashboardcategory.form.component.js +2 -2
  205. package/dist/lib/generated/Entities/DashboardCategory/sections/details.component.js +2 -2
  206. package/dist/lib/generated/Entities/DashboardUserPreference/dashboarduserpreference.form.component.js +2 -2
  207. package/dist/lib/generated/Entities/DashboardUserPreference/sections/details.component.js +2 -2
  208. package/dist/lib/generated/Entities/DashboardUserState/dashboarduserstate.form.component.js +2 -2
  209. package/dist/lib/generated/Entities/DashboardUserState/sections/details.component.js +2 -2
  210. package/dist/lib/generated/Entities/DataContext/datacontext.form.component.js +2 -2
  211. package/dist/lib/generated/Entities/DataContext/sections/details.component.js +2 -2
  212. package/dist/lib/generated/Entities/DataContextItem/datacontextitem.form.component.js +2 -2
  213. package/dist/lib/generated/Entities/DataContextItem/sections/details.component.d.ts.map +1 -1
  214. package/dist/lib/generated/Entities/DataContextItem/sections/details.component.js +15 -6
  215. package/dist/lib/generated/Entities/DataContextItem/sections/details.component.js.map +1 -1
  216. package/dist/lib/generated/Entities/Dataset/dataset.form.component.js +2 -2
  217. package/dist/lib/generated/Entities/Dataset/sections/details.component.js +2 -2
  218. package/dist/lib/generated/Entities/DatasetItem/datasetitem.form.component.js +2 -2
  219. package/dist/lib/generated/Entities/DatasetItem/sections/details.component.js +2 -2
  220. package/dist/lib/generated/Entities/DuplicateRun/duplicaterun.form.component.js +2 -2
  221. package/dist/lib/generated/Entities/DuplicateRun/sections/details.component.js +2 -2
  222. package/dist/lib/generated/Entities/DuplicateRunDetail/duplicaterundetail.form.component.js +2 -2
  223. package/dist/lib/generated/Entities/DuplicateRunDetail/sections/details.component.js +2 -2
  224. package/dist/lib/generated/Entities/DuplicateRunDetailMatch/duplicaterundetailmatch.form.component.js +2 -2
  225. package/dist/lib/generated/Entities/DuplicateRunDetailMatch/sections/details.component.js +2 -2
  226. package/dist/lib/generated/Entities/Employee/employee.form.component.js +2 -2
  227. package/dist/lib/generated/Entities/Employee/sections/details.component.js +2 -2
  228. package/dist/lib/generated/Entities/EmployeeCompanyIntegration/employeecompanyintegration.form.component.js +2 -2
  229. package/dist/lib/generated/Entities/EmployeeCompanyIntegration/sections/details.component.js +2 -2
  230. package/dist/lib/generated/Entities/EmployeeRole/employeerole.form.component.js +2 -2
  231. package/dist/lib/generated/Entities/EmployeeRole/sections/details.component.js +2 -2
  232. package/dist/lib/generated/Entities/EmployeeSkill/employeeskill.form.component.js +2 -2
  233. package/dist/lib/generated/Entities/EmployeeSkill/sections/details.component.js +2 -2
  234. package/dist/lib/generated/Entities/Entity/entity.form.component.js +2 -2
  235. package/dist/lib/generated/Entities/Entity/sections/api.component.js +2 -2
  236. package/dist/lib/generated/Entities/Entity/sections/audit.component.js +2 -2
  237. package/dist/lib/generated/Entities/Entity/sections/db.component.js +2 -2
  238. package/dist/lib/generated/Entities/Entity/sections/details.component.js +2 -2
  239. package/dist/lib/generated/Entities/Entity/sections/top.component.js +2 -2
  240. package/dist/lib/generated/Entities/Entity/sections/ui.component.js +2 -2
  241. package/dist/lib/generated/Entities/EntityAIAction/entityaiaction.form.component.js +2 -2
  242. package/dist/lib/generated/Entities/EntityAIAction/sections/details.component.js +2 -2
  243. package/dist/lib/generated/Entities/EntityAction/entityaction.form.component.js +2 -2
  244. package/dist/lib/generated/Entities/EntityAction/sections/details.component.js +2 -2
  245. package/dist/lib/generated/Entities/EntityActionFilter/entityactionfilter.form.component.js +2 -2
  246. package/dist/lib/generated/Entities/EntityActionFilter/sections/details.component.js +2 -2
  247. package/dist/lib/generated/Entities/EntityActionInvocation/entityactioninvocation.form.component.js +2 -2
  248. package/dist/lib/generated/Entities/EntityActionInvocation/sections/details.component.js +2 -2
  249. package/dist/lib/generated/Entities/EntityActionInvocationType/entityactioninvocationtype.form.component.js +2 -2
  250. package/dist/lib/generated/Entities/EntityActionInvocationType/sections/details.component.js +2 -2
  251. package/dist/lib/generated/Entities/EntityActionParam/entityactionparam.form.component.js +2 -2
  252. package/dist/lib/generated/Entities/EntityActionParam/sections/details.component.js +2 -2
  253. package/dist/lib/generated/Entities/EntityCommunicationField/entitycommunicationfield.form.component.js +2 -2
  254. package/dist/lib/generated/Entities/EntityCommunicationField/sections/details.component.js +2 -2
  255. package/dist/lib/generated/Entities/EntityCommunicationMessageType/entitycommunicationmessagetype.form.component.js +2 -2
  256. package/dist/lib/generated/Entities/EntityCommunicationMessageType/sections/details.component.js +2 -2
  257. package/dist/lib/generated/Entities/EntityDocument/entitydocument.form.component.js +2 -2
  258. package/dist/lib/generated/Entities/EntityDocument/sections/details.component.js +2 -2
  259. package/dist/lib/generated/Entities/EntityDocumentRun/entitydocumentrun.form.component.js +2 -2
  260. package/dist/lib/generated/Entities/EntityDocumentRun/sections/details.component.js +2 -2
  261. package/dist/lib/generated/Entities/EntityDocumentSetting/entitydocumentsetting.form.component.js +2 -2
  262. package/dist/lib/generated/Entities/EntityDocumentSetting/sections/details.component.js +2 -2
  263. package/dist/lib/generated/Entities/EntityDocumentType/entitydocumenttype.form.component.js +2 -2
  264. package/dist/lib/generated/Entities/EntityDocumentType/sections/details.component.js +2 -2
  265. package/dist/lib/generated/Entities/EntityField/entityfield.form.component.js +2 -2
  266. package/dist/lib/generated/Entities/EntityField/sections/details.component.js +2 -2
  267. package/dist/lib/generated/Entities/EntityFieldValue/entityfieldvalue.form.component.js +2 -2
  268. package/dist/lib/generated/Entities/EntityFieldValue/sections/details.component.js +2 -2
  269. package/dist/lib/generated/Entities/EntityPermission/entitypermission.form.component.js +2 -2
  270. package/dist/lib/generated/Entities/EntityPermission/sections/details.component.js +2 -2
  271. package/dist/lib/generated/Entities/EntityRecordDocument/entityrecorddocument.form.component.js +2 -2
  272. package/dist/lib/generated/Entities/EntityRecordDocument/sections/details.component.js +2 -2
  273. package/dist/lib/generated/Entities/EntityRelationship/entityrelationship.form.component.js +2 -2
  274. package/dist/lib/generated/Entities/EntityRelationship/sections/details.component.js +2 -2
  275. package/dist/lib/generated/Entities/EntityRelationshipDisplayComponent/entityrelationshipdisplaycomponent.form.component.js +2 -2
  276. package/dist/lib/generated/Entities/EntityRelationshipDisplayComponent/sections/details.component.js +2 -2
  277. package/dist/lib/generated/Entities/EntitySetting/entitysetting.form.component.js +2 -2
  278. package/dist/lib/generated/Entities/EntitySetting/sections/details.component.js +2 -2
  279. package/dist/lib/generated/Entities/ErrorLog/errorlog.form.component.js +2 -2
  280. package/dist/lib/generated/Entities/ErrorLog/sections/details.component.js +2 -2
  281. package/dist/lib/generated/Entities/ExplorerNavigationItem/explorernavigationitem.form.component.js +2 -2
  282. package/dist/lib/generated/Entities/ExplorerNavigationItem/sections/details.component.js +2 -2
  283. package/dist/lib/generated/Entities/File/file.form.component.js +2 -2
  284. package/dist/lib/generated/Entities/File/sections/details.component.js +2 -2
  285. package/dist/lib/generated/Entities/FileCategory/filecategory.form.component.js +2 -2
  286. package/dist/lib/generated/Entities/FileCategory/sections/details.component.js +2 -2
  287. package/dist/lib/generated/Entities/FileEntityRecordLink/fileentityrecordlink.form.component.js +2 -2
  288. package/dist/lib/generated/Entities/FileEntityRecordLink/sections/details.component.js +2 -2
  289. package/dist/lib/generated/Entities/FileStorageProvider/filestorageprovider.form.component.js +2 -2
  290. package/dist/lib/generated/Entities/FileStorageProvider/sections/details.component.js +2 -2
  291. package/dist/lib/generated/Entities/GeneratedCode/generatedcode.form.component.js +2 -2
  292. package/dist/lib/generated/Entities/GeneratedCode/sections/details.component.js +2 -2
  293. package/dist/lib/generated/Entities/GeneratedCodeCategory/generatedcodecategory.form.component.js +2 -2
  294. package/dist/lib/generated/Entities/GeneratedCodeCategory/sections/details.component.js +2 -2
  295. package/dist/lib/generated/Entities/Integration/integration.form.component.js +2 -2
  296. package/dist/lib/generated/Entities/Integration/sections/details.component.js +2 -2
  297. package/dist/lib/generated/Entities/IntegrationURLFormat/integrationurlformat.form.component.js +2 -2
  298. package/dist/lib/generated/Entities/IntegrationURLFormat/sections/details.component.js +2 -2
  299. package/dist/lib/generated/Entities/Library/library.form.component.js +2 -2
  300. package/dist/lib/generated/Entities/Library/sections/details.component.js +2 -2
  301. package/dist/lib/generated/Entities/LibraryItem/libraryitem.form.component.js +2 -2
  302. package/dist/lib/generated/Entities/LibraryItem/sections/details.component.js +2 -2
  303. package/dist/lib/generated/Entities/List/list.form.component.js +2 -2
  304. package/dist/lib/generated/Entities/List/sections/details.component.js +2 -2
  305. package/dist/lib/generated/Entities/ListCategory/listcategory.form.component.js +2 -2
  306. package/dist/lib/generated/Entities/ListCategory/sections/details.component.js +2 -2
  307. package/dist/lib/generated/Entities/ListDetail/listdetail.form.component.js +2 -2
  308. package/dist/lib/generated/Entities/ListDetail/sections/details.component.js +2 -2
  309. package/dist/lib/generated/Entities/OutputDeliveryType/outputdeliverytype.form.component.js +2 -2
  310. package/dist/lib/generated/Entities/OutputDeliveryType/sections/details.component.js +2 -2
  311. package/dist/lib/generated/Entities/OutputFormatType/outputformattype.form.component.js +2 -2
  312. package/dist/lib/generated/Entities/OutputFormatType/sections/details.component.js +2 -2
  313. package/dist/lib/generated/Entities/OutputTriggerType/outputtriggertype.form.component.js +2 -2
  314. package/dist/lib/generated/Entities/OutputTriggerType/sections/details.component.js +2 -2
  315. package/dist/lib/generated/Entities/Query/query.form.component.js +2 -2
  316. package/dist/lib/generated/Entities/Query/sections/details.component.js +2 -2
  317. package/dist/lib/generated/Entities/QueryCategory/querycategory.form.component.js +2 -2
  318. package/dist/lib/generated/Entities/QueryCategory/sections/details.component.js +2 -2
  319. package/dist/lib/generated/Entities/QueryEntity/queryentity.form.component.js +2 -2
  320. package/dist/lib/generated/Entities/QueryEntity/sections/details.component.js +2 -2
  321. package/dist/lib/generated/Entities/QueryField/queryfield.form.component.js +2 -2
  322. package/dist/lib/generated/Entities/QueryField/sections/details.component.js +2 -2
  323. package/dist/lib/generated/Entities/QueryPermission/querypermission.form.component.js +2 -2
  324. package/dist/lib/generated/Entities/QueryPermission/sections/details.component.js +2 -2
  325. package/dist/lib/generated/Entities/Queue/queue.form.component.js +2 -2
  326. package/dist/lib/generated/Entities/Queue/sections/details.component.js +2 -2
  327. package/dist/lib/generated/Entities/QueueTask/queuetask.form.component.js +2 -2
  328. package/dist/lib/generated/Entities/QueueTask/sections/details.component.js +2 -2
  329. package/dist/lib/generated/Entities/QueueType/queuetype.form.component.js +2 -2
  330. package/dist/lib/generated/Entities/QueueType/sections/details.component.js +2 -2
  331. package/dist/lib/generated/Entities/Recommendation/recommendation.form.component.js +2 -2
  332. package/dist/lib/generated/Entities/Recommendation/sections/details.component.js +2 -2
  333. package/dist/lib/generated/Entities/RecommendationItem/recommendationitem.form.component.js +2 -2
  334. package/dist/lib/generated/Entities/RecommendationItem/sections/details.component.js +2 -2
  335. package/dist/lib/generated/Entities/RecommendationProvider/recommendationprovider.form.component.js +2 -2
  336. package/dist/lib/generated/Entities/RecommendationProvider/sections/details.component.js +2 -2
  337. package/dist/lib/generated/Entities/RecommendationRun/recommendationrun.form.component.js +2 -2
  338. package/dist/lib/generated/Entities/RecommendationRun/sections/details.component.js +2 -2
  339. package/dist/lib/generated/Entities/RecordChange/recordchange.form.component.js +2 -2
  340. package/dist/lib/generated/Entities/RecordChange/sections/details.component.js +2 -2
  341. package/dist/lib/generated/Entities/RecordChangeReplayRun/recordchangereplayrun.form.component.js +2 -2
  342. package/dist/lib/generated/Entities/RecordChangeReplayRun/sections/details.component.js +2 -2
  343. package/dist/lib/generated/Entities/RecordMergeDeletionLog/recordmergedeletionlog.form.component.js +2 -2
  344. package/dist/lib/generated/Entities/RecordMergeDeletionLog/sections/details.component.js +2 -2
  345. package/dist/lib/generated/Entities/RecordMergeLog/recordmergelog.form.component.js +2 -2
  346. package/dist/lib/generated/Entities/RecordMergeLog/sections/details.component.js +2 -2
  347. package/dist/lib/generated/Entities/Report/report.form.component.js +2 -2
  348. package/dist/lib/generated/Entities/Report/sections/details.component.js +2 -2
  349. package/dist/lib/generated/Entities/ReportCategory/reportcategory.form.component.js +2 -2
  350. package/dist/lib/generated/Entities/ReportCategory/sections/details.component.js +2 -2
  351. package/dist/lib/generated/Entities/ReportSnapshot/reportsnapshot.form.component.js +2 -2
  352. package/dist/lib/generated/Entities/ReportSnapshot/sections/details.component.js +2 -2
  353. package/dist/lib/generated/Entities/ReportUserState/reportuserstate.form.component.js +2 -2
  354. package/dist/lib/generated/Entities/ReportUserState/sections/details.component.js +2 -2
  355. package/dist/lib/generated/Entities/ReportVersion/reportversion.form.component.js +2 -2
  356. package/dist/lib/generated/Entities/ReportVersion/sections/details.component.js +2 -2
  357. package/dist/lib/generated/Entities/ResourceLink/resourcelink.form.component.js +2 -2
  358. package/dist/lib/generated/Entities/ResourceLink/sections/details.component.js +2 -2
  359. package/dist/lib/generated/Entities/ResourcePermission/resourcepermission.form.component.js +2 -2
  360. package/dist/lib/generated/Entities/ResourcePermission/sections/details.component.js +2 -2
  361. package/dist/lib/generated/Entities/ResourceType/resourcetype.form.component.js +2 -2
  362. package/dist/lib/generated/Entities/ResourceType/sections/details.component.js +2 -2
  363. package/dist/lib/generated/Entities/Role/role.form.component.js +2 -2
  364. package/dist/lib/generated/Entities/Role/sections/details.component.js +2 -2
  365. package/dist/lib/generated/Entities/RowLevelSecurityFilter/rowlevelsecurityfilter.form.component.js +2 -2
  366. package/dist/lib/generated/Entities/RowLevelSecurityFilter/sections/details.component.js +2 -2
  367. package/dist/lib/generated/Entities/ScheduledAction/scheduledaction.form.component.js +2 -2
  368. package/dist/lib/generated/Entities/ScheduledAction/sections/details.component.js +2 -2
  369. package/dist/lib/generated/Entities/ScheduledActionParam/scheduledactionparam.form.component.js +2 -2
  370. package/dist/lib/generated/Entities/ScheduledActionParam/sections/details.component.js +2 -2
  371. package/dist/lib/generated/Entities/SchemaInfo/schemainfo.form.component.js +2 -2
  372. package/dist/lib/generated/Entities/SchemaInfo/sections/details.component.js +2 -2
  373. package/dist/lib/generated/Entities/Skill/sections/details.component.js +2 -2
  374. package/dist/lib/generated/Entities/Skill/skill.form.component.js +2 -2
  375. package/dist/lib/generated/Entities/Tag/sections/details.component.js +2 -2
  376. package/dist/lib/generated/Entities/Tag/tag.form.component.js +2 -2
  377. package/dist/lib/generated/Entities/TaggedItem/sections/details.component.js +2 -2
  378. package/dist/lib/generated/Entities/TaggedItem/taggeditem.form.component.js +2 -2
  379. package/dist/lib/generated/Entities/Template/sections/details.component.js +2 -2
  380. package/dist/lib/generated/Entities/Template/template.form.component.js +2 -2
  381. package/dist/lib/generated/Entities/TemplateCategory/sections/details.component.js +2 -2
  382. package/dist/lib/generated/Entities/TemplateCategory/templatecategory.form.component.js +2 -2
  383. package/dist/lib/generated/Entities/TemplateContent/sections/details.component.js +2 -2
  384. package/dist/lib/generated/Entities/TemplateContent/templatecontent.form.component.js +2 -2
  385. package/dist/lib/generated/Entities/TemplateContentType/sections/details.component.js +2 -2
  386. package/dist/lib/generated/Entities/TemplateContentType/templatecontenttype.form.component.js +2 -2
  387. package/dist/lib/generated/Entities/TemplateParam/sections/details.component.js +2 -2
  388. package/dist/lib/generated/Entities/TemplateParam/templateparam.form.component.js +2 -2
  389. package/dist/lib/generated/Entities/User/sections/details.component.js +2 -2
  390. package/dist/lib/generated/Entities/User/user.form.component.js +20 -10
  391. package/dist/lib/generated/Entities/User/user.form.component.js.map +1 -1
  392. package/dist/lib/generated/Entities/UserApplication/sections/details.component.js +2 -2
  393. package/dist/lib/generated/Entities/UserApplication/userapplication.form.component.js +2 -2
  394. package/dist/lib/generated/Entities/UserApplicationEntity/sections/details.component.js +2 -2
  395. package/dist/lib/generated/Entities/UserApplicationEntity/userapplicationentity.form.component.js +2 -2
  396. package/dist/lib/generated/Entities/UserFavorite/sections/details.component.js +2 -2
  397. package/dist/lib/generated/Entities/UserFavorite/userfavorite.form.component.js +2 -2
  398. package/dist/lib/generated/Entities/UserNotification/sections/details.component.js +2 -2
  399. package/dist/lib/generated/Entities/UserNotification/usernotification.form.component.js +2 -2
  400. package/dist/lib/generated/Entities/UserRecordLog/sections/details.component.js +2 -2
  401. package/dist/lib/generated/Entities/UserRecordLog/userrecordlog.form.component.js +2 -2
  402. package/dist/lib/generated/Entities/UserRole/sections/details.component.js +2 -2
  403. package/dist/lib/generated/Entities/UserRole/userrole.form.component.js +2 -2
  404. package/dist/lib/generated/Entities/UserView/sections/details.component.js +2 -2
  405. package/dist/lib/generated/Entities/UserView/userview.form.component.js +2 -2
  406. package/dist/lib/generated/Entities/UserViewCategory/sections/details.component.js +2 -2
  407. package/dist/lib/generated/Entities/UserViewCategory/userviewcategory.form.component.js +2 -2
  408. package/dist/lib/generated/Entities/UserViewRun/sections/details.component.js +2 -2
  409. package/dist/lib/generated/Entities/UserViewRun/userviewrun.form.component.js +2 -2
  410. package/dist/lib/generated/Entities/UserViewRunDetail/sections/details.component.js +2 -2
  411. package/dist/lib/generated/Entities/UserViewRunDetail/userviewrundetail.form.component.js +2 -2
  412. package/dist/lib/generated/Entities/VectorDatabase/sections/details.component.js +2 -2
  413. package/dist/lib/generated/Entities/VectorDatabase/vectordatabase.form.component.js +2 -2
  414. package/dist/lib/generated/Entities/VectorIndex/sections/details.component.js +2 -2
  415. package/dist/lib/generated/Entities/VectorIndex/vectorindex.form.component.js +2 -2
  416. package/dist/lib/generated/Entities/VersionInstallation/sections/details.component.js +2 -2
  417. package/dist/lib/generated/Entities/VersionInstallation/versioninstallation.form.component.js +2 -2
  418. package/dist/lib/generated/Entities/Workflow/sections/details.component.js +2 -2
  419. package/dist/lib/generated/Entities/Workflow/workflow.form.component.js +2 -2
  420. package/dist/lib/generated/Entities/WorkflowEngine/sections/details.component.js +2 -2
  421. package/dist/lib/generated/Entities/WorkflowEngine/workflowengine.form.component.js +2 -2
  422. package/dist/lib/generated/Entities/WorkflowRun/sections/details.component.js +2 -2
  423. package/dist/lib/generated/Entities/WorkflowRun/workflowrun.form.component.js +2 -2
  424. package/dist/lib/generated/Entities/Workspace/sections/details.component.js +2 -2
  425. package/dist/lib/generated/Entities/Workspace/workspace.form.component.js +2 -2
  426. package/dist/lib/generated/Entities/WorkspaceItem/sections/details.component.js +2 -2
  427. package/dist/lib/generated/Entities/WorkspaceItem/workspaceitem.form.component.js +2 -2
  428. package/dist/lib/generated/generated-forms.module.d.ts +278 -272
  429. package/dist/lib/generated/generated-forms.module.d.ts.map +1 -1
  430. package/dist/lib/generated/generated-forms.module.js +171 -144
  431. package/dist/lib/generated/generated-forms.module.js.map +1 -1
  432. package/dist/lib/shared/components/template-editor.component.d.ts +67 -0
  433. package/dist/lib/shared/components/template-editor.component.d.ts.map +1 -0
  434. package/dist/lib/shared/components/template-editor.component.js +698 -0
  435. package/dist/lib/shared/components/template-editor.component.js.map +1 -0
  436. package/package.json +11 -11
@@ -0,0 +1,1874 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
8
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
9
+ return new (P || (P = Promise))(function (resolve, reject) {
10
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
11
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
12
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
13
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
14
+ });
15
+ };
16
+ import { Component, ViewChild } from '@angular/core';
17
+ import { RegisterClass } from '@memberjunction/global';
18
+ import { BaseFormComponent } from '@memberjunction/ng-base-forms';
19
+ import { Metadata, RunView } from '@memberjunction/core';
20
+ import { MJNotificationService } from '@memberjunction/ng-notifications';
21
+ import { AIPromptFormComponent } from '../../generated/Entities/AIPrompt/aiprompt.form.component';
22
+ import { AIEngineBase } from '@memberjunction/ai-engine-base';
23
+ import * as i0 from "@angular/core";
24
+ import * as i1 from "@angular/common";
25
+ import * as i2 from "@angular/forms";
26
+ import * as i3 from "@progress/kendo-angular-layout";
27
+ import * as i4 from "@progress/kendo-angular-inputs";
28
+ import * as i5 from "@progress/kendo-angular-dropdowns";
29
+ import * as i6 from "@progress/kendo-angular-buttons";
30
+ import * as i7 from "@memberjunction/ng-user-view-grid";
31
+ import * as i8 from "@memberjunction/ng-base-forms";
32
+ import * as i9 from "@memberjunction/ng-form-toolbar";
33
+ import * as i10 from "@memberjunction/ng-container-directives";
34
+ import * as i11 from "@memberjunction/ng-code-editor";
35
+ import * as i12 from "../../shared/components/template-editor.component";
36
+ import * as i13 from "./ai-prompt-execution-dialog.component";
37
+ const _c0 = ["templateEditor"];
38
+ const _forTrack0 = ($index, $item) => $item.ID || $index;
39
+ const _c1 = () => ({ text: "Active", value: "Active" });
40
+ const _c2 = () => ({ text: "Pending", value: "Pending" });
41
+ const _c3 = () => ({ text: "Disabled", value: "Disabled" });
42
+ const _c4 = (a0, a1, a2) => [a0, a1, a2];
43
+ const _c5 = () => ({ text: "None", value: "None" });
44
+ const _c6 = () => ({ text: "Static Count", value: "StaticCount" });
45
+ const _c7 = () => ({ text: "Config Param", value: "ConfigParam" });
46
+ function AIPromptFormComponentExtended_form_1_Conditional_9_Template(rf, ctx) { if (rf & 1) {
47
+ const _r1 = i0.ɵɵgetCurrentView();
48
+ i0.ɵɵelementStart(0, "kendo-textbox", 49);
49
+ i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_9_Template_kendo_textbox_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(2); i0.ɵɵtwoWayBindingSet(ctx_r1.record.Name, $event) || (ctx_r1.record.Name = $event); return i0.ɵɵresetView($event); });
50
+ i0.ɵɵelementEnd();
51
+ } if (rf & 2) {
52
+ const ctx_r1 = i0.ɵɵnextContext(2);
53
+ i0.ɵɵtwoWayProperty("ngModel", ctx_r1.record.Name);
54
+ } }
55
+ function AIPromptFormComponentExtended_form_1_Conditional_10_Template(rf, ctx) { if (rf & 1) {
56
+ i0.ɵɵelementStart(0, "h4", 50);
57
+ i0.ɵɵtext(1);
58
+ i0.ɵɵelementEnd();
59
+ i0.ɵɵelementStart(2, "span", 51);
60
+ i0.ɵɵtext(3);
61
+ i0.ɵɵelementEnd();
62
+ } if (rf & 2) {
63
+ const ctx_r1 = i0.ɵɵnextContext(2);
64
+ i0.ɵɵadvance();
65
+ i0.ɵɵtextInterpolate(ctx_r1.record.Name || "Untitled AI Prompt");
66
+ i0.ɵɵadvance();
67
+ i0.ɵɵstyleProp("background-color", ctx_r1.getStatusBadgeColor());
68
+ i0.ɵɵadvance();
69
+ i0.ɵɵtextInterpolate1(" ", ctx_r1.record.Status, " ");
70
+ } }
71
+ function AIPromptFormComponentExtended_form_1_Conditional_11_Conditional_10_Template(rf, ctx) { if (rf & 1) {
72
+ i0.ɵɵelementStart(0, "div", 54);
73
+ i0.ɵɵelement(1, "i", 56);
74
+ i0.ɵɵtext(2, " Loading types... ");
75
+ i0.ɵɵelementEnd();
76
+ } }
77
+ function AIPromptFormComponentExtended_form_1_Conditional_11_Conditional_11_Template(rf, ctx) { if (rf & 1) {
78
+ const _r4 = i0.ɵɵgetCurrentView();
79
+ i0.ɵɵelementStart(0, "kendo-dropdownlist", 57);
80
+ i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_11_Conditional_11_Template_kendo_dropdownlist_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(3); i0.ɵɵtwoWayBindingSet(ctx_r1.record.TypeID, $event) || (ctx_r1.record.TypeID = $event); return i0.ɵɵresetView($event); });
81
+ i0.ɵɵelementEnd();
82
+ } if (rf & 2) {
83
+ const ctx_r1 = i0.ɵɵnextContext(3);
84
+ i0.ɵɵtwoWayProperty("ngModel", ctx_r1.record.TypeID);
85
+ i0.ɵɵproperty("data", ctx_r1.availablePromptTypes)("valuePrimitive", true)("filterable", true);
86
+ } }
87
+ function AIPromptFormComponentExtended_form_1_Conditional_11_Template(rf, ctx) { if (rf & 1) {
88
+ const _r3 = i0.ɵɵgetCurrentView();
89
+ i0.ɵɵelementStart(0, "div", 14)(1, "div")(2, "label", 47);
90
+ i0.ɵɵtext(3, "Status");
91
+ i0.ɵɵelementEnd();
92
+ i0.ɵɵelementStart(4, "kendo-dropdownlist", 52);
93
+ i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_11_Template_kendo_dropdownlist_ngModelChange_4_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(2); i0.ɵɵtwoWayBindingSet(ctx_r1.record.Status, $event) || (ctx_r1.record.Status = $event); return i0.ɵɵresetView($event); });
94
+ i0.ɵɵelementEnd()();
95
+ i0.ɵɵelementStart(5, "div")(6, "label", 47);
96
+ i0.ɵɵtext(7, " Type ");
97
+ i0.ɵɵelementStart(8, "span", 53);
98
+ i0.ɵɵtext(9, "*");
99
+ i0.ɵɵelementEnd()();
100
+ i0.ɵɵtemplate(10, AIPromptFormComponentExtended_form_1_Conditional_11_Conditional_10_Template, 3, 0, "div", 54)(11, AIPromptFormComponentExtended_form_1_Conditional_11_Conditional_11_Template, 1, 4, "kendo-dropdownlist", 55);
101
+ i0.ɵɵelementEnd()();
102
+ } if (rf & 2) {
103
+ const ctx_r1 = i0.ɵɵnextContext(2);
104
+ i0.ɵɵadvance(4);
105
+ i0.ɵɵtwoWayProperty("ngModel", ctx_r1.record.Status);
106
+ i0.ɵɵproperty("data", i0.ɵɵpureFunction3(7, _c4, i0.ɵɵpureFunction0(4, _c1), i0.ɵɵpureFunction0(5, _c2), i0.ɵɵpureFunction0(6, _c3)))("valuePrimitive", true);
107
+ i0.ɵɵadvance(6);
108
+ i0.ɵɵconditional(ctx_r1.isLoadingPromptTypes ? 10 : 11);
109
+ } }
110
+ function AIPromptFormComponentExtended_form_1_Conditional_12_Template(rf, ctx) { if (rf & 1) {
111
+ const _r5 = i0.ɵɵgetCurrentView();
112
+ i0.ɵɵelementStart(0, "kendo-textarea", 58);
113
+ i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_12_Template_kendo_textarea_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r5); const ctx_r1 = i0.ɵɵnextContext(2); i0.ɵɵtwoWayBindingSet(ctx_r1.record.Description, $event) || (ctx_r1.record.Description = $event); return i0.ɵɵresetView($event); });
114
+ i0.ɵɵelementEnd();
115
+ } if (rf & 2) {
116
+ const ctx_r1 = i0.ɵɵnextContext(2);
117
+ i0.ɵɵtwoWayProperty("ngModel", ctx_r1.record.Description);
118
+ i0.ɵɵproperty("rows", 2);
119
+ } }
120
+ function AIPromptFormComponentExtended_form_1_Conditional_13_Template(rf, ctx) { if (rf & 1) {
121
+ i0.ɵɵelementStart(0, "p", 16);
122
+ i0.ɵɵtext(1);
123
+ i0.ɵɵelementEnd();
124
+ } if (rf & 2) {
125
+ const ctx_r1 = i0.ɵɵnextContext(2);
126
+ i0.ɵɵadvance();
127
+ i0.ɵɵtextInterpolate(ctx_r1.record.Description);
128
+ } }
129
+ function AIPromptFormComponentExtended_form_1_Conditional_15_Template(rf, ctx) { if (rf & 1) {
130
+ i0.ɵɵelementStart(0, "div", 18);
131
+ i0.ɵɵelement(1, "i", 59);
132
+ i0.ɵɵelementStart(2, "span", 20);
133
+ i0.ɵɵtext(3, "Type:");
134
+ i0.ɵɵelementEnd();
135
+ i0.ɵɵelementStart(4, "span", 21);
136
+ i0.ɵɵtext(5);
137
+ i0.ɵɵelementEnd()();
138
+ } if (rf & 2) {
139
+ const ctx_r1 = i0.ɵɵnextContext(2);
140
+ i0.ɵɵadvance(5);
141
+ i0.ɵɵtextInterpolate(ctx_r1.getPromptTypeDisplayName(ctx_r1.record.TypeID));
142
+ } }
143
+ function AIPromptFormComponentExtended_form_1_Conditional_28_Template(rf, ctx) { if (rf & 1) {
144
+ i0.ɵɵelementStart(0, "div", 18);
145
+ i0.ɵɵelement(1, "i", 60);
146
+ i0.ɵɵelementStart(2, "span", 61);
147
+ i0.ɵɵtext(3, "Caching Enabled");
148
+ i0.ɵɵelementEnd()();
149
+ } }
150
+ function AIPromptFormComponentExtended_form_1_Conditional_31_Template(rf, ctx) { if (rf & 1) {
151
+ const _r6 = i0.ɵɵgetCurrentView();
152
+ i0.ɵɵelementStart(0, "kendo-button", 62);
153
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_31_Template_kendo_button_click_0_listener() { i0.ɵɵrestoreView(_r6); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.executeAIPrompt()); });
154
+ i0.ɵɵelement(1, "i", 63);
155
+ i0.ɵɵtext(2, " Execute Prompt ");
156
+ i0.ɵɵelementEnd();
157
+ } }
158
+ function AIPromptFormComponentExtended_form_1_Conditional_32_Template(rf, ctx) { if (rf & 1) {
159
+ i0.ɵɵelementStart(0, "kendo-button", 27);
160
+ i0.ɵɵelement(1, "i", 64);
161
+ i0.ɵɵtext(2, " Cannot Execute ");
162
+ i0.ɵɵelementEnd();
163
+ } if (rf & 2) {
164
+ i0.ɵɵproperty("disabled", true);
165
+ } }
166
+ function AIPromptFormComponentExtended_form_1_Conditional_33_Template(rf, ctx) { if (rf & 1) {
167
+ i0.ɵɵelementStart(0, "kendo-button", 28);
168
+ i0.ɵɵelement(1, "i", 65);
169
+ i0.ɵɵtext(2, " History ");
170
+ i0.ɵɵelementEnd();
171
+ } }
172
+ function AIPromptFormComponentExtended_form_1_Conditional_34_Conditional_1_Template(rf, ctx) { if (rf & 1) {
173
+ i0.ɵɵtext(0, " \u2022 Prompt must be Active");
174
+ i0.ɵɵelement(1, "br");
175
+ } }
176
+ function AIPromptFormComponentExtended_form_1_Conditional_34_Conditional_2_Template(rf, ctx) { if (rf & 1) {
177
+ i0.ɵɵtext(0, " \u2022 Template is required");
178
+ i0.ɵɵelement(1, "br");
179
+ } }
180
+ function AIPromptFormComponentExtended_form_1_Conditional_34_Conditional_3_Template(rf, ctx) { if (rf & 1) {
181
+ i0.ɵɵtext(0, " \u2022 Template not found");
182
+ i0.ɵɵelement(1, "br");
183
+ } }
184
+ function AIPromptFormComponentExtended_form_1_Conditional_34_Template(rf, ctx) { if (rf & 1) {
185
+ i0.ɵɵelementStart(0, "div", 29);
186
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_34_Conditional_1_Template, 2, 0, "br")(2, AIPromptFormComponentExtended_form_1_Conditional_34_Conditional_2_Template, 2, 0, "br")(3, AIPromptFormComponentExtended_form_1_Conditional_34_Conditional_3_Template, 2, 0, "br");
187
+ i0.ɵɵelementEnd();
188
+ } if (rf & 2) {
189
+ const ctx_r1 = i0.ɵɵnextContext(2);
190
+ i0.ɵɵadvance();
191
+ i0.ɵɵconditional(ctx_r1.record.Status !== "Active" ? 1 : -1);
192
+ i0.ɵɵadvance();
193
+ i0.ɵɵconditional(!ctx_r1.record.TemplateID ? 2 : -1);
194
+ i0.ɵɵadvance();
195
+ i0.ɵɵconditional(!ctx_r1.template && ctx_r1.record.TemplateID ? 3 : -1);
196
+ } }
197
+ function AIPromptFormComponentExtended_form_1_ng_template_37_Conditional_3_Template(rf, ctx) { if (rf & 1) {
198
+ i0.ɵɵelementStart(0, "span", 67);
199
+ i0.ɵɵtext(1);
200
+ i0.ɵɵelementEnd();
201
+ } if (rf & 2) {
202
+ const ctx_r1 = i0.ɵɵnextContext(3);
203
+ i0.ɵɵadvance();
204
+ i0.ɵɵtextInterpolate1("\u2022 ", ctx_r1.template.Name, "");
205
+ } }
206
+ function AIPromptFormComponentExtended_form_1_ng_template_37_Template(rf, ctx) { if (rf & 1) {
207
+ i0.ɵɵelementStart(0, "span", 66);
208
+ i0.ɵɵelement(1, "i", 22);
209
+ i0.ɵɵtext(2, " Template Editor ");
210
+ i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_ng_template_37_Conditional_3_Template, 2, 1, "span", 67);
211
+ i0.ɵɵelementEnd();
212
+ } if (rf & 2) {
213
+ const ctx_r1 = i0.ɵɵnextContext(2);
214
+ i0.ɵɵadvance(3);
215
+ i0.ɵɵconditional(ctx_r1.template ? 3 : -1);
216
+ } }
217
+ function AIPromptFormComponentExtended_form_1_Conditional_39_Template(rf, ctx) { if (rf & 1) {
218
+ i0.ɵɵelementStart(0, "div", 34);
219
+ i0.ɵɵelement(1, "i", 68);
220
+ i0.ɵɵtext(2, " Loading template... ");
221
+ i0.ɵɵelementEnd();
222
+ } }
223
+ function AIPromptFormComponentExtended_form_1_Conditional_40_Template(rf, ctx) { if (rf & 1) {
224
+ const _r7 = i0.ɵɵgetCurrentView();
225
+ i0.ɵɵelementStart(0, "div", 35);
226
+ i0.ɵɵelement(1, "i", 69);
227
+ i0.ɵɵelementStart(2, "h5", 70);
228
+ i0.ɵɵtext(3, "No Template Associated");
229
+ i0.ɵɵelementEnd();
230
+ i0.ɵɵelementStart(4, "p", 71);
231
+ i0.ɵɵtext(5, " This AI prompt needs a template to define its structure and parameters. Create a new template or link to an existing one. ");
232
+ i0.ɵɵelementEnd();
233
+ i0.ɵɵelementStart(6, "div", 72)(7, "kendo-button", 73);
234
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_40_Template_kendo_button_click_7_listener() { i0.ɵɵrestoreView(_r7); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.createNewTemplate()); });
235
+ i0.ɵɵelement(8, "i", 74);
236
+ i0.ɵɵtext(9, " Create New Template ");
237
+ i0.ɵɵelementEnd();
238
+ i0.ɵɵelementStart(10, "kendo-button", 75);
239
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_40_Template_kendo_button_click_10_listener() { i0.ɵɵrestoreView(_r7); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.linkExistingTemplate()); });
240
+ i0.ɵɵelement(11, "i", 76);
241
+ i0.ɵɵtext(12, " Link Existing Template ");
242
+ i0.ɵɵelementEnd()()();
243
+ } }
244
+ function AIPromptFormComponentExtended_form_1_Conditional_41_Template(rf, ctx) { if (rf & 1) {
245
+ const _r8 = i0.ɵɵgetCurrentView();
246
+ i0.ɵɵelementStart(0, "div", 36);
247
+ i0.ɵɵelement(1, "i", 77);
248
+ i0.ɵɵelementStart(2, "h5", 78);
249
+ i0.ɵɵtext(3, "Template Not Found");
250
+ i0.ɵɵelementEnd();
251
+ i0.ɵɵelementStart(4, "p", 71);
252
+ i0.ɵɵtext(5, " The referenced template could not be loaded. It may have been deleted or moved. ");
253
+ i0.ɵɵelementEnd();
254
+ i0.ɵɵelementStart(6, "div", 72)(7, "kendo-button", 75);
255
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_41_Template_kendo_button_click_7_listener() { i0.ɵɵrestoreView(_r8); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.loadTemplate()); });
256
+ i0.ɵɵelement(8, "i", 79);
257
+ i0.ɵɵtext(9, " Retry Loading ");
258
+ i0.ɵɵelementEnd();
259
+ i0.ɵɵelementStart(10, "kendo-button", 73);
260
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_41_Template_kendo_button_click_10_listener() { i0.ɵɵrestoreView(_r8); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.createNewTemplate()); });
261
+ i0.ɵɵelement(11, "i", 74);
262
+ i0.ɵɵtext(12, " Create New Template ");
263
+ i0.ɵɵelementEnd()()();
264
+ } }
265
+ function AIPromptFormComponentExtended_form_1_Conditional_42_Template(rf, ctx) { if (rf & 1) {
266
+ const _r9 = i0.ɵɵgetCurrentView();
267
+ i0.ɵɵelementStart(0, "div", 37)(1, "div", 80)(2, "mj-template-editor", 81, 1);
268
+ i0.ɵɵlistener("contentChange", function AIPromptFormComponentExtended_form_1_Conditional_42_Template_mj_template_editor_contentChange_2_listener($event) { i0.ɵɵrestoreView(_r9); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.onTemplateContentChange($event)); })("runTemplate", function AIPromptFormComponentExtended_form_1_Conditional_42_Template_mj_template_editor_runTemplate_2_listener($event) { i0.ɵɵrestoreView(_r9); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.onTemplateRun($event)); });
269
+ i0.ɵɵelementEnd()()();
270
+ } if (rf & 2) {
271
+ const ctx_r1 = i0.ɵɵnextContext(2);
272
+ i0.ɵɵadvance(2);
273
+ i0.ɵɵproperty("template", ctx_r1.template)("config", ctx_r1.templateEditorConfig);
274
+ } }
275
+ function AIPromptFormComponentExtended_form_1_Conditional_43_ng_template_1_Conditional_3_Template(rf, ctx) { if (rf & 1) {
276
+ i0.ɵɵelementStart(0, "span", 85);
277
+ i0.ɵɵtext(1);
278
+ i0.ɵɵelementEnd();
279
+ } if (rf & 2) {
280
+ const ctx_r1 = i0.ɵɵnextContext(4);
281
+ i0.ɵɵadvance();
282
+ i0.ɵɵtextInterpolate1(" ", ctx_r1.promptModels.length, " ");
283
+ } }
284
+ function AIPromptFormComponentExtended_form_1_Conditional_43_ng_template_1_Template(rf, ctx) { if (rf & 1) {
285
+ i0.ɵɵelementStart(0, "span", 66);
286
+ i0.ɵɵelement(1, "i", 84);
287
+ i0.ɵɵtext(2, " Models ");
288
+ i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_Conditional_43_ng_template_1_Conditional_3_Template, 2, 1, "span", 85);
289
+ i0.ɵɵelementEnd();
290
+ } if (rf & 2) {
291
+ const ctx_r1 = i0.ɵɵnextContext(3);
292
+ i0.ɵɵadvance(3);
293
+ i0.ɵɵconditional(ctx_r1.promptModels.length > 0 ? 3 : -1);
294
+ } }
295
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_4_Template(rf, ctx) { if (rf & 1) {
296
+ i0.ɵɵelementStart(0, "div", 83);
297
+ i0.ɵɵelement(1, "i", 56);
298
+ i0.ɵɵtext(2, " Loading models... ");
299
+ i0.ɵɵelementEnd();
300
+ } }
301
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_0_Conditional_3_Template(rf, ctx) { if (rf & 1) {
302
+ const _r10 = i0.ɵɵgetCurrentView();
303
+ i0.ɵɵelementStart(0, "div", 88)(1, "kendo-button", 89);
304
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_0_Conditional_3_Template_kendo_button_click_1_listener() { i0.ɵɵrestoreView(_r10); const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.addNewModel()); });
305
+ i0.ɵɵelement(2, "i", 74);
306
+ i0.ɵɵtext(3, " Add Model ");
307
+ i0.ɵɵelementEnd()();
308
+ } }
309
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_0_Template(rf, ctx) { if (rf & 1) {
310
+ i0.ɵɵelementStart(0, "div", 86);
311
+ i0.ɵɵelement(1, "i", 87);
312
+ i0.ɵɵtext(2, " No models configured ");
313
+ i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_0_Conditional_3_Template, 4, 0, "div", 88);
314
+ i0.ɵɵelementEnd();
315
+ } if (rf & 2) {
316
+ const ctx_r1 = i0.ɵɵnextContext(4);
317
+ i0.ɵɵadvance(3);
318
+ i0.ɵɵconditional(ctx_r1.EditMode ? 3 : -1);
319
+ } }
320
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_2_Template(rf, ctx) { if (rf & 1) {
321
+ i0.ɵɵelement(0, "i", 94);
322
+ } }
323
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_3_Template(rf, ctx) { if (rf & 1) {
324
+ i0.ɵɵelementStart(0, "span", 95);
325
+ i0.ɵɵtext(1);
326
+ i0.ɵɵelementEnd();
327
+ } if (rf & 2) {
328
+ const ɵ$index_278_r11 = i0.ɵɵnextContext().$index;
329
+ i0.ɵɵadvance();
330
+ i0.ɵɵtextInterpolate(ɵ$index_278_r11 + 1);
331
+ } }
332
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_5_Template(rf, ctx) { if (rf & 1) {
333
+ const _r12 = i0.ɵɵgetCurrentView();
334
+ i0.ɵɵelementStart(0, "kendo-dropdownlist", 106);
335
+ i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_5_Template_kendo_dropdownlist_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r12); const model_r13 = i0.ɵɵnextContext().$implicit; i0.ɵɵtwoWayBindingSet(model_r13.ModelID, $event) || (model_r13.ModelID = $event); return i0.ɵɵresetView($event); });
336
+ i0.ɵɵlistener("valueChange", function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_5_Template_kendo_dropdownlist_valueChange_0_listener($event) { i0.ɵɵrestoreView(_r12); const ɵ$index_278_r11 = i0.ɵɵnextContext().$index; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.onModelChange($event, ɵ$index_278_r11)); });
337
+ i0.ɵɵelementEnd();
338
+ } if (rf & 2) {
339
+ const ctx_r13 = i0.ɵɵnextContext();
340
+ const model_r13 = ctx_r13.$implicit;
341
+ const ɵ$index_278_r11 = ctx_r13.$index;
342
+ const ctx_r1 = i0.ɵɵnextContext(5);
343
+ i0.ɵɵtwoWayProperty("ngModel", model_r13.ModelID);
344
+ i0.ɵɵproperty("name", "modelId_" + ɵ$index_278_r11)("data", ctx_r1.availableModels)("valuePrimitive", true)("filterable", true);
345
+ } }
346
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_6_Template(rf, ctx) { if (rf & 1) {
347
+ i0.ɵɵelementStart(0, "span", 23);
348
+ i0.ɵɵtext(1);
349
+ i0.ɵɵelementEnd();
350
+ } if (rf & 2) {
351
+ const model_r13 = i0.ɵɵnextContext().$implicit;
352
+ const ctx_r1 = i0.ɵɵnextContext(5);
353
+ i0.ɵɵadvance();
354
+ i0.ɵɵtextInterpolate(ctx_r1.getModelDisplayName(model_r13.ModelID));
355
+ } }
356
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_0_ng_template_1_Conditional_2_Template(rf, ctx) { if (rf & 1) {
357
+ i0.ɵɵelementStart(0, "span", 111);
358
+ i0.ɵɵtext(1);
359
+ i0.ɵɵelementEnd();
360
+ } if (rf & 2) {
361
+ const dataItem_r16 = i0.ɵɵnextContext().$implicit;
362
+ const model_r13 = i0.ɵɵnextContext(4).$implicit;
363
+ const ctx_r1 = i0.ɵɵnextContext(5);
364
+ i0.ɵɵadvance();
365
+ i0.ɵɵtextInterpolate1("(", ctx_r1.getModelVendorStatus(model_r13.ModelID, dataItem_r16.ID), ")");
366
+ } }
367
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_0_ng_template_1_Template(rf, ctx) { if (rf & 1) {
368
+ i0.ɵɵelementStart(0, "span");
369
+ i0.ɵɵtext(1);
370
+ i0.ɵɵtemplate(2, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_0_ng_template_1_Conditional_2_Template, 2, 1, "span", 111);
371
+ i0.ɵɵelementEnd();
372
+ } if (rf & 2) {
373
+ const dataItem_r16 = ctx.$implicit;
374
+ const model_r13 = i0.ɵɵnextContext(4).$implicit;
375
+ const ctx_r1 = i0.ɵɵnextContext(5);
376
+ i0.ɵɵstyleProp("color", ctx_r1.getVendorStatusColor(model_r13.ModelID, dataItem_r16.ID));
377
+ i0.ɵɵadvance();
378
+ i0.ɵɵtextInterpolate1(" ", dataItem_r16.Name, " ");
379
+ i0.ɵɵadvance();
380
+ i0.ɵɵconditional(ctx_r1.getModelVendorStatus(model_r13.ModelID, dataItem_r16.ID) !== "Active" ? 2 : -1);
381
+ } }
382
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_0_Template(rf, ctx) { if (rf & 1) {
383
+ const _r15 = i0.ɵɵgetCurrentView();
384
+ i0.ɵɵelementStart(0, "kendo-dropdownlist", 109);
385
+ i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_0_Template_kendo_dropdownlist_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r15); const model_r13 = i0.ɵɵnextContext(3).$implicit; i0.ɵɵtwoWayBindingSet(model_r13.VendorID, $event) || (model_r13.VendorID = $event); return i0.ɵɵresetView($event); });
386
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_0_ng_template_1_Template, 3, 4, "ng-template", 110);
387
+ i0.ɵɵelementEnd();
388
+ } if (rf & 2) {
389
+ const ctx_r13 = i0.ɵɵnextContext(3);
390
+ const model_r13 = ctx_r13.$implicit;
391
+ const ɵ$index_278_r11 = ctx_r13.$index;
392
+ const ctx_r1 = i0.ɵɵnextContext(5);
393
+ i0.ɵɵtwoWayProperty("ngModel", model_r13.VendorID);
394
+ i0.ɵɵproperty("name", "vendorId_" + ɵ$index_278_r11)("data", ctx_r1.getVendorsForModelSync(model_r13.ModelID))("valuePrimitive", true)("filterable", true);
395
+ } }
396
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_1_Conditional_0_Conditional_2_Template(rf, ctx) { if (rf & 1) {
397
+ i0.ɵɵelementStart(0, "span", 111);
398
+ i0.ɵɵtext(1);
399
+ i0.ɵɵelementEnd();
400
+ } if (rf & 2) {
401
+ const model_r13 = i0.ɵɵnextContext(5).$implicit;
402
+ const ctx_r1 = i0.ɵɵnextContext(5);
403
+ i0.ɵɵadvance();
404
+ i0.ɵɵtextInterpolate1("(", ctx_r1.getModelVendorStatus(model_r13.ModelID, ctx_r1.getVendorsForModelSync(model_r13.ModelID)[0].ID), ")");
405
+ } }
406
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_1_Conditional_0_Template(rf, ctx) { if (rf & 1) {
407
+ i0.ɵɵelementStart(0, "span", 113);
408
+ i0.ɵɵtext(1);
409
+ i0.ɵɵtemplate(2, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_1_Conditional_0_Conditional_2_Template, 2, 1, "span", 111);
410
+ i0.ɵɵelementEnd();
411
+ } if (rf & 2) {
412
+ const model_r13 = i0.ɵɵnextContext(4).$implicit;
413
+ const ctx_r1 = i0.ɵɵnextContext(5);
414
+ i0.ɵɵstyleProp("color", ctx_r1.getVendorStatusColor(model_r13.ModelID, ctx_r1.getVendorsForModelSync(model_r13.ModelID)[0].ID));
415
+ i0.ɵɵadvance();
416
+ i0.ɵɵtextInterpolate1(" ", ctx_r1.getVendorsForModelSync(model_r13.ModelID)[0].Name, " ");
417
+ i0.ɵɵadvance();
418
+ i0.ɵɵconditional(ctx_r1.getModelVendorStatus(model_r13.ModelID, ctx_r1.getVendorsForModelSync(model_r13.ModelID)[0].ID) !== "Active" ? 2 : -1);
419
+ } }
420
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_1_Conditional_1_Template(rf, ctx) { if (rf & 1) {
421
+ i0.ɵɵelementStart(0, "span", 107);
422
+ i0.ɵɵtext(1, "No vendors available");
423
+ i0.ɵɵelementEnd();
424
+ } }
425
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_1_Template(rf, ctx) { if (rf & 1) {
426
+ i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_1_Conditional_0_Template, 3, 4, "span", 112)(1, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_1_Conditional_1_Template, 2, 0, "span", 107);
427
+ } if (rf & 2) {
428
+ const model_r13 = i0.ɵɵnextContext(3).$implicit;
429
+ const ctx_r1 = i0.ɵɵnextContext(5);
430
+ i0.ɵɵconditional(ctx_r1.getVendorsForModelSync(model_r13.ModelID).length === 1 ? 0 : 1);
431
+ } }
432
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Template(rf, ctx) { if (rf & 1) {
433
+ i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_0_Template, 2, 5, "kendo-dropdownlist", 108)(1, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Conditional_1_Template, 2, 1);
434
+ } if (rf & 2) {
435
+ const model_r13 = i0.ɵɵnextContext(2).$implicit;
436
+ const ctx_r1 = i0.ɵɵnextContext(5);
437
+ i0.ɵɵconditional(ctx_r1.shouldShowVendorDropdown(model_r13.ModelID) ? 0 : 1);
438
+ } }
439
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_1_Template(rf, ctx) { if (rf & 1) {
440
+ i0.ɵɵelementStart(0, "span", 107);
441
+ i0.ɵɵtext(1, "Select model first");
442
+ i0.ɵɵelementEnd();
443
+ } }
444
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Template(rf, ctx) { if (rf & 1) {
445
+ i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_0_Template, 2, 1)(1, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Conditional_1_Template, 2, 0, "span", 107);
446
+ } if (rf & 2) {
447
+ const model_r13 = i0.ɵɵnextContext().$implicit;
448
+ i0.ɵɵconditional(model_r13.ModelID ? 0 : 1);
449
+ } }
450
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_9_Conditional_0_Conditional_2_Template(rf, ctx) { if (rf & 1) {
451
+ i0.ɵɵelementStart(0, "span", 111);
452
+ i0.ɵɵtext(1);
453
+ i0.ɵɵelementEnd();
454
+ } if (rf & 2) {
455
+ const model_r13 = i0.ɵɵnextContext(3).$implicit;
456
+ const ctx_r1 = i0.ɵɵnextContext(5);
457
+ i0.ɵɵadvance();
458
+ i0.ɵɵtextInterpolate1("(", ctx_r1.getModelVendorStatus(model_r13.ModelID, model_r13.VendorID), ")");
459
+ } }
460
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_9_Conditional_0_Template(rf, ctx) { if (rf & 1) {
461
+ i0.ɵɵelementStart(0, "span", 116);
462
+ i0.ɵɵtext(1);
463
+ i0.ɵɵtemplate(2, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_9_Conditional_0_Conditional_2_Template, 2, 1, "span", 111);
464
+ i0.ɵɵelementEnd();
465
+ } if (rf & 2) {
466
+ const model_r13 = i0.ɵɵnextContext(2).$implicit;
467
+ const ctx_r1 = i0.ɵɵnextContext(5);
468
+ i0.ɵɵstyleProp("color", ctx_r1.getVendorStatusColor(model_r13.ModelID, model_r13.VendorID));
469
+ i0.ɵɵadvance();
470
+ i0.ɵɵtextInterpolate1(" ", ctx_r1.getVendorDisplayName(model_r13.VendorID), " ");
471
+ i0.ɵɵadvance();
472
+ i0.ɵɵconditional(ctx_r1.getModelVendorStatus(model_r13.ModelID, model_r13.VendorID) !== "Active" ? 2 : -1);
473
+ } }
474
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_9_Conditional_1_Template(rf, ctx) { if (rf & 1) {
475
+ i0.ɵɵelementStart(0, "span", 115);
476
+ i0.ɵɵtext(1, "-");
477
+ i0.ɵɵelementEnd();
478
+ } }
479
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_9_Template(rf, ctx) { if (rf & 1) {
480
+ i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_9_Conditional_0_Template, 3, 4, "span", 114)(1, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_9_Conditional_1_Template, 2, 0, "span", 115);
481
+ } if (rf & 2) {
482
+ const model_r13 = i0.ɵɵnextContext().$implicit;
483
+ i0.ɵɵconditional(model_r13.VendorID && model_r13.ModelID ? 0 : 1);
484
+ } }
485
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_11_Template(rf, ctx) { if (rf & 1) {
486
+ i0.ɵɵelementStart(0, "span", 100);
487
+ i0.ɵɵtext(1);
488
+ i0.ɵɵpipe(2, "date");
489
+ i0.ɵɵelementEnd();
490
+ } if (rf & 2) {
491
+ const model_r13 = i0.ɵɵnextContext().$implicit;
492
+ i0.ɵɵadvance();
493
+ i0.ɵɵtextInterpolate(i0.ɵɵpipeBind2(2, 1, model_r13.__mj_CreatedAt, "short"));
494
+ } }
495
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_12_Template(rf, ctx) { if (rf & 1) {
496
+ i0.ɵɵelementStart(0, "span", 101);
497
+ i0.ɵɵtext(1, "New");
498
+ i0.ɵɵelementEnd();
499
+ } }
500
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_14_Template(rf, ctx) { if (rf & 1) {
501
+ const _r17 = i0.ɵɵgetCurrentView();
502
+ i0.ɵɵelementStart(0, "div", 117)(1, "kendo-button", 118);
503
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_14_Template_kendo_button_click_1_listener() { i0.ɵɵrestoreView(_r17); const ɵ$index_278_r11 = i0.ɵɵnextContext().$index; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.moveModelUp(ɵ$index_278_r11)); });
504
+ i0.ɵɵelement(2, "i", 119);
505
+ i0.ɵɵelementEnd();
506
+ i0.ɵɵelementStart(3, "kendo-button", 120);
507
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_14_Template_kendo_button_click_3_listener() { i0.ɵɵrestoreView(_r17); const ɵ$index_278_r11 = i0.ɵɵnextContext().$index; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.moveModelDown(ɵ$index_278_r11)); });
508
+ i0.ɵɵelement(4, "i", 121);
509
+ i0.ɵɵelementEnd()();
510
+ i0.ɵɵelementStart(5, "kendo-button", 122);
511
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_14_Template_kendo_button_click_5_listener() { i0.ɵɵrestoreView(_r17); const ɵ$index_278_r11 = i0.ɵɵnextContext().$index; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.removePromptModel(ɵ$index_278_r11)); });
512
+ i0.ɵɵelement(6, "i", 123);
513
+ i0.ɵɵelementEnd();
514
+ } if (rf & 2) {
515
+ const ɵ$index_278_r11 = i0.ɵɵnextContext().$index;
516
+ const ctx_r1 = i0.ɵɵnextContext(5);
517
+ i0.ɵɵadvance();
518
+ i0.ɵɵproperty("disabled", ɵ$index_278_r11 === 0);
519
+ i0.ɵɵadvance(2);
520
+ i0.ɵɵproperty("disabled", ɵ$index_278_r11 === ctx_r1.promptModels.length - 1);
521
+ } }
522
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_19_Template(rf, ctx) { if (rf & 1) {
523
+ i0.ɵɵelementStart(0, "span")(1, "strong");
524
+ i0.ɵɵtext(2, "Status:");
525
+ i0.ɵɵelementEnd();
526
+ i0.ɵɵtext(3);
527
+ i0.ɵɵelementEnd();
528
+ } if (rf & 2) {
529
+ const model_r13 = i0.ɵɵnextContext().$implicit;
530
+ i0.ɵɵadvance(3);
531
+ i0.ɵɵtextInterpolate1(" ", model_r13.Status, "");
532
+ } }
533
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_20_Template(rf, ctx) { if (rf & 1) {
534
+ i0.ɵɵelementStart(0, "span")(1, "strong");
535
+ i0.ɵɵtext(2, "Configuration:");
536
+ i0.ɵɵelementEnd();
537
+ i0.ɵɵtext(3);
538
+ i0.ɵɵelementEnd();
539
+ } if (rf & 2) {
540
+ const model_r13 = i0.ɵɵnextContext().$implicit;
541
+ i0.ɵɵadvance(3);
542
+ i0.ɵɵtextInterpolate1(" ", model_r13.ConfigurationID, "");
543
+ } }
544
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_4_Conditional_5_Template(rf, ctx) { if (rf & 1) {
545
+ const _r19 = i0.ɵɵgetCurrentView();
546
+ i0.ɵɵelementStart(0, "div")(1, "label", 128);
547
+ i0.ɵɵtext(2, "Parallel Count");
548
+ i0.ɵɵelementEnd();
549
+ i0.ɵɵelementStart(3, "kendo-numerictextbox", 130);
550
+ i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_4_Conditional_5_Template_kendo_numerictextbox_ngModelChange_3_listener($event) { i0.ɵɵrestoreView(_r19); const model_r13 = i0.ɵɵnextContext(3).$implicit; i0.ɵɵtwoWayBindingSet(model_r13.ParallelCount, $event) || (model_r13.ParallelCount = $event); return i0.ɵɵresetView($event); });
551
+ i0.ɵɵelementEnd()();
552
+ } if (rf & 2) {
553
+ const ctx_r13 = i0.ɵɵnextContext(3);
554
+ const model_r13 = ctx_r13.$implicit;
555
+ const ɵ$index_278_r11 = ctx_r13.$index;
556
+ i0.ɵɵadvance(3);
557
+ i0.ɵɵtwoWayProperty("ngModel", model_r13.ParallelCount);
558
+ i0.ɵɵproperty("name", "parallelCount_" + ɵ$index_278_r11)("min", 1)("step", 1)("format", "n0");
559
+ } }
560
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_4_Conditional_6_Template(rf, ctx) { if (rf & 1) {
561
+ const _r20 = i0.ɵɵgetCurrentView();
562
+ i0.ɵɵelementStart(0, "div")(1, "label", 128);
563
+ i0.ɵɵtext(2, "Config Parameter");
564
+ i0.ɵɵelementEnd();
565
+ i0.ɵɵelementStart(3, "kendo-textbox", 131);
566
+ i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_4_Conditional_6_Template_kendo_textbox_ngModelChange_3_listener($event) { i0.ɵɵrestoreView(_r20); const model_r13 = i0.ɵɵnextContext(3).$implicit; i0.ɵɵtwoWayBindingSet(model_r13.ParallelConfigParam, $event) || (model_r13.ParallelConfigParam = $event); return i0.ɵɵresetView($event); });
567
+ i0.ɵɵelementEnd()();
568
+ } if (rf & 2) {
569
+ const ctx_r13 = i0.ɵɵnextContext(3);
570
+ const model_r13 = ctx_r13.$implicit;
571
+ const ɵ$index_278_r11 = ctx_r13.$index;
572
+ i0.ɵɵadvance(3);
573
+ i0.ɵɵtwoWayProperty("ngModel", model_r13.ParallelConfigParam);
574
+ i0.ɵɵproperty("name", "parallelConfigParam_" + ɵ$index_278_r11);
575
+ } }
576
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_4_Template(rf, ctx) { if (rf & 1) {
577
+ const _r18 = i0.ɵɵgetCurrentView();
578
+ i0.ɵɵelementStart(0, "div", 126)(1, "div")(2, "label", 128);
579
+ i0.ɵɵtext(3, "Parallel Mode");
580
+ i0.ɵɵelementEnd();
581
+ i0.ɵɵelementStart(4, "kendo-dropdownlist", 129);
582
+ i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_4_Template_kendo_dropdownlist_ngModelChange_4_listener($event) { i0.ɵɵrestoreView(_r18); const model_r13 = i0.ɵɵnextContext(2).$implicit; i0.ɵɵtwoWayBindingSet(model_r13.ParallelizationMode, $event) || (model_r13.ParallelizationMode = $event); return i0.ɵɵresetView($event); });
583
+ i0.ɵɵelementEnd()();
584
+ i0.ɵɵtemplate(5, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_4_Conditional_5_Template, 4, 5, "div")(6, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_4_Conditional_6_Template, 4, 2, "div");
585
+ i0.ɵɵelementEnd();
586
+ } if (rf & 2) {
587
+ const ctx_r13 = i0.ɵɵnextContext(2);
588
+ const model_r13 = ctx_r13.$implicit;
589
+ const ɵ$index_278_r11 = ctx_r13.$index;
590
+ i0.ɵɵadvance(4);
591
+ i0.ɵɵtwoWayProperty("ngModel", model_r13.ParallelizationMode);
592
+ i0.ɵɵproperty("name", "parallelMode_" + ɵ$index_278_r11)("data", i0.ɵɵpureFunction3(9, _c4, i0.ɵɵpureFunction0(6, _c5), i0.ɵɵpureFunction0(7, _c6), i0.ɵɵpureFunction0(8, _c7)))("valuePrimitive", true);
593
+ i0.ɵɵadvance();
594
+ i0.ɵɵconditional(model_r13.ParallelizationMode === "StaticCount" ? 5 : -1);
595
+ i0.ɵɵadvance();
596
+ i0.ɵɵconditional(model_r13.ParallelizationMode === "ConfigParam" ? 6 : -1);
597
+ } }
598
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_5_Conditional_1_Template(rf, ctx) { if (rf & 1) {
599
+ i0.ɵɵelementStart(0, "span")(1, "strong");
600
+ i0.ɵɵtext(2, "Parallel Mode:");
601
+ i0.ɵɵelementEnd();
602
+ i0.ɵɵtext(3);
603
+ i0.ɵɵelementEnd();
604
+ } if (rf & 2) {
605
+ const model_r13 = i0.ɵɵnextContext(3).$implicit;
606
+ i0.ɵɵadvance(3);
607
+ i0.ɵɵtextInterpolate1(" ", model_r13.ParallelizationMode, "");
608
+ } }
609
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_5_Conditional_2_Template(rf, ctx) { if (rf & 1) {
610
+ i0.ɵɵelementStart(0, "span")(1, "strong");
611
+ i0.ɵɵtext(2, "Parallel Count:");
612
+ i0.ɵɵelementEnd();
613
+ i0.ɵɵtext(3);
614
+ i0.ɵɵelementEnd();
615
+ } if (rf & 2) {
616
+ const model_r13 = i0.ɵɵnextContext(3).$implicit;
617
+ i0.ɵɵadvance(3);
618
+ i0.ɵɵtextInterpolate1(" ", model_r13.ParallelCount, "");
619
+ } }
620
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_5_Conditional_3_Template(rf, ctx) { if (rf & 1) {
621
+ i0.ɵɵelementStart(0, "span")(1, "strong");
622
+ i0.ɵɵtext(2, "Config Param:");
623
+ i0.ɵɵelementEnd();
624
+ i0.ɵɵtext(3);
625
+ i0.ɵɵelementEnd();
626
+ } if (rf & 2) {
627
+ const model_r13 = i0.ɵɵnextContext(3).$implicit;
628
+ i0.ɵɵadvance(3);
629
+ i0.ɵɵtextInterpolate1(" ", model_r13.ParallelConfigParam, "");
630
+ } }
631
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_5_Template(rf, ctx) { if (rf & 1) {
632
+ i0.ɵɵelementStart(0, "div", 127);
633
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_5_Conditional_1_Template, 4, 1, "span")(2, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_5_Conditional_2_Template, 4, 1, "span")(3, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_5_Conditional_3_Template, 4, 1, "span");
634
+ i0.ɵɵelementEnd();
635
+ } if (rf & 2) {
636
+ const model_r13 = i0.ɵɵnextContext(2).$implicit;
637
+ i0.ɵɵadvance();
638
+ i0.ɵɵconditional(model_r13.ParallelizationMode ? 1 : -1);
639
+ i0.ɵɵadvance();
640
+ i0.ɵɵconditional(model_r13.ParallelCount ? 2 : -1);
641
+ i0.ɵɵadvance();
642
+ i0.ɵɵconditional(model_r13.ParallelConfigParam ? 3 : -1);
643
+ } }
644
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Template(rf, ctx) { if (rf & 1) {
645
+ i0.ɵɵelementStart(0, "div", 105)(1, "div", 124);
646
+ i0.ɵɵelement(2, "i", 125);
647
+ i0.ɵɵtext(3, " Model-Specific Parallel Execution ");
648
+ i0.ɵɵelementEnd();
649
+ i0.ɵɵtemplate(4, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_4_Template, 7, 13, "div", 126)(5, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Conditional_5_Template, 4, 3, "div", 127);
650
+ i0.ɵɵelementEnd();
651
+ } if (rf & 2) {
652
+ const ctx_r1 = i0.ɵɵnextContext(6);
653
+ i0.ɵɵadvance(4);
654
+ i0.ɵɵconditional(ctx_r1.EditMode ? 4 : 5);
655
+ } }
656
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Template(rf, ctx) { if (rf & 1) {
657
+ i0.ɵɵelementStart(0, "div", 92)(1, "div", 93);
658
+ i0.ɵɵtemplate(2, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_2_Template, 1, 0, "i", 94)(3, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_3_Template, 2, 1, "span", 95);
659
+ i0.ɵɵelementEnd();
660
+ i0.ɵɵelementStart(4, "div", 96);
661
+ i0.ɵɵtemplate(5, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_5_Template, 1, 5, "kendo-dropdownlist", 97)(6, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_6_Template, 2, 1, "span", 23);
662
+ i0.ɵɵelementEnd();
663
+ i0.ɵɵelementStart(7, "div", 98);
664
+ i0.ɵɵtemplate(8, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_8_Template, 2, 1)(9, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_9_Template, 2, 1);
665
+ i0.ɵɵelementEnd();
666
+ i0.ɵɵelementStart(10, "div", 99);
667
+ i0.ɵɵtemplate(11, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_11_Template, 3, 4, "span", 100)(12, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_12_Template, 2, 0, "span", 101);
668
+ i0.ɵɵelementEnd();
669
+ i0.ɵɵelementStart(13, "div", 102);
670
+ i0.ɵɵtemplate(14, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_14_Template, 7, 2);
671
+ i0.ɵɵelementEnd()();
672
+ i0.ɵɵelementStart(15, "div", 103);
673
+ i0.ɵɵelement(16, "div");
674
+ i0.ɵɵelementStart(17, "div")(18, "div", 104);
675
+ i0.ɵɵtemplate(19, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_19_Template, 4, 1, "span")(20, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_20_Template, 4, 1, "span");
676
+ i0.ɵɵelementEnd();
677
+ i0.ɵɵtemplate(21, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Conditional_21_Template, 6, 1, "div", 105);
678
+ i0.ɵɵelementEnd()();
679
+ } if (rf & 2) {
680
+ const model_r13 = ctx.$implicit;
681
+ const ctx_r1 = i0.ɵɵnextContext(5);
682
+ i0.ɵɵstyleProp("background", !model_r13.ModelID ? "#fff3cd" : "white")("border-left", !model_r13.ModelID ? "3px solid #ffc107" : "none");
683
+ i0.ɵɵadvance(2);
684
+ i0.ɵɵconditional(ctx_r1.EditMode ? 2 : 3);
685
+ i0.ɵɵadvance(3);
686
+ i0.ɵɵconditional(ctx_r1.EditMode ? 5 : 6);
687
+ i0.ɵɵadvance(3);
688
+ i0.ɵɵconditional(ctx_r1.EditMode ? 8 : 9);
689
+ i0.ɵɵadvance(3);
690
+ i0.ɵɵconditional(model_r13.ID ? 11 : 12);
691
+ i0.ɵɵadvance(3);
692
+ i0.ɵɵconditional(ctx_r1.EditMode ? 14 : -1);
693
+ i0.ɵɵadvance(5);
694
+ i0.ɵɵconditional(model_r13.Status ? 19 : -1);
695
+ i0.ɵɵadvance();
696
+ i0.ɵɵconditional(model_r13.ConfigurationID ? 20 : -1);
697
+ i0.ɵɵadvance();
698
+ i0.ɵɵconditional(ctx_r1.record.ParallelizationMode === "ModelSpecific" ? 21 : -1);
699
+ } }
700
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_Conditional_14_Template(rf, ctx) { if (rf & 1) {
701
+ const _r21 = i0.ɵɵgetCurrentView();
702
+ i0.ɵɵelementStart(0, "div", 91)(1, "kendo-button", 132);
703
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_Conditional_14_Template_kendo_button_click_1_listener() { i0.ɵɵrestoreView(_r21); const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.addNewModel()); });
704
+ i0.ɵɵelement(2, "i", 74);
705
+ i0.ɵɵtext(3, " Add Model ");
706
+ i0.ɵɵelementEnd()();
707
+ } }
708
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_Template(rf, ctx) { if (rf & 1) {
709
+ i0.ɵɵelementStart(0, "div", 90);
710
+ i0.ɵɵelement(1, "div");
711
+ i0.ɵɵelementStart(2, "div");
712
+ i0.ɵɵtext(3, "AI Model ");
713
+ i0.ɵɵelementStart(4, "span", 53);
714
+ i0.ɵɵtext(5, "*");
715
+ i0.ɵɵelementEnd()();
716
+ i0.ɵɵelementStart(6, "div");
717
+ i0.ɵɵtext(7, "Vendor");
718
+ i0.ɵɵelementEnd();
719
+ i0.ɵɵelementStart(8, "div");
720
+ i0.ɵɵtext(9, "Created");
721
+ i0.ɵɵelementEnd();
722
+ i0.ɵɵelementStart(10, "div");
723
+ i0.ɵɵtext(11, "Actions");
724
+ i0.ɵɵelementEnd()();
725
+ i0.ɵɵrepeaterCreate(12, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_For_13_Template, 22, 12, null, null, _forTrack0);
726
+ i0.ɵɵtemplate(14, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_Conditional_14_Template, 4, 0, "div", 91);
727
+ } if (rf & 2) {
728
+ const ctx_r1 = i0.ɵɵnextContext(4);
729
+ i0.ɵɵadvance(12);
730
+ i0.ɵɵrepeater(ctx_r1.promptModels);
731
+ i0.ɵɵadvance(2);
732
+ i0.ɵɵconditional(ctx_r1.EditMode ? 14 : -1);
733
+ } }
734
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Template(rf, ctx) { if (rf & 1) {
735
+ i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_0_Template, 4, 1, "div", 86)(1, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Conditional_1_Template, 15, 1);
736
+ } if (rf & 2) {
737
+ const ctx_r1 = i0.ɵɵnextContext(3);
738
+ i0.ɵɵconditional(ctx_r1.promptModels.length === 0 ? 0 : 1);
739
+ } }
740
+ function AIPromptFormComponentExtended_form_1_Conditional_43_Template(rf, ctx) { if (rf & 1) {
741
+ i0.ɵɵelementStart(0, "kendo-expansionpanel", 31);
742
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_43_ng_template_1_Template, 4, 1, "ng-template", 32);
743
+ i0.ɵɵelementStart(2, "div", 38)(3, "div", 82);
744
+ i0.ɵɵtemplate(4, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_4_Template, 3, 0, "div", 83)(5, AIPromptFormComponentExtended_form_1_Conditional_43_Conditional_5_Template, 2, 1);
745
+ i0.ɵɵelementEnd()()();
746
+ } if (rf & 2) {
747
+ const ctx_r1 = i0.ɵɵnextContext(2);
748
+ i0.ɵɵproperty("expanded", false);
749
+ i0.ɵɵadvance(4);
750
+ i0.ɵɵconditional(ctx_r1.isLoadingModels ? 4 : 5);
751
+ } }
752
+ function AIPromptFormComponentExtended_form_1_ng_template_45_Template(rf, ctx) { if (rf & 1) {
753
+ i0.ɵɵelementStart(0, "span", 66);
754
+ i0.ɵɵelement(1, "i", 133);
755
+ i0.ɵɵtext(2, " Advanced Configuration ");
756
+ i0.ɵɵelementEnd();
757
+ } }
758
+ function AIPromptFormComponentExtended_form_1_Conditional_50_Template(rf, ctx) { if (rf & 1) {
759
+ i0.ɵɵelement(0, "mj-form-field", 41);
760
+ } if (rf & 2) {
761
+ const ctx_r1 = i0.ɵɵnextContext(2);
762
+ i0.ɵɵproperty("record", ctx_r1.record)("ShowLabel", true)("EditMode", ctx_r1.EditMode);
763
+ } }
764
+ function AIPromptFormComponentExtended_form_1_Conditional_51_Template(rf, ctx) { if (rf & 1) {
765
+ i0.ɵɵelement(0, "mj-form-field", 42);
766
+ } if (rf & 2) {
767
+ const ctx_r1 = i0.ɵɵnextContext(2);
768
+ i0.ɵɵproperty("record", ctx_r1.record)("ShowLabel", true)("EditMode", ctx_r1.EditMode);
769
+ } }
770
+ function AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_0_Template(rf, ctx) { if (rf & 1) {
771
+ i0.ɵɵelementStart(0, "div", 134);
772
+ i0.ɵɵelement(1, "i", 56);
773
+ i0.ɵɵtext(2, " Loading prompts... ");
774
+ i0.ɵɵelementEnd();
775
+ } }
776
+ function AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_1_Template(rf, ctx) { if (rf & 1) {
777
+ const _r22 = i0.ɵɵgetCurrentView();
778
+ i0.ɵɵelementStart(0, "kendo-dropdowntree", 136);
779
+ i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_1_Template_kendo_dropdowntree_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r22); const ctx_r1 = i0.ɵɵnextContext(3); i0.ɵɵtwoWayBindingSet(ctx_r1.record.ResultSelectorPromptID, $event) || (ctx_r1.record.ResultSelectorPromptID = $event); return i0.ɵɵresetView($event); });
780
+ i0.ɵɵlistener("valueChange", function AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_1_Template_kendo_dropdowntree_valueChange_0_listener($event) { i0.ɵɵrestoreView(_r22); const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.onResultSelectorChange($event)); });
781
+ i0.ɵɵelementEnd();
782
+ } if (rf & 2) {
783
+ const ctx_r1 = i0.ɵɵnextContext(3);
784
+ i0.ɵɵtwoWayProperty("ngModel", ctx_r1.record.ResultSelectorPromptID);
785
+ i0.ɵɵproperty("data", ctx_r1.resultSelectorTreeData)("valuePrimitive", true)("filterable", true);
786
+ } }
787
+ function AIPromptFormComponentExtended_form_1_Conditional_59_Template(rf, ctx) { if (rf & 1) {
788
+ i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_0_Template, 3, 0, "div", 134)(1, AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_1_Template, 1, 4, "kendo-dropdowntree", 135);
789
+ } if (rf & 2) {
790
+ const ctx_r1 = i0.ɵɵnextContext(2);
791
+ i0.ɵɵconditional(ctx_r1.isLoadingResultSelectorData ? 0 : 1);
792
+ } }
793
+ function AIPromptFormComponentExtended_form_1_Conditional_60_Template(rf, ctx) { if (rf & 1) {
794
+ i0.ɵɵelementStart(0, "span", 48);
795
+ i0.ɵɵtext(1);
796
+ i0.ɵɵelementEnd();
797
+ } if (rf & 2) {
798
+ const ctx_r1 = i0.ɵɵnextContext(2);
799
+ i0.ɵɵadvance();
800
+ i0.ɵɵtextInterpolate(ctx_r1.getPromptDisplayName(ctx_r1.record.ResultSelectorPromptID || "") || "None selected");
801
+ } }
802
+ function AIPromptFormComponentExtended_form_1_Conditional_61_ng_template_1_Template(rf, ctx) { if (rf & 1) {
803
+ i0.ɵɵelementStart(0, "span", 66);
804
+ i0.ɵɵelement(1, "i", 22);
805
+ i0.ɵɵtext(2, " Output Example (JSON) ");
806
+ i0.ɵɵelementStart(3, "span", 140);
807
+ i0.ɵɵtext(4, "\u2022 Required for object output type");
808
+ i0.ɵɵelementEnd()();
809
+ } }
810
+ function AIPromptFormComponentExtended_form_1_Conditional_61_Conditional_3_Template(rf, ctx) { if (rf & 1) {
811
+ const _r23 = i0.ɵɵgetCurrentView();
812
+ i0.ɵɵelementStart(0, "mj-code-editor", 141);
813
+ i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_61_Conditional_3_Template_mj_code_editor_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r23); const ctx_r1 = i0.ɵɵnextContext(3); i0.ɵɵtwoWayBindingSet(ctx_r1.record.OutputExample, $event) || (ctx_r1.record.OutputExample = $event); return i0.ɵɵresetView($event); });
814
+ i0.ɵɵelementEnd();
815
+ i0.ɵɵelementStart(1, "div", 142);
816
+ i0.ɵɵelement(2, "i", 87);
817
+ i0.ɵɵtext(3, " Provide a JSON example that defines the expected structure for object output validation. ");
818
+ i0.ɵɵelementEnd();
819
+ } if (rf & 2) {
820
+ const ctx_r1 = i0.ɵɵnextContext(3);
821
+ i0.ɵɵtwoWayProperty("ngModel", ctx_r1.record.OutputExample);
822
+ } }
823
+ function AIPromptFormComponentExtended_form_1_Conditional_61_Conditional_4_Template(rf, ctx) { if (rf & 1) {
824
+ i0.ɵɵelementStart(0, "div", 138);
825
+ i0.ɵɵtext(1);
826
+ i0.ɵɵelementEnd();
827
+ } if (rf & 2) {
828
+ const ctx_r1 = i0.ɵɵnextContext(3);
829
+ i0.ɵɵadvance();
830
+ i0.ɵɵtextInterpolate(ctx_r1.record.OutputExample);
831
+ } }
832
+ function AIPromptFormComponentExtended_form_1_Conditional_61_Conditional_5_Template(rf, ctx) { if (rf & 1) {
833
+ i0.ɵɵelementStart(0, "div", 139);
834
+ i0.ɵɵelement(1, "i", 64);
835
+ i0.ɵɵtext(2, " Output example is required when output type is 'object' ");
836
+ i0.ɵɵelementEnd();
837
+ } }
838
+ function AIPromptFormComponentExtended_form_1_Conditional_61_Template(rf, ctx) { if (rf & 1) {
839
+ i0.ɵɵelementStart(0, "kendo-expansionpanel", 31);
840
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_61_ng_template_1_Template, 5, 0, "ng-template", 32);
841
+ i0.ɵɵelementStart(2, "div", 137);
842
+ i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_Conditional_61_Conditional_3_Template, 4, 1)(4, AIPromptFormComponentExtended_form_1_Conditional_61_Conditional_4_Template, 2, 1, "div", 138)(5, AIPromptFormComponentExtended_form_1_Conditional_61_Conditional_5_Template, 3, 0, "div", 139);
843
+ i0.ɵɵelementEnd()();
844
+ } if (rf & 2) {
845
+ const ctx_r1 = i0.ɵɵnextContext(2);
846
+ i0.ɵɵproperty("expanded", true);
847
+ i0.ɵɵadvance(3);
848
+ i0.ɵɵconditional(ctx_r1.EditMode ? 3 : ctx_r1.record.OutputExample ? 4 : 5);
849
+ } }
850
+ function AIPromptFormComponentExtended_form_1_Conditional_62_ng_template_1_Template(rf, ctx) { if (rf & 1) {
851
+ i0.ɵɵelementStart(0, "span", 66);
852
+ i0.ɵɵelement(1, "i", 144);
853
+ i0.ɵɵtext(2, " Execution History ");
854
+ i0.ɵɵelementEnd();
855
+ } }
856
+ function AIPromptFormComponentExtended_form_1_Conditional_62_Template(rf, ctx) { if (rf & 1) {
857
+ i0.ɵɵelementStart(0, "kendo-expansionpanel", 31);
858
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_62_ng_template_1_Template, 3, 0, "ng-template", 32);
859
+ i0.ɵɵelementStart(2, "div", 38);
860
+ i0.ɵɵelement(3, "mj-user-view-grid", 143);
861
+ i0.ɵɵelementEnd()();
862
+ } if (rf & 2) {
863
+ const ctx_r1 = i0.ɵɵnextContext(2);
864
+ i0.ɵɵproperty("expanded", false);
865
+ i0.ɵɵadvance(3);
866
+ i0.ɵɵproperty("Params", ctx_r1.BuildRelationshipViewParamsByEntityName("MJ: AI Prompt Runs", "PromptID"))("NewRecordValues", ctx_r1.NewRecordValues("MJ: AI Prompt Runs"))("AllowLoad", true)("EditMode", ctx_r1.GridEditMode())("BottomMargin", 0);
867
+ } }
868
+ function AIPromptFormComponentExtended_form_1_Conditional_63_ng_template_1_Template(rf, ctx) { if (rf & 1) {
869
+ i0.ɵɵelementStart(0, "span", 66);
870
+ i0.ɵɵelement(1, "i", 145);
871
+ i0.ɵɵtext(2, " Result Cache ");
872
+ i0.ɵɵelementEnd();
873
+ } }
874
+ function AIPromptFormComponentExtended_form_1_Conditional_63_Template(rf, ctx) { if (rf & 1) {
875
+ i0.ɵɵelementStart(0, "kendo-expansionpanel", 31);
876
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_63_ng_template_1_Template, 3, 0, "ng-template", 32);
877
+ i0.ɵɵelementStart(2, "div", 38);
878
+ i0.ɵɵelement(3, "mj-user-view-grid", 143);
879
+ i0.ɵɵelementEnd()();
880
+ } if (rf & 2) {
881
+ const ctx_r1 = i0.ɵɵnextContext(2);
882
+ i0.ɵɵproperty("expanded", false);
883
+ i0.ɵɵadvance(3);
884
+ i0.ɵɵproperty("Params", ctx_r1.BuildRelationshipViewParamsByEntityName("AI Result Cache", "AIPromptID"))("NewRecordValues", ctx_r1.NewRecordValues("AI Result Cache"))("AllowLoad", true)("EditMode", ctx_r1.GridEditMode())("BottomMargin", 0);
885
+ } }
886
+ function AIPromptFormComponentExtended_form_1_Conditional_64_ng_template_1_Template(rf, ctx) { if (rf & 1) {
887
+ i0.ɵɵelementStart(0, "span", 66);
888
+ i0.ɵɵelement(1, "i", 148);
889
+ i0.ɵɵtext(2, " Related Items ");
890
+ i0.ɵɵelementEnd();
891
+ } }
892
+ function AIPromptFormComponentExtended_form_1_Conditional_64_Template(rf, ctx) { if (rf & 1) {
893
+ i0.ɵɵelementStart(0, "kendo-expansionpanel", 31);
894
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_64_ng_template_1_Template, 3, 0, "ng-template", 32);
895
+ i0.ɵɵelementStart(2, "div", 38)(3, "div", 39)(4, "div")(5, "h6", 146);
896
+ i0.ɵɵtext(6, "AI Agents Using This Prompt");
897
+ i0.ɵɵelementEnd();
898
+ i0.ɵɵelement(7, "mj-user-view-grid", 147);
899
+ i0.ɵɵelementEnd();
900
+ i0.ɵɵelementStart(8, "div")(9, "h6", 146);
901
+ i0.ɵɵtext(10, "Prompts Using This as Result Selector");
902
+ i0.ɵɵelementEnd();
903
+ i0.ɵɵelement(11, "mj-user-view-grid", 147);
904
+ i0.ɵɵelementEnd()()()();
905
+ } if (rf & 2) {
906
+ const ctx_r1 = i0.ɵɵnextContext(2);
907
+ i0.ɵɵproperty("expanded", false);
908
+ i0.ɵɵadvance(7);
909
+ i0.ɵɵproperty("Params", ctx_r1.BuildRelationshipViewParamsByEntityName("MJ: AI Agent Prompts", "PromptID"))("NewRecordValues", ctx_r1.NewRecordValues("MJ: AI Agent Prompts"))("AllowLoad", true)("EditMode", ctx_r1.GridEditMode())("BottomMargin", 0);
910
+ i0.ɵɵadvance(4);
911
+ i0.ɵɵproperty("Params", ctx_r1.BuildRelationshipViewParamsByEntityName("AI Prompts", "ResultSelectorPromptID"))("NewRecordValues", ctx_r1.NewRecordValues("AI Prompts"))("AllowLoad", true)("EditMode", ctx_r1.GridEditMode())("BottomMargin", 0);
912
+ } }
913
+ function AIPromptFormComponentExtended_form_1_Template(rf, ctx) { if (rf & 1) {
914
+ i0.ɵɵelementStart(0, "form", 5, 0);
915
+ i0.ɵɵelement(2, "mj-form-toolbar", 6);
916
+ i0.ɵɵelementStart(3, "div", 7)(4, "div", 8)(5, "div", 9)(6, "div", 10)(7, "div", 11);
917
+ i0.ɵɵelement(8, "i", 12);
918
+ i0.ɵɵtemplate(9, AIPromptFormComponentExtended_form_1_Conditional_9_Template, 1, 1, "kendo-textbox", 13)(10, AIPromptFormComponentExtended_form_1_Conditional_10_Template, 4, 4);
919
+ i0.ɵɵelementEnd();
920
+ i0.ɵɵtemplate(11, AIPromptFormComponentExtended_form_1_Conditional_11_Template, 12, 11, "div", 14)(12, AIPromptFormComponentExtended_form_1_Conditional_12_Template, 1, 2, "kendo-textarea", 15)(13, AIPromptFormComponentExtended_form_1_Conditional_13_Template, 2, 1, "p", 16);
921
+ i0.ɵɵelementStart(14, "div", 17);
922
+ i0.ɵɵtemplate(15, AIPromptFormComponentExtended_form_1_Conditional_15_Template, 6, 1, "div", 18);
923
+ i0.ɵɵelementStart(16, "div", 18);
924
+ i0.ɵɵelement(17, "i", 19);
925
+ i0.ɵɵelementStart(18, "span", 20);
926
+ i0.ɵɵtext(19, "Parallelization:");
927
+ i0.ɵɵelementEnd();
928
+ i0.ɵɵelementStart(20, "span", 21);
929
+ i0.ɵɵtext(21);
930
+ i0.ɵɵelementEnd()();
931
+ i0.ɵɵelementStart(22, "div", 18);
932
+ i0.ɵɵelement(23, "i", 22);
933
+ i0.ɵɵelementStart(24, "span", 20);
934
+ i0.ɵɵtext(25, "Output:");
935
+ i0.ɵɵelementEnd();
936
+ i0.ɵɵelementStart(26, "span", 23);
937
+ i0.ɵɵtext(27);
938
+ i0.ɵɵelementEnd()();
939
+ i0.ɵɵtemplate(28, AIPromptFormComponentExtended_form_1_Conditional_28_Template, 4, 0, "div", 18);
940
+ i0.ɵɵelementEnd()();
941
+ i0.ɵɵelementStart(29, "div", 24)(30, "div", 25);
942
+ i0.ɵɵtemplate(31, AIPromptFormComponentExtended_form_1_Conditional_31_Template, 3, 0, "kendo-button", 26)(32, AIPromptFormComponentExtended_form_1_Conditional_32_Template, 3, 1, "kendo-button", 27)(33, AIPromptFormComponentExtended_form_1_Conditional_33_Template, 3, 0, "kendo-button", 28);
943
+ i0.ɵɵelementEnd();
944
+ i0.ɵɵtemplate(34, AIPromptFormComponentExtended_form_1_Conditional_34_Template, 4, 3, "div", 29);
945
+ i0.ɵɵelementEnd()()();
946
+ i0.ɵɵelementStart(35, "div", 30)(36, "kendo-expansionpanel", 31);
947
+ i0.ɵɵtemplate(37, AIPromptFormComponentExtended_form_1_ng_template_37_Template, 4, 1, "ng-template", 32);
948
+ i0.ɵɵelementStart(38, "div", 33);
949
+ i0.ɵɵtemplate(39, AIPromptFormComponentExtended_form_1_Conditional_39_Template, 3, 0, "div", 34)(40, AIPromptFormComponentExtended_form_1_Conditional_40_Template, 13, 0, "div", 35)(41, AIPromptFormComponentExtended_form_1_Conditional_41_Template, 13, 0, "div", 36)(42, AIPromptFormComponentExtended_form_1_Conditional_42_Template, 4, 2, "div", 37);
950
+ i0.ɵɵelementEnd()();
951
+ i0.ɵɵtemplate(43, AIPromptFormComponentExtended_form_1_Conditional_43_Template, 6, 2, "kendo-expansionpanel", 31);
952
+ i0.ɵɵelementStart(44, "kendo-expansionpanel", 31);
953
+ i0.ɵɵtemplate(45, AIPromptFormComponentExtended_form_1_ng_template_45_Template, 3, 0, "ng-template", 32);
954
+ i0.ɵɵelementStart(46, "div", 38)(47, "div", 39)(48, "div");
955
+ i0.ɵɵelement(49, "mj-form-field", 40);
956
+ i0.ɵɵtemplate(50, AIPromptFormComponentExtended_form_1_Conditional_50_Template, 1, 3, "mj-form-field", 41)(51, AIPromptFormComponentExtended_form_1_Conditional_51_Template, 1, 3, "mj-form-field", 42);
957
+ i0.ɵɵelement(52, "mj-form-field", 43);
958
+ i0.ɵɵelementEnd();
959
+ i0.ɵɵelementStart(53, "div");
960
+ i0.ɵɵelement(54, "mj-form-field", 44)(55, "mj-form-field", 45);
961
+ i0.ɵɵelementStart(56, "div", 46)(57, "label", 47);
962
+ i0.ɵɵtext(58, " Result Selector Prompt ");
963
+ i0.ɵɵelementEnd();
964
+ i0.ɵɵtemplate(59, AIPromptFormComponentExtended_form_1_Conditional_59_Template, 2, 1)(60, AIPromptFormComponentExtended_form_1_Conditional_60_Template, 2, 1, "span", 48);
965
+ i0.ɵɵelementEnd()()()()();
966
+ i0.ɵɵtemplate(61, AIPromptFormComponentExtended_form_1_Conditional_61_Template, 6, 2, "kendo-expansionpanel", 31)(62, AIPromptFormComponentExtended_form_1_Conditional_62_Template, 4, 6, "kendo-expansionpanel", 31)(63, AIPromptFormComponentExtended_form_1_Conditional_63_Template, 4, 6, "kendo-expansionpanel", 31)(64, AIPromptFormComponentExtended_form_1_Conditional_64_Template, 12, 11, "kendo-expansionpanel", 31);
967
+ i0.ɵɵelementEnd()()();
968
+ } if (rf & 2) {
969
+ const ctx_r1 = i0.ɵɵnextContext();
970
+ i0.ɵɵadvance(2);
971
+ i0.ɵɵproperty("form", ctx_r1);
972
+ i0.ɵɵadvance(7);
973
+ i0.ɵɵconditional(ctx_r1.EditMode ? 9 : 10);
974
+ i0.ɵɵadvance(2);
975
+ i0.ɵɵconditional(ctx_r1.EditMode ? 11 : -1);
976
+ i0.ɵɵadvance();
977
+ i0.ɵɵconditional(ctx_r1.EditMode ? 12 : ctx_r1.record.Description ? 13 : -1);
978
+ i0.ɵɵadvance(3);
979
+ i0.ɵɵconditional(ctx_r1.record.TypeID ? 15 : -1);
980
+ i0.ɵɵadvance(6);
981
+ i0.ɵɵtextInterpolate(ctx_r1.getParallelizationModeDisplay());
982
+ i0.ɵɵadvance(5);
983
+ i0.ɵɵstyleProp("color", ctx_r1.getValidationColor());
984
+ i0.ɵɵadvance();
985
+ i0.ɵɵtextInterpolate(ctx_r1.getOutputTypeDisplay());
986
+ i0.ɵɵadvance();
987
+ i0.ɵɵconditional(ctx_r1.record.EnableCaching ? 28 : -1);
988
+ i0.ɵɵadvance(3);
989
+ i0.ɵɵconditional(ctx_r1.record.ID && ctx_r1.canExecute ? 31 : ctx_r1.record.ID && !ctx_r1.canExecute ? 32 : -1);
990
+ i0.ɵɵadvance(2);
991
+ i0.ɵɵconditional(ctx_r1.record.ID ? 33 : -1);
992
+ i0.ɵɵadvance();
993
+ i0.ɵɵconditional(!ctx_r1.canExecute && ctx_r1.record.ID ? 34 : -1);
994
+ i0.ɵɵadvance(2);
995
+ i0.ɵɵproperty("expanded", true);
996
+ i0.ɵɵadvance(3);
997
+ i0.ɵɵconditional(ctx_r1.isLoadingTemplate ? 39 : !ctx_r1.record.TemplateID ? 40 : !ctx_r1.template ? 41 : 42);
998
+ i0.ɵɵadvance(4);
999
+ i0.ɵɵconditional(ctx_r1.record.IsSaved ? 43 : -1);
1000
+ i0.ɵɵadvance();
1001
+ i0.ɵɵproperty("expanded", false);
1002
+ i0.ɵɵadvance(5);
1003
+ i0.ɵɵproperty("record", ctx_r1.record)("ShowLabel", true)("EditMode", ctx_r1.EditMode);
1004
+ i0.ɵɵadvance();
1005
+ i0.ɵɵconditional(ctx_r1.showParallelCount ? 50 : -1);
1006
+ i0.ɵɵadvance();
1007
+ i0.ɵɵconditional(ctx_r1.showParallelConfigParam ? 51 : -1);
1008
+ i0.ɵɵadvance();
1009
+ i0.ɵɵproperty("record", ctx_r1.record)("ShowLabel", true)("EditMode", ctx_r1.EditMode);
1010
+ i0.ɵɵadvance(2);
1011
+ i0.ɵɵproperty("record", ctx_r1.record)("ShowLabel", true)("EditMode", ctx_r1.EditMode);
1012
+ i0.ɵɵadvance();
1013
+ i0.ɵɵproperty("record", ctx_r1.record)("ShowLabel", true)("EditMode", ctx_r1.EditMode);
1014
+ i0.ɵɵadvance(4);
1015
+ i0.ɵɵconditional(ctx_r1.EditMode ? 59 : 60);
1016
+ i0.ɵɵadvance(2);
1017
+ i0.ɵɵconditional(ctx_r1.showOutputExample ? 61 : -1);
1018
+ i0.ɵɵadvance();
1019
+ i0.ɵɵconditional(ctx_r1.record.IsSaved ? 62 : -1);
1020
+ i0.ɵɵadvance();
1021
+ i0.ɵɵconditional(ctx_r1.record.IsSaved && ctx_r1.record.EnableCaching ? 63 : -1);
1022
+ i0.ɵɵadvance();
1023
+ i0.ɵɵconditional(ctx_r1.record.IsSaved ? 64 : -1);
1024
+ } }
1025
+ let AIPromptFormComponentExtended = class AIPromptFormComponentExtended extends AIPromptFormComponent {
1026
+ constructor() {
1027
+ super(...arguments);
1028
+ this.template = null;
1029
+ this.isLoadingTemplate = false;
1030
+ this.showExecutionDialog = false;
1031
+ // Model management
1032
+ this.promptModels = [];
1033
+ this.availableModels = [];
1034
+ this.availableVendors = [];
1035
+ this.isLoadingModels = false;
1036
+ // Vendor management per model
1037
+ this.modelVendorsMap = new Map();
1038
+ // AI Prompt Types
1039
+ this.availablePromptTypes = [];
1040
+ this.isLoadingPromptTypes = false;
1041
+ // Result Selector Tree Data
1042
+ this.resultSelectorTreeData = [];
1043
+ this.isLoadingResultSelectorData = false;
1044
+ this._metadata = new Metadata();
1045
+ this.__InferenceProvider_VendorTypeDefinitionID = '';
1046
+ }
1047
+ // Template editor configuration
1048
+ get templateEditorConfig() {
1049
+ return {
1050
+ allowEdit: this.EditMode,
1051
+ showRunButton: false,
1052
+ compactMode: false
1053
+ };
1054
+ }
1055
+ ngOnInit() {
1056
+ const _super = Object.create(null, {
1057
+ ngOnInit: { get: () => super.ngOnInit }
1058
+ });
1059
+ return __awaiter(this, void 0, void 0, function* () {
1060
+ var _a, _b;
1061
+ yield _super.ngOnInit.call(this);
1062
+ // make sure AI Engine Base is configured, this will load stuff only if not already
1063
+ // loaded in the current process space
1064
+ yield AIEngineBase.Instance.Config(false, this._metadata.CurrentUser);
1065
+ this.__InferenceProvider_VendorTypeDefinitionID = ((_a = AIEngineBase.Instance.VendorTypeDefinitions.find(vtd => vtd.Name.trim().toLowerCase() === 'inference provider')) === null || _a === void 0 ? void 0 : _a.ID) || '';
1066
+ if (!this.__InferenceProvider_VendorTypeDefinitionID) {
1067
+ console.error('Inference Provider Vendor Type Definition ID not found');
1068
+ MJNotificationService.Instance.CreateSimpleNotification('Inference Provider Vendor Type Definition not found', 'error', 5000);
1069
+ return;
1070
+ }
1071
+ // Load template when record changes
1072
+ if ((_b = this.record) === null || _b === void 0 ? void 0 : _b.TemplateID) {
1073
+ this.loadTemplate();
1074
+ }
1075
+ // Load available models, vendors, prompt types, prompt models, and result selector data
1076
+ yield Promise.all([
1077
+ this.loadAvailableModels(),
1078
+ this.loadAvailableVendors(),
1079
+ this.loadAvailablePromptTypes(),
1080
+ this.loadPromptModels(),
1081
+ this.loadResultSelectorTreeData()
1082
+ ]);
1083
+ // Set defaults for new records
1084
+ if (!this.record.IsSaved) {
1085
+ // Default to first prompt type if not set
1086
+ if (!this.record.TypeID && this.availablePromptTypes.length > 0) {
1087
+ this.record.TypeID = this.availablePromptTypes[0].ID;
1088
+ }
1089
+ // Default status to Pending if not set
1090
+ if (!this.record.Status) {
1091
+ this.record.Status = 'Pending';
1092
+ }
1093
+ }
1094
+ });
1095
+ }
1096
+ /**
1097
+ * Loads the template associated with this AI prompt
1098
+ */
1099
+ loadTemplate() {
1100
+ return __awaiter(this, void 0, void 0, function* () {
1101
+ var _a;
1102
+ if (!((_a = this.record) === null || _a === void 0 ? void 0 : _a.TemplateID)) {
1103
+ this.template = null;
1104
+ return;
1105
+ }
1106
+ this.isLoadingTemplate = true;
1107
+ try {
1108
+ this.template = yield this._metadata.GetEntityObject('Templates');
1109
+ yield this.template.Load(this.record.TemplateID);
1110
+ if (!this.template.IsSaved) {
1111
+ this.template = null;
1112
+ console.warn(`Template with ID ${this.record.TemplateID} not found`);
1113
+ }
1114
+ }
1115
+ catch (error) {
1116
+ console.error('Error loading template:', error);
1117
+ this.template = null;
1118
+ MJNotificationService.Instance.CreateSimpleNotification('Error loading associated template', 'error', 5000);
1119
+ }
1120
+ finally {
1121
+ this.isLoadingTemplate = false;
1122
+ }
1123
+ });
1124
+ }
1125
+ /**
1126
+ * Handles template ID changes in the form
1127
+ */
1128
+ onTemplateIdChange() {
1129
+ return __awaiter(this, void 0, void 0, function* () {
1130
+ var _a;
1131
+ if ((_a = this.record) === null || _a === void 0 ? void 0 : _a.TemplateID) {
1132
+ yield this.loadTemplate();
1133
+ }
1134
+ else {
1135
+ this.template = null;
1136
+ }
1137
+ });
1138
+ }
1139
+ /**
1140
+ * Opens a dialog to link an existing template
1141
+ */
1142
+ linkExistingTemplate() {
1143
+ return __awaiter(this, void 0, void 0, function* () {
1144
+ // TODO: Implement template selection dialog
1145
+ MJNotificationService.Instance.CreateSimpleNotification('Template linking functionality coming soon', 'info', 3000);
1146
+ });
1147
+ }
1148
+ /**
1149
+ * Opens the current template in a new window
1150
+ */
1151
+ openTemplateInNewWindow() {
1152
+ var _a;
1153
+ if (!((_a = this.template) === null || _a === void 0 ? void 0 : _a.ID))
1154
+ return;
1155
+ // TODO: Get the proper URL for template editing
1156
+ const templateUrl = `/templates/${this.template.ID}`;
1157
+ window.open(templateUrl, '_blank');
1158
+ }
1159
+ /**
1160
+ * Creates a new template for this AI prompt
1161
+ */
1162
+ createNewTemplate() {
1163
+ return __awaiter(this, void 0, void 0, function* () {
1164
+ var _a, _b;
1165
+ try {
1166
+ const newTemplate = yield this._metadata.GetEntityObject('Templates');
1167
+ newTemplate.NewRecord();
1168
+ newTemplate.Name = `${this.record.Name || 'AI Prompt'} Template`;
1169
+ newTemplate.Description = `Template for AI Prompt: ${this.record.Name}`;
1170
+ newTemplate.UserID = this._metadata.CurrentUser.ID;
1171
+ const saveResult = yield newTemplate.Save();
1172
+ if (!saveResult) {
1173
+ const errorMessage = ((_a = newTemplate.LatestResult) === null || _a === void 0 ? void 0 : _a.Message) || ((_b = newTemplate.LatestResult) === null || _b === void 0 ? void 0 : _b.Errors) || 'Unknown error';
1174
+ console.error('Template save failed:', errorMessage);
1175
+ throw new Error(`Failed to save new template: ${errorMessage}`);
1176
+ }
1177
+ // Update the AI prompt to reference the new template
1178
+ this.record.TemplateID = newTemplate.ID;
1179
+ // Load the new template
1180
+ yield this.loadTemplate();
1181
+ MJNotificationService.Instance.CreateSimpleNotification('New template created and linked successfully', 'success', 4000);
1182
+ }
1183
+ catch (error) {
1184
+ console.error('Error creating new template:', error);
1185
+ const errorMessage = error instanceof Error ? error.message : 'Unknown error';
1186
+ MJNotificationService.Instance.CreateSimpleNotification(`Error creating new template: ${errorMessage}`, 'error', 6000);
1187
+ }
1188
+ });
1189
+ }
1190
+ /**
1191
+ * Opens the AI prompt execution dialog
1192
+ */
1193
+ executeAIPrompt() {
1194
+ var _a;
1195
+ if (!((_a = this.record) === null || _a === void 0 ? void 0 : _a.ID)) {
1196
+ MJNotificationService.Instance.CreateSimpleNotification('Please save the AI prompt before executing', 'warning', 4000);
1197
+ return;
1198
+ }
1199
+ if (this.record.Status !== 'Active') {
1200
+ MJNotificationService.Instance.CreateSimpleNotification('AI prompt must be Active to execute', 'warning', 4000);
1201
+ return;
1202
+ }
1203
+ this.showExecutionDialog = true;
1204
+ }
1205
+ /**
1206
+ * Handles template content changes from the editor
1207
+ */
1208
+ onTemplateContentChange(content) {
1209
+ // Handle template content changes if needed
1210
+ console.log('Template content changed:', content);
1211
+ }
1212
+ /**
1213
+ * Handles template run requests from the editor
1214
+ */
1215
+ onTemplateRun(template) {
1216
+ console.log('Template run requested:', template);
1217
+ // Could open the template parameter dialog here if needed
1218
+ MJNotificationService.Instance.CreateSimpleNotification('Template run functionality coming soon', 'info', 3000);
1219
+ }
1220
+ /**
1221
+ * Gets the display text for parallelization mode
1222
+ */
1223
+ getParallelizationModeDisplay() {
1224
+ var _a;
1225
+ switch ((_a = this.record) === null || _a === void 0 ? void 0 : _a.ParallelizationMode) {
1226
+ case 'None': return 'None';
1227
+ case 'StaticCount': return `Static count (${this.record.ParallelCount || 1})`;
1228
+ case 'ConfigParam': return `Config parameter (${this.record.ParallelConfigParam || 'not set'})`;
1229
+ case 'ModelSpecific': return 'Model-specific configuration';
1230
+ default: return 'Unknown';
1231
+ }
1232
+ }
1233
+ /**
1234
+ * Gets the display text for output type
1235
+ */
1236
+ getOutputTypeDisplay() {
1237
+ var _a, _b;
1238
+ const type = ((_a = this.record) === null || _a === void 0 ? void 0 : _a.OutputType) || 'string';
1239
+ const validationBehavior = ((_b = this.record) === null || _b === void 0 ? void 0 : _b.ValidationBehavior) || 'Warn';
1240
+ if (validationBehavior === 'None') {
1241
+ return type;
1242
+ }
1243
+ else {
1244
+ return `${type} (${validationBehavior})`;
1245
+ }
1246
+ }
1247
+ /**
1248
+ * Gets the color for validation behavior display
1249
+ */
1250
+ getValidationColor() {
1251
+ var _a;
1252
+ switch ((_a = this.record) === null || _a === void 0 ? void 0 : _a.ValidationBehavior) {
1253
+ case 'Strict': return '#dc3545'; // red
1254
+ case 'Warn': return '#ffc107'; // yellow
1255
+ default: return '#6c757d'; // default gray
1256
+ }
1257
+ }
1258
+ /**
1259
+ * Checks if ParallelCount field should be visible
1260
+ */
1261
+ get showParallelCount() {
1262
+ var _a;
1263
+ return ((_a = this.record) === null || _a === void 0 ? void 0 : _a.ParallelizationMode) === 'StaticCount';
1264
+ }
1265
+ /**
1266
+ * Checks if ParallelConfigParam field should be visible
1267
+ */
1268
+ get showParallelConfigParam() {
1269
+ var _a;
1270
+ return ((_a = this.record) === null || _a === void 0 ? void 0 : _a.ParallelizationMode) === 'ConfigParam';
1271
+ }
1272
+ /**
1273
+ * Checks if OutputExample field should be visible
1274
+ */
1275
+ get showOutputExample() {
1276
+ var _a;
1277
+ return ((_a = this.record) === null || _a === void 0 ? void 0 : _a.OutputType) === 'object';
1278
+ }
1279
+ /**
1280
+ * Checks if the AI prompt can be executed
1281
+ */
1282
+ get canExecute() {
1283
+ var _a;
1284
+ return !!(((_a = this.record) === null || _a === void 0 ? void 0 : _a.ID) &&
1285
+ this.record.Status === 'Active' &&
1286
+ this.record.TemplateID &&
1287
+ this.template);
1288
+ }
1289
+ /**
1290
+ * Gets status badge color
1291
+ */
1292
+ getStatusBadgeColor() {
1293
+ var _a;
1294
+ switch ((_a = this.record) === null || _a === void 0 ? void 0 : _a.Status) {
1295
+ case 'Active': return '#28a745';
1296
+ case 'Pending': return '#ffc107';
1297
+ case 'Disabled': return '#6c757d';
1298
+ default: return '#6c757d';
1299
+ }
1300
+ }
1301
+ /**
1302
+ * Loads available AI models for selection
1303
+ */
1304
+ loadAvailableModels() {
1305
+ return __awaiter(this, void 0, void 0, function* () {
1306
+ try {
1307
+ const rv = new RunView();
1308
+ const results = yield rv.RunView({
1309
+ EntityName: 'AI Models',
1310
+ OrderBy: 'Name ASC',
1311
+ ResultType: 'entity_object'
1312
+ });
1313
+ this.availableModels = results.Results;
1314
+ }
1315
+ catch (error) {
1316
+ console.error('Error loading available models:', error);
1317
+ }
1318
+ });
1319
+ }
1320
+ /**
1321
+ * Loads available AI vendors for selection
1322
+ */
1323
+ loadAvailableVendors() {
1324
+ return __awaiter(this, void 0, void 0, function* () {
1325
+ try {
1326
+ const rv = new RunView();
1327
+ const results = yield rv.RunView({
1328
+ EntityName: 'MJ: AI Vendors',
1329
+ OrderBy: 'Name ASC',
1330
+ ResultType: 'entity_object'
1331
+ });
1332
+ this.availableVendors = results.Results;
1333
+ }
1334
+ catch (error) {
1335
+ console.error('Error loading available vendors:', error);
1336
+ }
1337
+ });
1338
+ }
1339
+ /**
1340
+ * Loads available AI prompt types for selection
1341
+ */
1342
+ loadAvailablePromptTypes() {
1343
+ return __awaiter(this, void 0, void 0, function* () {
1344
+ this.isLoadingPromptTypes = true;
1345
+ try {
1346
+ const rv = new RunView();
1347
+ const results = yield rv.RunView({
1348
+ EntityName: 'AI Prompt Types',
1349
+ OrderBy: '__mj_CreatedAt ASC',
1350
+ ResultType: 'entity_object'
1351
+ });
1352
+ this.availablePromptTypes = results.Results;
1353
+ }
1354
+ catch (error) {
1355
+ console.error('Error loading available prompt types:', error);
1356
+ }
1357
+ finally {
1358
+ this.isLoadingPromptTypes = false;
1359
+ }
1360
+ });
1361
+ }
1362
+ /**
1363
+ * Loads vendors available for a specific model
1364
+ */
1365
+ loadVendorsForModel(modelId) {
1366
+ return __awaiter(this, void 0, void 0, function* () {
1367
+ if (!modelId) {
1368
+ return { vendors: [], modelVendors: [] };
1369
+ }
1370
+ // Check cache first
1371
+ if (this.modelVendorsMap.has(modelId)) {
1372
+ return this.modelVendorsMap.get(modelId);
1373
+ }
1374
+ try {
1375
+ // Load model vendors for this model, filtering by TypeID for inference providers only
1376
+ const rv = new RunView();
1377
+ const modelVendorsResult = yield rv.RunView({
1378
+ EntityName: 'MJ: AI Model Vendors',
1379
+ ExtraFilter: `ModelID='${modelId}' AND TypeID='${this.__InferenceProvider_VendorTypeDefinitionID}'`,
1380
+ OrderBy: 'VendorID ASC',
1381
+ ResultType: 'entity_object'
1382
+ });
1383
+ const modelVendors = modelVendorsResult.Results || [];
1384
+ // Get unique vendor IDs
1385
+ const vendorIds = [...new Set(modelVendors.map(mv => mv.VendorID))];
1386
+ // Load vendor details
1387
+ const vendors = [];
1388
+ if (vendorIds.length > 0) {
1389
+ const vendorFilter = vendorIds.map(id => `ID='${id}'`).join(' OR ');
1390
+ const vendorsResult = yield rv.RunView({
1391
+ EntityName: 'MJ: AI Vendors',
1392
+ ExtraFilter: vendorFilter,
1393
+ OrderBy: 'Name ASC',
1394
+ ResultType: 'entity_object'
1395
+ });
1396
+ vendors.push(...(vendorsResult.Results || []));
1397
+ }
1398
+ const result = { vendors, modelVendors };
1399
+ this.modelVendorsMap.set(modelId, result);
1400
+ return result;
1401
+ }
1402
+ catch (error) {
1403
+ console.error('Error loading vendors for model:', error);
1404
+ return { vendors: [], modelVendors: [] };
1405
+ }
1406
+ });
1407
+ }
1408
+ /**
1409
+ * Gets vendors for a specific model from cache or loads them
1410
+ */
1411
+ getVendorsForModel(modelId) {
1412
+ return __awaiter(this, void 0, void 0, function* () {
1413
+ const result = yield this.loadVendorsForModel(modelId);
1414
+ return result.vendors;
1415
+ });
1416
+ }
1417
+ /**
1418
+ * Gets the status for a model-vendor combination
1419
+ */
1420
+ getModelVendorStatus(modelId, vendorId) {
1421
+ const modelVendorData = this.modelVendorsMap.get(modelId);
1422
+ if (!modelVendorData)
1423
+ return 'Unknown';
1424
+ const modelVendor = modelVendorData.modelVendors.find(mv => mv.VendorID === vendorId);
1425
+ return (modelVendor === null || modelVendor === void 0 ? void 0 : modelVendor.Status) || 'Unknown';
1426
+ }
1427
+ /**
1428
+ * Gets the color for vendor status display
1429
+ */
1430
+ getVendorStatusColor(modelId, vendorId) {
1431
+ const status = this.getModelVendorStatus(modelId, vendorId);
1432
+ switch (status) {
1433
+ case 'Active': return '#28a745'; // green
1434
+ case 'Inactive': return '#dc3545'; // red
1435
+ case 'Pending': return '#ffc107'; // yellow
1436
+ default: return '#6c757d'; // gray
1437
+ }
1438
+ }
1439
+ /**
1440
+ * Handles model selection change and loads vendors for that model
1441
+ */
1442
+ onModelChange(modelId, promptModelIndex) {
1443
+ return __awaiter(this, void 0, void 0, function* () {
1444
+ const promptModel = this.promptModels[promptModelIndex];
1445
+ if (!promptModel)
1446
+ return;
1447
+ // Clear the vendor selection when model changes
1448
+ promptModel.VendorID = null;
1449
+ // Load vendors for the new model
1450
+ if (modelId) {
1451
+ const vendorData = yield this.loadVendorsForModel(modelId);
1452
+ // Auto-select first vendor if available
1453
+ if (vendorData.vendors.length > 0) {
1454
+ promptModel.VendorID = vendorData.vendors[0].ID;
1455
+ }
1456
+ }
1457
+ });
1458
+ }
1459
+ /**
1460
+ * Gets vendors for a specific model
1461
+ */
1462
+ getVendorsForModelSync(modelId) {
1463
+ const modelVendorData = this.modelVendorsMap.get(modelId);
1464
+ return (modelVendorData === null || modelVendorData === void 0 ? void 0 : modelVendorData.vendors) || [];
1465
+ }
1466
+ /**
1467
+ * Checks if vendor dropdown should be shown (more than one vendor)
1468
+ */
1469
+ shouldShowVendorDropdown(modelId) {
1470
+ if (!modelId)
1471
+ return false;
1472
+ const vendors = this.getVendorsForModelSync(modelId);
1473
+ return vendors.length > 1;
1474
+ }
1475
+ /**
1476
+ * Loads prompt models for this AI prompt
1477
+ */
1478
+ loadPromptModels() {
1479
+ return __awaiter(this, void 0, void 0, function* () {
1480
+ var _a;
1481
+ if (!((_a = this.record) === null || _a === void 0 ? void 0 : _a.ID)) {
1482
+ this.promptModels = [];
1483
+ return;
1484
+ }
1485
+ this.isLoadingModels = true;
1486
+ try {
1487
+ const rv = new RunView();
1488
+ const results = yield rv.RunView({
1489
+ EntityName: 'MJ: AI Prompt Models',
1490
+ ExtraFilter: `PromptID='${this.record.ID}'`,
1491
+ OrderBy: 'Priority ASC, __mj_CreatedAt ASC',
1492
+ ResultType: 'entity_object'
1493
+ });
1494
+ this.promptModels = results.Results;
1495
+ // Load vendors for existing models
1496
+ const modelIds = this.promptModels
1497
+ .map(pm => pm.ModelID)
1498
+ .filter(id => id); // Filter out null/undefined
1499
+ yield Promise.all(modelIds.map(modelId => this.loadVendorsForModel(modelId)));
1500
+ }
1501
+ catch (error) {
1502
+ console.error('Error loading prompt models:', error);
1503
+ }
1504
+ finally {
1505
+ this.isLoadingModels = false;
1506
+ }
1507
+ });
1508
+ }
1509
+ /**
1510
+ * Adds a new model to the prompt
1511
+ */
1512
+ addNewModel() {
1513
+ return __awaiter(this, void 0, void 0, function* () {
1514
+ var _a;
1515
+ if (!((_a = this.record) === null || _a === void 0 ? void 0 : _a.ID))
1516
+ return;
1517
+ try {
1518
+ const newModel = yield this._metadata.GetEntityObject('MJ: AI Prompt Models');
1519
+ newModel.PromptID = this.record.ID;
1520
+ // Set priority to highest existing priority + 1
1521
+ const maxPriority = this.promptModels.length > 0
1522
+ ? Math.max(...this.promptModels.map(pm => pm.Priority || 0))
1523
+ : 0;
1524
+ newModel.Priority = maxPriority + 1;
1525
+ // ModelID will be set by user
1526
+ this.promptModels.push(newModel);
1527
+ }
1528
+ catch (error) {
1529
+ console.error('Error creating new model:', error);
1530
+ MJNotificationService.Instance.CreateSimpleNotification('Error creating new model', 'error', 5000);
1531
+ }
1532
+ });
1533
+ }
1534
+ /**
1535
+ * Removes a model from the prompt
1536
+ */
1537
+ removePromptModel(index) {
1538
+ return __awaiter(this, void 0, void 0, function* () {
1539
+ if (index < 0 || index >= this.promptModels.length)
1540
+ return;
1541
+ const model = this.promptModels[index];
1542
+ try {
1543
+ // If it's a saved model, delete it from the database
1544
+ if (model.IsSaved) {
1545
+ const deleteResult = yield model.Delete();
1546
+ if (!deleteResult) {
1547
+ throw new Error('Failed to delete model from database');
1548
+ }
1549
+ }
1550
+ // Remove from local array
1551
+ this.promptModels.splice(index, 1);
1552
+ MJNotificationService.Instance.CreateSimpleNotification('Model removed successfully', 'success', 3000);
1553
+ }
1554
+ catch (error) {
1555
+ console.error('Error removing model:', error);
1556
+ MJNotificationService.Instance.CreateSimpleNotification('Error removing model', 'error', 5000);
1557
+ }
1558
+ });
1559
+ }
1560
+ /**
1561
+ * Gets the display name for a model ID
1562
+ */
1563
+ getModelDisplayName(modelId) {
1564
+ if (!modelId)
1565
+ return '';
1566
+ const model = this.availableModels.find(m => m.ID === modelId);
1567
+ return model ? model.Name : modelId;
1568
+ }
1569
+ /**
1570
+ * Gets the display name for a vendor ID
1571
+ */
1572
+ getVendorDisplayName(vendorId) {
1573
+ if (!vendorId)
1574
+ return '';
1575
+ const vendor = this.availableVendors.find(v => v.ID === vendorId);
1576
+ return vendor ? vendor.Name : vendorId;
1577
+ }
1578
+ /**
1579
+ * Gets the display name for a prompt type ID
1580
+ */
1581
+ getPromptTypeDisplayName(typeId) {
1582
+ if (!typeId)
1583
+ return '';
1584
+ const type = this.availablePromptTypes.find(t => t.ID === typeId);
1585
+ return type ? type.Name : typeId;
1586
+ }
1587
+ /**
1588
+ * Override SaveRecord to auto-save template contents and prompt models
1589
+ */
1590
+ SaveRecord() {
1591
+ const _super = Object.create(null, {
1592
+ SaveRecord: { get: () => super.SaveRecord }
1593
+ });
1594
+ return __awaiter(this, arguments, void 0, function* (StopEditModeAfterSave = true) {
1595
+ try {
1596
+ // If this is a new prompt with a new template, we need to save the template first
1597
+ if (!this.record.IsSaved && this.template && !this.template.IsSaved) {
1598
+ const templateSaved = yield this.template.Save();
1599
+ if (!templateSaved) {
1600
+ MJNotificationService.Instance.CreateSimpleNotification('Failed to save template', 'error', 5000);
1601
+ return false;
1602
+ }
1603
+ // Set the template ID on the AI prompt before saving
1604
+ this.record.TemplateID = this.template.ID;
1605
+ }
1606
+ // Save the AI prompt itself
1607
+ const promptSaved = yield _super.SaveRecord.call(this, StopEditModeAfterSave);
1608
+ if (promptSaved) {
1609
+ // Save template contents if we have a template
1610
+ if (this.template && this.templateEditor) {
1611
+ const templateContentsSaved = yield this.templateEditor.saveTemplateContents();
1612
+ if (!templateContentsSaved) {
1613
+ MJNotificationService.Instance.CreateSimpleNotification('AI prompt saved, but template contents failed to save', 'warning', 5000);
1614
+ }
1615
+ }
1616
+ // Then save all prompt models
1617
+ return yield this.savePromptModels();
1618
+ }
1619
+ return false;
1620
+ }
1621
+ catch (error) {
1622
+ console.error('Error in SaveRecord:', error);
1623
+ MJNotificationService.Instance.CreateSimpleNotification('Error saving AI prompt', 'error', 5000);
1624
+ return false;
1625
+ }
1626
+ });
1627
+ }
1628
+ /**
1629
+ * Saves all prompt models (creates, updates, deletes)
1630
+ */
1631
+ savePromptModels() {
1632
+ return __awaiter(this, void 0, void 0, function* () {
1633
+ try {
1634
+ let allSuccessful = true;
1635
+ // Save each prompt model
1636
+ for (const model of this.promptModels) {
1637
+ if (model.ModelID) { // Only save if a model is selected
1638
+ // Set the PromptID if it's not already set
1639
+ if (!model.PromptID) {
1640
+ model.PromptID = this.record.ID;
1641
+ }
1642
+ const saved = yield model.Save();
1643
+ if (!saved) {
1644
+ console.error('Failed to save prompt model:', model);
1645
+ allSuccessful = false;
1646
+ }
1647
+ }
1648
+ }
1649
+ if (allSuccessful) {
1650
+ // Reload the prompt models to get the updated state
1651
+ yield this.loadPromptModels();
1652
+ MJNotificationService.Instance.CreateSimpleNotification('AI prompt and models saved successfully', 'success', 4000);
1653
+ }
1654
+ else {
1655
+ MJNotificationService.Instance.CreateSimpleNotification('AI prompt saved, but some models failed to save', 'warning', 5000);
1656
+ }
1657
+ return allSuccessful;
1658
+ }
1659
+ catch (error) {
1660
+ console.error('Error saving prompt models:', error);
1661
+ MJNotificationService.Instance.CreateSimpleNotification('Error saving prompt models', 'error', 5000);
1662
+ return false;
1663
+ }
1664
+ });
1665
+ }
1666
+ /**
1667
+ * Loads the result selector tree data (categories and prompts)
1668
+ */
1669
+ loadResultSelectorTreeData() {
1670
+ return __awaiter(this, void 0, void 0, function* () {
1671
+ this.isLoadingResultSelectorData = true;
1672
+ try {
1673
+ // Load categories and prompts
1674
+ const [categoriesResult, promptsResult] = yield Promise.all([
1675
+ new RunView().RunView({
1676
+ EntityName: 'AI Prompt Categories',
1677
+ OrderBy: 'Name ASC',
1678
+ ResultType: 'entity_object'
1679
+ }),
1680
+ new RunView().RunView({
1681
+ EntityName: 'AI Prompts',
1682
+ ExtraFilter: 'Status=\'Active\'',
1683
+ OrderBy: 'Name ASC',
1684
+ ResultType: 'entity_object'
1685
+ })
1686
+ ]);
1687
+ const categories = categoriesResult.Results || [];
1688
+ const prompts = promptsResult.Results || [];
1689
+ // Build tree structure
1690
+ this.resultSelectorTreeData = this.buildResultSelectorTree(categories, prompts);
1691
+ }
1692
+ catch (error) {
1693
+ console.error('Error loading result selector tree data:', error);
1694
+ this.resultSelectorTreeData = [];
1695
+ }
1696
+ finally {
1697
+ this.isLoadingResultSelectorData = false;
1698
+ }
1699
+ });
1700
+ }
1701
+ /**
1702
+ * Builds the tree structure for result selector
1703
+ */
1704
+ buildResultSelectorTree(categories, prompts) {
1705
+ const tree = [];
1706
+ // Add "Clear Selection" option at the top
1707
+ tree.push({
1708
+ text: '(Clear Selection)',
1709
+ value: null,
1710
+ hasChildren: false,
1711
+ isCategory: false,
1712
+ isClearOption: true
1713
+ });
1714
+ // Create category nodes
1715
+ const categoryMap = new Map();
1716
+ categories.forEach(category => {
1717
+ const node = {
1718
+ text: category.Name,
1719
+ value: null, // Categories don't have values
1720
+ expanded: true,
1721
+ hasChildren: true,
1722
+ items: [],
1723
+ isCategory: true,
1724
+ categoryId: category.ID
1725
+ };
1726
+ categoryMap.set(category.ID, node);
1727
+ // Handle parent-child relationships
1728
+ if (category.ParentID) {
1729
+ const parentNode = categoryMap.get(category.ParentID);
1730
+ if (parentNode) {
1731
+ parentNode.items.push(node);
1732
+ }
1733
+ else {
1734
+ tree.push(node); // Parent not found, add to root
1735
+ }
1736
+ }
1737
+ else {
1738
+ tree.push(node); // Root category
1739
+ }
1740
+ });
1741
+ // Collect uncategorized prompts
1742
+ const uncategorizedPrompts = [];
1743
+ // Add prompts to their categories
1744
+ prompts.forEach(prompt => {
1745
+ const promptNode = {
1746
+ text: prompt.Name,
1747
+ value: prompt.ID,
1748
+ hasChildren: false,
1749
+ isCategory: false,
1750
+ promptId: prompt.ID
1751
+ };
1752
+ if (prompt.CategoryID) {
1753
+ const categoryNode = categoryMap.get(prompt.CategoryID);
1754
+ if (categoryNode) {
1755
+ categoryNode.items.push(promptNode);
1756
+ }
1757
+ else {
1758
+ // Category not found, add to uncategorized
1759
+ uncategorizedPrompts.push(promptNode);
1760
+ }
1761
+ }
1762
+ else {
1763
+ // No category, add to uncategorized
1764
+ uncategorizedPrompts.push(promptNode);
1765
+ }
1766
+ });
1767
+ // If there are uncategorized prompts, add them to a special section
1768
+ if (uncategorizedPrompts.length > 0) {
1769
+ tree.push({
1770
+ text: 'Uncategorized',
1771
+ value: null,
1772
+ expanded: true,
1773
+ hasChildren: true,
1774
+ items: uncategorizedPrompts,
1775
+ isCategory: true,
1776
+ categoryId: 'uncategorized'
1777
+ });
1778
+ }
1779
+ return tree;
1780
+ }
1781
+ /**
1782
+ * Handles result selector selection
1783
+ */
1784
+ onResultSelectorChange(value) {
1785
+ this.record.ResultSelectorPromptID = value || null;
1786
+ }
1787
+ /**
1788
+ * Gets the display name for a prompt ID from the tree data
1789
+ */
1790
+ getPromptDisplayName(promptId) {
1791
+ if (!promptId)
1792
+ return '';
1793
+ const findPromptInTree = (nodes) => {
1794
+ for (const node of nodes) {
1795
+ if (!node.isCategory && node.value === promptId) {
1796
+ return node.text;
1797
+ }
1798
+ if (node.items && node.items.length > 0) {
1799
+ const found = findPromptInTree(node.items);
1800
+ if (found)
1801
+ return found;
1802
+ }
1803
+ }
1804
+ return '';
1805
+ };
1806
+ return findPromptInTree(this.resultSelectorTreeData);
1807
+ }
1808
+ /**
1809
+ * Moves a model up in the list
1810
+ */
1811
+ moveModelUp(index) {
1812
+ if (index > 0 && index < this.promptModels.length) {
1813
+ const model = this.promptModels[index];
1814
+ this.promptModels.splice(index, 1);
1815
+ this.promptModels.splice(index - 1, 0, model);
1816
+ this.updateModelPriorities();
1817
+ }
1818
+ }
1819
+ /**
1820
+ * Moves a model down in the list
1821
+ */
1822
+ moveModelDown(index) {
1823
+ if (index >= 0 && index < this.promptModels.length - 1) {
1824
+ const model = this.promptModels[index];
1825
+ this.promptModels.splice(index, 1);
1826
+ this.promptModels.splice(index + 1, 0, model);
1827
+ this.updateModelPriorities();
1828
+ }
1829
+ }
1830
+ /**
1831
+ * Updates priority values based on array order
1832
+ */
1833
+ updateModelPriorities() {
1834
+ this.promptModels.forEach((model, index) => {
1835
+ model.Priority = index + 1;
1836
+ });
1837
+ }
1838
+ };
1839
+ AIPromptFormComponentExtended.ɵfac = /*@__PURE__*/ (() => { let ɵAIPromptFormComponentExtended_BaseFactory; return function AIPromptFormComponentExtended_Factory(t) { return (ɵAIPromptFormComponentExtended_BaseFactory || (ɵAIPromptFormComponentExtended_BaseFactory = i0.ɵɵgetInheritedFactory(AIPromptFormComponentExtended)))(t || AIPromptFormComponentExtended); }; })();
1840
+ AIPromptFormComponentExtended.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: AIPromptFormComponentExtended, selectors: [["mj-ai-prompt-form"]], viewQuery: function AIPromptFormComponentExtended_Query(rf, ctx) { if (rf & 1) {
1841
+ i0.ɵɵviewQuery(_c0, 5);
1842
+ } if (rf & 2) {
1843
+ let _t;
1844
+ i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.templateEditor = _t.first);
1845
+ } }, features: [i0.ɵɵInheritDefinitionFeature], decls: 3, vars: 5, consts: [["form", "ngForm"], ["templateEditor", ""], ["mjFillContainer", "", 1, "record-form-container", 3, "bottomMargin", "rightMargin"], ["class", "record-form", "mjFillContainer", "", 4, "ngIf"], [3, "isVisibleChange", "aiPrompt", "isVisible"], ["mjFillContainer", "", 1, "record-form"], [3, "form"], [1, "prompt-main-area", 2, "display", "flex", "flex-direction", "column", "height", "100%", "overflow-y", "auto"], [1, "prompt-header", 2, "flex-shrink", "0", "padding", "20px", "background", "#f8f9fa", "border-bottom", "2px solid #e9ecef"], [2, "display", "flex", "justify-content", "space-between", "align-items", "flex-start", "gap", "20px"], [2, "flex", "1", "min-width", "0"], [2, "display", "flex", "align-items", "center", "gap", "12px", "margin-bottom", "8px"], [1, "fa-solid", "fa-robot", 2, "color", "#6f42c1", "font-size", "1.4em"], ["name", "promptName", "placeholder", "Enter prompt name...", 2, "font-size", "1.2em", "font-weight", "600", "min-width", "300px", "flex", "1", 3, "ngModel"], [2, "display", "flex", "gap", "16px", "margin-bottom", "12px", "flex-wrap", "wrap"], ["name", "promptDescription", "placeholder", "Enter prompt description...", 2, "width", "100%", "max-width", "600px", "margin-bottom", "12px", 3, "ngModel", "rows"], [2, "margin", "0 0 12px 0", "color", "#6c757d", "font-size", "0.9em", "line-height", "1.4"], [1, "quick-config", 2, "display", "flex", "align-items", "center", "gap", "16px", "flex-wrap", "wrap"], [1, "config-item", 2, "display", "flex", "align-items", "center", "gap", "6px", "font-size", "0.85em"], [1, "fa-solid", "fa-layer-group", 2, "color", "#6c757d"], [2, "color", "#6c757d"], [2, "color", "#495057", "font-weight", "500"], [1, "fa-solid", "fa-code", 2, "color", "#6c757d"], [2, "font-weight", "500"], [1, "action-buttons", 2, "display", "flex", "flex-direction", "column", "gap", "8px", "align-items", "flex-end"], [2, "display", "flex", "gap", "8px"], ["themeColor", "primary", "size", "large", "title", "Execute this AI prompt"], ["themeColor", "primary", "size", "large", "title", "Prompt must be Active and have a Template to execute", 3, "disabled"], ["fillMode", "outline", "themeColor", "info", "title", "View execution history"], [2, "font-size", "0.75em", "color", "#dc3545", "text-align", "right", "max-width", "200px"], [1, "configuration-sections", 2, "flex", "1", "background", "white", "border-top", "2px solid #e9ecef", "padding", "16px", "min-height", "0"], [2, "margin-bottom", "12px", 3, "expanded"], ["kendoExpansionPanelTitleDirective", ""], [1, "template-section", 2, "display", "flex", "flex-direction", "column", "min-height", "400px", "padding", "8px"], [1, "loading-state", 2, "flex", "1", "display", "flex", "align-items", "center", "justify-content", "center", "color", "#6c757d"], [1, "no-template-state", 2, "flex", "1", "display", "flex", "flex-direction", "column", "align-items", "center", "justify-content", "center", "padding", "40px", "color", "#6c757d"], [1, "invalid-template-state", 2, "flex", "1", "display", "flex", "flex-direction", "column", "align-items", "center", "justify-content", "center", "padding", "40px", "color", "#dc3545"], [1, "template-editor-container", 2, "flex", "1", "display", "flex", "flex-direction", "column", "min-height", "350px"], [2, "padding", "16px 0"], [2, "display", "grid", "grid-template-columns", "1fr 1fr", "gap", "20px"], ["FieldName", "ParallelizationMode", "Type", "dropdownlist", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "ParallelCount", "Type", "numerictextbox", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "ParallelConfigParam", "Type", "textbox", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "OutputType", "Type", "dropdownlist", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "ValidationBehavior", "Type", "dropdownlist", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "EnableCaching", "Type", "checkbox", 3, "record", "ShowLabel", "EditMode"], [2, "margin-bottom", "16px"], [2, "display", "block", "margin-bottom", "4px", "font-weight", "600", "color", "#495057", "font-size", "0.9em"], [2, "color", "#495057"], ["name", "promptName", "placeholder", "Enter prompt name...", 2, "font-size", "1.2em", "font-weight", "600", "min-width", "300px", "flex", "1", 3, "ngModelChange", "ngModel"], [2, "margin", "0", "color", "#495057", "font-weight", "600", "flex", "1"], [1, "status-badge", 2, "color", "white", "padding", "4px 10px", "border-radius", "12px", "font-size", "0.75em", "font-weight", "500"], ["name", "promptStatus", "textField", "text", "valueField", "value", 2, "width", "150px", 3, "ngModelChange", "ngModel", "data", "valuePrimitive"], [2, "color", "#dc3545"], [2, "padding", "8px", "color", "#6c757d", "font-style", "italic", "width", "200px"], ["name", "promptTypeID", "textField", "Name", "valueField", "ID", "placeholder", "Select prompt type...", 2, "width", "200px", 3, "ngModel", "data", "valuePrimitive", "filterable"], [1, "fa-solid", "fa-spinner", "fa-spin"], ["name", "promptTypeID", "textField", "Name", "valueField", "ID", "placeholder", "Select prompt type...", 2, "width", "200px", 3, "ngModelChange", "ngModel", "data", "valuePrimitive", "filterable"], ["name", "promptDescription", "placeholder", "Enter prompt description...", 2, "width", "100%", "max-width", "600px", "margin-bottom", "12px", 3, "ngModelChange", "ngModel", "rows"], [1, "fa-solid", "fa-tag", 2, "color", "#6c757d"], [1, "fa-solid", "fa-database", 2, "color", "#28a745"], [2, "color", "#28a745", "font-weight", "500"], ["themeColor", "primary", "size", "large", "title", "Execute this AI prompt", 3, "click"], [1, "fa-solid", "fa-play"], [1, "fa-solid", "fa-exclamation-triangle"], [1, "fa-solid", "fa-history"], [2, "display", "flex", "align-items", "center", "gap", "8px", "font-weight", "600"], [2, "color", "#6c757d", "font-size", "0.9em", "font-weight", "normal"], [1, "fa-solid", "fa-spinner", "fa-spin", 2, "font-size", "24px", "margin-right", "12px"], [1, "fa-solid", "fa-code", 2, "font-size", "64px", "margin-bottom", "20px", "opacity", "0.3"], [2, "margin-bottom", "12px", "color", "#495057"], [2, "margin-bottom", "24px", "text-align", "center", "max-width", "400px"], [2, "display", "flex", "gap", "12px"], ["themeColor", "primary", 3, "click"], [1, "fa-solid", "fa-plus"], ["fillMode", "outline", 3, "click"], [1, "fa-solid", "fa-link"], [1, "fa-solid", "fa-exclamation-triangle", 2, "font-size", "64px", "margin-bottom", "20px", "opacity", "0.7"], [2, "margin-bottom", "12px"], [1, "fa-solid", "fa-refresh"], [2, "flex", "1", "background", "white", "border-radius", "6px", "border", "1px solid #e9ecef"], [2, "display", "block", "min-height", "300px", 3, "contentChange", "runTemplate", "template", "config"], [1, "model-management", 2, "border", "1px solid #dee2e6", "border-radius", "6px", "background", "#f8f9fa"], [1, "loading-state", 2, "padding", "20px", "text-align", "center", "color", "#6c757d"], [1, "fa-solid", "fa-microchip", 2, "color", "#6c757d"], [1, "badge", 2, "background", "#17a2b8", "color", "white", "padding", "2px 6px", "border-radius", "10px", "font-size", "0.7em"], [1, "empty-state", 2, "padding", "20px", "text-align", "center", "color", "#6c757d"], [1, "fa-solid", "fa-info-circle"], [2, "margin-top", "10px"], ["fillMode", "outline", "themeColor", "primary", "size", "small", 3, "click"], [1, "model-header", 2, "display", "grid", "grid-template-columns", "40px 2fr 1fr 1fr 60px", "gap", "12px", "padding", "12px 16px", "background", "#e9ecef", "font-weight", "600", "font-size", "0.85em", "color", "#495057", "border-bottom", "1px solid #dee2e6"], [1, "add-model-row", 2, "padding", "12px 16px", "text-align", "center", "background", "#f8f9fa", "border-top", "1px solid #dee2e6"], [1, "model-row", 2, "display", "grid", "grid-template-columns", "40px 2fr 1fr 1fr 60px", "gap", "12px", "padding", "12px 16px", "border-bottom", "1px solid #e9ecef", "align-items", "start"], [1, "drag-handle", 2, "display", "flex", "align-items", "center", "justify-content", "center", "cursor", "move", "color", "#6c757d"], ["title", "Drag to reorder", 1, "fa-solid", "fa-grip-vertical"], [2, "font-size", "0.8em", "color", "#6c757d"], [1, "model-select"], ["textField", "Name", "valueField", "ID", "placeholder", "Select a model...", 2, "width", "100%", 3, "ngModel", "name", "data", "valuePrimitive", "filterable"], [1, "model-vendor"], [1, "model-created"], [2, "color", "#6c757d", "font-size", "0.8em"], [2, "color", "#28a745", "font-size", "0.8em", "font-style", "italic"], [1, "model-actions", 2, "display", "flex", "gap", "2px", "flex-direction", "column"], [2, "display", "grid", "grid-template-columns", "40px 1fr", "gap", "12px", "padding", "8px 16px", "border-bottom", "1px solid #e9ecef", "background", "#f8f9fa", "font-size", "0.85em", "color", "#6c757d"], [2, "display", "flex", "gap", "16px", "flex-wrap", "wrap", "align-items", "center", "margin-bottom", "8px"], [2, "padding", "8px", "background", "#fff", "border", "1px solid #dee2e6", "border-radius", "4px", "margin-top", "8px"], ["textField", "Name", "valueField", "ID", "placeholder", "Select a model...", 2, "width", "100%", 3, "ngModelChange", "valueChange", "ngModel", "name", "data", "valuePrimitive", "filterable"], [2, "color", "#6c757d", "font-style", "italic", "font-size", "0.9em"], ["textField", "Name", "valueField", "ID", "placeholder", "Select vendor...", 2, "width", "100%", 3, "ngModel", "name", "data", "valuePrimitive", "filterable"], ["textField", "Name", "valueField", "ID", "placeholder", "Select vendor...", 2, "width", "100%", 3, "ngModelChange", "ngModel", "name", "data", "valuePrimitive", "filterable"], ["kendoDropDownListItemTemplate", ""], [2, "font-size", "0.8em", "margin-left", "4px"], [2, "font-size", "0.9em", "font-weight", "500", 3, "color"], [2, "font-size", "0.9em", "font-weight", "500"], [2, "font-size", "0.9em", 3, "color"], [2, "color", "#6c757d", "font-size", "0.9em"], [2, "font-size", "0.9em"], [2, "display", "flex", "gap", "2px", "margin-bottom", "4px"], ["fillMode", "flat", "size", "small", "title", "Move up", 3, "click", "disabled"], [1, "fa-solid", "fa-chevron-up"], ["fillMode", "flat", "size", "small", "title", "Move down", 3, "click", "disabled"], [1, "fa-solid", "fa-chevron-down"], ["fillMode", "flat", "themeColor", "error", "size", "small", "title", "Remove model", 3, "click"], [1, "fa-solid", "fa-times"], [2, "margin-bottom", "6px", "font-weight", "600", "color", "#495057", "font-size", "0.9em"], [1, "fa-solid", "fa-layer-group"], [2, "display", "grid", "grid-template-columns", "1fr 1fr 1fr", "gap", "12px", "align-items", "center"], [2, "display", "flex", "gap", "16px", "flex-wrap", "wrap", "align-items", "center"], [2, "display", "block", "margin-bottom", "2px", "font-size", "0.8em", "font-weight", "600", "color", "#495057"], ["textField", "text", "valueField", "value", "placeholder", "Select mode...", 2, "width", "100%", "font-size", "0.85em", 3, "ngModelChange", "ngModel", "name", "data", "valuePrimitive"], ["placeholder", "Count...", 2, "width", "100%", "font-size", "0.85em", 3, "ngModelChange", "ngModel", "name", "min", "step", "format"], ["placeholder", "Parameter name...", 2, "width", "100%", "font-size", "0.85em", 3, "ngModelChange", "ngModel", "name"], ["fillMode", "outline", "themeColor", "success", "size", "small", 3, "click"], [1, "fa-solid", "fa-cogs", 2, "color", "#6c757d"], [2, "padding", "8px", "color", "#6c757d", "font-style", "italic"], ["name", "resultSelectorPromptID", "textField", "text", "valueField", "value", "placeholder", "Select a result selector prompt...", 2, "width", "100%", 3, "ngModel", "data", "valuePrimitive", "filterable"], ["name", "resultSelectorPromptID", "textField", "text", "valueField", "value", "placeholder", "Select a result selector prompt...", 2, "width", "100%", 3, "ngModelChange", "valueChange", "ngModel", "data", "valuePrimitive", "filterable"], [2, "padding", "16px"], [2, "background", "#f8f9fa", "border", "1px solid #dee2e6", "border-radius", "4px", "padding", "12px", "font-family", "'Courier New', monospace", "font-size", "0.9em", "white-space", "pre-wrap", "overflow", "auto", "max-height", "250px"], [2, "background", "#fff3cd", "border", "1px solid #ffeaa7", "border-radius", "4px", "padding", "12px", "color", "#856404", "text-align", "center"], [2, "color", "#dc3545", "font-size", "0.8em", "font-weight", "normal"], ["name", "outputExample", "language", "json", "placeholder", "Enter JSON example structure...", 2, "width", "100%", "height", "200px", "border", "1px solid #dee2e6", "border-radius", "4px", 3, "ngModelChange", "ngModel"], [2, "margin-top", "8px", "color", "#6c757d", "font-size", "0.85em"], [2, "height", "300px", 3, "Params", "NewRecordValues", "AllowLoad", "EditMode", "BottomMargin"], [1, "fa-solid", "fa-history", 2, "color", "#6c757d"], [1, "fa-solid", "fa-database", 2, "color", "#6c757d"], [2, "margin", "0 0 12px 0", "color", "#495057"], [2, "height", "200px", 3, "Params", "NewRecordValues", "AllowLoad", "EditMode", "BottomMargin"], [1, "fa-solid", "fa-link", 2, "color", "#6c757d"]], template: function AIPromptFormComponentExtended_Template(rf, ctx) { if (rf & 1) {
1846
+ i0.ɵɵelementStart(0, "div", 2);
1847
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Template, 65, 36, "form", 3);
1848
+ i0.ɵɵelementStart(2, "mj-ai-prompt-execution-dialog", 4);
1849
+ i0.ɵɵtwoWayListener("isVisibleChange", function AIPromptFormComponentExtended_Template_mj_ai_prompt_execution_dialog_isVisibleChange_2_listener($event) { i0.ɵɵtwoWayBindingSet(ctx.showExecutionDialog, $event) || (ctx.showExecutionDialog = $event); return $event; });
1850
+ i0.ɵɵelementEnd()();
1851
+ } if (rf & 2) {
1852
+ i0.ɵɵproperty("bottomMargin", 20)("rightMargin", 5);
1853
+ i0.ɵɵadvance();
1854
+ i0.ɵɵproperty("ngIf", ctx.record);
1855
+ i0.ɵɵadvance();
1856
+ i0.ɵɵproperty("aiPrompt", ctx.record);
1857
+ i0.ɵɵtwoWayProperty("isVisible", ctx.showExecutionDialog);
1858
+ } }, dependencies: [i1.NgIf, i2.ɵNgNoValidate, i2.NgControlStatus, i2.NgControlStatusGroup, i2.NgModel, i2.NgForm, i3.ExpansionPanelComponent, i3.ExpansionPanelTitleDirective, i4.TextAreaComponent, i4.TextBoxComponent, i4.NumericTextBoxComponent, i5.ItemTemplateDirective, i5.DropDownListComponent, i5.DropDownTreeComponent, i6.ButtonComponent, i7.UserViewGridComponent, i8.MJFormField, i9.FormToolbarComponent, i10.FillContainer, i11.CodeEditorComponent, i12.TemplateEditorComponent, i13.AIPromptExecutionDialogComponent, i1.DatePipe], styles: [".record-form-container[_ngcontent-%COMP%] {\n font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n padding: 10px;\n}\n\n.custom-toolbar-actions[_ngcontent-%COMP%] {\n margin-left: auto;\n}\n\n.status-badge[_ngcontent-%COMP%] {\n font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n font-weight: 500;\n letter-spacing: 0.02em;\n}\n\n.config-summary[_ngcontent-%COMP%] {\n position: sticky;\n top: 0;\n max-height: 600px;\n overflow-y: auto;\n}\n\n.config-item[_ngcontent-%COMP%] {\n padding: 8px 0;\n border-bottom: 1px solid #e9ecef;\n}\n\n.config-item[_ngcontent-%COMP%]:last-child {\n border-bottom: none;\n}\n\n.template-tab-content[_ngcontent-%COMP%] {\n background: #fff;\n}\n\n.template-header[_ngcontent-%COMP%] h5[_ngcontent-%COMP%] {\n font-size: 1.1em;\n}\n\n.loading-state[_ngcontent-%COMP%], \n.no-template-state[_ngcontent-%COMP%], \n.invalid-template-state[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n}\n\n.no-template-state[_ngcontent-%COMP%] i[_ngcontent-%COMP%], \n.invalid-template-state[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n opacity: 0.6;\n}\n\n.template-editor-container[_ngcontent-%COMP%] {\n background: #fff;\n border-radius: 6px;\n}\n\n\n\n@media (max-width: 1200px) {\n .record-form-container[_ngcontent-%COMP%] .mj-tab-body[_ngcontent-%COMP%] > div[_ngcontent-%COMP%] {\n grid-template-columns: 1fr !important;\n gap: 20px;\n }\n \n .config-summary[_ngcontent-%COMP%] {\n order: -1;\n position: static;\n max-height: none;\n }\n}\n\n\n\n@media (max-width: 768px) {\n .custom-toolbar-actions[_ngcontent-%COMP%] {\n flex-direction: column;\n gap: 4px !important;\n }\n \n .status-badge[_ngcontent-%COMP%] {\n align-self: flex-start;\n }\n}\n\n\n\n.record-form-container[_ngcontent-%COMP%] mj-form-section[_ngcontent-%COMP%] {\n padding: 16px;\n}\n\n\n\n.status-badge[_ngcontent-%COMP%], \n.config-item[_ngcontent-%COMP%], \n.template-header[_ngcontent-%COMP%] {\n transition: all 0.2s ease;\n}\n\n.config-item[_ngcontent-%COMP%]:hover {\n background-color: rgba(0,0,0,0.02);\n border-radius: 4px;\n margin: 0 -8px;\n padding: 8px;\n}"] });
1859
+ AIPromptFormComponentExtended = __decorate([
1860
+ RegisterClass(BaseFormComponent, 'AI Prompts')
1861
+ ], AIPromptFormComponentExtended);
1862
+ export { AIPromptFormComponentExtended };
1863
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(AIPromptFormComponentExtended, [{
1864
+ type: Component,
1865
+ args: [{ selector: 'mj-ai-prompt-form', template: "<div class=\"record-form-container\" mjFillContainer [bottomMargin]=\"20\" [rightMargin]=\"5\">\n <form *ngIf=\"record\" class=\"record-form\" #form=\"ngForm\" mjFillContainer>\n <mj-form-toolbar [form]=\"this\"></mj-form-toolbar>\n\n <!-- Main Content Area - Template Editor and Configuration -->\n <div class=\"prompt-main-area\" style=\"display: flex; flex-direction: column; height: 100%; overflow-y: auto;\">\n \n <!-- Header Section -->\n <div class=\"prompt-header\" style=\"flex-shrink: 0; padding: 20px; background: #f8f9fa; border-bottom: 2px solid #e9ecef;\">\n <div style=\"display: flex; justify-content: space-between; align-items: flex-start; gap: 20px;\">\n \n <!-- Left: Prompt Info -->\n <div style=\"flex: 1; min-width: 0;\">\n <div style=\"display: flex; align-items: center; gap: 12px; margin-bottom: 8px;\">\n <i class=\"fa-solid fa-robot\" style=\"color: #6f42c1; font-size: 1.4em;\"></i>\n @if (EditMode) {\n <kendo-textbox [(ngModel)]=\"record.Name\" \n name=\"promptName\"\n placeholder=\"Enter prompt name...\"\n style=\"font-size: 1.2em; font-weight: 600; min-width: 300px; flex: 1;\">\n </kendo-textbox>\n } @else {\n <h4 style=\"margin: 0; color: #495057; font-weight: 600; flex: 1;\">{{ record.Name || 'Untitled AI Prompt' }}</h4>\n <span class=\"status-badge\" [style.background-color]=\"getStatusBadgeColor()\" \n style=\"color: white; padding: 4px 10px; border-radius: 12px; font-size: 0.75em; font-weight: 500;\">\n {{ record.Status }}\n </span>\n }\n </div>\n \n <!-- Status and Type Editors when in edit mode -->\n @if (EditMode) {\n <div style=\"display: flex; gap: 16px; margin-bottom: 12px; flex-wrap: wrap;\">\n <div>\n <label style=\"display: block; margin-bottom: 4px; font-weight: 600; color: #495057; font-size: 0.9em;\">Status</label>\n <kendo-dropdownlist [(ngModel)]=\"record.Status\"\n name=\"promptStatus\"\n [data]=\"[{text: 'Active', value: 'Active'}, {text: 'Pending', value: 'Pending'}, {text: 'Disabled', value: 'Disabled'}]\"\n textField=\"text\"\n valueField=\"value\"\n [valuePrimitive]=\"true\"\n style=\"width: 150px;\">\n </kendo-dropdownlist>\n </div>\n <div>\n <label style=\"display: block; margin-bottom: 4px; font-weight: 600; color: #495057; font-size: 0.9em;\">\n Type <span style=\"color: #dc3545;\">*</span>\n </label>\n @if (isLoadingPromptTypes) {\n <div style=\"padding: 8px; color: #6c757d; font-style: italic; width: 200px;\">\n <i class=\"fa-solid fa-spinner fa-spin\"></i> Loading types...\n </div>\n } @else {\n <kendo-dropdownlist [(ngModel)]=\"record.TypeID\"\n name=\"promptTypeID\"\n [data]=\"availablePromptTypes\"\n textField=\"Name\"\n valueField=\"ID\"\n [valuePrimitive]=\"true\"\n [filterable]=\"true\"\n placeholder=\"Select prompt type...\"\n style=\"width: 200px;\">\n </kendo-dropdownlist>\n }\n </div>\n </div>\n }\n \n @if (EditMode) {\n <kendo-textarea [(ngModel)]=\"record.Description\" \n name=\"promptDescription\"\n [rows]=\"2\"\n placeholder=\"Enter prompt description...\"\n style=\"width: 100%; max-width: 600px; margin-bottom: 12px;\">\n </kendo-textarea>\n } @else if (record.Description) {\n <p style=\"margin: 0 0 12px 0; color: #6c757d; font-size: 0.9em; line-height: 1.4;\">{{ record.Description }}</p>\n }\n \n <!-- Quick Config Row -->\n <div class=\"quick-config\" style=\"display: flex; align-items: center; gap: 16px; flex-wrap: wrap;\">\n @if (record.TypeID) {\n <div class=\"config-item\" style=\"display: flex; align-items: center; gap: 6px; font-size: 0.85em;\">\n <i class=\"fa-solid fa-tag\" style=\"color: #6c757d;\"></i>\n <span style=\"color: #6c757d;\">Type:</span>\n <span style=\"color: #495057; font-weight: 500;\">{{ getPromptTypeDisplayName(record.TypeID) }}</span>\n </div>\n }\n \n <div class=\"config-item\" style=\"display: flex; align-items: center; gap: 6px; font-size: 0.85em;\">\n <i class=\"fa-solid fa-layer-group\" style=\"color: #6c757d;\"></i>\n <span style=\"color: #6c757d;\">Parallelization:</span>\n <span style=\"color: #495057; font-weight: 500;\">{{ getParallelizationModeDisplay() }}</span>\n </div>\n \n <div class=\"config-item\" style=\"display: flex; align-items: center; gap: 6px; font-size: 0.85em;\">\n <i class=\"fa-solid fa-code\" style=\"color: #6c757d;\"></i>\n <span style=\"color: #6c757d;\">Output:</span>\n <span [style.color]=\"getValidationColor()\" style=\"font-weight: 500;\">{{ getOutputTypeDisplay() }}</span>\n </div>\n \n @if (record.EnableCaching) {\n <div class=\"config-item\" style=\"display: flex; align-items: center; gap: 6px; font-size: 0.85em;\">\n <i class=\"fa-solid fa-database\" style=\"color: #28a745;\"></i>\n <span style=\"color: #28a745; font-weight: 500;\">Caching Enabled</span>\n </div>\n }\n </div>\n </div>\n \n <!-- Right: Action Buttons -->\n <div class=\"action-buttons\" style=\"display: flex; flex-direction: column; gap: 8px; align-items: flex-end;\">\n <div style=\"display: flex; gap: 8px;\">\n @if (record.ID && canExecute) {\n <kendo-button themeColor=\"primary\" size=\"large\"\n (click)=\"executeAIPrompt()\"\n title=\"Execute this AI prompt\">\n <i class=\"fa-solid fa-play\"></i> Execute Prompt\n </kendo-button>\n } @else if (record.ID && !canExecute) {\n <kendo-button themeColor=\"primary\" size=\"large\" [disabled]=\"true\"\n title=\"Prompt must be Active and have a Template to execute\">\n <i class=\"fa-solid fa-exclamation-triangle\"></i> Cannot Execute\n </kendo-button>\n }\n \n @if (record.ID) {\n <kendo-button fillMode=\"outline\" themeColor=\"info\"\n title=\"View execution history\">\n <i class=\"fa-solid fa-history\"></i> History\n </kendo-button>\n }\n </div>\n \n @if (!canExecute && record.ID) {\n <div style=\"font-size: 0.75em; color: #dc3545; text-align: right; max-width: 200px;\">\n @if (record.Status !== 'Active') {\n \u2022 Prompt must be Active<br>\n }\n @if (!record.TemplateID) {\n \u2022 Template is required<br>\n }\n @if (!template && record.TemplateID) {\n \u2022 Template not found<br>\n }\n </div>\n }\n </div>\n </div>\n </div>\n\n <!-- Configuration Sections with Expansion Panels -->\n <div class=\"configuration-sections\" style=\"flex: 1; background: white; border-top: 2px solid #e9ecef; padding: 16px; min-height: 0;\">\n <!-- Template Editor Section -->\n <kendo-expansionpanel \n [expanded]=\"true\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-code\" style=\"color: #6c757d;\"></i>\n Template Editor\n @if (template) {\n <span style=\"color: #6c757d; font-size: 0.9em; font-weight: normal;\">\u2022 {{ template.Name }}</span>\n }\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div class=\"template-section\" style=\"display: flex; flex-direction: column; min-height: 400px; padding: 8px;\">\n @if (isLoadingTemplate) {\n <div class=\"loading-state\" style=\"flex: 1; display: flex; align-items: center; justify-content: center; color: #6c757d;\">\n <i class=\"fa-solid fa-spinner fa-spin\" style=\"font-size: 24px; margin-right: 12px;\"></i>\n Loading template...\n </div>\n } @else if (!record.TemplateID) {\n <div class=\"no-template-state\" style=\"flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px; color: #6c757d;\">\n <i class=\"fa-solid fa-code\" style=\"font-size: 64px; margin-bottom: 20px; opacity: 0.3;\"></i>\n <h5 style=\"margin-bottom: 12px; color: #495057;\">No Template Associated</h5>\n <p style=\"margin-bottom: 24px; text-align: center; max-width: 400px;\">\n This AI prompt needs a template to define its structure and parameters. \n Create a new template or link to an existing one.\n </p>\n <div style=\"display: flex; gap: 12px;\">\n <kendo-button themeColor=\"primary\" (click)=\"createNewTemplate()\">\n <i class=\"fa-solid fa-plus\"></i> Create New Template\n </kendo-button>\n <kendo-button fillMode=\"outline\" (click)=\"linkExistingTemplate()\">\n <i class=\"fa-solid fa-link\"></i> Link Existing Template\n </kendo-button>\n </div>\n </div>\n } @else if (!template) {\n <div class=\"invalid-template-state\" style=\"flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px; color: #dc3545;\">\n <i class=\"fa-solid fa-exclamation-triangle\" style=\"font-size: 64px; margin-bottom: 20px; opacity: 0.7;\"></i>\n <h5 style=\"margin-bottom: 12px;\">Template Not Found</h5>\n <p style=\"margin-bottom: 24px; text-align: center; max-width: 400px;\">\n The referenced template could not be loaded. It may have been deleted or moved.\n </p>\n <div style=\"display: flex; gap: 12px;\">\n <kendo-button fillMode=\"outline\" (click)=\"loadTemplate()\">\n <i class=\"fa-solid fa-refresh\"></i> Retry Loading\n </kendo-button>\n <kendo-button themeColor=\"primary\" (click)=\"createNewTemplate()\">\n <i class=\"fa-solid fa-plus\"></i> Create New Template\n </kendo-button>\n </div>\n </div>\n } @else {\n <!-- Active Template Editor -->\n <div class=\"template-editor-container\" style=\"flex: 1; display: flex; flex-direction: column; min-height: 350px;\">\n <!-- Template Editor -->\n <div style=\"flex: 1; background: white; border-radius: 6px; border: 1px solid #e9ecef;\">\n <mj-template-editor \n #templateEditor\n [template]=\"template\"\n [config]=\"templateEditorConfig\"\n (contentChange)=\"onTemplateContentChange($event)\"\n (runTemplate)=\"onTemplateRun($event)\"\n style=\"display: block; min-height: 300px;\">\n </mj-template-editor>\n </div>\n </div>\n }\n </div>\n </kendo-expansionpanel> \n\n <!-- Model Configuration Expansion Panel -->\n @if (record.IsSaved) {\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-microchip\" style=\"color: #6c757d;\"></i>\n Models\n @if (promptModels.length > 0) {\n <span class=\"badge\" style=\"background: #17a2b8; color: white; padding: 2px 6px; border-radius: 10px; font-size: 0.7em;\">\n {{ promptModels.length }}\n </span>\n }\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px 0;\">\n <!-- Model Management Interface -->\n <div class=\"model-management\" style=\"border: 1px solid #dee2e6; border-radius: 6px; background: #f8f9fa;\">\n @if (isLoadingModels) {\n <div class=\"loading-state\" style=\"padding: 20px; text-align: center; color: #6c757d;\">\n <i class=\"fa-solid fa-spinner fa-spin\"></i> Loading models...\n </div>\n } @else {\n @if (promptModels.length === 0) {\n <div class=\"empty-state\" style=\"padding: 20px; text-align: center; color: #6c757d;\">\n <i class=\"fa-solid fa-info-circle\"></i> No models configured\n @if (EditMode) {\n <div style=\"margin-top: 10px;\">\n <kendo-button fillMode=\"outline\" themeColor=\"primary\" size=\"small\"\n (click)=\"addNewModel()\">\n <i class=\"fa-solid fa-plus\"></i> Add Model\n </kendo-button>\n </div>\n }\n </div>\n } @else {\n <!-- Column Headers -->\n <div class=\"model-header\" style=\"display: grid; grid-template-columns: 40px 2fr 1fr 1fr 60px; gap: 12px; padding: 12px 16px; background: #e9ecef; font-weight: 600; font-size: 0.85em; color: #495057; border-bottom: 1px solid #dee2e6;\">\n <div></div>\n <div>AI Model <span style=\"color: #dc3545;\">*</span></div>\n <div>Vendor</div>\n <div>Created</div>\n <div>Actions</div>\n </div>\n \n @for (model of promptModels; track model.ID || $index; let i = $index) {\n <div class=\"model-row\" \n [style.background]=\"!model.ModelID ? '#fff3cd' : 'white'\"\n [style.border-left]=\"!model.ModelID ? '3px solid #ffc107' : 'none'\"\n style=\"display: grid; grid-template-columns: 40px 2fr 1fr 1fr 60px; gap: 12px; padding: 12px 16px; border-bottom: 1px solid #e9ecef; align-items: start;\">\n \n <!-- Drag Handle -->\n <div class=\"drag-handle\" style=\"display: flex; align-items: center; justify-content: center; cursor: move; color: #6c757d;\">\n @if (EditMode) {\n <i class=\"fa-solid fa-grip-vertical\" title=\"Drag to reorder\"></i>\n } @else {\n <span style=\"font-size: 0.8em; color: #6c757d;\">{{ i + 1 }}</span>\n }\n </div>\n \n <!-- Model Selection -->\n <div class=\"model-select\">\n @if (EditMode) {\n <kendo-dropdownlist [(ngModel)]=\"model.ModelID\"\n [name]=\"'modelId_' + i\"\n [data]=\"availableModels\"\n textField=\"Name\"\n valueField=\"ID\"\n [valuePrimitive]=\"true\"\n [filterable]=\"true\"\n placeholder=\"Select a model...\"\n (valueChange)=\"onModelChange($event, i)\"\n style=\"width: 100%;\">\n </kendo-dropdownlist>\n } @else {\n <span style=\"font-weight: 500;\">{{ getModelDisplayName(model.ModelID) }}</span>\n }\n </div>\n \n <!-- Vendor -->\n <div class=\"model-vendor\">\n @if (EditMode) {\n @if (model.ModelID) {\n @if (shouldShowVendorDropdown(model.ModelID)) {\n <kendo-dropdownlist [(ngModel)]=\"model.VendorID\"\n [name]=\"'vendorId_' + i\"\n [data]=\"getVendorsForModelSync(model.ModelID)\"\n textField=\"Name\"\n valueField=\"ID\"\n [valuePrimitive]=\"true\"\n [filterable]=\"true\"\n placeholder=\"Select vendor...\"\n style=\"width: 100%;\">\n <ng-template kendoDropDownListItemTemplate let-dataItem>\n <span [style.color]=\"getVendorStatusColor(model.ModelID, dataItem.ID)\">\n {{ dataItem.Name }}\n @if (getModelVendorStatus(model.ModelID, dataItem.ID) !== 'Active') {\n <span style=\"font-size: 0.8em; margin-left: 4px;\">({{ getModelVendorStatus(model.ModelID, dataItem.ID) }})</span>\n }\n </span>\n </ng-template>\n </kendo-dropdownlist>\n } @else {\n <!-- Single vendor - just show the name -->\n @if (getVendorsForModelSync(model.ModelID).length === 1) {\n <span [style.color]=\"getVendorStatusColor(model.ModelID, getVendorsForModelSync(model.ModelID)[0].ID)\" style=\"font-size: 0.9em; font-weight: 500;\">\n {{ getVendorsForModelSync(model.ModelID)[0].Name }}\n @if (getModelVendorStatus(model.ModelID, getVendorsForModelSync(model.ModelID)[0].ID) !== 'Active') {\n <span style=\"font-size: 0.8em; margin-left: 4px;\">({{ getModelVendorStatus(model.ModelID, getVendorsForModelSync(model.ModelID)[0].ID) }})</span>\n }\n </span>\n } @else {\n <span style=\"color: #6c757d; font-style: italic; font-size: 0.9em;\">No vendors available</span>\n }\n }\n } @else {\n <span style=\"color: #6c757d; font-style: italic; font-size: 0.9em;\">Select model first</span>\n }\n } @else {\n @if (model.VendorID && model.ModelID) {\n <span [style.color]=\"getVendorStatusColor(model.ModelID, model.VendorID)\" style=\"font-size: 0.9em;\">\n {{ getVendorDisplayName(model.VendorID) }}\n @if (getModelVendorStatus(model.ModelID, model.VendorID) !== 'Active') {\n <span style=\"font-size: 0.8em; margin-left: 4px;\">({{ getModelVendorStatus(model.ModelID, model.VendorID) }})</span>\n }\n </span>\n } @else {\n <span style=\"color: #6c757d; font-size: 0.9em;\">-</span>\n }\n }\n </div>\n \n \n <!-- Created Date -->\n <div class=\"model-created\">\n @if (model.ID) {\n <span style=\"color: #6c757d; font-size: 0.8em;\">{{ model.__mj_CreatedAt | date:'short' }}</span>\n } @else {\n <span style=\"color: #28a745; font-size: 0.8em; font-style: italic;\">New</span>\n }\n </div>\n \n <!-- Actions -->\n <div class=\"model-actions\" style=\"display: flex; gap: 2px; flex-direction: column;\">\n @if (EditMode) {\n <div style=\"display: flex; gap: 2px; margin-bottom: 4px;\">\n <kendo-button fillMode=\"flat\" size=\"small\"\n (click)=\"moveModelUp(i)\"\n [disabled]=\"i === 0\"\n title=\"Move up\">\n <i class=\"fa-solid fa-chevron-up\"></i>\n </kendo-button>\n <kendo-button fillMode=\"flat\" size=\"small\"\n (click)=\"moveModelDown(i)\"\n [disabled]=\"i === promptModels.length - 1\"\n title=\"Move down\">\n <i class=\"fa-solid fa-chevron-down\"></i>\n </kendo-button>\n </div>\n <kendo-button fillMode=\"flat\" themeColor=\"error\" size=\"small\"\n (click)=\"removePromptModel(i)\"\n title=\"Remove model\">\n <i class=\"fa-solid fa-times\"></i>\n </kendo-button>\n }\n </div>\n </div>\n \n <!-- Second row with additional details -->\n <div style=\"display: grid; grid-template-columns: 40px 1fr; gap: 12px; padding: 8px 16px; border-bottom: 1px solid #e9ecef; background: #f8f9fa; font-size: 0.85em; color: #6c757d;\">\n <div></div>\n <div>\n <!-- Basic model details -->\n <div style=\"display: flex; gap: 16px; flex-wrap: wrap; align-items: center; margin-bottom: 8px;\">\n @if (model.Status) {\n <span><strong>Status:</strong> {{ model.Status }}</span>\n }\n @if (model.ConfigurationID) {\n <span><strong>Configuration:</strong> {{ model.ConfigurationID }}</span>\n }\n </div>\n \n <!-- Parallel execution fields when prompt is ModelSpecific -->\n @if (record.ParallelizationMode === 'ModelSpecific') {\n <div style=\"padding: 8px; background: #fff; border: 1px solid #dee2e6; border-radius: 4px; margin-top: 8px;\">\n <div style=\"margin-bottom: 6px; font-weight: 600; color: #495057; font-size: 0.9em;\">\n <i class=\"fa-solid fa-layer-group\"></i> Model-Specific Parallel Execution\n </div>\n \n @if (EditMode) {\n <div style=\"display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; align-items: center;\">\n <!-- Parallel Mode -->\n <div>\n <label style=\"display: block; margin-bottom: 2px; font-size: 0.8em; font-weight: 600; color: #495057;\">Parallel Mode</label>\n <kendo-dropdownlist [(ngModel)]=\"model.ParallelizationMode\"\n [name]=\"'parallelMode_' + i\"\n [data]=\"[{text: 'None', value: 'None'}, {text: 'Static Count', value: 'StaticCount'}, {text: 'Config Param', value: 'ConfigParam'}]\"\n textField=\"text\"\n valueField=\"value\"\n [valuePrimitive]=\"true\"\n placeholder=\"Select mode...\"\n style=\"width: 100%; font-size: 0.85em;\">\n </kendo-dropdownlist>\n </div>\n \n <!-- Parallel Count (when StaticCount) -->\n @if (model.ParallelizationMode === 'StaticCount') {\n <div>\n <label style=\"display: block; margin-bottom: 2px; font-size: 0.8em; font-weight: 600; color: #495057;\">Parallel Count</label>\n <kendo-numerictextbox [(ngModel)]=\"model.ParallelCount\"\n [name]=\"'parallelCount_' + i\"\n [min]=\"1\"\n [step]=\"1\"\n [format]=\"'n0'\"\n placeholder=\"Count...\"\n style=\"width: 100%; font-size: 0.85em;\">\n </kendo-numerictextbox>\n </div>\n }\n \n <!-- Config Param (when ConfigParam) -->\n @if (model.ParallelizationMode === 'ConfigParam') {\n <div>\n <label style=\"display: block; margin-bottom: 2px; font-size: 0.8em; font-weight: 600; color: #495057;\">Config Parameter</label>\n <kendo-textbox [(ngModel)]=\"model.ParallelConfigParam\"\n [name]=\"'parallelConfigParam_' + i\"\n placeholder=\"Parameter name...\"\n style=\"width: 100%; font-size: 0.85em;\">\n </kendo-textbox>\n </div>\n }\n </div>\n } @else {\n <!-- Read-only display -->\n <div style=\"display: flex; gap: 16px; flex-wrap: wrap; align-items: center;\">\n @if (model.ParallelizationMode) {\n <span><strong>Parallel Mode:</strong> {{ model.ParallelizationMode }}</span>\n }\n @if (model.ParallelCount) {\n <span><strong>Parallel Count:</strong> {{ model.ParallelCount }}</span>\n }\n @if (model.ParallelConfigParam) {\n <span><strong>Config Param:</strong> {{ model.ParallelConfigParam }}</span>\n }\n </div>\n }\n </div>\n }\n </div>\n </div>\n }\n \n @if (EditMode) {\n <div class=\"add-model-row\" style=\"padding: 12px 16px; text-align: center; background: #f8f9fa; border-top: 1px solid #dee2e6;\">\n <kendo-button fillMode=\"outline\" themeColor=\"success\" size=\"small\"\n (click)=\"addNewModel()\">\n <i class=\"fa-solid fa-plus\"></i> Add Model\n </kendo-button>\n </div>\n }\n }\n }\n </div>\n </div>\n </kendo-expansionpanel>\n }\n\n <!-- Advanced Configuration Expansion Panel -->\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-cogs\" style=\"color: #6c757d;\"></i>\n Advanced Configuration\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px 0;\">\n <div style=\"display: grid; grid-template-columns: 1fr 1fr; gap: 20px;\">\n \n <!-- Left Column -->\n <div>\n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"ParallelizationMode\"\n Type=\"dropdownlist\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n \n @if (showParallelCount) {\n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"ParallelCount\"\n Type=\"numerictextbox\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n }\n \n @if (showParallelConfigParam) {\n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"ParallelConfigParam\"\n Type=\"textbox\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n }\n \n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"OutputType\"\n Type=\"dropdownlist\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n \n </div>\n \n <!-- Right Column -->\n <div>\n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"ValidationBehavior\"\n Type=\"dropdownlist\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n \n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"EnableCaching\"\n Type=\"checkbox\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n \n <!-- Result Selector Prompt with Tree Selector -->\n <div style=\"margin-bottom: 16px;\">\n <label style=\"display: block; margin-bottom: 4px; font-weight: 600; color: #495057; font-size: 0.9em;\">\n Result Selector Prompt\n </label>\n @if (EditMode) {\n @if (isLoadingResultSelectorData) {\n <div style=\"padding: 8px; color: #6c757d; font-style: italic;\">\n <i class=\"fa-solid fa-spinner fa-spin\"></i> Loading prompts...\n </div>\n } @else {\n <kendo-dropdowntree \n [(ngModel)]=\"record.ResultSelectorPromptID\"\n name=\"resultSelectorPromptID\"\n [data]=\"resultSelectorTreeData\"\n textField=\"text\"\n valueField=\"value\"\n [valuePrimitive]=\"true\"\n [filterable]=\"true\"\n placeholder=\"Select a result selector prompt...\"\n style=\"width: 100%;\"\n (valueChange)=\"onResultSelectorChange($event)\">\n </kendo-dropdowntree>\n }\n } @else {\n <span style=\"color: #495057;\">{{ getPromptDisplayName(record.ResultSelectorPromptID || '') || 'None selected' }}</span>\n }\n </div>\n </div>\n </div>\n </div>\n </kendo-expansionpanel>\n\n <!-- Output Example Expansion Panel (when OutputType = object) -->\n @if (showOutputExample) {\n <kendo-expansionpanel \n [expanded]=\"true\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-code\" style=\"color: #6c757d;\"></i>\n Output Example (JSON)\n <span style=\"color: #dc3545; font-size: 0.8em; font-weight: normal;\">\u2022 Required for object output type</span>\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px;\">\n @if (EditMode) {\n <mj-code-editor \n [(ngModel)]=\"record.OutputExample\"\n name=\"outputExample\"\n language=\"json\"\n placeholder=\"Enter JSON example structure...\"\n style=\"width: 100%; height: 200px; border: 1px solid #dee2e6; border-radius: 4px;\">\n </mj-code-editor>\n <div style=\"margin-top: 8px; color: #6c757d; font-size: 0.85em;\">\n <i class=\"fa-solid fa-info-circle\"></i> Provide a JSON example that defines the expected structure for object output validation.\n </div>\n } @else if (record.OutputExample) {\n <div style=\"background: #f8f9fa; border: 1px solid #dee2e6; border-radius: 4px; padding: 12px; font-family: 'Courier New', monospace; font-size: 0.9em; white-space: pre-wrap; overflow: auto; max-height: 250px;\">{{ record.OutputExample }}</div>\n } @else {\n <div style=\"background: #fff3cd; border: 1px solid #ffeaa7; border-radius: 4px; padding: 12px; color: #856404; text-align: center;\">\n <i class=\"fa-solid fa-exclamation-triangle\"></i> Output example is required when output type is 'object'\n </div>\n }\n </div>\n </kendo-expansionpanel>\n }\n\n <!-- Execution History Expansion Panel -->\n @if (record.IsSaved) {\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-history\" style=\"color: #6c757d;\"></i>\n Execution History\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px 0;\">\n <mj-user-view-grid \n [Params]=\"BuildRelationshipViewParamsByEntityName('MJ: AI Prompt Runs','PromptID')\" \n [NewRecordValues]=\"NewRecordValues('MJ: AI Prompt Runs')\"\n [AllowLoad]=\"true\"\n [EditMode]=\"GridEditMode()\" \n [BottomMargin]=\"0\"\n style=\"height: 300px;\">\n </mj-user-view-grid>\n </div>\n </kendo-expansionpanel>\n }\n\n <!-- Cache Expansion Panel -->\n @if (record.IsSaved && record.EnableCaching) {\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-database\" style=\"color: #6c757d;\"></i>\n Result Cache\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px 0;\">\n <mj-user-view-grid \n [Params]=\"BuildRelationshipViewParamsByEntityName('AI Result Cache','AIPromptID')\" \n [NewRecordValues]=\"NewRecordValues('AI Result Cache')\"\n [AllowLoad]=\"true\"\n [EditMode]=\"GridEditMode()\" \n [BottomMargin]=\"0\"\n style=\"height: 300px;\">\n </mj-user-view-grid>\n </div>\n </kendo-expansionpanel>\n }\n\n <!-- Related Items Expansion Panel -->\n @if (record.IsSaved) {\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-link\" style=\"color: #6c757d;\"></i>\n Related Items\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px 0;\">\n <div style=\"display: grid; grid-template-columns: 1fr 1fr; gap: 20px;\">\n <!-- AI Agents -->\n <div>\n <h6 style=\"margin: 0 0 12px 0; color: #495057;\">AI Agents Using This Prompt</h6>\n <mj-user-view-grid \n [Params]=\"BuildRelationshipViewParamsByEntityName('MJ: AI Agent Prompts','PromptID')\" \n [NewRecordValues]=\"NewRecordValues('MJ: AI Agent Prompts')\"\n [AllowLoad]=\"true\"\n [EditMode]=\"GridEditMode()\" \n [BottomMargin]=\"0\"\n style=\"height: 200px;\">\n </mj-user-view-grid>\n </div>\n \n <!-- Result Selector References -->\n <div>\n <h6 style=\"margin: 0 0 12px 0; color: #495057;\">Prompts Using This as Result Selector</h6>\n <mj-user-view-grid \n [Params]=\"BuildRelationshipViewParamsByEntityName('AI Prompts','ResultSelectorPromptID')\" \n [NewRecordValues]=\"NewRecordValues('AI Prompts')\"\n [AllowLoad]=\"true\"\n [EditMode]=\"GridEditMode()\" \n [BottomMargin]=\"0\"\n style=\"height: 200px;\">\n </mj-user-view-grid>\n </div>\n </div>\n </div>\n </kendo-expansionpanel>\n }\n </div>\n </div>\n </form>\n\n <!-- AI Prompt Execution Dialog -->\n <mj-ai-prompt-execution-dialog\n [aiPrompt]=\"record\"\n [(isVisible)]=\"showExecutionDialog\">\n </mj-ai-prompt-execution-dialog>\n</div>", styles: [".record-form-container {\n font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n padding: 10px;\n}\n\n.custom-toolbar-actions {\n margin-left: auto;\n}\n\n.status-badge {\n font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n font-weight: 500;\n letter-spacing: 0.02em;\n}\n\n.config-summary {\n position: sticky;\n top: 0;\n max-height: 600px;\n overflow-y: auto;\n}\n\n.config-item {\n padding: 8px 0;\n border-bottom: 1px solid #e9ecef;\n}\n\n.config-item:last-child {\n border-bottom: none;\n}\n\n.template-tab-content {\n background: #fff;\n}\n\n.template-header h5 {\n font-size: 1.1em;\n}\n\n.loading-state,\n.no-template-state,\n.invalid-template-state {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n}\n\n.no-template-state i,\n.invalid-template-state i {\n opacity: 0.6;\n}\n\n.template-editor-container {\n background: #fff;\n border-radius: 6px;\n}\n\n/* Grid layout adjustments */\n@media (max-width: 1200px) {\n .record-form-container .mj-tab-body > div {\n grid-template-columns: 1fr !important;\n gap: 20px;\n }\n \n .config-summary {\n order: -1;\n position: static;\n max-height: none;\n }\n}\n\n/* Responsive toolbar */\n@media (max-width: 768px) {\n .custom-toolbar-actions {\n flex-direction: column;\n gap: 4px !important;\n }\n \n .status-badge {\n align-self: flex-start;\n }\n}\n\n/* Ensure proper spacing in form sections */\n.record-form-container mj-form-section {\n padding: 16px;\n}\n\n/* Smooth transitions for better UX */\n.status-badge,\n.config-item,\n.template-header {\n transition: all 0.2s ease;\n}\n\n.config-item:hover {\n background-color: rgba(0,0,0,0.02);\n border-radius: 4px;\n margin: 0 -8px;\n padding: 8px;\n}"] }]
1866
+ }], null, { templateEditor: [{
1867
+ type: ViewChild,
1868
+ args: ['templateEditor']
1869
+ }] }); })();
1870
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(AIPromptFormComponentExtended, { className: "AIPromptFormComponentExtended", filePath: "src/lib/custom/AIPrompts/ai-prompt-form.component.ts", lineNumber: 17 }); })();
1871
+ export function LoadAIPromptFormComponentExtended() {
1872
+ // This function ensures the class isn't tree-shaken and registers it with MemberJunction
1873
+ }
1874
+ //# sourceMappingURL=ai-prompt-form.component.js.map