ugcinc-render 1.8.173 → 1.8.174
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/dist/index.d.mts +2 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +12 -4
- package/dist/index.mjs +12 -4
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1123,6 +1123,8 @@ interface IMessageDmCompositionProps {
|
|
|
1123
1123
|
readReceiptFontSize?: number;
|
|
1124
1124
|
readReceiptLetterSpacing?: number;
|
|
1125
1125
|
readReceiptColor?: string;
|
|
1126
|
+
readReceiptLeft?: number;
|
|
1127
|
+
readReceiptRight?: number;
|
|
1126
1128
|
messages?: ImMessage[];
|
|
1127
1129
|
}
|
|
1128
1130
|
|
package/dist/index.d.ts
CHANGED
|
@@ -1123,6 +1123,8 @@ interface IMessageDmCompositionProps {
|
|
|
1123
1123
|
readReceiptFontSize?: number;
|
|
1124
1124
|
readReceiptLetterSpacing?: number;
|
|
1125
1125
|
readReceiptColor?: string;
|
|
1126
|
+
readReceiptLeft?: number;
|
|
1127
|
+
readReceiptRight?: number;
|
|
1126
1128
|
messages?: ImMessage[];
|
|
1127
1129
|
}
|
|
1128
1130
|
|
package/dist/index.js
CHANGED
|
@@ -5310,7 +5310,9 @@ var MESSAGE_DEFAULTS2 = {
|
|
|
5310
5310
|
readReceiptGap: 47,
|
|
5311
5311
|
readReceiptFontSize: 34,
|
|
5312
5312
|
readReceiptLetterSpacing: 1.25,
|
|
5313
|
-
readReceiptColor: "#626167"
|
|
5313
|
+
readReceiptColor: "#626167",
|
|
5314
|
+
readReceiptLeft: 0,
|
|
5315
|
+
readReceiptRight: 1158
|
|
5314
5316
|
};
|
|
5315
5317
|
var FONT_FAMILY2 = getFontFamily("apple");
|
|
5316
5318
|
function calculateAutoWidthAndLines3({
|
|
@@ -5689,14 +5691,16 @@ function generateReadReceiptElement(props, calculatedMessages) {
|
|
|
5689
5691
|
const readReceiptFontSize = props.readReceiptFontSize ?? MESSAGE_DEFAULTS2.readReceiptFontSize;
|
|
5690
5692
|
const readReceiptLetterSpacing = props.readReceiptLetterSpacing ?? MESSAGE_DEFAULTS2.readReceiptLetterSpacing;
|
|
5691
5693
|
const readReceiptColor = props.readReceiptColor ?? MESSAGE_DEFAULTS2.readReceiptColor;
|
|
5692
|
-
const
|
|
5694
|
+
const readReceiptLeft = props.readReceiptLeft ?? MESSAGE_DEFAULTS2.readReceiptLeft;
|
|
5695
|
+
const readReceiptRight = props.readReceiptRight ?? MESSAGE_DEFAULTS2.readReceiptRight;
|
|
5696
|
+
const readReceiptWidth = readReceiptRight - readReceiptLeft;
|
|
5693
5697
|
const readReceiptTop = lastSenderMessage.bottom + readReceiptGap - readReceiptFontSize;
|
|
5694
5698
|
return [{
|
|
5695
5699
|
id: "read-receipt",
|
|
5696
5700
|
type: "text",
|
|
5697
|
-
x:
|
|
5701
|
+
x: readReceiptLeft,
|
|
5698
5702
|
y: readReceiptTop,
|
|
5699
|
-
width:
|
|
5703
|
+
width: readReceiptWidth,
|
|
5700
5704
|
height: readReceiptFontSize,
|
|
5701
5705
|
zIndex: 4,
|
|
5702
5706
|
text: readReceiptText,
|
|
@@ -5892,6 +5896,8 @@ var defaultIMessageDmProps = {
|
|
|
5892
5896
|
readReceiptFontSize: 34,
|
|
5893
5897
|
readReceiptLetterSpacing: 1.25,
|
|
5894
5898
|
readReceiptColor: "#626167",
|
|
5899
|
+
readReceiptLeft: 0,
|
|
5900
|
+
readReceiptRight: 1158,
|
|
5895
5901
|
// Example messages
|
|
5896
5902
|
messages: [
|
|
5897
5903
|
{ id: "msg-1", sender: "user", text: "heyyy fae, help me slide on this baddie pls \u{1F64F}", imageUrl: "https://n14dcpakf8w1fekl.public.blob.vercel-storage.com/media/06c3ed1c-eefb-4a60-b0c4-5fb872811ba0/pinterest-1766175214139-0-JpXmGIxVWdjEJ3qxGyoC4DAi2KAZrg.jpg" },
|
|
@@ -7140,6 +7146,8 @@ var iMessageDmPropsSchema = import_zod.z.object({
|
|
|
7140
7146
|
readReceiptFontSize: import_zod.z.number().optional(),
|
|
7141
7147
|
readReceiptLetterSpacing: import_zod.z.number().optional(),
|
|
7142
7148
|
readReceiptColor: import_zod.z.string().optional(),
|
|
7149
|
+
readReceiptLeft: import_zod.z.number().optional(),
|
|
7150
|
+
readReceiptRight: import_zod.z.number().optional(),
|
|
7143
7151
|
// Messages
|
|
7144
7152
|
messages: import_zod.z.array(import_zod.z.object({
|
|
7145
7153
|
id: import_zod.z.string(),
|
package/dist/index.mjs
CHANGED
|
@@ -4356,7 +4356,9 @@ var MESSAGE_DEFAULTS2 = {
|
|
|
4356
4356
|
readReceiptGap: 47,
|
|
4357
4357
|
readReceiptFontSize: 34,
|
|
4358
4358
|
readReceiptLetterSpacing: 1.25,
|
|
4359
|
-
readReceiptColor: "#626167"
|
|
4359
|
+
readReceiptColor: "#626167",
|
|
4360
|
+
readReceiptLeft: 0,
|
|
4361
|
+
readReceiptRight: 1158
|
|
4360
4362
|
};
|
|
4361
4363
|
var FONT_FAMILY2 = getFontFamily("apple");
|
|
4362
4364
|
function calculateAutoWidthAndLines3({
|
|
@@ -4735,14 +4737,16 @@ function generateReadReceiptElement(props, calculatedMessages) {
|
|
|
4735
4737
|
const readReceiptFontSize = props.readReceiptFontSize ?? MESSAGE_DEFAULTS2.readReceiptFontSize;
|
|
4736
4738
|
const readReceiptLetterSpacing = props.readReceiptLetterSpacing ?? MESSAGE_DEFAULTS2.readReceiptLetterSpacing;
|
|
4737
4739
|
const readReceiptColor = props.readReceiptColor ?? MESSAGE_DEFAULTS2.readReceiptColor;
|
|
4738
|
-
const
|
|
4740
|
+
const readReceiptLeft = props.readReceiptLeft ?? MESSAGE_DEFAULTS2.readReceiptLeft;
|
|
4741
|
+
const readReceiptRight = props.readReceiptRight ?? MESSAGE_DEFAULTS2.readReceiptRight;
|
|
4742
|
+
const readReceiptWidth = readReceiptRight - readReceiptLeft;
|
|
4739
4743
|
const readReceiptTop = lastSenderMessage.bottom + readReceiptGap - readReceiptFontSize;
|
|
4740
4744
|
return [{
|
|
4741
4745
|
id: "read-receipt",
|
|
4742
4746
|
type: "text",
|
|
4743
|
-
x:
|
|
4747
|
+
x: readReceiptLeft,
|
|
4744
4748
|
y: readReceiptTop,
|
|
4745
|
-
width:
|
|
4749
|
+
width: readReceiptWidth,
|
|
4746
4750
|
height: readReceiptFontSize,
|
|
4747
4751
|
zIndex: 4,
|
|
4748
4752
|
text: readReceiptText,
|
|
@@ -4938,6 +4942,8 @@ var defaultIMessageDmProps = {
|
|
|
4938
4942
|
readReceiptFontSize: 34,
|
|
4939
4943
|
readReceiptLetterSpacing: 1.25,
|
|
4940
4944
|
readReceiptColor: "#626167",
|
|
4945
|
+
readReceiptLeft: 0,
|
|
4946
|
+
readReceiptRight: 1158,
|
|
4941
4947
|
// Example messages
|
|
4942
4948
|
messages: [
|
|
4943
4949
|
{ id: "msg-1", sender: "user", text: "heyyy fae, help me slide on this baddie pls \u{1F64F}", imageUrl: "https://n14dcpakf8w1fekl.public.blob.vercel-storage.com/media/06c3ed1c-eefb-4a60-b0c4-5fb872811ba0/pinterest-1766175214139-0-JpXmGIxVWdjEJ3qxGyoC4DAi2KAZrg.jpg" },
|
|
@@ -5903,6 +5909,8 @@ var iMessageDmPropsSchema = z.object({
|
|
|
5903
5909
|
readReceiptFontSize: z.number().optional(),
|
|
5904
5910
|
readReceiptLetterSpacing: z.number().optional(),
|
|
5905
5911
|
readReceiptColor: z.string().optional(),
|
|
5912
|
+
readReceiptLeft: z.number().optional(),
|
|
5913
|
+
readReceiptRight: z.number().optional(),
|
|
5906
5914
|
// Messages
|
|
5907
5915
|
messages: z.array(z.object({
|
|
5908
5916
|
id: z.string(),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ugcinc-render",
|
|
3
|
-
"version": "1.8.
|
|
3
|
+
"version": "1.8.174",
|
|
4
4
|
"description": "Unified rendering package for UGC Inc - shared types, components, and compositions for pixel-perfect client/server rendering",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|