Sha256: 7ebf39a96431ffd394782bcb07d00418452b48e74376279066d1608e632c1dff
Contents?: true
Size: 1.38 KB
Versions: 12
Compression:
Stored size: 1.38 KB
Contents
import { FormGroup, Radio } from '@patternfly/react-core'; import { translate as __ } from 'foremanReact/common/I18n'; import PropTypes from 'prop-types'; import React from 'react'; import { helpLabel } from '../form/FormHelpers'; export const QueryType = ({ isTypeStatic, setIsTypeStatic }) => ( <> <FormGroup label={__('Query type')} fieldId="query-type-static" labelIcon={helpLabel( __('Type has impact on when is the query evaluated to hosts.'), 'query-type' )} > <Radio ouiaId="query-type-static" isChecked={isTypeStatic} name="query-type" onChange={() => setIsTypeStatic(true)} id="query-type-static" label={__('Static query')} body={__('evaluates just after you submit this form')} /> </FormGroup> <FormGroup fieldId="query-type-dynamic"> <Radio ouiaId="query-type-dynamic" isChecked={!isTypeStatic} name="query-type" onChange={() => setIsTypeStatic(false)} id="query-type-dynamic" label={__('Dynamic query')} body={__( "evaluates just before the execution is started, so if it's planned in future, targeted hosts set may change before it" )} /> </FormGroup> </> ); QueryType.propTypes = { isTypeStatic: PropTypes.bool.isRequired, setIsTypeStatic: PropTypes.func.isRequired, };
Version data entries
12 entries across 12 versions & 1 rubygems