2022-05-31 13:00:47 +03:00
|
|
|
import angular from 'angular';
|
|
|
|
|
|
|
|
import { r2a } from '@/react-tools/react2angular';
|
|
|
|
import { CustomTemplatesVariablesDefinitionField } from '@/react/portainer/custom-templates/components/CustomTemplatesVariablesDefinitionField';
|
|
|
|
import { CustomTemplatesVariablesField } from '@/react/portainer/custom-templates/components/CustomTemplatesVariablesField';
|
2022-12-15 17:49:36 +01:00
|
|
|
import { withControlledInput } from '@/react-tools/withControlledInput';
|
2022-05-31 13:00:47 +03:00
|
|
|
|
|
|
|
import { VariablesFieldAngular } from './variables-field';
|
|
|
|
|
|
|
|
export const customTemplatesModule = angular
|
|
|
|
.module('portainer.app.react.components.custom-templates', [])
|
|
|
|
.component(
|
|
|
|
'customTemplatesVariablesFieldReact',
|
2022-12-15 17:49:36 +01:00
|
|
|
r2a(withControlledInput(CustomTemplatesVariablesField), [
|
|
|
|
'value',
|
|
|
|
'onChange',
|
|
|
|
'definitions',
|
|
|
|
])
|
2022-05-31 13:00:47 +03:00
|
|
|
)
|
|
|
|
.component('customTemplatesVariablesField', VariablesFieldAngular)
|
|
|
|
.component(
|
|
|
|
'customTemplatesVariablesDefinitionField',
|
2022-12-15 17:49:36 +01:00
|
|
|
r2a(withControlledInput(CustomTemplatesVariablesDefinitionField), [
|
2022-05-31 13:00:47 +03:00
|
|
|
'onChange',
|
|
|
|
'value',
|
|
|
|
'errors',
|
|
|
|
'isVariablesNamesFromParent',
|
|
|
|
])
|
|
|
|
).name;
|