bsky-app/bskyweb
Paul Frazee 0dae24e78f
Additional embed sources and external-media consent controls (#2424)
* add apple music embed

* add vimeo embed

* add logic for tenor and giphy embeds

* keep it simple, use playerUri for images too

* add gif embed player

* lint, fix tests

* remove links that can't produce a thumb

* Revert "remove links that can't produce a thumb"

This reverts commit 985b92b4e622db936bb0c79fdf324099b9c8fcd8.

* Revert "Revert "remove links that can't produce a thumb""

This reverts commit 4895ded8b5120c4fc52b43ae85c9a01ea0b1a733.

* Revert "Revert "Revert "remove links that can't produce a thumb"""

This reverts commit 36d04b517ba5139e1639f2eda28d7f9aaa2dbfb6.

* properly obtain giphy metadata regardless of used url

* test fixes

* adjust gif player

* add all twitch embed types

* support m.youtube links

* few logic adjustments

* adjust spotify player height

* prefetch gif before showing

* use memory-disk cache policy on gifs

* use `disk` cachePolicy on ios - can't start/stop animation

* support pause/play on web

* onLoad fix

* remove extra pressable, add accessibility, fix scale issues

* improve size of embed

* add settings

* fix(?) settings

* add source to embed player params

* update tests

* better naming and settings options

* consent modal

* fix test id

* why is webstorm adding .tsx

* web modal

* simplify types

* adjust snap points

* remove unnecessary yt embed library. just use the webview always

* remove now useless WebGifStill 😭

* more type cleanup

* more type cleanup

* combine parse and prefs check in one memo

* improve dimensions of youtube shorts

* oops didn't commit the test 🫥

* add shorts as separate embed type

* fix up schema

* shorts modal

* hide gif details

* support localized spotify embeds

* more cleanup

* improve look and accessibility of gif embeds

* Update routing for the external embeds settings page

* Update and simplify the external embed preferences screen

* Update copy in embedconsent modal and add 'allow all' button

---------

Co-authored-by: Hailey <me@haileyok.com>
2024-01-04 17:37:36 -08:00
..
cmd/bskyweb Additional embed sources and external-media consent controls (#2424) 2024-01-04 17:37:36 -08:00
static Update some brand assets (#2301) 2023-12-24 14:32:23 -08:00
templates support multiple og:image tags (#2305) 2023-12-27 18:13:53 +01:00
.gitignore Updates indigo golang packages post-lex-refactor (!), which fixes XRPC calls (#582) 2023-05-04 13:56:17 -05:00
Makefile bskyweb: update golang indigo dep (from May!), and some small devex tweaks (#2227) 2023-12-18 19:31:48 +04:00
README.md update golang to v1.21; set GOEXPERIMENT=loopvar (#1256) 2023-08-28 19:35:23 -07:00
example.dev.env bskyweb: switch from PDS backend to AppView backend (#1065) 2023-08-24 16:00:45 -07:00
example.env bskyweb: update golang indigo dep (from May!), and some small devex tweaks (#2227) 2023-12-18 19:31:48 +04:00
go.mod bskyweb: update golang indigo dep (from May!), and some small devex tweaks (#2227) 2023-12-18 19:31:48 +04:00
go.sum bskyweb: update golang indigo dep (from May!), and some small devex tweaks (#2227) 2023-12-18 19:31:48 +04:00
static.go bskyweb additions (#296) 2023-03-20 14:41:15 -07:00
templates.go bskyweb additions (#296) 2023-03-20 14:41:15 -07:00

README.md

Build / Develop

SPA Bundle (monolithic static javascript file)

To build the SPA bundle (bundle.web.js), first get a JavaScript development environment set up. Either follow the top-level README, or something quick like:

# install nodejs 18 (specifically)
nvm install 18
nvm use 18
npm install --global yarn

# setup tools and deps (in top level of this repo)
yarn install --frozen-lockfile

# run yarn web dev server, if you wanted
yarn web

Then build and copy over the big 'ol bundle.web.js file:

# in the top level of this repo
yarn build-web

Golang Daemon

Install golang. We are generally using v1.21+.

In this directory (bskyweb/):

# re-build and run daemon
go run ./cmd/bskyweb serve

# build and output a binary
go build -o bskyweb ./cmd/bskyweb/

The easiest way to configure the daemon is to copy example.env to .env and fill in auth values there.