[js/web] allow relative path matching (#21657)
### Description
<!-- Describe your changes. -->
This change allows to match external data path like `a.data` to
`./a.data`.
<!-- - Why is this change required? What problem does it solve?
- If it fixes an open issue, please link to the issue here. -->