Skip to content

Commit

Permalink
minor fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
gagdiez committed Oct 24, 2023
2 parents 49116b8 + 1b719ae commit d24c7fd
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 21 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
id: additional-sources
title: Additional Sources
id: additional-resources
title: Additional Resources
hide_table_of_contents: false
---

Expand Down
6 changes: 0 additions & 6 deletions docs/7.primitives/nft/interacting/bos.md
Original file line number Diff line number Diff line change
Expand Up @@ -438,8 +438,6 @@ This snippet will enable your users to transfer NFTs in one of the NFT solutions
<Tabs>
<TabItem value="NFT Primitive" label="NFT Primitive" default>

By calling a smart contract method

```js
const tokenData = Near.call("nft.primitives.near", "nft_transfer", {
token_id: "1",
Expand All @@ -451,8 +449,6 @@ const tokenData = Near.call("nft.primitives.near", "nft_transfer", {

<TabItem value="Paras" label="Paras">

By calling a smart contract method

```js
const tokenData = Near.call("x.paras.near", "nft_transfer", {
token_id: "490641",
Expand All @@ -464,8 +460,6 @@ const tokenData = Near.call("x.paras.near", "nft_transfer", {

<TabItem value="Mintbase" label="Mintbase">

By calling a smart contract method

```js
const tokenData = Near.call("thomasettorreiv.mintbase1.near", "nft_transfer", {
token_id: "490641",
Expand Down
8 changes: 0 additions & 8 deletions docs/7.primitives/nft/interacting/near-cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ This section shows how to interact with an NFT contract from your shell using [`
<Tabs>
<TabItem value="NFT Primitive" label="NFT Primitive" default>

By calling a smart contract method

```bash
near call nft.primitives.near nft_mint, '{"token_id": "1", "receiver_id": "bob.near", "token_metadata": {"title": "NFT Primitive Token", "description": "Awesome NFT Primitive Token", "media": "string"}}' --accountId bob.near
```
Expand All @@ -26,8 +24,6 @@ near call nft.primitives.near nft_mint, '{"token_id": "1", "receiver_id": "bob.n

<TabItem value="Paras" label="Paras">

By calling a smart contract method

```bash
near call x.paras.near nft_mint '{"token_series_id": "490641", "receiver_id": "bob.near"}' --accountId bob.near
```
Expand Down Expand Up @@ -281,8 +277,6 @@ Usually, a basic NFT contract following [the NEP-171 and NEP-177 standards](http

<TabItem value="Paras" label="Paras">

By calling a smart contract method

In order to put a NFT for a sale on Paras you need to do two actions: cover data storage costs in `marketplace.paras.near` contract (by calling the `storage_deposit` method) and add a marketplace contract address as approved one in your NFT contract (by calling the `nft_approve` method).

There is an example how to do it:
Expand All @@ -299,8 +293,6 @@ Method `nft_approve` of a NFT contract also calls the `nft_on_approve` method in

<TabItem value="Mintbase" label="Mintbase">

By calling a smart contract method

In order to put a NFT for a sale on Mintbase you need to do two actions: cover data storage costs in `simple.market.mintbase1.near` contract (by calling the `deposit_storage` method) and add a marketplace contract address as approved one in your NFT contract (by calling the `nft_approve` method).

There is an example how to do it:
Expand Down
3 changes: 3 additions & 0 deletions docs/7.primitives/nft/interacting/smart-contract.md
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,9 @@ impl Contract {
}
}
```

---

## List a NFT up for a sale

Due to the specifics of putting a token up for sale on a NFT marketplace (more precisely, the need for the owner of the token to sign an approval transaction), you need to do this on the client side.
Expand Down
13 changes: 9 additions & 4 deletions docs/7.primitives/nft/interacting/web-app.md
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,8 @@ export const MintComponent = ({ media, reference, contractAddress, owner }: Mint
</TabItem>
</Tabs>

---

## Buy a NFT

<Tabs>
Expand Down Expand Up @@ -247,6 +249,8 @@ export const BuyComponent = ({ contractAddress, price, tokenId, affiliateAccount
</TabItem>
</Tabs>

---

## Query NFT data

<Tabs>
Expand Down Expand Up @@ -571,6 +575,8 @@ console.log(data.tokenData[0]) // => token metadata
</TabItem>
</Tabs>

---

## Transfer a NFT

<Tabs>
Expand Down Expand Up @@ -598,8 +604,6 @@ await wallet.callMethod({

<TabItem value="Paras" label="Paras">

By calling a smart contract method

```js
import { Wallet } from './near-wallet';

Expand Down Expand Up @@ -678,6 +682,8 @@ const TransferComponent = ({ tokenId, contractAddress }: TransferArgs): JSX.Elem
</TabItem>
</Tabs>

---

## List a NFT up for a sale

Usually, a basic NFT contract following [the NEP-171 and NEP-177 standards](https://nomicon.io/Standards/Tokens/NonFungibleToken) doesn't implement marketplace functionality such as listing NFT up for a sale. For this purpose, there are special marketplaces in the ecosystem, like [Paras](https://paras.id/) or [Mintbase](https://www.mintbase.xyz/). They use dedicated marketplace contracts (e.g., `marketplace.paras.near` or `simple.market.mintbase1.near`).
Expand Down Expand Up @@ -803,5 +809,4 @@ export const ListComponent = ({ contractAddress, marketAddress , tokenId, price
```

</TabItem>
</Tabs>

</Tabs>
2 changes: 1 addition & 1 deletion website/sidebars.json
Original file line number Diff line number Diff line change
Expand Up @@ -378,7 +378,7 @@
"primitives/nft/interacting/near-cli"
]
},
"primitives/nft/additional-sources",
"primitives/nft/additional-resources",
{
"type": "html",
"value": "<hr/>"
Expand Down

0 comments on commit d24c7fd

Please sign in to comment.