mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-06-09 00:59:02 +02:00
[web] add clsi-cache prompts (#29281)
* [web] add clsi-cache prompts * [web] add new editor variant to segmentation * [web] add tests for useNewEditorVariant * [web] adjust start of using clsi-cache in split-test GitOrigin-RevId: c9c5b1eff2ceefb65ef82516d9074cb971cb4c48
This commit is contained in:
@@ -386,6 +386,7 @@ const _ProjectController = {
|
||||
'external-socket-heartbeat',
|
||||
'null-test-share-modal',
|
||||
'populate-clsi-cache',
|
||||
'populate-clsi-cache-for-prompt',
|
||||
'pdf-caching-cached-url-lookup',
|
||||
'pdf-caching-mode',
|
||||
'pdf-caching-prefetch-large',
|
||||
@@ -818,14 +819,26 @@ const _ProjectController = {
|
||||
|
||||
const planDetails = Settings.plans.find(p => p.planCode === planCode)
|
||||
|
||||
const projectOwnerHasPremiumOnPageLoad =
|
||||
ownerFeatures?.compileGroup === 'priority'
|
||||
if (
|
||||
projectOwnerHasPremiumOnPageLoad &&
|
||||
splitTestAssignments['populate-clsi-cache']?.variant !== 'enabled'
|
||||
) {
|
||||
await SplitTestHandler.promises.getAssignment(
|
||||
req,
|
||||
res,
|
||||
'clsi-cache-prompt'
|
||||
)
|
||||
}
|
||||
|
||||
res.render(template, {
|
||||
title: project.name,
|
||||
priority_title: true,
|
||||
bodyClasses: ['editor'],
|
||||
project_id: project._id,
|
||||
projectName: project.name,
|
||||
projectOwnerHasPremiumOnPageLoad:
|
||||
ownerFeatures?.compileGroup === 'priority',
|
||||
projectOwnerHasPremiumOnPageLoad,
|
||||
user: {
|
||||
id: userId,
|
||||
email: user.email,
|
||||
|
||||
Reference in New Issue
Block a user