Kaynağa Gözat

Update markdoc and allow comments

Loris Leiva 2 yıl önce
ebeveyn
işleme
fe408a1639
4 değiştirilmiş dosya ile 57 ekleme ve 36 silme
  1. 3 1
      next.config.js
  2. 2 2
      package.json
  3. 41 10
      pnpm-lock.yaml
  4. 11 23
      src/pages/token-metadata/index.md

+ 3 - 1
next.config.js

@@ -9,4 +9,6 @@ const nextConfig = {
   },
 }
 
-module.exports = withMarkdoc()(nextConfig)
+module.exports = withMarkdoc({
+  tokenizerOptions: { allowComments: true },
+})(nextConfig)

+ 2 - 2
package.json

@@ -13,8 +13,8 @@
     "@docsearch/react": "^3.2.1",
     "@headlessui/react": "^1.7.13",
     "@heroicons/react": "^2.0.18",
-    "@markdoc/markdoc": "0.1.7",
-    "@markdoc/next.js": "0.1.6",
+    "@markdoc/markdoc": "0.3.0",
+    "@markdoc/next.js": "0.2.3",
     "@sindresorhus/slugify": "^2.1.0",
     "@tailwindcss/typography": "^0.5.7",
     "autoprefixer": "^10.4.12",

+ 41 - 10
pnpm-lock.yaml

@@ -11,11 +11,11 @@ dependencies:
     specifier: ^2.0.18
     version: 2.0.18(react@18.2.0)
   '@markdoc/markdoc':
-    specifier: 0.1.7
-    version: 0.1.7
+    specifier: 0.3.0
+    version: 0.3.0(react@18.2.0)
   '@markdoc/next.js':
-    specifier: 0.1.6
-    version: 0.1.6(@markdoc/markdoc@0.1.7)(next@13.3.0)(react@18.2.0)
+    specifier: 0.2.3
+    version: 0.2.3(@markdoc/markdoc@0.3.0)(next@13.3.0)(react@18.2.0)
   '@sindresorhus/slugify':
     specifier: ^2.1.0
     version: 2.1.0
@@ -321,19 +321,31 @@ packages:
       '@jridgewell/sourcemap-codec': 1.4.14
     dev: false
 
-  /@markdoc/markdoc@0.1.7:
-    resolution: {integrity: sha512-Dz7+VP5I3m/DFpLnzjwvXv64XmneYNzy4adm5uJSkcAJxFlJujIn+hCmMh11k70w+y5Qu18sjngetpuP+3570g==}
+  /@markdoc/markdoc@0.3.0(react@18.2.0):
+    resolution: {integrity: sha512-QWCF8krIIw52ulflfnoff0yG1eKl9CCGA3KAiOjHyYtHNzSEouFh8lO52nAaO3qV2Ctj1GTB8TTb2rTfvISQfA==}
     engines: {node: '>=14.7.0'}
+    peerDependencies:
+      '@types/react': '*'
+      react: '*'
+    peerDependenciesMeta:
+      '@types/react':
+        optional: true
+      react:
+        optional: true
+    dependencies:
+      react: 18.2.0
+    optionalDependencies:
+      '@types/markdown-it': 12.2.3
     dev: false
 
-  /@markdoc/next.js@0.1.6(@markdoc/markdoc@0.1.7)(next@13.3.0)(react@18.2.0):
-    resolution: {integrity: sha512-AkILWoOg3zMrTPDubQgq5lRZ22UuFQsRn/J8oaYUYx/w8RtZ3ZACDNwX9hWVVDT3AcGokNSXaFRsQeWbmpPoFQ==}
+  /@markdoc/next.js@0.2.3(@markdoc/markdoc@0.3.0)(next@13.3.0)(react@18.2.0):
+    resolution: {integrity: sha512-O9WWGi/VHfGn70/BzqYYwsqcxidN1BpvKaO4Uf4AKC0z1d16TU0ADl/CepAeM/V2D8pDBmYALTMtiQoTWuObaw==}
     peerDependencies:
-      '@markdoc/markdoc': ^0.1.1
+      '@markdoc/markdoc': '*'
       next: '*'
       react: '*'
     dependencies:
-      '@markdoc/markdoc': 0.1.7
+      '@markdoc/markdoc': 0.3.0(react@18.2.0)
       js-yaml: 4.1.0
       next: 13.3.0(react-dom@18.2.0)(react@18.2.0)
       react: 18.2.0
