structurizr / ui

UI code for Structurizr Lite, on-premises, and cloud service.
https://docs.structurizr.com/ui
MIT License
38 stars 22 forks source link

Filtered views use the base view title on the diagram, rather than the defined title #32

Closed Midnighter closed 9 months ago

Midnighter commented 9 months ago

Description

I noticed something funny about filtered views: When I define a different title for a filtered view (for a system context in my case), that title is shown correctly in the diagram overview and the sidebar. However, on the diagram itself, the base diagram title is shown.

Steps to reproduce

  1. Define a view in the DSL
  2. Define a filtered view on top of that view with a title element (see code below)
  3. Visualize workspace by running lite, pushing to on-premises or cloud
  4. Look at the filtered view

Screenshot

image

Code sample

workspace {

   model {
      user = person "User" "A user of my software system."
      softwareSystem = softwareSystem "Software System" "My software system."

      user -> softwareSystem "Uses"
   }

   views {
      systemContext softwareSystem "SystemContext" {
         include *
         autoLayout
         title "Short Title"
         description "Such a nice description."
      }

      filtered "SystemContext" include "Element" "FilteredContext" {
         title "Much longer Title"
         description "Definitely an ugly description."
      }

      styles {
         element "Software System" {
            background #1168bd
            color #ffffff
         }
         element "Person" {
            shape person
            background #08427b
            color #ffffff
         }
      }
   }

}

Configuration

structurizr/lite:latest (Docker image pulled today)

Severity

Minor

Priority

Low

Resolution

I have no budget and there's no rush, please fix this for free

More information

No response

Midnighter commented 9 months ago

Fantastic, thank you for the quick fix!