2017-12-20 12:33:33 +01:00
|
|
|
import coreModule from 'app/core/core_module';
|
2019-02-05 17:04:48 +01:00
|
|
|
import { provideTheme } from 'app/core/utils/ConfigProvider';
|
2017-10-17 10:51:42 +02:00
|
|
|
|
2017-12-21 08:39:31 +01:00
|
|
|
export function react2AngularDirective(name: string, component: any, options: any) {
|
2017-12-19 16:06:54 +01:00
|
|
|
coreModule.directive(name, [
|
2017-12-20 12:33:33 +01:00
|
|
|
'reactDirective',
|
2017-12-19 16:06:54 +01:00
|
|
|
reactDirective => {
|
2019-02-05 17:04:48 +01:00
|
|
|
return reactDirective(provideTheme(component), options);
|
2017-12-20 12:33:33 +01:00
|
|
|
},
|
2017-12-19 16:06:54 +01:00
|
|
|
]);
|
2017-10-17 10:51:42 +02:00
|
|
|
}
|