mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
Merge pull request #4257 from overleaf/ae-file-views-beta
Roll out new file view UI to beta users GitOrigin-RevId: c8665c5043ad55dd530989fb3b9c51f21858fcac
This commit is contained in:
parent
3fb6ea4ea5
commit
2be1a44eda
3 changed files with 12 additions and 1 deletions
|
@ -887,7 +887,7 @@ const ProjectController = {
|
||||||
),
|
),
|
||||||
showNewFileViewUI: shouldDisplayFeature(
|
showNewFileViewUI: shouldDisplayFeature(
|
||||||
'new_file_view',
|
'new_file_view',
|
||||||
user.alphaProgram
|
user.alphaProgram || user.betaProgram
|
||||||
),
|
),
|
||||||
showSymbolPalette: shouldDisplayFeature(
|
showSymbolPalette: shouldDisplayFeature(
|
||||||
'symbol_palette',
|
'symbol_palette',
|
||||||
|
|
|
@ -9,6 +9,7 @@ import { useProjectContext } from '../../../shared/context/project-context'
|
||||||
|
|
||||||
import importOverleafModules from '../../../../macros/import-overleaf-module.macro'
|
import importOverleafModules from '../../../../macros/import-overleaf-module.macro'
|
||||||
import useAbortController from '../../../shared/hooks/use-abort-controller'
|
import useAbortController from '../../../shared/hooks/use-abort-controller'
|
||||||
|
import BetaBadge from '../../../shared/components/beta-badge'
|
||||||
const tprLinkedFileInfo = importOverleafModules('tprLinkedFileInfo')
|
const tprLinkedFileInfo = importOverleafModules('tprLinkedFileInfo')
|
||||||
const tprLinkedFileRefreshError = importOverleafModules(
|
const tprLinkedFileRefreshError = importOverleafModules(
|
||||||
'tprLinkedFileRefreshError'
|
'tprLinkedFileRefreshError'
|
||||||
|
@ -105,6 +106,12 @@ export default function FileViewHeader({ file, storeReferencesKeys }) {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
|
<BetaBadge
|
||||||
|
tooltip={{
|
||||||
|
id: 'file-view-beta-tooltip',
|
||||||
|
text: t('beta_badge_tooltip', { feature: 'file views' }),
|
||||||
|
}}
|
||||||
|
/>
|
||||||
{file.linkedFileData && fileInfo}
|
{file.linkedFileData && fileInfo}
|
||||||
{file.linkedFileData &&
|
{file.linkedFileData &&
|
||||||
tprLinkedFileInfo.map(({ import: { LinkedFileInfo }, path }) => (
|
tprLinkedFileInfo.map(({ import: { LinkedFileInfo }, path }) => (
|
||||||
|
|
|
@ -44,4 +44,8 @@
|
||||||
.linked-file-icon {
|
.linked-file-icon {
|
||||||
color: @blue;
|
color: @blue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.beta-badge {
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue