@versini/ui-types 8.1.1 → 8.2.0

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.
Files changed (2) hide show
  1. package/dist/index.d.ts +20 -0
  2. package/package.json +2 -2
package/dist/index.d.ts CHANGED
@@ -46,6 +46,10 @@ type CommonButtonProps = {
46
46
 
47
47
  declare namespace ButtonTypes {
48
48
  export type Props = {
49
+ /**
50
+ * A ref to the button element.
51
+ */
52
+ ref?: React.Ref<HTMLButtonElement>;
49
53
  /**
50
54
  * The text to render in the button.
51
55
  */
@@ -77,6 +81,10 @@ declare namespace ButtonTypes {
77
81
 
78
82
  declare namespace ButtonLinkTypes {
79
83
  export type Props = {
84
+ /**
85
+ * A ref to the anchor element.
86
+ */
87
+ ref?: React.Ref<HTMLAnchorElement>;
80
88
  /**
81
89
  * Whether or not to add an icon indicating that the link
82
90
  * opens in a new window.
@@ -144,6 +152,10 @@ declare namespace ButtonIconTypes {
144
152
  labelRight?: undefined;
145
153
  };
146
154
  export type Props = LabelProps & {
155
+ /**
156
+ * A ref to the button element.
157
+ */
158
+ ref?: React.Ref<HTMLButtonElement>;
147
159
  /**
148
160
  * The icon to render in the button.
149
161
  */
@@ -177,6 +189,10 @@ declare namespace ButtonIconTypes {
177
189
 
178
190
  declare namespace ButtonSortTypes {
179
191
  export type Props = {
192
+ /**
193
+ * A ref to the button element.
194
+ */
195
+ ref?: React.Ref<HTMLButtonElement>;
180
196
  /**
181
197
  * Prop to signal if the Button is active.
182
198
  */
@@ -186,6 +202,10 @@ declare namespace ButtonSortTypes {
186
202
 
187
203
  declare namespace ButtonCopyTypes {
188
204
  export type Props = {
205
+ /**
206
+ * A ref to the button element.
207
+ */
208
+ ref?: React.Ref<HTMLButtonElement>;
189
209
  /**
190
210
  * What kind of text to copy to the clipboard.
191
211
  * - If a string is passed, that string will be copied.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@versini/ui-types",
3
- "version": "8.1.1",
3
+ "version": "8.2.0",
4
4
  "license": "MIT",
5
5
  "author": "Arno Versini",
6
6
  "publishConfig": {
@@ -32,5 +32,5 @@
32
32
  "test:watch": "vitest",
33
33
  "test": "vitest run"
34
34
  },
35
- "gitHead": "a3730974df8fcea3c016bd83844c4243dbb10208"
35
+ "gitHead": "5cc3c9aaf61ca3843f16a3d6b322a92f7fb210ca"
36
36
  }