From 4522d97b5262b4f714c53f00eea091052c321803 Mon Sep 17 00:00:00 2001 From: saucepoint <98790946+saucepoint@users.noreply.github.com> Date: Mon, 16 Sep 2024 23:27:41 -0400 Subject: [PATCH] Reorganize v4 Technical Reference (#765) --- .../v4/reference/core/01-overview.mdx => 02-overview.mdx | 0 docs/contracts/v4/concepts/07-dynamic-fees.mdx | 2 +- .../contracts/v4/guides/04-hooks/{setup.mdx => 00-setup.mdx} | 0 docs/contracts/v4/guides/08-testing.mdx | 5 ----- docs/contracts/v4/reference/core/_category_.json | 2 +- .../liquidity-amounts.mdx} | 0 docs/contracts/v4/reference/core/libraries/state-library.mdx | 2 +- .../transient-state-library.mdx} | 2 +- docs/contracts/v4/reference/core/poolmanager.mdx | 3 --- docs/contracts/v4/reference/core/types/_category_.json | 5 +++++ .../core/{BalanceDelta.mdx => types/balancedelta.mdx} | 0 .../core/{BeforeSwapDelta.mdx => types/beforeswapdelta.mdx} | 0 .../v4/reference/core/{Currency.mdx => types/currency.mdx} | 0 .../v4/reference/core/{PoolKey.mdx => types/poolkey.mdx} | 0 docs/contracts/v4/reference/periphery/_category_.json | 2 +- docs/contracts/v4/reference/periphery/overview.mdx | 5 ----- docs/contracts/v4/reference/periphery/positionmanager.mdx | 4 ++-- 17 files changed, 12 insertions(+), 20 deletions(-) rename docs/contracts/v4/reference/core/01-overview.mdx => 02-overview.mdx (100%) rename docs/contracts/v4/guides/04-hooks/{setup.mdx => 00-setup.mdx} (100%) delete mode 100644 docs/contracts/v4/guides/08-testing.mdx rename docs/contracts/v4/reference/core/{LiquidityAmounts.mdx => libraries/liquidity-amounts.mdx} (100%) rename docs/contracts/v4/reference/core/{TransientStateLibrary.mdx => libraries/transient-state-library.mdx} (99%) delete mode 100644 docs/contracts/v4/reference/core/poolmanager.mdx create mode 100644 docs/contracts/v4/reference/core/types/_category_.json rename docs/contracts/v4/reference/core/{BalanceDelta.mdx => types/balancedelta.mdx} (100%) rename docs/contracts/v4/reference/core/{BeforeSwapDelta.mdx => types/beforeswapdelta.mdx} (100%) rename docs/contracts/v4/reference/core/{Currency.mdx => types/currency.mdx} (100%) rename docs/contracts/v4/reference/core/{PoolKey.mdx => types/poolkey.mdx} (100%) delete mode 100644 docs/contracts/v4/reference/periphery/overview.mdx diff --git a/docs/contracts/v4/reference/core/01-overview.mdx b/02-overview.mdx similarity index 100% rename from docs/contracts/v4/reference/core/01-overview.mdx rename to 02-overview.mdx diff --git a/docs/contracts/v4/concepts/07-dynamic-fees.mdx b/docs/contracts/v4/concepts/07-dynamic-fees.mdx index a18e6fa82..842eb2172 100644 --- a/docs/contracts/v4/concepts/07-dynamic-fees.mdx +++ b/docs/contracts/v4/concepts/07-dynamic-fees.mdx @@ -1,5 +1,5 @@ --- -title: Introduction to Dynamic Fees +title: Dynamic Fees --- Uniswap v4 introduces dynamic fees, allowing for flexible and responsive fee structures managed through hooks. This feature enables pools to adapt fees to changing market conditions, potentially improving liquidity provider profitability and overall market efficiency. diff --git a/docs/contracts/v4/guides/04-hooks/setup.mdx b/docs/contracts/v4/guides/04-hooks/00-setup.mdx similarity index 100% rename from docs/contracts/v4/guides/04-hooks/setup.mdx rename to docs/contracts/v4/guides/04-hooks/00-setup.mdx diff --git a/docs/contracts/v4/guides/08-testing.mdx b/docs/contracts/v4/guides/08-testing.mdx deleted file mode 100644 index 281920761..000000000 --- a/docs/contracts/v4/guides/08-testing.mdx +++ /dev/null @@ -1,5 +0,0 @@ ---- -title: Testing ---- - -(TODO: explain Deployers / setUp() / common operations) \ No newline at end of file diff --git a/docs/contracts/v4/reference/core/_category_.json b/docs/contracts/v4/reference/core/_category_.json index 0202f3e19..255eb73d5 100644 --- a/docs/contracts/v4/reference/core/_category_.json +++ b/docs/contracts/v4/reference/core/_category_.json @@ -1,5 +1,5 @@ { "label": "Core", "position": 1, - "collapsed": true + "collapsed": false } diff --git a/docs/contracts/v4/reference/core/LiquidityAmounts.mdx b/docs/contracts/v4/reference/core/libraries/liquidity-amounts.mdx similarity index 100% rename from docs/contracts/v4/reference/core/LiquidityAmounts.mdx rename to docs/contracts/v4/reference/core/libraries/liquidity-amounts.mdx diff --git a/docs/contracts/v4/reference/core/libraries/state-library.mdx b/docs/contracts/v4/reference/core/libraries/state-library.mdx index 76d4a4cb3..bb121d874 100644 --- a/docs/contracts/v4/reference/core/libraries/state-library.mdx +++ b/docs/contracts/v4/reference/core/libraries/state-library.mdx @@ -1,5 +1,5 @@ --- -title: StateLibrary.sol +title: StateLibrary --- (TODO: state library) \ No newline at end of file diff --git a/docs/contracts/v4/reference/core/TransientStateLibrary.mdx b/docs/contracts/v4/reference/core/libraries/transient-state-library.mdx similarity index 99% rename from docs/contracts/v4/reference/core/TransientStateLibrary.mdx rename to docs/contracts/v4/reference/core/libraries/transient-state-library.mdx index 46913660f..9df782a43 100644 --- a/docs/contracts/v4/reference/core/TransientStateLibrary.mdx +++ b/docs/contracts/v4/reference/core/libraries/transient-state-library.mdx @@ -1,5 +1,5 @@ --- -title: Transient State Library +title: TransientStateLibrary --- The `TransientStateLibrary` is a crucial component of Uniswap V4, providing utility functions for managing transient state in the PoolManager contract. This library handles operations related to reserves, delta counts, and locking state, which are essential for the efficient and secure operation of the Uniswap V4 protocol. diff --git a/docs/contracts/v4/reference/core/poolmanager.mdx b/docs/contracts/v4/reference/core/poolmanager.mdx deleted file mode 100644 index 29a8c5fce..000000000 --- a/docs/contracts/v4/reference/core/poolmanager.mdx +++ /dev/null @@ -1,3 +0,0 @@ ---- -title: PoolManager.sol ---- \ No newline at end of file diff --git a/docs/contracts/v4/reference/core/types/_category_.json b/docs/contracts/v4/reference/core/types/_category_.json new file mode 100644 index 000000000..8ef8d9321 --- /dev/null +++ b/docs/contracts/v4/reference/core/types/_category_.json @@ -0,0 +1,5 @@ +{ + "label": "Types", + "position": 1, + "collapsed": true +} diff --git a/docs/contracts/v4/reference/core/BalanceDelta.mdx b/docs/contracts/v4/reference/core/types/balancedelta.mdx similarity index 100% rename from docs/contracts/v4/reference/core/BalanceDelta.mdx rename to docs/contracts/v4/reference/core/types/balancedelta.mdx diff --git a/docs/contracts/v4/reference/core/BeforeSwapDelta.mdx b/docs/contracts/v4/reference/core/types/beforeswapdelta.mdx similarity index 100% rename from docs/contracts/v4/reference/core/BeforeSwapDelta.mdx rename to docs/contracts/v4/reference/core/types/beforeswapdelta.mdx diff --git a/docs/contracts/v4/reference/core/Currency.mdx b/docs/contracts/v4/reference/core/types/currency.mdx similarity index 100% rename from docs/contracts/v4/reference/core/Currency.mdx rename to docs/contracts/v4/reference/core/types/currency.mdx diff --git a/docs/contracts/v4/reference/core/PoolKey.mdx b/docs/contracts/v4/reference/core/types/poolkey.mdx similarity index 100% rename from docs/contracts/v4/reference/core/PoolKey.mdx rename to docs/contracts/v4/reference/core/types/poolkey.mdx diff --git a/docs/contracts/v4/reference/periphery/_category_.json b/docs/contracts/v4/reference/periphery/_category_.json index 47b990c48..bef23ca2d 100644 --- a/docs/contracts/v4/reference/periphery/_category_.json +++ b/docs/contracts/v4/reference/periphery/_category_.json @@ -1,5 +1,5 @@ { "label": "Periphery", "position": 2, - "collapsed": false + "collapsed": true } diff --git a/docs/contracts/v4/reference/periphery/overview.mdx b/docs/contracts/v4/reference/periphery/overview.mdx deleted file mode 100644 index a577d97ef..000000000 --- a/docs/contracts/v4/reference/periphery/overview.mdx +++ /dev/null @@ -1,5 +0,0 @@ ---- -title: Overview ---- - -(TODO: explain periphery and how its contracts are used) \ No newline at end of file diff --git a/docs/contracts/v4/reference/periphery/positionmanager.mdx b/docs/contracts/v4/reference/periphery/positionmanager.mdx index 23fd5725b..b27831762 100644 --- a/docs/contracts/v4/reference/periphery/positionmanager.mdx +++ b/docs/contracts/v4/reference/periphery/positionmanager.mdx @@ -1,5 +1,5 @@ --- -title: PositionManager.sol +title: PositionManager --- -(TODO: posm) \ No newline at end of file +... in progress, please see [mint position](../../guides/02-manage-liquidity/01-mint-position.mdx) \ No newline at end of file