- <%= render V2::ButtonComponent.new(scheme: :light,
+ <% if current_organization %>
+ <%= render V2::ButtonComponent.new(scheme: :light,
options: edit_accounts_organization_path(current_organization),
type: :link,
size: :xxs) do |b| %>
- <% b.with_tooltip("Organization Settings") %>
- <% b.with_icon("v2/building.svg", size: :md) %>
- <% end %>
-
- <%= render V2::DropdownComponent.new(authz: false) do |dropdown| %>
- <% button = dropdown.with_button(size: :xs) %>
- <% button.with_icon("art/org_default.png", size: :xxl) %>
- <% button.with_title_text do %>
-
-
- <%= current_organization.name %>
-
-
+ <% b.with_tooltip("Organization Settings") %>
+ <% b.with_icon("v2/building.svg", size: :md) %>
<% end %>
-
- <% dropdown.with_item_group do |group| %>
- <% current_user.organizations.each do |organization| %>
- <% group.with_item(link: { path: switch_accounts_organization_path(organization), "data-turbo": false },
- selected: organization.id == current_organization.id) do %>
-
-
- <%= organization.name %>
-
-
-
- Created <%= time_format organization.created_at, with_year: true, with_time: false %>
-
-
- <% end %>
- <% end %>
- <% end %>
- <% end %>
-
- <% if default_app %>
- <%= inline_svg("layer_separator.svg", classname: "w-3 h-3 text-secondary dark:text-secondary-50") %>
-
<%= render V2::DropdownComponent.new(authz: false) do |dropdown| %>
<% button = dropdown.with_button(size: :xs) %>
- <% button.with_icon("art/cross_platform_default.png", size: :xxl, rounded: false) %>
+ <% button.with_icon("art/org_default.png", size: :xxl) %>
<% button.with_title_text do %>
-
- <%= render V2::IconComponent.new("v2/#{default_app.platform}.svg", size: :md) %>
- <%= default_app.name %>
-
- <%= default_app.bundle_identifier %>
-
+
+
+ <%= current_organization.name %>
+
<% end %>
-
<% dropdown.with_item_group do |group| %>
- <% current_organization.apps.filter(&:persisted?).each do |app| %>
- <% group.with_item(link: { path: app_path(app) }, selected: app.id == default_app.id) do %>
+ <% current_user.organizations.each do |organization| %>
+ <% group.with_item(link: { path: switch_accounts_organization_path(organization), "data-turbo": false },
+ selected: organization.id == current_organization.id) do %>
- <%= app.name %>
-
-
- <%= app.bundle_identifier %>
+ <%= organization.name %>
- <%= app.display_attr(:platform) %>
+ Created <%= time_format organization.created_at, with_year: true, with_time: false %>
<% end %>
<% end %>
<% end %>
<% end %>
-
-
- <%= render V2::ButtonComponent.new(scheme: :light,
- options: edit_app_path(default_app),
- type: :link,
- size: :xxs) do |b| %>
- <% b.with_tooltip("App Settings") %>
- <% b.with_icon("v2/cog.svg", size: :md) %>
- <% end %>
-
- <%= render V2::ButtonComponent.new(scheme: :light,
- options: all_builds_app_path(default_app),
- type: :link,
- size: :xxs,
- authz: false) do |b| %>
- <% b.with_tooltip("All Builds") %>
- <% b.with_icon("v2/drill.svg", size: :md) %>
- <% end %>
-
- <%= render V2::ModalComponent.new(title: "Store Status", size: :xs, authz: false) do |modal| %>
- <% button = modal.with_button(scheme: :light, type: :action, size: :xxs, arrow: :none) %>
- <% button.with_tooltip("Store Status") %>
- <% button.with_icon("v2/upload_cloud.svg", size: :md) %>
- <% modal.with_body do %>
- <%= render V2::ExternalAppComponent.new(app: default_app) %>
+ <% if default_app %>
+ <%= inline_svg("layer_separator.svg", classname: "w-3 h-3 text-secondary dark:text-secondary-50") %>
+ <%= render V2::DropdownComponent.new(authz: false) do |dropdown| %>
+ <% button = dropdown.with_button(size: :xs) %>
+ <% button.with_icon("art/cross_platform_default.png", size: :xxl, rounded: false) %>
+ <% button.with_title_text do %>
+
+ <%= render V2::IconComponent.new("v2/#{default_app.platform}.svg", size: :md) %>
+ <%= default_app.name %>
+
+ <%= default_app.bundle_identifier %>
+
+
+ <% end %>
+ <% dropdown.with_item_group do |group| %>
+ <% current_organization.apps.filter(&:persisted?).each do |app| %>
+ <% group.with_item(link: { path: app_path(app) }, selected: app.id == default_app.id) do %>
+
+
+ <%= app.name %>
+
+
+ <%= app.bundle_identifier %>
+
+
+ <%= app.display_attr(:platform) %>
+
+
+ <% end %>
+ <% end %>
+ <% end %>
<% end %>
- <% end %>
-
-
-
- <%= render V2::ModalComponent.new(title: "Add a new app", dismissable: false) do |modal| %>
- <% mb = modal.with_button(scheme: :light, type: :action, size: :xxs) %>
- <% mb.with_tooltip("Add a new app") %>
- <% mb.with_icon("plus.svg", size: :md) %>
- <% modal.with_body do %>
- <%= render partial: "apps/form", locals: { app: new_app } %>
+ <%= render V2::ButtonComponent.new(scheme: :light,
+ options: edit_app_path(default_app),
+ type: :link,
+ size: :xxs) do |b| %>
+ <% b.with_tooltip("App Settings") %>
+ <% b.with_icon("v2/cog.svg", size: :md) %>
+ <% end %>
+ <%= render V2::ButtonComponent.new(scheme: :light,
+ options: all_builds_app_path(default_app),
+ type: :link,
+ size: :xxs,
+ authz: false) do |b| %>
+ <% b.with_tooltip("All Builds") %>
+ <% b.with_icon("v2/drill.svg", size: :md) %>
+ <% end %>
+ <%= render V2::ModalComponent.new(title: "Store Status", size: :xs, authz: false) do |modal| %>
+ <% button = modal.with_button(scheme: :light, type: :action, size: :xxs, arrow: :none) %>
+ <% button.with_tooltip("Store Status") %>
+ <% button.with_icon("v2/upload_cloud.svg", size: :md) %>
+ <% modal.with_body do %>
+ <%= render V2::ExternalAppComponent.new(app: default_app) %>
+ <% end %>
+ <% end %>
+
+ <%= render V2::ModalComponent.new(title: "Add a new app", dismissable: false) do |modal| %>
+ <% mb = modal.with_button(scheme: :light, type: :action, size: :xxs) %>
+ <% mb.with_tooltip("Add a new app") %>
+ <% mb.with_icon("plus.svg", size: :md) %>
+ <% modal.with_body do %>
+ <%= render partial: "apps/form", locals: { app: new_app } %>
+ <% end %>
<% end %>
<% end %>
+ <% else %>
+
+ You are not a member of any organization
+
<% end %>