File tree Expand file tree Collapse file tree 2 files changed +12
-2
lines changed
[agentId]/agent-components Expand file tree Collapse file tree 2 files changed +12
-2
lines changed Original file line number Diff line number Diff line change 7474 bind: this = {audioTranscriptionConfigCmp}
7575 llmConfigOptions= {llmConfigs}
7676 llmConfig= {agent .llm_config ? .audio_transcription }
77+ modelType= {LlmModelType .Audio }
7778 modelCapability= {LlmModelCapability .AudioTranscription }
7879 {handleAgentChange}
7980 / >
8283 bind: this = {realtimeConfigCmp}
8384 llmConfigOptions= {llmConfigs}
8485 llmConfig= {agent .llm_config ? .realtime }
86+ modelType= {LlmModelType .Realtime }
8587 modelCapability= {LlmModelCapability .Realtime }
8688 {handleAgentChange}
8789 / >
Original file line number Diff line number Diff line change 77 import HeadTitle from ' $lib/common/HeadTitle.svelte' ;
88 import LoadingToComplete from ' $lib/common/LoadingToComplete.svelte' ;
99 import Select from ' $lib/common/Select.svelte' ;
10+ import { myInfo } from ' $lib/services/auth-service' ;
1011 import { getAgentCodeScripts , getAgentOptions , updateAgentCodeScripts } from ' $lib/services/agent-service' ;
1112 import { AgentCodeScriptType } from ' $lib/helpers/enums' ;
1213 import ScriptEditor from ' ./script-editor.svelte' ;
13-
14+ import { ADMIN_ROLES } from ' $lib/helpers/constants' ;
15+
1416 /** @type {boolean} */
1517 let isLoading = false ;
1618 /** @type {boolean} */
2022 /** @type {number} */
2123 let duration = 2000 ;
2224
25+ /** @type {import('$userTypes').UserModel} */
26+ let user;
27+
2328 /** @type {import('$commonTypes').LabelValuePair[]} */
2429 let agentOptions = [];
2530
4752 };
4853
4954 onMount (async () => {
50- loadAgentOptions ();
55+ user = await myInfo ();
56+ await loadAgentOptions ();
5157 });
5258
5359 function loadAgentOptions () {
201207 bind: scriptObj= {testScriptObj}
202208/ >
203209
210+ {#if ADMIN_ROLES .includes (user? .role || ' ' )}
204211< Row>
205212 < div class = " hstack gap-2 my-4" >
206213 < Button
219226 < / div>
220227< / Row>
221228{/ if }
229+ {/ if }
You can’t perform that action at this time.
0 commit comments