diff --git a/app/assets/stylesheets/application.scss.erb b/app/assets/stylesheets/application.scss.erb
index a63b9e3c..dffd756d 100644
--- a/app/assets/stylesheets/application.scss.erb
+++ b/app/assets/stylesheets/application.scss.erb
@@ -827,6 +827,9 @@ label {
.accountAdmin .accountIcon {
background-position: 0 -32px;
}
+.accountApps .accountIcon {
+ background-position: 0 -32px;
+}
.accountInvite .accountIcon {
background-position: 0 -64px;
}
diff --git a/app/assets/stylesheets/clean.css.erb b/app/assets/stylesheets/clean.css.erb
index 6eee644e..42a0aef7 100644
--- a/app/assets/stylesheets/clean.css.erb
+++ b/app/assets/stylesheets/clean.css.erb
@@ -753,6 +753,11 @@
top:5px;
left:5px;
}
+
+.exploreMapsCenter .authedApps .exploreMapsIcon {
+ background-image: url(<%= asset_data_uri('user_sprite.png') %>);
+ background-position: 0 -32px;
+}
.exploreMapsCenter .myMaps .exploreMapsIcon {
background-image: url(<%= asset_path 'exploremaps_sprite.png' %>);
background-position: -32px 0;
@@ -773,6 +778,9 @@
background-image: url(<%= asset_path 'exploremaps_sprite.png' %>);
background-position: -96px 0;
}
+.authedApps:hover .exploreMapsIcon, .authedApps.active .exploreMapsIcon {
+ background-position-x: -32px;
+}
.myMaps:hover .exploreMapsIcon, .myMaps.active .exploreMapsIcon {
background-position: -32px -32px;
}
diff --git a/app/controllers/users/sessions_controller.rb b/app/controllers/users/sessions_controller.rb
index d2daa38c..fed670ae 100644
--- a/app/controllers/users/sessions_controller.rb
+++ b/app/controllers/users/sessions_controller.rb
@@ -1,2 +1,14 @@
class Users::SessionsController < Devise::SessionsController
+ protected
+
+ def after_sign_in_path_for(resource)
+ stored = stored_location_for(User)
+ return stored if stored
+
+ if request.referer&.match(sign_in_url) || request.referer&.match(sign_up_url)
+ super
+ else
+ request.referer || root_path
+ end
+ end
end
diff --git a/app/views/doorkeeper/authorized_applications/index.html.erb b/app/views/doorkeeper/authorized_applications/index.html.erb
index 0464c2be..42c3127d 100644
--- a/app/views/doorkeeper/authorized_applications/index.html.erb
+++ b/app/views/doorkeeper/authorized_applications/index.html.erb
@@ -5,6 +5,12 @@
+
+ Coming soon!
+ There are a number of apps being worked on for Metamaps currently, including the playful Metamapper Slack Bot. Check back here for updates.
+ If you're a developer interested in building an app for Metamaps, check out
the API docs.
+
+ <% if @applications.count > 0 %>
@@ -24,6 +30,7 @@
<% end %>
+ <% end %>
diff --git a/app/views/layouts/_account.html.erb b/app/views/layouts/_account.html.erb
index 0b20cf4c..748e5f1b 100644
--- a/app/views/layouts/_account.html.erb
+++ b/app/views/layouts/_account.html.erb
@@ -22,6 +22,10 @@
Share Invite
+
+
+ <%= link_to "Apps", oauth_authorized_applications_path %>
+
<%= link_to "Sign Out", "/logout", id: "Logout" %>
diff --git a/app/views/layouts/doorkeeper.html.erb b/app/views/layouts/doorkeeper.html.erb
index b39730da..500a0f0e 100644
--- a/app/views/layouts/doorkeeper.html.erb
+++ b/app/views/layouts/doorkeeper.html.erb
@@ -9,14 +9,10 @@
- <% if devise_error_messages? %>
- <%= devise_error_messages! %>
- <% elsif notice %>
- <%= notice %>
- <% end %>
+
<%= content_tag :div, class: "main" do %>
-
+
<% if params[:controller] == 'doorkeeper/applications' || params[:controller] == 'doorkeeper/authorized_applications'
classes = 'appsPage'
else
@@ -30,24 +26,16 @@
<%= yield %>
-
- <% if current_user %>
- <% # for creating and pulling in topics and synapses %>
- <%= render :partial => 'maps/newtopic' %>
- <%= render :partial => 'maps/newsynapse' %>
- <% # for populating the change metacode list on the topic card %>
- <%= render :partial => 'shared/metacodeoptions' %>
- <% end %>
- <%= render :partial => 'layouts/lowermapelements' %>
-