]> git.immae.eu Git - github/wallabag/wallabag.git/commitdiff
Filters view on side for baggy
authorJeremy Benoist <jeremy.benoist@gmail.com>
Tue, 25 Aug 2015 21:24:24 +0000 (23:24 +0200)
committerJeremy Benoist <jeremy.benoist@gmail.com>
Sun, 13 Sep 2015 12:56:34 +0000 (14:56 +0200)
src/Wallabag/CoreBundle/Resources/views/themes/baggy/Entry/entries.html.twig
src/Wallabag/CoreBundle/Resources/views/themes/baggy/public/css/main.css

index 28bf0ab951fc6356e186d366dbcdbf256ddacbad..26cafc42d46bee012dcf9bb549de79dfe6d1264f 100644 (file)
         </div>
     {% endblock %}
 
-    <div id="filter-form" class="messages info popup-form">
-        <form method="get" action="{{ path('all') }}">
-            <h2>{% trans %}Filter{% endtrans %}</h2>
-            <a href="javascript: void(null);" id="filter-form-close" class="close-button--popup close-button">&times;</a>
-            {{ form_rest(form) }}
-            <button class="btn waves-effect waves-light" type="submit" id="submit-filter" value="filter">{% trans %}Filter{% endtrans %}</button>
-        </form>
-    </div>
-
     {% if entries is empty %}
         <div class="messages warning"><p>{% trans %}No articles found.{% endtrans %}</p></div>
     {% else %}
             </div>
         {% endfor %}
     {% endif %}
+
+    <aside id="filter-form" class="">
+        <form method="get" action="{{ path('all') }}">
+            <h2>{% trans %}Filters{% endtrans %}</h2>
+            <a href="javascript: void(null);" id="filter-form-close" class="close-button--popup close-button">&times;</a>
+
+            <div id="filter-status" class="filter-group">
+                <div class="">
+                    <label>{% trans %}Status{% endtrans %}</label>
+                </div>
+                <div class="input-field">
+                    {{ form_widget(form.isArchived) }}
+                    <label for="entry_filter_isArchived">{% trans %}Archived{% endtrans %}</label>
+                </div>
+
+                <div class="input-field">
+                    {{ form_widget(form.isStarred) }}
+                    <label for="entry_filter_isStarred">{% trans %}Starred{% endtrans %}</label>
+                </div>
+            </div>
+            <div id="filter-reading-time" class="filter-group">
+                <div class="">
+                    <label>{% trans %}Reading time in minutes{% endtrans %}</label>
+                </div>
+                <div class="input-field ">
+                    <label for="entry_filter_readingTime_left_number">{% trans %}from{% endtrans %}</label>
+                    {{ form_widget(form.readingTime.left_number, {'type': 'number'}) }}  
+                </div>
+                <div class="input-field ">
+                    <label for="entry_filter_readingTime_right_number">{% trans %}to{% endtrans %}</label>
+                    {{ form_widget(form.readingTime.right_number, {'type': 'number'}) }}
+                </div>
+            </div>
+
+            <div id="filter-domain-name" class="filter-group">
+                <label for="entry_filter_domainName">{% trans %}Domain name{% endtrans %}</label>
+                <div class="input-field ">
+                    {{ form_widget(form.domainName, {'type': 'text', 'attr' : {'placeholder': 'website.com'} }) }}
+                </div>
+            </div>
+
+            <div id="filter-creation-date" class="filter-group">
+                <div class="">
+                    <label>{% trans %}Creation date{% endtrans %}</label>
+                </div>
+                <div class="input-field ">
+                    <label for="entry_filter_createdAt_left_date" class="active">{% trans %}from{% endtrans %}</label>
+                    {{ form_widget(form.createdAt.left_date, {'type': 'date', 'attr': {'class': 'datepicker', 'data-value': form.createdAt.left_date.vars.value} }) }}
+                </div>
+                <div class="input-field ">
+                    <label for="entry_filter_createdAt_right_date" class="active">{% trans %}to{% endtrans %}</label>
+                    {{ form_widget(form.createdAt.right_date, {'type': 'date', 'attr': {'class': 'datepicker', 'data-value': form.createdAt.right_date.vars.value} }) }}
+                </div>
+            </div>
+            <div id="filter-buttons" class="filter-group">
+
+                <div class="">
+                    <a href="#!" class="center waves-effect waves-green btn-flat" id="clear_form_filters">{% trans %}Clear{% endtrans %}</a>
+                </div>
+
+                <button class="btn waves-effect waves-light" type="submit" id="submit-filter" value="filter">{% trans %}Filters{% endtrans %}</button>
+
+                </div>
+        </form>
+    </aside>
+
 {% endblock %}
index dee307f396342f24355b35943f9d0269a43bcdca..16ff2fe2d9862ee516478546ab16fd62383d6a3a 100755 (executable)
@@ -940,16 +940,31 @@ pre code {
 }
 
 #filter-form {
-    margin-top: 30px !important;
-    width: 500px;
-    height: 370px;
-    right: 5em;
-    left: inherit;
+  position: fixed;
+  width: 15%;
+  height: 100%;
+  top: 0;
+  right: 0;
+  background-color: #FFF;
+  padding: 15px;
+  padding-right: 30px;
+  padding-top: 30px;
+
+  z-index: 12;
+
+  /*transition-property: transform;
+  transition-duration: 0.3s;
+  transition-delay: 0.3s;
+  transform: translate3d(100%, 0, 0);*/
 }
 
 #filter-form form {
-    width: 500px;
-    height: 370px;
+    
+}
+
+#filter-form form .filter-group {
+  margin: 5px;
 }