Skip to content

Bug: Inspector prop values only reflect default useCase values #189

@mhsdesign

Description

@mhsdesign

Build a simple component:

prototype(Foo.Bar:Block.Thing) < prototype(Neos.Fusion:Component) {
    @styleguide {
        title = 'Thing'
        props {
            option = true
        }
        useCases {
            blablabla {
                title = "Blablabla"
                props {
                    option = false
                }
            }
        }
    }
    renderer = afx`
        {Json.stringify(props)}
    `
}

Open it in monocle

  • expect rendering to be {"option":true}
  • expect inpector to correctly reflect option with checkbox marked

Select usecase Blablabla

  • expect rendering to be {"option":false}
  • expect inpector to correctly reflect option with checkbox not marked -> fails!
Bildschirmaufzeichnung.vom.10.10.2022.22.05.33.webm

I looked at the code and \Sitegeist\Monocle\Domain\PrototypeDetails\Props\PropsCollectionFactory only takes into account the current default for the initial page load - and there is simply no update inspector logic in place ...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions