mirror of
https://github.com/wassname/talk.git
synced 2026-09-09 11:38:08 +08:00
changes
This commit is contained in:
@@ -8,6 +8,7 @@ import isEqual from 'lodash/isEqual';
|
||||
import get from 'lodash/get';
|
||||
import { getShallowChanges } from 'coral-framework/utils';
|
||||
import omit from 'lodash/omit';
|
||||
import merge from 'lodash/merge';
|
||||
|
||||
const emptyConfig = {};
|
||||
|
||||
@@ -75,9 +76,10 @@ class Slot extends React.Component {
|
||||
|
||||
// @Deprecated plugin_config
|
||||
const pluginsConfig =
|
||||
get(reduxState, 'config.plugins_config') ||
|
||||
get(reduxState, 'config.plugin_config') ||
|
||||
emptyConfig;
|
||||
merge(
|
||||
get(reduxState, 'config.plugins_config'),
|
||||
get(reduxState, 'config.plugin_config')
|
||||
) || emptyConfig;
|
||||
|
||||
if (children.length === 0 && DefaultComponent) {
|
||||
const props = plugins.getSlotComponentProps(
|
||||
@@ -93,6 +95,8 @@ class Slot extends React.Component {
|
||||
children = children.map(childFactory);
|
||||
}
|
||||
|
||||
// console.log('pluginsConfig', pluginsConfig);
|
||||
|
||||
return (
|
||||
<Component
|
||||
className={cn(
|
||||
|
||||
@@ -97,11 +97,17 @@ class PluginsService {
|
||||
this.showPluginsConfigWarning = false;
|
||||
}
|
||||
|
||||
console.log(
|
||||
'slot plugins_config',
|
||||
get(reduxState, 'config.plugins_config')
|
||||
);
|
||||
|
||||
// @Deprecated plugin_config
|
||||
const pluginsConfig =
|
||||
get(reduxState, 'config.plugins_config') ||
|
||||
get(reduxState, 'config.plugin_config') ||
|
||||
emptyConfig;
|
||||
merge(
|
||||
get(reduxState, 'config.plugins_config'),
|
||||
get(reduxState, 'config.plugin_config')
|
||||
) || emptyConfig;
|
||||
|
||||
const debugProps = pluginsConfig.debug
|
||||
? {
|
||||
|
||||
Reference in New Issue
Block a user