File tree Expand file tree Collapse file tree 3 files changed +9
-4
lines changed Expand file tree Collapse file tree 3 files changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -2,8 +2,11 @@ import Controller from '@ember/controller';
22import { action } from '@ember/object' ;
33
44export default class CatchAllController extends Controller {
5- @action reload ( event ) {
6- event . preventDefault ( ) ;
5+ @action reload ( ) {
76 this . model . transition . retry ( ) ;
87 }
8+
9+ @action back ( ) {
10+ history . back ( ) ;
11+ }
912}
Original file line number Diff line number Diff line change 1515}
1616
1717.link {
18+ composes : button-reset from '../styles/shared/buttons.module.css' ;
19+ composes : link from '../styles/application.module.css' ;
1820 font-weight : 500 ;
1921}
Original file line number Diff line number Diff line change 55 <h1 local-class =" title" data-test-title>{{ or @model.title " Page not found" }} </h1 >
66
77 {{ #if @model.tryAgain }}
8- <a href = " javascript:location.reload() " local-class =" link" data-test-try-again {{ on " click" this.reload }} >Try Again</a >
8+ <button type = " button " local-class =" link" data-test-try-again {{ on " click" this.reload }} >Try Again</button >
99 {{ else }}
10- <a href = " javascript:history.back() " local-class =" link" data-test-go-back>Go Back</a >
10+ <button type = " button " local-class =" link" data-test-go-back {{ on " click " this.back }} >Go Back</button >
1111 {{ /if }}
1212 </div >
1313</div >
You can’t perform that action at this time.
0 commit comments