import { i18n } from '@kbn/i18n' ; import { AdvanceRoleType } from '../../types' ; export const ROLE_MAPPING_DELETED_MESSAGE = i18n . translate ( 'xpack.enterpriseSearch.appSearch.roleMappingDeletedMessage' , { defaultMessage : 'Your role mapping was deleted' , } ) ; export const ROLE_MAPPING_CREATED_MESSAGE = i18n . translate ( 'xpack.enterpriseSearch.appSearch.roleMappingCreatedMessage' , { defaultMessage : 'Your role mapping was created' , } ) ; export const ROLE_MAPPING_UPDATED_MESSAGE = i18n . translate ( 'xpack.enterpriseSearch.appSearch.roleMappingUpdatedMessage' , { defaultMessage : 'Your role mapping was updated' , } ) ; export const ROLE_MAPPINGS_ENGINE_ACCESS_HEADING = i18n . translate ( 'xpack.enterpriseSearch.appSearch.roleMappingsEngineAccessHeading' , { defaultMessage : 'Engine access' , } ) ; export const DEV_ROLE_TYPE_DESCRIPTION = i18n . translate ( 'xpack.enterpriseSearch.appSearch.DEV_ROLE_TYPE_DESCRIPTION' , { defaultMessage : 'Devs can manage all aspects of an engine.' , } ) ; export const EDITOR_ROLE_TYPE_DESCRIPTION = i18n . translate ( 'xpack.enterpriseSearch.appSearch.editorRoleTypeDescription' , { defaultMessage : 'Editors can manage search settings.' , } ) ; export const ANALYST_ROLE_TYPE_DESCRIPTION = i18n . translate ( 'xpack.enterpriseSearch.appSearch.analystRoleTypeDescription' , { defaultMessage : 'Analysts can only view documents, query tester, and analytics.' , } ) ; export const OWNER_ROLE_TYPE_DESCRIPTION = i18n . translate ( 'xpack.enterpriseSearch.appSearch.ownerRoleTypeDescription' , { defaultMessage : 'Owners can do anything. There can be many owners on the account, but there must be at least one owner at any time.' , } ) ; export const ADMIN_ROLE_TYPE_DESCRIPTION = i18n . translate ( 'xpack.enterpriseSearch.appSearch.adminRoleTypeDescription' , { defaultMessage : 'Admins can do anything, except manage account settings.' , } ) ; export const ENGINE_REQUIRED_ERROR = i18n . translate ( 'xpack.enterpriseSearch.appSearch.engineRequiredError' , { defaultMessage : 'At least one assigned engine is required.' , } ) ; export const ALL_ENGINES_LABEL = i18n . translate ( 'xpack.enterpriseSearch.appSearch.allEnginesLabel' , { defaultMessage : 'Assign to all engines' , } ) ; export const ALL_ENGINES_DESCRIPTION = i18n . translate ( 'xpack.enterpriseSearch.appSearch.allEnginesDescription' , { defaultMessage : 'Assigning to all engines includes all current and future engines as created and administered at a later date.' , } ) ; export const SPECIFIC_ENGINES_LABEL = i18n . translate ( 'xpack.enterpriseSearch.appSearch.specificEnginesLabel' , { defaultMessage : 'Assign to specific engines' , } ) ; export const SPECIFIC_ENGINES_DESCRIPTION = i18n . translate ( 'xpack.enterpriseSearch.appSearch.specificEnginesDescription' , { defaultMessage : 'Assign to a select set of engines statically.' , } ) ; export const ENGINE_ASSIGNMENT_LABEL = i18n . translate ( 'xpack.enterpriseSearch.appSearch.engineAssignmentLabel' , { defaultMessage : 'Engine assignment' , } ) ; export const ADVANCED_ROLE_TYPES = [ { id : 'dev' , description : DEV_ROLE_TYPE_DESCRIPTION , } , { id : 'editor' , description : EDITOR_ROLE_TYPE_DESCRIPTION , } , { id : 'analyst' , description : ANALYST_ROLE_TYPE_DESCRIPTION , } , ] as AdvanceRoleType [ ] ; export const STANDARD_ROLE_TYPES = [ { id : 'owner' , description : OWNER_ROLE_TYPE_DESCRIPTION , } , { id : 'admin' , description : ADMIN_ROLE_TYPE_DESCRIPTION , } , ] as AdvanceRoleType [ ] ;