Spaces:
Paused
Paused
Shereen Lee commited on
Commit ·
d0e548b
1
Parent(s): b108887
feat(upload): rename to Develop Photos, cull tags, handwriting+larger title/caption, drop camera icon
Browse files- index.html +4 -67
index.html
CHANGED
|
@@ -1718,7 +1718,7 @@
|
|
| 1718 |
onChange={(e) => onTitleChange(e.target.value)}
|
| 1719 |
placeholder="Name this moment…"
|
| 1720 |
aria-label="Photo title"
|
| 1721 |
-
className="w-full rounded-md bg-transparent px-3 py-2.5 font-
|
| 1722 |
/>
|
| 1723 |
{/* developing overlay — same darkroom effect as the caption */}
|
| 1724 |
{titleBusy ? (
|
|
@@ -1785,7 +1785,7 @@
|
|
| 1785 |
<div className="relative rounded-md border-2 border-primary/70 bg-card">
|
| 1786 |
<textarea id="caption" value={caption} onChange={(e) => onCaptionChange(e.target.value)} rows={3}
|
| 1787 |
placeholder="Write something about this moment..."
|
| 1788 |
-
className="w-full resize-none rounded-md bg-transparent px-3 py-2.5 font-hand text-
|
| 1789 |
{/* developing overlay: a darkroom-flavored caption "developing in the tray" */}
|
| 1790 |
{autoBusy ? (
|
| 1791 |
<div className="absolute inset-0 flex flex-col items-center justify-center gap-2 overflow-hidden rounded-md"
|
|
@@ -1822,73 +1822,10 @@
|
|
| 1822 |
</div>
|
| 1823 |
</div>
|
| 1824 |
</div>
|
| 1825 |
-
<div className="space-y-2">
|
| 1826 |
-
<div className="flex items-center justify-between gap-2">
|
| 1827 |
-
<label htmlFor="tags" className="font-mono text-xs font-semibold uppercase tracking-wide text-foreground">Tags <span className="text-muted-foreground">(optional)</span></label>
|
| 1828 |
-
<div className="flex items-center gap-1.5">
|
| 1829 |
-
<MicButton field="tags" title="Dictate tags"
|
| 1830 |
-
onText={(t) => onTagsChange(((tags || "").trim() ? tags.trim().replace(/,\s*$/, "") + ", " : "") + t)} />
|
| 1831 |
-
<button type="button" onClick={() => setShowTagsPrompt((v) => !v)} aria-expanded={showTagsPrompt}
|
| 1832 |
-
title="Customize the AI tags prompt"
|
| 1833 |
-
className={cn("flex items-center gap-1.5 rounded-md border-2 px-2.5 py-1 font-mono text-[11px] uppercase tracking-wide transition-colors",
|
| 1834 |
-
showTagsPrompt ? "border-primary bg-accent text-foreground" : "border-primary/60 text-primary hover:bg-accent")}>
|
| 1835 |
-
<Settings className="size-3.5" /> Prompt
|
| 1836 |
-
</button>
|
| 1837 |
-
<button type="button" onClick={onAutoTags} disabled={tagsBusy}
|
| 1838 |
-
className="flex items-center gap-1.5 rounded-md border-2 border-primary/60 px-2.5 py-1 font-mono text-[11px] uppercase tracking-wide text-primary transition-colors hover:bg-accent disabled:opacity-60">
|
| 1839 |
-
<Wand2 className={cn("size-3.5", tagsBusy && "animate-pulse")} /> {tagsBusy ? "Tagging…" : "Auto-generate"}
|
| 1840 |
-
</button>
|
| 1841 |
-
</div>
|
| 1842 |
-
</div>
|
| 1843 |
-
|
| 1844 |
-
{/* editable, independent tags prompt (traced separately as "autotags") */}
|
| 1845 |
-
{showTagsPrompt ? (
|
| 1846 |
-
<div className="rounded-md border-2 border-primary/50 bg-accent/30 p-3">
|
| 1847 |
-
<div className="flex items-center justify-between gap-2">
|
| 1848 |
-
<label htmlFor="tags-prompt" className="font-mono text-[10px] font-semibold uppercase tracking-wide text-foreground">Tags prompt</label>
|
| 1849 |
-
<span className="flex items-center gap-1.5 font-mono text-[10px] uppercase tracking-wide text-muted-foreground" title="Active vision-language model">
|
| 1850 |
-
<Cpu className="size-3 text-primary" /> {captionModel || "loading model…"}
|
| 1851 |
-
</span>
|
| 1852 |
-
</div>
|
| 1853 |
-
<textarea id="tags-prompt" value={tagsPrompt} onChange={(e) => onTagsPromptChange(e.target.value)} rows={2}
|
| 1854 |
-
placeholder={DEFAULT_TAGS_HINT}
|
| 1855 |
-
className="mt-2 w-full resize-none rounded-md border-2 border-primary/40 bg-card px-2.5 py-2 text-xs leading-relaxed text-foreground outline-none placeholder:text-muted-foreground focus:border-primary" />
|
| 1856 |
-
<div className="mt-1.5 flex items-center justify-between gap-2">
|
| 1857 |
-
<p className="font-mono text-[9px] leading-snug tracking-wide text-muted-foreground">Generated tags are always comma-separated. Leave blank for the default.</p>
|
| 1858 |
-
{tagsPrompt ? (
|
| 1859 |
-
<button type="button" onClick={() => onTagsPromptChange("")}
|
| 1860 |
-
className="shrink-0 font-mono text-[9px] uppercase tracking-widest text-primary underline-offset-2 hover:underline">reset</button>
|
| 1861 |
-
) : null}
|
| 1862 |
-
</div>
|
| 1863 |
-
</div>
|
| 1864 |
-
) : null}
|
| 1865 |
-
|
| 1866 |
-
<div className="relative rounded-md border-2 border-primary/70 bg-card">
|
| 1867 |
-
<input id="tags" value={tags} onChange={(e) => onTagsChange(e.target.value)} placeholder="ottawa, architecture, travel"
|
| 1868 |
-
className="w-full rounded-md bg-transparent px-3 py-2.5 text-sm text-foreground outline-none placeholder:text-muted-foreground" />
|
| 1869 |
-
{tagsBusy ? (
|
| 1870 |
-
<div className="absolute inset-0 flex items-center justify-center gap-2 overflow-hidden rounded-md"
|
| 1871 |
-
role="status" aria-live="polite"
|
| 1872 |
-
style={{ background: "linear-gradient(180deg, var(--card), color-mix(in oklch, var(--accent) 60%, var(--card)))" }}>
|
| 1873 |
-
<span aria-hidden="true" className="absolute inset-0"
|
| 1874 |
-
style={{ background: "linear-gradient(110deg, transparent 20%, color-mix(in oklch, var(--primary) 22%, transparent) 50%, transparent 80%)", backgroundSize: "200% 100%", animation: "sozai-shimmer 1.3s linear infinite" }} />
|
| 1875 |
-
<span className="relative flex items-center gap-2 font-mono text-[11px] uppercase tracking-widest text-primary">
|
| 1876 |
-
<Wand2 className="size-3.5 animate-pulse" /> {tagsStage || "Tagging…"}
|
| 1877 |
-
</span>
|
| 1878 |
-
<span className="relative flex gap-1" aria-hidden="true">
|
| 1879 |
-
<span className="size-1.5 rounded-full bg-primary" style={{ animation: "sozai-bounce 1s infinite", animationDelay: "0ms" }} />
|
| 1880 |
-
<span className="size-1.5 rounded-full bg-primary" style={{ animation: "sozai-bounce 1s infinite", animationDelay: "150ms" }} />
|
| 1881 |
-
<span className="size-1.5 rounded-full bg-primary" style={{ animation: "sozai-bounce 1s infinite", animationDelay: "300ms" }} />
|
| 1882 |
-
</span>
|
| 1883 |
-
</div>
|
| 1884 |
-
) : null}
|
| 1885 |
-
</div>
|
| 1886 |
-
{tagsError ? <p role="status" className="font-mono text-[11px] uppercase tracking-wide text-[oklch(0.55_0.18_25)]">{tagsError}</p> : null}
|
| 1887 |
-
</div>
|
| 1888 |
<div className="flex flex-col items-center gap-2 pt-1">
|
| 1889 |
<button type="button" onClick={onSubmit}
|
| 1890 |
className="flex w-full items-center justify-center gap-2 rounded-md border-2 border-primary bg-primary px-4 py-3 font-mono text-sm font-semibold uppercase tracking-wide text-primary-foreground transition-colors hover:bg-primary/90">
|
| 1891 |
-
<Plus className="size-4" />
|
| 1892 |
</button>
|
| 1893 |
<p className="text-center text-xs text-muted-foreground">Save to your memory album</p>
|
| 1894 |
</div>
|
|
@@ -2370,7 +2307,7 @@
|
|
| 2370 |
return (
|
| 2371 |
<section className="w-full max-w-6xl rounded-xl border-2 border-primary bg-card shadow-lg">
|
| 2372 |
<header className="flex items-center justify-between gap-4 border-b-2 border-dashed border-primary/50 px-5 py-4 sm:px-7">
|
| 2373 |
-
<div className="flex items-center gap-2.5"><
|
| 2374 |
<div className="flex items-center gap-2">
|
| 2375 |
<button type="button" onClick={() => onOpenSettings && onOpenSettings()} aria-label="Settings" className="flex size-9 items-center justify-center rounded-md border-2 border-primary/70 text-primary transition-colors hover:bg-accent"><Settings className="size-4" /></button>
|
| 2376 |
</div>
|
|
|
|
| 1718 |
onChange={(e) => onTitleChange(e.target.value)}
|
| 1719 |
placeholder="Name this moment…"
|
| 1720 |
aria-label="Photo title"
|
| 1721 |
+
className="w-full rounded-md bg-transparent px-3 py-2.5 font-hand text-lg text-foreground outline-none placeholder:font-normal placeholder:text-muted-foreground"
|
| 1722 |
/>
|
| 1723 |
{/* developing overlay — same darkroom effect as the caption */}
|
| 1724 |
{titleBusy ? (
|
|
|
|
| 1785 |
<div className="relative rounded-md border-2 border-primary/70 bg-card">
|
| 1786 |
<textarea id="caption" value={caption} onChange={(e) => onCaptionChange(e.target.value)} rows={3}
|
| 1787 |
placeholder="Write something about this moment..."
|
| 1788 |
+
className="w-full resize-none rounded-md bg-transparent px-3 py-2.5 font-hand text-lg leading-relaxed text-foreground outline-none placeholder:text-muted-foreground" />
|
| 1789 |
{/* developing overlay: a darkroom-flavored caption "developing in the tray" */}
|
| 1790 |
{autoBusy ? (
|
| 1791 |
<div className="absolute inset-0 flex flex-col items-center justify-center gap-2 overflow-hidden rounded-md"
|
|
|
|
| 1822 |
</div>
|
| 1823 |
</div>
|
| 1824 |
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1825 |
<div className="flex flex-col items-center gap-2 pt-1">
|
| 1826 |
<button type="button" onClick={onSubmit}
|
| 1827 |
className="flex w-full items-center justify-center gap-2 rounded-md border-2 border-primary bg-primary px-4 py-3 font-mono text-sm font-semibold uppercase tracking-wide text-primary-foreground transition-colors hover:bg-primary/90">
|
| 1828 |
+
<Plus className="size-4" /> Develop Photos
|
| 1829 |
</button>
|
| 1830 |
<p className="text-center text-xs text-muted-foreground">Save to your memory album</p>
|
| 1831 |
</div>
|
|
|
|
| 2307 |
return (
|
| 2308 |
<section className="w-full max-w-6xl rounded-xl border-2 border-primary bg-card shadow-lg">
|
| 2309 |
<header className="flex items-center justify-between gap-4 border-b-2 border-dashed border-primary/50 px-5 py-4 sm:px-7">
|
| 2310 |
+
<div className="flex items-center gap-2.5"><h1 className="font-display text-2xl text-foreground">Develop Photos</h1></div>
|
| 2311 |
<div className="flex items-center gap-2">
|
| 2312 |
<button type="button" onClick={() => onOpenSettings && onOpenSettings()} aria-label="Settings" className="flex size-9 items-center justify-center rounded-md border-2 border-primary/70 text-primary transition-colors hover:bg-accent"><Settings className="size-4" /></button>
|
| 2313 |
</div>
|