Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement shared sections (verse1,verse2) and overriding information #11

Open
mickmister opened this issue May 29, 2024 · 0 comments
Open

Comments

@mickmister
Copy link
Member

mickmister commented May 29, 2024

When you clone/duplicate a section, they should continue to share all data. Whenever the user makes a change to a section, we should ask them if they want to make this a holistic change for all sections that are cloned, or just this one and create a divergent path for this particular instance of the section

So the data model around this needs to have a sense of "overriden changes". Maybe we have a relationship like "section template" in the data model. When a user clones a section, we end up with 3 section objects. One is a template, and two are instances.

Before user duplicates the first section:

{
    sections: [
        {id: 'aabb', name: 'Verse'}
    ]
}

After user duplicates the section:

{
    sections: [
        {id: 'zzz', is_template: true, name: 'Verse'},
        {id: 'aabb', name: 'Verse 1', template_id: 'zzz'},
        {id: 'ccdd', name: 'Verse 2', template_id: 'zzz'},
    ]
}

This should be the result if the user has confirmed they want to share information between clones of the section I think

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: No status
Status: No status
Development

No branches or pull requests

1 participant