{
  "version": 3,
  "sources": ["../../../config/src/employeesOnlySettings.ts", "../../../config/src/experiments.ts", "../../../config/src/features.ts", "../../src/app/FeatureSet.tsx", "../../src/app/GradualRollout.ts", "../../src/app/siteIdsWithExperimentsForceEnabled.ts", "../../src/app/experiments.ts"],
  "sourcesContent": ["export const defaultEmployeesOnlySettings = {\n\tdisableAIAgentMessageRedaction: \"off\",\n\tdisableLazyModuleLoading: \"off\",\n\tdisablePartialDocumentLoading: \"off\",\n\tdisablePartialTreeInSandbox: \"off\",\n\teditableLegacyProjects: \"off\",\n\tmoduleTools: \"off\",\n\topenPrimaryForBuiltInModules: \"on\",\n\tsandboxExportDebugging: \"off\",\n\tsandboxNodeDebugging: \"off\",\n\tshowAdditionalAutosaves: \"off\",\n\tshowDOMLayoutDebuggingPanel: \"off\",\n\tshowErrorForOutdatedBuiltInModules: \"on\",\n\tshowImportMap: \"off\",\n\tshowShaderTools: \"off\",\n\tshowDebugBar: \"off\",\n\tshowStatusBar: \"on\",\n\tsuppressDocumentLoading: \"off\",\n\tsuppressUIMount: \"off\",\n\tuserIsViewer: \"off\",\n}\n\nexport type EmployeesOnlySettingsName = keyof typeof defaultEmployeesOnlySettings\n", "type OnOrOff = \"on\" | \"off\"\n\n/** Type-safe variant experiment creator */\nfunction withVariants<T extends readonly string[]>(variants: [...T], value: T[number] | OnOrOff) {\n\tconst unique = new Set(variants)\n\tunique.add(\"on\")\n\tunique.add(\"off\")\n\treturn { variants: [...unique], value }\n}\n\ntype ActiveVariant<T> = T extends OnOrOff ? OnOrOff : T extends { value: infer R extends string } ? R : never\n\ntype Overrides<T extends Record<string, unknown>> = {\n\t[K in keyof T]: ActiveVariant<T[K]>\n}\n\nconst experimentVariants: Record<string, string[]> = {}\n\nexport function getExperimentVariants(name: string): string[] | undefined {\n\treturn experimentVariants[name]\n}\n\n/**\n * Configures experiments\n *\n * If an experiment is a variant, it extracts variants into\n * a separate object and normalizes it to a string.\n */\nfunction configure<T extends Record<string, OnOrOff | { variants: string[]; value: string }>>(config: T) {\n\tconst newConfig: Record<string, string> = {}\n\n\tfor (const key in config) {\n\t\tconst experimentValue = config[key]\n\t\tif (typeof experimentValue === \"object\") {\n\t\t\tnewConfig[key] = experimentValue.value\n\t\t\texperimentVariants[key] = experimentValue.variants\n\t\t} else if (typeof experimentValue === \"string\") {\n\t\t\tnewConfig[key] = experimentValue\n\t\t} else {\n\t\t\tthrow Error(`Invalid experiment value: ${experimentValue}`)\n\t\t}\n\t}\n\n\treturn newConfig as Overrides<T>\n}\n\n/**\n * Stable experiments are the features enabled for most customers.\n *\n * The list must be alphabetically sorted.\n *\n * When toggling a stable experiment, for features that result in differences to generated code, or\n * differences to the publish html, consider bumping the { @see protocol-version.mjs } to ensure\n * that customers collaborating on a project have a consistent experience.\n *\n * Variant definition should **only** be defined in this object using\n * the `variant` method.\n */\nexport const stableExperiments = configure({\n\tadvancedAgentControls: \"off\",\n\tadvancedHostingUpsells: \"on\",\n\tagent: \"off\",\n\tagentNodeByIdBudgetedReads: \"off\",\n\tagentUseOpenAIResponsesAPI: \"off\",\n\tanalyticsFunnelGroupBy: \"off\",\n\tapiKeys: \"on\",\n\tarrays: \"off\",\n\tassertCenterAnchorPresent: \"off\",\n\tautobahnNavigation: \"on\",\n\tbetterStackGridItemMoving: \"on\",\n\tbillingV3: \"on\",\n\tbillingV3Migration: \"on\",\n\tbranching: withVariants([\"autoBranching\"], \"off\"),\n\tcanUseStaticFileHosting: \"on\",\n\tcmsDatabase: \"off\",\n\tcmsMultiSort: \"off\",\n\tcmsPasteModules: \"off\",\n\tcmsPrivateDraftItems: \"off\",\n\tcmsRichTextCollectionTable: \"off\",\n\tcodeLinkPlugin: \"off\",\n\tcollectionLocalModuleImportMapEntries: \"off\",\n\tcompareFastTreeLibrary: \"off\",\n\tcomponentSlotsAreChildNodes: \"off\",\n\tcontentEditor: \"on\",\n\tconvertToOutline: \"off\",\n\tcoupons: \"on\",\n\tcustomFontGrouping: \"on\",\n\tdataOnlyTree: \"on\" /* Only has effect in crdt projects. */,\n\tdebugEditWhileLoadingRuntimeChecks: \"off\",\n\tdebugEditWhileNeverLoadingRest: \"off\",\n\tdisableLoadingIndicatorTimeout: \"off\",\n\teditorBarDisableFrameAncestorsSecurity: \"off\" /* always employees only */,\n\teffectsInDesignPages: \"off\",\n\tenableCrdtForNewProjects: \"off\",\n\tfixedSizeImageSrcset: \"off\",\n\tflowEffect: \"on\",\n\tflowEffectInLayoutTemplates: \"on\",\n\tfontPreview: \"on\",\n\tfontPreviewStylePresets: \"on\",\n\tformAntispam: \"off\",\n\tformRecaptchaV3: \"off\",\n\tfreeDomains: \"on\",\n\tgreyFrameDefault: \"off\",\n\tgridBentoFill: \"on\",\n\tgridBentoFit: \"off\",\n\tgridCollapseMacros: \"on\",\n\thydrationAutobahn: \"on\",\n\timportMapPruning: \"off\",\n\t/**\n\t * Temporary performance experiment to improve INP during hydration + to fix a \"infinite hydration loop\" bug.\n\t * Will be unlaunched eventually.\n\t */\n\timproveInpDuringHydration: \"on\",\n\tinlineColorArrayControl: \"on\",\n\tjsonRichTextStorage: \"off\",\n\tlayoutMenuStack: \"on\",\n\tlayoutScroll: \"off\",\n\tlazyProviderMaps: \"on\",\n\tlocalCache: \"on\",\n\tlocalizationAiUpdate: \"on\",\n\tlocalizedLinks: \"off\",\n\tlocationControl: \"off\",\n\tmasonryLayout: \"on\",\n\tmentionsInComments: \"on\",\n\tmodulesInTree: \"off\",\n\tmotionDivToDiv: \"off\",\n\tnodeLevelRepeat: \"off\",\n\tonDemandSSG: \"on\",\n\tonPageEnumVariableOnComponentInstanceEditTool: \"on\",\n\tonPageLocalizationSupport: \"on\",\n\tonPageLockedLayers: \"on\",\n\tonPageMoveTool: \"on\",\n\tonPageQuickAddRepeaterItems: \"on\",\n\toverridesWithPropertyControls: \"off\",\n\tpageLinkReferenceCheck: \"on\",\n\tpaneEdgeDoubleClickReset: \"off\",\n\tpasskeys: \"off\",\n\tpatching: withVariants([\"collections\"], \"off\"),\n\tpreventVariableDeletion: \"on\",\n\tpreviewSharing: \"off\",\n\tprioritizedModuleEvaluation: \"on\",\n\tprotectedStaging: \"on\",\n\tprototypeTreeDriver: withVariants([\"dynamicOverrides\"], \"dynamicOverrides\"),\n\tpublishBandwidthBlock: \"on\",\n\tpublishingRecoveryProgress: \"off\",\n\tpublishStaleModuleErrors: \"off\",\n\traindropSelfDiagnostics: \"on\",\n\tredirectLondonTimezone: \"on\",\n\tremoveProjectFontUploads: \"on\",\n\trenameLayers: \"on\",\n\t/**\n\t * Temporarily kept to debug differences between esbuild and Rolldown.\n\t * We'll remove the flag once:\n\t * - Rolldown's memory usage is on-par with esbuild\n\t * - We're confident we don't have Rolldown related crashes anymore\n\t */\n\trolldown: \"on\",\n\tserverTimingRoute: \"on\",\n\tshaders: \"on\",\n\tshowCanonicalUrlAsDefault: \"off\",\n\tsnapshotTrackingIdNodes: \"off\",\n\tsquircle: \"on\",\n\t/** Temporary performance experiment to measure the INP impact of synchronous navigation on desktop. */\n\tsynchronousNavigationOnDesktop: \"off\",\n\ttemplatesModal: \"on\",\n\n\ttranslationModelGemini3Flash: \"off\",\n\tuseFastTreeLibraryFastCloneCompare: \"off\",\n\tvantara: \"off\",\n\tvisibilityFromSandbox: \"off\",\n\twireframerKits: \"off\",\n\t/** Temporary performance experiment to measure the impact of yielding on tap to improve INP. */\n\tyieldOnTap: \"off\",\n})\n\nexport type Experiments = typeof stableExperiments\nexport type ExperimentName = keyof Experiments\n\nconst experimentsNeedingFullReload: readonly ExperimentName[] = [\n\t\"agent\",\n\t\"branching\",\n\t\"modulesInTree\",\n\t\"jsonRichTextStorage\",\n]\n\nexport function experimentNeedsFullReload(name: ExperimentName): boolean {\n\treturn experimentsNeedingFullReload.includes(name)\n}\n\nexport const enum ExperimentScope {\n\tTeam = \"Team\",\n\tProject = \"Project\",\n\tUser = \"User\",\n}\n\nexport interface GradualRolloutDefinition<T extends string> {\n\t/**\n\t * share of users getting \"on\" treatment: number [0..1]\n\t */\n\tsample: number\n\n\t/**\n\t * whether the treatment is defined per user, per team or per project\n\t */\n\tscope: ExperimentScope\n\n\t/**\n\t * experiment names that should be enabled alongside if the treatment was evaluated to \"on\"\n\t */\n\tdependencies?: ExperimentName[]\n\n\t/**\n\t * whether or not include enterprise teams/users/projects\n\t */\n\tincludeEnterprise: boolean\n\n\t/**\n\t * channels that the gradual rollout is constrained to, defaults to no constraints\n\t */\n\tchannels?: string[]\n\n\t/**\n\t * for most experiments, it will be \"on\"\n\t */\n\tvariant: T\n}\n\n// Experiment settings for projects on the \u201Cbeta\u201D release channel (opt-in for selected teams)\n// The \u201Cbeta\u201D release channel is deployed automatically from the \"master\" branch and\n// doesn't require a manual release deployment.\nexport const betaExperiments = {\n\tassertCenterAnchorPresent: \"on\",\n\tcmsMultiSort: \"on\",\n\tcmsPrivateDraftItems: \"on\",\n\tcmsRichTextCollectionTable: \"on\",\n\tcodeLinkPlugin: \"on\",\n\tconvertToOutline: \"on\",\n\t/** @ShallowLoading: Enables extra runtime checks to ensure that we don't break the projects due to operations that assume the full tree is loaded */\n\tdebugEditWhileLoadingRuntimeChecks: \"on\",\n\tenableCrdtForNewProjects: \"on\",\n\tformAntispam: \"on\",\n\tlayoutScroll: \"on\",\n\ttranslationModelGemini3Flash: \"on\",\n\tvantara: \"on\",\n} as const satisfies Partial<Experiments>\n\n// Experiment settings for projects on the \u201Calpha\u201D release channel (only employees)\n// will also include all \"beta\" experiments.\nexport const alphaExperiments = {\n\tcmsPasteModules: \"on\",\n\tdisableLoadingIndicatorTimeout: \"on\",\n\teffectsInDesignPages: \"on\",\n\tlocalizedLinks: \"on\",\n\tmodulesInTree: \"on\",\n\tmotionDivToDiv: \"on\",\n\tpaneEdgeDoubleClickReset: \"on\",\n\tpasskeys: \"on\",\n\tsnapshotTrackingIdNodes: \"on\",\n\tsynchronousNavigationOnDesktop: \"on\",\n\tvisibilityFromSandbox: \"on\",\n\tyieldOnTap: \"on\",\n} as const satisfies Partial<Experiments>\n\ntype GradualRolloutObject<T> = {\n\t[K in keyof T]?: T[K] extends string ? GradualRolloutDefinition<T[K]> | GradualRolloutDefinition<T[K]>[] : never\n}\n\n/**\n * Gradual rollout experiments are experiments that are rolled out to a subset of users.\n *\n * @important When using `channels`, make sure the experiment isn't enabled in the same channel as a regular\n * experiment (e.g. when using `channels: [\"beta\"]`, don't enable the experiment in `betaExperiments`).\n *\n * Most rollouts use the following schedule:\n * - 1% non-enterprise users for a day or two (kinda canary testing)\n * - 10% for another day or two\n * - Either 50% or directly to 100%\n * This is not a fixed schedule, and can be adjusted as needed.\n */\nexport const gradualRolloutExperiments: GradualRolloutObject<Experiments> = {\n\tvantara: [\n\t\t{\n\t\t\tsample: 0.5,\n\t\t\tscope: ExperimentScope.User,\n\t\t\tincludeEnterprise: false,\n\t\t\tvariant: \"on\",\n\t\t},\n\t],\n}\n", "export type FeatureValue = \"on\" | \"off\" | \"upsell\"\n\n// Properties for project.settings.featureFlags\n// See API response: https://github.com/framer/FramerWebApi/blob/7e53be61370ccd2424186906e613a951f791152d/src/lib/projects/getProjectsSettings.ts#L12\n\nexport interface ProjectSettingsFeatureFlags {\n\tcanPublishToCustomDomain: FeatureValue\n\tcanUsePasswordProtection: FeatureValue\n\tcanUseAnalytics: FeatureValue\n\tcanUseStagingEnvironment: FeatureValue\n\tcanUseVersioning: FeatureValue\n\tshowBannerOnPublishedSite: FeatureValue\n\tcanUseRedirects: FeatureValue\n\tcanUseCustomCanonicalUrl: FeatureValue\n\tcanUseRewriteCanonicalUrl: FeatureValue\n\tcanUseWellKnown: FeatureValue\n\tcanUseEditorPermissions: FeatureValue\n\tcanInviteEditors: FeatureValue\n\tcanUsePrivateLink: FeatureValue\n\tcanUsePrototypePassword: FeatureValue\n\tcanPublishTeamPackages: FeatureValue\n\tcanChangeProjectAccess: FeatureValue\n\tcanChangePrototypeAccess: FeatureValue\n\tcanInviteAnyDomain: FeatureValue\n\tcanInviteAnyDomainToPrototype: FeatureValue\n\tcanExportToHtml: FeatureValue\n\tcanHidePreviewInterface: FeatureValue\n\tshowSitesUpsell: FeatureValue\n\tcanUseBatchAITranslation: FeatureValue\n\tcanUseCustomLocaleRegions: FeatureValue\n\tcanUseLocalizationVariables: FeatureValue\n\tcanUseLocalizationCustomAiInstructions: FeatureValue\n\tcanUseBetaChannel: FeatureValue\n\tcanUseUTMTracking: FeatureValue\n\tcanUseTeamPlugins: FeatureValue\n\tcanUseWorkspacePlugins: FeatureValue\n\tblockEditorBar: FeatureValue\n\t/** @deprecated check canUseFunnels, abTests and trackingEventsLimit instead */\n\tcanUseAdvancedAnalytics: FeatureValue\n\tcanUseFunnels: FeatureValue\n\tcanUseTriggers: FeatureValue\n\tcanUseSpamProtectionAdvanced: FeatureValue\n\tcanUseAdvancedHosting: FeatureValue\n\tcanUseExternalRewrites: FeatureValue\n\tcanUseInternalRewrites: FeatureValue\n\tcanUseCustomHeaders: FeatureValue\n\tcanUseAdvancedHeaders: FeatureValue\n}\n\nexport const defaultProjectFeatureFlags = {\n\tcanPublishToCustomDomain: \"upsell\",\n\tcanUsePasswordProtection: \"upsell\",\n\tcanUseAnalytics: \"upsell\",\n\tcanUseStagingEnvironment: \"upsell\",\n\tcanUseVersioning: \"upsell\",\n\tshowBannerOnPublishedSite: \"on\",\n\tcanUseRedirects: \"upsell\",\n\tcanUseCustomCanonicalUrl: \"upsell\",\n\tcanUseRewriteCanonicalUrl: \"off\",\n\tcanUseWellKnown: \"upsell\",\n\tcanUseEditorPermissions: \"off\",\n\tcanInviteEditors: \"on\",\n\tcanUsePrivateLink: \"upsell\",\n\tcanUsePrototypePassword: \"upsell\",\n\tcanPublishTeamPackages: \"upsell\",\n\tcanChangeProjectAccess: \"off\",\n\tcanChangePrototypeAccess: \"off\",\n\tcanInviteAnyDomain: \"off\",\n\tcanInviteAnyDomainToPrototype: \"off\",\n\tcanExportToHtml: \"off\",\n\tcanHidePreviewInterface: \"off\",\n\tshowSitesUpsell: \"off\",\n\tcanUseBatchAITranslation: \"upsell\",\n\tcanUseCustomLocaleRegions: \"upsell\",\n\tcanUseLocalizationVariables: \"upsell\",\n\tcanUseLocalizationCustomAiInstructions: \"upsell\",\n\tcanUseBetaChannel: \"off\",\n\tcanUseUTMTracking: \"off\",\n\tcanUseTeamPlugins: \"off\",\n\tcanUseWorkspacePlugins: \"off\",\n\tblockEditorBar: \"off\",\n\tcanUseAdvancedAnalytics: \"off\",\n\tcanUseFunnels: \"off\",\n\tcanUseSpamProtectionAdvanced: \"off\",\n\tcanUseAdvancedHosting: \"off\",\n\tcanUseTriggers: \"off\",\n\tcanUseExternalRewrites: \"off\",\n\tcanUseInternalRewrites: \"off\",\n\tcanUseCustomHeaders: \"off\",\n\tcanUseAdvancedHeaders: \"off\",\n} satisfies ProjectSettingsFeatureFlags\n\n// Properties in currentSpace.license.featureFlag (Team license)\n// See API response: https://github.com/framer/FramerTeamsService/blob/d22e943acd3b93c01467bba3f241abcdb2f78e9d/models/license.go#L102\n\nexport interface TeamLicenseFeatureFlags {\n\tcanInviteEditors: FeatureValue\n\tisAutoRenew: FeatureValue\n\tcanRestrictEmailDomain: FeatureValue\n\tcanChangeDefaultProjectAccess: FeatureValue\n\tcanChangeAutoJoinTeam: FeatureValue\n\tcanChangeAutoJoinDefaultRole: FeatureValue\n\tcanUseCustomTemplates: FeatureValue\n\tcanChangeMoveProjectPermissions: FeatureValue\n\tcanUseWorkspacePlugins: FeatureValue\n\tcanUseRevampedDashboard: FeatureValue\n}\n\n// Properties in project license featureFlags\n// See https://github.com/framer/FramerProjectsService/blob/ff60fc1c606bca6dc8d0f37c8dbca9e5951c57c5/src/lib/types/license.ts#L38\nexport interface ProjectLicenseFeatureFlags {\n\tcanPublishToCustomDomain: FeatureValue\n\tshowBannerOnPublishedSite: FeatureValue\n\tcanUsePasswordProtection: FeatureValue\n\tcanUseAnalytics: FeatureValue\n\tcanUseStagingEnvironment: FeatureValue\n\tcanUseVersioning: FeatureValue\n\tcanUseRedirects: FeatureValue\n\tcanUseCustomCanonicalUrl: FeatureValue\n\tcanUseBatchAITranslation: FeatureValue\n\tcanUseCustomLocaleRegions: FeatureValue\n\tcanUseLocalizationVariables: FeatureValue\n\tcanUseLocalizationCustomAiInstructions: FeatureValue\n\tcanUseBetaChannel: FeatureValue\n\tcanUseWellKnown: FeatureValue\n\tcanUseEditorPermissions: FeatureValue\n\tcanUseCustomProxy: FeatureValue\n\tcanUseSSO: FeatureValue\n\tcanUseUTMTracking: FeatureValue\n\t/** @deprecated check canUseFunnels, abTests and trackingEventsLimit instead */\n\tcanUseAdvancedAnalytics: FeatureValue\n\tcanUseFunnels: FeatureValue\n\tcanUseTriggers: FeatureValue\n\tcanUseExternalRewrites: FeatureValue\n\tcanUseInternalRewrites: FeatureValue\n\tcanUseCustomHeaders: FeatureValue\n\tcanUseAdvancedHeaders: FeatureValue\n}\n", "import { assert } from \"@framerjs/shared\"\nimport type { FunctionComponent } from \"react\"\nimport React, { useLayoutEffect, useReducer, useRef } from \"react\"\nimport { isString, isUndefined } from \"utils/typeChecks.ts\"\n\n// True when fetching the state of a feature from within the useCondition hook (making it safe).\nlet isInSafeContext = false\n\nexport type Config<Name extends string> = { [name in Name]: string }\ntype ConfigWithBools<Name extends string> = { [name in Name]: string | boolean }\ntype Listener = (variant: string, featureName: string) => void\ntype FeatureOverrideReset = (() => void) & { [Symbol.dispose]: () => void }\n\ninterface Options {\n\tassertIfUsedBeforeUpdate?: boolean\n}\n\nexport class FeatureSet<Name extends string> {\n\tprivate readonly activeConfig: Config<Name>\n\tprivate readonly activeOverrides: Partial<Config<Name>>[] = []\n\tprivate readonly initialConfig: Config<Name>\n\tprivate readonly listeners = new Map<Name, Set<Listener>>()\n\tprivate assertOnUse: boolean\n\n\t/** A promise that resolves the first time the `FeatureSet` is updated. */\n\treadonly updated: Promise<void>\n\t#resolveUpdated: (() => void) | undefined\n\n\tconstructor(config: ConfigWithBools<Name>, { assertIfUsedBeforeUpdate = false }: Options = {}) {\n\t\tthis.initialConfig = convertBools(config)\n\t\tthis.activeConfig = { ...this.initialConfig }\n\t\tthis.assertOnUse = process.env.NODE_ENV !== \"production\" && assertIfUsedBeforeUpdate\n\t\tthis.updated = new Promise(resolve => {\n\t\t\tthis.#resolveUpdated = resolve\n\t\t})\n\t}\n\n\taddListener(name: Name, listener: Listener) {\n\t\tlet set = this.listeners.get(name)\n\t\tif (!set) {\n\t\t\tset = new Set()\n\t\t\tthis.listeners.set(name, set)\n\t\t}\n\t\tset.add(listener)\n\t}\n\n\tget(name: Name): string {\n\t\tif (this.assertOnUse) {\n\t\t\tassert(isInSafeContext, \"Tried to read state of\", name, \"before update, await on .updated first\")\n\t\t}\n\t\tfor (let i = this.activeOverrides.length - 1; i >= 0; i--) {\n\t\t\t// biome-ignore lint/style/noNonNullAssertion: fast c style loop\n\t\t\tconst variant = this.activeOverrides[i]![name]\n\t\t\tif (!isString(variant)) continue\n\t\t\treturn variant\n\t\t}\n\t\treturn this.activeConfig[name]\n\t}\n\n\tgetInitial(name: Name): string {\n\t\treturn this.initialConfig[name]\n\t}\n\n\tis(name: Name, variant: string): boolean {\n\t\tif (this.assertOnUse) {\n\t\t\tassert(isInSafeContext, \"Tried to read state of\", name, \"before update, await on .updated first\")\n\t\t}\n\t\t// TODO: Only do this check when in a testing environment.\n\t\tconst isActiveByOverrides = this.isActiveByOverrides(name, variant)\n\t\tif (!isUndefined(isActiveByOverrides)) return isActiveByOverrides\n\t\treturn this.activeConfig[name] === variant\n\t}\n\n\t/**\n\t * @important This only checks for \"on\" variant, and will return false for any other variants\n\t */\n\tisOn(name: Name): boolean {\n\t\tif (this.assertOnUse) {\n\t\t\tassert(isInSafeContext, \"Tried to read the state of\", name, \"before update, await on .updated first\")\n\t\t}\n\n\t\treturn this.is(name, \"on\")\n\t}\n\n\t/**\n\t * Resolves experiment name with the variant suffix appended mainly for debugging reasons\n\t */\n\tgetVariantName(name: Name): string | undefined {\n\t\tif (this.assertOnUse) {\n\t\t\tassert(isInSafeContext, \"Tried to read the state of\", name, \"before update, await on .updated first\")\n\t\t}\n\n\t\tconst variant = this.get(name)\n\t\treturn variant === \"on\" || variant === \"off\" ? name : `${name}_${variant}`\n\t}\n\n\t/** Read the value and be sure it was updated with the actual values. */\n\tasync didUpdateAndIsOn(name: Name): Promise<boolean> {\n\t\tawait this.updated\n\t\treturn this.isOn(name)\n\t}\n\n\t/**\n\t * Dynamically changes the active features by overriding them until the\n\t * returned `reset()` function is called.\n\t *\n\t * NOTE: Use the helper exported from \"test/features\" as this will manage\n\t * setup and teardown.\n\t *\n\t * For simpler overrides prefer `withOverridesForTest()` which will handle\n\t * the clean-up for you.\n\t *\n\t * @param overrides Feature/variant pairs to override.\n\t * @returns A reset handle that is both callable and disposable.\n\t * @example\n\t * using reset = experiments.overrideForTest({ feedback: \"on\" })\n\t * // override is reset automatically at end of scope\n\t */\n\toverrideForTest(overrides: Partial<Config<Name>>): FeatureOverrideReset {\n\t\tconst shouldAssertOnUse = this.assertOnUse\n\t\tthis.assertOnUse = false\n\t\tthis.activeOverrides.push(overrides)\n\t\tlet isReset = false\n\t\tconst reset = Object.assign(\n\t\t\t() => {\n\t\t\t\tif (isReset) return\n\t\t\t\t// Verify reset has been called in correct order.\n\t\t\t\tif (this.activeOverrides.pop() !== overrides) {\n\t\t\t\t\tthrow Error(\"Something went wrong with experiment overrides\")\n\t\t\t\t}\n\t\t\t\tisReset = true\n\t\t\t\tthis.assertOnUse = shouldAssertOnUse\n\t\t\t},\n\t\t\t{\n\t\t\t\t[Symbol.dispose]() {\n\t\t\t\t\treset()\n\t\t\t\t},\n\t\t\t},\n\t\t) satisfies FeatureOverrideReset\n\t\treturn reset\n\t}\n\n\tremoveListener(name: Name, listener: Listener) {\n\t\tthis.listeners.get(name)?.delete(listener)\n\t}\n\n\tupdate(changes: Partial<ConfigWithBools<Name>>) {\n\t\tthis.assertOnUse = false\n\t\tfor (const name in changes) {\n\t\t\tconst variant = convertBool(changes[name])\n\t\t\tif (!isString(variant)) continue\n\t\t\tif (variant === this.activeConfig[name]) continue\n\t\t\tthis.activeConfig[name] = variant\n\t\t\tconst set = this.listeners.get(name)\n\t\t\tif (!set) continue\n\t\t\tset.forEach(listener => listener(variant, name))\n\t\t}\n\t\tif (this.#resolveUpdated) {\n\t\t\tthis.#resolveUpdated()\n\t\t\tthis.#resolveUpdated = undefined\n\t\t}\n\t}\n\n\t/**\n\t * Dynamically changes the active features by overriding them within the\n\t * provided scope. This should only be used in tests, not in production code!\n\t * NOTE: Use the helper exported from \"test/features\"\n\t *\n\t * @param overrides Feature/variant pairs to override.\n\t * @param scope An immediately executed function within which the overrides are active.\n\t * @example\n\t * experiments.withOverridesForTest({ feedback: \"on\" }, () => {\n\t *    feedbackStore.initialize()\n\t * })\n\t */\n\twithOverridesForTest<T>(overrides: Partial<Config<Name>>, scope: () => T): T {\n\t\tconst reset = this.overrideForTest(overrides)\n\t\ttry {\n\t\t\tthis.signalForTests(overrides)\n\t\t\treturn scope()\n\t\t} finally {\n\t\t\treset()\n\t\t\tthis.signalForTests(overrides)\n\t\t}\n\t}\n\n\tprivate signalForTests(names: Partial<Config<Name>>) {\n\t\tfor (const name in names) {\n\t\t\tconst set = this.listeners.get(name)\n\t\t\tif (!set) continue\n\t\t\tconst variant = this.get(name)\n\t\t\tset.forEach(listener => listener(variant, name))\n\t\t}\n\t}\n\n\t/**\n\t * Checks all active overrides for the feature and if one is found, returns if the variant is active.\n\t */\n\tprivate isActiveByOverrides(name: Name, variant: string): boolean | undefined {\n\t\tfor (let i = this.activeOverrides.length - 1; i >= 0; i--) {\n\t\t\t// biome-ignore lint/style/noNonNullAssertion: fast c style loop\n\t\t\tconst overrides = this.activeOverrides[i]!\n\t\t\tif (!(name in overrides)) continue\n\t\t\treturn overrides[name] === variant\n\t\t}\n\t\treturn undefined\n\t}\n\n\t/** Serializes the active features into a JSON object, e.g., for sending to SSG. */\n\tserialize(): Config<Name> {\n\t\tconst result: Partial<Config<Name>> = {}\n\t\tfor (const name in this.activeConfig) {\n\t\t\tresult[name] = this.get(name)\n\t\t}\n\t\treturn result as Config<Name>\n\t}\n\n\t/** Get the diff from the initial config to the current active config or overrides. */\n\tdiffFromInitial(): Partial<Config<Name>> {\n\t\tconst result: Partial<Config<Name>> = {}\n\t\tfor (const name in this.initialConfig) {\n\t\t\tconst currentValue = this.get(name)\n\t\t\tif (this.initialConfig[name] !== currentValue) {\n\t\t\t\tresult[name] = currentValue\n\t\t\t}\n\t\t}\n\t\treturn result\n\t}\n}\n\nfunction convertBool(variant: string | boolean | undefined): string | undefined {\n\tif (typeof variant === \"boolean\") return variant ? \"on\" : \"off\"\n\treturn variant\n}\n\nfunction convertBools<Name extends string>(input: ConfigWithBools<Name>): Config<Name> {\n\tconst result: Partial<Config<Name>> = {}\n\tfor (const name in input) {\n\t\tresult[name] = convertBool(input[name])\n\t}\n\treturn result as Config<Name>\n}\n\ntype Props<Name extends string> =\n\t| {\n\t\t\t/** Renders contents if the variant of the feature with the provided name is `\"on\"`. */\n\t\t\tisOn: Name\n\t  }\n\t| {\n\t\t\t/** Renders contents if the variant of the feature with the provided name is *not* `\"on\"`. */\n\t\t\tisNotOn: Name\n\t  }\n\t| {\n\t\t\t/** Renders contents if the variant of the feature with the provided name is equal to `variant`. */\n\t\t\tisActive: Name\n\t\t\t/** The variant to test for. */\n\t\t\tvariant: string\n\t  }\n\t| {\n\t\t\t/** Renders contents if the variant of the feature with the provided name is *not* equal to `variant`. */\n\t\t\tisNotActive: Name\n\t\t\t/** The variant to test for. */\n\t\t\tvariant: string\n\t  }\n\t| {\n\t\t\tname: Name\n\t\t\tcondition: (variant: string) => boolean\n\t  }\n\n/**\n * Converts `Props` to `[feature, variant, expectedCondition]`.\n */\nfunction propsToParameters<Name extends string>(\n\tprops: Props<Name>,\n): [Name, string, boolean] | [Name, (variant?: string) => boolean] {\n\tif (\"isOn\" in props) {\n\t\treturn [props.isOn, \"on\", true]\n\t} else if (\"isNotOn\" in props) {\n\t\treturn [props.isNotOn, \"on\", false]\n\t} else if (\"isActive\" in props) {\n\t\treturn [props.isActive, props.variant, true]\n\t} else if (\"isNotActive\" in props) {\n\t\treturn [props.isNotActive, props.variant, false]\n\t} else if (\"condition\" in props) {\n\t\treturn [props.name, props.condition]\n\t}\n\tthrow Error(\"invalid props\")\n}\n\n/**\n * Creates a React component that conditionally renders its contents based on the\n * currently active features. Prefer this component over the `isOn` and `isActive`\n * methods in React components because this component is able to handle server-side\n * rendering correctly.\n *\n * @example\n * const Feature = createFeatureComponent(abTestFeatures)\n * // \u2026\n * <Feature isOn=\"prize\"><p>Click for a chance to win cash!</p></Feature>\n */\nexport function createFeatureComponent<Name extends string>(\n\tfeatures: FeatureSet<Name>,\n): FunctionComponent<Props<Name> & { children?: React.ReactNode }> {\n\treturn function Feature({ children, ...props }) {\n\t\tlet condition: (variant: string | undefined) => boolean\n\t\tlet featureName: Name\n\t\tif (\"condition\" in props) {\n\t\t\tcondition = props.condition\n\t\t\tfeatureName = props.name\n\t\t} else {\n\t\t\tconst [name, parameterVariant, expectedCondition] = propsToParameters(props)\n\t\t\tcondition = variant => (variant === parameterVariant) === expectedCondition\n\t\t\tfeatureName = name\n\t\t}\n\t\tconst shouldRender = useCondition(features, featureName, condition)\n\t\treturn shouldRender ? React.createElement(React.Fragment, null, children) : null\n\t}\n}\n\nfunction getVariantInSafeContext<Name extends string>(features: FeatureSet<Name>, name: Name): string {\n\tisInSafeContext = true\n\ttry {\n\t\treturn features.get(name)\n\t} finally {\n\t\tisInSafeContext = false\n\t}\n}\n\nexport function useCondition<Name extends string>(\n\tfeatures: FeatureSet<Name>,\n\tname: Name,\n\tcondition: (variant?: string) => boolean,\n): boolean {\n\tconst [, forceRerender] = useReducer((state: number) => state + 1, 0)\n\n\tconst isActive = useRef(false)\n\tconst conditionRef = useRef(condition)\n\tconditionRef.current = condition\n\n\tconst variant = getVariantInSafeContext(features, name)\n\n\tisActive.current = conditionRef.current(variant)\n\n\tuseLayoutEffect(() => {\n\t\tconst listener = (newVariant: string) => {\n\t\t\tconst newCondition = conditionRef.current(newVariant)\n\t\t\tif (newCondition === isActive.current) return\n\t\t\t// Variant active state changed, trigger a rerender.\n\t\t\tisActive.current = newCondition\n\t\t\tforceRerender()\n\t\t}\n\n\t\tfeatures.addListener(name, listener)\n\t\treturn () => features.removeListener(name, listener)\n\t}, [features, name])\n\n\treturn isActive.current\n}\n", "import type { ExperimentName, Experiments, GradualRolloutDefinition } from \"@framerjs/app-config\"\nimport { ExperimentScope, gradualRolloutExperiments } from \"@framerjs/app-config\"\nimport type { ProjectLicenseType } from \"@framerjs/app-shared\"\nimport { murmurHash } from \"@framerjs/shared\"\nimport { isArray, isNull } from \"utils/typeChecks.ts\"\n\n/**\n * 2^32-1, Maximum possible value of murmurHash\n */\nconst MAX_32_BIT_INT = 0xffffffff\n\nconst state = {\n\thashes: {\n\t\t[ExperimentScope.Project]: null,\n\t\t[ExperimentScope.Team]: null,\n\t\t[ExperimentScope.User]: null,\n\t} as { [name in ExperimentScope]: number | null },\n\n\tisEnterprise: {\n\t\t/**\n\t\t * whether the currently open project is on enterprise plan\n\t\t */\n\t\t[ExperimentScope.Project]: null,\n\n\t\t/**\n\t\t * whether the current team of the current user is on enterprise account\n\t\t */\n\t\t[ExperimentScope.Team]: null,\n\n\t\t/**\n\t\t * whether current user is part of at least one enterprise team\n\t\t */\n\t\t[ExperimentScope.User]: null,\n\t} as { [name in ExperimentScope]: boolean | null },\n\n\tchannel: null as string | null,\n}\n\nexport function setProject(project: { id: string; license: { type: ProjectLicenseType } }) {\n\tstate.isEnterprise[ExperimentScope.Project] = project.license.type === \"enterpriseSite\"\n\tstate.hashes[ExperimentScope.Project] = murmurHash(project.id)\n}\n\nexport function setUser(user: { id: string; spaces: { id?: string; license?: { type: string } }[] }) {\n\tstate.isEnterprise[ExperimentScope.User] = user.spaces.some(team => team.license?.type === \"enterprise\")\n\tstate.hashes[ExperimentScope.User] = murmurHash(user.id)\n}\n\nexport function setTeam(id: string, license: string) {\n\tstate.isEnterprise[ExperimentScope.Team] = license === \"enterprise\"\n\tstate.hashes[ExperimentScope.Team] = murmurHash(id)\n}\n\nexport function setChannel(channel: string) {\n\tstate.channel = channel\n}\n\nfunction shouldEnableVariant<T extends ExperimentName>(\n\texperimentName: T,\n\t{ sample, scope, variant, includeEnterprise, channels }: GradualRolloutDefinition<Experiments[T]>,\n): boolean {\n\tif (channels) {\n\t\tif (!state.channel) {\n\t\t\t// Experiment is constrained to select channels, but we don't know the channel we're on.\n\t\t\t// Let's be on the safe side and assume we might be on the wrong channel.\n\t\t\treturn false\n\t\t} else if (!channels.includes(state.channel)) {\n\t\t\t// Experiment is constrained to select channels, and we're not on the right channel.\n\t\t\treturn false\n\t\t}\n\t\t// We're on the right channel, so we can check the rest of the conditions.\n\t}\n\n\tconst hashThreshold = sample * MAX_32_BIT_INT\n\tconst experimentHash = murmurHash(experimentName)\n\tconst variantHash = murmurHash(variant)\n\n\tif (isNull(state.hashes[scope]) || isNull(state.isEnterprise[scope])) {\n\t\t// graceful fallback if parameters are not initialized\n\t\treturn false\n\t}\n\n\tif (!includeEnterprise && state.isEnterprise[scope]) {\n\t\treturn false\n\t}\n\n\tconst definitionHash = (state.hashes[scope] ^ experimentHash ^ variantHash) >>> 0\n\n\treturn definitionHash < hashThreshold\n}\n\n/**\n * Returns a record of binary on/off state gradual rollout from project ID and experiment name\n * according to the specified sample size [0..1]\n *\n * Hash values are evenly distributed across 0..2^32 range,\n *\n * We use XOR of the project id hash and salt it with experiment name hash\n * to avoid all the experiments being enabled for the same small set of projects\n */\nexport function getOverrides(overrideDefinitions = gradualRolloutExperiments) {\n\tconst overrides: { [name in ExperimentName]?: string } = {}\n\n\tObject.keys(overrideDefinitions).forEach((name: ExperimentName) => {\n\t\tif (!overrideDefinitions[name]) return\n\n\t\t// Handle both single definition and array of definitions\n\t\tconst definitions = isArray(overrideDefinitions[name])\n\t\t\t? (overrideDefinitions[name] as GradualRolloutDefinition<Experiments[typeof name]>[])\n\t\t\t: ([overrideDefinitions[name]] as GradualRolloutDefinition<Experiments[typeof name]>[])\n\n\t\tfor (const definition of definitions) {\n\t\t\tif (!shouldEnableVariant(name, definition)) continue\n\n\t\t\tconst experimentsToEnable = [name, ...(definition.dependencies ?? [])]\n\n\t\t\texperimentsToEnable.forEach(key => {\n\t\t\t\toverrides[key] = definition.variant\n\t\t\t})\n\t\t\t// Once a definition is enabled, we don't need to check the rest\n\t\t\tbreak\n\t\t}\n\t})\n\n\treturn overrides\n}\n", "// Set of hardcoded site ids that should have new translation model enabled but we don't want to put on beta channel.\n\nimport type { ExperimentName } from \"@framerjs/app-config/src/experiments.ts\"\n\n// TODO: Remove this once the experiments are released\nexport const enableExperimentsForProjects: Record<string, ExperimentName[]> = {\n\t// Perplexity Site\n\t\"637362dde0f8db852b3ff44aba1678e1ceee077bd6d1ac503a395dd8fd467cd1\": [\n\t\t\"translationModelGemini3Flash\",\n\t\t\"localizationAiUpdate\",\n\t],\n\t// Perplexity Pro - Enterprise\n\t\"95b5cc8ae7f015eabad543eef528a979c811885f9a3ca65168a6cb126da680ba\": [\n\t\t\"translationModelGemini3Flash\",\n\t\t\"localizationAiUpdate\",\n\t],\n\t// Perplexity Changelog\n\tde0eb89af30f0e49c67495d6440ea21ecc1a1e200c38829566040b22c7bf59fc: [\n\t\t\"translationModelGemini3Flash\",\n\t\t\"localizationAiUpdate\",\n\t],\n\n\t// Tandem ai\n\td90a8d106017986195d14414e9a0ac4d2d6044c34e40ccd9400cde31b0137ca2: [\"translationModelGemini3Flash\"],\n\n\t// l10n QA test site prod framer.com/projects/Localization-QA--TvkiwzfJOcCnP6KiBvO4\n\tc874a142cd73dccb399c7352e844346a524c7af0347d60b7a9b620f18b7a9158: [\"localizationAiUpdate\"],\n\n\t// Mollie\n\tbf17748a4e084a2d7e9929a68f3b31a5759f614ce328e84ee4192fddecea62f3: [\"localizationAiUpdate\"],\n\n\t// Tickadoo projects\n\t// British Theatre Website\n\tbf53f24395c6f2b6c965b10d5633d16cf9d2c58341612c180c1ac280b5b03168: [\"localizationAiUpdate\"],\n\t// Blog\n\tff2a11c8e1a1dd6eee7c7a0365dec3c1c1b353e62230395bb9a00fd347a52d1a: [\"localizationAiUpdate\"],\n\t// UK\n\t\"8c10117d000814e2891bdde214fefbd2f4a2ac6d417600eede2856d8102cf86e\": [\"localizationAiUpdate\"],\n\t// EU East\n\t\"36439efdb60b949ee33791118d3c3dc47b657a23a2fda8bacc7fc3ed7d2dda45\": [\"localizationAiUpdate\"],\n\t// America\n\ta2846c600bf841b5247f2b81233f20d47f922bcbc0a39716a7c3db7282dd1e72: [\"localizationAiUpdate\"],\n\t// EU West\n\tcb15333875ee186289f57808e05d6f985476b719299224518950be3df89a4155: [\"localizationAiUpdate\"],\n\t// Asia Pacific\n\t\"980d6bef77fdbd2250892051a61fd33b5381a35d768e1a94842e233c70d04632\": [\"localizationAiUpdate\"],\n\t// Africa Middle East\n\t\"5c333815ebd3604547ec50da62e896c7d58552e1cc771babf4e63a452db4f047\": [\"localizationAiUpdate\"],\n\t// Other\n\t\"832f30149c8800940b48335ae7dcb95a57bbc50699106f1fb9ef51e3745e97d9\": [\"localizationAiUpdate\"],\n}\n", "import type { ExperimentName } from \"@framerjs/app-config\"\nimport { alphaExperiments, betaExperiments, stableExperiments } from \"@framerjs/app-config\"\nimport type { WindowWithCurrentUser } from \"@framerjs/app-shared\"\nimport { hostInfo } from \"@framerjs/shared\"\nimport { getFramerRelease } from \"environment/getFramerRelease.ts\"\nimport { objectKeys } from \"library/utils/objectKeys.ts\"\nimport { isString } from \"utils/typeChecks.ts\"\nimport { FeatureSet, createFeatureComponent, useCondition } from \"./FeatureSet.tsx\"\nimport * as GradualRollout from \"./GradualRollout.ts\"\nimport { enableExperimentsForProjects } from \"./siteIdsWithExperimentsForceEnabled.ts\"\n\ntype ExperimentOverrides = { [name in ExperimentName]?: string }\n\nif (typeof window !== \"undefined\" && (window as WindowWithCurrentUser).framerUser) {\n\tGradualRollout.setUser((window as WindowWithCurrentUser).framerUser)\n}\n\nexport const experiments = new FeatureSet<ExperimentName>(defaultExperimentsForChannel())\nexperiments.update(getAllExperimentsOverrides())\n\nexport const Experiment = createFeatureComponent(experiments)\n\nexport function useExperimentIsOn(experiment: ExperimentName, framerSiteId?: string): boolean {\n\tconst isOn = useCondition(experiments, experiment, variant => variant === \"on\")\n\treturn isOn || shouldForceEnableForSite(experiment, framerSiteId)\n}\n\nexport function useExperimentIs(experiment: ExperimentName, variant: string): boolean {\n\treturn useCondition(experiments, experiment, currentVariant => currentVariant === variant)\n}\n\nexport function experimentIsOnOrForceEnabled(experiment: ExperimentName, framerSiteId?: string): boolean {\n\treturn experiments.isOn(experiment) || shouldForceEnableForSite(experiment, framerSiteId)\n}\n\nfunction shouldForceEnableForSite(experiment: ExperimentName, framerSiteId?: string): boolean {\n\tif (!framerSiteId) return false\n\tif (!enableExperimentsForProjects[framerSiteId]) return false\n\treturn enableExperimentsForProjects[framerSiteId].includes(experiment)\n}\n\nfunction getStorageKey() {\n\tif (typeof window === \"undefined\") return \"experiments\"\n\t// Each channel gets its own storage key so it never clashes.\n\tconst channel = getFramerRelease(window)?.channel\n\treturn channel ? `experiments-${channel}` : \"experiments\"\n}\n\n// Sets of overrides determined by the current release channel\nfunction getChannelOverrides() {\n\tconst overrides: { [name in ExperimentName]?: string } = {}\n\tif (typeof window === \"undefined\") return {}\n\n\tconst framerRelease = getFramerRelease(window)\n\tif (!framerRelease) return overrides\n\n\tconst { channel, override } = framerRelease\n\t// Turn alpha experiments on in dev tunnel.\n\tconst isDevTunnel = override === \"tunnel\" && hostInfo.isDevelopment\n\tif (channel === \"alpha\" || channel === \"local\" || isDevTunnel) {\n\t\tObject.assign(overrides, betaExperiments, alphaExperiments)\n\t}\n\tif (channel === \"beta\") {\n\t\tObject.assign(overrides, betaExperiments)\n\t}\n\treturn overrides\n}\n\n// Controlled by the menu to toggle experiments\nfunction getStoredOverrides() {\n\tconst overrides: { [name in ExperimentName]?: string } = {}\n\ttry {\n\t\tconst config = JSON.parse(localStorage[getStorageKey()] || \"{}\")\n\t\tObject.assign(overrides, config)\n\t} catch (e) {\n\t\t// Ignore errors.\n\t}\n\treturn overrides\n}\n\n// Used by testing\nfunction getTestingOverrides(): ExperimentOverrides {\n\tif (typeof window === \"undefined\") return {}\n\tif (!hasTestingOverrides(window)) return {}\n\n\ttry {\n\t\treturn JSON.parse(window.experiments)\n\t} catch {}\n\n\treturn {}\n}\n\n// See src/automation/src/EditorSession.ts\nfunction hasTestingOverrides(window: Window): window is Window & { experiments: string } {\n\treturn \"experiments\" in window && isString(window.experiments)\n}\n\n// Experiment overrides for the current session.\nfunction getURLParamOverrides() {\n\tconst overrides: ExperimentOverrides = {}\n\tif (typeof window === \"undefined\") return {}\n\tfor (const item of new URLSearchParams(window?.location.search).getAll(\"experiment\")) {\n\t\tconst [experiment, value = \"on\"] = item.split(\"=\")\n\t\toverrides[experiment as ExperimentName] = value\n\t}\n\treturn overrides\n}\n\nexport function defaultExperimentsForChannel() {\n\treturn { ...stableExperiments, ...getChannelOverrides() }\n}\n\nexport function resetExperiments({\n\tresetStorage,\n\tresetSession,\n}: { resetStorage?: boolean; resetSession?: boolean } = {}) {\n\tif (typeof window === \"undefined\") return\n\n\tif (resetStorage) {\n\t\tlocalStorage.removeItem(getStorageKey())\n\t}\n\tif (resetSession) {\n\t\tconst currentURL = new URL(window.location.href)\n\t\tcurrentURL.searchParams.delete(\"experiment\")\n\t\twindow.history.replaceState(window.history.state, \"\", currentURL.href)\n\t}\n\texperiments.update({\n\t\t...stableExperiments,\n\t\t...getAllExperimentsOverrides(),\n\t})\n}\n\nfunction getAllExperimentsOverrides() {\n\treturn {\n\t\t...GradualRollout.getOverrides(),\n\t\t...getChannelOverrides(),\n\t\t...getStoredOverrides(),\n\t\t...getTestingOverrides(),\n\t\t...getURLParamOverrides(),\n\t}\n}\n\nif (typeof window !== \"undefined\") {\n\t// this is a non-critical flag clean-up, for the sake of hygiene.\n\t// this code can be safely deleted anytime after a couple of weeks\n\twindow.localStorage.removeItem(\"useThemeLogo\")\n}\n\nexport function updateExperimentsStorage(changes: Partial<typeof stableExperiments>) {\n\tconst storageKey = getStorageKey()\n\tlet storedFeatures = {}\n\ttry {\n\t\tstoredFeatures = JSON.parse(localStorage[storageKey] || \"{}\")\n\t} catch (e) {\n\t\t// Ignore errors.\n\t}\n\n\tconst storageUpdate = { ...storedFeatures, ...changes }\n\n\t// Filter out values that are already default\n\tfor (const name of objectKeys(storageUpdate)) {\n\t\tif (experiments.getInitial(name) === storageUpdate[name]) {\n\t\t\tdelete storageUpdate[name]\n\t\t}\n\t}\n\n\ttry {\n\t\tObject.keys(storageUpdate).length === 0\n\t\t\t? localStorage.removeItem(storageKey)\n\t\t\t: localStorage.setItem(storageKey, JSON.stringify(storageUpdate))\n\t} catch (e) {\n\t\t// Ignore errors when localStorage is not available.\n\t}\n}\n"],
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAO,IAAM,+BAA+B;AAAA,EAC3C,gCAAgC;AAAA,EAChC,0BAA0B;AAAA,EAC1B,+BAA+B;AAAA,EAC/B,6BAA6B;AAAA,EAC7B,wBAAwB;AAAA,EACxB,aAAa;AAAA,EACb,8BAA8B;AAAA,EAC9B,wBAAwB;AAAA,EACxB,sBAAsB;AAAA,EACtB,yBAAyB;AAAA,EACzB,6BAA6B;AAAA,EAC7B,oCAAoC;AAAA,EACpC,eAAe;AAAA,EACf,iBAAiB;AAAA,EACjB,cAAc;AAAA,EACd,eAAe;AAAA,EACf,yBAAyB;AAAA,EACzB,iBAAiB;AAAA,EACjB,cAAc;AACf;;;ACjBA,SAAS,aAA0C,UAAkB,OAA4B;AAChG,QAAM,SAAS,IAAI,IAAI,QAAQ;AAC/B,SAAO,IAAI,IAAI;AACf,SAAO,IAAI,KAAK;AAChB,SAAO,EAAE,UAAU,CAAC,GAAG,MAAM,GAAG,MAAM;AACvC;AAQA,IAAM,qBAA+C,CAAC;AAE/C,SAAS,sBAAsB,MAAoC;AACzE,SAAO,mBAAmB,IAAI;AAC/B;AAQA,SAAS,UAAqF,Q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