2024-12-06 12:03:32 +00:00
|
|
|
import { cyParamName } from "./common";
|
|
|
|
|
|
2023-08-14 09:16:16 +00:00
|
|
|
|
|
|
|
|
export const workspaceConstantsSelectors = {
|
|
|
|
|
workspaceConstantsHelperText: '[data-cy="workspace-constant-helper-text"]',
|
|
|
|
|
emptyStateImage: '[data-cy="empty-state-image"]',
|
|
|
|
|
emptyStateHeader: '[data-cy="empty-state-header"]',
|
|
|
|
|
emptyStateText: '[data-cy="empty-state-text"]',
|
2024-12-06 12:03:32 +00:00
|
|
|
addNewConstantButton: '[data-cy="form-add-new-constant-button"]',
|
2023-08-14 09:16:16 +00:00
|
|
|
contantFormTitle: '[data-cy="constant-form-title"]',
|
|
|
|
|
addConstantButton: '[data-cy="add-constant-button"]',
|
|
|
|
|
envName: '[data-cy="env-name"]',
|
|
|
|
|
constantsTableNameHeader: '[data-cy="workspace-variable-table-name-header"]',
|
|
|
|
|
constantsTableValueHeader:
|
|
|
|
|
'[data-cy="workspace-variable-table-value-header"]',
|
2024-12-10 05:26:33 +00:00
|
|
|
nameInputFiled: '[data-cy="name-input-field"]',
|
2025-01-27 06:42:24 +00:00
|
|
|
nameFieldLabel: '[data-cy="name-label"]',
|
|
|
|
|
nameFieldHelperText: '[data-cy="name-info"]',
|
|
|
|
|
typeLabel: '[data-cy="type-label"]',
|
|
|
|
|
globalConstLabel: '[data-cy="global-constants-label"]',
|
|
|
|
|
globalConstHelperText: '[data-cy="global-constants-info"]',
|
|
|
|
|
secretsConstLabel: '[data-cy="secrets-constants-label"]',
|
|
|
|
|
secretsConstHelperText: '[data-cy="secrets-constants-info"]',
|
|
|
|
|
valueLabel: '[data-cy="value-label"]',
|
|
|
|
|
alertInfoText: '[data-cy="alert-info-text"]',
|
|
|
|
|
tableAddNewConstButton: '[data-cy="table-add-new-constant-button"]',
|
|
|
|
|
searchField: '[data-cy="-search-bar"]',
|
2023-08-14 09:16:16 +00:00
|
|
|
constantName: (constName) => {
|
2023-08-18 09:23:53 +00:00
|
|
|
return `[data-cy="${cyParamName(constName)}-workspace-constant-name"]`;
|
2023-08-14 09:16:16 +00:00
|
|
|
},
|
|
|
|
|
constantValue: (constName) => {
|
2023-08-18 09:23:53 +00:00
|
|
|
return `[data-cy="${cyParamName(constName)}-workspace-constant-value"]`;
|
2023-08-14 09:16:16 +00:00
|
|
|
},
|
|
|
|
|
constEditButton: (constName) => {
|
2023-08-18 09:23:53 +00:00
|
|
|
return `[data-cy="${cyParamName(constName)}-edit-button"]`;
|
2023-08-14 09:16:16 +00:00
|
|
|
},
|
|
|
|
|
constDeleteButton: (constName) => {
|
2023-08-18 09:23:53 +00:00
|
|
|
return `[data-cy="${cyParamName(constName)}-delete-button"]`;
|
2023-08-14 09:16:16 +00:00
|
|
|
},
|
2024-05-14 10:19:12 +00:00
|
|
|
constHideButton: (constName) => {
|
|
|
|
|
return `[data-cy="${cyParamName(constName)}-constant-visibility"]`;
|
|
|
|
|
},
|
2024-12-06 12:03:32 +00:00
|
|
|
constantsType: (type) => {
|
|
|
|
|
return `[data-cy="${cyParamName(type)}-constants-input"]`;
|
|
|
|
|
},
|
2023-08-14 09:16:16 +00:00
|
|
|
};
|