"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});

var _reactIntl = require("react-intl");

const template = pluginContext => {
  const React = pluginContext.lib.React;
  var _pluginContext$layout = pluginContext.layoutComponents;
  const Panel = _pluginContext$layout.Panel,
        Row = _pluginContext$layout.Row;
  const Field = pluginContext.recordComponents.Field;
  const extensions = pluginContext.config.extensions;


  return React.createElement(
    Field,
    { name: "document" },
    React.createElement(
      Panel,
      { name: "id", collapsible: true },
      React.createElement(
        Row,
        null,
        React.createElement(
          "div",
          null,
          React.createElement(Field, { name: "objectNumber" }),
          React.createElement(Field, { name: "numberOfObjects" }),
          React.createElement(
            Field,
            { name: "responsibleDepartments" },
            React.createElement(Field, { name: "responsibleDepartment" })
          ),
          React.createElement(Field, { name: "collection" })
        ),
        React.createElement(
          "div",
          null,
          React.createElement(
            Field,
            { name: "briefDescriptions" },
            React.createElement(Field, { name: "briefDescription" })
          ),
          React.createElement(Field, { name: "distinguishingFeatures" })
        )
      ),
      React.createElement(
        Field,
        { name: "titleGroupList" },
        React.createElement(
          Field,
          { name: "titleGroup" },
          React.createElement(
            Panel,
            null,
            React.createElement(
              Row,
              null,
              React.createElement(
                "div",
                null,
                React.createElement(Field, { name: "title" }),
                React.createElement(Field, { name: "titleLanguage" })
              ),
              React.createElement(
                "div",
                null,
                React.createElement(Field, { name: "titleType" }),
                React.createElement(
                  Field,
                  { name: "titleTranslationSubGroupList" },
                  React.createElement(
                    Field,
                    { name: "titleTranslationSubGroup" },
                    React.createElement(Field, { name: "titleTranslation" }),
                    React.createElement(Field, { name: "titleTranslationLanguage" })
                  )
                )
              )
            )
          )
        )
      ),
      React.createElement(
        Field,
        { name: "objectNameList" },
        React.createElement(
          Field,
          { name: "objectNameGroup" },
          React.createElement(Field, { name: "objectName" }),
          React.createElement(Field, { name: "objectNameCurrency" }),
          React.createElement(Field, { name: "objectNameLevel" }),
          React.createElement(Field, { name: "objectNameSystem" }),
          React.createElement(Field, { name: "objectNameType" }),
          React.createElement(Field, { name: "objectNameLanguage" }),
          React.createElement(Field, { name: "objectNameNote" })
        )
      )
    ),
    React.createElement(
      Panel,
      { name: "desc", collapsible: true, collapsed: true },
      React.createElement(
        Row,
        null,
        React.createElement(
          "div",
          null,
          React.createElement(Field, { name: "copyNumber" })
        ),
        React.createElement(
          "div",
          null,
          React.createElement(Field, { name: "editionNumber" }),
          React.createElement(
            Field,
            { name: "colors" },
            React.createElement(Field, { name: "color" })
          )
        )
      ),
      React.createElement(
        Field,
        { name: "materialGroupList" },
        React.createElement(
          Field,
          { name: "materialGroup" },
          React.createElement(Field, { name: "material" }),
          React.createElement(Field, { name: "materialComponent" }),
          React.createElement(Field, { name: "materialComponentNote" }),
          React.createElement(Field, { name: "materialName" }),
          React.createElement(Field, { name: "materialSource" })
        )
      ),
      React.createElement(Field, { name: "physicalDescription" }),
      React.createElement(
        Row,
        null,
        React.createElement(
          Field,
          { name: "technicalAttributeGroupList" },
          React.createElement(
            Field,
            { name: "technicalAttributeGroup" },
            React.createElement(Field, { name: "technicalAttribute" }),
            React.createElement(Field, { name: "technicalAttributeMeasurement" }),
            React.createElement(Field, { name: "technicalAttributeMeasurementUnit" })
          )
        ),
        React.createElement("div", null)
      ),
      extensions.dimension.form,
      React.createElement(
        Panel,
        { name: "content", collapsible: true, collapsed: true },
        React.createElement(Field, { name: "contentDescription" }),
        React.createElement(
          Row,
          null,
          React.createElement(
            "div",
            null,
            React.createElement(
              Field,
              { name: "contentLanguages" },
              React.createElement(Field, { name: "contentLanguage" })
            ),
            React.createElement(
              Field,
              { name: "contentActivities" },
              React.createElement(Field, { name: "contentActivity" })
            ),
            React.createElement(
              Field,
              { name: "contentConcepts" },
              React.createElement(Field, { name: "contentConcept", label: "" })
            ),
            React.createElement(Field, { name: "contentDateGroup" }),
            React.createElement(
              Field,
              { name: "contentPositions" },
              React.createElement(Field, { name: "contentPosition" })
            ),
            React.createElement(
              Field,
              { name: "contentObjectGroupList" },
              React.createElement(
                Field,
                { name: "contentObjectGroup" },
                React.createElement(Field, { name: "contentObject" }),
                React.createElement(Field, { name: "contentObjectType" })
              )
            )
          ),
          React.createElement(
            "div",
            null,
            React.createElement(
              Field,
              { name: "contentPeoples" },
              React.createElement(Field, { name: "contentPeople" })
            ),
            React.createElement(
              Field,
              { name: "contentPersons" },
              React.createElement(Field, { name: "contentPerson", label: "" })
            ),
            React.createElement(
              Field,
              { name: "contentPlaces" },
              React.createElement(Field, { name: "contentPlace" })
            ),
            React.createElement(
              Field,
              { name: "contentScripts" },
              React.createElement(Field, { name: "contentScript" })
            ),
            React.createElement(
              Field,
              { name: "contentOrganizations" },
              React.createElement(Field, { name: "contentOrganization", label: "" })
            ),
            React.createElement(
              Field,
              { name: "contentEventNameGroupList" },
              React.createElement(
                Field,
                { name: "contentEventNameGroup" },
                React.createElement(Field, { name: "contentEventName" }),
                React.createElement(Field, { name: "contentEventNameType" })
              )
            ),
            React.createElement(
              Field,
              { name: "contentOtherGroupList" },
              React.createElement(
                Field,
                { name: "contentOtherGroup" },
                React.createElement(Field, { name: "contentOther" }),
                React.createElement(Field, { name: "contentOtherType" })
              )
            )
          )
        ),
        React.createElement(Field, { name: "contentNote" })
      )
    ),
    React.createElement(
      Panel,
      { name: "prod", collapsible: true, collapsed: true },
      React.createElement(
        Row,
        null,
        React.createElement(
          "div",
          null,
          React.createElement(
            Field,
            { name: "objectProductionDateGroupList" },
            React.createElement(Field, { name: "objectProductionDateGroup" })
          ),
          React.createElement(
            Field,
            { name: "techniqueGroupList" },
            React.createElement(
              Field,
              { name: "techniqueGroup" },
              React.createElement(Field, { name: "technique" }),
              React.createElement(Field, { name: "techniqueType" })
            )
          ),
          React.createElement(
            Field,
            { name: "objectProductionPlaceGroupList" },
            React.createElement(
              Field,
              { name: "objectProductionPlaceGroup" },
              React.createElement(Field, { name: "objectProductionPlace" }),
              React.createElement(Field, { name: "objectProductionPlaceRole" })
            )
          )
        ),
        React.createElement(
          "div",
          null,
          React.createElement(
            Field,
            { name: "objectProductionPersonGroupList" },
            React.createElement(
              Field,
              { name: "objectProductionPersonGroup" },
              React.createElement(Field, { name: "objectProductionPerson" }),
              React.createElement(Field, { name: "objectProductionPersonRole" })
            )
          ),
          React.createElement(
            Field,
            { name: "objectProductionOrganizationGroupList" },
            React.createElement(
              Field,
              { name: "objectProductionOrganizationGroup" },
              React.createElement(Field, { name: "objectProductionOrganization" }),
              React.createElement(Field, { name: "objectProductionOrganizationRole" })
            )
          ),
          React.createElement(Field, { name: "objectProductionNote" })
        )
      )
    ),
    React.createElement(
      Panel,
      { name: "reference", collapsible: true, collapsed: true },
      React.createElement(
        Field,
        { name: "referenceGroupList" },
        React.createElement(
          Field,
          { name: "referenceGroup" },
          React.createElement(Field, { name: "reference" }),
          React.createElement(Field, { name: "referenceNote" })
        )
      )
    ),
    React.createElement(
      Panel,
      { name: "hierarchy", collapsible: true, collapsed: true },
      React.createElement(Field, { name: "relation-list-item", subpath: "rel:relations-common-list" })
    )
  );
};

exports.default = pluginContext => ({
  messages: (0, _reactIntl.defineMessages)({
    name: {
      "id": "form.collectionobject.photo.name",
      "defaultMessage": "Photograph Template"
    }
  }),
  sortOrder: 2,
  template: template(pluginContext)
});