@primer/react-brand 0.20.0 → 0.20.1-rc.936afc7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/Accordion/Accordion.d.ts +5 -5
- package/lib/ActionMenu/ActionMenu.d.ts +5 -5
- package/lib/AnchorNav/AnchorNav.d.ts +4 -4
- package/lib/Avatar/Avatar.d.ts +6 -6
- package/lib/Button/Button.d.ts +4 -4
- package/lib/ButtonGroup/ButtonGroup.d.ts +2 -2
- package/lib/CTABanner/CTABanner.d.ts +5 -3
- package/lib/Card/Card.d.ts +9 -9
- package/lib/ComparisonTable/ComparisonTable.d.ts +4 -4
- package/lib/ExpandableArrow/ExpandableArrow.d.ts +1 -1
- package/lib/FAQ/FAQ.d.ts +5 -5
- package/lib/Grid/Grid.d.ts +4 -4
- package/lib/Heading/Heading.d.ts +10 -10
- package/lib/Hero/Hero.d.ts +5 -5
- package/lib/Image/Image.d.ts +2 -2
- package/lib/InlineLink/InlineLink.d.ts +4 -4
- package/lib/Label/Label.d.ts +4 -4
- package/lib/LayoutExamples/KitchenSink.d.ts +1 -1
- package/lib/LayoutExamples/Resources.d.ts +1 -1
- package/lib/Link/Link.d.ts +1 -1
- package/lib/MinimalFooter/MinimalFooter.d.ts +4 -4
- package/lib/MonaSans/MonaSans.d.ts +1 -1
- package/lib/Pillar/Pillar.d.ts +7 -7
- package/lib/River/River.d.ts +5 -5
- package/lib/SectionIntro/SectionIntro.d.ts +5 -5
- package/lib/Stack/Stack.d.ts +9 -9
- package/lib/SubdomainNavBar/SubdomainNavBar.d.ts +5 -5
- package/lib/SubdomainNavBar/useVisibilityObserver.d.ts +1 -1
- package/lib/Testimonial/Testimonial.d.ts +10 -10
- package/lib/Text/Text.d.ts +8 -8
- package/lib/ThemeProvider/ThemeProvider.d.ts +3 -3
- package/lib/animation/Animate/Animate.d.ts +1 -1
- package/lib/animation/AnimationProvider/AnimationProvider.d.ts +7 -7
- package/lib/component-helpers.d.ts +3 -3
- package/lib/css/main.css +32 -31
- package/lib/design-tokens/css/tokens/base/colors/color-scales-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/base/colors/color-scales.css +1 -1
- package/lib/design-tokens/css/tokens/base/size/size.css +1 -1
- package/lib/design-tokens/css/tokens/base/typography/typography.css +1 -1
- package/lib/design-tokens/css/tokens/functional/animation/base.css +1 -1
- package/lib/design-tokens/css/tokens/functional/colors/global-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/colors/global.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/accordion/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/action-menu/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/anchor-nav/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/button/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/card/base.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/card/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/card/colors.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/comparison-table/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/control/base.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/control/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/cta-banner/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/faq/base.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/faq/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/faq/colors.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/footer/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/footer/colors.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/grid/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/grid/colors.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/grid/grid.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/hero/base.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/image/base.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/inline-link/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/inline-link/colors.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/label/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/label/colors.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/pillar/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/pillar/colors.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/river/base.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/river/river.css +1 -1
- package/lib/design-tokens/css/tokens/functional/components/subdomain-nav-bar/colors-with-modes.css +1 -1
- package/lib/design-tokens/css/tokens/functional/size/border.css +1 -1
- package/lib/design-tokens/css/tokens/functional/size/breakpoints.css +1 -1
- package/lib/design-tokens/css/tokens/functional/size/size-coarse.css +3 -2
- package/lib/design-tokens/css/tokens/functional/size/size-fine.css +3 -2
- package/lib/design-tokens/css/tokens/functional/size/size.css +1 -1
- package/lib/design-tokens/css/tokens/functional/typography/typography-responsive.css +1 -1
- package/lib/design-tokens/css/tokens/functional/typography/typography.css +1 -1
- package/lib/design-tokens/js/module/tokens/base/colors/color-scales.js +2 -2
- package/lib/design-tokens/js/module/tokens/base/size/size.js +2 -2
- package/lib/design-tokens/js/module/tokens/base/typography/typography.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/animation/base.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/colors/global.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/card/base.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/card/colors.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/control/base.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/faq/base.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/faq/colors.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/footer/colors.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/grid/colors.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/grid/grid.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/hero/base.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/image/base.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/inline-link/colors.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/label/colors.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/pillar/colors.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/river/base.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/components/river/river.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/size/border.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/size/breakpoints.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/size/size-coarse.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/size/size-fine.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/size/size.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/size/viewport.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/typography/typography-responsive.js +2 -2
- package/lib/design-tokens/js/module/tokens/functional/typography/typography.js +2 -2
- package/lib/design-tokens/js/tokens/base/colors/color-scales.js +2 -2
- package/lib/design-tokens/js/tokens/base/size/size.js +2 -2
- package/lib/design-tokens/js/tokens/base/typography/typography.js +2 -2
- package/lib/design-tokens/js/tokens/functional/animation/base.js +2 -2
- package/lib/design-tokens/js/tokens/functional/colors/global.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/card/base.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/card/colors.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/control/base.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/faq/base.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/faq/colors.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/footer/colors.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/grid/colors.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/grid/grid.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/hero/base.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/image/base.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/inline-link/colors.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/label/colors.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/pillar/colors.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/river/base.js +2 -2
- package/lib/design-tokens/js/tokens/functional/components/river/river.js +2 -2
- package/lib/design-tokens/js/tokens/functional/size/border.js +2 -2
- package/lib/design-tokens/js/tokens/functional/size/breakpoints.js +2 -2
- package/lib/design-tokens/js/tokens/functional/size/size-coarse.js +2 -2
- package/lib/design-tokens/js/tokens/functional/size/size-fine.js +2 -2
- package/lib/design-tokens/js/tokens/functional/size/size.js +2 -2
- package/lib/design-tokens/js/tokens/functional/size/viewport.js +2 -2
- package/lib/design-tokens/js/tokens/functional/typography/typography-responsive.js +2 -2
- package/lib/design-tokens/js/tokens/functional/typography/typography.js +2 -2
- package/lib/design-tokens/scss/tokens/base/colors/color-scales.scss +136 -0
- package/lib/design-tokens/scss/tokens/base/size/size.scss +21 -0
- package/lib/design-tokens/scss/tokens/base/typography/typography.scss +11 -0
- package/lib/design-tokens/scss/tokens/functional/animation/base.scss +27 -0
- package/lib/design-tokens/scss/tokens/functional/colors/global.scss +30 -0
- package/lib/design-tokens/scss/tokens/functional/components/card/base.scss +8 -0
- package/lib/design-tokens/scss/tokens/functional/components/card/colors.scss +33 -0
- package/lib/design-tokens/scss/tokens/functional/components/control/base.scss +15 -0
- package/lib/design-tokens/scss/tokens/functional/components/faq/base.scss +6 -0
- package/lib/design-tokens/scss/tokens/functional/components/faq/colors.scss +5 -0
- package/lib/design-tokens/scss/tokens/functional/components/footer/colors.scss +5 -0
- package/lib/design-tokens/scss/tokens/functional/components/grid/colors.scss +5 -0
- package/lib/design-tokens/scss/tokens/functional/components/grid/grid.scss +7 -0
- package/lib/design-tokens/scss/tokens/functional/components/hero/base.scss +6 -0
- package/lib/design-tokens/scss/tokens/functional/components/image/base.scss +5 -0
- package/lib/design-tokens/scss/tokens/functional/components/inline-link/colors.scss +6 -0
- package/lib/design-tokens/scss/tokens/functional/components/label/colors.scss +28 -0
- package/lib/design-tokens/scss/tokens/functional/components/pillar/colors.scss +18 -0
- package/lib/design-tokens/scss/tokens/functional/components/river/base.scss +6 -0
- package/lib/design-tokens/scss/tokens/functional/components/river/river.scss +6 -0
- package/lib/design-tokens/scss/tokens/functional/size/border.scss +14 -0
- package/lib/design-tokens/scss/tokens/functional/size/breakpoints.scss +10 -0
- package/lib/design-tokens/scss/tokens/functional/size/size-coarse.scss +7 -0
- package/lib/design-tokens/scss/tokens/functional/size/size-fine.scss +7 -0
- package/lib/design-tokens/scss/tokens/functional/size/size.scss +49 -0
- package/lib/design-tokens/scss/tokens/functional/size/viewport.scss +10 -0
- package/lib/design-tokens/scss/tokens/functional/typography/typography-responsive.scss +8 -0
- package/lib/design-tokens/scss/tokens/functional/typography/typography.scss +62 -0
- package/lib/design-tokens/ts/tokens/base/colors/color-scales.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/base/colors/color-scales.js +3 -1
- package/lib/design-tokens/ts/tokens/base/size/size.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/base/size/size.js +3 -1
- package/lib/design-tokens/ts/tokens/base/typography/typography.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/base/typography/typography.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/animation/base.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/animation/base.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/colors/global.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/colors/global.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/card/base.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/card/base.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/card/colors.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/card/colors.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/control/base.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/control/base.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/faq/base.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/faq/base.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/faq/colors.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/faq/colors.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/footer/colors.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/footer/colors.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/grid/colors.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/grid/colors.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/grid/grid.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/grid/grid.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/hero/base.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/hero/base.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/image/base.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/image/base.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/inline-link/colors.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/inline-link/colors.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/label/colors.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/label/colors.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/pillar/colors.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/pillar/colors.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/river/base.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/river/base.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/components/river/river.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/components/river/river.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/size/border.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/size/border.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/size/breakpoints.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/size/breakpoints.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/size/size-coarse.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/size/size-coarse.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/size/size-fine.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/size/size-fine.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/size/size.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/size/size.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/size/viewport.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/size/viewport.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/typography/typography-responsive.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/typography/typography-responsive.js +3 -1
- package/lib/design-tokens/ts/tokens/functional/typography/typography.d.ts +4 -2
- package/lib/design-tokens/ts/tokens/functional/typography/typography.js +3 -1
- package/lib/forms/Checkbox/Checkbox.d.ts +2 -2
- package/lib/forms/FormControl/FormControl.d.ts +5 -4
- package/lib/forms/Radio/Radio.d.ts +2 -2
- package/lib/forms/Select/Select.d.ts +4 -4
- package/lib/forms/TextInput/TextInput.d.ts +8 -6
- package/lib/forms/Textarea/Textarea.d.ts +2 -2
- package/lib/forms/form-types.d.ts +2 -2
- package/lib/hooks/useResizeObserver.d.ts +1 -1
- package/lib/hooks/useWindowSize.d.ts +1 -1
- package/lib/index.js +1 -1
- package/lib/list/ListItem/ListItem.d.ts +1 -1
- package/lib/list/OrderedList/OrderedList.d.ts +1 -1
- package/lib/list/UnorderedList/UnorderedList.d.ts +1 -1
- package/package.json +24 -24
|
@@ -4,18 +4,18 @@ import type { BaseProps } from '../component-helpers';
|
|
|
4
4
|
* Design tokens
|
|
5
5
|
*/
|
|
6
6
|
import '@primer/brand-primitives/lib/design-tokens/css/tokens/functional/components/accordion/colors-with-modes.css';
|
|
7
|
-
export
|
|
7
|
+
export type AccordionRootProps = BaseProps<HTMLDetailsElement> & {
|
|
8
8
|
open?: boolean;
|
|
9
9
|
children: React.ReactElement<AccordionHeadingProps | AccordionContentProps>[];
|
|
10
10
|
} & React.HTMLAttributes<HTMLDetailsElement>;
|
|
11
|
-
export declare const AccordionRoot: React.ForwardRefExoticComponent<Pick<AccordionRootProps, "children" | "className" | "id" | "animate" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "open"> & React.RefAttributes<HTMLDetailsElement>>;
|
|
12
|
-
|
|
11
|
+
export declare const AccordionRoot: React.ForwardRefExoticComponent<Pick<AccordionRootProps, "children" | "className" | "id" | "animate" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "nonce" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "content" | "datatype" | "inlist" | "prefix" | "property" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "open"> & React.RefAttributes<HTMLDetailsElement>>;
|
|
12
|
+
type AccordionHeadingProps = BaseProps<HTMLHeadingElement> & {
|
|
13
13
|
className?: string;
|
|
14
14
|
children: string;
|
|
15
15
|
as?: 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
|
|
16
16
|
};
|
|
17
17
|
export declare const AccordionHeading: React.ForwardRefExoticComponent<Pick<AccordionHeadingProps, "children" | "className" | "id" | "animate" | "as"> & React.RefAttributes<HTMLHeadingElement>>;
|
|
18
|
-
|
|
18
|
+
type AccordionContentProps = BaseProps<HTMLElement> & {
|
|
19
19
|
className?: string;
|
|
20
20
|
children: React.ReactElement | React.ReactElement[];
|
|
21
21
|
};
|
|
@@ -23,7 +23,7 @@ export declare function AccordionContent({ children, className, ...rest }: Accor
|
|
|
23
23
|
/**
|
|
24
24
|
* Branded Accordion component
|
|
25
25
|
*/
|
|
26
|
-
export declare const Accordion: React.ForwardRefExoticComponent<Pick<AccordionRootProps, "children" | "className" | "id" | "animate" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "open"> & React.RefAttributes<HTMLDetailsElement>> & {
|
|
26
|
+
export declare const Accordion: React.ForwardRefExoticComponent<Pick<AccordionRootProps, "children" | "className" | "id" | "animate" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "nonce" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "content" | "datatype" | "inlist" | "prefix" | "property" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "open"> & React.RefAttributes<HTMLDetailsElement>> & {
|
|
27
27
|
Content: typeof AccordionContent;
|
|
28
28
|
Heading: React.ForwardRefExoticComponent<Pick<AccordionHeadingProps, "children" | "className" | "id" | "animate" | "as"> & React.RefAttributes<HTMLHeadingElement>>;
|
|
29
29
|
};
|
|
@@ -4,7 +4,7 @@ import type { BaseProps } from '../component-helpers';
|
|
|
4
4
|
* Design tokens
|
|
5
5
|
*/
|
|
6
6
|
import '@primer/brand-primitives/lib/design-tokens/css/tokens/functional/components/action-menu/colors-with-modes.css';
|
|
7
|
-
|
|
7
|
+
type ActionMenuProps = {
|
|
8
8
|
/**
|
|
9
9
|
* The content of the ActionMenu. Must be an ActionMenu.Button and an ActionMenu.Overlay
|
|
10
10
|
*/
|
|
@@ -37,7 +37,7 @@ declare type ActionMenuProps = {
|
|
|
37
37
|
*/
|
|
38
38
|
menuAlignment?: 'start' | 'end';
|
|
39
39
|
} & BaseProps<HTMLDivElement>;
|
|
40
|
-
|
|
40
|
+
type ActionMenuButtonProps = PropsWithChildren<Ref<HTMLButtonElement>> & {
|
|
41
41
|
id?: string;
|
|
42
42
|
ref?: React.RefObject<HTMLButtonElement>;
|
|
43
43
|
className?: string;
|
|
@@ -46,14 +46,14 @@ declare type ActionMenuButtonProps = PropsWithChildren<Ref<HTMLButtonElement>> &
|
|
|
46
46
|
onClick?: (event: React.MouseEvent<HTMLButtonElement>) => void;
|
|
47
47
|
'data-testid'?: string;
|
|
48
48
|
};
|
|
49
|
-
|
|
49
|
+
type ActionMenuItemProps = {
|
|
50
50
|
value: string;
|
|
51
51
|
handler?: (newValue: string) => void;
|
|
52
52
|
selected?: boolean;
|
|
53
53
|
type?: 'none' | 'single';
|
|
54
54
|
disabled?: boolean;
|
|
55
55
|
} & PropsWithChildren<React.HTMLProps<HTMLLIElement>>;
|
|
56
|
-
|
|
56
|
+
type ActionMenuOverlayProps = PropsWithChildren<Ref<HTMLUListElement>> & {
|
|
57
57
|
'aria-label': string;
|
|
58
58
|
id?: string;
|
|
59
59
|
ref?: React.RefObject<HTMLUListElement>;
|
|
@@ -99,7 +99,7 @@ export declare const ActionMenu: React.NamedExoticComponent<{
|
|
|
99
99
|
*/
|
|
100
100
|
menuAlignment?: "start" | "end" | undefined;
|
|
101
101
|
} & BaseProps<HTMLDivElement>> & {
|
|
102
|
-
readonly type: ({ id, children, "data-testid": testId, disabled, open, selectionVariant, menuAlignment, onSelect }: ActionMenuProps) => JSX.Element;
|
|
102
|
+
readonly type: ({ id, children, "data-testid": testId, disabled, open, selectionVariant, menuAlignment, onSelect, }: ActionMenuProps) => JSX.Element;
|
|
103
103
|
} & {
|
|
104
104
|
Button: React.ForwardRefExoticComponent<(Pick<((instance: HTMLButtonElement | null) => void) & {
|
|
105
105
|
children?: React.ReactNode;
|
|
@@ -4,7 +4,7 @@ import type { BaseProps } from '../component-helpers';
|
|
|
4
4
|
* Design tokens
|
|
5
5
|
*/
|
|
6
6
|
import '@primer/brand-primitives/lib/design-tokens/css/tokens/functional/components/anchor-nav/colors-with-modes.css';
|
|
7
|
-
export
|
|
7
|
+
export type AnchorNavProps = BaseProps<HTMLElement> & {
|
|
8
8
|
/**
|
|
9
9
|
* Accepts all of `AnchorNav.Item` and `AnchorNav.Action` child components.
|
|
10
10
|
*/
|
|
@@ -15,13 +15,13 @@ export declare type AnchorNavProps = BaseProps<HTMLElement> & {
|
|
|
15
15
|
enableDefaultBgColor?: boolean;
|
|
16
16
|
} & React.ComponentPropsWithoutRef<'nav'>;
|
|
17
17
|
declare function _AnchorNav({ children, enableDefaultBgColor, ...props }: AnchorNavProps): JSX.Element;
|
|
18
|
-
|
|
18
|
+
type AnchorNavLinkIntersectionOptions = {
|
|
19
19
|
/**
|
|
20
20
|
* The area of the element that should trigger the next linked section to be highlighted.
|
|
21
21
|
*/
|
|
22
22
|
rootMargin: 'start' | 'middle';
|
|
23
23
|
};
|
|
24
|
-
|
|
24
|
+
type AnchorNavLinkProps = BaseProps<HTMLAnchorElement> & {
|
|
25
25
|
/**
|
|
26
26
|
* Optional text alignment for the link. Defaults to 'start' if there are less than 4 links, otherwise 'center'.
|
|
27
27
|
*/
|
|
@@ -41,7 +41,7 @@ declare type AnchorNavLinkProps = BaseProps<HTMLAnchorElement> & {
|
|
|
41
41
|
updateCurrentActiveNav?: (id: string | null) => void;
|
|
42
42
|
} & Omit<React.AnchorHTMLAttributes<HTMLAnchorElement>, 'href'>;
|
|
43
43
|
declare function _AnchorNavLink({ alignment, children, href, isActive, toggleMenuCallback, prefersReducedMotion, intersectionOptions, updateCurrentActiveNav, ...rest }: AnchorNavLinkProps): JSX.Element;
|
|
44
|
-
|
|
44
|
+
type AnchorNavActionProps = {
|
|
45
45
|
/**
|
|
46
46
|
* Required path or location for the action button to link to.
|
|
47
47
|
*/
|
package/lib/Avatar/Avatar.d.ts
CHANGED
|
@@ -2,20 +2,20 @@ import React from 'react';
|
|
|
2
2
|
import type { BaseProps } from '../component-helpers';
|
|
3
3
|
export declare const AvatarSizes: readonly [32, 40, 48, 64, 80];
|
|
4
4
|
export declare const AvatarShapes: readonly ["circle", "square"];
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
type AvatarSizeVariants = (typeof AvatarSizes)[number];
|
|
6
|
+
type ResponsiveSizeMap = {
|
|
7
7
|
narrow?: AvatarSizeVariants;
|
|
8
8
|
regular?: AvatarSizeVariants;
|
|
9
9
|
wide?: AvatarSizeVariants;
|
|
10
10
|
};
|
|
11
|
-
export
|
|
12
|
-
size?: typeof AvatarSizes[number] | ResponsiveSizeMap;
|
|
13
|
-
shape?: typeof AvatarShapes[number];
|
|
11
|
+
export type AvatarProps = BaseProps<HTMLImageElement> & {
|
|
12
|
+
size?: (typeof AvatarSizes)[number] | ResponsiveSizeMap;
|
|
13
|
+
shape?: (typeof AvatarShapes)[number];
|
|
14
14
|
src: string;
|
|
15
15
|
alt: string;
|
|
16
16
|
['data-testid']?: string;
|
|
17
17
|
} & React.ImgHTMLAttributes<HTMLImageElement>;
|
|
18
|
-
export declare const Avatar: React.ForwardRefExoticComponent<Pick<AvatarProps, "children" | "className" | "id" | "animate" | "size" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "referrerPolicy" | "alt" | "src" | "data-testid" | "crossOrigin" | "height" | "width" | "shape" | "decoding" | "loading" | "sizes" | "srcSet" | "useMap"> & React.RefAttributes<HTMLImageElement>> & {
|
|
18
|
+
export declare const Avatar: React.ForwardRefExoticComponent<Pick<AvatarProps, "children" | "className" | "id" | "animate" | "size" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "nonce" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "content" | "datatype" | "inlist" | "prefix" | "property" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "referrerPolicy" | "alt" | "src" | "data-testid" | "crossOrigin" | "height" | "width" | "shape" | "decoding" | "loading" | "sizes" | "srcSet" | "useMap"> & React.RefAttributes<HTMLImageElement>> & {
|
|
19
19
|
testIds: {
|
|
20
20
|
root: string;
|
|
21
21
|
readonly image: string;
|
package/lib/Button/Button.d.ts
CHANGED
|
@@ -6,7 +6,7 @@ export declare const ButtonVariants: readonly ["primary", "secondary", "subtle"]
|
|
|
6
6
|
export declare const ButtonSizes: readonly ["medium", "large"];
|
|
7
7
|
export declare const defaultButtonVariant: "secondary";
|
|
8
8
|
export declare const defaultButtonSize: "medium";
|
|
9
|
-
export
|
|
9
|
+
export type ButtonBaseProps = {
|
|
10
10
|
/**
|
|
11
11
|
* The leading visual appears before the button content
|
|
12
12
|
*/
|
|
@@ -18,17 +18,17 @@ export declare type ButtonBaseProps = {
|
|
|
18
18
|
/**
|
|
19
19
|
* The styling variations available in Button
|
|
20
20
|
*/
|
|
21
|
-
variant?: typeof ButtonVariants[number];
|
|
21
|
+
variant?: (typeof ButtonVariants)[number];
|
|
22
22
|
/**
|
|
23
23
|
* The size variations available in Button
|
|
24
24
|
*/
|
|
25
|
-
size?: typeof ButtonSizes[number];
|
|
25
|
+
size?: (typeof ButtonSizes)[number];
|
|
26
26
|
/**
|
|
27
27
|
* A flag to show/hide the arrow icon
|
|
28
28
|
*/
|
|
29
29
|
hasArrow?: boolean;
|
|
30
30
|
};
|
|
31
|
-
export
|
|
31
|
+
export type ButtonProps<C extends React.ElementType> = BaseProps<C> & {
|
|
32
32
|
as?: C;
|
|
33
33
|
} & ButtonBaseProps & React.ComponentPropsWithoutRef<C>;
|
|
34
34
|
export declare const _Button: React.ForwardRefExoticComponent<Pick<BaseProps<React.ElementType<any>> & {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { BaseProps } from '../component-helpers';
|
|
3
3
|
import { ButtonProps } from '../Button';
|
|
4
|
-
|
|
5
|
-
export
|
|
4
|
+
type PrimerBrandButtonType = React.ReactElement<ButtonProps<React.ElementType<'button' | 'a'>>>;
|
|
5
|
+
export type ButtonGroupProps = BaseProps<HTMLDivElement> & {
|
|
6
6
|
children: PrimerBrandButtonType[] | PrimerBrandButtonType;
|
|
7
7
|
buttonSize?: ButtonProps<'button' | 'a'>['size'];
|
|
8
8
|
buttonsAs?: React.ElementType;
|
|
@@ -4,7 +4,7 @@ import type { BaseProps } from '../component-helpers';
|
|
|
4
4
|
* Design tokens
|
|
5
5
|
*/
|
|
6
6
|
import '@primer/brand-primitives/lib/design-tokens/css/tokens/functional/components/cta-banner/colors-with-modes.css';
|
|
7
|
-
export
|
|
7
|
+
export type CTABannerProps = BaseProps<HTMLElement> & {
|
|
8
8
|
children: React.ReactNode | React.ReactNode[];
|
|
9
9
|
align?: 'start' | 'center';
|
|
10
10
|
hasBorder?: boolean;
|
|
@@ -31,14 +31,16 @@ export declare const CTABanner: React.ForwardRefExoticComponent<Pick<BaseProps<H
|
|
|
31
31
|
stretch?: "normal" | "condensed" | "expanded" | {
|
|
32
32
|
narrow?: "normal" | "condensed" | "expanded" | undefined;
|
|
33
33
|
regular?: "normal" | "condensed" | "expanded" | undefined;
|
|
34
|
-
wide?: "normal" | "condensed" | "expanded" | undefined;
|
|
34
|
+
wide?: "normal" | "condensed" | "expanded" | undefined; /**
|
|
35
|
+
* A flag to remove the background from the banner.
|
|
36
|
+
*/
|
|
35
37
|
} | undefined;
|
|
36
38
|
letterSpacing?: "normal" | "condensed" | "none" | {
|
|
37
39
|
narrow?: "normal" | "condensed" | "none" | undefined;
|
|
38
40
|
regular?: "normal" | "condensed" | "none" | undefined;
|
|
39
41
|
wide?: "normal" | "condensed" | "none" | undefined;
|
|
40
42
|
} | undefined;
|
|
41
|
-
} & React.HTMLAttributes<HTMLHeadingElement>, "children" | "className" | "id" | "animate" | "as" | "size" | "weight" | "stretch" | "letterSpacing" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & React.RefAttributes<HTMLHeadingElement>>;
|
|
43
|
+
} & React.HTMLAttributes<HTMLHeadingElement>, "children" | "className" | "id" | "animate" | "as" | "size" | "weight" | "stretch" | "letterSpacing" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "nonce" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "content" | "datatype" | "inlist" | "prefix" | "property" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & React.RefAttributes<HTMLHeadingElement>>;
|
|
42
44
|
Description: React.ForwardRefExoticComponent<Pick<BaseProps<HTMLParagraphElement> & {
|
|
43
45
|
children: React.ReactNode | React.ReactNode[];
|
|
44
46
|
}, "children" | "className" | "id" | "animate"> & React.RefAttributes<HTMLParagraphElement>>;
|
package/lib/Card/Card.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ import '@primer/brand-primitives/lib/design-tokens/css/tokens/functional/compone
|
|
|
11
11
|
import { Icon as IconProps } from '@primer/octicons-react';
|
|
12
12
|
export declare const CardIconColors: readonly ["default", "blue", "coral", "green", "gray", "indigo", "lemon", "lime", "orange", "pink", "purple", "red", "teal", "yellow"];
|
|
13
13
|
export declare const defaultCardIconColor: "default";
|
|
14
|
-
export
|
|
14
|
+
export type CardProps = {
|
|
15
15
|
/**
|
|
16
16
|
* Valid children include Card.Image, Card.Heading, and Card.Description
|
|
17
17
|
*/
|
|
@@ -25,23 +25,23 @@ export declare type CardProps = {
|
|
|
25
25
|
* */
|
|
26
26
|
ctaText?: string;
|
|
27
27
|
} & Omit<BaseProps<HTMLAnchorElement>, 'animate'> & React.ComponentPropsWithoutRef<'a'>;
|
|
28
|
-
|
|
28
|
+
type CardImageProps = ImageProps;
|
|
29
29
|
declare function CardImage({ className, ...rest }: CardImageProps): JSX.Element;
|
|
30
|
-
|
|
30
|
+
type CardIconProps = BaseProps<HTMLSpanElement> & {
|
|
31
31
|
icon: React.ReactNode | IconProps;
|
|
32
|
-
color?: typeof CardIconColors[number];
|
|
32
|
+
color?: (typeof CardIconColors)[number];
|
|
33
33
|
hasBackground?: boolean;
|
|
34
34
|
};
|
|
35
35
|
declare function CardIcon({ icon: Icon, className, color, hasBackground, ...rest }: CardIconProps): JSX.Element;
|
|
36
|
-
|
|
36
|
+
type CardLabelProps = BaseProps<HTMLSpanElement> & {
|
|
37
37
|
children: React.ReactNode | React.ReactNode[];
|
|
38
|
-
color?: typeof LabelColors[number];
|
|
38
|
+
color?: (typeof LabelColors)[number];
|
|
39
39
|
};
|
|
40
|
-
|
|
40
|
+
type CardHeadingProps = BaseProps<HTMLHeadingElement> & {
|
|
41
41
|
children: React.ReactNode | React.ReactNode[];
|
|
42
42
|
as?: Exclude<HeadingProps['as'], 'h1'>;
|
|
43
43
|
} & HeadingProps;
|
|
44
|
-
|
|
44
|
+
type CardDescriptionProps = BaseProps<HTMLParagraphElement> & {
|
|
45
45
|
children: React.ReactNode | React.ReactNode[];
|
|
46
46
|
};
|
|
47
47
|
/**
|
|
@@ -52,7 +52,7 @@ export declare const Card: React.ForwardRefExoticComponent<Pick<CardProps, keyof
|
|
|
52
52
|
Image: typeof CardImage;
|
|
53
53
|
Label: React.ForwardRefExoticComponent<Pick<CardLabelProps, "children" | "className" | "id" | "animate" | "color"> & React.RefAttributes<HTMLSpanElement>>;
|
|
54
54
|
Icon: typeof CardIcon;
|
|
55
|
-
Heading: React.ForwardRefExoticComponent<Pick<CardHeadingProps, "children" | "className" | "id" | "animate" | "as" | "size" | "weight" | "stretch" | "letterSpacing" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & React.RefAttributes<HTMLHeadingElement>>;
|
|
55
|
+
Heading: React.ForwardRefExoticComponent<Pick<CardHeadingProps, "children" | "className" | "id" | "animate" | "as" | "size" | "weight" | "stretch" | "letterSpacing" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "nonce" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "content" | "datatype" | "inlist" | "prefix" | "property" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & React.RefAttributes<HTMLHeadingElement>>;
|
|
56
56
|
Description: React.ForwardRefExoticComponent<Pick<CardDescriptionProps, "children" | "className" | "id" | "animate"> & React.RefAttributes<HTMLParagraphElement>>;
|
|
57
57
|
};
|
|
58
58
|
export {};
|
|
@@ -4,7 +4,7 @@ import type { BaseProps } from '../component-helpers';
|
|
|
4
4
|
* Design tokens
|
|
5
5
|
*/
|
|
6
6
|
import '@primer/brand-primitives/lib/design-tokens/css/tokens/functional/components/comparison-table/colors-with-modes.css';
|
|
7
|
-
export
|
|
7
|
+
export type ComparisonTableProps<C extends React.ElementType> = BaseProps<C> & {
|
|
8
8
|
as?: C;
|
|
9
9
|
heading?: string;
|
|
10
10
|
variant?: 'default' | 'minimal';
|
|
@@ -16,13 +16,13 @@ export declare const _ComparisonTable: React.ForwardRefExoticComponent<Pick<Base
|
|
|
16
16
|
variant?: "default" | "minimal" | undefined;
|
|
17
17
|
featuredColumn?: number | undefined;
|
|
18
18
|
} & Pick<any, string | number | symbol>, string | number | symbol> & React.RefAttributes<HTMLDivElement>>;
|
|
19
|
-
|
|
19
|
+
type RowProps = {
|
|
20
20
|
header?: boolean;
|
|
21
21
|
};
|
|
22
|
-
export
|
|
22
|
+
export type CellProps = BaseProps<HTMLTableCellElement> & {
|
|
23
23
|
as?: 'td' | 'th';
|
|
24
24
|
};
|
|
25
|
-
export
|
|
25
|
+
export type FootnoteProps = BaseProps<HTMLParagraphElement>;
|
|
26
26
|
/**
|
|
27
27
|
* @description
|
|
28
28
|
* Comparison tables are used to aid decision-making by displaying a list of features and their associated qualities side-by-side.
|
package/lib/FAQ/FAQ.d.ts
CHANGED
|
@@ -6,14 +6,14 @@ import type { BaseProps } from '../component-helpers';
|
|
|
6
6
|
*/
|
|
7
7
|
import '@primer/brand-primitives/lib/design-tokens/css/tokens/functional/components/faq/base.css';
|
|
8
8
|
import '@primer/brand-primitives/lib/design-tokens/css/tokens/functional/components/faq/colors-with-modes.css';
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
type FAQRootProps = PropsWithChildren<BaseProps<HTMLElement>> & React.HTMLAttributes<HTMLElement>;
|
|
10
|
+
type FAQHeadingProps = BaseProps<HTMLHeadingElement> & {
|
|
11
11
|
size?: 'medium' | 'large';
|
|
12
12
|
align?: 'start' | 'center';
|
|
13
13
|
children: React.ReactNode | React.ReactNode[];
|
|
14
14
|
as?: HeadingProps['as'];
|
|
15
15
|
};
|
|
16
|
-
|
|
16
|
+
type FAQSubheadingProps = BaseProps<HTMLHeadingElement> & {
|
|
17
17
|
align?: 'start' | 'center';
|
|
18
18
|
children: React.ReactNode | React.ReactNode[];
|
|
19
19
|
as?: Exclude<HeadingProps['as'], 'h1'>;
|
|
@@ -23,10 +23,10 @@ declare function FAQSubheading({ children, className, as, ...rest }: FAQSubheadi
|
|
|
23
23
|
* FAQ component:
|
|
24
24
|
* {@link https://primer.style/brand/components/FAQ/ See usage examples}.
|
|
25
25
|
*/
|
|
26
|
-
export declare const FAQ: React.ForwardRefExoticComponent<Pick<FAQRootProps, "children" | "className" | "id" | "animate" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & React.RefAttributes<HTMLElement>> & {
|
|
26
|
+
export declare const FAQ: React.ForwardRefExoticComponent<Pick<FAQRootProps, "children" | "className" | "id" | "animate" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "nonce" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "content" | "datatype" | "inlist" | "prefix" | "property" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & React.RefAttributes<HTMLElement>> & {
|
|
27
27
|
Subheading: typeof FAQSubheading;
|
|
28
28
|
Heading: React.ForwardRefExoticComponent<Pick<FAQHeadingProps, "children" | "className" | "align" | "id" | "animate" | "as" | "size"> & React.RefAttributes<HTMLHeadingElement>>;
|
|
29
|
-
Item: React.ForwardRefExoticComponent<Pick<import("..").AccordionRootProps, "children" | "className" | "id" | "animate" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "open"> & React.RefAttributes<HTMLDetailsElement>>;
|
|
29
|
+
Item: React.ForwardRefExoticComponent<Pick<import("..").AccordionRootProps, "children" | "className" | "id" | "animate" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "nonce" | "placeholder" | "slot" | "spellCheck" | "style" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "content" | "datatype" | "inlist" | "prefix" | "property" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "open"> & React.RefAttributes<HTMLDetailsElement>>;
|
|
30
30
|
Question: React.ForwardRefExoticComponent<Pick<BaseProps<HTMLHeadingElement> & {
|
|
31
31
|
className?: string | undefined;
|
|
32
32
|
children: string;
|
package/lib/Grid/Grid.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ import type { BaseProps } from '../component-helpers';
|
|
|
5
5
|
*/
|
|
6
6
|
import '@primer/brand-primitives/lib/design-tokens/css/tokens/functional/components/grid/grid.css';
|
|
7
7
|
import '@primer/brand-primitives/lib/design-tokens/css/tokens/functional/components/grid/colors-with-modes.css';
|
|
8
|
-
|
|
8
|
+
type ResponsiveMap = {
|
|
9
9
|
xsmall?: GridColumnIndex;
|
|
10
10
|
small?: GridColumnIndex;
|
|
11
11
|
medium?: GridColumnIndex;
|
|
@@ -13,8 +13,8 @@ declare type ResponsiveMap = {
|
|
|
13
13
|
xlarge?: GridColumnIndex;
|
|
14
14
|
xxlarge?: GridColumnIndex;
|
|
15
15
|
};
|
|
16
|
-
export
|
|
17
|
-
export
|
|
16
|
+
export type GridColumnIndex = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
|
|
17
|
+
export type GridProps<T extends keyof JSX.IntrinsicElements = 'div'> = React.HTMLAttributes<T> & {
|
|
18
18
|
/**
|
|
19
19
|
* The HTML element used to render the grid.
|
|
20
20
|
*/
|
|
@@ -28,7 +28,7 @@ export declare type GridProps<T extends keyof JSX.IntrinsicElements = 'div'> = R
|
|
|
28
28
|
*/
|
|
29
29
|
['data-testid']?: string;
|
|
30
30
|
} & (T extends 'span' ? BaseProps<HTMLSpanElement> : T extends 'section' ? BaseProps<HTMLElement> : BaseProps<HTMLDivElement>);
|
|
31
|
-
|
|
31
|
+
type GridColumnProps<T extends keyof JSX.IntrinsicElements = 'div'> = {
|
|
32
32
|
as?: T | 'div' | 'span' | 'section';
|
|
33
33
|
span?: GridColumnIndex | ResponsiveMap;
|
|
34
34
|
start?: GridColumnIndex | ResponsiveMap;
|