Skip to content

Commit a4edc0a

Browse files
CopilotTechQuery
andcommitted
Add new components to demo page and complete implementation
Co-authored-by: TechQuery <[email protected]>
1 parent 88e80d5 commit a4edc0a

1 file changed

Lines changed: 83 additions & 0 deletions

File tree

app/page.tsx

Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,12 @@ import { ImagePreviewExample } from "@/registry/new-york/blocks/image-preview/ex
99
import { FilePreviewExample } from "@/registry/new-york/blocks/file-preview/example";
1010
import { ScrollBoundaryExample } from "@/registry/new-york/blocks/scroll-boundary/example";
1111
import { ScrollListExample } from "@/registry/new-york/blocks/scroll-list/example";
12+
import { ArrayFieldExample } from "@/registry/new-york/blocks/array-field/example";
13+
import { BadgeInputExample } from "@/registry/new-york/blocks/badge-input/example";
14+
import { RangeInputExample } from "@/registry/new-york/blocks/range-input/example";
15+
import { FilePickerExample } from "@/registry/new-york/blocks/file-picker/example";
16+
import { FormFieldExample } from "@/registry/new-york/blocks/form-field/example";
17+
import { SearchableInputExample } from "@/registry/new-york/blocks/searchable-input/example";
1218
// This page displays items from the custom registry.
1319
// You are free to implement this with your own design as needed.
1420

@@ -145,6 +151,83 @@ export default function Home() {
145151
<ScrollListExample />
146152
</div>
147153
</div>
154+
155+
<div className="flex flex-col gap-4 border rounded-lg p-4 min-h-[450px] relative">
156+
<div className="flex items-center justify-between">
157+
<h2 className="text-sm text-muted-foreground sm:pl-3">
158+
A dynamic array field component with add/remove functionality for
159+
form arrays.
160+
</h2>
161+
<OpenInV0Button name="array-field" className="w-fit" />
162+
</div>
163+
<div className="flex items-center justify-center min-h-[400px] relative">
164+
<ArrayFieldExample />
165+
</div>
166+
</div>
167+
168+
<div className="flex flex-col gap-4 border rounded-lg p-4 min-h-[450px] relative">
169+
<div className="flex items-center justify-between">
170+
<h2 className="text-sm text-muted-foreground sm:pl-3">
171+
An input component that displays values as removable badges,
172+
supporting multiple entries.
173+
</h2>
174+
<OpenInV0Button name="badge-input" className="w-fit" />
175+
</div>
176+
<div className="flex items-center justify-center min-h-[400px] relative">
177+
<BadgeInputExample />
178+
</div>
179+
</div>
180+
181+
<div className="flex flex-col gap-4 border rounded-lg p-4 min-h-[450px] relative">
182+
<div className="flex items-center justify-between">
183+
<h2 className="text-sm text-muted-foreground sm:pl-3">
184+
A range slider input with optional custom icon display for each
185+
step.
186+
</h2>
187+
<OpenInV0Button name="range-input" className="w-fit" />
188+
</div>
189+
<div className="flex items-center justify-center min-h-[400px] relative">
190+
<RangeInputExample />
191+
</div>
192+
</div>
193+
194+
<div className="flex flex-col gap-4 border rounded-lg p-4 min-h-[450px] relative">
195+
<div className="flex items-center justify-between">
196+
<h2 className="text-sm text-muted-foreground sm:pl-3">
197+
A file picker component with preview and remove functionality.
198+
</h2>
199+
<OpenInV0Button name="file-picker" className="w-fit" />
200+
</div>
201+
<div className="flex items-center justify-center min-h-[400px] relative">
202+
<FilePickerExample />
203+
</div>
204+
</div>
205+
206+
<div className="flex flex-col gap-4 border rounded-lg p-4 min-h-[450px] relative">
207+
<div className="flex items-center justify-between">
208+
<h2 className="text-sm text-muted-foreground sm:pl-3">
209+
A unified form field component supporting input, textarea, and
210+
select elements with labels.
211+
</h2>
212+
<OpenInV0Button name="form-field" className="w-fit" />
213+
</div>
214+
<div className="flex items-center justify-center min-h-[400px] relative">
215+
<FormFieldExample />
216+
</div>
217+
</div>
218+
219+
<div className="flex flex-col gap-4 border rounded-lg p-4 min-h-[450px] relative">
220+
<div className="flex items-center justify-between">
221+
<h2 className="text-sm text-muted-foreground sm:pl-3">
222+
A searchable select input with badge display, supporting single or
223+
multiple selection.
224+
</h2>
225+
<OpenInV0Button name="searchable-input" className="w-fit" />
226+
</div>
227+
<div className="flex items-center justify-center min-h-[400px] relative">
228+
<SearchableInputExample />
229+
</div>
230+
</div>
148231
</main>
149232
</div>
150233
);

0 commit comments

Comments
 (0)