[web] Don't get break type from v8BreakIterator (#43053)

In some languages, when the text contains a new line "\n", the `v8BreakIterator` starts returning different values from `breakType()`. This caused our code to think that those line breaks were hard line breaks when in fact they were soft line breaks. Still unclear if this is a `v8BreakIterator` bug or a wrong expectation on our side regarding how `breakType()` is supposed to work.

Instead of using `v8BreakIterator.breakType()`, let's do the `soft` vs `hard` detection ourselves (we already have all the necessary pieces).

Fixes https://github.com/flutter/flutter/issues/127379
https://dart.googlesource.com/external/github.com/flutter/engine/+/0a10768017dd0edbbc52871d10d3c1e68d2f9ae0
1 file changed
tree: ab4205b126836d9f33fbab3c18cf59b4a98510d6
  1. commits.json