@siyahi/ui 0.1.9-next.8 → 0.1.9-next.9

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,6 +2,7 @@
2
2
  import { Badge } from "../../ui/badge.js";
3
3
  import { Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle } from "../../ui/card.js";
4
4
  import { cn } from "../../../lib/utils.js";
5
+ import { useSurface } from "../../siyahi/siyahi-provider.js";
5
6
  import { jsx, jsxs } from "react/jsx-runtime";
6
7
  import "react";
7
8
  //#region src/components/registry/dashboard-01/section-cards.tsx
@@ -13,12 +14,13 @@ const COLUMNS = {
13
14
  6: "@3xl/main:grid-cols-3"
14
15
  };
15
16
  function SectionCards({ items, selected, onSelect }) {
17
+ const ruled = useSurface() === "ruled";
16
18
  return /* @__PURE__ */ jsx("div", {
17
- className: "@container/main",
19
+ className: cn("@container/main", ruled && "overflow-hidden border-y"),
18
20
  children: /* @__PURE__ */ jsx("div", {
19
- className: cn("grid grid-cols-1 gap-4", COLUMNS[items.length] ?? COLUMNS[4]),
21
+ className: cn("grid grid-cols-1", ruled ? "-mt-px -ml-px" : "gap-4", COLUMNS[items.length] ?? COLUMNS[4]),
20
22
  children: items.map((item) => /* @__PURE__ */ jsxs(Card, {
21
- className: cn("@container/card", onSelect && "relative", item.label === selected && "ring-2 ring-primary!", onSelect && item.disabled && "opacity-60"),
23
+ className: cn("@container/card", ruled && "border-t border-l", onSelect && "relative", item.label === selected && "ring-2 ring-primary!", item.label === selected && ruled && "ring-inset", onSelect && item.disabled && "opacity-60"),
22
24
  children: [
23
25
  onSelect && /* @__PURE__ */ jsx("button", {
24
26
  type: "button",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@siyahi/ui",
3
- "version": "0.1.9-next.8",
3
+ "version": "0.1.9-next.9",
4
4
  "description": "Stock shadcn/ui on Base UI and Tailwind v4, a finance theme, a few compositions and formatters.",
5
5
  "keywords": [
6
6
  "base-ui",
package/styles/siyahi.css CHANGED
@@ -246,6 +246,8 @@
246
246
  [data-slot="card-footer"] {
247
247
  background: none;
248
248
  border-top-width: 0;
249
+ /* The band's own top padding stacked on the card's gap, and with no band it read as a hole under the figure. */
250
+ padding-top: 0;
249
251
  }
250
252
  }
251
253