@builder6/rooms 3.0.5 → 3.0.7
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.
- package/package.json +10 -7
- package/.prettierrc +0 -4
- package/src/emails/UnreadMention.tsx +0 -37
- package/src/emails/UnreadReplies.tsx +0 -49
- package/src/emails/_components/comment.tsx +0 -70
- package/src/emails/_components/header.tsx +0 -26
- package/src/emails/_components/headline.tsx +0 -20
- package/src/emails/_components/layout.tsx +0 -45
- package/src/emails/_lib/types.ts +0 -10
- package/src/emails/_styles/colors.ts +0 -7
- package/src/emails/_utils/cn.ts +0 -6
- package/src/emails/_utils/comments.ts +0 -61
- package/src/emails/_utils/getProps.ts +0 -7
- package/src/plugin.module.ts +0 -3
- package/src/rooms/app.controller.ts +0 -89
- package/src/rooms/dtos/inbox_notifications.dto.ts +0 -13
- package/src/rooms/dtos/notifications.dto.ts +0 -14
- package/src/rooms/dtos/room_members.dto.ts +0 -32
- package/src/rooms/dtos/rooms.dto.ts +0 -51
- package/src/rooms/emailNotification.service.tsx +0 -126
- package/src/rooms/emails/comment-body.tsx +0 -342
- package/src/rooms/emails/comment-with-body.ts +0 -24
- package/src/rooms/emails/index.ts +0 -25
- package/src/rooms/emails/lib/batch-users-resolver.ts +0 -120
- package/src/rooms/emails/lib/css-properties.ts +0 -123
- package/src/rooms/emails/lib/warning.ts +0 -25
- package/src/rooms/emails/thread-notification.tsx +0 -583
- package/src/rooms/globals/augmentation.ts +0 -89
- package/src/rooms/index.ts +0 -5
- package/src/rooms/lib/DateToString.ts +0 -9
- package/src/rooms/lib/Json.ts +0 -34
- package/src/rooms/lib/utils.ts +0 -240
- package/src/rooms/liveblocks.service.ts +0 -25
- package/src/rooms/notifications.service.ts +0 -235
- package/src/rooms/protocol/AuthToken.ts +0 -126
- package/src/rooms/protocol/Authentication.ts +0 -18
- package/src/rooms/protocol/BaseActivitiesData.ts +0 -5
- package/src/rooms/protocol/BaseRoomInfo.ts +0 -15
- package/src/rooms/protocol/BaseUserMeta.ts +0 -28
- package/src/rooms/protocol/ClientMsg.ts +0 -94
- package/src/rooms/protocol/Comments.ts +0 -202
- package/src/rooms/protocol/InboxNotifications.ts +0 -75
- package/src/rooms/protocol/Op.ts +0 -143
- package/src/rooms/protocol/SerializedCrdt.ts +0 -61
- package/src/rooms/protocol/ServerMsg.ts +0 -307
- package/src/rooms/protocol/VersionHistory.ts +0 -9
- package/src/rooms/rooms.controller.ts +0 -587
- package/src/rooms/rooms.gateway.ts +0 -267
- package/src/rooms/rooms.guard.ts +0 -52
- package/src/rooms/rooms.module.ts +0 -38
- package/src/rooms/rooms.moleculer.ts +0 -80
- package/src/rooms/rooms.service.ts +0 -723
- package/tsconfig.json +0 -10
- package/yarn-error.log +0 -17218
|
@@ -1,123 +0,0 @@
|
|
|
1
|
-
import type { Properties } from "csstype";
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* CSS properties object.
|
|
5
|
-
* Type alias for DX purposes.
|
|
6
|
-
*
|
|
7
|
-
*/
|
|
8
|
-
export type CSSProperties = Properties;
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* Vendors
|
|
12
|
-
*/
|
|
13
|
-
const VENDORS_PREFIXES = new RegExp(/^(webkit|moz|ms|o)-/);
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* CSS properties which accept numbers but are not in units of "px".
|
|
17
|
-
* Based on: https://github.com/facebook/react/blob/bfe91fbecf183f85fc1c4f909e12a6833a247319/packages/react-dom-bindings/src/shared/isUnitlessNumber.js
|
|
18
|
-
*/
|
|
19
|
-
const UNITLESS_PROPERTIES = [
|
|
20
|
-
"animationIterationCount",
|
|
21
|
-
"aspectRatio",
|
|
22
|
-
"borderImageOutset",
|
|
23
|
-
"borderImageSlice",
|
|
24
|
-
"borderImageWidth",
|
|
25
|
-
"boxFlex",
|
|
26
|
-
"boxFlexGroup",
|
|
27
|
-
"boxOrdinalGroup",
|
|
28
|
-
"columnCount",
|
|
29
|
-
"columns",
|
|
30
|
-
"flex",
|
|
31
|
-
"flexGrow",
|
|
32
|
-
"flexPositive",
|
|
33
|
-
"flexShrink",
|
|
34
|
-
"flexNegative",
|
|
35
|
-
"flexOrder",
|
|
36
|
-
"gridArea",
|
|
37
|
-
"gridRow",
|
|
38
|
-
"gridRowEnd",
|
|
39
|
-
"gridRowSpan",
|
|
40
|
-
"gridRowStart",
|
|
41
|
-
"gridColumn",
|
|
42
|
-
"gridColumnEnd",
|
|
43
|
-
"gridColumnSpan",
|
|
44
|
-
"gridColumnStart",
|
|
45
|
-
"fontWeight",
|
|
46
|
-
"lineClamp",
|
|
47
|
-
"lineHeight",
|
|
48
|
-
"opacity",
|
|
49
|
-
"order",
|
|
50
|
-
"orphans",
|
|
51
|
-
"scale",
|
|
52
|
-
"tabSize",
|
|
53
|
-
"widows",
|
|
54
|
-
"zIndex",
|
|
55
|
-
"zoom",
|
|
56
|
-
"fillOpacity",
|
|
57
|
-
"floodOpacity",
|
|
58
|
-
"stopOpacity",
|
|
59
|
-
"strokeDasharray",
|
|
60
|
-
"strokeDashoffset",
|
|
61
|
-
"strokeMiterlimit",
|
|
62
|
-
"strokeOpacity",
|
|
63
|
-
"strokeWidth",
|
|
64
|
-
"MozAnimationIterationCount",
|
|
65
|
-
"MozBoxFlex",
|
|
66
|
-
"MozBoxFlexGroup",
|
|
67
|
-
"MozLineClamp",
|
|
68
|
-
"msAnimationIterationCount",
|
|
69
|
-
"msFlex",
|
|
70
|
-
"msZoom",
|
|
71
|
-
"msFlexPositive",
|
|
72
|
-
"msGridColumns",
|
|
73
|
-
"msGridRows",
|
|
74
|
-
"WebkitAnimationIterationCount",
|
|
75
|
-
"WebkitBoxFlex",
|
|
76
|
-
"WebKitBoxFlexGroup",
|
|
77
|
-
"WebkitBoxOrdinalGroup",
|
|
78
|
-
"WebkitColumnCount",
|
|
79
|
-
"WebkitColumns",
|
|
80
|
-
"WebkitFlex",
|
|
81
|
-
"WebkitFlexGrow",
|
|
82
|
-
"WebkitFlexPositive",
|
|
83
|
-
"WebkitFlexShrink",
|
|
84
|
-
"WebkitLineClamp",
|
|
85
|
-
];
|
|
86
|
-
|
|
87
|
-
/**
|
|
88
|
-
* Convert a `CSSProperties` style object into a inline CSS string.
|
|
89
|
-
*/
|
|
90
|
-
export function toInlineCSSString(styles: CSSProperties): string {
|
|
91
|
-
const entries = Object.entries(styles);
|
|
92
|
-
const inline = entries
|
|
93
|
-
.map(([key, value]): string | null => {
|
|
94
|
-
// Return an empty string if `value` is not acceptable
|
|
95
|
-
if (
|
|
96
|
-
value === null ||
|
|
97
|
-
typeof value === "boolean" ||
|
|
98
|
-
value === "" ||
|
|
99
|
-
typeof value === "undefined"
|
|
100
|
-
) {
|
|
101
|
-
return "";
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
// Convert key from camelCase to kebab-case
|
|
105
|
-
let property = key.replace(/([A-Z])/g, "-$1").toLowerCase();
|
|
106
|
-
|
|
107
|
-
// Manage vendors prefixes
|
|
108
|
-
if (VENDORS_PREFIXES.test(property)) {
|
|
109
|
-
property = `-${property}`;
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
// Add `px` if needed for properties which aren't unitless
|
|
113
|
-
if (typeof value === "number" && !UNITLESS_PROPERTIES.includes(key)) {
|
|
114
|
-
return `${property}:${value}px;`;
|
|
115
|
-
}
|
|
116
|
-
|
|
117
|
-
return `${property}:${String(value).trim()};`;
|
|
118
|
-
})
|
|
119
|
-
.filter(Boolean)
|
|
120
|
-
.join("");
|
|
121
|
-
|
|
122
|
-
return inline;
|
|
123
|
-
}
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @internal
|
|
3
|
-
* Emit a warning only once if a condition is met, in development only.
|
|
4
|
-
*/
|
|
5
|
-
export const createDevelopmentWarning = (
|
|
6
|
-
condition: boolean | (() => boolean),
|
|
7
|
-
...args: Parameters<typeof console.warn>
|
|
8
|
-
) => {
|
|
9
|
-
let hasWarned = false;
|
|
10
|
-
|
|
11
|
-
if (process.env.NODE_ENV !== "production") {
|
|
12
|
-
return () => {
|
|
13
|
-
if (
|
|
14
|
-
!hasWarned &&
|
|
15
|
-
(typeof condition === "function" ? condition() : condition)
|
|
16
|
-
) {
|
|
17
|
-
console.warn(...args);
|
|
18
|
-
|
|
19
|
-
hasWarned = true;
|
|
20
|
-
}
|
|
21
|
-
};
|
|
22
|
-
} else {
|
|
23
|
-
return () => {};
|
|
24
|
-
}
|
|
25
|
-
};
|