<configure xmlns="http://namespaces.zope.org/zope"
           xmlns:browser="http://namespaces.zope.org/browser">

  <include package="zope.app.form.browser" />

  <browser:page
      for="*"
      name="form_macros"
      permission="zope2.View"
      class=".macros.FormMacros"
      allowed_interface="zope.interface.common.mapping.IItemMapping"
      />

  <configure package="zope.formlib">

    <adapter
        factory=".form.render_submit_button"
        name="render"
        />

    <!-- Error view for 'Invalid' -->
    <adapter
        for="zope.interface.Invalid
             zope.publisher.interfaces.browser.IBrowserRequest"
        factory=".errors.InvalidErrorView"
        permission="zope.Public"
        />

  </configure>

</configure>
