allaw-ui 1.0.137 → 1.0.140

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.
@@ -33,7 +33,7 @@
33
33
  cursor: pointer;
34
34
  outline: none;
35
35
  font-family: "Open Sans";
36
- font-size: 14px;
36
+ font-size: 16px;
37
37
  font-style: normal;
38
38
  font-weight: 500;
39
39
  line-height: normal;
@@ -1,7 +1,6 @@
1
1
  import React from "react";
2
2
  import styles from "./BlogCard.module.css";
3
3
  import Link from "next/link";
4
- import OtherStatusTag from "../../atoms/tags/OtherStatusTag";
5
4
  import TinyInfo from "../../atoms/typography/TinyInfo";
6
5
  import Image from "next/image";
7
6
  var BlogTopSection = function (_a) {
@@ -14,7 +13,7 @@ var BlogBottomSection = function (_a) {
14
13
  React.createElement("div", { className: styles.blogBottomSectionUp },
15
14
  React.createElement("div", { className: styles.tagsContainer }, tags.slice(0, 2).map(function (tag, index) {
16
15
  var validatedTag = tag.trim().length > 12 ? "".concat(tag.slice(0, 12), "...") : tag;
17
- return React.createElement(OtherStatusTag, { key: index, label: validatedTag });
16
+ return (React.createElement("span", { key: index, className: styles.blogTypeTag }, validatedTag));
18
17
  })),
19
18
  React.createElement(TinyInfo, { text: date.toLocaleDateString(), variant: "medium14", color: "mid-grey" })),
20
19
  React.createElement("div", { className: styles.blogSplitSection }),
@@ -4,7 +4,7 @@
4
4
  flex-direction: column;
5
5
  align-items: flex-start;
6
6
  width: 100%;
7
- max-width: 361px;
7
+ max-width: 280px;
8
8
  box-shadow: 0px 1px 20px 0px rgba(213, 233, 246, 0.8);
9
9
  border-radius: 16px;
10
10
  overflow: hidden;
@@ -12,7 +12,7 @@
12
12
  cursor: pointer;
13
13
  border: none;
14
14
  height: 100%;
15
- max-height: 385px;
15
+ max-height: 380px;
16
16
  }
17
17
 
18
18
  .blogContainer:hover {
@@ -20,13 +20,13 @@
20
20
  }
21
21
 
22
22
  .blogTopSection {
23
- height: 200px;
23
+ height: 150px;
24
24
  object-fit: contain;
25
25
  width: 100%;
26
26
  }
27
27
 
28
28
  .blogSplitSection {
29
- width: 329px;
29
+ width: 100%;
30
30
  height: 1px;
31
31
  background: #f1f4f8;
32
32
  }
@@ -55,6 +55,7 @@
55
55
  -webkit-line-clamp: 1;
56
56
  -webkit-box-orient: vertical;
57
57
  overflow: hidden;
58
+ text-align: left;
58
59
  color: var(--Primary-Mid-black, #171e25);
59
60
  font-family: Poppins;
60
61
  font-size: 18px;
@@ -72,6 +73,7 @@
72
73
  -webkit-line-clamp: 3;
73
74
  -webkit-box-orient: vertical;
74
75
  overflow: hidden;
76
+ text-align: left;
75
77
  text-overflow: ellipsis;
76
78
  white-space: normal;
77
79
  word-wrap: break-word;
@@ -101,6 +103,23 @@
101
103
  overflow: hidden;
102
104
  }
103
105
 
106
+ .blogTypeTag {
107
+ font-size: 12px;
108
+ padding: 4px 6px;
109
+ border-radius: 0.3rem;
110
+ font-style: normal;
111
+ font-weight: 600;
112
+ font-family: "Open Sans";
113
+ text-align: center;
114
+ height: fit-content;
115
+ width: fit-content;
116
+ color: var(--Primary-Dark-grey, var(--dark-grey, #456073));
117
+ background-color: var(--primary-light-grey, #f4f7fb);
118
+ border: none;
119
+ display: inline-block;
120
+ line-height: 1;
121
+ }
122
+
104
123
  .blogBottomSectionUp {
105
124
  display: flex;
106
125
  justify-content: space-between;
@@ -0,0 +1,12 @@
1
+ import React from "react";
2
+ export type BlogFooterProps = {
3
+ job: "Avocat" | "Notaire" | "Commissaire de justice";
4
+ firstName: string;
5
+ lastName: string;
6
+ address: string;
7
+ profileUrl: string;
8
+ description: string;
9
+ imageUrl: string;
10
+ };
11
+ declare function BlogFooter({ job, firstName, lastName, address, profileUrl, description, imageUrl, }: BlogFooterProps): React.JSX.Element;
12
+ export default BlogFooter;
@@ -0,0 +1,14 @@
1
+ import React from "react";
2
+ import Link from "next/link";
3
+ import styles from "./BlogFooter.module.css";
4
+ import ProCard from "../../molecules/proCard/ProCard";
5
+ function BlogFooter(_a) {
6
+ var job = _a.job, firstName = _a.firstName, lastName = _a.lastName, address = _a.address, profileUrl = _a.profileUrl, description = _a.description, imageUrl = _a.imageUrl;
7
+ return (React.createElement("footer", { className: styles.BlogFooterContainer },
8
+ React.createElement("div", { className: styles.BlogFooterCard },
9
+ React.createElement("p", { className: styles.BlogFooterTitle }, description),
10
+ React.createElement(Link, { href: profileUrl, passHref: true, legacyBehavior: true },
11
+ React.createElement("a", { className: styles.LinkWrapper, "aria-label": "Profil de ".concat(firstName, " ").concat(lastName) },
12
+ React.createElement(ProCard, { job: job, firstName: firstName, lastName: lastName, address: address, profileUrl: profileUrl, imageUrl: imageUrl }))))));
13
+ }
14
+ export default BlogFooter;
@@ -0,0 +1,48 @@
1
+ .BlogFooterContainer {
2
+ display: flex;
3
+ justify-content: flex-end;
4
+ background-color: white;
5
+ padding: 16px;
6
+ width: 100%;
7
+ max-width: 1000px;
8
+ }
9
+
10
+ .BlogFooterCard {
11
+ display: flex;
12
+ flex-direction: column;
13
+ max-width: 370px;
14
+ width: 100%;
15
+ gap: 20px;
16
+ }
17
+
18
+ .BlogFooterTitle {
19
+ width: 100%;
20
+ color: var(--Primary-Mid-black, #171e25);
21
+ text-align: left;
22
+ font-family: Poppins;
23
+ font-size: 18px;
24
+ font-style: normal;
25
+ font-weight: 600;
26
+ line-height: normal;
27
+ margin: 0;
28
+ max-width: 100%;
29
+ overflow: hidden;
30
+ text-overflow: ellipsis;
31
+ display: -webkit-box;
32
+ line-clamp: 3;
33
+ -webkit-line-clamp: 3;
34
+ -webkit-box-orient: vertical;
35
+ }
36
+
37
+ .LinkWrapper {
38
+ text-decoration: none;
39
+ display: block;
40
+ width: 100%;
41
+ }
42
+
43
+ @media (max-width: 720px) {
44
+ .BlogFooterContainer {
45
+ justify-content: center;
46
+ padding: 12px;
47
+ }
48
+ }
@@ -0,0 +1,60 @@
1
+ declare namespace _default {
2
+ export let title: string;
3
+ export { BlogFooter as component };
4
+ export let tags: string[];
5
+ export namespace argTypes {
6
+ export namespace job {
7
+ let control: string;
8
+ let description: string;
9
+ }
10
+ export namespace firstName {
11
+ let control_1: string;
12
+ export { control_1 as control };
13
+ let description_1: string;
14
+ export { description_1 as description };
15
+ }
16
+ export namespace lastName {
17
+ let control_2: string;
18
+ export { control_2 as control };
19
+ let description_2: string;
20
+ export { description_2 as description };
21
+ }
22
+ export namespace address {
23
+ let control_3: string;
24
+ export { control_3 as control };
25
+ let description_3: string;
26
+ export { description_3 as description };
27
+ }
28
+ export namespace profileUrl {
29
+ let control_4: string;
30
+ export { control_4 as control };
31
+ let description_4: string;
32
+ export { description_4 as description };
33
+ }
34
+ export namespace imageUrl {
35
+ let control_5: string;
36
+ export { control_5 as control };
37
+ let description_5: string;
38
+ export { description_5 as description };
39
+ }
40
+ export namespace description_6 {
41
+ let control_6: string;
42
+ export { control_6 as control };
43
+ let description_7: string;
44
+ export { description_7 as description };
45
+ }
46
+ export { description_6 as description };
47
+ }
48
+ export namespace parameters {
49
+ namespace docs {
50
+ export namespace description_8 {
51
+ let component: string;
52
+ }
53
+ export { description_8 as description };
54
+ }
55
+ }
56
+ }
57
+ export default _default;
58
+ export const Default: any;
59
+ export const WithLongDescription: any;
60
+ import BlogFooter from "./BlogFooter";
@@ -0,0 +1,67 @@
1
+ var __assign = (this && this.__assign) || function () {
2
+ __assign = Object.assign || function(t) {
3
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
4
+ s = arguments[i];
5
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
6
+ t[p] = s[p];
7
+ }
8
+ return t;
9
+ };
10
+ return __assign.apply(this, arguments);
11
+ };
12
+ import React from "react";
13
+ import BlogFooter, { BlogFooterProps } from "./BlogFooter";
14
+ export default {
15
+ title: "Components/molecules/Blog/BlogFooter",
16
+ component: BlogFooter,
17
+ tags: ["autodocs"],
18
+ argTypes: {
19
+ job: { control: "text", description: "Le métier de la personne." },
20
+ firstName: { control: "text", description: "Le prénom de la personne." },
21
+ lastName: {
22
+ control: "text",
23
+ description: "Le nom de famille de la personne.",
24
+ },
25
+ address: { control: "text", description: "L'adresse de la personne." },
26
+ profileUrl: {
27
+ control: "text",
28
+ description: "L'URL du profil ou de l'image de la personne.",
29
+ },
30
+ imageUrl: {
31
+ control: "text",
32
+ description: "L'URL de l'image de la carte ou de la personne.",
33
+ },
34
+ description: {
35
+ control: "text",
36
+ description: "Une description ou un titre lié au blog.",
37
+ },
38
+ },
39
+ parameters: {
40
+ docs: {
41
+ description: {
42
+ component: "Le composant `BlogFooter` affiche une section de pied de page avec des informations sur une personne, incluant un métier, un nom, une adresse, une description et une image.",
43
+ },
44
+ },
45
+ },
46
+ };
47
+ var Template = function (args) { return React.createElement(BlogFooter, __assign({}, args)); };
48
+ export var Default = Template.bind({});
49
+ Default.args = {
50
+ job: "Avocat",
51
+ firstName: "Jean",
52
+ lastName: "Dupont",
53
+ address: "123 Rue de la Loi, Paris",
54
+ profileUrl: "https://via.placeholder.com/150",
55
+ description: "À propos de l'auteur",
56
+ imageUrl: "https://plus.unsplash.com/premium_photo-1698084059560-9a53de7b816b?w=500&auto=format&fit=crop&q=60&ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxzZWFyY2h8NXx8YXZvY2F0fGVufDB8fDB8fHww",
57
+ };
58
+ export var WithLongDescription = Template.bind({});
59
+ WithLongDescription.args = {
60
+ job: "Notaire",
61
+ firstName: "Marie",
62
+ lastName: "Durand",
63
+ address: "45 Boulevard Haussmann, Paris",
64
+ profileUrl: "https://via.placeholder.com/150",
65
+ description: "Marie Durand est une notaire expérimentée avec plus de 15 ans d'expérience dans le domaine juridique. Elle est spécialisée dans les contrats immobiliers et la gestion des patrimoines complexes.",
66
+ imageUrl: "https://images.unsplash.com/photo-1587986077033-5fccb5819f5b?w=400&q=80",
67
+ };
@@ -0,0 +1,2 @@
1
+ export { default as BlogFooter } from "./BlogFooter";
2
+ export type { BlogFooterProps } from "./BlogFooter";
@@ -0,0 +1 @@
1
+ export { default as BlogFooter } from "./BlogFooter";
@@ -5,7 +5,7 @@ import styles from "./BlogHeader.module.css";
5
5
  function BlogHeader(_a) {
6
6
  var title = _a.title, author = _a.author, date = _a.date, timeToRead = _a.timeToRead, profession = _a.profession, imageBlog = _a.imageBlog;
7
7
  return (React.createElement("article", { className: styles.blogContainerWrapper },
8
- React.createElement("div", { className: styles.blogContainer },
8
+ React.createElement("header", { className: styles.blogContainer },
9
9
  React.createElement("h1", { className: styles.title }, title),
10
10
  React.createElement("div", { className: styles.blogInfoContainer },
11
11
  React.createElement("time", { className: styles.blogDate, dateTime: date.toISOString(), "aria-label": "Date de publication" },
@@ -5,10 +5,6 @@ import Image from "next/image";
5
5
  var NoPhoto = "/assets/NoPhoto.png";
6
6
  var ProCard = function (_a) {
7
7
  var imageUrl = _a.imageUrl, job = _a.job, firstName = _a.firstName, lastName = _a.lastName, address = _a.address, profileUrl = _a.profileUrl, _b = _a.isPro, isPro = _b === void 0 ? false : _b;
8
- console.log("Données reçues dans ProCard:", {
9
- address: address,
10
- hasAddress: Boolean(address && /[a-zA-Z0-9]/.test(address)),
11
- });
12
8
  var uppercaseJob = job.toUpperCase();
13
9
  return (React.createElement("div", { className: "pro-card" },
14
10
  React.createElement("div", { className: "pro-card-content" },
package/dist/index.d.ts CHANGED
@@ -71,3 +71,5 @@ export { default as BlogText } from "./components/molecules/blogText/BlogText";
71
71
  export type { BlogTextProps } from "./components/molecules/blogText/BlogText";
72
72
  export { default as blogTextImageBlock } from "./components/molecules/blogTextImageBlock/BlogTextImageBlock";
73
73
  export type { BlogTextImageBlockProps } from "./components/molecules/blogTextImageBlock/BlogTextImageBlock";
74
+ export { default as blogFooter } from "./components/molecules/blogFooter/BlogFooter";
75
+ export type { BlogFooterProps } from "./components/molecules/blogFooter/BlogFooter";
package/dist/index.js CHANGED
@@ -80,7 +80,9 @@ export { default as Breadcrumb } from "./components/molecules/breadcrumb/Breadcr
80
80
  export { default as ProCard } from "./components/molecules/proCard/ProCard";
81
81
  // Pagination
82
82
  export { default as Pagination } from "./components/molecules/pagination/Pagination";
83
+ // Blog
83
84
  export { default as BlogHeader } from "./components/molecules/blogHeader/BlogHeader";
84
85
  export { default as BlogCard } from "./components/molecules/blogCard/BlogCard";
85
86
  export { default as BlogText } from "./components/molecules/blogText/BlogText";
86
87
  export { default as blogTextImageBlock } from "./components/molecules/blogTextImageBlock/BlogTextImageBlock";
88
+ export { default as blogFooter } from "./components/molecules/blogFooter/BlogFooter";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "allaw-ui",
3
- "version": "1.0.137",
3
+ "version": "1.0.140",
4
4
  "description": "Composants UI pour l'application Allaw",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.esm.js",