<%- include("template/head.ejs", {tituloWeb})%>
    <link rel="stylesheet" href="/css/register.css">
    </head>

    <body class="login">
        <main class="container-fluid mainlogin">

            <div class="container">
                <div class="row justify-content-center containerFormat">
                    <form id="editar" class="rounded bg-dark p-4 text-white loginFormat align-self-center"
                        data-id="<%=noticiaEditar.id%>">
                        <div class="mt-2 text-center">
                            <h1 class="display-6">Editar noticia</h1>
                        </div>
                        <div class="mb-3 pt-4 ps-5 pe-5">
                            <label for="titulo" class="form-label">Titulo de la noticia</label>
                            <input type="text" class="form-control" id="titulo" placeholder="Titulo" name="titulo"
                                value="<%=noticiaEditar.titulo%>">
                        </div>
                        <div class="mb-3 pt-4 ps-5 pe-5">
                            <label for="descripcion" class="form-label">Descripcion</label>
                            <input type="text" class="form-control" id="descripcion" placeholder="Descripcion"
                                name="descripcion" value="<%=noticiaEditar.descripcion%>">
                        </div>
                        <div class="row justify-content-center">
                            <button id="edit" type="submit" class="btn btn-success mt-5 buttonFormat me-md-0 me-lg-5 me-xl-5">Guardar
                                cambios</button>
                            <button id="delete" type="submit" class="btn btn-danger mt-5 buttonFormat me-md-0 me-lg-5 me-xl-5">Eliminar
                                Noticia</button>

                            <a class="btn btn-success mt-5 buttonFormat" href="/news">Volver</a>
                        </div>
                    </form>
                </div>
            </div>
        </main>
        <%- include("template/footer.ejs")%>
            <script src="/js/edit_delete_news.js"></script>