ui: fix cobrowse buttons
This commit is contained in:
parent
ec8f9a349d
commit
94e8e0319d
4 changed files with 17 additions and 17 deletions
|
|
@ -29,14 +29,9 @@ function AssistSearchActions() {
|
|||
const isSaas = /app\.openreplay\.com/.test(originStr);
|
||||
return (
|
||||
<div className="flex items-center w-full gap-2">
|
||||
{!isSaas && isEnterprise && !modules.includes(MODULES.OFFLINE_RECORDINGS)
|
||||
? <Button type="text" onClick={showRecords}>Training Videos</Button> : null
|
||||
}
|
||||
{isEnterprise && userStore.account?.admin && (
|
||||
<Button type="text" onClick={showStats}
|
||||
disabled={modules.includes(MODULES.ASSIST_STATS) || modules.includes(MODULES.ASSIST)}>
|
||||
Co-Browsing Reports</Button>
|
||||
)}
|
||||
<h3 className="text-2xl capitalize mr-2">
|
||||
<span>Co-Browse</span>
|
||||
</h3>
|
||||
<Tooltip title='Clear Search Filters'>
|
||||
<Button
|
||||
type="text"
|
||||
|
|
@ -47,6 +42,14 @@ function AssistSearchActions() {
|
|||
Clear
|
||||
</Button>
|
||||
</Tooltip>
|
||||
{!isSaas && isEnterprise && !modules.includes(MODULES.OFFLINE_RECORDINGS)
|
||||
? <Button size={'small'} onClick={showRecords}>Training Videos</Button> : null
|
||||
}
|
||||
{isEnterprise && userStore.account?.admin && (
|
||||
<Button size={'small'} onClick={showStats}
|
||||
disabled={modules.includes(MODULES.ASSIST_STATS) || modules.includes(MODULES.ASSIST)}>
|
||||
Co-Browsing Reports</Button>
|
||||
)}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -92,13 +92,7 @@ function LiveSessionList() {
|
|||
<div>
|
||||
<div className="bg-white py-3 rounded-lg border shadow-sm">
|
||||
<div className="flex mb-4 pb-2 px-3 justify-between items-center border-b border-b-gray-lighter">
|
||||
<div className="flex items-center">
|
||||
<h3 className="text-2xl capitalize mr-2">
|
||||
<span>Co-Browse</span>
|
||||
</h3>
|
||||
|
||||
<LiveSessionReloadButton onClick={refetch} />
|
||||
</div>
|
||||
<LiveSessionReloadButton onClick={refetch} />
|
||||
<div className="flex items-center">
|
||||
<div className="flex items-center ml-6">
|
||||
<span className="mr-2 color-gray-medium">Sort By</span>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ function LiveSessionReloadButton(props: Props) {
|
|||
const { onClick } = props;
|
||||
const loading = sessionStore.loadingLiveSessions;
|
||||
return (
|
||||
<ReloadButton buttonSize={'small'} iconSize={14} loading={loading} onClick={onClick} className="cursor-pointer" />
|
||||
<ReloadButton label={'Refresh'} buttonSize={'small'} iconSize={14} loading={loading} onClick={onClick} className="cursor-pointer" />
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ interface Props {
|
|||
onClick: () => void;
|
||||
iconSize?: number;
|
||||
buttonSize: 'small' | 'middle' | 'large' | undefined;
|
||||
label?: string
|
||||
}
|
||||
export default function ReloadButton(props: Props) {
|
||||
const { loading, onClick, iconSize = 18, buttonSize } = props;
|
||||
|
|
@ -17,7 +18,9 @@ export default function ReloadButton(props: Props) {
|
|||
size={buttonSize}
|
||||
onClick={onClick}
|
||||
icon={<SyncOutlined style={{ fontSize: iconSize }} />}
|
||||
/>
|
||||
>
|
||||
{props.label}
|
||||
</Button>
|
||||
</Tooltip>
|
||||
);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue