@alpaca-editor/core 1.0.4134 → 1.0.4140

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 (126) hide show
  1. package/dist/config/config.js +7 -0
  2. package/dist/config/config.js.map +1 -1
  3. package/dist/editor/FieldListField.js +3 -4
  4. package/dist/editor/FieldListField.js.map +1 -1
  5. package/dist/editor/Terminal.js +1 -1
  6. package/dist/editor/Terminal.js.map +1 -1
  7. package/dist/editor/Titlebar.js +0 -1
  8. package/dist/editor/Titlebar.js.map +1 -1
  9. package/dist/editor/ai/AgentCostDisplay.d.ts +3 -1
  10. package/dist/editor/ai/AgentCostDisplay.js +26 -2
  11. package/dist/editor/ai/AgentCostDisplay.js.map +1 -1
  12. package/dist/editor/ai/AgentStatusBadge.d.ts +26 -0
  13. package/dist/editor/ai/AgentStatusBadge.js +110 -0
  14. package/dist/editor/ai/AgentStatusBadge.js.map +1 -0
  15. package/dist/editor/ai/AgentTerminal.js +289 -198
  16. package/dist/editor/ai/AgentTerminal.js.map +1 -1
  17. package/dist/editor/ai/Agents.d.ts +2 -2
  18. package/dist/editor/ai/Agents.js +115 -19
  19. package/dist/editor/ai/Agents.js.map +1 -1
  20. package/dist/editor/ai/AiResponseMessage.js +259 -45
  21. package/dist/editor/ai/AiResponseMessage.js.map +1 -1
  22. package/dist/editor/ai/ContextInfoBar.js +124 -113
  23. package/dist/editor/ai/ContextInfoBar.js.map +1 -1
  24. package/dist/editor/ai/ToolCallDisplay.d.ts +1 -0
  25. package/dist/editor/ai/ToolCallDisplay.js +70 -58
  26. package/dist/editor/ai/ToolCallDisplay.js.map +1 -1
  27. package/dist/editor/ai/useAgentStatus.d.ts +13 -0
  28. package/dist/editor/ai/useAgentStatus.js +101 -0
  29. package/dist/editor/ai/useAgentStatus.js.map +1 -0
  30. package/dist/editor/client/EditorShell.js +23 -8
  31. package/dist/editor/client/EditorShell.js.map +1 -1
  32. package/dist/editor/client/itemsRepository.js.map +1 -1
  33. package/dist/editor/commands/localizeItem/LocalizeItemDialog.js +5 -5
  34. package/dist/editor/commands/localizeItem/LocalizeItemDialog.js.map +1 -1
  35. package/dist/editor/control-center/About.js +1 -1
  36. package/dist/editor/control-center/About.js.map +1 -1
  37. package/dist/editor/control-center/AllAgentsPanel.d.ts +5 -0
  38. package/dist/editor/control-center/AllAgentsPanel.js +126 -0
  39. package/dist/editor/control-center/AllAgentsPanel.js.map +1 -0
  40. package/dist/editor/control-center/WebSocketMessages.js +1 -0
  41. package/dist/editor/control-center/WebSocketMessages.js.map +1 -1
  42. package/dist/editor/control-center/setup-steps/AiSetupStep/tools/GenerateToolsSection.js +42 -7
  43. package/dist/editor/control-center/setup-steps/AiSetupStep/tools/GenerateToolsSection.js.map +1 -1
  44. package/dist/editor/media-selector/AiImageSearch.d.ts +1 -1
  45. package/dist/editor/media-selector/AiImageSearch.js +162 -103
  46. package/dist/editor/media-selector/AiImageSearch.js.map +1 -1
  47. package/dist/editor/media-selector/TreeSelector.js +20 -4
  48. package/dist/editor/media-selector/TreeSelector.js.map +1 -1
  49. package/dist/editor/menubar/toolbar-sections/UtilityControls.js +5 -2
  50. package/dist/editor/menubar/toolbar-sections/UtilityControls.js.map +1 -1
  51. package/dist/editor/page-editor-chrome/PlaceholderDropZone.d.ts +1 -1
  52. package/dist/editor/page-editor-chrome/PlaceholderDropZone.js +7 -5
  53. package/dist/editor/page-editor-chrome/PlaceholderDropZone.js.map +1 -1
  54. package/dist/editor/page-viewer/DeviceToolbar.js +2 -2
  55. package/dist/editor/page-viewer/DeviceToolbar.js.map +1 -1
  56. package/dist/editor/page-viewer/PageViewerFrame.js +18 -11
  57. package/dist/editor/page-viewer/PageViewerFrame.js.map +1 -1
  58. package/dist/editor/services/agentService.d.ts +53 -48
  59. package/dist/editor/services/agentService.js +137 -79
  60. package/dist/editor/services/agentService.js.map +1 -1
  61. package/dist/editor/services/aiService.d.ts +1 -1
  62. package/dist/editor/services/editService.js +1 -0
  63. package/dist/editor/services/editService.js.map +1 -1
  64. package/dist/editor/sidebar/GraphQL.js +20 -7
  65. package/dist/editor/sidebar/GraphQL.js.map +1 -1
  66. package/dist/editor/sidebar/SEOInfo.js +1 -2
  67. package/dist/editor/sidebar/SEOInfo.js.map +1 -1
  68. package/dist/editor/sidebar/Translations.js +10 -7
  69. package/dist/editor/sidebar/Translations.js.map +1 -1
  70. package/dist/editor/ui/ItemNameDialogNew.js +1 -1
  71. package/dist/editor/ui/ItemSearch.js +10 -4
  72. package/dist/editor/ui/ItemSearch.js.map +1 -1
  73. package/dist/page-wizard/steps/CollectStep.js +2 -2
  74. package/dist/page-wizard/steps/CollectStep.js.map +1 -1
  75. package/dist/page-wizard/steps/FieldEditor.js +2 -2
  76. package/dist/page-wizard/steps/FieldEditor.js.map +1 -1
  77. package/dist/revision.d.ts +2 -2
  78. package/dist/revision.js +2 -2
  79. package/dist/splash-screen/NewPage.js +2 -2
  80. package/dist/splash-screen/NewPage.js.map +1 -1
  81. package/dist/splash-screen/RecentPages.js +1 -1
  82. package/dist/splash-screen/RecentPages.js.map +1 -1
  83. package/dist/styles.css +167 -22
  84. package/dist/tour/Tour.js +15 -11
  85. package/dist/tour/Tour.js.map +1 -1
  86. package/package.json +1 -1
  87. package/src/config/config.tsx +7 -0
  88. package/src/editor/FieldListField.tsx +13 -13
  89. package/src/editor/Terminal.tsx +1 -1
  90. package/src/editor/Titlebar.tsx +0 -1
  91. package/src/editor/ai/AgentCostDisplay.tsx +57 -1
  92. package/src/editor/ai/AgentStatusBadge.tsx +144 -0
  93. package/src/editor/ai/AgentTerminal.tsx +345 -219
  94. package/src/editor/ai/Agents.tsx +179 -30
  95. package/src/editor/ai/AiResponseMessage.tsx +411 -114
  96. package/src/editor/ai/ContextInfoBar.tsx +134 -131
  97. package/src/editor/ai/ToolCallDisplay.tsx +217 -176
  98. package/src/editor/ai/useAgentStatus.ts +123 -0
  99. package/src/editor/client/EditorShell.tsx +34 -8
  100. package/src/editor/client/itemsRepository.ts +1 -2
  101. package/src/editor/commands/localizeItem/LocalizeItemDialog.tsx +5 -5
  102. package/src/editor/control-center/About.tsx +0 -14
  103. package/src/editor/control-center/AllAgentsPanel.tsx +300 -0
  104. package/src/editor/control-center/WebSocketMessages.tsx +1 -0
  105. package/src/editor/control-center/setup-steps/AiSetupStep/tools/GenerateToolsSection.tsx +49 -8
  106. package/src/editor/media-selector/AiImageSearch.tsx +162 -172
  107. package/src/editor/media-selector/TreeSelector.tsx +137 -116
  108. package/src/editor/menubar/toolbar-sections/UtilityControls.tsx +9 -1
  109. package/src/editor/page-editor-chrome/PlaceholderDropZone.tsx +7 -4
  110. package/src/editor/page-viewer/DeviceToolbar.tsx +15 -11
  111. package/src/editor/page-viewer/PageViewerFrame.tsx +20 -14
  112. package/src/editor/services/agentService.ts +217 -129
  113. package/src/editor/services/aiService.ts +2 -2
  114. package/src/editor/services/editService.ts +1 -0
  115. package/src/editor/sidebar/GraphQL.tsx +143 -117
  116. package/src/editor/sidebar/SEOInfo.tsx +1 -2
  117. package/src/editor/sidebar/Translations.tsx +14 -12
  118. package/src/editor/ui/ItemNameDialogNew.tsx +1 -1
  119. package/src/editor/ui/ItemSearch.tsx +11 -4
  120. package/src/editor/ui/SimpleTabs.tsx +1 -1
  121. package/src/page-wizard/steps/CollectStep.tsx +2 -2
  122. package/src/page-wizard/steps/FieldEditor.tsx +13 -15
  123. package/src/revision.ts +2 -2
  124. package/src/splash-screen/NewPage.tsx +2 -2
  125. package/src/splash-screen/RecentPages.tsx +1 -1
  126. package/src/tour/Tour.tsx +61 -48
@@ -1,6 +1,6 @@
1
1
  import "@uiw/react-textarea-code-editor/dist.css";
2
2
 
3
- import { Splitter, SplitterPanel } from "primereact/splitter";
3
+ import { Splitter } from "../ui/Splitter";
4
4
  import CodeEditor from "@uiw/react-textarea-code-editor";
5
5
  import { ActionButton } from "../../components/ActionButton";
6
6
  import { useEffect, useState } from "react";
@@ -218,129 +218,155 @@ export function GraphQL() {
218
218
  // (moved useEffect for context factory above to ensure hooks order remains stable)
219
219
 
220
220
  return (
221
- <Splitter layout="vertical" style={{ height: "100%" }}>
222
- <SplitterPanel size={50} className="relative">
223
- <div className="absolute inset-0 flex flex-col overflow-hidden">
224
- {aiGeneratedQuery && aiGeneratedQuery !== query && (
225
- <div className="flex items-center gap-2 border-b border-yellow-200 bg-yellow-50 p-2 text-xs">
226
- <span className="text-yellow-800">AI generated a new query</span>
227
- <ActionButton
228
- onClick={() => applyQueryToEditor(aiGeneratedQuery)}
229
- className="p-1 text-xs"
230
- variant="outline"
231
- >
232
- Apply
233
- </ActionButton>
234
- <ActionButton
235
- onClick={() => setAiGeneratedQuery("")}
236
- className="p-1"
237
- variant="ghost"
238
- >
239
- ×
240
- </ActionButton>
241
- </div>
242
- )}
243
- <Splitter layout="horizontal" style={{ height: "100%" }}>
244
- <SplitterPanel size={50} className="relative">
245
- <div className="absolute inset-0 flex items-stretch">
246
- <div className="relative min-w-0 flex-1">
247
- <div className="absolute inset-0 overflow-auto">
248
- <CodeEditor
249
- value={query}
250
- language="graphql"
251
- placeholder="Enter your GraphQL query here..."
252
- onChange={(evn: any) => setQuery(evn.target.value)}
253
- padding={15}
254
- style={{
255
- fontSize: 12,
256
- backgroundColor: "#f8f9fa",
257
- fontFamily:
258
- "ui-monospace,SFMono-Regular,SF Mono,Consolas,Liberation Mono,Menlo,monospace",
259
- }}
260
- />
221
+ <Splitter
222
+ direction="vertical"
223
+ className="h-full"
224
+ panels={[
225
+ {
226
+ name: "query",
227
+ defaultSize: 850,
228
+ className: "flex flex-col min-h-[500px]",
229
+ content: (
230
+ <div className="flex flex-1 flex-col overflow-hidden">
231
+ {aiGeneratedQuery && aiGeneratedQuery !== query && (
232
+ <div className="flex items-center gap-2 border-b border-yellow-200 bg-yellow-50 p-2 text-xs">
233
+ <span className="text-yellow-800">
234
+ AI generated a new query
235
+ </span>
236
+ <ActionButton
237
+ onClick={() => applyQueryToEditor(aiGeneratedQuery)}
238
+ className="p-1 text-xs"
239
+ variant="outline"
240
+ >
241
+ Apply
242
+ </ActionButton>
243
+ <ActionButton
244
+ onClick={() => setAiGeneratedQuery("")}
245
+ className="p-1"
246
+ variant="ghost"
247
+ >
248
+ ×
249
+ </ActionButton>
250
+ </div>
251
+ )}
252
+ <div className="flex h-full flex-col">
253
+ {/* GraphQL Query Section */}
254
+ <div className="flex flex-1 flex-col border-b border-gray-300">
255
+ <div className="border-b border-gray-300 bg-gray-100 px-3 py-2 text-sm font-medium text-gray-700">
256
+ GraphQL Query
257
+ </div>
258
+ <div className="relative flex-1">
259
+ <div className="absolute inset-0 overflow-auto">
260
+ <CodeEditor
261
+ value={query}
262
+ language="graphql"
263
+ placeholder="Enter your GraphQL query here..."
264
+ onChange={(evn: any) => setQuery(evn.target.value)}
265
+ padding={15}
266
+ style={{
267
+ fontSize: 12,
268
+ backgroundColor: "#f8f9fa",
269
+ fontFamily:
270
+ "ui-monospace,SFMono-Regular,SF Mono,Consolas,Liberation Mono,Menlo,monospace",
271
+ }}
272
+ />
273
+ </div>
261
274
  </div>
262
275
  </div>
263
- <ActionButton
264
- onClick={refresh}
265
- disabled={showSpinner}
266
- className="h-full px-2"
267
- variant="outline"
268
- >
269
- <RefreshCw strokeWidth={1} />
270
- </ActionButton>
271
- </div>
272
- </SplitterPanel>
273
- <SplitterPanel className="relative">
274
- <div className="absolute inset-0 flex flex-col text-xs">
275
- <div className="border-b border-gray-300 bg-gray-50 px-2 py-1 text-xs font-medium">
276
- JSON Result
276
+
277
+ {/* Run Button Section */}
278
+ <div className="flex items-center justify-center border-b border-gray-300 bg-gray-50 py-3">
279
+ <ActionButton
280
+ onClick={refresh}
281
+ disabled={showSpinner}
282
+ className="px-4 py-2"
283
+ variant="outline"
284
+ >
285
+ <RefreshCw strokeWidth={1.5} className="mr-2 h-4 w-4" />
286
+ Run
287
+ </ActionButton>
277
288
  </div>
278
- <div className="flex-1 overflow-auto p-2">
279
- <div className="min-w-0 overflow-x-auto">
280
- <ObjectInspector data={graphqlResult} expandLevel={3} />
289
+
290
+ {/* JSON Result Section */}
291
+ <div className="flex flex-1 flex-col">
292
+ <div className="border-b border-gray-300 bg-gray-100 px-3 py-2 text-sm font-medium text-gray-700">
293
+ JSON Result
294
+ </div>
295
+ <div className="flex-1 overflow-auto p-2">
296
+ <div className="min-w-0 overflow-x-auto">
297
+ <ObjectInspector data={graphqlResult} expandLevel={3} />
298
+ </div>
281
299
  </div>
282
300
  </div>
283
301
  </div>
284
- </SplitterPanel>
285
- </Splitter>
286
- </div>
287
- </SplitterPanel>
288
- <SplitterPanel className="relative">
289
- <div className="absolute inset-0 flex flex-col text-xs">
290
- <SimpleTabs
291
- className="border-gray-3 border-b px-2 pt-2"
292
- tabs={[
293
- {
294
- id: "schema",
295
- label: "Schema",
296
- content: (
297
- <div className="relative h-full overflow-hidden">
298
- <div className="flex items-center gap-2 border-b p-2">
299
- <ActionButton
300
- onClick={fetchSchema}
301
- disabled={showSchemaSpinner}
302
- variant="outline"
303
- className="text-sm"
304
- >
305
- 📥 Fetch Schema
306
- </ActionButton>
307
- </div>
308
- <div className="flex-1 overflow-auto p-2">
309
- <div className="min-w-0 overflow-x-auto">
310
- <ObjectInspector data={schemaResult} expandLevel={3} />
302
+ </div>
303
+ ),
304
+ },
305
+ {
306
+ name: "schema",
307
+ defaultSize: 150,
308
+ className: "flex flex-col text-xs min-h-[150px]",
309
+ content: (
310
+ <div className="flex flex-1 flex-col text-xs">
311
+ <SimpleTabs
312
+ className="border-gray-3 border-b px-2 pt-2"
313
+ tabs={[
314
+ {
315
+ id: "schema",
316
+ label: "Schema",
317
+ content: (
318
+ <div className="relative h-full overflow-hidden">
319
+ <div className="flex items-center gap-2 border-b p-2">
320
+ <ActionButton
321
+ onClick={fetchSchema}
322
+ disabled={showSchemaSpinner}
323
+ variant="outline"
324
+ className="text-sm"
325
+ >
326
+ 📥 Fetch Schema
327
+ </ActionButton>
328
+ </div>
329
+ <div className="flex-1 overflow-auto p-2">
330
+ <div className="min-w-0 overflow-x-auto">
331
+ <ObjectInspector
332
+ data={schemaResult}
333
+ expandLevel={3}
334
+ />
335
+ </div>
336
+ </div>
311
337
  </div>
312
- </div>
313
- </div>
314
- ),
315
- },
316
- ]}
317
- activeTab={activeTab}
318
- setActiveTab={setActiveTab}
319
- />
320
- <div className="border-t border-gray-200 p-2">
321
- <ActionButton
322
- variant="outline"
323
- className="text-xs"
324
- onClick={() => {
325
- editContext?.executeCommand?.({
326
- command: createAgentCommand,
327
- data: {
328
- profileName: "GraphQL Assistant",
329
- contextFactory: "graphql:context:v1",
330
- initialPrompt:
331
- "Help with the current GraphQL query and schema.",
332
- additionalData: {
333
- source: "GraphQLPanel",
334
- },
338
+ ),
335
339
  },
336
- });
337
- }}
338
- >
339
- Start GraphQL Agent
340
- </ActionButton>
341
- </div>
342
- </div>
343
- </SplitterPanel>
344
- </Splitter>
340
+ ]}
341
+ activeTab={activeTab}
342
+ setActiveTab={setActiveTab}
343
+ />
344
+ <div className="border-t border-gray-200 p-2">
345
+ <ActionButton
346
+ variant="outline"
347
+ className="text-xs"
348
+ onClick={() => {
349
+ editContext?.executeCommand?.({
350
+ command: createAgentCommand,
351
+ data: {
352
+ profileName: "GraphQL Assistant",
353
+ contextFactory: "graphql:context:v1",
354
+ initialPrompt:
355
+ "Help with the current GraphQL query and schema.",
356
+ additionalData: {
357
+ source: "GraphQLPanel",
358
+ },
359
+ },
360
+ });
361
+ }}
362
+ >
363
+ Start GraphQL Agent
364
+ </ActionButton>
365
+ </div>
366
+ </div>
367
+ ),
368
+ },
369
+ ]}
370
+ />
345
371
  );
346
372
  }
@@ -1,7 +1,6 @@
1
1
  import { useState } from "react";
2
2
  import { Button } from "../../components/ui/button";
3
3
  import { Search } from "lucide-react";
4
- import { Divider } from "primereact/divider";
5
4
  import { useEditContext } from "../client/editContext";
6
5
  import { toast } from "sonner";
7
6
 
@@ -203,7 +202,7 @@ Focus on actionable insights for improving search engine visibility.`;
203
202
  Run SEO Analysis
204
203
  </Button>
205
204
 
206
- <Divider />
205
+ <div className="my-4 border-t border-gray-200" />
207
206
 
208
207
  {/* SEO Information */}
209
208
  <div className="space-y-3">
@@ -10,8 +10,9 @@ import {
10
10
  import { useEffect, useState } from "react";
11
11
  import { TranslationStatus } from "../../config/types";
12
12
 
13
- import { ProgressBar } from "primereact/progressbar";
14
- import { Checkbox } from "primereact/checkbox";
13
+ // Custom Progress component using Tailwind CSS
14
+ import { Checkbox } from "../../components/ui/checkbox";
15
+ import { Sparkles, Plus } from "lucide-react";
15
16
  import { confirmCreateVersion } from "../utils/itemutils";
16
17
  import { Select } from "../../components/ui/select";
17
18
 
@@ -216,7 +217,7 @@ export function Translation() {
216
217
  }}
217
218
  disabled={checkedLanguages.length === 0}
218
219
  >
219
- <i className="pi pi-sparkles" />
220
+ <Sparkles className="h-4 w-4" />
220
221
  Translate
221
222
  </Button>
222
223
  )}
@@ -228,7 +229,7 @@ export function Translation() {
228
229
  }}
229
230
  disabled={checkedLanguages.length === 0}
230
231
  >
231
- <i className="pi pi-plus" />
232
+ <Plus className="h-4 w-4" />
232
233
  Create Versions
233
234
  </Button>
234
235
  </div>
@@ -242,9 +243,9 @@ export function Translation() {
242
243
  <div onClick={(e) => e.stopPropagation()}>
243
244
  <Checkbox
244
245
  checked={checkedLanguages.includes(x.languageCode)}
245
- onChange={(ev) => {
246
+ onCheckedChange={(checked) => {
246
247
  setCheckedLanguages(
247
- ev.checked
248
+ Boolean(checked)
248
249
  ? [...checkedLanguages, x.languageCode]
249
250
  : checkedLanguages.filter(
250
251
  (y) => y !== x.languageCode,
@@ -266,13 +267,14 @@ export function Translation() {
266
267
  body: (x) => (
267
268
  <div className="flex items-center gap-2">
268
269
  {x.translationStatus?.status === "In Progress" && (
269
- <div className="relative w-full">
270
- <ProgressBar
271
- style={{ height: "20px" }}
272
- value={(x.translationProgress?.progress || 0) * 100}
273
- showValue={false}
270
+ <div className="relative h-5 w-full overflow-hidden rounded-full bg-gray-200">
271
+ <div
272
+ className="h-full bg-blue-500 transition-all duration-300 ease-in-out"
273
+ style={{
274
+ width: `${(x.translationProgress?.progress || 0) * 100}%`,
275
+ }}
274
276
  />
275
- <div className="absolute inset-0 flex items-center justify-center text-white">
277
+ <div className="absolute inset-0 flex items-center justify-center text-sm font-medium text-white">
276
278
  {x.translationProgress?.message}
277
279
  </div>
278
280
  </div>
@@ -114,7 +114,7 @@ export function ItemNameDialog(
114
114
  <DialogTitle>{props?.title ?? "Name"}</DialogTitle>
115
115
  </DialogHeader>
116
116
  <div className="p-3">
117
- <div className="my-2 text-sm">
117
+ <div className="mb-2 text-sm">
118
118
  {props.message || "Enter a name for the new item:"}
119
119
  </div>
120
120
  <Input
@@ -47,13 +47,15 @@ export const ItemSearch: React.FC<SearchProps> = ({
47
47
  if (!editContext || disabled) return;
48
48
 
49
49
  setLoading(true);
50
+ const trimmedPrompt = searchPrompt.trim();
50
51
  const currentQuery = searchPrompt;
51
52
 
53
+ // Check for GUID pattern
52
54
  const guidPattern =
53
55
  /^\{?[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}\}?$/;
54
- if (guidPattern.test(searchPrompt)) {
56
+ if (guidPattern.test(trimmedPrompt)) {
55
57
  const item = await editContext.itemsRepository.getItem({
56
- id: searchPrompt,
58
+ id: trimmedPrompt,
57
59
  language: language || "en",
58
60
  version: 0,
59
61
  });
@@ -78,12 +80,17 @@ export const ItemSearch: React.FC<SearchProps> = ({
78
80
  return;
79
81
  }
80
82
 
83
+ // Check for item path pattern (starts with /)
84
+ const isPath = trimmedPrompt.startsWith("/");
85
+
86
+ // If it looks like a path, search with skipValidation to allow exact path matching
81
87
  const result = await executeSearch({
82
88
  index: "master",
83
- query: searchPrompt,
89
+ query: trimmedPrompt,
84
90
  editContext,
85
91
  rootItemIds,
86
- maxResults: 15,
92
+ maxResults: isPath ? 15 : 15,
93
+ skipValidation: isPath,
87
94
  });
88
95
 
89
96
  if (query === currentQuery) {
@@ -6,7 +6,7 @@ export type Tab = {
6
6
  content: React.ReactNode;
7
7
  id: string;
8
8
  testId?: string;
9
- icon?: string; // PrimeReact icon class name (e.g., "pi pi-search")
9
+ icon?: string;
10
10
  };
11
11
 
12
12
  export function SimpleTabs({
@@ -1,4 +1,4 @@
1
- import { InputText } from "primereact/inputtext";
1
+ import { Input } from "../../components/ui/input";
2
2
  import { useEffect, useRef, useState } from "react";
3
3
  import { WizardData } from "../PageWizard";
4
4
 
@@ -236,7 +236,7 @@ export function CollectStep({
236
236
  defaultCollapsed="mobileOnly"
237
237
  >
238
238
  <div className="flex flex-col gap-2">
239
- <InputText
239
+ <Input
240
240
  type="text"
241
241
  className="rounded-md border border-gray-300 px-3 py-2"
242
242
  onChange={(e) => setScrapeUrl(e.target.value)}
@@ -1,10 +1,9 @@
1
1
  import { useState, useEffect } from "react";
2
+ import { Editor, EditorTextChangeEvent } from "primereact/editor";
2
3
 
3
4
  import { WizardField } from "../PageWizard";
4
5
  import { TextField } from "../../editor/fieldTypes";
5
6
 
6
- import { Editor } from "primereact/editor";
7
-
8
7
  export function FieldEditor({
9
8
  field,
10
9
  onFieldEdited,
@@ -24,13 +23,10 @@ export function FieldEditor({
24
23
 
25
24
  if (!isEditing) {
26
25
  return (
27
- <div
28
- onClick={() => setIsEditing(true)}
29
- className="cursor-pointer mb-2"
30
- >
26
+ <div onClick={() => setIsEditing(true)} className="mb-2 cursor-pointer">
31
27
  <div className="font-bold text-gray-900">{field.name}:</div>
32
28
  <div
33
- className="text-gray-700 [&_ul]:list-disc [&_ul]:pl-5 [&_li]:my-1 [&_p]:my-1"
29
+ className="text-gray-700 [&_li]:my-1 [&_p]:my-1 [&_ul]:list-disc [&_ul]:pl-5"
34
30
  dangerouslySetInnerHTML={{ __html: field.value }}
35
31
  ></div>
36
32
  {/* <SimpleIconButton
@@ -56,24 +52,26 @@ export function FieldEditor({
56
52
  };
57
53
 
58
54
  return (
59
- <div className="fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-1000">
60
- <div className="bg-white rounded-lg shadow-xl p-6 w-full max-w-lg">
61
- <h3 className="text-lg font-medium text-gray-900 mb-4">
55
+ <div className="bg-opacity-50 fixed inset-0 z-1000 flex items-center justify-center bg-black">
56
+ <div className="w-full max-w-lg rounded-lg bg-white p-6 shadow-xl">
57
+ <h3 className="mb-4 text-lg font-medium text-gray-900">
62
58
  Edit {field.name || "Field"}
63
59
  </h3>
64
60
 
65
61
  {isRichText ? (
66
62
  <div className="mb-4">
67
63
  <Editor
68
- className="w-full h-64 p-2 border border-gray-300 rounded-md"
64
+ className="h-64 w-full rounded-md border border-gray-300 p-2"
69
65
  value={fieldValue}
70
- onTextChange={(e) => setFieldValue(e.htmlValue || "")}
66
+ onTextChange={(e: EditorTextChangeEvent) =>
67
+ setFieldValue(e.htmlValue || "")
68
+ }
71
69
  />
72
70
  </div>
73
71
  ) : (
74
72
  <div className="mb-4">
75
73
  <textarea
76
- className="w-full p-2 border border-gray-300 rounded-md"
74
+ className="w-full rounded-md border border-gray-300 p-2"
77
75
  value={fieldValue}
78
76
  onChange={(e) => setFieldValue(e.target.value)}
79
77
  />
@@ -84,14 +82,14 @@ export function FieldEditor({
84
82
  <button
85
83
  type="button"
86
84
  onClick={handleCancel}
87
- className="inline-flex items-center px-4 py-2 border border-gray-300 text-sm font-medium rounded-md text-gray-700 bg-white hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500"
85
+ className="inline-flex items-center rounded-md border border-gray-300 bg-white px-4 py-2 text-sm font-medium text-gray-700 hover:bg-gray-50 focus:ring-2 focus:ring-blue-500 focus:ring-offset-2 focus:outline-none"
88
86
  >
89
87
  Cancel
90
88
  </button>
91
89
  <button
92
90
  type="button"
93
91
  onClick={handleSave}
94
- className="inline-flex items-center px-4 py-2 border border-transparent text-sm font-medium rounded-md shadow-sm text-white bg-blue-600 hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500"
92
+ className="inline-flex items-center rounded-md border border-transparent bg-blue-600 px-4 py-2 text-sm font-medium text-white shadow-sm hover:bg-blue-700 focus:ring-2 focus:ring-blue-500 focus:ring-offset-2 focus:outline-none"
95
93
  >
96
94
  Save
97
95
  </button>
package/src/revision.ts CHANGED
@@ -1,2 +1,2 @@
1
- export const version = "1.0.4134";
2
- export const buildDate = "2025-10-02 00:59:02";
1
+ export const version = "1.0.4140";
2
+ export const buildDate = "2025-10-06 11:12:09";
@@ -9,7 +9,7 @@ import {
9
9
  executeCreateItem,
10
10
  loadInsertOptions,
11
11
  } from "../editor/services/editService";
12
- import { InputText } from "primereact/inputtext";
12
+ import { Input } from "../components/ui/input";
13
13
  import { getAbsoluteIconUrl, getItemDescriptor } from "../editor/utils";
14
14
  import { cn } from "../lib/utils";
15
15
  import { useEditContext } from "../client-components";
@@ -282,7 +282,7 @@ export function NewPage({ selectedItemId }: { selectedItemId?: string }) {
282
282
  description="Enter a name for your new page"
283
283
  >
284
284
  <div>
285
- <InputText
285
+ <Input
286
286
  className="w-full rounded p-1.5 text-xs"
287
287
  value={name}
288
288
  id="new-page-name"
@@ -68,7 +68,7 @@ export function RecentPages() {
68
68
  onClick={() => handlePageLoad(page)}
69
69
  className="cursor-pointer border-b border-gray-100 hover:bg-gray-50"
70
70
  >
71
- <td className="py-3">
71
+ <td className="px-1.5 py-3">
72
72
  <div className="flex items-center gap-2">
73
73
  {/* {page.icon && (
74
74
  <img