@openbunny/react 0.1.0 → 0.1.1

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/README.md CHANGED
@@ -1,8 +1,5 @@
1
1
  # @openbunny/react
2
2
 
3
- > **Work in progress.** Names, identifiers and interfaces can change without
4
- > notice.
5
-
6
3
  Generic React components for OpenBunny sites. The package ships components and
7
4
  helpers with no site content.
8
5
 
@@ -121,7 +118,7 @@ Types and helpers:
121
118
 
122
119
  - `PlateAsset`: `gifSrc`, `staticSrc` (strings), `width`, `height` (numbers).
123
120
  - `CommandStep`: `command` and `comment` (strings).
124
- - `CopyText`: `caption?`, `copiedCaption?`, `failureHint?`.
121
+ - `CopyText`: `caption?`, `copiedCaption?`, `failureHint?`, `onCopy?`.
125
122
  - `shellTokens(command)` returns `ShellToken[]`; it throws on unbalanced quotes.
126
123
  - `formatLongDate(isoDate)` formats an ISO date for `PageTitle`.
127
124
  - `cn(...classes)` merges class names.
@@ -3,11 +3,11 @@ export type CopyText = {
3
3
  readonly failureHint?: string;
4
4
  readonly caption?: string;
5
5
  readonly copiedCaption?: string;
6
+ readonly onCopy?: () => void;
6
7
  };
7
8
  type CopyButtonProps = CopyText & {
8
9
  readonly text: string;
9
10
  readonly label: string;
10
- readonly onCopy?: () => void;
11
11
  };
12
12
  export declare function CopyButton({ text, label, failureHint, caption, copiedCaption, onCopy, }: CopyButtonProps): ReactElement;
13
13
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openbunny/react",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "type": "module",
5
5
  "license": "MIT",
6
6
  "description": "Generic React components for OpenBunny sites.",