Reverts `js/webtorrent.js` and `js/gridHealth.js` to a simplified implementation that correctly treats webseeds as peers. This ensures that videos with only webseeds (and 0 P2P peers) are considered healthy and playable, resolving an issue where such videos were marked as unhealthy or failed to stream.
- Updates `js/webtorrent.js` to use `client.add(url, { urlList: [...] })` for better webseed integration.
- Updates `js/gridHealth.js` to rely on `peers > 0` for health, removing complex `webseedOnly` logic.
- Updates `tests/webtorrent-regression.test.mjs` to verify that webseeds are counted as peers and result in a healthy state with reason "peer".
- Excludes `bitvid-working-webtorrent/**` from all linting scripts (`scripts/check-hex.js`, `scripts/check-design-tokens.mjs`, `scripts/check-inline-styles.mjs`, `scripts/check-tailwind-colors.mjs`, `stylelint.config.cjs`) to prevent CI failures from reference code.
Co-authored-by: PR0M3TH3AN <[email protected]>
Run `npm run format` and `npm run lint`.
Fix stylelint configuration to correctly parse variables with units in their names.
Migrate raw CSS measurements to tokens in `css/tokens.css` and update usages in `css/tailwind.source.css` and HTML templates.
Improve `scripts/check-design-tokens.mjs` to handle variable names with unit-like suffixes.
Files changed:
- css/tailwind.source.css (formatted and fixed lint)
- css/tokens.css (added tokens)
- stylelint.config.cjs (fixed regex)
- scripts/check-design-tokens.mjs (improved detection logic)
- components/profile-modal.html (fixed arbitrary values)
- index.html (fixed arbitrary values)