<?php
return array(
    "type" => "sidebar_object",
    "model" => "SidebarObject",
    "label" => "Sidebar Objects",
    "label_singular" => "Sidebar Object",
    "group" => "general",
    "template" => false,
    "order" => true,
    "websites" => array(1, 2),
    "shareable" => "none",
    "fields" => array(
        array(
            "name" => "title",
            "label" => "title",
            "type" => "textBox",
            "maxLength" => 100,
            "multiLanguage" => true,
            "preValidation" => "strip_tags|xss_clean|trim",
            "validation" => "required|max:100",
            "inList" => true,
            "search" => true,
            "sort" => true
        ),
        array(
            "name" => "image",
            "label" => "Side image",
            "type" => "mediaPicker",
            "mediaType" => "image",
            "placement" => "sidebar",
            /*
            "thumbnailSizes" => array(
                array("type" => "fit", "name" => "150x150", "width" => 150, "height" => 150),
            )
            */
        ),
        /*
        array(
            "name" => "bgImage",
            "label" => "Background image",
            "type" => "mediaPicker",
            "mediaType" => "image",
            "placement" => "sidebar",
            "thumbnailSizes" => array(
                array("type" => "fit", "name" => "470x500", "width" => 470, "height" => 500),
            )
        ),
        */
        array(
            "name" => "content",
            "label" => "Content",
            "type" => "editor",
            "validation" => "required_if:type,generic,facts",
            "multiLanguage" => true
        ),
        array(
            "name" => "color_scheme",
            "label" => "color scheme",
            "type" => "selectBox",
            "list" => array(
                "light" => "Light",
                "dark" => "Dark"
            ),
            "preValidation" => "trim",
            "validation" => "nullable|required_if:type,generic|in:light,dark",
            "placement" => "sidebar"
        ),
        array(
            "name" => "call_to_action",
            "label" => "call to action",
            "type" => "link",
            "multiLanguage" => true,
            "required" => false,
            "maxLabel" => 60,
            "objectTypes" => array("project", "page", "solution", "case_study", "publication", "contact", "pardot_form")
        ),
        array(
            "name" => "ref_content_type",
            "label" => "Ref Content Type",
            "type" => "textBox",
            "maxLength" => 50,
            "multiLanguage" => false,
            "preValidation" => "strip_tags|xss_clean|trim",
            "validation" => "max:50",
            "inList" => true,
            "search" => true,
            "sort" => true
        ),
        array(
            "name" => "ref_content_title",
            "label" => "Ref Content Title",
            "type" => "textBox",
            "maxLength" => 255,
            "multiLanguage" => false,
            "preValidation" => "strip_tags|xss_clean|trim",
            "validation" => "max:255",
            "inList" => true,
            "search" => true,
            "sort" => true
        ),
    ),
    "actions" => array(
        "insert", "edit", "duplicate", "delete"
    )
);
