@makolabs/ripple 1.2.3 → 1.2.4

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 (106) hide show
  1. package/README.md +77 -0
  2. package/dist/adapters/ai/OpenAIAdapter.js +16 -11
  3. package/dist/adapters/ai/types.d.ts +3 -3
  4. package/dist/adapters/storage/BaseAdapter.d.ts +1 -1
  5. package/dist/adapters/storage/BaseAdapter.js +1 -1
  6. package/dist/adapters/storage/S3Adapter.js +2 -2
  7. package/dist/ai/AIChatInterface.svelte +32 -34
  8. package/dist/ai/AIChatInterface.svelte.d.ts +0 -1
  9. package/dist/ai/AIChatInterfaceTestWrapper.svelte +26 -0
  10. package/dist/ai/AIChatInterfaceTestWrapper.svelte.d.ts +17 -0
  11. package/dist/ai/ChatInput.svelte +7 -15
  12. package/dist/ai/ChatInput.svelte.d.ts +0 -2
  13. package/dist/ai/CodeRenderer.svelte +25 -12
  14. package/dist/ai/ComposeDropdown.svelte +17 -14
  15. package/dist/ai/MermaidRenderer.svelte +21 -17
  16. package/dist/ai/MermaidRenderer.svelte.d.ts +0 -1
  17. package/dist/ai/MessageBox.svelte +10 -7
  18. package/dist/ai/ThinkingDisplay.svelte +67 -43
  19. package/dist/ai/ai-chat-interface.d.ts +22 -21
  20. package/dist/ai/ai-chat-interface.js +8 -7
  21. package/dist/ai/content-detector.js +2 -2
  22. package/dist/button/ButtonTestWrapper.svelte +10 -0
  23. package/dist/button/ButtonTestWrapper.svelte.d.ts +7 -0
  24. package/dist/charts/Chart.svelte +6 -1
  25. package/dist/config/ai.js +1 -0
  26. package/dist/drawer/DrawerTestWrapper.svelte +19 -0
  27. package/dist/drawer/DrawerTestWrapper.svelte.d.ts +9 -0
  28. package/dist/drawer/drawer.d.ts +19 -18
  29. package/dist/drawer/drawer.js +7 -6
  30. package/dist/elements/accordion/Accordion.svelte +1 -1
  31. package/dist/elements/accordion/Accordion.svelte.d.ts +1 -1
  32. package/dist/elements/accordion/AccordionTestWrapper.svelte +21 -0
  33. package/dist/elements/accordion/AccordionTestWrapper.svelte.d.ts +10 -0
  34. package/dist/elements/badge/Badge.svelte +5 -4
  35. package/dist/elements/badge/BadgeTestWrapper.svelte +14 -0
  36. package/dist/elements/badge/BadgeTestWrapper.svelte.d.ts +9 -0
  37. package/dist/elements/badge/badge.d.ts +40 -39
  38. package/dist/elements/badge/badge.js +14 -13
  39. package/dist/elements/dropdown/Dropdown.svelte +0 -1
  40. package/dist/elements/pagination/Pagination.svelte +20 -26
  41. package/dist/elements/progress/Progress.svelte +3 -3
  42. package/dist/elements/timeline/Timeline.svelte +1 -1
  43. package/dist/file-browser/FileBrowser.svelte +7 -10
  44. package/dist/filters/CompactFilters.svelte +3 -3
  45. package/dist/forms/Checkbox.svelte +0 -1
  46. package/dist/forms/CheckboxTestWrapper.svelte +8 -0
  47. package/dist/forms/CheckboxTestWrapper.svelte.d.ts +4 -0
  48. package/dist/forms/DateRange.svelte +186 -198
  49. package/dist/forms/Form.svelte +1 -0
  50. package/dist/forms/Input.svelte +14 -5
  51. package/dist/forms/InputTestWrapper.svelte +8 -0
  52. package/dist/forms/InputTestWrapper.svelte.d.ts +4 -0
  53. package/dist/forms/NumberInput.svelte +2 -2
  54. package/dist/forms/RadioInputs.svelte +1 -1
  55. package/dist/forms/RadioPill.svelte +1 -1
  56. package/dist/forms/Slider.svelte +2 -2
  57. package/dist/forms/Tags.svelte +3 -3
  58. package/dist/forms/ToggleTestWrapper.svelte +8 -0
  59. package/dist/forms/ToggleTestWrapper.svelte.d.ts +7 -0
  60. package/dist/forms/slider.js +1 -1
  61. package/dist/header/PageHeader.svelte +2 -1
  62. package/dist/header/breadcrumbs.d.ts +47 -33
  63. package/dist/header/breadcrumbs.js +12 -11
  64. package/dist/index.d.ts +3 -2
  65. package/dist/index.js +2 -0
  66. package/dist/layout/activity-list/ActivityList.svelte +9 -11
  67. package/dist/layout/card/CardTestWrapper.svelte +15 -0
  68. package/dist/layout/card/CardTestWrapper.svelte.d.ts +7 -0
  69. package/dist/layout/card/RankedCard.svelte +2 -3
  70. package/dist/layout/navbar/navbar.d.ts +19 -18
  71. package/dist/layout/navbar/navbar.js +7 -6
  72. package/dist/layout/sidebar/NavGroup.svelte +1 -0
  73. package/dist/layout/table/Cells.svelte +5 -5
  74. package/dist/layout/table/Table.svelte +8 -8
  75. package/dist/layout/table/table.d.ts +28 -24
  76. package/dist/layout/table/table.js +14 -13
  77. package/dist/modal/Modal.svelte +1 -1
  78. package/dist/modal/ModalTestWrapper.svelte +20 -0
  79. package/dist/modal/ModalTestWrapper.svelte.d.ts +8 -0
  80. package/dist/modal/modal.d.ts +1 -20
  81. package/dist/pipeline/Pipeline.svelte +29 -17
  82. package/dist/user-management/README.md +417 -0
  83. package/dist/user-management/UserManagement.svelte +184 -0
  84. package/dist/user-management/UserManagement.svelte.d.ts +4 -0
  85. package/dist/user-management/UserManagementTestWrapper.svelte +47 -0
  86. package/dist/user-management/UserManagementTestWrapper.svelte.d.ts +7 -0
  87. package/dist/user-management/UserModal.svelte +303 -0
  88. package/dist/user-management/UserModal.svelte.d.ts +4 -0
  89. package/dist/user-management/UserModalTestWrapper.svelte +22 -0
  90. package/dist/user-management/UserModalTestWrapper.svelte.d.ts +7 -0
  91. package/dist/user-management/UserTable.svelte +219 -0
  92. package/dist/user-management/UserTable.svelte.d.ts +4 -0
  93. package/dist/user-management/UserTableTestWrapper.svelte +41 -0
  94. package/dist/user-management/UserTableTestWrapper.svelte.d.ts +7 -0
  95. package/dist/user-management/UserViewModal.svelte +282 -0
  96. package/dist/user-management/UserViewModal.svelte.d.ts +4 -0
  97. package/dist/user-management/UserViewModalTestWrapper.svelte +22 -0
  98. package/dist/user-management/UserViewModalTestWrapper.svelte.d.ts +7 -0
  99. package/dist/user-management/index.d.ts +10 -0
  100. package/dist/user-management/index.js +11 -0
  101. package/dist/user-management/user-management.d.ts +99 -0
  102. package/dist/user-management/user-management.js +42 -0
  103. package/package.json +3 -1
  104. package/dist/types/markdown.d.ts +0 -14
  105. package/dist/types/variants.d.ts +0 -1
  106. package/dist/types/variants.js +0 -1
@@ -2,7 +2,6 @@
2
2
  import { tv } from 'tailwind-variants';
3
3
  import Toggle from '../forms/Toggle.svelte';
4
4
  import { Size } from '../variants.js';
5
- import type { VariantColors } from '../index.js';
6
5
 
7
6
  interface ComposeDropdownProps {
8
7
  disabled?: boolean;
@@ -33,7 +32,8 @@
33
32
  variants: {
34
33
  state: {
35
34
  disabled: 'bg-gray-100 text-gray-300 cursor-not-allowed',
36
- enabled: 'bg-gray-200 text-gray-600 hover:bg-gray-300 hover:text-gray-800 focus:ring-2 focus:ring-gray-300/50'
35
+ enabled:
36
+ 'bg-gray-200 text-gray-600 hover:bg-gray-300 hover:text-gray-800 focus:ring-2 focus:ring-gray-300/50'
37
37
  }
38
38
  }
39
39
  });
@@ -119,20 +119,23 @@
119
119
  width="0.7em"
120
120
  height="0.7em"
121
121
  viewBox="0 0 20 20"
122
- class="w-5 h-5"
122
+ class="h-5 w-5"
123
123
  >
124
- <path fill="currentColor" d="M10 2.25a.75.75 0 0 1 .75.75v6.25H17a.75.75 0 0 1 0 1.5h-6.25V17a.75.75 0 0 1-1.5 0v-6.25H3a.75.75 0 0 1 0-1.5h6.25V3a.75.75 0 0 1 .75-.75"/>
124
+ <path
125
+ fill="currentColor"
126
+ d="M10 2.25a.75.75 0 0 1 .75.75v6.25H17a.75.75 0 0 1 0 1.5h-6.25V17a.75.75 0 0 1-1.5 0v-6.25H3a.75.75 0 0 1 0-1.5h6.25V3a.75.75 0 0 1 .75-.75"
127
+ />
125
128
  </svg>
