2

I am using an embedded multivalue field in one of my components to manage multiple "links", the embedded field has several fields such as title, text, internalLink, externalLink (the usual...). I added the appropriate markup (or so I think) for it to be inline editable in XPM, I can modify the "text" field (that's the one I want to allow inline-editing for:

enter image description here

I can also add/remove embedded values:

enter image description here

But I cannot edit the existing one, is there a way to edit the current field being displayed in the metadata-like xpm form as you would add embedded values? This form shows the form I am talking about when adding new embedded values:

enter image description here

This is the markup around the link field:

<div class="col-sm-5 col-md-4 hidden-xs login-box" prefix="s: http://schema.org" typeof="s:GenericWidget"><!-- Start Component Presentation: {"ComponentID" : "tcm:1009-5286", "ComponentModified" : "2015-05-18T15:20:44", "ComponentTemplateID" : "tcm:1009-5287-32", "ComponentTemplateModified" : "2015-04-30T14:16:03", "IsRepositoryPublished" : false} -->
<div class="row">
    <div class="col-sm-12 text-center login-header" property="s:title"><!-- Start Component Field: {"XPath":"tcm:Content/custom:GenericWidget/custom:title[1]"} -->Login or Register</div>
</div>
<div class="row pad-row-8px">
    <div class="col-sm-12 text-center">
        <div class="btn-group">
            <button type="button" class="btn btn-default dropdown-toggle select-acct-btn" data-toggle="dropdown">
                Select One

                        <span class="caret"></span>
            </button>

                <ul class="dropdown-menu" role="menu"><!-- Start Component Field: {"XPath":"tcm:Metadata/custom:Metadata/custom:parameter[1]"} -->
                    <li><a href="/insurance">Insurance</a></li><li><a href="/retirement">Retirement </a></li><li><a href="/investments">Mutual Funds</a></li><li><a href="/insurance">Annuities </a></li> 
            </ul>
        </div>
    </div>
</div>
<div class="row pad-row-8px">
    <div class="col-xs-12 text-center">
        <button type="button" class="btn btn-default login-acct-btn">Login</button>
    </div>
</div>
<div class="row pad-row-8px">
    <div class="col-xs-12 text-center" property="s:link">
        <!-- Start Component Field: {"XPath":"tcm:Content/custom:GenericWidget/custom:link[1]"} -->
        <a class="signup-acct-link" href="www.google.com">
            <span>
            <!-- Start Component Field: {"XPath":"tcm:Content/custom:GenericWidget/custom:link[1]/custom:linkText[1]"} -->
                Sign Up for an Account
            </span>
        </a>
    </div>
</div>

Enhancement Request

It would be great if there was an "edit" button either on the Ribbon Toolbar or the Embedded Schema Field properties dialog...

enter image description here

3
  • So you want to edit the non visible values like title and target, or just the link? May 19, 2015 at 12:38
  • With regards to your enhancement request, why not get some people to build that for you in the hackathon ;o) May 19, 2015 at 20:39
  • I want to edit the current embeddable field in the form view (xpm form view, not cme) May 22, 2015 at 19:02

1 Answer 1

1

When you click on the link, you can edit the "text" field. To edit the non existing values like Title, Target and Icon, you would at least need to have XPM markup added for those fields, which your HTML currently doesn't show.

What you can try, is to click the []link in the breadcrumb, after you selected the text field. But I'm not sure if that actually will bring up a form for the available values, don't think it currently does that yet.

If it is only the available values you want to edit, you should make sure that those values are all correctly marked, so something like:

<div class="col-xs-12 text-center" property="s:link">
    <!-- Start Component Field: {"XPath":"tcm:Content/custom:GenericWidget/custom:link[1]"} -->
    <div>
        <!-- Start Component Field: {"XPath":"tcm:Content/custom:GenericWidget/custom:link[1]/custom:externalLink[1]"} -->
        <a class="signup-acct-link" href="www.google.com">
            <span>
                <!-- Start Component Field: {"XPath":"tcm:Content/custom:GenericWidget/custom:link[1]/custom:linkText[1]"} -->
                Sign Up for an Account
            </span>
        </a>
    </div>
</div>
2

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.