[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:
Jakob Ackermann
2025-10-23 16:33:22 +02:00
committed by Copybot
parent d0d360c1bd
commit f3f6a8a8e0
23 changed files with 576 additions and 19 deletions
@@ -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,