Commit Graph

624 Commits

Author SHA1 Message Date
Christian Bundy 671c5f3fd3
Merge pull request #106 from jedahan/c4
C4
2020-01-29 17:22:28 -08:00
Jonathan Dahan 0fc2bdd30e
Merge pull request #1 from christianbundy/pr/106
Appease linter with `npm run fix`
2020-01-29 18:20:40 -05:00
Christian Bundy 04c5e97789 Appease linter with `npm run fix`
Problem: `docs/contributing.md` was failing the Prettier test.

Solution: `npm run fix`
2020-01-29 18:20:06 -05:00
Christian Bundy 7d6dd163e2 Appease linter with `npm run fix`
Problem: `docs/contributing.md` was failing the Prettier test.

Solution: `npm run fix`
2020-01-29 13:19:50 -08:00
Christian Bundy 0dc4b0cc00
Merge pull request #118 from jedahan/github-issue-template-typo
fix typo in github issue template
2020-01-29 11:29:13 -08:00
Jonathan Dahan 35f2c5b904 fix typo in github issue template 2020-01-28 22:18:52 -05:00
Cinnamon eca2309769
Merge pull request #114 from christianbundy/filter-private-from-profile
Hide private messages from author profiles
2020-01-28 18:08:15 -08:00
Christian Bundy bc386e1ac4
Merge pull request #115 from fraction/add-license-1
Add LICENSE file (for AGPL-3.0)
2020-01-28 18:05:01 -08:00
Cinnamon 72214effcb
Add LICENSE file (for AGPL-3.0)
The README says this is AGPL-3.0 but we don't have a standard LICENSE file.  I added this using the tool at https://github.com/fraction/oasis/community
2020-01-28 17:45:00 -08:00
Christian Bundy 53c1a1ad94 Hide private messages from author profiles
Problem: Showing private posts on profiles is scary and may give people
the impression that these posts are visible.
https://github.com/fraction/oasis/issues/113

Solution: Hide private messages when rendering public profiles and
change the method name to be very clear that it only returns public
messages.
2020-01-28 17:15:48 -08:00
Christian Bundy 82f080f3c6
Merge pull request #108 from christianbundy/release-2.12.0
2.12.0
2020-01-28 13:10:56 -08:00
Christian Bundy 89b68db17e 2.12.0 2020-01-28 12:56:55 -08:00
Jonathan Dahan a3c08a6341 Relax MUST to SHOULD for commit message format 2020-01-28 14:33:06 -05:00
Jonathan Dahan a4ff159b94 Thank and explain why we have contributing.md 2020-01-28 14:33:06 -05:00
Jonathan Dahan ffbee28f88 explain that our contributing.md is an implementation of C4 2020-01-28 14:33:06 -05:00
Jonathan Dahan e2dd57be3d remove liquid templates from contributing.md 2020-01-28 14:33:06 -05:00
Jonathan Dahan 1da4a2b865 add contributing link to readme 2020-01-28 14:33:05 -05:00
Jonathan Dahan a3265dc635 add upstream C4/42 contributing document 2020-01-28 14:33:05 -05:00
Jonathan Dahan 37d01bf517
Merge pull request #92 from fraction/conn-buttons
Add buttons to 'meta' page to manage networking
2020-01-28 14:03:30 -05:00
Christian Bundy ec3e4d489a Merge branch 'master' of github.com:fraction/oasis into conn-buttons 2020-01-28 10:25:42 -08:00
Christian Bundy b56b4bcd74 Update Flotilla to fix conn.stop bug
Problem: Stopping the networking would sometimes allow peers to remain
connected, which was confusing.

Solution: Upgrade to latest SSB-CONN to pull in a bugfix for this
behavior. Huge thanks to @staltz for the quick fix!
2020-01-28 10:22:24 -08:00
Christian Bundy eafd5cd177
Merge pull request #104 from jedahan/rename-contributing-to-architecture
rename contributing to architecture
2020-01-28 10:02:07 -08:00
Jonathan Dahan fed37b1e57 rename contributing to architecture 2020-01-28 12:25:22 -05:00
Christian Bundy 6735783b3f Fix sidebar moving along X axis on short pages
Problem: On short pages, like the search page, there's no scrollbar
gutter on the right side of the page, which moves everything a few
pixels to the right. After banging my head against this for an hour I finally
realized that it only happens when your viewport is taller than the
content on the page, which creates the scrollbar. This was reported as:
https://github.com/fraction/oasis/issues/96

