-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue 238: Add Support for Bluesky #239
Issue 238: Add Support for Bluesky #239
Conversation
b025da9
to
b144f82
Compare
b144f82
to
ac9a9e9
Compare
@JoshyPHP I have got it working so that it embeds BlueSky posts using the API. I've added it to the DefaultSites list as well as the MediaPack bundle. Please let me know if I missed anything or anything needs to change. |
Sorry for not coming back to this sooner. I've just published a commit that adds support for Bluesky in a manner that's conceptually different from what you proposed in this PR. In order to support different environments I use a third party iframe hosted here on GitHub. Among other things, it makes it easier to communicate with it without interfering with the rest of the page. Please check it out at your leisure and let me know if it works as expected or it I overlooked anything. I'm going to close this PR but feel free to continue this discussion in #238. |
Does anyone know why this isn't working, @JoshyPHP ? Specifically, the scrape that is trying to capture the DID simply isnt providing that value to the resulting iframe src code. That just results in BlueSky returning this: name: Bluesky
host: bsky.app
homepage: https://bsky.app/
example: https://bsky.app/profile/jamesgunn.bsky.social/post/3l6kscjixz22q
extract: "!bsky\\.app/profile/(?'name'[A-Za-z0-9.]+)/post/(?'id'\\w+)!"
oembed:
endpoint: https://embed.bsky.app/oembed
scheme: https://bsky.app/profile/{@name}/post/{@id}
scrape:
- extract: "!\"did\":\\s*\"did:(?'did'[a-zA-Z0-9._:%-]+)\"!"
- match: "//"
- url: https://public.api.bsky.app/xrpc/app.bsky.actor.getProfile?actor={@name}
iframe:
width: "550"
height: "350"
src: https://embed.bsky.app/embed/did:{@did}/app.bsky.feed.post/{@id} |
I don't know, I went with a different approach so I didn't really test that PR. I recommend you use the definition that's currently in the repo. |
That seems to rely on classes/files that don't exist in the version we are stuck using. |
I don't think so, although I can't test it right now. You or @rxu open an issue in the phpBB extension's repo, tag me and we can continue the discussion there. |
Added BlueSky to the default sites list and MediaPack bundle.