@photoroom/ui 0.1.529 → 0.1.531

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.
@@ -5,6 +5,7 @@ export type SideNavigationItemProps = Readonly<{
5
5
  isSelected?: boolean;
6
6
  icon?: React.ComponentType<React.ComponentProps<"svg">> | React.ReactElement;
7
7
  activeIcon?: React.ComponentType<React.ComponentProps<"svg">> | React.ReactElement;
8
+ trailingElement?: React.ReactNode;
8
9
  }>;
9
10
  export declare const SideNavigationItem: PolymorphicComponent<"button", SideNavigationItemProps>;
10
11
  //# sourceMappingURL=SideNavigationItem.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SideNavigationItem.d.ts","sourceRoot":"","sources":["../../../../../src/components/navigation/SideNavigation/SideNavigationItem/SideNavigationItem.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,oBAAoB,EAAoB,MAAM,sBAAsB,CAAC;AAE9E,MAAM,MAAM,uBAAuB,GAAG,QAAQ,CAAC;IAC7C,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,SAAS,GAAG,UAAU,CAAC;IACjC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,IAAI,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC,GAAG,KAAK,CAAC,YAAY,CAAC;IAC7E,UAAU,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC,GAAG,KAAK,CAAC,YAAY,CAAC;CACpF,CAAC,CAAC;AAEH,eAAO,MAAM,kBAAkB,EA4CzB,oBAAoB,CAAC,QAAQ,EAAE,uBAAuB,CAAC,CAAC"}
