diff --git a/majak_uistyleguide/static/images/captcha.png b/majak_uistyleguide/static/images/captcha.png new file mode 100644 index 0000000000000000000000000000000000000000..9b27637459d390e9b46d9a7a2b523ba221a7d24e Binary files /dev/null and b/majak_uistyleguide/static/images/captcha.png differ diff --git a/majak_uistyleguide/templates/patterns/atoms/form_fields/form_captcha.html b/majak_uistyleguide/templates/patterns/atoms/form_fields/form_captcha.html new file mode 100644 index 0000000000000000000000000000000000000000..7f8b53a2acd8c7df8f7f6cc2d384ae2f96e3c13f --- /dev/null +++ b/majak_uistyleguide/templates/patterns/atoms/form_fields/form_captcha.html @@ -0,0 +1,8 @@ +<div class="flex gap-3 w-full"> + <img + src="/static/images/captcha.png" + alt="Captcha obrázek" + > + + {% include "patterns/atoms/form_fields/form_input.html" with placeholder=placeholder label='' hint='' extra_classes='lg:!w-full' %} +</div> \ No newline at end of file diff --git a/majak_uistyleguide/templates/patterns/atoms/form_fields/form_captcha.yaml b/majak_uistyleguide/templates/patterns/atoms/form_fields/form_captcha.yaml new file mode 100644 index 0000000000000000000000000000000000000000..e817578f06c44af790cf14b482cfc4921036cb2d --- /dev/null +++ b/majak_uistyleguide/templates/patterns/atoms/form_fields/form_captcha.yaml @@ -0,0 +1,2 @@ +context: + placeholder: 'Kód z obrázku' \ No newline at end of file diff --git a/majak_uistyleguide/templates/patterns/atoms/form_fields/form_input.yaml b/majak_uistyleguide/templates/patterns/atoms/form_fields/form_input.yaml index ec3dc507b747a9f4bc7558378474c33b7556527e..8f0d299a92c925c198acc4be7d96ac11ffdcdc25 100644 --- a/majak_uistyleguide/templates/patterns/atoms/form_fields/form_input.yaml +++ b/majak_uistyleguide/templates/patterns/atoms/form_fields/form_input.yaml @@ -1,7 +1,7 @@ context: - placeholder: 'Pirát Pepa' - hint: 'Hlavně žádné osobní údaje.' + placeholder: '' + hint: '' name: 'example' - is_required: true + is_required: false extra_classes: '' - label: 'Jméno' \ No newline at end of file + label: '' \ No newline at end of file diff --git a/majak_uistyleguide/templates/patterns/atoms/form_fields/form_text.html b/majak_uistyleguide/templates/patterns/atoms/form_fields/form_text.html new file mode 100644 index 0000000000000000000000000000000000000000..b6e5bf204854dfb33494215a75f35190083e7a62 --- /dev/null +++ b/majak_uistyleguide/templates/patterns/atoms/form_fields/form_text.html @@ -0,0 +1 @@ +{% extends "patterns/atoms/form_fields/form_input.html" %} \ No newline at end of file diff --git a/majak_uistyleguide/templates/patterns/atoms/form_fields/form_text.yaml b/majak_uistyleguide/templates/patterns/atoms/form_fields/form_text.yaml new file mode 100644 index 0000000000000000000000000000000000000000..8b16856b5e4e6ddd10c17511fd12cfd109868944 --- /dev/null +++ b/majak_uistyleguide/templates/patterns/atoms/form_fields/form_text.yaml @@ -0,0 +1,5 @@ +context: + label: 'Jméno' + placeholder: 'Pirát Pepa' + hint: 'Hlavně žádné osobní údaje.' + id: 'name_1' \ No newline at end of file diff --git a/majak_uistyleguide/templates/patterns/templates/uniweb/form.html b/majak_uistyleguide/templates/patterns/templates/uniweb/form.html index 812af91c85443db3b16936c1d25d89dbadf2dd03..8076f5cec61a719251942ab442e66cc12beb952e 100644 --- a/majak_uistyleguide/templates/patterns/templates/uniweb/form.html +++ b/majak_uistyleguide/templates/patterns/templates/uniweb/form.html @@ -3,7 +3,7 @@ <main role="main" class="mb-10 xl:mb-32"> <div class="container--wide flex flex-col gap-8 mb-2 lg:mb-12"> - {% include "patterns/atoms/form_fields/form_input.html" %} + {% include "patterns/atoms/form_fields/form_text.html" %} {% include "patterns/atoms/form_fields/form_date.html" %} {% include "patterns/atoms/form_fields/form_datetime.html" %} {% include "patterns/atoms/form_fields/form_email.html" %} @@ -13,6 +13,7 @@ {% include "patterns/atoms/form_fields/form_multiselect.html" %} {% include "patterns/atoms/form_fields/form_textarea.html" %} {% include "patterns/atoms/form_fields/form_checkbox.html" %} + {% include "patterns/atoms/form_fields/form_captcha.html" %} {% comment %} {% if field.widget_type == "select" %}