@hackersheet/next-document-content-components 0.1.0-alpha.17 → 0.1.0-alpha.19

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.
@@ -35,5 +35,5 @@ var import_link = __toESM(require("next/link"));
35
35
  var import_react = __toESM(require("react"));
36
36
  var import_md = require("react-icons/md");
37
37
  function Heading({ HeadingTag, id, children }) {
38
- return /* @__PURE__ */ import_react.default.createElement(HeadingTag, { id, className: "heading" }, /* @__PURE__ */ import_react.default.createElement(import_link.default, { href: `#${id}` }, /* @__PURE__ */ import_react.default.createElement("span", { className: "heading-label" }, children), /* @__PURE__ */ import_react.default.createElement("span", { className: "heading-link-icon" }, /* @__PURE__ */ import_react.default.createElement(import_md.MdLink, null))));
38
+ return /* @__PURE__ */ import_react.default.createElement(HeadingTag, { id, className: "heading" }, /* @__PURE__ */ import_react.default.createElement(import_link.default, { href: `#${id}`, prefetch: false }, /* @__PURE__ */ import_react.default.createElement("span", { className: "heading-label" }, children), /* @__PURE__ */ import_react.default.createElement("span", { className: "heading-link-icon" }, /* @__PURE__ */ import_react.default.createElement(import_md.MdLink, null))));
39
39
  }
@@ -31,8 +31,7 @@ __export(image_exports, {
31
31
  default: () => Image
32
32
  });
33
33
  module.exports = __toCommonJS(image_exports);
34
- var import_image = __toESM(require("next/image"));
35
34
  var import_react = __toESM(require("react"));
36
35
  function Image({ src, width, height, alt }) {
37
- return /* @__PURE__ */ import_react.default.createElement(import_image.default, { src, width, height, alt });
36
+ return /* @__PURE__ */ import_react.default.createElement("picture", null, /* @__PURE__ */ import_react.default.createElement("img", { src, width, height, alt }));
38
37
  }
@@ -34,5 +34,5 @@ module.exports = __toCommonJS(link_exports);
34
34
  var import_link = __toESM(require("next/link"));
35
35
  var import_react = __toESM(require("react"));
36
36
  function Link({ href, id, children }) {
37
- return /* @__PURE__ */ import_react.default.createElement(import_link.default, { href, id }, children);
37
+ return /* @__PURE__ */ import_react.default.createElement(import_link.default, { href, id, prefetch: false }, children);
38
38
  }
@@ -31,7 +31,6 @@ __export(link_card_exports, {
31
31
  default: () => LinkCard
32
32
  });
33
33
  module.exports = __toCommonJS(link_card_exports);
34
- var import_image = __toESM(require("next/image"));
35
34
  var import_react = __toESM(require("react"));
36
35
  function LinkCard({
37
36
  domain,
@@ -43,5 +42,5 @@ function LinkCard({
43
42
  imageWidth
44
43
  }) {
45
44
  const faviconUrl = `https://t1.gstatic.com/faviconV2?client=SOCIAL&type=FAVICON&fallback_opts=TYPE,SIZE,URL&url=https://${domain}&size=16`;
46
- return /* @__PURE__ */ import_react.default.createElement("a", { href: url, className: "link-card" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "link-card-main" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "link-card-title-container" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "link-card-title" }, title)), /* @__PURE__ */ import_react.default.createElement("div", { className: "link-card-description" }, description), /* @__PURE__ */ import_react.default.createElement("div", { className: "link-card-domain" }, /* @__PURE__ */ import_react.default.createElement("picture", null, /* @__PURE__ */ import_react.default.createElement("img", { src: faviconUrl, alt: `${domain} favicon`, width: 16, height: 16 })), /* @__PURE__ */ import_react.default.createElement("div", null, domain))), imageUrl && /* @__PURE__ */ import_react.default.createElement("div", { className: "link-card-image" }, /* @__PURE__ */ import_react.default.createElement(import_image.default, { alt: title, src: imageUrl, height: imageHeight, width: imageWidth })));
45
+ return /* @__PURE__ */ import_react.default.createElement("a", { href: url, className: "link-card" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "link-card-main" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "link-card-title-container" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "link-card-title" }, title)), /* @__PURE__ */ import_react.default.createElement("div", { className: "link-card-description" }, description), /* @__PURE__ */ import_react.default.createElement("div", { className: "link-card-domain" }, /* @__PURE__ */ import_react.default.createElement("picture", null, /* @__PURE__ */ import_react.default.createElement("img", { src: faviconUrl, alt: `${domain} favicon`, width: 16, height: 16 })), /* @__PURE__ */ import_react.default.createElement("div", null, domain))), imageUrl && /* @__PURE__ */ import_react.default.createElement("picture", { className: "link-card-image" }, /* @__PURE__ */ import_react.default.createElement("img", { alt: title, src: imageUrl, height: imageHeight, width: imageWidth })));
47
46
  }
@@ -2,7 +2,7 @@ import Link from "next/link";
2
2
  import React from "react";
3
3
  import { MdLink } from "react-icons/md";
