From e84be8f0a0fb702f25d1288b8f65e412471086f7 Mon Sep 17 00:00:00 2001 From: lisa Date: Wed, 11 Dec 2024 16:50:33 +0100 Subject: [PATCH] fix: tests --- .../__snapshots__/Regular.test.tsx.snap | 4 +- .../__snapshots__/index.test.tsx.snap | 46 ++++++------ .../__snapshots__/index.test.tsx.snap | 75 +++++++------------ .../components/Navigation/components/Item.tsx | 6 +- .../__snapshots__/index.test.tsx.snap | 2 +- .../components/Text/__tests__/index.test.tsx | 2 +- 6 files changed, 55 insertions(+), 80 deletions(-) diff --git a/packages/plus/src/components/EstimateCost/__tests__/__snapshots__/Regular.test.tsx.snap b/packages/plus/src/components/EstimateCost/__tests__/__snapshots__/Regular.test.tsx.snap index 02dcc8dfa2..786d3c5f96 100644 --- a/packages/plus/src/components/EstimateCost/__tests__/__snapshots__/Regular.test.tsx.snap +++ b/packages/plus/src/components/EstimateCost/__tests__/__snapshots__/Regular.test.tsx.snap @@ -7590,6 +7590,7 @@ exports[`EstimateCost - Regular Item > render basic props with overlay beta 1`] text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -7602,7 +7603,6 @@ exports[`EstimateCost - Regular Item > render basic props with overlay beta 1`] -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -8228,6 +8228,7 @@ exports[`EstimateCost - Regular Item > render basic props with overlay beta 1`] text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -8240,7 +8241,6 @@ exports[`EstimateCost - Regular Item > render basic props with overlay beta 1`] -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; diff --git a/packages/plus/src/components/EstimateCost/__tests__/__snapshots__/index.test.tsx.snap b/packages/plus/src/components/EstimateCost/__tests__/__snapshots__/index.test.tsx.snap index 8d9a497b09..74de5517ae 100644 --- a/packages/plus/src/components/EstimateCost/__tests__/__snapshots__/index.test.tsx.snap +++ b/packages/plus/src/components/EstimateCost/__tests__/__snapshots__/index.test.tsx.snap @@ -284,6 +284,7 @@ exports[`EstimateCost - index > render isBeta with discount 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -296,7 +297,6 @@ exports[`EstimateCost - index > render isBeta with discount 1`] = ` -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -898,6 +898,7 @@ exports[`EstimateCost - index > render isBeta with discount 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -910,7 +911,6 @@ exports[`EstimateCost - index > render isBeta with discount 1`] = ` -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -1581,6 +1581,7 @@ exports[`EstimateCost - index > render isBeta with discount equal to 100% 1`] = text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -1593,7 +1594,6 @@ exports[`EstimateCost - index > render isBeta with discount equal to 100% 1`] = -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -2195,6 +2195,7 @@ exports[`EstimateCost - index > render isBeta with discount equal to 100% 1`] = text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -2207,7 +2208,6 @@ exports[`EstimateCost - index > render isBeta with discount equal to 100% 1`] = -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -2883,6 +2883,7 @@ exports[`EstimateCost - index > render isBeta with discount more than 100% 1`] = text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -2895,7 +2896,6 @@ exports[`EstimateCost - index > render isBeta with discount more than 100% 1`] = -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -3497,6 +3497,7 @@ exports[`EstimateCost - index > render isBeta with discount more than 100% 1`] = text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -3509,7 +3510,6 @@ exports[`EstimateCost - index > render isBeta with discount more than 100% 1`] = -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -4190,6 +4190,7 @@ exports[`EstimateCost - index > render isBeta without discount 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -4202,7 +4203,6 @@ exports[`EstimateCost - index > render isBeta without discount 1`] = ` -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -4804,6 +4804,7 @@ exports[`EstimateCost - index > render isBeta without discount 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -4816,7 +4817,6 @@ exports[`EstimateCost - index > render isBeta without discount 1`] = ` -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -17268,6 +17268,7 @@ exports[`EstimateCost - index > render with discount 1, isBeta and defaultTimeUn text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -17280,7 +17281,6 @@ exports[`EstimateCost - index > render with discount 1, isBeta and defaultTimeUn -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -17882,6 +17882,7 @@ exports[`EstimateCost - index > render with discount 1, isBeta and defaultTimeUn text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -17894,7 +17895,6 @@ exports[`EstimateCost - index > render with discount 1, isBeta and defaultTimeUn -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -22741,6 +22741,7 @@ exports[`EstimateCost - index > render with isBeta but undefined discount 1`] = text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -22753,7 +22754,6 @@ exports[`EstimateCost - index > render with isBeta but undefined discount 1`] = -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -23355,6 +23355,7 @@ exports[`EstimateCost - index > render with isBeta but undefined discount 1`] = text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -23367,7 +23368,6 @@ exports[`EstimateCost - index > render with isBeta but undefined discount 1`] = -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -24321,6 +24321,7 @@ exports[`EstimateCost - index > render with isBeta, discount 0 and defaultTimeUn text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -24333,7 +24334,6 @@ exports[`EstimateCost - index > render with isBeta, discount 0 and defaultTimeUn -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -24361,6 +24361,7 @@ exports[`EstimateCost - index > render with isBeta, discount 0 and defaultTimeUn text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -24373,7 +24374,6 @@ exports[`EstimateCost - index > render with isBeta, discount 0 and defaultTimeUn -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -25549,6 +25549,7 @@ exports[`EstimateCost - index > render with isBeta, discount 0 and defaultTimeUn text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -25561,7 +25562,6 @@ exports[`EstimateCost - index > render with isBeta, discount 0 and defaultTimeUn -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -25587,6 +25587,7 @@ exports[`EstimateCost - index > render with isBeta, discount 0 and defaultTimeUn text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -25599,7 +25600,6 @@ exports[`EstimateCost - index > render with isBeta, discount 0 and defaultTimeUn -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -26557,6 +26557,7 @@ exports[`EstimateCost - index > render with isBeta, discount 0.5 and defaultTime text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -26569,7 +26570,6 @@ exports[`EstimateCost - index > render with isBeta, discount 0.5 and defaultTime -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -26597,6 +26597,7 @@ exports[`EstimateCost - index > render with isBeta, discount 0.5 and defaultTime text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -26609,7 +26610,6 @@ exports[`EstimateCost - index > render with isBeta, discount 0.5 and defaultTime -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -27785,6 +27785,7 @@ exports[`EstimateCost - index > render with isBeta, discount 0.5 and defaultTime text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -27797,7 +27798,6 @@ exports[`EstimateCost - index > render with isBeta, discount 0.5 and defaultTime -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -27823,6 +27823,7 @@ exports[`EstimateCost - index > render with isBeta, discount 0.5 and defaultTime text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -27835,7 +27836,6 @@ exports[`EstimateCost - index > render with isBeta, discount 0.5 and defaultTime -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -28520,6 +28520,7 @@ exports[`EstimateCost - index > render with isBeta, price, discount 50% 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -28532,7 +28533,6 @@ exports[`EstimateCost - index > render with isBeta, price, discount 50% 1`] = ` -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -29134,6 +29134,7 @@ exports[`EstimateCost - index > render with isBeta, price, discount 50% 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -29146,7 +29147,6 @@ exports[`EstimateCost - index > render with isBeta, price, discount 50% 1`] = ` -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.75rem; gap: 0.5rem; @@ -32096,6 +32096,7 @@ exports[`EstimateCost - index > render with item discount 50% and text 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: nowrap; display: -webkit-inline-box; display: -webkit-inline-flex; display: -ms-inline-flexbox; @@ -32108,7 +32109,6 @@ exports[`EstimateCost - index > render with item discount 50% and text 1`] = ` -ms-flex-pack: center; -webkit-justify-content: center; justify-content: center; - white-space: nowrap; border-radius: 1rem; padding: 0 0.5rem; gap: 0.25rem; diff --git a/packages/plus/src/components/Navigation/__tests__/__snapshots__/index.test.tsx.snap b/packages/plus/src/components/Navigation/__tests__/__snapshots__/index.test.tsx.snap index b9cd052ede..183fac0cb6 100644 --- a/packages/plus/src/components/Navigation/__tests__/__snapshots__/index.test.tsx.snap +++ b/packages/plus/src/components/Navigation/__tests__/__snapshots__/index.test.tsx.snap @@ -860,13 +860,12 @@ exports[`Navigation > click on expand / collapse button 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-23 { @@ -879,13 +878,12 @@ exports[`Navigation > click on expand / collapse button 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-25 { @@ -1274,13 +1272,12 @@ exports[`Navigation > click on expand / collapse button 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-65 { @@ -1293,13 +1290,12 @@ exports[`Navigation > click on expand / collapse button 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-84 { @@ -3913,13 +3909,12 @@ exports[`Navigation > pin and unpin an item 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-23 { @@ -3932,13 +3927,12 @@ exports[`Navigation > pin and unpin an item 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-25 { @@ -4327,13 +4321,12 @@ exports[`Navigation > pin and unpin an item 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-65 { @@ -4346,13 +4339,12 @@ exports[`Navigation > pin and unpin an item 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-84 { @@ -5887,13 +5879,12 @@ exports[`Navigation > pin and unpin an item 2`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-23 { @@ -5906,13 +5897,12 @@ exports[`Navigation > pin and unpin an item 2`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-25 { @@ -6301,13 +6291,12 @@ exports[`Navigation > pin and unpin an item 2`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-65 { @@ -6320,13 +6309,12 @@ exports[`Navigation > pin and unpin an item 2`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-84 { @@ -7861,13 +7849,12 @@ exports[`Navigation > pin and unpin an item 3`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-23 { @@ -7880,13 +7867,12 @@ exports[`Navigation > pin and unpin an item 3`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-25 { @@ -8109,13 +8095,12 @@ exports[`Navigation > pin and unpin an item 3`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-54 { @@ -8374,13 +8359,12 @@ exports[`Navigation > pin and unpin an item 3`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-88 { @@ -8393,13 +8377,12 @@ exports[`Navigation > pin and unpin an item 3`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-116 { @@ -9470,13 +9453,12 @@ exports[`Navigation > render with basic content 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-25 { @@ -9677,13 +9659,12 @@ exports[`Navigation > render with basic content 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-84 { @@ -10693,13 +10674,12 @@ exports[`Navigation > render without pinnedFeature 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-35 { @@ -10743,13 +10723,12 @@ exports[`Navigation > render without pinnedFeature 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-52 { @@ -11945,13 +11924,12 @@ exports[`Navigation > resize manually the navigation using slider 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-23 { @@ -11964,13 +11942,12 @@ exports[`Navigation > resize manually the navigation using slider 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-25 { @@ -12359,13 +12336,12 @@ exports[`Navigation > resize manually the navigation using slider 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-65 { @@ -12378,13 +12354,12 @@ exports[`Navigation > resize manually the navigation using slider 1`] = ` text-transform: none; -webkit-text-decoration: none; text-decoration: none; + white-space: pre-wrap; overflow-wrap: anywhere; - white-space: normal; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; - white-space: pre-wrap; } .emotion-84 { diff --git a/packages/plus/src/components/Navigation/components/Item.tsx b/packages/plus/src/components/Navigation/components/Item.tsx index fdd42774b9..b01e68a8ec 100644 --- a/packages/plus/src/components/Navigation/components/Item.tsx +++ b/packages/plus/src/components/Navigation/components/Item.tsx @@ -128,7 +128,6 @@ const WrapText = styled(Text, { subLabel?: boolean }>` overflow-wrap: ${({ animation }) => (animation ? 'normal' : 'anywhere')}; - white-space: ${({ animation }) => (animation ? 'nowrap' : 'normal')}; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; @@ -549,7 +548,7 @@ export const Item = memo( expanded ? onDragStopTrigger(event) : undefined } id={id} - data-testId={dataTestId} + data-testid={dataTestId} > {label} @@ -805,7 +805,7 @@ export const Item = memo( flex={1} width="100%" > - + {label} diff --git a/packages/ui/src/components/Text/__tests__/__snapshots__/index.test.tsx.snap b/packages/ui/src/components/Text/__tests__/__snapshots__/index.test.tsx.snap index 0105f16fc5..b17b291cd5 100644 --- a/packages/ui/src/components/Text/__tests__/__snapshots__/index.test.tsx.snap +++ b/packages/ui/src/components/Text/__tests__/__snapshots__/index.test.tsx.snap @@ -802,7 +802,7 @@ exports[`Text > with italic 1`] = ` `; -exports[`Text > with monochrome 1`] = ` +exports[`Text > with monochrome 1`] = ` .emotion-0 { color: #151a2d; diff --git a/packages/ui/src/components/Text/__tests__/index.test.tsx b/packages/ui/src/components/Text/__tests__/index.test.tsx index 1b40bf4c79..e8403f2465 100644 --- a/packages/ui/src/components/Text/__tests__/index.test.tsx +++ b/packages/ui/src/components/Text/__tests__/index.test.tsx @@ -93,7 +93,7 @@ describe('Text', () => { , )) - test(`with monochrome `, () => + test(`with monochrome`, () => shouldMatchEmotionSnapshot( Lorem Ipsum