mirror of
https://github.com/ClaperCo/Claper.git
synced 2026-09-01 19:49:11 +02:00
Format code
This commit is contained in:
@@ -149,7 +149,7 @@
|
||||
</.detail_row>
|
||||
</.detail_card>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Transcriptions Section -->
|
||||
<div class="mt-6">
|
||||
<div class="card bg-base-100 shadow-xl">
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
</div>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- API Key -->
|
||||
<div :if={@transcription_enabled} class="form-control mb-6">
|
||||
<label class="label">
|
||||
@@ -70,7 +70,7 @@
|
||||
</span>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Default Language -->
|
||||
<div :if={@transcription_enabled} class="form-control mb-6">
|
||||
<label class="label">
|
||||
@@ -89,7 +89,7 @@
|
||||
</span>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Submit -->
|
||||
<div class="card-actions justify-end">
|
||||
<button type="submit" class="btn btn-primary">
|
||||
|
||||
@@ -52,7 +52,7 @@ defmodule ClaperWeb.EventLive.EventCardComponent do
|
||||
<span class="text-sm font-medium text-gray-600">{gettext("Processing...")}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Status Badge -->
|
||||
<div class="absolute top-4 left-4 z-10">
|
||||
<%= if Event.started?(@event) && !Event.finished?(@event) do %>
|
||||
@@ -72,7 +72,7 @@ defmodule ClaperWeb.EventLive.EventCardComponent do
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- LTI Badge -->
|
||||
<div :if={@event.lti_resource} class="absolute top-4 right-4 z-10">
|
||||
<span class="badge badge-neutral gap-1">
|
||||
@@ -91,7 +91,7 @@ defmodule ClaperWeb.EventLive.EventCardComponent do
|
||||
LTI
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Sliding Bottom Panel -->
|
||||
<div class="absolute bottom-0 left-0 right-0 bg-white transition-transform duration-300 ease-out z-20 translate-y-14 group-hover:translate-y-0 group-focus-within:translate-y-0">
|
||||
<!-- Card Body (Title, Code, Menu) -->
|
||||
@@ -105,7 +105,7 @@ defmodule ClaperWeb.EventLive.EventCardComponent do
|
||||
# {@event.code}
|
||||
</p>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- 3-dot Menu -->
|
||||
<div :if={not @is_leader} class="relative shrink-0">
|
||||
<button
|
||||
@@ -135,7 +135,7 @@ defmodule ClaperWeb.EventLive.EventCardComponent do
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Action Buttons (revealed on hover) -->
|
||||
<div
|
||||
:if={@event.presentation_file.status == "done" && !Event.finished?(@event)}
|
||||
@@ -247,14 +247,14 @@ defmodule ClaperWeb.EventLive.EventCardComponent do
|
||||
{gettext("End Event")}
|
||||
</.link>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Error Status -->
|
||||
<div :if={@event.presentation_file.status == "fail"} class="px-2 pb-2">
|
||||
<span class="text-sm text-supporting-red-500">
|
||||
{gettext("Error when processing the file")}
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Finished Event Actions -->
|
||||
<div :if={Event.finished?(@event)} class="px-2 pb-2">
|
||||
<a href={~p"/events/#{@event.uuid}/stats"} class="btn btn-primary w-full">
|
||||
@@ -297,7 +297,7 @@ defmodule ClaperWeb.EventLive.EventCardComponent do
|
||||
<img src="/images/logo.svg" class="h-6 animate-pulse" alt="Loading" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Event Info -->
|
||||
<div class="min-w-0">
|
||||
<div class="flex items-center gap-2">
|
||||
@@ -353,7 +353,7 @@ defmodule ClaperWeb.EventLive.EventCardComponent do
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Actions -->
|
||||
<div class="flex items-center gap-2 ml-auto">
|
||||
<%= if @event.presentation_file.status == "done" && !Event.finished?(@event) do %>
|
||||
@@ -491,7 +491,7 @@ defmodule ClaperWeb.EventLive.EventCardComponent do
|
||||
{gettext("View report")}
|
||||
</a>
|
||||
<% end %>
|
||||
|
||||
|
||||
<!-- 3-dot Menu -->
|
||||
<div :if={not @is_leader} class="relative">
|
||||
<button
|
||||
@@ -550,7 +550,7 @@ defmodule ClaperWeb.EventLive.EventCardComponent do
|
||||
<img src="/images/logo.svg" class="h-8 animate-pulse" alt="Loading" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Event Info -->
|
||||
<div class="flex-1 min-w-0 py-1">
|
||||
<h3 class="font-semibold text-gray-800 text-lg leading-tight truncate">
|
||||
@@ -577,7 +577,7 @@ defmodule ClaperWeb.EventLive.EventCardComponent do
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- 3-dot Menu -->
|
||||
<div :if={not @is_leader} class="relative shrink-0">
|
||||
<button
|
||||
@@ -606,7 +606,7 @@ defmodule ClaperWeb.EventLive.EventCardComponent do
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Bottom Row: Action Buttons -->
|
||||
<div class="flex gap-2">
|
||||
<%= if @event.presentation_file.status == "done" && !Event.finished?(@event) do %>
|
||||
|
||||
@@ -56,7 +56,7 @@
|
||||
</:tab>
|
||||
</.tabs>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Desktop: Full layout with tabs, view toggle, and action buttons -->
|
||||
<div class="hidden lg:flex items-center justify-between gap-4">
|
||||
<!-- Left: Filter Tabs -->
|
||||
@@ -85,7 +85,7 @@
|
||||
{gettext("Shared with you")}
|
||||
</:tab>
|
||||
</.tabs>
|
||||
|
||||
|
||||
<!-- Right: View Toggle & Action Buttons -->
|
||||
<div class="flex items-center gap-2 flex-wrap">
|
||||
<!-- View Toggle -->
|
||||
@@ -131,7 +131,7 @@
|
||||
</svg>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Create Event Button -->
|
||||
<.link patch={~p"/events/new"} class="btn btn-gradient">
|
||||
<svg
|
||||
@@ -151,7 +151,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Events Grid/List -->
|
||||
<div class="relative">
|
||||
<!-- Mobile: Always list view -->
|
||||
@@ -168,7 +168,7 @@
|
||||
/>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Desktop: Grid or List based on view_mode -->
|
||||
<%= if @view_mode == "grid" do %>
|
||||
<!-- Grid View -->
|
||||
@@ -205,7 +205,7 @@
|
||||
<% end %>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
|
||||
<!-- Load More Button -->
|
||||
<%= if @page < @total_pages do %>
|
||||
<div class="flex justify-center my-8">
|
||||
@@ -214,7 +214,7 @@
|
||||
</button>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
|
||||
<!-- Empty State -->
|
||||
<%= if Enum.count(@events) == 0 do %>
|
||||
<div class="w-full py-16 text-center">
|
||||
@@ -251,7 +251,7 @@
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Mobile Fixed Bottom Action Buttons -->
|
||||
<div class="lg:hidden fixed bottom-0 left-0 right-0 bg-gradient-to-t from-white from-70% via-white via-85% to-transparent px-4 pt-12 pb-6 z-20">
|
||||
<div class="flex flex-col gap-2.5">
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
<button>close</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Interaction Modal -->
|
||||
<div
|
||||
:if={@interaction_modal}
|
||||
@@ -379,7 +379,7 @@
|
||||
<button>close</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Header Bar -->
|
||||
<header class="flex-shrink-0 flex items-center justify-between px-4 lg:px-8 py-5 bg-white">
|
||||
<!-- Left: Back button, Title, and Code Badge -->
|
||||
@@ -411,12 +411,12 @@
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Center: Logo -->
|
||||
<div class="hidden md:flex items-center justify-center absolute left-1/2 -translate-x-1/2 bg-white rounded-full p-2">
|
||||
<img src="/images/logo.svg" alt="Claper" class="h-8" />
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Right: Action Buttons -->
|
||||
<div class="bg-white p-1 rounded-full shadow-lg flex items-center gap-x-2">
|
||||
<button
|
||||
@@ -505,7 +505,7 @@
|
||||
</button>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
|
||||
<!-- Main Content Area - Three Column Layout -->
|
||||
<div id="wrapper" class="flex-1 flex overflow-hidden">
|
||||
<!-- Left Sidebar - Slide Thumbnails -->
|
||||
@@ -521,7 +521,7 @@
|
||||
thumbnail_cache_bust={@thumbnail_cache_bust}
|
||||
/>
|
||||
</aside>
|
||||
|
||||
|
||||
<!-- Center Content -->
|
||||
<main class="flex-1 flex flex-col min-w-0 overflow-hidden bg-white">
|
||||
<!-- Slide Preview (only if presentation has slides) -->
|
||||
@@ -536,7 +536,7 @@
|
||||
thumbnail_regeneration_in_progress={@thumbnail_regeneration_in_progress}
|
||||
/>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Bottom Section - Interactions & Options -->
|
||||
<div class="flex-1 flex flex-col lg:flex-row overflow-y-auto lg:overflow-hidden">
|
||||
<!-- Interactions Panel -->
|
||||
@@ -550,7 +550,7 @@
|
||||
transcription_globally_enabled={@transcription_globally_enabled}
|
||||
/>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Audience Responses Panel -->
|
||||
<div class="min-h-[400px] lg:min-h-0 flex-1 flex flex-col overflow-hidden p-4">
|
||||
<ClaperWeb.EventLive.ManageAudienceResponsesComponent.render
|
||||
@@ -565,7 +565,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
|
||||
<!-- Right Sidebar - Settings -->
|
||||
<aside class="hidden xl:flex w-80 flex-shrink-0 flex-col overflow-hidden bg-white">
|
||||
<div class="flex-1 overflow-y-auto">
|
||||
|
||||
@@ -31,7 +31,7 @@ defmodule ClaperWeb.EventLive.ManageAudienceResponsesComponent do
|
||||
</svg>
|
||||
<span class="font-bold text-sm text-[#140553]">{gettext("Audience Responses")}</span>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Tabs -->
|
||||
<ul id="menu" phx-update="replace" class="flex items-center gap-x-1 overflow-x-auto">
|
||||
<li>
|
||||
@@ -71,7 +71,7 @@ defmodule ClaperWeb.EventLive.ManageAudienceResponsesComponent do
|
||||
</button>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
<!-- Tab Content -->
|
||||
<div class="flex-1 overflow-y-auto overflow-x-hidden">
|
||||
<%= if @list_tab == :posts do %>
|
||||
|
||||
@@ -32,7 +32,7 @@ defmodule ClaperWeb.EventLive.ManageablePostComponent do
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Right: header + bubble -->
|
||||
<div class="flex-1 min-w-0 flex flex-col">
|
||||
<!-- Header: name + actions -->
|
||||
@@ -40,7 +40,7 @@ defmodule ClaperWeb.EventLive.ManageablePostComponent do
|
||||
<p :if={@post.name} class="font-bold text-xs text-gray-700 truncate">
|
||||
{@post.name}
|
||||
</p>
|
||||
|
||||
|
||||
<!-- Actions (visible on hover) -->
|
||||
<div
|
||||
:if={!@readonly}
|
||||
@@ -167,7 +167,7 @@ defmodule ClaperWeb.EventLive.ManageablePostComponent do
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Message bubble with tail -->
|
||||
<% is_question = ClaperWeb.Helpers.body_without_links(@post.body) =~ "?" %>
|
||||
<% bubble_bg =
|
||||
|
||||
@@ -239,7 +239,7 @@
|
||||
phx-update="ignore"
|
||||
>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- ONLINE BADGE -->
|
||||
<div
|
||||
:if={!@iframe && @state.show_attendee_count}
|
||||
|
||||
@@ -268,7 +268,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Preferences Card -->
|
||||
<div class="card bg-base-100 shadow-md">
|
||||
<div class="card-body">
|
||||
@@ -332,7 +332,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Linked Accounts Card -->
|
||||
<div :if={@is_external_user} class="card bg-base-100 shadow-md">
|
||||
<div class="card-body">
|
||||
@@ -422,7 +422,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Danger Zone Card -->
|
||||
<div :if={!@is_external_user} class="card bg-base-100 shadow-md border border-error/20">
|
||||
<div class="card-body">
|
||||
|
||||
@@ -13,14 +13,14 @@
|
||||
<a href={~p"/events"} class="shrink-0 bg-white p-2 rounded-full shadow-md">
|
||||
<img src="/images/logo.svg" class="h-4" alt="Claper" />
|
||||
</a>
|
||||
|
||||
|
||||
<!-- Title -->
|
||||
<h1 class="text-base font-bold text-secondary-500 capitalize">
|
||||
{if String.starts_with?(@conn.request_path, "/users/settings"),
|
||||
do: gettext("My account"),
|
||||
else: gettext("My events")}
|
||||
</h1>
|
||||
|
||||
|
||||
<!-- User Menu -->
|
||||
<div class="dropdown dropdown-end shrink-0 bg-white p-1 shadow-md rounded-full">
|
||||
<div
|
||||
@@ -58,14 +58,14 @@
|
||||
<a href={~p"/events"} class="shrink-0 bg-white p-2 rounded-full shadow-md">
|
||||
<img src="/images/logo.svg" class="h-5" alt="Claper" />
|
||||
</a>
|
||||
|
||||
|
||||
<!-- Title -->
|
||||
<h1 class="text-2xl font-bold text-secondary-500 capitalize shrink-0">
|
||||
{if String.starts_with?(@conn.request_path, "/users/settings"),
|
||||
do: gettext("My account"),
|
||||
else: gettext("My events")}
|
||||
</h1>
|
||||
|
||||
|
||||
<!-- Search Bar (only on events page) -->
|
||||
<%= if @conn.request_path == "/events" do %>
|
||||
<div class="flex-1 max-w-md">
|
||||
@@ -96,10 +96,10 @@
|
||||
</form>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
|
||||
<!-- Spacer -->
|
||||
<div class="flex-1"></div>
|
||||
|
||||
|
||||
<!-- User Menu -->
|
||||
<div class="dropdown dropdown-end shrink-0 bg-white p-1 shadow-md rounded-full">
|
||||
<div
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Page content -->
|
||||
<main class="flex-1 overflow-y-auto bg-base-200 p-4 lg:p-6">
|
||||
<div class="toast toast-bottom toast-center z-50">
|
||||
@@ -45,7 +45,7 @@
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Sidebar -->
|
||||
<div class="drawer-side">
|
||||
<label for="drawer-toggle" class="drawer-overlay"></label>
|
||||
|
||||
Reference in New Issue
Block a user