@pollinations/ui 0.1.0-alpha.5 → 0.1.0-alpha.7

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.
package/dist/index.d.cts CHANGED
@@ -249,7 +249,7 @@ declare function CopyButton({ value, children, copiedTimeoutMs, tooltip, tooltip
249
249
  type CopyFieldProps = Pick<CopyButtonProps, "value" | "onCopied" | "onCopyError" | "copiedTimeoutMs"> & {
250
250
  /** Accessible name, e.g. "Copy secret key". */
251
251
  label: string;
252
- /** What to show; defaults to the value itself (lists pass a truncated form). */
252
+ /** What to show; defaults to a string value or the label for lazy values. */
253
253
  display?: ReactNode;
254
254
  className?: string;
255
255
  };
package/dist/index.d.ts CHANGED
@@ -249,7 +249,7 @@ declare function CopyButton({ value, children, copiedTimeoutMs, tooltip, tooltip
249
249
  type CopyFieldProps = Pick<CopyButtonProps, "value" | "onCopied" | "onCopyError" | "copiedTimeoutMs"> & {
250
250
  /** Accessible name, e.g. "Copy secret key". */
251
251
  label: string;
252
- /** What to show; defaults to the value itself (lists pass a truncated form). */
252
+ /** What to show; defaults to a string value or the label for lazy values. */
253
253
  display?: ReactNode;
254
254
  className?: string;
255
255
  };
package/dist/index.js CHANGED
@@ -2335,7 +2335,7 @@ function CopyField({
2335
2335
  className
2336
2336
  ),
2337
2337
  children: (copied) => /* @__PURE__ */ jsxs18(Fragment6, { children: [
2338
- /* @__PURE__ */ jsx26("span", { className: "polli:min-w-0 polli:flex-1 polli:select-all polli:break-all", children: copied ? "Copied" : display ?? String(value) }),
2338
+ /* @__PURE__ */ jsx26("span", { className: "polli:min-w-0 polli:flex-1 polli:select-all polli:break-all", children: copied ? "Copied" : display ?? (typeof value === "string" ? value : label) }),
2339
2339
  /* @__PURE__ */ jsx26(
2340
2340
  "span",
2341
2341
  {