@epam/ai-dial-ui-kit 0.15.0-dev.21 → 0.15.0-dev.22

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/CHANGELOG.md CHANGED
@@ -35,6 +35,8 @@ Versions match the git tags on the `development` branch.
35
35
 
36
36
  ### Fixed
37
37
 
38
+ - **`Accordion` (2.0) — the caret follows the reading direction, and the panel slides open and shut** — the collapsed caret pointed right under `dir="rtl"` too, against the reading direction; it now turns to point left in RTL and still points down once open. The content was also mounted only while expanded, so it appeared and vanished in one frame. It now stays mounted and animates its height (`grid-template-rows` 0fr ↔ 1fr, 200 ms, off under `prefers-reduced-motion`); while collapsed it is `inert`, so nothing in it is focusable or announced, and `aria-controls` always points at the region. The 12px gap under the header moved inside the clipped part, so a collapsed panel is exactly as tall as before. A caller that relied on the content unmounting while collapsed (to defer an expensive render, or to reset child state on close) now needs to render it conditionally itself. Requested in [ai-dial-chat](https://github.com/epam/ai-dial-chat) while moving its conversation stages onto `Accordion`.
39
+
38
40
  - **`Select` and `Dropdown` (2.0) — rows are 2px apart, and every option list and submenu has the same vertical inset** — rows were stacked edge to edge, so a selected row's tint and a hovered neighbour's merged into one block; every option list, menu and kit-rendered submenu now stacks its rows with `gap-0.5` (the shared `overlayListClassName`). Separately, the `Dropdown` menu wraps its rows in `py-1` inside the panel's `p-1`, but the `Select` option list and the submenus of both components rendered their rows straight into the panel, so the first and last rows (and the focus ring of a keyboard-focused one) sat flush against its top and bottom edge. The `Select` option list now carries the same `py-1`, and a submenu panel of kit-rendered rows takes `py-2` — the same 8px in total. A `Dropdown` submenu drawn through `renderSubMenu` keeps the plain panel, as a `renderOverlay` body does at the top level.
39
41
 
40
42
  - **`MarkdownEditor` (2.0) — the live preview is part of the card now, instead of a sheet of GitHub's own CSS laid over it** — the 2.0 restyle covered the card and the toolbar and stopped at the split: everything right of it was still `@uiw/react-md-editor`'s default stylesheet. Three things came out of that. The pane divider was the library's `inset` box-shadow in a hardcoded `#d0d7de`, drawn on the preview and then painted over by the markdown body's opaque white — and since that body is only as tall as its content, the divider survived as a hairline starting halfway down the pane, under the last rendered block. The white itself was the second: a `#ffffff` patch over the card's `bg-layer-raised`, which a dark theme would have kept white. And Tailwind's preflight, which the kit ships, had stripped the list markers and the task-list checkbox out of the rendered markdown — a bulleted list came out as indented lines, a `- [ ]` as a 0×0 box. The divider is now a real border on `border-secondary`, the body and its table rows are transparent, code, quotes, tables and headings take kit tokens, and lists and task boxes render again. The preview also inherits the host's font and `text-primary` instead of the library's `-apple-system` stack and `#24292f`; the edit pane keeps its monospace face. Both panes gained a 16px gutter beside the divider, so text no longer butts against it.
@@ -1,81 +1,81 @@
1
- import { jsx as t, jsxs as s, Fragment as j } from "react/jsx-runtime";
1
+ import { jsx as e, jsxs as s, Fragment as j } from "react/jsx-runtime";
2
2
  import { IconChevronRight as T } from "@tabler/icons-react";
3
3
  import { useState as k, useId as D } from "react";
4
4
  import { DIAL_KIT_ICON_STROKE as K } from "../constants/icon.js";
5
5
  import { DIAL_ICON_SIZE as O } from "../../../constants/icon.js";
6
6
  import { resolveAccessibleName as R } from "../../../utils/accessible-name.js";
7
- import { mergeClasses as r } from "../../../utils/merge-classes.js";
7
+ import { mergeClasses as t } from "../../../utils/merge-classes.js";
8
8
  import { DIAL_KIT_CLASS as $ } from "../../../constants/public-class-names.js";
9
- import { AccordionCaretPosition as I } from "../../../types/accordion.js";
9
+ import { AccordionCaretPosition as y } from "../../../types/accordion.js";
10
10
  const J = ({
11
- title: v,
11
+ title: g,
12
12
  description: c,
13
- children: g,
13
+ children: I,
14
14
  expanded: l,
15
15
  defaultExpanded: N = !1,
16
16
  disabled: o,
17
17
  nonCollapsible: n,
18
- ariaLabel: b,
19
- onToggle: A,
20
- caretPosition: C = I.End,
21
- className: S,
18
+ ariaLabel: w,
19
+ onToggle: b,
20
+ caretPosition: A = y.End,
21
+ className: C,
22
22
  headerClassName: d,
23
- contentClassName: _
23
+ contentClassName: S
24
24
  }) => {
25
- const m = l !== void 0, [w, E] = k(N), e = n ? !0 : m ? l : w, f = D(), a = `accordion-header-${f}`, u = `accordion-content-${f}`, L = () => {
25
+ const m = l !== void 0, [_, E] = k(N), r = n ? !0 : m ? l : _, f = D(), i = `accordion-header-${f}`, u = `accordion-content-${f}`, L = () => {
26
26
  if (o) return;
27
- const y = !e;
28
- m || E(y), A?.(y);
29
- }, i = C === I.Start, x = n ? null : /* @__PURE__ */ t(
27
+ const v = !r;
28
+ m || E(v), b?.(v);
29
+ }, a = A === y.Start, p = n ? null : /* @__PURE__ */ e(
30
30
  T,
31
31
  {
32
32
  size: O.SM,
33
33
  stroke: K,
34
34
  "aria-hidden": "true",
35
- className: r(
35
+ className: t(
36
36
  "shrink-0 text-secondary transition-transform motion-reduce:transition-none",
37
- e && "rotate-90"
37
+ r ? "rotate-90" : "rtl:rotate-180"
38
38
  )
39
39
  }
40
- ), p = /* @__PURE__ */ s(j, { children: [
41
- i && x,
40
+ ), x = /* @__PURE__ */ s(j, { children: [
41
+ a && p,
42
42
  /* @__PURE__ */ s("span", { className: "flex min-w-0 flex-col", children: [
43
- /* @__PURE__ */ t("span", { className: "truncate dial-body-text text-primary", children: v }),
44
- c ? /* @__PURE__ */ t("span", { className: "truncate dial-tiny-text text-secondary", children: c }) : null
43
+ /* @__PURE__ */ e("span", { className: "truncate dial-body-text text-primary", children: g }),
44
+ c ? /* @__PURE__ */ e("span", { className: "truncate dial-tiny-text text-secondary", children: c }) : null
45
45
  ] }),
46
- !i && x
47
- ] }), h = i ? "justify-start gap-2" : "justify-between";
46
+ !a && p
47
+ ] }), h = a ? "justify-start gap-2" : "justify-between";
48
48
  return /* @__PURE__ */ s(
49
49
  "div",
50
50
  {
51
- className: r(
52
- "flex flex-col gap-3 py-3 overflow-hidden bg-transparent ",
53
- S,
51
+ className: t(
52
+ "flex flex-col py-3 overflow-hidden bg-transparent",
53
+ C,
54
54
  $.accordion
55
55
  ),
56
56
  children: [
57
- n ? /* @__PURE__ */ t(
57
+ n ? /* @__PURE__ */ e(
58
58
  "div",
59
59
  {
60
- id: a,
61
- className: r(
60
+ id: i,
61
+ className: t(
62
62
  "flex w-full px-4 rounded-xl items-center dial-tiny-text",
63
63
  h,
64
64
  d
65
65
  ),
66
- children: p
66
+ children: x
67
67
  }
68
- ) : /* @__PURE__ */ t(
68
+ ) : /* @__PURE__ */ e(
69
69
  "button",
70
70
  {
71
- id: a,
71
+ id: i,
72
72
  type: "button",
73
- "aria-expanded": e,
74
- "aria-controls": e ? u : void 0,
75
- "aria-label": R(b),
73
+ "aria-expanded": r,
74
+ "aria-controls": u,
75
+ "aria-label": R(w),
76
76
  disabled: o,
77
77
  onClick: L,
78
- className: r(
78
+ className: t(
79
79
  "flex w-full px-4 rounded-xl items-center dial-tiny-text",
80
80
  h,
81
81
  o ? "cursor-not-allowed opacity-75" : (
@@ -84,20 +84,30 @@ const J = ({
84
84
  ),
85
85
  d
86
86
  ),
87
- children: p
87
+ children: x
88
88
  }
89
89
  ),
90
- e && /* @__PURE__ */ t(
90
+ /* @__PURE__ */ e(
91
91
  "div",
92
92
  {
93
- id: u,
94
- role: "region",
95
- "aria-labelledby": a,
96
- className: r(
97
- "px-4 dial-small-text text-primary",
98
- _
93
+ inert: !r,
94
+ className: t(
95
+ "grid transition-[grid-template-rows] duration-200 ease-out motion-reduce:transition-none",
96
+ r ? "grid-rows-[1fr]" : "grid-rows-[0fr]"
99
97
  ),
100
- children: g
98
+ children: /* @__PURE__ */ e("div", { className: "min-h-0 overflow-hidden", children: /* @__PURE__ */ e("div", { className: "pt-3", children: /* @__PURE__ */ e(
99
+ "div",
100
+ {
101
+ id: u,
102
+ role: "region",
103
+ "aria-labelledby": i,
104
+ className: t(
105
+ "px-4 dial-small-text text-primary",
106
+ S
107
+ ),
108
+ children: I
109
+ }
110
+ ) }) })
101
111
  }
102
112
  )
103
113
  ]
@@ -1,6 +1,6 @@
1
1
  {
2
- "version": "0.15.0-dev.21",
3
- "generatedAt": "2026-09-27T13:45:56.317Z",
2
+ "version": "0.15.0-dev.22",
3
+ "generatedAt": "2026-09-28T06:50:57.410Z",
4
4
  "kit": {
5
5
  "name": "@epam/ai-dial-ui-kit",
6
6
  "description": "A modern UI kit for building AI DIAL interfaces with React",
@@ -2276,7 +2276,7 @@
2276
2276
  "name": "Accordion",
2277
2277
  "category": "Components_2_0",
2278
2278
  "generation": "2.0",
2279
- "description": "A collapsible panel that toggles its content when the header is clicked.\naliases: Collapse|Disclosure|ExpandablePanel\nDesign system 2.0\n\nWorks as a controlled component when `expanded` is provided, otherwise it manages\nits own state from `defaultExpanded`. The header shows a caret that rotates when\nexpanded, a title, and an optional description stacked beneath it.\n\nThe revealed content is a labelled `region`, so assistive tech announces it by the\nheader it belongs to. `nonCollapsible` renders the header as static text instead of\na permanently disabled button, which keeps a decorative panel out of the tab order.",
2279
+ "description": "A collapsible panel that toggles its content when the header is clicked.\naliases: Collapse|Disclosure|ExpandablePanel\nDesign system 2.0\n\nWorks as a controlled component when `expanded` is provided, otherwise it manages\nits own state from `defaultExpanded`. The header shows a caret that rotates when\nexpanded, a title, and an optional description stacked beneath it.\n\nThe revealed content is a labelled `region`, so assistive tech announces it by the\nheader it belongs to. It stays mounted while collapsed so it can slide open and shut,\nand is `inert` then, out of both the tab order and the accessibility tree. `nonCollapsible` renders the header as static text instead of\na permanently disabled button, which keeps a decorative panel out of the tab order.",
2280
2280
  "props": [
2281
2281
  {
2282
2282
  "name": "title",