specification {
    tag developer
    element actor {
        style {
            shape person
        }
    }
    element environment

}

model {
    actor developer 'Developer' {
        -> Platform.DeliveryAndControlPlane.Portal 'use Portal as E2E Golden Path Processor'
        -> Platform.DeliveryAndControlPlane.IDE 'use preferred IDE as local code editing, building, testing, syncing tool'
        -> Platform.DeliveryAndControlPlane.VersionControl.ApplicationSourceCode 'git cli tools'
        -> Platform.DeliveryAndControlPlane.VersionControl.PlatformSourceCode 'git cli tools'

        -> Platform.DeliveryAndControlPlane.Portal.Catalogue
        -> Platform.DeliveryAndControlPlane.Portal.Documentation
        -> Platform.DeliveryAndControlPlane.Portal.Templates
        -> Platform.DeliveryAndControlPlane.Portal.SystemDashboard
    }

    actor platformengineer 'P' {
        -> Platform.DeliveryAndControlPlane.Portal 'use Portal as E2E Golden Path Processor'
        -> Platform.DeliveryAndControlPlane.IDE 'use preferred IDE as local code editing, building, testing, syncing tool'
        -> Platform.DeliveryAndControlPlane.VersionControl.ApplicationSourceCode 'git cli tools'
        -> Platform.DeliveryAndControlPlane.VersionControl.PlatformSourceCode 'git cli tools'

    }

    extend Platform.DeliveryAndControlPlane.IDE {
        IDE -> Platform.DeliveryAndControlPlane.VersionControl.PlatformSourceCode 'IDE git'
        IDE -> Platform.DeliveryAndControlPlane.VersionControl.ApplicationSourceCode 'IDE git'
        IDE -> Platform.DeliveryAndControlPlane.Portal.API '(opt.) browse/control in IDE'
    }

    extend Platform.DeliveryAndControlPlane.Portal {
        component API
        component Templates
        component Catalogue
        component Documentation
        component SystemDashboard
    }

    environment localBox {
        environment EDF 'Platform' 'Environment for the EDF Platform Orchestration' {
            -> local 'provision'
            -> test 'provision'
            -> prod 'provision'
            developer -> this 'manage (in Developer Portal)'
            Platform.DeliveryAndControlPlane.IDE -> this 'provide "code"'
        }
        environment local 'Environment Local' 'Environment for developing / Integration'
    }
    environment cloud {
        environment test 'Environment Test' 'Environment for review delivery'
        environment prod 'Environment Prod' 'Environment for final delivery'
    }
}

views {
    view developer {
        title "Developer Experience"
        include developer
        include Platform.DeliveryAndControlPlane.*
        include Platform.DeliveryAndControlPlane.VersionControl.*
        include Platform.DeliveryAndControlPlane.Portal.*

        include Platform.DeliveryAndControlPlane.IDE with {
            title 'IDE'
            description 'The IDE is the developers center of coding'
            color green
        }
    }

    view environments {
        include platformengineer, developer
        include Platform.DeliveryAndControlPlane.IDE, Platform.Portal
        include element.kind=environment
      autoLayout TopBottom
    }
}