lm-web-controls 1.4.67 → 1.5.0
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.
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import e from"react";import a from"moment";import t from"next/image";import o from"next/link";function n(n){var c,
|
|
2
|
+
import e from"react";import a from"moment";import t from"next/image";import o from"next/link";function n(n){var l,c,r,i,m,d,s,u,g=n.featured,v=n.icon,f=n.nestedUrl,E=n.categoryUrl,h=n.category,N=n.isH1,b=n.hasCategoryPages;return e.createElement("section",{className:"featured-blog-main-container"},e.createElement("div",{className:"featured-blog-image-container"},e.createElement(t,{src:g.featuredImage,alt:g.title,className:"featured-blog-image",width:1200,height:675}),b?e.createElement(o,{className:"post-category",href:"".concat(E?"/".concat(E):"","/category/").concat(null===(l=g.categoryInfo)||void 0===l?void 0:l.slug)},(null===(c=null==g?void 0:g.categoryInfo)||void 0===c?void 0:c.name)||"General"):e.createElement("span",{className:"post-category"},(null===(r=null==g?void 0:g.categoryInfo)||void 0===r?void 0:r.name)||"General")),e.createElement("div",{className:"featured-blog-data-container"},e.createElement(o,{href:"".concat(f?"/".concat(f):"","/post").concat(h?"/".concat(null===(i=g.categoryInfo)||void 0===i?void 0:i.slug):"","/").concat(g.slug),className:"featured-blog-title-link"},N?e.createElement("h1",{className:"featured-blog-title"},g.title):e.createElement("h2",{className:"featured-blog-title"},g.title)),e.createElement("div",{className:"featured-blog-avatar-main-container"},e.createElement("div",{className:"featured-blog-avatar"},(null===(m=g.author)||void 0===m?void 0:m.name)?null===(d=g.author)||void 0===d?void 0:d.name[0]:""),e.createElement("div",{className:"featured-blog-author-container"},e.createElement("h3",{className:"featured-blog-author-name"},(null===(s=g.author)||void 0===s?void 0:s.name)||""),e.createElement("div",{className:"featured-blog-date-read"},"On ".concat(a(g.publishedOn).format("ddd, MMM DD, YYYY"),", ").concat(g.readTime?"".concat(g.readTime," Min read"):"3 Min read")),e.createElement("h3",{className:"featured-blog-view-count"},g.views||0," ",1===(g.views||0)?"View":"Views"))),e.createElement("p",{className:"featured-blog-preview-content"},g.previewContent),e.createElement(o,{className:"read-more-container",href:"".concat(f?"/".concat(f):"","/post").concat(h?"/".concat(null===(u=g.categoryInfo)||void 0===u?void 0:u.slug):"","/").concat(g.slug)},e.createElement("p",null,"Read More"),v||null)))}export{n as FeaturedBlog};
|
package/package.json
CHANGED
|
@@ -128,6 +128,7 @@ declare module "lm-web-controls" {
|
|
|
128
128
|
ish1?: boolean;
|
|
129
129
|
views: number;
|
|
130
130
|
categoryUrl?: string;
|
|
131
|
+
hasCategoryPages?: boolean;
|
|
131
132
|
};
|
|
132
133
|
|
|
133
134
|
type FeaturedBlogProps = {
|
|
@@ -137,6 +138,7 @@ declare module "lm-web-controls" {
|
|
|
137
138
|
category?: boolean;
|
|
138
139
|
categoryUrl?: string;
|
|
139
140
|
isH1?: boolean;
|
|
141
|
+
hasCategoryPages?: boolean;
|
|
140
142
|
};
|
|
141
143
|
|
|
142
144
|
type RelatedPostProps = {
|