4
4
  function Heading({ HeadingTag, id, children }) {
5
- return /* @__PURE__ */ React.createElement(HeadingTag, { id, className: "heading" }, /* @__PURE__ */ React.createElement(Link, { href: `#${id}` }, /* @__PURE__ */ React.createElement("span", { className: "heading-label" }, children), /* @__PURE__ */ React.createElement("span", { className: "heading-link-icon" }, /* @__PURE__ */ React.createElement(MdLink, null))));
5
+ return /* @__PURE__ */ React.createElement(HeadingTag, { id, className: "heading" }, /* @__PURE__ */ React.createElement(Link, { href: `#${id}`, prefetch: false }, /* @__PURE__ */ React.createElement("span", { className: "heading-label" }, children), /* @__PURE__ */ React.createElement("span", { className: "heading-link-icon" }, /* @__PURE__ */ React.createElement(MdLink, null))));
6
6
  }
7
7
  export {
8
8
  Heading as default
@@ -1,7 +1,6 @@
1
- import NextImage from "next/image";
2
1
  import React from "react";
3
2
  function Image({ src, width, height, alt }) {
4
- return /* @__PURE__ */ React.createElement(NextImage, { src, width, height, alt });
3
+ return /* @__PURE__ */ React.createElement("picture", null, /* @__PURE__ */ React.createElement("img", { src, width, height, alt }));
5
4
  }
6
5
  export {
7
6
  Image as default
@@ -1,7 +1,7 @@
1
1
  import NextLink from "next/link";
2
2
  import React from "react";
3
3
  function Link({ href, id, children }) {
4
- return /* @__PURE__ */ React.createElement(NextLink, { href, id }, children);
4
+ return /* @__PURE__ */ React.createElement(NextLink, { href, id, prefetch: false }, children);
5
5
  }
6
6
  export {
7
7
  Link as default
@@ -1,4 +1,3 @@
1
- import Image from "next/image";
2
1
  import React from "react";
3
2
  function LinkCard({
4
3
  domain,
@@ -10,7 +9,7 @@ function LinkCard({
10
9
  imageWidth
11
10
  }) {
12
11
  const faviconUrl = `https://t1.gstatic.com/faviconV2?client=SOCIAL&type=FAVICON&fallback_opts=TYPE,SIZE,URL&url=https://${domain}&size=16`;
13
- return /* @__PURE__ */ React.createElement("a", { href: url, className: "link-card" }, /* @__PURE__ */ React.createElement("div", { className: "link-card-main" }, /* @__PURE__ */ React.createElement("div", { className: "link-card-title-container" }, /* @__PURE__ */ React.createElement("div", { className: "link-card-title" }, title)), /* @__PURE__ */ React.createElement("div", { className: "link-card-description" }, description), /* @__PURE__ */ React.createElement("div", { className: "link-card-domain" }, /* @__PURE__ */ React.createElement("picture", null, /* @__PURE__ */ React.createElement("img", { src: faviconUrl, alt: `${domain} favicon`, width: 16, height: 16 })), /* @__PURE__ */ React.createElement("div", null, domain))), imageUrl && /* @__PURE__ */ React.createElement("div", { className: "link-card-image" }, /* @__PURE__ */ React.createElement(Image, { alt: title, src: imageUrl, height: imageHeight, width: imageWidth })));
12
+ return /* @__PURE__ */ React.createElement("a", { href: url, className: "link-card" }, /* @__PURE__ */ React.createElement("div", { className: "link-card-main" }, /* @__PURE__ */ React.createElement("div", { className: "link-card-title-container" }, /* @__PURE__ */ React.createElement("div", { className: "link-card-title" }, title)), /* @__PURE__ */ React.createElement("div", { className: "link-card-description" }, description), /* @__PURE__ */ React.createElement("div", { className: "link-card-domain" }, /* @__PURE__ */ React.createElement("picture", null, /* @__PURE__ */ React.createElement("img", { src: faviconUrl, alt: `${domain} favicon`, width: 16, height: 16 })), /* @__PURE__ */ React.createElement("div", null, domain))), imageUrl && /* @__PURE__ */ React.createElement("picture", { className: "link-card-image" }, /* @__PURE__ */ React.createElement("img", { alt: title, src: imageUrl, height: imageHeight, width: imageWidth })));
14
13
  }
15
14
  export {
16
15
  LinkCard as default
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hackersheet/next-document-content-components",
3
- "version": "0.1.0-alpha.17",
3
+ "version": "0.1.0-alpha.19",
4
4
  "description": "Hacker Sheet document content components for Next.js",
5
5
  "keywords": [],
6
6
  "repository": {
@@ -33,8 +33,8 @@
33
33
  "react-icons": "^5.5.0",
34
34
  "react-tweet": "^3.2.2",
35
35
  "shiki": "^3.13.0",
36
- "@hackersheet/core": "0.1.0-alpha.11",
37
- "@hackersheet/react-document-content": "0.1.0-alpha.13"
36
+ "@hackersheet/react-document-content": "0.1.0-alpha.13",
37
+ "@hackersheet/core": "0.1.0-alpha.11"
38
38
  },
39
39
  "devDependencies": {
40
40
  "@types/react": "^19.2.0",
@@ -44,7 +44,7 @@
44
44
  "react-dom": "^19.2.0"
45
45
  },
46
46
  "peerDependencies": {
47
- "next": "^15.0.0",
47
+ "next": "^15.0.0 || ^16.0.0",
48
48
  "react": "^19.0.0",
49
49
  "react-dom": "^19.0.0"
50
50
  },