-
Notifications
You must be signed in to change notification settings - Fork 295
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #842 from Stremio/feat/library-login-placeholder
Library: Align Guest placeholder with Calendar guest placeholder
- Loading branch information
Showing
6 changed files
with
231 additions
and
85 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,132 @@ | ||
// Copyright (C) 2017-2025 Smart code 203358507 | ||
|
||
@import (reference) '~stremio/common/screen-sizes.less'; | ||
|
||
.placeholder { | ||
position: relative; | ||
display: flex; | ||
flex-direction: column; | ||
align-items: center; | ||
justify-content: center; | ||
min-height: 100%; | ||
width: 100%; | ||
overflow-y: auto; | ||
|
||
.title { | ||
font-size: 1.75rem; | ||
font-weight: 400; | ||
text-align: center; | ||
color: var(--primary-foreground-color); | ||
margin-bottom: 1rem; | ||
opacity: 0.5; | ||
} | ||
|
||
.image-container { | ||
padding: 1.5rem 0; | ||
|
||
.image { | ||
height: 100%; | ||
max-height: 14rem; | ||
object-fit: contain; | ||
} | ||
} | ||
|
||
.overview { | ||
display: flex; | ||
flex-direction: row; | ||
align-items: center; | ||
gap: 4rem; | ||
margin-bottom: 1rem; | ||
|
||
.point { | ||
display: flex; | ||
flex-direction: row; | ||
align-items: center; | ||
gap: 1.5rem; | ||
width: 18rem; | ||
|
||
.icon { | ||
flex: none; | ||
height: 3.25rem; | ||
width: 3.25rem; | ||
color: var(--primary-foreground-color); | ||
opacity: 0.3; | ||
} | ||
|
||
.text { | ||
flex: auto; | ||
font-size: 1.1rem; | ||
font-size: 500; | ||
color: var(--primary-foreground-color); | ||
opacity: 0.9; | ||
} | ||
} | ||
} | ||
|
||
.button-container { | ||
margin: 1rem 0; | ||
|
||
.button { | ||
display: flex; | ||
justify-content: center; | ||
height: 4rem; | ||
line-height: 4rem; | ||
padding: 0 5rem; | ||
font-size: 1.1rem; | ||
color: var(--primary-foreground-color); | ||
text-align: center; | ||
border-radius: 3.5rem; | ||
background-color: var(--overlay-color); | ||
|
||
&:hover { | ||
outline: var(--focus-outline-size) solid var(--primary-foreground-color); | ||
background-color: transparent; | ||
} | ||
} | ||
} | ||
} | ||
|
||
@media only screen and (max-width: @xsmall) { | ||
.placeholder { | ||
padding: 1rem 2rem; | ||
|
||
.title { | ||
margin-bottom: 0; | ||
} | ||
|
||
.image-container { | ||
padding: 1rem; | ||
|
||
.image { | ||
max-height: 10rem; | ||
} | ||
} | ||
|
||
.button-container { | ||
margin: 1rem 0 0; | ||
} | ||
} | ||
} | ||
|
||
@media only screen and (max-width: @minimum) { | ||
.placeholder { | ||
padding: 1rem 2rem; | ||
|
||
.overview { | ||
flex-direction: column; | ||
gap: 1rem; | ||
|
||
.point { | ||
.text { | ||
font-size: 1rem; | ||
} | ||
} | ||
} | ||
|
||
.button-container { | ||
.button { | ||
width: 100%; | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
// Copyright (C) 2017-2025 Smart code 203358507 | ||
|
||
import React from 'react'; | ||
import { useTranslation } from 'react-i18next'; | ||
import Icon from '@stremio/stremio-icons/react'; | ||
import { Button, Image } from 'stremio/components'; | ||
import styles from './Placeholder.less'; | ||
|
||
const Placeholder = () => { | ||
const { t } = useTranslation(); | ||
|
||
return ( | ||
<div className={styles['placeholder']}> | ||
<div className={styles['title']}> | ||
{t('LIBRARY_NOT_LOGGED_IN')} | ||
</div> | ||
<div className={styles['image-container']}> | ||
<Image | ||
className={styles['image']} | ||
src={require('/images/library_placeholder.png')} | ||
alt={' '} | ||
/> | ||
</div> | ||
<div className={styles['overview']}> | ||
<div className={styles['point']}> | ||
<Icon className={styles['icon']} name={'cloud-library'} /> | ||
<div className={styles['text']}> | ||
{t('NOT_LOGGED_IN_CLOUD')} | ||
</div> | ||
</div> | ||
<div className={styles['point']}> | ||
<Icon className={styles['icon']} name={'actors'} /> | ||
<div className={styles['text']}> | ||
{t('NOT_LOGGED_IN_RECOMMENDATIONS')} | ||
</div> | ||
</div> | ||
</div> | ||
<div className={styles['button-container']}> | ||
<Button className={styles['button']} href={'#/intro?form=login'}> | ||
{t('LOG_IN')} | ||
</Button> | ||
</div> | ||
</div> | ||
); | ||
}; | ||
|
||
export default Placeholder; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
// Copyright (C) 2017-2025 Smart code 203358507 | ||
|
||
import Placeholder from './Placeholder'; | ||
|
||
export default Placeholder; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters