pl-api: display reactions list on shrimpnet
Signed-off-by: nicole mikołajczyk <git@mkljczk.pl>
This commit is contained in:
@ -2662,7 +2662,7 @@ class PlApiClient {
|
|||||||
const apiVersions = this.#instance.api_versions;
|
const apiVersions = this.#instance.api_versions;
|
||||||
|
|
||||||
let response;
|
let response;
|
||||||
if (apiVersions['emoji_reactions.pleroma.pl-api'] >= 1) {
|
if (apiVersions['emoji_reactions.pleroma.pl-api'] >= 1 || this.features.version.software === ICESHRIMP_NET) {
|
||||||
response = await this.request(`/api/v1/pleroma/statuses/${statusId}/reactions${emoji ? `/${emoji}` : ''}`);
|
response = await this.request(`/api/v1/pleroma/statuses/${statusId}/reactions${emoji ? `/${emoji}` : ''}`);
|
||||||
} else if (apiVersions['emoji_reaction.fedibird.pl-api'] >= 1) {
|
} else if (apiVersions['emoji_reaction.fedibird.pl-api'] >= 1) {
|
||||||
response = await this.request(`/api/v1/statuses/${statusId}/emoji_reactioned_by`);
|
response = await this.request(`/api/v1/statuses/${statusId}/emoji_reactioned_by`);
|
||||||
|
|||||||
@ -669,11 +669,11 @@ const getFeatures = (instance: Instance) => {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* @see GET /api/v1/pleroma/statuses/:id/reactions/:emoji?
|
* @see GET /api/v1/pleroma/statuses/:id/reactions/:emoji?
|
||||||
*
|
|
||||||
* @see GET /api/v1/statuses/:id/emoji_reactioned_by
|
* @see GET /api/v1/statuses/:id/emoji_reactioned_by
|
||||||
*/
|
*/
|
||||||
emojiReactsList: any([
|
emojiReactsList: any([
|
||||||
v.software === AKKOMA,
|
v.software === AKKOMA,
|
||||||
|
v.software === ICESHRIMP_NET,
|
||||||
v.software === PLEROMA,
|
v.software === PLEROMA,
|
||||||
instance.api_versions['emoji_reaction.fedibird.pl-api'] >= 1,
|
instance.api_versions['emoji_reaction.fedibird.pl-api'] >= 1,
|
||||||
]),
|
]),
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "pl-api",
|
"name": "pl-api",
|
||||||
"version": "1.0.0-rc.77",
|
"version": "1.0.0-rc.79",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"homepage": "https://codeberg.org/mkljczk/pl-fe/src/branch/develop/packages/pl-api",
|
"homepage": "https://codeberg.org/mkljczk/pl-fe/src/branch/develop/packages/pl-api",
|
||||||
"repository": {
|
"repository": {
|
||||||
|
|||||||
@ -105,7 +105,7 @@
|
|||||||
"multiselect-react-dropdown": "^2.0.25",
|
"multiselect-react-dropdown": "^2.0.25",
|
||||||
"mutative": "^1.1.0",
|
"mutative": "^1.1.0",
|
||||||
"path-browserify": "^1.0.1",
|
"path-browserify": "^1.0.1",
|
||||||
"pl-api": "^1.0.0-rc.77",
|
"pl-api": "^1.0.0-rc.79",
|
||||||
"postcss": "^8.5.3",
|
"postcss": "^8.5.3",
|
||||||
"process": "^0.11.10",
|
"process": "^0.11.10",
|
||||||
"punycode": "^2.1.1",
|
"punycode": "^2.1.1",
|
||||||
|
|||||||
@ -6875,10 +6875,10 @@ pkg-dir@^4.1.0:
|
|||||||
dependencies:
|
dependencies:
|
||||||
find-up "^4.0.0"
|
find-up "^4.0.0"
|
||||||
|
|
||||||
pl-api@^1.0.0-rc.77:
|
pl-api@^1.0.0-rc.79:
|
||||||
version "1.0.0-rc.77"
|
version "1.0.0-rc.79"
|
||||||
resolved "https://registry.yarnpkg.com/pl-api/-/pl-api-1.0.0-rc.77.tgz#823b0aef1380f61581574898d0b02f5e0e3f9f60"
|
resolved "https://registry.yarnpkg.com/pl-api/-/pl-api-1.0.0-rc.79.tgz#3c49079b0a071784aca3177e7417f1e80efe2a12"
|
||||||
integrity sha512-B1P/042xnVT/CPFBn1M5GdutzIb6Ar5stsVBLc4A7GUYMoy0A4F2Sn3rKNen9/9SWJTj2IEj/o00dYdmX2A9LQ==
|
integrity sha512-iXIDxCK1+s9V7a6jfskTYqGuGQk/gvC48A+//5jn8L867QrCmSTN5KuRaMi1J2n/K18y4vhlRs0WgRxwO4xcyA==
|
||||||
dependencies:
|
dependencies:
|
||||||
blurhash "^2.0.5"
|
blurhash "^2.0.5"
|
||||||
http-link-header "^1.1.3"
|
http-link-header "^1.1.3"
|
||||||
|
|||||||
Reference in New Issue
Block a user