Solution: Change the display so that we consistently show a scrollbar
gutter on the right side of the page regardless of whether we need it
(e.g. on very short pages or on very tall monitors). This means that
when we center the content on the page it won't move depending on the
height of the page, which was frustrating and janky.
2020-01-28 12:11:39 -05:00
Christian Bundy 03976b288d Solve inconsistent widths between pages
Problem: The `<section>` elements on some pages have different sizes,
which means that the sidebar is doing wonky stuff.

Solution: Make the sections all have a consistent width. Note that
there's still a few pixels of jank on the 'search' page, I'm not sure
why that's happening. The element inspector is reporting that everything
is the same width but that isn't true.
2020-01-28 12:11:39 -05:00
Christian Bundy 40c19c6a20 Add simple nav sidebar on large screens
Problem: Putting the navigation at the top of the screen makes it
impossible to use when you're scrolling through a page, which isn't a
good user experience. It was never meant to be permanent, and I think
everyone has pointed out that it's been a pain.

Solution: Super simple sidebar nav when people are on bigger screens.
This doesn't solve the problem on mobile, and it doesn't incorporate the
'popular' page's interval settings, but I think it's a step in the right
direction.
2020-01-28 12:11:39 -05:00
Jonathan Dahan dcafcdceb1
Merge pull request #99 from fraction/caps
Use capitalization for Oasis links and buttons
2020-01-28 16:34:43 +00:00
Jonathan Dahan d5e47a581d
Merge branch 'master' into caps 2020-01-28 16:22:39 +00:00
Jonathan Dahan 239fff19c4
Merge pull request #74 from fraction/favicon-dimensions
Change favicon dimensions to fit in tab
2020-01-28 16:19:06 +00:00
Jonathan Dahan 43f29e7658
Merge branch 'master' into favicon-dimensions 2020-01-28 16:05:26 +00:00
Cinnamon b7c1233f00
Merge pull request #83 from fraction/fix-tangle
Fix tangle bug when Patchwork is used as a server
2020-01-27 22:07:26 -08:00
Christian Bundy ae08e0715f Use capitalization for Oasis links and buttons
Problem: Using all-lowercase-everything isn't really a standard around
the web and it might be better to use consistent capitalization. This
was brought up in: https://github.com/fraction/oasis/issues/98

Solution: This changes the main navigation to use links with the first
letter capitalized, like how Patchwork + Twitter + Mastodon + etc do it.
This means that we're consistently using sentence case everywhere, which
I think is our best option. Originally I tried experimenting with
all-caps for actions, which I found aesthetically pleasing, but you have
to reduce the font size to make it look good (bad!) and I was reading
that all-caps text is harder for friends with dyslexia or vision
impairments.
2020-01-27 15:48:13 -08:00
Christian Bundy 0e026e020c
Merge branch 'master' into favicon-dimensions 2020-01-27 13:33:00 -08:00
Christian Bundy b61d696a53
Merge branch 'master' into fix-tangle 2020-01-27 13:32:58 -08:00
Christian Bundy 4d1e505701 Change to only inject SSB-Tangle when necessary
Problem: We were overwriting SSB-Tangle with itself, which is fine, but
kind of confusing and requires some knowledge on what is and isn't safe
for Secret-Stack.

Solution: Only inject SSB-Tangle if it doesn't already exist, which
makes the code easier to reason about.
2020-01-27 12:06:33 -08:00
Christian Bundy 64a2ed135c Update CLI with more info on --offline
Problem: The --offline documentation doesn't mention that networking
status can be changed, which may give the false understanding that the
networking is permanently offline when you use that flag.

Solution: Add a note that mentions that the 'meta' page lets you change
your networking status, and that --offline is only applicable to the
starting state of Oasis.
2020-01-27 11:58:32 -08:00
Christian Bundy f40c6ff484 Fix connection restart behavior
Problem: It was starting then stopping, which isn't what we want.

