openreplay/frontend/app/components/shared/SessionsTabOverview/components/NoContentMessage.tsx
Andrey Babushkin fd5c0c9747
Add lokalisation (#3092)
* applied eslint

* add locales and lint the project

* removed error boundary

* updated locales

* fix min files

* fix locales
2025-03-06 17:43:15 +01:00

21 lines
514 B
TypeScript

import React from 'react';
import { useStore } from 'App/mstore';
import { observer } from 'mobx-react-lite';
function NoContentMessage() {
const { searchStore } = useStore();
const { activeTab } = searchStore;
return <div>{getNoContentMessage(activeTab)}</div>;
}
export default observer(NoContentMessage);
function getNoContentMessage(activeTab: any) {
let str = 'No recordings found';
if (activeTab.type !== 'all') {
str += ` with ${activeTab.name}`;
return str;
}
return `${str}!`;
}