@schandlergarcia/sf-web-components 1.9.13 → 1.9.14
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/package.json
CHANGED
|
@@ -123,67 +123,14 @@ HOME="src/pages/Home.tsx"
|
|
|
123
123
|
echo "→ Updating ${HOME}..."
|
|
124
124
|
|
|
125
125
|
cat > "$HOME" << 'HOME_EOF'
|
|
126
|
-
import
|
|
127
|
-
import { useNavigate } from "react-router";
|
|
128
|
-
import UIInput from '@/components/library/ui/UIInput';
|
|
129
|
-
import UIButton from '@/components/library/ui/UIButton';
|
|
130
|
-
import { Search } from "lucide-react";
|
|
126
|
+
import CommandCenter from "@/components/workspace/CommandCenter";
|
|
131
127
|
|
|
132
128
|
export default function HomePage() {
|
|
133
|
-
|
|
134
|
-
const navigate = useNavigate();
|
|
135
|
-
|
|
136
|
-
const handleSearch = () => {
|
|
137
|
-
const trimmed = searchQuery.trim();
|
|
138
|
-
if (trimmed) {
|
|
139
|
-
navigate(`/accounts?search=${encodeURIComponent(trimmed)}`);
|
|
140
|
-
} else {
|
|
141
|
-
navigate('/accounts');
|
|
142
|
-
}
|
|
143
|
-
};
|
|
144
|
-
|
|
145
|
-
const handleKeyDown = (e: React.KeyboardEvent<HTMLInputElement>) => {
|
|
146
|
-
if (e.key === "Enter") {
|
|
147
|
-
e.preventDefault();
|
|
148
|
-
handleSearch();
|
|
149
|
-
}
|
|
150
|
-
};
|
|
151
|
-
|
|
152
|
-
return (
|
|
153
|
-
<div className="flex min-h-[80vh] items-center justify-center px-4 sm:px-6 lg:px-8 bg-slate-50 dark:bg-slate-950 transition-colors">
|
|
154
|
-
<div className="w-full max-w-4xl">
|
|
155
|
-
<div className="text-center mb-8">
|
|
156
|
-
<h1 className="text-4xl font-bold text-slate-900 dark:text-slate-50 mb-4">Search</h1>
|
|
157
|
-
<p className="text-lg text-slate-600 dark:text-slate-300">Find records across your organization.</p>
|
|
158
|
-
</div>
|
|
159
|
-
<div className="flex flex-col gap-4">
|
|
160
|
-
<div className="relative">
|
|
161
|
-
<Search className="absolute left-3 top-1/2 -translate-y-1/2 h-5 w-5 text-slate-400" />
|
|
162
|
-
<UIInput
|
|
163
|
-
type="text"
|
|
164
|
-
value={searchQuery}
|
|
165
|
-
onChange={(e) => setSearchQuery(e.target.value)}
|
|
166
|
-
onKeyDown={handleKeyDown}
|
|
167
|
-
placeholder="Search..."
|
|
168
|
-
className="pl-10 w-full"
|
|
169
|
-
/>
|
|
170
|
-
</div>
|
|
171
|
-
<div className="flex gap-3 justify-center">
|
|
172
|
-
<UIButton onClick={handleSearch} variant="primary">
|
|
173
|
-
Search
|
|
174
|
-
</UIButton>
|
|
175
|
-
<UIButton onClick={() => navigate('/accounts')} variant="secondary">
|
|
176
|
-
Browse All
|
|
177
|
-
</UIButton>
|
|
178
|
-
</div>
|
|
179
|
-
</div>
|
|
180
|
-
</div>
|
|
181
|
-
</div>
|
|
182
|
-
);
|
|
129
|
+
return <CommandCenter />;
|
|
183
130
|
}
|
|
184
131
|
HOME_EOF
|
|
185
132
|
|
|
186
|
-
echo " ✓ Home renders
|
|
133
|
+
echo " ✓ Home renders CommandCenter (dashboard)"
|
|
187
134
|
echo ""
|
|
188
135
|
|
|
189
136
|
# ── 5. Ensure Search.tsx page exists ─────────────────────────────────────────
|
|
@@ -317,13 +264,14 @@ echo "║ • Authentication features ║"
|
|
|
317
264
|
echo "║ • All styles & dependencies ║"
|
|
318
265
|
echo "║ ║"
|
|
319
266
|
echo "║ Layout: ║"
|
|
320
|
-
echo "║ / →
|
|
267
|
+
echo "║ / → CommandCenter (blank dashboard)║"
|
|
268
|
+
echo "║ /search → Search interface ║"
|
|
321
269
|
echo "║ /accounts → Account search and browse ║"
|
|
322
270
|
echo "║ ║"
|
|
323
|
-
echo "║
|
|
324
|
-
echo "║ •
|
|
325
|
-
echo "║ •
|
|
326
|
-
echo "║ •
|
|
271
|
+
echo "║ Command Center setup: ║"
|
|
272
|
+
echo "║ • Home renders BlankDashboard ║"
|
|
273
|
+
echo "║ • Theme and data providers configured ║"
|
|
274
|
+
echo "║ • Ready to build custom dashboards ║"
|
|
327
275
|
echo "║ ║"
|
|
328
276
|
echo "║ Start building: ║"
|
|
329
277
|
echo "║ npm run dev ║"
|