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

User Binders Container #6

Open
JonoSommers opened this issue Feb 25, 2025 · 0 comments
Open

User Binders Container #6

JonoSommers opened this issue Feb 25, 2025 · 0 comments

Comments

@JonoSommers
Copy link
Owner

JonoSommers commented Feb 25, 2025

Description:
The Users Binder Container will display a default binder when a user creates an account, along with the ability for the user to create a second binder. The container will also include a button to open the Binder Creation form. Users can only have a maximum of two binders, and clicking on a binder name will redirect them to that binder's specific view.

Details:

  • A default binder is automatically created when the user successfully creates an account.
  • A button to open the Binder Creation form is included below the list of binders.
  • Users are limited to only 2 binders. If they already have two, they cannot create more.
  • Clicking on a binder name will redirect the user to that binder's specific view.

Examples:

  • Request Body for Creating a New Binder:
{
  "binderName": "My Second Binder"
}
  • Response Body for Creating a New Binder:
{
  "message": "Your binder 'My Second Binder' has been successfully created.",
  "binder": {
    "id": 2,
    "name": "My Second Binder",
  }
}
  • Response Body for Retrieving User's Binders (including default binder and second binder):
{
  "binders": [
    {
      "id": 0,
      "name": "Default Binder",
    },
    {
      "id": 1,
      "name": "My Second Binder",
    }
  ]
}
  • Response Body if User Tries to Create a Third Binder:
{
  "error": "You cannot create more than two binders."
}

Acceptance Criteria:

  • Upon account creation, the user has a default binder created automatically.

  • The Binder Container displays:

    • The default binder.
    • Any additional binders the user has created (up to a maximum of two).
  • The Create Binder button:

    • Opens a Binder Creation form with a Binder Name input field.
    • Limits users to creating a maximum of two binders. If the user already has two binders, no further binders can be created.
  • Clicking on a binder name redirects the user to that binder's specific view.

  • If the user tries to create more than two binders, an error message is displayed: "You cannot create more than two binders."

  • The UI is structured and displays binders in a visually appealing way.

  • All interactions (button clicks, form submissions) work as expected and pass the tests.

Image
@JonoSommers JonoSommers moved this to Todo in Cardfolio FE Feb 25, 2025
@JonoSommers JonoSommers changed the title User Binders View User Binders Container Feb 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Todo
Development

No branches or pull requests

1 participant