2022-11-24 14:31:16 -05:00
|
|
|
<div class="h-full flex flex-col justify-start items-stretch space-y-4">
|
2022-07-25 20:12:11 -04:00
|
|
|
<.form
|
2022-11-16 21:11:02 -05:00
|
|
|
:let={f}
|
2022-07-25 20:12:11 -04:00
|
|
|
for={@changeset}
|
|
|
|
id="pipeline-form"
|
|
|
|
phx-target={@myself}
|
|
|
|
phx-change="validate"
|
2022-07-25 22:05:54 -04:00
|
|
|
phx-submit="save"
|
2022-11-24 14:31:16 -05:00
|
|
|
phx-debounce="300"
|
|
|
|
class="flex flex-col justify-start items-stretch space-y-4"
|
2022-07-25 22:05:54 -04:00
|
|
|
>
|
2022-11-26 14:51:18 -05:00
|
|
|
<%= text_input(f, :slug,
|
2022-11-24 14:31:16 -05:00
|
|
|
class: "input input-primary",
|
2022-11-26 14:51:18 -05:00
|
|
|
placeholder: gettext("slug")
|
2022-11-24 14:31:16 -05:00
|
|
|
) %>
|
2022-11-26 14:51:18 -05:00
|
|
|
<%= error_tag(f, :slug) %>
|
2022-07-25 22:05:54 -04:00
|
|
|
|
2022-11-24 14:31:16 -05:00
|
|
|
<%= textarea(f, :description,
|
|
|
|
id: "pipeline-form-description",
|
|
|
|
class: "input input-primary h-64 min-h-64",
|
|
|
|
phx_hook: "MaintainAttrs",
|
|
|
|
phx_update: "ignore",
|
|
|
|
placeholder: gettext("description")
|
|
|
|
) %>
|
2022-07-25 22:05:54 -04:00
|
|
|
<%= error_tag(f, :description) %>
|
|
|
|
|
2022-11-24 14:31:16 -05:00
|
|
|
<%= text_input(f, :tags_string,
|
|
|
|
id: "tags-input",
|
|
|
|
class: "input input-primary",
|
2022-12-19 22:29:26 -05:00
|
|
|
placeholder: gettext("tag1,tag2")
|
2022-07-25 22:05:54 -04:00
|
|
|
) %>
|
2022-11-24 14:31:16 -05:00
|
|
|
<%= error_tag(f, :tags_string) %>
|
|
|
|
|
|
|
|
<div class="flex justify-center items-stretch space-x-4">
|
|
|
|
<%= select(f, :visibility, Ecto.Enum.values(Memex.Pipelines.Pipeline, :visibility),
|
|
|
|
class: "grow input input-primary",
|
|
|
|
prompt: gettext("select privacy")
|
|
|
|
) %>
|
2022-07-25 22:05:54 -04:00
|
|
|
|
2022-11-24 14:31:16 -05:00
|
|
|
<%= submit(dgettext("actions", "save"),
|
|
|
|
phx_disable_with: gettext("saving..."),
|
|
|
|
class: "mx-auto btn btn-primary"
|
|
|
|
) %>
|
2022-07-25 20:12:11 -04:00
|
|
|
</div>
|
2022-11-24 14:31:16 -05:00
|
|
|
<%= error_tag(f, :visibility) %>
|
2022-07-25 20:12:11 -04:00
|
|
|
</.form>
|
|
|
|
</div>
|