@jsx-email/markdown
Advanced tools
Comparing version 2.0.3 to 2.0.4
@@ -1,2 +0,4 @@ | ||
export * from './markdown'; | ||
//# sourceMappingURL=index.d.ts.map | ||
export { Markdown, MarkdownProps } from './markdown.js'; | ||
import 'react/jsx-runtime'; | ||
import 'md-to-react-email'; | ||
import 'react'; |
"use strict"; | ||
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
var desc = Object.getOwnPropertyDescriptor(m, k); | ||
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { | ||
desc = { enumerable: true, get: function() { return m[k]; } }; | ||
} | ||
Object.defineProperty(o, k2, desc); | ||
}) : (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
o[k2] = m[k]; | ||
})); | ||
var __exportStar = (this && this.__exportStar) || function(m, exports) { | ||
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); | ||
var __defProp = Object.defineProperty; | ||
var __getOwnPropDesc = Object.getOwnPropertyDescriptor; | ||
var __getOwnPropNames = Object.getOwnPropertyNames; | ||
var __hasOwnProp = Object.prototype.hasOwnProperty; | ||
var __copyProps = (to, from, except, desc) => { | ||
if (from && typeof from === "object" || typeof from === "function") { | ||
for (let key of __getOwnPropNames(from)) | ||
if (!__hasOwnProp.call(to, key) && key !== except) | ||
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable }); | ||
} | ||
return to; | ||
}; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
__exportStar(require("./markdown"), exports); | ||
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default")); | ||
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod); | ||
// src/index.ts | ||
var src_exports = {}; | ||
module.exports = __toCommonJS(src_exports); | ||
__reExport(src_exports, require("./markdown.js"), module.exports); | ||
// Annotate the CommonJS export names for ESM import in node: | ||
0 && (module.exports = { | ||
...require("./markdown.js") | ||
}); | ||
//# sourceMappingURL=index.js.map |
@@ -1,4 +0,6 @@ | ||
import { type StylesType } from 'md-to-react-email'; | ||
import * as react_jsx_runtime from 'react/jsx-runtime'; | ||
import { StylesType } from 'md-to-react-email'; | ||
import React from 'react'; | ||
export interface MarkdownProps extends React.PropsWithChildren { | ||
interface MarkdownProps extends React.PropsWithChildren { | ||
children: string; | ||
@@ -8,6 +10,7 @@ markdownContainerStyles?: React.CSSProperties; | ||
} | ||
export declare const Markdown: { | ||
({ children, markdownContainerStyles, markdownCustomStyles, ...props }: React.PropsWithChildren<MarkdownProps>): import("react/jsx-runtime").JSX.Element; | ||
declare const Markdown: { | ||
({ children, markdownContainerStyles, markdownCustomStyles, ...props }: React.PropsWithChildren<MarkdownProps>): react_jsx_runtime.JSX.Element; | ||
displayName: string; | ||
}; | ||
//# sourceMappingURL=markdown.d.ts.map | ||
export { Markdown, MarkdownProps }; |
"use strict"; | ||
var __rest = (this && this.__rest) || function (s, e) { | ||
var t = {}; | ||
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) | ||
t[p] = s[p]; | ||
if (s != null && typeof Object.getOwnPropertySymbols === "function") | ||
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { | ||
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) | ||
t[p[i]] = s[p[i]]; | ||
} | ||
return t; | ||
var __defProp = Object.defineProperty; | ||
var __getOwnPropDesc = Object.getOwnPropertyDescriptor; | ||
var __getOwnPropNames = Object.getOwnPropertyNames; | ||
var __hasOwnProp = Object.prototype.hasOwnProperty; | ||
var __name = (target, value) => __defProp(target, "name", { value, configurable: true }); | ||
var __export = (target, all) => { | ||
for (var name in all) | ||
__defProp(target, name, { get: all[name], enumerable: true }); | ||
}; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.Markdown = void 0; | ||
const jsx_runtime_1 = require("react/jsx-runtime"); | ||
const md_to_react_email_1 = require("md-to-react-email"); | ||
const Markdown = (_a) => { | ||
var { children, markdownContainerStyles, markdownCustomStyles } = _a, props = __rest(_a, ["children", "markdownContainerStyles", "markdownCustomStyles"]); | ||
const parsedMarkdown = (0, md_to_react_email_1.parseMarkdownToJSX)({ | ||
customStyles: markdownCustomStyles, | ||
markdown: children | ||
}); | ||
return ((0, jsx_runtime_1.jsx)("div", Object.assign({}, props, { "data-id": "@jsx-email/markdown", style: markdownContainerStyles, dangerouslySetInnerHTML: { __html: parsedMarkdown } }))); | ||
var __copyProps = (to, from, except, desc) => { | ||
if (from && typeof from === "object" || typeof from === "function") { | ||
for (let key of __getOwnPropNames(from)) | ||
if (!__hasOwnProp.call(to, key) && key !== except) | ||
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable }); | ||
} | ||
return to; | ||
}; | ||
exports.Markdown = Markdown; | ||
exports.Markdown.displayName = 'Markdown'; | ||
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod); | ||
// src/markdown.tsx | ||
var markdown_exports = {}; | ||
__export(markdown_exports, { | ||
Markdown: () => Markdown | ||
}); | ||
module.exports = __toCommonJS(markdown_exports); | ||
var import_md_to_react_email = require("md-to-react-email"); | ||
var import_jsx_runtime = require("react/jsx-runtime"); | ||
var Markdown = /* @__PURE__ */ __name(({ | ||
children, | ||
markdownContainerStyles, | ||
markdownCustomStyles, | ||
...props | ||
}) => { | ||
const parsedMarkdown = (0, import_md_to_react_email.parseMarkdownToJSX)({ | ||
customStyles: markdownCustomStyles, | ||
markdown: children | ||
}); | ||
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)( | ||
"div", | ||
{ | ||
...props, | ||
"data-id": "@jsx-email/markdown", | ||
style: markdownContainerStyles, | ||
dangerouslySetInnerHTML: { __html: parsedMarkdown } | ||
} | ||
); | ||
}, "Markdown"); | ||
Markdown.displayName = "Markdown"; | ||
// Annotate the CommonJS export names for ESM import in node: | ||
0 && (module.exports = { | ||
Markdown | ||
}); | ||
//# sourceMappingURL=markdown.js.map |
{ | ||
"name": "@jsx-email/markdown", | ||
"version": "2.0.3", | ||
"version": "2.0.4", | ||
"publishConfig": { | ||
@@ -14,9 +14,17 @@ "access": "public" | ||
}, | ||
"homepage": "https://jsx.email/docs/components/markdown", | ||
"main": "dist/index.js", | ||
"module": "dist/es/index.js", | ||
"module": "dist/index.mjs", | ||
"exports": { | ||
".": { | ||
"import": "./dist/es/index.js", | ||
"require": "./dist/index.js" | ||
} | ||
"import": { | ||
"types": "./dist/index.d.mts", | ||
"default": "./dist/index.mjs" | ||
}, | ||
"require": { | ||
"types": "./dist/index.d.ts", | ||
"default": "./dist/index.js" | ||
} | ||
}, | ||
"./package.json": "./package.json" | ||
}, | ||
@@ -40,4 +48,8 @@ "engines": { | ||
}, | ||
"types": "./dist/index.d.ts", | ||
"types": "dist/index.d.mts", | ||
"funding": { | ||
"type": "github", | ||
"url": "https://github.com/sponsors/shellscape" | ||
}, | ||
"sideEffects": false | ||
} |
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
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
12555
123
0