ugcinc-render 1.8.181 → 1.8.183
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 +10 -12
- package/dist/index.d.ts +10 -12
- package/dist/index.js +90 -63
- package/dist/index.mjs +90 -63
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1136,26 +1136,24 @@ interface IMessageDmCompositionProps {
|
|
|
1136
1136
|
messageHeaderLeft?: number;
|
|
1137
1137
|
messageHeaderRight?: number;
|
|
1138
1138
|
showMessageTails?: boolean;
|
|
1139
|
+
recipientTailSideY?: number;
|
|
1140
|
+
recipientTailCurveStartY?: number;
|
|
1139
1141
|
recipientTailTipX?: number;
|
|
1140
1142
|
recipientTailTipY?: number;
|
|
1141
|
-
recipientTailSideX?: number;
|
|
1142
|
-
recipientTailSideY?: number;
|
|
1143
1143
|
recipientTailBottomX?: number;
|
|
1144
1144
|
recipientTailBottomY?: number;
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1145
|
+
recipientTailBottomEndX?: number;
|
|
1146
|
+
recipientTailTopBend?: number;
|
|
1147
|
+
recipientTailBottomBend?: number;
|
|
1148
|
+
senderTailSideY?: number;
|
|
1149
|
+
senderTailCurveStartY?: number;
|
|
1149
1150
|
senderTailTipX?: number;
|
|
1150
1151
|
senderTailTipY?: number;
|
|
1151
|
-
senderTailSideX?: number;
|
|
1152
|
-
senderTailSideY?: number;
|
|
1153
1152
|
senderTailBottomX?: number;
|
|
1154
1153
|
senderTailBottomY?: number;
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
senderTailBottomCurveY?: number;
|
|
1154
|
+
senderTailBottomEndX?: number;
|
|
1155
|
+
senderTailTopBend?: number;
|
|
1156
|
+
senderTailBottomBend?: number;
|
|
1159
1157
|
showReadReceipt?: boolean;
|
|
1160
1158
|
readReceiptText?: string;
|
|
1161
1159
|
readReceiptGap?: number;
|
package/dist/index.d.ts
CHANGED
|
@@ -1136,26 +1136,24 @@ interface IMessageDmCompositionProps {
|
|
|
1136
1136
|
messageHeaderLeft?: number;
|
|
1137
1137
|
messageHeaderRight?: number;
|
|
1138
1138
|
showMessageTails?: boolean;
|
|
1139
|
+
recipientTailSideY?: number;
|
|
1140
|
+
recipientTailCurveStartY?: number;
|
|
1139
1141
|
recipientTailTipX?: number;
|
|
1140
1142
|
recipientTailTipY?: number;
|
|
1141
|
-
recipientTailSideX?: number;
|
|
1142
|
-
recipientTailSideY?: number;
|
|
1143
1143
|
recipientTailBottomX?: number;
|
|
1144
1144
|
recipientTailBottomY?: number;
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1145
|
+
recipientTailBottomEndX?: number;
|
|
1146
|
+
recipientTailTopBend?: number;
|
|
1147
|
+
recipientTailBottomBend?: number;
|
|
1148
|
+
senderTailSideY?: number;
|
|
1149
|
+
senderTailCurveStartY?: number;
|
|
1149
1150
|
senderTailTipX?: number;
|
|
1150
1151
|
senderTailTipY?: number;
|
|
1151
|
-
senderTailSideX?: number;
|
|
1152
|
-
senderTailSideY?: number;
|
|
1153
1152
|
senderTailBottomX?: number;
|
|
1154
1153
|
senderTailBottomY?: number;
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
senderTailBottomCurveY?: number;
|
|
1154
|
+
senderTailBottomEndX?: number;
|
|
1155
|
+
senderTailTopBend?: number;
|
|
1156
|
+
senderTailBottomBend?: number;
|
|
1159
1157
|
showReadReceipt?: boolean;
|
|
1160
1158
|
readReceiptText?: string;
|
|
1161
1159
|
readReceiptGap?: number;
|
package/dist/index.js
CHANGED
|
@@ -5938,29 +5938,41 @@ var defaultIMessageDmProps = {
|
|
|
5938
5938
|
// Message tails (SVG-based, on last message in group)
|
|
5939
5939
|
showMessageTails: true,
|
|
5940
5940
|
// Recipient tail anchor points (offsets from message left & bottom)
|
|
5941
|
-
|
|
5942
|
-
|
|
5943
|
-
|
|
5944
|
-
|
|
5945
|
-
|
|
5946
|
-
|
|
5947
|
-
|
|
5948
|
-
|
|
5949
|
-
|
|
5950
|
-
|
|
5951
|
-
|
|
5941
|
+
recipientTailSideY: -53,
|
|
5942
|
+
// Y where tail meets bubble (top of straight line)
|
|
5943
|
+
recipientTailCurveStartY: -33,
|
|
5944
|
+
// Y where straight line ends and curve begins
|
|
5945
|
+
recipientTailTipX: -17,
|
|
5946
|
+
recipientTailTipY: -1,
|
|
5947
|
+
recipientTailBottomX: -19,
|
|
5948
|
+
// X where bottom curve ends
|
|
5949
|
+
recipientTailBottomY: -12,
|
|
5950
|
+
// Y where bottom curve ends
|
|
5951
|
+
recipientTailBottomEndX: 0,
|
|
5952
|
+
// X where flat bottom ends (at bubble edge)
|
|
5953
|
+
// Recipient tail curve bend (-1 to 1, negative = inward, positive = outward)
|
|
5954
|
+
recipientTailTopBend: -0.3,
|
|
5955
|
+
// Top curve bends inward
|
|
5956
|
+
recipientTailBottomBend: 0.5,
|
|
5957
|
+
// Bottom curve bends outward
|
|
5952
5958
|
// Sender tail anchor points (offsets from message right & bottom)
|
|
5953
|
-
|
|
5954
|
-
|
|
5955
|
-
|
|
5956
|
-
|
|
5957
|
-
|
|
5958
|
-
|
|
5959
|
-
|
|
5960
|
-
|
|
5961
|
-
|
|
5962
|
-
|
|
5963
|
-
|
|
5959
|
+
senderTailSideY: -53,
|
|
5960
|
+
// Y where tail meets bubble (top of straight line)
|
|
5961
|
+
senderTailCurveStartY: -33,
|
|
5962
|
+
// Y where straight line ends and curve begins
|
|
5963
|
+
senderTailTipX: 17,
|
|
5964
|
+
senderTailTipY: -1,
|
|
5965
|
+
senderTailBottomX: 19,
|
|
5966
|
+
// X where bottom curve ends
|
|
5967
|
+
senderTailBottomY: -12,
|
|
5968
|
+
// Y where bottom curve ends
|
|
5969
|
+
senderTailBottomEndX: 0,
|
|
5970
|
+
// X where flat bottom ends (at bubble edge)
|
|
5971
|
+
// Sender tail curve bend (-1 to 1, negative = inward, positive = outward)
|
|
5972
|
+
senderTailTopBend: -0.3,
|
|
5973
|
+
// Top curve bends inward
|
|
5974
|
+
senderTailBottomBend: 0.5,
|
|
5975
|
+
// Bottom curve bends outward
|
|
5964
5976
|
// Read receipt (under last sender message)
|
|
5965
5977
|
showReadReceipt: true,
|
|
5966
5978
|
readReceiptText: "Read 12:16 PM",
|
|
@@ -6135,27 +6147,25 @@ var IMessageDmComposition = (props) => {
|
|
|
6135
6147
|
senderBubbleColor = "#1a42d5",
|
|
6136
6148
|
recipientBubbleColor = "#303032",
|
|
6137
6149
|
// Tail props - recipient (offsets from message left & bottom)
|
|
6138
|
-
|
|
6139
|
-
|
|
6140
|
-
|
|
6141
|
-
|
|
6142
|
-
recipientTailBottomX =
|
|
6143
|
-
recipientTailBottomY = -
|
|
6144
|
-
|
|
6145
|
-
|
|
6146
|
-
|
|
6147
|
-
recipientTailBottomCurveY = 0,
|
|
6150
|
+
recipientTailSideY = -53,
|
|
6151
|
+
recipientTailCurveStartY = -33,
|
|
6152
|
+
recipientTailTipX = -17,
|
|
6153
|
+
recipientTailTipY = -1,
|
|
6154
|
+
recipientTailBottomX = -19,
|
|
6155
|
+
recipientTailBottomY = -12,
|
|
6156
|
+
recipientTailBottomEndX = 0,
|
|
6157
|
+
recipientTailTopBend = -0.3,
|
|
6158
|
+
recipientTailBottomBend = 0.5,
|
|
6148
6159
|
// Tail props - sender (offsets from message right & bottom)
|
|
6149
|
-
|
|
6150
|
-
|
|
6151
|
-
|
|
6152
|
-
|
|
6153
|
-
senderTailBottomX =
|
|
6154
|
-
senderTailBottomY = -
|
|
6155
|
-
|
|
6156
|
-
|
|
6157
|
-
|
|
6158
|
-
senderTailBottomCurveY = 1
|
|
6160
|
+
senderTailSideY = -53,
|
|
6161
|
+
senderTailCurveStartY = -33,
|
|
6162
|
+
senderTailTipX = 17,
|
|
6163
|
+
senderTailTipY = -1,
|
|
6164
|
+
senderTailBottomX = 19,
|
|
6165
|
+
senderTailBottomY = -12,
|
|
6166
|
+
senderTailBottomEndX = 0,
|
|
6167
|
+
senderTailTopBend = -0.3,
|
|
6168
|
+
senderTailBottomBend = 0.5
|
|
6159
6169
|
} = mergedProps;
|
|
6160
6170
|
return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
|
|
6161
6171
|
BaseDmComposition,
|
|
@@ -6409,18 +6419,37 @@ var IMessageDmComposition = (props) => {
|
|
|
6409
6419
|
conversionResult.tails.map((tail) => {
|
|
6410
6420
|
const refX = tail.isUser ? tail.messageRight : tail.messageLeft;
|
|
6411
6421
|
const refY = tail.messageBottom;
|
|
6422
|
+
const sideY = refY + (tail.isUser ? senderTailSideY : recipientTailSideY);
|
|
6423
|
+
const curveStartY = refY + (tail.isUser ? senderTailCurveStartY : recipientTailCurveStartY);
|
|
6412
6424
|
const tipX = refX + (tail.isUser ? senderTailTipX : recipientTailTipX);
|
|
6413
6425
|
const tipY = refY + (tail.isUser ? senderTailTipY : recipientTailTipY);
|
|
6414
|
-
const sideX = refX + (tail.isUser ? senderTailSideX : recipientTailSideX);
|
|
6415
|
-
const sideY = refY + (tail.isUser ? senderTailSideY : recipientTailSideY);
|
|
6416
6426
|
const bottomX = refX + (tail.isUser ? senderTailBottomX : recipientTailBottomX);
|
|
6417
6427
|
const bottomY = refY + (tail.isUser ? senderTailBottomY : recipientTailBottomY);
|
|
6418
|
-
const
|
|
6419
|
-
const
|
|
6420
|
-
const
|
|
6421
|
-
const
|
|
6428
|
+
const bottomEndX = refX + (tail.isUser ? senderTailBottomEndX : recipientTailBottomEndX);
|
|
6429
|
+
const topBend = tail.isUser ? senderTailTopBend : recipientTailTopBend;
|
|
6430
|
+
const bottomBend = tail.isUser ? senderTailBottomBend : recipientTailBottomBend;
|
|
6431
|
+
const sideX = refX;
|
|
6432
|
+
const curveStartX = refX;
|
|
6433
|
+
const topMidX = (curveStartX + tipX) / 2;
|
|
6434
|
+
const topMidY = (curveStartY + tipY) / 2;
|
|
6435
|
+
const topDx = tipX - curveStartX;
|
|
6436
|
+
const topDy = tipY - curveStartY;
|
|
6437
|
+
const topLen = Math.sqrt(topDx * topDx + topDy * topDy);
|
|
6438
|
+
const topPerpX = tail.isUser ? topDy / topLen : -topDy / topLen;
|
|
6439
|
+
const topPerpY = tail.isUser ? -topDx / topLen : topDx / topLen;
|
|
6440
|
+
const topCurveX = topMidX + topPerpX * topBend * topLen;
|
|
6441
|
+
const topCurveY = topMidY + topPerpY * topBend * topLen;
|
|
6442
|
+
const bottomMidX = (tipX + bottomX) / 2;
|
|
6443
|
+
const bottomMidY = (tipY + bottomY) / 2;
|
|
6444
|
+
const bottomDx = bottomX - tipX;
|
|
6445
|
+
const bottomDy = bottomY - tipY;
|
|
6446
|
+
const bottomLen = Math.sqrt(bottomDx * bottomDx + bottomDy * bottomDy);
|
|
6447
|
+
const bottomPerpX = tail.isUser ? bottomDy / bottomLen : -bottomDy / bottomLen;
|
|
6448
|
+
const bottomPerpY = tail.isUser ? -bottomDx / bottomLen : bottomDx / bottomLen;
|
|
6449
|
+
const bottomCurveX = bottomMidX + bottomPerpX * bottomBend * bottomLen;
|
|
6450
|
+
const bottomCurveY = bottomMidY + bottomPerpY * bottomBend * bottomLen;
|
|
6422
6451
|
const fillColor = tail.isUser ? senderBubbleColor : recipientBubbleColor;
|
|
6423
|
-
const pathD = `M ${sideX} ${sideY} Q ${topCurveX} ${topCurveY} ${tipX} ${tipY} Q ${bottomCurveX} ${bottomCurveY} ${bottomX} ${bottomY} Z`;
|
|
6452
|
+
const pathD = `M ${sideX} ${sideY} L ${curveStartX} ${curveStartY} Q ${topCurveX} ${topCurveY} ${tipX} ${tipY} Q ${bottomCurveX} ${bottomCurveY} ${bottomX} ${bottomY} L ${bottomEndX} ${bottomY} Z`;
|
|
6424
6453
|
return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
|
|
6425
6454
|
"svg",
|
|
6426
6455
|
{
|
|
@@ -7374,29 +7403,27 @@ var iMessageDmPropsSchema = import_zod.z.object({
|
|
|
7374
7403
|
// Message tails (SVG-based)
|
|
7375
7404
|
showMessageTails: import_zod.z.boolean().optional(),
|
|
7376
7405
|
// Recipient tail anchor points
|
|
7406
|
+
recipientTailSideY: import_zod.z.number().optional(),
|
|
7407
|
+
recipientTailCurveStartY: import_zod.z.number().optional(),
|
|
7377
7408
|
recipientTailTipX: import_zod.z.number().optional(),
|
|
7378
7409
|
recipientTailTipY: import_zod.z.number().optional(),
|
|
7379
|
-
recipientTailSideX: import_zod.z.number().optional(),
|
|
7380
|
-
recipientTailSideY: import_zod.z.number().optional(),
|
|
7381
7410
|
recipientTailBottomX: import_zod.z.number().optional(),
|
|
7382
7411
|
recipientTailBottomY: import_zod.z.number().optional(),
|
|
7383
|
-
|
|
7384
|
-
|
|
7385
|
-
|
|
7386
|
-
|
|
7387
|
-
recipientTailBottomCurveY: import_zod.z.number().optional(),
|
|
7412
|
+
recipientTailBottomEndX: import_zod.z.number().optional(),
|
|
7413
|
+
// Recipient tail curve bend
|
|
7414
|
+
recipientTailTopBend: import_zod.z.number().optional(),
|
|
7415
|
+
recipientTailBottomBend: import_zod.z.number().optional(),
|
|
7388
7416
|
// Sender tail anchor points
|
|
7417
|
+
senderTailSideY: import_zod.z.number().optional(),
|
|
7418
|
+
senderTailCurveStartY: import_zod.z.number().optional(),
|
|
7389
7419
|
senderTailTipX: import_zod.z.number().optional(),
|
|
7390
7420
|
senderTailTipY: import_zod.z.number().optional(),
|
|
7391
|
-
senderTailSideX: import_zod.z.number().optional(),
|
|
7392
|
-
senderTailSideY: import_zod.z.number().optional(),
|
|
7393
7421
|
senderTailBottomX: import_zod.z.number().optional(),
|
|
7394
7422
|
senderTailBottomY: import_zod.z.number().optional(),
|
|
7395
|
-
|
|
7396
|
-
|
|
7397
|
-
|
|
7398
|
-
|
|
7399
|
-
senderTailBottomCurveY: import_zod.z.number().optional(),
|
|
7423
|
+
senderTailBottomEndX: import_zod.z.number().optional(),
|
|
7424
|
+
// Sender tail curve bend
|
|
7425
|
+
senderTailTopBend: import_zod.z.number().optional(),
|
|
7426
|
+
senderTailBottomBend: import_zod.z.number().optional(),
|
|
7400
7427
|
// Read receipt
|
|
7401
7428
|
showReadReceipt: import_zod.z.boolean().optional(),
|
|
7402
7429
|
readReceiptText: import_zod.z.string().optional(),
|
package/dist/index.mjs
CHANGED
|
@@ -4984,29 +4984,41 @@ var defaultIMessageDmProps = {
|
|
|
4984
4984
|
// Message tails (SVG-based, on last message in group)
|
|
4985
4985
|
showMessageTails: true,
|
|
4986
4986
|
// Recipient tail anchor points (offsets from message left & bottom)
|
|
4987
|
-
|
|
4988
|
-
|
|
4989
|
-
|
|
4990
|
-
|
|
4991
|
-
|
|
4992
|
-
|
|
4993
|
-
|
|
4994
|
-
|
|
4995
|
-
|
|
4996
|
-
|
|
4997
|
-
|
|
4987
|
+
recipientTailSideY: -53,
|
|
4988
|
+
// Y where tail meets bubble (top of straight line)
|
|
4989
|
+
recipientTailCurveStartY: -33,
|
|
4990
|
+
// Y where straight line ends and curve begins
|
|
4991
|
+
recipientTailTipX: -17,
|
|
4992
|
+
recipientTailTipY: -1,
|
|
4993
|
+
recipientTailBottomX: -19,
|
|
4994
|
+
// X where bottom curve ends
|
|
4995
|
+
recipientTailBottomY: -12,
|
|
4996
|
+
// Y where bottom curve ends
|
|
4997
|
+
recipientTailBottomEndX: 0,
|
|
4998
|
+
// X where flat bottom ends (at bubble edge)
|
|
4999
|
+
// Recipient tail curve bend (-1 to 1, negative = inward, positive = outward)
|
|
5000
|
+
recipientTailTopBend: -0.3,
|
|
5001
|
+
// Top curve bends inward
|
|
5002
|
+
recipientTailBottomBend: 0.5,
|
|
5003
|
+
// Bottom curve bends outward
|
|
4998
5004
|
// Sender tail anchor points (offsets from message right & bottom)
|
|
4999
|
-
|
|
5000
|
-
|
|
5001
|
-
|
|
5002
|
-
|
|
5003
|
-
|
|
5004
|
-
|
|
5005
|
-
|
|
5006
|
-
|
|
5007
|
-
|
|
5008
|
-
|
|
5009
|
-
|
|
5005
|
+
senderTailSideY: -53,
|
|
5006
|
+
// Y where tail meets bubble (top of straight line)
|
|
5007
|
+
senderTailCurveStartY: -33,
|
|
5008
|
+
// Y where straight line ends and curve begins
|
|
5009
|
+
senderTailTipX: 17,
|
|
5010
|
+
senderTailTipY: -1,
|
|
5011
|
+
senderTailBottomX: 19,
|
|
5012
|
+
// X where bottom curve ends
|
|
5013
|
+
senderTailBottomY: -12,
|
|
5014
|
+
// Y where bottom curve ends
|
|
5015
|
+
senderTailBottomEndX: 0,
|
|
5016
|
+
// X where flat bottom ends (at bubble edge)
|
|
5017
|
+
// Sender tail curve bend (-1 to 1, negative = inward, positive = outward)
|
|
5018
|
+
senderTailTopBend: -0.3,
|
|
5019
|
+
// Top curve bends inward
|
|
5020
|
+
senderTailBottomBend: 0.5,
|
|
5021
|
+
// Bottom curve bends outward
|
|
5010
5022
|
// Read receipt (under last sender message)
|
|
5011
5023
|
showReadReceipt: true,
|
|
5012
5024
|
readReceiptText: "Read 12:16 PM",
|
|
@@ -5181,27 +5193,25 @@ var IMessageDmComposition = (props) => {
|
|
|
5181
5193
|
senderBubbleColor = "#1a42d5",
|
|
5182
5194
|
recipientBubbleColor = "#303032",
|
|
5183
5195
|
// Tail props - recipient (offsets from message left & bottom)
|
|
5184
|
-
|
|
5185
|
-
|
|
5186
|
-
|
|
5187
|
-
|
|
5188
|
-
recipientTailBottomX =
|
|
5189
|
-
recipientTailBottomY = -
|
|
5190
|
-
|
|
5191
|
-
|
|
5192
|
-
|
|
5193
|
-
recipientTailBottomCurveY = 0,
|
|
5196
|
+
recipientTailSideY = -53,
|
|
5197
|
+
recipientTailCurveStartY = -33,
|
|
5198
|
+
recipientTailTipX = -17,
|
|
5199
|
+
recipientTailTipY = -1,
|
|
5200
|
+
recipientTailBottomX = -19,
|
|
5201
|
+
recipientTailBottomY = -12,
|
|
5202
|
+
recipientTailBottomEndX = 0,
|
|
5203
|
+
recipientTailTopBend = -0.3,
|
|
5204
|
+
recipientTailBottomBend = 0.5,
|
|
5194
5205
|
// Tail props - sender (offsets from message right & bottom)
|
|
5195
|
-
|
|
5196
|
-
|
|
5197
|
-
|
|
5198
|
-
|
|
5199
|
-
senderTailBottomX =
|
|
5200
|
-
senderTailBottomY = -
|
|
5201
|
-
|
|
5202
|
-
|
|
5203
|
-
|
|
5204
|
-
senderTailBottomCurveY = 1
|
|
5206
|
+
senderTailSideY = -53,
|
|
5207
|
+
senderTailCurveStartY = -33,
|
|
5208
|
+
senderTailTipX = 17,
|
|
5209
|
+
senderTailTipY = -1,
|
|
5210
|
+
senderTailBottomX = 19,
|
|
5211
|
+
senderTailBottomY = -12,
|
|
5212
|
+
senderTailBottomEndX = 0,
|
|
5213
|
+
senderTailTopBend = -0.3,
|
|
5214
|
+
senderTailBottomBend = 0.5
|
|
5205
5215
|
} = mergedProps;
|
|
5206
5216
|
return /* @__PURE__ */ jsxs10(
|
|
5207
5217
|
BaseDmComposition,
|
|
@@ -5455,18 +5465,37 @@ var IMessageDmComposition = (props) => {
|
|
|
5455
5465
|
conversionResult.tails.map((tail) => {
|
|
5456
5466
|
const refX = tail.isUser ? tail.messageRight : tail.messageLeft;
|
|
5457
5467
|
const refY = tail.messageBottom;
|
|
5468
|
+
const sideY = refY + (tail.isUser ? senderTailSideY : recipientTailSideY);
|
|
5469
|
+
const curveStartY = refY + (tail.isUser ? senderTailCurveStartY : recipientTailCurveStartY);
|
|
5458
5470
|
const tipX = refX + (tail.isUser ? senderTailTipX : recipientTailTipX);
|
|
5459
5471
|
const tipY = refY + (tail.isUser ? senderTailTipY : recipientTailTipY);
|
|
5460
|
-
const sideX = refX + (tail.isUser ? senderTailSideX : recipientTailSideX);
|
|
5461
|
-
const sideY = refY + (tail.isUser ? senderTailSideY : recipientTailSideY);
|
|
5462
5472
|
const bottomX = refX + (tail.isUser ? senderTailBottomX : recipientTailBottomX);
|
|
5463
5473
|
const bottomY = refY + (tail.isUser ? senderTailBottomY : recipientTailBottomY);
|
|
5464
|
-
const
|
|
5465
|
-
const
|
|
5466
|
-
const
|
|
5467
|
-
const
|
|
5474
|
+
const bottomEndX = refX + (tail.isUser ? senderTailBottomEndX : recipientTailBottomEndX);
|
|
5475
|
+
const topBend = tail.isUser ? senderTailTopBend : recipientTailTopBend;
|
|
5476
|
+
const bottomBend = tail.isUser ? senderTailBottomBend : recipientTailBottomBend;
|
|
5477
|
+
const sideX = refX;
|
|
5478
|
+
const curveStartX = refX;
|
|
5479
|
+
const topMidX = (curveStartX + tipX) / 2;
|
|
5480
|
+
const topMidY = (curveStartY + tipY) / 2;
|
|
5481
|
+
const topDx = tipX - curveStartX;
|
|
5482
|
+
const topDy = tipY - curveStartY;
|
|
5483
|
+
const topLen = Math.sqrt(topDx * topDx + topDy * topDy);
|
|
5484
|
+
const topPerpX = tail.isUser ? topDy / topLen : -topDy / topLen;
|
|
5485
|
+
const topPerpY = tail.isUser ? -topDx / topLen : topDx / topLen;
|
|
5486
|
+
const topCurveX = topMidX + topPerpX * topBend * topLen;
|
|
5487
|
+
const topCurveY = topMidY + topPerpY * topBend * topLen;
|
|
5488
|
+
const bottomMidX = (tipX + bottomX) / 2;
|
|
5489
|
+
const bottomMidY = (tipY + bottomY) / 2;
|
|
5490
|
+
const bottomDx = bottomX - tipX;
|
|
5491
|
+
const bottomDy = bottomY - tipY;
|
|
5492
|
+
const bottomLen = Math.sqrt(bottomDx * bottomDx + bottomDy * bottomDy);
|
|
5493
|
+
const bottomPerpX = tail.isUser ? bottomDy / bottomLen : -bottomDy / bottomLen;
|
|
5494
|
+
const bottomPerpY = tail.isUser ? -bottomDx / bottomLen : bottomDx / bottomLen;
|
|
5495
|
+
const bottomCurveX = bottomMidX + bottomPerpX * bottomBend * bottomLen;
|
|
5496
|
+
const bottomCurveY = bottomMidY + bottomPerpY * bottomBend * bottomLen;
|
|
5468
5497
|
const fillColor = tail.isUser ? senderBubbleColor : recipientBubbleColor;
|
|
5469
|
-
const pathD = `M ${sideX} ${sideY} Q ${topCurveX} ${topCurveY} ${tipX} ${tipY} Q ${bottomCurveX} ${bottomCurveY} ${bottomX} ${bottomY} Z`;
|
|
5498
|
+
const pathD = `M ${sideX} ${sideY} L ${curveStartX} ${curveStartY} Q ${topCurveX} ${topCurveY} ${tipX} ${tipY} Q ${bottomCurveX} ${bottomCurveY} ${bottomX} ${bottomY} L ${bottomEndX} ${bottomY} Z`;
|
|
5470
5499
|
return /* @__PURE__ */ jsx12(
|
|
5471
5500
|
"svg",
|
|
5472
5501
|
{
|
|
@@ -6137,29 +6166,27 @@ var iMessageDmPropsSchema = z.object({
|
|
|
6137
6166
|
// Message tails (SVG-based)
|
|
6138
6167
|
showMessageTails: z.boolean().optional(),
|
|
6139
6168
|
// Recipient tail anchor points
|
|
6169
|
+
recipientTailSideY: z.number().optional(),
|
|
6170
|
+
recipientTailCurveStartY: z.number().optional(),
|
|
6140
6171
|
recipientTailTipX: z.number().optional(),
|
|
6141
6172
|
recipientTailTipY: z.number().optional(),
|
|
6142
|
-
recipientTailSideX: z.number().optional(),
|
|
6143
|
-
recipientTailSideY: z.number().optional(),
|
|
6144
6173
|
recipientTailBottomX: z.number().optional(),
|
|
6145
6174
|
recipientTailBottomY: z.number().optional(),
|
|
6146
|
-
|
|
6147
|
-
|
|
6148
|
-
|
|
6149
|
-
|
|
6150
|
-
recipientTailBottomCurveY: z.number().optional(),
|
|
6175
|
+
recipientTailBottomEndX: z.number().optional(),
|
|
6176
|
+
// Recipient tail curve bend
|
|
6177
|
+
recipientTailTopBend: z.number().optional(),
|
|
6178
|
+
recipientTailBottomBend: z.number().optional(),
|
|
6151
6179
|
// Sender tail anchor points
|
|
6180
|
+
senderTailSideY: z.number().optional(),
|
|
6181
|
+
senderTailCurveStartY: z.number().optional(),
|
|
6152
6182
|
senderTailTipX: z.number().optional(),
|
|
6153
6183
|
senderTailTipY: z.number().optional(),
|
|
6154
|
-
senderTailSideX: z.number().optional(),
|
|
6155
|
-
senderTailSideY: z.number().optional(),
|
|
6156
6184
|
senderTailBottomX: z.number().optional(),
|
|
6157
6185
|
senderTailBottomY: z.number().optional(),
|
|
6158
|
-
|
|
6159
|
-
|
|
6160
|
-
|
|
6161
|
-
|
|
6162
|
-
senderTailBottomCurveY: z.number().optional(),
|
|
6186
|
+
senderTailBottomEndX: z.number().optional(),
|
|
6187
|
+
// Sender tail curve bend
|
|
6188
|
+
senderTailTopBend: z.number().optional(),
|
|
6189
|
+
senderTailBottomBend: z.number().optional(),
|
|
6163
6190
|
// Read receipt
|
|
6164
6191
|
showReadReceipt: z.boolean().optional(),
|
|
6165
6192
|
readReceiptText: z.string().optional(),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ugcinc-render",
|
|
3
|
-
"version": "1.8.
|
|
3
|
+
"version": "1.8.183",
|
|
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",
|