126
129
  </button>
127
130
 
128
131
  <!-- Dropdown Menu -->
129
132
  <div class={dropdownClasses}>
130
133
  <!-- Models Section -->
131
- <div class="px-4 py-2 border-b border-gray-100">
132
- <h3 class="text-xs font-medium text-gray-500 uppercase tracking-wide">Models</h3>
134
+ <div class="border-b border-gray-100 px-4 py-2">
135
+ <h3 class="text-xs font-medium tracking-wide text-gray-500 uppercase">Models</h3>
133
136
  </div>
134
-
135
- {#each models as model}
137
+
138
+ {#each models as model (model.name)}
136
139
  <div class={menuItem({ state: 'disabled', layout: 'default' })}>
137
140
  <div class="flex flex-col">
138
141
  <span class="font-medium">{model.name}</span>
@@ -143,20 +146,20 @@
143
146
  {/each}
144
147
 
145
148
  <!-- Divider -->
146
- <div class="border-t border-gray-100 my-2"></div>
149
+ <div class="my-2 border-t border-gray-100"></div>
147
150
 
148
151
  <!-- Thinking Mode Option -->
149
- <div class="px-4 py-2 border-b border-gray-100">
150
- <h3 class="text-xs font-medium text-gray-500 uppercase tracking-wide">Options</h3>
152
+ <div class="border-b border-gray-100 px-4 py-2">
153
+ <h3 class="text-xs font-medium tracking-wide text-gray-500 uppercase">Options</h3>
151
154
  </div>
152
-
155
+
153
156
  <div class={menuItem({ state: 'enabled', layout: 'full' }) + ' w-full cursor-pointer'}>
154
- <div class="flex items-center justify-between w-full">
157
+ <div class="flex w-full items-center justify-between">
155
158
  <div class="flex flex-col items-start">
156
159
  <span class="font-medium">Thinking Mode</span>
157
160
  <span class="text-xs text-gray-500">Show reasoning process</span>
158
161
  </div>
159
- <div class="flex items-center ml-4">
162
+ <div class="ml-4 flex items-center">
160
163
  <Toggle
161
164
  name="thinking-mode"
162
165
  bind:value={thinkingMode}
@@ -4,10 +4,9 @@
4
4
 
5
5
  interface Props {
6
6
  diagram: string;
7
- class?: string;
8
7
  }
9
8
 
10
- let { diagram, class: className = '' }: Props = $props();
9
+ let { diagram }: Props = $props();
11
10
 
12
11
  // Mermaid configuration with multiple node colors like your image
13
12
  const config: MermaidConfig = {
@@ -17,30 +16,30 @@
17
16
  background: '#ffffff',
18
17
  fontFamily: '-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',
19
18
  fontSize: '14px',
20
-
19
+
21
20
  // Default node styling
22
21
  primaryColor: '#E8F4FD',
23
22
  primaryTextColor: '#2C3E50',
24
23
  primaryBorderColor: '#B8D4F0',
25
-
24
+
26
25
  // Lines and connections
27
26
  lineColor: '#7F8C8D',
28
27
  textColor: '#2C3E50',
29
28
  defaultLinkColor: '#7F8C8D',
30
29
  edgeLabelBackground: '#ffffff',
31
-
30
+
32
31
  // Color scale for different node types (matching your image)
33
- cScale0: '#E8F4FD', // Light blue - Frontend code, Tauri build
34
- cScale1: '#E8F5E8', // Light green - Bundler, App binary
35
- cScale2: '#FFF2E8', // Light orange - Dist assets
36
- cScale3: '#F0E8FF', // Light purple - Rust code
37
- cScale4: '#FFFDE8', // Light yellow - Installer
38
- cScale5: '#F8F8F8', // Light gray - fallback
39
- cScale6: '#E0E0E0', // Medium gray - borders
40
- cScale7: '#2C3E50', // Dark text
41
- cScale8: '#7F8C8D', // Line color
42
- cScale9: '#FFFFFF', // White background
43
-
32
+ cScale0: '#E8F4FD', // Light blue - Frontend code, Tauri build
33
+ cScale1: '#E8F5E8', // Light green - Bundler, App binary
34
+ cScale2: '#FFF2E8', // Light orange - Dist assets
35
+ cScale3: '#F0E8FF', // Light purple - Rust code
36
+ cScale4: '#FFFDE8', // Light yellow - Installer
37
+ cScale5: '#F8F8F8', // Light gray - fallback
38
+ cScale6: '#E0E0E0', // Medium gray - borders
39
+ cScale7: '#2C3E50', // Dark text
40
+ cScale8: '#7F8C8D', // Line color
41
+ cScale9: '#FFFFFF', // White background
42
+
44
43
  // Node styling
45
44
  nodeBorder: '#B8D4F0',
46
45
  nodeTextColor: '#2C3E50'
@@ -70,7 +69,12 @@
70
69
  <div class="rounded-lg border border-red-200 bg-red-50 p-4">
71
70
  <div class="flex items-center gap-2 text-red-800">
72
71
  <svg class="h-5 w-5" fill="none" stroke="currentColor" viewBox="0 0 24 24">
73
- <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 8v4m0 4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />
72
+ <path
73
+ stroke-linecap="round"
74
+ stroke-linejoin="round"
75
+ stroke-width="2"
76
+ d="M12 8v4m0 4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"
77
+ />
74
78
  </svg>
75
79
  <span class="font-medium">Failed to render Mermaid diagram</span>
76
80
  </div>
@@ -1,6 +1,5 @@
1
1
  interface Props {
2
2
  diagram: string;
3
- class?: string;
4
3
  }
5
4
  declare const MermaidRenderer: import("svelte").Component<Props, {}, "">;
6
5
  type MermaidRenderer = ReturnType<typeof MermaidRenderer>;
@@ -132,26 +132,29 @@
132
132
  {content}
133
133
  {:else}
134
134
  <!-- Enhanced rendering for AI messages with Mermaid and code highlighting -->
135
- {#each contentSegments as segment}
135
+ {#each contentSegments as segment, idx (idx)}
136
136
  {#if segment.type === 'mermaid'}
137
137
  <MermaidRenderer diagram={segment.content} />
138
138
  {:else if segment.type === 'code'}
139
- <CodeRenderer
140
- code={segment.content}
141
- language={segment.language ?? 'text'}
142
- />
139
+ <CodeRenderer code={segment.content} language={segment.language ?? 'text'} />
143
140
  {:else if segment.type === 'text'}
144
141
  <!-- Regular markdown content -->
142
+ <!-- eslint-disable-next-line svelte/no-at-html-tags -->
145
143
  {@html renderMarkdown(segment.content)}
146
144
  {/if}
147
145
  {/each}
148
146
  {/if}
149
147
  </div>
150
148
 
151
- <div class="flex flex-row items-center gap-2 justify-between">
149
+ <div class="flex flex-row items-center justify-between gap-2">
152
150
  <!-- Timestamp below message bubble -->
153
151
  {#if timestamp}
154
- <div class={cn('mt-1 text-xs text-gray-500', isUser ? 'text-right ml-auto' : 'text-left mr-auto')}>
152
+ <div
153
+ class={cn(
154
+ 'mt-1 text-xs text-gray-500',
155
+ isUser ? 'ml-auto text-right' : 'mr-auto text-left'
156
+ )}
157
+ >
155
158
  {formatTime(timestamp)}
156
159
  </div>
157
160
  {/if}
@@ -1,6 +1,5 @@
1
1
  <script lang="ts">
2
2
  import { tv } from 'tailwind-variants';
3
- import { onMount } from 'svelte';
4
3
 
5
4
  interface ThinkingDisplayProps {
6
5
  content: string;
@@ -18,15 +17,15 @@
18
17
 
19
18
  let isExpanded = $state(false);
20
19
  let containerRef: HTMLDivElement | undefined = $state();
21
-
20
+
22
21
  // Parse thinking content into structured steps
23
22
  const parsedSteps = $derived.by(() => {
24
23
  if (!content) return [];
25
-
24
+
26
25
  // Split content by markdown headers or double asterisks
27
26
  const sections = content.split(/\*\*([^*]+)\*\*/g);
28
27
  const steps = [];
29
-
28
+
30
29
  // When split by regex with capture groups, we get: [text, title, text, title, ...]
31
30
  for (let i = 0; i < sections.length; i++) {
32
31
  if (i % 2 === 0) {
@@ -55,7 +54,7 @@
55
54
  }
56
55
  }
57
56
  }
58
-
57
+
59
58
  // If no structured content found, treat as single step
60
59
  if (steps.length === 0 && content.trim()) {
61
60
  steps.push({
@@ -64,14 +63,14 @@
64
63
  isComplete: isComplete
65
64
  });
66
65
  }
67
-
66
+
68
67
  return steps;
69
68
  });
70
69
 
71
70
  // Find the longest/most descriptive title for collapsed view
72
71
  const bestTitle = $derived.by(() => {
73
72
  if (parsedSteps.length === 0) return 'Reasoning Complete';
74
-
73
+
75
74
  // Find the step with the longest title (most descriptive)
76
75
  let longest = parsedSteps[0];
77
76
  for (const step of parsedSteps) {
@@ -79,7 +78,7 @@
79
78
  longest = step;
80
79
  }
81
80
  }
82
-
81
+
83
82
  return longest.title;
84
83
  });
85
84
 
@@ -154,17 +153,16 @@
154
153
  // }, 300);
155
154
  // }
156
155
  // });
157
-
158
156
  </script>
159
157
 
160
158
  {#if isVisible && content}
161
159
  <div bind:this={containerRef} class={`${containerClasses} ${className}`}>
162
160
  <!-- Header -->
163
- <div
164
- class={headerClasses}
165
- onclick={toggleExpanded}
166
- onkeydown={(e) => e.key === 'Enter' || e.key === ' ' ? toggleExpanded() : null}
167
- role="button"
161
+ <div
162
+ class={headerClasses}
163
+ onclick={toggleExpanded}
164
+ onkeydown={(e) => (e.key === 'Enter' || e.key === ' ' ? toggleExpanded() : null)}
165
+ role="button"
168
166
  tabindex="0"
169
167
  >
170
168
  <div class="flex items-center gap-2">
@@ -173,30 +171,49 @@
173
171
  {#if !isComplete}
174
172
  <!-- Animated thinking dots -->
175
173
  <div class="flex items-center gap-1">
176
- <div class="w-1.5 h-1.5 bg-blue-500 rounded-full animate-pulse"></div>
177
- <div class="w-1.5 h-1.5 bg-blue-500 rounded-full animate-pulse" style="animation-delay: 0.2s"></div>
178
- <div class="w-1.5 h-1.5 bg-blue-500 rounded-full animate-pulse" style="animation-delay: 0.4s"></div>
174
+ <div class="h-1.5 w-1.5 animate-pulse rounded-full bg-blue-500"></div>
175
+ <div
176
+ class="h-1.5 w-1.5 animate-pulse rounded-full bg-blue-500"
177
+ style="animation-delay: 0.2s"
178
+ ></div>
179
+ <div
180
+ class="h-1.5 w-1.5 animate-pulse rounded-full bg-blue-500"
181
+ style="animation-delay: 0.4s"
182
+ ></div>
179
183
  </div>
180
184
  {:else}
181
185
  <!-- Completed icon -->
182
- <svg xmlns="http://www.w3.org/2000/svg" class="w-4 h-4 text-gray-500" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor">
183
- <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9.663 17h4.673M12 3v1m6.364 1.636l-.707.707M21 12h-1M4 12H3m3.343-5.657l-.707-.707m2.828 9.9a5 5 0 1 1 7.072 0l-.548.547A3.37 3.37 0 0 0 14 18.469V19a2 2 0 1 1-4 0v-.531c0-.895-.356-1.754-.988-2.386z"/>
186
+ <svg
187
+ xmlns="http://www.w3.org/2000/svg"
188
+ class="h-4 w-4 text-gray-500"
189
+ width="24"
190
+ height="24"
191
+ viewBox="0 0 24 24"
192
+ fill="none"
193
+ stroke="currentColor"
194
+ >
195
+ <path
196
+ stroke-linecap="round"
197
+ stroke-linejoin="round"
198
+ stroke-width="2"
199
+ d="M9.663 17h4.673M12 3v1m6.364 1.636l-.707.707M21 12h-1M4 12H3m3.343-5.657l-.707-.707m2.828 9.9a5 5 0 1 1 7.072 0l-.548.547A3.37 3.37 0 0 0 14 18.469V19a2 2 0 1 1-4 0v-.531c0-.895-.356-1.754-.988-2.386z"
200
+ />
184
201
  </svg>
185
202
  {/if}
186
- <span class="font-medium text-sm">
203
+ <span class="text-sm font-medium">
187
204
  {isComplete ? bestTitle : 'Thinking...'}
188
205
  </span>
189
206
  </div>
190
207
  </div>
191
-
208
+
192
209
  <!-- Expand/Collapse Icon -->
193
- <svg
194
- class={`w-4 h-4 transition-transform duration-200 ${isExpanded ? 'rotate-180' : ''}`}
195
- fill="none"
196
- stroke="currentColor"
210
+ <svg
211
+ class={`h-4 w-4 transition-transform duration-200 ${isExpanded ? 'rotate-180' : ''}`}
212
+ fill="none"
213
+ stroke="currentColor"
197
214
  viewBox="0 0 24 24"
198
215
  >
199
- <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7"/>
216
+ <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7" />
200
217
  </svg>
201
218
  </div>
202
219
 
@@ -205,51 +222,58 @@
205
222
  <div class={contentClasses}>
206
223
  <!-- Timeline Container -->
207
224
  <div class="relative">
208
- {#each parsedSteps as step, index}
225
+ {#each parsedSteps as step, index (index)}
209
226
  <div class="relative flex">
210
227
  <!-- Timeline Line and Icon -->
211
- <div class="flex flex-col items-center mr-4">
228
+ <div class="mr-4 flex flex-col items-center">
212
229
  <!-- Timeline Icon -->
213
- <div class="flex items-center justify-center w-5 h-5 shrink-0 rounded-full bg-white border border-gray-300 z-10">
230
+ <div
231
+ class="z-10 flex h-5 w-5 shrink-0 items-center justify-center rounded-full border border-gray-300 bg-white"
232
+ >
214
233
  {#if step.isComplete && index === parsedSteps.length - 1}
215
234
  <!-- Checkmark only for the last completed step -->
216
- <svg class="w-3 h-3 text-gray-600" fill="currentColor" viewBox="0 0 20 20">
217
- <path fill-rule="evenodd" d="M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z" clip-rule="evenodd"/>
235
+ <svg class="h-3 w-3 text-gray-600" fill="currentColor" viewBox="0 0 20 20">
236
+ <path
237
+ fill-rule="evenodd"
238
+ d="M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z"
239
+ clip-rule="evenodd"
240
+ />
218
241
  </svg>
219
242
  {:else if step.isComplete}
220
243
  <!-- Simple filled circle for other completed steps -->
221
- <div class="w-2.5 h-2.5 bg-gray-500 rounded-full"></div>
244
+ <div class="h-2.5 w-2.5 rounded-full bg-gray-500"></div>
222
245
  {:else}
223
246
  <!-- Pulsing dot for in-progress step -->
224
- <div class="w-2.5 h-2.5 bg-gray-400 rounded-full animate-pulse"></div>
247
+ <div class="h-2.5 w-2.5 animate-pulse rounded-full bg-gray-400"></div>
225
248
  {/if}
226
249
  </div>
227
-
250
+
228
251
  <!-- Vertical Line (except for last item) -->
229
252
  {#if index < parsedSteps.length - 1}
230
- <div class="w-0.5 h-full min-h-8 bg-gray-200 mt-1"></div>
253
+ <div class="mt-1 h-full min-h-8 w-0.5 bg-gray-200"></div>
231
254
  {/if}
232
255
  </div>
233
-
256
+
234
257
  <!-- Step Content -->
235
258
  <div class="flex-1 pb-6 last:pb-0">
236
259
  <!-- Step Title -->
237
260
  <div class="mb-2">
238
- <h4 class="font-medium text-sm text-gray-800 leading-tight">
261
+ <h4 class="text-sm leading-tight font-medium text-gray-800">
239
262
  {step.title}
240
263
  </h4>
241
264
  </div>
242
-
265
+
243
266
  <!-- Step Description -->
244
- <div class="text-sm text-gray-600 leading-relaxed">
267
+ <div class="text-sm leading-relaxed text-gray-600">
245
268
  {#if step.content.includes('•') || step.content.includes('-')}
246
269
  <!-- Parse bullet points -->
247
270
  <ul class="space-y-1">
248
- {#each step.content.split('\n') as line}
271
+ {#each step.content.split('\n') as line, lineIdx (lineIdx)}
249
272
  {@const trimmedLine = line.trim()}
250
273
  {#if trimmedLine.startsWith('•') || trimmedLine.startsWith('-')}
251
274
  <li class="flex items-start">
252
- <span class="w-1 h-1 bg-gray-400 rounded-full mt-2 mr-2 flex-shrink-0"></span>
275
+ <span class="mt-2 mr-2 h-1 w-1 flex-shrink-0 rounded-full bg-gray-400"
276
+ ></span>
253
277
  <span>{trimmedLine.substring(1).trim()}</span>
254
278
  </li>
255
279
  {:else if trimmedLine && !trimmedLine.startsWith('•') && !trimmedLine.startsWith('-')}
@@ -260,9 +284,9 @@
260
284
  {:else}
261
285
  <p class="whitespace-pre-wrap">{step.content}</p>
262
286
  {/if}
263
-
287
+
264
288
  {#if !step.isComplete && index === parsedSteps.length - 1}
265
- <span class="inline-block w-0.5 h-4 bg-blue-500 animate-pulse ml-1"></span>
289
+ <span class="ml-1 inline-block h-4 w-0.5 animate-pulse bg-blue-500"></span>
266
290
  {/if}
267
291
  </div>
268
292
  </div>
@@ -1,36 +1,37 @@
1
+ import { Color } from '../variants.js';
1
2
  export declare const aiChatInterface: import("tailwind-variants").TVReturnType<{
2
3
  color: {
3
- default: {
4
+ [Color.DEFAULT]: {
4
5
  userMessage: string;
5
6
  sendButton: string;
6
7
  background: string;
7
8
  };
8
- primary: {
9
+ [Color.PRIMARY]: {
9
10
  userMessage: string;
10
11
  sendButton: string;
11
12
  background: string;
12
13
  };
13
- secondary: {
14
+ [Color.SECONDARY]: {
14
15
  userMessage: string;
15
16
  sendButton: string;
16
17
  background: string;
17
18
  };
18
- success: {
19
+ [Color.SUCCESS]: {
19
20
  userMessage: string;
20
21
  sendButton: string;
21
22
  background: string;
22
23
  };
23
- warning: {
24
+ [Color.WARNING]: {
24
25
  userMessage: string;
25
26
  sendButton: string;
26
27
  background: string;
27
28
  };
28
- danger: {
29
+ [Color.DANGER]: {
29
30
  userMessage: string;
30
31
  sendButton: string;
31
32
  background: string;
32
33
  };
33
- info: {
34
+ [Color.INFO]: {
34
35
  userMessage: string;
35
36
  sendButton: string;
36
37
  background: string;
@@ -53,37 +54,37 @@ export declare const aiChatInterface: import("tailwind-variants").TVReturnType<{
53
54
  background: string;
54
55
  }, undefined, {
55
56
  color: {
56
- default: {
57
+ [Color.DEFAULT]: {
57
58
  userMessage: string;
58
59
  sendButton: string;
59
60
  background: string;
60
61
  };
61
- primary: {
62
+ [Color.PRIMARY]: {
62
63
  userMessage: string;
63
64
  sendButton: string;
64
65
  background: string;
65
66
  };
66
- secondary: {
67
+ [Color.SECONDARY]: {
67
68
  userMessage: string;
68
69
  sendButton: string;
69
70
  background: string;
70
71
  };
71
- success: {
72
+ [Color.SUCCESS]: {
72
73
  userMessage: string;
73
74
  sendButton: string;
74
75
  background: string;
75
76
  };
76
- warning: {
77
+ [Color.WARNING]: {
77
78
  userMessage: string;
78
79
  sendButton: string;
79
80
  background: string;
80
81
  };
81
- danger: {
82
+ [Color.DANGER]: {
82
83
  userMessage: string;
83
84
  sendButton: string;
84
85
  background: string;
85
86
  };
86
- info: {
87
+ [Color.INFO]: {
87
88
  userMessage: string;
88
89
  sendButton: string;
89
90
  background: string;
@@ -106,37 +107,37 @@ export declare const aiChatInterface: import("tailwind-variants").TVReturnType<{
106
107
  background: string;
107
108
  }, import("tailwind-variants").TVReturnType<{
108
109
  color: {
109
- default: {
110
+ [Color.DEFAULT]: {
110
111
  userMessage: string;
111
112
  sendButton: string;
112
113
  background: string;
113
114
  };
114
- primary: {
115
+ [Color.PRIMARY]: {
115
116
  userMessage: string;
116
117
  sendButton: string;
117
118
  background: string;
118
119
  };
119
- secondary: {
120
+ [Color.SECONDARY]: {
120
121
  userMessage: string;
121
122
  sendButton: string;
122
123
  background: string;
123
124
  };
124
- success: {
125
+ [Color.SUCCESS]: {
125
126
  userMessage: string;
126
127
  sendButton: string;
127
128
  background: string;
128
129
  };
129
- warning: {
130
+ [Color.WARNING]: {
130
131
  userMessage: string;
131
132
  sendButton: string;
132
133
  background: string;
133
134
  };
134
- danger: {
135
+ [Color.DANGER]: {
135
136
  userMessage: string;
136
137
  sendButton: string;
137
138
  background: string;
138
139
  };
139
- info: {
140
+ [Color.INFO]: {
140
141
  userMessage: string;
141
142
  sendButton: string;
142
143
  background: string;
@@ -1,4 +1,5 @@
1
1
  import { tv } from 'tailwind-variants';
2
+ import { Color } from '../variants.js';
2
3
  export const aiChatInterface = tv({
3
4
  slots: {
4
5
  userMessage: 'max-w-[70%] ml-auto px-4 py-3 rounded-3xl text-sm leading-relaxed shadow-lg',
@@ -8,37 +9,37 @@ export const aiChatInterface = tv({
8
9
  },
9
10
  variants: {
10
11
  color: {
11
- default: {
12
+ [Color.DEFAULT]: {
12
13
  userMessage: 'bg-default-900 text-white',
13
14
  sendButton: 'bg-default-900 hover:bg-default-800 text-white disabled:bg-default-300 disabled:text-default-500',
14
15
  background: 'bg-gray-50'
15
16
  },
16
- primary: {
17
+ [Color.PRIMARY]: {
17
18
  userMessage: 'bg-primary-600 text-white',
18
19
  sendButton: 'bg-primary-600 hover:bg-primary-700 text-white disabled:bg-primary-300 disabled:text-primary-100',
19
20
  background: 'bg-blue-50'
20
21
  },
21
- secondary: {
22
+ [Color.SECONDARY]: {
22
23
  userMessage: 'bg-secondary-600 text-white',
23
24
  sendButton: 'bg-secondary-600 hover:bg-secondary-700 text-white disabled:bg-secondary-300 disabled:text-secondary-100',
24
25
  background: 'bg-purple-50'
25
26
  },
26
- success: {
27
+ [Color.SUCCESS]: {
27
28
  userMessage: 'bg-success-600 text-white',
28
29
  sendButton: 'bg-success-600 hover:bg-success-700 text-white disabled:bg-success-300 disabled:text-success-100',
29
30
  background: 'bg-green-50'
30
31
  },
31
- warning: {
32
+ [Color.WARNING]: {
32
33
  userMessage: 'bg-warning-600 text-white',
33
34
  sendButton: 'bg-warning-600 hover:bg-warning-700 text-white disabled:bg-warning-300 disabled:text-warning-100',
34
35
  background: 'bg-yellow-50'
35
36
  },
36
- danger: {
37
+ [Color.DANGER]: {
37
38
  userMessage: 'bg-danger-600 text-white',
38
39
  sendButton: 'bg-danger-600 hover:bg-danger-700 text-white disabled:bg-danger-300 disabled:text-danger-100',
39
40
  background: 'bg-red-50'
40
41
  },
41
- info: {
42
+ [Color.INFO]: {
42
43
  userMessage: 'bg-info-600 text-white',
43
44
  sendButton: 'bg-info-600 hover:bg-info-700 text-white disabled:bg-info-300 disabled:text-info-100',
44
45
  background: 'bg-cyan-50'
@@ -78,8 +78,8 @@ export function parseContentSegments(content) {
78
78
  const codeBlocks = detectCodeBlocks(content);
79
79
  // Combine all blocks and sort by position
80
80
  const allBlocks = [
81
- ...mermaidBlocks.map(block => ({ ...block, type: 'mermaid' })),
82
- ...codeBlocks.map(block => ({ ...block, type: 'code' }))
81
+ ...mermaidBlocks.map((block) => ({ ...block, type: 'mermaid' })),
82
+ ...codeBlocks.map((block) => ({ ...block, type: 'code' }))
83
83
  ].sort((a, b) => a.startIndex - b.startIndex);
84
84
  let currentIndex = 0;
85
85
  for (const block of allBlocks) {
@@ -0,0 +1,10 @@
1
+ <script lang="ts">
2
+ import Button from './Button.svelte';
3
+ import type { ButtonProps } from '../index.js';
4
+
5
+ let { text = '', ...buttonProps }: ButtonProps & { text?: string } = $props();
6
+ </script>
7
+
8
+ <Button {...buttonProps}>
9
+ {text}
10
+ </Button>
@@ -0,0 +1,7 @@
1
+ import type { ButtonProps } from '../index.js';
2
+ type $$ComponentProps = ButtonProps & {
3
+ text?: string;
4
+ };
5
+ declare const ButtonTestWrapper: import("svelte").Component<$$ComponentProps, {}, "">;
6
+ type ButtonTestWrapper = ReturnType<typeof ButtonTestWrapper>;
7
+ export default ButtonTestWrapper;