@epam/ai-dial-sidebar 1.0.0-dev.512 → 1.0.0-dev.514

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +72 -55
  2. package/package.json +3 -3
package/index.js CHANGED
@@ -52296,7 +52296,7 @@ b(({ icon: e, label: t, colors: n }) => /* @__PURE__ */ j("div", {
52296
52296
  }),
52297
52297
  children: /* @__PURE__ */ j(Uo, {
52298
52298
  title: t,
52299
- icon: /* @__PURE__ */ j("span", {
52299
+ icon: e && /* @__PURE__ */ j("span", {
52300
52300
  className: FB.icon,
52301
52301
  children: e
52302
52302
  }),
@@ -76013,9 +76013,9 @@ var L4 = 2e3, R4 = (e, t = L4) => {
76013
76013
  })]
76014
76014
  });
76015
76015
  }), q4 = {
76016
- thinking: "_thinking_1mmkt_16",
76017
- "cm-shimmer": "_cm-shimmer_1mmkt_1",
76018
- secondaryBorder: "_secondaryBorder_1mmkt_25"
76016
+ thinking: "_thinking_1b9r7_9",
76017
+ "cm-shimmer": "_cm-shimmer_1b9r7_1",
76018
+ secondaryBorder: "_secondaryBorder_1b9r7_18"
76019
76019
  }, J4 = 1, Y4 = () => {
76020
76020
  let e = O(null), t = O(null), [n, r] = k(!1), [i, a] = k(!1), o = x(() => {
76021
76021
  let n = e.current, i = t.current;
@@ -76037,29 +76037,38 @@ var L4 = 2e3, R4 = (e, t = L4) => {
76037
76037
  handleScroll: o
76038
76038
  };
76039
76039
  }, X4 = {
76040
- scrollContainer: "_scrollContainer_1bv91_1",
76041
- tableScrollFadeEnd: "_tableScrollFadeEnd_1bv91_17",
76042
- tableScrollFadeStart: "_tableScrollFadeStart_1bv91_25",
76043
- tableScrollFadeBoth: "_tableScrollFadeBoth_1bv91_33"
76044
- }, Z4 = b(({ children: e, classNames: t, colors: n }) => {
76045
- let { scrollContainerRef: r, tableRef: i, hasContentBeyondStart: a, hasContentBeyondEnd: o, handleScroll: s } = Y4();
76040
+ tableContainer: "_tableContainer_g3hpg_1",
76041
+ tableContainerLight: "_tableContainerLight_g3hpg_6",
76042
+ scrollContainer: "_scrollContainer_g3hpg_10",
76043
+ tableHeaderCell: "_tableHeaderCell_g3hpg_25",
76044
+ sectionRow: "_sectionRow_g3hpg_29",
76045
+ row: "_row_g3hpg_33",
76046
+ rowDivider: "_rowDivider_g3hpg_37",
76047
+ tableScrollFadeEnd: "_tableScrollFadeEnd_g3hpg_45",
76048
+ tableScrollFadeStart: "_tableScrollFadeStart_g3hpg_53",
76049
+ tableScrollFadeBoth: "_tableScrollFadeBoth_g3hpg_61"
76050
+ }, Z4 = b(({ children: e, classNames: t, colors: n, scrollRegionAriaLabel: r = "Scrollable table" }) => {
76051
+ let { scrollContainerRef: i, tableRef: a, hasContentBeyondStart: o, hasContentBeyondEnd: s, handleScroll: c } = Y4(), l = DB({
76052
+ "--cm-markdown-border": n?.border,
76053
+ "--cm-table-scrollbar": n?.scrollbar,
76054
+ "--cm-table-fade": n?.fade
76055
+ }), u = o || s;
76046
76056
  return /* @__PURE__ */ j("div", {
76047
- style: DB({
76048
- "--cm-markdown-border": n?.border,
76049
- "--cm-table-scrollbar": n?.scrollbar,
76050
- "--cm-table-fade": n?.fade
76051
- }),
76052
- className: EB("relative w-full min-w-0 max-w-full overflow-hidden", t.tableWrapper),
76057
+ style: l,
76058
+ className: EB("relative w-full min-w-0 max-w-full overflow-hidden rounded-xl border", X4.tableContainer, X4.tableContainerLight, t.tableWrapper),
76053
76059
  children: /* @__PURE__ */ j("div", {
76054
- ref: r,
76055
- className: EB("w-full min-w-0 max-w-full overflow-x-auto rounded border", X4.scrollContainer, {
76056
- [X4.tableScrollFadeBoth]: a && o,
76057
- [X4.tableScrollFadeStart]: a && !o,
76058
- [X4.tableScrollFadeEnd]: !a && o
76060
+ ref: i,
76061
+ className: EB("w-full min-w-0 max-w-full overflow-x-auto", X4.scrollContainer, {
76062
+ [X4.tableScrollFadeBoth]: o && s,
76063
+ [X4.tableScrollFadeStart]: o && !s,
76064
+ [X4.tableScrollFadeEnd]: !o && s
76059
76065
  }),
76060
- onScroll: s,
76066
+ onScroll: c,
76067
+ role: u ? "region" : void 0,
76068
+ "aria-label": u ? r : void 0,
76069
+ tabIndex: u ? 0 : void 0,
76061
76070
  children: /* @__PURE__ */ j("table", {
76062
- ref: i,
76071
+ ref: a,
76063
76072
  className: EB("w-max min-w-full border-collapse", t.tableFont ?? "text-sm"),
76064
76073
  children: e
76065
76074
  })
@@ -76075,7 +76084,7 @@ var L4 = 2e3, R4 = (e, t = L4) => {
76075
76084
  }), $4 = [xX], e3 = {}, t3 = { li: ({ children: e }) => /* @__PURE__ */ j("li", {
76076
76085
  className: "mb-1.5 last:mb-0",
76077
76086
  children: e
76078
- }) }, n3 = (e, t, n, r, i) => ({
76087
+ }) }, n3 = (e) => e ? e.type === "text" ? e.value ?? "" : (e.children ?? []).map(n3).join("") : "", r3 = (e, t, n, r, i, a) => ({
76079
76088
  h1: ({ children: t }) => /* @__PURE__ */ j("h1", {
76080
76089
  className: e.h1,
76081
76090
  children: t
@@ -76157,23 +76166,32 @@ var L4 = 2e3, R4 = (e, t = L4) => {
76157
76166
  input: ({ type: e, checked: t }) => e === "checkbox" ? /* @__PURE__ */ j(Q4, { checked: t ?? !1 }) : null,
76158
76167
  table: ({ children: t }) => /* @__PURE__ */ j(Z4, {
76159
76168
  classNames: e,
76169
+ scrollRegionAriaLabel: a,
76160
76170
  children: t
76161
76171
  }),
76172
+ tr: ({ children: e, node: t }) => {
76173
+ let n = t?.children.filter((e) => e.type === "element") ?? [], r = n.some((e) => e.tagName === "th"), i = n.filter((e) => n3(e).trim().length > 0).length, a = !r && n.length > 1 && i === 1;
76174
+ return /* @__PURE__ */ j("tr", {
76175
+ className: EB(X4.row, a && X4.sectionRow),
76176
+ children: e
76177
+ });
76178
+ },
76162
76179
  th: ({ children: t }) => /* @__PURE__ */ j("th", {
76163
- className: EB("max-w-96 whitespace-normal break-words border-b px-3 py-2.5 text-start text-secondary", q4.secondaryBorder, e.tableHeaderFont ?? "font-semibold", e.tableCell, e.tableHeader),
76180
+ scope: "col",
76181
+ className: EB("sticky top-0 z-[2] max-w-96 whitespace-normal break-words border-b px-3 py-2.5 text-start [overflow-wrap:anywhere]", X4.rowDivider, X4.tableHeaderCell, e.tableHeaderFont ?? "dial-tiny-semi-text uppercase tracking-wider text-secondary", e.tableCell, e.tableHeader),
76164
76182
  children: t
76165
76183
  }),
76166
76184
  td: ({ children: t }) => /* @__PURE__ */ j("td", {
76167
- className: EB("max-w-96 whitespace-normal break-words border-b px-3 py-2.5 align-top", q4.secondaryBorder, e.tableBodyCell, e.tableCell),
76185
+ className: EB("max-w-96 whitespace-normal break-words border-b px-3 py-2.5 align-top [overflow-wrap:anywhere]", X4.rowDivider, e.tableBodyCell, e.tableCell),
76168
76186
  children: t
76169
76187
  })
76170
- }), r3 = b(({ content: e, isStreaming: t, streamCharactersPerSecond: n, classNames: r = e3, components: i, thinkingLabel: a = "Thinking", codeBlockCopyLabel: o, codeBlockCopiedLabel: s, codeBlockTheme: c, colors: l }) => {
76171
- let u = OX(e, t, n), d = DB({
76188
+ }), i3 = b(({ content: e, isStreaming: t, streamCharactersPerSecond: n, classNames: r = e3, components: i, thinkingLabel: a = "Thinking", codeBlockCopyLabel: o, codeBlockCopiedLabel: s, codeBlockTheme: c, colors: l, tableScrollRegionAriaLabel: u }) => {
76189
+ let d = OX(e, t, n), f = DB({
76172
76190
  "--cm-thinking-inverted": l?.thinkingPrimary,
76173
76191
  "--cm-thinking-secondary": l?.thinkingSecondary,
76174
76192
  "--cm-markdown-border": l?.border
76175
- }), f = D(() => ({
76176
- ...n3(r, t, o, s, c),
76193
+ }), p = D(() => ({
76194
+ ...r3(r, t, o, s, c, u),
76177
76195
  ...t3,
76178
76196
  ...i
76179
76197
  }), [
@@ -76182,21 +76200,22 @@ var L4 = 2e3, R4 = (e, t = L4) => {
76182
76200
  o,
76183
76201
  s,
76184
76202
  c,
76203
+ u,
76185
76204
  i
76186
76205
  ]);
76187
- return t && !u ? /* @__PURE__ */ j("span", {
76206
+ return t && !d ? /* @__PURE__ */ j("span", {
76188
76207
  className: q4.thinking,
76189
- style: d,
76208
+ style: f,
76190
76209
  children: a
76191
76210
  }) : /* @__PURE__ */ j("div", {
76192
- style: d,
76211
+ style: f,
76193
76212
  children: /* @__PURE__ */ j(_q, {
76194
76213
  remarkPlugins: $4,
76195
- components: f,
76196
- children: u
76214
+ components: p,
76215
+ children: d
76197
76216
  })
76198
76217
  });
76199
- }), i3 = {
76218
+ }), a3 = {
76200
76219
  h1: "dial-h1-text mb-3 mt-6 first:mt-0 [text-wrap:balance]",
76201
76220
  h2: "dial-h2-text mb-2 mt-5 first:mt-0 [text-wrap:balance]",
76202
76221
  h3: "dial-h3-text mb-2 mt-4 first:mt-0 [text-wrap:balance]",
@@ -76209,11 +76228,9 @@ var L4 = 2e3, R4 = (e, t = L4) => {
76209
76228
  codeInline: "mx-0.5 bg-layer-3 px-1.5 text-[0.875em] text-primary break-words [overflow-wrap:anywhere]",
76210
76229
  blockquote: "my-4",
76211
76230
  link: "break-words [overflow-wrap:anywhere]",
76212
- tableWrapper: "my-4",
76213
- tableHeader: "bg-layer-3",
76214
- tableBodyCell: "bg-layer-2"
76231
+ tableWrapper: "my-4"
76215
76232
  };
76216
- b(({ content: e, isStreaming: t, thinkingLabel: n, components: r, codeBlockCopyLabel: i, codeBlockCopiedLabel: a, codeBlockTheme: o }) => /* @__PURE__ */ j(r3, {
76233
+ b(({ content: e, isStreaming: t, thinkingLabel: n, components: r, codeBlockCopyLabel: i, codeBlockCopiedLabel: a, codeBlockTheme: o }) => /* @__PURE__ */ j(i3, {
76217
76234
  content: e,
76218
76235
  isStreaming: t,
76219
76236
  thinkingLabel: n,
@@ -76221,28 +76238,28 @@ b(({ content: e, isStreaming: t, thinkingLabel: n, components: r, codeBlockCopyL
76221
76238
  codeBlockCopyLabel: i,
76222
76239
  codeBlockCopiedLabel: a,
76223
76240
  codeBlockTheme: o,
76224
- classNames: i3
76241
+ classNames: a3
76225
76242
  }));
76226
- var a3 = {
76243
+ var o3 = {
76227
76244
  container: "_container_bc4pw_1",
76228
76245
  icon: "_icon_bc4pw_16",
76229
76246
  input: "_input_bc4pw_20"
76230
- }, o3 = ({ value: e, onChange: t, labels: n, iconSize: r = ko.MD, iconStrokeWidth: i, styles: a }) => {
76247
+ }, s3 = ({ value: e, onChange: t, labels: n, iconSize: r = ko.MD, iconStrokeWidth: i, styles: a }) => {
76231
76248
  let { placeholder: o = "Search", ariaLabel: s, clearLabel: c = "Clear search" } = n ?? {}, { containerClassName: l, iconClassName: u, inputClassName: d, clearButtonClassName: f } = a ?? {}, p = s ?? o;
76232
76249
  return /* @__PURE__ */ j("div", {
76233
76250
  role: "search",
76234
76251
  children: /* @__PURE__ */ M("div", {
76235
- className: EB(a3.container, "flex cursor-text items-center gap-3 rounded-xl border px-4 py-2 transition-[border-color,box-shadow] duration-150 ease-in-out", l),
76252
+ className: EB(o3.container, "flex cursor-text items-center gap-3 rounded-xl border px-4 py-2 transition-[border-color,box-shadow] duration-150 ease-in-out", l),
76236
76253
  children: [
76237
76254
  /* @__PURE__ */ j(be, {
76238
76255
  size: r,
76239
76256
  stroke: i,
76240
- className: EB(a3.icon, "shrink-0 transition-colors duration-150 ease-in-out", u),
76257
+ className: EB(o3.icon, "shrink-0 transition-colors duration-150 ease-in-out", u),
76241
76258
  "aria-hidden": !0
76242
76259
  }),
76243
76260
  /* @__PURE__ */ j("input", {
76244
76261
  type: "text",
76245
- className: EB(a3.input, "min-w-0 flex-1 border-0 p-0 text-sm font-normal leading-5 outline-none", d),
76262
+ className: EB(o3.input, "min-w-0 flex-1 border-0 p-0 text-sm font-normal leading-5 outline-none", d),
76246
76263
  value: e,
76247
76264
  placeholder: o,
76248
76265
  "aria-label": p,
@@ -76256,14 +76273,14 @@ var a3 = {
76256
76273
  children: /* @__PURE__ */ j(xe, {
76257
76274
  size: r,
76258
76275
  stroke: i,
76259
- className: EB(a3.icon, u),
76276
+ className: EB(o3.icon, u),
76260
76277
  "aria-hidden": !0
76261
76278
  })
76262
76279
  })
76263
76280
  ]
76264
76281
  })
76265
76282
  });
76266
- }, s3 = {
76283
+ }, c3 = {
76267
76284
  tabContainer: "_tabContainer_rzv03_1",
76268
76285
  tabActive: "_tabActive_rzv03_13"
76269
76286
  };
@@ -76277,17 +76294,17 @@ b(({ tabs: e, activeTabId: t, onTabChange: n, styles: r }) => {
76277
76294
  label: e.label,
76278
76295
  selected: r,
76279
76296
  onClick: () => n(e.id),
76280
- className: EB("box-border h-auto shrink-0 justify-center rounded-full p-2 text-center", i, s3.tabContainer, r && s3.tabActive)
76297
+ className: EB("box-border h-auto shrink-0 justify-center rounded-full p-2 text-center", i, c3.tabContainer, r && c3.tabActive)
76281
76298
  }, e.id);
76282
76299
  })
76283
76300
  });
76284
76301
  });
76285
- var c3 = { icon: "_icon_1b1ye_1" }, l3 = b(({ value: e, onChange: i, labels: a, styles: o }) => {
76286
- let { colors: s, iconClassName: c = c3.icon, wrapperClassName: l, rowClassName: u } = o ?? {}, d = D(() => t({ "--si-icon": s?.icon }), [s]);
76302
+ var l3 = { icon: "_icon_1b1ye_1" }, u3 = b(({ value: e, onChange: i, labels: a, styles: o }) => {
76303
+ let { colors: s, iconClassName: c = l3.icon, wrapperClassName: l, rowClassName: u } = o ?? {}, d = D(() => t({ "--si-icon": s?.icon }), [s]);
76287
76304
  return /* @__PURE__ */ j("div", {
76288
76305
  className: n("px-3 py-2", l),
76289
76306
  style: d,
76290
- children: /* @__PURE__ */ j(o3, {
76307
+ children: /* @__PURE__ */ j(s3, {
76291
76308
  value: e,
76292
76309
  onChange: i,
76293
76310
  labels: {
@@ -76304,14 +76321,14 @@ var c3 = { icon: "_icon_1b1ye_1" }, l3 = b(({ value: e, onChange: i, labels: a,
76304
76321
  }
76305
76322
  })
76306
76323
  });
76307
- }), u3 = b(({ label: t, icon: n = c, iconSize: r = 48 }) => /* @__PURE__ */ j(e, {
76324
+ }), d3 = b(({ label: t, icon: n = c, iconSize: r = 48 }) => /* @__PURE__ */ j(e, {
76308
76325
  icon: /* @__PURE__ */ j(n, {
76309
76326
  "aria-hidden": !0,
76310
76327
  size: r,
76311
76328
  stroke: 1
76312
76329
  }),
76313
76330
  label: t
76314
- })), d3 = b(({ label: t, icon: n = u, iconSize: r = 45 }) => /* @__PURE__ */ j(e, {
76331
+ })), f3 = b(({ label: t, icon: n = u, iconSize: r = 45 }) => /* @__PURE__ */ j(e, {
76315
76332
  icon: /* @__PURE__ */ j(n, {
76316
76333
  "aria-hidden": !0,
76317
76334
  size: r,
@@ -76320,4 +76337,4 @@ var c3 = { icon: "_icon_1b1ye_1" }, l3 = b(({ value: e, onChange: i, labels: a,
76320
76337
  label: t
76321
76338
  }));
76322
76339
  //#endregion
76323
- export { u3 as PanelEmpty, d3 as PanelNoResults, l3 as SearchInput, re as SidebarOrientation, oe as SidebarPanel };
76340
+ export { d3 as PanelEmpty, f3 as PanelNoResults, u3 as SearchInput, re as SidebarOrientation, oe as SidebarPanel };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@epam/ai-dial-sidebar",
3
3
  "description": "Resizable sidebar panel shell with header, search, and empty state components",
4
- "version": "1.0.0-dev.512",
4
+ "version": "1.0.0-dev.514",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",
7
7
  "main": "./index.js",
@@ -17,8 +17,8 @@
17
17
  }
18
18
  },
19
19
  "peerDependencies": {
20
- "@epam/ai-dial-chat-shared": "1.0.0-dev.512",
21
- "@epam/ai-dial-kit": "1.0.0-dev.512",
20
+ "@epam/ai-dial-chat-shared": "1.0.0-dev.514",
21
+ "@epam/ai-dial-kit": "1.0.0-dev.514",
22
22
  "@epam/ai-dial-ui-kit": "0.12.0-dev.28",
23
23
  "@tabler/icons-react": "^3.44.0",
24
24
  "react": "^19.0.0"