@botonic/nx-plugin 2.27.0 → 2.28.0

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/CHANGELOG.md CHANGED
@@ -1,3 +1,15 @@
1
+ ## 2.28.0 (2026-05-06)
2
+
3
+ ### 🚀 Features
4
+
5
+ - **webchat:** message grouping, responsive layout, and token refinements (BLT-2359) ([#880](https://github.com/metis-ai/hubtype-product/pull/880))
6
+ - **lilara:** semantic token layer — primary/secondary scales, text/surface/radius tokens, component CSS migration ([#879](https://github.com/metis-ai/hubtype-product/pull/879))
7
+ - **foundations:** semantic token layer — PR 1 foundations (BLT-2358) ([#874](https://github.com/metis-ai/hubtype-product/pull/874))
8
+
9
+ ### ❤️ Thank You
10
+
11
+ - David Hidalgo @Davidhidalgo
12
+
1
13
  ## 2.27.0 (2026-04-29)
2
14
 
3
15
  ### 🚀 Features
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@botonic/nx-plugin",
3
- "version": "2.27.0",
3
+ "version": "2.28.0",
4
4
  "description": "Nx plugin for creating Botonic bot applications",
5
5
  "main": "./src/index.js",
6
6
  "types": "./src/index.d.ts",
@@ -1,4 +1,4 @@
1
- import { BotonicContext, BotServerMessageFactory } from '@botonic/shared'
1
+ import { BotonicContext, BotServerMessageFactory } from '@botonic/core'
2
2
 
3
3
  export async function <%= className %>({ sendMessages }: BotonicContext) {
4
4
  // TODO: Implement your action logic here
@@ -5,7 +5,7 @@
5
5
  <title><%= className %> Webchat</title>
6
6
  <base href="/" />
7
7
 
8
- <meta name="viewport" content="width=device-width, initial-scale=1" />
8
+ <meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover" />
9
9
  <link rel="icon" type="image/x-icon" href="/favicon.ico" />
10
10
  </head>
11
11
  <body>
@@ -1,3 +1,4 @@
1
+ @import '@lilara/foundations/base.css';
1
2
  /* Import app-specific token overrides */
2
3
  @import './webchat-tokens-overrides.css';
3
4
 
@@ -1,2 +1,46 @@
1
1
  @layer overrides {
2
+ :root {
3
+ /* ── Primary scale ─────────────────────────────────────────────────────────
4
+ * Override to apply your primary brand colour. All components that reference
5
+ * --primary-* will update automatically.
6
+ *
7
+ * --primary-25: ;
8
+ * --primary-50: ;
9
+ * --primary-100: ;
10
+ * --primary-200: ;
11
+ * --primary-300: ;
12
+ * --primary-400: ;
13
+ * --primary-500: ;
14
+ * --primary-600: ;
15
+ * --primary-700: ;
16
+ * --primary-800: ;
17
+ * --primary-900: ;
18
+ */
19
+
20
+ /* ── Secondary scale ───────────────────────────────────────────────────────
21
+ * Override to apply your secondary / accent colour.
22
+ * Note: --secondary-600 also drives --color-focus (keyboard focus rings).
23
+ *
24
+ * --secondary-25: ;
25
+ * --secondary-50: ;
26
+ * --secondary-100: ;
27
+ * --secondary-200: ;
28
+ * --secondary-300: ;
29
+ * --secondary-400: ;
30
+ * --secondary-500: ;
31
+ * --secondary-600: ;
32
+ * --secondary-700: ;
33
+ * --secondary-800: ;
34
+ * --secondary-900: ;
35
+ */
36
+
37
+ /* ── Webchat-specific overrides ────────────────────────────────────────────
38
+ * Use --webchat-* tokens to customise individual webchat components.
39
+ * See webchat-tokens.css for the full list of available tokens.
40
+ *
41
+ * --webchat-header-bg: var(--primary-600);
42
+ * --webchat-message-bubble-bot-bg: var(--primary-50);
43
+ * --webchat-trigger-bg: var(--primary-500);
44
+ */
45
+ }
2
46
  }
@@ -1,4 +1,4 @@
1
- import { BotonicContext, BotServerMessageFactory } from '@botonic/shared'
1
+ import { BotonicContext, BotServerMessageFactory } from '@botonic/core'
2
2
 
3
3
  export async function NotFound({ sendMessages }: BotonicContext) {
4
4
  await sendMessages([
@@ -1,4 +1,4 @@
1
- import { BotonicContext, BotServerMessageFactory } from '@botonic/shared'
1
+ import { BotonicContext, BotServerMessageFactory } from '@botonic/core'
2
2
 
3
3
  export async function Welcome({ sendMessages }: BotonicContext) {
4
4
  await sendMessages([
@@ -1,6 +1,9 @@
1
1
  // eslint-disable-next-line @nx/enforce-module-boundaries
2
- import { CoreBot } from '@botonic/core'
3
- import { BotonicContext, BotServerMessageFactory } from '@botonic/shared'
2
+ import {
3
+ BotonicContext,
4
+ BotServerMessageFactory,
5
+ CoreBot,
6
+ } from '@botonic/core'
4
7
 
5
8
  import { plugins } from './plugins'
6
9
  import { routes } from './routes'
@@ -1,5 +1,5 @@
1
1
  import { AiAgentArgs, BotonicPluginAiAgents } from '@botonic/plugin-ai-agents'
2
- import { BotonicContext } from '@botonic/shared'
2
+ import { BotonicContext } from '@botonic/core'
3
3
 
4
4
  import { customTools } from '../../tools'
5
5
  import { BotPlugins } from '../../types'
@@ -4,7 +4,7 @@ import {
4
4
  BotonicPluginFlowBuilderOptions,
5
5
  FlowBuilderJSONVersion,
6
6
  } from '@botonic/plugin-flow-builder'
7
- import { BotonicContext } from '@botonic/shared'
7
+ import { BotonicContext } from '@botonic/core'
8
8
 
9
9
  import { trackEventToHubtypeAnalytics } from '../../tracking'
10
10
  import { isLambdaLocal } from '../../utils'
@@ -1,5 +1,5 @@
1
1
  import { FlowBuilderAction } from '@botonic/plugin-flow-builder'
2
- import { BotonicContext } from '@botonic/shared'
2
+ import { BotonicContext } from '@botonic/core'
3
3
 
4
4
  import { Welcome, NotFound } from './actions'
5
5
 
@@ -3,7 +3,7 @@ import {
3
3
  EventAction,
4
4
  HtEventProps,
5
5
  } from '@botonic/plugin-hubtype-analytics'
6
- import { BotonicContext } from '@botonic/shared'
6
+ import { BotonicContext } from '@botonic/core'
7
7
 
8
8
  import { BotPlugins } from './types'
9
9
 
@@ -1,3 +1,3 @@
1
1
  {
2
- "version": "0.6.0"
2
+ "version": "0.7.0"
3
3
  }
@@ -78,10 +78,10 @@ If not already clear from context, ask: "What should this action do?"
78
78
  Every action receives `BotonicContext` as its argument. The two key pieces for sending responses are:
79
79
 
80
80
  - **`sendMessages`** — async function from `BotonicContext`. Pass an array of messages to send them in a single call.
81
- - **`BotServerMessageFactory`** — imported from `@botonic/shared`. Use its factory methods to build every message; never construct raw message objects by hand.
81
+ - **`BotServerMessageFactory`** — imported from `@botonic/core`. Use its factory methods to build every message; never construct raw message objects by hand.
82
82
 
83
83
  ```typescript
84
- import { BotonicContext, BotServerMessageFactory } from '@botonic/shared'
84
+ import { BotonicContext, BotServerMessageFactory } from '@botonic/core'
85
85
 
86
86
  export async function MyAction({ sendMessages }: BotonicContext) {
87
87
  await sendMessages([BotServerMessageFactory.createText({ text: 'Hello!' })])
@@ -105,6 +105,9 @@ export const ProductCard: React.FC<ProductCardProps> = (props: any) => {
105
105
  In the output action, build the button server-side and pass it as a prop:
106
106
 
107
107
  ```typescript
108
+ import type { BotonicContext } from '@botonic/core'
109
+ import { BotServerMessageFactory } from '@botonic/core'
110
+
108
111
  export async function productCardOutput({ sendMessages, session }: BotonicContext) {
109
112
  const button = BotServerMessageFactory.createWebviewButton({ title: 'View details', webview: WEBVIEWS.PRODUCT }, session)
110
113
  await sendMessages([