Open the title field for editing after creating a new bubble
This commit is contained in:
@@ -330,6 +330,11 @@
|
||||
color: var(--splat-color);
|
||||
}
|
||||
|
||||
textarea::selection {
|
||||
background-color: var(--bubble-color);
|
||||
color: var(--color-ink-reversed);
|
||||
}
|
||||
|
||||
@media (hover: hover) {
|
||||
.bubble:has(.bubble__image img:not([src=""])):hover & {
|
||||
color: var(--color-ink-reversed);
|
||||
|
||||
@@ -12,7 +12,7 @@ class BubblesController < ApplicationController
|
||||
|
||||
def create
|
||||
@bubble = @bucket.bubbles.create!
|
||||
redirect_to @bubble
|
||||
redirect_to bucket_bubble_path(@bubble.bucket, @bubble, editing: true)
|
||||
end
|
||||
|
||||
def show
|
||||
|
||||
@@ -6,12 +6,16 @@
|
||||
|
||||
<div>
|
||||
<h1 class="bubble__title">
|
||||
<%= turbo_frame_tag bubble, :edit do %>
|
||||
<%= link_to bubble.title, edit_bucket_bubble_path(bubble.bucket, bubble), class: "txt-undecorated" %>
|
||||
<% if local_assigns[:editing] %>
|
||||
<%= turbo_frame_tag bubble, :edit, src: edit_bucket_bubble_path(bubble.bucket, bubble) %>
|
||||
<% else %>
|
||||
<%= turbo_frame_tag bubble, :edit do %>
|
||||
<%= link_to bubble.title, edit_bucket_bubble_path(bubble.bucket, bubble), class: "txt-undecorated" %>
|
||||
|
||||
<div class="bubble__tags flex flex-wrap align-end justify-center gap-half txt-tight-lines">
|
||||
<%= render "bubbles/tags", bubble: bubble %>
|
||||
</div>
|
||||
<div class="bubble__tags flex flex-wrap align-end justify-center gap-half txt-tight-lines">
|
||||
<%= render "bubbles/tags", bubble: bubble %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</h1>
|
||||
</div>
|
||||
|
||||
@@ -61,7 +61,7 @@
|
||||
|
||||
<div class="bubble__container">
|
||||
<div class="bubble__perma flex justify-center center margin-block-end-double">
|
||||
<%= render "bubbles/bubble", bubble: @bubble %>
|
||||
<%= render "bubbles/bubble", bubble: @bubble, editing: params[:editing] %>
|
||||
</div>
|
||||
|
||||
<%= render "bubbles/messages", bubble: @bubble %>
|
||||
|
||||
Reference in New Issue
Block a user