mirror of
https://github.com/cheeaun/phanpy.git
synced 2024-12-18 08:21:45 +03:00
Merge pull request #856 from Steffo99/feature/login-default-instance
Use the same logic as the main login button for the login tooltip in posts
This commit is contained in:
commit
e2e9e3cdb0
1 changed files with 10 additions and 1 deletions
|
@ -44,6 +44,8 @@ import useTitle from '../utils/useTitle';
|
|||
|
||||
import getInstanceStatusURL from './../utils/get-instance-status-url';
|
||||
|
||||
const { PHANPY_DEFAULT_INSTANCE: DEFAULT_INSTANCE } = import.meta.env;
|
||||
|
||||
const LIMIT = 40;
|
||||
const SUBCOMMENTS_OPEN_ALL_LIMIT = 10;
|
||||
const MAX_WEIGHT = 5;
|
||||
|
@ -788,7 +790,14 @@ function StatusThread({ id, closeLink = '/', instance: propInstance }) {
|
|||
not possible.
|
||||
</Trans>
|
||||
</p>
|
||||
<Link to="/login" class="button">
|
||||
<Link
|
||||
to={
|
||||
DEFAULT_INSTANCE
|
||||
? `/login?instance=${DEFAULT_INSTANCE}&submit=1`
|
||||
: '/login'
|
||||
}
|
||||
class="button"
|
||||
>
|
||||
<Trans>Log in</Trans>
|
||||
</Link>
|
||||
</div>
|
||||
|
|
Loading…
Reference in a new issue