33 See the LICENCE file in the repository root for full licence text.
44--}}
55@php
6- $filter ??= null ;
7- $mode ??= default_mode ();
8- $sort ??= null ;
9- $type ??= ' performance ' ;
10- $variant ??= null ;
6+ $params [ ' filter' ] ??= null ;
7+ $params [ ' mode' ] ??= default_mode ();
8+ $params [ ' sort' ] ??= null ;
9+ $params [ ' type' ] ??= ' global ' ;
10+ $params [ ' variant' ] ??= null ;
1111@endphp
1212@if ($object instanceof App \Models \Country )
1313 <a
1414 class =" ranking-page-table-main"
1515 href =" {{ route (' rankings' , [
16- ' mode' => $mode ,
17- ' type' => ' performance ' ,
16+ ' mode' => $params [ ' mode' ] ,
17+ ' type' => ' global ' ,
1818 ' country' => $object -> acronym ,
1919 ]) } }"
2020 >
@@ -31,8 +31,8 @@ class="ranking-page-table-main"
3131 <a
3232 class =" ranking-page-table-main"
3333 href =" {{ route (' teams.leaderboard' , [
34- ' ruleset' => $mode ,
35- ' sort' => $sort ,
34+ ' ruleset' => $params [ ' mode' ] ,
35+ ' sort' => $params [ ' sort' ] ,
3636 ' team' => $object ,
3737 ]) } }"
3838 >
@@ -49,13 +49,13 @@ class="ranking-page-table-main"
4949 <a
5050 class =" u-contents"
5151 href =" {{ route (' rankings' , [
52- ' mode' => $mode ,
53- ' sort' => $sort ,
54- ' type' => $type ,
52+ ' mode' => $params [ ' mode' ] ,
53+ ' sort' => $params [ ' sort' ] ,
54+ ' type' => $params [ ' type' ] ,
5555
5656 ' country' => $object -> country -> acronym ,
57- ' filter' => $filter ,
58- ' variant' => $variant ,
57+ ' filter' => $params [ ' filter' ] ,
58+ ' variant' => $params [ ' variant' ] ,
5959 ]) } }"
6060 >
6161 @include (' objects._flag_country' , [
@@ -76,7 +76,7 @@ class="u-contents"
7676 class =" ranking-page-table-main__link js-usercard"
7777 data-tooltip-position =" right center"
7878 data-user-id =" {{ $object -> getKey () } }"
79- href =" {{ route (' users.show' , [' user' => $object -> getKey (), ' mode' => $mode ]) } }"
79+ href =" {{ route (' users.show' , [' user' => $object -> getKey (), ' mode' => $params [ ' mode' ] ]) } }"
8080 >
8181 @if ($showAvatar ?? false )
8282 <span class =" ranking-page-table-main__flag" >
0 commit comments