A next-generation tool to create blazing-fast documentation sites
API
created:3/5/2021
updated:3/5/2021
source lines:21
comments %:19

ComponentSource

@component-controls/blocks
3.6.1

Displays import statement for a component as well as the component file source code Optionally also displays some repository information from the component's package.json

import { ComponentSource } from '@component-controls/blocks';

Overview

import ArrowButton from '@component-controls/blocks';

Name
Description
Default
- (3 properties)
onSelect

callback to be called when the tab changes if the function returns false, it can stop chabging to the new tab

(((name: string, component: Component) => boolean | void) & ((event: SyntheticEvent<HTMLDivElement, Event>) => void))
-
ref
((instance: HTMLDivElement | null) => void) | RefObject<HTMLDivElement> | null
-
visibility

by default will show both controls and props tables user setting can display only props table or only controls

undefinedallcontrolsinfo
-
SpaceProps (28 properties)
HTMLAttributes (42 properties)
BlockContainerOwnProps (6 properties)
Attributes (2 properties)
AriaAttributes (48 properties)
DOMAttributes (160 properties)
BoxOwnProps (3 properties)
BackgroundColorProps (2 properties)
OpacityProps (1 properties)
ComponentInputProps (2 properties)
ActionContainerProps (1 properties)
SyntaxHighlighterProps (5 properties)

Commits

Date
Author
Commit Message
7/25/2020

atanasster

chore: remove react context api
7/10/2020

atanasster

feat: data-testids
6/24/2020

atanasster

chore: actionitems node renamed
6/21/2020

atanasster

fix: dark mode removed from theme context
5/10/2020

atanasster

feat: props table selectively display props, controls or both
5/7/2020

atanasster

chore: refactor repository into package info field
4/16/2020

atanasster

feat: added theme, components for PageContainer
4/1/2020

atanasster

fix: hide component source when no components
3/31/2020

atanasster

fix: various fixes
3/30/2020

atanasster

chore: refactor ComponentSource with new blocks
26 commits

package
imports
peer
SourceProps
react
^17.0.1
ReactFC
*

file
imports
"../BlockContainer/components/ComponentsBlockContainer"
ComponentsBlockContainerComponentsBlockContainerProps
"./BaseComponentSource"
BaseComponentSource

Stories

Theme

import { Button } from '../../components/button-named-arrow-func';

Title

import ArrowButton from '@component-controls/blocks';

Custom Title

import ArrowButton from '@component-controls/blocks';

Not Collapsible

import ArrowButton from '@component-controls/blocks';

No Component

import ArrowButton from '@component-controls/blocks';