@plusrouter/ui 0.1.27 → 0.1.29

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.
@@ -1,7 +1,15 @@
1
- import type { ComponentPropsWithoutRef } from 'react';
1
+ import { type ComponentPropsWithoutRef, type ReactNode } from 'react';
2
2
  export interface CardProps extends ComponentPropsWithoutRef<'div'> {
3
3
  variant?: 'default' | 'reference';
4
4
  /** Semantic element for the same visual treatment, e.g. an article in a list. */
5
5
  as?: 'div' | 'article';
6
+ /** Decorative SVG element repeated behind the card content. */
7
+ backgroundIcon?: ReactNode;
8
+ /** Base icon size in pixels. */
9
+ backgroundIconSize?: number;
10
+ /** Pattern color; SVGs should use currentColor to inherit it. */
11
+ backgroundIconColor?: string;
12
+ /** Opacity of the entire decorative pattern, from 0 to 1. */
13
+ backgroundIconOpacity?: number;
6
14
  }
7
- export declare const Card: ({ variant, as: Tag, className, ...props }: CardProps) => import("react").JSX.Element;
15
+ export declare const Card: ({ variant, as: Tag, className, children, backgroundIcon, backgroundIconSize, backgroundIconColor, backgroundIconOpacity, ...props }: CardProps) => import("react").JSX.Element;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@plusrouter/ui",
3
- "version": "0.1.27",
3
+ "version": "0.1.29",
4
4
  "type": "module",
5
5
  "license": "MIT",
6
6
  "main": "./dist/index.js",
@@ -33,7 +33,7 @@
33
33
  "storybook": "storybook dev -p 6006",
34
34
  "build": "node build.mjs",
35
35
  "prepack": "npm run build",
36
- "test:package": "node --test test/package.test.mjs test/background-square.test.mjs",
36
+ "test:package": "node --test test/package.test.mjs test/background-square.test.mjs test/card-pattern.test.mjs",
37
37
  "build:storybook": "storybook build",
38
38
  "check": "tsc --noEmit",
39
39
  "lint": "eslint src .storybook --max-warnings=0",