allaw-ui 1.0.115 → 1.0.120

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.
@@ -6,6 +6,8 @@ export type BlogArticleProps = {
6
6
  Date: Date;
7
7
  Title: string;
8
8
  Description: string;
9
+ Preview?: boolean;
10
+ onClick?: () => void;
9
11
  };
10
12
  declare const BlogArticle: React.FC<BlogArticleProps>;
11
13
  export default BlogArticle;
@@ -25,9 +25,12 @@ var BlogBottomSection = function (_a) {
25
25
  React.createElement(TinyInfo, { variant: "medium14", text: Description, color: "noir" })))));
26
26
  };
27
27
  var BlogArticle = function (_a) {
28
- var Article_URL = _a.Article_URL, Image_URL = _a.Image_URL, Tags = _a.Tags, Date = _a.Date, Title = _a.Title, Description = _a.Description;
29
- return (React.createElement(Link, { href: Article_URL, className: styles.blogContainer },
30
- React.createElement(BlogTopSection, { Image_URL: Image_URL, Title: Title }),
31
- React.createElement(BlogBottomSection, { Tags: Tags, Date: Date, Title: Title, Description: Description })));
28
+ var Article_URL = _a.Article_URL, Image_URL = _a.Image_URL, Tags = _a.Tags, Date = _a.Date, Title = _a.Title, Description = _a.Description, _b = _a.Preview, Preview = _b === void 0 ? false : _b, onClick = _a.onClick;
29
+ return (React.createElement(React.Fragment, null, onClick ? React.createElement("button", { className: styles.blogContainer, onClick: function () { return onClick && onClick(); } },
30
+ !Preview && React.createElement(BlogTopSection, { Image_URL: Image_URL, Title: Title }),
31
+ React.createElement(BlogBottomSection, { Tags: Tags, Date: Date, Title: Title, Description: Description })) :
32
+ React.createElement(Link, { href: Article_URL, className: styles.blogContainer },
33
+ !Preview && React.createElement(BlogTopSection, { Image_URL: Image_URL, Title: Title }),
34
+ React.createElement(BlogBottomSection, { Tags: Tags, Date: Date, Title: Title, Description: Description }))));
32
35
  };
33
36
  export default BlogArticle;
@@ -9,6 +9,7 @@
9
9
  overflow: hidden;
10
10
  transition: transform 0.2s ease;
11
11
  cursor: pointer;
12
+ border: none;
12
13
  }
13
14
 
14
15
  .blogContainer:hover {
package/dist/index.d.ts CHANGED
@@ -63,3 +63,5 @@ export { default as Pagination } from "./components/molecules/pagination/Paginat
63
63
  export type { PaginationProps } from "./components/molecules/pagination/Pagination";
64
64
  export { default as BlogTextBlock } from './components/molecules/BlogTextBlock/BlogTextBlock';
65
65
  export type { BlogTextBlockProps } from './components/molecules/BlogTextBlock/BlogTextBlock';
66
+ export { default as BlogArticle } from './components/molecules/blogArticle/BlogArticle';
67
+ export type { BlogArticleProps } from './components/molecules/blogArticle/BlogArticle';
package/dist/index.js CHANGED
@@ -80,3 +80,4 @@ export { default as ProCard } from "./components/molecules/proCard/ProCard";
80
80
  // Pagination
81
81
  export { default as Pagination } from "./components/molecules/pagination/Pagination";
82
82
  export { default as BlogTextBlock } from './components/molecules/BlogTextBlock/BlogTextBlock';
83
+ export { default as BlogArticle } from './components/molecules/blogArticle/BlogArticle';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "allaw-ui",
3
- "version": "1.0.115",
3
+ "version": "1.0.120",
4
4
  "description": "Composants UI pour l'application Allaw",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.esm.js",