Skip to content

Commit fe89449

Browse files
Sacha Lanskyjonnysmillie
andauthored
Add banners and warnings (#2069)
* add warning to pallet macros section * add warning about genesis configuration * remove custom weight guides * remove landing pg links for deleted weight guides * fix broken links * update warning styles --------- Co-authored-by: jonnysmillie <[email protected]>
1 parent df7ccad commit fe89449

File tree

14 files changed

+26
-255
lines changed

14 files changed

+26
-255
lines changed

content/md/en/docs/build/genesis-configuration.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,11 @@ description:
44
keywords:
55
---
66

7+
<div class="warning">
8+
<strong>⚠️ WARNING:</strong> This page contains outdated information. Please refer to the <a href="https://paritytech.github.io/polkadot-sdk/master/frame_support/pallet_macros/attr.genesis_build.html">Rust docs</a> for the most up-to-date documentation on this topic.
9+
</div>
10+
11+
712
The first block produced by any blockchain is referred to as the genesis block.
813
The hash associated with this block is the top-level parent of all blocks produced after that first block.
914

content/md/en/docs/learn/light-clients-in-substrate-connect.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ A few of the key benefits include:
4343

4444
You can use Substrate Connect to connect to any Substrate-based blockchain.
4545
However, you must specify the correct name of the chain that you want to connect to.
46-
There are a few well-known chain names that are defined for the [`WellKnownChain`](https://paritytech.github.io/substrate-connect/api/enums/connect_src.WellKnownChain.html) enumeration type.
46+
There are a few well-known chain names that are defined for the [`WellKnownChain`](https://paritytech.github.io/substrate-connect/api/enums/_substrate_connect.WellKnownChain.html) enumeration type.
4747

4848
You can connect to the following public blockchain networks using the name listed:
4949

content/md/en/docs/reference/frame-macros.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ title: FRAME macros
33
description:
44
keywords:
55
---
6+
<div class="warning">
7+
<strong>⚠️ WARNING:</strong> This section contains outdated information. Please refer to the <a href="https://paritytech.github.io/polkadot-sdk/master/frame_support/attr.pallet.html">Rust docs</a> for the most up-to-date documentation on this topic.
8+
</div>
69

710
Substrate uses customized [Rust macros](https://doc.rust-lang.org/book/ch19-06-macros.html) to generate code and aggregate the logic from the pallets you implement for a runtime.
811
These runtime macros allow you to focus on your runtime logic rather than spending time on encoding and decoding on-chain variables or duplicating the code required for [basic blockchain development](/learn/runtime-development#core-primitives).
@@ -391,9 +394,9 @@ $vis type $StorageName<$some_generic> $optional_where_clause
391394

392395
For more information, see the Rust documentation for [pallet::storage](https://paritytech.github.io/substrate/master/frame_support/attr.pallet.html#storage-palletstorage-optional) and the following storage data structures:
393396

394-
- [StorageDoubleMap](https://paritytech.github.io/substrate/master/frame_support/pallet_prelude/struct.StorageDoubleMap.html)
395-
- [StorageMap](https://paritytech.github.io/substrate/master/frame_support/pallet_prelude/struct.StorageMap.html#implementations)
396-
- [StorageValue](https://paritytech.github.io/substrate/master/frame_support/pallet_prelude/struct.StorageValue.html)
397+
- [StorageDoubleMap](https://paritytech.github.io/polkadot-sdk/master/frame_support/storage/types/struct.StorageDoubleMap.html)
398+
- [StorageMap](https://paritytech.github.io/polkadot-sdk/master/frame_support/storage/types/struct.StorageMap.html)
399+
- [StorageValue](https://paritytech.github.io/polkadot-sdk/master/frame_support/storage/types/struct.StorageValue.html)
397400

398401
### #[pallet::type_value]
399402

content/md/en/docs/reference/how-to-guides/consensus-models/create-a-hybrid-node.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ Customize the consensus mechanisms of a Substrate chain.
2929
We begin by creating the block import for Grandpa.
3030
In addition to the block import itself, we get back a `grandpa_link`.
3131
This link is a channel over which the block import can communicate with the background task that actually casts Grandpa votes.
32-
The [details of the Grandpa protocol](https://research.web3.foundation/en/latest/polkadot/finality.html) are beyond the scope of this guide.
32+
The [details of the Grandpa protocol](https://research.web3.foundation/Polkadot/protocols/finality) are beyond the scope of this guide.
3333

3434
In `node/src/service.rs`, create the Grandpa block import:
3535

content/md/en/docs/reference/how-to-guides/index.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,6 @@ See the following guides for help with benchmarking and weight configurations.
3434

3535
- [Calculate fees](/reference/how-to-guides/weights/calculate-fees/)
3636
- [Add benchmarks](/reference/how-to-guides/weights/add-benchmarks/)
37-
- [Use custom weights](/reference/how-to-guides/weights/use-custom-weights/)
38-
- [Use conditional weights](/reference/how-to-guides/weights/use-conditional-weights/)
3937

4038
## Testing
4139

content/md/en/docs/reference/how-to-guides/pallet-design/implement-lockable-currency.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ keywords:
99
---
1010

1111
This guide shows you how to write a pallet that allows users to lock funds for staking and voting.
12-
The [`LockableCurrency`](https://paritytech.github.io/substrate/master/frame_support/traits/trait.LockableCurrency.html) trait is useful in the context of economic systems that enforce accountability by collateralizing fungible resources.
12+
The [`LockableCurrency`](https://paritytech.github.io/polkadot-sdk/master/frame_support/traits/tokens/currency/trait.LockableCurrency.html) trait is useful in the context of economic systems that enforce accountability by collateralizing fungible resources.
1313
You can use the Substrate [staking pallet](https://paritytech.github.io/substrate/master/pallet_staking/index.html) to manage locked funds in time-based increments.
1414

1515
In this guide, we will implement the `set_lock`, `extend_lock` and `remove_lock` methods in our own custom pallet.
@@ -22,7 +22,7 @@ You can use the template pallet in the [node template](https://github.com/substr
2222

2323
## Declare the necessary dependencies
2424

25-
The methods from [`LockableCurrency`](https://paritytech.github.io/substrate/master/frame_support/traits/trait.LockableCurrency.html) require us to import a few traits from `frame_support`.
25+
The methods from [`LockableCurrency`](https://paritytech.github.io/polkadot-sdk/master/frame_support/traits/tokens/currency/trait.LockableCurrency.html) require us to import a few traits from `frame_support`.
2626

2727
1. Ensure you have the following traits imported in the top section of your pallet:
2828

@@ -162,5 +162,5 @@ The required methods are:
162162
## Related material
163163

164164
- [Currency trait](https://paritytech.github.io/substrate/master/frame_support/traits/tokens/currency/trait.Currency.html)
165-
- [LockableCurrency](https://paritytech.github.io/substrate/master/frame_support/traits/trait.LockableCurrency.html)
166-
- [LockIdentifier](https://paritytech.github.io/substrate/master/frame_support/traits/type.LockIdentifier.html)
165+
- [LockableCurrency](https://paritytech.github.io/polkadot-sdk/master/frame_support/traits/tokens/currency/trait.LockableCurrency.html)
166+
- [LockIdentifier](https://paritytech.github.io/polkadot-sdk/master/frame_support/traits/tokens/currency/type.LockIdentifier.html)

content/md/en/docs/reference/how-to-guides/parachains/connect-to-a-relay-chain.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -180,8 +180,8 @@ pub const fn deposit(items: u32, bytes: u32) -> Balance {}
180180
You can find this function for each relay chain in the Polkadot repository.
181181
For example:
182182

183-
- [Kusama](https://github.com/paritytech/polkadot-sdk/blob/master/polkadot/runtime/kusama/constants/src/lib.rs)
184-
- [Polkadot](https://github.com/paritytech/polkadot-sdk/blob/master/polkadot/runtime/polkadot/constants/src/lib.rs)
183+
- [Kusama](https://github.com/polkadot-fellows/runtimes/blob/main/relay/kusama/constants/src/lib.rs)
184+
- [Polkadot](https://github.com/polkadot-fellows/runtimes/blob/main/relay/polkadot/constants/src/lib.rs)
185185
- [Rococo](https://github.com/paritytech/polkadot-sdk/blob/master/polkadot/runtime/rococo/constants/src/lib.rs)
186186
- [Westend](https://github.com/paritytech/polkadot-sdk/blob/master/polkadot/runtime/westend/constants/src/lib.rs)
187187

content/md/en/docs/reference/how-to-guides/weights/index.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,3 @@ The _How-to_ guides in the _Weights_ category illustrate use benchmarks and weig
88

99
- [Calculate fees](/reference/how-to-guides/weights/calculate-fees/)
1010
- [Add benchmarks](/reference/how-to-guides/weights/add-benchmarks/)
11-
- [Use custom weights](/reference/how-to-guides/weights/use-custom-weights/)
12-
- [Use conditional weights](/reference/how-to-guides/weights/use-conditional-weights/)

content/md/en/docs/reference/how-to-guides/weights/use-conditional-weights.md

Lines changed: 0 additions & 124 deletions
This file was deleted.

content/md/en/docs/reference/how-to-guides/weights/use-custom-weights.md

Lines changed: 0 additions & 113 deletions
This file was deleted.

0 commit comments

Comments
 (0)