---
to: <%- route -%>.extension.ts
---
import { extensions } from '@wix/astro/builders';

export default extensions.customElement({
  id: '<%- config.id -%>',
  name: '<%- config.name -%>',
  width: {
    defaultWidth: 450,
    allowStretch: true
  },
  height: {
    defaultHeight: 250
  },
  installation: {
    autoAdd: true
  },
  presets: [
    {
      id: '<%- config.presetId -%>',
      name: 'default',
      thumbnailUrl: '{{BASE_URL}}/<%- route -%>-thumbnail.png',
    },
  ],
  <% if (config.dashboardPageId) { %>
  behaviors: {
    dashboard: {
      dashboardPageComponentId: '<%- config.dashboardPageId -%>'
    }
  },<% } %>
  tagName: '<%- route -%>',
  element: '<%- config.element -%>',
  settings: '<%- config.settings -%>',
});
