@questdb/react-components
Advanced tools
Comparing version 0.0.2 to 0.0.3
@@ -18,4 +18,5 @@ import React, { MouseEvent, ReactNode } from "react"; | ||
prefixIcon?: React.ReactNode; | ||
dataHook?: string; | ||
}; | ||
export declare const Button: React.FunctionComponent<Props>; | ||
export {}; |
@@ -66,3 +66,3 @@ "use strict"; | ||
var type = as === "button" ? { type: "button" } : {}; | ||
return (react_1.default.createElement(StyledButton, __assign({ ref: ref, as: as !== null && as !== void 0 ? as : "button", disabled: disabled }, props, type), | ||
return (react_1.default.createElement(StyledButton, __assign({ ref: ref, as: as !== null && as !== void 0 ? as : "button", disabled: disabled, "data-hook": props.dataHook }, props, type), | ||
prefixIcon && react_1.default.createElement(Prefix, { disabled: disabled }, prefixIcon), | ||
@@ -69,0 +69,0 @@ children)); |
@@ -6,4 +6,5 @@ import React from "react"; | ||
children?: React.ReactNode; | ||
dataHook?: string; | ||
}; | ||
export declare const Heading: ({ level, children, ...rest }: Props) => React.DetailedReactHTMLElement<{ | ||
export declare const Heading: ({ level, children, dataHook, ...rest }: Props) => React.DetailedReactHTMLElement<{ | ||
style: { | ||
@@ -13,3 +14,4 @@ fontSize: string; | ||
}; | ||
"data-hook": string | undefined; | ||
}, HTMLElement>; | ||
export {}; |
@@ -38,5 +38,5 @@ "use strict"; | ||
var Heading = function (_a) { | ||
var level = _a.level, children = _a.children, rest = __rest(_a, ["level", "children"]); | ||
return react_1.default.createElement("h" + level, __assign({ style: { fontSize: fontSizes[level], margin: 0 } }, rest), children); | ||
var level = _a.level, children = _a.children, dataHook = _a.dataHook, rest = __rest(_a, ["level", "children", "dataHook"]); | ||
return react_1.default.createElement("h" + level, __assign({ style: { fontSize: fontSizes[level], margin: 0 }, "data-hook": dataHook }, rest), children); | ||
}; | ||
exports.Heading = Heading; |
{ | ||
"name": "@questdb/react-components", | ||
"version": "0.0.2", | ||
"version": "0.0.3", | ||
"packageManager": "yarn@3.2.0", | ||
@@ -5,0 +5,0 @@ "files": [ |
17338
409