@next-bricks/ai-portal 0.58.10 → 0.58.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bricks.json +29 -29
- package/dist/chunks/151.d08c1ef1.js +2 -0
- package/dist/chunks/151.d08c1ef1.js.map +1 -0
- package/dist/chunks/{2232.4c2a5ea6.js → 2232.57f7b38c.js} +2 -2
- package/dist/chunks/2232.57f7b38c.js.map +1 -0
- package/dist/chunks/chat-stream.b713afed.js +2 -0
- package/dist/chunks/chat-stream.b713afed.js.map +1 -0
- package/dist/chunks/{main.ec8527dd.js → main.99c703d7.js} +2 -2
- package/dist/chunks/{main.ec8527dd.js.map → main.99c703d7.js.map} +1 -1
- package/dist/examples.json +21 -21
- package/dist/{index.7ed0f10c.js → index.b5b0ddea.js} +2 -2
- package/dist/{index.7ed0f10c.js.map → index.b5b0ddea.js.map} +1 -1
- package/dist/manifest.json +199 -195
- package/dist/types.json +374 -367
- package/dist-types/chat-stream/ChatStream.d.ts +1 -1
- package/dist-types/chat-stream/index.d.ts +2 -0
- package/package.json +2 -2
- package/dist/chunks/151.098c765c.js +0 -2
- package/dist/chunks/151.098c765c.js.map +0 -1
- package/dist/chunks/2232.4c2a5ea6.js.map +0 -1
- package/dist/chunks/chat-stream.541a3565.js +0 -2
- package/dist/chunks/chat-stream.541a3565.js.map +0 -1
package/dist/bricks.json
CHANGED
|
@@ -1,39 +1,39 @@
|
|
|
1
1
|
{
|
|
2
2
|
"id": "bricks/ai-portal",
|
|
3
3
|
"bricks": [
|
|
4
|
+
"ai-portal.home-container",
|
|
4
5
|
"ai-portal.cruise-canvas",
|
|
5
6
|
"ai-portal.elevo-sidebar",
|
|
6
7
|
"ai-portal.icon-button",
|
|
7
|
-
"ai-portal.stat-with-mini-chart",
|
|
8
|
-
"ai-portal.show-cases",
|
|
9
8
|
"ai-portal.mcp-tools",
|
|
10
|
-
"ai-portal.
|
|
9
|
+
"ai-portal.show-cases",
|
|
11
10
|
"ai-portal.chat-box",
|
|
12
|
-
"ai-portal.
|
|
11
|
+
"ai-portal.ai-employees",
|
|
13
12
|
"ai-portal.ai-agents",
|
|
14
|
-
"ai-portal.
|
|
13
|
+
"ai-portal.chat-stream",
|
|
14
|
+
"ai-portal.call-tool",
|
|
15
|
+
"ai-portal.set-chat-command",
|
|
15
16
|
"ai-portal.save-request-store",
|
|
16
17
|
"ai-portal.load-request-store",
|
|
17
18
|
"ai-portal.clear-request-store",
|
|
18
|
-
"ai-portal.
|
|
19
|
-
"ai-portal.
|
|
19
|
+
"ai-portal.page-container",
|
|
20
|
+
"ai-portal.stat-with-mini-chart",
|
|
20
21
|
"ai-portal.tab-list",
|
|
21
|
-
"ai-portal.home-container",
|
|
22
22
|
"ai-portal.dropdown-select",
|
|
23
23
|
"ai-portal.preview-container",
|
|
24
24
|
"ai-portal.action-buttons",
|
|
25
25
|
"ai-portal.goal-card-list",
|
|
26
26
|
"ai-portal.project-conversations",
|
|
27
|
-
"ai-portal.activity-timeline",
|
|
28
27
|
"ai-portal.project-knowledges",
|
|
28
|
+
"ai-portal.activity-timeline",
|
|
29
29
|
"ai-portal.chat-input",
|
|
30
|
+
"ai-portal.elevo-logo",
|
|
30
31
|
"ai-portal.show-case",
|
|
31
32
|
"ai-portal.blank-state",
|
|
32
|
-
"ai-portal.elevo-logo",
|
|
33
33
|
"ai-portal.sticky-container",
|
|
34
34
|
"ai-portal.elevo-card",
|
|
35
|
-
"ai-portal.stage-flow",
|
|
36
35
|
"ai-portal.flow-tabs",
|
|
36
|
+
"ai-portal.stage-flow",
|
|
37
37
|
"ai-portal.running-flow",
|
|
38
38
|
"ai-portal.notice-dropdown"
|
|
39
39
|
],
|
|
@@ -75,27 +75,28 @@
|
|
|
75
75
|
"eo-icon",
|
|
76
76
|
"eo-tooltip"
|
|
77
77
|
],
|
|
78
|
-
"ai-portal.
|
|
79
|
-
"eo-
|
|
78
|
+
"ai-portal.mcp-tools": [
|
|
79
|
+
"eo-icon",
|
|
80
|
+
"ai-portal.tab-list",
|
|
81
|
+
"ai-portal.sticky-container"
|
|
80
82
|
],
|
|
81
83
|
"ai-portal.show-cases": [
|
|
82
84
|
"ai-portal.show-case",
|
|
83
85
|
"ai-portal.tab-list"
|
|
84
86
|
],
|
|
85
|
-
"ai-portal.
|
|
87
|
+
"ai-portal.chat-box": [
|
|
86
88
|
"eo-icon",
|
|
87
|
-
"
|
|
88
|
-
"ai-portal.
|
|
89
|
+
"eo-actions",
|
|
90
|
+
"ai-portal.icon-button"
|
|
89
91
|
],
|
|
90
92
|
"ai-portal.ai-employees": [
|
|
91
93
|
"eo-link",
|
|
92
94
|
"eo-icon",
|
|
93
95
|
"ai-portal.tab-list"
|
|
94
96
|
],
|
|
95
|
-
"ai-portal.
|
|
97
|
+
"ai-portal.ai-agents": [
|
|
96
98
|
"eo-icon",
|
|
97
|
-
"eo-
|
|
98
|
-
"ai-portal.icon-button"
|
|
99
|
+
"eo-link"
|
|
99
100
|
],
|
|
100
101
|
"ai-portal.chat-stream": [
|
|
101
102
|
"eo-icon",
|
|
@@ -116,14 +117,13 @@
|
|
|
116
117
|
"eo-counter-badge",
|
|
117
118
|
"presentational.code-wrapper"
|
|
118
119
|
],
|
|
119
|
-
"ai-portal.ai-agents": [
|
|
120
|
-
"eo-icon",
|
|
121
|
-
"eo-link"
|
|
122
|
-
],
|
|
123
120
|
"ai-portal.page-container": [
|
|
124
121
|
"eo-link",
|
|
125
122
|
"ai-portal.sticky-container"
|
|
126
123
|
],
|
|
124
|
+
"ai-portal.stat-with-mini-chart": [
|
|
125
|
+
"eo-mini-line-chart"
|
|
126
|
+
],
|
|
127
127
|
"ai-portal.dropdown-select": [
|
|
128
128
|
"eo-popover",
|
|
129
129
|
"eo-icon",
|
|
@@ -154,17 +154,17 @@
|
|
|
154
154
|
"eo-easyops-avatar",
|
|
155
155
|
"eo-mini-actions"
|
|
156
156
|
],
|
|
157
|
-
"ai-portal.activity-timeline": [
|
|
158
|
-
"eo-link",
|
|
159
|
-
"eo-icon",
|
|
160
|
-
"eo-easyops-avatar"
|
|
161
|
-
],
|
|
162
157
|
"ai-portal.project-knowledges": [
|
|
163
158
|
"eo-link",
|
|
164
159
|
"eo-icon",
|
|
165
160
|
"eo-easyops-avatar",
|
|
166
161
|
"eo-mini-actions"
|
|
167
162
|
],
|
|
163
|
+
"ai-portal.activity-timeline": [
|
|
164
|
+
"eo-link",
|
|
165
|
+
"eo-icon",
|
|
166
|
+
"eo-easyops-avatar"
|
|
167
|
+
],
|
|
168
168
|
"ai-portal.chat-input": [
|
|
169
169
|
"eo-icon",
|
|
170
170
|
"ai-portal.icon-button"
|
|
@@ -196,5 +196,5 @@
|
|
|
196
196
|
"eo-tooltip"
|
|
197
197
|
]
|
|
198
198
|
},
|
|
199
|
-
"filePath": "bricks/ai-portal/dist/index.
|
|
199
|
+
"filePath": "bricks/ai-portal/dist/index.b5b0ddea.js"
|
|
200
200
|
}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";(globalThis.webpackChunk_next_bricks_ai_portal=globalThis.webpackChunk_next_bricks_ai_portal||[]).push([[151],{24:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,':host{display:block;white-space:nowrap}.container{border-radius:var(--elevo-border-radius)}:host([hidden]){display:none}*{box-sizing:border-box}.label{font-weight:500;overflow:hidden;text-overflow:ellipsis}.stat{font-weight:600}.chart{min-width:0}.chart > *{display:block}:host(:not([size="small"])) .container{background:linear-gradient(164deg,rgba(105,153,253,0) 40%,rgba(105,153,253,0.05) 60%,rgba(105,153,253,0.32) 100%),#fff;padding:22px}:host(:not([size="small"])) .label{font-size:14px;height:22px;margin-bottom:16px}:host(:not([size="small"])) .stat-and-chart{display:flex;align-items:center;justify-content:end;position:relative}:host(:not([size="small"])) .stat{font-size:36px;color:#1d212a;position:absolute;left:0}:host(:not([size="small"])) .chart{width:calc(100% - 160px)}:host([size="small"]) .container{padding:11px 15px;display:flex;align-items:center;justify-content:end;position:relative;background:var(--elevo-component-background);-webkit-backdrop-filter:var(--elevo-component-backdrop-filter);backdrop-filter:var(--elevo-component-backdrop-filter)}:host([size="small"]) .label-and-stat{position:absolute;left:15px}:host([size="small"]) .label{font-size:12px;color:#8c8c8c;line-height:17px;height:17px;margin-bottom:7px}:host([size="small"]) .stat{font-size:20px;color:#262626;line-height:24px}:host([size="small"]) .chart{width:calc(100% - 90px)}',""]);const o=s.toString()},9884:(e,t,i)=>{i.d(t,{A:()=>h});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r),o=i(20062),l=i.n(o),c=new URL(i(17932),i.b),d=s()(a()),p=l()(c);d.push([e.id,`:host{display:inline-block}:host([hidden]){display:none}.popover::part(popup){border-radius:12px}.notice-dropdown-content{max-width:500px;border-radius:12px;display:flex;flex-direction:column;background-image:url(${p});background-size:cover}.header{display:flex;justify-content:space-between;align-items:center;padding:16px 20px}.title{font-size:18px;font-weight:500;color:var(--text-color-title)}.close-btn{cursor:pointer;display:flex;align-items:center;justify-content:center;width:16px;height:16px;color:#000}ul{list-style:none;margin:0;padding:4px}.content{flex:1;max-height:500px;overflow-y:auto}.link{display:block}.link::part(link){display:flex;align-items:start;gap:12px;padding:10px 16px}.link:hover::part(link):hover{background-color:rgba(0,0,0,0.04);border-radius:8px}.link:last-child{border-bottom:none}.icon-wrapper{position:relative;flex-shrink:0;width:18px;height:18px;padding:2px 0;display:flex;align-items:center;justify-content:center;font-size:18px}.message-content{flex:1;min-width:0;display:flex;flex-direction:column;gap:4px}.primary-text{font-size:14px;font-weight:400;line-height:20px;color:var(--text-color-title)}.secondary-text{color:rgba(0,0,0,0.45)}.empty-state{padding:60px 20px;text-align:center;font-size:14px;color:var(--text-color-secondary)}.footer{display:flex;gap:10px;justify-content:space-between;align-items:center;padding:9px 10px;box-shadow:0px -12px 16px -8px rgba(0,0,0,0.08);border-radius:0px 0px 12px 12px}.footer .footer-button::part(button){color:var(--text-color-secondary)}.footer .footer-button::part(button):hover{color:var(--text-color-default)!important}`,""]);const h=d.toString()},10335:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,":host{display:inline-block}:host([hidden]){display:none}.goal-container{display:flex;flex-direction:column;gap:3px}.loading{display:flex;align-items:center;justify-content:center;padding:24px;font-size:20px;color:#595959}",""]);const o=s.toString()},11816:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,":host{display:inline-block}:host([hidden]){display:none}.button-container{display:flex;gap:6px}.action{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0}.action::part(button){height:28px;font-size:13px;padding:5px 10px}.action.active::part(button){color:var(--elevo-color-brand);background-color:rgba(var(--elevo-color-brand-rgb-channel),0.04);border-color:#c9d7ff}.icon{font-size:16px;margin-right:4px}.remove{padding:1px;font-size:14px;margin-left:10px}",""]);const o=s.toString()},14763:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,':host{display:block;color:#262626}:host([hidden]){display:none}*{box-sizing:border-box}ul{list-style:none;margin:0;padding:0}.activity{position:relative;padding-left:27px}.activity + .activity{margin-top:20px}.main{display:flex;align-items:flex-start}.action{flex:1;min-width:0;display:flex;align-items:center;margin-left:6px;word-break:break-word}.time{color:#8c8c8c;margin-left:12px}.action,\n.time{padding:1px 0}.guide-line{position:absolute;left:8px;top:0;bottom:-20px;width:0;background-color:#d8d8d8}.guide-line::before{content:"";position:absolute;top:0;bottom:0;left:3.5px;width:1px;background-color:#d8d8d8}.guide-line::after{content:"";position:absolute;top:8px;left:0;width:8px;height:8px;border-radius:8px;background-color:#d8d8d8}.activity:first-child .guide-line::before{top:12px}.activity:last-child .guide-line::before{height:12px;bottom:auto}.activity:first-child:last-child .guide-line::before{height:0}.comment{position:relative;font-size:13px;color:#595959;background-color:#f3f3f3;border-radius:8px;padding:8px 12px;margin-top:10px}.comment::before{content:"";position:absolute;top:-6px;left:36px;width:0;height:0;border-left:6px solid transparent;border-right:6px solid transparent;border-bottom:6px solid #f3f3f3}.conversation{margin:0 7px 0 10px}.conversation::part(link){background:#f9f0ff;border-radius:3px;font-weight:500;font-size:12px;color:#aa64f5;display:flex;align-items:center;height:24px;padding:0 8px}.external-link-icon{color:#8c8c8c}.loading{display:flex;align-items:center;justify-content:center;padding:24px;font-size:20px;color:#595959}',""]);const o=s.toString()},17932:(e,t,i)=>{e.exports=i.p+"images/391238ae.png"},18338:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,":host{display:block}:host([hidden]){display:none}*{box-sizing:border-box}.card{display:block}.card::part(link){display:flex;flex-direction:column;gap:12px;background:rgba(255,255,255,0.6);box-shadow:0px 2px 5px 0px rgba(0,0,0,0.04);border-radius:12px;border:1px solid #fff;-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);padding:16px;color:#262626}.card:not(.clickable)::part(link){cursor:auto}.card::part(link):hover{background:#fff}.header,\n.body,\n.footer{width:100%}.header{display:flex;gap:12px}.heading{display:flex;align-items:center;gap:12px;flex:1;min-width:0}.avatar{width:42px;height:42px;border-radius:50%;border:1px solid rgba(0,0,0,0.15);font-size:24px;display:flex;align-items:center;justify-content:center}.title{font-weight:500;font-size:16px;color:#262626;line-height:22px;flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.actions{margin:-8px -8px 0 0}.body{font-size:12px;color:rgba(0,0,0,0.45);line-height:17px;height:51px;display:-webkit-box;-webkit-line-clamp:3;line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}.footer{align-items:center;justify-content:flex-end;gap:8px}.footer:not([hidden]){display:flex}",""]);const o=s.toString()},19428:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,":host{display:flex;flex-direction:column;align-items:center;gap:26px}:host([hidden]){display:none}p{color:rgba(0,0,0,0.45);margin:0}",""]);const o=s.toString()},20124:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,':host{display:block}:host([hidden]){display:none}*{box-sizing:border-box}.tabs{list-style:none;padding:0;margin:0;display:flex;flex-wrap:wrap;gap:32px;row-gap:10px;font-size:16px}.tabs a{color:rgba(38,38,38,0.65);cursor:pointer;padding:0 0 4px;display:block;position:relative}.tabs .active a{color:#262626;font-weight:500}.tabs .active a::after{content:"";position:absolute;bottom:0;left:0;right:0;height:4px;background-color:currentColor;border-radius:2px}',""]);const o=s.toString()},23677:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,":host{display:block}:host([hidden]){display:none}*{box-sizing:border-box}ul{list-style:none;margin:0;padding:0}.link{display:block}.link::part(link){display:flex;align-items:center;padding:12px 24px;color:#262626;background:rgba(255,255,255,0.6);border-radius:8px;-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px)}.item:not(:last-child){margin-bottom:4px}.link.actions-active::part(link),\n.link::part(link):hover{background:rgba(0,0,0,0.05);-webkit-backdrop-filter:none;backdrop-filter:none}.icon{font-size:20px;margin-right:8px}.title{font-weight:500;font-size:16px}.title,\n.description{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.attachment{color:#1a7aff;margin-left:8px}.header{display:flex;align-items:center}.description{color:#595959;padding-left:28px;line-height:20px}.time{color:rgba(0,0,0,0.45);margin:0 16px}.main{flex:1;min-width:0}.operations{display:flex;align-items:center;justify-content:center;width:32px;height:32px}.link.actions-active .avatar,\n.link:hover .avatar,\n.link:hover .time,\n.link:not(:hover):not(.actions-active) .actions{display:none}.loading{display:flex;align-items:center;justify-content:center;padding:24px;font-size:20px;color:#595959}",""]);const o=s.toString()},29511:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,":host{display:block}:host([hidden]){display:none}*{box-sizing:border-box}.container{position:relative}.bg{position:absolute;top:0;left:0;z-index:-1;-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px)}.header{display:flex;align-items:center;justify-content:space-between}.tabs{list-style:none;padding:0;margin:0;display:flex}.tabs .tab{padding:0 18px}.tabs a{display:block;padding:9px 10px;color:rgba(0,0,0,0.55);line-height:20px;cursor:pointer}.tabs .active a{font-weight:500;color:#262626}.body{padding:23px 27px;overflow-x:auto}.toolbar{display:flex;align-items:center;gap:8px}",""]);const o=s.toString()},31653:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,":host{display:inline-block}:host([hidden]){display:none}img{vertical-align:middle}",""]);const o=s.toString()},31748:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,":host{display:block}:host([hidden]){display:none}*{box-sizing:border-box}h2{font-weight:500;margin:0;font-size:16px;line-height:22px}.groups,\n.list{list-style:none;margin:0;padding:0}.groups{margin-top:17px}.group + .group{margin-top:32px}.list{margin-top:16px;display:grid;grid-template-columns:repeat(auto-fill,minmax(320px,1fr));gap:24px}.list .item{background:rgba(255,255,255,0.9);box-shadow:0px 2px 5px 0px rgba(0,0,0,0.08);border-radius:12px;padding:20px 26px}.heading{display:flex;align-items:center}.icon{font-size:24px;color:#333;margin-right:8px}.title{font-size:15px;font-weight:500;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.description{margin-top:13px;font-size:13px;color:rgba(0,0,0,0.45);line-height:18px;height:54px;display:-webkit-box;-webkit-line-clamp:3;line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}.sticky-tabs{margin:0 -24px;padding:0 24px 10px}.non-sticky-tabs{padding:0 0 10px}",""]);const o=s.toString()},40138:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,':host{display:inline-block}:host([hidden]){display:none}*{box-sizing:border-box}.trigger{display:flex;align-items:center;font-size:14px;cursor:pointer;position:relative;padding:4px 12px;border-radius:15px;color:var(--elevo-color-brand)}.trigger:hover{background-color:rgba(37,64,255,0.06)}.trigger::before{content:"";position:absolute;top:0;right:0;bottom:0;left:0;padding:1px;background:linear-gradient(145deg,rgba(37,64,255,1),rgba(180,95,248,1));border-radius:15px;-webkit-mask:linear-gradient(#fff 0,#fff 0) content-box,linear-gradient(#fff 0,#fff 0);mask:linear-gradient(#fff 0,#fff 0) content-box,linear-gradient(#fff 0,#fff 0);-webkit-mask:linear-gradient(#fff 0 0) content-box,linear-gradient(#fff 0 0);mask:linear-gradient(#fff 0 0) content-box,linear-gradient(#fff 0 0);-webkit-mask-composite:xor;mask-composite:xor;-webkit-mask:linear-gradient(#fff 0,#fff 0) content-box,linear-gradient(#fff 0,#fff 0);-webkit-mask:linear-gradient(#fff 0 0) content-box,linear-gradient(#fff 0 0);-webkit-mask-composite:xor}.trigger .label{margin-right:0}.label{max-width:650px;margin-right:0.5em;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.dropdown{max-width:500px;border-radius:4px;background:var(--antd-dropdown-menu-bg);box-shadow:var(--antd-box-shadow-base)}.dropdown-inner{padding:9px 4px}.search-container{padding:3px;border-bottom:1px solid rgba(0,0,0,0.08)}.search::part(affix-wrapper){box-shadow:none;border:none}eo-menu{border:0;padding:0;background:none;border-radius:0}eo-menu-item::part(menu-item){padding:5px 8px;line-height:22px;border-radius:var(--medius-border-radius)}eo-menu-item:not([disabled]):hover::part(menu-item){background-color:var(--left-sidebar-item-hover-bg)}.active::part(menu-item){font-weight:600;background-color:var(--left-sidebar-item-hover-bg)}.empty{display:flex;justify-content:center;align-items:center;color:var(--color-secondary-text)}',""]);const o=s.toString()},42873:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,":host{display:flex;flex-direction:column;align-items:center;max-width:1020px;width:100%}:host([hidden]){display:none}*{box-sizing:border-box}.tips{color:rgba(0,0,0,0.45);margin-bottom:27px}.cases{list-style:none;padding:0;margin:0;display:grid;width:100%;grid-template-columns:repeat(auto-fill,minmax(240px,1fr));gap:20px;margin-top:36px}",""]);const o=s.toString()},44492:(e,t,i)=>{e.exports=i.p+"images/60cd488d.svg"},46121:(e,t,i)=>{e.exports=i.p+"images/69cf3ae2.png"},46122:(e,t,i)=>{i.d(t,{A:()=>b});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r),o=i(20062),l=i.n(o),c=new URL(i(56791),i.b),d=new URL(i(88786),i.b),p=new URL(i(46121),i.b),h=s()(a()),u=l()(c),m=l()(d),g=l()(p);h.push([e.id,`:host{display:block}:host([hidden]){display:none}*{box-sizing:border-box}.link{display:block;background:rgba(255,255,255,0.6);border-radius:12px;-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);background-size:cover;background-position:center;background-repeat:no-repeat;background-clip:padding-box;overflow:hidden}.purple{background-image:url(${u})}.green{background-image:url(${m})}.pink{background-image:url(${g})}.link::part(link){display:flex;flex-direction:column;gap:0;box-sizing:border-box;height:128px;padding:20px;position:relative}.title{width:100%;margin-bottom:8px;color:#262626;font-weight:500;font-size:14px;line-height:20px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.description{width:100%;height:60px;display:-webkit-box;-webkit-line-clamp:3;line-clamp:3;-webkit-box-orient:vertical;overflow:hidden;font-size:13px;color:#18212f;line-height:20px}.link::part(link):hover{box-shadow:0px 4px 12px 0px rgba(96,96,138,0.15),0px 2px 4px 0px rgba(96,96,138,0.06)}.button{display:none;position:absolute;bottom:12px;left:20px;right:20px;height:32px;background:rgba(0,0,0,0.04);border-radius:8px;align-items:center;justify-content:center;gap:4px;color:#262626}.button:hover{background:rgba(0,0,0,0.08)}.link:hover .button{display:flex}.link:hover .description{-webkit-mask-image:linear-gradient(to bottom,rgba(0,0,0,0.65) 0%,rgba(0,0,0,0.11) 51%,rgba(0,0,0,0) 100%);mask-image:linear-gradient(to bottom,rgba(0,0,0,0.65) 0%,rgba(0,0,0,0.11) 51%,rgba(0,0,0,0) 100%);-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;-webkit-mask-size:100% 60%;mask-size:100% 60%}`,""]);const b=h.toString()},46342:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,".goal-item{display:flex;align-items:center;justify-content:space-between;gap:8px;cursor:pointer;padding:12px 24px;background-color:rgba(255,255,255,0.6);border-radius:8px;-webkit-user-select:none;user-select:none;border:1px solid transparent}.goal-item:hover,.goal-item:has(.title:focus){background-color:rgba(0,0,0,0.05)}.goal-item:has(.title:focus) .end .operation{display:flex}.goal-item:hover:not(.does-not-exist) .end .operation{display:flex}.goal-item:has(.title:focus) .end .info{display:none}.goal-item:hover:not(.does-not-exist) .end .info{display:none}.goal-item.completed .serial-number,.goal-item.completed .title{color:#bfbfbf}.goal-item.active{background:rgba(37,64,255,0.1);border:1px solid #2540ff}.goal-item > *{-webkit-user-select:auto;user-select:auto}.goal-item .start,.goal-item .end{display:flex;align-items:center}.goal-item .start{flex:1;min-width:0;column-gap:16px;min-width:0}.goal-item .end{flex-shrink:0;column-gap:30px}.goal-item .end .operation{display:none;align-items:center;gap:8px}.goal-item .end .operation eo-button::part(button){height:28px}.goal-item .end .operation .new-chat::part(button){padding:5px 10px;font-size:13px}.goal-item .end .operation .append-child::part(button){padding:5px 8px;font-size:14px}.goal-item .end .info{display:inline-flex;align-items:center;column-gap:24px}.goal-item .serial-number{font-weight:400;color:var(--palette-gray-7);font-size:16px;overflow:visible}.goal-item .title{font-weight:500;padding:2px 4px;font-size:16px;color:var(--palette-gray-10);border:1px solid transparent;border-radius:8px;cursor:pointer;min-width:80px}.goal-item .title:hover{background-color:rgba(255,255,255,0.6);border:1px solid var(--palette-gray-5);cursor:text}.goal-item .title:focus{outline:none;background-color:rgba(255,255,255,0.6);border:1px solid var(--elevo-color-brand)}.goal-item .icon{border-radius:8px;padding:6px;position:relative;top:2px}.goal-item .icon:hover{background-color:rgba(0,0,0,0.04)}.goal-item .message{color:var(--palette-gray-7);display:inline-flex;align-items:center;column-gap:6px}.goal-item .message .count{font-weight:500;color:var(--palette-gray-10)}.goal-item:not(.editing) .title{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}",""]);const o=s.toString()},47008:(e,t,i)=>{i.d(t,{A:()=>h});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r),o=i(20062),l=i.n(o),c=new URL(i(47336),i.b),d=s()(a()),p=l()(c);d.push([e.id,`:host{display:block}:host([hidden]){display:none}*{box-sizing:border-box}.root{color:#262626;background:url(${p}) no-repeat center bottom;background-size:100% 104px;padding:12px 12px 29px;margin:0 -12px}.container{position:relative;background:#ffffff;box-shadow:0px 2px 4px 0px rgba(38,45,65,0.1);border-radius:16px;border:1px solid #dadfe8}.container:has(textarea:focus){border-color:#b7c3d8}textarea{display:block;width:100%;padding:10px 16px 50px;color:var(--antd-input-color);border-radius:16px;-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);border:1px solid rgba(255,255,255,0.5);font:inherit;font-size:14px;line-height:22px;height:120px}textarea::placeholder{color:rgba(0,0,0,0.4)}button:focus,\ntextarea:focus{outline:none}button{margin:0;padding:0;font:inherit;background:none;border:none}.actions-bar{position:absolute;bottom:12px;left:14px;right:14px;display:flex;align-items:flex-end;justify-content:space-between;gap:6px}.btn-send{width:28px;height:28px;display:flex;align-items:center;justify-content:center;background:var(--elevo-color-brand);border:none;border-radius:8px;color:#fff;flex-shrink:0}.btn-send[disabled]{background:rgba(0,0,0,0.15)}.btn-send:not([disabled]){cursor:pointer}.btn-send:not([disabled]):hover{background:#5166ff}.btn-send:not([disabled]):active{background:#1e33cc}.mention-overlay{position:absolute;border-radius:4px;pointer-events:none;background:rgba(38,45,65,0.1)}.buttons{display:flex;align-items:center;gap:12px}.btn-divider{width:1px;height:16px;background:rgba(0,0,0,0.1)}`,""]);const h=d.toString()},47336:(e,t,i)=>{e.exports=i.p+"images/25c20165.png"},47338:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,':host{display:inline-block;--elevo-icon-button-icon-size:18px}:host([hidden]){display:none}:host,\neo-tooltip{vertical-align:middle}button{height:28px;padding:0 5px;font-size:14px;border-radius:8px;display:flex;align-items:center;justify-content:center;border:none;background:none;color:#333}.icon{font-size:var(--elevo-icon-button-icon-size)}button:disabled{color:#8c8c8c}button:not(:disabled){cursor:pointer}button:focus{outline:none}button:not(:disabled):hover{background:rgba(0,0,0,0.04)}button:not(:disabled):active{background:rgba(0,0,0,0.08)}.has-slotted .icon{margin-right:8px}:host([variant="light"]) button{color:#595959}:host([variant="mini"]) button{height:24px;--elevo-icon-button-icon-size:16px;padding:0 4px;border-radius:4px}:host([variant="mini-light"]) button{color:#8c8c8c;height:20px;--elevo-icon-button-icon-size:14px;padding:0 3px;border-radius:4px}:host([variant="bordered"]) button{background:#ffffff;border-radius:8px;border:1px solid rgba(0,0,0,0.1);color:#595959;height:32px;--elevo-icon-button-icon-size:18px;padding:0 7px}button.has-slotted{padding:0 8px}:host([variant="bordered"]) button:not(:disabled):hover{background:rgba(0,0,0,0.04)}',""]);const o=s.toString()},49041:(e,t,i)=>{i.d(t,{A:()=>h});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r),o=i(20062),l=i.n(o),c=new URL(i(32360),i.b),d=s()(a()),p=l()(c);d.push([e.id,`:host{display:block;position:relative;width:100%;height:100%;color:#262626;padding:0 54px 48px;overflow:hidden;overflow-y:auto}:host::before{content:"";position:fixed;z-index:-1;top:0;right:0;bottom:0;left:0;background-color:rgb(205,206,207);background-image:url(${p});background-position:center;background-size:cover;background-repeat:no-repeat;background-attachment:fixed}:host([hidden]){display:none}:host([variant="form"])::before{background:#fff}*{box-sizing:border-box}.container{max-width:1400px;margin:0 auto}:host([size="small"]) .container{max-width:1000px}:host([size="full"]) .container{max-width:100%}.sticky-header{margin:0 -24px;padding:17px 24px 30px}.non-sticky-header{padding:17px 0 30px}.header{display:flex;justify-content:space-between;align-items:center}nav{font-weight:500;font-size:20px;line-height:28px;display:flex;min-width:0;white-space:nowrap;flex-wrap:wrap}h1{margin:0;font-size:inherit;line-height:inherit}.breadcrumbs{list-style:none;padding:0;margin:0;color:#bfbfbf}.breadcrumbs eo-link::part(link){color:inherit}.breadcrumbs eo-link::part(link):hover{color:#595959}.breadcrumbs li::after{content:"/";margin:0 8px}@media (max-width: 719px){:host{padding-left:24px;padding-right:24px}nav{margin-left:40px}}`,""]);const h=d.toString()},54022:(e,t,i)=>{var n,a=i(74635),r=i(70918),s=i(26902),o=i(5536),l=i(86121),c=i(70829),d=i(62740),p=i(18769),h=i.n(p),u=i(90870),m=i(30981),g=(i(34419),i(52616)),b=i(2901),A=i(24863);let v,f,E,x,k,w,y,T,S,N,C,M,_,R,W,I,D,L,O,z,P,B,U,H,F,G,V,j,K,$,Y,q,X,J,Q,Z,ee,te,ie,ne,ae,re,se,oe,le,ce,de,pe,he,ue,me,ge,be,Ae,ve,fe,Ee,xe,ke,we,ye,Te,Se,Ne,Ce,Me;(0,g.initializeI18n)(b.NS,b.I);const{defineElement:_e,property:Re,event:We,method:Ie}=(0,u.createDecorators)(),De=(0,p.forwardRef)(A.B);let Le;var Oe=new WeakMap,ze=new WeakMap,Pe=new WeakMap,Be=new WeakMap,Ue=new WeakMap,He=new WeakMap,Fe=new WeakMap,Ge=new WeakMap,Ve=new WeakMap,je=new WeakMap,Ke=new WeakMap,$e=new WeakMap,Ye=new WeakMap,qe=new WeakMap,Xe=new WeakMap,Je=new WeakMap,Qe=new WeakMap,Ze=new WeakMap,et=new WeakMap,tt=new WeakMap,it=new WeakMap,nt=new WeakSet,at=new WeakMap,rt=new WeakMap,st=new WeakMap,ot=new WeakMap,lt=new WeakMap,ct=new WeakMap,dt=new WeakMap,pt=new WeakMap,ht=new WeakMap,ut=new WeakMap,mt=new WeakMap,gt=new WeakMap;class bt extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,nt),(0,r.A)(this,Oe,(v(this),E(this))),(0,r.A)(this,ze,(x(this),k(this))),(0,r.A)(this,Pe,(w(this),y(this))),(0,r.A)(this,Be,(T(this),S(this))),(0,r.A)(this,Ue,(N(this),C(this))),(0,r.A)(this,He,(M(this),_(this))),(0,r.A)(this,Fe,(R(this),W(this))),(0,r.A)(this,Ge,(I(this),D(this))),(0,r.A)(this,Ve,(L(this),O(this))),(0,r.A)(this,je,(z(this),P(this))),(0,r.A)(this,Ke,(B(this),U(this))),(0,r.A)(this,$e,(H(this),F(this))),(0,r.A)(this,Ye,(G(this),V(this))),(0,r.A)(this,qe,(j(this),K(this))),(0,r.A)(this,Xe,($(this),Y(this))),(0,r.A)(this,Je,(q(this),X(this))),(0,r.A)(this,Qe,(J(this),Q(this))),(0,r.A)(this,Ze,(Z(this),ee(this))),(0,r.A)(this,et,(te(this),ie(this))),(0,r.A)(this,tt,(ne(this),ae(this))),(0,r.A)(this,it,(re(this),se(this))),(0,r.A)(this,at,(ce(this),()=>{(0,o.A)(nt,this,oe).emit()})),(0,r.A)(this,rt,de(this)),(0,r.A)(this,st,(ue(this),()=>{(0,o.A)(nt,this,pe).emit()})),(0,r.A)(this,ot,me(this)),(0,r.A)(this,lt,(Ae(this),e=>{(0,o.A)(nt,this,ge).emit(e)})),(0,r.A)(this,ct,ve(this)),(0,r.A)(this,dt,(xe(this),e=>{(0,o.A)(nt,this,fe).emit(e)})),(0,r.A)(this,pt,ke(this)),(0,r.A)(this,ht,(Te(this),()=>{(0,o.A)(nt,this,we).emit("chat")})),(0,r.A)(this,ut,Se(this)),(0,r.A)(this,mt,(Me(this),e=>{(0,o.A)(nt,this,Ne).emit(e)})),(0,r.A)(this,gt,(0,p.createRef)())}get conversationId(){return(0,c.A)(Oe,this)}set conversationId(e){(0,l.A)(Oe,this,e)}get initialRequest(){return(0,c.A)(ze,this)}set initialRequest(e){(0,l.A)(ze,this,e)}get replay(){return(0,c.A)(Pe,this)}set replay(e){(0,l.A)(Pe,this,e)}get replayDelay(){return(0,c.A)(Be,this)}set replayDelay(e){(0,l.A)(Be,this,e)}get supports(){return(0,c.A)(Ue,this)}set supports(e){(0,l.A)(Ue,this,e)}get showHiddenJobs(){return(0,c.A)(He,this)}set showHiddenJobs(e){(0,l.A)(He,this,e)}get showHumanActions(){return(0,c.A)(Fe,this)}set showHumanActions(e){(0,l.A)(Fe,this,e)}get showFeedback(){return(0,c.A)(Ge,this)}set showFeedback(e){(0,l.A)(Ge,this,e)}get showFeedbackAfterFailed(){return(0,c.A)(Ve,this)}set showFeedbackAfterFailed(e){(0,l.A)(Ve,this,e)}get showFeedbackOnView(){return(0,c.A)(je,this)}set showFeedbackOnView(e){(0,l.A)(je,this,e)}get showUiSwitch(){return(0,c.A)(Ke,this)}set showUiSwitch(e){(0,l.A)(Ke,this,e)}get hideMermaid(){return(0,c.A)($e,this)}set hideMermaid(e){(0,l.A)($e,this,e)}get showJsxEditor(){return(0,c.A)(Ye,this)}set showJsxEditor(e){(0,l.A)(Ye,this,e)}get previewUrlTemplate(){return(0,c.A)(qe,this)}set previewUrlTemplate(e){(0,l.A)(qe,this,e)}get showCases(){return(0,c.A)(Xe,this)}set showCases(e){(0,l.A)(Xe,this,e)}get exampleProjects(){return(0,c.A)(Je,this)}set exampleProjects(e){(0,l.A)(Je,this,e)}get tryItOutUrl(){return(0,c.A)(Qe,this)}set tryItOutUrl(e){(0,l.A)(Qe,this,e)}get separateInstructions(){return(0,c.A)(Ze,this)}set separateInstructions(e){(0,l.A)(Ze,this,e)}get uploadOptions(){return(0,c.A)(et,this)}set uploadOptions(e){(0,l.A)(et,this,e)}get toolbarBrick(){return(0,c.A)(tt,this)}set toolbarBrick(e){(0,l.A)(tt,this,e)}resumed(){var e,t;null===(e=(0,c.A)(gt,this).current)||void 0===e||null===(t=e.resumed)||void 0===t||t.call(e)}feedbackSubmitDone(){var e;null===(e=(0,c.A)(gt,this).current)||void 0===e||e.feedbackSubmitDone()}feedbackSubmitFailed(){var e;null===(e=(0,c.A)(gt,this).current)||void 0===e||e.feedbackSubmitFailed()}feedbackOnViewDone(e){var t;null===(t=(0,c.A)(gt,this).current)||void 0===t||t.feedbackOnViewDone(e)}render(){return h().createElement(De,{conversationId:this.conversationId,initialRequest:this.initialRequest,replay:this.replay,replayDelay:this.replayDelay,supports:this.supports,showHiddenJobs:this.showHiddenJobs,showHumanActions:this.showHumanActions,showFeedback:this.showFeedback,showFeedbackAfterFailed:this.showFeedbackAfterFailed,showUiSwitch:this.showUiSwitch,showFeedbackOnView:this.showFeedbackOnView,toolbarBrick:this.toolbarBrick,showJsxEditor:this.showJsxEditor,previewUrlTemplate:this.previewUrlTemplate,showCases:this.showCases,exampleProjects:this.exampleProjects,tryItOutUrl:this.tryItOutUrl,separateInstructions:this.separateInstructions,uploadOptions:this.uploadOptions,onShare:(0,c.A)(at,this),onTerminate:(0,c.A)(st,this),onSubmitFeedback:(0,c.A)(lt,this),onSwitchToChat:(0,c.A)(ht,this),onFeedbackOnView:(0,c.A)(dt,this),onDetailChange:(0,c.A)(mt,this),ref:(0,c.A)(gt,this)})}}n=bt,({e:[E,x,k,w,y,T,S,N,C,M,_,R,W,I,D,L,O,z,P,B,U,H,F,G,V,j,K,$,Y,q,X,J,Q,Z,ee,te,ie,ne,ae,re,se,oe,le,ce,de,pe,he,ue,me,ge,be,Ae,ve,fe,Ee,xe,ke,we,ye,Te,Se,Ne,Ce,Me,v],c:[Le,f]}=(0,d.A)(n,[_e("ai-portal.cruise-canvas",{shadowOptions:!1})],[[Re(),1,"conversationId"],[Re({attribute:!1,render:!1}),1,"initialRequest"],[Re({type:Boolean,render:!1}),1,"replay"],[Re({type:Number,render:!1}),1,"replayDelay"],[Re({attribute:!1}),1,"supports"],[Re({type:Boolean}),1,"showHiddenJobs"],[Re({type:Boolean}),1,"showHumanActions"],[Re({type:Boolean}),1,"showFeedback"],[Re({type:Boolean}),1,"showFeedbackAfterFailed"],[Re({type:Boolean}),1,"showFeedbackOnView"],[Re({type:Boolean}),1,"showUiSwitch"],[Re({type:Boolean,render:!1}),1,"hideMermaid"],[Re({type:Boolean}),1,"showJsxEditor"],[Re(),1,"previewUrlTemplate"],[Re({attribute:!1}),1,"showCases"],[Re({attribute:!1}),1,"exampleProjects"],[Re(),1,"tryItOutUrl"],[Re({type:Boolean}),1,"separateInstructions"],[Re({attribute:!1}),1,"uploadOptions"],[Re({attribute:!1}),1,"toolbarBrick"],[We({type:"share"}),1,"shareEvent",e=>(0,c.A)(it,e),(e,t)=>(0,l.A)(it,e,t)],[We({type:"terminate"}),1,"terminateEvent",e=>(0,c.A)(rt,e),(e,t)=>(0,l.A)(rt,e,t)],[We({type:"feedback.submit"}),1,"feedbackSubmitEvent",e=>(0,c.A)(ot,e),(e,t)=>(0,l.A)(ot,e,t)],[We({type:"feedback.on.view"}),1,"feedbackOnViewEvent",e=>(0,c.A)(ct,e),(e,t)=>(0,l.A)(ct,e,t)],[We({type:"ui.switch"}),1,"switch",e=>(0,c.A)(pt,e),(e,t)=>(0,l.A)(pt,e,t)],[We({type:"detail.change"}),1,"detailChange",e=>(0,c.A)(ut,e),(e,t)=>(0,l.A)(ut,e,t)],[Ie(),2,"resumed"],[Ie(),2,"feedbackSubmitDone"],[Ie(),2,"feedbackSubmitFailed"],[Ie(),2,"feedbackOnViewDone"]],0,(e=>gt.has((0,s.A)(e))),m.ReactNextElement)),f();var At=i(24586),vt=i(59435),ft=i(80592);let Et,xt;function kt(e,t){Et||(Et=document.createElement("div"),Et.setAttribute("tab-index","-1"),Et.setAttribute("aria-hidden","true"),document.body.appendChild(Et)),Et.setAttribute("style",(0,ft.w)(e)),Et.textContent=e.value.slice(0,t);const i=document.createElement("span");i.textContent="",Et.appendChild(i);const n=i.getBoundingClientRect();return i.remove(),{top:n.top,left:n.left}}function wt(e,t,i){xt||(xt=document.createElement("div"),xt.setAttribute("tab-index","-1"),xt.setAttribute("aria-hidden","true"),document.body.appendChild(xt)),xt.setAttribute("style",(0,ft.w)(e)),xt.textContent=t;const n=document.createElement("span");n.textContent=i,xt.appendChild(n);const a=n.getBoundingClientRect();if(n.remove(),i.length<=1)return[a];const r=i[0],s=document.createElement("span");s.textContent=r,xt.appendChild(s);const o=s.getBoundingClientRect();s.remove(),xt.textContent=`${t}${i.slice(0,-1)}`;const l=i[i.length-1],c=document.createElement("span");c.textContent=l,xt.appendChild(c);const d=c.getBoundingClientRect();if(c.remove(),o.top===d.top)return[a];const p=[];p.push(new DOMRect(o.left,o.top,a.right-o.left,o.bottom-o.top));const h=d.top-o.bottom;return h>=10&&p.push(new DOMRect(a.left,o.bottom,a.width,h)),p.push(new DOMRect(a.left,d.top,d.right-a.left,d.bottom-d.top)),p}var yt=i(92879);let Tt=function(e){return e.ASK_ANY_THING="ASK_ANYTHING",e.COMMON_TASKS="COMMON_TASKS",e}({});const St="bricks/ai-portal/chat-box",Nt={en:{[Tt.ASK_ANY_THING]:"Ask anything",[Tt.COMMON_TASKS]:"Common tasks"},zh:{[Tt.ASK_ANY_THING]:"询问任何问题",[Tt.COMMON_TASKS]:"常用任务"}},Ct=g.i18n.getFixedT(null,St);var Mt=i(47008),_t=i(77019);let Rt=null;function Wt(e){Rt=e}function It(){return Rt}customElements.define("ai-portal.set-chat-command",(0,_t.createProviderClass)(Wt));var Dt=i(57227),Lt=i(45387),Ot=i(51020);const zt=(0,m.wrapBrick)("eo-icon"),Pt=(0,m.wrapBrick)("eo-actions",{onActionClick:"action.click",onItemDragEnd:"item.drag.end",onItemDragStart:"item.drag.start"});(0,m.wrapBrick)("ai-portal.icon-button");var Bt,Ut=i(45889),Ht=i(21020);let Ft,Gt,Vt,jt,Kt,$t,Yt,qt,Xt,Jt,Qt,Zt,ei,ti,ii,ni,ai,ri,si,oi,li,ci,di,pi,hi,ui;(0,g.initializeI18n)(St,Nt);const{defineElement:mi,property:gi,event:bi,method:Ai}=(0,u.createDecorators)(),vi=(0,p.forwardRef)(Di);let fi;var Ei=new WeakMap,xi=new WeakMap,ki=new WeakMap,wi=new WeakMap,yi=new WeakMap,Ti=new WeakMap,Si=new WeakMap,Ni=new WeakSet,Ci=new WeakMap,Mi=new WeakMap,_i=new WeakMap,Ri=new WeakMap,Wi=new WeakMap;class Ii extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,Ni),(0,At.A)(this,"ref",(Ft(this),(0,p.createRef)())),(0,r.A)(this,Ei,Vt(this)),(0,r.A)(this,xi,(jt(this),Kt(this))),(0,r.A)(this,ki,($t(this),Yt(this))),(0,r.A)(this,wi,(qt(this),Xt(this))),(0,r.A)(this,yi,(Jt(this),Qt(this))),(0,r.A)(this,Ti,(Zt(this),ei(this))),(0,r.A)(this,Si,(ti(this),ii(this))),(0,r.A)(this,Ci,(ri(this),e=>{(0,o.A)(Ni,this,ni).emit(e)})),(0,r.A)(this,Mi,si(this)),(0,r.A)(this,_i,(ci(this),e=>{(0,o.A)(Ni,this,oi).emit(e)})),(0,r.A)(this,Ri,di(this)),(0,r.A)(this,Wi,(ui(this),e=>{(0,o.A)(Ni,this,pi).emit(e)}))}get disabled(){return(0,c.A)(Ei,this)}set disabled(e){(0,l.A)(Ei,this,e)}get placeholder(){return(0,c.A)(xi,this)}set placeholder(e){(0,l.A)(xi,this,e)}get autoFocus(){return(0,c.A)(ki,this)}set autoFocus(e){(0,l.A)(ki,this,e)}get aiEmployees(){return(0,c.A)(wi,this)}set aiEmployees(e){(0,l.A)(wi,this,e)}get commands(){return(0,c.A)(yi,this)}set commands(e){(0,l.A)(yi,this,e)}get uploadOptions(){return(0,c.A)(Ti,this)}set uploadOptions(e){(0,l.A)(Ti,this,e)}setValue(e){var t;null===(t=this.ref.current)||void 0===t||t.setValue(e)}getValue(){var e;return null===(e=this.ref.current)||void 0===e?void 0:e.getValue()}focusOnInput(){var e;return null===(e=this.ref.current)||void 0===e?void 0:e.focusOnInput()}render(){return h().createElement(vi,{disabled:this.disabled,placeholder:this.placeholder,autoFocus:this.autoFocus,aiEmployees:this.aiEmployees,commands:this.commands,uploadOptions:this.uploadOptions,onMessageSubmit:(0,c.A)(Ci,this),onChatSubmit:(0,c.A)(_i,this),onCommandSelect:(0,c.A)(Wi,this),ref:this.ref})}}function Di(e,t){let{disabled:i,placeholder:n,autoFocus:a,aiEmployees:r,commands:s,uploadOptions:o,onMessageSubmit:l,onChatSubmit:c,onCommandSelect:d}=e;const u=(0,p.useRef)(null),m=(0,p.useRef)(null),[g,b]=(0,p.useState)(""),A=(0,p.useRef)(""),[v,f]=(0,p.useState)(null),[E,x]=(0,p.useState)(null),[k,w]=(0,p.useState)(""),[y,T]=(0,p.useState)(0),[S,N]=(0,p.useState)([0]),[C,M]=(0,p.useState)(null),[_,R]=(0,p.useState)(null),[W,I]=(0,p.useState)(null),[D,L]=(0,p.useState)(null),[O,z]=(0,p.useState)(""),P=(0,p.useRef)(null),B=null==o?void 0:o.enabled,U=null==o?void 0:o.accept,{files:H,resetFiles:F,appendFiles:G,removeFile:V,hasFiles:j,allFilesDone:K,fileInfos:$,exceeded:Y,paste:q}=(0,Ut.O)(o);(0,p.useEffect)((()=>{B||F()}),[B,F]),(0,p.useEffect)((()=>{const e=window.__elevo_try_it_out;e&&delete window.__elevo_try_it_out,"string"==typeof(null==e?void 0:e.content)&&(A.current=e.content,b(e.content))}),[]),(0,p.useImperativeHandle)(t,(()=>({setValue:e=>{A.current=e,b(e)},getValue:()=>A.current,focusOnInput:()=>{var e;null===(e=m.current)||void 0===e||e.focus()}})));const X=(0,p.useCallback)((e=>{const t=e.slice(O.length||k.length);l(t),c({content:t,files:$,cmd:C,aiEmployeeId:_})}),[O.length,k.length,C,$,_,c,l]),J=(0,p.useCallback)((e=>{e.currentTarget.value&&K&&X(e.currentTarget.value)}),[X,K]),Q=(0,p.useCallback)((e=>{const{value:t,selectionStart:i,selectionEnd:n}=e.target;if(A.current=t,b(t),null!==i&&i===n&&null!=r&&r.length){const n=t.slice(0,i);if(n.startsWith("@")){const t=n.slice(1).toLowerCase(),a=r.filter((e=>e.employeeId.toLowerCase().includes(t)||e.name.toLowerCase().includes(t))).slice(0,10);if(a.length>0){const t=kt(e.currentTarget,i),n=e.currentTarget.getBoundingClientRect();return f({style:{left:t.left+10+n.left,top:t.top+22+n.top,position:"absolute",zIndex:1},range:{start:0,end:i},actions:a.map((e=>({key:e.employeeId,text:e.name,data:e})))}),void T(0)}}}if(f(null),null!==i&&i===n&&null!=s&&s.length){const n=t.slice(0,i);if(n.startsWith("/")){const t=n.slice(1).toLowerCase(),a=s.filter((e=>e.label.toLowerCase().includes(t))).slice(0,10);if(a.length>0){const t=kt(e.currentTarget,i),n=e.currentTarget.getBoundingClientRect();return I({style:{left:t.left+10+n.left,top:t.top+22+n.top,position:"absolute",zIndex:1},range:{start:0,end:i},actions:a.map((e=>({key:e.value,text:e.label,data:e,ancestors:[],items:Li(e,[]),payload:e.payload})))}),void N([0])}}}I(null)}),[r,s]);(0,p.useEffect)((()=>{k&&!g.includes(k)&&(w(""),R(null))}),[k,g]),(0,p.useEffect)((()=>{O&&!g.includes(O)&&(z(""),M(null),d(null))}),[O,d,g]);const Z=(0,p.useCallback)((()=>{X(A.current)}),[X]);(0,p.useEffect)((()=>{a&&Promise.resolve().then((()=>{var e;null===(e=m.current)||void 0===e||e.focus()}))}),[]),(0,p.useEffect)((()=>{var e;const t=null===(e=m.current)||void 0===e?void 0:e.element;if(!k||!t)return void x(null);const i=wt(t,"",k.slice(0,-1));x(i.map((e=>({left:e.left-1,top:e.top-1,width:e.width+4,height:e.height+4}))))}),[k,j]),(0,p.useEffect)((()=>{var e;const t=null===(e=m.current)||void 0===e?void 0:e.element;if(!O||!t)return void L(null);const i=wt(t,"",O.slice(0,-1));L(i.map((e=>({left:e.left-1,top:e.top-1,width:e.width+4,height:e.height+4}))))}),[O,j]);const ee=(0,p.useMemo)((()=>{const e=It();return e&&Wt(null),e}),[]);(0,p.useEffect)((()=>{ee&&(M(ee.payload),d(ee.payload))}),[ee,d]),(0,p.useEffect)((()=>{var e;const t=null===(e=m.current)||void 0===e?void 0:e.element;if(ee&&t){const e=`/${ee.command} `,i=wt(t,"",e.slice(0,-1));L(i.map((e=>({left:e.left-1,top:e.top-1,width:e.width+4,height:e.height+4})))),A.current=e,P.current={start:e.length,end:e.length},b(e),z(e)}}),[ee]);const te=(0,p.useCallback)((e=>{var t;const i=`@${e.text} `,n=`${A.current.slice(0,v.range.start)}${i}`,a=`${n}${A.current.slice(v.range.end)}`;A.current=a,P.current={start:n.length,end:n.length},b(a),w(i),f(null),R(e.data.employeeId),null===(t=m.current)||void 0===t||t.focus()}),[v]),ie=(0,p.useCallback)((e=>{var t;const i=`/${[...e.ancestors.map((e=>e.label)),e.text].join(": ")} `,n=`${A.current.slice(0,W.range.start)}${i}`,a=`${n}${A.current.slice(W.range.end)}`;A.current=a,P.current={start:n.length,end:n.length},b(a),z(i),I(null),M(e.payload),d(e.payload),null===(t=m.current)||void 0===t||t.focus()}),[W,d]),ne=(0,p.useCallback)((e=>{switch(e.key){case"Escape":if(!v&&!W)return;return e.preventDefault(),e.stopPropagation(),e.nativeEvent.stopImmediatePropagation(),f(null),I(null),!1;case"ArrowUp":case"ArrowDown":if(!v&&!W)return;return e.preventDefault(),e.stopPropagation(),e.nativeEvent.stopImmediatePropagation(),v?T((t=>{const i=t+("ArrowUp"===e.key?-1:1),n=v.actions.length;return(n+i)%n})):N((t=>{let i=0,{actions:n}=W;const a=[];for(;i<t.length-1;){const e=n[t[i]];if(!Oi(e))break;n=e.items,a.push(t[i]),i+=1}const r=t[i]+("ArrowUp"===e.key?-1:1),s=n.length,o=(s+r)%s;return a.push(o),a})),!1;case"Enter":case"ArrowLeft":case"ArrowRight":if(v){if("Enter"===e.key)return e.preventDefault(),e.stopPropagation(),e.nativeEvent.stopImmediatePropagation(),te(v.actions[y]),!1}else if(W){if(e.preventDefault(),e.stopPropagation(),e.nativeEvent.stopImmediatePropagation(),"ArrowLeft"===e.key)return S.length>1&&N((e=>e.slice(0,-1))),!1;let t,i=0,{actions:n}=W;for(;i<S.length&&(t=n[S[i]],Oi(t));)n=t.items,i+=1;return t&&(Oi(t)?N((e=>[...e,0])):"Enter"===e.key&&ie(t)),!1}break;case"Delete":case"Backspace":{const t=[{textLength:k.length,prefixLength:0},{textLength:O.length,prefixLength:0}];for(const{textLength:i,prefixLength:n}of t)if(i){let{selectionStart:t,selectionEnd:a}=e.currentTarget;t===a&&("Backspace"===e.key?t-=1:a+=1);const r=n,s=r+i;if(t<s&&a>r){const i=Math.min(t,r),n=Math.max(a,s),o=`${A.current.slice(0,i)}${A.current.slice(n)}`;return A.current=o,P.current={start:i,end:i},b(o),e.preventDefault(),e.stopPropagation(),!1}}break}}}),[y,S,W,O.length,te,ie,v,k.length]),ae=(0,p.useMemo)((()=>{if(!W)return[];let e=W.actions;const t=[];for(let i=0;i<S.length;i+=1){const n=e[S[i]];if(!n)break;if(!Oi(n)){t.push(n.key);break}t.push(n.key),e=n.items}return t}),[S,W]),re=(0,p.useRef)(null),se=(0,p.useCallback)((e=>{var t;G(e),null===(t=m.current)||void 0===t||t.focus()}),[G]),oe=!g||!K||!!k&&g.length<=k.length||!!O&&g.length<=O.length;return h().createElement(h().Fragment,null,h().createElement("div",{className:"root"},h().createElement("div",{className:"container",ref:u},h().createElement(yt.e,{containerRef:u,ref:m,value:g,minRows:58/22,paddingSize:j?144:60,autoResize:!0,disabled:i,placeholder:null!=n?n:Ct(Tt.ASK_ANY_THING),submitWhen:"enter-without-shift",desiredSelectionRef:P,onSubmit:J,onChange:Q,onKeyDown:ne,onPaste:q,style:{paddingTop:j?94:10}}),j&&h().createElement(Lt.C,{files:H,onRemove:(e,t)=>{V(e),null==t||t.abort()},onAdd:()=>{var e;null===(e=re.current)||void 0===e||e.requestUpload()}}),h().createElement("div",{className:"actions-bar"},h().createElement("div",null,h().createElement("slot",{name:"actions"})),h().createElement("div",{className:"buttons"},B?h().createElement(h().Fragment,null,h().createElement(Dt.s,{ref:re,accept:U,disabled:Y,onChange:e=>{var t;G(e),null===(t=m.current)||void 0===t||t.focus()}}),h().createElement("div",{className:"btn-divider"})):null,h().createElement("button",{className:"btn-send",disabled:oe,onClick:Z},h().createElement(zt,{lib:"fa",prefix:"fas",icon:"arrow-up"})))),null==E?void 0:E.map(((e,t)=>h().createElement("div",{key:t,className:"mention-overlay",style:e}))),null==D?void 0:D.map(((e,t)=>h().createElement("div",{key:t,className:"mention-overlay",style:e}))),v&&(0,vt.createPortal)(h().createElement(Pt,{actions:v.actions,style:v.style,activeKeys:[v.actions[y].key],onActionClick:e=>te(e.detail)}),document.body),W&&(0,vt.createPortal)(h().createElement(Pt,{actions:W.actions,style:W.style,activeKeys:ae,onActionClick:e=>ie(e.detail)}),document.body))),h().createElement(Ht.A,{disabled:!B||Y,uploadOptions:o,onFilesDropped:se}))}function Li(e,t){var i;return null===(i=e.options)||void 0===i?void 0:i.map((i=>{const n=[...t,e];return{key:i.value,text:i.label,data:i,ancestors:n,items:Li(i,n),payload:i.payload}}))}function Oi(e){var t;return!(null===(t=e.items)||void 0===t||!t.length)}Bt=Ii,({e:[Vt,jt,Kt,$t,Yt,qt,Xt,Jt,Qt,Zt,ei,ti,ii,ni,ai,ri,si,oi,li,ci,di,pi,hi,ui,Ft],c:[fi,Gt]}=(0,d.A)(Bt,[mi("ai-portal.chat-box",{styleTexts:[Mt.A,Ot.A],shadowOptions:{delegatesFocus:!0}})],[[gi({type:Boolean}),1,"disabled"],[gi(),1,"placeholder"],[gi({type:Boolean}),1,"autoFocus"],[gi({attribute:!1}),1,"aiEmployees"],[gi({attribute:!1}),1,"commands"],[gi({attribute:!1}),1,"uploadOptions"],[bi({type:"message.submit"}),1,"messageSubmit",e=>(0,c.A)(Si,e),(e,t)=>(0,l.A)(Si,e,t)],[bi({type:"chat.submit"}),1,"chatSubmit",e=>(0,c.A)(Mi,e),(e,t)=>(0,l.A)(Mi,e,t)],[bi({type:"command.select"}),1,"commandSelect",e=>(0,c.A)(Ri,e),(e,t)=>(0,l.A)(Ri,e,t)],[Ai(),2,"setValue"],[Ai(),2,"getValue"],[Ai(),2,"focusOnInput"]],0,(e=>Wi.has((0,s.A)(e))),m.ReactNextElement)),Gt();var zi,Pi=i(82165);let Bi,Ui,Hi;const{defineElement:Fi,property:Gi}=(0,u.createDecorators)();let Vi;var ji=new WeakMap;class Ki extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,ji,Ui(this)),Hi(this)}get sticky(){return(0,c.A)(ji,this)}set sticky(e){(0,l.A)(ji,this,e)}render(){return h().createElement($i,null)}}function $i(){return h().createElement("slot",null)}zi=Ki,({e:[Ui,Hi],c:[Vi,Bi]}=(0,d.A)(zi,[Fi("ai-portal.home-container",{styleTexts:[Pi.A]})],[[Gi({type:Boolean,render:!1}),1,"sticky"]],0,void 0,m.ReactNextElement)),Bi();var Yi,qi=i(89575),Xi=i(24);let Ji,Qi,Zi,en,tn,nn,an,rn,sn,on,ln,cn,dn,pn,hn,un,mn,gn,bn,An,vn;const fn=(0,m.wrapBrick)("eo-mini-line-chart"),{defineElement:En,property:xn}=(0,u.createDecorators)();let kn;var wn=new WeakMap,yn=new WeakMap,Tn=new WeakMap,Sn=new WeakMap,Nn=new WeakMap,Cn=new WeakMap,Mn=new WeakMap,_n=new WeakMap,Rn=new WeakMap,Wn=new WeakMap;class In extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,wn,Qi(this)),(0,r.A)(this,yn,(Zi(this),en(this))),(0,r.A)(this,Tn,(tn(this),nn(this))),(0,r.A)(this,Sn,(an(this),rn(this))),(0,r.A)(this,Nn,(sn(this),on(this))),(0,r.A)(this,Cn,(ln(this),cn(this))),(0,r.A)(this,Mn,(dn(this),pn(this))),(0,r.A)(this,_n,(hn(this),un(this))),(0,r.A)(this,Rn,(mn(this),gn(this))),(0,r.A)(this,Wn,(bn(this),An(this))),vn(this)}get label(){return(0,c.A)(wn,this)}set label(e){(0,l.A)(wn,this,e)}get value(){return(0,c.A)(yn,this)}set value(e){(0,l.A)(yn,this,e)}get size(){return(0,c.A)(Tn,this)}set size(e){(0,l.A)(Tn,this,e)}get lineColor(){return(0,c.A)(Sn,this)}set lineColor(e){(0,l.A)(Sn,this,e)}get showArea(){return(0,c.A)(Nn,this)}set showArea(e){(0,l.A)(Nn,this,e)}get min(){return(0,c.A)(Cn,this)}set min(e){(0,l.A)(Cn,this,e)}get max(){return(0,c.A)(Mn,this)}set max(e){(0,l.A)(Mn,this,e)}get xField(){return(0,c.A)(_n,this)}set xField(e){(0,l.A)(_n,this,e)}get yField(){return(0,c.A)(Rn,this)}set yField(e){(0,l.A)(Rn,this,e)}get data(){return(0,c.A)(Wn,this)}set data(e){(0,l.A)(Wn,this,e)}render(){return h().createElement(Dn,{label:this.label,value:this.value,size:this.size,lineColor:this.lineColor,showArea:this.showArea,min:this.min,max:this.max,xField:this.xField,yField:this.yField,data:this.data})}}function Dn(e){let{label:t,value:i,size:n,...a}=e;return"small"===n?h().createElement("div",{className:"container"},h().createElement("div",{className:"label-and-stat"},h().createElement("div",{className:"label"},t),h().createElement("div",{className:"stat"},i)),h().createElement("div",{className:"chart"},h().createElement(fn,(0,qi.A)({},a,{lineWidth:1.5,width:"auto",height:"55"})))):h().createElement("div",{className:"container"},h().createElement("div",{className:"label"},t),h().createElement("div",{className:"stat-and-chart"},h().createElement("div",{className:"chart"},h().createElement(fn,(0,qi.A)({},a,{lineWidth:2,width:"auto",height:"92"}))),h().createElement("div",{className:"stat"},i)))}Yi=In,({e:[Qi,Zi,en,tn,nn,an,rn,sn,on,ln,cn,dn,pn,hn,un,mn,gn,bn,An,vn],c:[kn,Ji]}=(0,d.A)(Yi,[En("ai-portal.stat-with-mini-chart",{styleTexts:[Xi.A]})],[[xn(),1,"label"],[xn(),1,"value"],[xn(),1,"size"],[xn(),1,"lineColor"],[xn({type:Boolean}),1,"showArea"],[xn({type:Number}),1,"min"],[xn({type:Number}),1,"max"],[xn(),1,"xField"],[xn(),1,"yField"],[xn({attribute:!1}),1,"data"]],0,void 0,m.ReactNextElement)),Ji();var Ln,On=i(30348),zn=i(53373),Pn=i.n(zn),Bn=i(5813),Un=i(61408),Hn=i(70579),Fn=i(75197),Gn=i(94504);let Vn,jn,Kn,$n,Yn,qn,Xn,Jn,Qn,Zn,ea,ta,ia,na,aa,ra,sa,oa,la,ca,da,pa,ha,ua,ma,ga,ba,Aa,va,fa,Ea,xa,ka,wa,ya,Ta,Sa,Na,Ca,Ma,_a,Ra;(0,g.initializeI18n)(Bn.NS,Bn.I);const Wa={lib:"easyops",icon:"sidebar"},Ia=(0,m.wrapBrick)("ai-portal.elevo-logo"),{defineElement:Da,property:La,event:Oa,method:za}=(0,u.createDecorators)(),Pa=(0,p.forwardRef)(cr);let Ba;var Ua=new WeakMap,Ha=new WeakMap,Fa=new WeakMap,Ga=new WeakMap,Va=new WeakMap,ja=new WeakMap,Ka=new WeakMap,$a=new WeakMap,Ya=new WeakMap,qa=new WeakMap,Xa=new WeakMap,Ja=new WeakMap,Qa=new WeakMap,Za=new WeakSet,er=new WeakMap,tr=new WeakMap,ir=new WeakMap,nr=new WeakMap,ar=new WeakMap,rr=new WeakMap,sr=new WeakMap,or=new WeakMap;class lr extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,Za),(0,r.A)(this,Ua,(Vn(this),Kn(this))),(0,r.A)(this,Ha,($n(this),Yn(this))),(0,r.A)(this,Fa,(qn(this),Xn(this))),(0,r.A)(this,Ga,(Jn(this),Qn(this))),(0,r.A)(this,Va,(Zn(this),ea(this))),(0,r.A)(this,ja,(ta(this),ia(this))),(0,r.A)(this,Ka,(na(this),aa(this))),(0,r.A)(this,$a,(ra(this),sa(this))),(0,r.A)(this,Ya,(oa(this),la(this))),(0,r.A)(this,qa,(ca(this),da(this))),(0,r.A)(this,Xa,(pa(this),ha(this,!0))),(0,r.A)(this,Ja,(ua(this),ma(this))),(0,r.A)(this,Qa,(ga(this),ba(this))),(0,r.A)(this,er,(fa(this),()=>{(0,o.A)(Za,this,Aa).emit()})),(0,r.A)(this,tr,Ea(this)),(0,r.A)(this,ir,(wa(this),e=>{(0,o.A)(Za,this,xa).emit(e)})),(0,r.A)(this,nr,ya(this)),(0,r.A)(this,ar,(Na(this),e=>{(0,o.A)(Za,this,Ta).emit(e)})),(0,r.A)(this,rr,Ca(this)),(0,r.A)(this,sr,(Ra(this),()=>{(0,o.A)(Za,this,Ma).emit()})),(0,r.A)(this,or,(0,p.createRef)())}get userInstanceId(){return(0,c.A)(Ua,this)}set userInstanceId(e){(0,l.A)(Ua,this,e)}get behavior(){return(0,c.A)(Ha,this)}set behavior(e){(0,l.A)(Ha,this,e)}get logoUrl(){return(0,c.A)(Fa,this)}set logoUrl(e){(0,l.A)(Fa,this,e)}get newChatUrl(){return(0,c.A)(Ga,this)}set newChatUrl(e){(0,l.A)(Ga,this,e)}get newChatLinkWhenCollapsed(){return(0,c.A)(Va,this)}set newChatLinkWhenCollapsed(e){(0,l.A)(Va,this,e)}get historyUrlTemplate(){return(0,c.A)(ja,this)}set historyUrlTemplate(e){(0,l.A)(ja,this,e)}get historyActions(){return(0,c.A)(Ka,this)}set historyActions(e){(0,l.A)(Ka,this,e)}get projectUrlTemplate(){return(0,c.A)($a,this)}set projectUrlTemplate(e){(0,l.A)($a,this,e)}get projectActions(){return(0,c.A)(Ya,this)}set projectActions(e){(0,l.A)(Ya,this,e)}get links(){return(0,c.A)(qa,this)}set links(e){(0,l.A)(qa,this,e)}get canAddProject(){return(0,c.A)(Xa,this)}set canAddProject(e){(0,l.A)(Xa,this,e)}get myLinks(){return(0,c.A)(Ja,this)}set myLinks(e){(0,l.A)(Ja,this,e)}pullHistory(e){setTimeout((()=>{var e;null===(e=(0,c.A)(or,this).current)||void 0===e||e.pull()}),e)}open(){var e;null===(e=(0,c.A)(or,this).current)||void 0===e||e.open()}close(){var e;null===(e=(0,c.A)(or,this).current)||void 0===e||e.close()}removeProject(e){var t,i;null===(t=(0,c.A)(or,this).current)||void 0===t||null===(i=t.removeProject)||void 0===i||i.call(t,e)}addProject(e){var t,i;null===(t=(0,c.A)(or,this).current)||void 0===t||null===(i=t.addProject)||void 0===i||i.call(t,e)}moveConversation(e){var t,i;null===(t=(0,c.A)(or,this).current)||void 0===t||null===(i=t.moveConversation)||void 0===i||i.call(t,e)}render(){return h().createElement(Pa,{ref:(0,c.A)(or,this),userInstanceId:this.userInstanceId,behavior:this.behavior,logoUrl:this.logoUrl,newChatUrl:this.newChatUrl,newChatLinkWhenCollapsed:this.newChatLinkWhenCollapsed,historyUrlTemplate:this.historyUrlTemplate,historyActions:this.historyActions,projectUrlTemplate:this.projectUrlTemplate,projectActions:this.projectActions,links:this.links,canAddProject:this.canAddProject,myLinks:this.myLinks,onLogout:(0,c.A)(er,this),onActionClick:(0,c.A)(ir,this),onProjectActionClick:(0,c.A)(ar,this),onAddProject:(0,c.A)(sr,this)})}}function cr(e,t){let{userInstanceId:i,behavior:n,logoUrl:a,newChatUrl:r,newChatLinkWhenCollapsed:s,historyUrlTemplate:o,historyActions:l,projectUrlTemplate:c,projectActions:d,links:u,canAddProject:m,myLinks:b,onLogout:A,onActionClick:v,onProjectActionClick:f,onAddProject:E}=e;const[x,k]=(0,p.useState)("drawer"===n),w=(0,p.useCallback)((()=>{k(!0)}),[]),y=(0,p.useCallback)((()=>{k(!1)}),[]);(0,p.useEffect)((()=>{"drawer"===n&&k(!0)}),[n]);const T=(0,p.useCallback)((()=>{k(!0)}),[]),S=(0,p.useCallback)((()=>{"drawer"===n&&k(!0)}),[n]),N=(0,p.useMemo)((()=>[{key:"logout",icon:{lib:"fa",prefix:"fas",icon:"arrow-right-from-bracket"},text:(0,Bn.t)(Bn.K.LOGOUT)},{key:"switch-language",icon:{lib:"easyops",icon:"language"},text:(0,Bn.t)(Bn.K.SWITCH_LANGUAGE)}]),[]),C=(0,p.useRef)(null);return(0,p.useImperativeHandle)(t,(()=>({close:()=>{k(!0)},pull:()=>{var e;null===(e=C.current)||void 0===e||e.pull()},removeProject:e=>{var t,i;null===(t=C.current)||void 0===t||null===(i=t.removeProject)||void 0===i||i.call(t,e)},addProject:e=>{var t,i;null===(t=C.current)||void 0===t||null===(i=t.addProject)||void 0===i||i.call(t,e)},moveConversation:e=>{var t,i;null===(t=C.current)||void 0===t||null===(i=t.moveConversation)||void 0===i||i.call(t,e)},open:()=>{k(!1)}})),[]),h().createElement("div",{className:Pn()("container",{collapsed:x})},"drawer"===n&&!x&&h().createElement("div",{className:"mask",onClick:T}),h().createElement("div",{className:"alternative"},h().createElement(Hn.Py,{icon:Wa,variant:"light",onClick:y}),s&&h().createElement(Hn.EM,{className:"new-chat",url:r},h().createElement(Hn.Bj,{className:"new-chat-icon",lib:"easyops",icon:"new-chat"}),(0,Bn.t)(Bn.K.NEW_CHAT))),h().createElement("div",{className:"sidebar"},h().createElement("div",{className:"logo-bar"},h().createElement(Hn.EM,{url:a,className:"logo-link"},h().createElement(Ia,null)),h().createElement(Hn.Py,{icon:Wa,variant:"light",onClick:w})),h().createElement(Hn.EM,{className:"new-chat",url:r},h().createElement(Hn.Bj,{className:"new-chat-icon",lib:"easyops",icon:"new-chat"}),(0,Bn.t)(Bn.K.NEW_CHAT)),null!=u&&u.length?h().createElement("div",{className:"links"},u.map(((e,t)=>h().createElement(Gn.k,{key:t,url:e.url,activeIncludes:e.activeIncludes,render:i=>{let{active:n}=i;return h().createElement(Hn.EM,{key:t,className:Pn()("link",{active:n}),url:e.url},h().createElement(Hn.Bj,(0,qi.A)({className:"icon"},e.icon)),h().createElement("span",{className:"title"},e.title))}})))):null,h().createElement(Fn.D,{ref:C,canAddProject:m,historyUrlTemplate:o,historyActions:l,projectUrlTemplate:c,projectActions:d,myLinks:b,onActionClick:v,onHistoryClick:S,onProjectActionClick:f,onAddProject:E}),h().createElement("div",{className:"footer"},h().createElement(Hn.qb,{className:"dropdown",actions:N,onActionClick:async e=>{"logout"===e.detail.key?A():(await g.i18n.changeLanguage(g.i18n.language&&"en"===g.i18n.language.split("-")[0]?"zh":"en"),(0,On.getHistory)().reload())}},h().createElement("button",{className:"account"},h().createElement(Hn.JQ,{nameOrInstanceId:i,showName:!0,size:"xs"}))))))}Ln=lr,({e:[Kn,$n,Yn,qn,Xn,Jn,Qn,Zn,ea,ta,ia,na,aa,ra,sa,oa,la,ca,da,pa,ha,ua,ma,ga,ba,Aa,va,fa,Ea,xa,ka,wa,ya,Ta,Sa,Na,Ca,Ma,_a,Ra,Vn],c:[Ba,jn]}=(0,d.A)(Ln,[Da("ai-portal.elevo-sidebar",{styleTexts:[Un.A]})],[[La(),1,"userInstanceId"],[La(),1,"behavior"],[La(),1,"logoUrl"],[La(),1,"newChatUrl"],[La({type:Boolean}),1,"newChatLinkWhenCollapsed"],[La(),1,"historyUrlTemplate"],[La({attribute:!1}),1,"historyActions"],[La(),1,"projectUrlTemplate"],[La({attribute:!1}),1,"projectActions"],[La({attribute:!1}),1,"links"],[La({type:Boolean}),1,"canAddProject"],[La({attribute:!1}),1,"myLinks"],[Oa({type:"logout"}),1,"logout",e=>(0,c.A)(Qa,e),(e,t)=>(0,l.A)(Qa,e,t)],[Oa({type:"action.click"}),1,"actionClick",e=>(0,c.A)(tr,e),(e,t)=>(0,l.A)(tr,e,t)],[Oa({type:"project.action.click"}),1,"projectActionClick",e=>(0,c.A)(nr,e),(e,t)=>(0,l.A)(nr,e,t)],[Oa({type:"add.project"}),1,"addProject",e=>(0,c.A)(rr,e),(e,t)=>(0,l.A)(rr,e,t)],[za(),2,"pullHistory"],[za(),2,"open"],[za(),2,"close"],[za(),2,"removeProject"],[za(),2,"addProject"],[za(),2,"moveConversation"]],0,(e=>or.has((0,s.A)(e))),m.ReactNextElement)),jn();var dr,pr=i(47338);function hr(e){const[t,i]=(0,p.useState)(!1);return(0,p.useEffect)((()=>{const t=e.current;if(!t)return;const n=()=>{i(t.assignedNodes().length>0)};return n(),t.addEventListener("slotchange",n),()=>{t.removeEventListener("slotchange",n)}}),[e]),t}let ur,mr,gr,br,Ar,vr,fr,Er,xr,kr,wr;const yr=(0,m.wrapBrick)("eo-icon"),Tr=(0,m.wrapBrick)("eo-tooltip"),{defineElement:Sr,property:Nr}=(0,u.createDecorators)();let Cr;var Mr=new WeakMap,_r=new WeakMap,Rr=new WeakMap,Wr=new WeakMap,Ir=new WeakMap;class Dr extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,Mr,mr(this)),(0,r.A)(this,_r,(gr(this),br(this))),(0,r.A)(this,Rr,(Ar(this),vr(this))),(0,r.A)(this,Wr,(fr(this),Er(this))),(0,r.A)(this,Ir,(xr(this),kr(this))),wr(this)}get icon(){return(0,c.A)(Mr,this)}set icon(e){(0,l.A)(Mr,this,e)}get tooltip(){return(0,c.A)(_r,this)}set tooltip(e){(0,l.A)(_r,this,e)}get tooltipHoist(){return(0,c.A)(Rr,this)}set tooltipHoist(e){(0,l.A)(Rr,this,e)}get disabled(){return(0,c.A)(Wr,this)}set disabled(e){(0,l.A)(Wr,this,e)}get variant(){return(0,c.A)(Ir,this)}set variant(e){(0,l.A)(Ir,this,e)}render(){return h().createElement(Lr,{icon:this.icon,tooltip:this.tooltip,tooltipHoist:this.tooltipHoist,disabled:this.disabled})}}function Lr(e){let{icon:t,tooltip:i,tooltipHoist:n,disabled:a}=e;const r=(0,p.useRef)(null),s=hr(r),o=h().createElement("button",{disabled:a,className:s?"has-slotted":""},h().createElement(yr,(0,qi.A)({className:"icon"},t)),h().createElement("slot",{ref:r}));return i?h().createElement(Tr,{content:i,hoist:n},o):o}dr=Dr,({e:[mr,gr,br,Ar,vr,fr,Er,xr,kr,wr],c:[Cr,ur]}=(0,d.A)(dr,[Sr("ai-portal.icon-button",{styleTexts:[pr.A]})],[[Nr({attribute:!1}),1,"icon"],[Nr(),1,"tooltip"],[Nr({type:Boolean}),1,"tooltipHoist"],[Nr({type:Boolean}),1,"disabled"],[Nr({render:!1}),1,"variant"]],0,void 0,m.ReactNextElement)),ur();let Or=function(e){return e.ALL="ALL",e.EXPLORE_EXCELLENT_CASES="EXPLORE_EXCELLENT_CASES",e}({});const zr="bricks/ai-portal/show-cases",Pr={en:{[Or.ALL]:"All",[Or.EXPLORE_EXCELLENT_CASES]:"Explore excellent cases"},zh:{[Or.ALL]:"全部",[Or.EXPLORE_EXCELLENT_CASES]:"探索优秀案例"}},Br=g.i18n.getFixedT(null,zr);var Ur,Hr=i(42873);let Fr,Gr,Vr,jr,Kr;(0,g.initializeI18n)(zr,Pr);const $r=(0,m.wrapBrick)("ai-portal.show-case"),Yr=(0,m.wrapBrick)("ai-portal.tab-list",{onTabClick:"tab.click"}),{defineElement:qr,property:Xr}=(0,u.createDecorators)();let Jr;var Qr=new WeakMap,Zr=new WeakMap;class es extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,Qr,Gr(this)),(0,r.A)(this,Zr,(Vr(this),jr(this))),Kr(this)}get list(){return(0,c.A)(Qr,this)}set list(e){(0,l.A)(Qr,this,e)}get limit(){return(0,c.A)(Zr,this)}set limit(e){(0,l.A)(Zr,this,e)}render(){return h().createElement(ts,{list:this.list,limit:this.limit})}}function ts(e){let{list:t,limit:i}=e;const n=(0,p.useMemo)((()=>["",...new Set(null==t?void 0:t.map((e=>e.scenario)).filter(Boolean))]),[t]),[a,r]=(0,p.useState)(""),s=(0,p.useMemo)((()=>{if(!t)return;let e=t;return a&&(e=e.filter((e=>e.scenario===a))),i&&(e=e.slice(0,i)),e}),[a,t,i]),o=(0,p.useMemo)((()=>n.map((e=>({id:e,label:""===e?Br(Or.ALL):e})))),[n]);return null!=t&&t.length?h().createElement(h().Fragment,null,h().createElement("div",{className:"tips"},`${Br(Or.EXPLORE_EXCELLENT_CASES)} ↓`),h().createElement(Yr,{tabs:o,activeTab:a,onTabClick:e=>r(e.detail.id)}),h().createElement("ul",{className:"cases"},null==s?void 0:s.map((e=>h().createElement("li",{key:e.conversationId},h().createElement($r,{caseTitle:e.title,summary:e.summary,url:e.url})))))):null}Ur=es,({e:[Gr,Vr,jr,Kr],c:[Jr,Fr]}=(0,d.A)(Ur,[qr("ai-portal.show-cases",{styleTexts:[Hr.A]})],[[Xr({attribute:!1}),1,"list"],[Xr({type:Number}),1,"limit"]],0,void 0,m.ReactNextElement)),Fr();let is=function(e){return e.MCP_HUB="MCP_HUB",e.ALL="ALL",e.SERVER_cmdb="SERVER_cmdb",e.SERVER_cmdb_product_helper="SERVER_cmdb_product_helper",e.SERVER_alert="SERVER_alert",e.SERVER_web_builder="SERVER_web_builder",e.SERVER_web_builder2="SERVER_web_builder2",e.SERVER_host_troubleshooting="SERVER_host_troubleshooting",e.SERVER_system_inspection="SERVER_system_inspection",e.SERVER_grafana="SERVER_grafana",e.SERVER_kubernetes="SERVER_kubernetes",e.SERVER_llm="SERVER_llm",e}({});const ns="bricks/ai-portal/mcp-tools",as={en:{[is.MCP_HUB]:"MCP Hub",[is.ALL]:"All",[is.SERVER_cmdb]:"CMDB",[is.SERVER_cmdb_product_helper]:"CMDB",[is.SERVER_alert]:"Alert",[is.SERVER_web_builder]:"View",[is.SERVER_web_builder2]:"View",[is.SERVER_host_troubleshooting]:"Host Troubleshooting",[is.SERVER_system_inspection]:"System Inspection",[is.SERVER_grafana]:"Grafana",[is.SERVER_kubernetes]:"Kubernetes",[is.SERVER_llm]:"LLM"},zh:{[is.MCP_HUB]:"MCP 中心",[is.ALL]:"全部",[is.SERVER_cmdb]:"CMDB",[is.SERVER_cmdb_product_helper]:"CMDB",[is.SERVER_alert]:"告警",[is.SERVER_web_builder]:"视图",[is.SERVER_web_builder2]:"视图",[is.SERVER_host_troubleshooting]:"主机故障排查",[is.SERVER_system_inspection]:"系统巡检",[is.SERVER_grafana]:"Grafana",[is.SERVER_kubernetes]:"Kubernetes",[is.SERVER_llm]:"大模型"}},rs=g.i18n.getFixedT(null,ns);var ss,os=i(31748);let ls,cs,ds,ps,hs;(0,g.initializeI18n)(ns,as);const us={lib:"antd",icon:"tool"},ms=new Map([["EasyOps平台",{servers:["cmdb","cmdb_product_helper"]}],["Grafana",{servers:["grafana"]}],["Kubernetes",{servers:["kubernetes"]}],["监控事件",{servers:["alert"]}],["浏览器",{servers:["playwright"]}],["低代码",{servers:["web-builder","web-builder2"]}],["大模型",{servers:["llm"]}],["故障排查",{servers:["host-troubleshooting"]}]]),gs=(0,m.wrapBrick)("eo-icon"),bs=(0,m.wrapBrick)("ai-portal.tab-list",{onTabClick:"tab.click"}),As=(0,m.wrapBrick)("ai-portal.sticky-container"),{defineElement:vs,property:fs}=(0,u.createDecorators)();let Es;var xs=new WeakMap,ks=new WeakMap;class ws extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,xs,cs(this)),(0,r.A)(this,ks,(ds(this),ps(this))),hs(this)}get list(){return(0,c.A)(xs,this)}set list(e){(0,l.A)(xs,this,e)}get stickyTop(){return(0,c.A)(ks,this)}set stickyTop(e){(0,l.A)(ks,this,e)}render(){return h().createElement(ys,{list:this.list,stickyTop:this.stickyTop})}}function ys(e){let{list:t,stickyTop:i}=e;const[n,a]=(0,p.useMemo)((()=>{const e=new Map,i=new Map;null==t||t.forEach((t=>{const n=rs(`SERVER_${t.server.id.replaceAll("-","_")}`,t.server.name);let a=e.get(n);a||e.set(n,a=[]),a.push(t);const r=[...ms.entries()].find((e=>{let[i,{servers:n}]=e;return n.includes(t.server.id)})),s=r?r[0]:"其他";let o=i.get(s);o||i.set(s,o=[]),o.push(n)}));const n=["CMDB"];return[new Map([...e.entries()].sort(((e,t)=>{let[i]=e,[a]=t;const r=n.indexOf(i),s=n.indexOf(a);return(r<0?n.length:r)-(s<0?n.length:s)}))),i]}),[t]),r=(0,p.useMemo)((()=>{const e=[...ms.keys()],t=[...a.keys()];return t.sort(((t,i)=>{const n=e.indexOf(t),a=e.indexOf(i);return(n<0?e.length:n)-(a<0?e.length:a)})),["",...t]}),[a]),[s,o]=(0,p.useState)(""),l=(0,p.useMemo)((()=>{const e=[...n];if(!s)return e;const t=a.get(s);return e.filter((e=>{let[i]=e;return null==t?void 0:t.includes(i)}))}),[s,n,a]),c=(0,p.useMemo)((()=>r.map((e=>({id:e,label:""===e?rs(is.ALL):e})))),[r]),d=h().createElement(bs,{tabs:c,activeTab:s,onTabClick:e=>o(e.detail.id)});return h().createElement(h().Fragment,null,null==i?h().createElement("div",{className:"non-sticky-tabs"},d):h().createElement(As,{className:"sticky-tabs",style:{top:i}},d),h().createElement("ul",{className:"groups"},null==l?void 0:l.map((e=>{let[t,i]=e;return h().createElement("li",{key:t,className:"group"},h().createElement("h2",null,t),h().createElement("ul",{className:"list"},i.map(((e,t)=>{var i;return h().createElement("li",{key:t,className:"item"},h().createElement("div",{className:"heading"},h().createElement(gs,(0,qi.A)({className:"icon"},null!==(i=e.icon)&&void 0!==i?i:us,{fallback:us})),h().createElement("div",{className:"title"},e.title)),h().createElement("div",{className:"description"},e.description))}))))}))))}ss=ws,({e:[cs,ds,ps,hs],c:[Es,ls]}=(0,d.A)(ss,[vs("ai-portal.mcp-tools",{styleTexts:[os.A]})],[[fs({attribute:!1}),1,"list"],[fs({type:Number}),1,"stickyTop"]],0,void 0,m.ReactNextElement)),ls();var Ts,Ss=i(48952),Ns=i(62232);let Cs,Ms,_s,Rs,Ws,Is,Ds,Ls,Os,zs,Ps,Bs,Us,Hs,Fs,Gs,Vs,js,Ks,$s,Ys,qs,Xs,Js,Qs,Zs,eo,to,io,no,ao,ro,so,oo,lo,co,po,ho,uo,mo,go,bo,Ao,vo,fo,Eo,xo,ko,wo,yo,To,So,No,Co,Mo,_o,Ro,Wo,Io,Do,Lo,Oo,zo,Po,Bo,Uo,Ho,Fo,Go,Vo,jo,Ko;(0,g.initializeI18n)(Ss.NS,Ss.I);const{defineElement:$o,property:Yo,event:qo,method:Xo}=(0,u.createDecorators)(),Jo=(0,p.forwardRef)(Ns.C);let Qo;var Zo=new WeakMap,el=new WeakMap,tl=new WeakMap,il=new WeakMap,nl=new WeakMap,al=new WeakMap,rl=new WeakMap,sl=new WeakMap,ol=new WeakMap,ll=new WeakMap,cl=new WeakMap,dl=new WeakMap,pl=new WeakMap,hl=new WeakMap,ul=new WeakMap,ml=new WeakMap,gl=new WeakMap,bl=new WeakMap,Al=new WeakMap,vl=new WeakMap,fl=new WeakSet,El=new WeakMap,xl=new WeakMap,kl=new WeakMap,wl=new WeakMap,yl=new WeakMap,Tl=new WeakMap,Sl=new WeakMap,Nl=new WeakMap,Cl=new WeakMap,Ml=new WeakMap,_l=new WeakMap,Rl=new WeakMap,Wl=new WeakMap,Il=new WeakMap,Dl=new WeakMap,Ll=new WeakMap;class Ol extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,fl),(0,r.A)(this,Zo,(Cs(this),_s(this))),(0,r.A)(this,el,(Rs(this),Ws(this))),(0,r.A)(this,tl,(Is(this),Ds(this))),(0,r.A)(this,il,(Ls(this),Os(this))),(0,r.A)(this,nl,(zs(this),Ps(this))),(0,r.A)(this,al,(Bs(this),Us(this))),(0,r.A)(this,rl,(Hs(this),Fs(this))),(0,r.A)(this,sl,(Gs(this),Vs(this))),(0,r.A)(this,ol,(js(this),Ks(this))),(0,r.A)(this,ll,($s(this),Ys(this))),(0,r.A)(this,cl,(qs(this),Xs(this))),(0,r.A)(this,dl,(Js(this),Qs(this))),(0,r.A)(this,pl,(Zs(this),eo(this))),(0,r.A)(this,hl,(to(this),io(this))),(0,r.A)(this,ul,(no(this),ao(this))),(0,r.A)(this,ml,(ro(this),so(this))),(0,r.A)(this,gl,(oo(this),lo(this))),(0,r.A)(this,bl,(co(this),po(this))),(0,r.A)(this,Al,(ho(this),uo(this))),(0,r.A)(this,vl,(mo(this),go(this))),(0,r.A)(this,El,(vo(this),()=>{(0,o.A)(fl,this,bo).emit()})),(0,r.A)(this,xl,fo(this)),(0,r.A)(this,kl,(ko(this),()=>{(0,o.A)(fl,this,Eo).emit()})),(0,r.A)(this,wl,wo(this)),(0,r.A)(this,yl,(So(this),e=>{(0,o.A)(fl,this,yo).emit(e)})),(0,r.A)(this,Tl,No(this)),(0,r.A)(this,Sl,(_o(this),e=>{(0,o.A)(fl,this,Co).emit(e)})),(0,r.A)(this,Nl,Ro(this)),(0,r.A)(this,Cl,(Do(this),()=>{(0,o.A)(fl,this,Wo).emit("canvas")})),(0,r.A)(this,Ml,Lo(this)),(0,r.A)(this,_l,(Po(this),e=>{(0,o.A)(fl,this,Oo).emit(e)})),(0,r.A)(this,Rl,Bo(this)),(0,r.A)(this,Wl,(Fo(this),()=>{(0,o.A)(fl,this,Uo).emit()})),(0,r.A)(this,Il,Go(this)),(0,r.A)(this,Dl,(Ko(this),e=>{(0,o.A)(fl,this,Vo).emit(e)})),(0,r.A)(this,Ll,(0,p.createRef)())}get conversationId(){return(0,c.A)(Zo,this)}set conversationId(e){(0,l.A)(Zo,this,e)}get initialRequest(){return(0,c.A)(el,this)}set initialRequest(e){(0,l.A)(el,this,e)}get replay(){return(0,c.A)(tl,this)}set replay(e){(0,l.A)(tl,this,e)}get replayDelay(){return(0,c.A)(il,this)}set replayDelay(e){(0,l.A)(il,this,e)}get supports(){return(0,c.A)(nl,this)}set supports(e){(0,l.A)(nl,this,e)}get showHumanActions(){return(0,c.A)(al,this)}set showHumanActions(e){(0,l.A)(al,this,e)}get showFeedback(){return(0,c.A)(rl,this)}set showFeedback(e){(0,l.A)(rl,this,e)}get showFeedbackAfterFailed(){return(0,c.A)(sl,this)}set showFeedbackAfterFailed(e){(0,l.A)(sl,this,e)}get showFeedbackOnView(){return(0,c.A)(ol,this)}set showFeedbackOnView(e){(0,l.A)(ol,this,e)}get showUiSwitch(){return(0,c.A)(ll,this)}set showUiSwitch(e){(0,l.A)(ll,this,e)}get hideMermaid(){return(0,c.A)(cl,this)}set hideMermaid(e){(0,l.A)(cl,this,e)}get previewUrlTemplate(){return(0,c.A)(dl,this)}set previewUrlTemplate(e){(0,l.A)(dl,this,e)}get showCases(){return(0,c.A)(pl,this)}set showCases(e){(0,l.A)(pl,this,e)}get exampleProjects(){return(0,c.A)(hl,this)}set exampleProjects(e){(0,l.A)(hl,this,e)}get tryItOutUrl(){return(0,c.A)(ul,this)}set tryItOutUrl(e){(0,l.A)(ul,this,e)}get uploadOptions(){return(0,c.A)(ml,this)}set uploadOptions(e){(0,l.A)(ml,this,e)}get notices(){return(0,c.A)(gl,this)}set notices(e){(0,l.A)(gl,this,e)}get showNoticeIcon(){return(0,c.A)(bl,this)}set showNoticeIcon(e){(0,l.A)(bl,this,e)}get noticeUrlTemplate(){return(0,c.A)(Al,this)}set noticeUrlTemplate(e){(0,l.A)(Al,this,e)}resumed(){var e,t;null===(e=(0,c.A)(Ll,this).current)||void 0===e||null===(t=e.resumed)||void 0===t||t.call(e)}feedbackSubmitDone(){var e;null===(e=(0,c.A)(Ll,this).current)||void 0===e||e.feedbackSubmitDone()}feedbackSubmitFailed(){var e;null===(e=(0,c.A)(Ll,this).current)||void 0===e||e.feedbackSubmitFailed()}feedbackOnViewDone(e){var t;null===(t=(0,c.A)(Ll,this).current)||void 0===t||t.feedbackOnViewDone(e)}render(){return h().createElement(Jo,{conversationId:this.conversationId,initialRequest:this.initialRequest,replay:this.replay,replayDelay:this.replayDelay,supports:this.supports,showHumanActions:this.showHumanActions,showFeedback:this.showFeedback,showFeedbackAfterFailed:this.showFeedbackAfterFailed,showFeedbackOnView:this.showFeedbackOnView,showUiSwitch:this.showUiSwitch,showNoticeIcon:this.showNoticeIcon,previewUrlTemplate:this.previewUrlTemplate,noticeUrlTemplate:this.noticeUrlTemplate,showCases:this.showCases,exampleProjects:this.exampleProjects,tryItOutUrl:this.tryItOutUrl,uploadOptions:this.uploadOptions,notices:this.notices,onShare:(0,c.A)(El,this),onTerminate:(0,c.A)(kl,this),onSubmitFeedback:(0,c.A)(yl,this),onSwitchToCanvas:(0,c.A)(Cl,this),onFeedbackOnView:(0,c.A)(Sl,this),onDetailChange:(0,c.A)(_l,this),onMarkNoticesRead:(0,c.A)(Wl,this),onNoticeClick:(0,c.A)(Dl,this),ref:(0,c.A)(Ll,this)})}}Ts=Ol,({e:[_s,Rs,Ws,Is,Ds,Ls,Os,zs,Ps,Bs,Us,Hs,Fs,Gs,Vs,js,Ks,$s,Ys,qs,Xs,Js,Qs,Zs,eo,to,io,no,ao,ro,so,oo,lo,co,po,ho,uo,mo,go,bo,Ao,vo,fo,Eo,xo,ko,wo,yo,To,So,No,Co,Mo,_o,Ro,Wo,Io,Do,Lo,Oo,zo,Po,Bo,Uo,Ho,Fo,Go,Vo,jo,Ko,Cs],c:[Qo,Ms]}=(0,d.A)(Ts,[$o("ai-portal.chat-stream",{shadowOptions:!1})],[[Yo(),1,"conversationId"],[Yo({attribute:!1,render:!1}),1,"initialRequest"],[Yo({type:Boolean}),1,"replay"],[Yo({type:Number}),1,"replayDelay"],[Yo({attribute:!1}),1,"supports"],[Yo({type:Boolean}),1,"showHumanActions"],[Yo({type:Boolean}),1,"showFeedback"],[Yo({type:Boolean}),1,"showFeedbackAfterFailed"],[Yo({type:Boolean}),1,"showFeedbackOnView"],[Yo({type:Boolean}),1,"showUiSwitch"],[Yo({type:Boolean,render:!1}),1,"hideMermaid"],[Yo(),1,"previewUrlTemplate"],[Yo({attribute:!1}),1,"showCases"],[Yo({attribute:!1}),1,"exampleProjects"],[Yo(),1,"tryItOutUrl"],[Yo({attribute:!1}),1,"uploadOptions"],[Yo({attribute:!1}),1,"notices"],[Yo({type:Boolean}),1,"showNoticeIcon"],[Yo(),1,"noticeUrlTemplate"],[qo({type:"share"}),1,"shareEvent",e=>(0,c.A)(vl,e),(e,t)=>(0,l.A)(vl,e,t)],[qo({type:"terminate"}),1,"terminateEvent",e=>(0,c.A)(xl,e),(e,t)=>(0,l.A)(xl,e,t)],[qo({type:"feedback.submit"}),1,"feedbackSubmitEvent",e=>(0,c.A)(wl,e),(e,t)=>(0,l.A)(wl,e,t)],[qo({type:"feedback.on.view"}),1,"feedbackOnViewEvent",e=>(0,c.A)(Tl,e),(e,t)=>(0,l.A)(Tl,e,t)],[qo({type:"ui.switch"}),1,"switch",e=>(0,c.A)(Nl,e),(e,t)=>(0,l.A)(Nl,e,t)],[qo({type:"detail.change"}),1,"detailChange",e=>(0,c.A)(Ml,e),(e,t)=>(0,l.A)(Ml,e,t)],[qo({type:"mark.notices.read"}),1,"markNoticesReadEvent",e=>(0,c.A)(Rl,e),(e,t)=>(0,l.A)(Rl,e,t)],[qo({type:"notice.click"}),1,"noticeClickEvent",e=>(0,c.A)(Il,e),(e,t)=>(0,l.A)(Il,e,t)],[Xo(),2,"resumed"],[Xo(),2,"feedbackSubmitDone"],[Xo(),2,"feedbackSubmitFailed"],[Xo(),2,"feedbackOnViewDone"]],0,(e=>Ll.has((0,s.A)(e))),m.ReactNextElement)),Ms();let zl=function(e){return e.AI_EMPLOYEES="AI_EMPLOYEES",e.UNTITLED="UNTITLED",e}({});const Pl="bricks/ai-portal/ai-employees",Bl=g.i18n.getFixedT(null,Pl);var Ul,Hl=i(98036),Fl=i(65549);let Gl,Vl,jl,Kl,$l,Yl,ql,Xl,Jl;(0,g.initializeI18n)(Pl,{en:{AI_EMPLOYEES:"AI Employees",UNTITLED:"Untitled"},zh:{AI_EMPLOYEES:"Ai 数字人",UNTITLED:"未命名"}});const Ql=(0,m.wrapBrick)("eo-link"),Zl=(0,m.wrapBrick)("eo-icon"),ec=(0,m.wrapBrick)("ai-portal.tab-list",{onTabClick:"tab.click"}),{defineElement:tc,property:ic}=(0,u.createDecorators)();let nc;var ac=new WeakMap,rc=new WeakMap,sc=new WeakMap,oc=new WeakMap;class lc extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,ac,Vl(this)),(0,r.A)(this,rc,(jl(this),Kl(this))),(0,r.A)(this,sc,($l(this),Yl(this))),(0,r.A)(this,oc,(ql(this),Xl(this,!0))),Jl(this)}get list(){return(0,c.A)(ac,this)}set list(e){(0,l.A)(ac,this,e)}get industries(){return(0,c.A)(rc,this)}set industries(e){(0,l.A)(rc,this,e)}get urlTemplate(){return(0,c.A)(sc,this)}set urlTemplate(e){(0,l.A)(sc,this,e)}get withContainer(){return(0,c.A)(oc,this)}set withContainer(e){(0,l.A)(oc,this,e)}render(){return h().createElement(cc,{list:this.list,industries:this.industries,urlTemplate:this.urlTemplate,withContainer:this.withContainer})}}function cc(e){let{list:t,industries:i,urlTemplate:n,withContainer:a}=e;const r=(0,p.useMemo)((()=>[...new Set([...null!=i?i:[],...(null!=t?t:[]).map((e=>e.industry))])]),[i,t]),[s,o]=(0,p.useState)(r[0]),l=(0,p.useMemo)((()=>{const e=new Map;return null==t||t.forEach((t=>{if(t.industry!==s)return;let i=e.get(t.role);i||e.set(t.role,i=[]),i.push(t)})),[...e.entries()]}),[s,t]),c=(0,p.useMemo)((()=>r.map((e=>({id:e,label:e||Bl(zl.UNTITLED)})))),[r]),d=h().createElement(h().Fragment,null,h().createElement(ec,{tabs:c,activeTab:s,onTabClick:e=>o(e.detail.id)}),h().createElement("ul",{className:"groups"},l.map((e=>{let[t,i]=e;return h().createElement("li",{key:t,className:"group"},h().createElement("h2",null,t),h().createElement("ul",{className:"list"},i.map(((e,t)=>h().createElement("li",{key:t},h().createElement(Ql,(0,qi.A)({className:Pn()("link",{clickable:!!n})},n?{url:(0,Fl.Q)(n,e)}:null),h().createElement("div",{className:"heading"},h().createElement("div",{className:"avatar"},e.avatar?h().createElement("img",{src:e.avatar}):h().createElement(Zl,{lib:"antd",icon:"user"})),h().createElement("div",{className:"title"},e.name)),h().createElement("div",{className:"description"},e.description)))))))}))));return a?h().createElement("div",{className:"container"},h().createElement("h1",null,Bl(zl.AI_EMPLOYEES)),d):d}Ul=lc,({e:[Vl,jl,Kl,$l,Yl,ql,Xl,Jl],c:[nc,Gl]}=(0,d.A)(Ul,[tc("ai-portal.ai-employees",{styleTexts:[Hl.A]})],[[ic({attribute:!1}),1,"list"],[ic({attribute:!1}),1,"industries"],[ic(),1,"urlTemplate"],[ic({type:Boolean}),1,"withContainer"]],0,void 0,m.ReactNextElement)),Gl();let dc=function(e){return e.AGENTS="AGENTS",e}({});const pc="bricks/ai-portal/ai-agents",hc=g.i18n.getFixedT(null,pc);var uc,mc=i(83059);let gc,bc,Ac,vc,fc,Ec,xc;const kc={lib:"antd",icon:"tool"};(0,g.initializeI18n)(pc,{en:{AGENTS:"Agents"},zh:{AGENTS:"智能体"}});const wc=(0,m.wrapBrick)("eo-icon"),yc=(0,m.wrapBrick)("eo-link"),{defineElement:Tc,property:Sc}=(0,u.createDecorators)();let Nc;var Cc=new WeakMap,Mc=new WeakMap,_c=new WeakMap;class Rc extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,Cc,bc(this)),(0,r.A)(this,Mc,(Ac(this),vc(this))),(0,r.A)(this,_c,(fc(this),Ec(this,!0))),xc(this)}get list(){return(0,c.A)(Cc,this)}set list(e){(0,l.A)(Cc,this,e)}get urlTemplate(){return(0,c.A)(Mc,this)}set urlTemplate(e){(0,l.A)(Mc,this,e)}get withContainer(){return(0,c.A)(_c,this)}set withContainer(e){(0,l.A)(_c,this,e)}render(){return h().createElement(Wc,{list:this.list,urlTemplate:this.urlTemplate,withContainer:this.withContainer})}}function Wc(e){let{list:t,urlTemplate:i,withContainer:n}=e;const a=h().createElement(h().Fragment,null,h().createElement("ul",{className:"list"},null==t?void 0:t.map(((e,t)=>{var n,a;return h().createElement("li",{key:t},h().createElement(yc,(0,qi.A)({className:Pn()("link",{clickable:!!i})},i?{url:(0,Fl.Q)(i,e)}:null),h().createElement("div",{className:"heading"},h().createElement("div",{className:"icon"},h().createElement(wc,(0,qi.A)({},null!==(n=e.icon)&&void 0!==n?n:kc,{fallback:kc}))),h().createElement("div",{className:"title"},e.name)),h().createElement("div",{className:"tags"},null===(a=e.tags)||void 0===a?void 0:a.map(((e,t)=>h().createElement("span",{key:t,className:"tag"},e)))),h().createElement("div",{className:"description"},e.description)))}))));return n?h().createElement("div",{className:"container"},h().createElement("h1",null,hc(dc.AGENTS)),a):a}uc=Rc,({e:[bc,Ac,vc,fc,Ec,xc],c:[Nc,gc]}=(0,d.A)(uc,[Tc("ai-portal.ai-agents",{styleTexts:[mc.A]})],[[Sc({attribute:!1}),1,"list"],[Sc(),1,"urlTemplate"],[Sc({type:Boolean}),1,"withContainer"]],0,void 0,m.ReactNextElement)),gc();let Ic=null;customElements.define("ai-portal.save-request-store",(0,_t.createProviderClass)((function(e){Ic=e}))),customElements.define("ai-portal.load-request-store",(0,_t.createProviderClass)((function(){const e=Ic;return Ic=null,e}))),customElements.define("ai-portal.clear-request-store",(0,_t.createProviderClass)((function(){Ic=null})));var Dc,Lc=i(49041);let Oc,zc,Pc,Bc,Uc,Hc,Fc,Gc,Vc,jc,Kc;const $c=(0,m.wrapBrick)("eo-link"),Yc=(0,m.wrapBrick)("ai-portal.sticky-container"),{defineElement:qc,property:Xc}=(0,u.createDecorators)();let Jc;var Qc=new WeakMap,Zc=new WeakMap,ed=new WeakMap,td=new WeakMap,id=new WeakMap;class nd extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,Qc,zc(this)),(0,r.A)(this,Zc,(Pc(this),Bc(this))),(0,r.A)(this,ed,(Uc(this),Hc(this))),(0,r.A)(this,td,(Fc(this),Gc(this))),(0,r.A)(this,id,(Vc(this),jc(this))),Kc(this)}get pageTitle(){return(0,c.A)(Qc,this)}set pageTitle(e){(0,l.A)(Qc,this,e)}get breadcrumbs(){return(0,c.A)(Zc,this)}set breadcrumbs(e){(0,l.A)(Zc,this,e)}get size(){return(0,c.A)(ed,this)}set size(e){(0,l.A)(ed,this,e)}get variant(){return(0,c.A)(td,this)}set variant(e){(0,l.A)(td,this,e)}get sticky(){return(0,c.A)(id,this)}set sticky(e){(0,l.A)(id,this,e)}render(){return h().createElement(ad,{pageTitle:this.pageTitle,breadcrumbs:this.breadcrumbs,sticky:this.sticky})}}function ad(e){let{breadcrumbs:t,pageTitle:i,sticky:n}=e;(0,p.useEffect)((()=>{"string"==typeof i&&(0,On.getRuntime)().applyPageTitle(i)}),[i]);const a=i||null!=t&&t.length?h().createElement("div",{className:"header"},h().createElement("nav",null,null!=t&&t.length?h().createElement("ul",{className:"breadcrumbs"},t.map(((e,t)=>h().createElement("li",{key:t},h().createElement($c,{url:e.url},e.text))))):null,i?h().createElement("h1",null,i):null),h().createElement("slot",{name:"toolbar"})):null;return h().createElement("div",{className:"container"},a&&n?h().createElement(Yc,{className:"sticky-header"},a):h().createElement("div",{className:"non-sticky-header"},a),h().createElement("slot",null))}Dc=nd,({e:[zc,Pc,Bc,Uc,Hc,Fc,Gc,Vc,jc,Kc],c:[Jc,Oc]}=(0,d.A)(Dc,[qc("ai-portal.page-container",{styleTexts:[Lc.A]})],[[Xc(),1,"pageTitle"],[Xc({attribute:!1}),1,"breadcrumbs"],[Xc({render:!1}),1,"size"],[Xc({render:!1}),1,"variant"],[Xc({type:Boolean}),1,"sticky"]],0,void 0,m.ReactNextElement)),Oc();var rd,sd=i(20124);let od,ld,cd,dd,pd,hd,ud,md,gd;const{defineElement:bd,property:Ad,event:vd}=(0,u.createDecorators)();let fd;var Ed=new WeakMap,xd=new WeakMap,kd=new WeakMap,wd=new WeakSet,yd=new WeakMap;class Td extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,wd),(0,r.A)(this,Ed,ld(this)),(0,r.A)(this,xd,(cd(this),dd(this))),(0,r.A)(this,kd,(pd(this),hd(this))),(0,r.A)(this,yd,(gd(this),e=>{this.activeTab=e.id,(0,o.A)(wd,this,ud).emit(e)}))}get tabs(){return(0,c.A)(Ed,this)}set tabs(e){(0,l.A)(Ed,this,e)}get activeTab(){return(0,c.A)(xd,this)}set activeTab(e){(0,l.A)(xd,this,e)}render(){return h().createElement(Sd,{tabs:this.tabs,activeTab:this.activeTab,onTabClick:(0,c.A)(yd,this)})}}function Sd(e){let{tabs:t,activeTab:i,onTabClick:n}=e;return h().createElement("ul",{className:"tabs",part:"tabs"},null==t?void 0:t.map((e=>h().createElement("li",{key:e.id,part:"tab",className:Pn()("tab",{active:e.id===i})},h().createElement("a",{onClick:()=>n(e)},e.label)))))}rd=Td,({e:[ld,cd,dd,pd,hd,ud,md,gd],c:[fd,od]}=(0,d.A)(rd,[bd("ai-portal.tab-list",{styleTexts:[sd.A]})],[[Ad({attribute:!1}),1,"tabs"],[Ad({attribute:!1}),1,"activeTab"],[vd({type:"tab.click"}),1,"tabClick",e=>(0,c.A)(kd,e),(e,t)=>(0,l.A)(kd,e,t)]],0,(e=>yd.has((0,s.A)(e))),m.ReactNextElement)),od();var Nd=i(41030);let Cd=function(e){return e.PLEASE_SELECT="PLEASE_SELECT",e.SEARCH_PLACEHOLDER="SEARCH_PLACEHOLDER",e.SEARCH_NO_DATA="SEARCH_NO_DATA",e}({});const Md="bricks/ai-portal/dropdown-select",_d=g.i18n.getFixedT(null,Md);var Rd,Wd=i(40138);let Id,Dd,Ld,Od,zd,Pd,Bd,Ud,Hd,Fd,Gd,Vd,jd,Kd,$d,Yd,qd,Xd,Jd,Qd,Zd;(0,g.initializeI18n)(Md,{en:{PLEASE_SELECT:"Please Select",SEARCH_PLACEHOLDER:"Search",SEARCH_NO_DATA:"No Data"},zh:{PLEASE_SELECT:"请选择",SEARCH_PLACEHOLDER:"搜索",SEARCH_NO_DATA:"暂无结果"}});const{defineElement:ep,property:tp,event:ip}=(0,u.createDecorators)(),np=(0,m.wrapBrick)("eo-popover",{onVisibleChange:"visible.change",onBeforeVisibleChange:"before.visible.change"}),ap=(0,m.wrapBrick)("eo-icon"),rp=(0,m.wrapBrick)("eo-loading-container"),sp=(0,m.wrapBrick)("eo-menu"),op=(0,m.wrapBrick)("eo-menu-item"),lp=(0,m.wrapBrick)("eo-input",{onValueChange:"change"});let cp;var dp=new WeakMap,pp=new WeakMap,hp=new WeakMap,up=new WeakMap,mp=new WeakMap,gp=new WeakMap,bp=new WeakMap,Ap=new WeakMap,vp=new WeakMap,fp=new WeakSet,Ep=new WeakMap;class xp extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,fp),(0,r.A)(this,dp,Dd(this)),(0,r.A)(this,pp,(Ld(this),Od(this))),(0,r.A)(this,hp,(zd(this),Pd(this))),(0,r.A)(this,up,(Bd(this),Ud(this))),(0,r.A)(this,mp,(Hd(this),Fd(this))),(0,r.A)(this,gp,(Gd(this),Vd(this))),(0,r.A)(this,bp,(jd(this),Kd(this))),(0,r.A)(this,Ap,($d(this),Yd(this))),(0,r.A)(this,vp,(qd(this),Xd(this))),(0,r.A)(this,Ep,(Zd(this),e=>{(0,o.A)(fp,this,Jd).emit(e)}))}get value(){return(0,c.A)(dp,this)}set value(e){(0,l.A)(dp,this,e)}get options(){return(0,c.A)(pp,this)}set options(e){(0,l.A)(pp,this,e)}get labelMaxWidth(){return(0,c.A)(hp,this)}set labelMaxWidth(e){(0,l.A)(hp,this,e)}get loading(){return(0,c.A)(up,this)}set loading(e){(0,l.A)(up,this,e)}get searchPlaceholder(){return(0,c.A)(mp,this)}set searchPlaceholder(e){(0,l.A)(mp,this,e)}get dropdownContentStyle(){return(0,c.A)(gp,this)}set dropdownContentStyle(e){(0,l.A)(gp,this,e)}get dropdownMaxWidth(){return(0,c.A)(bp,this)}set dropdownMaxWidth(e){(0,l.A)(bp,this,e)}get showSearch(){return(0,c.A)(Ap,this)}set showSearch(e){(0,l.A)(Ap,this,e)}render(){return h().createElement(kp,{value:this.value,options:this.options,onChange:(0,c.A)(Ep,this),loading:this.loading,labelMaxWidth:this.labelMaxWidth,dropdownMaxWidth:this.dropdownMaxWidth,showSearch:this.showSearch,searchPlaceholder:this.searchPlaceholder,dropdownContentStyle:this.dropdownContentStyle})}}function kp(e){let{value:t,options:i,labelMaxWidth:n,dropdownMaxWidth:a,showSearch:r,loading:s,searchPlaceholder:o,dropdownContentStyle:l,onChange:c}=e;const[d,u]=(0,p.useState)(!1),[m,g]=(0,p.useState)(t),[b,A]=(0,p.useState)(""),[v,f]=(0,p.useState)(i);(0,p.useEffect)((()=>{f(i)}),[i]);const E=(0,p.useMemo)((()=>null==v?void 0:v.find((e=>e.value===m))),[v,m]),x=(0,p.useMemo)((()=>b&&v?null==v?void 0:v.filter((e=>e.label.toLowerCase().includes(b.toLowerCase()))):v),[v,b]),k=(0,p.useCallback)((e=>{u(e.detail),e.detail||A("")}),[]),w=(0,p.useMemo)((()=>(0,Nd.debounce)((e=>{A(e.detail)}),300)),[]);return h().createElement(np,{placement:"bottom-start",trigger:"click",active:d,arrow:!1,distance:5,onBeforeVisibleChange:k},h().createElement("span",{slot:"anchor",className:"trigger"},h().createElement("span",{className:"label",style:{maxWidth:n}},E?null==E?void 0:E.label:_d(Cd.PLEASE_SELECT)),h().createElement(ap,{lib:"lucide",icon:d?"chevron-up":"chevron-down"})),h().createElement("div",{className:"dropdown",style:{maxWidth:a}},r&&h().createElement("div",{className:"search-container"},h().createElement(lp,{className:"search",value:b,placeholder:o||_d(Cd.SEARCH_PLACEHOLDER),onValueChange:w},h().createElement(ap,{slot:"prefix",lib:"antd",icon:"search"}))),h().createElement(rp,{loading:s,delay:500,style:{width:"100%"}},h().createElement("div",{className:"dropdown-inner",style:l},h().createElement("slot",{name:"prefix"}),!(null==x||!x.length)&&h().createElement(sp,null,null==x?void 0:x.map((e=>h().createElement(op,{key:e.value,disabled:e.disabled,className:m===e.value?"active":void 0,onClick:t=>{t.preventDefault(),t.stopPropagation(),u(!1),m!==e.value&&(g(e.value),c(e))}},e.label)))),!(null!=x&&x.length)&&h().createElement("div",{className:"empty"},_d(Cd.SEARCH_NO_DATA))))))}Rd=xp,({e:[Dd,Ld,Od,zd,Pd,Bd,Ud,Hd,Fd,Gd,Vd,jd,Kd,$d,Yd,qd,Xd,Jd,Qd,Zd],c:[cp,Id]}=(0,d.A)(Rd,[ep("ai-portal.dropdown-select",{styleTexts:[Wd.A]})],[[tp(),1,"value"],[tp({attribute:!1}),1,"options"],[tp({attribute:!1}),1,"labelMaxWidth"],[tp({type:Boolean}),1,"loading"],[tp({attribute:!1}),1,"searchPlaceholder"],[tp({attribute:!1}),1,"dropdownContentStyle"],[tp({attribute:!1}),1,"dropdownMaxWidth"],[tp({type:Boolean}),1,"showSearch"],[ip({type:"change"}),1,"changeEvent",e=>(0,c.A)(vp,e),(e,t)=>(0,l.A)(vp,e,t)]],0,(e=>Ep.has((0,s.A)(e))),m.ReactNextElement)),Id();var wp=i(71568);let yp=function(e){return e.UNTITLED="UNTITLED",e}({});const Tp="bricks/ai-portal/preview-container",Sp=g.i18n.getFixedT(null,Tp);var Np=i(72591),Cp=i.n(Np),Mp=i(1740),_p=i.n(Mp),Rp=i(88128),Wp=i.n(Rp),Ip=i(30855),Dp=i.n(Ip),Lp=i(93051),Op=i.n(Lp),zp=i(73656),Pp=i.n(zp),Bp=i(62522),Up={};Up.styleTagTransform=Pp(),Up.setAttributes=Dp(),Up.insert=Wp().bind(null,"head"),Up.domAPI=_p(),Up.insertStyleElement=Op(),Cp()(Bp.A,Up);const Hp=Bp.A&&Bp.A.locals?Bp.A.locals:void 0;var Fp,Gp=i(43100),Vp=i(23241);let jp,Kp,$p,Yp,qp;(0,g.initializeI18n)(Tp,{en:{UNTITLED:"Untitled"},zh:{UNTITLED:"无标题"}});const Xp=(0,m.wrapBrick)("eo-icon"),Jp=(0,m.wrapBrick)("eo-page-title"),Qp=(0,m.wrapBrick)("eo-main-view"),Zp=(0,m.wrapBrick)("eo-narrow-view"),{defineElement:eh,property:th}=(0,u.createDecorators)();let ih;var nh=new WeakMap,ah=new WeakMap,rh=new WeakMap;class sh extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,nh,Kp(this)),(0,r.A)(this,ah,($p(this),Yp(this))),(0,r.A)(this,rh,(qp(this),(0,Nd.uniqueId)()))}get source(){return(0,c.A)(nh,this)}set source(e){(0,l.A)(nh,this,e)}get url(){return(0,c.A)(ah,this)}set url(e){(0,l.A)(ah,this,e)}render(){return h().createElement(p.Suspense,{fallback:h().createElement(Xp,{lib:"antd",icon:"loading-3-quarters",spinning:!0,className:Hp.loading})},h().createElement(oh,{rootId:(0,c.A)(rh,this),source:this.source,url:this.url}))}}function oh(e){let{rootId:t,source:i,url:n}=e;const a=(0,p.useMemo)((()=>i?async function(e){const t=await(0,Gp.f)();return await t.parseView(e)}(i).catch((e=>(console.error("Failed to parse view:",e),null))):Promise.resolve(null)),[i]),r=(0,p.use)(a),s=(0,p.useMemo)((()=>r?(0,wp.z)(r,{rootId:t,expanded:!0}).catch((e=>(console.error("Failed to convert view:",e),null))):Promise.resolve(null)),[r,t]),o=(0,p.use)(s),l=(0,p.useMemo)((()=>{var e;return null==r||null===(e=r.entry)||void 0===e||null===(e=e.defaultExport)||void 0===e?void 0:e.title}),[r]);return h().createElement(lh,{rootId:t,pageTitle:l,convertedResult:o,url:n})}function lh(e){let{rootId:t,pageTitle:i,convertedResult:n,url:a}=e;const r=(0,p.useRef)(null),s=(0,p.useRef)(null);return(0,p.useEffect)((()=>{const e=r.current;if(!e)return;const i=(0,Vp.d)(t),n=(0,On.unstable_createRoot)(e,{portal:i,supportsUseChildren:!0});return s.current=n,()=>{n.unmount(),i.remove(),s.current=null}}),[t]),(0,p.useEffect)((()=>{var e;if(!n)return;const{brick:t,context:i,functions:r,templates:o}=n;null===(e=s.current)||void 0===e||e.render(t,{context:i,functions:r,templates:o,url:a})}),[n,a]),h().createElement(Zp,{size:"large",className:Hp.container},h().createElement(Qp,null,h().createElement(Jp,{slot:"pageTitle",pageTitle:i||Sp(yp.UNTITLED)}),h().createElement("div",{className:Hp.main,ref:r,"data-root-id":t})))}Fp=sh,({e:[Kp,$p,Yp,qp],c:[ih,jp]}=(0,d.A)(Fp,[eh("ai-portal.preview-container",{shadowOptions:!1})],[[th({attribute:!1}),1,"source"],[th(),1,"url"]],0,void 0,m.ReactNextElement)),jp();const ch="bricks/ai-portal/action-buttons";g.i18n.getFixedT(null,ch);var dh,ph=i(11816);let hh,uh,mh,gh,bh,Ah,vh,fh,Eh;(0,g.initializeI18n)(ch,{en:{},zh:{}});const xh=(0,m.wrapBrick)("eo-icon"),kh=(0,m.wrapBrick)("eo-button"),{defineElement:wh,property:yh,event:Th}=(0,u.createDecorators)();let Sh;var Nh=new WeakMap,Ch=new WeakMap,Mh=new WeakMap,_h=new WeakSet,Rh=new WeakMap;class Wh extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,_h),(0,r.A)(this,Nh,uh(this)),(0,r.A)(this,Ch,(mh(this),gh(this))),(0,r.A)(this,Mh,(bh(this),Ah(this))),(0,r.A)(this,Rh,(Eh(this),e=>{this.activeKey=e?e.key:null,(0,o.A)(_h,this,vh).emit(e)}))}get items(){return(0,c.A)(Nh,this)}set items(e){(0,l.A)(Nh,this,e)}get activeKey(){return(0,c.A)(Ch,this)}set activeKey(e){(0,l.A)(Ch,this,e)}render(){return h().createElement(Ih,{items:this.items,activeKey:this.activeKey,onChange:(0,c.A)(Rh,this)})}}function Ih(e){let{items:t,activeKey:i,onChange:n}=e;const[a,r]=(0,p.useState)(null!=i?i:null),s=(0,p.useRef)(!1);(0,p.useEffect)((()=>{r(null!=i?i:null)}),[i]),(0,p.useEffect)((()=>{var e;s.current?n(a&&null!==(e=null==t?void 0:t.find((e=>!e.hidden&&e.key===a)))&&void 0!==e?e:null):s.current=!0}),[a,t,n]);const o=(0,p.useMemo)((()=>null==t?void 0:t.filter((e=>!e.hidden&&!a||e.key===a))),[t,a]);return h().createElement("div",{className:"button-container"},null==o?void 0:o.map((e=>{const{text:t,icon:i,key:n}=e;return h().createElement(kh,{key:n,className:"action"+(a?" active":""),themeVariant:"elevo",type:"neutral",onClick:()=>{a||r(n)}},i?h().createElement(xh,(0,qi.A)({className:"icon"},i)):null,t,a?h().createElement(xh,{className:"remove",lib:"lucide",icon:"x",onClick:e=>{e.stopPropagation(),e.preventDefault(),r(null)}}):null)})))}dh=Wh,({e:[uh,mh,gh,bh,Ah,vh,fh,Eh],c:[Sh,hh]}=(0,d.A)(dh,[wh("ai-portal.action-buttons",{styleTexts:[ph.A]})],[[yh({attribute:!1}),1,"items"],[yh(),1,"activeKey"],[Th({type:"change"}),1,"change",e=>(0,c.A)(Mh,e),(e,t)=>(0,l.A)(Mh,e,t)]],0,(e=>Rh.has((0,s.A)(e))),m.ReactNextElement)),hh();let Dh=function(e){return e.UN_START_STATUS="UN_START_STATUS",e.RUNNING_STATUS="RUNNING_STATUS",e.COMPLETED_STATUS="COMPLETED_STATUS",e.NEW_CHAT="NEW_CHAT",e}({});const Lh="bricks/ai-portal/goal-card-list",Oh={en:{UN_START_STATUS:"Not Start",RUNNING_STATUS:"Running",COMPLETED_STATUS:"Completed",NEW_CHAT:"New chat"},zh:{UN_START_STATUS:"未开始",RUNNING_STATUS:"运行中",COMPLETED_STATUS:"已完成",NEW_CHAT:"新对话"}},zh=g.i18n.getFixedT(null,Lh);var Ph=i(46342),Bh=i(10335);let Uh;(0,g.initializeI18n)(Lh,Oh);const Hh=(0,m.wrapBrick)("eo-icon"),Fh=(0,m.wrapBrick)("eo-dropdown-actions",{onActionClick:"action.click",onVisibleChange:"visible.change"}),Gh=(0,m.wrapBrick)("eo-easyops-avatar"),Vh=(0,m.wrapBrick)("eo-button"),jh={ready:"uncheck-status",working:"active-status",completed:"check-status"},Kh=[{key:"ready",icon:{icon:"uncheck-status",lib:"easyops",category:"colored-common"},text:zh(Dh.UN_START_STATUS)},{key:"working",icon:{icon:"active-status",lib:"easyops",category:"colored-common"},text:zh(Dh.RUNNING_STATUS)},{key:"completed",icon:{icon:"check-status",lib:"easyops",category:"colored-common"},text:zh(Dh.COMPLETED_STATUS)}];function $h(e){let{goalItem:t,idWidth:i,cardStyle:n,onStatusChange:a,onTitleChange:r,onClick:s,onNewChat:o,onAppendChild:l,onRevokeAppendChild:c,isActive:d}=e;const{state:u,id:m,title:g,conversations:b,owner:A,pending:v}=t,f=(0,p.useRef)(!1),E=(0,p.useCallback)((()=>{f.current=!0}),[]),x=(0,p.useCallback)((()=>{f.current=!1}),[]),[k,w]=(0,p.useState)(!1),y=(0,p.useCallback)((()=>{w(!0)}),[]),T=(0,p.useCallback)((e=>{w(!1);const t=e.currentTarget.textContent;!v||null!=t&&t.trim()?null!==t&&g!==t&&(null==r||r(t)):null==c||c()}),[v,g,c,r]),S=(0,p.useCallback)((e=>{f.current||"Enter"===e.key&&(e.preventDefault(),e.currentTarget.blur())}),[]),N=(0,p.useRef)(null);return(0,p.useEffect)((()=>{var e;v&&(null===(e=N.current)||void 0===e||e.focus())}),[v]),h().createElement("div",{className:Pn()("goal-item",t.state,{editing:k},{active:d}),style:{paddingLeft:24*(t.level+1)+"px",...n},onClick:v?void 0:s},h().createElement("div",{className:"start"},h().createElement(Fh,{actions:Kh,disabled:v,onActionClick:e=>{var t;t=e.detail,null==a||a(t.key)}},h().createElement(Hh,{className:"icon",lib:"easyops",category:"colored-common",icon:jh[u],onClick:e=>e.stopPropagation()})),h().createElement("span",{className:"serial-number",style:{width:i}},"#",v?"":m),h().createElement("span",{className:"title",ref:N,onClick:e=>e.stopPropagation(),onFocus:y,onBlur:T,onKeyDown:S,onCompositionStart:E,onCompositionEnd:x,contentEditable:(C=!0,C?function(){if("boolean"!=typeof Uh){const e=document.createElement("div");e.setAttribute("contenteditable","PLAINTEXT-ONLY"),Uh="plaintext-only"===e.contentEditable}return Uh}()?"plaintext-only":"true":"false"),suppressContentEditableWarning:!0},g)),h().createElement("div",{className:"end"},h().createElement("div",{className:"info"},h().createElement("div",{className:"message"},h().createElement(Hh,{lib:"easyops",category:"common",icon:"message"}),h().createElement("span",{className:"count"},b||0)),h().createElement(Gh,{nameOrInstanceId:null==A?void 0:A.instanceId,size:"small"})),h().createElement("div",{className:"operation",onClick:e=>e.stopPropagation()},0===t.level&&h().createElement(Vh,{className:"append-child",themeVariant:"elevo",type:"neutral",size:"small",onClick:l},h().createElement(Hh,{lib:"lucide",icon:"plus"})),!v&&h().createElement(Vh,{className:"new-chat",themeVariant:"elevo",type:"neutral",size:"small",onClick:o},zh(Dh.NEW_CHAT)))));var C}var Yh;let qh,Xh,Jh,Qh,Zh,eu,tu,iu,nu,au,ru,su,ou,lu,cu,du,pu,hu,uu,mu,gu,bu,Au,vu;(0,g.initializeI18n)(Lh,Oh);const{defineElement:fu,property:Eu,event:xu,method:ku}=(0,u.createDecorators)(),wu=(0,m.wrapBrick)("eo-icon"),yu=(0,p.forwardRef)(Uu);let Tu;var Su=new WeakMap,Nu=new WeakMap,Cu=new WeakMap,Mu=new WeakMap,_u=new WeakSet,Ru=new WeakMap,Wu=new WeakMap,Iu=new WeakMap,Du=new WeakMap,Lu=new WeakMap,Ou=new WeakMap,zu=new WeakMap,Pu=new WeakMap;class Bu extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,_u),(0,r.A)(this,Su,(qh(this),Jh(this))),(0,r.A)(this,Nu,(Qh(this),Zh(this))),(0,r.A)(this,Cu,(eu(this),tu(this))),(0,r.A)(this,Mu,(iu(this),nu(this))),(0,r.A)(this,Ru,(su(this),e=>{(0,o.A)(_u,this,au).emit(e)})),(0,r.A)(this,Wu,ou(this)),(0,r.A)(this,Iu,(du(this),e=>{(0,o.A)(_u,this,lu).emit(e)})),(0,r.A)(this,Du,pu(this)),(0,r.A)(this,Lu,(mu(this),e=>{(0,o.A)(_u,this,hu).emit(e)})),(0,r.A)(this,Ou,gu(this)),(0,r.A)(this,zu,(vu(this),e=>{(0,o.A)(_u,this,bu).emit(e)})),(0,r.A)(this,Pu,(0,p.createRef)())}get goalList(){return(0,c.A)(Su,this)}set goalList(e){(0,l.A)(Su,this,e)}get cardStyle(){return(0,c.A)(Nu,this)}set cardStyle(e){(0,l.A)(Nu,this,e)}get activeKey(){return(0,c.A)(Cu,this)}set activeKey(e){(0,l.A)(Cu,this,e)}appendChildDone(e,t){var i;null===(i=(0,c.A)(Pu,this).current)||void 0===i||i.appendChildDone(e,t)}render(){return h().createElement(yu,{ref:(0,c.A)(Pu,this),goalList:this.goalList,cardStyle:this.cardStyle,onTitleChange:(0,c.A)(Lu,this),onStatusChange:(0,c.A)(Iu,this),onItemClick:(0,c.A)(Ru,this),onNewChat:(0,c.A)(zu,this),activeKey:this.activeKey})}}function Uu(e,t){let{goalList:i,cardStyle:n,onTitleChange:a,onStatusChange:r,onItemClick:s,onNewChat:o,activeKey:l}=e;const[c,d]=(0,p.useState)(i);(0,p.useEffect)((()=>{d(i)}),[i]);const u=(e,t,i,n)=>{const a={...e,[t]:i};d(null==c?void 0:c.map((e=>e.instanceId===a.instanceId?a:e))),null==n||n(a)};(0,p.useImperativeHandle)(t,(()=>({appendChildDone:(e,t)=>{d((i=>null==i?void 0:i.map((i=>i.instanceId===e?{...t,level:i.level}:i))))}})),[]);const m=(0,p.useMemo)((()=>{var e;return 10*((null!==(e=null==c?void 0:c.reduce(((e,t)=>Math.max(e,t.id)),0))&&void 0!==e?e:0).toString().length+1)}),[c]);return c?h().createElement("div",{className:"goal-container"},null==c?void 0:c.map((e=>h().createElement($h,{key:e.instanceId,isActive:l===e.instanceId,goalItem:e,idWidth:m,cardStyle:n,onTitleChange:t=>((e,t)=>{u(t,"title",e,a)})(t,e),onStatusChange:t=>((e,t)=>{u(t,"state",e,r)})(t,e),onNewChat:()=>null==o?void 0:o(e),onClick:()=>null==s?void 0:s(e),onAppendChild:()=>(e=>{const t={instanceId:(0,Nd.uniqueId)("pending-"),pending:!0,id:0,title:"",state:"ready",level:1,pendingParentId:e.instanceId};d((i=>{var n;const a=null!==(n=null==i?void 0:i.findIndex((t=>t.instanceId===e.instanceId)))&&void 0!==n?n:-1;if(-1===a)return i;const r=i.slice(a+1).findIndex((e=>0===e.level))+1;return 0===r?[...i,t]:[...i.slice(0,a+r),t,...i.slice(a+r)]}))})(e),onRevokeAppendChild:()=>{d((t=>null==t?void 0:t.filter((t=>t.instanceId!==e.instanceId))))}})))):h().createElement("div",{className:"loading"},h().createElement(wu,{lib:"antd",icon:"loading-3-quarters",spinning:!0}))}Yh=Bu,({e:[Jh,Qh,Zh,eu,tu,iu,nu,au,ru,su,ou,lu,cu,du,pu,hu,uu,mu,gu,bu,Au,vu,qh],c:[Tu,Xh]}=(0,d.A)(Yh,[fu("ai-portal.goal-card-list",{styleTexts:[Bh.A,Ph.A]})],[[Eu({attribute:!1}),1,"goalList"],[Eu({attribute:!1}),1,"cardStyle"],[Eu(),1,"activeKey"],[xu({type:"item.click"}),1,"itemClickEvent",e=>(0,c.A)(Mu,e),(e,t)=>(0,l.A)(Mu,e,t)],[xu({type:"item.status.change"}),1,"itemStatusChangeEvent",e=>(0,c.A)(Wu,e),(e,t)=>(0,l.A)(Wu,e,t)],[xu({type:"item.title.change"}),1,"itemTitleChangeEvent",e=>(0,c.A)(Du,e),(e,t)=>(0,l.A)(Du,e,t)],[xu({type:"item.new.chat"}),1,"itemNewChatEvent",e=>(0,c.A)(Ou,e),(e,t)=>(0,l.A)(Ou,e,t)],[ku(),2,"appendChildDone"]],0,(e=>Pu.has((0,s.A)(e))),m.ReactNextElement)),Xh();var Hu=i(62916);let Fu=function(e){return e.PROJECT_OVERALL="PROJECT_OVERALL",e}({});const Gu="bricks/ai-portal/project-conversations",Vu=g.i18n.getFixedT(null,Gu);var ju,Ku=i(79286);let $u,Yu,qu,Xu,Ju,Qu,Zu,em,tm,im,nm,am,rm,sm,om,lm,cm;(0,g.initializeI18n)(Gu,{en:{PROJECT_OVERALL:"Project overall"},zh:{PROJECT_OVERALL:"项目整体"}});const dm=(0,m.wrapBrick)("eo-link"),pm=(0,m.wrapBrick)("eo-icon"),hm=(0,m.wrapBrick)("eo-easyops-avatar"),um=(0,m.wrapBrick)("eo-mini-actions",{onActionClick:"action.click",onVisibleChange:"visible.change"}),{defineElement:mm,property:gm,event:bm}=(0,u.createDecorators)();let Am;var vm=new WeakMap,fm=new WeakMap,Em=new WeakMap,xm=new WeakMap,km=new WeakMap,wm=new WeakSet,ym=new WeakMap,Tm=new WeakMap,Sm=new WeakMap;class Nm extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,wm),(0,r.A)(this,vm,Yu(this)),(0,r.A)(this,fm,(qu(this),Xu(this))),(0,r.A)(this,Em,(Ju(this),Qu(this))),(0,r.A)(this,xm,(Zu(this),em(this))),(0,r.A)(this,km,(tm(this),im(this))),(0,r.A)(this,ym,(rm(this),e=>{(0,o.A)(wm,this,nm).emit(e)})),(0,r.A)(this,Tm,sm(this)),(0,r.A)(this,Sm,(cm(this),e=>{(0,o.A)(wm,this,om).emit(e)}))}get list(){return(0,c.A)(vm,this)}set list(e){(0,l.A)(vm,this,e)}get urlTemplate(){return(0,c.A)(fm,this)}set urlTemplate(e){(0,l.A)(fm,this,e)}get actions(){return(0,c.A)(Em,this)}set actions(e){(0,l.A)(Em,this,e)}get goals(){return(0,c.A)(xm,this)}set goals(e){(0,l.A)(xm,this,e)}render(){return h().createElement(Cm,{list:this.list,urlTemplate:this.urlTemplate,actions:this.actions,goals:this.goals,onGoalClick:(0,c.A)(ym,this),onActionClick:(0,c.A)(Sm,this)})}}function Cm(e){let{list:t,urlTemplate:i,actions:n,goals:a,onGoalClick:r,onActionClick:s}=e;return t?h().createElement("ul",null,t.map((e=>h().createElement("li",{className:"item",key:e.conversationId},h().createElement(Mm,{conversation:e,urlTemplate:i,actions:n,goals:a,onGoalClick:r,onActionClick:s}))))):h().createElement("div",{className:"loading"},h().createElement(pm,{lib:"antd",icon:"loading-3-quarters",spinning:!0}))}function Mm(e){var t;let{conversation:i,urlTemplate:n,actions:a,goals:r,onGoalClick:s,onActionClick:o}=e;const l=(0,p.useRef)(null),c=g.i18n.language.split("-")[0];(0,p.useEffect)((()=>{const e=l.current;if(!e)return;const t=e=>{e.stopPropagation(),e.preventDefault(),s(i)};return e.addEventListener("click",t),()=>{e.removeEventListener("click",t)}}),[i,s]);const[d,u]=(0,p.useState)(!1);return h().createElement(dm,{className:Pn()("link",{"actions-active":d}),url:(0,Fl.Q)(n,i)},h().createElement("div",{className:"main"},h().createElement("div",{className:"header"},h().createElement(pm,{className:"icon",lib:"easyops",category:"common",icon:"clock"}),h().createElement("div",{className:"title"},i.title)),i.description&&h().createElement("div",{className:"description"},i.description)),r&&h().createElement("div",{className:Pn()("goal",{global:!i.goalInstanceId}),ref:l},i.goalInstanceId?null===(t=r.find((e=>e.instanceId===i.goalInstanceId)))||void 0===t?void 0:t.title:Vu(Fu.PROJECT_OVERALL)),h().createElement(hm,{className:"avatar",size:"small",nameOrInstanceId:i.username}),h().createElement("div",{className:`operations lang-${c}`},h().createElement(um,{className:"actions",actions:a,onActionClick:e=>{o({action:e.detail,item:i})},onVisibleChange:e=>{u(e.detail)}}),h().createElement("div",{className:"time",title:(0,Hu.P)(1e3*i.startTime,Hu.c.full)},(0,Hu.P)(1e3*i.startTime,Hu.c.relative))))}ju=Nm,({e:[Yu,qu,Xu,Ju,Qu,Zu,em,tm,im,nm,am,rm,sm,om,lm,cm],c:[Am,$u]}=(0,d.A)(ju,[mm("ai-portal.project-conversations",{styleTexts:[Ku.A]})],[[gm({attribute:!1}),1,"list"],[gm(),1,"urlTemplate"],[gm({attribute:!1}),1,"actions"],[gm({attribute:!1}),1,"goals"],[bm({type:"goal.click"}),1,"goalClick",e=>(0,c.A)(km,e),(e,t)=>(0,l.A)(km,e,t)],[bm({type:"action.click"}),1,"actionClick",e=>(0,c.A)(Tm,e),(e,t)=>(0,l.A)(Tm,e,t)]],0,(e=>Sm.has((0,s.A)(e))),m.ReactNextElement)),$u();var _m,Rm=i(23677);let Wm,Im,Dm,Lm,Om,zm,Pm,Bm,Um,Hm,Fm,Gm,Vm,jm,Km;const $m=(0,m.wrapBrick)("eo-link"),Ym=(0,m.wrapBrick)("eo-icon"),qm=(0,m.wrapBrick)("eo-easyops-avatar"),Xm=(0,m.wrapBrick)("eo-mini-actions",{onActionClick:"action.click",onVisibleChange:"visible.change"}),{defineElement:Jm,property:Qm,event:Zm}=(0,u.createDecorators)();let eg;var tg=new WeakMap,ig=new WeakMap,ng=new WeakMap,ag=new WeakMap,rg=new WeakSet,sg=new WeakMap,og=new WeakMap,lg=new WeakMap;class cg extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,rg),(0,r.A)(this,tg,Im(this)),(0,r.A)(this,ig,(Dm(this),Lm(this))),(0,r.A)(this,ng,(Om(this),zm(this))),(0,r.A)(this,ag,(Pm(this),Bm(this))),(0,r.A)(this,sg,(Fm(this),Gm(this))),(0,r.A)(this,og,(Km(this),e=>{(0,o.A)(rg,this,Um).emit(e)})),(0,r.A)(this,lg,(e=>{(0,o.A)(rg,this,Vm).emit(e)}))}get list(){return(0,c.A)(tg,this)}set list(e){(0,l.A)(tg,this,e)}get urlTemplate(){return(0,c.A)(ig,this)}set urlTemplate(e){(0,l.A)(ig,this,e)}get actions(){return(0,c.A)(ng,this)}set actions(e){(0,l.A)(ng,this,e)}render(){return h().createElement(dg,{list:this.list,urlTemplate:this.urlTemplate,actions:this.actions,onActionClick:(0,c.A)(og,this),onItemClick:(0,c.A)(lg,this)})}}function dg(e){let{list:t,urlTemplate:i,actions:n,onActionClick:a,onItemClick:r}=e;return t?h().createElement("ul",null,null==t?void 0:t.map((e=>h().createElement("li",{className:"item",key:e.instanceId},h().createElement(pg,{knowledge:e,urlTemplate:i,actions:n,onActionClick:a,onItemClick:r}))))):h().createElement("div",{className:"loading"},h().createElement(Ym,{lib:"antd",icon:"loading-3-quarters",spinning:!0}))}function pg(e){let{knowledge:t,urlTemplate:i,actions:n,onActionClick:a,onItemClick:r}=e;const[s,o]=(0,p.useState)(!1);return h().createElement($m,{className:Pn()("link",{"actions-active":s}),url:(0,Fl.Q)(i,t),onClick:()=>null==r?void 0:r(t)},h().createElement("div",{className:"main"},h().createElement("div",{className:"header"},h().createElement(Ym,{className:"icon",lib:"easyops",icon:"lightbulb",category:"common"}),h().createElement("span",{className:"title"},t.name),h().createElement(Ym,{className:"attachment",lib:"lucide",icon:"paperclip"})),t.description&&h().createElement("div",{className:"description"},t.description)),h().createElement("div",{className:"time"},(0,Hu.P)(1e3*t.time,Hu.c.relative)),h().createElement("div",{className:"operations"},h().createElement(Xm,{className:"actions",actions:n,onActionClick:e=>{a({action:e.detail,item:t})},onVisibleChange:e=>{o(e.detail)}}),h().createElement(qm,{className:"avatar",size:"small",nameOrInstanceId:t.user})))}_m=cg,({e:[Im,Dm,Lm,Om,zm,Pm,Bm,Um,Hm,Fm,Gm,Vm,jm,Km],c:[eg,Wm]}=(0,d.A)(_m,[Jm("ai-portal.project-knowledges",{styleTexts:[Rm.A]})],[[Qm({attribute:!1}),1,"list"],[Qm(),1,"urlTemplate"],[Qm({attribute:!1}),1,"actions"],[Zm({type:"action.click"}),1,"actionClick",e=>(0,c.A)(ag,e),(e,t)=>(0,l.A)(ag,e,t)],[Zm({type:"item.click"}),1,"itemClick",e=>(0,c.A)(sg,e),(e,t)=>(0,l.A)(sg,e,t)]],0,(e=>lg.has((0,s.A)(e))),m.ReactNextElement)),Wm();let hg=function(e){return e.STARTED_A_CHAT="STARTED_A_CHAT",e.CREATED_THIS_GOAL="CREATED_THIS_GOAL",e.CHANGED_THE_GOAL_TITLE="CHANGED_THE_GOAL_TITLE",e.CHANGED_THE_GOAL_DESCRIPTION="CHANGED_THE_GOAL_DESCRIPTION",e.CHANGED_THE_GOAL="CHANGED_THE_GOAL",e.DELETED_THIS_GOAL="DELETED_THIS_GOAL",e.DECOMPOSED_THIS_GOAL="DECOMPOSED_THIS_GOAL",e.SET_OWNER="SET_OWNER",e.REMOVED_GOAL_PARTICIPANTS="REMOVED_GOAL_PARTICIPANTS",e.ADDED_GOAL_PARTICIPANTS="ADDED_GOAL_PARTICIPANTS",e.COMMENTED="COMMENTED",e.COMMA="COMMA",e.SEMICOLON="SEMICOLON",e}({});const ug="bricks/ai-portal/activity-timeline",mg=g.i18n.getFixedT(null,ug);var gg,bg=i(14763);let Ag,vg,fg,Eg,xg;(0,g.initializeI18n)(ug,{en:{STARTED_A_CHAT:"started a chat",CREATED_THIS_GOAL:"created this goal",CHANGED_THE_GOAL_TITLE:'changed the goal title to "{{ title }}"',CHANGED_THE_GOAL_DESCRIPTION:'changed the goal description to "{{ description }}"',CHANGED_THE_GOAL:"changed the goal",DELETED_THIS_GOAL:"deleted this goal",DECOMPOSED_THIS_GOAL:"decomposed this goal to {{ count }} sub-goal: ",DECOMPOSED_THIS_GOAL_plural:"decomposed this goal to {{ count }} sub-goals: ",SET_OWNER:"set {{ user }} as the owner",REMOVED_GOAL_PARTICIPANTS:"removed a goal participant: ",REMOVED_GOAL_PARTICIPANTS_plural:"removed {{ count }} goal participants: ",ADDED_GOAL_PARTICIPANTS:"added a goal participant: ",ADDED_GOAL_PARTICIPANTS_plural:"added {{ count }} goal participants: ",COMMENTED:"commented",COMMA:", ",SEMICOLON:"; "},zh:{STARTED_A_CHAT:"发起了对话",CREATED_THIS_GOAL:"创建了此目标",CHANGED_THE_GOAL_TITLE:"修改目标标题为 “{{ title }}”",CHANGED_THE_GOAL_DESCRIPTION:"修改目标描述为 “{{ description }}”",CHANGED_THE_GOAL:"修改了此目标",DELETED_THIS_GOAL:"删除了此目标",DECOMPOSED_THIS_GOAL:"将此目标分解为 {{ count }} 个子目标:",DECOMPOSED_THIS_GOAL_plural:"将此目标分解为 {{ count }} 个子目标:",SET_OWNER:"设定负责人为 {{ user }}",REMOVED_GOAL_PARTICIPANTS:"移除了目标参与成员:",ADDED_GOAL_PARTICIPANTS:"添加了目标参与成员:",COMMENTED:"评论",COMMA:",",SEMICOLON:";"}});const kg=(0,m.wrapBrick)("eo-link"),wg=(0,m.wrapBrick)("eo-icon"),yg=(0,m.wrapBrick)("eo-easyops-avatar"),{defineElement:Tg,property:Sg}=(0,u.createDecorators)();let Ng;var Cg=new WeakMap,Mg=new WeakMap;class _g extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,Cg,vg(this)),(0,r.A)(this,Mg,(fg(this),Eg(this))),xg(this)}get list(){return(0,c.A)(Cg,this)}set list(e){(0,l.A)(Cg,this,e)}get chatUrlTemplate(){return(0,c.A)(Mg,this)}set chatUrlTemplate(e){(0,l.A)(Mg,this,e)}render(){return h().createElement(Rg,{list:this.list,chatUrlTemplate:this.chatUrlTemplate})}}function Rg(e){let{list:t,chatUrlTemplate:i}=e;return t?h().createElement("ul",null,t.map(((e,t)=>{var n,a;return h().createElement("li",{className:"activity",key:t},h().createElement("div",{className:"guide-line"}),h().createElement("div",{className:"main"},h().createElement(yg,{className:"avatar",nameOrInstanceId:e.user_id,size:"xs"}),h().createElement("span",{className:"action"},e.user_name," ","start_conversation"===e.action_type?h().createElement(h().Fragment,null,h().createElement("span",null,mg(hg.STARTED_A_CHAT)),h().createElement(kg,{className:"conversation",url:(0,Fl.Q)(i,e),target:"_blank"},null===(n=e.metadata)||void 0===n?void 0:n.conversation_title),h().createElement(wg,{className:"external-link-icon",lib:"lucide",icon:"external-link"})):"create_goal"===e.action_type?mg(hg.CREATED_THIS_GOAL):"edit_goal"===e.action_type?e.metadata.after.title?mg(hg.CHANGED_THE_GOAL_TITLE,e.metadata.after):e.metadata.after.description?mg(hg.CHANGED_THE_GOAL_DESCRIPTION,e.metadata.after):mg(hg.CHANGED_THE_GOAL):"delete_goal"===e.action_type?mg(hg.DELETED_THIS_GOAL):"decompose_goals"===e.action_type?`${mg(hg.DECOMPOSED_THIS_GOAL,{count:e.metadata.sub_goals_count})}${e.metadata.sub_goals.map((e=>e.title)).join(mg(hg.COMMA))}`:"alter_owner"===e.action_type?mg(hg.SET_OWNER,{user:e.metadata.after.owner.user_name}):"alter_user"===e.action_type?function(e){const t=[],i=[],n=new Set(e.metadata.before.users.map((e=>e.user_name)));for(const t of e.metadata.after.users)n.has(t.user_name)||i.push(t.user_name);const a=new Set(e.metadata.after.users.map((e=>e.user_name)));for(const i of e.metadata.before.users)a.has(i.user_name)||t.push(i.user_name);const r=[];return t.length>0&&r.push(mg(hg.REMOVED_GOAL_PARTICIPANTS,{count:t.length})+t.join(mg(hg.COMMA))),i.length>0&&r.push(mg(hg.ADDED_GOAL_PARTICIPANTS,{count:i.length})+i.join(mg(hg.COMMA))),r.join(mg(hg.SEMICOLON))}(e):"add_comment"===e.action_type?mg(hg.COMMENTED):e.action_type),h().createElement("span",{className:"time",title:(0,Hu.P)(e.time,Hu.c.full)},(0,Hu.P)(e.time,Hu.c.relative))),"add_comment"===e.action_type&&h().createElement("div",{className:"comment"},null===(a=e.metadata)||void 0===a?void 0:a.comment_content))}))):h().createElement("div",{className:"loading"},h().createElement(wg,{lib:"antd",icon:"loading-3-quarters",spinning:!0}))}gg=_g,({e:[vg,fg,Eg,xg],c:[Ng,Ag]}=(0,d.A)(gg,[Tg("ai-portal.activity-timeline",{styleTexts:[bg.A]})],[[Sg({attribute:!1}),1,"list"],[Sg(),1,"chatUrlTemplate"]],0,void 0,m.ReactNextElement)),Ag();var Wg=i(99126);let Ig=function(e){return e.TERMINATE_THE_TASK="TERMINATE_THE_TASK",e}({});const Dg="bricks/ai-portal/chat-input",Lg=g.i18n.getFixedT(null,Dg);var Og,zg=i(84479);let Pg,Bg,Ug,Hg,Fg,Gg,Vg,jg,Kg,$g,Yg,qg,Xg,Jg,Qg,Zg,eb,tb,ib,nb,ab,rb,sb,ob,lb;(0,g.initializeI18n)(Dg,{en:{TERMINATE_THE_TASK:"Terminate the task"},zh:{TERMINATE_THE_TASK:"终止任务"}});const cb={lib:"antd",icon:"loading-3-quarters",spinning:!0},db={lib:"fa",prefix:"far",icon:"circle-stop"},pb=(0,m.wrapBrick)("eo-icon"),hb=(0,m.wrapBrick)("ai-portal.icon-button"),{defineElement:ub,property:mb,event:gb}=(0,u.createDecorators)();let bb;var Ab=new WeakMap,vb=new WeakMap,fb=new WeakMap,Eb=new WeakMap,xb=new WeakMap,kb=new WeakMap,wb=new WeakMap,yb=new WeakSet,Tb=new WeakMap,Sb=new WeakMap,Nb=new WeakMap,Cb=new WeakMap,Mb=new WeakMap;class _b extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,yb),(0,r.A)(this,Ab,Bg(this)),(0,r.A)(this,vb,(Ug(this),Hg(this))),(0,r.A)(this,fb,(Fg(this),Gg(this))),(0,r.A)(this,Eb,(Vg(this),jg(this))),(0,r.A)(this,xb,(Kg(this),$g(this))),(0,r.A)(this,kb,(Yg(this),qg(this))),(0,r.A)(this,wb,(Xg(this),Jg(this))),(0,r.A)(this,Tb,(eb(this),e=>{(0,o.A)(yb,this,Qg).emit(e)})),(0,r.A)(this,Sb,tb(this)),(0,r.A)(this,Nb,(ab(this),e=>{(0,o.A)(yb,this,ib).emit(e)})),(0,r.A)(this,Cb,rb(this)),(0,r.A)(this,Mb,(lb(this),()=>{(0,o.A)(yb,this,sb).emit()}))}get placeholder(){return(0,c.A)(Ab,this)}set placeholder(e){(0,l.A)(Ab,this,e)}get autoFocus(){return(0,c.A)(vb,this)}set autoFocus(e){(0,l.A)(vb,this,e)}get submitDisabled(){return(0,c.A)(fb,this)}set submitDisabled(e){(0,l.A)(fb,this,e)}get supportsTerminate(){return(0,c.A)(Eb,this)}set supportsTerminate(e){(0,l.A)(Eb,this,e)}get terminating(){return(0,c.A)(xb,this)}set terminating(e){(0,l.A)(xb,this,e)}get uploadOptions(){return(0,c.A)(kb,this)}set uploadOptions(e){(0,l.A)(kb,this,e)}render(){return h().createElement(Rb,{placeholder:this.placeholder,autoFocus:this.autoFocus,submitDisabled:this.submitDisabled,supportsTerminate:this.supportsTerminate,terminating:this.terminating,uploadOptions:this.uploadOptions,onMessageSubmit:(0,c.A)(Tb,this),onChatSubmit:(0,c.A)(Nb,this),onTerminate:(0,c.A)(Mb,this)})}}function Rb(e){let{placeholder:t,autoFocus:i,submitDisabled:n,supportsTerminate:a,terminating:r,uploadOptions:s,onMessageSubmit:o,onChatSubmit:l,onTerminate:c}=e;const d=(0,p.useRef)(null),u=(0,p.useRef)(null),[m,g]=(0,p.useState)(""),b=(0,p.useRef)(""),[A,v]=(0,p.useState)(!1),f=null==s?void 0:s.enabled,E=null==s?void 0:s.accept,{files:x,resetFiles:k,appendFiles:w,removeFile:y,hasFiles:T,allFilesDone:S,fileInfos:N,exceeded:C,paste:M}=(0,Ut.O)(s),_=(0,p.useRef)(null);(0,p.useEffect)((()=>{f||k()}),[f,k]),(0,p.useEffect)((()=>{var e;i&&!n&&(null===(e=u.current)||void 0===e||e.focus())}),[i,n]);const R=(0,p.useCallback)((e=>{!n&&e&&S&&(o(e),l({content:e,files:N}),b.current="",g(""),k())}),[S,n,o,l,N,k]),W=(0,p.useCallback)((e=>{R(e.currentTarget.value)}),[R]),I=(0,p.useCallback)((e=>{b.current=e.target.value,g(e.target.value)}),[]),D=(0,p.useCallback)((()=>{R(b.current)}),[R]);(0,p.useEffect)((()=>{if(T)return void v(!0);const e=null==d?void 0:d.current;if(!e)return;const t=new Wg.A((t=>{for(const i of t)i.target===e&&(i.contentBoxSize?i.contentBoxSize[0]?i.contentBoxSize[0].blockSize:i.contentBoxSize.blockSize:i.contentRect.height)>52&&v(!0)}));return t.observe(e),()=>{t.disconnect()}}),[T]),(0,p.useEffect)((()=>{m||T||v(!1)}),[m,T]);const L=(0,p.useCallback)((e=>{var t;for(const t of e.nativeEvent.composedPath())if(t instanceof HTMLTextAreaElement||t instanceof HTMLButtonElement)return;null===(t=u.current)||void 0===t||t.focus()}),[]),O=(0,p.useCallback)((e=>{var t;w(e),null===(t=u.current)||void 0===t||t.focus()}),[w]);return h().createElement(h().Fragment,null,h().createElement("div",{className:"container",onClick:L},h().createElement("div",{className:Pn()("box",{wrap:A})},h().createElement("div",{className:"input",ref:d},h().createElement(yt.e,{containerRef:d,ref:u,value:m,minRows:1,maxRows:4,borderSize:0,paddingSize:T?86:16,autoResize:!0,placeholder:t,submitWhen:"enter-without-shift",onSubmit:W,onChange:I,onPaste:M,style:{paddingTop:T?78:8}}),T&&h().createElement(Lt.C,{files:x,className:"condensed",onRemove:(e,t)=>{y(e),null==t||t.abort()},onAdd:()=>{var e;null===(e=_.current)||void 0===e||e.requestUpload()}})),h().createElement("div",{className:"toolbar"},f?h().createElement(h().Fragment,null,h().createElement(Dt.s,{ref:_,accept:E,disabled:C,onChange:e=>{var t;w(e),null===(t=u.current)||void 0===t||t.focus()}}),h().createElement("div",{className:"btn-divider"})):null,n&&a?h().createElement(h().Fragment,null,r?h().createElement(hb,{icon:cb,disabled:!0}):h().createElement(hb,{icon:db,tooltip:Lg(Ig.TERMINATE_THE_TASK),onClick:c})):h().createElement("button",{className:"btn-send",disabled:n||!m||!S,onClick:D},h().createElement(pb,{lib:"fa",icon:"arrow-up"}))))),h().createElement(Ht.A,{disabled:!f||C||(null==s?void 0:s.dragDisabled),uploadOptions:s,onFilesDropped:O}))}Og=_b,({e:[Bg,Ug,Hg,Fg,Gg,Vg,jg,Kg,$g,Yg,qg,Xg,Jg,Qg,Zg,eb,tb,ib,nb,ab,rb,sb,ob,lb],c:[bb,Pg]}=(0,d.A)(Og,[ub("ai-portal.chat-input",{styleTexts:[zg.A,Ot.A],shadowOptions:{delegatesFocus:!0}})],[[mb(),1,"placeholder"],[mb({type:Boolean}),1,"autoFocus"],[mb({type:Boolean}),1,"submitDisabled"],[mb({type:Boolean}),1,"supportsTerminate"],[mb({type:Boolean}),1,"terminating"],[mb({attribute:!1}),1,"uploadOptions"],[gb({type:"message.submit"}),1,"messageSubmit",e=>(0,c.A)(wb,e),(e,t)=>(0,l.A)(wb,e,t)],[gb({type:"chat.submit"}),1,"chatSubmit",e=>(0,c.A)(Sb,e),(e,t)=>(0,l.A)(Sb,e,t)],[gb({type:"terminate"}),1,"terminate",e=>(0,c.A)(Cb,e),(e,t)=>(0,l.A)(Cb,e,t)]],0,(e=>Mb.has((0,s.A)(e))),m.ReactNextElement)),Pg();const Wb=i.p+"images/e47076cc.png";var Ib,Db=i(31653);let Lb;const{defineElement:Ob}=(0,u.createDecorators)();let zb;class Pb extends m.ReactNextElement{render(){return h().createElement("img",{className:"logo",alt:"Elevo",src:Wb,width:95,height:28})}}Ib=Pb,[zb,Lb]=(0,d.A)(Ib,[Ob("ai-portal.elevo-logo",{styleTexts:[Db.A]})],[],0,void 0,m.ReactNextElement).c,Lb();let Bb=function(e){return e.WATCH_REPLAY="WATCH_REPLAY",e}({});const Ub="bricks/ai-portal/show-case",Hb={en:{[Bb.WATCH_REPLAY]:"Watch replay"},zh:{[Bb.WATCH_REPLAY]:"查看回放"}},Fb=g.i18n.getFixedT(null,Ub);var Gb,Vb=i(46122);let jb,Kb,$b,Yb,qb,Xb,Jb;(0,g.initializeI18n)(Ub,Hb);const Qb=["purple","green","pink"],Zb=(0,m.wrapBrick)("eo-icon"),eA=(0,m.wrapBrick)("eo-link"),{defineElement:tA,property:iA}=(0,u.createDecorators)();let nA;var aA=new WeakMap,rA=new WeakMap,sA=new WeakMap;class oA extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,aA,Kb(this)),(0,r.A)(this,rA,($b(this),Yb(this))),(0,r.A)(this,sA,(qb(this),Xb(this))),Jb(this)}get caseTitle(){return(0,c.A)(aA,this)}set caseTitle(e){(0,l.A)(aA,this,e)}get summary(){return(0,c.A)(rA,this)}set summary(e){(0,l.A)(rA,this,e)}get url(){return(0,c.A)(sA,this)}set url(e){(0,l.A)(sA,this,e)}render(){return h().createElement(lA,{caseTitle:this.caseTitle,summary:this.summary,url:this.url})}}function lA(e){let{caseTitle:t,summary:i,url:n}=e;const a=(0,p.useMemo)((()=>{if(!t)return Qb[0];let e=0;for(let i=0;i<t.length;i++)e=t.charCodeAt(i)+((e<<5)-e);const i=Math.abs(e)%Qb.length;return Qb[i]}),[t]);return h().createElement(eA,{className:`link ${a}`,url:n},h().createElement("span",{className:"title"},t),h().createElement("span",{className:"description"},i),h().createElement("span",{className:"mask"}),h().createElement("span",{className:"button"},h().createElement(Zb,{lib:"easyops",icon:"replay"}),Fb(Bb.WATCH_REPLAY)))}Gb=oA,({e:[Kb,$b,Yb,qb,Xb,Jb],c:[nA,jb]}=(0,d.A)(Gb,[tA("ai-portal.show-case",{styleTexts:[Vb.A]})],[[iA(),1,"caseTitle"],[iA(),1,"summary"],[iA(),1,"url"]],0,void 0,m.ReactNextElement)),jb();var cA=i(22919);customElements.define("ai-portal.call-tool",(0,_t.createProviderClass)((async function(e,t){return(await cA.http.post(`api/gateway/logic.llm.aiops_service/api/v1/elevo/conversation/${e.conversationId}/step/${e.stepId}/view`,{params:t})).data})));const dA=i.p+"images/449e2e64.png",pA=i.p+"images/fc2c99bb.png",hA=i.p+"images/27bd64e1.png",uA=i.p+"images/c19e3f37.png";var mA,gA=i(19428);let bA,AA,vA,fA,EA;const{defineElement:xA,property:kA}=(0,u.createDecorators)();let wA;var yA=new WeakMap,TA=new WeakMap;class SA extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,yA,AA(this)),(0,r.A)(this,TA,(vA(this),fA(this))),EA(this)}get illustration(){return(0,c.A)(yA,this)}set illustration(e){(0,l.A)(yA,this,e)}get description(){return(0,c.A)(TA,this)}set description(e){(0,l.A)(TA,this,e)}render(){return h().createElement(NA,{illustration:this.illustration,description:this.description})}}function NA(e){let{illustration:t,description:i}=e;return h().createElement(h().Fragment,null,h().createElement("img",{src:CA(t),width:184,height:138}),h().createElement("p",null,i))}function CA(e){switch(e){case"goals":return dA;case"collaboration-spaces":return hA;case"serviceflows":return uA;default:return pA}}mA=SA,({e:[AA,vA,fA,EA],c:[wA,bA]}=(0,d.A)(mA,[xA("ai-portal.blank-state",{styleTexts:[gA.A]})],[[kA(),1,"illustration"],[kA(),1,"description"]],0,void 0,m.ReactNextElement)),bA();var MA,_A=i(81129);let RA,WA,IA;const{defineElement:DA,property:LA}=(0,u.createDecorators)();let OA;var zA=new WeakMap;class PA extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,zA,WA(this)),IA(this)}get variant(){return(0,c.A)(zA,this)}set variant(e){(0,l.A)(zA,this,e)}render(){return h().createElement(BA,null)}}function BA(){return h().createElement("slot",null)}MA=PA,({e:[WA,IA],c:[OA,RA]}=(0,d.A)(MA,[DA("ai-portal.sticky-container",{styleTexts:[_A.A]})],[[LA({render:!1}),1,"variant"]],0,void 0,m.ReactNextElement)),RA();var UA,HA=i(18338);let FA,GA,VA,jA,KA,$A,YA,qA,XA,JA,QA;const ZA=(0,m.wrapBrick)("eo-link"),ev=(0,m.wrapBrick)("eo-icon"),{defineElement:tv,property:iv}=(0,u.createDecorators)();let nv;var av=new WeakMap,rv=new WeakMap,sv=new WeakMap,ov=new WeakMap,lv=new WeakMap;class cv extends m.ReactNextElement{constructor(){super(...arguments),(0,r.A)(this,av,GA(this)),(0,r.A)(this,rv,(VA(this),jA(this))),(0,r.A)(this,sv,(KA(this),$A(this))),(0,r.A)(this,ov,(YA(this),qA(this))),(0,r.A)(this,lv,(XA(this),JA(this))),QA(this)}get cardTitle(){return(0,c.A)(av,this)}set cardTitle(e){(0,l.A)(av,this,e)}get description(){return(0,c.A)(rv,this)}set description(e){(0,l.A)(rv,this,e)}get url(){return(0,c.A)(sv,this)}set url(e){(0,l.A)(sv,this,e)}get avatar(){return(0,c.A)(ov,this)}set avatar(e){(0,l.A)(ov,this,e)}get avatarType(){return(0,c.A)(lv,this)}set avatarType(e){(0,l.A)(lv,this,e)}render(){return h().createElement(dv,{cardTitle:this.cardTitle,description:this.description,url:this.url,avatar:this.avatar,avatarType:this.avatarType})}}function dv(e){let{cardTitle:t,description:i,url:n,avatar:a,avatarType:r}=e;const s=(0,p.useRef)(null),o=hr(s),l=(0,p.useRef)(null),c=hr(l);return h().createElement(ZA,{className:Pn()("card",{clickable:!!n}),url:n},h().createElement("div",{className:"header"},h().createElement("div",{className:"heading"},"image"!==r&&a?h().createElement(pv,a):h().createElement("div",{className:"avatar"}),h().createElement("div",{className:"title"},t)),h().createElement("div",{className:"actions",hidden:!c},h().createElement("slot",{name:"actions",ref:l}))),h().createElement("div",{className:"body"},i),h().createElement("div",{className:"footer",hidden:!o},h().createElement("slot",{name:"footer",ref:s})))}function pv(e){let{color:t,...i}=e;return h().createElement("div",{className:"avatar",style:t?{borderColor:`rgba(var(--theme-${t}-color-rgb-channel), 0.15)`,color:`var(--theme-${t}-color)`}:void 0},h().createElement(ev,i))}UA=cv,({e:[GA,VA,jA,KA,$A,YA,qA,XA,JA,QA],c:[nv,FA]}=(0,d.A)(UA,[tv("ai-portal.elevo-card",{styleTexts:[HA.A]})],[[iv(),1,"cardTitle"],[iv(),1,"description"],[iv(),1,"url"],[iv({attribute:!1}),1,"avatar"],[iv(),1,"avatarType"]],0,void 0,m.ReactNextElement)),FA();const hv=window.devicePixelRatio||1,uv=40,mv=12,gv=36*Math.PI/180,bv=mv*(1-Math.sin(gv)),Av=mv*Math.cos(gv),vv=(uv-2*bv)*Math.tan(gv),fv=Av+vv/2;var Ev,xv=i(29511);let kv,wv,yv,Tv,Sv,Nv,Cv,Mv,_v;const{defineElement:Rv,property:Wv,event:Iv}=(0,u.createDecorators)();let Dv;var Lv=new WeakMap,Ov=new WeakMap,zv=new WeakMap,Pv=new WeakSet,Bv=new WeakMap;class Uv extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,Pv),(0,r.A)(this,Lv,wv(this)),(0,r.A)(this,Ov,(yv(this),Tv(this))),(0,r.A)(this,zv,(Sv(this),Nv(this))),(0,r.A)(this,Bv,(_v(this),e=>{this.activeTab=e.id,(0,o.A)(Pv,this,Cv).emit(e)}))}get tabs(){return(0,c.A)(Lv,this)}set tabs(e){(0,l.A)(Lv,this,e)}get activeTab(){return(0,c.A)(Ov,this)}set activeTab(e){(0,l.A)(Ov,this,e)}render(){return h().createElement(Hv,{tabs:this.tabs,activeTab:this.activeTab,onTabClick:(0,c.A)(Bv,this)})}}function Hv(e){let{tabs:t,activeTab:i,onTabClick:n}=e;const a=(0,p.useRef)(null),r=(0,p.useRef)(null),s=(0,p.useRef)(null);return(0,p.useEffect)((()=>{const e=a.current,i=r.current,n=s.current;if(!(e&&i&&n&&null!=t&&t.length))return;const o=i.getContext("2d");if(!o)return;let l,c;const d=new Wg.A((t=>{for(const i of t)if(i.target===e){const e=Fv(i,"width"),t=Fv(i,"height");l=[e,t]}const a=Array.from(n.querySelectorAll(".tab")),r=a.find((e=>e.classList.contains("active")));if(!r)return;const s=r.getBoundingClientRect().width,d=0===a.indexOf(r);let p=0;if(!d){const e=n.getBoundingClientRect().left,t=r.getBoundingClientRect().left;p=t-e}c&&cancelAnimationFrame(c),c=requestAnimationFrame((()=>{l&&function(e,t,i,n,a,r,s){e.width=i*hv,e.height=n*hv,e.style.width=`${i}px`,e.style.height=`${n}px`,t.scale(hv,hv),t.clearRect(0,0,i,n),t.fillStyle="rgba(255,255,255,0.5)";const o=t.createLinearGradient(0,0,0,n);o.addColorStop(0,"rgba(255,255,255,0.9)"),o.addColorStop(1,"rgba(255,255,255,0.4)"),t.lineWidth=1,t.strokeStyle=o;const l=i-1,c=n-1;if(t.translate(.5,.5),t.beginPath(),a)t.moveTo(0,mv),t.arcTo(0,0,mv,0,mv);else{t.moveTo(0,52),t.arcTo(0,uv,mv,uv,mv);const e=r-fv;t.lineTo(e,uv),t.arc(e,28,mv,Math.PI/2,gv,!0),t.lineTo(e+Av+vv,bv),t.arc(e+2*fv,mv,mv,Math.PI+gv,1.5*Math.PI,!1)}const d=r+s-fv;t.lineTo(d,0),t.arc(d,mv,mv,1.5*Math.PI,2*Math.PI-gv,!1),t.lineTo(d+Av+vv,uv-bv),t.arc(d+2*fv,28,mv,Math.PI-gv,Math.PI/2,!0),t.lineTo(l-mv,uv),t.arcTo(l,uv,l,52,mv),t.lineTo(l,c-mv),t.arcTo(l,c,l-mv,c,mv),t.lineTo(mv,c),t.arcTo(0,c,0,c-mv,mv),t.closePath(),t.fill(),t.stroke()}(i,o,l[0],l[1],d,p,s)}))}));return d.observe(e),d.observe(n),()=>{d.disconnect(),c&&cancelAnimationFrame(c)}}),[t,i]),h().createElement("div",{className:"container",ref:a},h().createElement("canvas",{className:"bg",ref:r}),h().createElement("div",{className:"header"},h().createElement("ul",{className:"tabs",ref:s},null==t?void 0:t.map((e=>h().createElement("li",{key:e.id,part:"tab",className:Pn()("tab",{active:e.id===i})},h().createElement("a",{onClick:()=>n(e)},e.label))))),h().createElement("div",{className:"toolbar"},h().createElement("slot",{name:"toolbar"}))),h().createElement("div",{className:"body"},h().createElement("slot",null)))}function Fv(e,t){const i="height"===t?"blockSize":"inlineSize";return e.contentBoxSize?e.contentBoxSize[0]?e.contentBoxSize[0][i]:e.contentBoxSize[i]:e.contentRect[t]}Ev=Uv,({e:[wv,yv,Tv,Sv,Nv,Cv,Mv,_v],c:[Dv,kv]}=(0,d.A)(Ev,[Rv("ai-portal.flow-tabs",{styleTexts:[xv.A]})],[[Wv({attribute:!1}),1,"tabs"],[Wv({attribute:!1}),1,"activeTab"],[Iv({type:"tab.click"}),1,"tabClick",e=>(0,c.A)(zv,e),(e,t)=>(0,l.A)(zv,e,t)]],0,(e=>Bv.has((0,s.A)(e))),m.ReactNextElement)),kv();let Gv=function(e){return e.ADD_STAGE="ADD_STAGE",e.PLEASE_ENTER_NAME="PLEASE_ENTER_NAME",e.UNASSIGNED="UNASSIGNED",e.DELETE_STAGE="DELETE_STAGE",e.DELETE_STAGE_TIPS="DELETE_STAGE_TIPS",e.DELETE="DELETE",e.ADD_ACTIVITY="ADD_ACTIVITY",e.STAGE_NAME_EXISTS="STAGE_NAME_EXISTS",e.ACTIVITY_NAME_EXISTS="ACTIVITY_NAME_EXISTS",e}({});const Vv="bricks/ai-portal/stage-flow",jv={en:{[Gv.ADD_STAGE]:"Add stage",[Gv.PLEASE_ENTER_NAME]:"Please enter name",[Gv.UNASSIGNED]:"Unassigned",[Gv.DELETE_STAGE]:"Delete stage",[Gv.DELETE_STAGE_TIPS]:'Are you sure you want to delete stage "{{ name }}"?',[Gv.DELETE]:"Delete",[Gv.ADD_ACTIVITY]:"Add activity",[Gv.STAGE_NAME_EXISTS]:'Stage with name "{{ name }}" already exists.',[Gv.ACTIVITY_NAME_EXISTS]:'Activity with name "{{ name }}" already exists.'},zh:{[Gv.ADD_STAGE]:"添加阶段",[Gv.PLEASE_ENTER_NAME]:"请输入名称",[Gv.UNASSIGNED]:"未设置",[Gv.DELETE_STAGE]:"删除阶段",[Gv.DELETE_STAGE_TIPS]:"您确定要删除阶段 “{{ name }}” 吗?",[Gv.DELETE]:"删除",[Gv.ADD_ACTIVITY]:"添加活动",[Gv.STAGE_NAME_EXISTS]:'阶段名称 "{{ name }}" 已存在。',[Gv.ACTIVITY_NAME_EXISTS]:'活动名称 "{{ name }}" 已存在。'}},Kv=g.i18n.getFixedT(null,Vv);var $v,Yv=i(66489);let qv,Xv,Jv,Qv,Zv,ef,tf,nf,af,rf,sf,of,lf,cf,df,pf,hf,uf,mf,gf;(0,g.initializeI18n)(Vv,jv);const bf=(0,m.wrapBrick)("eo-icon"),Af=(0,m.wrapBrick)("eo-popover",{onVisibleChange:"visible.change",onBeforeVisibleChange:"before.visible.change"}),vf=(0,m.wrapBrick)("eo-input",{onChange:"change"}),ff=(0,_t.unwrapProvider)("basic.show-dialog"),{defineElement:Ef,property:xf,event:kf,method:wf}=(0,u.createDecorators)(),yf=(0,p.forwardRef)(Pf);let Tf;var Sf=new WeakMap,Nf=new WeakMap,Cf=new WeakMap,Mf=new WeakMap,_f=new WeakSet,Rf=new WeakMap,Wf=new WeakMap,If=new WeakMap,Df=new WeakMap,Lf=new WeakMap,Of=new WeakMap;class zf extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,_f),(0,r.A)(this,Sf,(qv(this),Jv(this))),(0,r.A)(this,Nf,(Qv(this),Zv(this))),(0,r.A)(this,Cf,(ef(this),tf(this))),(0,r.A)(this,Mf,(nf(this),af(this))),(0,r.A)(this,Rf,(of(this),e=>{(0,o.A)(_f,this,rf).emit(e)})),(0,r.A)(this,Wf,lf(this)),(0,r.A)(this,If,(pf(this),e=>{(0,o.A)(_f,this,cf).emit({stage:e})})),(0,r.A)(this,Df,hf(this)),(0,r.A)(this,Lf,(gf(this),e=>{(0,o.A)(_f,this,uf).emit(e)})),(0,r.A)(this,Of,(0,p.createRef)())}get spec(){return(0,c.A)(Sf,this)}set spec(e){(0,l.A)(Sf,this,e)}get aiEmployees(){return(0,c.A)(Nf,this)}set aiEmployees(e){(0,l.A)(Nf,this,e)}get readOnly(){return(0,c.A)(Cf,this)}set readOnly(e){(0,l.A)(Cf,this,e)}addActivity(e,t){var i;null===(i=(0,c.A)(Of,this).current)||void 0===i||i.addActivity(e,t)}editActivity(e,t,i){var n;null===(n=(0,c.A)(Of,this).current)||void 0===n||n.editActivity(e,t,i)}deleteActivity(e,t){var i;null===(i=(0,c.A)(Of,this).current)||void 0===i||i.deleteActivity(e,t)}render(){return h().createElement(yf,{ref:(0,c.A)(Of,this),spec:this.spec,aiEmployees:this.aiEmployees,readOnly:this.readOnly,onChange:(0,c.A)(Rf,this),onAddActivity:(0,c.A)(If,this),onEditActivity:(0,c.A)(Lf,this)})}}function Pf(e,t){let{spec:i,aiEmployees:n,readOnly:a,onChange:r,onAddActivity:s,onEditActivity:o}=e;const[l,c]=(0,p.useState)(i),[d,u]=(0,p.useState)(!1),m=(0,p.useRef)(!0);(0,p.useEffect)((()=>{c(i)}),[i]),(0,p.useEffect)((()=>{m.current?m.current=!1:l&&r(l)}),[l,r]);const g=(0,p.useCallback)((e=>{if(!e)return Kv(Gv.UNASSIGNED);const t=null==n?void 0:n.find((t=>t.employeeId===e));return t?t.name:e}),[n]);return(0,p.useImperativeHandle)(t,(()=>({addActivity(e,t){c((i=>{var n;const a=null!=i?i:[],r=a.findIndex((t=>t.name===e.name));if(-1===r)return a;const s={...a[r]},o=null!==(n=s.serviceFlowActivities)&&void 0!==n?n:[];if(o.find((e=>e.name===t.name)))return ff({type:"warn",content:Kv(Gv.ACTIVITY_NAME_EXISTS,{name:t.name})}),a;const l=[...o,t];s.serviceFlowActivities=l;const c=[...a];return c[r]=s,c}))},editActivity(e,t,i){c((n=>{var a;const r=null!=n?n:[],s=r.findIndex((t=>t.name===e.name));if(-1===s)return r;const o={...r[s]},l=null!==(a=o.serviceFlowActivities)&&void 0!==a?a:[];if(l.find(((e,n)=>e.name===t.name&&n!==i)))return ff({type:"warn",content:Kv(Gv.ACTIVITY_NAME_EXISTS,{name:t.name})}),r;const c=[...l];if(i<0||i>=c.length)return r;c[i]=t,o.serviceFlowActivities=c;const d=[...r];return d[s]=o,d}))},deleteActivity(e,t){c((i=>{var n;const a=null!=i?i:[],r=a.findIndex((t=>t.name===e.name));if(-1===r)return a;const s={...a[r]},o=[...null!==(n=s.serviceFlowActivities)&&void 0!==n?n:[]];if(t<0||t>=o.length)return a;o.splice(t,1),s.serviceFlowActivities=o;const l=[...a];return l[r]=s,l}))}})),[]),h().createElement("div",{className:"container"},h().createElement("ul",{className:"nav"},null==l?void 0:l.map(((e,t)=>h().createElement(Uf,{key:t,stage:e,readOnly:a,otherStageNames:l.filter((t=>t!==e)).map((e=>e.name)),onNameChange:i=>{c((n=>{const a=[...null!=n?n:[]];return a[t]={...e,name:i},a}))},onDelete:()=>{c((e=>(null!=e?e:[]).filter(((e,i)=>i!==t))))}}))),d&&h().createElement("li",{className:"nav-item pending"},h().createElement(Bf,{onDone:e=>{u(!1),e&&c((t=>{const i=null!=t?t:[];return i.find((t=>t.name===e))?(ff({type:"warn",content:Kv(Gv.STAGE_NAME_EXISTS,{name:e})}),i):[...i,{name:e}]}))}})),!a&&h().createElement("li",{className:"nav-add"},h().createElement("button",{className:"btn-add-stage",onClick:()=>u(!0)},h().createElement(bf,{lib:"antd",icon:"plus",className:"plus"}),Kv(Gv.ADD_STAGE)))),h().createElement("div",{className:"lanes"},null==l?void 0:l.map(((e,t)=>{var i;return h().createElement("ul",{className:"lane",key:t},null===(i=e.serviceFlowActivities)||void 0===i?void 0:i.map(((t,i)=>h().createElement("li",{key:i},h().createElement("div",{className:"activity",onClick:()=>{a||o({stage:e,activity:t,activityIndex:i})}},h().createElement("div",{className:"title"},t.name),h().createElement("div",{className:"assignee"},h().createElement(bf,{lib:"antd",icon:"user",className:"assignee-icon"}),g(t.aiEmployeeId)))))),!a&&h().createElement("li",null,h().createElement("button",{className:"btn-add-activity",onClick:()=>s(e)},h().createElement(bf,{lib:"antd",icon:"plus"}),Kv(Gv.ADD_ACTIVITY))))}))))}function Bf(e){let{onDone:t}=e;const i=(0,p.useRef)(!1);return h().createElement("input",{className:"input-new-stage",type:"text",placeholder:Kv(Gv.PLEASE_ENTER_NAME),autoFocus:!0,onCompositionStart:()=>{i.current=!0},onCompositionEnd:()=>{i.current=!1},onKeyDown:e=>{if(!i.current)if("Enter"===e.key){e.preventDefault();const i=e.target.value.trim();t(i)}else"Escape"===e.key&&(e.preventDefault(),t(""))},onBlur:e=>{const i=e.target.value.trim();t(i)}})}function Uf(e){let{stage:t,otherStageNames:i,readOnly:n,onNameChange:a,onDelete:r}=e;const s=(0,p.useRef)(!1),o=(0,p.useRef)(null);return n?h().createElement("li",{className:"nav-item"},h().createElement("span",{className:"nav-link"},h().createElement("span",null,t.name))):h().createElement("li",{className:"nav-item"},h().createElement(Af,{trigger:"click",placement:"bottom",sync:"width",arrow:!1,distance:8,themeVariant:"elevo",ref:o},h().createElement("button",{className:"nav-link",slot:"anchor"},h().createElement("span",null,t.name)),h().createElement("div",{className:"stage-settings"},h().createElement(vf,{value:t.name,themeVariant:"elevo",onCompositionStart:()=>{s.current=!0},onCompositionEnd:()=>{s.current=!1},onBlur:e=>{var n;const r=null===(n=e.currentTarget.value)||void 0===n?void 0:n.trim();r&&r!==t.name?i.includes(r)?(ff({type:"warn",content:Kv(Gv.STAGE_NAME_EXISTS,{name:r})}),e.currentTarget.value=t.name):a(r):r||(e.currentTarget.value=t.name)},onKeyDown:e=>{s.current||"Enter"===e.key&&(e.preventDefault(),o.current.active=!1)}}),h().createElement("div",{className:"divider"}),h().createElement("button",{onClick:async()=>{o.current.active=!1,await ff({type:"delete",title:Kv(Gv.DELETE_STAGE),content:Kv(Gv.DELETE_STAGE_TIPS,{name:t.name})}),r(t)}},Kv(Gv.DELETE)))))}$v=zf,({e:[Jv,Qv,Zv,ef,tf,nf,af,rf,sf,of,lf,cf,df,pf,hf,uf,mf,gf,qv],c:[Tf,Xv]}=(0,d.A)($v,[Ef("ai-portal.stage-flow",{styleTexts:[Yv.A]})],[[xf({attribute:!1}),1,"spec"],[xf({attribute:!1}),1,"aiEmployees"],[xf({type:Boolean}),1,"readOnly"],[kf({type:"change"}),1,"change",e=>(0,c.A)(Mf,e),(e,t)=>(0,l.A)(Mf,e,t)],[kf({type:"add.activity"}),1,"addActivity",e=>(0,c.A)(Wf,e),(e,t)=>(0,l.A)(Wf,e,t)],[kf({type:"edit.activity"}),1,"editActivity",e=>(0,c.A)(Df,e),(e,t)=>(0,l.A)(Df,e,t)],[wf(),2,"addActivity"],[wf(),2,"editActivity"],[wf(),2,"deleteActivity"]],0,(e=>Of.has((0,s.A)(e))),m.ReactNextElement)),Xv();var Hf=i(65100);const Ff=e=>p.createElement("svg",(0,qi.A)({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"currentColor",stroke:"currentColor","aria-hidden":"true",viewBox:"0 0 20 26"},e),p.createElement("g",{fillRule:"evenodd"},p.createElement("path",{d:"M12 9H8a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v4a1 1 0 0 1-1 1zm0 10H8a1 1 0 0 1-1-1v-4a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v4a1 1 0 0 1-1 1zM10 7v9"}),p.createElement("path",{strokeLinecap:"round",d:"M17.112 16.112h-4.224"})));var Gf,Vf=i(625);let jf,Kf,$f,Yf,qf,Xf,Jf,Qf,Zf;const eE=(0,m.wrapBrick)("eo-icon"),{defineElement:tE,property:iE,event:nE}=(0,u.createDecorators)();let aE;var rE=new WeakMap,sE=new WeakMap,oE=new WeakMap,lE=new WeakSet,cE=new WeakMap;class dE extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,lE),(0,r.A)(this,rE,Kf(this)),(0,r.A)(this,sE,($f(this),Yf(this))),(0,r.A)(this,oE,(qf(this),Xf(this))),(0,r.A)(this,cE,(Zf(this),e=>{var t;null===(t=(0,o.A)(lE,this,Jf))||void 0===t||t.emit(e)}))}get spec(){return(0,c.A)(rE,this)}set spec(e){(0,l.A)(rE,this,e)}get activeActivityId(){return(0,c.A)(sE,this)}set activeActivityId(e){(0,l.A)(sE,this,e)}render(){return h().createElement(pE,{spec:this.spec,activeActivityId:this.activeActivityId,onActiveChange:(0,c.A)(cE,this)})}}function pE(e){let{spec:t,activeActivityId:i,onActiveChange:n}=e;const[a,r]=(0,p.useState)(i||null);return(0,p.useEffect)((()=>{r(i||null)}),[i]),h().createElement("div",{className:"container"},h().createElement("ul",{className:"nav"},null==t?void 0:t.map(((e,t)=>h().createElement("li",{key:t,className:"nav-item"},h().createElement("div",{className:"nav-content"},h().createElement("span",{className:"icon"},h().createElement(Ff,null)),h().createElement("div",{className:"title"},e.name)))))),h().createElement("div",{className:"lanes"},null==t?void 0:t.map(((e,t)=>{var i;return h().createElement("ul",{className:"lane",key:t},null===(i=e.serviceFlowActivities)||void 0===i?void 0:i.map(((e,t)=>h().createElement("li",{key:t},h().createElement("div",{className:Pn()("activity",hE(e.state),{active:a&&e.taskId===a}),onClick:()=>{e.taskId&&a!==e.taskId&&(r(e.taskId),n(e.taskId))}},h().createElement(eE,(0,qi.A)({},(0,Vf.W)(e.state),{className:"icon"})),h().createElement("div",{className:"title"},e.name),null!=e.startTime&&null!=e.endTime&&h().createElement(uE,{startTime:e.startTime,endTime:e.endTime,state:e.state}))))))}))))}function hE(e){switch(e){case"input-required":return"paused";case"completed":return"completed";case"failed":return"failed";case"working":return"working";default:return"default"}}function uE(e){let{startTime:t,endTime:i,state:n}=e;const[a,r]=(0,p.useState)(i),s=null!=t&&null==i&&"working"===n;return(0,p.useEffect)((()=>{null!=i&&r(i)}),[i]),(0,p.useEffect)((()=>{if(s){const e=()=>{r(Date.now()/1e3)};e();const t=setInterval(e,1e3);return()=>clearInterval(t)}}),[s]),null==t||null==a?null:h().createElement("div",{className:"duration"},function(e){const t=Math.ceil(e),i=Math.floor(t/60),n=t%60;return`${String(i).padStart(2,"0")}:${String(n).padStart(2,"0")}`}(a-t))}Gf=dE,({e:[Kf,$f,Yf,qf,Xf,Jf,Qf,Zf],c:[aE,jf]}=(0,d.A)(Gf,[tE("ai-portal.running-flow",{styleTexts:[Hf.A]})],[[iE({attribute:!1}),1,"spec"],[iE(),1,"activeActivityId"],[nE({type:"active.change"}),1,"activeChange",e=>(0,c.A)(oE,e),(e,t)=>(0,l.A)(oE,e,t)]],0,(e=>cE.has((0,s.A)(e))),m.ReactNextElement)),jf();let mE=function(e){return e.MESSAGE_LIST="MESSAGE_LIST",e.NO_NEW_MESSAGE="NO_NEW_MESSAGE",e.MARK_ALL_READ="MARK_ALL_READ",e.ENTER_MESSAGE_CENTER="ENTER_MESSAGE_CENTER",e}({});const gE="bricks/ai-portal/notice-dropdown",bE=g.i18n.getFixedT(null,gE);var AE=i(9884);const vE=i.p+"images/0155287e.svg",fE=i.p+"images/218d5865.svg",EE=i.p+"images/dcee4821.svg",xE=i.p+"images/0e89dec0.svg";var kE;let wE,yE,TE,SE,NE,CE,ME,_E,RE,WE,IE,DE,LE,OE,zE,PE,BE,UE,HE,FE,GE,VE,jE,KE,$E,YE,qE;(0,g.initializeI18n)(gE,{en:{MESSAGE_LIST:"Message List",NO_NEW_MESSAGE:"No new messages for now",MARK_ALL_READ:"Mark all as read",ENTER_MESSAGE_CENTER:"Enter Message Center"},zh:{MESSAGE_LIST:"消息列表",NO_NEW_MESSAGE:"暂无新消息",MARK_ALL_READ:"全部已读",ENTER_MESSAGE_CENTER:"进入消息中心"}});const{defineElement:XE,property:JE,event:QE}=(0,u.createDecorators)(),ZE=(0,m.wrapBrick)("eo-popover",{onVisibleChange:"visible.change",onBeforeVisibleChange:"before.visible.change"}),ex=(0,m.wrapBrick)("eo-icon"),tx=(0,m.wrapBrick)("eo-link"),ix=(0,m.wrapBrick)("eo-button"),nx=(0,m.wrapBrick)("eo-counter-badge"),ax=(0,m.wrapBrick)("ai-portal.icon-button");let rx;var sx=new WeakMap,ox=new WeakMap,lx=new WeakMap,cx=new WeakMap,dx=new WeakMap,px=new WeakMap,hx=new WeakMap,ux=new WeakMap,mx=new WeakMap,gx=new WeakMap,bx=new WeakSet,Ax=new WeakMap,vx=new WeakMap,fx=new WeakMap;class Ex extends m.ReactNextElement{constructor(){super(...arguments),(0,a.A)(this,bx),(0,r.A)(this,sx,yE(this)),(0,r.A)(this,ox,(TE(this),SE(this))),(0,r.A)(this,lx,(NE(this),CE(this))),(0,r.A)(this,cx,(ME(this),_E(this))),(0,r.A)(this,dx,(RE(this),WE(this))),(0,r.A)(this,px,(IE(this),DE(this))),(0,r.A)(this,hx,(LE(this),OE(this))),(0,r.A)(this,ux,(zE(this),PE(this))),(0,r.A)(this,mx,(BE(this),UE(this))),(0,r.A)(this,gx,(HE(this),FE(this))),(0,r.A)(this,Ax,(jE(this),KE(this))),(0,r.A)(this,vx,(qE(this),e=>{(0,o.A)(bx,this,GE).emit(e)})),(0,r.A)(this,fx,(()=>{(0,o.A)(bx,this,$E).emit()}))}get dataSource(){return(0,c.A)(sx,this)}set dataSource(e){(0,l.A)(sx,this,e)}get popoverPlacement(){return(0,c.A)(ox,this)}set popoverPlacement(e){(0,l.A)(ox,this,e)}get emptyText(){return(0,c.A)(lx,this)}set emptyText(e){(0,l.A)(lx,this,e)}get notifyCenterUrl(){return(0,c.A)(cx,this)}set notifyCenterUrl(e){(0,l.A)(cx,this,e)}get urlTemplate(){return(0,c.A)(dx,this)}set urlTemplate(e){(0,l.A)(dx,this,e)}get urlTarget(){return(0,c.A)(px,this)}set urlTarget(e){(0,l.A)(px,this,e)}get dropdownMaxWidth(){return(0,c.A)(hx,this)}set dropdownMaxWidth(e){(0,l.A)(hx,this,e)}get dropdownContentStyle(){return(0,c.A)(ux,this)}set dropdownContentStyle(e){(0,l.A)(ux,this,e)}get hideNotifyCenterButton(){return(0,c.A)(mx,this)}set hideNotifyCenterButton(e){(0,l.A)(mx,this,e)}render(){return h().createElement(xx,{dataSource:this.dataSource,popoverPlacement:this.popoverPlacement,emptyText:this.emptyText,onNoticeClick:(0,c.A)(vx,this),urlTemplate:this.urlTemplate,dropdownMaxWidth:this.dropdownMaxWidth,notifyCenterUrl:this.notifyCenterUrl,dropdownContentStyle:this.dropdownContentStyle,onMarkAllRead:(0,c.A)(fx,this),hideNotifyCenterButton:this.hideNotifyCenterButton,urlTarget:this.urlTarget})}}function xx(e){var t;let{dataSource:i=[],popoverPlacement:n,emptyText:a,notifyCenterUrl:r,urlTemplate:s,dropdownMaxWidth:o,dropdownContentStyle:l,onNoticeClick:c,onMarkAllRead:d,hideNotifyCenterButton:u,urlTarget:m}=e;const[g,b]=(0,p.useState)(!1),A=(0,p.useRef)(null),v=(0,p.useCallback)((e=>{b(e.detail)}),[]),f=(0,p.useCallback)((()=>{b(!1)}),[]),E=(0,p.useCallback)((e=>{c(e)}),[c]),x=(0,p.useCallback)((()=>{d()}),[d]);return(0,p.useEffect)((()=>{if(!g)return;const e=e=>{var t;((null===(t=e.composedPath)||void 0===t?void 0:t.call(e))||[]).some((e=>e instanceof HTMLElement&&e===A.current))||b(!1)};return document.addEventListener("click",e,!0),()=>{document.removeEventListener("click",e,!0)}}),[g]),h().createElement(ZE,{className:"popover",placement:n,trigger:"click",active:g,arrow:!1,distance:8,ref:A,onBeforeVisibleChange:v},h().createElement("span",{slot:"anchor"},h().createElement("slot",{name:"trigger"},h().createElement(nx,{showZero:!1,dot:!0,count:null!==(t=null==i?void 0:i.length)&&void 0!==t?t:0,offset:[-5,0]},h().createElement(ax,{icon:{lib:"antd",icon:"bell"}})))),h().createElement("div",{className:"notice-dropdown-content",style:{maxWidth:o}},h().createElement("div",{className:"header"},h().createElement("div",{className:"title"},bE(mE.MESSAGE_LIST)),h().createElement("div",{className:"close-btn",onClick:f},h().createElement(ex,{lib:"antd",icon:"close"}))),h().createElement("div",{className:"content",style:l},(null==i?void 0:i.length)>0?h().createElement("ul",{className:"message-list"},i.map((e=>h().createElement("li",{key:e.id},h().createElement(tx,{className:"link",url:(0,Fl.Q)(s,e),target:m,onClick:()=>E(e)},h().createElement("div",{className:"icon-wrapper"},h().createElement(ex,{imgSrc:kx(e.type),keepSvgOriginalColor:!0})),h().createElement("div",{className:"message-content"},h().createElement("div",{className:"primary-text"},e.title),e.description&&h().createElement("div",{className:"secondary-text"},e.description))))))):h().createElement("div",{className:"empty-state"},a||bE(mE.NO_NEW_MESSAGE))),h().createElement("div",{className:"footer"},h().createElement(ix,{disabled:!(null!=i&&i.length),type:"text",className:"footer-button",onClick:x},bE(mE.MARK_ALL_READ)),!u&&h().createElement(ix,{href:r,type:"text",className:"footer-button"},bE(mE.ENTER_MESSAGE_CENTER)," >"))))}function kx(e){switch(e){case"project":default:return vE;case"account":return fE;case"system":return EE;case"space":return xE}}kE=Ex,({e:[yE,TE,SE,NE,CE,ME,_E,RE,WE,IE,DE,LE,OE,zE,PE,BE,UE,HE,FE,GE,VE,jE,KE,$E,YE,qE],c:[rx,wE]}=(0,d.A)(kE,[XE("ai-portal.notice-dropdown",{styleTexts:[AE.A]})],[[JE({attribute:!1}),1,"dataSource"],[JE(),1,"popoverPlacement"],[JE(),1,"emptyText"],[JE(),1,"notifyCenterUrl"],[JE(),1,"urlTemplate"],[JE(),1,"urlTarget"],[JE(),1,"dropdownMaxWidth"],[JE({attribute:!1}),1,"dropdownContentStyle"],[JE({type:Boolean}),1,"hideNotifyCenterButton"],[QE({type:"notice.click"}),1,"noticeClickEvent",e=>(0,c.A)(gx,e),(e,t)=>(0,l.A)(gx,e,t)],[QE({type:"mark.all.read"}),1,"markAllReadEvent",e=>(0,c.A)(Ax,e),(e,t)=>(0,l.A)(Ax,e,t)]],0,(e=>fx.has((0,s.A)(e))),m.ReactNextElement)),wE()},56791:(e,t,i)=>{e.exports=i.p+"images/3e0f6758.png"},61393:(e,t,i)=>{e.exports=i.p+"images/ecaecc18.svg"},62522:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,"ai-portal\\.preview-container{display:block;background:rgba(247,248,250,1)}.loading--uD2jY9vX{position:absolute;top:50%;left:50%;font-size:48px;color:var(--palette-gray-5);margin:0 -24px}",""]),s.locals={loading:"loading--uD2jY9vX"};const o=s},65100:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,':host{display:block;color:#262626;--running-flow-lane-width:234px;--running-flow-status-color:#aeb3bc}:host([hidden]){display:none}*{box-sizing:border-box}ul{list-style:none;margin:0;padding:0}.nav,\n.lanes{display:flex;gap:40px}.nav-item,\n.lane{width:var(--running-flow-lane-width);flex-shrink:0}.nav-item{position:relative;background-color:#e3e4e5;border-top-left-radius:8px;border-bottom-left-radius:8px}.nav-item::after{content:"";position:absolute;top:0;right:-24px;border-color:transparent;border-style:solid;border-width:24px 0 24px 24px;border-left-color:#e3e4e5}.nav-content{height:48px;display:flex;align-items:center;padding-left:22px}.nav-content .icon{color:#8c8c8c;font-size:22px;display:contents}.nav-content .title{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:0 8px}.lanes{margin-top:16px}.lane{display:flex;flex-direction:column;gap:8px}.lane > li{padding-left:4px}.activity{background:#fff;border-radius:8px;border:1px solid #d9d9d9;height:42px;display:flex;align-items:center;position:relative;padding-left:16px;cursor:pointer}.activity .icon{color:var(--running-flow-status-color);font-size:20px}.activity .title{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#595959;padding:0 7px}.activity .duration{font-size:12px;color:#8c8c8c;background:#fafafa;border-radius:6px;padding:0 8px;height:100%;display:flex;align-items:center}.activity::before{content:"";position:absolute;top:50%;left:-1px;transform:translateY(-50%);width:3px;height:18px;background:var(--running-flow-status-color);border-radius:0 3px 3px 0}.activity:hover{box-shadow:0px 2px 5px 0px rgba(0,0,0,0.08)}.activity.paused{--running-flow-status-color:#f0a22e}.activity.working{--running-flow-status-color:#4f69ff}.activity.completed{--running-flow-status-color:#08bf33}.activity.failed{--running-flow-status-color:var(--color-error)}.activity:not(.active) .icon{color:var(--running-flow-status-color)}.activity:not(.active)::before{background:var(--running-flow-status-color)}.activity.active{background:var(--running-flow-status-color);border-color:var(--running-flow-status-color)}.activity.active .icon,.activity.active .title,.activity.active .duration{color:#fff}.activity.active .duration{background:rgba(250,250,250,0.2)}.activity.active::before{display:none}',""]);const o=s.toString()},66489:(e,t,i)=>{i.d(t,{A:()=>m});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r),o=i(20062),l=i.n(o),c=new URL(i(61393),i.b),d=new URL(i(44492),i.b),p=s()(a()),h=l()(c),u=l()(d);p.push([e.id,`:host{display:block;--stage-flow-lane-width:268px}:host([hidden]){display:none}*{box-sizing:border-box}ul{list-style:none;margin:0;padding:0}button{background:none;border:none;cursor:pointer;padding:0}.button:focus{outline:none}.nav,\n.lanes{display:flex;gap:40px}.nav-item,\n.nav-add,\n.lane{width:var(--stage-flow-lane-width);flex-shrink:0}.nav-item{position:relative;background-color:var(--stage-flow-nav-bg);--stage-flow-nav-bg:rgba(37,64,255,0.1)}.nav-item:first-child{border-top-left-radius:20px;border-bottom-left-radius:20px}.nav-item.pending{--stage-flow-nav-bg:rgba(0,0,0,0.04)}.nav-item::after{content:"";position:absolute;top:0;right:-20px;border-color:transparent;border-style:solid;border-width:20px 0 20px 20px;border-left-color:var(--stage-flow-nav-bg)}.nav-item:not(:first-child)::before{content:"";position:absolute;top:0;left:-30px;width:30px;height:40px;background-color:var(--stage-flow-nav-bg);-webkit-clip-path:polygon(0 0,100% 0,100% 100%,0 100%,20px 50%);clip-path:polygon(0 0,100% 0,100% 100%,0 100%,20px 50%)}.nav-link,\n.btn-add-stage{width:100%;display:flex;align-items:center;justify-content:center;height:40px;font-size:16px}.nav-item.pending:first-child .input-new-stage{padding-left:20px}.nav-link{font-weight:600;color:#000}.nav-link span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.btn-add-stage{font-weight:500;color:rgba(0,0,0,0.65);gap:8px;position:relative}.btn-add-stage .plus{margin-right:8px;font-size:14px}.nav-add:first-child .btn-add-stage{border-radius:20px;border:1px dashed rgba(0,0,0,0.1)}.nav-add:first-child .btn-add-stage:hover{background:rgba(0,0,0,0.04)}.nav-add:not(:first-child) .btn-add-stage::before{content:"";position:absolute;top:0;bottom:0;left:-30px;right:-20px;pointer-events:none;background:url(${h}) center center no-repeat}.nav-add:not(:first-child) .btn-add-stage:hover::before{background-image:url(${u})}.input-new-stage{width:100%;border:none;background:none;display:flex;align-items:center;height:40px;font-weight:600;font-size:16px;color:#000}.input-new-stage::placeholder{color:#8c8c8c;font-weight:400}.input-new-stage:focus{outline:none}.lanes{margin-top:16px}.lane{display:flex;flex-direction:column;gap:8px}.activity{background:#ffffff;box-shadow:0px 1px 2px 0px rgba(0,0,0,0.1);border-radius:8px;padding:12px 14px 10px}.activity .title{font-weight:600;color:#000000;line-height:20px;text-shadow:0px 1px 2px rgba(0,0,0,0.1)}:host(:not([read-only])) .activity{cursor:pointer}.assignee{display:flex;align-items:center;gap:4px;font-size:12px;color:#000000;line-height:17px;margin-top:10px}.assignee-icon{font-size:14px;color:rgba(0,0,0,0.45)}.btn-add-activity{width:100%;display:flex;align-items:center;justify-content:center;gap:8px;height:34px;border:1px dashed rgba(0,0,0,0.1);border-radius:8px;color:rgba(0,0,0,0.45)}.btn-add-activity:hover{background:rgba(0,0,0,0.04);color:rgba(0,0,0,0.65)}.stage-settings{padding:4px;display:flex;flex-direction:column;align-items:stretch;gap:4px}.stage-settings eo-input{margin-bottom:5px}.stage-settings .divider{height:1px;background-color:rgba(0,0,0,0.1)}.stage-settings button{color:var(--color-error);border-radius:6px;padding:5px 8px;font-size:14px;line-height:22px;text-align:left}.stage-settings button:hover{background-color:var(--left-sidebar-item-hover-bg)}`,""]);const m=p.toString()},79286:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,":host{display:block}:host([hidden]){display:none}*{box-sizing:border-box}ul{list-style:none;margin:0;padding:0}.link{display:block}.link::part(link){display:flex;align-items:center;gap:16px;padding:12px 24px;color:#262626;background:rgba(255,255,255,0.6);border-radius:8px;-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px)}.link.actions-active::part(link),\n.link::part(link):hover{background:rgba(0,0,0,0.05);-webkit-backdrop-filter:none;backdrop-filter:none}.item:not(:last-child){margin-bottom:4px}.icon{font-size:18px;margin-right:8px}.title{font-weight:500;font-size:16px}.title,\n.description{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.goal{background:#f0fff8;border-radius:4px;font-weight:500;font-size:12px;color:#1dc897;line-height:20px;padding:2px 8px;white-space:nowrap}.goal.global{background:#e6f4ff;color:#1a7aff}.header{display:flex;align-items:center}.description{color:#595959;margin-top:6px;padding-left:28px;line-height:20px}.time{color:rgba(0,0,0,0.45);white-space:nowrap}.main{flex:1;min-width:0}.operations{display:flex;align-items:center;justify-content:right;width:100px}.operations.lang-zh{width:64px}.link.actions-active .time,\n.link:hover .time,\n.link:not(:hover):not(.actions-active) .actions{display:none}.loading{display:flex;align-items:center;justify-content:center;padding:24px;font-size:20px;color:#595959}",""]);const o=s.toString()},81129:(e,t,i)=>{i.d(t,{A:()=>h});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r),o=i(20062),l=i.n(o),c=new URL(i(32360),i.b),d=s()(a()),p=l()(c);d.push([e.id,`:host{display:block;position:sticky;top:0}:host([hidden]){display:none}:host::before{content:"";display:block;position:absolute;top:0;right:0;bottom:0;left:0;z-index:-1;background-color:rgb(205,206,207);background-image:url(${p});background-position:center;background-size:cover;background-repeat:no-repeat;background-attachment:fixed;pointer-events:none}:host([variant="home"])::before{background-color:#f1f1f1}`,""]);const h=d.toString()},82165:(e,t,i)=>{i.d(t,{A:()=>h});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r),o=i(20062),l=i.n(o),c=new URL(i(32360),i.b),d=s()(a()),p=l()(c);d.push([e.id,`:host{display:block;padding:24px 54px 72px}:host([sticky]){padding-top:0}:host([hidden]){display:none}:host::before{content:"";position:fixed;z-index:-1;top:0;right:0;bottom:0;left:0;background-color:#f1f1f1;background-image:url(${p});background-position:center;background-size:cover;background-repeat:no-repeat;background-attachment:fixed}@media (max-width: 719px){:host{padding-left:24px;padding-right:24px}}`,""]);const h=d.toString()},83059:(e,t,i)=>{i.d(t,{A:()=>h});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r),o=i(20062),l=i.n(o),c=new URL(i(32360),i.b),d=s()(a()),p=l()(c);d.push([e.id,`:host{display:block}:host([hidden]){display:none}:host([with-container]){position:relative;width:100%;height:100%;overflow:hidden;background-color:rgb(205,206,207);background-image:url(${p});background-size:cover;background-repeat:no-repeat;background-position:center;background-attachment:fixed;color:#262626;padding:48px 24px;overflow-y:auto}*{box-sizing:border-box}.container{max-width:1400px;margin:0 auto}h1{font-weight:500;margin:0;font-size:20px;line-height:28px;margin-bottom:17px}.list{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(auto-fill,minmax(320px,1fr));gap:24px}.link{display:block;height:100%}.link::part(link){display:block;height:100%;color:#262626;background:rgba(255,255,255,0.9);box-shadow:0px 2px 5px 0px rgba(0,0,0,0.08);border-radius:12px;padding:20px 26px;box-sizing:border-box}.link:not(.clickable)::part(link){cursor:auto}.clickable::part(link):hover{box-shadow:0px 4px 10px 0px rgba(0,0,0,0.1)}.heading{display:flex;align-items:center}.icon{width:48px;height:48px;display:flex;align-items:center;justify-content:center;background:#ffffff;border-radius:12px;border:1px solid #e8e9ec;font-size:32px;color:#595959;margin-right:16px}.title{font-size:16px;font-weight:500;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.clickable::part(link):hover .title{color:var(--elevo-color-brand)}.description{margin-top:13px;font-size:13px;color:rgba(0,0,0,0.45);line-height:18px;height:54px;display:-webkit-box;-webkit-line-clamp:3;line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}.tags{display:flex;gap:6px;margin:16px 0 -3px}.tag{display:block;background:rgba(0,0,0,0.04);border-radius:4px;font-size:12px;line-height:22px;padding:0 7px}`,""]);const h=d.toString()},84479:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r)()(a());s.push([e.id,":host{display:block}:host([hidden]){display:none}*{box-sizing:border-box}button:focus,\ntextarea:focus{outline:none}button{margin:0;padding:0;font:inherit;background:none;border:none}.container{background-color:#fff;border:2px solid #7891ff;border-radius:12px;box-shadow:0px 9px 28px 8px rgba(0,0,0,0.05),0px 6px 16px 0px rgba(0,0,0,0.08),0px 3px 6px -4px rgba(0,0,0,0.12);cursor:text}.container:not(:has(textarea:focus)){background-color:rgba(255,255,255,0.5);border-color:#99c4ff;-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px)}.box{display:flex;flex-wrap:wrap;border-radius:10px;padding:8px}.input{position:relative;min-width:0;flex:1}.wrap .input{flex-basis:100%}.input textarea{display:block;width:100%;padding:8px;font:inherit;font-size:16px;line-height:24px;color:var(--antd-input-color);border:none;background:none;height:24px;color:#262626}.input textarea::placeholder{color:#bfbfbf}.toolbar{padding:6px 0 6px 8px;margin-left:auto;display:flex;align-items:center;gap:12px}.btn-send{width:28px;height:28px;display:flex;align-items:center;justify-content:center;background:var(--elevo-color-brand);border-radius:8px;color:#fff}.btn-send:disabled{background:rgba(0,0,0,0.15)}.btn-send:not(:disabled){cursor:pointer}.btn-send:not(:disabled):hover{background:#5166ff}.btn-send:not(:disabled):active{background:#1e33cc}.btn-divider{width:1px;height:16px;background:rgba(0,0,0,0.1)}.files.condensed{top:2px;left:8px;right:8px}",""]);const o=s.toString()},88786:(e,t,i)=>{e.exports=i.p+"images/e15a6988.png"},98036:(e,t,i)=>{i.d(t,{A:()=>h});var n=i(36758),a=i.n(n),r=i(40935),s=i.n(r),o=i(20062),l=i.n(o),c=new URL(i(32360),i.b),d=s()(a()),p=l()(c);d.push([e.id,`:host{display:block}:host([hidden]){display:none}:host([with-container]){position:relative;width:100%;height:100%;overflow:hidden;background-color:rgb(205,206,207);background-image:url(${p});background-size:cover;background-repeat:no-repeat;background-position:center;background-attachment:fixed;color:#262626;padding:48px 24px;overflow-y:auto}*{box-sizing:border-box}.container{max-width:1400px;margin:0 auto;margin-bottom:17px}h1,\nh2{font-weight:500;margin:0}h1{font-size:20px;line-height:28px;margin-bottom:17px}h2{font-size:16px;line-height:22px}.groups,\n.list{list-style:none;margin:0;padding:0}.groups{margin-top:27px}.group + .group{margin-top:32px}.list{margin-top:16px;display:grid;grid-template-columns:repeat(auto-fill,minmax(320px,1fr));gap:24px}.link{display:block;height:100%}.link::part(link){display:block;height:100%;color:#262626;background:rgba(255,255,255,0.9);box-shadow:0px 2px 5px 0px rgba(0,0,0,0.08);border-radius:12px;padding:20px 26px;box-sizing:border-box}.link:not(.clickable)::part(link){cursor:auto}.clickable::part(link):hover{box-shadow:0px 4px 10px 0px rgba(0,0,0,0.1)}.heading{display:flex;align-items:center}.avatar{width:48px;height:48px;border-radius:12px;margin-right:16px;background-color:#d5d6e6;display:flex;align-items:center;justify-content:center;font-size:24px;overflow:hidden}.avatar img{width:100%;height:100%}.title{font-size:16px;font-weight:500;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.clickable::part(link):hover .title{color:var(--elevo-color-brand)}.description{margin-top:13px;font-size:13px;color:rgba(0,0,0,0.45);line-height:18px;height:54px;display:-webkit-box;-webkit-line-clamp:3;line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}`,""]);const h=d.toString()}}]);
|
|
2
|
+
//# sourceMappingURL=151.d08c1ef1.js.map
|