When you have multiple strings on each line with at least 1 f-string that isn't on the last line, bracket highlighting doesn't work although it's valid Python string literal concatenation syntax. Bracket highlighting works properly if the f-string is on the last line.
Describe the issue
When you have multiple strings on each line with at least 1 f-string that isn't on the last line, bracket highlighting doesn't work although it's valid Python string literal concatenation syntax. Bracket highlighting works properly if the f-string is on the last line.
Here's a video with the issue:
https://github.com/user-attachments/assets/2e24db2f-5637-4af5-bcb9-38dfb243de58
I think it could be a regression issue as the issue is there on https://codemirror.net/try/ but not on the older CodeMirror 5 Python mode
Browser and platform
JupyterLab Desktop 4.2.5-1, Windows 11
Reproduction link
https://codemirror.net/try/?c=aW1wb3J0IHtiYXNpY1NldHVwLCBFZGl0b3JWaWV3fSBmcm9tICJjb2RlbWlycm9yIgppbXBvcnQge3B5dGhvbn0gZnJvbSAiQGNvZGVtaXJyb3IvbGFuZy1weXRob24iOwoKbmV3IEVkaXRvclZpZXcoewogIGRvYzogInByaW50KFxuZid0ZXN0J1xuJ3Rlc3QnXG4pIiwKICBleHRlbnNpb25zOiBbYmFzaWNTZXR1cCwgcHl0aG9uKCldLAogIHBhcmVudDogZG9jdW1lbnQuYm9keQp9KQo=