Solution: Swap the lines and make sure that we stop, *then* start.
2020-01-27 11:52:29 -08:00
Cinnamon b311f7848f
Merge pull request #82 from fraction/add-jsdoc
Add some basic type info with JSDoc
2020-01-27 10:18:20 -08:00
Christian Bundy 681e3c6755 Add buttons to 'meta' page to manage networking
Problem: Sometimes you want to disconnect from the network but you don't
want to have to restart Oasis with the `--offline` flag
(https://github.com/fraction/oasis/issues/89). Sometimes networking gets
stuck and you need to run the equivalent of `ssb gossip reconnect`
(https://github.com/fraction/oasis/issues/63).

Solution: Buttons on the 'meta' page that let you start, stop, or
restart SSB-CONN whenever you want. Note that this commit includes an
update to SSB-CONN, but this version and the previous version both have
a bug where hitting 'stop' twice in a row will throw an error. This
commit implements a workaround for the bug, but it's something we'll
want to remove later once the underlying bug is fixed.
2020-01-26 16:55:48 -08:00
Christian Bundy dec0f42b0f Fix tangle bug when Patchwork is used as a server
Problem: Patchwork is missing a plugin that we need to set the `branch`
property when posting a message. This property is important because it
helps us sort threads, so we're throwing an error when it isn't
available. See: https://github.com/fraction/oasis/issues/21

Solution: HACK THE ~~PLANET~~ API. This commit injects the plugin we
need via Oasis, which is a bit of a duct tape solution but it *is* a
solution.
2020-01-26 12:57:42 -08:00
Christian Bundy b6314309f6 Add some basic type info with JSDoc
Problem: When we don't have any documentation for variable types it's
difficult for both humans and machines to parse our code.

Solution: As discussed in https://github.com/fraction/oasis/issues/78,
adding some JSDoc information on function signatures would be a nice
step in the right direction and could make debugging easier.
2020-01-26 12:42:28 -08:00
Cinnamon c218d8bcad
Merge pull request #79 from fraction/faster-inbox
Use ssb-backlinks to improve /inbox page load
2020-01-26 11:30:12 -08:00
Cinnamon c80de07e40
Merge branch 'master' into faster-inbox 2020-01-26 11:19:04 -08:00
Cinnamon 8709ad3c56
Merge pull request #81 from fraction/npm-update
Update Common-Good to stop using npm alias
2020-01-26 11:04:40 -08:00
Christian Bundy 3c50b94fa1 Update Common-Good to stop using npm alias
Problem: CG's dependency, CSpell, had problems with Windows support, so
I was using a forked module as an alias to circumvent the problem. This
only works on very recent version of npm.

Solution: This morning the CSpell maintainer resolved the problem, so
the latest CG doesn't have to depend on an alias. This commit runs `npm
update` to get the latest version of CG so we don't have this problem.
2020-01-25 16:28:08 -08:00
Christian Bundy 502e5e400d Use ssb-backlinks to improve /inbox page load
Problem: The /inbox page was being rendered super slowly because it was
reading through tons of messages.

Solution: There isn't a way to query the database for "private messages
for me", although maybe there should be, but one way we can get
something close is querying for "messages that reference me". Every
message that's encrypted for us will have a `.value.content.recps`
property that includes our feed ID, so we just have to filter out the
public messages and we're about 4 times faster than the previous
implementation.

```console
$ hyperfine 'curl -I http://localhost:4515/inbox' 'curl -I http://localhost:3000/inbox'
Benchmark #1: curl -I http://localhost:4515/inbox
  Time (mean ± σ):      3.352 s ±  0.093 s    [User: 2.0 ms, System: 4.3 ms]
  Range (min … max):    3.231 s …  3.483 s    10 runs

Benchmark #2: curl -I http://localhost:3000/inbox
  Time (mean ± σ):     811.8 ms ±  88.3 ms    [User: 2.7 ms, System: 2.9 ms]
  Range (min … max):   709.1 ms … 972.5 ms    10 runs

Summary
  'curl -I http://localhost:3000/inbox' ran
    4.13 ± 0.46 times faster than 'curl -I http://localhost:4515/inbox'
```
2020-01-25 10:23:19 -08:00
Cinnamon 57702c7b44
Merge pull request #75 from fraction/fix-private-comment
Fix private reply with `recps` bug
2020-01-24 15:59:10 -08:00
Christian Bundy 69bc92dc5a Merge branch 'master' of github.com:fraction/oasis into fix-private-comment 2020-01-24 14:26:47 -08:00
Christian Bundy 416b715eb0 Fix incorrect comment, throw if no recipients 2020-01-24 14:26:33 -08:00
Cinnamon 5f33869f5c
Merge pull request #76 from fraction/cg-update
Update npm dependencies for new common-good
2020-01-24 14:09:23 -08:00