Add comprehensive installation and setup documentation

- Add GETTING_STARTED.md with quick start guide and development modes
- Add INSTALL.sh automated installation script
- Add INSTALLATION_CHECKLIST.md, INSTALLATION_SUCCESS.md, and INSTALLATION_SUMMARY.md
- Add QUICK_REFERENCE.md for common commands
- Add SETUP_GUIDE.md with detailed setup instructions
- Update README.md with improved project overview
- Add did-wallet app dependencies and node_modules
This commit is contained in:
Dorian
2026-01-27 17:18:21 +00:00
parent a81f655133
commit 0d073fa89e
22658 changed files with 4494151 additions and 6 deletions

176
apps/web5-dwn/node_modules/jsbi/LICENSE generated vendored Normal file
View File

@@ -0,0 +1,176 @@
Apache License
Version 2.0, January 2004
https://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS

173
apps/web5-dwn/node_modules/jsbi/README.md generated vendored Normal file
View File

@@ -0,0 +1,173 @@
# JSBI — pure-JavaScript BigInts [![Build status](https://github.com/GoogleChromeLabs/jsbi/actions/workflows/main.yml/badge.svg)](https://github.com/GoogleChromeLabs/jsbi/actions/workflows/main.yml) [![jsbi on npm](https://img.shields.io/npm/v/jsbi)](https://www.npmjs.com/package/jsbi)
JSBI is a pure-JavaScript implementation of [the ECMAScript BigInt proposal](https://tc39.es/proposal-bigint/), which officially became a part of the JavaScript language in ES2020.
## Installation
```sh
npm install jsbi --save
```
## Usage
```js
import JSBI from './jsbi.mjs';
const max = JSBI.BigInt(Number.MAX_SAFE_INTEGER);
console.log(String(max));
// → '9007199254740991'
const other = JSBI.BigInt('2');
const result = JSBI.add(max, other);
console.log(String(result));
// → '9007199254740993'
```
Note: explicitly call `toString` on any `JSBI` instances when `console.log()`ing them to see their numeric representation (e.g. `String(max)` or `max.toString()`). Without it (e.g. `console.log(max)`), youll instead see the object that represents the value.
Use [babel-plugin-transform-jsbi-to-bigint](https://github.com/GoogleChromeLabs/babel-plugin-transform-jsbi-to-bigint) to transpile JSBI code into native BigInt code.
Refer to the detailed instructions below for more information.
## Why?
[Native BigInts are already shipping](https://v8.dev/features/bigint) in modern browsers (at the time of this writing, Google Chrome 67+, Opera 54+, Firefox 68+, Edge 79+, Safari 14+) and Node.js (v10.4+), but some users are still running older browsers — which means you can't use them yet if you want your code to run everywhere.
To use BigInts in code that you want to run *everywhere*, you need a library. But theres a difficulty: the BigInt proposal changes the behavior of operators (like `+`, `>=`, etc.) to work on BigInts. These changes are impossible to polyfill directly; and they are also making it infeasible (in most cases) to transpile BigInt code to fallback code using Babel or similar tools. The reason is that such a transpilation would have to replace every single operator in the program with a call to some function that performs type checks on its inputs, which would incur an unacceptable performance penalty.
The solution is to do it the other way round: write code using a librarys syntax, and [transpile it to native BigInt code](https://github.com/GoogleChromeLabs/babel-plugin-transform-jsbi-to-bigint) when available. JSBI is designed for exactly this purpose: it provides a BigInt “polyfill” implementation that behaves exactly like the upcoming native BigInts, but with a syntax that you can ship on all browsers, today.
Its advantages over other, existing big-integer libraries are:
- it behaves exactly like native BigInts do where they are available, so to eventually migrate to those, you can [mechanically](https://github.com/GoogleChromeLabs/babel-plugin-transform-jsbi-to-bigint) update your codes syntax; no re-thinking of its logic will be required.
- strong focus on performance. On average, JSBI is performance-competitive with the native implementation that Google Chrome is currently shipping. (Note: we expect this statement to gradually become outdated as browsers invest in additional optimizations.)
## How?
Except for mechanical differences in syntax, you use JSBI-BigInts just [like you would use native BigInts](https://developers.google.com/web/updates/2018/05/bigint). Some things even look the same, after you replace `BigInt` with `JSBI.BigInt`:
| Operation | native BigInts | JSBI |
| -------------------- | ----------------------- | ------------------------ |
| Creation from String | `a = BigInt('456')` | `a = JSBI.BigInt('456')` |
| Creation from Number | `a = BigInt(789)` | `a = JSBI.BigInt(789)` |
| Conversion to String | `a.toString(radix)` | `a.toString(radix)` |
| Conversion to Number | `Number(a)` | `JSBI.toNumber(a)` |
| Truncation | `BigInt.asIntN(64, a)` | `JSBI.asIntN(64, a)` |
| | `BigInt.asUintN(64, a)` | `JSBI.asUintN(64, a)` |
| Type check | `typeof a === 'bigint'` | `a instanceof JSBI` |
Most operators are replaced by static functions:
| Operation | native BigInts | JSBI |
| --------------------------- | -------------- | --------------------------------- |
| Addition | `c = a + b` | `c = JSBI.add(a, b)` |
| Subtraction | `c = a - b` | `c = JSBI.subtract(a, b)` |
| Multiplication | `c = a * b` | `c = JSBI.multiply(a, b)` |
| Division | `c = a / b` | `c = JSBI.divide(a, b)` |
| Remainder | `c = a % b` | `c = JSBI.remainder(a, b)` |
| Exponentiation | `c = a ** b` | `c = JSBI.exponentiate(a, b)` |
| Negation | `b = -a` | `b = JSBI.unaryMinus(a)` |
| Bitwise negation | `b = ~a` | `b = JSBI.bitwiseNot(a)` |
| Left shifting | `c = a << b` | `c = JSBI.leftShift(a, b)` |
| Right shifting | `c = a >> b` | `c = JSBI.signedRightShift(a, b)` |
| Bitwise “and” | `c = a & b` | `c = JSBI.bitwiseAnd(a, b)` |
| Bitwise “or” | `c = a \| b` | `c = JSBI.bitwiseOr(a, b)` |
| Bitwise “xor” | `c = a ^ b` | `c = JSBI.bitwiseXor(a, b)` |
| Comparison to other BigInts | `a === b` | `JSBI.equal(a, b)` |
| | `a !== b` | `JSBI.notEqual(a, b)` |
| | `a < b` | `JSBI.lessThan(a, b)` |
| | `a <= b` | `JSBI.lessThanOrEqual(a, b)` |
| | `a > b` | `JSBI.greaterThan(a, b)` |
| | `a >= b` | `JSBI.greaterThanOrEqual(a, b)` |
The functions above operate only on BigInts. (They dont perform type checks in the current implementation, because such checks are a waste of time when we assume that you know what youre doing. Dont try to call them with other inputs, or youll get “interesting” failures!)
Some operations are particularly interesting when you give them inputs of mixed types, e.g. comparing a BigInt to a Number, or concatenating a string with a BigInt. They are implemented as static functions named after the respective native operators:
| Operation | native BigInts | JSBI |
| ------------------------------- | -------------- | ---------------- |
| Abstract equality comparison | `x == y` | `JSBI.EQ(x, y)` |
| Generic “not equal” | `x != y` | `JSBI.NE(x, y)` |
| Generic “less than” | `x < y` | `JSBI.LT(x, y)` |
| Generic “less than or equal” | `x <= y` | `JSBI.LE(x, y)` |
| Generic “greater than” | `x > y` | `JSBI.GT(x, y)` |
| Generic “greater than or equal” | `x >= y` | `JSBI.GE(x, y)` |
| Generic addition | `x + y` | `JSBI.ADD(x, y)` |
The variable names `x` and `y` here indicate that the variables can refer to anything, for example: `JSBI.GT(101.5, BigInt('100'))` or `str = JSBI.ADD('result: ', BigInt('0x2A'))`.
Unfortunately, there are also a few things that are not supported at all:
| Unsupported operation | native BigInts | JSBI |
| --------------------- | -------------- | ------------------------------------ |
| literals | `a = 123n;` | N/A ☹ |
| increment | `a++` | N/A ☹ |
| | `a + 1n` | `JSBI.add(a, JSBI.BigInt('1'))` |
| decrement | `a--` | N/A ☹ |
| | `a - 1n` | `JSBI.subtract(a, JSBI.BigInt('1'))` |
It is impossible to replicate the exact behavior of the native `++` and `--` operators in a polyfill/library. Since JSBI is intended to be transpiled away eventually, it doesnt provide a similar-but-different alternative. You can use `JSBI.add()` and `JSBI.subtract()` instead.
Since version 4.2.0, polyfills for `DataView` operations are included (where `dv` is a `DataView`, `i` is an index, `le` is an optional boolean indicating little endian mode, and `x` is a `BigInt` or a `JSBI` instance, respectively):
| native BigInts/DataViews | JSBI |
|-----------------------------|-------------------------------------------|
| `dv.getBigInt64(i, le)` | `JSBI.DataViewGetBigInt64(dv, i, le)` |
| `dv.setBigInt64(i, x, le)` | `JSBI.DataViewSetBigInt64(dv, i, x, le)` |
| `dv.getBigUint64(i, le)` | `JSBI.DataViewGetBigUint64(dv, i, le)` |
| `dv.setBigUint64(i, x, le)` | `JSBI.DataViewSetBigUint64(dv, i, x, le)` |
## When?
Now! The JSBI library is ready for use today.
Once BigInts are natively supported everywhere, use [babel-plugin-transform-jsbi-to-bigint](https://github.com/GoogleChromeLabs/babel-plugin-transform-jsbi-to-bigint) to transpile your JSBI code into native BigInt code once and for all.
View [our issue tracker](https://github.com/GoogleChromeLabs/jsbi/issues) to learn more about out our future plans for JSBI, and please join the discussion!
A more vague future plan is to use the JSBI library (or an extension to it) as a staging ground for additional BigInt-related functionality. The official proposal is intentionally somewhat minimal, and leaves further “library functions” for follow-up proposals. Examples are a combined `exp`+`mod` function, and bit manipulation functions.
## Development
1. Clone this repository and `cd` into the local directory.
1. Use the Node.js version specified in `.nvmrc`:
```sh
nvm use
```
1. Install development dependencies:
```sh
npm install
```
1. Run the tests:
```sh
npm test
```
See `npm run` for the list of commands.
## For maintainers
### How to publish a new release
1. On the `main` branch, bump the version number in `package.json`:
```sh
npm version patch -m 'Release v%s'
```
Instead of `patch`, use `minor` or `major` [as needed](https://semver.org/).
Note that this produces a Git commit + tag.
1. Push the release commit and tag:
```sh
git push && git push --tags
```
Our CI then automatically publishes the new release to npm.

2
apps/web5-dwn/node_modules/jsbi/dist/jsbi-cjs.js generated vendored Normal file

File diff suppressed because one or more lines are too long

1
apps/web5-dwn/node_modules/jsbi/dist/jsbi-cjs.js.map generated vendored Normal file

File diff suppressed because one or more lines are too long

2
apps/web5-dwn/node_modules/jsbi/dist/jsbi-umd.js generated vendored Normal file

File diff suppressed because one or more lines are too long

1
apps/web5-dwn/node_modules/jsbi/dist/jsbi-umd.js.map generated vendored Normal file

File diff suppressed because one or more lines are too long

2
apps/web5-dwn/node_modules/jsbi/dist/jsbi.mjs generated vendored Normal file

File diff suppressed because one or more lines are too long

1
apps/web5-dwn/node_modules/jsbi/dist/jsbi.mjs.map generated vendored Normal file

File diff suppressed because one or more lines are too long

43
apps/web5-dwn/node_modules/jsbi/jsbi.d.ts generated vendored Normal file
View File

@@ -0,0 +1,43 @@
declare class JSBI extends Array {
private sign;
private constructor();
static BigInt(arg: number | string | boolean | object): JSBI;
toDebugString(): string;
toString(radix?: number): string;
valueOf(): void;
static toNumber(x: JSBI): number;
static unaryMinus(x: JSBI): JSBI;
static bitwiseNot(x: JSBI): JSBI;
static exponentiate(x: JSBI, y: JSBI): JSBI;
static multiply(x: JSBI, y: JSBI): JSBI;
static divide(x: JSBI, y: JSBI): JSBI;
static remainder(x: JSBI, y: JSBI): JSBI;
static add(x: JSBI, y: JSBI): JSBI;
static subtract(x: JSBI, y: JSBI): JSBI;
static leftShift(x: JSBI, y: JSBI): JSBI;
static signedRightShift(x: JSBI, y: JSBI): JSBI;
static unsignedRightShift(): void;
static lessThan(x: JSBI, y: JSBI): boolean;
static lessThanOrEqual(x: JSBI, y: JSBI): boolean;
static greaterThan(x: JSBI, y: JSBI): boolean;
static greaterThanOrEqual(x: JSBI, y: JSBI): boolean;
static equal(x: JSBI, y: JSBI): boolean;
static notEqual(x: JSBI, y: JSBI): boolean;
static bitwiseAnd(x: JSBI, y: JSBI): JSBI;
static bitwiseXor(x: JSBI, y: JSBI): JSBI;
static bitwiseOr(x: JSBI, y: JSBI): JSBI;
static asIntN(n: number, x: JSBI): JSBI;
static asUintN(n: number, x: JSBI): JSBI;
static ADD(x: any, y: any): string | number | JSBI;
static LT(x: any, y: any): boolean;
static LE(x: any, y: any): boolean;
static GT(x: any, y: any): boolean;
static GE(x: any, y: any): boolean;
static EQ(x: any, y: any): boolean;
static NE(x: any, y: any): boolean;
static DataViewGetBigInt64(dataview: DataView, byteOffset: number, littleEndian?: boolean): JSBI;
static DataViewGetBigUint64(dataview: DataView, byteOffset: number, littleEndian?: boolean): JSBI;
static DataViewSetBigInt64(dataview: DataView, byteOffset: number, value: JSBI, littleEndian?: boolean): void;
static DataViewSetBigUint64(dataview: DataView, byteOffset: number, value: JSBI, littleEndian?: boolean): void;
}
export default JSBI;

35
apps/web5-dwn/node_modules/jsbi/package.json generated vendored Normal file
View File

@@ -0,0 +1,35 @@
{
"name": "jsbi",
"version": "4.3.2",
"repository": "GoogleChromeLabs/jsbi",
"devDependencies": {
"@babel/preset-env": "^7.5.5",
"@typescript-eslint/eslint-plugin": "^4.29.1",
"@typescript-eslint/parser": "^4.29.1",
"eslint": "^6.2.0",
"eslint-config-google": "^0.14.0",
"rollup": "^1.19.4",
"rollup-plugin-babel": "^4.3.3",
"rollup-plugin-babel-minify": "^9.0.0",
"typescript": "^4.4.2"
},
"main": "dist/jsbi-cjs.js",
"module": "dist/jsbi.mjs",
"browser": "dist/jsbi-umd.js",
"types": "jsbi.d.ts",
"files": [
"dist",
"jsbi.d.ts"
],
"scripts": {
"build": "tsc && for f in tsc-out/*.js; do mv -- \"$f\" \"${f%.js}.mjs\"; done && sed -e '/__absoluteDivLarge/,+4d' tsc-out/jsbi.d.ts | grep -v ' __' > jsbi.d.ts && rollup --config rollup.config.js",
"dev": "tsc --watch",
"test": "set -e; for file in tests/*.mjs; do node --no-warnings --experimental-modules --experimental-specifier-resolution=node --loader ./tests/resolve.source.mjs \"${file}\"; done; for file in benchmarks/*.mjs; do node --no-warnings --experimental-modules --experimental-specifier-resolution=node --loader ./tests/resolve.source.mjs \"${file}\"; done",
"pretest": "npm run build",
"prepublish": "npm run ci",
"lint": "eslint . --ext ts --fix",
"generate-benchmarks": "for op in add and div mod mul neg not or sar shl sub xor; do scripts/generate-benchmark.py generate \"${op}\" > \"benchmarks/${op}.mjs\"; done",
"ci": "npm run lint && npm run build && git status && git diff-index --quiet HEAD -- || git diff && npm test"
},
"license": "Apache-2.0"
}