{
    "version": 1,
    "supportedProjectTypes": [ ],
    "id": "Q.QtStudio.QmlPane",
    "category": "H.StudioControlsFiles",
    "trDescription": "Provides a background that matches the UI style and theme.",
    "trDisplayName": "Pane",
    "trDisplayCategory": "Qt Quick Controls",
    "icon": "custom_panes.png",
    "platformIndependent": true,

    "options":
        [
        { "key": "QmlFile", "value": "%{Class}.%{JS: Util.preferredSuffix('application/x-qt.ui+qml')}" },
        { "key": "ApplicationImport", "value": "%{QmlProjectName} 1.0" }
    ],

    "pages" :
        [
        {
            "trDisplayName": "Define Class",
            "trShortTitle": "Details",
            "typeId": "Fields",
            "data" :
                [
                {
                    "name": "Class",
                    "trDisplayName": "Component name:",
                    "mandatory": true,
                    "type": "LineEdit",
                    "data": {
                        "validator": "(?:[A-Z_][a-zA-Z_0-9]*|)",
                        "fixup": "%{JS: '%{INPUT}'.charAt(0).toUpperCase() + '%{INPUT}'.slice(1) }"
                    }
                },
                {
                    "name": "TargetPath",
                    "type": "PathChooser",
                    "trDisplayName": "Path:",
                    "mandatory": true,
                    "data":
                    {
                        "kind": "existingDirectory",
                        "basePath": "%{InitialPath}",
                        "path": "%{InitialPath}"
                    }
                }
            ]
        }
    ],
    "generators" :
        [
        {
            "typeId": "File",
            "data":
            {
                "source": "file.qml.tpl",
                "target": "%{TargetPath}/%{QmlFile}",
                "openInEditor": true
            }
        }
    ]
}
