Skip to content

Repeater: dehydration drops shared statePath when a sibling Group is hidden #19542

@capell-app

Description

@capell-app

Package

filament/filament

Package Version

v5.4.1

Laravel Version

12.55.1

Livewire Version

v4.2.1

PHP Version

8.4.8

Problem description

When two sibling Group components within a Repeater share the same statePath, hiding one of them causes the entire path to be removed during dehydration.

Expected behavior

Dehydration should only remove the hidden component’s data — not the entire shared state.

Steps to reproduce

howdu@5860079#diff-5dddb3985033b868906cdd986cc250a2579799ab792a350f9a1bf2df1633b371

Repeater::make('posts')
    ->relationship('posts')
    ->schema([
        Group::make([
            TextInput::make('internal_notes'),
        ])
            ->statePath('config')
            ->hidden(),
        Group::make([
            TextInput::make('seo_title'),
        ])
            ->statePath('config'),
    ]),

Reproduction repository (issue will be closed if this is not valid)

https://github.com/howdu/filament/tree/hotfix%2Fdehydate-state-conflict

Relevant log output

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    Status

    Done

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions