From 874a4607fe169937f3509e5538286f414a3f2088 Mon Sep 17 00:00:00 2001 From: nksazonov Date: Wed, 29 Apr 2026 12:47:34 +0200 Subject: [PATCH 01/16] refactor(docs): move content into /nitrolite and /clearnet directory structure MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Reorganize the docs/ tree to mirror the planned sub-site split. All Nitrolite content (learn, build/sdk, build/getting-started, build/quick-start, api-reference, tutorials, protocol/protocol-reference, protocol/terminology) moves under docs/nitrolite/. All Clearnet content (introduction, architecture, decentralized-layer, contracts) moves under docs/clearnet/. Removes orphaned docs/build/api/_category_.json. The main sidebar config sidebars.ts is renamed to sidebars-nitrolite.ts to match the naming pattern of the upcoming sidebars-clearnet.ts. This commit is purely structural — no in-file content changes; build is intentionally broken until the follow-up commit wires up docusaurus.config.ts. --- docs/build/api/_category_.json | 9 --------- docs/{protocol => clearnet}/architecture.mdx | 0 docs/{build/api => clearnet}/contracts/_category_.json | 0 .../contracts/api-reference/_category_.json | 0 .../contracts/api-reference/app-registry.md | 0 .../api => clearnet}/contracts/api-reference/faucet.md | 0 .../contracts/api-reference/interfaces/_category_.json | 0 .../contracts/api-reference/interfaces/ilock.md | 0 .../contracts/api-reference/interfaces/islash.md | 0 .../api => clearnet}/contracts/api-reference/locker.md | 0 .../contracts/api-reference/node-registry.md | 0 .../api => clearnet}/contracts/api-reference/treasury.md | 0 .../contracts/api-reference/yellow-governor.md | 0 .../contracts/api-reference/yellow-token.md | 0 docs/{build/api => clearnet}/contracts/faq.md | 0 docs/{build/api => clearnet}/contracts/index.md | 0 .../contracts/integration/_category_.json | 0 .../api => clearnet}/contracts/integration/deployment.md | 0 .../api => clearnet}/contracts/integration/events.md | 0 .../api => clearnet}/contracts/integration/ui-spec.md | 0 .../api => clearnet}/contracts/protocol/_category_.json | 0 .../api => clearnet}/contracts/protocol/governance.md | 0 .../api => clearnet}/contracts/protocol/overview.md | 0 .../api => clearnet}/contracts/protocol/slashing.md | 0 .../api => clearnet}/contracts/protocol/staking.md | 0 .../api => clearnet}/contracts/protocol/treasury.md | 0 .../api => clearnet}/contracts/sdk/_category_.json | 0 .../api => clearnet}/contracts/sdk/api-reference.md | 0 docs/{build/api => clearnet}/contracts/sdk/examples.md | 0 .../api => clearnet}/contracts/sdk/getting-started.md | 0 .../decentralized-layer/_category_.json | 0 .../decentralized-layer/cluster-lifecycle.mdx | 0 .../decentralized-layer/elastic-security.mdx | 0 .../decentralized-layer/liquidity-layer.mdx | 0 .../decentralized-layer/overview.mdx | 0 .../decentralized-layer/protocol-lifecycle.mdx | 0 .../decentralized-layer/security.mdx | 0 docs/{protocol => clearnet}/introduction.mdx | 0 docs/{ => nitrolite}/api-reference/_category_.json | 0 docs/{ => nitrolite}/api-reference/app-sessions.md | 0 docs/{ => nitrolite}/api-reference/index.md | 0 docs/{ => nitrolite}/build/_category_.json | 0 .../build/getting-started/_category_.json | 0 docs/{ => nitrolite}/build/getting-started/key-terms.mdx | 0 .../build/getting-started/prerequisites.mdx | 0 .../{ => nitrolite}/build/getting-started/quickstart.mdx | 0 docs/{ => nitrolite}/build/quick-start/index.md | 0 docs/{ => nitrolite}/build/sdk/_category_.json | 0 docs/{ => nitrolite}/build/sdk/go/_category_.json | 0 docs/{ => nitrolite}/build/sdk/go/api-reference.mdx | 0 docs/{ => nitrolite}/build/sdk/go/getting-started.mdx | 0 docs/{ => nitrolite}/build/sdk/index.md | 0 docs/{ => nitrolite}/build/sdk/migration-guide.md | 0 .../build/sdk/multi-party-app-sessions.mdx | 0 .../build/sdk/typescript-compat/_category_.json | 0 .../build/sdk/typescript-compat/migration-offchain.mdx | 0 .../build/sdk/typescript-compat/migration-onchain.mdx | 0 .../build/sdk/typescript-compat/migration-overview.mdx | 0 .../build/sdk/typescript-compat/overview.mdx | 0 .../{ => nitrolite}/build/sdk/typescript/_category_.json | 0 .../build/sdk/typescript/api-reference.mdx | 0 .../build/sdk/typescript/configuration.mdx | 0 docs/{ => nitrolite}/build/sdk/typescript/examples.mdx | 0 .../build/sdk/typescript/getting-started.mdx | 0 docs/{ => nitrolite}/learn/_category_.json | 0 docs/{ => nitrolite}/learn/core-concepts/_category_.json | 0 .../learn/core-concepts/challenge-response.mdx | 0 .../learn/core-concepts/state-channels-vs-l1-l2.mdx | 0 .../{ => nitrolite}/learn/core-concepts/yellow-token.mdx | 0 docs/{ => nitrolite}/learn/index.mdx | 0 docs/{ => nitrolite}/learn/introduction/_category_.json | 0 .../learn/introduction/architecture-at-a-glance.mdx | 0 .../learn/introduction/supported-chains.mdx | 0 .../learn/introduction/what-yellow-solves.mdx | 0 .../{ => nitrolite}/learn/protocol-flows/_category_.json | 0 .../learn/protocol-flows/app-session-deposit.mdx | 0 .../learn/protocol-flows/architecture.mdx | 0 .../learn/protocol-flows/escrow-deposit.mdx | 0 .../learn/protocol-flows/escrow-withdrawal.mdx | 0 .../learn/protocol-flows/home-channel-creation.mdx | 0 .../learn/protocol-flows/home-channel-deposit.mdx | 0 .../protocol-flows/home-channel-withdraw-on-create.mdx | 0 .../learn/protocol-flows/home-channel-withdrawal.mdx | 0 .../learn/protocol-flows/transfer-flow.mdx | 0 docs/{ => nitrolite}/protocol/_category_.json | 0 docs/{ => nitrolite}/protocol/protocol-reference.mdx | 0 docs/{ => nitrolite}/protocol/terminology.mdx | 0 docs/{ => nitrolite}/tutorials/_category_.json | 0 docs/{ => nitrolite}/tutorials/index.md | 0 sidebars.ts => sidebars-nitrolite.ts | 0 90 files changed, 9 deletions(-) delete mode 100644 docs/build/api/_category_.json rename docs/{protocol => clearnet}/architecture.mdx (100%) rename docs/{build/api => clearnet}/contracts/_category_.json (100%) rename docs/{build/api => clearnet}/contracts/api-reference/_category_.json (100%) rename docs/{build/api => clearnet}/contracts/api-reference/app-registry.md (100%) rename docs/{build/api => clearnet}/contracts/api-reference/faucet.md (100%) rename docs/{build/api => clearnet}/contracts/api-reference/interfaces/_category_.json (100%) rename docs/{build/api => clearnet}/contracts/api-reference/interfaces/ilock.md (100%) rename docs/{build/api => clearnet}/contracts/api-reference/interfaces/islash.md (100%) rename docs/{build/api => clearnet}/contracts/api-reference/locker.md (100%) rename docs/{build/api => clearnet}/contracts/api-reference/node-registry.md (100%) rename docs/{build/api => clearnet}/contracts/api-reference/treasury.md (100%) rename docs/{build/api => clearnet}/contracts/api-reference/yellow-governor.md (100%) rename docs/{build/api => clearnet}/contracts/api-reference/yellow-token.md (100%) rename docs/{build/api => clearnet}/contracts/faq.md (100%) rename docs/{build/api => clearnet}/contracts/index.md (100%) rename docs/{build/api => clearnet}/contracts/integration/_category_.json (100%) rename docs/{build/api => clearnet}/contracts/integration/deployment.md (100%) rename docs/{build/api => clearnet}/contracts/integration/events.md (100%) rename docs/{build/api => clearnet}/contracts/integration/ui-spec.md (100%) rename docs/{build/api => clearnet}/contracts/protocol/_category_.json (100%) rename docs/{build/api => clearnet}/contracts/protocol/governance.md (100%) rename docs/{build/api => clearnet}/contracts/protocol/overview.md (100%) rename docs/{build/api => clearnet}/contracts/protocol/slashing.md (100%) rename docs/{build/api => clearnet}/contracts/protocol/staking.md (100%) rename docs/{build/api => clearnet}/contracts/protocol/treasury.md (100%) rename docs/{build/api => clearnet}/contracts/sdk/_category_.json (100%) rename docs/{build/api => clearnet}/contracts/sdk/api-reference.md (100%) rename docs/{build/api => clearnet}/contracts/sdk/examples.md (100%) rename docs/{build/api => clearnet}/contracts/sdk/getting-started.md (100%) rename docs/{protocol => clearnet}/decentralized-layer/_category_.json (100%) rename docs/{protocol => clearnet}/decentralized-layer/cluster-lifecycle.mdx (100%) rename docs/{protocol => clearnet}/decentralized-layer/elastic-security.mdx (100%) rename docs/{protocol => clearnet}/decentralized-layer/liquidity-layer.mdx (100%) rename docs/{protocol => clearnet}/decentralized-layer/overview.mdx (100%) rename docs/{protocol => clearnet}/decentralized-layer/protocol-lifecycle.mdx (100%) rename docs/{protocol => clearnet}/decentralized-layer/security.mdx (100%) rename docs/{protocol => clearnet}/introduction.mdx (100%) rename docs/{ => nitrolite}/api-reference/_category_.json (100%) rename docs/{ => nitrolite}/api-reference/app-sessions.md (100%) rename docs/{ => nitrolite}/api-reference/index.md (100%) rename docs/{ => nitrolite}/build/_category_.json (100%) rename docs/{ => nitrolite}/build/getting-started/_category_.json (100%) rename docs/{ => nitrolite}/build/getting-started/key-terms.mdx (100%) rename docs/{ => nitrolite}/build/getting-started/prerequisites.mdx (100%) rename docs/{ => nitrolite}/build/getting-started/quickstart.mdx (100%) rename docs/{ => nitrolite}/build/quick-start/index.md (100%) rename docs/{ => nitrolite}/build/sdk/_category_.json (100%) rename docs/{ => nitrolite}/build/sdk/go/_category_.json (100%) rename docs/{ => nitrolite}/build/sdk/go/api-reference.mdx (100%) rename docs/{ => nitrolite}/build/sdk/go/getting-started.mdx (100%) rename docs/{ => nitrolite}/build/sdk/index.md (100%) rename docs/{ => nitrolite}/build/sdk/migration-guide.md (100%) rename docs/{ => nitrolite}/build/sdk/multi-party-app-sessions.mdx (100%) rename docs/{ => nitrolite}/build/sdk/typescript-compat/_category_.json (100%) rename docs/{ => nitrolite}/build/sdk/typescript-compat/migration-offchain.mdx (100%) rename docs/{ => nitrolite}/build/sdk/typescript-compat/migration-onchain.mdx (100%) rename docs/{ => nitrolite}/build/sdk/typescript-compat/migration-overview.mdx (100%) rename docs/{ => nitrolite}/build/sdk/typescript-compat/overview.mdx (100%) rename docs/{ => nitrolite}/build/sdk/typescript/_category_.json (100%) rename docs/{ => nitrolite}/build/sdk/typescript/api-reference.mdx (100%) rename docs/{ => nitrolite}/build/sdk/typescript/configuration.mdx (100%) rename docs/{ => nitrolite}/build/sdk/typescript/examples.mdx (100%) rename docs/{ => nitrolite}/build/sdk/typescript/getting-started.mdx (100%) rename docs/{ => nitrolite}/learn/_category_.json (100%) rename docs/{ => nitrolite}/learn/core-concepts/_category_.json (100%) rename docs/{ => nitrolite}/learn/core-concepts/challenge-response.mdx (100%) rename docs/{ => nitrolite}/learn/core-concepts/state-channels-vs-l1-l2.mdx (100%) rename docs/{ => nitrolite}/learn/core-concepts/yellow-token.mdx (100%) rename docs/{ => nitrolite}/learn/index.mdx (100%) rename docs/{ => nitrolite}/learn/introduction/_category_.json (100%) rename docs/{ => nitrolite}/learn/introduction/architecture-at-a-glance.mdx (100%) rename docs/{ => nitrolite}/learn/introduction/supported-chains.mdx (100%) rename docs/{ => nitrolite}/learn/introduction/what-yellow-solves.mdx (100%) rename docs/{ => nitrolite}/learn/protocol-flows/_category_.json (100%) rename docs/{ => nitrolite}/learn/protocol-flows/app-session-deposit.mdx (100%) rename docs/{ => nitrolite}/learn/protocol-flows/architecture.mdx (100%) rename docs/{ => nitrolite}/learn/protocol-flows/escrow-deposit.mdx (100%) rename docs/{ => nitrolite}/learn/protocol-flows/escrow-withdrawal.mdx (100%) rename docs/{ => nitrolite}/learn/protocol-flows/home-channel-creation.mdx (100%) rename docs/{ => nitrolite}/learn/protocol-flows/home-channel-deposit.mdx (100%) rename docs/{ => nitrolite}/learn/protocol-flows/home-channel-withdraw-on-create.mdx (100%) rename docs/{ => nitrolite}/learn/protocol-flows/home-channel-withdrawal.mdx (100%) rename docs/{ => nitrolite}/learn/protocol-flows/transfer-flow.mdx (100%) rename docs/{ => nitrolite}/protocol/_category_.json (100%) rename docs/{ => nitrolite}/protocol/protocol-reference.mdx (100%) rename docs/{ => nitrolite}/protocol/terminology.mdx (100%) rename docs/{ => nitrolite}/tutorials/_category_.json (100%) rename docs/{ => nitrolite}/tutorials/index.md (100%) rename sidebars.ts => sidebars-nitrolite.ts (100%) diff --git a/docs/build/api/_category_.json b/docs/build/api/_category_.json deleted file mode 100644 index 69cc463..0000000 --- a/docs/build/api/_category_.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "label": "API", - "position": 3, - "link": { - "type": "generated-index" - }, - "collapsible": false, - "collapsed": false -} diff --git a/docs/protocol/architecture.mdx b/docs/clearnet/architecture.mdx similarity index 100% rename from docs/protocol/architecture.mdx rename to docs/clearnet/architecture.mdx diff --git a/docs/build/api/contracts/_category_.json b/docs/clearnet/contracts/_category_.json similarity index 100% rename from docs/build/api/contracts/_category_.json rename to docs/clearnet/contracts/_category_.json diff --git a/docs/build/api/contracts/api-reference/_category_.json b/docs/clearnet/contracts/api-reference/_category_.json similarity index 100% rename from docs/build/api/contracts/api-reference/_category_.json rename to docs/clearnet/contracts/api-reference/_category_.json diff --git a/docs/build/api/contracts/api-reference/app-registry.md b/docs/clearnet/contracts/api-reference/app-registry.md similarity index 100% rename from docs/build/api/contracts/api-reference/app-registry.md rename to docs/clearnet/contracts/api-reference/app-registry.md diff --git a/docs/build/api/contracts/api-reference/faucet.md b/docs/clearnet/contracts/api-reference/faucet.md similarity index 100% rename from docs/build/api/contracts/api-reference/faucet.md rename to docs/clearnet/contracts/api-reference/faucet.md diff --git a/docs/build/api/contracts/api-reference/interfaces/_category_.json b/docs/clearnet/contracts/api-reference/interfaces/_category_.json similarity index 100% rename from docs/build/api/contracts/api-reference/interfaces/_category_.json rename to docs/clearnet/contracts/api-reference/interfaces/_category_.json diff --git a/docs/build/api/contracts/api-reference/interfaces/ilock.md b/docs/clearnet/contracts/api-reference/interfaces/ilock.md similarity index 100% rename from docs/build/api/contracts/api-reference/interfaces/ilock.md rename to docs/clearnet/contracts/api-reference/interfaces/ilock.md diff --git a/docs/build/api/contracts/api-reference/interfaces/islash.md b/docs/clearnet/contracts/api-reference/interfaces/islash.md similarity index 100% rename from docs/build/api/contracts/api-reference/interfaces/islash.md rename to docs/clearnet/contracts/api-reference/interfaces/islash.md diff --git a/docs/build/api/contracts/api-reference/locker.md b/docs/clearnet/contracts/api-reference/locker.md similarity index 100% rename from docs/build/api/contracts/api-reference/locker.md rename to docs/clearnet/contracts/api-reference/locker.md diff --git a/docs/build/api/contracts/api-reference/node-registry.md b/docs/clearnet/contracts/api-reference/node-registry.md similarity index 100% rename from docs/build/api/contracts/api-reference/node-registry.md rename to docs/clearnet/contracts/api-reference/node-registry.md diff --git a/docs/build/api/contracts/api-reference/treasury.md b/docs/clearnet/contracts/api-reference/treasury.md similarity index 100% rename from docs/build/api/contracts/api-reference/treasury.md rename to docs/clearnet/contracts/api-reference/treasury.md diff --git a/docs/build/api/contracts/api-reference/yellow-governor.md b/docs/clearnet/contracts/api-reference/yellow-governor.md similarity index 100% rename from docs/build/api/contracts/api-reference/yellow-governor.md rename to docs/clearnet/contracts/api-reference/yellow-governor.md diff --git a/docs/build/api/contracts/api-reference/yellow-token.md b/docs/clearnet/contracts/api-reference/yellow-token.md similarity index 100% rename from docs/build/api/contracts/api-reference/yellow-token.md rename to docs/clearnet/contracts/api-reference/yellow-token.md diff --git a/docs/build/api/contracts/faq.md b/docs/clearnet/contracts/faq.md similarity index 100% rename from docs/build/api/contracts/faq.md rename to docs/clearnet/contracts/faq.md diff --git a/docs/build/api/contracts/index.md b/docs/clearnet/contracts/index.md similarity index 100% rename from docs/build/api/contracts/index.md rename to docs/clearnet/contracts/index.md diff --git a/docs/build/api/contracts/integration/_category_.json b/docs/clearnet/contracts/integration/_category_.json similarity index 100% rename from docs/build/api/contracts/integration/_category_.json rename to docs/clearnet/contracts/integration/_category_.json diff --git a/docs/build/api/contracts/integration/deployment.md b/docs/clearnet/contracts/integration/deployment.md similarity index 100% rename from docs/build/api/contracts/integration/deployment.md rename to docs/clearnet/contracts/integration/deployment.md diff --git a/docs/build/api/contracts/integration/events.md b/docs/clearnet/contracts/integration/events.md similarity index 100% rename from docs/build/api/contracts/integration/events.md rename to docs/clearnet/contracts/integration/events.md diff --git a/docs/build/api/contracts/integration/ui-spec.md b/docs/clearnet/contracts/integration/ui-spec.md similarity index 100% rename from docs/build/api/contracts/integration/ui-spec.md rename to docs/clearnet/contracts/integration/ui-spec.md diff --git a/docs/build/api/contracts/protocol/_category_.json b/docs/clearnet/contracts/protocol/_category_.json similarity index 100% rename from docs/build/api/contracts/protocol/_category_.json rename to docs/clearnet/contracts/protocol/_category_.json diff --git a/docs/build/api/contracts/protocol/governance.md b/docs/clearnet/contracts/protocol/governance.md similarity index 100% rename from docs/build/api/contracts/protocol/governance.md rename to docs/clearnet/contracts/protocol/governance.md diff --git a/docs/build/api/contracts/protocol/overview.md b/docs/clearnet/contracts/protocol/overview.md similarity index 100% rename from docs/build/api/contracts/protocol/overview.md rename to docs/clearnet/contracts/protocol/overview.md diff --git a/docs/build/api/contracts/protocol/slashing.md b/docs/clearnet/contracts/protocol/slashing.md similarity index 100% rename from docs/build/api/contracts/protocol/slashing.md rename to docs/clearnet/contracts/protocol/slashing.md diff --git a/docs/build/api/contracts/protocol/staking.md b/docs/clearnet/contracts/protocol/staking.md similarity index 100% rename from docs/build/api/contracts/protocol/staking.md rename to docs/clearnet/contracts/protocol/staking.md diff --git a/docs/build/api/contracts/protocol/treasury.md b/docs/clearnet/contracts/protocol/treasury.md similarity index 100% rename from docs/build/api/contracts/protocol/treasury.md rename to docs/clearnet/contracts/protocol/treasury.md diff --git a/docs/build/api/contracts/sdk/_category_.json b/docs/clearnet/contracts/sdk/_category_.json similarity index 100% rename from docs/build/api/contracts/sdk/_category_.json rename to docs/clearnet/contracts/sdk/_category_.json diff --git a/docs/build/api/contracts/sdk/api-reference.md b/docs/clearnet/contracts/sdk/api-reference.md similarity index 100% rename from docs/build/api/contracts/sdk/api-reference.md rename to docs/clearnet/contracts/sdk/api-reference.md diff --git a/docs/build/api/contracts/sdk/examples.md b/docs/clearnet/contracts/sdk/examples.md similarity index 100% rename from docs/build/api/contracts/sdk/examples.md rename to docs/clearnet/contracts/sdk/examples.md diff --git a/docs/build/api/contracts/sdk/getting-started.md b/docs/clearnet/contracts/sdk/getting-started.md similarity index 100% rename from docs/build/api/contracts/sdk/getting-started.md rename to docs/clearnet/contracts/sdk/getting-started.md diff --git a/docs/protocol/decentralized-layer/_category_.json b/docs/clearnet/decentralized-layer/_category_.json similarity index 100% rename from docs/protocol/decentralized-layer/_category_.json rename to docs/clearnet/decentralized-layer/_category_.json diff --git a/docs/protocol/decentralized-layer/cluster-lifecycle.mdx b/docs/clearnet/decentralized-layer/cluster-lifecycle.mdx similarity index 100% rename from docs/protocol/decentralized-layer/cluster-lifecycle.mdx rename to docs/clearnet/decentralized-layer/cluster-lifecycle.mdx diff --git a/docs/protocol/decentralized-layer/elastic-security.mdx b/docs/clearnet/decentralized-layer/elastic-security.mdx similarity index 100% rename from docs/protocol/decentralized-layer/elastic-security.mdx rename to docs/clearnet/decentralized-layer/elastic-security.mdx diff --git a/docs/protocol/decentralized-layer/liquidity-layer.mdx b/docs/clearnet/decentralized-layer/liquidity-layer.mdx similarity index 100% rename from docs/protocol/decentralized-layer/liquidity-layer.mdx rename to docs/clearnet/decentralized-layer/liquidity-layer.mdx diff --git a/docs/protocol/decentralized-layer/overview.mdx b/docs/clearnet/decentralized-layer/overview.mdx similarity index 100% rename from docs/protocol/decentralized-layer/overview.mdx rename to docs/clearnet/decentralized-layer/overview.mdx diff --git a/docs/protocol/decentralized-layer/protocol-lifecycle.mdx b/docs/clearnet/decentralized-layer/protocol-lifecycle.mdx similarity index 100% rename from docs/protocol/decentralized-layer/protocol-lifecycle.mdx rename to docs/clearnet/decentralized-layer/protocol-lifecycle.mdx diff --git a/docs/protocol/decentralized-layer/security.mdx b/docs/clearnet/decentralized-layer/security.mdx similarity index 100% rename from docs/protocol/decentralized-layer/security.mdx rename to docs/clearnet/decentralized-layer/security.mdx diff --git a/docs/protocol/introduction.mdx b/docs/clearnet/introduction.mdx similarity index 100% rename from docs/protocol/introduction.mdx rename to docs/clearnet/introduction.mdx diff --git a/docs/api-reference/_category_.json b/docs/nitrolite/api-reference/_category_.json similarity index 100% rename from docs/api-reference/_category_.json rename to docs/nitrolite/api-reference/_category_.json diff --git a/docs/api-reference/app-sessions.md b/docs/nitrolite/api-reference/app-sessions.md similarity index 100% rename from docs/api-reference/app-sessions.md rename to docs/nitrolite/api-reference/app-sessions.md diff --git a/docs/api-reference/index.md b/docs/nitrolite/api-reference/index.md similarity index 100% rename from docs/api-reference/index.md rename to docs/nitrolite/api-reference/index.md diff --git a/docs/build/_category_.json b/docs/nitrolite/build/_category_.json similarity index 100% rename from docs/build/_category_.json rename to docs/nitrolite/build/_category_.json diff --git a/docs/build/getting-started/_category_.json b/docs/nitrolite/build/getting-started/_category_.json similarity index 100% rename from docs/build/getting-started/_category_.json rename to docs/nitrolite/build/getting-started/_category_.json diff --git a/docs/build/getting-started/key-terms.mdx b/docs/nitrolite/build/getting-started/key-terms.mdx similarity index 100% rename from docs/build/getting-started/key-terms.mdx rename to docs/nitrolite/build/getting-started/key-terms.mdx diff --git a/docs/build/getting-started/prerequisites.mdx b/docs/nitrolite/build/getting-started/prerequisites.mdx similarity index 100% rename from docs/build/getting-started/prerequisites.mdx rename to docs/nitrolite/build/getting-started/prerequisites.mdx diff --git a/docs/build/getting-started/quickstart.mdx b/docs/nitrolite/build/getting-started/quickstart.mdx similarity index 100% rename from docs/build/getting-started/quickstart.mdx rename to docs/nitrolite/build/getting-started/quickstart.mdx diff --git a/docs/build/quick-start/index.md b/docs/nitrolite/build/quick-start/index.md similarity index 100% rename from docs/build/quick-start/index.md rename to docs/nitrolite/build/quick-start/index.md diff --git a/docs/build/sdk/_category_.json b/docs/nitrolite/build/sdk/_category_.json similarity index 100% rename from docs/build/sdk/_category_.json rename to docs/nitrolite/build/sdk/_category_.json diff --git a/docs/build/sdk/go/_category_.json b/docs/nitrolite/build/sdk/go/_category_.json similarity index 100% rename from docs/build/sdk/go/_category_.json rename to docs/nitrolite/build/sdk/go/_category_.json diff --git a/docs/build/sdk/go/api-reference.mdx b/docs/nitrolite/build/sdk/go/api-reference.mdx similarity index 100% rename from docs/build/sdk/go/api-reference.mdx rename to docs/nitrolite/build/sdk/go/api-reference.mdx diff --git a/docs/build/sdk/go/getting-started.mdx b/docs/nitrolite/build/sdk/go/getting-started.mdx similarity index 100% rename from docs/build/sdk/go/getting-started.mdx rename to docs/nitrolite/build/sdk/go/getting-started.mdx diff --git a/docs/build/sdk/index.md b/docs/nitrolite/build/sdk/index.md similarity index 100% rename from docs/build/sdk/index.md rename to docs/nitrolite/build/sdk/index.md diff --git a/docs/build/sdk/migration-guide.md b/docs/nitrolite/build/sdk/migration-guide.md similarity index 100% rename from docs/build/sdk/migration-guide.md rename to docs/nitrolite/build/sdk/migration-guide.md diff --git a/docs/build/sdk/multi-party-app-sessions.mdx b/docs/nitrolite/build/sdk/multi-party-app-sessions.mdx similarity index 100% rename from docs/build/sdk/multi-party-app-sessions.mdx rename to docs/nitrolite/build/sdk/multi-party-app-sessions.mdx diff --git a/docs/build/sdk/typescript-compat/_category_.json b/docs/nitrolite/build/sdk/typescript-compat/_category_.json similarity index 100% rename from docs/build/sdk/typescript-compat/_category_.json rename to docs/nitrolite/build/sdk/typescript-compat/_category_.json diff --git a/docs/build/sdk/typescript-compat/migration-offchain.mdx b/docs/nitrolite/build/sdk/typescript-compat/migration-offchain.mdx similarity index 100% rename from docs/build/sdk/typescript-compat/migration-offchain.mdx rename to docs/nitrolite/build/sdk/typescript-compat/migration-offchain.mdx diff --git a/docs/build/sdk/typescript-compat/migration-onchain.mdx b/docs/nitrolite/build/sdk/typescript-compat/migration-onchain.mdx similarity index 100% rename from docs/build/sdk/typescript-compat/migration-onchain.mdx rename to docs/nitrolite/build/sdk/typescript-compat/migration-onchain.mdx diff --git a/docs/build/sdk/typescript-compat/migration-overview.mdx b/docs/nitrolite/build/sdk/typescript-compat/migration-overview.mdx similarity index 100% rename from docs/build/sdk/typescript-compat/migration-overview.mdx rename to docs/nitrolite/build/sdk/typescript-compat/migration-overview.mdx diff --git a/docs/build/sdk/typescript-compat/overview.mdx b/docs/nitrolite/build/sdk/typescript-compat/overview.mdx similarity index 100% rename from docs/build/sdk/typescript-compat/overview.mdx rename to docs/nitrolite/build/sdk/typescript-compat/overview.mdx diff --git a/docs/build/sdk/typescript/_category_.json b/docs/nitrolite/build/sdk/typescript/_category_.json similarity index 100% rename from docs/build/sdk/typescript/_category_.json rename to docs/nitrolite/build/sdk/typescript/_category_.json diff --git a/docs/build/sdk/typescript/api-reference.mdx b/docs/nitrolite/build/sdk/typescript/api-reference.mdx similarity index 100% rename from docs/build/sdk/typescript/api-reference.mdx rename to docs/nitrolite/build/sdk/typescript/api-reference.mdx diff --git a/docs/build/sdk/typescript/configuration.mdx b/docs/nitrolite/build/sdk/typescript/configuration.mdx similarity index 100% rename from docs/build/sdk/typescript/configuration.mdx rename to docs/nitrolite/build/sdk/typescript/configuration.mdx diff --git a/docs/build/sdk/typescript/examples.mdx b/docs/nitrolite/build/sdk/typescript/examples.mdx similarity index 100% rename from docs/build/sdk/typescript/examples.mdx rename to docs/nitrolite/build/sdk/typescript/examples.mdx diff --git a/docs/build/sdk/typescript/getting-started.mdx b/docs/nitrolite/build/sdk/typescript/getting-started.mdx similarity index 100% rename from docs/build/sdk/typescript/getting-started.mdx rename to docs/nitrolite/build/sdk/typescript/getting-started.mdx diff --git a/docs/learn/_category_.json b/docs/nitrolite/learn/_category_.json similarity index 100% rename from docs/learn/_category_.json rename to docs/nitrolite/learn/_category_.json diff --git a/docs/learn/core-concepts/_category_.json b/docs/nitrolite/learn/core-concepts/_category_.json similarity index 100% rename from docs/learn/core-concepts/_category_.json rename to docs/nitrolite/learn/core-concepts/_category_.json diff --git a/docs/learn/core-concepts/challenge-response.mdx b/docs/nitrolite/learn/core-concepts/challenge-response.mdx similarity index 100% rename from docs/learn/core-concepts/challenge-response.mdx rename to docs/nitrolite/learn/core-concepts/challenge-response.mdx diff --git a/docs/learn/core-concepts/state-channels-vs-l1-l2.mdx b/docs/nitrolite/learn/core-concepts/state-channels-vs-l1-l2.mdx similarity index 100% rename from docs/learn/core-concepts/state-channels-vs-l1-l2.mdx rename to docs/nitrolite/learn/core-concepts/state-channels-vs-l1-l2.mdx diff --git a/docs/learn/core-concepts/yellow-token.mdx b/docs/nitrolite/learn/core-concepts/yellow-token.mdx similarity index 100% rename from docs/learn/core-concepts/yellow-token.mdx rename to docs/nitrolite/learn/core-concepts/yellow-token.mdx diff --git a/docs/learn/index.mdx b/docs/nitrolite/learn/index.mdx similarity index 100% rename from docs/learn/index.mdx rename to docs/nitrolite/learn/index.mdx diff --git a/docs/learn/introduction/_category_.json b/docs/nitrolite/learn/introduction/_category_.json similarity index 100% rename from docs/learn/introduction/_category_.json rename to docs/nitrolite/learn/introduction/_category_.json diff --git a/docs/learn/introduction/architecture-at-a-glance.mdx b/docs/nitrolite/learn/introduction/architecture-at-a-glance.mdx similarity index 100% rename from docs/learn/introduction/architecture-at-a-glance.mdx rename to docs/nitrolite/learn/introduction/architecture-at-a-glance.mdx diff --git a/docs/learn/introduction/supported-chains.mdx b/docs/nitrolite/learn/introduction/supported-chains.mdx similarity index 100% rename from docs/learn/introduction/supported-chains.mdx rename to docs/nitrolite/learn/introduction/supported-chains.mdx diff --git a/docs/learn/introduction/what-yellow-solves.mdx b/docs/nitrolite/learn/introduction/what-yellow-solves.mdx similarity index 100% rename from docs/learn/introduction/what-yellow-solves.mdx rename to docs/nitrolite/learn/introduction/what-yellow-solves.mdx diff --git a/docs/learn/protocol-flows/_category_.json b/docs/nitrolite/learn/protocol-flows/_category_.json similarity index 100% rename from docs/learn/protocol-flows/_category_.json rename to docs/nitrolite/learn/protocol-flows/_category_.json diff --git a/docs/learn/protocol-flows/app-session-deposit.mdx b/docs/nitrolite/learn/protocol-flows/app-session-deposit.mdx similarity index 100% rename from docs/learn/protocol-flows/app-session-deposit.mdx rename to docs/nitrolite/learn/protocol-flows/app-session-deposit.mdx diff --git a/docs/learn/protocol-flows/architecture.mdx b/docs/nitrolite/learn/protocol-flows/architecture.mdx similarity index 100% rename from docs/learn/protocol-flows/architecture.mdx rename to docs/nitrolite/learn/protocol-flows/architecture.mdx diff --git a/docs/learn/protocol-flows/escrow-deposit.mdx b/docs/nitrolite/learn/protocol-flows/escrow-deposit.mdx similarity index 100% rename from docs/learn/protocol-flows/escrow-deposit.mdx rename to docs/nitrolite/learn/protocol-flows/escrow-deposit.mdx diff --git a/docs/learn/protocol-flows/escrow-withdrawal.mdx b/docs/nitrolite/learn/protocol-flows/escrow-withdrawal.mdx similarity index 100% rename from docs/learn/protocol-flows/escrow-withdrawal.mdx rename to docs/nitrolite/learn/protocol-flows/escrow-withdrawal.mdx diff --git a/docs/learn/protocol-flows/home-channel-creation.mdx b/docs/nitrolite/learn/protocol-flows/home-channel-creation.mdx similarity index 100% rename from docs/learn/protocol-flows/home-channel-creation.mdx rename to docs/nitrolite/learn/protocol-flows/home-channel-creation.mdx diff --git a/docs/learn/protocol-flows/home-channel-deposit.mdx b/docs/nitrolite/learn/protocol-flows/home-channel-deposit.mdx similarity index 100% rename from docs/learn/protocol-flows/home-channel-deposit.mdx rename to docs/nitrolite/learn/protocol-flows/home-channel-deposit.mdx diff --git a/docs/learn/protocol-flows/home-channel-withdraw-on-create.mdx b/docs/nitrolite/learn/protocol-flows/home-channel-withdraw-on-create.mdx similarity index 100% rename from docs/learn/protocol-flows/home-channel-withdraw-on-create.mdx rename to docs/nitrolite/learn/protocol-flows/home-channel-withdraw-on-create.mdx diff --git a/docs/learn/protocol-flows/home-channel-withdrawal.mdx b/docs/nitrolite/learn/protocol-flows/home-channel-withdrawal.mdx similarity index 100% rename from docs/learn/protocol-flows/home-channel-withdrawal.mdx rename to docs/nitrolite/learn/protocol-flows/home-channel-withdrawal.mdx diff --git a/docs/learn/protocol-flows/transfer-flow.mdx b/docs/nitrolite/learn/protocol-flows/transfer-flow.mdx similarity index 100% rename from docs/learn/protocol-flows/transfer-flow.mdx rename to docs/nitrolite/learn/protocol-flows/transfer-flow.mdx diff --git a/docs/protocol/_category_.json b/docs/nitrolite/protocol/_category_.json similarity index 100% rename from docs/protocol/_category_.json rename to docs/nitrolite/protocol/_category_.json diff --git a/docs/protocol/protocol-reference.mdx b/docs/nitrolite/protocol/protocol-reference.mdx similarity index 100% rename from docs/protocol/protocol-reference.mdx rename to docs/nitrolite/protocol/protocol-reference.mdx diff --git a/docs/protocol/terminology.mdx b/docs/nitrolite/protocol/terminology.mdx similarity index 100% rename from docs/protocol/terminology.mdx rename to docs/nitrolite/protocol/terminology.mdx diff --git a/docs/tutorials/_category_.json b/docs/nitrolite/tutorials/_category_.json similarity index 100% rename from docs/tutorials/_category_.json rename to docs/nitrolite/tutorials/_category_.json diff --git a/docs/tutorials/index.md b/docs/nitrolite/tutorials/index.md similarity index 100% rename from docs/tutorials/index.md rename to docs/nitrolite/tutorials/index.md diff --git a/sidebars.ts b/sidebars-nitrolite.ts similarity index 100% rename from sidebars.ts rename to sidebars-nitrolite.ts From 310d240cba34feb5eca78eff15bb490cf4c838c8 Mon Sep 17 00:00:00 2001 From: nksazonov Date: Wed, 29 Apr 2026 12:49:14 +0200 Subject: [PATCH 02/16] refactor(docs): update frontmatter and links inside moved pages MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fix displayed_sidebar (buildSidebar → clearnetSidebar) in 22 contracts files, update _category_.json id, and rewrite internal /docs/* links to /nitrolite/* or /clearnet/*. --- docs/clearnet/contracts/_category_.json | 2 +- docs/clearnet/contracts/api-reference/app-registry.md | 2 +- docs/clearnet/contracts/api-reference/faucet.md | 2 +- docs/clearnet/contracts/api-reference/interfaces/ilock.md | 2 +- docs/clearnet/contracts/api-reference/interfaces/islash.md | 2 +- docs/clearnet/contracts/api-reference/locker.md | 2 +- docs/clearnet/contracts/api-reference/node-registry.md | 2 +- docs/clearnet/contracts/api-reference/treasury.md | 2 +- docs/clearnet/contracts/api-reference/yellow-governor.md | 2 +- docs/clearnet/contracts/api-reference/yellow-token.md | 2 +- docs/clearnet/contracts/faq.md | 2 +- docs/clearnet/contracts/index.md | 2 +- docs/clearnet/contracts/integration/deployment.md | 2 +- docs/clearnet/contracts/integration/events.md | 2 +- docs/clearnet/contracts/integration/ui-spec.md | 2 +- docs/clearnet/contracts/protocol/governance.md | 2 +- docs/clearnet/contracts/protocol/overview.md | 2 +- docs/clearnet/contracts/protocol/slashing.md | 2 +- docs/clearnet/contracts/protocol/staking.md | 2 +- docs/clearnet/contracts/protocol/treasury.md | 2 +- docs/clearnet/contracts/sdk/api-reference.md | 2 +- docs/clearnet/contracts/sdk/examples.md | 2 +- docs/clearnet/contracts/sdk/getting-started.md | 2 +- docs/nitrolite/build/getting-started/key-terms.mdx | 4 ++-- docs/nitrolite/build/getting-started/prerequisites.mdx | 2 +- docs/nitrolite/build/sdk/multi-party-app-sessions.mdx | 4 ++-- docs/nitrolite/learn/core-concepts/challenge-response.mdx | 2 +- .../learn/core-concepts/state-channels-vs-l1-l2.mdx | 2 +- docs/nitrolite/learn/index.mdx | 4 ++-- .../learn/introduction/architecture-at-a-glance.mdx | 6 +++--- docs/nitrolite/learn/introduction/supported-chains.mdx | 6 +++--- docs/nitrolite/learn/introduction/what-yellow-solves.mdx | 2 +- 32 files changed, 39 insertions(+), 39 deletions(-) diff --git a/docs/clearnet/contracts/_category_.json b/docs/clearnet/contracts/_category_.json index 7cb0321..1740788 100644 --- a/docs/clearnet/contracts/_category_.json +++ b/docs/clearnet/contracts/_category_.json @@ -3,7 +3,7 @@ "position": 1, "link": { "type": "doc", - "id": "build/api/contracts/index" + "id": "contracts/index" }, "collapsible": false, "collapsed": false diff --git a/docs/clearnet/contracts/api-reference/app-registry.md b/docs/clearnet/contracts/api-reference/app-registry.md index efaaec0..a228e3a 100644 --- a/docs/clearnet/contracts/api-reference/app-registry.md +++ b/docs/clearnet/contracts/api-reference/app-registry.md @@ -2,7 +2,7 @@ title: "AppRegistry" description: "App builder registry with slashing." sidebar_position: 4 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # AppRegistry diff --git a/docs/clearnet/contracts/api-reference/faucet.md b/docs/clearnet/contracts/api-reference/faucet.md index 9ee6f99..54670cb 100644 --- a/docs/clearnet/contracts/api-reference/faucet.md +++ b/docs/clearnet/contracts/api-reference/faucet.md @@ -2,7 +2,7 @@ title: "Faucet" description: "Testnet token faucet." sidebar_position: 7 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # Faucet diff --git a/docs/clearnet/contracts/api-reference/interfaces/ilock.md b/docs/clearnet/contracts/api-reference/interfaces/ilock.md index ae5753e..e59ec79 100644 --- a/docs/clearnet/contracts/api-reference/interfaces/ilock.md +++ b/docs/clearnet/contracts/api-reference/interfaces/ilock.md @@ -2,7 +2,7 @@ title: "ILock" description: "Lock/unlock/withdraw interface." sidebar_position: 1 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # ILock diff --git a/docs/clearnet/contracts/api-reference/interfaces/islash.md b/docs/clearnet/contracts/api-reference/interfaces/islash.md index 8a71ea8..010a979 100644 --- a/docs/clearnet/contracts/api-reference/interfaces/islash.md +++ b/docs/clearnet/contracts/api-reference/interfaces/islash.md @@ -2,7 +2,7 @@ title: "ISlash" description: "Slashing interface." sidebar_position: 2 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # ISlash diff --git a/docs/clearnet/contracts/api-reference/locker.md b/docs/clearnet/contracts/api-reference/locker.md index 62a9118..0cc21cd 100644 --- a/docs/clearnet/contracts/api-reference/locker.md +++ b/docs/clearnet/contracts/api-reference/locker.md @@ -2,7 +2,7 @@ title: "Locker" description: "Abstract lock/unlock/withdraw state machine." sidebar_position: 2 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # Locker diff --git a/docs/clearnet/contracts/api-reference/node-registry.md b/docs/clearnet/contracts/api-reference/node-registry.md index 17dfc09..d8b3344 100644 --- a/docs/clearnet/contracts/api-reference/node-registry.md +++ b/docs/clearnet/contracts/api-reference/node-registry.md @@ -2,7 +2,7 @@ title: "NodeRegistry" description: "Node operator registry with voting power." sidebar_position: 3 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # NodeRegistry diff --git a/docs/clearnet/contracts/api-reference/treasury.md b/docs/clearnet/contracts/api-reference/treasury.md index 96df3c6..59eedeb 100644 --- a/docs/clearnet/contracts/api-reference/treasury.md +++ b/docs/clearnet/contracts/api-reference/treasury.md @@ -2,7 +2,7 @@ title: "Treasury" description: "Secure vault for Foundation assets." sidebar_position: 6 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # Treasury diff --git a/docs/clearnet/contracts/api-reference/yellow-governor.md b/docs/clearnet/contracts/api-reference/yellow-governor.md index b2604d1..2484416 100644 --- a/docs/clearnet/contracts/api-reference/yellow-governor.md +++ b/docs/clearnet/contracts/api-reference/yellow-governor.md @@ -2,7 +2,7 @@ title: "YellowGovernor" description: "OpenZeppelin Governor for protocol parameters." sidebar_position: 5 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # YellowGovernor diff --git a/docs/clearnet/contracts/api-reference/yellow-token.md b/docs/clearnet/contracts/api-reference/yellow-token.md index a00b819..2470286 100644 --- a/docs/clearnet/contracts/api-reference/yellow-token.md +++ b/docs/clearnet/contracts/api-reference/yellow-token.md @@ -2,7 +2,7 @@ title: "YellowToken" description: "ERC-20 token with fixed 10B supply." sidebar_position: 1 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # YellowToken diff --git a/docs/clearnet/contracts/faq.md b/docs/clearnet/contracts/faq.md index 1e5c034..6797c3b 100644 --- a/docs/clearnet/contracts/faq.md +++ b/docs/clearnet/contracts/faq.md @@ -2,7 +2,7 @@ title: "FAQ" description: "Frequently asked questions about Yellow Network smart contracts." sidebar_position: 2 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # Frequently Asked Questions diff --git a/docs/clearnet/contracts/index.md b/docs/clearnet/contracts/index.md index ec00923..7370a5a 100644 --- a/docs/clearnet/contracts/index.md +++ b/docs/clearnet/contracts/index.md @@ -2,7 +2,7 @@ title: "Deployed Addresses" description: "Mainnet and testnet contract addresses for Yellow Network." sidebar_position: 1 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- diff --git a/docs/clearnet/contracts/integration/deployment.md b/docs/clearnet/contracts/integration/deployment.md index eb32485..7ec7c53 100644 --- a/docs/clearnet/contracts/integration/deployment.md +++ b/docs/clearnet/contracts/integration/deployment.md @@ -2,7 +2,7 @@ title: "Deployment" description: "Deploying contracts and configuration." sidebar_position: 1 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # Deployment diff --git a/docs/clearnet/contracts/integration/events.md b/docs/clearnet/contracts/integration/events.md index cc3eaaa..245b5f3 100644 --- a/docs/clearnet/contracts/integration/events.md +++ b/docs/clearnet/contracts/integration/events.md @@ -2,7 +2,7 @@ title: "Events" description: "Contract events for real-time subscriptions." sidebar_position: 2 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # Events diff --git a/docs/clearnet/contracts/integration/ui-spec.md b/docs/clearnet/contracts/integration/ui-spec.md index 20140f8..a9a84f1 100644 --- a/docs/clearnet/contracts/integration/ui-spec.md +++ b/docs/clearnet/contracts/integration/ui-spec.md @@ -2,7 +2,7 @@ title: "UI Specification" description: "Frontend implementation guide." sidebar_position: 3 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # UI Specification diff --git a/docs/clearnet/contracts/protocol/governance.md b/docs/clearnet/contracts/protocol/governance.md index 944fa07..52c2fb7 100644 --- a/docs/clearnet/contracts/protocol/governance.md +++ b/docs/clearnet/contracts/protocol/governance.md @@ -2,7 +2,7 @@ title: "Governance" description: "On-chain parameter administration via YellowGovernor." sidebar_position: 2 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # Protocol Parameter Administration diff --git a/docs/clearnet/contracts/protocol/overview.md b/docs/clearnet/contracts/protocol/overview.md index d3ee258..48b6a3c 100644 --- a/docs/clearnet/contracts/protocol/overview.md +++ b/docs/clearnet/contracts/protocol/overview.md @@ -2,7 +2,7 @@ title: "Protocol Overview" description: "Architecture, contracts, and how they fit together." sidebar_position: 1 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # Protocol Overview diff --git a/docs/clearnet/contracts/protocol/slashing.md b/docs/clearnet/contracts/protocol/slashing.md index 0f88eaf..d6d2744 100644 --- a/docs/clearnet/contracts/protocol/slashing.md +++ b/docs/clearnet/contracts/protocol/slashing.md @@ -2,7 +2,7 @@ title: "Slashing" description: "Adjudicator slashing and cooldown mechanism." sidebar_position: 4 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # Slashing diff --git a/docs/clearnet/contracts/protocol/staking.md b/docs/clearnet/contracts/protocol/staking.md index 0049c71..3ea7e57 100644 --- a/docs/clearnet/contracts/protocol/staking.md +++ b/docs/clearnet/contracts/protocol/staking.md @@ -2,7 +2,7 @@ title: "Collateral & Staking" description: "Lock/unlock state machine for NodeRegistry and AppRegistry." sidebar_position: 3 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # Collateral diff --git a/docs/clearnet/contracts/protocol/treasury.md b/docs/clearnet/contracts/protocol/treasury.md index add28c0..f4a0c70 100644 --- a/docs/clearnet/contracts/protocol/treasury.md +++ b/docs/clearnet/contracts/protocol/treasury.md @@ -2,7 +2,7 @@ title: "Treasury" description: "Foundation asset management." sidebar_position: 5 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # Treasury diff --git a/docs/clearnet/contracts/sdk/api-reference.md b/docs/clearnet/contracts/sdk/api-reference.md index 033f31d..38c4baf 100644 --- a/docs/clearnet/contracts/sdk/api-reference.md +++ b/docs/clearnet/contracts/sdk/api-reference.md @@ -2,7 +2,7 @@ title: "SDK API Reference" description: "All exports: ABIs, addresses, and types." sidebar_position: 2 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # SDK — API Reference diff --git a/docs/clearnet/contracts/sdk/examples.md b/docs/clearnet/contracts/sdk/examples.md index c338051..6b582a6 100644 --- a/docs/clearnet/contracts/sdk/examples.md +++ b/docs/clearnet/contracts/sdk/examples.md @@ -2,7 +2,7 @@ title: "Examples" description: "Code samples for viem, ethers.js, and wagmi." sidebar_position: 3 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # SDK — Examples diff --git a/docs/clearnet/contracts/sdk/getting-started.md b/docs/clearnet/contracts/sdk/getting-started.md index 8f5e48f..f179048 100644 --- a/docs/clearnet/contracts/sdk/getting-started.md +++ b/docs/clearnet/contracts/sdk/getting-started.md @@ -2,7 +2,7 @@ title: "Getting Started" description: "Install, import, and use the contracts SDK." sidebar_position: 1 -displayed_sidebar: buildSidebar +displayed_sidebar: clearnetSidebar --- # SDK — Getting Started diff --git a/docs/nitrolite/build/getting-started/key-terms.mdx b/docs/nitrolite/build/getting-started/key-terms.mdx index a079a9f..876926f 100644 --- a/docs/nitrolite/build/getting-started/key-terms.mdx +++ b/docs/nitrolite/build/getting-started/key-terms.mdx @@ -336,5 +336,5 @@ Valid combinations: Now that you understand the vocabulary, continue to: -- **[State Channels vs L1/L2](/docs/learn/core-concepts/state-channels-vs-l1-l2)** — Deep comparison with other scaling solutions -- **[Challenge Response & Disputes](/docs/learn/core-concepts/challenge-response)** — On-chain dispute resolution \ No newline at end of file +- **[State Channels vs L1/L2](/nitrolite/learn/core-concepts/state-channels-vs-l1-l2)** — Deep comparison with other scaling solutions +- **[Challenge Response & Disputes](/nitrolite/learn/core-concepts/challenge-response)** — On-chain dispute resolution \ No newline at end of file diff --git a/docs/nitrolite/build/getting-started/prerequisites.mdx b/docs/nitrolite/build/getting-started/prerequisites.mdx index 5cb7a52..6b5dc87 100644 --- a/docs/nitrolite/build/getting-started/prerequisites.mdx +++ b/docs/nitrolite/build/getting-started/prerequisites.mdx @@ -362,7 +362,7 @@ Your environment is ready! Continue to: - **[Key Terms & Mental Models](./key-terms.mdx)** — Understand the core concepts - **[Quickstart](./quickstart.mdx)** — Build your first Yellow App -- **[State Channels vs L1/L2](/docs/learn/core-concepts/state-channels-vs-l1-l2)** — Deep dive into state channels +- **[State Channels vs L1/L2](/nitrolite/learn/core-concepts/state-channels-vs-l1-l2)** — Deep dive into state channels --- diff --git a/docs/nitrolite/build/sdk/multi-party-app-sessions.mdx b/docs/nitrolite/build/sdk/multi-party-app-sessions.mdx index 925d880..e60a631 100644 --- a/docs/nitrolite/build/sdk/multi-party-app-sessions.mdx +++ b/docs/nitrolite/build/sdk/multi-party-app-sessions.mdx @@ -585,5 +585,5 @@ console.log(`Current weight: ${signatureWeight}, Required: ${quorum}`); ## Further Reading -- [Protocol](/docs/protocol/introduction) — Protocol specification and architecture -- [SDK Reference](/docs/build/sdk) — Complete SDK documentation +- [Clearnet Protocol](/clearnet/introduction) — Protocol specification and architecture +- [SDK Reference](/nitrolite/build/sdk) — Complete SDK documentation diff --git a/docs/nitrolite/learn/core-concepts/challenge-response.mdx b/docs/nitrolite/learn/core-concepts/challenge-response.mdx index 4bf2d23..0acb50e 100644 --- a/docs/nitrolite/learn/core-concepts/challenge-response.mdx +++ b/docs/nitrolite/learn/core-concepts/challenge-response.mdx @@ -152,4 +152,4 @@ You can **always** recover your funds according to the latest mutually signed st ## Deep Dive -For technical implementation details, see the [Protocol](/docs/protocol/introduction) section. +For technical implementation details, see the [Clearnet Protocol](/clearnet/introduction) section. diff --git a/docs/nitrolite/learn/core-concepts/state-channels-vs-l1-l2.mdx b/docs/nitrolite/learn/core-concepts/state-channels-vs-l1-l2.mdx index 6bfbf8a..45dc5f1 100644 --- a/docs/nitrolite/learn/core-concepts/state-channels-vs-l1-l2.mdx +++ b/docs/nitrolite/learn/core-concepts/state-channels-vs-l1-l2.mdx @@ -140,4 +140,4 @@ State channels shine when you have identified participants who will interact fre For technical details on channel implementation: -- **[Architecture](/docs/protocol/architecture.mdx)** — System design and fund flows +- **[Architecture](/clearnet/architecture)** — System design and fund flows diff --git a/docs/nitrolite/learn/index.mdx b/docs/nitrolite/learn/index.mdx index 7a7ff3f..3e6ea48 100644 --- a/docs/nitrolite/learn/index.mdx +++ b/docs/nitrolite/learn/index.mdx @@ -56,8 +56,8 @@ Detailed v1 protocol flow documentation for deposits, withdrawals, transfers, an After completing the Learn section, continue to: -- **[Build](/docs/build/quick-start)** — Implement complete Yellow Applications -- **[Protocol Reference](/docs/protocol/introduction)** — Authoritative protocol specification +- **[Build](/nitrolite/build/quick-start)** — Implement complete Yellow Applications +- **[Clearnet Protocol](/clearnet/introduction)** — Authoritative protocol specification --- diff --git a/docs/nitrolite/learn/introduction/architecture-at-a-glance.mdx b/docs/nitrolite/learn/introduction/architecture-at-a-glance.mdx index 8fa19c6..ebbe7f4 100644 --- a/docs/nitrolite/learn/introduction/architecture-at-a-glance.mdx +++ b/docs/nitrolite/learn/introduction/architecture-at-a-glance.mdx @@ -181,7 +181,7 @@ stateDiagram-v2 ``` :::info Legacy Flow -The diagram above shows the recommended flow where both participants sign the initial state, creating the channel directly in ACTIVE status. A legacy flow also exists where only the creator signs initially (status becomes INITIAL), and other participants call `join()` separately. See the [Protocol](/docs/protocol/introduction) section for details. +The diagram above shows the recommended flow where both participants sign the initial state, creating the channel directly in ACTIVE status. A legacy flow also exists where only the creator signs initially (status becomes INITIAL), and other participants call `join()` separately. See the [Clearnet Protocol](/clearnet/introduction) section for details. ::: ### Typical Flow @@ -256,6 +256,6 @@ At every stage, funds remain cryptographically secured. You can always recover y Ready to start building? Continue to: -- **[Quickstart](/docs/build/getting-started/quickstart)** — Create your first channel in minutes -- **[Prerequisites](/docs/build/getting-started/prerequisites)** — Set up your development environment +- **[Quickstart](/nitrolite/build/getting-started/quickstart)** — Create your first channel in minutes +- **[Prerequisites](/nitrolite/build/getting-started/prerequisites)** — Set up your development environment - **[Core Concepts](../core-concepts/state-channels-vs-l1-l2.mdx)** — Deep dive into state channels diff --git a/docs/nitrolite/learn/introduction/supported-chains.mdx b/docs/nitrolite/learn/introduction/supported-chains.mdx index 044617f..877cee7 100644 --- a/docs/nitrolite/learn/introduction/supported-chains.mdx +++ b/docs/nitrolite/learn/introduction/supported-chains.mdx @@ -293,6 +293,6 @@ const productionAllocations = [ ## See Also -- [Quick Start Guide](/docs/build/quick-start) — Get started building with Yellow SDK -- [Multi-Party App Sessions](/docs/build/sdk/multi-party-app-sessions) — Create multi-party application sessions -- [API Reference](/docs/api-reference) — Complete SDK documentation +- [Quick Start Guide](/nitrolite/build/quick-start) — Get started building with Yellow SDK +- [Multi-Party App Sessions](/nitrolite/build/sdk/multi-party-app-sessions) — Create multi-party application sessions +- [API Reference](/nitrolite/api-reference) — Complete SDK documentation diff --git a/docs/nitrolite/learn/introduction/what-yellow-solves.mdx b/docs/nitrolite/learn/introduction/what-yellow-solves.mdx index 3535fa0..87f7c93 100644 --- a/docs/nitrolite/learn/introduction/what-yellow-solves.mdx +++ b/docs/nitrolite/learn/introduction/what-yellow-solves.mdx @@ -146,4 +146,4 @@ If a Clearnode becomes unresponsive or malicious, you can submit your latest sig Now that you understand what Yellow solves, continue to: - **[Architecture at a Glance](./architecture-at-a-glance.mdx)** — See how the protocol layers work together -- **[Quickstart](/docs/build/getting-started/quickstart)** — Create your first state channel in minutes +- **[Quickstart](/nitrolite/build/getting-started/quickstart)** — Create your first state channel in minutes From c1bcf3888768646809cf8f0b4dc8aceab1043cef Mon Sep 17 00:00:00 2001 From: nksazonov Date: Wed, 29 Apr 2026 12:49:37 +0200 Subject: [PATCH 03/16] feat(docs): wire up two-plugin Docusaurus config for /nitrolite and /clearnet Point main docs plugin at docs/nitrolite (route /nitrolite), add second plugin-content-docs instance for clearnet (route /clearnet, no versioning), tag navbar items with customProps.showOn, split footer columns per product, add sidebars-clearnet.ts and narrow protocolSidebar. --- docusaurus.config.ts | 95 ++++++++++++++++++++++++++++++++++++++++--- sidebars-clearnet.ts | 30 ++++++++++++++ sidebars-nitrolite.ts | 9 ++-- 3 files changed, 123 insertions(+), 11 deletions(-) create mode 100644 sidebars-clearnet.ts diff --git a/docusaurus.config.ts b/docusaurus.config.ts index 0c15747..4f004f7 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -59,8 +59,9 @@ const config: Config = { 'classic', { docs: { - sidebarPath: './sidebars.ts', - routeBasePath: '/docs', + path: './docs/nitrolite', + sidebarPath: './sidebars-nitrolite.ts', + routeBasePath: '/nitrolite', editUrl: 'https://github.com/layer-3/docs/tree/master/', sidebarCollapsed: false, @@ -93,6 +94,20 @@ const config: Config = { }, themes: ['@docusaurus/theme-mermaid'], plugins: [ + [ + '@docusaurus/plugin-content-docs', + { + id: 'clearnet', + path: './docs/clearnet', + routeBasePath: '/clearnet', + sidebarPath: './sidebars-clearnet.ts', + editUrl: 'https://github.com/layer-3/docs/tree/master/', + sidebarCollapsed: false, + sidebarCollapsible: false, + breadcrumbs: true, + // No versions block — Clearnet starts unversioned + }, + ], [ 'docusaurus-lunr-search', { @@ -118,39 +133,81 @@ const config: Config = { srcDark: 'img/themes/dark/logo.svg', }, items: [ + // Nitrolite navbar items (shown on /nitrolite/* and /) { type: 'doc', docId: 'learn/index', label: 'Learn', position: 'left', + customProps: { showOn: 'nitrolite' }, }, { type: 'doc', docId: 'build/quick-start/index', label: 'Build', position: 'left', + customProps: { showOn: 'nitrolite' }, }, { type: 'doc', - docId: 'protocol/introduction', + docId: 'protocol/terminology', label: 'Protocol', position: 'left', + customProps: { showOn: 'nitrolite' }, + }, + // Clearnet navbar items (shown on /clearnet/*) + { + type: 'doc', + docsPluginId: 'clearnet', + docId: 'introduction', + label: 'Introduction', + position: 'left', + customProps: { showOn: 'clearnet' }, + }, + { + type: 'doc', + docsPluginId: 'clearnet', + docId: 'architecture', + label: 'Architecture', + position: 'left', + customProps: { showOn: 'clearnet' }, + }, + { + type: 'doc', + docsPluginId: 'clearnet', + docId: 'decentralized-layer/overview', + label: 'Decentralized Layer', + position: 'left', + customProps: { showOn: 'clearnet' }, + }, + { + type: 'doc', + docsPluginId: 'clearnet', + docId: 'contracts/index', + label: 'Contracts', + position: 'left', + customProps: { showOn: 'clearnet' }, }, + // Shared items (always shown) { to: '/whitepaper', label: 'Whitepaper', position: 'left', + customProps: { showOn: 'all' }, }, { href: 'https://github.com/layer-3', position: 'right', className: 'header-github-link', 'aria-label': 'GitHub repository', + customProps: { showOn: 'all' }, }, + // Version dropdown only on Nitrolite (Clearnet is unversioned) { type: 'docsVersionDropdown', position: 'right', className: 'navbar-version-dropdown', + customProps: { showOn: 'nitrolite' }, }, ], }, @@ -169,16 +226,42 @@ const config: Config = { ], }, { - title: 'Docs', + title: 'Nitrolite', items: [ { label: 'Learn', - to: '/docs/learn', + to: '/nitrolite/learn', }, { label: 'Build', - to: '/docs/build/quick-start', + to: '/nitrolite/build/quick-start', + }, + { + label: 'Protocol', + to: '/nitrolite/protocol/terminology', + }, + ], + }, + { + title: 'Clearnet', + items: [ + { + label: 'Introduction', + to: '/clearnet/introduction', + }, + { + label: 'Architecture', + to: '/clearnet/architecture', + }, + { + label: 'Contracts', + to: '/clearnet/contracts', }, + ], + }, + { + title: 'More', + items: [ { label: 'Whitepaper', to: '/whitepaper', diff --git a/sidebars-clearnet.ts b/sidebars-clearnet.ts new file mode 100644 index 0000000..87fe56d --- /dev/null +++ b/sidebars-clearnet.ts @@ -0,0 +1,30 @@ +import type {SidebarsConfig} from '@docusaurus/plugin-content-docs'; + +// This runs in Node.js - Don't use client-side code here (browser APIs, JSX...) + +const sidebars: SidebarsConfig = { + clearnetSidebar: [ + 'introduction', + 'architecture', + { + type: 'category', + label: 'Decentralized Layer', + items: [ + {type: 'autogenerated', dirName: 'decentralized-layer'}, + ], + collapsible: false, + collapsed: false, + }, + { + type: 'category', + label: 'Contracts', + items: [ + {type: 'autogenerated', dirName: 'contracts'}, + ], + collapsible: false, + collapsed: false, + }, + ], +}; + +export default sidebars; diff --git a/sidebars-nitrolite.ts b/sidebars-nitrolite.ts index 315f6ac..1da1d5e 100644 --- a/sidebars-nitrolite.ts +++ b/sidebars-nitrolite.ts @@ -77,12 +77,11 @@ const sidebars: SidebarsConfig = { }, ], - // Protocol section sidebar + // Protocol section sidebar — only protocol-reference and terminology remain + // (introduction, architecture, decentralized-layer moved to Clearnet) protocolSidebar: [ - { - type: 'autogenerated', - dirName: 'protocol', - }, + 'protocol/protocol-reference', + 'protocol/terminology', ], // Default sidebar for standalone pages From fee4140398e6d9d55412f785a6fba7c0a16fe64b Mon Sep 17 00:00:00 2001 From: nksazonov Date: Wed, 29 Apr 2026 12:50:00 +0200 Subject: [PATCH 04/16] feat(theme): swizzle Navbar/Content to filter items by current sub-site Render only navbar items whose customProps.showOn matches the current path prefix (/nitrolite, /clearnet, or 'all'). Items without showOn always render. --- src/theme/Navbar/Content/index.tsx | 131 +++++++++++++++++++++ src/theme/Navbar/Content/styles.module.css | 23 ++++ 2 files changed, 154 insertions(+) create mode 100644 src/theme/Navbar/Content/index.tsx create mode 100644 src/theme/Navbar/Content/styles.module.css diff --git a/src/theme/Navbar/Content/index.tsx b/src/theme/Navbar/Content/index.tsx new file mode 100644 index 0000000..69833c9 --- /dev/null +++ b/src/theme/Navbar/Content/index.tsx @@ -0,0 +1,131 @@ +/** + * Swizzled from @docusaurus/theme-classic/src/theme/Navbar/Content/index.tsx + * + * Adds path-based filtering: navbar items with `customProps.showOn` are only + * rendered on matching sub-sites (`nitrolite` | `clearnet` | `all`). + * Items without `customProps.showOn` are always rendered. + */ + +import React, {type ReactNode} from 'react'; +import clsx from 'clsx'; +import {useLocation} from '@docusaurus/router'; +import { + useThemeConfig, + ErrorCauseBoundary, + ThemeClassNames, +} from '@docusaurus/theme-common'; +import { + splitNavbarItems, + useNavbarMobileSidebar, +} from '@docusaurus/theme-common/internal'; +import NavbarItem, {type Props as NavbarItemConfig} from '@theme/NavbarItem'; +import NavbarColorModeToggle from '@theme/Navbar/ColorModeToggle'; +import SearchBar from '@theme/SearchBar'; +import NavbarMobileSidebarToggle from '@theme/Navbar/MobileSidebar/Toggle'; +import NavbarLogo from '@theme/Navbar/Logo'; +import NavbarSearch from '@theme/Navbar/Search'; + +import styles from './styles.module.css'; + +type ShowOn = 'nitrolite' | 'clearnet' | 'all'; + +function useNavbarItems() { + // TODO temporary casting until ThemeConfig type is improved + return useThemeConfig().navbar.items as NavbarItemConfig[]; +} + +function currentSubsite(pathname: string): 'nitrolite' | 'clearnet' | 'portal' { + if (pathname.startsWith('/nitrolite')) return 'nitrolite'; + if (pathname.startsWith('/clearnet')) return 'clearnet'; + return 'portal'; +} + +function shouldShowItem(item: NavbarItemConfig, pathname: string): boolean { + const showOn = (item as {customProps?: {showOn?: ShowOn}}).customProps?.showOn; + if (!showOn || showOn === 'all') return true; + const sub = currentSubsite(pathname); + if (sub === 'portal') return false; + return showOn === sub; +} + +function NavbarItems({items}: {items: NavbarItemConfig[]}): ReactNode { + return ( + <> + {items.map((item, i) => ( + + new Error( + `A theme navbar item failed to render. +Please double-check the following navbar item (themeConfig.navbar.items) of your Docusaurus config: +${JSON.stringify(item, null, 2)}`, + {cause: error}, + ) + }> + + + ))} + + ); +} + +function NavbarContentLayout({ + left, + right, +}: { + left: ReactNode; + right: ReactNode; +}) { + return ( +
+
+ {left} +
+
+ {right} +
+
+ ); +} + +export default function NavbarContent(): ReactNode { + const mobileSidebar = useNavbarMobileSidebar(); + const {pathname} = useLocation(); + + const items = useNavbarItems(); + const filteredItems = items.filter((item) => shouldShowItem(item, pathname)); + const [leftItems, rightItems] = splitNavbarItems(filteredItems); + + const searchBarItem = items.find((item) => item.type === 'search'); + + return ( + + {!mobileSidebar.disabled && } + + + + } + right={ + <> + + + {!searchBarItem && ( + + + + )} + + } + /> + ); +} diff --git a/src/theme/Navbar/Content/styles.module.css b/src/theme/Navbar/Content/styles.module.css new file mode 100644 index 0000000..eee2127 --- /dev/null +++ b/src/theme/Navbar/Content/styles.module.css @@ -0,0 +1,23 @@ +/** + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + +/* +Hide color mode toggle in small viewports + */ +@media (max-width: 996px) { + .colorModeToggle { + display: none; + } +} + +/* +Restore some Infima style that broke with CSS Cascade Layers +See https://github.com/facebook/docusaurus/pull/11142 + */ +:global(.navbar__items--right) > :last-child { + padding-right: 0; +} From 8b30a50bd140277df6c64027eb15504fbb544ed8 Mon Sep 17 00:00:00 2001 From: nksazonov Date: Wed, 29 Apr 2026 12:50:22 +0200 Subject: [PATCH 05/16] feat(home): redesign homepage as portal landing page MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace "Explore the SDK" hero with yellow.org tagline ("Build. Trade. Unify.") and reduce HomepageFeatures to two product cards — Nitrolite (left) and Clearnet (right) — each linking to its sub-site. --- src/components/HomepageFeatures/index.tsx | 56 ++++------------------- src/pages/index.tsx | 7 +-- 2 files changed, 13 insertions(+), 50 deletions(-) diff --git a/src/components/HomepageFeatures/index.tsx b/src/components/HomepageFeatures/index.tsx index cbc0e05..ccda8f1 100644 --- a/src/components/HomepageFeatures/index.tsx +++ b/src/components/HomepageFeatures/index.tsx @@ -17,66 +17,28 @@ type FeatureItem = { const FeatureList: FeatureItem[] = [ { - title: 'Learn the Basics', - imageSrc: require('@site/static/img/themes/light/icons/learn.png').default, - imageSrcDark: require('@site/static/img/themes/dark/icons/learn.png').default, - description: ( - <> - Understand the fundamentals of Yellow Network, its architecture, - and how decentralized clearing and settlement works. - - ), - link: '/docs/learn', - }, - { - title: 'Build a Yellow App', + title: 'Nitrolite', imageSrc: require('@site/static/img/themes/light/icons/build.png').default, imageSrcDark: require('@site/static/img/themes/dark/icons/build.png').default, description: ( <> - Create decentralized applications using Yellow SDK with real-time - trading capabilities and instant cross-chain settlements. + State channel SDK for building decentralized apps with instant + finality, real-time trading, and cross-chain settlement. ), - link: '/docs/build/quick-start', + link: '/nitrolite/learn', }, { - title: 'Run a Clearnode', + title: 'Clearnet', imageSrc: require('@site/static/img/themes/light/icons/clearnode.png').default, imageSrcDark: require('@site/static/img/themes/dark/icons/clearnode.png').default, description: ( <> - Set up and operate a clearnode to provide network services - and contribute to decentralized infrastructure. - - ), - link: '/docs/learn', - }, - { - title: 'Join the Community', - imageSrc: require('@site/static/img/themes/light/icons/community.png').default, - imageSrcDark: require('@site/static/img/themes/dark/icons/community.png').default, - description: ( - <> - Connect with developers, traders, and node operators in our - Discord community and contribute to the ecosystem. - - ), - link: 'https://discord.com/invite/yellownetwork', - isExternal: true, - }, - { - title: 'Apply for Grants', - imageSrc: require('@site/static/img/themes/light/icons/grants.png').default, - imageSrcDark: require('@site/static/img/themes/dark/icons/grants.png').default, - description: ( - <> - Get funding support for your Yellow Network project through - our grants program for innovative applications and integrations. + Decentralized clearing and settlement protocol — peer-to-peer overlay + network, smart contracts, governance, and node operations. ), - link: 'https://forms.yellow.org/build', - isExternal: true, + link: '/clearnet/introduction', }, ]; @@ -89,7 +51,7 @@ function Feature({title, imageSrc, imageSrcDark, description, link, isExternal}: : { to: link }; return ( -
+
- Explore the SDK + Build. Trade. Unify.

- Decentralized clearing and settlement network
- Develop Yellow Apps with instant finality. + Leverage our trustless infrastructure to create powerful businesses + that are governed by logic — giving you the freedom to focus on your + vision, not the operations.

From a4ed6bad90113406b69626c5e482dd45bc929eb4 Mon Sep 17 00:00:00 2001 From: nksazonov Date: Wed, 29 Apr 2026 12:50:43 +0200 Subject: [PATCH 06/16] docs(readme): document site architecture and known limitations Add a Site Architecture section describing the two-sub-site layout and source files, plus Known Limitations covering the shared search index and stale links inside versioned_docs/. --- README.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/README.md b/README.md index b28211a..c8a01c0 100644 --- a/README.md +++ b/README.md @@ -39,3 +39,23 @@ GIT_USER= yarn deploy ``` If you are using GitHub pages for hosting, this command is a convenient way to build the website and push to the `gh-pages` branch. + +## Site Architecture + +This site hosts two product docs as separate sub-sites under one Docusaurus instance: + +- **`/nitrolite/*`** — State channel SDK docs (versioned 1.x / 0.5.x) +- **`/clearnet/*`** — Decentralized clearing protocol docs (unversioned) +- **`/`** — Portal landing page linking to both sub-sites + +Source layout: + +- `docs/nitrolite/` — Nitrolite content (managed by the preset's docs plugin) +- `docs/clearnet/` — Clearnet content (managed by a second `@docusaurus/plugin-content-docs` instance, id: `clearnet`) +- `sidebars-nitrolite.ts` / `sidebars-clearnet.ts` — sidebar configs per sub-site +- `src/theme/Navbar/Content/` — swizzled component that filters top-navbar items by current path (via `customProps.showOn`) + +### Known Limitations + +- **Search**: lunr-search uses a single index across both sub-sites. A query from `/nitrolite/...` may surface Clearnet results and vice versa. To scope search per sub-site, replace lunr-search with Algolia (separate indices) or a custom search component. +- **Versioned docs links**: `versioned_docs/version-0.5.x/` is a historical snapshot and still contains `/docs/...` links from when the site lived under that path. Those links break under the new `/nitrolite/0.5.x/...` routing. Either rewrite versioned content links or accept them as archived. From fb37aef43f804596eb1b17abcf8669f6f137975b Mon Sep 17 00:00:00 2001 From: nksazonov Date: Wed, 29 Apr 2026 13:59:52 +0200 Subject: [PATCH 07/16] docs(v0.5.x): drop System Overview and Two-Layer Architecture from protocol/architecture Versioned 0.5.x snapshot retained the obsolete two-layer intro that no longer applies after the Nitrolite/Clearnet split. Remove both sections; page now starts directly at "App Layer Architecture". --- .../version-0.5.x/protocol/architecture.mdx | 49 ------------------- 1 file changed, 49 deletions(-) diff --git a/versioned_docs/version-0.5.x/protocol/architecture.mdx b/versioned_docs/version-0.5.x/protocol/architecture.mdx index 8252fe0..759f28c 100644 --- a/versioned_docs/version-0.5.x/protocol/architecture.mdx +++ b/versioned_docs/version-0.5.x/protocol/architecture.mdx @@ -8,55 +8,6 @@ import { tooltipDefinitions } from '@site/src/constants/tooltipDefinitions'; # Architecture -## System Overview - -Yellow Protocol consists of two distinct layers — the **Decentralized Layer** for network consensus and settlement, and the **App Layer (VirtualApp)** for state channel operations. Together they enable scalable, secure cross-chain clearing and application hosting. - -### Two-Layer Architecture - -```mermaid -%%{init: { "flowchart": { "htmlLabels": true } }}%% -graph TB - subgraph DL["Decentralized Layer"] - direction LR - DHT["Kademlia DHT"] - BLS["BLS Clusters"] - SECURITY["Elastic Security"] - end - - subgraph AL["App Layer — VirtualApp"] - direction LR - RPC["Nitro RPC"] - CHANNELS["State Channels"] - SESSIONS["YApps / App Sessions"] - end - - subgraph OnChain["On-Chain Contracts"] - direction LR - DL_CONTRACTS["Registry, Custody, Governor"] - AL_CONTRACTS["Custody, Adjudicator"] - end - - subgraph Blockchain["Blockchains"] - CHAIN["Ethereum, Arbitrum, Base, Polygon, Linea, BNB"] - end - - DL --> AL - DL_CONTRACTS --> Blockchain - AL_CONTRACTS --> Blockchain - - style DL fill:#e1f5ff,stroke:#9ad7ff,color:#111 - style AL fill:#fff4e1,stroke:#ffd497,color:#111 - style OnChain fill:#ffe1f5,stroke:#ffbde6,color:#111 - style Blockchain fill:#f0f0f0,stroke:#c9c9c9,color:#111 -``` - -:::info Contract Convergence -Both layers currently deploy their own on-chain contracts. These are expected to be merged into a unified contract suite once testnet concludes. -::: - -The Decentralized Layer architecture (DHT topology, cluster formation, elastic security) is documented in the v1.x release. - ## App Layer Architecture The VirtualApp App Layer architecture consists of multiple components working together to enable state channel operations: From 35ae0c823674cd220534acda1feebe3d52ceb90c Mon Sep 17 00:00:00 2001 From: nksazonov Date: Wed, 29 Apr 2026 14:32:15 +0200 Subject: [PATCH 08/16] feat(ui): add sub-site badge, scope navbar links per page, fix layout Yellow [Nitrolite]/[Clearnet] badge after the logo on sub-sites; portal navbar shows Nitrolite/Clearnet/Whitepaper, sub-sites show only their own sections (introduce showOn:'portal'). Cards on the portal use col--4 (~67% total width, centered). Footer grid expands to 6 columns so all link sections sit next to the logo. --- docusaurus.config.ts | 20 +++++++++++++++++--- src/components/HomepageFeatures/index.tsx | 4 ++-- src/css/custom.css | 7 ++++--- src/theme/Navbar/Content/index.tsx | 11 +++++++++-- src/theme/Navbar/Content/styles.module.css | 16 ++++++++++++++++ 5 files changed, 48 insertions(+), 10 deletions(-) diff --git a/docusaurus.config.ts b/docusaurus.config.ts index 4f004f7..005a311 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -133,7 +133,20 @@ const config: Config = { srcDark: 'img/themes/dark/logo.svg', }, items: [ - // Nitrolite navbar items (shown on /nitrolite/* and /) + // Portal-only product entry links + { + to: '/nitrolite/learn', + label: 'Nitrolite', + position: 'left', + customProps: { showOn: 'portal' }, + }, + { + to: '/clearnet/introduction', + label: 'Clearnet', + position: 'left', + customProps: { showOn: 'portal' }, + }, + // Nitrolite navbar items (shown on /nitrolite/*) { type: 'doc', docId: 'learn/index', @@ -188,13 +201,14 @@ const config: Config = { position: 'left', customProps: { showOn: 'clearnet' }, }, - // Shared items (always shown) + // Whitepaper only on portal { to: '/whitepaper', label: 'Whitepaper', position: 'left', - customProps: { showOn: 'all' }, + customProps: { showOn: 'portal' }, }, + // GitHub link visible on all sub-sites { href: 'https://github.com/layer-3', position: 'right', diff --git a/src/components/HomepageFeatures/index.tsx b/src/components/HomepageFeatures/index.tsx index ccda8f1..4d575d7 100644 --- a/src/components/HomepageFeatures/index.tsx +++ b/src/components/HomepageFeatures/index.tsx @@ -51,7 +51,7 @@ function Feature({title, imageSrc, imageSrcDark, description, link, isExternal}: : { to: link }; return ( -
+
-
+
{FeatureList.map((props, idx) => ( ))} diff --git a/src/css/custom.css b/src/css/custom.css index b5e9667..23f99fb 100644 --- a/src/css/custom.css +++ b/src/css/custom.css @@ -489,13 +489,14 @@ a.menu__link.menu__link--sublist.menu__link--active:hover { color: #ffffff !important; } -/* Footer 4-column layout */ +/* Footer 6-column layout: logo + 5 link columns */ .footer__links { display: grid; - grid-template-columns: 1fr 1fr 1fr 1fr; + grid-template-columns: auto repeat(5, 1fr); gap: 2rem; max-width: 1200px; margin: 0 auto; + align-items: start; } /* Align footer logo with content */ @@ -551,7 +552,7 @@ a.menu__link.menu__link--sublist.menu__link--active:hover { @media screen and (max-width: 996px) { .footer__links { - grid-template-columns: 1fr 1fr; + grid-template-columns: auto repeat(2, 1fr); gap: 1.5rem; } } diff --git a/src/theme/Navbar/Content/index.tsx b/src/theme/Navbar/Content/index.tsx index 69833c9..e31e78a 100644 --- a/src/theme/Navbar/Content/index.tsx +++ b/src/theme/Navbar/Content/index.tsx @@ -27,7 +27,7 @@ import NavbarSearch from '@theme/Navbar/Search'; import styles from './styles.module.css'; -type ShowOn = 'nitrolite' | 'clearnet' | 'all'; +type ShowOn = 'nitrolite' | 'clearnet' | 'portal' | 'all'; function useNavbarItems() { // TODO temporary casting until ThemeConfig type is improved @@ -44,10 +44,15 @@ function shouldShowItem(item: NavbarItemConfig, pathname: string): boolean { const showOn = (item as {customProps?: {showOn?: ShowOn}}).customProps?.showOn; if (!showOn || showOn === 'all') return true; const sub = currentSubsite(pathname); - if (sub === 'portal') return false; return showOn === sub; } +function SubsiteBadge({sub}: {sub: 'nitrolite' | 'clearnet' | 'portal'}) { + if (sub === 'portal') return null; + const label = sub === 'nitrolite' ? 'Nitrolite' : 'Clearnet'; + return {label}; +} + function NavbarItems({items}: {items: NavbarItemConfig[]}): ReactNode { return ( <> @@ -105,6 +110,7 @@ export default function NavbarContent(): ReactNode { const [leftItems, rightItems] = splitNavbarItems(filteredItems); const searchBarItem = items.find((item) => item.type === 'search'); + const sub = currentSubsite(pathname); return ( {!mobileSidebar.disabled && } + } diff --git a/src/theme/Navbar/Content/styles.module.css b/src/theme/Navbar/Content/styles.module.css index eee2127..cf17b53 100644 --- a/src/theme/Navbar/Content/styles.module.css +++ b/src/theme/Navbar/Content/styles.module.css @@ -21,3 +21,19 @@ See https://github.com/facebook/docusaurus/pull/11142 :global(.navbar__items--right) > :last-child { padding-right: 0; } + +/* Sub-site badge: yellow rectangle showing which docs you're viewing */ +.subsiteBadge { + display: inline-flex; + align-items: center; + margin: 0 1rem 0 0.5rem; + padding: 0.25rem 0.75rem; + background-color: #FDDA16; + color: #1c1e21; + font-weight: 600; + font-size: 0.875rem; + line-height: 1.25rem; + border-radius: 4px; + user-select: none; + white-space: nowrap; +} From a7b7fa7b6937e6de37f0b22777e46f8e660e6ed8 Mon Sep 17 00:00:00 2001 From: nksazonov Date: Wed, 29 Apr 2026 14:39:00 +0200 Subject: [PATCH 09/16] chore(docs): reorder Nitrolite Build sidebar and Protocol nav default MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Build top-level: Quick Start (1), Getting Started (2), SDK (3). Inside SDK: Migration Guide → Multi-Party App Sessions → TypeScript SDK → TypeScript Compat → Go. Protocol navbar link now lands on protocol-reference instead of terminology. --- docs/nitrolite/build/quick-start/index.md | 2 +- docs/nitrolite/build/sdk/_category_.json | 2 +- docs/nitrolite/build/sdk/go/_category_.json | 2 +- docs/nitrolite/build/sdk/typescript-compat/_category_.json | 2 +- docs/nitrolite/build/sdk/typescript/_category_.json | 2 +- docusaurus.config.ts | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/nitrolite/build/quick-start/index.md b/docs/nitrolite/build/quick-start/index.md index 75cad82..e9ae8c3 100644 --- a/docs/nitrolite/build/quick-start/index.md +++ b/docs/nitrolite/build/quick-start/index.md @@ -1,5 +1,5 @@ --- -sidebar_position: 2 +sidebar_position: 1 sidebar_label: Quick Start title: Quick Start description: Build your first Yellow App in 5 minutes - a complete beginner's guide diff --git a/docs/nitrolite/build/sdk/_category_.json b/docs/nitrolite/build/sdk/_category_.json index 32cf882..4a71e07 100644 --- a/docs/nitrolite/build/sdk/_category_.json +++ b/docs/nitrolite/build/sdk/_category_.json @@ -1,6 +1,6 @@ { "label": "SDK", - "position": 2, + "position": 3, "collapsed": false, "collapsible": false } diff --git a/docs/nitrolite/build/sdk/go/_category_.json b/docs/nitrolite/build/sdk/go/_category_.json index 3a2be2d..593eb15 100644 --- a/docs/nitrolite/build/sdk/go/_category_.json +++ b/docs/nitrolite/build/sdk/go/_category_.json @@ -1,6 +1,6 @@ { "label": "Go SDK", - "position": 4, + "position": 6, "collapsed": false, "collapsible": false } diff --git a/docs/nitrolite/build/sdk/typescript-compat/_category_.json b/docs/nitrolite/build/sdk/typescript-compat/_category_.json index 5139e8f..28b66b7 100644 --- a/docs/nitrolite/build/sdk/typescript-compat/_category_.json +++ b/docs/nitrolite/build/sdk/typescript-compat/_category_.json @@ -1,6 +1,6 @@ { "label": "TypeScript Compat SDK", - "position": 3, + "position": 5, "collapsed": false, "collapsible": false } diff --git a/docs/nitrolite/build/sdk/typescript/_category_.json b/docs/nitrolite/build/sdk/typescript/_category_.json index 9fdfa4a..d58d148 100644 --- a/docs/nitrolite/build/sdk/typescript/_category_.json +++ b/docs/nitrolite/build/sdk/typescript/_category_.json @@ -1,6 +1,6 @@ { "label": "TypeScript SDK", - "position": 2, + "position": 4, "collapsed": false, "collapsible": false } diff --git a/docusaurus.config.ts b/docusaurus.config.ts index 005a311..e77f6f1 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -163,7 +163,7 @@ const config: Config = { }, { type: 'doc', - docId: 'protocol/terminology', + docId: 'protocol/protocol-reference', label: 'Protocol', position: 'left', customProps: { showOn: 'nitrolite' }, From 6ee9af587d9ebc047b15902663a3306bcad1ae52 Mon Sep 17 00:00:00 2001 From: nksazonov Date: Wed, 29 Apr 2026 16:41:32 +0200 Subject: [PATCH 10/16] feat(sidebar): toggle categories only via chevron, not row text Swizzles DocSidebarItem/Category so .menu__caret is the only click target that expands/collapses a category; the label stays inert (or navigates if it has an href). Replaces the decorative ::before arrow with a real button so it can have hover and focus states. Resets Infima's default chevron rotations and applies rotate(90deg) only on [aria-expanded="true"]. Drops collapsible: false from Learn categories so they actually become collapsible. Light + dark mode both styled. --- sidebars-nitrolite.ts | 3 - src/css/custom.css | 116 ++++++-- src/theme/DocSidebarItem/Category/index.tsx | 279 ++++++++++++++++++ .../DocSidebarItem/Category/styles.module.css | 16 + 4 files changed, 379 insertions(+), 35 deletions(-) create mode 100644 src/theme/DocSidebarItem/Category/index.tsx create mode 100644 src/theme/DocSidebarItem/Category/styles.module.css diff --git a/sidebars-nitrolite.ts b/sidebars-nitrolite.ts index 1da1d5e..e905768 100644 --- a/sidebars-nitrolite.ts +++ b/sidebars-nitrolite.ts @@ -28,7 +28,6 @@ const sidebars: SidebarsConfig = { 'learn/introduction/architecture-at-a-glance', 'learn/introduction/supported-chains', ], - collapsible: false, collapsed: false, }, { @@ -39,7 +38,6 @@ const sidebars: SidebarsConfig = { 'learn/core-concepts/challenge-response', 'learn/core-concepts/yellow-token', ], - collapsible: false, collapsed: false, }, { @@ -48,7 +46,6 @@ const sidebars: SidebarsConfig = { items: [ {type: 'autogenerated', dirName: 'learn/protocol-flows'}, ], - collapsible: false, collapsed: false, }, ], diff --git a/src/css/custom.css b/src/css/custom.css index 23f99fb..602a0a5 100644 --- a/src/css/custom.css +++ b/src/css/custom.css @@ -367,57 +367,109 @@ a.menu__link.menu__link--sublist.menu__link--active:hover { color: #cccccc !important; } -/* Move expand/collapse icon to the left side of text */ -.menu__link--sublist, -.menu__list-item-collapsible>.menu__link { +/* Sidebar collapsible category: chevron-only toggle. + * The .menu__caret
From 50f73661b3f609ec25ead48d945d0a7643612cc1 Mon Sep 17 00:00:00 2001 From: nksazonov Date: Wed, 29 Apr 2026 17:54:44 +0200 Subject: [PATCH 12/16] feat(nitrolite): versioned product homepage at /nitrolite Adds a Nitrolite landing page (hero + cards) at /nitrolite with two versions: v1 (current) shows 4 cards (Learn, Build, Community, Grants); 0.5.x shows 5 cards (adds Run a Clearnode, which lives only in 0.5.x docs). Wires the homepage into Docusaurus' versioning so the navbar version dropdown switches between /nitrolite and /nitrolite/0.5.x while the user is on a homepage, and continues to map between doc equivalents elsewhere (swizzled DocsVersionDropdownNavbarItem). The yellow "Nitrolite" sub-site badge in the navbar is now a link to /nitrolite (and "Clearnet" symmetrically links to /clearnet/introduction). The portal's homepage card and navbar entry both point to /nitrolite instead of /nitrolite/learn. Breadcrumb home icon (swizzled) routes per sub-site and per version: /nitrolite/0.5.x/* breadcrumbs land on /nitrolite/0.5.x; /nitrolite/* land on /nitrolite; /clearnet/* land on /clearnet/introduction. --- docusaurus.config.ts | 4 +- src/components/HomepageFeatures/index.tsx | 2 +- src/pages/nitrolite.tsx | 133 +++++++++++ src/pages/nitrolite/0.5.x/index.tsx | 145 ++++++++++++ src/theme/DocBreadcrumbs/Items/Home/index.tsx | 43 ++++ .../Items/Home/styles.module.css | 14 ++ src/theme/Navbar/Content/index.tsx | 30 ++- src/theme/Navbar/Content/styles.module.css | 15 +- .../DocsVersionDropdownNavbarItem.tsx | 208 ++++++++++++++++++ 9 files changed, 582 insertions(+), 12 deletions(-) create mode 100644 src/pages/nitrolite.tsx create mode 100644 src/pages/nitrolite/0.5.x/index.tsx create mode 100644 src/theme/DocBreadcrumbs/Items/Home/index.tsx create mode 100644 src/theme/DocBreadcrumbs/Items/Home/styles.module.css create mode 100644 src/theme/NavbarItem/DocsVersionDropdownNavbarItem.tsx diff --git a/docusaurus.config.ts b/docusaurus.config.ts index e77f6f1..757f4de 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -135,7 +135,7 @@ const config: Config = { items: [ // Portal-only product entry links { - to: '/nitrolite/learn', + to: '/nitrolite', label: 'Nitrolite', position: 'left', customProps: { showOn: 'portal' }, @@ -216,7 +216,7 @@ const config: Config = { 'aria-label': 'GitHub repository', customProps: { showOn: 'all' }, }, - // Version dropdown only on Nitrolite (Clearnet is unversioned) + // Version dropdown only on Nitrolite (Clearnet is unversioned). { type: 'docsVersionDropdown', position: 'right', diff --git a/src/components/HomepageFeatures/index.tsx b/src/components/HomepageFeatures/index.tsx index 4d575d7..4490384 100644 --- a/src/components/HomepageFeatures/index.tsx +++ b/src/components/HomepageFeatures/index.tsx @@ -26,7 +26,7 @@ const FeatureList: FeatureItem[] = [ finality, real-time trading, and cross-chain settlement. ), - link: '/nitrolite/learn', + link: '/nitrolite', }, { title: 'Clearnet', diff --git a/src/pages/nitrolite.tsx b/src/pages/nitrolite.tsx new file mode 100644 index 0000000..6a68ee5 --- /dev/null +++ b/src/pages/nitrolite.tsx @@ -0,0 +1,133 @@ +import type {ReactNode} from 'react'; +import clsx from 'clsx'; +import Link from '@docusaurus/Link'; +import {useColorMode} from '@docusaurus/theme-common'; +import Layout from '@theme/Layout'; +import Heading from '@theme/Heading'; + +import sharedStyles from './index.module.css'; +import featureStyles from '@site/src/components/HomepageFeatures/styles.module.css'; + +type FeatureItem = { + title: string; + imageSrc: string; + imageSrcDark: string; + description: ReactNode; + link: string; + isExternal?: boolean; +}; + +// v1 cards. Clearnode setup lives in 0.5.x docs (and on the 0.5.x homepage) +// — it has been migrated to the Clearnet sub-site for the v1 line. +const FeatureList: FeatureItem[] = [ + { + title: 'Learn the Basics', + imageSrc: require('@site/static/img/themes/light/icons/learn.png').default, + imageSrcDark: require('@site/static/img/themes/dark/icons/learn.png').default, + description: ( + <> + Understand the fundamentals of Yellow Network, its architecture, + and how decentralized clearing and settlement works. + + ), + link: '/nitrolite/learn', + }, + { + title: 'Build a Yellow App', + imageSrc: require('@site/static/img/themes/light/icons/build.png').default, + imageSrcDark: require('@site/static/img/themes/dark/icons/build.png').default, + description: ( + <> + Create decentralized applications using Yellow SDK with real-time + trading capabilities and instant cross-chain settlements. + + ), + link: '/nitrolite/build/quick-start', + }, + { + title: 'Join the Community', + imageSrc: require('@site/static/img/themes/light/icons/community.png').default, + imageSrcDark: require('@site/static/img/themes/dark/icons/community.png').default, + description: ( + <> + Connect with developers, traders, and node operators in our + Discord community and contribute to the ecosystem. + + ), + link: 'https://discord.com/invite/yellownetwork', + isExternal: true, + }, + { + title: 'Apply for Grants', + imageSrc: require('@site/static/img/themes/light/icons/grants.png').default, + imageSrcDark: require('@site/static/img/themes/dark/icons/grants.png').default, + description: ( + <> + Get funding support for your Yellow Network project through + our grants program for innovative applications and integrations. + + ), + link: 'https://forms.yellow.org/build', + isExternal: true, + }, +]; + +function NitroliteHeader() { + return ( +
+
+ + Explore the SDK + +

+ Decentralized clearing and settlement network
+ Develop Yellow Apps with instant finality. +

+
+
+ ); +} + +function Feature({title, imageSrc, imageSrcDark, description, link, isExternal}: FeatureItem) { + const {colorMode} = useColorMode(); + const currentImageSrc = colorMode === 'dark' ? imageSrcDark : imageSrc; + + const linkProps = isExternal + ? {href: link, target: '_blank', rel: 'noopener noreferrer'} + : {to: link}; + + return ( +
+ +
+
+ {title} +
+ {title} +

{description}

+
+ +
+ ); +} + +export default function NitroliteHome(): ReactNode { + return ( + + +
+
+
+
+ {FeatureList.map((props) => ( + + ))} +
+
+
+
+
+ ); +} diff --git a/src/pages/nitrolite/0.5.x/index.tsx b/src/pages/nitrolite/0.5.x/index.tsx new file mode 100644 index 0000000..02fc571 --- /dev/null +++ b/src/pages/nitrolite/0.5.x/index.tsx @@ -0,0 +1,145 @@ +import type {ReactNode} from 'react'; +import clsx from 'clsx'; +import Link from '@docusaurus/Link'; +import {useColorMode} from '@docusaurus/theme-common'; +import Layout from '@theme/Layout'; +import Heading from '@theme/Heading'; + +import sharedStyles from '@site/src/pages/index.module.css'; +import featureStyles from '@site/src/components/HomepageFeatures/styles.module.css'; + +type FeatureItem = { + title: string; + imageSrc: string; + imageSrcDark: string; + description: ReactNode; + link: string; + isExternal?: boolean; +}; + +// 0.5.x cards — includes Clearnode setup, which lived in this version's docs +// before being moved to the Clearnet sub-site. +const FeatureList: FeatureItem[] = [ + { + title: 'Learn the Basics', + imageSrc: require('@site/static/img/themes/light/icons/learn.png').default, + imageSrcDark: require('@site/static/img/themes/dark/icons/learn.png').default, + description: ( + <> + Understand the fundamentals of Yellow Network, its architecture, + and how decentralized clearing and settlement works. + + ), + link: '/nitrolite/0.5.x/learn', + }, + { + title: 'Build a Yellow App', + imageSrc: require('@site/static/img/themes/light/icons/build.png').default, + imageSrcDark: require('@site/static/img/themes/dark/icons/build.png').default, + description: ( + <> + Create decentralized applications using Yellow SDK with real-time + trading capabilities and instant cross-chain settlements. + + ), + link: '/nitrolite/0.5.x/build/quick-start', + }, + { + title: 'Run a Clearnode', + imageSrc: require('@site/static/img/themes/light/icons/clearnode.png').default, + imageSrcDark: require('@site/static/img/themes/dark/icons/clearnode.png').default, + description: ( + <> + Set up and operate a clearnode to provide network services + and contribute to decentralized infrastructure. + + ), + link: '/nitrolite/0.5.x/guides/manuals/running-clearnode-locally', + }, + { + title: 'Join the Community', + imageSrc: require('@site/static/img/themes/light/icons/community.png').default, + imageSrcDark: require('@site/static/img/themes/dark/icons/community.png').default, + description: ( + <> + Connect with developers, traders, and node operators in our + Discord community and contribute to the ecosystem. + + ), + link: 'https://discord.com/invite/yellownetwork', + isExternal: true, + }, + { + title: 'Apply for Grants', + imageSrc: require('@site/static/img/themes/light/icons/grants.png').default, + imageSrcDark: require('@site/static/img/themes/dark/icons/grants.png').default, + description: ( + <> + Get funding support for your Yellow Network project through + our grants program for innovative applications and integrations. + + ), + link: 'https://forms.yellow.org/build', + isExternal: true, + }, +]; + +function NitroliteHeader() { + return ( +
+
+ + Explore the SDK + +

+ Decentralized clearing and settlement network
+ Develop Yellow Apps with instant finality. +

+
+
+ ); +} + +function Feature({title, imageSrc, imageSrcDark, description, link, isExternal}: FeatureItem) { + const {colorMode} = useColorMode(); + const currentImageSrc = colorMode === 'dark' ? imageSrcDark : imageSrc; + + const linkProps = isExternal + ? {href: link, target: '_blank', rel: 'noopener noreferrer'} + : {to: link}; + + return ( +
+ +
+
+ {title} +
+ {title} +

{description}

+
+ +
+ ); +} + +export default function NitroliteHomeLegacy(): ReactNode { + return ( + + +
+
+
+
+ {FeatureList.map((props) => ( + + ))} +
+
+
+
+
+ ); +} diff --git a/src/theme/DocBreadcrumbs/Items/Home/index.tsx b/src/theme/DocBreadcrumbs/Items/Home/index.tsx new file mode 100644 index 0000000..cdf1713 --- /dev/null +++ b/src/theme/DocBreadcrumbs/Items/Home/index.tsx @@ -0,0 +1,43 @@ +/** + * Swizzled from @docusaurus/theme-classic. + * The home icon points to the current sub-site's homepage instead of the + * global root: /nitrolite/* → /nitrolite, /clearnet/* → /clearnet/introduction. + */ + +import React, {type ReactNode} from 'react'; +import Link from '@docusaurus/Link'; +import {useLocation} from '@docusaurus/router'; +import useBaseUrl from '@docusaurus/useBaseUrl'; +import {translate} from '@docusaurus/Translate'; +import IconHome from '@theme/Icon/Home'; + +import styles from './styles.module.css'; + +function subsiteHome(pathname: string): string { + // Match the most specific Nitrolite version path first so /nitrolite/0.5.x/* + // breadcrumbs land on the 0.5.x homepage instead of the v1 homepage. + if (pathname.startsWith('/nitrolite/0.5.x')) return '/nitrolite/0.5.x'; + if (pathname.startsWith('/nitrolite')) return '/nitrolite'; + if (pathname.startsWith('/clearnet')) return '/clearnet/introduction'; + return '/'; +} + +export default function HomeBreadcrumbItem(): ReactNode { + const {pathname} = useLocation(); + const homeHref = useBaseUrl(subsiteHome(pathname)); + + return ( +
  • + + + +
  • + ); +} diff --git a/src/theme/DocBreadcrumbs/Items/Home/styles.module.css b/src/theme/DocBreadcrumbs/Items/Home/styles.module.css new file mode 100644 index 0000000..81c9f72 --- /dev/null +++ b/src/theme/DocBreadcrumbs/Items/Home/styles.module.css @@ -0,0 +1,14 @@ +/** + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + +.breadcrumbHomeIcon { + position: relative; + top: 1px; + vertical-align: top; + height: 1.1rem; + width: 1.1rem; +} diff --git a/src/theme/Navbar/Content/index.tsx b/src/theme/Navbar/Content/index.tsx index e31e78a..68e445b 100644 --- a/src/theme/Navbar/Content/index.tsx +++ b/src/theme/Navbar/Content/index.tsx @@ -8,6 +8,7 @@ import React, {type ReactNode} from 'react'; import clsx from 'clsx'; +import Link from '@docusaurus/Link'; import {useLocation} from '@docusaurus/router'; import { useThemeConfig, @@ -29,6 +30,13 @@ import styles from './styles.module.css'; type ShowOn = 'nitrolite' | 'clearnet' | 'portal' | 'all'; +// Subsite homepages: where the badge link and breadcrumb home should land. +// /clearnet has no dedicated homepage yet; falls back to its first doc. +const SUBSITE_HOME: Record<'nitrolite' | 'clearnet', string> = { + nitrolite: '/nitrolite', + clearnet: '/clearnet/introduction', +}; + function useNavbarItems() { // TODO temporary casting until ThemeConfig type is improved return useThemeConfig().navbar.items as NavbarItemConfig[]; @@ -41,16 +49,28 @@ function currentSubsite(pathname: string): 'nitrolite' | 'clearnet' | 'portal' { } function shouldShowItem(item: NavbarItemConfig, pathname: string): boolean { - const showOn = (item as {customProps?: {showOn?: ShowOn}}).customProps?.showOn; - if (!showOn || showOn === 'all') return true; - const sub = currentSubsite(pathname); - return showOn === sub; + const customProps = (item as {customProps?: {showOn?: ShowOn; hideOnPaths?: string[]}}).customProps; + const showOn = customProps?.showOn; + if (showOn && showOn !== 'all' && showOn !== currentSubsite(pathname)) { + return false; + } + if (customProps?.hideOnPaths?.some((p) => pathname === p || pathname === `${p}/`)) { + return false; + } + return true; } function SubsiteBadge({sub}: {sub: 'nitrolite' | 'clearnet' | 'portal'}) { if (sub === 'portal') return null; const label = sub === 'nitrolite' ? 'Nitrolite' : 'Clearnet'; - return {label}; + return ( + + {label} + + ); } function NavbarItems({items}: {items: NavbarItemConfig[]}): ReactNode { diff --git a/src/theme/Navbar/Content/styles.module.css b/src/theme/Navbar/Content/styles.module.css index cf17b53..0947024 100644 --- a/src/theme/Navbar/Content/styles.module.css +++ b/src/theme/Navbar/Content/styles.module.css @@ -22,18 +22,25 @@ See https://github.com/facebook/docusaurus/pull/11142 padding-right: 0; } -/* Sub-site badge: yellow rectangle showing which docs you're viewing */ -.subsiteBadge { +/* Sub-site badge: yellow rectangle that links to the sub-site homepage. */ +.subsiteBadge, +.subsiteBadge:hover, +.subsiteBadge:focus, +.subsiteBadge:visited { display: inline-flex; align-items: center; margin: 0 1rem 0 0.5rem; padding: 0.25rem 0.75rem; background-color: #FDDA16; - color: #1c1e21; + color: #1c1e21 !important; font-weight: 600; font-size: 0.875rem; line-height: 1.25rem; border-radius: 4px; - user-select: none; + text-decoration: none !important; white-space: nowrap; } + +.subsiteBadge:hover { + background-color: #FCD002; +} diff --git a/src/theme/NavbarItem/DocsVersionDropdownNavbarItem.tsx b/src/theme/NavbarItem/DocsVersionDropdownNavbarItem.tsx new file mode 100644 index 0000000..3470048 --- /dev/null +++ b/src/theme/NavbarItem/DocsVersionDropdownNavbarItem.tsx @@ -0,0 +1,208 @@ +/** + * Swizzled from @docusaurus/theme-classic. + * + * The only change vs upstream: when the user is on the Nitrolite homepage + * (/nitrolite or /nitrolite/0.5.x), the dropdown links and the trigger label + * point to the equivalent homepage in the other version, not to the docs + * default. Everywhere else, behavior is unchanged. + */ + +import React, {type ReactNode} from 'react'; +import { + useVersions, + useActiveDocContext, + useDocsVersionCandidates, + useDocsPreferredVersion, +} from '@docusaurus/plugin-content-docs/client'; +import {translate} from '@docusaurus/Translate'; +import {useHistorySelector} from '@docusaurus/theme-common'; +import {useLocation} from '@docusaurus/router'; +import DefaultNavbarItem from '@theme/NavbarItem/DefaultNavbarItem'; +import DropdownNavbarItem from '@theme/NavbarItem/DropdownNavbarItem'; +import type { + Props, + PropVersions, + PropVersionItem, +} from '@theme/NavbarItem/DocsVersionDropdownNavbarItem'; +import type {LinkLikeNavbarItemProps} from '@theme/NavbarItem'; +import type { + GlobalVersion, + GlobalDoc, + ActiveDocContext, +} from '@docusaurus/plugin-content-docs/client'; + +type VersionItem = { + version: GlobalVersion; + label: string; +}; + +// Nitrolite homepage paths per version. When the user is on one of these, +// the version dropdown should switch between them instead of jumping into +// the docs. +const NITROLITE_HOMEPAGES: Record = { + current: '/nitrolite', + '0.5.x': '/nitrolite/0.5.x', +}; + +function isOnNitroliteHomepage(pathname: string): boolean { + return Object.values(NITROLITE_HOMEPAGES).some( + (p) => pathname === p || pathname === `${p}/`, + ); +} + +function getVersionItems( + versions: GlobalVersion[], + configs?: PropVersions, +): VersionItem[] { + if (configs) { + const versionMap = new Map( + versions.map((version) => [version.name, version]), + ); + + const toVersionItem = ( + name: string, + config?: PropVersionItem, + ): VersionItem => { + const version = versionMap.get(name); + if (!version) { + throw new Error( + `No docs version exist for name '${name}'.\nAvailable: ${versions.map((v) => v.name).join(', ')}`, + ); + } + return {version, label: config?.label ?? version.label}; + }; + + if (Array.isArray(configs)) { + return configs.map((name) => toVersionItem(name, undefined)); + } else { + return Object.entries(configs).map(([name, config]) => + toVersionItem(name, config), + ); + } + } else { + return versions.map((version) => ({version, label: version.label})); + } +} + +function useVersionItems({ + docsPluginId, + configs, +}: { + docsPluginId: Props['docsPluginId']; + configs: Props['versions']; +}): VersionItem[] { + const versions = useVersions(docsPluginId); + return getVersionItems(versions, configs); +} + +function getVersionMainDoc(version: GlobalVersion): GlobalDoc { + return version.docs.find((doc) => doc.id === version.mainDocId)!; +} + +function getVersionTargetPath( + version: GlobalVersion, + activeDocContext: ActiveDocContext, + onHomepage: boolean, +): string { + if (onHomepage && NITROLITE_HOMEPAGES[version.name]) { + return NITROLITE_HOMEPAGES[version.name]!; + } + return ( + activeDocContext.alternateDocVersions[version.name]?.path ?? + getVersionMainDoc(version).path + ); +} + +function useDisplayedVersionItem({ + docsPluginId, + versionItems, +}: { + docsPluginId: Props['docsPluginId']; + versionItems: VersionItem[]; +}): VersionItem { + const candidates = useDocsVersionCandidates(docsPluginId); + const candidateItems = candidates + .map((candidate) => versionItems.find((vi) => vi.version === candidate)) + .filter((vi) => vi !== undefined); + return candidateItems[0] ?? versionItems[0]!; +} + +export default function DocsVersionDropdownNavbarItem({ + mobile, + docsPluginId, + dropdownActiveClassDisabled, + dropdownItemsBefore, + dropdownItemsAfter, + versions: configs, + ...props +}: Props): ReactNode { + const search = useHistorySelector((history) => history.location.search); + const hash = useHistorySelector((history) => history.location.hash); + const {pathname} = useLocation(); + const activeDocContext = useActiveDocContext(docsPluginId); + const {savePreferredVersionName} = useDocsPreferredVersion(docsPluginId); + const versionItems = useVersionItems({docsPluginId, configs}); + const displayedVersionItem = useDisplayedVersionItem({ + docsPluginId, + versionItems, + }); + + const onHomepage = isOnNitroliteHomepage(pathname); + + function versionItemToLink({ + version, + label, + }: VersionItem): LinkLikeNavbarItemProps { + const targetPath = getVersionTargetPath(version, activeDocContext, onHomepage); + return { + label, + to: `${targetPath}${search}${hash}`, + isActive: () => version === activeDocContext.activeVersion, + onClick: () => savePreferredVersionName(version.name), + }; + } + + const items: LinkLikeNavbarItemProps[] = [ + ...dropdownItemsBefore, + ...versionItems.map(versionItemToLink), + ...dropdownItemsAfter, + ]; + + const dropdownLabel = + mobile && items.length > 1 + ? translate({ + id: 'theme.navbar.mobileVersionsDropdown.label', + message: 'Versions', + description: + 'The label for the navbar versions dropdown on mobile view', + }) + : displayedVersionItem.label; + + const dropdownTo = + mobile && items.length > 1 + ? undefined + : getVersionTargetPath(displayedVersionItem.version, activeDocContext, onHomepage); + + if (items.length <= 1) { + return ( + false : undefined} + /> + ); + } + + return ( + false : undefined} + /> + ); +} From fdf2afafa356d0d126dae2faede6950524abc8cd Mon Sep 17 00:00:00 2001 From: nksazonov Date: Thu, 30 Apr 2026 11:29:49 +0200 Subject: [PATCH 13/16] fix: apply comments --- .gitignore | 1 + docs/clearnet/{ => learn}/architecture.mdx | 0 .../{ => learn}/contracts/_category_.json | 0 .../contracts/api-reference/_category_.json | 0 .../contracts/api-reference/app-registry.md | 0 .../contracts/api-reference/faucet.md | 0 .../api-reference/interfaces/_category_.json | 0 .../api-reference/interfaces/ilock.md | 0 .../api-reference/interfaces/islash.md | 0 .../contracts/api-reference/locker.md | 0 .../contracts/api-reference/node-registry.md | 0 .../contracts/api-reference/treasury.md | 0 .../api-reference/yellow-governor.md | 0 .../contracts/api-reference/yellow-token.md | 0 docs/clearnet/{ => learn}/contracts/faq.md | 0 docs/clearnet/{ => learn}/contracts/index.md | 0 .../contracts/integration/_category_.json | 0 .../contracts/integration/deployment.md | 0 .../contracts/integration/events.md | 0 .../contracts/integration/ui-spec.md | 0 .../contracts/protocol/_category_.json | 0 .../contracts/protocol/governance.md | 0 .../contracts/protocol/overview.md | 0 .../contracts/protocol/slashing.md | 0 .../{ => learn}/contracts/protocol/staking.md | 0 .../contracts/protocol/treasury.md | 0 .../{ => learn}/contracts/sdk/_category_.json | 0 .../contracts/sdk/api-reference.md | 0 .../{ => learn}/contracts/sdk/examples.md | 0 .../contracts/sdk/getting-started.md | 0 .../decentralized-layer/_category_.json | 0 .../decentralized-layer/cluster-lifecycle.mdx | 0 .../decentralized-layer/elastic-security.mdx | 0 .../decentralized-layer/liquidity-layer.mdx | 0 .../decentralized-layer/overview.mdx | 0 .../protocol-lifecycle.mdx | 0 .../decentralized-layer/security.mdx | 0 docs/clearnet/{ => learn}/introduction.mdx | 0 docusaurus.config.ts | 48 ++++++------------- lessons.md | 9 ++++ sidebars-clearnet.ts | 10 ++-- src/components/HomepageFeatures/index.tsx | 14 +++++- src/css/custom.css | 2 +- src/pages/nitrolite.tsx | 6 +-- src/pages/nitrolite/0.5.x/index.tsx | 2 +- src/theme/DocBreadcrumbs/Items/Home/index.tsx | 4 +- src/theme/Navbar/Content/index.tsx | 2 +- 47 files changed, 49 insertions(+), 49 deletions(-) rename docs/clearnet/{ => learn}/architecture.mdx (100%) rename docs/clearnet/{ => learn}/contracts/_category_.json (100%) rename docs/clearnet/{ => learn}/contracts/api-reference/_category_.json (100%) rename docs/clearnet/{ => learn}/contracts/api-reference/app-registry.md (100%) rename docs/clearnet/{ => learn}/contracts/api-reference/faucet.md (100%) rename docs/clearnet/{ => learn}/contracts/api-reference/interfaces/_category_.json (100%) rename docs/clearnet/{ => learn}/contracts/api-reference/interfaces/ilock.md (100%) rename docs/clearnet/{ => learn}/contracts/api-reference/interfaces/islash.md (100%) rename docs/clearnet/{ => learn}/contracts/api-reference/locker.md (100%) rename docs/clearnet/{ => learn}/contracts/api-reference/node-registry.md (100%) rename docs/clearnet/{ => learn}/contracts/api-reference/treasury.md (100%) rename docs/clearnet/{ => learn}/contracts/api-reference/yellow-governor.md (100%) rename docs/clearnet/{ => learn}/contracts/api-reference/yellow-token.md (100%) rename docs/clearnet/{ => learn}/contracts/faq.md (100%) rename docs/clearnet/{ => learn}/contracts/index.md (100%) rename docs/clearnet/{ => learn}/contracts/integration/_category_.json (100%) rename docs/clearnet/{ => learn}/contracts/integration/deployment.md (100%) rename docs/clearnet/{ => learn}/contracts/integration/events.md (100%) rename docs/clearnet/{ => learn}/contracts/integration/ui-spec.md (100%) rename docs/clearnet/{ => learn}/contracts/protocol/_category_.json (100%) rename docs/clearnet/{ => learn}/contracts/protocol/governance.md (100%) rename docs/clearnet/{ => learn}/contracts/protocol/overview.md (100%) rename docs/clearnet/{ => learn}/contracts/protocol/slashing.md (100%) rename docs/clearnet/{ => learn}/contracts/protocol/staking.md (100%) rename docs/clearnet/{ => learn}/contracts/protocol/treasury.md (100%) rename docs/clearnet/{ => learn}/contracts/sdk/_category_.json (100%) rename docs/clearnet/{ => learn}/contracts/sdk/api-reference.md (100%) rename docs/clearnet/{ => learn}/contracts/sdk/examples.md (100%) rename docs/clearnet/{ => learn}/contracts/sdk/getting-started.md (100%) rename docs/clearnet/{ => learn}/decentralized-layer/_category_.json (100%) rename docs/clearnet/{ => learn}/decentralized-layer/cluster-lifecycle.mdx (100%) rename docs/clearnet/{ => learn}/decentralized-layer/elastic-security.mdx (100%) rename docs/clearnet/{ => learn}/decentralized-layer/liquidity-layer.mdx (100%) rename docs/clearnet/{ => learn}/decentralized-layer/overview.mdx (100%) rename docs/clearnet/{ => learn}/decentralized-layer/protocol-lifecycle.mdx (100%) rename docs/clearnet/{ => learn}/decentralized-layer/security.mdx (100%) rename docs/clearnet/{ => learn}/introduction.mdx (100%) create mode 100644 lessons.md diff --git a/.gitignore b/.gitignore index b580350..90af70d 100644 --- a/.gitignore +++ b/.gitignore @@ -21,3 +21,4 @@ npm-debug.log* yarn-debug.log* yarn-error.log* .vercel +.gstack/ diff --git a/docs/clearnet/architecture.mdx b/docs/clearnet/learn/architecture.mdx similarity index 100% rename from docs/clearnet/architecture.mdx rename to docs/clearnet/learn/architecture.mdx diff --git a/docs/clearnet/contracts/_category_.json b/docs/clearnet/learn/contracts/_category_.json similarity index 100% rename from docs/clearnet/contracts/_category_.json rename to docs/clearnet/learn/contracts/_category_.json diff --git a/docs/clearnet/contracts/api-reference/_category_.json b/docs/clearnet/learn/contracts/api-reference/_category_.json similarity index 100% rename from docs/clearnet/contracts/api-reference/_category_.json rename to docs/clearnet/learn/contracts/api-reference/_category_.json diff --git a/docs/clearnet/contracts/api-reference/app-registry.md b/docs/clearnet/learn/contracts/api-reference/app-registry.md similarity index 100% rename from docs/clearnet/contracts/api-reference/app-registry.md rename to docs/clearnet/learn/contracts/api-reference/app-registry.md diff --git a/docs/clearnet/contracts/api-reference/faucet.md b/docs/clearnet/learn/contracts/api-reference/faucet.md similarity index 100% rename from docs/clearnet/contracts/api-reference/faucet.md rename to docs/clearnet/learn/contracts/api-reference/faucet.md diff --git a/docs/clearnet/contracts/api-reference/interfaces/_category_.json b/docs/clearnet/learn/contracts/api-reference/interfaces/_category_.json similarity index 100% rename from docs/clearnet/contracts/api-reference/interfaces/_category_.json rename to docs/clearnet/learn/contracts/api-reference/interfaces/_category_.json diff --git a/docs/clearnet/contracts/api-reference/interfaces/ilock.md b/docs/clearnet/learn/contracts/api-reference/interfaces/ilock.md similarity index 100% rename from docs/clearnet/contracts/api-reference/interfaces/ilock.md rename to docs/clearnet/learn/contracts/api-reference/interfaces/ilock.md diff --git a/docs/clearnet/contracts/api-reference/interfaces/islash.md b/docs/clearnet/learn/contracts/api-reference/interfaces/islash.md similarity index 100% rename from docs/clearnet/contracts/api-reference/interfaces/islash.md rename to docs/clearnet/learn/contracts/api-reference/interfaces/islash.md diff --git a/docs/clearnet/contracts/api-reference/locker.md b/docs/clearnet/learn/contracts/api-reference/locker.md similarity index 100% rename from docs/clearnet/contracts/api-reference/locker.md rename to docs/clearnet/learn/contracts/api-reference/locker.md diff --git a/docs/clearnet/contracts/api-reference/node-registry.md b/docs/clearnet/learn/contracts/api-reference/node-registry.md similarity index 100% rename from docs/clearnet/contracts/api-reference/node-registry.md rename to docs/clearnet/learn/contracts/api-reference/node-registry.md diff --git a/docs/clearnet/contracts/api-reference/treasury.md b/docs/clearnet/learn/contracts/api-reference/treasury.md similarity index 100% rename from docs/clearnet/contracts/api-reference/treasury.md rename to docs/clearnet/learn/contracts/api-reference/treasury.md diff --git a/docs/clearnet/contracts/api-reference/yellow-governor.md b/docs/clearnet/learn/contracts/api-reference/yellow-governor.md similarity index 100% rename from docs/clearnet/contracts/api-reference/yellow-governor.md rename to docs/clearnet/learn/contracts/api-reference/yellow-governor.md diff --git a/docs/clearnet/contracts/api-reference/yellow-token.md b/docs/clearnet/learn/contracts/api-reference/yellow-token.md similarity index 100% rename from docs/clearnet/contracts/api-reference/yellow-token.md rename to docs/clearnet/learn/contracts/api-reference/yellow-token.md diff --git a/docs/clearnet/contracts/faq.md b/docs/clearnet/learn/contracts/faq.md similarity index 100% rename from docs/clearnet/contracts/faq.md rename to docs/clearnet/learn/contracts/faq.md diff --git a/docs/clearnet/contracts/index.md b/docs/clearnet/learn/contracts/index.md similarity index 100% rename from docs/clearnet/contracts/index.md rename to docs/clearnet/learn/contracts/index.md diff --git a/docs/clearnet/contracts/integration/_category_.json b/docs/clearnet/learn/contracts/integration/_category_.json similarity index 100% rename from docs/clearnet/contracts/integration/_category_.json rename to docs/clearnet/learn/contracts/integration/_category_.json diff --git a/docs/clearnet/contracts/integration/deployment.md b/docs/clearnet/learn/contracts/integration/deployment.md similarity index 100% rename from docs/clearnet/contracts/integration/deployment.md rename to docs/clearnet/learn/contracts/integration/deployment.md diff --git a/docs/clearnet/contracts/integration/events.md b/docs/clearnet/learn/contracts/integration/events.md similarity index 100% rename from docs/clearnet/contracts/integration/events.md rename to docs/clearnet/learn/contracts/integration/events.md diff --git a/docs/clearnet/contracts/integration/ui-spec.md b/docs/clearnet/learn/contracts/integration/ui-spec.md similarity index 100% rename from docs/clearnet/contracts/integration/ui-spec.md rename to docs/clearnet/learn/contracts/integration/ui-spec.md diff --git a/docs/clearnet/contracts/protocol/_category_.json b/docs/clearnet/learn/contracts/protocol/_category_.json similarity index 100% rename from docs/clearnet/contracts/protocol/_category_.json rename to docs/clearnet/learn/contracts/protocol/_category_.json diff --git a/docs/clearnet/contracts/protocol/governance.md b/docs/clearnet/learn/contracts/protocol/governance.md similarity index 100% rename from docs/clearnet/contracts/protocol/governance.md rename to docs/clearnet/learn/contracts/protocol/governance.md diff --git a/docs/clearnet/contracts/protocol/overview.md b/docs/clearnet/learn/contracts/protocol/overview.md similarity index 100% rename from docs/clearnet/contracts/protocol/overview.md rename to docs/clearnet/learn/contracts/protocol/overview.md diff --git a/docs/clearnet/contracts/protocol/slashing.md b/docs/clearnet/learn/contracts/protocol/slashing.md similarity index 100% rename from docs/clearnet/contracts/protocol/slashing.md rename to docs/clearnet/learn/contracts/protocol/slashing.md diff --git a/docs/clearnet/contracts/protocol/staking.md b/docs/clearnet/learn/contracts/protocol/staking.md similarity index 100% rename from docs/clearnet/contracts/protocol/staking.md rename to docs/clearnet/learn/contracts/protocol/staking.md diff --git a/docs/clearnet/contracts/protocol/treasury.md b/docs/clearnet/learn/contracts/protocol/treasury.md similarity index 100% rename from docs/clearnet/contracts/protocol/treasury.md rename to docs/clearnet/learn/contracts/protocol/treasury.md diff --git a/docs/clearnet/contracts/sdk/_category_.json b/docs/clearnet/learn/contracts/sdk/_category_.json similarity index 100% rename from docs/clearnet/contracts/sdk/_category_.json rename to docs/clearnet/learn/contracts/sdk/_category_.json diff --git a/docs/clearnet/contracts/sdk/api-reference.md b/docs/clearnet/learn/contracts/sdk/api-reference.md similarity index 100% rename from docs/clearnet/contracts/sdk/api-reference.md rename to docs/clearnet/learn/contracts/sdk/api-reference.md diff --git a/docs/clearnet/contracts/sdk/examples.md b/docs/clearnet/learn/contracts/sdk/examples.md similarity index 100% rename from docs/clearnet/contracts/sdk/examples.md rename to docs/clearnet/learn/contracts/sdk/examples.md diff --git a/docs/clearnet/contracts/sdk/getting-started.md b/docs/clearnet/learn/contracts/sdk/getting-started.md similarity index 100% rename from docs/clearnet/contracts/sdk/getting-started.md rename to docs/clearnet/learn/contracts/sdk/getting-started.md diff --git a/docs/clearnet/decentralized-layer/_category_.json b/docs/clearnet/learn/decentralized-layer/_category_.json similarity index 100% rename from docs/clearnet/decentralized-layer/_category_.json rename to docs/clearnet/learn/decentralized-layer/_category_.json diff --git a/docs/clearnet/decentralized-layer/cluster-lifecycle.mdx b/docs/clearnet/learn/decentralized-layer/cluster-lifecycle.mdx similarity index 100% rename from docs/clearnet/decentralized-layer/cluster-lifecycle.mdx rename to docs/clearnet/learn/decentralized-layer/cluster-lifecycle.mdx diff --git a/docs/clearnet/decentralized-layer/elastic-security.mdx b/docs/clearnet/learn/decentralized-layer/elastic-security.mdx similarity index 100% rename from docs/clearnet/decentralized-layer/elastic-security.mdx rename to docs/clearnet/learn/decentralized-layer/elastic-security.mdx diff --git a/docs/clearnet/decentralized-layer/liquidity-layer.mdx b/docs/clearnet/learn/decentralized-layer/liquidity-layer.mdx similarity index 100% rename from docs/clearnet/decentralized-layer/liquidity-layer.mdx rename to docs/clearnet/learn/decentralized-layer/liquidity-layer.mdx diff --git a/docs/clearnet/decentralized-layer/overview.mdx b/docs/clearnet/learn/decentralized-layer/overview.mdx similarity index 100% rename from docs/clearnet/decentralized-layer/overview.mdx rename to docs/clearnet/learn/decentralized-layer/overview.mdx diff --git a/docs/clearnet/decentralized-layer/protocol-lifecycle.mdx b/docs/clearnet/learn/decentralized-layer/protocol-lifecycle.mdx similarity index 100% rename from docs/clearnet/decentralized-layer/protocol-lifecycle.mdx rename to docs/clearnet/learn/decentralized-layer/protocol-lifecycle.mdx diff --git a/docs/clearnet/decentralized-layer/security.mdx b/docs/clearnet/learn/decentralized-layer/security.mdx similarity index 100% rename from docs/clearnet/decentralized-layer/security.mdx rename to docs/clearnet/learn/decentralized-layer/security.mdx diff --git a/docs/clearnet/introduction.mdx b/docs/clearnet/learn/introduction.mdx similarity index 100% rename from docs/clearnet/introduction.mdx rename to docs/clearnet/learn/introduction.mdx diff --git a/docusaurus.config.ts b/docusaurus.config.ts index 757f4de..a7f5ded 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -141,7 +141,7 @@ const config: Config = { customProps: { showOn: 'portal' }, }, { - to: '/clearnet/introduction', + to: '/clearnet/learn/introduction', label: 'Clearnet', position: 'left', customProps: { showOn: 'portal' }, @@ -168,36 +168,12 @@ const config: Config = { position: 'left', customProps: { showOn: 'nitrolite' }, }, - // Clearnet navbar items (shown on /clearnet/*) + // Clearnet navbar items (shown on /clearnet/*) — single "Learn" entry + // is a plain link to Introduction, not a doc reference, so the navbar + // item itself doesn't represent a page. { - type: 'doc', - docsPluginId: 'clearnet', - docId: 'introduction', - label: 'Introduction', - position: 'left', - customProps: { showOn: 'clearnet' }, - }, - { - type: 'doc', - docsPluginId: 'clearnet', - docId: 'architecture', - label: 'Architecture', - position: 'left', - customProps: { showOn: 'clearnet' }, - }, - { - type: 'doc', - docsPluginId: 'clearnet', - docId: 'decentralized-layer/overview', - label: 'Decentralized Layer', - position: 'left', - customProps: { showOn: 'clearnet' }, - }, - { - type: 'doc', - docsPluginId: 'clearnet', - docId: 'contracts/index', - label: 'Contracts', + to: '/clearnet/learn/introduction', + label: 'Learn', position: 'left', customProps: { showOn: 'clearnet' }, }, @@ -210,7 +186,7 @@ const config: Config = { }, // GitHub link visible on all sub-sites { - href: 'https://github.com/layer-3', + href: 'https://github.com/layer-3/docs', position: 'right', className: 'header-github-link', 'aria-label': 'GitHub repository', @@ -261,15 +237,15 @@ const config: Config = { items: [ { label: 'Introduction', - to: '/clearnet/introduction', + to: '/clearnet/learn/introduction', }, { label: 'Architecture', - to: '/clearnet/architecture', + to: '/clearnet/learn/architecture', }, { label: 'Contracts', - to: '/clearnet/contracts', + to: '/clearnet/learn/contracts', }, ], }, @@ -285,6 +261,10 @@ const config: Config = { { title: 'Community', items: [ + { + label: 'Telegram', + href: 'https://t.me/YellowSDKCommunity', + }, { label: 'Discord', href: 'https://discord.com/invite/yellownetwork', diff --git a/lessons.md b/lessons.md new file mode 100644 index 0000000..49ec4d5 --- /dev/null +++ b/lessons.md @@ -0,0 +1,9 @@ +## Sidebar arrow-only toggle (2026-04-29) + +The sidebar uses Docusaurus's `DocSidebarItem/Category`. The `>` chevron previously visible was a CSS `::before` pseudo-element on `.menu__link--sublist` — purely decorative; clicking the row text triggered the toggle. + +To make only the chevron clickable: +1. Swizzle `src/theme/DocSidebarItem/Category/index.tsx` and always render the upstream `` (`.clean-btn.menu__caret`) before the link. Its `onClick` calls `updateCollapsed()`. The link's `onClick` only navigates (when `href`) or `preventDefault`s (when not). +2. CSS: hide the legacy `::before` arrows on `.menu__link--sublist`/`.menu__list-item-collapsible > .menu__link`, then style `.menu__list-item-collapsible > .menu__caret` as the new chevron with rotation on `[aria-expanded="true"]`. +3. Infima ships its own rotations on `.menu__caret::before` (`rotate(180deg)` default and `rotateZ(90deg)` under `.menu__list-item--collapsed`). Reset both with `transform: none !important;` on the base rule, then apply `transform: rotate(90deg)` only on `[aria-expanded="true"]`. +4. Per-item `collapsible: false` in `sidebars-*.ts` makes a category non-collapsible (no chevron rendered, `useCollapsible` returns always-expanded). Removing the override defaults to `collapsible: true`. diff --git a/sidebars-clearnet.ts b/sidebars-clearnet.ts index 87fe56d..ec394e7 100644 --- a/sidebars-clearnet.ts +++ b/sidebars-clearnet.ts @@ -4,24 +4,22 @@ import type {SidebarsConfig} from '@docusaurus/plugin-content-docs'; const sidebars: SidebarsConfig = { clearnetSidebar: [ - 'introduction', - 'architecture', + 'learn/introduction', + 'learn/architecture', { type: 'category', label: 'Decentralized Layer', items: [ - {type: 'autogenerated', dirName: 'decentralized-layer'}, + {type: 'autogenerated', dirName: 'learn/decentralized-layer'}, ], - collapsible: false, collapsed: false, }, { type: 'category', label: 'Contracts', items: [ - {type: 'autogenerated', dirName: 'contracts'}, + {type: 'autogenerated', dirName: 'learn/contracts'}, ], - collapsible: false, collapsed: false, }, ], diff --git a/src/components/HomepageFeatures/index.tsx b/src/components/HomepageFeatures/index.tsx index 4490384..b1bea0e 100644 --- a/src/components/HomepageFeatures/index.tsx +++ b/src/components/HomepageFeatures/index.tsx @@ -38,7 +38,19 @@ const FeatureList: FeatureItem[] = [ network, smart contracts, governance, and node operations. ), - link: '/clearnet/introduction', + link: '/clearnet/learn/introduction', + }, + { + title: 'Whitepaper', + imageSrc: require('@site/static/img/themes/light/icons/learn.png').default, + imageSrcDark: require('@site/static/img/themes/dark/icons/learn.png').default, + description: ( + <> + The Yellow Network whitepaper — protocol design, economic model, + and technical reference for the decentralized clearing layer. + + ), + link: '/whitepaper', }, ]; diff --git a/src/css/custom.css b/src/css/custom.css index d5e07af..85f5eaa 100644 --- a/src/css/custom.css +++ b/src/css/custom.css @@ -644,8 +644,8 @@ a.menu__link.menu__link--sublist.menu__link--active:hover { .footer__col:first-child, .footer__col:first-child .footer__items, .footer__col:first-child .footer__item { - padding-left: 0 !important; margin-left: 0 !important; + margin-right: 2rem !important; text-align: left !important; } diff --git a/src/pages/nitrolite.tsx b/src/pages/nitrolite.tsx index 6a68ee5..37e7896 100644 --- a/src/pages/nitrolite.tsx +++ b/src/pages/nitrolite.tsx @@ -50,11 +50,11 @@ const FeatureList: FeatureItem[] = [ imageSrcDark: require('@site/static/img/themes/dark/icons/community.png').default, description: ( <> - Connect with developers, traders, and node operators in our - Discord community and contribute to the ecosystem. + Connect with users, developers, and traders in our + Telegram community and contribute to the ecosystem. ), - link: 'https://discord.com/invite/yellownetwork', + link: 'https://t.me/YellowSDKCommunity', isExternal: true, }, { diff --git a/src/pages/nitrolite/0.5.x/index.tsx b/src/pages/nitrolite/0.5.x/index.tsx index 02fc571..22b7b1e 100644 --- a/src/pages/nitrolite/0.5.x/index.tsx +++ b/src/pages/nitrolite/0.5.x/index.tsx @@ -66,7 +66,7 @@ const FeatureList: FeatureItem[] = [ Discord community and contribute to the ecosystem. ), - link: 'https://discord.com/invite/yellownetwork', + link: 'https://t.me/YellowSDKCommunity', isExternal: true, }, { diff --git a/src/theme/DocBreadcrumbs/Items/Home/index.tsx b/src/theme/DocBreadcrumbs/Items/Home/index.tsx index cdf1713..59141ec 100644 --- a/src/theme/DocBreadcrumbs/Items/Home/index.tsx +++ b/src/theme/DocBreadcrumbs/Items/Home/index.tsx @@ -1,7 +1,7 @@ /** * Swizzled from @docusaurus/theme-classic. * The home icon points to the current sub-site's homepage instead of the - * global root: /nitrolite/* → /nitrolite, /clearnet/* → /clearnet/introduction. + * global root: /nitrolite/* → /nitrolite, /clearnet/* → /clearnet/learn/introduction. */ import React, {type ReactNode} from 'react'; @@ -18,7 +18,7 @@ function subsiteHome(pathname: string): string { // breadcrumbs land on the 0.5.x homepage instead of the v1 homepage. if (pathname.startsWith('/nitrolite/0.5.x')) return '/nitrolite/0.5.x'; if (pathname.startsWith('/nitrolite')) return '/nitrolite'; - if (pathname.startsWith('/clearnet')) return '/clearnet/introduction'; + if (pathname.startsWith('/clearnet')) return '/clearnet/learn/introduction'; return '/'; } diff --git a/src/theme/Navbar/Content/index.tsx b/src/theme/Navbar/Content/index.tsx index 68e445b..e773bbc 100644 --- a/src/theme/Navbar/Content/index.tsx +++ b/src/theme/Navbar/Content/index.tsx @@ -34,7 +34,7 @@ type ShowOn = 'nitrolite' | 'clearnet' | 'portal' | 'all'; // /clearnet has no dedicated homepage yet; falls back to its first doc. const SUBSITE_HOME: Record<'nitrolite' | 'clearnet', string> = { nitrolite: '/nitrolite', - clearnet: '/clearnet/introduction', + clearnet: '/clearnet/learn/introduction', }; function useNavbarItems() { From ba8702065671567b61e2e7538ed02eb8dbb46dbf Mon Sep 17 00:00:00 2001 From: nksazonov Date: Thu, 30 Apr 2026 12:27:10 +0200 Subject: [PATCH 14/16] fix: text size, contents --- src/css/custom.css | 53 +++++++++++++++++++++++++++++++++++----------- 1 file changed, 41 insertions(+), 12 deletions(-) diff --git a/src/css/custom.css b/src/css/custom.css index 85f5eaa..c8634c9 100644 --- a/src/css/custom.css +++ b/src/css/custom.css @@ -26,7 +26,7 @@ --ifm-font-weight-base: 300; --ifm-font-weight-semibold: 500; --ifm-font-weight-bold: 500; - --doc-sidebar-width: 315px; + --doc-sidebar-width: 270px; --ifm-navbar-search-input-icon: url('data:image/svg+xml;utf8,'); } @@ -69,8 +69,8 @@ font-family: 'Poppins', sans-serif !important; font-weight: 300 !important; font-style: normal !important; - font-size: 16px !important; - line-height: 24px !important; + font-size: 15px !important; + line-height: 17px !important; letter-spacing: 0.15px !important; vertical-align: middle !important; } @@ -82,8 +82,8 @@ font-family: 'Poppins', sans-serif !important; font-weight: 500 !important; font-style: normal !important; - font-size: 16px !important; - line-height: 24px !important; + font-size: 15px !important; + line-height: 17px !important; letter-spacing: 0.15px !important; vertical-align: middle !important; } @@ -143,12 +143,11 @@ a.menu__link--active { background-color: #EDEDED; } -/* Level 3 leaf vertical line: align with the level-2 collapsible chevron above - * it. The previous `left: 8px` offset shifted this line away from the chevron, - * breaking the chevron-on-line invariant. +/* Level 3 leaf vertical line: align with the level-2 collapsible chevron, + * which sits at padding-left: 32px on its container. */ .menu__list .menu__list .menu__list .menu__link:not(.menu__link--sublist):not(.menu__link--sublist-caret)::before { - left: 0; + left: 12px; } /* Add proper padding for all sidebar items with borders */ @@ -156,17 +155,30 @@ a.menu__link--active { position: relative; } -/* Add extra spacing only for sub-items (level-2 items under categories) */ +/* Double the default horizontal padding of the central doc content column */ +[class*='docItemCol'] { + padding: 0 40px !important; +} + +/* Nested indentation — each level shifts further right */ .theme-doc-sidebar-item-link-level-2 .menu__link { padding-left: 32px !important; } .menu__list .menu__list .menu__link:not(.menu__link--sublist) { - padding-left: 24px !important; + padding-left: 20px !important; +} + +/* Level-2 category headers (e.g. "TypeScript SDK" under "SDK") — + * chevron at 28px so it aligns with sibling doc items */ +.menu__list .menu__list .menu__list-item-collapsible, +.menu__list .menu__list .menu__list-item-collapsible--active, +.menu__list .menu__list .menu__list-item-collapsible:hover { + padding-left: 28px !important; } .menu__list .menu__list .menu__list .menu__link:not(.menu__link--sublist) { - padding-left: 32px !important; + padding-left: 36px !important; } /* Table of contents styling - use darker/lighter colors instead of theme colors */ @@ -211,6 +223,23 @@ a.table-of-contents__link.table-of-contents__link--active code { color: #cccccc !important; } +/* Remove left padding from the right TOC column */ +.col.col--3 { + padding-left: 0 !important; +} + +/* "ON THIS PAGE:" heading above the TOC */ +.theme-doc-toc-desktop::before { + content: 'ON THIS PAGE:'; + display: block; + font-family: 'Poppins', sans-serif; + font-size: 13px; + font-weight: 500; + letter-spacing: 0.08em; + margin-bottom: 12px; + margin-left: 6px; +} + /* Pagination navigation styling */ .pagination-nav__link { border: 1px solid #e0e0e0 !important; From 41c9b27de9803ea2044135b456314cfa1675c8af Mon Sep 17 00:00:00 2001 From: nksazonov Date: Thu, 30 Apr 2026 12:36:50 +0200 Subject: [PATCH 15/16] fix: bring back v0.5 guides, ensure version remains when routing to index --- docusaurus.config.ts | 7 +++++++ src/theme/Navbar/Content/index.tsx | 23 ++++++++++++++--------- 2 files changed, 21 insertions(+), 9 deletions(-) diff --git a/docusaurus.config.ts b/docusaurus.config.ts index a7f5ded..375be78 100644 --- a/docusaurus.config.ts +++ b/docusaurus.config.ts @@ -168,6 +168,13 @@ const config: Config = { position: 'left', customProps: { showOn: 'nitrolite' }, }, + { + type: 'doc', + docId: 'guides/index', + label: 'Guides', + position: 'left', + customProps: { showOn: 'nitrolite', onlyIfPathStartsWith: '/nitrolite/0.5.x' }, + }, // Clearnet navbar items (shown on /clearnet/*) — single "Learn" entry // is a plain link to Introduction, not a doc reference, so the navbar // item itself doesn't represent a page. diff --git a/src/theme/Navbar/Content/index.tsx b/src/theme/Navbar/Content/index.tsx index e773bbc..3354b0a 100644 --- a/src/theme/Navbar/Content/index.tsx +++ b/src/theme/Navbar/Content/index.tsx @@ -31,11 +31,13 @@ import styles from './styles.module.css'; type ShowOn = 'nitrolite' | 'clearnet' | 'portal' | 'all'; // Subsite homepages: where the badge link and breadcrumb home should land. -// /clearnet has no dedicated homepage yet; falls back to its first doc. -const SUBSITE_HOME: Record<'nitrolite' | 'clearnet', string> = { - nitrolite: '/nitrolite', - clearnet: '/clearnet/learn/introduction', -}; +// For Nitrolite, the homepage is version-aware: 0.5.x stays on 0.5.x. +function subsiteHome(sub: 'nitrolite' | 'clearnet', pathname: string): string { + if (sub === 'nitrolite') { + return pathname.startsWith('/nitrolite/0.5.x') ? '/nitrolite/0.5.x' : '/nitrolite'; + } + return '/clearnet/learn/introduction'; +} function useNavbarItems() { // TODO temporary casting until ThemeConfig type is improved @@ -49,7 +51,7 @@ function currentSubsite(pathname: string): 'nitrolite' | 'clearnet' | 'portal' { } function shouldShowItem(item: NavbarItemConfig, pathname: string): boolean { - const customProps = (item as {customProps?: {showOn?: ShowOn; hideOnPaths?: string[]}}).customProps; + const customProps = (item as {customProps?: {showOn?: ShowOn; hideOnPaths?: string[]; onlyIfPathStartsWith?: string}}).customProps; const showOn = customProps?.showOn; if (showOn && showOn !== 'all' && showOn !== currentSubsite(pathname)) { return false; @@ -57,15 +59,18 @@ function shouldShowItem(item: NavbarItemConfig, pathname: string): boolean { if (customProps?.hideOnPaths?.some((p) => pathname === p || pathname === `${p}/`)) { return false; } + if (customProps?.onlyIfPathStartsWith && !pathname.startsWith(customProps.onlyIfPathStartsWith)) { + return false; + } return true; } -function SubsiteBadge({sub}: {sub: 'nitrolite' | 'clearnet' | 'portal'}) { +function SubsiteBadge({sub, pathname}: {sub: 'nitrolite' | 'clearnet' | 'portal'; pathname: string}) { if (sub === 'portal') return null; const label = sub === 'nitrolite' ? 'Nitrolite' : 'Clearnet'; return ( {label} @@ -138,7 +143,7 @@ export default function NavbarContent(): ReactNode { <> {!mobileSidebar.disabled && } - + } From 4df54f0be153022c4250316d02eaa43c74eceb19 Mon Sep 17 00:00:00 2001 From: nksazonov Date: Thu, 30 Apr 2026 15:01:06 +0200 Subject: [PATCH 16/16] fix: resolve PR review findings - Replace cross-site Clearnet links in Nitrolite docs with /nitrolite/protocol/protocol-reference - Fix _category_.json doc ID to learn/contracts/index (was missing learn/ prefix) - Use filteredItems for searchBarItem in Navbar/Content to respect showOn filtering - Remove lessons.md --- docs/clearnet/learn/contracts/_category_.json | 2 +- docs/nitrolite/build/sdk/multi-party-app-sessions.mdx | 2 +- .../nitrolite/learn/core-concepts/challenge-response.mdx | 2 +- .../learn/core-concepts/state-channels-vs-l1-l2.mdx | 2 +- docs/nitrolite/learn/index.mdx | 2 +- .../learn/introduction/architecture-at-a-glance.mdx | 2 +- lessons.md | 9 --------- src/theme/Navbar/Content/index.tsx | 2 +- 8 files changed, 7 insertions(+), 16 deletions(-) delete mode 100644 lessons.md diff --git a/docs/clearnet/learn/contracts/_category_.json b/docs/clearnet/learn/contracts/_category_.json index 1740788..510e0b2 100644 --- a/docs/clearnet/learn/contracts/_category_.json +++ b/docs/clearnet/learn/contracts/_category_.json @@ -3,7 +3,7 @@ "position": 1, "link": { "type": "doc", - "id": "contracts/index" + "id": "learn/contracts/index" }, "collapsible": false, "collapsed": false diff --git a/docs/nitrolite/build/sdk/multi-party-app-sessions.mdx b/docs/nitrolite/build/sdk/multi-party-app-sessions.mdx index e60a631..1262dda 100644 --- a/docs/nitrolite/build/sdk/multi-party-app-sessions.mdx +++ b/docs/nitrolite/build/sdk/multi-party-app-sessions.mdx @@ -585,5 +585,5 @@ console.log(`Current weight: ${signatureWeight}, Required: ${quorum}`); ## Further Reading -- [Clearnet Protocol](/clearnet/introduction) — Protocol specification and architecture +- [Protocol Reference](/nitrolite/protocol/protocol-reference) — Protocol specification and architecture - [SDK Reference](/nitrolite/build/sdk) — Complete SDK documentation diff --git a/docs/nitrolite/learn/core-concepts/challenge-response.mdx b/docs/nitrolite/learn/core-concepts/challenge-response.mdx index 0acb50e..30e7b4c 100644 --- a/docs/nitrolite/learn/core-concepts/challenge-response.mdx +++ b/docs/nitrolite/learn/core-concepts/challenge-response.mdx @@ -152,4 +152,4 @@ You can **always** recover your funds according to the latest mutually signed st ## Deep Dive -For technical implementation details, see the [Clearnet Protocol](/clearnet/introduction) section. +For technical implementation details, see the [Protocol Reference](/nitrolite/protocol/protocol-reference) section. diff --git a/docs/nitrolite/learn/core-concepts/state-channels-vs-l1-l2.mdx b/docs/nitrolite/learn/core-concepts/state-channels-vs-l1-l2.mdx index 45dc5f1..c35cc85 100644 --- a/docs/nitrolite/learn/core-concepts/state-channels-vs-l1-l2.mdx +++ b/docs/nitrolite/learn/core-concepts/state-channels-vs-l1-l2.mdx @@ -140,4 +140,4 @@ State channels shine when you have identified participants who will interact fre For technical details on channel implementation: -- **[Architecture](/clearnet/architecture)** — System design and fund flows +- **[Protocol Reference](/nitrolite/protocol/protocol-reference)** — System design and fund flows diff --git a/docs/nitrolite/learn/index.mdx b/docs/nitrolite/learn/index.mdx index 3e6ea48..5ebed62 100644 --- a/docs/nitrolite/learn/index.mdx +++ b/docs/nitrolite/learn/index.mdx @@ -57,7 +57,7 @@ Detailed v1 protocol flow documentation for deposits, withdrawals, transfers, an After completing the Learn section, continue to: - **[Build](/nitrolite/build/quick-start)** — Implement complete Yellow Applications -- **[Clearnet Protocol](/clearnet/introduction)** — Authoritative protocol specification +- **[Protocol Reference](/nitrolite/protocol/protocol-reference)** — Authoritative protocol specification --- diff --git a/docs/nitrolite/learn/introduction/architecture-at-a-glance.mdx b/docs/nitrolite/learn/introduction/architecture-at-a-glance.mdx index ebbe7f4..726c096 100644 --- a/docs/nitrolite/learn/introduction/architecture-at-a-glance.mdx +++ b/docs/nitrolite/learn/introduction/architecture-at-a-glance.mdx @@ -181,7 +181,7 @@ stateDiagram-v2 ``` :::info Legacy Flow -The diagram above shows the recommended flow where both participants sign the initial state, creating the channel directly in ACTIVE status. A legacy flow also exists where only the creator signs initially (status becomes INITIAL), and other participants call `join()` separately. See the [Clearnet Protocol](/clearnet/introduction) section for details. +The diagram above shows the recommended flow where both participants sign the initial state, creating the channel directly in ACTIVE status. A legacy flow also exists where only the creator signs initially (status becomes INITIAL), and other participants call `join()` separately. See the [Protocol Reference](/nitrolite/protocol/protocol-reference) section for details. ::: ### Typical Flow diff --git a/lessons.md b/lessons.md deleted file mode 100644 index 49ec4d5..0000000 --- a/lessons.md +++ /dev/null @@ -1,9 +0,0 @@ -## Sidebar arrow-only toggle (2026-04-29) - -The sidebar uses Docusaurus's `DocSidebarItem/Category`. The `>` chevron previously visible was a CSS `::before` pseudo-element on `.menu__link--sublist` — purely decorative; clicking the row text triggered the toggle. - -To make only the chevron clickable: -1. Swizzle `src/theme/DocSidebarItem/Category/index.tsx` and always render the upstream `` (`.clean-btn.menu__caret`) before the link. Its `onClick` calls `updateCollapsed()`. The link's `onClick` only navigates (when `href`) or `preventDefault`s (when not). -2. CSS: hide the legacy `::before` arrows on `.menu__link--sublist`/`.menu__list-item-collapsible > .menu__link`, then style `.menu__list-item-collapsible > .menu__caret` as the new chevron with rotation on `[aria-expanded="true"]`. -3. Infima ships its own rotations on `.menu__caret::before` (`rotate(180deg)` default and `rotateZ(90deg)` under `.menu__list-item--collapsed`). Reset both with `transform: none !important;` on the base rule, then apply `transform: rotate(90deg)` only on `[aria-expanded="true"]`. -4. Per-item `collapsible: false` in `sidebars-*.ts` makes a category non-collapsible (no chevron rendered, `useCollapsible` returns always-expanded). Removing the override defaults to `collapsible: true`. diff --git a/src/theme/Navbar/Content/index.tsx b/src/theme/Navbar/Content/index.tsx index 3354b0a..83455a7 100644 --- a/src/theme/Navbar/Content/index.tsx +++ b/src/theme/Navbar/Content/index.tsx @@ -134,7 +134,7 @@ export default function NavbarContent(): ReactNode { const filteredItems = items.filter((item) => shouldShowItem(item, pathname)); const [leftItems, rightItems] = splitNavbarItems(filteredItems); - const searchBarItem = items.find((item) => item.type === 'search'); + const searchBarItem = filteredItems.find((item) => item.type === 'search'); const sub = currentSubsite(pathname); return (