File tree 7 files changed +50
-20
lines changed 7 files changed +50
-20
lines changed Original file line number Diff line number Diff line change 1
1
twig :
2
2
default_path : ' %kernel.project_dir%/templates'
3
+ form_themes : ['form/tailwind.html.twig']
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ const purgecss = require('@fullhuman/postcss-purgecss')({
2
2
3
3
// Specify the paths to all of the template files in your project
4
4
content : [
5
- './templates/**/*.html. twig' ,
5
+ './templates/**/*.twig' ,
6
6
] ,
7
7
8
8
// This is the function used to extract class names from your templates
@@ -15,12 +15,12 @@ const purgecss = require('@fullhuman/postcss-purgecss')({
15
15
16
16
return broadMatches . concat ( innerMatches )
17
17
}
18
- } )
18
+ } ) ;
19
19
20
20
module . exports = {
21
21
plugins : [
22
22
require ( 'tailwindcss' ) ,
23
23
require ( 'autoprefixer' ) ,
24
24
purgecss ,
25
25
]
26
- }
26
+ } ;
Original file line number Diff line number Diff line change
1
+ {% use " form_div_layout.html.twig" %}
2
+
3
+ {# Widgets #}
4
+ {%- block form_widget_simple -%}
5
+ {%- set type = type | default (' text' ) -%}
6
+ {%- if type == ' range' or type == ' color' -%}
7
+ {# Attribute "required" is not supported #}
8
+ {%- set required = false -%}
9
+ {%- endif -%}
10
+ <input class =" bg-gray-400 bg-placeholder-gray-300 border-gray-600 focus:bg-white w-full p-2 rounded" type =" {{ type }}" {{ block (' widget_attributes' ) }} {% if value is not empty %}value =" {{ value }}" {% endif %}/>
11
+ {%- endblock form_widget_simple -%}
12
+
13
+ {%- block form_row -%}
14
+ {%- set widget_attr = {} -%}
15
+ {%- if help is not empty -%}
16
+ {%- set widget_attr = {attr : {' aria-describedby' : id ~" _help" }} -%}
17
+ {%- endif -%}
18
+ <div class =" m-3 pt-3" {% with {attr : row_attr } %}{{ block (' attributes' ) }}{% endwith %}>
19
+ {{- form_label(form ) -}}
20
+ {{- form_errors(form ) -}}
21
+ {{- form_widget(form , widget_attr ) -}}
22
+ {{- form_help(form ) -}}
23
+ </div >
24
+ {%- endblock form_row -%}
Original file line number Diff line number Diff line change 3
3
{% block title %}Password Reset Email Sent{% endblock %}
4
4
5
5
{% block body %}
6
- <p >An email has been sent that contains a link that you can click to reset your password. This link will expire in {{ tokenLifetime | date (' g' ) }} hour(s).</p >
7
- <p >If you don't receive an email please check your spam folder or <a href =" {{ path(' app_forgot_password_request' ) }}" >try again</a >.</p >
6
+ <p class =" text-center" >An email has been sent that contains a link that you can click to reset your password. This link will expire in {{ tokenLifetime | date (' g' ) }} hour(s).</p >
7
+ <p >If you don't receive an email please check your spam folder or
8
+ <a class =" font-bold" href =" {{ path(' app_forgot_password_request' ) }}" >try again</a >.
9
+ </p >
8
10
{% endblock %}
Original file line number Diff line number Diff line change 3
3
{% block title %}Reset your password{% endblock %}
4
4
5
5
{% block body %}
6
- {% for flashError in app.flashes (' reset_password_error' ) %}
7
- <div class =" alert alert-danger" role =" alert" >{{ flashError }}</div >
8
- {% endfor %}
9
- <h1 >Reset your password</h1 >
6
+ <div class =" w-full md:w-1/2 mx-auto" >
7
+ {% for flashError in app.flashes (' reset_password_error' ) %}
8
+ <div class =" bg-red-400 p-3" role =" alert" >{{ flashError }}</div >
9
+ {% endfor %}
10
+ <h1 >Reset your password</h1 >
10
11
11
- {{ form_start(requestForm ) }}
12
+ {{ form_start(requestForm ) }}
12
13
{{ form_row(requestForm .email ) }}
13
- <div >
14
- <small >
15
- Enter your email address and we we will send you a
16
- link to reset your password.
17
- </small >
18
- </div >
19
14
20
- <button class =" btn btn-primary" >Send password reset email</button >
21
- {{ form_end(requestForm ) }}
15
+ <p class =" p-4 m-3 text-gray-500" >
16
+ Enter your email address and we we will send you a
17
+ link to reset your password.
18
+ </p >
19
+ <div class =" text-center" >
20
+ <button class =" bg-green-600 p-3 text-white" >Send password reset email</button >
21
+ {{ form_end(requestForm ) }}
22
+ </div >
23
+ </div >
22
24
{% endblock %}
Original file line number Diff line number Diff line change 7
7
8
8
{{ form_start(resetForm ) }}
9
9
{{ form_row(resetForm .plainPassword ) }}
10
- <button class =" btn btn-primary " >Reset password</button >
10
+ <button class =" " >Reset password</button >
11
11
{{ form_end(resetForm ) }}
12
12
{% endblock %}
Original file line number Diff line number Diff line change @@ -73,9 +73,10 @@ Encore
73
73
//.enableReactPreset()
74
74
//.addEntry('admin', './assets/js/admin.js')
75
75
;
76
+
76
77
Encore . enablePostCssLoader ( function ( options ) {
77
78
options . config = {
78
79
path : 'postcss.config.js'
79
80
}
80
- } )
81
+ } ) ;
81
82
module . exports = Encore . getWebpackConfig ( ) ;
You can’t perform that action at this time.
0 commit comments