{% load static %}

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Osina</title>

    <link rel="stylesheet" type="text/css" href='{% static "dist/output.css" %}'>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.3/css/all.min.css">
</head>

<body class="font-poppinsLight">
    <form method="POST" {% if not milestone %} action="{% url 'adduserstorymodal' project.project_id %}" {% else %} action="{% url 'addmilestoneuserstorymodal' milestone.id %}" {% endif %}>
        {% csrf_token %}
        <h1 class="text-secondosiblue text-2xl font-semibold text-center">Add User Story</h1>

        {% if not milestone %}
        <div class="w-full">
            <label class="text-gray-500">Milestone:</label>
            <select required name="milestone" id=""
                class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
                {% for milestone in milestones %}
                    <option value="{{milestone.id}}">{{milestone.name}}</option>
                {% endfor %}
            </select>
        </div>
        {% endif %}
    
        <div class="w-full flex justify-center items-center">
            <input name="content" type="text" placeholder="User Story"
            class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-4"
            required>
        </div>


        <div class="w-full flex justify-start items-center gap-2 mt-4">
            <input name="completed" type="checkbox">
            <p class="text-gray-500">Completed</p>
        </div>

        <div class="w-full flex justify-start items-center gap-2 mt-4">
            <input name="confirmed" type="checkbox">
            <p class="text-gray-500">Confirmed</p>
        </div>


    
        <div class="w-full flex justify-center items-center mt-4">
            <button type="submit"
                class="w-fit bg-osiblue border border-osiblue rounded-md text-white text-xl px-5 py-1 hover:bg-white hover:text-osiblue duration-300">Save</button>
        </div>
    </form>
</body>
</html>