@@ -774,6 +786,25 @@ packages:
     resolution: {integrity: sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==}
     dev: true
 
+  /@types/linkify-it@3.0.2:
+    resolution: {integrity: sha512-HZQYqbiFVWufzCwexrvh694SOim8z2d+xJl5UNamcvQFejLY/2YUtzXHYi3cHdI7PMlS8ejH2slRAOJQ32aNbA==}
+    dev: false
+    optional: true
+
+  /@types/markdown-it@12.2.3:
+    resolution: {integrity: sha512-GKMHFfv3458yYy+v/N8gjufHO6MSZKCOXpZc5GXIWWy8uldwfmPn98vp81gZ5f9SVw8YYBctgfJ22a2d7AOMeQ==}
+    requiresBuild: true
+    dependencies:
+      '@types/linkify-it': 3.0.2
+      '@types/mdurl': 1.0.2
+    dev: false
+    optional: true
+
+  /@types/mdurl@1.0.2:
+    resolution: {integrity: sha512-eC4U9MlIcu2q0KQmXszyn5Akca/0jrQmwDRgpAMJai7qBWq4amIQhZyNau4VYGtCeALvW1/NtjzJJ567aZxfKA==}
+    dev: false
+    optional: true
+
   /@typescript-eslint/parser@5.59.7(eslint@8.26.0)(typescript@5.0.4):
     resolution: {integrity: sha512-VhpsIEuq/8i5SF+mPg9jSdIwgMBBp0z9XqjiEay+81PYLJuroN+ET1hM5IhkiYMJd9MkTz8iJLt7aaGAgzWUbQ==}
     engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0}

+ 11 - 23
src/pages/token-metadata/index.md

@@ -8,13 +8,9 @@ The Token Metadata program is a fundamental program when dealing NFTs and Fungib
 
 {% quick-links %}
 
-{% quick-link title="Installation" icon="InboxArrowDown" href="/" description="Step-by-step guides to setting up your system and installing the library." /%}
+{% quick-link title="Getting Started" icon="InboxArrowDown" href="/token-metadata/getting-started" description="Find the language or library of your choice and get started with digital assets on Solana." /%}
 
-{% quick-link title="Architecture guide" icon="CubeTransparent" href="/" description="Learn how the internals work and contribute." /%}
-
-{% quick-link title="Plugins" icon="SquaresPlus" href="/" description="Extend the library with third-party plugins or write your own." /%}
-
-{% quick-link title="API reference" icon="CodeBracketSquare" href="/" description="Learn to easily customize and modify your app's visual design to fit your brand." /%}
+{% quick-link title="API reference" icon="CodeBracketSquare" href="/token-metadata/references" description="Looking for something specific? Have a peak at our API References and find your answer." /%}
 
 {% /quick-links %}
 
@@ -484,21 +480,13 @@ You can [read more about Programmable NFTs here](https://github.com/metaplex-fou
 
 Whilst this provides a good overview of the Token Metadata program and what it has to offer, there’s still a lot more that can be done with it.
 
-The other pages of the “Token Metadata” section aim to document it further and explain significant features in their own individual pages.
-
-The next three pages focus on helping you get started with the Token Metadata program and provide detailed information on the accounts and instructions it provides, so you get the full picture and can refer back to them in the future.
-
-- [Getting started](/token-metadata/getting-started)
-- [Accounts](/token-metadata/accounts)
-- [Instructions](/token-metadata/instructions)
-
-The next pages act as in-depth guides on certain features offered by the program.
-
-- [Token Standard](/token-metadata/token-standard)
-- [Certified Collections](/token-metadata/certified-collections)
-- [Using NFTs](/token-metadata/using-nfts)
-
-Finally, the last two pages answer frequently asked questions and document version updates.
+The other pages of this documentation aim to document it further and explain significant features in their own individual pages.
 
-- [FAQ](/token-metadata/faq)
-- [Changelog](/token-metadata/changelog/)
+- [TODO](/token-metadata/TODO)
+- [TODO](/token-metadata/TODO)
+- [TODO](/token-metadata/TODO)
+- [TODO](/token-metadata/TODO)
+- [TODO](/token-metadata/TODO)
+- [TODO](/token-metadata/TODO)
+- [TODO](/token-metadata/TODO)
+- [TODO](/token-metadata/TODO)