1
+ {"version":3,"file":"SideNavigationItem.d.ts","sourceRoot":"","sources":["../../../../../src/components/navigation/SideNavigation/SideNavigationItem/SideNavigationItem.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,oBAAoB,EAAoB,MAAM,sBAAsB,CAAC;AAE9E,MAAM,MAAM,uBAAuB,GAAG,QAAQ,CAAC;IAC7C,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,SAAS,GAAG,UAAU,CAAC;IACjC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,IAAI,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC,GAAG,KAAK,CAAC,YAAY,CAAC;IAC7E,UAAU,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC,GAAG,KAAK,CAAC,YAAY,CAAC;IACnF,eAAe,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CACnC,CAAC,CAAC;AAEH,eAAO,MAAM,kBAAkB,EA8CzB,oBAAoB,CAAC,QAAQ,EAAE,uBAAuB,CAAC,CAAC"}
package/index.mjs CHANGED
@@ -49934,54 +49934,62 @@ var Nhe = W(["rounded-400 flex flex-1 grow flex-col items-center justify-center
49934
49934
  x5.displayName = "SideNavigationHeader";
49935
49935
  //#endregion
49936
49936
  //#region src/components/navigation/SideNavigation/SideNavigationItem/SideNavigationItem.tsx
49937
- var S5 = (({ isSelected: e = !1, label: n, variant: r = "default", disabled: i, icon: a, activeIcon: o = a, as: s, className: c, ref: l, ...u }) => {
49938
- let d = {
49937
+ var S5 = (({ isSelected: e = !1, label: n, variant: r = "default", disabled: i, icon: a, activeIcon: o = a, trailingElement: s, as: c, className: l, ref: u, ...d }) => {
49938
+ let f = {
49939
49939
  variant: r,
49940
49940
  label: n,
49941
49941
  activeIcon: o,
49942
- icon: a
49942
+ icon: a,
49943
+ trailingElement: s
49943
49944
  };
49944
- return s === void 0 ? /* @__PURE__ */ t("button", {
49945
- ref: l,
49946
- className: U("group flex w-full outline-hidden", i && "opacity-30", c),
49947
- ...u,
49945
+ return c === void 0 ? /* @__PURE__ */ t("button", {
49946
+ ref: u,
49947
+ className: U("group flex w-full outline-hidden", i && "opacity-30", l),
49948
+ ...d,
49948
49949
  children: /* @__PURE__ */ t(C5, {
49949
- ...d,
49950
+ ...f,
49950
49951
  isActive: e
49951
49952
  })
49952
- }) : /* @__PURE__ */ t(s, {
49953
- ref: l,
49954
- className: U("group flex w-full outline-hidden", i && "opacity-30", c),
49955
- ...u,
49953
+ }) : /* @__PURE__ */ t(c, {
49954
+ ref: u,
49955
+ className: U("group flex w-full outline-hidden", i && "opacity-30", l),
49956
+ ...d,
49956
49957
  children: ({ isActive: n }) => /* @__PURE__ */ t(C5, {
49957
- ...d,
49958
+ ...f,
49958
49959
  isActive: n || e
49959
49960
  })
49960
49961
  });
49961
49962
  });
49962
49963
  S5.displayName = "SideNavigationItem";
49963
- var C5 = ({ variant: e = "default", label: r, isActive: i, activeIcon: a, icon: o }) => {
49964
- let s = i ? a : o;
49964
+ var C5 = ({ variant: e = "default", label: r, isActive: i, activeIcon: a, icon: o, trailingElement: s }) => {
49965
+ let c = i ? a : o;
49965
49966
  return /* @__PURE__ */ n("span", {
49966
49967
  className: H("flex w-full flex-row items-center gap-3 py-[10px] pe-3", "group-focus-visible:ring-misc-focus-indicator group-focus-visible:misc-border-size-focus-ring group-disabled:opacity-30", "rounded-500 cursor-pointer outline-hidden transition duration-200", {
49967
49968
  "text-content-primary": !i && e === "default",
49968
49969
  "text-content-positive": !i && e === "positive",
49969
49970
  "hover:bg-background-borderless-subdued-hover active:bg-background-borderless-subdued-down group-focus-visible:bg-background-borderless-subdued-hover bg-transparent": !i,
49970
49971
  "bg-background-subdued text-content-primary": i,
49971
- "ps-[10px]": s,
49972
- "ps-3": !s
49972
+ "ps-[10px]": c,
49973
+ "ps-3": !c
49973
49974
  }),
49974
- children: [!!s && (be(s) ? /* @__PURE__ */ t("span", {
49975
- className: "flex h-5 w-5 shrink-0 items-center justify-center",
49976
- children: s
49977
- }) : /* @__PURE__ */ t(s, { className: H("h-5 w-5 shrink-0 transition duration-200", {
49978
- "fill-content-secondary": !i && e === "default",
49979
- "fill-content-positive": !i && e === "positive",
49980
- "fill-content-primary": i
49981
- }) })), /* @__PURE__ */ t("span", {
49982
- className: "component-500 text-start",
49983
- children: r
49984
- })]
49975
+ children: [
49976
+ !!c && (be(c) ? /* @__PURE__ */ t("span", {
49977
+ className: "flex h-5 w-5 shrink-0 items-center justify-center",
49978
+ children: c
49979
+ }) : /* @__PURE__ */ t(c, { className: H("h-5 w-5 shrink-0 transition duration-200", {
49980
+ "fill-content-secondary": !i && e === "default",
49981
+ "fill-content-positive": !i && e === "positive",
49982
+ "fill-content-primary": i
49983
+ }) })),
49984
+ /* @__PURE__ */ t("span", {
49985
+ className: "component-500 min-w-0 text-start",
49986
+ children: r
49987
+ }),
49988
+ !!s && /* @__PURE__ */ t("span", {
49989
+ className: "ms-auto flex shrink-0 items-center",
49990
+ children: s
49991
+ })
49992
+ ]
49985
49993
  });
49986
49994
  }, Ihe = W(["h-5"], { variants: { size: {
49987
49995
  small: "w-[75px]",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@photoroom/ui",
3
- "version": "0.1.529",
3
+ "version": "0.1.531",
4
4
  "private": false,
5
5
  "description": "Photoroom design system components",
6
6
  "sideEffects": [