@djangocfg/nextjs 2.1.18 → 2.1.20
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.
- package/dist/config/index.mjs +1 -1
- package/dist/config/index.mjs.map +1 -1
- package/dist/index.mjs +20 -19
- package/dist/index.mjs.map +1 -1
- package/dist/og-image/components/index.mjs +1 -0
- package/dist/og-image/components/index.mjs.map +1 -1
- package/dist/og-image/index.mjs +19 -18
- package/dist/og-image/index.mjs.map +1 -1
- package/package.json +4 -4
- package/src/og-image/components/DefaultTemplate.tsx +1 -0
package/dist/index.mjs
CHANGED
|
@@ -14,7 +14,7 @@ var require_package = __commonJS({
|
|
|
14
14
|
"package.json"(exports, module) {
|
|
15
15
|
module.exports = {
|
|
16
16
|
name: "@djangocfg/nextjs",
|
|
17
|
-
version: "2.1.
|
|
17
|
+
version: "2.1.20",
|
|
18
18
|
description: "Next.js server utilities: sitemap, health, OG images, contact forms, navigation, config",
|
|
19
19
|
keywords: [
|
|
20
20
|
"nextjs",
|
|
@@ -561,6 +561,7 @@ function createOgImageMetadataGenerator(options) {
|
|
|
561
561
|
}
|
|
562
562
|
|
|
563
563
|
// src/og-image/components/DefaultTemplate.tsx
|
|
564
|
+
import React2 from "react";
|
|
564
565
|
function DefaultTemplate({
|
|
565
566
|
title,
|
|
566
567
|
description,
|
|
@@ -592,7 +593,7 @@ function DefaultTemplate({
|
|
|
592
593
|
}) {
|
|
593
594
|
const calculatedTitleSize = titleSize || (title.length > 60 ? 56 : 72);
|
|
594
595
|
const backgroundStyle = backgroundType === "gradient" ? `linear-gradient(135deg, ${gradientStart} 0%, ${gradientEnd} 100%)` : backgroundColor;
|
|
595
|
-
const gridOverlay = devMode ? /* @__PURE__ */
|
|
596
|
+
const gridOverlay = devMode ? /* @__PURE__ */ React2.createElement(
|
|
596
597
|
"div",
|
|
597
598
|
{
|
|
598
599
|
style: {
|
|
@@ -611,7 +612,7 @@ function DefaultTemplate({
|
|
|
611
612
|
}
|
|
612
613
|
}
|
|
613
614
|
) : null;
|
|
614
|
-
return /* @__PURE__ */
|
|
615
|
+
return /* @__PURE__ */ React2.createElement(
|
|
615
616
|
"div",
|
|
616
617
|
{
|
|
617
618
|
style: {
|
|
@@ -628,7 +629,7 @@ function DefaultTemplate({
|
|
|
628
629
|
}
|
|
629
630
|
},
|
|
630
631
|
gridOverlay,
|
|
631
|
-
(showLogo && logo || showSiteName && siteName) && /* @__PURE__ */
|
|
632
|
+
(showLogo && logo || showSiteName && siteName) && /* @__PURE__ */ React2.createElement(
|
|
632
633
|
"div",
|
|
633
634
|
{
|
|
634
635
|
style: {
|
|
@@ -638,7 +639,7 @@ function DefaultTemplate({
|
|
|
638
639
|
}
|
|
639
640
|
},
|
|
640
641
|
showLogo && logo && // eslint-disable-next-line @next/next/no-img-element
|
|
641
|
-
/* @__PURE__ */
|
|
642
|
+
/* @__PURE__ */ React2.createElement(
|
|
642
643
|
"img",
|
|
643
644
|
{
|
|
644
645
|
src: logo,
|
|
@@ -650,7 +651,7 @@ function DefaultTemplate({
|
|
|
650
651
|
}
|
|
651
652
|
}
|
|
652
653
|
),
|
|
653
|
-
showSiteName && siteName && /* @__PURE__ */
|
|
654
|
+
showSiteName && siteName && /* @__PURE__ */ React2.createElement(
|
|
654
655
|
"div",
|
|
655
656
|
{
|
|
656
657
|
style: {
|
|
@@ -663,7 +664,7 @@ function DefaultTemplate({
|
|
|
663
664
|
siteName
|
|
664
665
|
)
|
|
665
666
|
),
|
|
666
|
-
/* @__PURE__ */
|
|
667
|
+
/* @__PURE__ */ React2.createElement(
|
|
667
668
|
"div",
|
|
668
669
|
{
|
|
669
670
|
style: {
|
|
@@ -674,7 +675,7 @@ function DefaultTemplate({
|
|
|
674
675
|
justifyContent: "center"
|
|
675
676
|
}
|
|
676
677
|
},
|
|
677
|
-
/* @__PURE__ */
|
|
678
|
+
/* @__PURE__ */ React2.createElement(
|
|
678
679
|
"div",
|
|
679
680
|
{
|
|
680
681
|
style: {
|
|
@@ -690,7 +691,7 @@ function DefaultTemplate({
|
|
|
690
691
|
},
|
|
691
692
|
title
|
|
692
693
|
),
|
|
693
|
-
description && /* @__PURE__ */
|
|
694
|
+
description && /* @__PURE__ */ React2.createElement(
|
|
694
695
|
"div",
|
|
695
696
|
{
|
|
696
697
|
style: {
|
|
@@ -709,7 +710,7 @@ function DefaultTemplate({
|
|
|
709
710
|
description
|
|
710
711
|
)
|
|
711
712
|
),
|
|
712
|
-
/* @__PURE__ */
|
|
713
|
+
/* @__PURE__ */ React2.createElement(
|
|
713
714
|
"div",
|
|
714
715
|
{
|
|
715
716
|
style: {
|
|
@@ -754,7 +755,7 @@ function LightTemplate({
|
|
|
754
755
|
}) {
|
|
755
756
|
const calculatedTitleSize = titleSize || (title.length > 60 ? 56 : 72);
|
|
756
757
|
const backgroundStyle = backgroundType === "gradient" ? `linear-gradient(135deg, ${gradientStart} 0%, ${gradientEnd} 100%)` : backgroundColor;
|
|
757
|
-
const gridOverlay = devMode ? /* @__PURE__ */
|
|
758
|
+
const gridOverlay = devMode ? /* @__PURE__ */ React2.createElement(
|
|
758
759
|
"div",
|
|
759
760
|
{
|
|
760
761
|
style: {
|
|
@@ -773,7 +774,7 @@ function LightTemplate({
|
|
|
773
774
|
}
|
|
774
775
|
}
|
|
775
776
|
) : null;
|
|
776
|
-
return /* @__PURE__ */
|
|
777
|
+
return /* @__PURE__ */ React2.createElement(
|
|
777
778
|
"div",
|
|
778
779
|
{
|
|
779
780
|
style: {
|
|
@@ -790,7 +791,7 @@ function LightTemplate({
|
|
|
790
791
|
}
|
|
791
792
|
},
|
|
792
793
|
gridOverlay,
|
|
793
|
-
(showLogo && logo || showSiteName && siteName) && /* @__PURE__ */
|
|
794
|
+
(showLogo && logo || showSiteName && siteName) && /* @__PURE__ */ React2.createElement(
|
|
794
795
|
"div",
|
|
795
796
|
{
|
|
796
797
|
style: {
|
|
@@ -800,7 +801,7 @@ function LightTemplate({
|
|
|
800
801
|
}
|
|
801
802
|
},
|
|
802
803
|
showLogo && logo && // eslint-disable-next-line @next/next/no-img-element
|
|
803
|
-
/* @__PURE__ */
|
|
804
|
+
/* @__PURE__ */ React2.createElement(
|
|
804
805
|
"img",
|
|
805
806
|
{
|
|
806
807
|
src: logo,
|
|
@@ -812,7 +813,7 @@ function LightTemplate({
|
|
|
812
813
|
}
|
|
813
814
|
}
|
|
814
815
|
),
|
|
815
|
-
showSiteName && siteName && /* @__PURE__ */
|
|
816
|
+
showSiteName && siteName && /* @__PURE__ */ React2.createElement(
|
|
816
817
|
"div",
|
|
817
818
|
{
|
|
818
819
|
style: {
|
|
@@ -825,7 +826,7 @@ function LightTemplate({
|
|
|
825
826
|
siteName
|
|
826
827
|
)
|
|
827
828
|
),
|
|
828
|
-
/* @__PURE__ */
|
|
829
|
+
/* @__PURE__ */ React2.createElement(
|
|
829
830
|
"div",
|
|
830
831
|
{
|
|
831
832
|
style: {
|
|
@@ -836,7 +837,7 @@ function LightTemplate({
|
|
|
836
837
|
justifyContent: "center"
|
|
837
838
|
}
|
|
838
839
|
},
|
|
839
|
-
/* @__PURE__ */
|
|
840
|
+
/* @__PURE__ */ React2.createElement(
|
|
840
841
|
"div",
|
|
841
842
|
{
|
|
842
843
|
style: {
|
|
@@ -851,7 +852,7 @@ function LightTemplate({
|
|
|
851
852
|
},
|
|
852
853
|
title
|
|
853
854
|
),
|
|
854
|
-
description && /* @__PURE__ */
|
|
855
|
+
description && /* @__PURE__ */ React2.createElement(
|
|
855
856
|
"div",
|
|
856
857
|
{
|
|
857
858
|
style: {
|
|
@@ -866,7 +867,7 @@ function LightTemplate({
|
|
|
866
867
|
description
|
|
867
868
|
)
|
|
868
869
|
),
|
|
869
|
-
/* @__PURE__ */
|
|
870
|
+
/* @__PURE__ */ React2.createElement(
|
|
870
871
|
"div",
|
|
871
872
|
{
|
|
872
873
|
style: {
|