From 69322dea1708163831f84df74ff0ec6b3a7c8592 Mon Sep 17 00:00:00 2001 From: Ekaterina Mekhnetsova Date: Thu, 2 Nov 2023 16:21:08 +0300 Subject: [PATCH] Introduce cookbook (updated init version) Signed-off-by: Ekaterina Mekhnetsova --- .vitepress/config.mts | 294 ++++++++++++++++++++++++++++++++++++++++++ src/cookbook/index.md | 3 + src/index.md | 5 +- 3 files changed, 301 insertions(+), 1 deletion(-) create mode 100644 src/cookbook/index.md diff --git a/.vitepress/config.mts b/.vitepress/config.mts index 3f0c7964a..2e7123d7e 100644 --- a/.vitepress/config.mts +++ b/.vitepress/config.mts @@ -35,6 +35,299 @@ function nav(): DefaultTheme.NavItem[] { link: '/reference/torii-endpoints', activeMatch: '/reference/', }, + { + text: 'Cookbook', + link: '/cookbook/', + activeMatch: '/cookbook/', + }, + ] +} + +function sidebarCookbook(): DefaultTheme.SidebarItem[] { + return [ + { + text: 'Access Control', + collapsed: true, + items: [ + { + text: 'Permission Tokens', + collapsed: true, + items: [], + }, + { + text: 'Roles', + collapsed: true, + items: [ + { + text: 'Register a Role', + }, + { + text: 'Grant a Role', + }, + { + text: 'Revoke a Role', + }, + ], + }, + { + text: 'Executors (Permission Validators)', + collapsed: true, + items: [ + { + text: 'Write Executor', + }, + { + text: 'Update Executor', + } + ], + } + ], + }, + { + text: 'Accounts', + collapsed: true, + items: [ + { + text: 'Register Accounts', + }, + { + text: 'Unregister Accounts', + }, + { + text: 'Update Account Metadata' + }, + // ... + ], + }, + { + text: 'Assets', + collapsed: true, + items: [ + { + text: 'Assets', // All Assets? + collapsed: true, + items: [ + { + text: 'Register Assets', + }, + { + text: 'Unregister Assets', + }, + { + text: 'Transfer Assets Between Accounts', + }, + ], + }, + { + text: 'Numeric Assets', + collapsed: true, + items: [], + }, + { + text: 'Store Assets', + collapsed: true, + items: [], + }, + { + text: 'Mintable Assets', + collapsed: true, + items: [ + { + text: 'Mint Assets', + }, + { + text: 'Mint More of a Mintable Asset', + }, + { + text: 'Burn Assets', + }, + ], + }, + { + text: 'Non-Mintable Assets', + collapsed: true, + items: [ + { + text: 'Work with Non-Mintable Assets', + }, + ], + }, + { + text: 'Tokens', + collapsed: true, + items: [ + { + text: 'Create Asset-backed Tokens', + }, + { + text: 'Create Non-Fungible Tokens (NFTs)', + }, + ], + }, + ], + }, + { + text: 'Domains', + collapsed: true, + items: [ + { + text: 'Register Domains', + }, + { + text: 'Update Domain Metadata', + }, + // ... + // access management for domains + ], + }, + { + text: 'Events and Filters', + collapsed: true, + items: [ + { + text: 'Pipeline Events', + collapsed: true, + items: [], + }, + { + text: 'Data Events', + collapsed: true, + items: [], + }, + { + text: 'Trigger Events', + collapsed: true, + items: [], + }, + { + text: 'Advanced Filtering', + collapsed: true, + items: [], + }, + { + text: 'Block Stream', + collapsed: true, + items: [ + { + text: 'Subscribe to Block Stream', + }, + { + text: 'View output', + }, + ], + }, + ], + }, + { + text: 'Instructions', + collapsed: true, + items: [ + { + text: 'Use instructions', + }, + { + text: 'Combine Instructions via Expressions', + }, + ], + }, + { + text: 'Metadata', + collapsed: true, + items: [ + { + text: 'Set Key Value', + }, + { + text: 'Remove Key Value', + }, + { + text: 'Access Metadata', + }, + ], + }, + { + text: 'Peers', + collapsed: true, + items: [ + { + text: 'Register Peers', + }, + { + text: "Check Current Peer's Load", + }, + { + text: 'Find the Leader Among Running Peers', + }, + ], + }, + { + text: 'Queries', + collapsed: true, + items: [ + {text: 'Use queries'}, + {text: 'Filter query results'}, + {text: 'Use Lazy Pagination'}, + {text: 'Query Connected Peers'}, + ], + }, + { + text: 'Telemetry', + collapsed: true, + items: [ + { + text: 'Check Status', + }, + { + text: 'Get Metrics', + }, + { + text: 'Monitor Iroha Performance', + }, + { + text: 'Check Health', + }, + ], + }, + { + text: 'Transactions', + collapsed: true, + items: [ + { + text: 'Create Transactions', + }, + { + text: 'Submit Transactions', + }, + { + text: 'Compile Transactions', + }, + { + text: 'Use Multi-Signature Transactions', + }, + ], + }, + { + text: 'Triggers', + collapsed: true, + items: [ + { + text: 'Data Triggers', + collapsed: true, + items: [], + }, + { + text: 'Time Triggers', + collapsed: true, + items: [], + }, + { + text: 'By-call Triggers', + collapsed: true, + items: [], + }, + ], + }, + ] } @@ -481,6 +774,7 @@ export default defineConfig({ sidebar: { '/guide/': sidebarGuide(), '/reference/': sidebarAPI(), + '/cookbook/': sidebarCookbook(), }, search: { diff --git a/src/cookbook/index.md b/src/cookbook/index.md new file mode 100644 index 000000000..6cb8213d5 --- /dev/null +++ b/src/cookbook/index.md @@ -0,0 +1,3 @@ +# Cookbook + +TODO \ No newline at end of file diff --git a/src/index.md b/src/index.md index 7003f3da4..babbe8b57 100644 --- a/src/index.md +++ b/src/index.md @@ -23,4 +23,7 @@ features: title: Reference details: Consult reference documentation for extensive information about available functionality link: /reference/ - # - title: Cookbook # (TBA) + - icon: 📓 + title: Cookbook + details: Find code samples and example showcasing Iroha functionality + link: /cookbook/ \ No newline at end of file