@pkcprotocol/pkc-js 0.0.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +339 -0
- package/README.md +1663 -0
- package/dist/browser/challenges.d.ts +1 -0
- package/dist/browser/challenges.js +2 -0
- package/dist/browser/challenges.js.map +1 -0
- package/dist/browser/clients/base-client-manager.d.ts +126 -0
- package/dist/browser/clients/base-client-manager.js +673 -0
- package/dist/browser/clients/base-client-manager.js.map +1 -0
- package/dist/browser/clients/name-resolver-client.d.ts +8 -0
- package/dist/browser/clients/name-resolver-client.js +10 -0
- package/dist/browser/clients/name-resolver-client.js.map +1 -0
- package/dist/browser/clients/pkc-typed-emitter.d.ts +9 -0
- package/dist/browser/clients/pkc-typed-emitter.js +52 -0
- package/dist/browser/clients/pkc-typed-emitter.js.map +1 -0
- package/dist/browser/clients/rpc-client/decode-rpc-response-util.d.ts +8 -0
- package/dist/browser/clients/rpc-client/decode-rpc-response-util.js +53 -0
- package/dist/browser/clients/rpc-client/decode-rpc-response-util.js.map +1 -0
- package/dist/browser/clients/rpc-client/pkc-rpc-client.d.ts +68 -0
- package/dist/browser/clients/rpc-client/pkc-rpc-client.js +404 -0
- package/dist/browser/clients/rpc-client/pkc-rpc-client.js.map +1 -0
- package/dist/browser/clients/rpc-client/rpc-schema-util.d.ts +147 -0
- package/dist/browser/clients/rpc-client/rpc-schema-util.js +11 -0
- package/dist/browser/clients/rpc-client/rpc-schema-util.js.map +1 -0
- package/dist/browser/clients/rpc-client/schema.d.ts +433 -0
- package/dist/browser/clients/rpc-client/schema.js +49 -0
- package/dist/browser/clients/rpc-client/schema.js.map +1 -0
- package/dist/browser/clients/rpc-client/types.d.ts +8 -0
- package/dist/browser/clients/rpc-client/types.js +2 -0
- package/dist/browser/clients/rpc-client/types.js.map +1 -0
- package/dist/browser/community/community-client-manager.d.ts +60 -0
- package/dist/browser/community/community-client-manager.js +717 -0
- package/dist/browser/community/community-client-manager.js.map +1 -0
- package/dist/browser/community/community-clients.d.ts +18 -0
- package/dist/browser/community/community-clients.js +12 -0
- package/dist/browser/community/community-clients.js.map +1 -0
- package/dist/browser/community/community-wire.d.ts +20 -0
- package/dist/browser/community/community-wire.js +38 -0
- package/dist/browser/community/community-wire.js.map +1 -0
- package/dist/browser/community/remote-community.d.ts +110 -0
- package/dist/browser/community/remote-community.js +555 -0
- package/dist/browser/community/remote-community.js.map +1 -0
- package/dist/browser/community/rpc-local-community.d.ts +41 -0
- package/dist/browser/community/rpc-local-community.js +289 -0
- package/dist/browser/community/rpc-local-community.js.map +1 -0
- package/dist/browser/community/rpc-remote-community.d.ts +18 -0
- package/dist/browser/community/rpc-remote-community.js +286 -0
- package/dist/browser/community/rpc-remote-community.js.map +1 -0
- package/dist/browser/community/schema.d.ts +4217 -0
- package/dist/browser/community/schema.js +289 -0
- package/dist/browser/community/schema.js.map +1 -0
- package/dist/browser/community/types.d.ts +135 -0
- package/dist/browser/community/types.js +2 -0
- package/dist/browser/community/types.js.map +1 -0
- package/dist/browser/constants.d.ts +6 -0
- package/dist/browser/constants.js +9 -0
- package/dist/browser/constants.js.map +1 -0
- package/dist/browser/decorator-util.d.ts +1 -0
- package/dist/browser/decorator-util.js +35 -0
- package/dist/browser/decorator-util.js.map +1 -0
- package/dist/browser/errors.d.ts +343 -0
- package/dist/browser/errors.js +358 -0
- package/dist/browser/errors.js.map +1 -0
- package/dist/browser/general-util/limited-set.d.ts +15 -0
- package/dist/browser/general-util/limited-set.js +66 -0
- package/dist/browser/general-util/limited-set.js.map +1 -0
- package/dist/browser/generated-version.d.ts +1 -0
- package/dist/browser/generated-version.js +3 -0
- package/dist/browser/generated-version.js.map +1 -0
- package/dist/browser/generic-state-client.d.ts +6 -0
- package/dist/browser/generic-state-client.js +11 -0
- package/dist/browser/generic-state-client.js.map +1 -0
- package/dist/browser/helia/helia-for-pkc.d.ts +3 -0
- package/dist/browser/helia/helia-for-pkc.js +255 -0
- package/dist/browser/helia/helia-for-pkc.js.map +1 -0
- package/dist/browser/helia/ipns-over-pubsub-with-fetch.d.ts +36 -0
- package/dist/browser/helia/ipns-over-pubsub-with-fetch.js +229 -0
- package/dist/browser/helia/ipns-over-pubsub-with-fetch.js.map +1 -0
- package/dist/browser/helia/libp2pjsClient.d.ts +27 -0
- package/dist/browser/helia/libp2pjsClient.js +15 -0
- package/dist/browser/helia/libp2pjsClient.js.map +1 -0
- package/dist/browser/helia/types.d.ts +19 -0
- package/dist/browser/helia/types.js +2 -0
- package/dist/browser/helia/types.js.map +1 -0
- package/dist/browser/helia/util.d.ts +13 -0
- package/dist/browser/helia/util.js +98 -0
- package/dist/browser/helia/util.js.map +1 -0
- package/dist/browser/index.d.ts +244 -0
- package/dist/browser/index.js +36 -0
- package/dist/browser/index.js.map +1 -0
- package/dist/browser/logger.d.ts +12 -0
- package/dist/browser/logger.js +11 -0
- package/dist/browser/logger.js.map +1 -0
- package/dist/browser/pages/pages-client-manager.d.ts +159 -0
- package/dist/browser/pages/pages-client-manager.js +334 -0
- package/dist/browser/pages/pages-client-manager.js.map +1 -0
- package/dist/browser/pages/pages-clients.d.ts +11 -0
- package/dist/browser/pages/pages-clients.js +10 -0
- package/dist/browser/pages/pages-clients.js.map +1 -0
- package/dist/browser/pages/pages.d.ts +107 -0
- package/dist/browser/pages/pages.js +262 -0
- package/dist/browser/pages/pages.js.map +1 -0
- package/dist/browser/pages/schema-util.d.ts +3 -0
- package/dist/browser/pages/schema-util.js +3 -0
- package/dist/browser/pages/schema-util.js.map +1 -0
- package/dist/browser/pages/schema.d.ts +719 -0
- package/dist/browser/pages/schema.js +32 -0
- package/dist/browser/pages/schema.js.map +1 -0
- package/dist/browser/pages/types.d.ts +44 -0
- package/dist/browser/pages/types.js +2 -0
- package/dist/browser/pages/types.js.map +1 -0
- package/dist/browser/pages/util.d.ts +56 -0
- package/dist/browser/pages/util.js +446 -0
- package/dist/browser/pages/util.js.map +1 -0
- package/dist/browser/pkc/pkc-client-manager.d.ts +44 -0
- package/dist/browser/pkc/pkc-client-manager.js +156 -0
- package/dist/browser/pkc/pkc-client-manager.js.map +1 -0
- package/dist/browser/pkc/pkc-clients.d.ts +11 -0
- package/dist/browser/pkc/pkc-clients.js +8 -0
- package/dist/browser/pkc/pkc-clients.js.map +1 -0
- package/dist/browser/pkc/pkc-with-rpc-client.d.ts +19 -0
- package/dist/browser/pkc/pkc-with-rpc-client.js +128 -0
- package/dist/browser/pkc/pkc-with-rpc-client.js.map +1 -0
- package/dist/browser/pkc/pkc.d.ts +137 -0
- package/dist/browser/pkc/pkc.js +888 -0
- package/dist/browser/pkc/pkc.js.map +1 -0
- package/dist/browser/pkc/tracked-instance-registry-util.d.ts +44 -0
- package/dist/browser/pkc/tracked-instance-registry-util.js +106 -0
- package/dist/browser/pkc/tracked-instance-registry-util.js.map +1 -0
- package/dist/browser/pkc/tracked-instance-registry.d.ts +18 -0
- package/dist/browser/pkc/tracked-instance-registry.js +134 -0
- package/dist/browser/pkc/tracked-instance-registry.js.map +1 -0
- package/dist/browser/pkc-error.d.ts +65 -0
- package/dist/browser/pkc-error.js +137 -0
- package/dist/browser/pkc-error.js.map +1 -0
- package/dist/browser/publications/comment/comment-client-manager.d.ts +86 -0
- package/dist/browser/publications/comment/comment-client-manager.js +908 -0
- package/dist/browser/publications/comment/comment-client-manager.js.map +1 -0
- package/dist/browser/publications/comment/comment-clients.d.ts +19 -0
- package/dist/browser/publications/comment/comment-clients.js +12 -0
- package/dist/browser/publications/comment/comment-clients.js.map +1 -0
- package/dist/browser/publications/comment/comment-util.d.ts +10 -0
- package/dist/browser/publications/comment/comment-util.js +202 -0
- package/dist/browser/publications/comment/comment-util.js.map +1 -0
- package/dist/browser/publications/comment/comment.d.ts +147 -0
- package/dist/browser/publications/comment/comment.js +1044 -0
- package/dist/browser/publications/comment/comment.js.map +1 -0
- package/dist/browser/publications/comment/schema.d.ts +1237 -0
- package/dist/browser/publications/comment/schema.js +184 -0
- package/dist/browser/publications/comment/schema.js.map +1 -0
- package/dist/browser/publications/comment/types.d.ts +100 -0
- package/dist/browser/publications/comment/types.js +2 -0
- package/dist/browser/publications/comment/types.js.map +1 -0
- package/dist/browser/publications/comment-edit/comment-edit.d.ts +41 -0
- package/dist/browser/publications/comment-edit/comment-edit.js +63 -0
- package/dist/browser/publications/comment-edit/comment-edit.js.map +1 -0
- package/dist/browser/publications/comment-edit/schema.d.ts +295 -0
- package/dist/browser/publications/comment-edit/schema.js +55 -0
- package/dist/browser/publications/comment-edit/schema.js.map +1 -0
- package/dist/browser/publications/comment-edit/types.d.ts +25 -0
- package/dist/browser/publications/comment-edit/types.js +2 -0
- package/dist/browser/publications/comment-edit/types.js.map +1 -0
- package/dist/browser/publications/comment-moderation/comment-moderation.d.ts +36 -0
- package/dist/browser/publications/comment-moderation/comment-moderation.js +53 -0
- package/dist/browser/publications/comment-moderation/comment-moderation.js.map +1 -0
- package/dist/browser/publications/comment-moderation/schema.d.ts +315 -0
- package/dist/browser/publications/comment-moderation/schema.js +62 -0
- package/dist/browser/publications/comment-moderation/schema.js.map +1 -0
- package/dist/browser/publications/comment-moderation/types.d.ts +22 -0
- package/dist/browser/publications/comment-moderation/types.js +2 -0
- package/dist/browser/publications/comment-moderation/types.js.map +1 -0
- package/dist/browser/publications/community-edit/community-edit.d.ts +35 -0
- package/dist/browser/publications/community-edit/community-edit.js +50 -0
- package/dist/browser/publications/community-edit/community-edit.js.map +1 -0
- package/dist/browser/publications/community-edit/schema.d.ts +467 -0
- package/dist/browser/publications/community-edit/schema.js +36 -0
- package/dist/browser/publications/community-edit/schema.js.map +1 -0
- package/dist/browser/publications/community-edit/types.d.ts +19 -0
- package/dist/browser/publications/community-edit/types.js +2 -0
- package/dist/browser/publications/community-edit/types.js.map +1 -0
- package/dist/browser/publications/publication-author.d.ts +22 -0
- package/dist/browser/publications/publication-author.js +66 -0
- package/dist/browser/publications/publication-author.js.map +1 -0
- package/dist/browser/publications/publication-client-manager.d.ts +62 -0
- package/dist/browser/publications/publication-client-manager.js +257 -0
- package/dist/browser/publications/publication-client-manager.js.map +1 -0
- package/dist/browser/publications/publication-clients.d.ts +19 -0
- package/dist/browser/publications/publication-clients.js +12 -0
- package/dist/browser/publications/publication-clients.js.map +1 -0
- package/dist/browser/publications/publication-community.d.ts +55 -0
- package/dist/browser/publications/publication-community.js +87 -0
- package/dist/browser/publications/publication-community.js.map +1 -0
- package/dist/browser/publications/publication.d.ts +120 -0
- package/dist/browser/publications/publication.js +950 -0
- package/dist/browser/publications/publication.js.map +1 -0
- package/dist/browser/publications/types.d.ts +26 -0
- package/dist/browser/publications/types.js +2 -0
- package/dist/browser/publications/types.js.map +1 -0
- package/dist/browser/publications/vote/schema.d.ts +150 -0
- package/dist/browser/publications/vote/schema.js +44 -0
- package/dist/browser/publications/vote/schema.js.map +1 -0
- package/dist/browser/publications/vote/types.d.ts +21 -0
- package/dist/browser/publications/vote/types.js +2 -0
- package/dist/browser/publications/vote/types.js.map +1 -0
- package/dist/browser/publications/vote/vote.d.ts +36 -0
- package/dist/browser/publications/vote/vote.js +49 -0
- package/dist/browser/publications/vote/vote.js.map +1 -0
- package/dist/browser/pubsub-messages/schema.d.ts +964 -0
- package/dist/browser/pubsub-messages/schema.js +98 -0
- package/dist/browser/pubsub-messages/schema.js.map +1 -0
- package/dist/browser/pubsub-messages/types.d.ts +81 -0
- package/dist/browser/pubsub-messages/types.js +2 -0
- package/dist/browser/pubsub-messages/types.js.map +1 -0
- package/dist/browser/rpc/src/index.d.ts +483 -0
- package/dist/browser/rpc/src/index.js +1267 -0
- package/dist/browser/rpc/src/index.js.map +1 -0
- package/dist/browser/rpc/src/json-rpc-util.d.ts +1 -0
- package/dist/browser/rpc/src/json-rpc-util.js +19 -0
- package/dist/browser/rpc/src/json-rpc-util.js.map +1 -0
- package/dist/browser/rpc/src/lib/pkc-js/index.d.ts +132 -0
- package/dist/browser/rpc/src/lib/pkc-js/index.js +29 -0
- package/dist/browser/rpc/src/lib/pkc-js/index.js.map +1 -0
- package/dist/browser/rpc/src/lib/pkc-js/pkc-js-mock.d.ts +1 -0
- package/dist/browser/rpc/src/lib/pkc-js/pkc-js-mock.js +472 -0
- package/dist/browser/rpc/src/lib/pkc-js/pkc-js-mock.js.map +1 -0
- package/dist/browser/rpc/src/schema.d.ts +843 -0
- package/dist/browser/rpc/src/schema.js +28 -0
- package/dist/browser/rpc/src/schema.js.map +1 -0
- package/dist/browser/rpc/src/types.d.ts +24 -0
- package/dist/browser/rpc/src/types.js +2 -0
- package/dist/browser/rpc/src/types.js.map +1 -0
- package/dist/browser/rpc/src/utils.d.ts +7 -0
- package/dist/browser/rpc/src/utils.js +58 -0
- package/dist/browser/rpc/src/utils.js.map +1 -0
- package/dist/browser/runtime/browser/community/challenges/index.d.ts +6 -0
- package/dist/browser/runtime/browser/community/challenges/index.js +7 -0
- package/dist/browser/runtime/browser/community/challenges/index.js.map +1 -0
- package/dist/browser/runtime/browser/community/local-community.d.ts +3 -0
- package/dist/browser/runtime/browser/community/local-community.js +6 -0
- package/dist/browser/runtime/browser/community/local-community.js.map +1 -0
- package/dist/browser/runtime/browser/db-handler.d.ts +4 -0
- package/dist/browser/runtime/browser/db-handler.js +8 -0
- package/dist/browser/runtime/browser/db-handler.js.map +1 -0
- package/dist/browser/runtime/browser/localforage-lru.d.ts +15 -0
- package/dist/browser/runtime/browser/localforage-lru.js +140 -0
- package/dist/browser/runtime/browser/localforage-lru.js.map +1 -0
- package/dist/browser/runtime/browser/lru-storage.d.ts +14 -0
- package/dist/browser/runtime/browser/lru-storage.js +34 -0
- package/dist/browser/runtime/browser/lru-storage.js.map +1 -0
- package/dist/browser/runtime/browser/native-functions.d.ts +3 -0
- package/dist/browser/runtime/browser/native-functions.js +6 -0
- package/dist/browser/runtime/browser/native-functions.js.map +1 -0
- package/dist/browser/runtime/browser/polyfill.d.ts +3 -0
- package/dist/browser/runtime/browser/polyfill.js +37 -0
- package/dist/browser/runtime/browser/polyfill.js.map +1 -0
- package/dist/browser/runtime/browser/setup-kubo-address-rewriter-and-http-router.d.ts +1 -0
- package/dist/browser/runtime/browser/setup-kubo-address-rewriter-and-http-router.js +4 -0
- package/dist/browser/runtime/browser/setup-kubo-address-rewriter-and-http-router.js.map +1 -0
- package/dist/browser/runtime/browser/storage.d.ts +13 -0
- package/dist/browser/runtime/browser/storage.js +37 -0
- package/dist/browser/runtime/browser/storage.js.map +1 -0
- package/dist/browser/runtime/browser/util.d.ts +14 -0
- package/dist/browser/runtime/browser/util.js +61 -0
- package/dist/browser/runtime/browser/util.js.map +1 -0
- package/dist/browser/runtime/node/address-rewriter-db.d.ts +31 -0
- package/dist/browser/runtime/node/address-rewriter-db.js +156 -0
- package/dist/browser/runtime/node/address-rewriter-db.js.map +1 -0
- package/dist/browser/runtime/node/addresses-rewriter-proxy-server.d.ts +45 -0
- package/dist/browser/runtime/node/addresses-rewriter-proxy-server.js +493 -0
- package/dist/browser/runtime/node/addresses-rewriter-proxy-server.js.map +1 -0
- package/dist/browser/runtime/node/community/challenges/exclude/exclude.d.ts +8 -0
- package/dist/browser/runtime/node/community/challenges/exclude/exclude.js +280 -0
- package/dist/browser/runtime/node/community/challenges/exclude/exclude.js.map +1 -0
- package/dist/browser/runtime/node/community/challenges/exclude/index.d.ts +3 -0
- package/dist/browser/runtime/node/community/challenges/exclude/index.js +4 -0
- package/dist/browser/runtime/node/community/challenges/exclude/index.js.map +1 -0
- package/dist/browser/runtime/node/community/challenges/exclude/rate-limiter.d.ts +5 -0
- package/dist/browser/runtime/node/community/challenges/exclude/rate-limiter.js +127 -0
- package/dist/browser/runtime/node/community/challenges/exclude/rate-limiter.js.map +1 -0
- package/dist/browser/runtime/node/community/challenges/exclude/utils.d.ts +13 -0
- package/dist/browser/runtime/node/community/challenges/exclude/utils.js +52 -0
- package/dist/browser/runtime/node/community/challenges/exclude/utils.js.map +1 -0
- package/dist/browser/runtime/node/community/challenges/index.d.ts +32 -0
- package/dist/browser/runtime/node/community/challenges/index.js +307 -0
- package/dist/browser/runtime/node/community/challenges/index.js.map +1 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/blacklist.d.ts +5 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/blacklist.js +118 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/blacklist.js.map +1 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/fail.d.ts +5 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/fail.js +26 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/fail.js.map +1 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/publication-match.d.ts +5 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/publication-match.js +135 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/publication-match.js.map +1 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/question.d.ts +5 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/question.js +66 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/question.js.map +1 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/text-math.d.ts +5 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/text-math.js +61 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/text-math.js.map +1 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/whitelist.d.ts +5 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/whitelist.js +118 -0
- package/dist/browser/runtime/node/community/challenges/pkc-js-challenges/whitelist.js.map +1 -0
- package/dist/browser/runtime/node/community/db-handler-types.d.ts +19 -0
- package/dist/browser/runtime/node/community/db-handler-types.js +2 -0
- package/dist/browser/runtime/node/community/db-handler-types.js.map +1 -0
- package/dist/browser/runtime/node/community/db-handler.d.ts +226 -0
- package/dist/browser/runtime/node/community/db-handler.js +2462 -0
- package/dist/browser/runtime/node/community/db-handler.js.map +1 -0
- package/dist/browser/runtime/node/community/db-row-parser.d.ts +19 -0
- package/dist/browser/runtime/node/community/db-row-parser.js +40 -0
- package/dist/browser/runtime/node/community/db-row-parser.js.map +1 -0
- package/dist/browser/runtime/node/community/keyv-better-sqlite3.d.ts +68 -0
- package/dist/browser/runtime/node/community/keyv-better-sqlite3.js +251 -0
- package/dist/browser/runtime/node/community/keyv-better-sqlite3.js.map +1 -0
- package/dist/browser/runtime/node/community/local-community.d.ts +129 -0
- package/dist/browser/runtime/node/community/local-community.js +2978 -0
- package/dist/browser/runtime/node/community/local-community.js.map +1 -0
- package/dist/browser/runtime/node/community/page-generator.d.ts +433 -0
- package/dist/browser/runtime/node/community/page-generator.js +441 -0
- package/dist/browser/runtime/node/community/page-generator.js.map +1 -0
- package/dist/browser/runtime/node/lru-storage.d.ts +14 -0
- package/dist/browser/runtime/node/lru-storage.js +40 -0
- package/dist/browser/runtime/node/lru-storage.js.map +1 -0
- package/dist/browser/runtime/node/native-functions.d.ts +3 -0
- package/dist/browser/runtime/node/native-functions.js +7 -0
- package/dist/browser/runtime/node/native-functions.js.map +1 -0
- package/dist/browser/runtime/node/polyfill.d.ts +3 -0
- package/dist/browser/runtime/node/polyfill.js +20 -0
- package/dist/browser/runtime/node/polyfill.js.map +1 -0
- package/dist/browser/runtime/node/setup-kubo-address-rewriter-and-http-router.d.ts +4 -0
- package/dist/browser/runtime/node/setup-kubo-address-rewriter-and-http-router.js +240 -0
- package/dist/browser/runtime/node/setup-kubo-address-rewriter-and-http-router.js.map +1 -0
- package/dist/browser/runtime/node/sqlite-lru-cache.d.ts +52 -0
- package/dist/browser/runtime/node/sqlite-lru-cache.js +127 -0
- package/dist/browser/runtime/node/sqlite-lru-cache.js.map +1 -0
- package/dist/browser/runtime/node/storage.d.ts +14 -0
- package/dist/browser/runtime/node/storage.js +52 -0
- package/dist/browser/runtime/node/storage.js.map +1 -0
- package/dist/browser/runtime/node/test/helpers/hanging-runner.d.ts +1 -0
- package/dist/browser/runtime/node/test/helpers/hanging-runner.js +157 -0
- package/dist/browser/runtime/node/test/helpers/hanging-runner.js.map +1 -0
- package/dist/browser/runtime/node/test/helpers/run-hanging-node.d.ts +7 -0
- package/dist/browser/runtime/node/test/helpers/run-hanging-node.js +68 -0
- package/dist/browser/runtime/node/test/helpers/run-hanging-node.js.map +1 -0
- package/dist/browser/runtime/node/test/mock-http-router.d.ts +54 -0
- package/dist/browser/runtime/node/test/mock-http-router.js +397 -0
- package/dist/browser/runtime/node/test/mock-http-router.js.map +1 -0
- package/dist/browser/runtime/node/util.d.ts +43 -0
- package/dist/browser/runtime/node/util.js +384 -0
- package/dist/browser/runtime/node/util.js.map +1 -0
- package/dist/browser/schema/schema-util.d.ts +2751 -0
- package/dist/browser/schema/schema-util.js +562 -0
- package/dist/browser/schema/schema-util.js.map +1 -0
- package/dist/browser/schema/schema.d.ts +237 -0
- package/dist/browser/schema/schema.js +128 -0
- package/dist/browser/schema/schema.js.map +1 -0
- package/dist/browser/schema.d.ts +1142 -0
- package/dist/browser/schema.js +104 -0
- package/dist/browser/schema.js.map +1 -0
- package/dist/browser/signer/constants.d.ts +2 -0
- package/dist/browser/signer/constants.js +3 -0
- package/dist/browser/signer/constants.js.map +1 -0
- package/dist/browser/signer/encryption.d.ts +21 -0
- package/dist/browser/signer/encryption.js +122 -0
- package/dist/browser/signer/encryption.js.map +1 -0
- package/dist/browser/signer/index.d.ts +21 -0
- package/dist/browser/signer/index.js +49 -0
- package/dist/browser/signer/index.js.map +1 -0
- package/dist/browser/signer/signatures.d.ts +200 -0
- package/dist/browser/signer/signatures.js +594 -0
- package/dist/browser/signer/signatures.js.map +1 -0
- package/dist/browser/signer/types.d.ts +20 -0
- package/dist/browser/signer/types.js +2 -0
- package/dist/browser/signer/types.js.map +1 -0
- package/dist/browser/signer/util.d.ts +14 -0
- package/dist/browser/signer/util.js +156 -0
- package/dist/browser/signer/util.js.map +1 -0
- package/dist/browser/stats.d.ts +15 -0
- package/dist/browser/stats.js +64 -0
- package/dist/browser/stats.js.map +1 -0
- package/dist/browser/test/mock-ipfs-client.d.ts +34 -0
- package/dist/browser/test/mock-ipfs-client.js +208 -0
- package/dist/browser/test/mock-ipfs-client.js.map +1 -0
- package/dist/browser/test/node/hanging-test/scenarios/comment-publish-pending.scenario.d.ts +8 -0
- package/dist/browser/test/node/hanging-test/scenarios/comment-publish-pending.scenario.js +21 -0
- package/dist/browser/test/node/hanging-test/scenarios/comment-publish-pending.scenario.js.map +1 -0
- package/dist/browser/test/node/hanging-test/scenarios/comment-publish.scenario.d.ts +8 -0
- package/dist/browser/test/node/hanging-test/scenarios/comment-publish.scenario.js +19 -0
- package/dist/browser/test/node/hanging-test/scenarios/comment-publish.scenario.js.map +1 -0
- package/dist/browser/test/node/hanging-test/scenarios/comment-update.scenario.d.ts +8 -0
- package/dist/browser/test/node/hanging-test/scenarios/comment-update.scenario.js +22 -0
- package/dist/browser/test/node/hanging-test/scenarios/comment-update.scenario.js.map +1 -0
- package/dist/browser/test/node/hanging-test/scenarios/community-start.scenario.d.ts +8 -0
- package/dist/browser/test/node/hanging-test/scenarios/community-start.scenario.js +23 -0
- package/dist/browser/test/node/hanging-test/scenarios/community-start.scenario.js.map +1 -0
- package/dist/browser/test/node/hanging-test/scenarios/community-update.scenario.d.ts +8 -0
- package/dist/browser/test/node/hanging-test/scenarios/community-update.scenario.js +21 -0
- package/dist/browser/test/node/hanging-test/scenarios/community-update.scenario.js.map +1 -0
- package/dist/browser/test/node/hanging-test/scenarios/destroy-only.scenario.d.ts +7 -0
- package/dist/browser/test/node/hanging-test/scenarios/destroy-only.scenario.js +15 -0
- package/dist/browser/test/node/hanging-test/scenarios/destroy-only.scenario.js.map +1 -0
- package/dist/browser/test/node/hanging-test/scenarios/hanging-test-util.d.ts +30 -0
- package/dist/browser/test/node/hanging-test/scenarios/hanging-test-util.js +46 -0
- package/dist/browser/test/node/hanging-test/scenarios/hanging-test-util.js.map +1 -0
- package/dist/browser/test/test-util.d.ts +1019 -0
- package/dist/browser/test/test-util.js +1886 -0
- package/dist/browser/test/test-util.js.map +1 -0
- package/dist/browser/types.d.ts +165 -0
- package/dist/browser/types.js +2 -0
- package/dist/browser/types.js.map +1 -0
- package/dist/browser/util/inflight-fetch-manager.d.ts +11 -0
- package/dist/browser/util/inflight-fetch-manager.js +41 -0
- package/dist/browser/util/inflight-fetch-manager.js.map +1 -0
- package/dist/browser/util.d.ts +120 -0
- package/dist/browser/util.js +816 -0
- package/dist/browser/util.js.map +1 -0
- package/dist/browser/version.d.ts +7 -0
- package/dist/browser/version.js +12 -0
- package/dist/browser/version.js.map +1 -0
- package/dist/browser/zod-error-map.d.ts +1 -0
- package/dist/browser/zod-error-map.js +10 -0
- package/dist/browser/zod-error-map.js.map +1 -0
- package/dist/node/challenges.d.ts +1 -0
- package/dist/node/challenges.js +2 -0
- package/dist/node/challenges.js.map +1 -0
- package/dist/node/clients/base-client-manager.d.ts +126 -0
- package/dist/node/clients/base-client-manager.js +673 -0
- package/dist/node/clients/base-client-manager.js.map +1 -0
- package/dist/node/clients/name-resolver-client.d.ts +8 -0
- package/dist/node/clients/name-resolver-client.js +10 -0
- package/dist/node/clients/name-resolver-client.js.map +1 -0
- package/dist/node/clients/pkc-typed-emitter.d.ts +9 -0
- package/dist/node/clients/pkc-typed-emitter.js +52 -0
- package/dist/node/clients/pkc-typed-emitter.js.map +1 -0
- package/dist/node/clients/rpc-client/decode-rpc-response-util.d.ts +8 -0
- package/dist/node/clients/rpc-client/decode-rpc-response-util.js +53 -0
- package/dist/node/clients/rpc-client/decode-rpc-response-util.js.map +1 -0
- package/dist/node/clients/rpc-client/pkc-rpc-client.d.ts +68 -0
- package/dist/node/clients/rpc-client/pkc-rpc-client.js +404 -0
- package/dist/node/clients/rpc-client/pkc-rpc-client.js.map +1 -0
- package/dist/node/clients/rpc-client/rpc-schema-util.d.ts +147 -0
- package/dist/node/clients/rpc-client/rpc-schema-util.js +11 -0
- package/dist/node/clients/rpc-client/rpc-schema-util.js.map +1 -0
- package/dist/node/clients/rpc-client/schema.d.ts +433 -0
- package/dist/node/clients/rpc-client/schema.js +49 -0
- package/dist/node/clients/rpc-client/schema.js.map +1 -0
- package/dist/node/clients/rpc-client/types.d.ts +8 -0
- package/dist/node/clients/rpc-client/types.js +2 -0
- package/dist/node/clients/rpc-client/types.js.map +1 -0
- package/dist/node/community/community-client-manager.d.ts +60 -0
- package/dist/node/community/community-client-manager.js +717 -0
- package/dist/node/community/community-client-manager.js.map +1 -0
- package/dist/node/community/community-clients.d.ts +18 -0
- package/dist/node/community/community-clients.js +12 -0
- package/dist/node/community/community-clients.js.map +1 -0
- package/dist/node/community/community-wire.d.ts +20 -0
- package/dist/node/community/community-wire.js +38 -0
- package/dist/node/community/community-wire.js.map +1 -0
- package/dist/node/community/remote-community.d.ts +110 -0
- package/dist/node/community/remote-community.js +555 -0
- package/dist/node/community/remote-community.js.map +1 -0
- package/dist/node/community/rpc-local-community.d.ts +41 -0
- package/dist/node/community/rpc-local-community.js +289 -0
- package/dist/node/community/rpc-local-community.js.map +1 -0
- package/dist/node/community/rpc-remote-community.d.ts +18 -0
- package/dist/node/community/rpc-remote-community.js +286 -0
- package/dist/node/community/rpc-remote-community.js.map +1 -0
- package/dist/node/community/schema.d.ts +4217 -0
- package/dist/node/community/schema.js +289 -0
- package/dist/node/community/schema.js.map +1 -0
- package/dist/node/community/types.d.ts +135 -0
- package/dist/node/community/types.js +2 -0
- package/dist/node/community/types.js.map +1 -0
- package/dist/node/constants.d.ts +6 -0
- package/dist/node/constants.js +9 -0
- package/dist/node/constants.js.map +1 -0
- package/dist/node/decorator-util.d.ts +1 -0
- package/dist/node/decorator-util.js +35 -0
- package/dist/node/decorator-util.js.map +1 -0
- package/dist/node/errors.d.ts +343 -0
- package/dist/node/errors.js +358 -0
- package/dist/node/errors.js.map +1 -0
- package/dist/node/general-util/limited-set.d.ts +15 -0
- package/dist/node/general-util/limited-set.js +66 -0
- package/dist/node/general-util/limited-set.js.map +1 -0
- package/dist/node/generated-version.d.ts +1 -0
- package/dist/node/generated-version.js +3 -0
- package/dist/node/generated-version.js.map +1 -0
- package/dist/node/generic-state-client.d.ts +6 -0
- package/dist/node/generic-state-client.js +11 -0
- package/dist/node/generic-state-client.js.map +1 -0
- package/dist/node/helia/helia-for-pkc.d.ts +3 -0
- package/dist/node/helia/helia-for-pkc.js +255 -0
- package/dist/node/helia/helia-for-pkc.js.map +1 -0
- package/dist/node/helia/ipns-over-pubsub-with-fetch.d.ts +36 -0
- package/dist/node/helia/ipns-over-pubsub-with-fetch.js +229 -0
- package/dist/node/helia/ipns-over-pubsub-with-fetch.js.map +1 -0
- package/dist/node/helia/libp2pjsClient.d.ts +27 -0
- package/dist/node/helia/libp2pjsClient.js +15 -0
- package/dist/node/helia/libp2pjsClient.js.map +1 -0
- package/dist/node/helia/types.d.ts +19 -0
- package/dist/node/helia/types.js +2 -0
- package/dist/node/helia/types.js.map +1 -0
- package/dist/node/helia/util.d.ts +13 -0
- package/dist/node/helia/util.js +98 -0
- package/dist/node/helia/util.js.map +1 -0
- package/dist/node/index.d.ts +244 -0
- package/dist/node/index.js +36 -0
- package/dist/node/index.js.map +1 -0
- package/dist/node/logger.d.ts +12 -0
- package/dist/node/logger.js +11 -0
- package/dist/node/logger.js.map +1 -0
- package/dist/node/pages/pages-client-manager.d.ts +159 -0
- package/dist/node/pages/pages-client-manager.js +334 -0
- package/dist/node/pages/pages-client-manager.js.map +1 -0
- package/dist/node/pages/pages-clients.d.ts +11 -0
- package/dist/node/pages/pages-clients.js +10 -0
- package/dist/node/pages/pages-clients.js.map +1 -0
- package/dist/node/pages/pages.d.ts +107 -0
- package/dist/node/pages/pages.js +262 -0
- package/dist/node/pages/pages.js.map +1 -0
- package/dist/node/pages/schema-util.d.ts +3 -0
- package/dist/node/pages/schema-util.js +3 -0
- package/dist/node/pages/schema-util.js.map +1 -0
- package/dist/node/pages/schema.d.ts +719 -0
- package/dist/node/pages/schema.js +32 -0
- package/dist/node/pages/schema.js.map +1 -0
- package/dist/node/pages/types.d.ts +44 -0
- package/dist/node/pages/types.js +2 -0
- package/dist/node/pages/types.js.map +1 -0
- package/dist/node/pages/util.d.ts +56 -0
- package/dist/node/pages/util.js +446 -0
- package/dist/node/pages/util.js.map +1 -0
- package/dist/node/pkc/pkc-client-manager.d.ts +44 -0
- package/dist/node/pkc/pkc-client-manager.js +156 -0
- package/dist/node/pkc/pkc-client-manager.js.map +1 -0
- package/dist/node/pkc/pkc-clients.d.ts +11 -0
- package/dist/node/pkc/pkc-clients.js +8 -0
- package/dist/node/pkc/pkc-clients.js.map +1 -0
- package/dist/node/pkc/pkc-with-rpc-client.d.ts +19 -0
- package/dist/node/pkc/pkc-with-rpc-client.js +128 -0
- package/dist/node/pkc/pkc-with-rpc-client.js.map +1 -0
- package/dist/node/pkc/pkc.d.ts +137 -0
- package/dist/node/pkc/pkc.js +888 -0
- package/dist/node/pkc/pkc.js.map +1 -0
- package/dist/node/pkc/tracked-instance-registry-util.d.ts +44 -0
- package/dist/node/pkc/tracked-instance-registry-util.js +106 -0
- package/dist/node/pkc/tracked-instance-registry-util.js.map +1 -0
- package/dist/node/pkc/tracked-instance-registry.d.ts +18 -0
- package/dist/node/pkc/tracked-instance-registry.js +134 -0
- package/dist/node/pkc/tracked-instance-registry.js.map +1 -0
- package/dist/node/pkc-error.d.ts +65 -0
- package/dist/node/pkc-error.js +137 -0
- package/dist/node/pkc-error.js.map +1 -0
- package/dist/node/publications/comment/comment-client-manager.d.ts +86 -0
- package/dist/node/publications/comment/comment-client-manager.js +908 -0
- package/dist/node/publications/comment/comment-client-manager.js.map +1 -0
- package/dist/node/publications/comment/comment-clients.d.ts +19 -0
- package/dist/node/publications/comment/comment-clients.js +12 -0
- package/dist/node/publications/comment/comment-clients.js.map +1 -0
- package/dist/node/publications/comment/comment-util.d.ts +10 -0
- package/dist/node/publications/comment/comment-util.js +202 -0
- package/dist/node/publications/comment/comment-util.js.map +1 -0
- package/dist/node/publications/comment/comment.d.ts +147 -0
- package/dist/node/publications/comment/comment.js +1044 -0
- package/dist/node/publications/comment/comment.js.map +1 -0
- package/dist/node/publications/comment/schema.d.ts +1237 -0
- package/dist/node/publications/comment/schema.js +184 -0
- package/dist/node/publications/comment/schema.js.map +1 -0
- package/dist/node/publications/comment/types.d.ts +100 -0
- package/dist/node/publications/comment/types.js +2 -0
- package/dist/node/publications/comment/types.js.map +1 -0
- package/dist/node/publications/comment-edit/comment-edit.d.ts +41 -0
- package/dist/node/publications/comment-edit/comment-edit.js +63 -0
- package/dist/node/publications/comment-edit/comment-edit.js.map +1 -0
- package/dist/node/publications/comment-edit/schema.d.ts +295 -0
- package/dist/node/publications/comment-edit/schema.js +55 -0
- package/dist/node/publications/comment-edit/schema.js.map +1 -0
- package/dist/node/publications/comment-edit/types.d.ts +25 -0
- package/dist/node/publications/comment-edit/types.js +2 -0
- package/dist/node/publications/comment-edit/types.js.map +1 -0
- package/dist/node/publications/comment-moderation/comment-moderation.d.ts +36 -0
- package/dist/node/publications/comment-moderation/comment-moderation.js +53 -0
- package/dist/node/publications/comment-moderation/comment-moderation.js.map +1 -0
- package/dist/node/publications/comment-moderation/schema.d.ts +315 -0
- package/dist/node/publications/comment-moderation/schema.js +62 -0
- package/dist/node/publications/comment-moderation/schema.js.map +1 -0
- package/dist/node/publications/comment-moderation/types.d.ts +22 -0
- package/dist/node/publications/comment-moderation/types.js +2 -0
- package/dist/node/publications/comment-moderation/types.js.map +1 -0
- package/dist/node/publications/community-edit/community-edit.d.ts +35 -0
- package/dist/node/publications/community-edit/community-edit.js +50 -0
- package/dist/node/publications/community-edit/community-edit.js.map +1 -0
- package/dist/node/publications/community-edit/schema.d.ts +467 -0
- package/dist/node/publications/community-edit/schema.js +36 -0
- package/dist/node/publications/community-edit/schema.js.map +1 -0
- package/dist/node/publications/community-edit/types.d.ts +19 -0
- package/dist/node/publications/community-edit/types.js +2 -0
- package/dist/node/publications/community-edit/types.js.map +1 -0
- package/dist/node/publications/publication-author.d.ts +22 -0
- package/dist/node/publications/publication-author.js +66 -0
- package/dist/node/publications/publication-author.js.map +1 -0
- package/dist/node/publications/publication-client-manager.d.ts +62 -0
- package/dist/node/publications/publication-client-manager.js +257 -0
- package/dist/node/publications/publication-client-manager.js.map +1 -0
- package/dist/node/publications/publication-clients.d.ts +19 -0
- package/dist/node/publications/publication-clients.js +12 -0
- package/dist/node/publications/publication-clients.js.map +1 -0
- package/dist/node/publications/publication-community.d.ts +55 -0
- package/dist/node/publications/publication-community.js +87 -0
- package/dist/node/publications/publication-community.js.map +1 -0
- package/dist/node/publications/publication.d.ts +120 -0
- package/dist/node/publications/publication.js +950 -0
- package/dist/node/publications/publication.js.map +1 -0
- package/dist/node/publications/types.d.ts +26 -0
- package/dist/node/publications/types.js +2 -0
- package/dist/node/publications/types.js.map +1 -0
- package/dist/node/publications/vote/schema.d.ts +150 -0
- package/dist/node/publications/vote/schema.js +44 -0
- package/dist/node/publications/vote/schema.js.map +1 -0
- package/dist/node/publications/vote/types.d.ts +21 -0
- package/dist/node/publications/vote/types.js +2 -0
- package/dist/node/publications/vote/types.js.map +1 -0
- package/dist/node/publications/vote/vote.d.ts +36 -0
- package/dist/node/publications/vote/vote.js +49 -0
- package/dist/node/publications/vote/vote.js.map +1 -0
- package/dist/node/pubsub-messages/schema.d.ts +964 -0
- package/dist/node/pubsub-messages/schema.js +98 -0
- package/dist/node/pubsub-messages/schema.js.map +1 -0
- package/dist/node/pubsub-messages/types.d.ts +81 -0
- package/dist/node/pubsub-messages/types.js +2 -0
- package/dist/node/pubsub-messages/types.js.map +1 -0
- package/dist/node/rpc/src/index.d.ts +483 -0
- package/dist/node/rpc/src/index.js +1267 -0
- package/dist/node/rpc/src/index.js.map +1 -0
- package/dist/node/rpc/src/json-rpc-util.d.ts +1 -0
- package/dist/node/rpc/src/json-rpc-util.js +19 -0
- package/dist/node/rpc/src/json-rpc-util.js.map +1 -0
- package/dist/node/rpc/src/lib/pkc-js/index.d.ts +132 -0
- package/dist/node/rpc/src/lib/pkc-js/index.js +29 -0
- package/dist/node/rpc/src/lib/pkc-js/index.js.map +1 -0
- package/dist/node/rpc/src/lib/pkc-js/pkc-js-mock.d.ts +1 -0
- package/dist/node/rpc/src/lib/pkc-js/pkc-js-mock.js +472 -0
- package/dist/node/rpc/src/lib/pkc-js/pkc-js-mock.js.map +1 -0
- package/dist/node/rpc/src/schema.d.ts +843 -0
- package/dist/node/rpc/src/schema.js +28 -0
- package/dist/node/rpc/src/schema.js.map +1 -0
- package/dist/node/rpc/src/types.d.ts +24 -0
- package/dist/node/rpc/src/types.js +2 -0
- package/dist/node/rpc/src/types.js.map +1 -0
- package/dist/node/rpc/src/utils.d.ts +7 -0
- package/dist/node/rpc/src/utils.js +58 -0
- package/dist/node/rpc/src/utils.js.map +1 -0
- package/dist/node/runtime/browser/community/challenges/index.d.ts +6 -0
- package/dist/node/runtime/browser/community/challenges/index.js +7 -0
- package/dist/node/runtime/browser/community/challenges/index.js.map +1 -0
- package/dist/node/runtime/browser/community/local-community.d.ts +3 -0
- package/dist/node/runtime/browser/community/local-community.js +6 -0
- package/dist/node/runtime/browser/community/local-community.js.map +1 -0
- package/dist/node/runtime/browser/db-handler.d.ts +4 -0
- package/dist/node/runtime/browser/db-handler.js +8 -0
- package/dist/node/runtime/browser/db-handler.js.map +1 -0
- package/dist/node/runtime/browser/localforage-lru.d.ts +15 -0
- package/dist/node/runtime/browser/localforage-lru.js +140 -0
- package/dist/node/runtime/browser/localforage-lru.js.map +1 -0
- package/dist/node/runtime/browser/lru-storage.d.ts +14 -0
- package/dist/node/runtime/browser/lru-storage.js +34 -0
- package/dist/node/runtime/browser/lru-storage.js.map +1 -0
- package/dist/node/runtime/browser/native-functions.d.ts +3 -0
- package/dist/node/runtime/browser/native-functions.js +6 -0
- package/dist/node/runtime/browser/native-functions.js.map +1 -0
- package/dist/node/runtime/browser/polyfill.d.ts +3 -0
- package/dist/node/runtime/browser/polyfill.js +37 -0
- package/dist/node/runtime/browser/polyfill.js.map +1 -0
- package/dist/node/runtime/browser/setup-kubo-address-rewriter-and-http-router.d.ts +1 -0
- package/dist/node/runtime/browser/setup-kubo-address-rewriter-and-http-router.js +4 -0
- package/dist/node/runtime/browser/setup-kubo-address-rewriter-and-http-router.js.map +1 -0
- package/dist/node/runtime/browser/storage.d.ts +13 -0
- package/dist/node/runtime/browser/storage.js +37 -0
- package/dist/node/runtime/browser/storage.js.map +1 -0
- package/dist/node/runtime/browser/util.d.ts +14 -0
- package/dist/node/runtime/browser/util.js +61 -0
- package/dist/node/runtime/browser/util.js.map +1 -0
- package/dist/node/runtime/node/address-rewriter-db.d.ts +31 -0
- package/dist/node/runtime/node/address-rewriter-db.js +156 -0
- package/dist/node/runtime/node/address-rewriter-db.js.map +1 -0
- package/dist/node/runtime/node/addresses-rewriter-proxy-server.d.ts +45 -0
- package/dist/node/runtime/node/addresses-rewriter-proxy-server.js +493 -0
- package/dist/node/runtime/node/addresses-rewriter-proxy-server.js.map +1 -0
- package/dist/node/runtime/node/community/challenges/exclude/exclude.d.ts +8 -0
- package/dist/node/runtime/node/community/challenges/exclude/exclude.js +280 -0
- package/dist/node/runtime/node/community/challenges/exclude/exclude.js.map +1 -0
- package/dist/node/runtime/node/community/challenges/exclude/index.d.ts +3 -0
- package/dist/node/runtime/node/community/challenges/exclude/index.js +4 -0
- package/dist/node/runtime/node/community/challenges/exclude/index.js.map +1 -0
- package/dist/node/runtime/node/community/challenges/exclude/rate-limiter.d.ts +5 -0
- package/dist/node/runtime/node/community/challenges/exclude/rate-limiter.js +127 -0
- package/dist/node/runtime/node/community/challenges/exclude/rate-limiter.js.map +1 -0
- package/dist/node/runtime/node/community/challenges/exclude/utils.d.ts +13 -0
- package/dist/node/runtime/node/community/challenges/exclude/utils.js +52 -0
- package/dist/node/runtime/node/community/challenges/exclude/utils.js.map +1 -0
- package/dist/node/runtime/node/community/challenges/index.d.ts +32 -0
- package/dist/node/runtime/node/community/challenges/index.js +307 -0
- package/dist/node/runtime/node/community/challenges/index.js.map +1 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/blacklist.d.ts +5 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/blacklist.js +118 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/blacklist.js.map +1 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/fail.d.ts +5 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/fail.js +26 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/fail.js.map +1 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/publication-match.d.ts +5 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/publication-match.js +135 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/publication-match.js.map +1 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/question.d.ts +5 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/question.js +66 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/question.js.map +1 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/text-math.d.ts +5 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/text-math.js +61 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/text-math.js.map +1 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/whitelist.d.ts +5 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/whitelist.js +118 -0
- package/dist/node/runtime/node/community/challenges/pkc-js-challenges/whitelist.js.map +1 -0
- package/dist/node/runtime/node/community/db-handler-types.d.ts +19 -0
- package/dist/node/runtime/node/community/db-handler-types.js +2 -0
- package/dist/node/runtime/node/community/db-handler-types.js.map +1 -0
- package/dist/node/runtime/node/community/db-handler.d.ts +226 -0
- package/dist/node/runtime/node/community/db-handler.js +2462 -0
- package/dist/node/runtime/node/community/db-handler.js.map +1 -0
- package/dist/node/runtime/node/community/db-row-parser.d.ts +19 -0
- package/dist/node/runtime/node/community/db-row-parser.js +40 -0
- package/dist/node/runtime/node/community/db-row-parser.js.map +1 -0
- package/dist/node/runtime/node/community/keyv-better-sqlite3.d.ts +68 -0
- package/dist/node/runtime/node/community/keyv-better-sqlite3.js +251 -0
- package/dist/node/runtime/node/community/keyv-better-sqlite3.js.map +1 -0
- package/dist/node/runtime/node/community/local-community.d.ts +129 -0
- package/dist/node/runtime/node/community/local-community.js +2978 -0
- package/dist/node/runtime/node/community/local-community.js.map +1 -0
- package/dist/node/runtime/node/community/page-generator.d.ts +433 -0
- package/dist/node/runtime/node/community/page-generator.js +441 -0
- package/dist/node/runtime/node/community/page-generator.js.map +1 -0
- package/dist/node/runtime/node/lru-storage.d.ts +14 -0
- package/dist/node/runtime/node/lru-storage.js +40 -0
- package/dist/node/runtime/node/lru-storage.js.map +1 -0
- package/dist/node/runtime/node/native-functions.d.ts +3 -0
- package/dist/node/runtime/node/native-functions.js +7 -0
- package/dist/node/runtime/node/native-functions.js.map +1 -0
- package/dist/node/runtime/node/polyfill.d.ts +3 -0
- package/dist/node/runtime/node/polyfill.js +20 -0
- package/dist/node/runtime/node/polyfill.js.map +1 -0
- package/dist/node/runtime/node/setup-kubo-address-rewriter-and-http-router.d.ts +4 -0
- package/dist/node/runtime/node/setup-kubo-address-rewriter-and-http-router.js +240 -0
- package/dist/node/runtime/node/setup-kubo-address-rewriter-and-http-router.js.map +1 -0
- package/dist/node/runtime/node/sqlite-lru-cache.d.ts +52 -0
- package/dist/node/runtime/node/sqlite-lru-cache.js +127 -0
- package/dist/node/runtime/node/sqlite-lru-cache.js.map +1 -0
- package/dist/node/runtime/node/storage.d.ts +14 -0
- package/dist/node/runtime/node/storage.js +52 -0
- package/dist/node/runtime/node/storage.js.map +1 -0
- package/dist/node/runtime/node/test/helpers/hanging-runner.d.ts +1 -0
- package/dist/node/runtime/node/test/helpers/hanging-runner.js +157 -0
- package/dist/node/runtime/node/test/helpers/hanging-runner.js.map +1 -0
- package/dist/node/runtime/node/test/helpers/run-hanging-node.d.ts +7 -0
- package/dist/node/runtime/node/test/helpers/run-hanging-node.js +68 -0
- package/dist/node/runtime/node/test/helpers/run-hanging-node.js.map +1 -0
- package/dist/node/runtime/node/test/mock-http-router.d.ts +54 -0
- package/dist/node/runtime/node/test/mock-http-router.js +397 -0
- package/dist/node/runtime/node/test/mock-http-router.js.map +1 -0
- package/dist/node/runtime/node/util.d.ts +43 -0
- package/dist/node/runtime/node/util.js +384 -0
- package/dist/node/runtime/node/util.js.map +1 -0
- package/dist/node/schema/schema-util.d.ts +2751 -0
- package/dist/node/schema/schema-util.js +562 -0
- package/dist/node/schema/schema-util.js.map +1 -0
- package/dist/node/schema/schema.d.ts +237 -0
- package/dist/node/schema/schema.js +128 -0
- package/dist/node/schema/schema.js.map +1 -0
- package/dist/node/schema.d.ts +1142 -0
- package/dist/node/schema.js +104 -0
- package/dist/node/schema.js.map +1 -0
- package/dist/node/signer/constants.d.ts +2 -0
- package/dist/node/signer/constants.js +3 -0
- package/dist/node/signer/constants.js.map +1 -0
- package/dist/node/signer/encryption.d.ts +21 -0
- package/dist/node/signer/encryption.js +122 -0
- package/dist/node/signer/encryption.js.map +1 -0
- package/dist/node/signer/index.d.ts +21 -0
- package/dist/node/signer/index.js +49 -0
- package/dist/node/signer/index.js.map +1 -0
- package/dist/node/signer/signatures.d.ts +200 -0
- package/dist/node/signer/signatures.js +594 -0
- package/dist/node/signer/signatures.js.map +1 -0
- package/dist/node/signer/types.d.ts +20 -0
- package/dist/node/signer/types.js +2 -0
- package/dist/node/signer/types.js.map +1 -0
- package/dist/node/signer/util.d.ts +14 -0
- package/dist/node/signer/util.js +156 -0
- package/dist/node/signer/util.js.map +1 -0
- package/dist/node/stats.d.ts +15 -0
- package/dist/node/stats.js +64 -0
- package/dist/node/stats.js.map +1 -0
- package/dist/node/test/mock-ipfs-client.d.ts +34 -0
- package/dist/node/test/mock-ipfs-client.js +208 -0
- package/dist/node/test/mock-ipfs-client.js.map +1 -0
- package/dist/node/test/node/hanging-test/scenarios/comment-publish-pending.scenario.d.ts +8 -0
- package/dist/node/test/node/hanging-test/scenarios/comment-publish-pending.scenario.js +21 -0
- package/dist/node/test/node/hanging-test/scenarios/comment-publish-pending.scenario.js.map +1 -0
- package/dist/node/test/node/hanging-test/scenarios/comment-publish.scenario.d.ts +8 -0
- package/dist/node/test/node/hanging-test/scenarios/comment-publish.scenario.js +19 -0
- package/dist/node/test/node/hanging-test/scenarios/comment-publish.scenario.js.map +1 -0
- package/dist/node/test/node/hanging-test/scenarios/comment-update.scenario.d.ts +8 -0
- package/dist/node/test/node/hanging-test/scenarios/comment-update.scenario.js +22 -0
- package/dist/node/test/node/hanging-test/scenarios/comment-update.scenario.js.map +1 -0
- package/dist/node/test/node/hanging-test/scenarios/community-start.scenario.d.ts +8 -0
- package/dist/node/test/node/hanging-test/scenarios/community-start.scenario.js +23 -0
- package/dist/node/test/node/hanging-test/scenarios/community-start.scenario.js.map +1 -0
- package/dist/node/test/node/hanging-test/scenarios/community-update.scenario.d.ts +8 -0
- package/dist/node/test/node/hanging-test/scenarios/community-update.scenario.js +21 -0
- package/dist/node/test/node/hanging-test/scenarios/community-update.scenario.js.map +1 -0
- package/dist/node/test/node/hanging-test/scenarios/destroy-only.scenario.d.ts +7 -0
- package/dist/node/test/node/hanging-test/scenarios/destroy-only.scenario.js +15 -0
- package/dist/node/test/node/hanging-test/scenarios/destroy-only.scenario.js.map +1 -0
- package/dist/node/test/node/hanging-test/scenarios/hanging-test-util.d.ts +30 -0
- package/dist/node/test/node/hanging-test/scenarios/hanging-test-util.js +46 -0
- package/dist/node/test/node/hanging-test/scenarios/hanging-test-util.js.map +1 -0
- package/dist/node/test/test-util.d.ts +1019 -0
- package/dist/node/test/test-util.js +1886 -0
- package/dist/node/test/test-util.js.map +1 -0
- package/dist/node/types.d.ts +165 -0
- package/dist/node/types.js +2 -0
- package/dist/node/types.js.map +1 -0
- package/dist/node/util/inflight-fetch-manager.d.ts +11 -0
- package/dist/node/util/inflight-fetch-manager.js +41 -0
- package/dist/node/util/inflight-fetch-manager.js.map +1 -0
- package/dist/node/util.d.ts +120 -0
- package/dist/node/util.js +816 -0
- package/dist/node/util.js.map +1 -0
- package/dist/node/version.d.ts +7 -0
- package/dist/node/version.js +12 -0
- package/dist/node/version.js.map +1 -0
- package/dist/node/zod-error-map.d.ts +1 -0
- package/dist/node/zod-error-map.js +10 -0
- package/dist/node/zod-error-map.js.map +1 -0
- package/package.json +212 -0
|
@@ -0,0 +1,1019 @@
|
|
|
1
|
+
import { Comment } from "../publications/comment/comment.js";
|
|
2
|
+
import { PKC } from "../pkc/pkc.js";
|
|
3
|
+
import Vote from "../publications/vote/vote.js";
|
|
4
|
+
import { RemoteCommunity } from "../community/remote-community.js";
|
|
5
|
+
import type { InputPKCOptions, NameResolver } from "../types.js";
|
|
6
|
+
import Publication from "../publications/publication.js";
|
|
7
|
+
import { EventEmitter } from "events";
|
|
8
|
+
import { LocalCommunity } from "../runtime/browser/community/local-community.js";
|
|
9
|
+
import { RpcLocalCommunity } from "../community/rpc-local-community.js";
|
|
10
|
+
import type { CreateNewLocalCommunityUserOptions, CommunityIpfsType, CommunityChallengeSetting } from "../community/types.js";
|
|
11
|
+
import type { SignerType } from "../signer/types.js";
|
|
12
|
+
import type { CreateVoteOptions } from "../publications/vote/types.js";
|
|
13
|
+
import type { CommentIpfsWithCidDefined, CommentWithinRepliesPostsPageJson, CreateCommentOptions } from "../publications/comment/types.js";
|
|
14
|
+
import { BasePages, PostsPages, RepliesPages } from "../pages/pages.js";
|
|
15
|
+
import { CommentEdit } from "../publications/comment-edit/comment-edit.js";
|
|
16
|
+
import type { CreateCommentEditOptions } from "../publications/comment-edit/types.js";
|
|
17
|
+
import type { ChallengeVerificationMessageType, DecryptedChallengeVerificationMessageType, PubsubMessage } from "../pubsub-messages/types.js";
|
|
18
|
+
import { CommentModeration } from "../publications/comment-moderation/comment-moderation.js";
|
|
19
|
+
import type { PageTypeJson } from "../pages/types.js";
|
|
20
|
+
interface MockPKCOptions {
|
|
21
|
+
pkcOptions?: InputPKCOptions;
|
|
22
|
+
forceMockPubsub?: boolean;
|
|
23
|
+
stubStorage?: boolean;
|
|
24
|
+
mockResolve?: boolean;
|
|
25
|
+
remotePKC?: boolean;
|
|
26
|
+
}
|
|
27
|
+
type MockResolverRecords = Map<string, string | undefined> | Record<string, string | undefined>;
|
|
28
|
+
export declare function createMockNameResolver({ records, includeDefaultRecords, key, provider, canResolve, resolveFunction }?: {
|
|
29
|
+
records?: MockResolverRecords;
|
|
30
|
+
includeDefaultRecords?: boolean;
|
|
31
|
+
key?: string;
|
|
32
|
+
provider?: string;
|
|
33
|
+
canResolve?: NameResolver["canResolve"];
|
|
34
|
+
resolveFunction?: NameResolver["resolve"];
|
|
35
|
+
}): NameResolver;
|
|
36
|
+
export declare function createPendingApprovalChallenge(overrides?: Partial<CommunityChallengeSetting>): CommunityChallengeSetting;
|
|
37
|
+
export declare function generateMockPost({ communityAddress, pkc, randomTimestamp, postProps }: {
|
|
38
|
+
communityAddress: string;
|
|
39
|
+
pkc: PKC;
|
|
40
|
+
randomTimestamp?: boolean;
|
|
41
|
+
postProps?: Partial<CreateCommentOptions>;
|
|
42
|
+
}): Promise<Comment>;
|
|
43
|
+
export declare function generateMockComment(parentPostOrComment: CommentIpfsWithCidDefined, pkc: PKC, randomTimestamp?: boolean, commentProps?: Partial<CreateCommentOptions>): Promise<Comment>;
|
|
44
|
+
export declare function generateMockVote(parentPostOrComment: CommentIpfsWithCidDefined, vote: -1 | 0 | 1, pkc: PKC, signer?: SignerType): Promise<Vote>;
|
|
45
|
+
export declare function loadAllPages(pageCid: string, pagesInstance: PostsPages | RepliesPages): Promise<CommentWithinRepliesPostsPageJson[]>;
|
|
46
|
+
export declare function loadAllPagesBySortName(pageSortName: string, pagesInstance: BasePages): Promise<CommentWithinRepliesPostsPageJson[] | import("../publications/comment/types.js").CommentWithinModQueuePageJson[]>;
|
|
47
|
+
export declare function loadAllUniquePostsUnderCommunity(community: RemoteCommunity): Promise<CommentWithinRepliesPostsPageJson[]>;
|
|
48
|
+
export declare function loadAllUniqueCommentsUnderCommentInstance(comment: Comment): Promise<CommentWithinRepliesPostsPageJson[]>;
|
|
49
|
+
type TestServerSubs = {
|
|
50
|
+
onlineSub?: LocalCommunity;
|
|
51
|
+
ensSub: LocalCommunity;
|
|
52
|
+
mainSub: LocalCommunity;
|
|
53
|
+
mathSub: LocalCommunity;
|
|
54
|
+
NoPubsubResponseSub: LocalCommunity;
|
|
55
|
+
mathCliSubWithNoMockedPubsub: LocalCommunity;
|
|
56
|
+
subForPurge: LocalCommunity;
|
|
57
|
+
subForRemove: LocalCommunity;
|
|
58
|
+
subForDelete: LocalCommunity;
|
|
59
|
+
subForChainProviders: LocalCommunity;
|
|
60
|
+
subForEditContent: LocalCommunity;
|
|
61
|
+
subForLocked: LocalCommunity;
|
|
62
|
+
};
|
|
63
|
+
export declare function startOnlineCommunity(): Promise<LocalCommunity>;
|
|
64
|
+
export declare function startCommunities(props: {
|
|
65
|
+
signers: SignerType[];
|
|
66
|
+
noData?: boolean;
|
|
67
|
+
dataPath?: string;
|
|
68
|
+
votesPerCommentToPublish: number;
|
|
69
|
+
numOfCommentsToPublish: number;
|
|
70
|
+
numOfPostsToPublish: number;
|
|
71
|
+
startOnlineSub: boolean;
|
|
72
|
+
}): Promise<TestServerSubs>;
|
|
73
|
+
export declare function fetchTestServerSubs(): Promise<TestServerSubs>;
|
|
74
|
+
export declare function mockDefaultOptionsForNodeAndBrowserTests(): Pick<InputPKCOptions, "pkcRpcClientsOptions" | "kuboRpcClientsOptions" | "ipfsGatewayUrls" | "pubsubKuboRpcClientsOptions" | "httpRoutersOptions">;
|
|
75
|
+
export declare function mockPKCV2({ pkcOptions, forceMockPubsub, stubStorage, mockResolve, remotePKC }?: MockPKCOptions): Promise<PKC>;
|
|
76
|
+
export declare function mockPKC(pkcOptions?: InputPKCOptions, forceMockPubsub?: boolean, stubStorage?: boolean, mockResolve?: boolean): Promise<PKC>;
|
|
77
|
+
export declare function mockRemotePKC(opts?: MockPKCOptions): Promise<PKC>;
|
|
78
|
+
export declare function createOnlinePKC(pkcOptions?: InputPKCOptions): Promise<PKC>;
|
|
79
|
+
export declare function mockPKCNoDataPathWithOnlyKuboClient(opts?: MockPKCOptions): Promise<PKC>;
|
|
80
|
+
export declare function mockPKCNoDataPathWithOnlyKuboClientNoAdd(opts?: MockPKCOptions): Promise<PKC>;
|
|
81
|
+
export declare function mockRpcServerPKC(pkcOptions?: InputPKCOptions): Promise<PKC>;
|
|
82
|
+
export declare function mockRpcRemotePKC(opts?: MockPKCOptions): Promise<PKC>;
|
|
83
|
+
export declare function mockRPCLocalPKC(pkcOptions?: InputPKCOptions): Promise<PKC>;
|
|
84
|
+
export declare function mockGatewayPKC(opts?: MockPKCOptions): Promise<PKC>;
|
|
85
|
+
export declare function publishRandomReply({ parentComment, pkc, commentProps }: {
|
|
86
|
+
parentComment: CommentIpfsWithCidDefined;
|
|
87
|
+
pkc: PKC;
|
|
88
|
+
commentProps?: Partial<CreateCommentOptions>;
|
|
89
|
+
}): Promise<Comment>;
|
|
90
|
+
export declare function publishRandomPost({ communityAddress, pkc, postProps }: {
|
|
91
|
+
communityAddress: string;
|
|
92
|
+
pkc: PKC;
|
|
93
|
+
postProps?: Partial<CreateCommentOptions>;
|
|
94
|
+
}): Promise<Comment>;
|
|
95
|
+
export declare function publishVote({ commentCid, communityAddress, vote, pkc, voteProps }: {
|
|
96
|
+
commentCid: string;
|
|
97
|
+
communityAddress: string;
|
|
98
|
+
vote: 1 | 0 | -1;
|
|
99
|
+
pkc: PKC;
|
|
100
|
+
voteProps?: Partial<CreateVoteOptions>;
|
|
101
|
+
}): Promise<Vote>;
|
|
102
|
+
export declare function publishWithExpectedResult({ publication, expectedChallengeSuccess, expectedReason }: {
|
|
103
|
+
publication: Publication;
|
|
104
|
+
expectedChallengeSuccess: boolean;
|
|
105
|
+
expectedReason?: string;
|
|
106
|
+
}): Promise<void>;
|
|
107
|
+
export declare function iterateThroughPageCidToFindComment(commentCid: string, pageCid: string, pages: PostsPages | RepliesPages): Promise<CommentWithinRepliesPostsPageJson | undefined>;
|
|
108
|
+
export declare function findCommentInCommunityInstancePagesPreloadedAndPageCids(opts: {
|
|
109
|
+
comment: Required<Pick<CommentIpfsWithCidDefined, "cid"> & {
|
|
110
|
+
communityAddress: string;
|
|
111
|
+
}>;
|
|
112
|
+
community: RemoteCommunity;
|
|
113
|
+
}): Promise<CommentWithinRepliesPostsPageJson | undefined>;
|
|
114
|
+
export declare function findReplyInParentCommentPagesInstancePreloadedAndPageCids(opts: {
|
|
115
|
+
reply: Required<Pick<CommentIpfsWithCidDefined, "cid" | "parentCid"> & {
|
|
116
|
+
communityAddress: string;
|
|
117
|
+
}>;
|
|
118
|
+
parentComment: Comment;
|
|
119
|
+
}): Promise<CommentWithinRepliesPostsPageJson | undefined>;
|
|
120
|
+
export declare function waitTillPostInCommunityInstancePages(post: Required<Pick<CommentIpfsWithCidDefined, "cid"> & {
|
|
121
|
+
communityAddress: string;
|
|
122
|
+
}>, community: RemoteCommunity): Promise<void>;
|
|
123
|
+
export declare function waitTillPostInCommunityPages(post: Required<Pick<CommentIpfsWithCidDefined, "cid"> & {
|
|
124
|
+
communityAddress: string;
|
|
125
|
+
}>, pkc: PKC): Promise<void>;
|
|
126
|
+
export declare function iterateThroughPagesToFindCommentInParentPagesInstance(commentCid: string, pages: PostsPages | RepliesPages): Promise<PageTypeJson["comments"][0] | undefined>;
|
|
127
|
+
export declare function waitTillReplyInParentPagesInstance(reply: Required<Pick<CommentIpfsWithCidDefined, "cid" | "parentCid"> & {
|
|
128
|
+
communityAddress: string;
|
|
129
|
+
}>, parentComment: Comment): Promise<void>;
|
|
130
|
+
export declare function waitTillReplyInParentPages(reply: Required<Pick<CommentIpfsWithCidDefined, "cid" | "parentCid"> & {
|
|
131
|
+
communityAddress: string;
|
|
132
|
+
}>, pkc: PKC): Promise<void>;
|
|
133
|
+
export declare function createSubWithNoChallenge(props: CreateNewLocalCommunityUserOptions, pkc: PKC): Promise<LocalCommunity | RpcLocalCommunity>;
|
|
134
|
+
export declare function generatePostToAnswerMathQuestion(props: Partial<CreateCommentOptions> & Pick<CreateCommentOptions, "communityAddress">, pkc: PKC): Promise<Comment>;
|
|
135
|
+
export declare function isRpcFlagOn(): boolean;
|
|
136
|
+
export declare function isRunningInBrowser(): boolean;
|
|
137
|
+
export type ResolveWhenConditionIsTrueOptions = {
|
|
138
|
+
toUpdate: EventEmitter;
|
|
139
|
+
predicate: () => Promise<boolean>;
|
|
140
|
+
eventName?: string;
|
|
141
|
+
};
|
|
142
|
+
export declare function resolveWhenConditionIsTrue(options: ResolveWhenConditionIsTrueOptions): Promise<void>;
|
|
143
|
+
export declare function disableValidationOfSignatureBeforePublishing(publication: Publication): Promise<void>;
|
|
144
|
+
export declare function overrideCommentInstancePropsAndSign(comment: Comment, props: CreateCommentOptions): Promise<void>;
|
|
145
|
+
export declare function overrideCommentEditInstancePropsAndSign(commentEdit: CommentEdit, props: CreateCommentEditOptions): Promise<void>;
|
|
146
|
+
export declare function ensurePublicationIsSigned(publication: Publication, community: {
|
|
147
|
+
address: string;
|
|
148
|
+
signer?: {
|
|
149
|
+
address: string;
|
|
150
|
+
};
|
|
151
|
+
encryption: {
|
|
152
|
+
type: string;
|
|
153
|
+
publicKey: string;
|
|
154
|
+
};
|
|
155
|
+
pubsubTopic?: string;
|
|
156
|
+
name?: string;
|
|
157
|
+
}): Promise<void>;
|
|
158
|
+
export declare function setExtraPropOnCommentAndSign(comment: Comment, extraProps: Object, includeExtraPropInSignedPropertyNames: boolean): Promise<void>;
|
|
159
|
+
export declare function setExtraPropOnVoteAndSign(vote: Vote, extraProps: Object, includeExtraPropInSignedPropertyNames: boolean): Promise<void>;
|
|
160
|
+
export declare function setExtraPropOnCommentEditAndSign(commentEdit: CommentEdit, extraProps: Object, includeExtraPropInSignedPropertyNames: boolean): Promise<void>;
|
|
161
|
+
export declare function setExtraPropOnCommentModerationAndSign(commentModeration: CommentModeration, extraProps: any, includeExtraPropInSignedPropertyNames: boolean): Promise<void>;
|
|
162
|
+
export declare function setExtraPropOnChallengeRequestAndSign({ publication, extraProps, includeExtraPropsInRequestSignedPropertyNames }: {
|
|
163
|
+
publication: Publication;
|
|
164
|
+
extraProps: Object;
|
|
165
|
+
includeExtraPropsInRequestSignedPropertyNames: boolean;
|
|
166
|
+
}): Promise<void>;
|
|
167
|
+
export declare function publishChallengeAnswerMessageWithExtraProps({ publication, challengeAnswers, extraProps, includeExtraPropsInChallengeSignedPropertyNames }: {
|
|
168
|
+
publication: Publication;
|
|
169
|
+
challengeAnswers: string[];
|
|
170
|
+
extraProps: Object;
|
|
171
|
+
includeExtraPropsInChallengeSignedPropertyNames: boolean;
|
|
172
|
+
}): Promise<void>;
|
|
173
|
+
export declare function publishChallengeMessageWithExtraProps({ publication, pubsubSigner, extraProps, includeExtraPropsInChallengeSignedPropertyNames }: {
|
|
174
|
+
publication: Publication;
|
|
175
|
+
pubsubSigner: SignerType;
|
|
176
|
+
extraProps: Object;
|
|
177
|
+
includeExtraPropsInChallengeSignedPropertyNames: boolean;
|
|
178
|
+
}): Promise<void>;
|
|
179
|
+
export declare function publishChallengeVerificationMessageWithExtraProps({ publication, pubsubSigner, extraProps, includeExtraPropsInChallengeSignedPropertyNames }: {
|
|
180
|
+
publication: Publication;
|
|
181
|
+
pubsubSigner: SignerType;
|
|
182
|
+
extraProps: Object;
|
|
183
|
+
includeExtraPropsInChallengeSignedPropertyNames: boolean;
|
|
184
|
+
}): Promise<void>;
|
|
185
|
+
export declare function publishChallengeVerificationMessageWithEncryption(publication: Publication, pubsubSigner: SignerType, toEncrypt: Object, verificationProps?: Partial<ChallengeVerificationMessageType>): Promise<void>;
|
|
186
|
+
export declare function addStringToIpfs(content: string): Promise<string>;
|
|
187
|
+
export declare function publishOverPubsub(pubsubTopic: string, jsonToPublish: PubsubMessage): Promise<void>;
|
|
188
|
+
export declare function mockPKCWithHeliaConfig(opts?: MockPKCOptions): Promise<PKC>;
|
|
189
|
+
type PKCTestConfigCode = "remote-kubo-rpc" | "remote-ipfs-gateway" | "remote-pkc-rpc" | "local-kubo-rpc" | "remote-libp2pjs";
|
|
190
|
+
type PKCConfigWithName = {
|
|
191
|
+
name: string;
|
|
192
|
+
pkcInstancePromise: (args?: MockPKCOptions) => Promise<PKC>;
|
|
193
|
+
testConfigCode: PKCTestConfigCode;
|
|
194
|
+
};
|
|
195
|
+
export declare function setPKCConfigs(configs: PKCTestConfigCode[]): void;
|
|
196
|
+
export declare function getAvailablePKCConfigsToTestAgainst(opts?: {
|
|
197
|
+
includeOnlyTheseTests?: PKCTestConfigCode[];
|
|
198
|
+
includeAllPossibleConfigOnEnv?: boolean;
|
|
199
|
+
}): PKCConfigWithName[];
|
|
200
|
+
export declare function createNewIpns(): Promise<{
|
|
201
|
+
signer: import("../signer/index.js").SignerWithPublicKeyAddress;
|
|
202
|
+
publishToIpns: (content: string) => Promise<void>;
|
|
203
|
+
pkc: PKC;
|
|
204
|
+
}>;
|
|
205
|
+
export declare function publishCommunityRecordWithExtraProp(opts?: {
|
|
206
|
+
includeExtraPropInSignedPropertyNames: boolean;
|
|
207
|
+
extraProps: Object;
|
|
208
|
+
}): Promise<{
|
|
209
|
+
communityRecord: any;
|
|
210
|
+
ipnsObj: {
|
|
211
|
+
signer: import("../signer/index.js").SignerWithPublicKeyAddress;
|
|
212
|
+
publishToIpns: (content: string) => Promise<void>;
|
|
213
|
+
pkc: PKC;
|
|
214
|
+
};
|
|
215
|
+
}>;
|
|
216
|
+
export declare function createMockedCommunityIpns(communityOpts: CreateNewLocalCommunityUserOptions): Promise<{
|
|
217
|
+
communityRecord: {
|
|
218
|
+
challenges: {
|
|
219
|
+
[x: string]: unknown;
|
|
220
|
+
type: string;
|
|
221
|
+
exclude?: {
|
|
222
|
+
[x: string]: unknown;
|
|
223
|
+
community?: {
|
|
224
|
+
addresses: string[];
|
|
225
|
+
maxCommentCids: number;
|
|
226
|
+
postScore?: number | undefined;
|
|
227
|
+
replyScore?: number | undefined;
|
|
228
|
+
firstCommentTimestamp?: number | undefined;
|
|
229
|
+
} | undefined;
|
|
230
|
+
postScore?: number | undefined;
|
|
231
|
+
replyScore?: number | undefined;
|
|
232
|
+
postCount?: number | undefined;
|
|
233
|
+
replyCount?: number | undefined;
|
|
234
|
+
firstCommentTimestamp?: number | undefined;
|
|
235
|
+
challenges?: number[] | undefined;
|
|
236
|
+
role?: string[] | undefined;
|
|
237
|
+
address?: string[] | undefined;
|
|
238
|
+
rateLimit?: number | undefined;
|
|
239
|
+
rateLimitChallengeSuccess?: boolean | undefined;
|
|
240
|
+
publicationType?: {
|
|
241
|
+
[x: string]: unknown;
|
|
242
|
+
post?: boolean | undefined;
|
|
243
|
+
reply?: boolean | undefined;
|
|
244
|
+
vote?: boolean | undefined;
|
|
245
|
+
commentEdit?: boolean | undefined;
|
|
246
|
+
commentModeration?: boolean | undefined;
|
|
247
|
+
communityEdit?: boolean | undefined;
|
|
248
|
+
} | undefined;
|
|
249
|
+
}[] | undefined;
|
|
250
|
+
description?: string | undefined;
|
|
251
|
+
challenge?: string | undefined;
|
|
252
|
+
caseInsensitive?: boolean | undefined;
|
|
253
|
+
pendingApproval?: boolean | undefined;
|
|
254
|
+
}[];
|
|
255
|
+
signature: {
|
|
256
|
+
type: string;
|
|
257
|
+
signature: string;
|
|
258
|
+
publicKey: string;
|
|
259
|
+
signedPropertyNames: string[];
|
|
260
|
+
};
|
|
261
|
+
encryption: {
|
|
262
|
+
[x: string]: unknown;
|
|
263
|
+
type: string;
|
|
264
|
+
publicKey: string;
|
|
265
|
+
};
|
|
266
|
+
createdAt: number;
|
|
267
|
+
updatedAt: number;
|
|
268
|
+
statsCid: string;
|
|
269
|
+
protocolVersion: string;
|
|
270
|
+
posts?: {
|
|
271
|
+
pages: Record<string, {
|
|
272
|
+
comments: {
|
|
273
|
+
comment: {
|
|
274
|
+
[x: string]: unknown;
|
|
275
|
+
timestamp: number;
|
|
276
|
+
signature: {
|
|
277
|
+
type: string;
|
|
278
|
+
signature: string;
|
|
279
|
+
publicKey: string;
|
|
280
|
+
signedPropertyNames: string[];
|
|
281
|
+
};
|
|
282
|
+
protocolVersion: string;
|
|
283
|
+
depth: number;
|
|
284
|
+
flairs?: {
|
|
285
|
+
[x: string]: unknown;
|
|
286
|
+
text: string;
|
|
287
|
+
backgroundColor?: string | undefined;
|
|
288
|
+
textColor?: string | undefined;
|
|
289
|
+
expiresAt?: number | undefined;
|
|
290
|
+
}[] | undefined;
|
|
291
|
+
communityPublicKey?: string | undefined;
|
|
292
|
+
communityName?: string | undefined;
|
|
293
|
+
link?: string | undefined;
|
|
294
|
+
spoiler?: boolean | undefined;
|
|
295
|
+
nsfw?: boolean | undefined;
|
|
296
|
+
content?: string | undefined;
|
|
297
|
+
title?: string | undefined;
|
|
298
|
+
linkWidth?: number | undefined;
|
|
299
|
+
linkHeight?: number | undefined;
|
|
300
|
+
linkHtmlTagName?: string | undefined;
|
|
301
|
+
parentCid?: string | undefined;
|
|
302
|
+
postCid?: string | undefined;
|
|
303
|
+
quotedCids?: string[] | undefined;
|
|
304
|
+
author?: {
|
|
305
|
+
[x: string]: unknown;
|
|
306
|
+
name?: string | undefined;
|
|
307
|
+
previousCommentCid?: string | undefined;
|
|
308
|
+
displayName?: string | undefined;
|
|
309
|
+
wallets?: Record<string, {
|
|
310
|
+
address: string;
|
|
311
|
+
timestamp: number;
|
|
312
|
+
signature: {
|
|
313
|
+
signature: string;
|
|
314
|
+
type: string;
|
|
315
|
+
};
|
|
316
|
+
}> | undefined;
|
|
317
|
+
avatar?: {
|
|
318
|
+
[x: string]: unknown;
|
|
319
|
+
chainTicker: string;
|
|
320
|
+
address: string;
|
|
321
|
+
id: string;
|
|
322
|
+
timestamp: number;
|
|
323
|
+
signature: {
|
|
324
|
+
signature: string;
|
|
325
|
+
type: string;
|
|
326
|
+
};
|
|
327
|
+
} | undefined;
|
|
328
|
+
flairs?: {
|
|
329
|
+
[x: string]: unknown;
|
|
330
|
+
text: string;
|
|
331
|
+
backgroundColor?: string | undefined;
|
|
332
|
+
textColor?: string | undefined;
|
|
333
|
+
expiresAt?: number | undefined;
|
|
334
|
+
}[] | undefined;
|
|
335
|
+
} | undefined;
|
|
336
|
+
thumbnailUrl?: string | undefined;
|
|
337
|
+
thumbnailUrlWidth?: number | undefined;
|
|
338
|
+
thumbnailUrlHeight?: number | undefined;
|
|
339
|
+
previousCid?: string | undefined;
|
|
340
|
+
pseudonymityMode?: "per-post" | "per-reply" | "per-author" | undefined;
|
|
341
|
+
};
|
|
342
|
+
commentUpdate: {
|
|
343
|
+
[x: string]: unknown;
|
|
344
|
+
cid: string;
|
|
345
|
+
upvoteCount: number;
|
|
346
|
+
downvoteCount: number;
|
|
347
|
+
replyCount: number;
|
|
348
|
+
updatedAt: number;
|
|
349
|
+
signature: {
|
|
350
|
+
type: string;
|
|
351
|
+
signature: string;
|
|
352
|
+
publicKey: string;
|
|
353
|
+
signedPropertyNames: string[];
|
|
354
|
+
};
|
|
355
|
+
protocolVersion: string;
|
|
356
|
+
childCount?: number | undefined;
|
|
357
|
+
number?: number | undefined;
|
|
358
|
+
postNumber?: number | undefined;
|
|
359
|
+
edit?: {
|
|
360
|
+
[x: string]: unknown;
|
|
361
|
+
timestamp: number;
|
|
362
|
+
signature: {
|
|
363
|
+
type: string;
|
|
364
|
+
signature: string;
|
|
365
|
+
publicKey: string;
|
|
366
|
+
signedPropertyNames: string[];
|
|
367
|
+
};
|
|
368
|
+
protocolVersion: string;
|
|
369
|
+
commentCid: string;
|
|
370
|
+
flairs?: {
|
|
371
|
+
[x: string]: unknown;
|
|
372
|
+
text: string;
|
|
373
|
+
backgroundColor?: string | undefined;
|
|
374
|
+
textColor?: string | undefined;
|
|
375
|
+
expiresAt?: number | undefined;
|
|
376
|
+
}[] | undefined;
|
|
377
|
+
communityPublicKey?: string | undefined;
|
|
378
|
+
communityName?: string | undefined;
|
|
379
|
+
spoiler?: boolean | undefined;
|
|
380
|
+
nsfw?: boolean | undefined;
|
|
381
|
+
reason?: string | undefined;
|
|
382
|
+
content?: string | undefined;
|
|
383
|
+
deleted?: boolean | undefined;
|
|
384
|
+
author?: {
|
|
385
|
+
[x: string]: unknown;
|
|
386
|
+
name?: string | undefined;
|
|
387
|
+
previousCommentCid?: string | undefined;
|
|
388
|
+
displayName?: string | undefined;
|
|
389
|
+
wallets?: Record<string, {
|
|
390
|
+
address: string;
|
|
391
|
+
timestamp: number;
|
|
392
|
+
signature: {
|
|
393
|
+
signature: string;
|
|
394
|
+
type: string;
|
|
395
|
+
};
|
|
396
|
+
}> | undefined;
|
|
397
|
+
avatar?: {
|
|
398
|
+
[x: string]: unknown;
|
|
399
|
+
chainTicker: string;
|
|
400
|
+
address: string;
|
|
401
|
+
id: string;
|
|
402
|
+
timestamp: number;
|
|
403
|
+
signature: {
|
|
404
|
+
signature: string;
|
|
405
|
+
type: string;
|
|
406
|
+
};
|
|
407
|
+
} | undefined;
|
|
408
|
+
flairs?: {
|
|
409
|
+
[x: string]: unknown;
|
|
410
|
+
text: string;
|
|
411
|
+
backgroundColor?: string | undefined;
|
|
412
|
+
textColor?: string | undefined;
|
|
413
|
+
expiresAt?: number | undefined;
|
|
414
|
+
}[] | undefined;
|
|
415
|
+
} | undefined;
|
|
416
|
+
} | undefined;
|
|
417
|
+
flairs?: {
|
|
418
|
+
[x: string]: unknown;
|
|
419
|
+
text: string;
|
|
420
|
+
backgroundColor?: string | undefined;
|
|
421
|
+
textColor?: string | undefined;
|
|
422
|
+
expiresAt?: number | undefined;
|
|
423
|
+
}[] | undefined;
|
|
424
|
+
spoiler?: boolean | undefined;
|
|
425
|
+
nsfw?: boolean | undefined;
|
|
426
|
+
pinned?: boolean | undefined;
|
|
427
|
+
locked?: boolean | undefined;
|
|
428
|
+
archived?: boolean | undefined;
|
|
429
|
+
removed?: boolean | undefined;
|
|
430
|
+
reason?: string | undefined;
|
|
431
|
+
approved?: boolean | undefined;
|
|
432
|
+
author?: {
|
|
433
|
+
[x: string]: unknown;
|
|
434
|
+
community?: {
|
|
435
|
+
[x: string]: unknown;
|
|
436
|
+
postScore: number;
|
|
437
|
+
replyScore: number;
|
|
438
|
+
firstCommentTimestamp: number;
|
|
439
|
+
lastCommentCid: string;
|
|
440
|
+
banExpiresAt?: number | undefined;
|
|
441
|
+
flairs?: {
|
|
442
|
+
[x: string]: unknown;
|
|
443
|
+
text: string;
|
|
444
|
+
backgroundColor?: string | undefined;
|
|
445
|
+
textColor?: string | undefined;
|
|
446
|
+
expiresAt?: number | undefined;
|
|
447
|
+
}[] | undefined;
|
|
448
|
+
} | undefined;
|
|
449
|
+
} | undefined;
|
|
450
|
+
lastChildCid?: string | undefined;
|
|
451
|
+
lastReplyTimestamp?: number | undefined;
|
|
452
|
+
replies?: {
|
|
453
|
+
pages: Record<string, /*elided*/ any>;
|
|
454
|
+
pageCids?: Record<string, string> | undefined;
|
|
455
|
+
} | undefined;
|
|
456
|
+
};
|
|
457
|
+
}[];
|
|
458
|
+
nextCid?: string | undefined;
|
|
459
|
+
}>;
|
|
460
|
+
pageCids?: Record<string, string> | undefined;
|
|
461
|
+
} | undefined;
|
|
462
|
+
modQueue?: {
|
|
463
|
+
pageCids: Record<string, string>;
|
|
464
|
+
} | undefined;
|
|
465
|
+
name?: string | undefined;
|
|
466
|
+
pubsubTopic?: string | undefined;
|
|
467
|
+
postUpdates?: Record<string, string> | undefined;
|
|
468
|
+
title?: string | undefined;
|
|
469
|
+
description?: string | undefined;
|
|
470
|
+
roles?: Record<string, {
|
|
471
|
+
[x: string]: unknown;
|
|
472
|
+
role: string;
|
|
473
|
+
}> | undefined;
|
|
474
|
+
rules?: string[] | undefined;
|
|
475
|
+
lastPostCid?: string | undefined;
|
|
476
|
+
lastCommentCid?: string | undefined;
|
|
477
|
+
features?: {
|
|
478
|
+
[x: string]: unknown;
|
|
479
|
+
noVideos?: boolean | undefined;
|
|
480
|
+
noSpoilers?: boolean | undefined;
|
|
481
|
+
noImages?: boolean | undefined;
|
|
482
|
+
noVideoReplies?: boolean | undefined;
|
|
483
|
+
noSpoilerReplies?: boolean | undefined;
|
|
484
|
+
noImageReplies?: boolean | undefined;
|
|
485
|
+
noPolls?: boolean | undefined;
|
|
486
|
+
noCrossposts?: boolean | undefined;
|
|
487
|
+
noNestedReplies?: boolean | undefined;
|
|
488
|
+
safeForWork?: boolean | undefined;
|
|
489
|
+
authorFlairs?: boolean | undefined;
|
|
490
|
+
requireAuthorFlairs?: boolean | undefined;
|
|
491
|
+
postFlairs?: boolean | undefined;
|
|
492
|
+
requirePostFlairs?: boolean | undefined;
|
|
493
|
+
noMarkdownImages?: boolean | undefined;
|
|
494
|
+
noMarkdownVideos?: boolean | undefined;
|
|
495
|
+
noMarkdownAudio?: boolean | undefined;
|
|
496
|
+
noAudio?: boolean | undefined;
|
|
497
|
+
noAudioReplies?: boolean | undefined;
|
|
498
|
+
markdownImageReplies?: boolean | undefined;
|
|
499
|
+
markdownVideoReplies?: boolean | undefined;
|
|
500
|
+
noPostUpvotes?: boolean | undefined;
|
|
501
|
+
noReplyUpvotes?: boolean | undefined;
|
|
502
|
+
noPostDownvotes?: boolean | undefined;
|
|
503
|
+
noReplyDownvotes?: boolean | undefined;
|
|
504
|
+
noUpvotes?: boolean | undefined;
|
|
505
|
+
noDownvotes?: boolean | undefined;
|
|
506
|
+
requirePostLink?: boolean | undefined;
|
|
507
|
+
requirePostLinkIsMedia?: boolean | undefined;
|
|
508
|
+
requireReplyLink?: boolean | undefined;
|
|
509
|
+
requireReplyLinkIsMedia?: boolean | undefined;
|
|
510
|
+
pseudonymityMode?: "per-post" | "per-reply" | "per-author" | undefined;
|
|
511
|
+
} | undefined;
|
|
512
|
+
suggested?: {
|
|
513
|
+
[x: string]: unknown;
|
|
514
|
+
primaryColor?: string | undefined;
|
|
515
|
+
secondaryColor?: string | undefined;
|
|
516
|
+
avatarUrl?: string | undefined;
|
|
517
|
+
bannerUrl?: string | undefined;
|
|
518
|
+
backgroundUrl?: string | undefined;
|
|
519
|
+
language?: string | undefined;
|
|
520
|
+
} | undefined;
|
|
521
|
+
flairs?: Record<string, {
|
|
522
|
+
[x: string]: unknown;
|
|
523
|
+
text: string;
|
|
524
|
+
backgroundColor?: string | undefined;
|
|
525
|
+
textColor?: string | undefined;
|
|
526
|
+
expiresAt?: number | undefined;
|
|
527
|
+
}[]> | undefined;
|
|
528
|
+
};
|
|
529
|
+
communityAddress: string;
|
|
530
|
+
ipnsObj: {
|
|
531
|
+
signer: import("../signer/index.js").SignerWithPublicKeyAddress;
|
|
532
|
+
publishToIpns: (content: string) => Promise<void>;
|
|
533
|
+
pkc: PKC;
|
|
534
|
+
};
|
|
535
|
+
}>;
|
|
536
|
+
export declare function createStaticCommunityRecordForComment(opts?: {
|
|
537
|
+
pkc?: PKC;
|
|
538
|
+
commentOptions?: Partial<CreateCommentOptions & {
|
|
539
|
+
depth?: number;
|
|
540
|
+
}>;
|
|
541
|
+
invalidateCommunitySignature?: boolean;
|
|
542
|
+
}): Promise<{
|
|
543
|
+
commentCid: string;
|
|
544
|
+
communityAddress: string;
|
|
545
|
+
}>;
|
|
546
|
+
export declare function jsonifyCommunityAndRemoveInternalProps(community: RemoteCommunity): Omit<any, "signer" | "state" | "clients" | "settings" | "updatingState" | "startedState" | "editable" | "started">;
|
|
547
|
+
export declare function jsonifyLocalCommunityWithNoInternalProps(community: LocalCommunity): Omit<{
|
|
548
|
+
address: string;
|
|
549
|
+
publicKey?: string | undefined;
|
|
550
|
+
shortAddress: string;
|
|
551
|
+
signature?: CommunityIpfsType["signature"] | undefined;
|
|
552
|
+
name?: string | undefined;
|
|
553
|
+
flairs?: Record<string, {
|
|
554
|
+
[x: string]: unknown;
|
|
555
|
+
text: string;
|
|
556
|
+
backgroundColor?: string | undefined;
|
|
557
|
+
textColor?: string | undefined;
|
|
558
|
+
expiresAt?: number | undefined;
|
|
559
|
+
}[]> | undefined;
|
|
560
|
+
signer: import("../signer/index.js").SignerWithPublicKeyAddress;
|
|
561
|
+
protocolVersion: CommunityIpfsType["protocolVersion"];
|
|
562
|
+
lastCommentCid?: string | undefined;
|
|
563
|
+
nameResolved?: boolean | undefined;
|
|
564
|
+
state: import("../community/types.js").CommunityState;
|
|
565
|
+
clients: import("../community/community-client-manager.js").CommunityClientsManager["clients"];
|
|
566
|
+
encryption: CommunityIpfsType["encryption"];
|
|
567
|
+
createdAt: CommunityIpfsType["createdAt"];
|
|
568
|
+
updatedAt?: CommunityIpfsType["updatedAt"] | undefined;
|
|
569
|
+
statsCid?: CommunityIpfsType["statsCid"] | undefined;
|
|
570
|
+
title?: string | undefined;
|
|
571
|
+
posts: PostsPages;
|
|
572
|
+
modQueue: import("../pages/pages.js").ModQueuePages;
|
|
573
|
+
challenges: CommunityIpfsType["challenges"];
|
|
574
|
+
description?: string | undefined;
|
|
575
|
+
pubsubTopic?: string | undefined;
|
|
576
|
+
postUpdates?: Record<string, string> | undefined;
|
|
577
|
+
roles?: Record<string, {
|
|
578
|
+
[x: string]: unknown;
|
|
579
|
+
role: string;
|
|
580
|
+
}> | undefined;
|
|
581
|
+
rules?: string[] | undefined;
|
|
582
|
+
lastPostCid?: string | undefined;
|
|
583
|
+
features?: {
|
|
584
|
+
[x: string]: unknown;
|
|
585
|
+
noVideos?: boolean | undefined;
|
|
586
|
+
noSpoilers?: boolean | undefined;
|
|
587
|
+
noImages?: boolean | undefined;
|
|
588
|
+
noVideoReplies?: boolean | undefined;
|
|
589
|
+
noSpoilerReplies?: boolean | undefined;
|
|
590
|
+
noImageReplies?: boolean | undefined;
|
|
591
|
+
noPolls?: boolean | undefined;
|
|
592
|
+
noCrossposts?: boolean | undefined;
|
|
593
|
+
noNestedReplies?: boolean | undefined;
|
|
594
|
+
safeForWork?: boolean | undefined;
|
|
595
|
+
authorFlairs?: boolean | undefined;
|
|
596
|
+
requireAuthorFlairs?: boolean | undefined;
|
|
597
|
+
postFlairs?: boolean | undefined;
|
|
598
|
+
requirePostFlairs?: boolean | undefined;
|
|
599
|
+
noMarkdownImages?: boolean | undefined;
|
|
600
|
+
noMarkdownVideos?: boolean | undefined;
|
|
601
|
+
noMarkdownAudio?: boolean | undefined;
|
|
602
|
+
noAudio?: boolean | undefined;
|
|
603
|
+
noAudioReplies?: boolean | undefined;
|
|
604
|
+
markdownImageReplies?: boolean | undefined;
|
|
605
|
+
markdownVideoReplies?: boolean | undefined;
|
|
606
|
+
noPostUpvotes?: boolean | undefined;
|
|
607
|
+
noReplyUpvotes?: boolean | undefined;
|
|
608
|
+
noPostDownvotes?: boolean | undefined;
|
|
609
|
+
noReplyDownvotes?: boolean | undefined;
|
|
610
|
+
noUpvotes?: boolean | undefined;
|
|
611
|
+
noDownvotes?: boolean | undefined;
|
|
612
|
+
requirePostLink?: boolean | undefined;
|
|
613
|
+
requirePostLinkIsMedia?: boolean | undefined;
|
|
614
|
+
requireReplyLink?: boolean | undefined;
|
|
615
|
+
requireReplyLinkIsMedia?: boolean | undefined;
|
|
616
|
+
pseudonymityMode?: "per-post" | "per-reply" | "per-author" | undefined;
|
|
617
|
+
} | undefined;
|
|
618
|
+
suggested?: {
|
|
619
|
+
[x: string]: unknown;
|
|
620
|
+
primaryColor?: string | undefined;
|
|
621
|
+
secondaryColor?: string | undefined;
|
|
622
|
+
avatarUrl?: string | undefined;
|
|
623
|
+
bannerUrl?: string | undefined;
|
|
624
|
+
backgroundUrl?: string | undefined;
|
|
625
|
+
language?: string | undefined;
|
|
626
|
+
} | undefined;
|
|
627
|
+
settings: import("../community/types.js").RpcLocalCommunityLocalProps["settings"];
|
|
628
|
+
readonly updatingState: RemoteCommunity["updatingState"];
|
|
629
|
+
raw: RpcLocalCommunity["raw"];
|
|
630
|
+
updateCid?: string | undefined;
|
|
631
|
+
startedState: import("../community/types.js").CommunityStartedState;
|
|
632
|
+
editable: Pick<RpcLocalCommunity, keyof import("../community/types.js").CommunityEditOptions>;
|
|
633
|
+
started: boolean;
|
|
634
|
+
ipnsName?: string | undefined;
|
|
635
|
+
ipnsPubsubTopic?: string | undefined;
|
|
636
|
+
ipnsPubsubTopicRoutingCid?: string | undefined;
|
|
637
|
+
pubsubTopicRoutingCid?: string | undefined;
|
|
638
|
+
}, "state" | "clients" | "updatingState" | "startedState" | "started">;
|
|
639
|
+
export declare function jsonifyCommentAndRemoveInstanceProps(comment: Comment): Omit<any, "state" | "publishingState" | "clients" | "updatingState" | "raw">;
|
|
640
|
+
export declare function waitUntilPKCCommunitiesIncludeSubAddress(pkc: PKC, subAddress: string): Promise<void>;
|
|
641
|
+
export declare function isPKCFetchingUsingGateways(pkc: PKC): boolean;
|
|
642
|
+
export declare function mockRpcServerForTests(pkcWs: any): void;
|
|
643
|
+
export declare function disablePreloadPagesOnSub({ community }: {
|
|
644
|
+
community: LocalCommunity;
|
|
645
|
+
}): {
|
|
646
|
+
cleanup: () => void;
|
|
647
|
+
};
|
|
648
|
+
export declare function mockPostToReturnSpecificCommentUpdate(commentToBeMocked: Comment, commentUpdateRecordString: string): void;
|
|
649
|
+
export declare function mockPostToFailToLoadFromPostUpdates(postToBeMocked: Comment): void;
|
|
650
|
+
export declare function mockPostToHaveCommunityWithNoPostUpdates(postToBeMocked: Comment): void;
|
|
651
|
+
export declare function createCommentUpdateWithInvalidSignature(commentCid: string): Promise<{
|
|
652
|
+
cid: string;
|
|
653
|
+
upvoteCount: number;
|
|
654
|
+
downvoteCount: number;
|
|
655
|
+
replyCount: number;
|
|
656
|
+
updatedAt: number;
|
|
657
|
+
signature: {
|
|
658
|
+
type: string;
|
|
659
|
+
signature: string;
|
|
660
|
+
publicKey: string;
|
|
661
|
+
signedPropertyNames: string[];
|
|
662
|
+
};
|
|
663
|
+
protocolVersion: string;
|
|
664
|
+
childCount?: number | undefined;
|
|
665
|
+
number?: number | undefined;
|
|
666
|
+
postNumber?: number | undefined;
|
|
667
|
+
edit?: {
|
|
668
|
+
[x: string]: unknown;
|
|
669
|
+
timestamp: number;
|
|
670
|
+
signature: {
|
|
671
|
+
type: string;
|
|
672
|
+
signature: string;
|
|
673
|
+
publicKey: string;
|
|
674
|
+
signedPropertyNames: string[];
|
|
675
|
+
};
|
|
676
|
+
protocolVersion: string;
|
|
677
|
+
commentCid: string;
|
|
678
|
+
flairs?: {
|
|
679
|
+
[x: string]: unknown;
|
|
680
|
+
text: string;
|
|
681
|
+
backgroundColor?: string | undefined;
|
|
682
|
+
textColor?: string | undefined;
|
|
683
|
+
expiresAt?: number | undefined;
|
|
684
|
+
}[] | undefined;
|
|
685
|
+
communityPublicKey?: string | undefined;
|
|
686
|
+
communityName?: string | undefined;
|
|
687
|
+
spoiler?: boolean | undefined;
|
|
688
|
+
nsfw?: boolean | undefined;
|
|
689
|
+
reason?: string | undefined;
|
|
690
|
+
content?: string | undefined;
|
|
691
|
+
deleted?: boolean | undefined;
|
|
692
|
+
author?: {
|
|
693
|
+
[x: string]: unknown;
|
|
694
|
+
name?: string | undefined;
|
|
695
|
+
previousCommentCid?: string | undefined;
|
|
696
|
+
displayName?: string | undefined;
|
|
697
|
+
wallets?: Record<string, {
|
|
698
|
+
address: string;
|
|
699
|
+
timestamp: number;
|
|
700
|
+
signature: {
|
|
701
|
+
signature: string;
|
|
702
|
+
type: string;
|
|
703
|
+
};
|
|
704
|
+
}> | undefined;
|
|
705
|
+
avatar?: {
|
|
706
|
+
[x: string]: unknown;
|
|
707
|
+
chainTicker: string;
|
|
708
|
+
address: string;
|
|
709
|
+
id: string;
|
|
710
|
+
timestamp: number;
|
|
711
|
+
signature: {
|
|
712
|
+
signature: string;
|
|
713
|
+
type: string;
|
|
714
|
+
};
|
|
715
|
+
} | undefined;
|
|
716
|
+
flairs?: {
|
|
717
|
+
[x: string]: unknown;
|
|
718
|
+
text: string;
|
|
719
|
+
backgroundColor?: string | undefined;
|
|
720
|
+
textColor?: string | undefined;
|
|
721
|
+
expiresAt?: number | undefined;
|
|
722
|
+
}[] | undefined;
|
|
723
|
+
} | undefined;
|
|
724
|
+
} | undefined;
|
|
725
|
+
flairs?: {
|
|
726
|
+
[x: string]: unknown;
|
|
727
|
+
text: string;
|
|
728
|
+
backgroundColor?: string | undefined;
|
|
729
|
+
textColor?: string | undefined;
|
|
730
|
+
expiresAt?: number | undefined;
|
|
731
|
+
}[] | undefined;
|
|
732
|
+
spoiler?: boolean | undefined;
|
|
733
|
+
nsfw?: boolean | undefined;
|
|
734
|
+
pinned?: boolean | undefined;
|
|
735
|
+
locked?: boolean | undefined;
|
|
736
|
+
archived?: boolean | undefined;
|
|
737
|
+
removed?: boolean | undefined;
|
|
738
|
+
reason?: string | undefined;
|
|
739
|
+
approved?: boolean | undefined;
|
|
740
|
+
author?: {
|
|
741
|
+
[x: string]: unknown;
|
|
742
|
+
community?: {
|
|
743
|
+
[x: string]: unknown;
|
|
744
|
+
postScore: number;
|
|
745
|
+
replyScore: number;
|
|
746
|
+
firstCommentTimestamp: number;
|
|
747
|
+
lastCommentCid: string;
|
|
748
|
+
banExpiresAt?: number | undefined;
|
|
749
|
+
flairs?: {
|
|
750
|
+
[x: string]: unknown;
|
|
751
|
+
text: string;
|
|
752
|
+
backgroundColor?: string | undefined;
|
|
753
|
+
textColor?: string | undefined;
|
|
754
|
+
expiresAt?: number | undefined;
|
|
755
|
+
}[] | undefined;
|
|
756
|
+
} | undefined;
|
|
757
|
+
} | undefined;
|
|
758
|
+
lastChildCid?: string | undefined;
|
|
759
|
+
lastReplyTimestamp?: number | undefined;
|
|
760
|
+
replies?: {
|
|
761
|
+
pages: Record<string, {
|
|
762
|
+
comments: {
|
|
763
|
+
comment: {
|
|
764
|
+
[x: string]: unknown;
|
|
765
|
+
timestamp: number;
|
|
766
|
+
signature: {
|
|
767
|
+
type: string;
|
|
768
|
+
signature: string;
|
|
769
|
+
publicKey: string;
|
|
770
|
+
signedPropertyNames: string[];
|
|
771
|
+
};
|
|
772
|
+
protocolVersion: string;
|
|
773
|
+
depth: number;
|
|
774
|
+
flairs?: {
|
|
775
|
+
[x: string]: unknown;
|
|
776
|
+
text: string;
|
|
777
|
+
backgroundColor?: string | undefined;
|
|
778
|
+
textColor?: string | undefined;
|
|
779
|
+
expiresAt?: number | undefined;
|
|
780
|
+
}[] | undefined;
|
|
781
|
+
communityPublicKey?: string | undefined;
|
|
782
|
+
communityName?: string | undefined;
|
|
783
|
+
link?: string | undefined;
|
|
784
|
+
spoiler?: boolean | undefined;
|
|
785
|
+
nsfw?: boolean | undefined;
|
|
786
|
+
content?: string | undefined;
|
|
787
|
+
title?: string | undefined;
|
|
788
|
+
linkWidth?: number | undefined;
|
|
789
|
+
linkHeight?: number | undefined;
|
|
790
|
+
linkHtmlTagName?: string | undefined;
|
|
791
|
+
parentCid?: string | undefined;
|
|
792
|
+
postCid?: string | undefined;
|
|
793
|
+
quotedCids?: string[] | undefined;
|
|
794
|
+
author?: {
|
|
795
|
+
[x: string]: unknown;
|
|
796
|
+
name?: string | undefined;
|
|
797
|
+
previousCommentCid?: string | undefined;
|
|
798
|
+
displayName?: string | undefined;
|
|
799
|
+
wallets?: Record<string, {
|
|
800
|
+
address: string;
|
|
801
|
+
timestamp: number;
|
|
802
|
+
signature: {
|
|
803
|
+
signature: string;
|
|
804
|
+
type: string;
|
|
805
|
+
};
|
|
806
|
+
}> | undefined;
|
|
807
|
+
avatar?: {
|
|
808
|
+
[x: string]: unknown;
|
|
809
|
+
chainTicker: string;
|
|
810
|
+
address: string;
|
|
811
|
+
id: string;
|
|
812
|
+
timestamp: number;
|
|
813
|
+
signature: {
|
|
814
|
+
signature: string;
|
|
815
|
+
type: string;
|
|
816
|
+
};
|
|
817
|
+
} | undefined;
|
|
818
|
+
flairs?: {
|
|
819
|
+
[x: string]: unknown;
|
|
820
|
+
text: string;
|
|
821
|
+
backgroundColor?: string | undefined;
|
|
822
|
+
textColor?: string | undefined;
|
|
823
|
+
expiresAt?: number | undefined;
|
|
824
|
+
}[] | undefined;
|
|
825
|
+
} | undefined;
|
|
826
|
+
thumbnailUrl?: string | undefined;
|
|
827
|
+
thumbnailUrlWidth?: number | undefined;
|
|
828
|
+
thumbnailUrlHeight?: number | undefined;
|
|
829
|
+
previousCid?: string | undefined;
|
|
830
|
+
pseudonymityMode?: "per-post" | "per-reply" | "per-author" | undefined;
|
|
831
|
+
};
|
|
832
|
+
commentUpdate: {
|
|
833
|
+
[x: string]: unknown;
|
|
834
|
+
cid: string;
|
|
835
|
+
upvoteCount: number;
|
|
836
|
+
downvoteCount: number;
|
|
837
|
+
replyCount: number;
|
|
838
|
+
updatedAt: number;
|
|
839
|
+
signature: {
|
|
840
|
+
type: string;
|
|
841
|
+
signature: string;
|
|
842
|
+
publicKey: string;
|
|
843
|
+
signedPropertyNames: string[];
|
|
844
|
+
};
|
|
845
|
+
protocolVersion: string;
|
|
846
|
+
childCount?: number | undefined;
|
|
847
|
+
number?: number | undefined;
|
|
848
|
+
postNumber?: number | undefined;
|
|
849
|
+
edit?: {
|
|
850
|
+
[x: string]: unknown;
|
|
851
|
+
timestamp: number;
|
|
852
|
+
signature: {
|
|
853
|
+
type: string;
|
|
854
|
+
signature: string;
|
|
855
|
+
publicKey: string;
|
|
856
|
+
signedPropertyNames: string[];
|
|
857
|
+
};
|
|
858
|
+
protocolVersion: string;
|
|
859
|
+
commentCid: string;
|
|
860
|
+
flairs?: {
|
|
861
|
+
[x: string]: unknown;
|
|
862
|
+
text: string;
|
|
863
|
+
backgroundColor?: string | undefined;
|
|
864
|
+
textColor?: string | undefined;
|
|
865
|
+
expiresAt?: number | undefined;
|
|
866
|
+
}[] | undefined;
|
|
867
|
+
communityPublicKey?: string | undefined;
|
|
868
|
+
communityName?: string | undefined;
|
|
869
|
+
spoiler?: boolean | undefined;
|
|
870
|
+
nsfw?: boolean | undefined;
|
|
871
|
+
reason?: string | undefined;
|
|
872
|
+
content?: string | undefined;
|
|
873
|
+
deleted?: boolean | undefined;
|
|
874
|
+
author?: {
|
|
875
|
+
[x: string]: unknown;
|
|
876
|
+
name?: string | undefined;
|
|
877
|
+
previousCommentCid?: string | undefined;
|
|
878
|
+
displayName?: string | undefined;
|
|
879
|
+
wallets?: Record<string, {
|
|
880
|
+
address: string;
|
|
881
|
+
timestamp: number;
|
|
882
|
+
signature: {
|
|
883
|
+
signature: string;
|
|
884
|
+
type: string;
|
|
885
|
+
};
|
|
886
|
+
}> | undefined;
|
|
887
|
+
avatar?: {
|
|
888
|
+
[x: string]: unknown;
|
|
889
|
+
chainTicker: string;
|
|
890
|
+
address: string;
|
|
891
|
+
id: string;
|
|
892
|
+
timestamp: number;
|
|
893
|
+
signature: {
|
|
894
|
+
signature: string;
|
|
895
|
+
type: string;
|
|
896
|
+
};
|
|
897
|
+
} | undefined;
|
|
898
|
+
flairs?: {
|
|
899
|
+
[x: string]: unknown;
|
|
900
|
+
text: string;
|
|
901
|
+
backgroundColor?: string | undefined;
|
|
902
|
+
textColor?: string | undefined;
|
|
903
|
+
expiresAt?: number | undefined;
|
|
904
|
+
}[] | undefined;
|
|
905
|
+
} | undefined;
|
|
906
|
+
} | undefined;
|
|
907
|
+
flairs?: {
|
|
908
|
+
[x: string]: unknown;
|
|
909
|
+
text: string;
|
|
910
|
+
backgroundColor?: string | undefined;
|
|
911
|
+
textColor?: string | undefined;
|
|
912
|
+
expiresAt?: number | undefined;
|
|
913
|
+
}[] | undefined;
|
|
914
|
+
spoiler?: boolean | undefined;
|
|
915
|
+
nsfw?: boolean | undefined;
|
|
916
|
+
pinned?: boolean | undefined;
|
|
917
|
+
locked?: boolean | undefined;
|
|
918
|
+
archived?: boolean | undefined;
|
|
919
|
+
removed?: boolean | undefined;
|
|
920
|
+
reason?: string | undefined;
|
|
921
|
+
approved?: boolean | undefined;
|
|
922
|
+
author?: {
|
|
923
|
+
[x: string]: unknown;
|
|
924
|
+
community?: {
|
|
925
|
+
[x: string]: unknown;
|
|
926
|
+
postScore: number;
|
|
927
|
+
replyScore: number;
|
|
928
|
+
firstCommentTimestamp: number;
|
|
929
|
+
lastCommentCid: string;
|
|
930
|
+
banExpiresAt?: number | undefined;
|
|
931
|
+
flairs?: {
|
|
932
|
+
[x: string]: unknown;
|
|
933
|
+
text: string;
|
|
934
|
+
backgroundColor?: string | undefined;
|
|
935
|
+
textColor?: string | undefined;
|
|
936
|
+
expiresAt?: number | undefined;
|
|
937
|
+
}[] | undefined;
|
|
938
|
+
} | undefined;
|
|
939
|
+
} | undefined;
|
|
940
|
+
lastChildCid?: string | undefined;
|
|
941
|
+
lastReplyTimestamp?: number | undefined;
|
|
942
|
+
replies?: /*elided*/ any | undefined;
|
|
943
|
+
};
|
|
944
|
+
}[];
|
|
945
|
+
nextCid?: string | undefined;
|
|
946
|
+
}>;
|
|
947
|
+
pageCids?: Record<string, string> | undefined;
|
|
948
|
+
} | undefined;
|
|
949
|
+
}>;
|
|
950
|
+
export declare function mockPKCToTimeoutFetchingCid(pkc: PKC): {
|
|
951
|
+
cleanUp: () => void;
|
|
952
|
+
};
|
|
953
|
+
export declare function mockCommentToNotUsePagesForUpdates(comment: Comment): void;
|
|
954
|
+
export declare function forceLocalSubPagesToAlwaysGenerateMultipleChunks({ community, parentComment, forcedPreloadedPageSizeBytes, parentCommentReplyProps, communityPostsCommentProps }: {
|
|
955
|
+
community: LocalCommunity | RemoteCommunity;
|
|
956
|
+
parentComment?: Comment;
|
|
957
|
+
forcedPreloadedPageSizeBytes?: number;
|
|
958
|
+
parentCommentReplyProps?: Partial<CreateCommentOptions>;
|
|
959
|
+
communityPostsCommentProps?: CreateCommentOptions;
|
|
960
|
+
}): Promise<{
|
|
961
|
+
cleanup: () => void;
|
|
962
|
+
}>;
|
|
963
|
+
export declare function findOrPublishCommentWithDepth({ depth, community, pkc }: {
|
|
964
|
+
depth: number;
|
|
965
|
+
community: RemoteCommunity;
|
|
966
|
+
pkc?: PKC;
|
|
967
|
+
}): Promise<Comment>;
|
|
968
|
+
export declare function findOrPublishCommentWithDepthWithHttpServerShortcut({ depth, community, pkc }: {
|
|
969
|
+
depth: number;
|
|
970
|
+
community: RemoteCommunity;
|
|
971
|
+
pkc?: PKC;
|
|
972
|
+
}): Promise<Comment>;
|
|
973
|
+
export declare function publishCommentWithDepth({ depth, community }: {
|
|
974
|
+
depth: number;
|
|
975
|
+
community: RemoteCommunity;
|
|
976
|
+
}): Promise<Comment>;
|
|
977
|
+
export declare function getCommentWithCommentUpdateProps({ cid, pkc }: {
|
|
978
|
+
cid: string;
|
|
979
|
+
pkc: PKC;
|
|
980
|
+
}): Promise<Comment>;
|
|
981
|
+
export declare function publishCommentToModQueue({ community, pkc, parentComment, commentProps }: {
|
|
982
|
+
community: RemoteCommunity;
|
|
983
|
+
pkc?: PKC;
|
|
984
|
+
parentComment?: Comment;
|
|
985
|
+
commentProps?: Partial<CreateCommentOptions>;
|
|
986
|
+
}): Promise<{
|
|
987
|
+
comment: Comment;
|
|
988
|
+
challengeVerification: DecryptedChallengeVerificationMessageType;
|
|
989
|
+
}>;
|
|
990
|
+
export declare function publishToModQueueWithDepth({ community, depth, pkc, modCommentProps, commentProps }: {
|
|
991
|
+
community: RemoteCommunity;
|
|
992
|
+
pkc: PKC;
|
|
993
|
+
depth: number;
|
|
994
|
+
modCommentProps?: Partial<CreateCommentOptions>;
|
|
995
|
+
commentProps?: Partial<CreateCommentOptions>;
|
|
996
|
+
}): Promise<{
|
|
997
|
+
comment: Comment;
|
|
998
|
+
challengeVerification: unknown;
|
|
999
|
+
}>;
|
|
1000
|
+
export declare function forceCommunityToGenerateAllPostsPages(community: RemoteCommunity, commentProps?: CreateCommentOptions): Promise<void>;
|
|
1001
|
+
export declare function mockReplyToUseParentPagesForUpdates(reply: Comment): void;
|
|
1002
|
+
export declare function mockUpdatingCommentResolvingAuthor(comment: Comment, mockFunction: Comment["_clientsManager"]["resolveAuthorNameIfNeeded"]): void;
|
|
1003
|
+
export declare function getRandomPostCidFromSub(communityAddress: string, pkc: PKC): Promise<string>;
|
|
1004
|
+
export declare const describeSkipIfRpc: any;
|
|
1005
|
+
export declare const describeIfRpc: any;
|
|
1006
|
+
export declare const itSkipIfRpc: any;
|
|
1007
|
+
export declare const itIfRpc: any;
|
|
1008
|
+
export declare function mockNameResolvers<T extends {
|
|
1009
|
+
name: string;
|
|
1010
|
+
provider: string;
|
|
1011
|
+
}>({ pkc, resolveFunction }: {
|
|
1012
|
+
pkc: PKC;
|
|
1013
|
+
resolveFunction: (opts: T) => Promise<{
|
|
1014
|
+
publicKey: string;
|
|
1015
|
+
[key: string]: string;
|
|
1016
|
+
} | undefined>;
|
|
1017
|
+
}): void;
|
|
1018
|
+
export declare function processAllCommentsRecursively(comments: (Comment | CommentWithinRepliesPostsPageJson)[] | undefined, processor: (comment: Comment | CommentWithinRepliesPostsPageJson) => void): void;
|
|
1019
|
+
export {};
|