@salla.sa/ui-ai-kit-core 1.0.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.
Files changed (147) hide show
  1. package/LICENSE +21 -0
  2. package/dist/cjs/ai-card.cjs.entry.js +25 -0
  3. package/dist/cjs/ai-chat-container.cjs.entry.js +138 -0
  4. package/dist/cjs/ai-chat-header.cjs.entry.js +79 -0
  5. package/dist/cjs/ai-chat-message.cjs.entry.js +164 -0
  6. package/dist/cjs/ai-icon.cjs.entry.js +25 -0
  7. package/dist/cjs/ai-link.cjs.entry.js +34 -0
  8. package/dist/cjs/ai-loading.cjs.entry.js +77 -0
  9. package/dist/cjs/ai-message-input.cjs.entry.js +65 -0
  10. package/dist/cjs/ai-rating.cjs.entry.js +57 -0
  11. package/dist/cjs/ai-suggestion.cjs.entry.js +31 -0
  12. package/dist/cjs/ai-voice-input.cjs.entry.js +233 -0
  13. package/dist/cjs/icon-registry-dmfLA-Dj.js +82 -0
  14. package/dist/cjs/index-DLJcLHFH.js +1622 -0
  15. package/dist/cjs/index.cjs.js +7 -0
  16. package/dist/cjs/loader.cjs.js +12 -0
  17. package/dist/cjs/ui-ai-kit.cjs.js +24 -0
  18. package/dist/collection/collection-manifest.json +23 -0
  19. package/dist/collection/components/ai-card/ai-card.css +40 -0
  20. package/dist/collection/components/ai-card/ai-card.js +70 -0
  21. package/dist/collection/components/ai-card/ai-card.stories.js +52 -0
  22. package/dist/collection/components/ai-chat-container/ai-chat-container.css +137 -0
  23. package/dist/collection/components/ai-chat-container/ai-chat-container.js +270 -0
  24. package/dist/collection/components/ai-chat-container/ai-chat-container.stories.js +160 -0
  25. package/dist/collection/components/ai-chat-header/ai-chat-header.css +186 -0
  26. package/dist/collection/components/ai-chat-header/ai-chat-header.js +311 -0
  27. package/dist/collection/components/ai-chat-header/ai-chat-header.stories.js +138 -0
  28. package/dist/collection/components/ai-chat-message/ai-chat-message.css +304 -0
  29. package/dist/collection/components/ai-chat-message/ai-chat-message.js +379 -0
  30. package/dist/collection/components/ai-chat-message/ai-chat-message.stories.js +164 -0
  31. package/dist/collection/components/ai-icon/ai-icon.css +9 -0
  32. package/dist/collection/components/ai-icon/ai-icon.js +76 -0
  33. package/dist/collection/components/ai-link/ai-link.css +62 -0
  34. package/dist/collection/components/ai-link/ai-link.js +119 -0
  35. package/dist/collection/components/ai-link/ai-link.stories.js +79 -0
  36. package/dist/collection/components/ai-loading/ai-loading.css +202 -0
  37. package/dist/collection/components/ai-loading/ai-loading.js +244 -0
  38. package/dist/collection/components/ai-loading/ai-loading.stories.js +145 -0
  39. package/dist/collection/components/ai-message-input/ai-message-input.css +175 -0
  40. package/dist/collection/components/ai-message-input/ai-message-input.js +192 -0
  41. package/dist/collection/components/ai-message-input/ai-message-input.stories.js +125 -0
  42. package/dist/collection/components/ai-rating/ai-rating.css +145 -0
  43. package/dist/collection/components/ai-rating/ai-rating.js +176 -0
  44. package/dist/collection/components/ai-rating/ai-rating.stories.js +78 -0
  45. package/dist/collection/components/ai-suggestion/ai-suggestion.css +69 -0
  46. package/dist/collection/components/ai-suggestion/ai-suggestion.js +93 -0
  47. package/dist/collection/components/ai-suggestion/ai-suggestion.stories.js +62 -0
  48. package/dist/collection/components/ai-voice-input/ai-voice-input.css +136 -0
  49. package/dist/collection/components/ai-voice-input/ai-voice-input.js +341 -0
  50. package/dist/collection/components/ai-voice-input/ai-voice-input.stories.js +118 -0
  51. package/dist/collection/index.js +10 -0
  52. package/dist/collection/utils/icon-registry.js +78 -0
  53. package/dist/collection/utils/utils.js +3 -0
  54. package/dist/components/ai-card.d.ts +11 -0
  55. package/dist/components/ai-card.js +1 -0
  56. package/dist/components/ai-chat-container.d.ts +11 -0
  57. package/dist/components/ai-chat-container.js +1 -0
  58. package/dist/components/ai-chat-header.d.ts +11 -0
  59. package/dist/components/ai-chat-header.js +1 -0
  60. package/dist/components/ai-chat-message.d.ts +11 -0
  61. package/dist/components/ai-chat-message.js +1 -0
  62. package/dist/components/ai-icon.d.ts +11 -0
  63. package/dist/components/ai-icon.js +1 -0
  64. package/dist/components/ai-link.d.ts +11 -0
  65. package/dist/components/ai-link.js +1 -0
  66. package/dist/components/ai-loading.d.ts +11 -0
  67. package/dist/components/ai-loading.js +1 -0
  68. package/dist/components/ai-message-input.d.ts +11 -0
  69. package/dist/components/ai-message-input.js +1 -0
  70. package/dist/components/ai-rating.d.ts +11 -0
  71. package/dist/components/ai-rating.js +1 -0
  72. package/dist/components/ai-suggestion.d.ts +11 -0
  73. package/dist/components/ai-suggestion.js +1 -0
  74. package/dist/components/ai-voice-input.d.ts +11 -0
  75. package/dist/components/ai-voice-input.js +1 -0
  76. package/dist/components/index.d.ts +35 -0
  77. package/dist/components/index.js +1 -0
  78. package/dist/components/p-CWjXxYJI.js +1 -0
  79. package/dist/components/p-CY6emva2.js +1 -0
  80. package/dist/components/p-DYv5ef4M.js +1 -0
  81. package/dist/esm/ai-card.entry.js +23 -0
  82. package/dist/esm/ai-chat-container.entry.js +136 -0
  83. package/dist/esm/ai-chat-header.entry.js +77 -0
  84. package/dist/esm/ai-chat-message.entry.js +162 -0
  85. package/dist/esm/ai-icon.entry.js +23 -0
  86. package/dist/esm/ai-link.entry.js +32 -0
  87. package/dist/esm/ai-loading.entry.js +75 -0
  88. package/dist/esm/ai-message-input.entry.js +63 -0
  89. package/dist/esm/ai-rating.entry.js +55 -0
  90. package/dist/esm/ai-suggestion.entry.js +29 -0
  91. package/dist/esm/ai-voice-input.entry.js +231 -0
  92. package/dist/esm/icon-registry-DYv5ef4M.js +80 -0
  93. package/dist/esm/index-7hrZ8FOQ.js +1612 -0
  94. package/dist/esm/index.js +5 -0
  95. package/dist/esm/loader.js +10 -0
  96. package/dist/esm/ui-ai-kit.js +20 -0
  97. package/dist/index.cjs.js +1 -0
  98. package/dist/index.js +1 -0
  99. package/dist/types/components/ai-card/ai-card.d.ts +7 -0
  100. package/dist/types/components/ai-card/ai-card.stories.d.ts +7 -0
  101. package/dist/types/components/ai-chat-container/ai-chat-container.d.ts +28 -0
  102. package/dist/types/components/ai-chat-container/ai-chat-container.stories.d.ts +7 -0
  103. package/dist/types/components/ai-chat-header/ai-chat-header.d.ts +38 -0
  104. package/dist/types/components/ai-chat-header/ai-chat-header.stories.d.ts +8 -0
  105. package/dist/types/components/ai-chat-message/ai-chat-message.d.ts +27 -0
  106. package/dist/types/components/ai-chat-message/ai-chat-message.stories.d.ts +10 -0
  107. package/dist/types/components/ai-icon/ai-icon.d.ts +8 -0
  108. package/dist/types/components/ai-link/ai-link.d.ts +12 -0
  109. package/dist/types/components/ai-link/ai-link.stories.d.ts +8 -0
  110. package/dist/types/components/ai-loading/ai-loading.d.ts +33 -0
  111. package/dist/types/components/ai-loading/ai-loading.stories.d.ts +10 -0
  112. package/dist/types/components/ai-message-input/ai-message-input.d.ts +22 -0
  113. package/dist/types/components/ai-message-input/ai-message-input.stories.d.ts +13 -0
  114. package/dist/types/components/ai-rating/ai-rating.d.ts +17 -0
  115. package/dist/types/components/ai-rating/ai-rating.stories.d.ts +8 -0
  116. package/dist/types/components/ai-suggestion/ai-suggestion.d.ts +10 -0
  117. package/dist/types/components/ai-suggestion/ai-suggestion.stories.d.ts +8 -0
  118. package/dist/types/components/ai-voice-input/ai-voice-input.d.ts +43 -0
  119. package/dist/types/components/ai-voice-input/ai-voice-input.stories.d.ts +9 -0
  120. package/dist/types/components.d.ts +860 -0
  121. package/dist/types/index.d.ts +11 -0
  122. package/dist/types/stencil-public-runtime.d.ts +1860 -0
  123. package/dist/types/utils/icon-registry.d.ts +5 -0
  124. package/dist/types/utils/utils.d.ts +1 -0
  125. package/dist/ui-ai-kit/index.esm.js +1 -0
  126. package/dist/ui-ai-kit/p-11facfad.entry.js +1 -0
  127. package/dist/ui-ai-kit/p-128a2ed4.entry.js +1 -0
  128. package/dist/ui-ai-kit/p-227bdb8f.entry.js +1 -0
  129. package/dist/ui-ai-kit/p-455daa17.entry.js +1 -0
  130. package/dist/ui-ai-kit/p-56163e8c.entry.js +1 -0
  131. package/dist/ui-ai-kit/p-6d21d0fd.entry.js +1 -0
  132. package/dist/ui-ai-kit/p-6ddcd77b.entry.js +1 -0
  133. package/dist/ui-ai-kit/p-7hrZ8FOQ.js +2 -0
  134. package/dist/ui-ai-kit/p-8e90143e.entry.js +1 -0
  135. package/dist/ui-ai-kit/p-9938c277.entry.js +1 -0
  136. package/dist/ui-ai-kit/p-DYv5ef4M.js +1 -0
  137. package/dist/ui-ai-kit/p-dc5b4a7f.entry.js +1 -0
  138. package/dist/ui-ai-kit/p-fb1702de.entry.js +1 -0
  139. package/dist/ui-ai-kit/ui-ai-kit.css +1 -0
  140. package/dist/ui-ai-kit/ui-ai-kit.esm.js +1 -0
  141. package/loader/cdn.js +1 -0
  142. package/loader/index.cjs.js +1 -0
  143. package/loader/index.d.ts +24 -0
  144. package/loader/index.es2017.js +1 -0
  145. package/loader/index.js +2 -0
  146. package/package.json +77 -0
  147. package/readme.md +111 -0
