|
101 | 101 | transform: scale(1.1);
|
102 | 102 | }
|
103 | 103 | </style>
|
| 104 | +<style> |
| 105 | +#button-top { |
| 106 | + display: inline-block; |
| 107 | + background-color: #275EFE; |
| 108 | + width: 50px; |
| 109 | + height: 50px; |
| 110 | + text-align: center; |
| 111 | + border-radius: 5px; |
| 112 | + position: fixed; |
| 113 | + bottom: 30px; |
| 114 | + right: 30px; |
| 115 | + transition: background-color .3s, |
| 116 | + opacity .5s, visibility .5s; |
| 117 | + opacity: 0; |
| 118 | + visibility: hidden; |
| 119 | + z-index: 1000; |
| 120 | +} |
| 121 | +#button-top::after { |
| 122 | + content: "\f077"; |
| 123 | + font-family: FontAwesome; |
| 124 | + font-weight: normal; |
| 125 | + font-style: normal; |
| 126 | + font-size: 2em; |
| 127 | + line-height: 50px; |
| 128 | + color: #fff; |
| 129 | +} |
| 130 | +#button-top:hover { |
| 131 | + cursor: pointer; |
| 132 | + -webkit-filter: brightness(90%); |
| 133 | +} |
| 134 | +#button-top:active { |
| 135 | + background-color: #555; |
| 136 | +} |
| 137 | +#button-top.show { |
| 138 | + opacity: 1; |
| 139 | + visibility: visible; |
| 140 | +} |
| 141 | +
|
| 142 | +/* Styles for the content section */ |
| 143 | +
|
| 144 | +.content { |
| 145 | + width: 77%; |
| 146 | + margin: 50px auto; |
| 147 | + font-family: 'Merriweather', serif; |
| 148 | + font-size: 17px; |
| 149 | + color: #6c767a; |
| 150 | + line-height: 1.9; |
| 151 | +} |
| 152 | +@media (min-width: 500px) { |
| 153 | + .content { |
| 154 | + width: 43%; |
| 155 | + } |
| 156 | + #button-top { |
| 157 | + margin: 30px; |
| 158 | + } |
| 159 | +} |
| 160 | +.content h1 { |
| 161 | + margin-bottom: -10px; |
| 162 | + color: #03a9f4; |
| 163 | + line-height: 1.5; |
| 164 | +} |
| 165 | +.content h3 { |
| 166 | + font-style: italic; |
| 167 | + color: #96a2a7; |
| 168 | +} |
| 169 | +</style> |
104 | 170 |
|
105 | 171 | <div class="option"><a href="?alternative-config">
|
106 | 172 | <div class="row"><i class="bi bi-pencil-square opt-img"></i><div>
|
|
178 | 244 |
|
179 | 245 | </div>
|
180 | 246 | </div>
|
| 247 | + |
| 248 | +<!-- Back to top button --> |
| 249 | +<a id="button-top"></a> |
| 250 | + |
181 | 251 | @elseif($_SERVER['QUERY_STRING'] == 'alternative-config')
|
182 | 252 | @include('components.config.alternative-config')
|
183 | 253 | @include('components.config.back-button')
|
184 | 254 | @endif
|
185 | 255 |
|
186 |
| - |
187 | 256 | @push("sidebar-scripts")
|
188 | 257 | <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
|
189 | 258 | <script src="//maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
|
|
203 | 272 | var hash = window.location.hash;
|
204 | 273 | $('#myTab a[href="' + hash + '"]').tab('show');
|
205 | 274 | </script>
|
| 275 | +<script> |
| 276 | +var btn = $('#button-top'); |
| 277 | +
|
| 278 | +$(window).scroll(function() { |
| 279 | + if ($(window).scrollTop() > 300) { |
| 280 | + btn.addClass('show'); |
| 281 | + } else { |
| 282 | + btn.removeClass('show'); |
| 283 | + } |
| 284 | +}); |
| 285 | +
|
| 286 | +btn.on('click', function(e) { |
| 287 | + e.preventDefault(); |
| 288 | + $('html, body').animate({scrollTop:250}, '300'); |
| 289 | +}); |
| 290 | +</script> |
206 | 291 | @endpush
|
207 | 292 |
|
| 293 | + |
208 | 294 | @endsection
|
0 commit comments