mirror of
https://github.com/perstarkse/minne.git
synced 2026-03-13 05:45:35 +01:00
refactor: modal homogenity
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -7,20 +7,26 @@ hx-swap="outerHTML"
|
||||
{% endblock %}
|
||||
|
||||
{% block modal_content %}
|
||||
<h3 class="text-lg font-bold mb-4">Edit Content</h3>
|
||||
|
||||
<h3 class="text-lg font-bold ">Edit Content</h3>
|
||||
<div class="form-control">
|
||||
<label class="floating-label">
|
||||
<span class="label-text">Content Name</span>
|
||||
<input type="text" name="name" value="{{ text_content.text }}" class="w-full input input-bordered">
|
||||
<span class="label-text">Instructions</span>
|
||||
<input type="text" name="name" value="{{ text_content.instructions}}" class="w-full input input-bordered">
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div class="form-control ">
|
||||
<label class="floating-label">
|
||||
<span class="label-text">Category</span>
|
||||
<input type="text" name="name" value="{{ text_content.category}}" class="w-full input input-bordered">
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<input type="text" name="id" value="{{ text_content.id }}" class="hidden">
|
||||
|
||||
<div class="form-control mt-4 ">
|
||||
<div class="form-control">
|
||||
<label class="floating-label">
|
||||
<span class="label-text">Description</span>
|
||||
<span class="label-text">Text</span>
|
||||
<textarea name="description" class="textarea textarea-bordered h-32 w-full">{{ text_content.text}}</textarea>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
@@ -8,7 +8,7 @@ hx-swap="outerHTML"
|
||||
{% endblock %}
|
||||
|
||||
{% block modal_content %}
|
||||
<h3 class="text-lg font-bold mb-4">Add new content</h3>
|
||||
<h3 class="text-lg font-bold">Add new content</h3>
|
||||
|
||||
<div class="form-control">
|
||||
<label class="floating-label">
|
||||
@@ -20,7 +20,7 @@ hx-swap="outerHTML"
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div class="form-control mt-4">
|
||||
<div class="form-control">
|
||||
<label class="floating-label">
|
||||
<span>Content</span>
|
||||
<textarea name="content" class="textarea input-bordered w-full"
|
||||
@@ -28,7 +28,7 @@ hx-swap="outerHTML"
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div class="form-control mt-4">
|
||||
<div class="form-control">
|
||||
<label class="floating-label">
|
||||
<span>Category</span>
|
||||
<input type="text" name="category" class="input input-bordered validator w-full" value="{{ category }}"
|
||||
@@ -42,7 +42,7 @@ hx-swap="outerHTML"
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div class="form-control mt-4">
|
||||
<div class="form-control">
|
||||
<label class="label label-text">Files</label>
|
||||
<input type="file" name="files" multiple class="file-input file-input-bordered w-full" />
|
||||
</div>
|
||||
|
||||
@@ -7,7 +7,7 @@ hx-swap="outerHTML"
|
||||
{% endblock %}
|
||||
|
||||
{% block modal_content %}
|
||||
<h3 class="text-lg font-bold mb-4">Edit Entity</h3>
|
||||
<h3 class="text-lg font-bold">Edit Entity</h3>
|
||||
|
||||
<div class="form-control">
|
||||
<label class="floating-label">
|
||||
@@ -18,7 +18,7 @@ hx-swap="outerHTML"
|
||||
|
||||
<input type="text" name="id" value="{{ entity.id }}" class="hidden">
|
||||
|
||||
<div class="form-control mt-4">
|
||||
<div class="form-control">
|
||||
<label class="floating-label">
|
||||
<span class="label-text">Description</span>
|
||||
<textarea name="description" class="w-full textarea textarea-bordered h-32">{{ entity.description }}</textarea>
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
<dialog id="body_modal" class="modal">
|
||||
<div class="modal-box">
|
||||
<form id="modal_form" {% block form_attributes %}{% endblock %}>
|
||||
{% block modal_content %}
|
||||
<!-- Form fields go here in child templates -->
|
||||
{% endblock %}
|
||||
<div class="flex flex-col space-y-4">
|
||||
{% block modal_content %} <!-- Form fields go here in child templates -->
|
||||
{% endblock %}
|
||||
</div>
|
||||
|
||||
<div class="modal-action">
|
||||
<!-- Close button (always visible) -->
|
||||
|
||||
Reference in New Issue
Block a user