added empty screen

This commit is contained in:
Elyor Djalilov 2024-06-19 20:02:37 +05:00
parent da52dad975
commit f713c56f50
4 changed files with 61 additions and 9 deletions

View File

@ -175,6 +175,7 @@
"Migration": "Migration",
"NewColorScheme": "New color scheme",
"NextStep": "Next step",
"NoSessionsHere": "No other sessions here yet",
"NoEmail": "NO EMAIL",
"NoUsersInBackup": "No users found. Try again or upload other backup files.",
"NumberOfActiveEmployees": "Number of active employees: {{count}}",

View File

@ -173,6 +173,7 @@
"Migration": "Миграция",
"NewColorScheme": "Новая цветовая схема",
"NextStep": "Следующий шаг",
"NoSessionsHere": "Здесь пока нет других сессии",
"NoEmail": "НЕТ ЭЛЕКТРОННОЙ ПОЧТЫ",
"NoUsersInBackup": "Пользователи не найдены. Попробуйте снова или загрузите другие файлы резервной копии.",
"NumberOfActiveEmployees": "Количество активных сотрудников: {{count}}",

View File

@ -1,12 +1,20 @@
import { observer, inject } from "mobx-react";
import { Text } from "@docspace/shared/components/text";
import { Button } from "@docspace/shared/components/button";
import { EmptyScreenContainer } from "@docspace/shared/components/empty-screen-container";
import styled from "styled-components";
import RowWrapper from "./sub-components";
import EmptyScreenSessionsReactSvgUrl from "PUBLIC_DIR/images/empty_screen_from_sessions.svg?url";
const Wrapper = styled.div`
padding: 20px 20px 12px;
.empty-screen-container {
width: auto;
padding-top: 60px;
}
.subtitle {
font-size: 14px;
font-weight: 600;
@ -28,7 +36,6 @@ const AllSessionsBlock = (props) => {
onClickLogoutAllExceptThis,
} = props;
const isDisabled = connections.length > 0;
const exceptId = userLastSession.connections[0]?.id;
return (
@ -36,14 +43,22 @@ const AllSessionsBlock = (props) => {
<Wrapper>
<Text className="subtitle">{t("Profile:AllSessions")}</Text>
<Text className="desciption">{t("Profile:PanelDescription")}</Text>
{connections.length > 0 ? (
<Button
label={t("Profile:LogoutFromAllSessions")}
size="small"
onClick={() => onClickLogoutAllExceptThis(t, exceptId)}
scale={true}
isLoading={isLoading}
isDisabled={!isDisabled}
/>
) : (
<EmptyScreenContainer
imageSrc={EmptyScreenSessionsReactSvgUrl}
className="empty-screen-container"
imageAlt="Empty Screen Sessions image"
headerText={t("Settings:NoSessionsHere")}
/>
)}
</Wrapper>
<RowWrapper t={t} connections={connections} />

View File

@ -0,0 +1,35 @@
<svg width="76" height="75" viewBox="0 0 76 75" fill="none" xmlns="http://www.w3.org/2000/svg">
<rect x="10" y="0.5" width="56" height="74" rx="7.5" fill="white" stroke="#333333"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M38 14C41.4502 14 44.5781 15.3971 46.8405 17.6595C49.1029 19.9219 50.5 23.0498 50.5 26.5C50.5 29.9502 49.0973 33.0781 46.8405 35.3405C44.5781 37.6029 41.4502 39 38 39C34.5498 39 31.4219 37.6029 29.1595 35.3405C26.8971 33.0781 25.5 29.9502 25.5 26.5C25.5 23.0498 26.9027 19.9219 29.1595 17.6595C31.4219 15.4027 34.5498 14 38 14Z" fill="#EFEFEF" stroke="#333333"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M38.2173 20.3165C39.3414 22.2149 41.9874 24.4208 43.8327 24.1556C43.8486 23.9647 43.8592 23.7738 43.8592 23.5829C43.8592 20.3378 41.2291 17.713 37.9892 17.713C34.7441 17.713 32.1193 20.3431 32.1193 23.5829C32.1193 23.8057 32.1299 24.0284 32.1564 24.2458C33.9168 24.2193 36.8227 23.0315 38.2173 20.3165Z" fill="#AAAAAA"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M44.1504 24.0943C42.2548 24.3554 39.5367 22.1877 38.3819 20.3125C36.9493 22.9869 33.9643 24.1622 32.1504 24.1778C32.4881 27.0664 35.0428 29.3125 38.1422 29.3125C41.2798 29.3177 43.8508 27.0246 44.1504 24.0943Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M40.1568 33.5162L40.2845 33.3022C40.3437 33.2039 40.3438 33.1577 40.3438 32.9206V32.2324V28.8438C39.6415 29.3122 38.8481 29.5724 38 29.5724C37.1519 29.5724 36.3585 29.3064 35.6562 28.8438V28.9421V32.2151V32.9148C35.6562 33.1519 35.6563 33.1981 35.7155 33.2964L35.8432 33.5104C36.4086 34.4588 37.0424 35.2857 37.6443 36.315C37.7902 36.5637 37.8906 36.6793 38 36.6504C38.114 36.6851 38.2098 36.5637 38.3557 36.315C38.953 35.2915 39.5914 34.4646 40.1568 33.5162Z" fill="white"/>
<path d="M40.4059 33.1465V33.5904L40.3544 33.6454L40.3543 33.6456C40.1426 33.8723 39.7863 34.0508 39.2972 34.2899L39.279 34.2988C38.8446 34.5112 38.3003 34.7773 37.9231 35.1841C37.5522 34.782 37.0549 34.5168 36.6514 34.3016L36.641 34.2961C36.197 34.0593 35.8652 33.8796 35.6456 33.6429L35.6444 33.6417L35.5884 33.5817V33.139V32.562L35.0173 32.6441C32.8463 32.956 31.1413 33.66 29.7271 34.581L29.2054 34.9208L29.6498 35.3569C31.539 37.2109 34.7452 39 38 39C41.2371 39 44.4659 37.1913 46.3488 35.3583L46.7935 34.9253L46.2758 34.583C44.865 33.6499 43.1431 32.9706 40.9787 32.6519L40.4059 32.5675V33.1465ZM40.4861 33.5046C40.4871 33.5035 40.4873 33.5033 40.4865 33.5041L40.4861 33.5046ZM35.5127 33.5007L35.5124 33.5004C35.5117 33.4996 35.5118 33.4997 35.5127 33.5007Z" fill="#D9F4FF" stroke="#333333"/>
<path d="M35.5973 29.3056V32.2415M40.4014 29.3056V32.2415" stroke="#333333" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M38.0027 17.5C39.6572 17.5 41.1585 18.1694 42.2445 19.2555C43.3306 20.3415 44 21.8428 44 23.4973C44 25.1514 43.3309 26.6524 42.2451 27.7384C41.152 28.8264 39.6554 29.5 38.0027 29.5C36.3494 29.5 34.8478 28.8259 33.761 27.739C32.6739 26.652 32 25.1559 32 23.4973C32 21.843 32.6692 20.3419 33.755 19.2559C34.8471 18.1691 36.3487 17.5 38.0027 17.5Z" stroke="#333333"/>
<path d="M43.8753 23.9661C42.9102 24.104 41.7861 23.6692 40.7467 22.9586C39.7817 22.3011 38.8696 21.3944 38.228 20.4982C37.6023 21.4898 36.7751 22.2534 35.9055 22.8155C34.6063 23.6533 33.1905 24.051 32.1406 24.0616" stroke="#333333" stroke-linejoin="round"/>
<path d="M18 46C18 44.6193 19.1193 43.5 20.5 43.5H55.5C56.8807 43.5 58 44.6193 58 46C58 47.3807 56.8807 48.5 55.5 48.5H20.5C19.1194 48.5 18.0001 47.3807 18 46Z" fill="#D9F4FF" stroke="#333333"/>
<path d="M24.5 46H51.5" stroke="#333333" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M18 64C18 62.6193 19.1193 61.5 20.5 61.5H55.5C56.8807 61.5 58 62.6193 58 64C58 65.3807 56.8807 66.5 55.5 66.5H20.5C19.1194 66.5 18.0001 65.3807 18 64Z" fill="url(#paint0_linear_1869_4620)" stroke="#333333"/>
<path d="M24.5 64L51.5 64" stroke="white" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M18 55C18 53.6193 19.1193 52.5 20.5 52.5H55.5C56.8807 52.5 58 53.6193 58 55C58 56.3807 56.8807 57.5 55.5 57.5H20.5C19.1194 57.5 18.0001 56.3807 18 55Z" fill="#D9F4FF" stroke="#333333"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M26 55.5C26.2762 55.5 26.5 55.2741 26.5 55C26.5 54.7238 26.2741 54.5 26 54.5C25.7239 54.5 25.5 54.7238 25.5 55C25.4979 55.2741 25.7239 55.5 26 55.5Z" fill="#333333"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M29 55.5C29.2762 55.5 29.5 55.2741 29.5 55C29.5 54.7238 29.2762 54.5 29 54.5C28.7239 54.5 28.5 54.7238 28.5 55C28.4979 55.2741 28.7239 55.5 29 55.5Z" fill="#333333"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M32 55.5C32.2762 55.5 32.5 55.2741 32.5 55C32.5 54.7238 32.2741 54.5 32 54.5C31.7239 54.5 31.5 54.7238 31.5 55C31.4979 55.2741 31.7239 55.5 32 55.5Z" fill="#333333"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M35 55.5C35.2762 55.5 35.5 55.2741 35.5 55C35.5 54.7238 35.2741 54.5 35 54.5C34.7239 54.5 34.5 54.7238 34.5 55C34.4979 55.2741 34.7239 55.5 35 55.5Z" fill="#333333"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M44 55.5C44.2762 55.5 44.5 55.2741 44.5 55C44.5 54.7238 44.2741 54.5 44 54.5C43.7239 54.5 43.5 54.7238 43.5 55C43.4979 55.2741 43.7239 55.5 44 55.5Z" fill="#333333"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M38 55.5C38.2762 55.5 38.5 55.2741 38.5 55C38.5 54.7238 38.2741 54.5 38 54.5C37.7239 54.5 37.5 54.7238 37.5 55C37.4979 55.2741 37.7239 55.5 38 55.5Z" fill="#333333"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M47 55.5C47.2762 55.5 47.5 55.2741 47.5 55C47.5 54.7238 47.2741 54.5 47 54.5C46.7239 54.5 46.5 54.7238 46.5 55C46.4979 55.2741 46.7239 55.5 47 55.5Z" fill="#333333"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M41 55.5C41.2762 55.5 41.5 55.2741 41.5 55C41.5 54.7238 41.2741 54.5 41 54.5C40.7239 54.5 40.5 54.7238 40.5 55C40.4979 55.2741 40.7239 55.5 41 55.5Z" fill="#333333"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M50 55.5C50.2762 55.5 50.5 55.2741 50.5 55C50.5 54.7238 50.2741 54.5 50 54.5C49.7239 54.5 49.5 54.7238 49.5 55C49.4979 55.2741 49.7239 55.5 50 55.5Z" fill="#333333"/>
<path d="M51.75 4.5C51.75 5.05229 51.3023 5.5 50.75 5.5C50.1977 5.5 49.75 5.05228 49.75 4.5C49.75 3.94772 50.1977 3.5 50.75 3.5C51.3023 3.5 51.75 3.94771 51.75 4.5Z" stroke="#333333"/>
<path d="M56.25 4.5C56.25 5.05229 55.8023 5.5 55.25 5.5C54.6977 5.5 54.25 5.05228 54.25 4.5C54.25 3.94772 54.6977 3.5 55.25 3.5C55.8023 3.5 56.25 3.94771 56.25 4.5Z" stroke="#333333"/>
<path d="M60.75 4.5C60.75 5.0511 60.3011 5.5 59.75 5.5C59.2 5.5 58.75 5.0472 58.75 4.5C58.75 3.9489 59.1989 3.5 59.75 3.5C60.3011 3.5 60.75 3.9489 60.75 4.5Z" stroke="#333333"/>
<path d="M66.5 8H9.5V9H66.5V8Z" fill="#333333"/>
<defs>
<linearGradient id="paint0_linear_1869_4620" x1="17.5001" y1="60.7656" x2="19.1585" y2="72.5409" gradientUnits="userSpaceOnUse">
<stop stop-color="#FF8E3D"/>
<stop offset="1" stop-color="#FF6F3D"/>
</linearGradient>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 6.7 KiB