Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/enhancement/add-task-manually' i…
Browse files Browse the repository at this point in the history
…nto test
  • Loading branch information
frjo committed Aug 22, 2024
2 parents 38aa5a0 + 9d8f121 commit deaa0a7
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 6 deletions.
38 changes: 36 additions & 2 deletions hypha/apply/activity/templates/activity/include/comment_form.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,40 @@
{% load i18n %}

<div class="wrapper wrapper--comments">
{% trans "Submit" as submit %}
{% include "funds/includes/delegated_form_base.html" with form=comment_form value=submit extra_classes="form__comments" %}
{% trans "Submit" as value %}
{% load i18n %}
<form
class="form form__comments"
method="post"
id="{% if form_id %}{{ form_id }}{% else %}{{ comment_form.name }}{% endif %}"
enctype="multipart/form-data"
{% if action %}action="{{ action }}"{% endif %}
>
{% csrf_token %}

{{ comment_form.media }}
{% for hidden in comment_form.hidden_fields %}
{{ hidden }}
{% endfor %}

<div class="fields--visible">
{% for field in comment_form.visible_fields %}
{% if field.field %}
{% include "forms/includes/field.html" %}
{% else %}
{{ field }}
{% endif %}
{% endfor %}

<button
class="button button--primary"
id="{{ comment_form.name }}-submit"
name="{{ form_prefix }}{{ comment_form.name }}"
type="submit"
form="{% if form_id %}{{ form_id }}{% else %}{{ comment_form.name }}{% endif %}">
{{ value }}
</button>
</div>

</form>
</div>
13 changes: 9 additions & 4 deletions hypha/static_src/sass/components/_form.scss
Original file line number Diff line number Diff line change
Expand Up @@ -449,12 +449,12 @@
&__comments {
.fields--visible {
display: grid;
grid-template-areas: "message" "attachments" "visibility" "actions";
grid-template-areas: "message" "attachments" "visibility" "assigned_to" "actions";
grid-template-rows: auto auto auto auto;
grid-template-columns: 1fr;

@include media-query(lg) {
grid-template-areas: "message attachments" "message visibility" "message assigned_to";
grid-template-areas: "message attachments" "message visibility" "message assigned_to" "actions assigned_to";
grid-template-rows: auto auto;
grid-template-columns: 2fr 1fr;
column-gap: 2rem;
Expand All @@ -466,6 +466,11 @@
}
}

// stylelint-disable-next-line selector-class-pattern
.button {
max-width: 150px;
}

// stylelint-disable-next-line selector-class-pattern
.form__group {
margin-block-end: 0.5rem;
Expand All @@ -492,9 +497,9 @@

// stylelint-disable-next-line selector-class-pattern
.id_assigned_to {
grid-area: assigned_to;
display: flex;
align-items: center;
gap: 1rem;
flex-direction: column;
}
}
}
Expand Down

0 comments on commit deaa0a7

Please sign in to comment.