chore: bump message parser from 0.31.14 to 0.31.26 (#5338)
* chore: bump message parser * fix markdown value assignment * update snapshot
This commit is contained in:
parent
629b8727d2
commit
93c8409354
File diff suppressed because one or more lines are too long
|
@ -30,11 +30,12 @@ const Inline = ({ value, forceTrim }: IParagraphProps): React.ReactElement | nul
|
|||
// to clean the empty spaces
|
||||
if (forceTrim) {
|
||||
if (index === 0 && block.type === 'LINK') {
|
||||
block.value.label.value =
|
||||
// Need to update the @rocket.chat/message-parser to understand that the label can be a Markup | Markup[]
|
||||
// https://github.com/RocketChat/fuselage/blob/461ecf661d9ff4a46390957c915e4352fa942a7c/packages/message-parser/src/definitions.ts#L141
|
||||
// @ts-ignore
|
||||
block.value?.label?.value?.toString().trimLeft() || block?.value?.label?.[0]?.value?.toString().trimLeft();
|
||||
if (!Array.isArray(block.value.label)) {
|
||||
block.value.label.value = block.value?.label?.value?.toString().trimLeft();
|
||||
} else {
|
||||
// @ts-ignore - we are forcing the value to be a string
|
||||
block.value.label.value = block?.value?.label?.[0]?.value?.toString().trimLeft();
|
||||
}
|
||||
}
|
||||
if (index === 1 && block.type !== 'LINK') {
|
||||
block.value = block.value?.toString().trimLeft();
|
||||
|
|
|
@ -61,7 +61,7 @@
|
|||
"@react-navigation/elements": "^1.3.6",
|
||||
"@react-navigation/native": "6.0.10",
|
||||
"@react-navigation/stack": "6.2.1",
|
||||
"@rocket.chat/message-parser": "^0.31.14",
|
||||
"@rocket.chat/message-parser": "^0.31.26",
|
||||
"@rocket.chat/sdk": "RocketChat/Rocket.Chat.js.SDK#mobile",
|
||||
"@rocket.chat/ui-kit": "^0.31.19",
|
||||
"bytebuffer": "^5.0.1",
|
||||
|
|
22
yarn.lock
22
yarn.lock
|
@ -5625,10 +5625,12 @@
|
|||
dependencies:
|
||||
eslint-plugin-import "^2.17.2"
|
||||
|
||||
"@rocket.chat/message-parser@^0.31.14":
|
||||
version "0.31.14"
|
||||
resolved "https://registry.yarnpkg.com/@rocket.chat/message-parser/-/message-parser-0.31.14.tgz#55042be10a7cd49a7a9a969272bc38897fe1c252"
|
||||
integrity sha512-WgaWLMCFWcmhRb7cEm1Q8GoD8lgpPuTniG27Qmfw8k86MuZfdHj+cdOfhvkmdNORxx181RhfksTO0k6IkRxh6A==
|
||||
"@rocket.chat/message-parser@^0.31.26":
|
||||
version "0.31.26"
|
||||
resolved "https://registry.yarnpkg.com/@rocket.chat/message-parser/-/message-parser-0.31.26.tgz#792785355634ed1bead6ee4051d496475964d5c4"
|
||||
integrity sha512-mRNi0od4YFhlQpcFBP9dVnlzcFZa3WgU8Sijtw0/bjTXU08hRcdAqUGt5CQkWtHe04MTTkjHs6kpwB0AYINu9Q==
|
||||
dependencies:
|
||||
tldts "~5.7.112"
|
||||
|
||||
"@rocket.chat/sdk@RocketChat/Rocket.Chat.js.SDK#mobile":
|
||||
version "1.3.1-mobile"
|
||||
|
@ -20186,6 +20188,18 @@ tinycolor2@^1.4.2:
|
|||
resolved "https://registry.yarnpkg.com/tinycolor2/-/tinycolor2-1.6.0.tgz#f98007460169b0263b97072c5ae92484ce02d09e"
|
||||
integrity sha512-XPaBkWQJdsf3pLKJV9p4qN/S+fm2Oj8AIPo1BTUhg5oxkvm9+SVEGFdhyOz7tTdUTfvxMiAs4sp6/eZO2Ew+pw==
|
||||
|
||||
tldts-core@^5.7.112:
|
||||
version "5.7.112"
|
||||
resolved "https://registry.yarnpkg.com/tldts-core/-/tldts-core-5.7.112.tgz#168459aa79495f5d46407a685a7a9f0cdc9a272b"
|
||||
integrity sha512-mutrEUgG2sp0e/MIAnv9TbSLR0IPbvmAImpzqul5O/HJ2XM1/I1sajchQ/fbj0fPdA31IiuWde8EUhfwyldY1Q==
|
||||
|
||||
tldts@~5.7.112:
|
||||
version "5.7.112"
|
||||
resolved "https://registry.yarnpkg.com/tldts/-/tldts-5.7.112.tgz#f3d7a5ade3ee09a48a1ecb4f05f04335b0787c84"
|
||||
integrity sha512-6VSJ/C0uBtc2PQlLsp4IT8MIk2UUh6qVeXB1HZtK+0HiXlAPzNcfF3p2WM9RqCO/2X1PIa4danlBLPoC2/Tc7A==
|
||||
dependencies:
|
||||
tldts-core "^5.7.112"
|
||||
|
||||
tmp@^0.0.33:
|
||||
version "0.0.33"
|
||||
resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.0.33.tgz#6d34335889768d21b2bcda0aa277ced3b1bfadf9"
|
||||
|
|
Loading…
Reference in New Issue