nestiq-component-library 1.1.56 → 1.1.58

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.
Files changed (49) hide show
  1. package/dist/assets/images/{card-arrow-left.28090aba4b4f2006.svg → card-arrow-left.55343410142dad3f.svg} +4 -4
  2. package/dist/assets/images/{card-arrow-right.c60af4cbbd49f3aa.svg → card-arrow-right.60b3bf0e34c1800d.svg} +4 -4
  3. package/dist/assets/images/{more.1e158adc48fbb406.svg → more.ce14789c8d37e327.svg} +12 -12
  4. package/dist/components/MessagePopup/MessagePopUp.d.ts +5 -5
  5. package/dist/components/NewPropertyCard/NewPropertyCard.d.ts +3 -6
  6. package/dist/index.es.js +41 -113
  7. package/dist/index.es.js.map +1 -1
  8. package/dist/index.js +41 -113
  9. package/dist/index.js.map +1 -1
  10. package/dist/models/message.model.d.ts +7 -0
  11. package/nestiq-component-library-1.1.58.tgz +0 -0
  12. package/package.json +1 -1
  13. package/rollup.config.mjs +36 -35
  14. package/src/assets/images/card-arrow-left.svg +4 -4
  15. package/src/assets/images/card-arrow-right.svg +4 -4
  16. package/src/assets/images/more.svg +12 -12
  17. package/src/components/FloorPlanPopup/FloorPlanPopup.css +3 -3
  18. package/src/components/FloorPlanPopup/FloorPlanPopup.tsx +83 -83
  19. package/src/components/ImageListPopup/ImageListPopup.css +83 -83
  20. package/src/components/ImageListPopup/ImageListPopup.tsx +141 -141
  21. package/src/components/MessagePopup/MessagePopUp.tsx +156 -172
  22. package/src/components/NewPropertyCard/NewPropertyCard.tsx +283 -315
  23. package/src/components/Popup/Popup.tsx +29 -29
  24. package/src/components/ToastWrapper/ToastWrapper.tsx +25 -25
  25. package/src/models/message.model.ts +7 -0
  26. package/dist/assets/images/Icon_rightArrow.svg +0 -3
  27. package/dist/assets/images/LayersIcon.svg +0 -5
  28. package/dist/assets/images/blackarrow-Right.svg +0 -3
  29. package/dist/assets/images/blckarrow-Left.svg +0 -3
  30. package/dist/assets/images/chevron-left.svg +0 -3
  31. package/dist/assets/images/default-property.jpg +0 -0
  32. package/dist/assets/images/heartIcon.svg +0 -3
  33. package/dist/assets/images/icon-close-white.webp +0 -0
  34. package/dist/assets/images/icon_checkmark.9b48c4a4bc651b08.svg +0 -10
  35. package/dist/assets/images/icon_close 2.e41bb9a4db48e048.png +0 -0
  36. package/dist/assets/images/icon_close_2.png +0 -0
  37. package/dist/assets/images/icon_gallery.svg +0 -4
  38. package/dist/assets/images/icon_map.svg +0 -10
  39. package/dist/assets/images/icon_share_1.svg +0 -3
  40. package/dist/assets/images/layer_icon.svg +0 -5
  41. package/dist/assets/images/locationIcon.0af399c78e0cdc20.svg +0 -4
  42. package/dist/assets/images/locationIcon.svg +0 -4
  43. package/dist/assets/images/locationIconBlack.svg +0 -4
  44. package/dist/assets/images/no-image-icon.png +0 -0
  45. package/dist/assets/images/warning.6f99cb4c6a048b47.svg +0 -11
  46. package/dist/components/Button/Button.js +0 -6
  47. package/dist/components/ImageListPopup/ImageListPopup.js +0 -26
  48. package/dist/components/Popup/Popup.js +0 -12
  49. package/dist/components/SharePopup/PopUp.d.ts +0 -7
