From c158ad0b682e008fadba120c024e4e9517d77756 Mon Sep 17 00:00:00 2001 From: Tristan Date: Thu, 7 Jun 2018 00:52:16 -0500 Subject: [PATCH] add autocomplete indicators + helpful tooltip --- app/assets/stylesheets/content.css.scss | 6 +----- app/views/content/form/_text_input.html.erb | 9 ++++++++- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/app/assets/stylesheets/content.css.scss b/app/assets/stylesheets/content.css.scss index 7c03e50a..570f9c2c 100644 --- a/app/assets/stylesheets/content.css.scss +++ b/app/assets/stylesheets/content.css.scss @@ -77,10 +77,6 @@ p.long-form { } } -.autocomplete-content { - position: absolute !important; -} - .spaced-paragraphs { p { margin-bottom: 18px !important; @@ -94,4 +90,4 @@ p.long-form { } margin-bottom: 30px; -} \ No newline at end of file +} diff --git a/app/views/content/form/_text_input.html.erb b/app/views/content/form/_text_input.html.erb index 0aa30300..5bcc645c 100644 --- a/app/views/content/form/_text_input.html.erb +++ b/app/views/content/form/_text_input.html.erb @@ -11,7 +11,14 @@ %>
- <%= f.label field.label.present? ? field.label : ' ' %> + <%= f.label field do %> + <%= field.label.present? ? field.label : ' ' %> + <% if defined?(autocomplete) %> + + offline_bolt + + <% end %> + <% end %> <% placeholder = I18n.translate "attributes.#{content_name}.#{field.name}", scope: :serendipitous_questions,