@burdenoff/microfe-coolandlovely 2026.716.1 → 2026.720.1

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 (32) hide show
  1. package/dist/coolandlovely/components/LookCard.d.ts +3 -1
  2. package/dist/coolandlovely/components/LookCard.d.ts.map +1 -1
  3. package/dist/coolandlovely/components/LookCard.js +80 -44
  4. package/dist/coolandlovely/components/LookCard.js.map +1 -1
  5. package/dist/coolandlovely/hooks/index.d.ts +1 -1
  6. package/dist/coolandlovely/hooks/index.d.ts.map +1 -1
  7. package/dist/coolandlovely/hooks/useCoolAndLovelyApi.d.ts +3 -0
  8. package/dist/coolandlovely/hooks/useCoolAndLovelyApi.d.ts.map +1 -1
  9. package/dist/coolandlovely/hooks/useCoolAndLovelyApi.js +58 -22
  10. package/dist/coolandlovely/hooks/useCoolAndLovelyApi.js.map +1 -1
  11. package/dist/coolandlovely/pages/HomePage.d.ts.map +1 -1
  12. package/dist/coolandlovely/pages/HomePage.js +2 -0
  13. package/dist/coolandlovely/pages/HomePage.js.map +1 -1
  14. package/dist/coolandlovely/pages/items/StyleItemDetailPage.d.ts.map +1 -1
  15. package/dist/coolandlovely/pages/items/StyleItemDetailPage.js +2 -0
  16. package/dist/coolandlovely/pages/items/StyleItemDetailPage.js.map +1 -1
  17. package/dist/coolandlovely/pages/looks/LookDetailPage.d.ts +4 -2
  18. package/dist/coolandlovely/pages/looks/LookDetailPage.d.ts.map +1 -1
  19. package/dist/coolandlovely/pages/looks/LookDetailPage.js +134 -128
  20. package/dist/coolandlovely/pages/looks/LookDetailPage.js.map +1 -1
  21. package/dist/coolandlovely/pages/looks/LooksListPage.d.ts.map +1 -1
  22. package/dist/coolandlovely/pages/looks/LooksListPage.js +2 -0
  23. package/dist/coolandlovely/pages/looks/LooksListPage.js.map +1 -1
  24. package/dist/coolandlovely/pages/wardrobe/WardrobeFormPage.d.ts.map +1 -1
  25. package/dist/coolandlovely/pages/wardrobe/WardrobeFormPage.js +46 -23
  26. package/dist/coolandlovely/pages/wardrobe/WardrobeFormPage.js.map +1 -1
  27. package/dist/coolandlovely/pages/wardrobe/WardrobeListPage.d.ts.map +1 -1
  28. package/dist/coolandlovely/pages/wardrobe/WardrobeListPage.js +70 -63
  29. package/dist/coolandlovely/pages/wardrobe/WardrobeListPage.js.map +1 -1
  30. package/dist/coolandlovely/types/index.d.ts +11 -0
  31. package/dist/coolandlovely/types/index.d.ts.map +1 -1
  32. package/package.json +1 -1
@@ -7,8 +7,10 @@ interface LookCardProps {
7
7
  occasion: string;
8
8
  imageFileId?: string | null;
9
9
  likeCount?: number;
10
+ isLikedByMe?: boolean;
11
+ isSavedByMe?: boolean;
10
12
  onOpen: () => void;
11
- /** Show the hover like/add-to-lookbook overlay cluster. */
13
+ /** Show the hover like/save/add-to-lookbook overlay cluster. */
12
14
  showActions?: boolean;
13
15
  className?: string;
14
16
  }
