// packages/block-library/src/video/index.js
import { __ } from "@wordpress/i18n";
import { video as icon } from "@wordpress/icons";
import initBlock from "../utils/init-block";
import deprecated from "./deprecated";
import edit from "./edit";
import metadata from "./block.json";
import save from "./save";
import transforms from "./transforms";
var { name } = metadata;
var settings = {
  icon,
  example: {
    attributes: {
      src: "https://upload.wikimedia.org/wikipedia/commons/c/ca/Wood_thrush_in_Central_Park_switch_sides_%2816510%29.webm",
      // translators: Caption accompanying a video of the wood thrush singing, which serves as an example for the Video block.
      caption: __("Wood thrush singing in Central Park, NYC.")
    }
  },
  transforms,
  deprecated,
  edit,
  save
};
if (window.__experimentalContentOnlyPatternInsertion) {
  settings.fields = [
    {
      label: __("Video"),
      type: "Media",
      shownByDefault: true,
      mapping: {
        id: "id",
        src: "src",
        caption: "caption",
        poster: "poster"
      },
      args: {
        allowedTypes: ["video"],
        multiple: false
      }
    },
    {
      label: __("Caption"),
      type: "RichText",
      shownByDefault: false,
      mapping: {
        value: "caption"
      }
    }
  ];
}
var init = () => initBlock({ name, metadata, settings });
export {
  init,
  metadata,
  name,
  settings
};
//# sourceMappingURL=index.js.map
