import React, { PropsWithChildren } from 'react'; import { InlineCode } from '~/components/base/code'; import { B, P } from '~/components/base/paragraph'; import { H3 } from '~/components/plugins/Headings'; import { Cell, HeaderCell, Row, Table, TableHead } from '~/ui/components/Table'; type Props = PropsWithChildren<{ properties: PluginProperty[]; }>; const platformNames: Record, string> = { android: 'Android', ios: 'iOS', web: 'Web', }; export const ConfigPluginProperties = ({ children, properties }: Props) => ( <>

Configurable properties

{!!children &&

{children}

} Name Default Description {properties.map(property => ( {property.name} {!property.default ? '-' : {property.default}} {!!property.platform && {platformNames[property.platform]} only } {property.description} ))}
); export type PluginProperty = { name: string; description: string; default?: string; platform?: 'android' | 'ios' | 'web'; };