@@ -0,0 +1,78 @@
1
+ import { html } from "lit";
2
+ const meta = {
3
+ title: 'UI/Rating',
4
+ component: 'ai-rating',
5
+ tags: ['autodocs'],
6
+ argTypes: {
7
+ question: { control: 'text' },
8
+ subtitle: { control: 'text' },
9
+ value: {
10
+ control: { type: 'select' },
11
+ options: [null, 1, 2, 3, 4, 5],
12
+ },
13
+ disabled: { control: 'boolean' },
14
+ },
15
+ };
16
+ export default meta;
17
+ const wrapStyle = 'padding: 24px; background: #f3f4f6; direction: rtl; max-width: 420px;';
18
+ /* ─── Standalone ─────────────────────────────────────────────────────────── */
19
+ export const Standalone = {
20
+ render: args => html `
21
+ <div style="${wrapStyle}">
22
+ <ai-rating
23
+ question="${args.question}"
24
+ subtitle="${args.subtitle}"
25
+ value="${args.value}"
26
+ ?disabled="${args.disabled}"
27
+ ></ai-rating>
28
+ </div>
29
+ `,
30
+ args: {
31
+ question: 'كيف كانت تجربتك؟',
32
+ subtitle: 'رأيك يساعدنا نحسن الخدمة',
33
+ value: null,
34
+ disabled: false,
35
+ },
36
+ };
37
+ /* ─── Inside Card (matches Figma node 1532-65078) ───────────────────────── */
38
+ export const InsideCard = {
39
+ render: () => html `
40
+ <div style="${wrapStyle}">
41
+ <ai-card>
42
+ <ai-rating
43
+ question="كيف كانت تجربتك؟"
44
+ subtitle="رأيك يساعدنا نحسن الخدمة"
45
+ ></ai-rating>
46
+ </ai-card>
47
+ </div>
48
+ `,
49
+ };
50
+ /* ─── With Pre-selected Value ────────────────────────────────────────────── */
51
+ export const PreSelected = {
52
+ render: () => html `
53
+ <div style="${wrapStyle}">
54
+ <ai-card>
55
+ <ai-rating
56
+ question="كيف كانت تجربتك؟"
57
+ subtitle="رأيك يساعدنا نحسن الخدمة"
58
+ value="5"
59
+ ></ai-rating>
60
+ </ai-card>
61
+ </div>
62
+ `,
63
+ };
64
+ /* ─── Disabled ───────────────────────────────────────────────────────────── */
65
+ export const Disabled = {
66
+ render: () => html `
67
+ <div style="${wrapStyle}">
68
+ <ai-card>
69
+ <ai-rating
70
+ question="كيف كانت تجربتك؟"
71
+ subtitle="تم إرسال تقييمك"
72
+ value="4"
73
+ disabled
74
+ ></ai-rating>
75
+ </ai-card>
76
+ </div>
77
+ `,
78
+ };
@@ -0,0 +1,69 @@
1
+ /* ─── Custom Properties ──────────────────────────────────────────────────── */
2
+ :host {
3
+ --ai-suggestion-bg: var(--ai-bg-card);
4
+ --ai-suggestion-bg-hover: var(--ai-accent-bg);
5
+ --ai-suggestion-bg-active: var(--ai-accent-bg);
6
+ --ai-suggestion-border: 1px solid var(--ai-accent);
7
+ --ai-suggestion-border-hover: 1px solid var(--ai-accent);
8
+ --ai-suggestion-radius: 9999px;
9
+ --ai-suggestion-padding: 8px 12px;
10
+ --ai-suggestion-gap: 4px;
11
+ --ai-suggestion-color: var(--ai-accent-dark);
12
+ --ai-suggestion-font-size: 14px;
13
+ --ai-suggestion-line-height: 20px;
14
+
15
+ display: inline-block;
16
+ direction: rtl;
17
+ font-family: var(--ai-font-family, "PingARLT", sans-serif);
18
+ }
19
+
20
+ /* ─── Chip button ────────────────────────────────────────────────────────── */
21
+ .chip {
22
+ display: inline-flex;
23
+ align-items: center;
24
+ justify-content: center;
25
+ gap: var(--ai-suggestion-gap);
26
+ background: var(--ai-suggestion-bg);
27
+ border: var(--ai-suggestion-border);
28
+ border-radius: var(--ai-suggestion-radius);
29
+ padding: var(--ai-suggestion-padding);
30
+ color: var(--ai-suggestion-color);
31
+ font-size: var(--ai-suggestion-font-size);
32
+ font-weight: 400;
33
+ line-height: var(--ai-suggestion-line-height);
34
+ font-family: inherit;
35
+ white-space: nowrap;
36
+ cursor: pointer;
37
+ transition: background 0.15s ease, border-color 0.15s ease;
38
+ outline: none;
39
+ text-align: right;
40
+ }
41
+
42
+ .chip:hover:not(:disabled) {
43
+ background: var(--ai-suggestion-bg-hover);
44
+ border: var(--ai-suggestion-border-hover);
45
+ }
46
+
47
+ .chip:active:not(:disabled) {
48
+ background: var(--ai-suggestion-bg-active);
49
+ }
50
+
51
+ .chip:focus-visible {
52
+ outline: 2px solid var(--ai-accent);
53
+ outline-offset: 2px;
54
+ }
55
+
56
+ /* ─── Disabled ───────────────────────────────────────────────────────────── */
57
+ .chip--disabled,
58
+ .chip:disabled {
59
+ opacity: 0.45;
60
+ cursor: not-allowed;
61
+ pointer-events: none;
62
+ }
63
+
64
+ /* ─── Label ──────────────────────────────────────────────────────────────── */
65
+ .chip__label {
66
+ display: inline-flex;
67
+ align-items: center;
68
+ gap: var(--ai-suggestion-gap);
69
+ }
@@ -0,0 +1,93 @@
1
+ import { Host, h } from "@stencil/core";
2
+ export class AiSuggestion {
3
+ /** Suggestion text label */
4
+ label = '';
5
+ /** Disabled state */
6
+ disabled = false;
7
+ suggestionClick;
8
+ handleClick() {
9
+ if (this.disabled)
10
+ return;
11
+ this.suggestionClick.emit(this.label);
12
+ }
13
+ render() {
14
+ return (h(Host, { key: '642ab1b74098e6cd3cebab33a127757cddd2a450' }, h("button", { key: 'd75585d53f5996d06a96bdfad5dc11a85b101b23', class: {
15
+ chip: true,
16
+ 'chip--disabled': this.disabled,
17
+ }, disabled: this.disabled, onClick: () => this.handleClick() }, h("span", { key: '532a8cc6168accab91bc10f0b4383d4173b8c887', class: "chip__label" }, this.label, h("slot", { key: '691ae51253a08ff2005733a263153f8470e77472' })))));
18
+ }
19
+ static get is() { return "ai-suggestion"; }
20
+ static get encapsulation() { return "shadow"; }
21
+ static get originalStyleUrls() {
22
+ return {
23
+ "$": ["ai-suggestion.css"]
24
+ };
25
+ }
26
+ static get styleUrls() {
27
+ return {
28
+ "$": ["ai-suggestion.css"]
29
+ };
30
+ }
31
+ static get properties() {
32
+ return {
33
+ "label": {
34
+ "type": "string",
35
+ "mutable": false,
36
+ "complexType": {
37
+ "original": "string",
38
+ "resolved": "string",
39
+ "references": {}
40
+ },
41
+ "required": false,
42
+ "optional": false,
43
+ "docs": {
44
+ "tags": [],
45
+ "text": "Suggestion text label"
46
+ },
47
+ "getter": false,
48
+ "setter": false,
49
+ "reflect": false,
50
+ "attribute": "label",
51
+ "defaultValue": "''"
52
+ },
53
+ "disabled": {
54
+ "type": "boolean",
55
+ "mutable": false,
56
+ "complexType": {
57
+ "original": "boolean",
58
+ "resolved": "boolean",
59
+ "references": {}
60
+ },
61
+ "required": false,
62
+ "optional": false,
63
+ "docs": {
64
+ "tags": [],
65
+ "text": "Disabled state"
66
+ },
67
+ "getter": false,
68
+ "setter": false,
69
+ "reflect": false,
70
+ "attribute": "disabled",
71
+ "defaultValue": "false"
72
+ }
73
+ };
74
+ }
75
+ static get events() {
76
+ return [{
77
+ "method": "suggestionClick",
78
+ "name": "suggestionClick",
79
+ "bubbles": true,
80
+ "cancelable": true,
81
+ "composed": true,
82
+ "docs": {
83
+ "tags": [],
84
+ "text": ""
85
+ },
86
+ "complexType": {
87
+ "original": "string",
88
+ "resolved": "string",
89
+ "references": {}
90
+ }
91
+ }];
92
+ }
93
+ }
@@ -0,0 +1,62 @@
1
+ import { html } from "lit";
2
+ const meta = {
3
+ title: 'UI/Suggestion',
4
+ component: 'ai-suggestion',
5
+ tags: ['autodocs'],
6
+ argTypes: {
7
+ label: { control: 'text' },
8
+ disabled: { control: 'boolean' },
9
+ },
10
+ };
11
+ export default meta;
12
+ const wrapStyle = 'padding: 24px; background: #f3f4f6; direction: rtl; display: flex; gap: 8px; flex-wrap: wrap; align-items: flex-start;';
13
+ /* ─── Playground ─────────────────────────────────────────────────────────── */
14
+ export const Playground = {
15
+ render: args => html `
16
+ <div style="${wrapStyle}">
17
+ <ai-suggestion
18
+ label="${args.label}"
19
+ ?disabled="${args.disabled}"
20
+ ></ai-suggestion>
21
+ </div>
22
+ `,
23
+ args: {
24
+ label: 'وش الفرق بين باقة بلس وبرو',
25
+ disabled: false,
26
+ },
27
+ };
28
+ /* ─── Multiple suggestions (typical usage in chat) ──────────────────────── */
29
+ export const SuggestionGroup = {
30
+ render: () => html `
31
+ <div style="${wrapStyle}">
32
+ <ai-suggestion label="وش الفرق بين باقة بلس وبرو"></ai-suggestion>
33
+ <ai-suggestion label="كيف أضيف منتج جديد؟"></ai-suggestion>
34
+ <ai-suggestion label="أظهر لي العملاء اللي ما اشتروا هذا الشهر"></ai-suggestion>
35
+ <ai-suggestion label="ما هي أفضل وقت لإرسال حملة تسويقية؟"></ai-suggestion>
36
+ </div>
37
+ `,
38
+ };
39
+ /* ─── Disabled ───────────────────────────────────────────────────────────── */
40
+ export const Disabled = {
41
+ render: () => html `
42
+ <div style="${wrapStyle}">
43
+ <ai-suggestion label="وش الفرق بين باقة بلس وبرو" disabled></ai-suggestion>
44
+ <ai-suggestion label="كيف أضيف منتج جديد؟" disabled></ai-suggestion>
45
+ </div>
46
+ `,
47
+ };
48
+ /* ─── Inside chat (realistic usage) ─────────────────────────────────────── */
49
+ export const InChatContext = {
50
+ render: () => html `
51
+ <div style="padding: 24px; background: #f3f4f6; direction: rtl; max-width: 480px; display: flex; flex-direction: column; gap: 16px;">
52
+ <ai-card>
53
+ <p style="margin:0; font-size:14px; font-weight:500; color:#333;">أهلاً! كيف يمكنني مساعدتك اليوم؟</p>
54
+ </ai-card>
55
+ <div style="display: flex; gap: 8px; flex-wrap: wrap;">
56
+ <ai-suggestion label="وش الفرق بين باقة بلس وبرو"></ai-suggestion>
57
+ <ai-suggestion label="أظهر لي أفضل المنتجات مبيعاً"></ai-suggestion>
58
+ <ai-suggestion label="كيف أحسن معدل التحويل؟"></ai-suggestion>
59
+ </div>
60
+ </div>
61
+ `,
62
+ };
@@ -0,0 +1,136 @@
1
+ :host {
2
+ display: block;
3
+ width: 100%;
4
+ font-family: var(--ai-font-family, "PingARLT", sans-serif);
5
+
6
+ --ai-input-bg: var(--ai-bg-input, #ffffff);
7
+ --ai-input-border-color: var(--ai-border-default, #eeeeee);
8
+ --ai-send-button-bg: var(--ai-border-default, #eeeeee);
9
+ --ai-send-button-border: var(--ai-border-default, #eeeeee);
10
+ --ai-send-button-color: var(--ai-text-secondary, #737373);
11
+ --ai-send-button-active-color: var(--ai-text-primary, #333333);
12
+ --ai-voice-timer-color: var(--ai-text-secondary, #737373);
13
+ }
14
+
15
+ /* Mirrors ai-message-input wrapper */
16
+ .wrapper {
17
+ position: relative;
18
+ padding: var(--ai-input-wrapper-padding, 16px);
19
+ }
20
+
21
+ /* Same glow as message input */
22
+ .glow {
23
+ position: absolute;
24
+ bottom: 20px;
25
+ left: 39px;
26
+ right: 39px;
27
+ height: 29px;
28
+ border-radius: 9999px;
29
+ background: var(--ai-input-glow);
30
+ filter: blur(20px);
31
+ opacity: 0.9;
32
+ pointer-events: none;
33
+ }
34
+
35
+ /* Same pill container as message input */
36
+ .input-container {
37
+ position: relative;
38
+ background-color: var(--ai-input-bg, #ffffff);
39
+ border-radius: var(--ai-input-border-radius, 9999px);
40
+ border: 1px solid var(--ai-input-border-color, #eeeeee);
41
+ box-shadow: 0 1px 2px 0 var(--ai-input-shadow-color, rgba(18, 18, 23, 0.05));
42
+ padding: var(--ai-input-padding, 12px);
43
+ overflow: hidden;
44
+ }
45
+
46
+ /* Recording row — mirrors .input-row */
47
+ .recording-row {
48
+ display: flex;
49
+ align-items: center;
50
+ gap: var(--ai-input-gap, 10px);
51
+ }
52
+
53
+ /* Cancel button — same style as inactive send-button */
54
+ .cancel-button {
55
+ display: inline-flex;
56
+ align-items: center;
57
+ justify-content: center;
58
+ gap: 4px;
59
+ min-height: 32px;
60
+ max-height: 32px;
61
+ padding: 4px 8px;
62
+ border-radius: 32px;
63
+ border: 2px solid var(--ai-send-button-border, var(--ai-border-default));
64
+ background-color: var(--ai-send-button-bg, var(--ai-border-default));
65
+ color: var(--ai-send-button-color, var(--ai-text-secondary));
66
+ cursor: pointer;
67
+ flex-shrink: 0;
68
+ transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
69
+ }
70
+
71
+ .cancel-button:hover {
72
+ background-color: var(--ai-bg-surface);
73
+ border-color: var(--ai-bg-surface);
74
+ }
75
+
76
+ /* Submit button — same style as active send-button */
77
+ .submit-button {
78
+ display: inline-flex;
79
+ align-items: center;
80
+ justify-content: center;
81
+ height: 32px;
82
+ width: 32px;
83
+ min-width: 32px;
84
+ padding: 4px 8px;
85
+ border-radius: 32px;
86
+ border: 2px solid var(--ai-send-button-active-border, var(--ai-accent));
87
+ background-color: var(--ai-send-button-active-bg, var(--ai-accent));
88
+ color: var(--ai-accent-text);
89
+ cursor: pointer;
90
+ flex-shrink: 0;
91
+ transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
92
+ }
93
+
94
+ .submit-button:hover {
95
+ background-color: var(--ai-send-button-active-hover-bg, var(--ai-accent));
96
+ border-color: var(--ai-send-button-active-hover-border, var(--ai-accent));
97
+ }
98
+
99
+ /* Timer */
100
+ .timer {
101
+ font-size: 13px;
102
+ font-weight: 500;
103
+ font-family: var(--ai-font-family, "PingARLT", sans-serif);
104
+ color: var(--ai-voice-timer-color, #737373);
105
+ min-width: 36px;
106
+ text-align: center;
107
+ flex-shrink: 0;
108
+ }
109
+
110
+ .timer.warning {
111
+ color: var(--ai-voice-timer-warning-color, var(--ai-danger-text));
112
+ }
113
+
114
+ /* Waveform canvas */
115
+ .waveform {
116
+ flex: 1;
117
+ height: 32px;
118
+ max-width: 100%;
119
+ }
120
+
121
+ /* Error message */
122
+ .error-message {
123
+ position: absolute;
124
+ bottom: -40px;
125
+ left: 50%;
126
+ transform: translateX(-50%);
127
+ background: var(--ai-voice-error-bg, var(--ai-danger-bg));
128
+ color: var(--ai-voice-error-color, var(--ai-danger-text));
129
+ font-size: 11px;
130
+ padding: 6px 12px;
131
+ border-radius: 6px;
132
+ white-space: nowrap;
133
+ box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
134
+ border: 1px solid var(--ai-voice-error-border, var(--ai-danger-border));
135
+ z-index: 10;
136
+ }