I'm trying to use <force:recordEdit>
on a Visualforce page via Lightning Out. But there seems to be some rendering issues. Using a standalone Lightning App it looks like this:
Using LightningOut there are a couple of spinners visible forever.
The spinners seam to correspond to the lookup fields. Lookups have missing lookup-buttons in the standalone lightning apps, too. I think this is a bug and might be related to Lightning Components: Using <force:inputField /> on a Lookup only works partly
Looking at the markup, I was able to make some hidden elements visible. Maybe they are even partly functional. Visibility and layout is messed-up at least. See here:
Will this be fixed in either Spring'16 or Summer'16?
Here is the code:
Component
<aura:component >
<h2>record display component inside</h2>
<force:recordEdit aura:id="edit" recordId="001g000000mGaZQ"/>
<ui:button class="elfSave" label="Save" press="{!c.save}"/>
</aura:component>
Controller
({
save : function(component, event, helper) {
component.find("edit").get("e.recordSave").fire();
},
})
outApp
<aura:application access="GLOBAL" extends="ltng:outApp">
<aura:dependency resource="c:elfLCX_recordEdit"/>
</aura:application>
Page
<apex:page standardController="Account" >
<apex:includeLightning />
<div id="elfLCX_recordEditWrapper"></div>
<script type="text/javascript">
$Lightning.use("c:elfLCX_out", function() {
$Lightning.createComponent(
"c:elfLCX_recordEdit"
,{ label : "Record Edit"}
,"elfLCX_recordEditWrapper"
,function(cmp) {
// do some stuff
}
);
});
</script>
</apex:page>