| Commit message (Collapse) | Author | Age |
| |
|
|
| |
This simplifies data flow, at the potential expense of re-rendering HTML more often than strictly necessary. Requiring every path that produces a message-shaped object to pre-render markdown made things more interdependent than intended and slowed me down.
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
| |
There is a subtle race conditon in this code, which is likely not fixable without a protocol change:
* Ghost messages can disappear before their "real" message replacement shows up, if the client finishes sending (i.e., receives an HTTP response on the POST) before the server delivers the real message.
* Ghost messages can be duplicated briefly, if the client receives the real message before the client finishes sending.
Both happen in practice; we make no ordering guarantees between requests.
To aviod this, we'd to give clients a way to correlate pending sends with received messages. This would require fundamentally the same capabilities, like per-operation nonces, that preventing duplicate operations will require.
|
| |
|
|
| |
Only once on load, then once per new message.
|
| |
|
|
|
|
|
|
| |
Access to "global" (maybe "external?") state is now handled at the top level of the component hierarchy, in `+page.svelte`, `+layout.svelte`, and their associated scripts. State is otherwise passed down through props, and changes are passed up through callbacks.
This is - hopefully - groundwork for refactoring state management a bit. I wanted to move access to state out to a smaller number of places, so that I have fewer places to update to implement reconnect logic. My broader goal is to make it easier to refactor these kinds of external side effects, as well, though no such changes are in this branch.
This change also makes testing a mile easier, since tests can interact with props and callbacks instead of emulating the whole HTTP request stack and the Pilcrow API. This change removes do-very-little tests.
|
| | |
|
| | |
|
| | |
|
| |\ |
|
| | |
| |
| |
| |
| |
| | |
This includes jamming the "at" of a message into a data- attribute on
the Message component, so that it can later be used by parent components
via Plain Old Javascript and the .dataset attribute of an HTML node.
|
| | | |
|
| |\| |
|
| | |
| |
| |
| | |
Svelte's lint complains if you add interaction to a div but don't give that div an ARIA role.
|
| | |
| |
| |
| |
| |
| | |
rendered.
~16% of the `hi development` channel's rendering time was taken up on this.
|
| |\| |
|
| | |
| |
| |
| | |
This also fixes some rendering jank with the message timestamp chip.
|
| | | |
|
| |/
|
|
| |
But it's not working. Why?
|
| |
|
|
|
|
| |
* We had an unused layer of divs in the main UI.
* The <div id="app"> div was superfluous with the body-level div in app.html.
* Some formatting changes in one component?? Weird.
|
| |
|
|
|
|
|
| |
This is some jinbodger CSS. I really need to do a unified-CSS sweep.
I start to see why per-component CSS is bad, too; there are so many
long-distance interactions needed!
|
| | |
|
| |
|
|
| |
Does not use runes in stores (yet).
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
This was causing messages to persist when switching channels, due to the work minimization performed by Svelte.
|
| |\ |
|
| | | |
|
| |/ |
|
| |
|
|
| |
message runs.
|
| | |
|
| |
|
|
| |
message display.
|
| |
|