"use strict";

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

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

var template = function template(pluginContext) {
  var React = pluginContext.lib.React;
  var _pluginContext$layout = pluginContext.layoutComponents,
      Col = _pluginContext$layout.Col,
      Cols = _pluginContext$layout.Cols,
      Panel = _pluginContext$layout.Panel,
      Row = _pluginContext$layout.Row;
  var _pluginContext$record = pluginContext.recordComponents,
      Field = _pluginContext$record.Field,
      Subrecord = _pluginContext$record.Subrecord;


  return React.createElement(
    Field,
    { name: "document" },
    React.createElement(
      Panel,
      { name: "media", collapsible: true },
      React.createElement(
        Row,
        null,
        React.createElement(Field, { name: "identificationNumber" }),
        React.createElement(Field, { name: "title" })
      ),
      React.createElement(
        Panel,
        { name: "file", collapsible: true },
        React.createElement(Subrecord, { name: "blob", showDetachButton: true })
      ),
      React.createElement(
        Cols,
        null,
        React.createElement(
          Col,
          null,
          React.createElement(Field, { name: "externalUrl" })
        ),
        React.createElement(Col, null)
      ),
      React.createElement(
        Field,
        { name: "measuredPartGroupList" },
        React.createElement(
          Field,
          { name: "measuredPartGroup" },
          React.createElement(
            Panel,
            null,
            React.createElement(
              Row,
              null,
              React.createElement(Field, { name: "measuredPart" }),
              React.createElement(Field, { name: "dimensionSummary" })
            ),
            React.createElement(
              Field,
              { name: "dimensionSubGroupList" },
              React.createElement(
                Field,
                { name: "dimensionSubGroup" },
                React.createElement(Field, { name: "dimension" }),
                React.createElement(Field, { name: "measuredBy" }),
                React.createElement(Field, { name: "measurementMethod" }),
                React.createElement(Field, { name: "value" }),
                React.createElement(Field, { name: "measurementUnit" }),
                React.createElement(Field, { name: "valueQualifier" }),
                React.createElement(Field, { name: "valueDate" })
              )
            )
          )
        )
      ),
      React.createElement(
        Cols,
        null,
        React.createElement(
          Col,
          null,
          React.createElement(Field, { name: "contributor" }),
          React.createElement(Field, { name: "creator" }),
          React.createElement(
            Field,
            { name: "languageList" },
            React.createElement(Field, { name: "language" })
          ),
          React.createElement(Field, { name: "publisher" }),
          React.createElement(
            Field,
            { name: "relationList" },
            React.createElement(Field, { name: "relation" })
          ),
          React.createElement(Field, { name: "copyrightStatement" })
        ),
        React.createElement(
          Col,
          null,
          React.createElement(
            Field,
            { name: "typeList" },
            React.createElement(Field, { name: "type" })
          ),
          React.createElement(Field, { name: "coverage" }),
          React.createElement(
            Field,
            { name: "dateGroupList" },
            React.createElement(Field, { name: "dateGroup" })
          ),
          React.createElement(Field, { name: "source" }),
          React.createElement(
            Field,
            { name: "subjectList" },
            React.createElement(Field, { name: "subject" })
          ),
          React.createElement(Field, { name: "rightsHolder" })
        )
      ),
      React.createElement(Field, { name: "description" })
    )
  );
};

exports.default = function (pluginContext) {
  return {
    messages: (0, _reactIntl.defineMessages)({
      name: {
        "id": "form.media.default.name",
        "defaultMessage": "Standard Template"
      }
    }),
    template: template(pluginContext)
  };
};