-
Notifications
You must be signed in to change notification settings - Fork 5
Huge restructure to update taxonomy #19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
For an update, I am currently working on trying out to implement sidebar tabbed groups like you can see on the docs.astro.build site. This is the structure I'm playing with, which feels pretty good. First arg is an id which is used for i18n of the labels, pulled from a js/json file. import { portal, tab, group } from './config/sidebar.js';
export const sidebar = [
// Scripting Portal
portal('script', {
items: [
tab('script.introduction', {
autogenerate: { directory: 'script/getting-started' },
}),
tab('script.guidebook', {
items: [
group('script.guidebook.features', { autogenerate: { directory: 'script/features' }}),
group('script.guidebook.guides', { slug: 'script/guides' }),
group('script.guidebook.recipes', { slug: 'script/recipes' }),
]
}),
tab('script.language-slua', {
collapsed: false,
autogenerate: { directory: 'script/slua' },
}),
tab('script.language-lsl', {
collapsed: true,
autogenerate: { directory: 'script/lsl' },
}),
tab('script.reference', {
collapsed: false,
items: [
group('script.reference.categories', { slug: 'script/reference/categories' }),
group('script.reference.events', { slug: 'script/reference/events' }),
group('script.reference.constants', { slug: 'script/reference/constants' }),
group('script.reference.stdlib', {
collapsed: false,
autogenerate: { directory: 'script/reference/standard-library' },
}),
group('script.reference.luau', {
collapsed: false,
autogenerate: { directory: 'script/reference/luau' },
}),
group('script.reference.lsl', {
collapsed: true,
autogenerate: { directory: 'script/reference/lsl' },
}),
]
}),
]
})
]; |
|
Sidebar has been split and tabbed! So all this functionality combines:
The multi-sidebar allows us to split the create site into separate portals. Preview: https://martin-pitt.github.io/create/script/ To be honest there is still some finessing to be done. Also I didn't get around to testing and implementing the site-wide SLua/LSL toggle — Sometimes I'm not sure we need it but then realise we really, really do. There are a lot of aspects this would affect, for example the Guides and Recipes sections could potentially have tons of the older LSL resources and also new SLua things. It would not be realistic to create SLua and LSL versions for everything or there may be incompatibilities. It wouldn't make sense how to do something related to turning tables into rich data structures make any sense for someone looking for something on LSL. Anyway. The point is, I'm going to flag this PR ready for review because this is a huge change and it is better to have it earlier in than later as it could introduce more and more merge conflicts. |
|
this isn't bad but you have to remember the website won't just be for scripting so the grouped tabs don't feel right |
|
Yeah not really happy with the grouped tabs either, I've got a new menu layout that I'm playing with that could work instead though. Multi sidebars is specifically required to do the other portals though like building or mesh etc |
Work in progress for updating to a new structure per #15