@@ -1 +1 @@
1
- {"version":3,"file":"LookCard.d.ts","sourceRoot":"","sources":["../../../src/coolandlovely/components/LookCard.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAShC,UAAU,aAAa;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,8EAA8E;IAC9E,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,2DAA2D;IAC3D,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AA8CD,eAAO,MAAM,QAAQ,EAAE,EAAE,CAAC,aAAa,CAwDtC,CAAC"}
1
+ {"version":3,"file":"LookCard.d.ts","sourceRoot":"","sources":["../../../src/coolandlovely/components/LookCard.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAiHhC,UAAU,aAAa;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,8EAA8E;IAC9E,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,gEAAgE;IAChE,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,eAAO,MAAM,QAAQ,EAAE,EAAE,CAAC,aAAa,CA2DtC,CAAC"}
@@ -1,77 +1,113 @@
1
1
  import { cn as e } from "../utils/cn.js";
2
2
  import { Thumbnail as t } from "./Thumbnail.js";
3
- import { useLikeLook as n } from "../hooks/useCoolAndLovelyApi.js";
4
- import { AddToLookbookButton as r } from "./AddToLookbookButton.js";
5
- import { titleCase as i } from "../utils/formatters.js";
6
- import { useEffect as a, useState as o } from "react";
7
- import { Heart as s, Sparkles as c } from "lucide-react";
8
- import { jsx as l, jsxs as u } from "react/jsx-runtime";
3
+ import { useLikeLook as n, useSaveLook as r, useUnlikeLook as i, useUnsaveLook as a } from "../hooks/useCoolAndLovelyApi.js";
4
+ import { AddToLookbookButton as o } from "./AddToLookbookButton.js";
5
+ import { titleCase as s } from "../utils/formatters.js";
6
+ import { useEffect as c, useState as l } from "react";
7
+ import { Bookmark as u, Heart as d, Sparkles as f } from "lucide-react";
8
+ import { jsx as p, jsxs as m } from "react/jsx-runtime";
9
9
  //#region src/coolandlovely/components/LookCard.tsx
10
- var d = ({ lookId: t, likeCount: r }) => {
11
- let i = n(), [c, d] = o(!1), [f, p] = o(r);
12
- return a(() => {
13
- c || p(r);
14
- }, [r, c]), /* @__PURE__ */ u("button", {
10
+ var h = ({ lookId: t, likeCount: r, isLikedByMe: a }) => {
11
+ let o = n(), s = i(), [u, f] = l(!!a), [h, g] = l(r), _ = o.isPending || s.isPending;
12
+ return c(() => {
13
+ _ || (f(!!a), g(r));
14
+ }, [
15
+ r,
16
+ a,
17
+ _
18
+ ]), /* @__PURE__ */ m("button", {
15
19
  type: "button",
16
20
  onClick: () => {
17
- c || i.isPending || (d(!0), p((e) => e + 1), i.mutate(t, {
18
- onSuccess: (e) => p(e.likeCount),
21
+ if (_) return;
22
+ let e = !u;
23
+ f(e), g((t) => t + (e ? 1 : -1)), (e ? o : s).mutate(t, {
24
+ onSuccess: (e) => {
25
+ f(!!e.isLikedByMe), g(e.likeCount);
26
+ },
19
27
  onError: () => {
20
- d(!1), p(r);
28
+ f(!e), g(r);
21
29
  }
22
- }));
30
+ });
23
31
  },
24
- disabled: i.isPending,
25
- "aria-pressed": c,
26
- "aria-label": c ? "Liked" : "Like this look",
32
+ disabled: _,
33
+ "aria-pressed": u,
34
+ "aria-label": u ? "Unlike this look" : "Like this look",
27
35
  className: "inline-flex items-center gap-1 rounded-full bg-bg-surface/90 px-2 py-1 text-xs font-medium text-text-primary shadow-sm backdrop-blur transition-colors hover:bg-bg-surface disabled:opacity-60 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]",
28
- children: [/* @__PURE__ */ l(s, { className: e("h-3.5 w-3.5", c ? "fill-current text-accent-primary" : "text-text-secondary") }), /* @__PURE__ */ l("span", {
36
+ children: [/* @__PURE__ */ p(d, { className: e("h-3.5 w-3.5", u ? "fill-current text-accent-primary" : "text-text-secondary") }), /* @__PURE__ */ p("span", {
29
37
  className: "tabular-nums",
30
- children: f
38
+ children: h
31
39
  })]
32
40
  });
33
- }, f = ({ id: n, title: a, occasion: o, imageFileId: f, likeCount: p, onOpen: m, showActions: h = !1, className: g }) => /* @__PURE__ */ u("div", {
34
- className: e("group relative overflow-hidden rounded-xl border border-border-seam bg-bg-surface transition-shadow hover:shadow-lg", g),
35
- children: [/* @__PURE__ */ l("button", {
41
+ }, g = ({ lookId: t, isSavedByMe: n }) => {
42
+ let i = r(), o = a(), [s, d] = l(!!n), f = i.isPending || o.isPending;
43
+ return c(() => {
44
+ f || d(!!n);
45
+ }, [n, f]), /* @__PURE__ */ p("button", {
36
46
  type: "button",
37
- onClick: m,
38
- "aria-label": `Open look ${a}`,
47
+ onClick: () => {
48
+ if (f) return;
49
+ let e = !s;
50
+ d(e), (e ? i : o).mutate(t, {
51
+ onSuccess: (e) => d(!!e.isSavedByMe),
52
+ onError: () => d(!e)
53
+ });
54
+ },
55
+ disabled: f,
56
+ "aria-pressed": s,
57
+ "aria-label": s ? "Remove from saved" : "Save this look",
58
+ className: "inline-flex items-center justify-center rounded-full bg-bg-surface/90 p-1.5 text-text-primary shadow-sm backdrop-blur transition-colors hover:bg-bg-surface disabled:opacity-60 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]",
59
+ children: /* @__PURE__ */ p(u, { className: e("h-3.5 w-3.5", s ? "fill-current text-accent-primary" : "text-text-secondary") })
60
+ });
61
+ }, _ = ({ id: n, title: r, occasion: i, imageFileId: a, likeCount: c, isLikedByMe: l, isSavedByMe: u, onOpen: _, showActions: v = !1, className: y }) => /* @__PURE__ */ m("div", {
62
+ className: e("group relative overflow-hidden rounded-xl border border-border-seam bg-bg-surface transition-shadow hover:shadow-lg", y),
63
+ children: [/* @__PURE__ */ p("button", {
64
+ type: "button",
65
+ onClick: _,
66
+ "aria-label": `Open look ${r}`,
39
67
  className: "block w-full text-left focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-[var(--color-focus-ring)]",
40
- children: /* @__PURE__ */ l(t, {
41
- icon: /* @__PURE__ */ l(c, { className: "h-8 w-8" }),
68
+ children: /* @__PURE__ */ p(t, {
69
+ icon: /* @__PURE__ */ p(f, { className: "h-8 w-8" }),
42
70
  seed: n,
43
- fileId: f,
44
- alt: a,
71
+ fileId: a,
72
+ alt: r,
45
73
  className: "aspect-[3/4] w-full rounded-none",
46
- overlay: /* @__PURE__ */ u("div", {
74
+ overlay: /* @__PURE__ */ m("div", {
47
75
  className: "pointer-events-none absolute inset-x-0 bottom-0 flex flex-col gap-1.5 bg-gradient-to-t from-bg-canvas/90 via-bg-canvas/45 to-transparent p-3 pt-10",
48
- children: [/* @__PURE__ */ l("p", {
76
+ children: [/* @__PURE__ */ p("p", {
49
77
  className: "truncate text-sm font-semibold text-text-primary",
50
- children: a
51
- }), /* @__PURE__ */ u("div", {
78
+ children: r
79
+ }), /* @__PURE__ */ m("div", {
52
80
  className: "flex items-center justify-between gap-2",
53
- children: [/* @__PURE__ */ l("span", {
81
+ children: [/* @__PURE__ */ p("span", {
54
82
  className: "inline-flex items-center rounded-full bg-bg-surface/85 px-2 py-0.5 text-[11px] font-medium text-text-primary backdrop-blur",
55
- children: i(o)
56
- }), !h && typeof p == "number" && p > 0 ? /* @__PURE__ */ u("span", {
83
+ children: s(i)
84
+ }), !v && typeof c == "number" && c > 0 ? /* @__PURE__ */ m("span", {
57
85
  className: "inline-flex items-center gap-1 text-xs text-text-secondary",
58
- children: [/* @__PURE__ */ l(s, { className: "h-3.5 w-3.5 fill-current text-accent-primary" }), /* @__PURE__ */ l("span", {
86
+ children: [/* @__PURE__ */ p(d, { className: "h-3.5 w-3.5 fill-current text-accent-primary" }), /* @__PURE__ */ p("span", {
59
87
  className: "tabular-nums",
60
- children: p
88
+ children: c
61
89
  })]
62
90
  }) : null]
63
91
  })]
64
92
  })
65
93
  })
66
- }), h ? /* @__PURE__ */ u("div", {
94
+ }), v ? /* @__PURE__ */ m("div", {
67
95
  className: "absolute right-2 top-2 flex items-center gap-1.5 opacity-100 transition-opacity duration-200 sm:opacity-0 sm:focus-within:opacity-100 sm:group-hover:opacity-100",
68
- children: [/* @__PURE__ */ l(d, {
69
- lookId: n,
70
- likeCount: p ?? 0
71
- }), /* @__PURE__ */ l(r, { lookId: n })]
96
+ children: [
97
+ /* @__PURE__ */ p(h, {
98
+ lookId: n,
99
+ likeCount: c ?? 0,
100
+ isLikedByMe: l
101
+ }),
102
+ /* @__PURE__ */ p(g, {
103
+ lookId: n,
104
+ isSavedByMe: u
105
+ }),
106
+ /* @__PURE__ */ p(o, { lookId: n })
107
+ ]
72
108
  }) : null]
73
109
  });
74
110
  //#endregion
75
- export { f as LookCard };
111
+ export { _ as LookCard };
76
112
 
77
113
  //# sourceMappingURL=LookCard.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"LookCard.js","names":[],"sources":["../../../src/coolandlovely/components/LookCard.tsx"],"sourcesContent":["/**\n * LookCard — an editorial, image-forward card for a look.\n * @module coolandlovely/components\n *\n * A portrait `Thumbnail` (the look photo) with a frosted bottom caption (title +\n * occasion pill) and, when `showActions`, a hover-revealed top-right cluster: a\n * Like heart (optimistic, via `useLikeLook`) + `AddToLookbookButton`. Reused by\n * the home latest-looks, Discover, the looks list and the collaboration\n * attributed-looks grid. Token-only; reuses `Thumbnail`/`FileImage` for imagery.\n */\n\nimport type { FC } from 'react';\nimport { useEffect, useState } from 'react';\nimport { Heart, Sparkles } from 'lucide-react';\nimport { Thumbnail } from './Thumbnail';\nimport { AddToLookbookButton } from './AddToLookbookButton';\nimport { useLikeLook } from '../hooks/useCoolAndLovelyApi';\nimport { titleCase } from '../utils/formatters';\nimport { cn } from '../utils/cn';\n\ninterface LookCardProps {\n id: string;\n title: string;\n /** Occasion label/value (rendered as a pill; enum values are title-cased). */\n occasion: string;\n imageFileId?: string | null;\n likeCount?: number;\n onOpen: () => void;\n /** Show the hover like/add-to-lookbook overlay cluster. */\n showActions?: boolean;\n className?: string;\n}\n\n/** Optimistic like heart — one-way like (no unlike op exists on the server). */\nconst LikeHeart: FC<{ lookId: string; likeCount: number }> = ({ lookId, likeCount }) => {\n const like = useLikeLook();\n const [liked, setLiked] = useState(false);\n const [count, setCount] = useState(likeCount);\n\n // Keep in sync with the server count until the user likes in this session.\n useEffect(() => {\n if (!liked) setCount(likeCount);\n }, [likeCount, liked]);\n\n const handleClick = () => {\n if (liked || like.isPending) return;\n setLiked(true);\n setCount((current) => current + 1);\n like.mutate(lookId, {\n onSuccess: (look) => setCount(look.likeCount),\n onError: () => {\n setLiked(false);\n setCount(likeCount);\n },\n });\n };\n\n return (\n <button\n type=\"button\"\n onClick={handleClick}\n disabled={like.isPending}\n aria-pressed={liked}\n aria-label={liked ? 'Liked' : 'Like this look'}\n className=\"inline-flex items-center gap-1 rounded-full bg-bg-surface/90 px-2 py-1 text-xs font-medium text-text-primary shadow-sm backdrop-blur transition-colors hover:bg-bg-surface disabled:opacity-60 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]\"\n >\n <Heart\n className={cn(\n 'h-3.5 w-3.5',\n liked ? 'fill-current text-accent-primary' : 'text-text-secondary'\n )}\n />\n <span className=\"tabular-nums\">{count}</span>\n </button>\n );\n};\n\nexport const LookCard: FC<LookCardProps> = ({\n id,\n title,\n occasion,\n imageFileId,\n likeCount,\n onOpen,\n showActions = false,\n className,\n}) => {\n return (\n <div\n className={cn(\n 'group relative overflow-hidden rounded-xl border border-border-seam bg-bg-surface transition-shadow hover:shadow-lg',\n className\n )}\n >\n <button\n type=\"button\"\n onClick={onOpen}\n aria-label={`Open look ${title}`}\n className=\"block w-full text-left focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-[var(--color-focus-ring)]\"\n >\n <Thumbnail\n icon={<Sparkles className=\"h-8 w-8\" />}\n seed={id}\n fileId={imageFileId}\n alt={title}\n className=\"aspect-[3/4] w-full rounded-none\"\n overlay={\n <div className=\"pointer-events-none absolute inset-x-0 bottom-0 flex flex-col gap-1.5 bg-gradient-to-t from-bg-canvas/90 via-bg-canvas/45 to-transparent p-3 pt-10\">\n <p className=\"truncate text-sm font-semibold text-text-primary\">{title}</p>\n <div className=\"flex items-center justify-between gap-2\">\n <span className=\"inline-flex items-center rounded-full bg-bg-surface/85 px-2 py-0.5 text-[11px] font-medium text-text-primary backdrop-blur\">\n {titleCase(occasion)}\n </span>\n {!showActions && typeof likeCount === 'number' && likeCount > 0 ? (\n <span className=\"inline-flex items-center gap-1 text-xs text-text-secondary\">\n <Heart className=\"h-3.5 w-3.5 fill-current text-accent-primary\" />\n <span className=\"tabular-nums\">{likeCount}</span>\n </span>\n ) : null}\n </div>\n </div>\n }\n />\n </button>\n\n {showActions ? (\n <div className=\"absolute right-2 top-2 flex items-center gap-1.5 opacity-100 transition-opacity duration-200 sm:opacity-0 sm:focus-within:opacity-100 sm:group-hover:opacity-100\">\n <LikeHeart lookId={id} likeCount={likeCount ?? 0} />\n <AddToLookbookButton lookId={id} />\n </div>\n ) : null}\n </div>\n );\n};\n"],"mappings":";;;;;;;;;AAkCA,IAAM,KAAwD,EAAE,WAAQ,mBAAgB;CACtF,IAAM,IAAO,GAAa,EACpB,CAAC,GAAO,KAAY,EAAS,GAAM,EACnC,CAAC,GAAO,KAAY,EAAS,EAAU;AAoB7C,QAjBA,QAAgB;AACd,EAAK,KAAO,EAAS,EAAU;IAC9B,CAAC,GAAW,EAAM,CAAC,EAgBpB,kBAAC,UAAD;EACE,MAAK;EACL,eAhBsB;AACpB,QAAS,EAAK,cAClB,EAAS,GAAK,EACd,GAAU,MAAY,IAAU,EAAE,EAClC,EAAK,OAAO,GAAQ;IAClB,YAAY,MAAS,EAAS,EAAK,UAAU;IAC7C,eAAe;AAEb,KADA,EAAS,GAAM,EACf,EAAS,EAAU;;IAEtB,CAAC;;EAOA,UAAU,EAAK;EACf,gBAAc;EACd,cAAY,IAAQ,UAAU;EAC9B,WAAU;YANZ,CAQE,kBAAC,GAAD,EACE,WAAW,EACT,eACA,IAAQ,qCAAqC,sBAC9C,EACD,CAAA,EACF,kBAAC,QAAD;GAAM,WAAU;aAAgB;GAAa,CAAA,CACtC;;GAIA,KAA+B,EAC1C,OACA,UACA,aACA,gBACA,cACA,WACA,iBAAc,IACd,mBAGE,kBAAC,OAAD;CACE,WAAW,EACT,uHACA,EACD;WAJH,CAME,kBAAC,UAAD;EACE,MAAK;EACL,SAAS;EACT,cAAY,aAAa;EACzB,WAAU;YAEV,kBAAC,GAAD;GACE,MAAM,kBAAC,GAAD,EAAU,WAAU,WAAY,CAAA;GACtC,MAAM;GACN,QAAQ;GACR,KAAK;GACL,WAAU;GACV,SACE,kBAAC,OAAD;IAAK,WAAU;cAAf,CACE,kBAAC,KAAD;KAAG,WAAU;eAAoD;KAAU,CAAA,EAC3E,kBAAC,OAAD;KAAK,WAAU;eAAf,CACE,kBAAC,QAAD;MAAM,WAAU;gBACb,EAAU,EAAS;MACf,CAAA,EACN,CAAC,KAAe,OAAO,KAAc,YAAY,IAAY,IAC5D,kBAAC,QAAD;MAAM,WAAU;gBAAhB,CACE,kBAAC,GAAD,EAAO,WAAU,gDAAiD,CAAA,EAClE,kBAAC,QAAD;OAAM,WAAU;iBAAgB;OAAiB,CAAA,CAC5C;UACL,KACA;OACF;;GAER,CAAA;EACK,CAAA,EAER,IACC,kBAAC,OAAD;EAAK,WAAU;YAAf,CACE,kBAAC,GAAD;GAAW,QAAQ;GAAI,WAAW,KAAa;GAAK,CAAA,EACpD,kBAAC,GAAD,EAAqB,QAAQ,GAAM,CAAA,CAC/B;MACJ,KACA"}
1
+ {"version":3,"file":"LookCard.js","names":[],"sources":["../../../src/coolandlovely/components/LookCard.tsx"],"sourcesContent":["/**\n * LookCard — an editorial, image-forward card for a look.\n * @module coolandlovely/components\n *\n * A portrait `Thumbnail` (the look photo) with a frosted bottom caption (title +\n * occasion pill) and, when `showActions`, a hover-revealed top-right cluster: a\n * true toggle Like heart (optimistic, via `useLikeLook`/`useUnlikeLook`), a\n * Save bookmark (optimistic, via `useSaveLook`/`useUnsaveLook` — distinct from\n * both liking and clipping into a named lookbook) + `AddToLookbookButton`.\n * Reused by the home latest-looks, Discover, the looks list and the\n * collaboration attributed-looks grid. Token-only; reuses `Thumbnail`/\n * `FileImage` for imagery.\n */\n\nimport type { FC } from 'react';\nimport { useEffect, useState } from 'react';\nimport { Bookmark, Heart, Sparkles } from 'lucide-react';\nimport { Thumbnail } from './Thumbnail';\nimport { AddToLookbookButton } from './AddToLookbookButton';\nimport {\n useLikeLook,\n useSaveLook,\n useUnlikeLook,\n useUnsaveLook,\n} from '../hooks/useCoolAndLovelyApi';\nimport { titleCase } from '../utils/formatters';\nimport { cn } from '../utils/cn';\n\n/** Optimistic, true-toggle like heart (cooLikeLook / cooUnlikeLook). */\nconst LikeHeart: FC<{ lookId: string; likeCount: number; isLikedByMe?: boolean }> = ({\n lookId,\n likeCount,\n isLikedByMe,\n}) => {\n const like = useLikeLook();\n const unlike = useUnlikeLook();\n const [liked, setLiked] = useState(Boolean(isLikedByMe));\n const [count, setCount] = useState(likeCount);\n const pending = like.isPending || unlike.isPending;\n\n // Keep in sync with the server state as long as no toggle is in flight.\n useEffect(() => {\n if (!pending) {\n setLiked(Boolean(isLikedByMe));\n setCount(likeCount);\n }\n }, [likeCount, isLikedByMe, pending]);\n\n const handleClick = () => {\n if (pending) return;\n const next = !liked;\n setLiked(next);\n setCount((current) => current + (next ? 1 : -1));\n const mutation = next ? like : unlike;\n mutation.mutate(lookId, {\n onSuccess: (look) => {\n setLiked(Boolean(look.isLikedByMe));\n setCount(look.likeCount);\n },\n onError: () => {\n setLiked(!next);\n setCount(likeCount);\n },\n });\n };\n\n return (\n <button\n type=\"button\"\n onClick={handleClick}\n disabled={pending}\n aria-pressed={liked}\n aria-label={liked ? 'Unlike this look' : 'Like this look'}\n className=\"inline-flex items-center gap-1 rounded-full bg-bg-surface/90 px-2 py-1 text-xs font-medium text-text-primary shadow-sm backdrop-blur transition-colors hover:bg-bg-surface disabled:opacity-60 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]\"\n >\n <Heart\n className={cn(\n 'h-3.5 w-3.5',\n liked ? 'fill-current text-accent-primary' : 'text-text-secondary'\n )}\n />\n <span className=\"tabular-nums\">{count}</span>\n </button>\n );\n};\n\n/** Optimistic, true-toggle save/bookmark (cooSaveLook / cooUnsaveLook). */\nconst SaveButton: FC<{ lookId: string; isSavedByMe?: boolean }> = ({ lookId, isSavedByMe }) => {\n const save = useSaveLook();\n const unsave = useUnsaveLook();\n const [saved, setSaved] = useState(Boolean(isSavedByMe));\n const pending = save.isPending || unsave.isPending;\n\n useEffect(() => {\n if (!pending) setSaved(Boolean(isSavedByMe));\n }, [isSavedByMe, pending]);\n\n const handleClick = () => {\n if (pending) return;\n const next = !saved;\n setSaved(next);\n const mutation = next ? save : unsave;\n mutation.mutate(lookId, {\n onSuccess: (look) => setSaved(Boolean(look.isSavedByMe)),\n onError: () => setSaved(!next),\n });\n };\n\n return (\n <button\n type=\"button\"\n onClick={handleClick}\n disabled={pending}\n aria-pressed={saved}\n aria-label={saved ? 'Remove from saved' : 'Save this look'}\n className=\"inline-flex items-center justify-center rounded-full bg-bg-surface/90 p-1.5 text-text-primary shadow-sm backdrop-blur transition-colors hover:bg-bg-surface disabled:opacity-60 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]\"\n >\n <Bookmark\n className={cn(\n 'h-3.5 w-3.5',\n saved ? 'fill-current text-accent-primary' : 'text-text-secondary'\n )}\n />\n </button>\n );\n};\n\ninterface LookCardProps {\n id: string;\n title: string;\n /** Occasion label/value (rendered as a pill; enum values are title-cased). */\n occasion: string;\n imageFileId?: string | null;\n likeCount?: number;\n isLikedByMe?: boolean;\n isSavedByMe?: boolean;\n onOpen: () => void;\n /** Show the hover like/save/add-to-lookbook overlay cluster. */\n showActions?: boolean;\n className?: string;\n}\n\nexport const LookCard: FC<LookCardProps> = ({\n id,\n title,\n occasion,\n imageFileId,\n likeCount,\n isLikedByMe,\n isSavedByMe,\n onOpen,\n showActions = false,\n className,\n}) => {\n return (\n <div\n className={cn(\n 'group relative overflow-hidden rounded-xl border border-border-seam bg-bg-surface transition-shadow hover:shadow-lg',\n className\n )}\n >\n <button\n type=\"button\"\n onClick={onOpen}\n aria-label={`Open look ${title}`}\n className=\"block w-full text-left focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-[var(--color-focus-ring)]\"\n >\n <Thumbnail\n icon={<Sparkles className=\"h-8 w-8\" />}\n seed={id}\n fileId={imageFileId}\n alt={title}\n className=\"aspect-[3/4] w-full rounded-none\"\n overlay={\n <div className=\"pointer-events-none absolute inset-x-0 bottom-0 flex flex-col gap-1.5 bg-gradient-to-t from-bg-canvas/90 via-bg-canvas/45 to-transparent p-3 pt-10\">\n <p className=\"truncate text-sm font-semibold text-text-primary\">{title}</p>\n <div className=\"flex items-center justify-between gap-2\">\n <span className=\"inline-flex items-center rounded-full bg-bg-surface/85 px-2 py-0.5 text-[11px] font-medium text-text-primary backdrop-blur\">\n {titleCase(occasion)}\n </span>\n {!showActions && typeof likeCount === 'number' && likeCount > 0 ? (\n <span className=\"inline-flex items-center gap-1 text-xs text-text-secondary\">\n <Heart className=\"h-3.5 w-3.5 fill-current text-accent-primary\" />\n <span className=\"tabular-nums\">{likeCount}</span>\n </span>\n ) : null}\n </div>\n </div>\n }\n />\n </button>\n\n {showActions ? (\n <div className=\"absolute right-2 top-2 flex items-center gap-1.5 opacity-100 transition-opacity duration-200 sm:opacity-0 sm:focus-within:opacity-100 sm:group-hover:opacity-100\">\n <LikeHeart lookId={id} likeCount={likeCount ?? 0} isLikedByMe={isLikedByMe} />\n <SaveButton lookId={id} isSavedByMe={isSavedByMe} />\n <AddToLookbookButton lookId={id} />\n </div>\n ) : null}\n </div>\n );\n};\n"],"mappings":";;;;;;;;;AA6BA,IAAM,KAA+E,EACnF,WACA,cACA,qBACI;CACJ,IAAM,IAAO,GAAa,EACpB,IAAS,GAAe,EACxB,CAAC,GAAO,KAAY,EAAS,EAAQ,EAAa,EAClD,CAAC,GAAO,KAAY,EAAS,EAAU,EACvC,IAAU,EAAK,aAAa,EAAO;AA4BzC,QAzBA,QAAgB;AACd,EA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D,CAAA;EACK,CAAA;GAmBA,KAA+B,EAC1C,OACA,UACA,aACA,gBACA,cACA,gBACA,gBACA,WACA,iBAAc,IACd,mBAGE,kBAAC,OAAD;CACE,WAAW,EACT,uHACA,EACD;WAJH,CAME,kBAAC,UAAD;EACE,MAAK;EACL,SAAS;EACT,cAAY,aAAa;EACzB,WAAU;YAEV,kBAAC,GAAD;GACE,MAAM,kBAAC,GAAD,EAAU,WAAU,WAAY,CAAA;GACtC,MAAM;GACN,QAAQ;GACR,KAAK;GACL,WAAU;GACV,SACE,kBAAC,OAAD;IAAK,WAAU;cAAf,CACE,kBAAC,KAAD;KAAG,WAAU;eAAoD;KAAU,CAAA,EAC3E,kBAAC,OAAD;KAAK,WAAU;eAAf,CACE,kBAAC,QAAD;MAAM,WAAU;gBACb,EAAU,EAAS;MACf,CAAA,EACN,CAAC,KAAe,OAAO,KAAc,YAAY,IAAY,IAC5D,kBAAC,QAAD;MAAM,WAAU;gBAAhB,CACE,kBAAC,GAAD,EAAO,WAAU,gDAAiD,CAAA,EAClE,kBAAC,QAAD;OAAM,WAAU;iBAAgB;OAAiB,CAAA,CAC5C;UACL,KACA;OACF;;GAER,CAAA;EACK,CAAA,EAER,IACC,kBAAC,OAAD;EAAK,WAAU;YAAf;GACE,kBAAC,GAAD;IAAW,QAAQ;IAAI,WAAW,KAAa;IAAgB;IAAe,CAAA;GAC9E,kBAAC,GAAD;IAAY,QAAQ;IAAiB;IAAe,CAAA;GACpD,kBAAC,GAAD,EAAqB,QAAQ,GAAM,CAAA;GAC/B;MACJ,KACA"}
@@ -2,7 +2,7 @@
2
2
  * Hooks Index
3
3
  * @module coolandlovely/hooks
4
4
  */
5
- export { useBrands, useBrand, useCreateBrand, useUpdateBrand, useTransitionBrand, useArchiveBrand, useCollections, useCollection, useCreateCollection, useUpdateCollection, usePublishCollection, useStyleItems, useStyleItem, useCreateStyleItem, useUpdateStyleItem, useArchiveStyleItem, useLooks, useLooksWithItems, useLook, useCreateLook, useUpdateLook, usePublishLook, useLikeLook, useDeleteLook, useCollaborations, useCollaboration, useCreateCollaboration, useTransitionCollaboration, useWardrobeItems, useCreateWardrobeItem, useUpdateWardrobeItem, useLogWardrobeWear, useRemoveWardrobeItem, useMyStyleProfile, useUpsertStyleProfile, useLookbooks, useLookbook, useCreateLookbook, useAddLookbookEntry, useRemoveLookbookEntry, useIsFollowing, useFollow, useUnfollow, useMyFollowing, useMyFollowers, } from './useCoolAndLovelyApi';
5
+ export { useBrands, useBrand, useCreateBrand, useUpdateBrand, useTransitionBrand, useArchiveBrand, useCollections, useCollection, useCreateCollection, useUpdateCollection, usePublishCollection, useStyleItems, useStyleItem, useCreateStyleItem, useUpdateStyleItem, useArchiveStyleItem, useLooks, useLooksWithItems, useLook, useCreateLook, useUpdateLook, usePublishLook, useLikeLook, useUnlikeLook, useSaveLook, useUnsaveLook, useDeleteLook, useCollaborations, useCollaboration, useCreateCollaboration, useTransitionCollaboration, useWardrobeItems, useCreateWardrobeItem, useUpdateWardrobeItem, useLogWardrobeWear, useRemoveWardrobeItem, useMyStyleProfile, useUpsertStyleProfile, useLookbooks, useLookbook, useCreateLookbook, useAddLookbookEntry, useRemoveLookbookEntry, useIsFollowing, useFollow, useUnfollow, useMyFollowing, useMyFollowers, } from './useCoolAndLovelyApi';
6
6
  export type { ListBrandsArgs, ListCollectionsArgs, ListStyleItemsArgs, ListLooksArgs, ListCollaborationsArgs, ListWardrobeArgs, } from './useCoolAndLovelyApi';
7
7
  export { uploadImageToFiles, useFileUrl, COO_FILE_FOLDERS } from './useFiles';
8
8
  export type { UploadedImage, CooFileFolder } from './useFiles';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/coolandlovely/hooks/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAEL,SAAS,EACT,QAAQ,EACR,cAAc,EACd,cAAc,EACd,kBAAkB,EAClB,eAAe,EAEf,cAAc,EACd,aAAa,EACb,mBAAmB,EACnB,mBAAmB,EACnB,oBAAoB,EAEpB,aAAa,EACb,YAAY,EACZ,kBAAkB,EAClB,kBAAkB,EAClB,mBAAmB,EAEnB,QAAQ,EACR,iBAAiB,EACjB,OAAO,EACP,aAAa,EACb,aAAa,EACb,cAAc,EACd,WAAW,EACX,aAAa,EAEb,iBAAiB,EACjB,gBAAgB,EAChB,sBAAsB,EACtB,0BAA0B,EAE1B,gBAAgB,EAChB,qBAAqB,EACrB,qBAAqB,EACrB,kBAAkB,EAClB,qBAAqB,EAErB,iBAAiB,EACjB,qBAAqB,EAErB,YAAY,EACZ,WAAW,EACX,iBAAiB,EACjB,mBAAmB,EACnB,sBAAsB,EAEtB,cAAc,EACd,SAAS,EACT,WAAW,EACX,cAAc,EACd,cAAc,GACf,MAAM,uBAAuB,CAAC;AAE/B,YAAY,EACV,cAAc,EACd,mBAAmB,EACnB,kBAAkB,EAClB,aAAa,EACb,sBAAsB,EACtB,gBAAgB,GACjB,MAAM,uBAAuB,CAAC;AAG/B,OAAO,EAAE,kBAAkB,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAC9E,YAAY,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAG/D,OAAO,EAAE,iBAAiB,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AACjE,YAAY,EAAE,iBAAiB,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/coolandlovely/hooks/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAEL,SAAS,EACT,QAAQ,EACR,cAAc,EACd,cAAc,EACd,kBAAkB,EAClB,eAAe,EAEf,cAAc,EACd,aAAa,EACb,mBAAmB,EACnB,mBAAmB,EACnB,oBAAoB,EAEpB,aAAa,EACb,YAAY,EACZ,kBAAkB,EAClB,kBAAkB,EAClB,mBAAmB,EAEnB,QAAQ,EACR,iBAAiB,EACjB,OAAO,EACP,aAAa,EACb,aAAa,EACb,cAAc,EACd,WAAW,EACX,aAAa,EACb,WAAW,EACX,aAAa,EACb,aAAa,EAEb,iBAAiB,EACjB,gBAAgB,EAChB,sBAAsB,EACtB,0BAA0B,EAE1B,gBAAgB,EAChB,qBAAqB,EACrB,qBAAqB,EACrB,kBAAkB,EAClB,qBAAqB,EAErB,iBAAiB,EACjB,qBAAqB,EAErB,YAAY,EACZ,WAAW,EACX,iBAAiB,EACjB,mBAAmB,EACnB,sBAAsB,EAEtB,cAAc,EACd,SAAS,EACT,WAAW,EACX,cAAc,EACd,cAAc,GACf,MAAM,uBAAuB,CAAC;AAE/B,YAAY,EACV,cAAc,EACd,mBAAmB,EACnB,kBAAkB,EAClB,aAAa,EACb,sBAAsB,EACtB,gBAAgB,GACjB,MAAM,uBAAuB,CAAC;AAG/B,OAAO,EAAE,kBAAkB,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAC9E,YAAY,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAG/D,OAAO,EAAE,iBAAiB,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AACjE,YAAY,EAAE,iBAAiB,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAC"}
@@ -60,6 +60,9 @@ export declare const useUpdateLook: () => import('@tanstack/react-query').UseMut
60
60
  }, unknown>;
61
61
  export declare const usePublishLook: () => import('@tanstack/react-query').UseMutationResult<CooLook, Error, string, unknown>;
62
62
  export declare const useLikeLook: () => import('@tanstack/react-query').UseMutationResult<CooLook, Error, string, unknown>;
63
+ export declare const useUnlikeLook: () => import('@tanstack/react-query').UseMutationResult<CooLook, Error, string, unknown>;
64
+ export declare const useSaveLook: () => import('@tanstack/react-query').UseMutationResult<CooLook, Error, string, unknown>;
65
+ export declare const useUnsaveLook: () => import('@tanstack/react-query').UseMutationResult<CooLook, Error, string, unknown>;
63
66
  export declare const useDeleteLook: () => import('@tanstack/react-query').UseMutationResult<boolean, Error, string, unknown>;
64
67
  export interface ListCollaborationsArgs {
65
68
  brandId?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"useCoolAndLovelyApi.d.ts","sourceRoot":"","sources":["../../../src/coolandlovely/hooks/useCoolAndLovelyApi.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAWH,OAAO,KAAK,EACV,wBAAwB,EACxB,QAAQ,EACR,kBAAkB,EAClB,cAAc,EACd,gBAAgB,EAChB,sBAAsB,EACtB,aAAa,EACb,mBAAmB,EACnB,mBAAmB,EACnB,2BAA2B,EAC3B,wBAAwB,EACxB,kBAAkB,EAClB,sBAAsB,EACtB,uBAAuB,EACvB,0BAA0B,EAC1B,OAAO,EACP,iBAAiB,EACjB,eAAe,EACf,WAAW,EACX,gBAAgB,EAChB,YAAY,EACZ,sBAAsB,EACtB,kBAAkB,EAClB,eAAe,EACf,mBAAmB,EACnB,wBAAwB,EACxB,kBAAkB,EAClB,uBAAuB,EACvB,0BAA0B,EAC1B,0BAA0B,EAC1B,eAAe,EACf,iBAAiB,EACjB,eAAe,EAChB,MAAM,UAAU,CAAC;AAkGlB,MAAM,WAAW,cAAc;IAC7B,MAAM,CAAC,EAAE,cAAc,CAAC;IACxB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,eAAe,CAAC;CAC9B;AAED,eAAO,MAAM,SAAS,GAAI,OAAM,cAAmB,uFAsBlD,CAAC;AAEF,eAAO,MAAM,QAAQ,GAAI,IAAI,MAAM,GAAG,SAAS,oFAoB9C,CAAC;AAEF,eAAO,MAAM,cAAc,wGAkB1B,CAAC;AAEF,eAAO,MAAM,cAAc;QAIiB,MAAM;WAAS,mBAAmB;WAe7E,CAAC;AAEF,eAAO,MAAM,kBAAkB;QAIc,MAAM;YAAU,cAAc;WAe1E,CAAC;AAEF,eAAO,MAAM,eAAe,0FAgB3B,CAAC;AAMF,MAAM,WAAW,mBAAmB;IAClC,OAAO,CAAC,EAAE,MAAM,CAAC;IACj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YF,yDAAyD;AACzD,eAAO,MAAM,cAAc,GAAI,YAAY,MAAM,GAAG,SAAS,mEAc5D,CAAC;AAEF,eAAO,MAAM,SAAS,0FAmBrB,CAAC;AAEF,eAAO,MAAM,WAAW,0FAmBvB,CAAC;AAEF,mDAAmD;AACnD,eAAO,MAAM,cAAc,yFAa1B,CAAC;AAEF,qDAAqD;AACrD,eAAO,MAAM,cAAc,yFAa1B,CAAC;AAEF,eAAO,MAAM,WAAW,GAAI,IAAI,MAAM,GAAG,SAAS,uFAmBjD,CAAC"}
1
+ {"version":3,"file":"useCoolAndLovelyApi.d.ts","sourceRoot":"","sources":["../../../src/coolandlovely/hooks/useCoolAndLovelyApi.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAWH,OAAO,KAAK,EACV,wBAAwB,EACxB,QAAQ,EACR,kBAAkB,EAClB,cAAc,EACd,gBAAgB,EAChB,sBAAsB,EACtB,aAAa,EACb,mBAAmB,EACnB,mBAAmB,EACnB,2BAA2B,EAC3B,wBAAwB,EACxB,kBAAkB,EAClB,sBAAsB,EACtB,uBAAuB,EACvB,0BAA0B,EAC1B,OAAO,EACP,iBAAiB,EACjB,eAAe,EACf,WAAW,EACX,gBAAgB,EAChB,YAAY,EACZ,sBAAsB,EACtB,kBAAkB,EAClB,eAAe,EACf,mBAAmB,EACnB,wBAAwB,EACxB,kBAAkB,EAClB,uBAAuB,EACvB,0BAA0B,EAC1B,0BAA0B,EAC1B,eAAe,EACf,iBAAiB,EACjB,eAAe,EAChB,MAAM,UAAU,CAAC;AAmGlB,MAAM,WAAW,cAAc;IAC7B,MAAM,CAAC,EAAE,cAAc,CAAC;IACxB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,eAAe,CAAC;CAC9B;AAED,eAAO,MAAM,SAAS,GAAI,OAAM,cAAmB,uFAsBlD,CAAC;AAEF,eAAO,MAAM,QAAQ,GAAI,IAAI,MAAM,GAAG,SAAS,oFAoB9C,CAAC;AAE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pF,CAAC;AAEF,eAAO,MAAM,kBAAkB,kGAkB9B,CAAC;AAEF,eAAO,MAAM,qBAAqB,0FAgBjC,CAAC;AAMF,eAAO,MAAM,iBAAiB,8FAa7B,CAAC;AAEF,eAAO,MAAM,qBAAqB,sHAkBjC,CAAC;AAMF,eAAO,MAAM,YAAY,GAAI,UAAU,MAAM,kFAkB5C,CAAC;AAEF,eAAO,MAAM,iBAAiB,8GAkB7B,CAAC;AAEF,eAAO,MAAM,mBAAmB;QAKgC,MAAM;gBAAc,MAAM;4CAiBzF,CAAC;AAEF,eAAO,MAAM,sBAAsB,0FAiBlC,CAAC;AAYF,yDAAyD;AACzD,eAAO,MAAM,cAAc,GAAI,YAAY,MAAM,GAAG,SAAS,mEAc5D,CAAC;AAEF,eAAO,MAAM,SAAS,0FAmBrB,CAAC;AAEF,eAAO,MAAM,WAAW,0FAmBvB,CAAC;AAEF,mDAAmD;AACnD,eAAO,MAAM,cAAc,yFAa1B,CAAC;AAEF,qDAAqD;AACrD,eAAO,MAAM,cAAc,yFAa1B,CAAC;AAEF,eAAO,MAAM,WAAW,GAAI,IAAI,MAAM,GAAG,SAAS,uFAmBjD,CAAC"}
@@ -15,7 +15,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
15
15
  if (r.errors?.length) throw Error(r.errors[0]?.message ?? "GraphQL request failed");
16
16
  if (!r.data) throw Error("GraphQL response did not include data");
17
17
  return /^\s*mutation\b/.test(e) && a(), r.data;
18
- }, c = "\n id workspaceId name handle tagline bio aesthetics tags websiteUrl\n isFeatured status logo { id } cover { id } createdAt updatedAt\n", l = "\n id workspaceId brandId name description season status tags\n cover { id } publishAt endAt createdAt updatedAt\n", u = "\n id workspaceId brandId collectionId name description category status\n sku price currency colours sizes materials tags image { id }\n createdAt updatedAt\n", d = "\n id workspaceId authorId title caption occasion visibility isFeatured\n likeCount saveCount collaborationId image { id } tags publishedAt\n createdAt updatedAt\n", f = "\n id workspaceId lookId styleItemId position styling createdAt updatedAt\n styleItem { id name category price currency brand { id name handle } image { id } }\n", p = "\n id workspaceId brandId creatorId collectionId title brief role status\n compensation currency tags startDate endDate publishedAt createdAt updatedAt\n", m = "\n id workspaceId profileId name category source brandName colour size notes\n styleItemId timesWorn lastWornAt tags image { id } createdAt updatedAt\n", h = "\n id workspaceId ownerId displayName bio visibility stylePreferences\n palette favouriteBrands sizes createdAt updatedAt\n isFollowedByMe followerCount followingCount\n", g = "\n id workspaceId ownerId profileId name description visibility tags\n cover { id } createdAt updatedAt\n", _ = (t = {}) => {
18
+ }, c = "\n id workspaceId name handle tagline bio aesthetics tags websiteUrl\n isFeatured status logo { id } cover { id } createdAt updatedAt\n", l = "\n id workspaceId brandId name description season status tags\n cover { id } publishAt endAt createdAt updatedAt\n", u = "\n id workspaceId brandId collectionId name description category status\n sku price currency colours sizes materials tags image { id }\n createdAt updatedAt\n", d = "\n id workspaceId authorId title caption occasion visibility isFeatured\n likeCount saveCount collaborationId image { id } tags publishedAt\n createdAt updatedAt isLikedByMe isSavedByMe\n", f = "\n id workspaceId lookId styleItemId position styling createdAt updatedAt\n styleItem { id name category price currency brand { id name handle } image { id } }\n", p = "\n id workspaceId brandId creatorId collectionId title brief role status\n compensation currency tags startDate endDate publishedAt createdAt updatedAt\n", m = "\n id workspaceId profileId name category source brandName colour size notes\n styleItemId purchasePrice currency costPerWear timesWorn lastWornAt tags\n image { id } createdAt updatedAt\n", h = "\n id workspaceId ownerId displayName bio visibility stylePreferences\n palette favouriteBrands sizes createdAt updatedAt\n isFollowedByMe followerCount followingCount\n", g = "\n id workspaceId ownerId profileId name description visibility tags\n cover { id } createdAt updatedAt\n", _ = (t = {}) => {
19
19
  let { apiGatewayUrl: r } = e();
20
20
  return n({
21
21
  queryKey: [
@@ -374,6 +374,42 @@ var o = "coolandlovely", s = async (e, t, n) => {
374
374
  }
375
375
  });
376
376
  }, R = () => {
377
+ let n = r(), { apiGatewayUrl: i } = e();
378
+ return t({
379
+ mutationFn: async (e) => (await s(`mutation CooUnlikeLook($id: ID!) { cooUnlikeLook(id: $id) { ${d} } }`, { id: e }, i)).cooUnlikeLook,
380
+ onSuccess: (e) => {
381
+ n.invalidateQueries({ queryKey: [o, "looks"] }), n.invalidateQueries({ queryKey: [o, "looks-with-items"] }), n.invalidateQueries({ queryKey: [
382
+ o,
383
+ "look",
384
+ e.id
385
+ ] });
386
+ }
387
+ });
388
+ }, z = () => {
389
+ let n = r(), { apiGatewayUrl: i } = e();
390
+ return t({
391
+ mutationFn: async (e) => (await s(`mutation CooSaveLook($id: ID!) { cooSaveLook(id: $id) { ${d} } }`, { id: e }, i)).cooSaveLook,
392
+ onSuccess: (e) => {
393
+ n.invalidateQueries({ queryKey: [o, "looks"] }), n.invalidateQueries({ queryKey: [o, "looks-with-items"] }), n.invalidateQueries({ queryKey: [
394
+ o,
395
+ "look",
396
+ e.id
397
+ ] });
398
+ }
399
+ });
400
+ }, B = () => {
401
+ let n = r(), { apiGatewayUrl: i } = e();
402
+ return t({
403
+ mutationFn: async (e) => (await s(`mutation CooUnsaveLook($id: ID!) { cooUnsaveLook(id: $id) { ${d} } }`, { id: e }, i)).cooUnsaveLook,
404
+ onSuccess: (e) => {
405
+ n.invalidateQueries({ queryKey: [o, "looks"] }), n.invalidateQueries({ queryKey: [o, "looks-with-items"] }), n.invalidateQueries({ queryKey: [
406
+ o,
407
+ "look",
408
+ e.id
409
+ ] });
410
+ }
411
+ });
412
+ }, V = () => {
377
413
  let n = r(), { apiGatewayUrl: i } = e();
378
414
  return t({
379
415
  mutationFn: async (e) => (await s("mutation CooDeleteLook($id: ID!) { cooDeleteLook(id: $id) }", { id: e }, i)).cooDeleteLook,
@@ -381,7 +417,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
381
417
  n.invalidateQueries({ queryKey: [o, "looks"] }), n.invalidateQueries({ queryKey: [o, "looks-with-items"] });
382
418
  }
383
419
  });
384
- }, z = (t = {}) => {
420
+ }, H = (t = {}) => {
385
421
  let { apiGatewayUrl: r } = e();
386
422
  return n({
387
423
  queryKey: [
@@ -400,7 +436,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
400
436
  status: t.status
401
437
  }, r)).cooListCollaborations
402
438
  });
403
- }, B = (t) => {
439
+ }, U = (t) => {
404
440
  let { apiGatewayUrl: r } = e();
405
441
  return n({
406
442
  queryKey: [
@@ -417,7 +453,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
417
453
  }`, { id: t }, r)).cooCollaboration,
418
454
  enabled: !!t
419
455
  });
420
- }, V = () => {
456
+ }, W = () => {
421
457
  let n = r(), { apiGatewayUrl: i } = e();
422
458
  return t({
423
459
  mutationFn: async (e) => (await s(`mutation CooCreateCollaboration($input: CooCreateCollaborationInput!) {
@@ -427,7 +463,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
427
463
  n.invalidateQueries({ queryKey: [o, "collaborations"] });
428
464
  }
429
465
  });
430
- }, H = () => {
466
+ }, G = () => {
431
467
  let n = r(), { apiGatewayUrl: i } = e();
432
468
  return t({
433
469
  mutationFn: async ({ id: e, status: t }) => (await s(`mutation CooTransitionCollaboration($id: ID!, $status: CooCollaborationStatus!) {
@@ -444,7 +480,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
444
480
  ] });
445
481
  }
446
482
  });
447
- }, U = (t = {}) => {
483
+ }, K = (t = {}) => {
448
484
  let { apiGatewayUrl: r } = e();
449
485
  return n({
450
486
  queryKey: [
@@ -459,7 +495,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
459
495
  source: t.source
460
496
  }, r)).cooListWardrobeItems
461
497
  });
462
- }, W = () => {
498
+ }, q = () => {
463
499
  let n = r(), { apiGatewayUrl: i } = e();
464
500
  return t({
465
501
  mutationFn: async (e) => (await s(`mutation CooCreateWardrobeItem($input: CooCreateWardrobeItemInput!) {
@@ -469,7 +505,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
469
505
  n.invalidateQueries({ queryKey: [o, "wardrobe"] });
470
506
  }
471
507
  });
472
- }, G = () => {
508
+ }, J = () => {
473
509
  let n = r(), { apiGatewayUrl: i } = e();
474
510
  return t({
475
511
  mutationFn: async (e) => (await s(`mutation CooLogWardrobeWear($id: ID!) {
@@ -479,7 +515,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
479
515
  n.invalidateQueries({ queryKey: [o, "wardrobe"] });
480
516
  }
481
517
  });
482
- }, K = () => {
518
+ }, Y = () => {
483
519
  let n = r(), { apiGatewayUrl: i } = e();
484
520
  return t({
485
521
  mutationFn: async (e) => (await s("mutation CooRemoveWardrobeItem($id: ID!) { cooRemoveWardrobeItem(id: $id) }", { id: e }, i)).cooRemoveWardrobeItem,
@@ -487,13 +523,13 @@ var o = "coolandlovely", s = async (e, t, n) => {
487
523
  n.invalidateQueries({ queryKey: [o, "wardrobe"] });
488
524
  }
489
525
  });
490
- }, q = () => {
526
+ }, X = () => {
491
527
  let { apiGatewayUrl: t } = e();
492
528
  return n({
493
529
  queryKey: [o, "my-style-profile"],
494
530
  queryFn: async () => (await s(`query CooMyStyleProfile { cooMyStyleProfile { ${h} } }`, {}, t)).cooMyStyleProfile
495
531
  });
496
- }, J = () => {
532
+ }, Z = () => {
497
533
  let n = r(), { apiGatewayUrl: i } = e();
498
534
  return t({
499
535
  mutationFn: async (e) => (await s(`mutation CooUpsertStyleProfile($input: CooUpsertStyleProfileInput!) {
@@ -503,7 +539,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
503
539
  n.invalidateQueries({ queryKey: [o, "my-style-profile"] });
504
540
  }
505
541
  });
506
- }, Y = (t) => {
542
+ }, Q = (t) => {
507
543
  let { apiGatewayUrl: r } = e();
508
544
  return n({
509
545
  queryKey: [
@@ -518,7 +554,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
518
554
  }
519
555
  }`, { ownerId: t }, r)).cooListLookbooks
520
556
  });
521
- }, X = () => {
557
+ }, $ = () => {
522
558
  let n = r(), { apiGatewayUrl: i } = e();
523
559
  return t({
524
560
  mutationFn: async (e) => (await s(`mutation CooCreateLookbook($input: CooCreateLookbookInput!) {
@@ -528,7 +564,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
528
564
  n.invalidateQueries({ queryKey: [o, "lookbooks"] });
529
565
  }
530
566
  });
531
- }, Z = () => {
567
+ }, te = () => {
532
568
  let n = r(), { apiGatewayUrl: i } = e();
533
569
  return t({
534
570
  mutationFn: async (e) => (await s("mutation CooAddLookbookEntry($input: CooAddLookbookEntryInput!) {\n cooAddLookbookEntry(input: $input) {\n id lookbookId lookId styleItemId note position createdAt updatedAt\n }\n }", { input: e }, i)).cooAddLookbookEntry,
@@ -540,7 +576,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
540
576
  ] });
541
577
  }
542
578
  });
543
- }, Q = () => {
579
+ }, ne = () => {
544
580
  let n = r(), { apiGatewayUrl: i } = e();
545
581
  return t({
546
582
  mutationFn: async (e) => (await s("mutation CooRemoveLookbookEntry($id: ID!) { cooRemoveLookbookEntry(id: $id) }", { id: e }, i)).cooRemoveLookbookEntry,
@@ -548,7 +584,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
548
584
  n.invalidateQueries({ queryKey: [o, "lookbooks"] }), n.invalidateQueries({ queryKey: [o, "lookbook"] });
549
585
  }
550
586
  });
551
- }, $ = "\n id workspaceId ownerId displayName bio visibility\n stylePreferences palette favouriteBrands\n isFollowedByMe followerCount followingCount\n", te = (t) => {
587
+ }, re = "\n id workspaceId ownerId displayName bio visibility\n stylePreferences palette favouriteBrands\n isFollowedByMe followerCount followingCount\n", ie = (t) => {
552
588
  let { apiGatewayUrl: r } = e();
553
589
  return n({
554
590
  queryKey: [
@@ -559,7 +595,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
559
595
  enabled: !!t,
560
596
  queryFn: async () => (await s("query CooIsFollowing($followeeId: ID!) { cooIsFollowing(followeeId: $followeeId) }", { followeeId: t }, r)).cooIsFollowing
561
597
  });
562
- }, ne = () => {
598
+ }, ae = () => {
563
599
  let n = r(), { apiGatewayUrl: i } = e();
564
600
  return t({
565
601
  mutationFn: async (e) => (await s("mutation CooFollow($followeeId: ID!) { cooFollow(followeeId: $followeeId) }", { followeeId: e }, i)).cooFollow,
@@ -571,7 +607,7 @@ var o = "coolandlovely", s = async (e, t, n) => {
571
607
  ] }), n.invalidateQueries({ queryKey: [o, "my-following"] }), n.invalidateQueries({ queryKey: [o, "my-followers"] }), n.invalidateQueries({ queryKey: [o, "my-style-profile"] });
572
608
  }
573
609
  });
574
- }, re = () => {
610
+ }, oe = () => {
575
611
  let n = r(), { apiGatewayUrl: i } = e();
576
612
  return t({
577
613
  mutationFn: async (e) => (await s("mutation CooUnfollow($followeeId: ID!) { cooUnfollow(followeeId: $followeeId) }", { followeeId: e }, i)).cooUnfollow,
@@ -583,13 +619,13 @@ var o = "coolandlovely", s = async (e, t, n) => {
583
619
  ] }), n.invalidateQueries({ queryKey: [o, "my-following"] }), n.invalidateQueries({ queryKey: [o, "my-followers"] }), n.invalidateQueries({ queryKey: [o, "my-style-profile"] });
584
620
  }
585
621
  });
586
- }, ie = () => {
622
+ }, se = () => {
587
623
  let { apiGatewayUrl: t } = e();
588
624
  return n({
589
625
  queryKey: [o, "my-following"],
590
- queryFn: async () => (await s(`query CooMyFollowing { cooMyFollowing { ${$} } }`, {}, t)).cooMyFollowing
626
+ queryFn: async () => (await s(`query CooMyFollowing { cooMyFollowing { ${re} } }`, {}, t)).cooMyFollowing
591
627
  });
592
- }, ae = (t) => {
628
+ }, ce = (t) => {
593
629
  let { apiGatewayUrl: r } = e();
594
630
  return n({
595
631
  queryKey: [
@@ -607,6 +643,6 @@ var o = "coolandlovely", s = async (e, t, n) => {
607
643
  });
608
644
  };
609
645
  //#endregion
610
- export { Z as useAddLookbookEntry, j as useArchiveStyleItem, v as useBrand, _ as useBrands, B as useCollaboration, z as useCollaborations, C as useCollection, S as useCollections, y as useCreateBrand, V as useCreateCollaboration, w as useCreateCollection, F as useCreateLook, X as useCreateLookbook, k as useCreateStyleItem, W as useCreateWardrobeItem, R as useDeleteLook, ne as useFollow, te as useIsFollowing, L as useLikeLook, G as useLogWardrobeWear, N as useLook, ae as useLookbook, Y as useLookbooks, M as useLooks, P as useLooksWithItems, ie as useMyFollowing, q as useMyStyleProfile, E as usePublishCollection, ee as usePublishLook, Q as useRemoveLookbookEntry, K as useRemoveWardrobeItem, O as useStyleItem, D as useStyleItems, x as useTransitionBrand, H as useTransitionCollaboration, re as useUnfollow, b as useUpdateBrand, T as useUpdateCollection, I as useUpdateLook, A as useUpdateStyleItem, J as useUpsertStyleProfile, U as useWardrobeItems };
646
+ export { te as useAddLookbookEntry, j as useArchiveStyleItem, v as useBrand, _ as useBrands, U as useCollaboration, H as useCollaborations, C as useCollection, S as useCollections, y as useCreateBrand, W as useCreateCollaboration, w as useCreateCollection, F as useCreateLook, $ as useCreateLookbook, k as useCreateStyleItem, q as useCreateWardrobeItem, V as useDeleteLook, ae as useFollow, ie as useIsFollowing, L as useLikeLook, J as useLogWardrobeWear, N as useLook, ce as useLookbook, Q as useLookbooks, M as useLooks, P as useLooksWithItems, se as useMyFollowing, X as useMyStyleProfile, E as usePublishCollection, ee as usePublishLook, ne as useRemoveLookbookEntry, Y as useRemoveWardrobeItem, z as useSaveLook, O as useStyleItem, D as useStyleItems, x as useTransitionBrand, G as useTransitionCollaboration, oe as useUnfollow, R as useUnlikeLook, B as useUnsaveLook, b as useUpdateBrand, T as useUpdateCollection, I as useUpdateLook, A as useUpdateStyleItem, Z as useUpsertStyleProfile, K as useWardrobeItems };
611
647
 
612
648
  //# sourceMappingURL=useCoolAndLovelyApi.js.map