(ctx, { target: to, offset })
| 6418 | return new _GoCommand(target, null, false, newWindow); |
| 6419 | } |
| 6420 | resolve(ctx, { target: to, offset }) { |
| 6421 | if (this.back) { |
| 6422 | window.history.back(); |
| 6423 | } else if (this.scrollOptions) { |
| 6424 | _resolveScroll(ctx, to, offset, this.plusOrMinus, this.scrollOptions); |
| 6425 | } else if (to != null) { |
| 6426 | if (to instanceof Element) { |
| 6427 | to.scrollIntoView({ block: "start", inline: "nearest" }); |
| 6428 | } else { |
| 6429 | var str = String(to); |
| 6430 | if (str.startsWith("#")) { |
| 6431 | window.location.hash = str; |
| 6432 | } else if (this.newWindow) { |
| 6433 | window.open(str); |
| 6434 | } else { |
| 6435 | window.location.href = str; |
| 6436 | } |
| 6437 | } |
| 6438 | } |
| 6439 | return this.findNext(ctx); |
| 6440 | } |
| 6441 | }; |
| 6442 | |
| 6443 | // src/parsetree/commands/setters.js |
nothing calls this directly
no test coverage detected