feat: add InlineEdit, ConfirmDialog, MultiSelect to Inventory demos
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -15,6 +15,7 @@ import {
|
||||
FilterPill,
|
||||
FormField,
|
||||
InfoCallout,
|
||||
InlineEdit,
|
||||
Input,
|
||||
KeyboardHint,
|
||||
Label,
|
||||
@@ -95,6 +96,9 @@ export function PrimitivesSection() {
|
||||
end: new Date('2026-03-18T23:59'),
|
||||
})
|
||||
|
||||
// InlineEdit state
|
||||
const [inlineValue, setInlineValue] = useState('Alice Johnson')
|
||||
|
||||
return (
|
||||
<section id="primitives" className={styles.section}>
|
||||
<h2 className={styles.sectionTitle}>Primitives</h2>
|
||||
@@ -328,6 +332,15 @@ export function PrimitivesSection() {
|
||||
<Input icon="🔍" placeholder="With icon" />
|
||||
</DemoCard>
|
||||
|
||||
{/* 15b. InlineEdit */}
|
||||
<DemoCard id="inline-edit" title="InlineEdit" description="Click-to-edit text field. Enter saves, Escape/blur cancels.">
|
||||
<div style={{ display: 'flex', flexDirection: 'column', gap: 12 }}>
|
||||
<InlineEdit value={inlineValue} onSave={setInlineValue} />
|
||||
<InlineEdit value="" onSave={() => {}} placeholder="Click to add name..." />
|
||||
<InlineEdit value="Read only" onSave={() => {}} disabled />
|
||||
</div>
|
||||
</DemoCard>
|
||||
|
||||
{/* 16. KeyboardHint */}
|
||||
<DemoCard
|
||||
id="keyboardhint"
|
||||
|
||||
Reference in New Issue
Block a user