@builder6/rooms 0.15.4 → 0.15.6

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,5 +1,5 @@
1
- import type { CommentEmailAsReactData } from "@liveblocks/emails";
2
- import type { CompanyInfo, RoomInfo } from "./_lib/types";
1
+ import type { CommentEmailAsReactData } from '@liveblocks/emails';
2
+ import type { CompanyInfo, RoomInfo } from './_lib/types';
3
3
  type UnreadMentionEmailProps = {
4
4
  company: CompanyInfo;
5
5
  room: RoomInfo;
@@ -35,47 +35,14 @@ var __importStar = (this && this.__importStar) || (function () {
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
36
  exports.default = UnreadMentionEmail;
37
37
  const components_1 = require("@react-email/components");
38
- const getProps_1 = require("./_utils/getProps");
39
38
  const layout_1 = require("./_components/layout");
40
39
  const header_1 = require("./_components/header");
41
40
  const headline_1 = require("./_components/headline");
42
41
  const comment_1 = require("./_components/comment");
43
42
  const comments_1 = require("./_utils/comments");
44
43
  const React = __importStar(require("react"));
45
- const previewProps = {
46
- company: {
47
- name: "Acme Inc.",
48
- url: "https://liveblocks.io/comments",
49
- },
50
- room: {
51
- name: "User Research Strategy",
52
- url: "https://liveblocks.io/comments?room_id=project-proposal-q4",
53
- },
54
- comment: {
55
- id: "cm_2",
56
- threadId: "th_1",
57
- createdAt: new Date(2024, 2, 4, 4, 6, 47),
58
- author: {
59
- id: "emil-joyce@my-liveblocks-app.com",
60
- info: {
61
- name: "Emil Joyce",
62
- color: "#8594F0",
63
- avatar: "https://liveblocks.io/avatars/avatar-6.png",
64
- },
65
- },
66
- reactBody: (React.createElement(components_1.Text, { className: "text-sm m-0 text-black" },
67
- React.createElement("span", null,
68
- "For the user research phase, we'll need",
69
- " ",
70
- React.createElement("span", { "data-mention": true, className: "text-email-accent font-medium" }, "@Quinn Elton"),
71
- " ",
72
- "to lead the interviews and compile the findings. His expertise in qualitative research will be crucial for this stage."))),
73
- url: "https://liveblocks.io/comments?room_id=project-proposal-q4#cm_2",
74
- roomId: "project-proposal-q4",
75
- },
76
- };
77
44
  function UnreadMentionEmail(props) {
78
- const { company, room, comment } = (0, getProps_1.getProps)(props, previewProps);
45
+ const { company, room, comment } = props;
79
46
  const previewText = (0, comments_1.getUnreadMentionPreviewText)(comment, room.name);
80
47
  const headlineParts = (0, comments_1.getUnreadMentionHeadlineParts)(comment, room.name);
81
48
  return (React.createElement(layout_1.Layout, { preview: previewText },
@@ -1 +1 @@
1
- {"version":3,"file":"UnreadMention.js","sourceRoot":"","sources":["../../src/emails/UnreadMention.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA4DA,qCAeC;AA3ED,wDAAwD;AAGxD,gDAA6C;AAG7C,iDAA8C;AAC9C,iDAA8C;AAC9C,qDAAkD;AAClD,mDAAgD;AAChD,gDAG2B;AAC3B,6CAA+B;AAQ/B,MAAM,YAAY,GAA4B;IAC5C,OAAO,EAAE;QACP,IAAI,EAAE,WAAW;QACjB,GAAG,EAAE,gCAAgC;KACtC;IACD,IAAI,EAAE;QACJ,IAAI,EAAE,wBAAwB;QAC9B,GAAG,EAAE,4DAA4D;KAClE;IACD,OAAO,EAAE;QACP,EAAE,EAAE,MAAM;QACV,QAAQ,EAAE,MAAM;QAChB,SAAS,EAAE,IAAI,IAAI,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC;QACzC,MAAM,EAAE;YACN,EAAE,EAAE,kCAAkC;YACtC,IAAI,EAAE;gBACJ,IAAI,EAAE,YAAY;gBAClB,KAAK,EAAE,SAAS;gBAChB,MAAM,EAAE,4CAA4C;aACrD;SACF;QACD,SAAS,EAAE,CACT,oBAAC,iBAAI,IAAC,SAAS,EAAC,wBAAwB;YACtC;;gBAC0C,GAAG;gBAC3C,oDAAmB,SAAS,EAAC,+BAA+B,mBAErD;gBAAC,GAAG;yIAGN,CACF,CACR;QACD,GAA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WAAW;QAC1B,oBAAC,eAAM,oBAAK,OAAO,EAAI;QACvB,oBAAC,oBAAO;YACN,oBAAC,mBAAQ,IAAC,SAAS,EAAC,MAAM,EAAC,KAAK,EAAE,aAAa,GAAI;YACnD,oBAAC,iBAAO,oBAAK,OAAO,IAAE,aAAa,UAAG,CAC9B,CACH,CACV,CAAC;AACJ,CAAC"}
@@ -1,10 +1,10 @@
1
- import type { CommentEmailAsReactData } from "@liveblocks/emails";
2
- import type { CompanyInfo, RoomInfo } from "./_lib/types";
1
+ import type { CommentEmailAsReactData } from '@liveblocks/emails';
2
+ import type { CompanyInfo, RoomInfo } from './_lib/types';
3
3
  type UnreadRepliesEmailProps = {
4
4
  company: CompanyInfo;
5
5
  room: RoomInfo;
6
6
  comments: CommentEmailAsReactData[];
7
7
  };
8
- import * as React from "react";
8
+ import * as React from 'react';
9
9
  declare const UnreadRepliesEmail: (props: UnreadRepliesEmailProps) => React.ReactElement;
10
10
  export default UnreadRepliesEmail;
@@ -34,68 +34,21 @@ var __importStar = (this && this.__importStar) || (function () {
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
36
  const components_1 = require("@react-email/components");
37
- const getProps_1 = require("./_utils/getProps");
38
37
  const layout_1 = require("./_components/layout");
39
38
  const header_1 = require("./_components/header");
40
39
  const headline_1 = require("./_components/headline");
41
40
  const comment_1 = require("./_components/comment");
42
41
  const comments_1 = require("./_utils/comments");
43
42
  const React = __importStar(require("react"));
44
- const previewProps = {
45
- company: {
46
- name: "Acme Inc.",
47
- url: "https://liveblocks.io/comments",
48
- },
49
- room: {
50
- name: "Project Proposal - Q4",
51
- url: "https://liveblocks.io/comments?room_id=project-proposal-q4",
52
- },
53
- comments: [
54
- {
55
- id: "cm_0",
56
- threadId: "th_0",
57
- createdAt: new Date(2024, 2, 4, 4, 6, 47),
58
- author: {
59
- id: "tatum-paolo@example.com",
60
- info: {
61
- name: "Tatum Paolo",
62
- color: "#F0D885",
63
- avatar: "https://liveblocks.io/avatars/avatar-3.png",
64
- },
65
- },
66
- reactBody: (React.createElement(components_1.Text, { className: "text-sm m-0 text-black" },
67
- React.createElement("span", null, "I've reviewed this section and think we need a more detailed breakdown of the budget. It might help if we add a few more figures to illustrate the cost distribution over the next six months. Let me know if you'd like me to draft a version for you."))),
68
- url: "https://liveblocks.io/comments?room_id=project-proposal-q4#cm_0",
69
- roomId: "project-proposal-q4",
70
- },
71
- {
72
- id: "cm_1",
73
- threadId: "th_0",
74
- createdAt: new Date(2024, 2, 4, 5, 12, 35),
75
- author: {
76
- id: "anjali-wanda@example.com",
77
- info: {
78
- name: "Anjali Wanda",
79
- color: "#85EED6",
80
- avatar: "https://liveblocks.io/avatars/avatar-4.png",
81
- },
82
- },
83
- reactBody: (React.createElement(components_1.Text, { className: "text-sm text-black m-0" },
84
- React.createElement("span", null, "Looks good overall. Just a quick note on the timeline."))),
85
- url: "https://liveblocks.io/comments?room_id=project-proposal-q4#cm_1",
86
- roomId: "project-proposal-q4",
87
- },
88
- ],
89
- };
90
43
  const UnreadRepliesEmail = (props) => {
91
- const { company, room, comments } = (0, getProps_1.getProps)(props, previewProps);
44
+ const { company, room, comments } = props;
92
45
  const previewText = (0, comments_1.getUnreadRepliesPreviewText)(comments, room.name);
93
46
  const headlineParts = (0, comments_1.getUnreadRepliesHeadlineParts)(comments, room.name);
94
47
  return (React.createElement(layout_1.Layout, { preview: previewText },
95
48
  React.createElement(header_1.Header, Object.assign({}, company)),
96
49
  React.createElement(components_1.Section, null,
97
50
  React.createElement(headline_1.Headline, { className: "mb-4", parts: headlineParts }),
98
- comments.map((comment, index) => (React.createElement(comment_1.Comment, Object.assign({ key: comment.id, className: index > 0 ? "mt-3" : undefined }, comment, { isHighlighted: comments.length === 1 })))))));
51
+ comments.map((comment, index) => (React.createElement(comment_1.Comment, Object.assign({ key: comment.id, className: index > 0 ? 'mt-3' : undefined }, comment, { isHighlighted: comments.length === 1 })))))));
99
52
  };
100
53
  exports.default = UnreadRepliesEmail;
101
54
  //# sourceMappingURL=UnreadReplies.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"UnreadReplies.js","sourceRoot":"","sources":["../../src/emails/UnreadReplies.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wDAAwD;AAIxD,gDAA6C;AAC7C,iDAA8C;AAC9C,iDAA8C;AAC9C,qDAAkD;AAClD,mDAAgD;AAChD,gDAG2B;AAO3B,6CAA+B;AAE/B,MAAM,YAAY,GAA4B;IAC5C,OAAO,EAAE;QACP,IAAI,EAAE,WAAW;QACjB,GAAG,EAAE,gCAAgC;KACtC;IACD,IAAI,EAAE;QACJ,IAAI,EAAE,uBAAuB;QAC7B,GAAG,EAAE,4DAA4D;KAClE;IACD,QAAQ,EAAE;QACR;YACE,EAAE,EAAE,MAAM;YACV,QAAQ,EAAE,MAAM;YAChB,SAAS,EAAE,IAAI,IAAI,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC;YACzC,MAAM,EAAE;gBACN,EAAE,EAAE,yBAAyB;gBAC7B,IAAI,EAAE;oBACJ,IAAI,EAAE,aAAa;oBACnB,KAAK,EAAE,SAAS;oBAChB,MAAM,EAAE,4CAA4C;iBACrD;aACF;YACD,SAAS,EAAE,CACT,oBAAC,iBAAI,IAAC,SAAS,EAAC,wBAAwB;gBACtC,4RAKO,CACF,CACR;YACD,GAAG,EAAE,iEAAiE;YACtE,MAAM,EAAE,qBAAqB;SAC9B;QACD;YACE,EAAE,EAAE,MAAM;YACV,QAAQ,EAAE,MAAM;YAChB,SAAS,EAAE,IAAI,IAAI,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,CAAC;YAC1C,MAAM,EAAE;gBACN,EAAE,EAAE,0BAA0B;gBAC9B,IAAI,EAAE;oBACJ,IAAI,EAAE,cAAc;oBACpB,KAAK,EAAE,SAAS;oBAChB,MAAM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AAC9C,iDAA8C;AAC9C,qDAAkD;AAClD,mDAAgD;AAChD,gDAG2B;AAO3B,6CAA+B;AAG/B,MAAM,kBAAkB,GAAG,CACzB,KAA8B,EACV,EAAE;IACtB,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,GAAG,KAAK,CAAC;IAE1C,MAAM,WAAW,GAAG,IAAA,sCAA2B,EAAC,QAAQ,EAAE,IAAI,CAAC,IAAI,CAAC,CAAC;IACrE,MAAM,aAAa,GAAG,IAAA,wCAA6B,EAAC,QAAQ,EAAE,IAAI,CAAC,IAAI,CAAC,CAAC;IAEzE,OAAO,CACL,oBAAC,eAAM,IAAC,OAAO,EAAE,WAAW;QAC1B,oBAAC,eAAM,oBAAK,OAAO,EAAI;QACvB,oBAAC,oBAAO;YACN,oBAAC,mBAAQ,IAAC,SAAS,EAAC,MAAM,EAAC,KAAK,EAAE,aAAa,GAAI;YAClD,QAAQ,CAAC,GAAG,CAAC,CAAC,OAAO,EAAE,KAAK,EAAE,EAAE,CAAC,CAChC,oBAAC,iBAAO,kBACN,GAAG,EAAE,OAAO,CAAC,EAAE,EACf,SAAS,EAAE,KAAK,GAAG,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,SAAS,IACrC,OAAO,IACX,aAAa,EAAE,QAAQ,CAAC,MAAM,KAAK,CAAC,IACpC,CACH,CAAC,CACM,CACH,CACV,CAAC;AACJ,CAAC,CAAC;AAEF,kBAAe,kBAAkB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@builder6/rooms",
3
- "version": "0.15.4",
3
+ "version": "0.15.6",
4
4
  "description": "",
5
5
  "author": "",
6
6
  "license": "MIT",
@@ -11,11 +11,11 @@
11
11
  "build:watch": "rimraf dist && tsc --watch"
12
12
  },
13
13
  "dependencies": {
14
- "@builder6/core": "0.15.4",
15
- "@builder6/email": "0.15.4",
16
- "@builder6/files": "0.15.4",
17
- "@builder6/moleculer": "0.15.4",
18
- "@builder6/pages": "0.15.4",
14
+ "@builder6/core": "0.15.6",
15
+ "@builder6/email": "0.15.6",
16
+ "@builder6/files": "0.15.6",
17
+ "@builder6/moleculer": "0.15.6",
18
+ "@builder6/pages": "0.15.6",
19
19
  "@liveblocks/emails": "2.12.0",
20
20
  "@liveblocks/node": "2.12.0",
21
21
  "@react-email/components": "^0.0.31",
@@ -54,5 +54,5 @@
54
54
  "devDependencies": {
55
55
  "@types/lodash": "^4.17.13"
56
56
  },
57
- "gitHead": "f9826f42e58032353b0c6a05903b8a8caeeacf3e"
57
+ "gitHead": "864d2715379b904499f6d93f13dd49047800c3ac"
58
58
  }
@@ -1,18 +1,17 @@
1
- import { Section, Text } from "@react-email/components";
2
- import type { CommentEmailAsReactData } from "@liveblocks/emails";
1
+ import { Section, Text } from '@react-email/components';
2
+ import type { CommentEmailAsReactData } from '@liveblocks/emails';
3
3
 
4
- import { getProps } from "./_utils/getProps";
5
- import type { CompanyInfo, RoomInfo } from "./_lib/types";
4
+ import type { CompanyInfo, RoomInfo } from './_lib/types';
6
5
 
7
- import { Layout } from "./_components/layout";
8
- import { Header } from "./_components/header";
9
- import { Headline } from "./_components/headline";
10
- import { Comment } from "./_components/comment";
6
+ import { Layout } from './_components/layout';
7
+ import { Header } from './_components/header';
8
+ import { Headline } from './_components/headline';
9
+ import { Comment } from './_components/comment';
11
10
  import {
12
11
  getUnreadMentionHeadlineParts,
13
12
  getUnreadMentionPreviewText,
14
- } from "./_utils/comments";
15
- import * as React from "react";
13
+ } from './_utils/comments';
14
+ import * as React from 'react';
16
15
 
17
16
  type UnreadMentionEmailProps = {
18
17
  company: CompanyInfo;
@@ -20,46 +19,8 @@ type UnreadMentionEmailProps = {
20
19
  comment: CommentEmailAsReactData;
21
20
  };
22
21
 
23
- const previewProps: UnreadMentionEmailProps = {
24
- company: {
25
- name: "Acme Inc.",
26
- url: "https://liveblocks.io/comments",
27
- },
28
- room: {
29
- name: "User Research Strategy",
30
- url: "https://liveblocks.io/comments?room_id=project-proposal-q4",
31
- },
32
- comment: {
33
- id: "cm_2",
34
- threadId: "th_1",
35
- createdAt: new Date(2024, 2, 4, 4, 6, 47),
36
- author: {
37
- id: "emil-joyce@my-liveblocks-app.com",
38
- info: {
39
- name: "Emil Joyce",
40
- color: "#8594F0",
41
- avatar: "https://liveblocks.io/avatars/avatar-6.png",
42
- },
43
- },
44
- reactBody: (
45
- <Text className="text-sm m-0 text-black">
46
- <span>
47
- For the user research phase, we'll need{" "}
48
- <span data-mention className="text-email-accent font-medium">
49
- @Quinn Elton
50
- </span>{" "}
51
- to lead the interviews and compile the findings. His expertise in
52
- qualitative research will be crucial for this stage.
53
- </span>
54
- </Text>
55
- ),
56
- url: "https://liveblocks.io/comments?room_id=project-proposal-q4#cm_2",
57
- roomId: "project-proposal-q4",
58
- },
59
- };
60
-
61
22
  export default function UnreadMentionEmail(props: UnreadMentionEmailProps) {
62
- const { company, room, comment } = getProps(props, previewProps);
23
+ const { company, room, comment } = props;
63
24
 
64
25
  const previewText = getUnreadMentionPreviewText(comment, room.name);
65
26
  const headlineParts = getUnreadMentionHeadlineParts(comment, room.name);
@@ -1,86 +1,29 @@
1
- import { Section, Text } from "@react-email/components";
2
- import type { CommentEmailAsReactData } from "@liveblocks/emails";
1
+ import { Section, Text } from '@react-email/components';
2
+ import type { CommentEmailAsReactData } from '@liveblocks/emails';
3
3
 
4
- import type { CompanyInfo, RoomInfo } from "./_lib/types";
5
- import { getProps } from "./_utils/getProps";
6
- import { Layout } from "./_components/layout";
7
- import { Header } from "./_components/header";
8
- import { Headline } from "./_components/headline";
9
- import { Comment } from "./_components/comment";
4
+ import type { CompanyInfo, RoomInfo } from './_lib/types';
5
+ import { getProps } from './_utils/getProps';
6
+ import { Layout } from './_components/layout';
7
+ import { Header } from './_components/header';
8
+ import { Headline } from './_components/headline';
9
+ import { Comment } from './_components/comment';
10
10
  import {
11
11
  getUnreadRepliesHeadlineParts,
12
12
  getUnreadRepliesPreviewText,
13
- } from "./_utils/comments";
13
+ } from './_utils/comments';
14
14
 
15
15
  type UnreadRepliesEmailProps = {
16
16
  company: CompanyInfo;
17
17
  room: RoomInfo;
18
18
  comments: CommentEmailAsReactData[];
19
19
  };
20
- import * as React from "react";
20
+ import * as React from 'react';
21
21
 
22
- const previewProps: UnreadRepliesEmailProps = {
23
- company: {
24
- name: "Acme Inc.",
25
- url: "https://liveblocks.io/comments",
26
- },
27
- room: {
28
- name: "Project Proposal - Q4",
29
- url: "https://liveblocks.io/comments?room_id=project-proposal-q4",
30
- },
31
- comments: [
32
- {
33
- id: "cm_0",
34
- threadId: "th_0",
35
- createdAt: new Date(2024, 2, 4, 4, 6, 47),
36
- author: {
37
- id: "tatum-paolo@example.com",
38
- info: {
39
- name: "Tatum Paolo",
40
- color: "#F0D885",
41
- avatar: "https://liveblocks.io/avatars/avatar-3.png",
42
- },
43
- },
44
- reactBody: (
45
- <Text className="text-sm m-0 text-black">
46
- <span>
47
- I've reviewed this section and think we need a more detailed
48
- breakdown of the budget. It might help if we add a few more figures
49
- to illustrate the cost distribution over the next six months. Let me
50
- know if you'd like me to draft a version for you.
51
- </span>
52
- </Text>
53
- ),
54
- url: "https://liveblocks.io/comments?room_id=project-proposal-q4#cm_0",
55
- roomId: "project-proposal-q4",
56
- },
57
- {
58
- id: "cm_1",
59
- threadId: "th_0",
60
- createdAt: new Date(2024, 2, 4, 5, 12, 35),
61
- author: {
62
- id: "anjali-wanda@example.com",
63
- info: {
64
- name: "Anjali Wanda",
65
- color: "#85EED6",
66
- avatar: "https://liveblocks.io/avatars/avatar-4.png",
67
- },
68
- },
69
- reactBody: (
70
- <Text className="text-sm text-black m-0">
71
- <span>Looks good overall. Just a quick note on the timeline.</span>
72
- </Text>
73
- ),
74
- url: "https://liveblocks.io/comments?room_id=project-proposal-q4#cm_1",
75
- roomId: "project-proposal-q4",
76
- },
77
- ],
78
- };
79
22
 
80
23
  const UnreadRepliesEmail = (
81
- props: UnreadRepliesEmailProps
24
+ props: UnreadRepliesEmailProps,
82
25
  ): React.ReactElement => {
83
- const { company, room, comments } = getProps(props, previewProps);
26
+ const { company, room, comments } = props;
84
27
 
85
28
  const previewText = getUnreadRepliesPreviewText(comments, room.name);
86
29
  const headlineParts = getUnreadRepliesHeadlineParts(comments, room.name);
@@ -93,7 +36,7 @@ const UnreadRepliesEmail = (
93
36
  {comments.map((comment, index) => (
94
37
  <Comment
95
38
  key={comment.id}
96
- className={index > 0 ? "mt-3" : undefined}
39
+ className={index > 0 ? 'mt-3' : undefined}
97
40
  {...comment}
98
41
  isHighlighted={comments.length === 1}
99
42
  />