docs: make generate work

This commit is contained in:
Benjamin Canac
2024-09-24 17:53:21 +02:00
parent d921b764de
commit b7f9422091
10 changed files with 41 additions and 28 deletions

View File

@@ -9,8 +9,8 @@ const name = camelCase(route.params.slug?.[route.params.slug.length - 1] ?? '')
const strippedCompoundVariants = ref(false)
function stripCompoundVariants(component: any) {
if (component.compoundVariants) {
function stripCompoundVariants(component?: any) {
if (component?.compoundVariants) {
component.compoundVariants = component.compoundVariants.filter((compoundVariant: any) => {
if (compoundVariant.color) {
if (!['primary', 'gray'].includes(compoundVariant.color)) {