@realminc/ui 0.10.0 → 0.11.0
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.
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import type { MouseEvent, ReactNode } from 'react';
|
|
2
|
+
export type OaFootnotesVariant = 'dark' | 'light';
|
|
3
|
+
export interface OaFootnoteItem {
|
|
4
|
+
/** Marker rendered in brackets, e.g. '*' or '1'; defaults to '*' */
|
|
5
|
+
marker?: string;
|
|
6
|
+
/** Anchor id for this footnote, e.g. 'footnote-char-transformer' */
|
|
7
|
+
id?: string;
|
|
8
|
+
/** Marker link target, usually the claim anchor e.g. '#ref-char-transformer' */
|
|
9
|
+
href?: string;
|
|
10
|
+
/** Footnote content */
|
|
11
|
+
children: ReactNode;
|
|
12
|
+
}
|
|
13
|
+
export interface OaFootnotesProps {
|
|
14
|
+
/** Footnote entries; a plain string renders with the default '*' marker */
|
|
15
|
+
items: readonly (string | OaFootnoteItem)[];
|
|
16
|
+
/** Surface variant */
|
|
17
|
+
variant?: OaFootnotesVariant;
|
|
18
|
+
/** Click handler for linked markers, e.g. a consumer-owned smooth scroll */
|
|
19
|
+
on_marker_click?: (event: MouseEvent<HTMLAnchorElement>) => void;
|
|
20
|
+
/** Additional className */
|
|
21
|
+
className?: string;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* OaFootnotes - footnote and provenance list
|
|
25
|
+
*
|
|
26
|
+
* Renders Microsoft-style marked fine print such as benchmark provenance,
|
|
27
|
+
* capability limits, and release qualifiers below all page sections and above
|
|
28
|
+
* the footer. Each bracketed marker sits in a fixed left column and links back
|
|
29
|
+
* to its claim anchor; the claim marker in section copy links down to the
|
|
30
|
+
* footnote id.
|
|
31
|
+
*
|
|
32
|
+
* @example
|
|
33
|
+
* <OaFootnotes
|
|
34
|
+
* variant="dark"
|
|
35
|
+
* items={[{
|
|
36
|
+
* marker: '*',
|
|
37
|
+
* id: 'footnote-char-transformer',
|
|
38
|
+
* href: '#ref-char-transformer',
|
|
39
|
+
* children: 'Measured on Intel Iris Xe TGL GT2 with Mesa 26.2.2.',
|
|
40
|
+
* }]}
|
|
41
|
+
* />
|
|
42
|
+
*/
|
|
43
|
+
export declare function OaFootnotes({ items, variant, on_marker_click, className }: OaFootnotesProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -14,6 +14,8 @@ export { OaMarquee } from './marquee';
|
|
|
14
14
|
export type { OaMarqueeProps, OaMarqueeItem } from './marquee';
|
|
15
15
|
export { OaLabel } from './label';
|
|
16
16
|
export type { OaLabelProps } from './label';
|
|
17
|
+
export { OaFootnotes } from './footnotes';
|
|
18
|
+
export type { OaFootnoteItem, OaFootnotesProps, OaFootnotesVariant } from './footnotes';
|
|
17
19
|
export { OaSideIndicator } from './side_indicator';
|
|
18
20
|
export type { OaSideIndicatorProps } from './side_indicator';
|
|
19
21
|
export { OaPriceDisplay } from './price_display';
|