mirror of
https://github.com/wassname/talk.git
synced 2026-07-06 05:17:19 +08:00
Rename getSlotComponents to getSlotElements
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
import React, {Component} from 'react';
|
||||
import {getSlotComponents} from 'coral-framework/helpers/plugins';
|
||||
import {getSlotElements} from 'coral-framework/helpers/plugins';
|
||||
|
||||
class Slot extends Component {
|
||||
render() {
|
||||
const {fill, ...rest} = this.props;
|
||||
return (
|
||||
<div>
|
||||
{getSlotComponents(fill, rest)}
|
||||
{getSlotElements(fill, rest)}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -41,7 +41,7 @@ function getConfig(plugin) {
|
||||
/**
|
||||
* getSlotComponents returns React Elements for given slot.
|
||||
*/
|
||||
export function getSlotComponents(slot, props = {}) {
|
||||
export function getSlotElements(slot, props = {}) {
|
||||
return loaded.components
|
||||
.map((o, i) => ({
|
||||
component: o.module,
|
||||
|
||||
Reference in New Issue
Block a user