Radish alpha
r
Radicle desktop app
Radicle
Git (anonymous pull)
Log in to clone via SSH
Use twemojis for reactions
Rūdolfs Ošiņš committed 1 year ago
commit c4bef0e99b1f9e2f64ddd4b3dbd380b39a95b94a
parent 557e96f98b1f1954ae28f6b04c07bfbabceb5fea
2 files changed +6 -2
modified src/components/ReactionSelector.svelte
@@ -4,6 +4,7 @@
  import Border from "./Border.svelte";
  import Icon from "./Icon.svelte";
  import Popover from "./Popover.svelte";
+
  import { twemoji } from "@app/lib/utils";

  interface Props {
    reactions?: Reaction[];
@@ -62,6 +63,7 @@
            ({ emoji }) => emoji === reaction,
          )}
          <button
+
            use:twemoji={{ exclude: ["21a9"] }}
            class:active={Boolean(lookedUpReaction)}
            onclick={() =>
              select(lookedUpReaction || { emoji: reaction, authors: [] })}>
modified src/components/Reactions.svelte
@@ -2,6 +2,8 @@
  import type { Author } from "@bindings/cob/Author";
  import type { Reaction } from "@bindings/cob/Reaction";

+
  import { twemoji } from "@app/lib/utils";
+

  interface Props {
    reactions: Reaction[];
    handleReaction?: (authors: Author[], reaction: string) => Promise<void>;
@@ -42,12 +44,12 @@
              await handleReaction(authors, emoji);
            }
          }}>
-
          <span>{emoji}</span>
+
          <span use:twemoji={{ exclude: ["21a9"] }}>{emoji}</span>
          <span>{authors.length}</span>
        </div>
      {:else}
        <div class="reaction txt-tiny" style="padding: 2px 4px;">
-
          <span>{emoji}</span>
+
          <span use:twemoji={{ exclude: ["21a9"] }}>{emoji}</span>
          <span>{authors.length}</span>
        </div>
      {/if}