@react-email/heading
Advanced tools
Comparing version 0.0.14-canary.0 to 0.0.14
@@ -29,4 +29,16 @@ import * as React$1 from 'react'; | ||
type HeadingProps = HeadingAs & Margin; | ||
declare const Heading: React$1.FC<Readonly<HeadingProps>>; | ||
declare const Heading: React$1.ForwardRefExoticComponent<(Omit<Readonly<React$1.ClassAttributes<HTMLHeadingElement> & React$1.HTMLAttributes<HTMLHeadingElement> & { | ||
as?: "h1" | undefined; | ||
} & Margin>, "ref"> | Omit<Readonly<React$1.ClassAttributes<HTMLHeadingElement> & React$1.HTMLAttributes<HTMLHeadingElement> & { | ||
as: "h2"; | ||
} & Margin>, "ref"> | Omit<Readonly<React$1.ClassAttributes<HTMLHeadingElement> & React$1.HTMLAttributes<HTMLHeadingElement> & { | ||
as: "h3"; | ||
} & Margin>, "ref"> | Omit<Readonly<React$1.ClassAttributes<HTMLHeadingElement> & React$1.HTMLAttributes<HTMLHeadingElement> & { | ||
as: "h4"; | ||
} & Margin>, "ref"> | Omit<Readonly<React$1.ClassAttributes<HTMLHeadingElement> & React$1.HTMLAttributes<HTMLHeadingElement> & { | ||
as: "h5"; | ||
} & Margin>, "ref"> | Omit<Readonly<React$1.ClassAttributes<HTMLHeadingElement> & React$1.HTMLAttributes<HTMLHeadingElement> & { | ||
as: "h6"; | ||
} & Margin>, "ref">) & React$1.RefAttributes<HTMLHeadingElement>>; | ||
export { Heading, HeadingAs, HeadingProps }; |
"use strict"; | ||
var __create = Object.create; | ||
var __defProp = Object.defineProperty; | ||
@@ -8,2 +9,3 @@ var __defProps = Object.defineProperties; | ||
var __getOwnPropSymbols = Object.getOwnPropertySymbols; | ||
var __getProtoOf = Object.getPrototypeOf; | ||
var __hasOwnProp = Object.prototype.hasOwnProperty; | ||
@@ -48,2 +50,10 @@ var __propIsEnum = Object.prototype.propertyIsEnumerable; | ||
}; | ||
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps( | ||
// If the importer is in node compatibility mode or this is not an ESM | ||
// file that has been converted to a CommonJS file using a Babel- | ||
// compatible transform (i.e. "__esModule" has not been set), then set | ||
// "default" to the CommonJS "module.exports" for node compatibility. | ||
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target, | ||
mod | ||
)); | ||
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod); | ||
@@ -59,3 +69,3 @@ | ||
// src/heading.tsx | ||
var import_react_slot = require("@radix-ui/react-slot"); | ||
var React = __toESM(require("react")); | ||
@@ -89,34 +99,16 @@ // src/utils/spaces.ts | ||
var import_jsx_runtime = require("react/jsx-runtime"); | ||
var Heading = (_a) => { | ||
var _b = _a, { | ||
as: Tag = "h1", | ||
children, | ||
style, | ||
m, | ||
mx, | ||
my, | ||
mt, | ||
mr, | ||
mb, | ||
ml | ||
} = _b, props = __objRest(_b, [ | ||
"as", | ||
"children", | ||
"style", | ||
"m", | ||
"mx", | ||
"my", | ||
"mt", | ||
"mr", | ||
"mb", | ||
"ml" | ||
]); | ||
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)( | ||
import_react_slot.Slot, | ||
__spreadProps(__spreadValues({}, props), { | ||
style: __spreadValues(__spreadValues({}, withMargin({ m, mx, my, mt, mr, mb, ml })), style), | ||
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Tag, { children }) | ||
}) | ||
); | ||
}; | ||
var Heading = React.forwardRef( | ||
(_a, ref) => { | ||
var _b = _a, { as: Tag = "h1", children, style, m, mx, my, mt, mr, mb, ml } = _b, props = __objRest(_b, ["as", "children", "style", "m", "mx", "my", "mt", "mr", "mb", "ml"]); | ||
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)( | ||
Tag, | ||
__spreadProps(__spreadValues({}, props), { | ||
ref, | ||
style: __spreadValues(__spreadValues({}, withMargin({ m, mx, my, mt, mr, mb, ml })), style), | ||
children | ||
}) | ||
); | ||
} | ||
); | ||
Heading.displayName = "Heading"; | ||
// Annotate the CommonJS export names for ESM import in node: | ||
@@ -123,0 +115,0 @@ 0 && (module.exports = { |
{ | ||
"name": "@react-email/heading", | ||
"version": "0.0.14-canary.0", | ||
"version": "0.0.14", | ||
"description": "A block of heading text", | ||
@@ -37,5 +37,2 @@ "sideEffects": false, | ||
}, | ||
"dependencies": { | ||
"@radix-ui/react-slot": "1.1.0" | ||
}, | ||
"peerDependencies": { | ||
@@ -45,7 +42,6 @@ "react": "^18.0 || ^19.0 || ^19.0.0-rc" | ||
"devDependencies": { | ||
"@babel/preset-react": "7.23.3", | ||
"typescript": "5.1.6", | ||
"eslint-config-custom": "0.0.0", | ||
"@react-email/render": "1.0.0", | ||
"tsconfig": "0.0.0", | ||
"@react-email/render": "0.0.18-canary.0" | ||
"eslint-config-custom": "0.0.0" | ||
}, | ||
@@ -52,0 +48,0 @@ "publishConfig": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
16102
1
4
224
- Removed@radix-ui/react-slot@1.1.0
- Removed@radix-ui/react-compose-refs@1.1.0(transitive)
- Removed@radix-ui/react-slot@1.1.0(transitive)