@sesamehr/react-design-system 2.0.0-beta.16 → 2.0.0-beta.18

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.
@@ -2,7 +2,10 @@ import { CardVariants } from './index.ts';
2
2
  export interface CardProps extends React.HTMLAttributes<HTMLDivElement> {
3
3
  /** Render as the child element instead of a `<div>` (Radix Slot). */
4
4
  asChild?: boolean;
5
- /** Which surface it is: `default` is white, `muted` is tinted. */
5
+ /**
6
+ * Which surface it is: `default` is white, `muted` is tinted, `highlighted`
7
+ * is filled with the brand colour and carries its own light text.
8
+ */
6
9
  tone?: CardVariants['tone'];
7
10
  /** Drops the border, the shadow and the glass — just the surface and its radius. */
8
11
  flat?: boolean;
@@ -3,9 +3,15 @@ export { Card, type CardProps } from './Card.tsx';
3
3
  /**
4
4
  * Two things vary, and they are not the same thing.
5
5
  *
6
- * `tone` is which surface it is: white, or tinted for the case the white one
7
- * cannot serve. White on white needs a border around every row to read as
8
- * separate things; a tinted surface lets the white ones separate on their own.
6
+ * `tone` is which surface it is: white, tinted for the case the white one
7
+ * cannot serve, or filled with the brand colour when the card is the one thing
8
+ * on the page meant to be looked at first. White on white needs a border around
9
+ * every row to read as separate things; a tinted surface lets the white ones
10
+ * separate on their own.
11
+ *
12
+ * `highlighted` is the only tone that also sets a text colour, because it is
13
+ * the only one whose surface is dark enough to need it. Everything inside
14
+ * inherits it, so the content composes exactly as it would on a white card.
9
15
  *
10
16
  * `flat` is what it carries on top of that surface. They are kept apart
11
17
  * because the combinations are all real: a white card over a tinted one, a
@@ -16,6 +22,6 @@ export { Card, type CardProps } from './Card.tsx';
16
22
  * styles keyed off `data-flat` rather than being bent into one.
17
23
  */
18
24
  export declare const cardVariants: (props?: ({
19
- tone?: "default" | "muted" | null | undefined;
25
+ tone?: "default" | "muted" | "highlighted" | null | undefined;
20
26
  } & import('class-variance-authority/types').ClassProp) | undefined) => string;
21
27
  export type CardVariants = VariantProps<typeof cardVariants>;