Bluesky app fork with some witchin' additions 💫
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Hackfix around 'images too large' issue

+32 -2
+6
ios/Podfile.lock
··· 341 341 - React-Core 342 342 - RNCClipboard (1.11.1): 343 343 - React-Core 344 + - RNFS (2.20.0): 345 + - React-Core 344 346 - RNGestureHandler (2.8.0): 345 347 - React-Core 346 348 - RNImageCropPicker (0.38.1): ··· 438 440 - rn-fetch-blob (from `../node_modules/rn-fetch-blob`) 439 441 - "RNCAsyncStorage (from `../node_modules/@react-native-async-storage/async-storage`)" 440 442 - "RNCClipboard (from `../node_modules/@react-native-clipboard/clipboard`)" 443 + - RNFS (from `../node_modules/react-native-fs`) 441 444 - RNGestureHandler (from `../node_modules/react-native-gesture-handler`) 442 445 - RNImageCropPicker (from `../node_modules/react-native-image-crop-picker`) 443 446 - RNInAppBrowser (from `../node_modules/react-native-inappbrowser-reborn`) ··· 542 545 :path: "../node_modules/@react-native-async-storage/async-storage" 543 546 RNCClipboard: 544 547 :path: "../node_modules/@react-native-clipboard/clipboard" 548 + RNFS: 549 + :path: "../node_modules/react-native-fs" 545 550 RNGestureHandler: 546 551 :path: "../node_modules/react-native-gesture-handler" 547 552 RNImageCropPicker: ··· 606 611 rn-fetch-blob: f065bb7ab7fb48dd002629f8bdcb0336602d3cba 607 612 RNCAsyncStorage: 8616bd5a58af409453ea4e1b246521bb76578d60 608 613 RNCClipboard: 2834e1c4af68697089cdd455ee4a4cdd198fa7dd 614 + RNFS: 4ac0f0ea233904cb798630b3c077808c06931688 609 615 RNGestureHandler: 62232ba8f562f7dea5ba1b3383494eb5bf97a4d3 610 616 RNImageCropPicker: 648356d68fbf9911a1016b3e3723885d28373eda 611 617 RNInAppBrowser: e36d6935517101ccba0e875bac8ad7b0cb655364
+1
package.json
··· 39 39 "react-dom": "17.0.2", 40 40 "react-native": "0.71.0", 41 41 "react-native-appstate-hook": "^1.0.6", 42 + "react-native-fs": "^2.20.0", 42 43 "react-native-gesture-handler": "^2.5.0", 43 44 "react-native-haptic-feedback": "^1.14.0", 44 45 "react-native-image-crop-picker": "^0.38.1",
+11 -1
src/state/lib/api.ts
··· 6 6 // import {ReactNativeStore} from './auth' 7 7 import { 8 8 sessionClient as AtpApi, 9 - APP_BSKY_GRAPH, 10 9 AppBskyEmbedImages, 11 10 AppBskyEmbedExternal, 12 11 } from '@atproto/api' 12 + import RNFS from 'react-native-fs' 13 13 import {AtUri} from '../../third-party/uri' 14 14 import {RootStoreModel} from '../models/root-store' 15 15 import {extractEntities} from '../../lib/strings' ··· 235 235 typeof reqBody === 'string' && 236 236 (reqBody.startsWith('/') || reqBody.startsWith('file:')) 237 237 ) { 238 + if (reqBody.endsWith('.jpeg') || reqBody.endsWith('.jpg')) { 239 + // HACK 240 + // React native has a bug that inflates the size of jpegs on upload 241 + // we get around that by renaming the file ext to .bin 242 + // see https://github.com/facebook/react-native/issues/27099 243 + // -prf 244 + const newPath = reqBody.replace(/\.jpe?g$/, '.bin') 245 + await RNFS.moveFile(reqBody, newPath) 246 + reqBody = newPath 247 + } 238 248 // NOTE 239 249 // React native treats bodies with {uri: string} as file uploads to pull from cache 240 250 // -prf
+14 -1
yarn.lock
··· 3700 3700 resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" 3701 3701 integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== 3702 3702 3703 - base-64@0.1.0: 3703 + base-64@0.1.0, base-64@^0.1.0: 3704 3704 version "0.1.0" 3705 3705 resolved "https://registry.yarnpkg.com/base-64/-/base-64-0.1.0.tgz#780a99c84e7d600260361511c4877613bf24f6bb" 3706 3706 integrity sha512-Y5gU45svrR5tI2Vt/X9GPd3L0HNIKzGu202EjxrXMpuc2V2CiKgemAbUUsqYmZJvPtCXoUKjNZwBJzsNScUbXA== ··· 10292 10292 dependencies: 10293 10293 dotenv "^16.0.3" 10294 10294 10295 + react-native-fs@^2.20.0: 10296 + version "2.20.0" 10297 + resolved "https://registry.yarnpkg.com/react-native-fs/-/react-native-fs-2.20.0.tgz#05a9362b473bfc0910772c0acbb73a78dbc810f6" 10298 + integrity sha512-VkTBzs7fIDUiy/XajOSNk0XazFE9l+QlMAce7lGuebZcag5CnjszB+u4BdqzwaQOdcYb5wsJIsqq4kxInIRpJQ== 10299 + dependencies: 10300 + base-64 "^0.1.0" 10301 + utf8 "^3.0.0" 10302 + 10295 10303 react-native-gesture-handler@^2.5.0: 10296 10304 version "2.8.0" 10297 10305 resolved "https://registry.yarnpkg.com/react-native-gesture-handler/-/react-native-gesture-handler-2.8.0.tgz#ef9857871c10663c95a51546225b6e00cd4740cf" ··· 12086 12094 version "3.1.1" 12087 12095 resolved "https://registry.yarnpkg.com/use/-/use-3.1.1.tgz#d50c8cac79a19fbc20f2911f56eb973f4e10070f" 12088 12096 integrity sha512-cwESVXlO3url9YWlFW/TA9cshCEhtu7IKJ/p5soJ/gGpj7vbvFrAY/eIioQ6Dw23KjZhYgiIo8HOs1nQ2vr/oQ== 12097 + 12098 + utf8@^3.0.0: 12099 + version "3.0.0" 12100 + resolved "https://registry.yarnpkg.com/utf8/-/utf8-3.0.0.tgz#f052eed1364d696e769ef058b183df88c87f69d1" 12101 + integrity sha512-E8VjFIQ/TyQgp+TZfS6l8yp/xWppSAHzidGiRrqe4bK4XP9pTRyKFgGJpO3SN7zdX4DeomTrwaseCHovfpFcqQ== 12089 12102 12090 12103 util-deprecate@^1.0.1, util-deprecate@^1.0.2, util-deprecate@~1.0.1: 12091 12104 version "1.0.2"