Skip to main content
File upload component.

Properties

  • file (object) (required)
    • url (string) - pattern: (https?://.*\.(png|jpeg|jpg|svg|gif|mp3|wav|aac|m4... - format: uri (required)
    • type (string) - Type of the file
    • mime (string) - MIME type of the file
    • name (string) - Name of the file
  • button (object - ref: _base_button) (required)

Used in Categories

This component is used in the following categories:

Schema

{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "title": "File Upload Schema",
  "description": "File upload component.",
  "type": "object",
  "required": [
    "file",
    "button"
  ],
  "properties": {
    "file": {
      "type": "object",
      "required": [
        "url"
      ],
      "additionalProperties": false,
      "properties": {
        "url": {
          "type": "string",
          "format": "uri",
          "pattern": "(https?://.*\\.(png|jpeg|jpg|svg|gif|mp3|wav|aac|m4a|pdf|doc|docx|xls|xlsx|ppt|pptx|odt|ods|odp|txt|csv|js|PNG|JPEG|JPG|SVG|GIF|MP3|WAV|AAC|M4A|PDF|DOC|DOCX|XLS|XLSX|PPT|PPTX|ODT|ODS|ODP|TXT|CSV|JS))$"
        },
        "type": {
          "type": "string",
          "description": "Type of the file"
        },
        "mime": {
          "type": "string",
          "description": "MIME type of the file"
        },
        "name": {
          "type": "string",
          "description": "Name of the file"
        }
      }
    },
    "button": {
      "$ref": "_base_button.json"
    }
  }
}