Skip to content

Commit 6d0f642

Browse files
committed
position poptup in top-left
1 parent 8ae6b25 commit 6d0f642

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

app/pods/components/intermediate-contest-view/component.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,6 @@ export default class IntermediateContestComponent extends Component {
118118
}
119119

120120
@action async openTestInNewWindow() {
121-
window.open(`${ENV.publicUrl}/contests/${this.contest.id}/attempt/`, '_blank', `menubar=1,resizable=0,height=${window.screen.availHeight},width=${window.screen.availWidth}`)
121+
window.open(`${ENV.publicUrl}/contests/${this.contest.id}/attempt/`, `hackerblocks-contest-${this.contest.id}`, `menubar=1,resizable=0,height=${window.screen.availHeight},width=${window.screen.availWidth},top=0,left=0`)
122122
}
123123
}

app/pods/contests/contest/index/controller.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,6 @@ export default class IndexController extends Controller {
6262
}
6363
@action
6464
onAfterCreate() {
65-
window.open(`${ENV.publicUrl}/contests/${this.contest.id}/attempt/`, `hackerblocks-contest-${this.contest.id}`, `menubar=0,resizable=0,height=${window.screen.availHeight},width=${window.screen.availWidth}`)
65+
window.open(`${ENV.publicUrl}/contests/${this.contest.id}/attempt/`, `hackerblocks-contest-${this.contest.id}`, `menubar=1,resizable=0,height=${window.screen.availHeight},width=${window.screen.availWidth},top=0,left=0`)
6666
}
6767
}

0 commit comments

Comments
 (0)