diff --git a/app/assets/stylesheets/components/header.scss b/app/assets/stylesheets/components/header.scss index 46992a693..42192c0d8 100644 --- a/app/assets/stylesheets/components/header.scss +++ b/app/assets/stylesheets/components/header.scss @@ -1,18 +1,4 @@ @layer components { - body > header { - @apply flex justify-between px-2 py-2 bg-primary-900 text-white place-items-end; - - .profile-menu { - @apply flex flex-row relative; - :first-child { - @apply pr-0; - } - > * { - @apply px-2; - } - } - } - .flash-message { @apply px-4 py-4; diff --git a/app/views/layouts/_header.html.erb b/app/views/layouts/_header.html.erb index 4e17aa874..69b9af7eb 100644 --- a/app/views/layouts/_header.html.erb +++ b/app/views/layouts/_header.html.erb @@ -1,16 +1 @@ -
- <%= render partial: "breadcrumbs" %> - - -
- <%= render "flash_messages" , flash: flash %> diff --git a/app/views/layouts/application.html.erb b/app/views/layouts/application.html.erb index 845679ce1..bd7788d2d 100644 --- a/app/views/layouts/application.html.erb +++ b/app/views/layouts/application.html.erb @@ -31,23 +31,32 @@ <%- if current_room && policy(current_room).edit? %> <%= link_to t('icons.edit'), [:edit, current_space, current_room], class: 'no-underline', aria: { label: "Configure Section"} %> <%- end %> - <%= render Neighborhood::LinkComponent.new %> - -
- 💾  - <%= link_to "Contribute", "https://github.com/zinc-collective/convene" %> - 💚  - <%= link_to "Sponsor", "https://opencollective.com/zinc-community" %> +
- <%- if current_space&.agreements&.present? %> -
- <%- current_space.agreements.each do |agreement| %> - <%- next unless agreement.persisted? %> - <%= link_to(agreement.name, agreement.location, class: "px-4 py-2") %> +
- <%- end %> + <%= link_to "Sign out", [current_space, :authenticated_session].compact, data: { turbo: true, turbo_method: :delete }, class: "sign-out px-4 py-1" %> + <%- else %> + <%= link_to "Sign in", [:new, current_space, :authenticated_session].compact, class: "px-4 py-1" %> + <%- end %> + + +
+ <%= link_to "💾 Contribute", "https://github.com/zinccollective/convene", class: "px-2 py-1" %> + <%= link_to "💚 Sponsor", "https://opencollective.com/zinccommunity", class: "px-2 py-1" %> + + <%- current_space&.agreements&.each do |agreement| %> + <%- next unless agreement.persisted? %> + <%= link_to(agreement.name, agreement.location, class: "px-2 py-1") %> + <%- end %> +
+
+ <%= render Neighborhood::LinkComponent.new %> +
diff --git a/features/harness/Page.js b/features/harness/Page.js index 84997d43a..d1c8cd269 100644 --- a/features/harness/Page.js +++ b/features/harness/Page.js @@ -23,7 +23,7 @@ class Page { * @returns {PersonNavigationComponent} */ personNavigation() { - return this.component(".profile-menu", PersonNavigationComponent); + return this.component("*[aria-label='Profile Menu']", PersonNavigationComponent); } /** * Goes directly to the page, as defined in the path method. diff --git a/features/lib/Actor.js b/features/lib/Actor.js index 400fdb104..162f95600 100644 --- a/features/lib/Actor.js +++ b/features/lib/Actor.js @@ -65,7 +65,7 @@ class Actor { * @returns {Promise} */ isSignedIn(driver) { - return new PersonNavigationComponent(driver, ".profile-menu") + return new PersonNavigationComponent(driver, "*[aria-label='Profile Menu']") .signedInEmail() .then((email) => this.email == email); }