blob: 9047f80315ff4636131a9c5e99383c3a2be91f6d [file] [log] [blame]
Charlene Yan0724dc562019-04-12 17:57:411// Copyright 2019 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5// This file defines the browser-specific base::FeatureList features that are
6// limited to top chrome UI.
7
8#ifndef CHROME_BROWSER_UI_UI_FEATURES_H_
9#define CHROME_BROWSER_UI_UI_FEATURES_H_
10
11#include "base/feature_list.h"
Thomas Lukaszewicz31c038da2020-09-24 22:49:0712#include "base/metrics/field_trial_params.h"
Dana Fried16e9d9c2021-01-28 09:32:2813#include "build/branding_buildflags.h"
Charlene Yan0724dc562019-04-12 17:57:4114#include "build/build_config.h"
Yuta Hijikata40b891d2020-11-27 09:05:0115#include "build/chromeos_buildflags.h"
Peter Boström92add81d2019-08-12 22:14:2416#include "chrome/common/buildflags.h"
Devlin Cronin5739bf02020-05-15 00:38:3817#include "extensions/buildflags/buildflags.h"
Charlene Yan0724dc562019-04-12 17:57:4118
19namespace features {
20
21// All features in alphabetical order. The features should be documented
22// alongside the definition of their values in the .cc file.
23
Elaine Chien29fce992020-12-01 17:44:3424extern const base::Feature kChromeLabs;
25
Dana Fried16e9d9c2021-01-28 09:32:2826#if BUILDFLAG(GOOGLE_CHROME_BRANDING)
27extern const base::Feature kChromeTipsInMainMenu;
28#endif
29
Christopher Thompsonf3ba20122019-06-06 22:01:0130extern const base::Feature kEvDetailsInPageInfo;
31
Devlin Cronin5739bf02020-05-15 00:38:3832#if BUILDFLAG(ENABLE_EXTENSIONS)
33extern const base::Feature kExtensionSettingsOverriddenDialogs;
34#endif
35
Charlene Yan0724dc562019-04-12 17:57:4136extern const base::Feature kExtensionsToolbarMenu;
37
rbpotter8c735ba2020-11-12 14:11:5538extern const base::Feature kForceEnablePrivetPrinting;
39
Monica Bastae2331412020-04-10 14:07:3040extern const base::Feature kNewProfilePicker;
41
Taylor Bergquist187a9f92019-08-12 22:13:1542extern const base::Feature kNewTabstripAnimation;
43
Joel Hockey73bc7122019-10-20 21:41:1144extern const base::Feature kProminentDarkModeActiveTabTitle;
45
Charlene Yan0ccd7f52019-04-12 23:20:5946extern const base::Feature kScrollableTabStrip;
47
Charlene Yana8164102020-11-10 04:39:4848extern const base::Feature kScrollableTabStripButtons;
49
Peter Boström259e1472020-10-22 22:26:2450extern const base::Feature kSidePanel;
51
Yann Dago0706f6072020-12-02 04:35:3852extern const base::Feature kSyncConfirmationUpdatedText;
53
Jan Krcal6c22f9f2021-01-07 10:34:4154extern const base::Feature kSignInProfileCreation;
dizgad7fe842020-08-12 16:55:1655
Charlene Yan45ff10d92020-09-16 03:14:5956extern const base::Feature kTabGroupsAutoCreate;
57
Charlene Yand49235292020-03-14 00:55:4358extern const base::Feature kTabGroupsCollapse;
59
Charlene Yan65e7cfe2020-07-28 18:55:2960extern const base::Feature kTabGroupsCollapseFreezing;
61
Charlene Yan5b80e052020-04-02 20:48:5662extern const base::Feature kTabGroupsFeedback;
63
Charlene Yan0724dc562019-04-12 17:57:4164extern const base::Feature kTabHoverCards;
65extern const char kTabHoverCardsFeatureParameterName[];
66
67extern const base::Feature kTabHoverCardImages;
68
Dana Fried07b03c62019-07-31 19:20:5669extern const base::Feature kTabOutlinesInLowContrastThemes;
70
Yuheng Huang4a8125c2020-06-23 20:45:3671extern const base::Feature kTabSearch;
72
Roman Arora4d4bb4b2020-09-24 17:28:1373extern const base::Feature kTabSearchFeedback;
74
Thomas Lukaszewicz31c038da2020-09-24 22:49:0775// Setting this to true will ignore the distance parameter when finding matches.
76// This means that it will not matter where in the string the pattern occurs.
77extern const base::FeatureParam<bool> kTabSearchSearchIgnoreLocation;
78
79// Determines how close the match must be to the beginning of the string. Eg a
80// distance of 100 and threshold of 0.8 would require a perfect match to be
81// within 80 characters of the beginning of the string.
82extern const base::FeatureParam<int> kTabSearchSearchDistance;
83
84// This determines how strong the match should be for the item to be included in
85// the result set. Eg a threshold of 0.0 requires a perfect match, 1.0 would
86// match anything. Permissible values are [0.0, 1.0].
87extern const base::FeatureParam<double> kTabSearchSearchThreshold;
88
89// These are the hardcoded minimum and maximum search threshold values for
90// |kTabSearchSearchThreshold|.
91constexpr double kTabSearchSearchThresholdMin = 0.0;
92constexpr double kTabSearchSearchThresholdMax = 1.0;
93
94// Controls how heavily weighted the tab's title is relative to the hostname.
95extern const base::FeatureParam<double> kTabSearchTitleToHostnameWeightRatio;
96
Yuheng Huangb2aa1bd42020-11-11 20:07:0997// Whether to move the active tab to the bottom of the list.
98extern const base::FeatureParam<bool> kTabSearchMoveActiveTabToBottom;
99
Peter Boström6e721192019-08-15 18:49:02100extern const base::Feature kWebFooterExperiment;
101
Collin Baker33a13f52019-12-13 00:30:23102extern const base::Feature kWebUITabStrip;
103
Yuta Hijikata40b891d2020-11-27 09:05:01104#if BUILDFLAG(IS_CHROMEOS_ASH)
Melissa Galonskya0c17c92019-06-27 18:34:19105extern const base::Feature kHiddenNetworkWarning;
Harry Cutts5b430df2020-09-22 11:22:29106extern const base::Feature kSeparatePointingStickSettings;
Yuta Hijikata40b891d2020-11-27 09:05:01107#endif // BUILDFLAG(IS_CHROMEOS_ASH)
Dana Fried16e9d9c2021-01-28 09:32:28108
Charlene Yan0724dc562019-04-12 17:57:41109} // namespace features
110
111#endif // CHROME_BROWSER_UI_UI_FEATURES_H_