package/rollup.config.mjs CHANGED
@@ -1,35 +1,36 @@
1
- import typescript from "rollup-plugin-typescript2";
2
- import url from "@rollup/plugin-url";
3
- import postcss from "rollup-plugin-postcss";
4
- import pkg from "./package.json" assert { type: "json" };
5
-
6
- export default {
7
- input: "src/index.tsx",
8
- output: [
9
- {
10
- file: pkg.main,
11
- format: "cjs",
12
- sourcemap: true,
13
- },
14
- {
15
- file: pkg.module,
16
- format: "es",
17
- sourcemap: true,
18
- },
19
- ],
20
- external: ["react", "react-dom"],
21
- plugins: [
22
- typescript(),
23
- postcss({
24
- extensions: [".css"],
25
- }),
26
- url({
27
- include: ['**/*.svg', '**/*.png', '**/*.jpg', '**/*.jpeg', '**/*.gif'],
28
- limit: 0,
29
- emitFiles: true,
30
- fileName: '[name].[hash][extname]',
31
- destDir: 'dist/assets/images',
32
- publicPath: `/static/media/`
33
- })
34
- ],
35
- };
1
+ import typescript from "rollup-plugin-typescript2";
2
+ import url from "@rollup/plugin-url";
3
+ import postcss from "rollup-plugin-postcss";
4
+ // import pkg from "./package.json" assert { type: "json" };
5
+ import pkg from "./package.json" with { type: "json" };
6
+
7
+ export default {
8
+ input: "src/index.tsx",
9
+ output: [
10
+ {
11
+ file: pkg.main,
12
+ format: "cjs",
13
+ sourcemap: true,
14
+ },
15
+ {
16
+ file: pkg.module,
17
+ format: "es",
18
+ sourcemap: true,
19
+ },
20
+ ],
21
+ external: ["react", "react-dom"],
22
+ plugins: [
23
+ typescript(),
24
+ postcss({
25
+ extensions: [".css"],
26
+ }),
27
+ url({
28
+ include: ['**/*.svg', '**/*.png', '**/*.jpg', '**/*.jpeg', '**/*.gif'],
29
+ limit: 0,
30
+ emitFiles: true,
31
+ fileName: '[name].[hash][extname]',
32
+ destDir: 'dist/assets/images',
33
+ publicPath: `/static/media/`
34
+ })
35
+ ],
36
+ };
@@ -1,4 +1,4 @@
1
- <svg width="50" height="50" viewBox="0 0 50 50" fill="none" xmlns="http://www.w3.org/2000/svg">
2
- <rect width="50" height="50" rx="25" fill="#fff" fill-opacity=".8"/>
3
- <path fill-rule="evenodd" clip-rule="evenodd" d="M29.127 17.18a.614.614 0 0 1 0 .872L22.177 25l6.95 6.948a.617.617 0 0 1-.871.872l-7.384-7.384a.616.616 0 0 1 0-.872l7.384-7.383a.616.616 0 0 1 .871 0z" fill="#000"/>
4
- </svg>
1
+ <svg width="50" height="50" viewBox="0 0 50 50" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <rect width="50" height="50" rx="25" fill="#fff" fill-opacity=".8"/>
3
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M29.127 17.18a.614.614 0 0 1 0 .872L22.177 25l6.95 6.948a.617.617 0 0 1-.871.872l-7.384-7.384a.616.616 0 0 1 0-.872l7.384-7.383a.616.616 0 0 1 .871 0z" fill="#000"/>
4
+ </svg>
@@ -1,4 +1,4 @@
1
- <svg width="50" height="50" viewBox="0 0 50 50" fill="none" xmlns="http://www.w3.org/2000/svg">
2
- <rect width="50" height="50" rx="25" fill="#fff" fill-opacity=".8"/>
3
- <path fill-rule="evenodd" clip-rule="evenodd" d="M20.873 32.82a.614.614 0 0 1 0-.872L27.823 25l-6.95-6.948a.617.617 0 0 1 .871-.872l7.384 7.384a.616.616 0 0 1 0 .872l-7.384 7.383a.616.616 0 0 1-.871 0z" fill="#000"/>
4
- </svg>
1
+ <svg width="50" height="50" viewBox="0 0 50 50" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <rect width="50" height="50" rx="25" fill="#fff" fill-opacity=".8"/>
3
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M20.873 32.82a.614.614 0 0 1 0-.872L27.823 25l-6.95-6.948a.617.617 0 0 1 .871-.872l7.384 7.384a.616.616 0 0 1 0 .872l-7.384 7.383a.616.616 0 0 1-.871 0z" fill="#000"/>
4
+ </svg>
@@ -1,12 +1,12 @@
1
- <svg width="4" height="20" viewBox="0 0 4 20" fill="none" xmlns="http://www.w3.org/2000/svg">
2
- <g clip-path="url(#fxcoqj8dma)" fill="#313131">
3
- <circle cx="2" cy="2" r="2"/>
4
- <circle cx="2" cy="10" r="2"/>
5
- <circle cx="2" cy="18" r="2"/>
6
- </g>
7
- <defs>
8
- <clipPath id="fxcoqj8dma">
9
- <path fill="#fff" d="M0 0h4v20H0z"/>
10
- </clipPath>
11
- </defs>
12
- </svg>
1
+ <svg width="4" height="20" viewBox="0 0 4 20" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <g clip-path="url(#fxcoqj8dma)" fill="#313131">
3
+ <circle cx="2" cy="2" r="2"/>
4
+ <circle cx="2" cy="10" r="2"/>
5
+ <circle cx="2" cy="18" r="2"/>
6
+ </g>
7
+ <defs>
8
+ <clipPath id="fxcoqj8dma">
9
+ <path fill="#fff" d="M0 0h4v20H0z"/>
10
+ </clipPath>
11
+ </defs>
12
+ </svg>
@@ -1,3 +1,3 @@
1
- .mainImage {
2
- height: 80%;
3
- }
1
+ .mainImage {
2
+ height: 80%;
3
+ }
@@ -1,83 +1,83 @@
1
- import React, { useEffect, useState } from "react";
2
- import iconClose from "../../assets/images/close.png";
3
-
4
- interface PopupProps {
5
- contentUrl: string;
6
- onCloseClick: () => void;
7
- }
8
-
9
- const FloorPlanPopup: React.FC<PopupProps> = ({ contentUrl, onCloseClick }) => {
10
- const [isContentImage, setIsContentImage] = useState(false);
11
-
12
- useEffect(() => {
13
- if (contentUrl) {
14
- const fileFormat = contentUrl.split(".").pop();
15
- if (
16
- fileFormat === "png" ||
17
- fileFormat === "jpg" ||
18
- fileFormat === "jpeg" ||
19
- fileFormat === "svg"
20
- ) {
21
- setIsContentImage(true);
22
- }
23
- }
24
- }, [contentUrl]);
25
-
26
- const downloadButtonClickHandler = (): void => {
27
- // Create a temporary anchor element
28
- const link = document.createElement("a");
29
- link.href = contentUrl;
30
- link.setAttribute("download", ""); // This attribute hints the browser to download the file
31
-
32
- // Append the anchor to the body and click it to trigger the download
33
- document.body.appendChild(link);
34
- link.click();
35
-
36
- // Clean up: remove the anchor element
37
- document.body.removeChild(link);
38
- };
39
- return (
40
- <div className="popup-overlay">
41
- <div className=" d-flex w-50 flex-column col-6 ">
42
- <div className="d-flex align-self-end me-5 mt-5">
43
- <img
44
- src={iconClose}
45
- alt="close"
46
- className="closeIcon mt-5"
47
- onClick={onCloseClick}
48
- />
49
- </div>
50
- <div className="d-flex justify-content-center">
51
- <div className="p-2 bd-highlight">
52
- {isContentImage && (
53
- <div
54
- className="rounded-5 mainImage"
55
- style={{
56
- backgroundImage: `url(${contentUrl})`,
57
- height: "350px",
58
- width: "600px",
59
- backgroundSize: "cover",
60
- backgroundPosition: "center",
61
- }}
62
- ></div>
63
- )}
64
- {!isContentImage && (
65
- <div className="text-white text-center">
66
- No Preview Available
67
- <button
68
- className="btn btn-info"
69
- onClick={downloadButtonClickHandler}
70
- >
71
- {" "}
72
- Download{" "}
73
- </button>
74
- </div>
75
- )}
76
- </div>
77
- </div>
78
- </div>
79
- </div>
80
- );
81
- };
82
-
83
- export default FloorPlanPopup;
1
+ import React, { useEffect, useState } from "react";
2
+ import iconClose from "../../assets/images/close.png";
3
+
4
+ interface PopupProps {
5
+ contentUrl: string;
6
+ onCloseClick: () => void;
7
+ }
8
+
9
+ const FloorPlanPopup: React.FC<PopupProps> = ({ contentUrl, onCloseClick }) => {
10
+ const [isContentImage, setIsContentImage] = useState(false);
11
+
12
+ useEffect(() => {
13
+ if (contentUrl) {
14
+ const fileFormat = contentUrl.split(".").pop();
15
+ if (
16
+ fileFormat === "png" ||
17
+ fileFormat === "jpg" ||
18
+ fileFormat === "jpeg" ||
19
+ fileFormat === "svg"
20
+ ) {
21
+ setIsContentImage(true);
22
+ }
23
+ }
24
+ }, [contentUrl]);
25
+
26
+ const downloadButtonClickHandler = (): void => {
27
+ // Create a temporary anchor element
28
+ const link = document.createElement("a");
29
+ link.href = contentUrl;
30
+ link.setAttribute("download", ""); // This attribute hints the browser to download the file
31
+
32
+ // Append the anchor to the body and click it to trigger the download
33
+ document.body.appendChild(link);
34
+ link.click();
35
+
36
+ // Clean up: remove the anchor element
37
+ document.body.removeChild(link);
38
+ };
39
+ return (
40
+ <div className="popup-overlay">
41
+ <div className=" d-flex w-50 flex-column col-6 ">
42
+ <div className="d-flex align-self-end me-5 mt-5">
43
+ <img
44
+ src={iconClose}
45
+ alt="close"
46
+ className="closeIcon mt-5"
47
+ onClick={onCloseClick}
48
+ />
49
+ </div>
50
+ <div className="d-flex justify-content-center">
51
+ <div className="p-2 bd-highlight">
52
+ {isContentImage && (
53
+ <div
54
+ className="rounded-5 mainImage"
55
+ style={{
56
+ backgroundImage: `url(${contentUrl})`,
57
+ height: "350px",
58
+ width: "600px",
59
+ backgroundSize: "cover",
60
+ backgroundPosition: "center",
61
+ }}
62
+ ></div>
63
+ )}
64
+ {!isContentImage && (
65
+ <div className="text-white text-center">
66
+ No Preview Available
67
+ <button
68
+ className="btn btn-info"
69
+ onClick={downloadButtonClickHandler}
70
+ >
71
+ {" "}
72
+ Download{" "}
73
+ </button>
74
+ </div>
75
+ )}
76
+ </div>
77
+ </div>
78
+ </div>
79
+ </div>
80
+ );
81
+ };
82
+
83
+ export default FloorPlanPopup;
@@ -1,83 +1,83 @@
1
- .popup-header {
2
- display: flex;
3
- justify-content: center;
4
- align-items: center;
5
- width: 100%;
6
- padding: 1rem;
7
- position: absolute;
8
- top: 0;
9
- }
10
-
11
- .popup-title {
12
- color: white;
13
- font-size: 24px;
14
- font-weight: bold;
15
- }
16
-
17
- .btn-close {
18
- position: absolute;
19
- right: 1rem;
20
- top: 1rem;
21
- background: none;
22
- border: none;
23
- color: white;
24
- font-size: 24px;
25
- cursor: pointer;
26
- }
27
-
28
- .popup-body {
29
- display: flex;
30
- justify-content: center;
31
- align-items: center;
32
- padding: 1rem;
33
- position: relative;
34
- flex: 1;
35
- }
36
-
37
- .main-image {
38
- max-width: 100%;
39
- max-height: 80vh;
40
- border-radius: 8px;
41
- }
42
-
43
- .btn-prev,
44
- .btn-next {
45
- background: none;
46
- border: none;
47
- color: white;
48
- font-size: 48px;
49
- cursor: pointer;
50
- position: absolute;
51
- top: 50%;
52
- transform: translateY(-50%);
53
- }
54
-
55
- .btn-prev {
56
- left: 10px;
57
- }
58
-
59
- .btn-next {
60
- right: 10px;
61
- }
62
-
63
- .popup-thumbnails {
64
- display: flex;
65
- justify-content: center;
66
- align-items: center;
67
- gap: 10px;
68
- padding: 1rem;
69
- }
70
-
71
- .thumbnail {
72
- width: 60px;
73
- height: 60px;
74
- object-fit: cover;
75
- border-radius: 8px;
76
- cursor: pointer;
77
- opacity: 0.6;
78
- }
79
-
80
- .thumbnail.active {
81
- border: 2px solid white;
82
- opacity: 1;
83
- }
1
+ .popup-header {
2
+ display: flex;
3
+ justify-content: center;
4
+ align-items: center;
5
+ width: 100%;
6
+ padding: 1rem;
7
+ position: absolute;
8
+ top: 0;
9
+ }
10
+
11
+ .popup-title {
12
+ color: white;
13
+ font-size: 24px;
14
+ font-weight: bold;
15
+ }
16
+
17
+ .btn-close {
18
+ position: absolute;
19
+ right: 1rem;
20
+ top: 1rem;
21
+ background: none;
22
+ border: none;
23
+ color: white;
24
+ font-size: 24px;
25
+ cursor: pointer;
26
+ }
27
+
28
+ .popup-body {
29
+ display: flex;
30
+ justify-content: center;
31
+ align-items: center;
32
+ padding: 1rem;
33
+ position: relative;
34
+ flex: 1;
35
+ }
36
+
37
+ .main-image {
38
+ max-width: 100%;
39
+ max-height: 80vh;
40
+ border-radius: 8px;
41
+ }
42
+
43
+ .btn-prev,
44
+ .btn-next {
45
+ background: none;
46
+ border: none;
47
+ color: white;
48
+ font-size: 48px;
49
+ cursor: pointer;
50
+ position: absolute;
51
+ top: 50%;
52
+ transform: translateY(-50%);
53
+ }
54
+
55
+ .btn-prev {
56
+ left: 10px;
57
+ }
58
+
59
+ .btn-next {
60
+ right: 10px;
61
+ }
62
+
63
+ .popup-thumbnails {
64
+ display: flex;
65
+ justify-content: center;
66
+ align-items: center;
67
+ gap: 10px;
68
+ padding: 1rem;
69
+ }
70
+
71
+ .thumbnail {
72
+ width: 60px;
73
+ height: 60px;
74
+ object-fit: cover;
75
+ border-radius: 8px;
76
+ cursor: pointer;
77
+ opacity: 0.6;
78
+ }
79
+
80
+ .thumbnail.active {
81
+ border: 2px solid white;
82
+ opacity: 1;
83
+ }