From 98f170004928e56bd77f39fb4a951a2bb2204f69 Mon Sep 17 00:00:00 2001 From: Cory McWilliams Date: Sun, 29 Dec 2024 15:42:12 -0500 Subject: [PATCH] ssb: Fiddling with message card and compose CSS some more. --- apps/ssb.json | 2 +- apps/ssb/tf-compose.js | 42 +++++++++++++++++++++++------------------- apps/ssb/tf-message.js | 21 ++++++++++++--------- 3 files changed, 36 insertions(+), 29 deletions(-) diff --git a/apps/ssb.json b/apps/ssb.json index 847f5224..23cd74bf 100644 --- a/apps/ssb.json +++ b/apps/ssb.json @@ -1,5 +1,5 @@ { "type": "tildefriends-app", "emoji": "🦀", - "previous": "&2aHEnXfmAZgCJxML+RF6j63QIYnI4TR5QvqzCHSitNQ=.sha256" + "previous": "&zUbiDsKYgSEnn5g5oDSQ1M5YwGqwHL+3cMO6a6zdCD8=.sha256" } diff --git a/apps/ssb/tf-compose.js b/apps/ssb/tf-compose.js index c02ba8dc..a386ff9c 100644 --- a/apps/ssb/tf-compose.js +++ b/apps/ssb/tf-compose.js @@ -572,13 +572,15 @@ class TfComposeElement extends LitElement { }
- ${this.channel !== undefined - ? html`

To #${this.channel}:

` - : undefined} - ${this.render_encrypt()} +
+ ${this.channel !== undefined + ? html`

To #${this.channel}:

` + : undefined} + ${this.render_encrypt()} +
-
+
${content_warning} -
+

${Object.values(draft.mentions || {}).map((x) => self.render_mention(x) )} - ${this.render_attach_app()} ${this.render_content_warning()} - ${this.render_new_thread()} - - - ${this.render_attach_app_button()} ${encrypt} - +
+ ${this.render_attach_app()} ${this.render_content_warning()} + ${this.render_new_thread()} + + + ${this.render_attach_app_button()} ${encrypt} + +
`; return result; diff --git a/apps/ssb/tf-message.js b/apps/ssb/tf-message.js index 2cdade7d..84e61db8 100644 --- a/apps/ssb/tf-message.js +++ b/apps/ssb/tf-message.js @@ -320,6 +320,8 @@ ${JSON.stringify(mention, null, 2)}` )}`; } + } else { + return undefined; } } @@ -639,7 +641,7 @@ ${JSON.stringify(content, null, 2)}${raw_button}
${payload} ${this.render_votes()} -

+

`; } else if (content.type === 'issue') { @@ -696,12 +698,12 @@ ${JSON.stringify(content, null, 2)}${raw_button} ${content.text} ${this.render_votes()} -

+

`; } else if (content.type === 'blog') { @@ -792,13 +794,14 @@ ${JSON.stringify(content, null, 2)}${body} ${this.render_mentions()} -
+ ${this.render_votes()} +
- ${this.render_votes()} ${this.render_children()} + ${this.render_children()} + `; } else if (content.type === 'pub') {