From bec82833996a3f10354272c37619939e05bb44bb Mon Sep 17 00:00:00 2001 From: Rajat Talesra Date: Tue, 20 Dec 2022 11:48:33 +0530 Subject: [PATCH] Remove bootstrap from admin/consumer_apps & admin/welcome and use Crayons (#18861) * Removed bootstrap from admin/consumer_apps * Removed bootstrap from admin/weclome * Nit fix * Minor design fix --- app/views/admin/consumer_apps/_form.html.erb | 32 +++++++++++--------- app/views/admin/consumer_apps/edit.html.erb | 2 +- app/views/admin/consumer_apps/index.html.erb | 6 ++-- app/views/admin/consumer_apps/new.html.erb | 2 +- app/views/admin/welcome/index.html.erb | 2 +- 5 files changed, 24 insertions(+), 20 deletions(-) diff --git a/app/views/admin/consumer_apps/_form.html.erb b/app/views/admin/consumer_apps/_form.html.erb index e20f05401..b924dc5a5 100644 --- a/app/views/admin/consumer_apps/_form.html.erb +++ b/app/views/admin/consumer_apps/_form.html.erb @@ -1,19 +1,21 @@ -
- <%= label_tag :app_bundle, "App Bundle:" %> - <%= text_field_tag :app_bundle, @app.app_bundle, class: "form-control" %> -
+
+
+ <%= label_tag :app_bundle, "App Bundle:", class: "crayons-field__label" %> + <%= text_field_tag :app_bundle, @app.app_bundle, class: "crayons-textfield" %> +
-
- <%= label_tag :platform, "Platform:" %> - <%= select_tag :platform, options_for_select(ConsumerApp.platforms.invert, selected: @app.platform, class: "crayons-select"), class: "crayons-select", data: { "consumer-app-target" => "platform", "action" => "consumer-app#checkPlatform" } %> -
+
+ <%= label_tag :platform, "Platform:", class: "crayons-field_label" %> + <%= select_tag :platform, options_for_select(ConsumerApp.platforms.invert, selected: @app.platform), class: "crayons-select", data: { "consumer-app-target" => "platform", "action" => "consumer-app#checkPlatform" } %> +
-
- <%= label_tag :auth_key, "Authentication Key:" %> - <%= text_area_tag :auth_key, @app.auth_key, size: "100x10", class: "form-control" %> -
+
+ <%= label_tag :auth_key, "Authentication Key:", class: "crayons-field__label" %> + <%= text_area_tag :auth_key, @app.auth_key, size: "100x10", class: "crayons-textfield" %> +
- diff --git a/app/views/admin/consumer_apps/edit.html.erb b/app/views/admin/consumer_apps/edit.html.erb index a230d1d83..e88e72eb0 100644 --- a/app/views/admin/consumer_apps/edit.html.erb +++ b/app/views/admin/consumer_apps/edit.html.erb @@ -2,6 +2,6 @@
<%= form_for([:admin, @app], method: :patch, data: { controller: "consumer-app" }) do %> <%= render "form" %> - <%= submit_tag "Update Consumer App", class: "crayons-btn" %> + <%= submit_tag "Update Consumer App", class: "crayons-btn mt-4" %> <% end %>
diff --git a/app/views/admin/consumer_apps/index.html.erb b/app/views/admin/consumer_apps/index.html.erb index 515bcede1..001290b34 100644 --- a/app/views/admin/consumer_apps/index.html.erb +++ b/app/views/admin/consumer_apps/index.html.erb @@ -1,7 +1,9 @@
- <%= link_to "New Consumer App", new_admin_consumer_app_path, class: "crayons-btn float-right" %> -

Consumer Apps

+
+

Consumer Apps

+ New Consumer App +

Consumer apps are standalone mobile apps that users can use to browse <%= Settings::Community.community_name %> as an alternative to web browsers. diff --git a/app/views/admin/consumer_apps/new.html.erb b/app/views/admin/consumer_apps/new.html.erb index f37999be2..ede414d97 100644 --- a/app/views/admin/consumer_apps/new.html.erb +++ b/app/views/admin/consumer_apps/new.html.erb @@ -2,6 +2,6 @@

<%= form_for([:admin, @app], method: :post, data: { controller: "consumer-app" }) do %> <%= render "form" %> - <%= submit_tag "Create Consumer App", class: "crayons-btn" %> + <%= submit_tag "Create Consumer App", class: "crayons-btn mt-4" %> <% end %>
diff --git a/app/views/admin/welcome/index.html.erb b/app/views/admin/welcome/index.html.erb index 0d5e1236f..ad8b85300 100644 --- a/app/views/admin/welcome/index.html.erb +++ b/app/views/admin/welcome/index.html.erb @@ -3,7 +3,7 @@

Welcome Threads

- <%= link_to "Create A New Welcome Thread", admin_welcome_index_path, method: :post, class: "btn btn-primary ml-auto" %> + <%= link_to "Create A New Welcome Thread", admin_welcome_index_path, method: :post, class: "crayons-btn ml-auto" %>