@epam/ai-dial-starter-buttons 1.0.0-dev.456 → 1.0.0-dev.459
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/index.d.ts +1 -1
- package/index.d.ts.map +1 -1
- package/index.js +1 -1
- package/models/starter-props.d.ts +10 -2
- package/models/starter-props.d.ts.map +1 -1
- package/package.json +2 -2
package/index.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export { StarterButtons } from './components/StarterButtons/StarterButtons';
|
|
2
|
-
export type { StarterButtonsProps,
|
|
2
|
+
export type { StarterButtonsProps, StarterButtonsLabels, } from './models/starter-props';
|
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
package/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,4CAA4C,CAAC;AAC5E,YAAY,EACV,mBAAmB,EACnB,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,4CAA4C,CAAC;AAC5E,YAAY,EACV,mBAAmB,EACnB,oBAAoB,GACrB,MAAM,wBAAwB,CAAC"}
|
package/index.js
CHANGED
|
@@ -3,7 +3,7 @@ import { IconDots as r, IconDotsVertical as i } from "@tabler/icons-react";
|
|
|
3
3
|
import { useCallback as a, useEffect as o, useRef as s, useState as c } from "react";
|
|
4
4
|
import { jsx as l, jsxs as u } from "react/jsx-runtime";
|
|
5
5
|
//#region src/components/StarterButtons/StarterButtons.tsx
|
|
6
|
-
var d = 4, f = 8, p = ({ starters: p, onSelect: m, isMobile: h,
|
|
6
|
+
var d = 4, f = 8, p = ({ starters: p, onSelect: m, isMobile: h, labels: g }) => {
|
|
7
7
|
let _ = s(null), v = s([]), y = s([]), [b, x] = c(() => Math.min(p.length, d)), S = a((e) => {
|
|
8
8
|
let t = _.current;
|
|
9
9
|
if (!t) return;
|
|
@@ -1,12 +1,20 @@
|
|
|
1
1
|
import { StarterOption } from '@epam/ai-dial-chat-shared';
|
|
2
|
-
|
|
2
|
+
/** Localized text strings used by the StarterButtons component. */
|
|
3
|
+
export interface StarterButtonsLabels {
|
|
4
|
+
/** Label for the visible list of starter buttons. */
|
|
3
5
|
list: string;
|
|
6
|
+
/** Label for the overflow menu that holds buttons that do not fit. */
|
|
4
7
|
overflow: string;
|
|
5
8
|
}
|
|
9
|
+
/** Props for the StarterButtons component. */
|
|
6
10
|
export interface StarterButtonsProps {
|
|
11
|
+
/** Starter prompt options to display as buttons. */
|
|
7
12
|
starters: StarterOption[];
|
|
13
|
+
/** Called when the user selects a starter option. */
|
|
8
14
|
onSelect: (starter: StarterOption) => void;
|
|
15
|
+
/** When `true`, renders a mobile-optimised layout. */
|
|
9
16
|
isMobile?: boolean;
|
|
10
|
-
|
|
17
|
+
/** Localized labels used within the component. */
|
|
18
|
+
labels: StarterButtonsLabels;
|
|
11
19
|
}
|
|
12
20
|
//# sourceMappingURL=starter-props.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"starter-props.d.ts","sourceRoot":"","sources":["../../src/models/starter-props.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAE/D,MAAM,WAAW,
|
|
1
|
+
{"version":3,"file":"starter-props.d.ts","sourceRoot":"","sources":["../../src/models/starter-props.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAE/D,mEAAmE;AACnE,MAAM,WAAW,oBAAoB;IACnC,qDAAqD;IACrD,IAAI,EAAE,MAAM,CAAC;IACb,sEAAsE;IACtE,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,8CAA8C;AAC9C,MAAM,WAAW,mBAAmB;IAClC,oDAAoD;IACpD,QAAQ,EAAE,aAAa,EAAE,CAAC;IAC1B,qDAAqD;IACrD,QAAQ,EAAE,CAAC,OAAO,EAAE,aAAa,KAAK,IAAI,CAAC;IAC3C,sDAAsD;IACtD,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,kDAAkD;IAClD,MAAM,EAAE,oBAAoB,CAAC;CAC9B"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@epam/ai-dial-starter-buttons",
|
|
3
3
|
"description": "Responsive starter prompt buttons that overflow into a dropdown when space is limited",
|
|
4
|
-
"version": "1.0.0-dev.
|
|
4
|
+
"version": "1.0.0-dev.459",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "./index.js",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
}
|
|
17
17
|
},
|
|
18
18
|
"peerDependencies": {
|
|
19
|
-
"@epam/ai-dial-chat-shared": "1.0.0-dev.
|
|
19
|
+
"@epam/ai-dial-chat-shared": "1.0.0-dev.459",
|
|
20
20
|
"@epam/ai-dial-ui-kit": "0.12.0-dev.25",
|
|
21
21
|
"@tabler/icons-react": "^3.44.0",
|
|
22
22
|
"react": "^19.0.0"
|