diff --git a/app/assets/images/37signals.svg b/app/assets/images/37signals.svg new file mode 100644 index 000000000..8ff6c3bb8 --- /dev/null +++ b/app/assets/images/37signals.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/app/assets/stylesheets/cards.css b/app/assets/stylesheets/cards.css index 38213e31e..c32dc74c5 100644 --- a/app/assets/stylesheets/cards.css +++ b/app/assets/stylesheets/cards.css @@ -188,7 +188,7 @@ .card-field__description { lexxy-toolbar { border-block-start: 1px solid var(--color-ink-light); - margin-block-start: var(--block-margin) !important; + margin-block-start: var(--block-space-half) !important; } } diff --git a/app/assets/stylesheets/icons.css b/app/assets/stylesheets/icons.css index e3e7a40fe..61e140007 100644 --- a/app/assets/stylesheets/icons.css +++ b/app/assets/stylesheets/icons.css @@ -18,6 +18,7 @@ background: none; } + .icon--37signals { --svg: url("37signals.svg"); } .icon--add { --svg: url("add.svg "); } .icon--add--meta { --svg: url("add--meta.svg "); } .icon--arrow-left { --svg: url("arrow-left.svg "); } diff --git a/app/assets/stylesheets/rich-text-content.css b/app/assets/stylesheets/rich-text-content.css index 873ad8cd9..27f265a03 100644 --- a/app/assets/stylesheets/rich-text-content.css +++ b/app/assets/stylesheets/rich-text-content.css @@ -5,7 +5,6 @@ :where(h1, h2, h3, h4, h5, h6) { display: block; font-weight: 800; - hyphens: auto; letter-spacing: -0.02ch; line-height: 1.1; margin-block: var(--block-margin); @@ -34,7 +33,6 @@ } :where(p, blockquote) { - hyphens: auto; letter-spacing: -0.005ch; } @@ -79,7 +77,6 @@ &[data-language] { border-radius: 0.5em; display: block; - hyphens: none; overflow-x: auto; padding: 0.5lh 2ch; tab-size: 2; diff --git a/app/controllers/cards/publishes_controller.rb b/app/controllers/cards/publishes_controller.rb index 298f8bbe4..9aeab76ce 100644 --- a/app/controllers/cards/publishes_controller.rb +++ b/app/controllers/cards/publishes_controller.rb @@ -7,7 +7,7 @@ class Cards::PublishesController < ApplicationController if add_another_param? redirect_to @collection.cards.create!, notice: "Card added" else - redirect_to @card + redirect_to @card.collection end end diff --git a/app/controllers/cards_controller.rb b/app/controllers/cards_controller.rb index 9a0d5d19c..9750d6e9c 100644 --- a/app/controllers/cards_controller.rb +++ b/app/controllers/cards_controller.rb @@ -38,7 +38,7 @@ class CardsController < ApplicationController def destroy @card.destroy! - redirect_to cards_path(collection_ids: [ @card.collection ]), notice: ("Card deleted" unless @card.creating?) + redirect_to @card.collection, notice: ("Card deleted" unless @card.creating?) end private diff --git a/app/helpers/accesses_helper.rb b/app/helpers/accesses_helper.rb index 103df67bb..ec98acc22 100644 --- a/app/helpers/accesses_helper.rb +++ b/app/helpers/accesses_helper.rb @@ -32,17 +32,20 @@ module AccessesHelper displayed_watchers = watchers.limit(MAX_DISPLAYED_WATCHERS) overflow_count = watchers.count - MAX_DISPLAYED_WATCHERS - tag.div(class: "collection-tools__watching") do - safe_join([ - safe_join(displayed_watchers.map { |watcher| avatar_tag(watcher) }), - (tag.div(data: { controller: "dialog", action: "keydown.esc->dialog#close click@document->dialog#closeOnClickOutside" }) do - concat tag.button("+#{overflow_count}", class: "overflow-count btn btn--circle borderless", data: { action: "dialog#open" }, aria: { label: "Show #{overflow_count} more watchers" }) - concat(tag.dialog(class: "collection-tools__watching-dialog dialog panel", data: { dialog_target: "dialog" }, aria: { hidden: "true" }) do - safe_join(watchers.map { |watcher| avatar_tag(watcher) }) - end) - end if overflow_count > 0) - ].compact) - end + safe_join([ + tag.strong(displayed_watchers.any? ? "Watching for new cards" : "No one is watching for new cards", class: "txt-uppercase"), + tag.div(class: "collection-tools__watching") do + safe_join([ + safe_join(displayed_watchers.map { |watcher| avatar_tag(watcher) }), + (tag.div(data: { controller: "dialog", action: "keydown.esc->dialog#close click@document->dialog#closeOnClickOutside" }) do + concat tag.button("+#{overflow_count}", class: "overflow-count btn btn--circle borderless", data: { action: "dialog#open" }, aria: { label: "Show #{overflow_count} more watchers" }) + concat(tag.dialog(class: "collection-tools__watching-dialog dialog panel", data: { dialog_target: "dialog" }, aria: { hidden: "true" }) do + safe_join(watchers.map { |watcher| avatar_tag(watcher) }) + end) + end if overflow_count > 0) + ].compact) + end + ]) end def involvement_button(collection, access, show_watchers, icon_only) diff --git a/app/views/collections/edit.html.erb b/app/views/collections/edit.html.erb index 8fa1a5f0e..536f7ef68 100644 --- a/app/views/collections/edit.html.erb +++ b/app/views/collections/edit.html.erb @@ -33,7 +33,7 @@ Save changes - <%= link_to "Cancel and go back", cards_path(collection_ids: [ @collection ]), data: { form_target: "cancel", turbo_frame: "_top" }, hidden: true %> + <%= link_to "Cancel and go back", @collection, data: { form_target: "cancel", turbo_frame: "_top" }, hidden: true %> <% end %> diff --git a/app/views/collections/edit/_name.html.erb b/app/views/collections/edit/_name.html.erb index 6c70cd6aa..396050204 100644 --- a/app/views/collections/edit/_name.html.erb +++ b/app/views/collections/edit/_name.html.erb @@ -1,7 +1,7 @@