commit d08df984d349a29da6a1a9022638cbc46f35551a
parent b6d30a70a86bbde2f5963811117cd8da67daaae3
Author: William Casarin <jb55@jb55.com>
Date: Thu, 27 Oct 2022 18:19:59 -0700
always render events when composing a reply
Diffstat:
3 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/webv2/damus.css b/webv2/damus.css
@@ -85,7 +85,6 @@ button {
padding: 10px;
margin: 10% auto;
width: 60%;
- height: 50%;
overflow: auto; /* Enable scroll if needed */
background: linear-gradient(0deg, #A74BDB 0%, #C45BFE 100%);
border-radius: 15px;
diff --git a/webv2/damus.js b/webv2/damus.js
@@ -384,7 +384,7 @@ function render_reply_line_bot() {
}
function render_event(model, ev, opts={}) {
- if (model.rendered[ev.id])
+ if (!opts.is_composing && model.rendered[ev.id])
return ""
model.rendered[ev.id] = true
const profile = model.profiles[ev.pubkey] || {
@@ -557,7 +557,7 @@ function reply_to(evid) {
replying_to.dataset.evid = evid
const ev = DSTATE.all_events[evid]
- replying_to.innerHTML = render_event(DSTATE, ev, {nobar: true})
+ replying_to.innerHTML = render_event(DSTATE, ev, {is_composing: true, nobar: true})
modal.style.display = replying? "block" : "none";
}
diff --git a/webv2/index.html b/webv2/index.html
@@ -6,7 +6,7 @@
<title>Damus Web</title>
- <link rel="stylesheet" href="damus.css?v=4">
+ <link rel="stylesheet" href="damus.css?v=6">
</head>
<body>
<section class="header">
@@ -43,7 +43,7 @@
<script src="noble-secp256k1.js?v=1"></script>
<script src="bech32.js?v=1"></script>
<script src="nostr.js?v=3"></script>
- <script src="damus.js?v=7"></script>
+ <script src="damus.js?v=9"></script>
<script>
const relay = damus_web_init("4e8b44bb43018f79bd3efcdcd71af43814cdf996e0c62adedda1ac33bf5e1371")
</script>