@allxsmith/bestax-bulma 5.7.0 → 5.8.1
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/AGENTS.md +28 -0
- package/CLAUDE.md +28 -0
- package/README.md +24 -0
- package/dist/index.cjs.js +3485 -55
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +3485 -55
- package/dist/index.esm.js.map +1 -1
- package/dist/types/columns/Column.d.ts +38 -0
- package/dist/types/columns/Columns.d.ts +31 -0
- package/dist/types/components/Avatar.d.ts +32 -0
- package/dist/types/components/Avatars.d.ts +12 -0
- package/dist/types/components/Badge.d.ts +34 -0
- package/dist/types/components/Breadcrumb.d.ts +25 -0
- package/dist/types/components/Card.d.ts +60 -0
- package/dist/types/components/Carousel.d.ts +70 -0
- package/dist/types/components/Collapse.d.ts +52 -0
- package/dist/types/components/Dialog.d.ts +89 -0
- package/dist/types/components/Dropdown.d.ts +42 -0
- package/dist/types/components/Loading.d.ts +50 -0
- package/dist/types/components/Menu.d.ts +44 -0
- package/dist/types/components/Message.d.ts +20 -0
- package/dist/types/components/Modal.d.ts +50 -0
- package/dist/types/components/Navbar.d.ts +147 -0
- package/dist/types/components/Pagination.d.ts +81 -0
- package/dist/types/components/Panel.d.ts +93 -0
- package/dist/types/components/Reveal.d.ts +37 -0
- package/dist/types/components/Sidebar.d.ts +37 -0
- package/dist/types/components/Steps.d.ts +56 -0
- package/dist/types/components/Tabs.d.ts +90 -0
- package/dist/types/components/Toast.d.ts +104 -0
- package/dist/types/components/Tooltip.d.ts +46 -0
- package/dist/types/elements/Block.d.ts +21 -0
- package/dist/types/elements/Box.d.ts +25 -1
- package/dist/types/elements/Button.d.ts +33 -0
- package/dist/types/elements/Buttons.d.ts +16 -0
- package/dist/types/elements/Code.d.ts +14 -0
- package/dist/types/elements/Content.d.ts +22 -0
- package/dist/types/elements/Delete.d.ts +24 -0
- package/dist/types/elements/Divider.d.ts +12 -0
- package/dist/types/elements/Emphasis.d.ts +14 -0
- package/dist/types/elements/Figure.d.ts +23 -0
- package/dist/types/elements/Icon.d.ts +28 -0
- package/dist/types/elements/IconText.d.ts +20 -0
- package/dist/types/elements/Image.d.ts +27 -0
- package/dist/types/elements/Link.d.ts +20 -0
- package/dist/types/elements/LinkButton.d.ts +20 -0
- package/dist/types/elements/ListItem.d.ts +15 -0
- package/dist/types/elements/Notification.d.ts +110 -0
- package/dist/types/elements/OrderedList.d.ts +10 -0
- package/dist/types/elements/Paragraph.d.ts +14 -0
- package/dist/types/elements/Pre.d.ts +14 -0
- package/dist/types/elements/Progress.d.ts +26 -0
- package/dist/types/elements/Skeleton.d.ts +22 -0
- package/dist/types/elements/Span.d.ts +14 -0
- package/dist/types/elements/Strong.d.ts +14 -0
- package/dist/types/elements/SubTitle.d.ts +25 -0
- package/dist/types/elements/Table.d.ts +14 -0
- package/dist/types/elements/Tag.d.ts +25 -0
- package/dist/types/elements/Tags.d.ts +7 -0
- package/dist/types/elements/Tbody.d.ts +18 -0
- package/dist/types/elements/Td.d.ts +23 -0
- package/dist/types/elements/Tfoot.d.ts +18 -0
- package/dist/types/elements/Th.d.ts +24 -0
- package/dist/types/elements/Thead.d.ts +18 -0
- package/dist/types/elements/Title.d.ts +26 -0
- package/dist/types/elements/Tr.d.ts +20 -0
- package/dist/types/elements/UnorderedList.d.ts +7 -0
- package/dist/types/form/Autocomplete.d.ts +64 -0
- package/dist/types/form/Checkbox.d.ts +33 -0
- package/dist/types/form/Checkboxes.d.ts +9 -0
- package/dist/types/form/Control.d.ts +37 -0
- package/dist/types/form/DateInput.d.ts +44 -0
- package/dist/types/form/DateInputBase.d.ts +49 -0
- package/dist/types/form/DateTimeInput.d.ts +42 -0
- package/dist/types/form/DateTimeInputBase.d.ts +58 -0
- package/dist/types/form/Field.d.ts +52 -0
- package/dist/types/form/File.d.ts +24 -0
- package/dist/types/form/FormContext.d.ts +46 -0
- package/dist/types/form/Input.d.ts +45 -0
- package/dist/types/form/InputBase.d.ts +21 -0
- package/dist/types/form/Numberinput.d.ts +43 -0
- package/dist/types/form/Radio.d.ts +33 -0
- package/dist/types/form/Radios.d.ts +9 -0
- package/dist/types/form/Rate.d.ts +55 -0
- package/dist/types/form/Select.d.ts +35 -0
- package/dist/types/form/SelectBase.d.ts +24 -0
- package/dist/types/form/Slider.d.ts +86 -0
- package/dist/types/form/Switch.d.ts +50 -0
- package/dist/types/form/Taginput.d.ts +74 -0
- package/dist/types/form/TextArea.d.ts +34 -0
- package/dist/types/form/TextAreaBase.d.ts +24 -0
- package/dist/types/form/TimeInput.d.ts +40 -0
- package/dist/types/form/TimeInputBase.d.ts +51 -0
- package/dist/types/form/_pickerInternals/Calendar.d.ts +6 -0
- package/dist/types/form/_pickerInternals/TimeWheels.d.ts +13 -0
- package/dist/types/form/_pickerInternals/audioTick.d.ts +47 -0
- package/dist/types/form/_pickerInternals/dateUtils.d.ts +13 -0
- package/dist/types/form/_pickerInternals/formatters.d.ts +19 -0
- package/dist/types/form/_pickerInternals/haptics.d.ts +23 -0
- package/dist/types/form/_pickerInternals/pickerTypes.d.ts +8 -0
- package/dist/types/form/_pickerInternals/segmentMap.d.ts +48 -0
- package/dist/types/form/_pickerInternals/useNativeMobilePicker.d.ts +1 -0
- package/dist/types/form/_pickerInternals/useSegmentedEntry.d.ts +30 -0
- package/dist/types/form/fieldProps.d.ts +12 -0
- package/dist/types/grid/Cell.d.ts +25 -0
- package/dist/types/grid/Grid.d.ts +32 -0
- package/dist/types/helpers/Config.d.ts +50 -0
- package/dist/types/helpers/Theme.d.ts +66 -0
- package/dist/types/helpers/bulmaClassHelpers.d.ts +97 -0
- package/dist/types/helpers/classNames.d.ts +50 -0
- package/dist/types/helpers/colorDeprecations.d.ts +17 -0
- package/dist/types/helpers/useBulmaClasses.d.ts +22 -0
- package/dist/types/helpers/useColorClasses.d.ts +20 -0
- package/dist/types/helpers/useFlexboxClasses.d.ts +34 -0
- package/dist/types/helpers/useOtherClasses.d.ts +27 -0
- package/dist/types/helpers/useSpacingClasses.d.ts +27 -0
- package/dist/types/helpers/useTypographyClasses.d.ts +32 -0
- package/dist/types/helpers/useVisibilityClasses.d.ts +25 -0
- package/dist/types/helpers/withSubComponents.d.ts +13 -0
- package/dist/types/layout/Container.d.ts +29 -0
- package/dist/types/layout/Footer.d.ts +22 -0
- package/dist/types/layout/Hero.d.ts +67 -0
- package/dist/types/layout/Level.d.ts +60 -0
- package/dist/types/layout/Media.d.ts +56 -0
- package/dist/types/layout/Section.d.ts +20 -0
- package/dist/types/skill-examples/ExampleMeta.d.ts +5 -0
- package/dist/types/skill-examples/ProfileCard.d.ts +13 -0
- package/llms.txt +9 -0
- package/package.json +30 -28
|
@@ -1,12 +1,34 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the Content component.
|
|
5
|
+
*/
|
|
3
6
|
interface ContentProps extends React.HTMLAttributes<HTMLDivElement>, Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
7
|
+
/** Additional CSS classes to apply. */
|
|
4
8
|
className?: string;
|
|
9
|
+
/** Text color helper (e.g., `'danger'` for `has-text-danger`). */
|
|
5
10
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
11
|
+
/**
|
|
12
|
+
* Text color alias: renders `has-text-<color>`, exactly like `textColor`.
|
|
13
|
+
* Not a filled variant (no `.content.is-<color>` CSS exists). Prefer
|
|
14
|
+
* `textColor`, which takes precedence when both are set; use `bgColor` for
|
|
15
|
+
* a colored surface.
|
|
16
|
+
*/
|
|
6
17
|
color?: 'primary' | 'link' | 'info' | 'success' | 'warning' | 'danger';
|
|
18
|
+
/** Background color helper (e.g., `'info'` for `has-background-info`). */
|
|
7
19
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
20
|
+
/** Size modifier for the content. */
|
|
8
21
|
size?: 'small' | 'normal' | 'medium' | 'large';
|
|
22
|
+
/** Content to be rendered inside the block. */
|
|
9
23
|
children?: React.ReactNode;
|
|
10
24
|
}
|
|
25
|
+
/**
|
|
26
|
+
* The `Content` component applies Bulma’s typographic styles to its children, enhancing the appearance of HTML elements like paragraphs, headings, lists, and tables.
|
|
27
|
+
*
|
|
28
|
+
* @function
|
|
29
|
+
* @param {ContentProps} props - Props for the Content component.
|
|
30
|
+
* @returns {JSX.Element} The rendered content block.
|
|
31
|
+
* @see {@link https://bulma.io/documentation/elements/content/ | Bulma Content documentation}
|
|
32
|
+
*/
|
|
11
33
|
export declare const Content: React.FC<ContentProps>;
|
|
12
34
|
export default Content;
|
|
@@ -1,14 +1,38 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the Delete component.
|
|
5
|
+
*/
|
|
3
6
|
interface DeleteProps extends React.HTMLAttributes<HTMLButtonElement>, BulmaClassesProps {
|
|
7
|
+
/** Additional CSS classes to apply. */
|
|
4
8
|
className?: string;
|
|
9
|
+
/** Text color helper. */
|
|
5
10
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
11
|
+
/**
|
|
12
|
+
* Text color alias: renders `has-text-<color>`, exactly like `textColor`.
|
|
13
|
+
* Not a filled variant (no `.delete.is-<color>` CSS exists). Prefer
|
|
14
|
+
* `textColor`, which takes precedence when both are set; use `bgColor` for
|
|
15
|
+
* a colored surface.
|
|
16
|
+
*/
|
|
6
17
|
color?: 'primary' | 'link' | 'info' | 'success' | 'warning' | 'danger';
|
|
18
|
+
/** Background color helper. */
|
|
7
19
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
20
|
+
/** Click handler for the button. */
|
|
8
21
|
onClick?: (event: React.MouseEvent<HTMLButtonElement>) => void;
|
|
22
|
+
/** Size modifier for the delete button. */
|
|
9
23
|
size?: 'small' | 'medium' | 'large';
|
|
24
|
+
/** ARIA label for accessibility (default: 'Close'). */
|
|
10
25
|
ariaLabel?: string;
|
|
26
|
+
/** Whether the button is disabled (default: false). */
|
|
11
27
|
disabled?: boolean;
|
|
12
28
|
}
|
|
29
|
+
/**
|
|
30
|
+
* The `Delete` component provides a Bulma-styled close/delete button for dismissing modals, notifications, tags, messages, and more.
|
|
31
|
+
*
|
|
32
|
+
* @function
|
|
33
|
+
* @param {DeleteProps} props - Props for the Delete component.
|
|
34
|
+
* @returns {JSX.Element} The rendered delete button.
|
|
35
|
+
* @see {@link https://bulma.io/documentation/elements/delete/ | Bulma Delete documentation}
|
|
36
|
+
*/
|
|
13
37
|
export declare const Delete: React.FC<DeleteProps>;
|
|
14
38
|
export {};
|
|
@@ -1,7 +1,19 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the Divider component.
|
|
5
|
+
*/
|
|
3
6
|
export interface DividerProps extends React.HTMLAttributes<HTMLHRElement>, Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
7
|
+
/** Additional CSS classes to apply. */
|
|
4
8
|
className?: string;
|
|
9
|
+
/** Background color helper. */
|
|
5
10
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
6
11
|
}
|
|
12
|
+
/**
|
|
13
|
+
* The `Divider` component renders a styled horizontal rule (`<hr>`) element with Bulma helper class integration.
|
|
14
|
+
*
|
|
15
|
+
* @function
|
|
16
|
+
* @param {DividerProps} props - Props for the Divider component.
|
|
17
|
+
* @returns {JSX.Element} The rendered hr element.
|
|
18
|
+
*/
|
|
7
19
|
export declare const Divider: React.FC<DividerProps>;
|
|
@@ -1,9 +1,23 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the Emphasis component.
|
|
5
|
+
*/
|
|
3
6
|
export interface EmphasisProps extends React.HTMLAttributes<HTMLElement>, Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
7
|
+
/** Additional CSS classes to apply. */
|
|
4
8
|
className?: string;
|
|
9
|
+
/** Text color helper. */
|
|
5
10
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
11
|
+
/** Background color helper. */
|
|
6
12
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
13
|
+
/** Content to render inside the em element. */
|
|
7
14
|
children?: React.ReactNode;
|
|
8
15
|
}
|
|
16
|
+
/**
|
|
17
|
+
* The `Emphasis` component renders a styled `<em>` element with Bulma helper class integration.
|
|
18
|
+
*
|
|
19
|
+
* @function
|
|
20
|
+
* @param {EmphasisProps} props - Props for the Emphasis component.
|
|
21
|
+
* @returns {JSX.Element} The rendered em element.
|
|
22
|
+
*/
|
|
9
23
|
export declare const Emphasis: React.FC<EmphasisProps>;
|
|
@@ -1,17 +1,40 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the FigureCaption component.
|
|
5
|
+
*/
|
|
3
6
|
export interface FigureCaptionProps extends React.HTMLAttributes<HTMLElement>, Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
7
|
+
/** Additional CSS classes to apply. */
|
|
4
8
|
className?: string;
|
|
9
|
+
/** Text color (Bulma color, 'inherit', or 'current'). */
|
|
5
10
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
11
|
+
/** Background color (Bulma color, 'inherit', or 'current'). */
|
|
6
12
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
13
|
+
/** Content to be rendered inside the figcaption. */
|
|
7
14
|
children?: React.ReactNode;
|
|
8
15
|
}
|
|
16
|
+
/**
|
|
17
|
+
* Props for the Figure component.
|
|
18
|
+
*/
|
|
9
19
|
export interface FigureProps extends React.HTMLAttributes<HTMLElement>, Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
20
|
+
/** Additional CSS classes to apply. */
|
|
10
21
|
className?: string;
|
|
22
|
+
/** Text color helper. */
|
|
11
23
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
24
|
+
/** Background color helper. */
|
|
12
25
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
26
|
+
/** Content to render inside the figure. */
|
|
13
27
|
children?: React.ReactNode;
|
|
14
28
|
}
|
|
29
|
+
/**
|
|
30
|
+
* Figure component with Caption subcomponent.
|
|
31
|
+
*
|
|
32
|
+
* @example
|
|
33
|
+
* <Figure>
|
|
34
|
+
* <img src="image.jpg" alt="Description" />
|
|
35
|
+
* <Figure.Caption>Image caption text</Figure.Caption>
|
|
36
|
+
* </Figure>
|
|
37
|
+
*/
|
|
15
38
|
export declare const Figure: React.FC<FigureProps> & {
|
|
16
39
|
Caption: React.FC<FigureCaptionProps>;
|
|
17
40
|
};
|
|
@@ -20,21 +20,49 @@ declare module 'react' {
|
|
|
20
20
|
}
|
|
21
21
|
}
|
|
22
22
|
type IconLibrary = 'fa' | 'mdi' | 'ion' | 'material-icons' | 'material-symbols';
|
|
23
|
+
/**
|
|
24
|
+
* Props for the Icon component.
|
|
25
|
+
*/
|
|
23
26
|
export interface IconProps extends React.HTMLAttributes<HTMLSpanElement>, BulmaClassesProps {
|
|
27
|
+
/** Additional CSS classes to apply. */
|
|
24
28
|
className?: string;
|
|
29
|
+
/** Text color helper. */
|
|
25
30
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
31
|
+
/** Bulma color modifier for the icon. */
|
|
26
32
|
color?: 'primary' | 'link' | 'info' | 'success' | 'warning' | 'danger';
|
|
33
|
+
/** Background color helper. */
|
|
27
34
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
35
|
+
/** The icon name, with or without its library prefix (e.g. `'star'` or `'fa-star'`). */
|
|
28
36
|
name: string;
|
|
37
|
+
/** DEPRECATED: Legacy prop, use `name` instead. */
|
|
29
38
|
icon?: string;
|
|
39
|
+
/**
|
|
40
|
+
* The icon library to use ('fa' = Font Awesome, 'mdi' = Material Design Icons, 'ion' = Ionicons Web Components, 'material-icons' = Google Material Icons, 'material-symbols' = Google Material Symbols). Defaults to the value set in ConfigProvider or 'fa' if not configured.
|
|
41
|
+
* @defaultValue 'fa'
|
|
42
|
+
*/
|
|
30
43
|
library?: IconLibrary;
|
|
44
|
+
/** Icon style variant (e.g. `'solid'`, `'outlined'`, `'rounded'`). */
|
|
31
45
|
variant?: string;
|
|
46
|
+
/** Additional modifiers (e.g. `'fa-lg'`, `'fa-spin'`, `'is-size-1'`). */
|
|
32
47
|
features?: string | string[];
|
|
48
|
+
/** **DEPRECATED:** Use `variant` and `features` instead. */
|
|
33
49
|
libraryFeatures?: string | string[];
|
|
50
|
+
/** Size modifier for the icon container. */
|
|
34
51
|
size?: 'small' | 'medium' | 'large';
|
|
52
|
+
/** ARIA label for accessibility (default: 'icon'). */
|
|
35
53
|
ariaLabel?: string;
|
|
54
|
+
/** Inline style object. */
|
|
36
55
|
style?: React.CSSProperties;
|
|
56
|
+
/** Override the default `'icon'` container class (e.g., `'panel-icon'`). */
|
|
37
57
|
containerClassName?: string;
|
|
38
58
|
}
|
|
59
|
+
/**
|
|
60
|
+
* The `Icon` component is a Bulma-styled wrapper for displaying icons from various libraries (Font Awesome, Material Design Icons, Ionicons, Google Material Icons, Material Symbols, etc.).
|
|
61
|
+
*
|
|
62
|
+
* @function
|
|
63
|
+
* @param {IconProps} props - Props for the Icon component.
|
|
64
|
+
* @returns {JSX.Element} The rendered icon element.
|
|
65
|
+
* @see {@link https://bulma.io/documentation/elements/icon/ | Bulma Icon documentation}
|
|
66
|
+
*/
|
|
39
67
|
export declare const Icon: React.FC<IconProps>;
|
|
40
68
|
export {};
|
|
@@ -1,17 +1,37 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
3
|
import { IconProps } from './Icon';
|
|
4
|
+
/**
|
|
5
|
+
* Represents an item for the IconText component, containing icon props and optional text.
|
|
6
|
+
*/
|
|
4
7
|
interface IconTextItem {
|
|
8
|
+
/** Props for the Icon component. */
|
|
5
9
|
iconProps: IconProps;
|
|
10
|
+
/** Optional text to display next to the icon. */
|
|
6
11
|
text?: string;
|
|
7
12
|
}
|
|
13
|
+
/**
|
|
14
|
+
* Props for the IconText component.
|
|
15
|
+
*/
|
|
8
16
|
interface IconTextProps extends React.HTMLAttributes<HTMLSpanElement>, BulmaClassesProps {
|
|
17
|
+
/** Additional CSS classes to apply. */
|
|
9
18
|
className?: string;
|
|
19
|
+
/** Text color helper. */
|
|
10
20
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
21
|
+
/**
|
|
22
|
+
* Text color alias: renders `has-text-<color>`, exactly like `textColor`.
|
|
23
|
+
* Not a filled variant (no `.icon-text.is-<color>` CSS exists). Prefer
|
|
24
|
+
* `textColor`, which takes precedence when both are set; use `bgColor` for
|
|
25
|
+
* a colored surface.
|
|
26
|
+
*/
|
|
11
27
|
color?: 'primary' | 'link' | 'info' | 'success' | 'warning' | 'danger';
|
|
28
|
+
/** Background color helper. */
|
|
12
29
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
30
|
+
/** Props for a single Icon component (for single icon mode). */
|
|
13
31
|
iconProps?: IconProps;
|
|
32
|
+
/** Text for a single icon (for single icon mode). */
|
|
14
33
|
children?: React.ReactNode;
|
|
34
|
+
/** Array of icon/text pairs (for multiple icons mode). */
|
|
15
35
|
items?: IconTextItem[];
|
|
16
36
|
}
|
|
17
37
|
export declare const IconText: React.FC<IconTextProps> & {
|
|
@@ -1,17 +1,44 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the Image component.
|
|
5
|
+
*/
|
|
3
6
|
export interface ImageProps extends React.HTMLAttributes<HTMLElement>, Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
7
|
+
/** Additional CSS classes to apply. */
|
|
4
8
|
className?: string;
|
|
9
|
+
/** Text color helper for the container. */
|
|
5
10
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
11
|
+
/**
|
|
12
|
+
* Text color alias: renders `has-text-<color>`, exactly like `textColor`.
|
|
13
|
+
* Not a filled variant (no `.image.is-<color>` CSS exists). Prefer
|
|
14
|
+
* `textColor`, which takes precedence when both are set; use `bgColor` for
|
|
15
|
+
* a colored surface.
|
|
16
|
+
*/
|
|
6
17
|
color?: 'primary' | 'link' | 'info' | 'success' | 'warning' | 'danger';
|
|
18
|
+
/** Background color helper for the container. */
|
|
7
19
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
20
|
+
/** Fixed size or aspect ratio modifier for the image container. */
|
|
8
21
|
size?: '16x16' | '24x24' | '32x32' | '48x48' | '64x64' | '96x96' | '128x128' | 'square' | '1by1' | '5by4' | '4by3' | '3by2' | '5by3' | '16by9' | '2by1' | '3by1' | '4by5' | '3by4' | '2by3' | '3by5' | '9by16' | '1by2' | '1by3';
|
|
22
|
+
/** Renders the image with rounded corners. */
|
|
9
23
|
isRounded?: boolean;
|
|
24
|
+
/** Uses retina (2x) image source. */
|
|
10
25
|
isRetina?: boolean;
|
|
26
|
+
/** Image source URL. */
|
|
11
27
|
src?: string;
|
|
28
|
+
/** Alternate text for the image. */
|
|
12
29
|
alt?: string;
|
|
30
|
+
/** Arbitrary content (e.g., iframe, custom HTML) inside the image container. */
|
|
13
31
|
children?: React.ReactNode;
|
|
32
|
+
/** Container element tag. Defaults to `'figure'` when using aspect-ratio sizes, `'div'` otherwise. */
|
|
14
33
|
as?: 'figure' | 'div' | 'p';
|
|
15
34
|
}
|
|
35
|
+
/**
|
|
36
|
+
* The `Image` component wraps images, iframes, or custom content in a Bulma-styled container, supporting fixed sizes, aspect ratios, rounded corners, retina images, and all Bulma helper props for color and spacing.
|
|
37
|
+
*
|
|
38
|
+
* @function
|
|
39
|
+
* @param {ImageProps} props - Props for the Image component.
|
|
40
|
+
* @returns {JSX.Element} The rendered image element.
|
|
41
|
+
* @see {@link https://bulma.io/documentation/elements/image/ | Bulma Image documentation}
|
|
42
|
+
*/
|
|
16
43
|
export declare const Image: React.FC<ImageProps>;
|
|
17
44
|
export default Image;
|
|
@@ -1,11 +1,31 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the Link component.
|
|
5
|
+
* @extraProp {string} [href] - The URL the link points to.
|
|
6
|
+
* @extraProp {'_self' | '_blank' | '_parent' | '_top'} [target] - Where to open the linked document.
|
|
7
|
+
* @extraProp {string} [rel] - Relationship between current and linked document.
|
|
8
|
+
*/
|
|
3
9
|
export interface LinkProps extends React.AnchorHTMLAttributes<HTMLAnchorElement>, Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
10
|
+
/** Additional CSS classes to apply. */
|
|
4
11
|
className?: string;
|
|
12
|
+
/** Text color helper. */
|
|
5
13
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
14
|
+
/** Background color helper. */
|
|
6
15
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
16
|
+
/** Whether the link appears active. */
|
|
7
17
|
isActive?: boolean;
|
|
18
|
+
/** Render as a custom component (e.g. a router `Link`) instead of `<a>`. Defaults to `'a'`. */
|
|
8
19
|
as?: React.ElementType;
|
|
20
|
+
/** Content to render inside the link. */
|
|
9
21
|
children?: React.ReactNode;
|
|
10
22
|
}
|
|
23
|
+
/**
|
|
24
|
+
* The `Link` component renders a styled anchor (`<a>`) element with Bulma helper class integration.
|
|
25
|
+
*
|
|
26
|
+
* @function
|
|
27
|
+
* @param {LinkProps} props - Props for the Link component.
|
|
28
|
+
* @returns {JSX.Element} The rendered anchor element.
|
|
29
|
+
* @see {@link https://bulma.io/documentation/elements/content/ | Bulma Content documentation}
|
|
30
|
+
*/
|
|
11
31
|
export declare const Link: React.FC<LinkProps>;
|
|
@@ -1,8 +1,28 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ButtonProps } from './Button';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the LinkButton component.
|
|
5
|
+
*/
|
|
3
6
|
export interface LinkButtonProps extends Omit<ButtonProps, 'color' | 'isOutlined' | 'isInverted' | 'isLight'> {
|
|
7
|
+
/** Display mode. `text` has no underline; `ghost` uses default text color. */
|
|
4
8
|
variant?: 'text' | 'ghost' | 'underline';
|
|
9
|
+
/** Text color override for the button. */
|
|
5
10
|
color?: 'primary' | 'link' | 'info' | 'success' | 'warning' | 'danger' | 'white' | 'light' | 'dark' | 'black';
|
|
6
11
|
}
|
|
12
|
+
/**
|
|
13
|
+
* The `LinkButton` component renders a `<button>` that visually looks like text or a link.
|
|
14
|
+
*
|
|
15
|
+
* @function
|
|
16
|
+
* @param {LinkButtonProps} props - Props for the LinkButton component.
|
|
17
|
+
* @returns {JSX.Element} The rendered link-styled button element.
|
|
18
|
+
*
|
|
19
|
+
* @example
|
|
20
|
+
* // Text variant (default)
|
|
21
|
+
* <LinkButton onClick={handleClick}>Click me</LinkButton>
|
|
22
|
+
*
|
|
23
|
+
* @example
|
|
24
|
+
* // Underline variant with color
|
|
25
|
+
* <LinkButton variant="underline" color="primary">Learn more</LinkButton>
|
|
26
|
+
*/
|
|
7
27
|
export declare const LinkButton: React.FC<LinkButtonProps>;
|
|
8
28
|
export default LinkButton;
|
|
@@ -1,9 +1,24 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the ListItem component.
|
|
5
|
+
* @extraProp {number} [value] - Custom value for ordered list items.
|
|
6
|
+
*/
|
|
3
7
|
export interface ListItemProps extends React.LiHTMLAttributes<HTMLLIElement>, Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
8
|
+
/** Additional CSS classes to apply. */
|
|
4
9
|
className?: string;
|
|
10
|
+
/** Text color helper. */
|
|
5
11
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
12
|
+
/** Background color helper. */
|
|
6
13
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
14
|
+
/** Content to render inside the list item. */
|
|
7
15
|
children?: React.ReactNode;
|
|
8
16
|
}
|
|
17
|
+
/**
|
|
18
|
+
* The `ListItem` component renders a styled list item (`<li>`) element with Bulma helper class integration.
|
|
19
|
+
*
|
|
20
|
+
* @function
|
|
21
|
+
* @param {ListItemProps} props - Props for the ListItem component.
|
|
22
|
+
* @returns {JSX.Element} The rendered li element.
|
|
23
|
+
*/
|
|
9
24
|
export declare const ListItem: React.FC<ListItemProps>;
|
|
@@ -1,41 +1,151 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the Notification component.
|
|
5
|
+
*/
|
|
3
6
|
export interface NotificationProps extends React.HTMLAttributes<HTMLDivElement>, Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
7
|
+
/** Additional CSS classes to apply. */
|
|
4
8
|
className?: string;
|
|
9
|
+
/**
|
|
10
|
+
* Bulma color modifier for the notification (renders `is-<color>`).
|
|
11
|
+
*
|
|
12
|
+
* Only `primary`, `link`, `info`, `success`, `warning`, `danger`, `black`,
|
|
13
|
+
* `white`, `light`, and `dark` have shipped CSS for `.notification`. The
|
|
14
|
+
* other accepted values (`black-bis`, `black-ter`, `grey-darker`,
|
|
15
|
+
* `grey-dark`, `grey`, `grey-light`, `grey-lighter`) emit a class no CSS
|
|
16
|
+
* rule matches, so the notification renders unstyled; they log a console
|
|
17
|
+
* warning in development and will be removed from this union in the next
|
|
18
|
+
* major version.
|
|
19
|
+
*/
|
|
5
20
|
color?: (typeof validColors)[number];
|
|
21
|
+
/** Text color helper. */
|
|
6
22
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
23
|
+
/** Use the light color variant. */
|
|
7
24
|
isLight?: boolean;
|
|
25
|
+
/** Shows a close (delete) button in the notification. */
|
|
8
26
|
hasDelete?: boolean;
|
|
27
|
+
/** Callback fired when the delete button is clicked. */
|
|
9
28
|
onDelete?: () => void;
|
|
29
|
+
/** Content inside the notification. */
|
|
10
30
|
children?: React.ReactNode;
|
|
11
31
|
}
|
|
32
|
+
/**
|
|
33
|
+
* The `Notification` component is a Bulma-styled alert/message area for providing feedback, warnings, or information to users.
|
|
34
|
+
*
|
|
35
|
+
* @function
|
|
36
|
+
* @param {NotificationProps} props - Props for the Notification component.
|
|
37
|
+
* @returns {JSX.Element} The rendered notification element.
|
|
38
|
+
* @see {@link https://bulma.io/documentation/elements/notification/ | Bulma Notification documentation}
|
|
39
|
+
*/
|
|
12
40
|
export declare const Notification: React.FC<NotificationProps>;
|
|
41
|
+
/** Screen positions where programmatic notifications can be displayed. */
|
|
13
42
|
export type NotificationPosition = 'top-left' | 'top' | 'top-right' | 'bottom-left' | 'bottom' | 'bottom-right';
|
|
43
|
+
/**
|
|
44
|
+
* Options for showing a programmatic notification.
|
|
45
|
+
*/
|
|
14
46
|
export interface NotificationOptions {
|
|
47
|
+
/** The message to display. */
|
|
15
48
|
message: string | React.ReactNode;
|
|
49
|
+
/**
|
|
50
|
+
* Bulma color modifier for the notification (renders `is-<color>`).
|
|
51
|
+
*
|
|
52
|
+
* Only `primary`, `link`, `info`, `success`, `warning`, `danger`, `black`,
|
|
53
|
+
* `white`, `light`, and `dark` have shipped CSS for `.notification`. The
|
|
54
|
+
* other accepted values (`black-bis`, `black-ter`, `grey-darker`,
|
|
55
|
+
* `grey-dark`, `grey`, `grey-light`, `grey-lighter`) emit a class no CSS
|
|
56
|
+
* rule matches, so the notification renders unstyled; they log a console
|
|
57
|
+
* warning in development and will be removed from this union in the next
|
|
58
|
+
* major version.
|
|
59
|
+
*/
|
|
16
60
|
color?: (typeof validColors)[number];
|
|
61
|
+
/** Use the light color variant. */
|
|
17
62
|
isLight?: boolean;
|
|
63
|
+
/** Duration in ms before auto-close. Default 3000. */
|
|
18
64
|
duration?: number;
|
|
65
|
+
/** Position on the screen. Default 'top-right'. */
|
|
19
66
|
position?: NotificationPosition;
|
|
67
|
+
/** When true, notifications enter a FIFO queue and display one at a time. Default false. */
|
|
20
68
|
queue?: boolean;
|
|
69
|
+
/** Show a delete (close) button. Default true. */
|
|
21
70
|
hasDelete?: boolean;
|
|
71
|
+
/** Stay open until dismissed. */
|
|
22
72
|
indefinite?: boolean;
|
|
73
|
+
/** Pause auto-close timer on hover. Default true. */
|
|
23
74
|
pauseOnHover?: boolean;
|
|
24
75
|
}
|
|
76
|
+
/**
|
|
77
|
+
* Internal representation of a notification instance.
|
|
78
|
+
*/
|
|
25
79
|
interface NotificationInstance {
|
|
80
|
+
/** Unique identifier for this notification. */
|
|
26
81
|
id: string;
|
|
82
|
+
/** Configuration options for the notification. */
|
|
27
83
|
options: NotificationOptions;
|
|
28
84
|
}
|
|
85
|
+
/**
|
|
86
|
+
* Programmatic notification API for showing, closing, and managing notifications.
|
|
87
|
+
*
|
|
88
|
+
* @example
|
|
89
|
+
* notification.success('File saved successfully');
|
|
90
|
+
* notification.danger('Something went wrong', { duration: 5000 });
|
|
91
|
+
*/
|
|
29
92
|
export declare const notification: {
|
|
93
|
+
/**
|
|
94
|
+
* Show a notification with the given options.
|
|
95
|
+
* @param {NotificationOptions} options - Notification configuration.
|
|
96
|
+
* @returns {string} The unique ID of the created notification.
|
|
97
|
+
*/
|
|
30
98
|
show: (options: NotificationOptions) => string;
|
|
99
|
+
/**
|
|
100
|
+
* Show a success notification.
|
|
101
|
+
* @param {string|React.ReactNode} message - The message to display.
|
|
102
|
+
* @param {Partial<NotificationOptions>} [options] - Additional options.
|
|
103
|
+
* @returns {string} The notification ID.
|
|
104
|
+
*/
|
|
31
105
|
success: (message: string | React.ReactNode, options?: Partial<NotificationOptions>) => string;
|
|
106
|
+
/**
|
|
107
|
+
* Show a danger notification.
|
|
108
|
+
* @param {string|React.ReactNode} message - The message to display.
|
|
109
|
+
* @param {Partial<NotificationOptions>} [options] - Additional options.
|
|
110
|
+
* @returns {string} The notification ID.
|
|
111
|
+
*/
|
|
32
112
|
danger: (message: string | React.ReactNode, options?: Partial<NotificationOptions>) => string;
|
|
113
|
+
/**
|
|
114
|
+
* Show a warning notification.
|
|
115
|
+
* @param {string|React.ReactNode} message - The message to display.
|
|
116
|
+
* @param {Partial<NotificationOptions>} [options] - Additional options.
|
|
117
|
+
* @returns {string} The notification ID.
|
|
118
|
+
*/
|
|
33
119
|
warning: (message: string | React.ReactNode, options?: Partial<NotificationOptions>) => string;
|
|
120
|
+
/**
|
|
121
|
+
* Show an info notification.
|
|
122
|
+
* @param {string|React.ReactNode} message - The message to display.
|
|
123
|
+
* @param {Partial<NotificationOptions>} [options] - Additional options.
|
|
124
|
+
* @returns {string} The notification ID.
|
|
125
|
+
*/
|
|
34
126
|
info: (message: string | React.ReactNode, options?: Partial<NotificationOptions>) => string;
|
|
127
|
+
/**
|
|
128
|
+
* Close a specific notification by ID.
|
|
129
|
+
* @param {string} id - The notification ID to close.
|
|
130
|
+
*/
|
|
35
131
|
close: (id: string) => void;
|
|
132
|
+
/** Close all notifications and clear the queue. */
|
|
36
133
|
closeAll: () => void;
|
|
134
|
+
/**
|
|
135
|
+
* Subscribe to notification state changes.
|
|
136
|
+
* @param {(items: NotificationInstance[]) => void} listener - Callback invoked on changes.
|
|
137
|
+
* @returns {() => void} Unsubscribe function.
|
|
138
|
+
*/
|
|
37
139
|
subscribe: (listener: (items: NotificationInstance[]) => void) => (() => void);
|
|
38
140
|
};
|
|
141
|
+
/**
|
|
142
|
+
* Container component for rendering programmatic notifications.
|
|
143
|
+
* Place once at your app root to enable the notification API.
|
|
144
|
+
*
|
|
145
|
+
* @function
|
|
146
|
+
* @param {{ position?: NotificationPosition }} props - Container props.
|
|
147
|
+
* @returns {JSX.Element | null} The rendered notification container, or null if empty.
|
|
148
|
+
*/
|
|
39
149
|
export declare const NotificationContainer: React.FC<{
|
|
40
150
|
position?: NotificationPosition;
|
|
41
151
|
}>;
|
|
@@ -1,9 +1,19 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the OrderedList component.
|
|
5
|
+
* @extraProp {'1' | 'a' | 'A' | 'i' | 'I'} [type='1'] - The numbering type for the list.
|
|
6
|
+
* @extraProp {number} [start] - The starting number for the list.
|
|
7
|
+
* @extraProp {boolean} [reversed] - Whether to reverse the list numbering.
|
|
8
|
+
*/
|
|
3
9
|
export interface OrderedListProps extends React.OlHTMLAttributes<HTMLOListElement>, Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
10
|
+
/** Additional CSS classes to apply. */
|
|
4
11
|
className?: string;
|
|
12
|
+
/** Text color helper. */
|
|
5
13
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
14
|
+
/** Background color helper. */
|
|
6
15
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
16
|
+
/** List items to render inside the list. */
|
|
7
17
|
children?: React.ReactNode;
|
|
8
18
|
}
|
|
9
19
|
export declare const OrderedList: React.FC<OrderedListProps> & {
|
|
@@ -1,9 +1,23 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the Paragraph component.
|
|
5
|
+
*/
|
|
3
6
|
export interface ParagraphProps extends React.HTMLAttributes<HTMLParagraphElement>, Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
7
|
+
/** Additional CSS classes to apply. */
|
|
4
8
|
className?: string;
|
|
9
|
+
/** Text color helper. */
|
|
5
10
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
11
|
+
/** Background color helper. */
|
|
6
12
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
13
|
+
/** Content to render inside the paragraph. */
|
|
7
14
|
children?: React.ReactNode;
|
|
8
15
|
}
|
|
16
|
+
/**
|
|
17
|
+
* The `Paragraph` component renders a styled `<p>` element with Bulma helper class integration.
|
|
18
|
+
*
|
|
19
|
+
* @function
|
|
20
|
+
* @param {ParagraphProps} props - Props for the Paragraph component.
|
|
21
|
+
* @returns {JSX.Element} The rendered paragraph element.
|
|
22
|
+
*/
|
|
9
23
|
export declare const Paragraph: React.FC<ParagraphProps>;
|
|
@@ -1,9 +1,23 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the Pre component.
|
|
5
|
+
*/
|
|
3
6
|
export interface PreProps extends React.HTMLAttributes<HTMLPreElement>, Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
7
|
+
/** Additional CSS classes to apply. */
|
|
4
8
|
className?: string;
|
|
9
|
+
/** Text color helper. */
|
|
5
10
|
textColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
11
|
+
/** Background color helper. */
|
|
6
12
|
bgColor?: (typeof validColors)[number] | 'inherit' | 'current';
|
|
13
|
+
/** Preformatted content to render. */
|
|
7
14
|
children?: React.ReactNode;
|
|
8
15
|
}
|
|
16
|
+
/**
|
|
17
|
+
* The `Pre` component renders a styled `<pre>` element with Bulma helper class integration.
|
|
18
|
+
*
|
|
19
|
+
* @function
|
|
20
|
+
* @param {PreProps} props - Props for the Pre component.
|
|
21
|
+
* @returns {JSX.Element} The rendered pre element.
|
|
22
|
+
*/
|
|
9
23
|
export declare const Pre: React.FC<PreProps>;
|
|
@@ -1,11 +1,37 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { BulmaClassesProps, validColors } from '../helpers/useBulmaClasses';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the Progress component.
|
|
5
|
+
*/
|
|
3
6
|
export interface ProgressProps extends React.ProgressHTMLAttributes<HTMLProgressElement>, Omit<BulmaClassesProps, 'color' | 'backgroundColor'> {
|
|
7
|
+
/** Additional CSS classes to apply. */
|
|
4
8
|
className?: string;
|
|
9
|
+
/**
|
|
10
|
+
* Bulma color modifier for the progress bar (renders `is-<color>`).
|
|
11
|
+
*
|
|
12
|
+
* Only `primary`, `link`, `info`, `success`, `warning`, `danger`, `black`,
|
|
13
|
+
* `white`, `light`, and `dark` have shipped CSS for `.progress`. The other
|
|
14
|
+
* accepted values (`black-bis`, `black-ter`, `grey-darker`, `grey-dark`,
|
|
15
|
+
* `grey`, `grey-light`, `grey-lighter`) emit a class no CSS rule matches, so
|
|
16
|
+
* the bar renders unstyled; they log a console warning in development and
|
|
17
|
+
* will be removed from this union in the next major version.
|
|
18
|
+
*/
|
|
5
19
|
color?: (typeof validColors)[number];
|
|
20
|
+
/** Size modifier for the progress bar. */
|
|
6
21
|
size?: 'small' | 'medium' | 'large';
|
|
22
|
+
/** Current value of the progress bar. */
|
|
7
23
|
value?: number;
|
|
24
|
+
/** Maximum value of the progress bar. */
|
|
8
25
|
max?: number;
|
|
26
|
+
/** Optional custom content inside the progress bar. */
|
|
9
27
|
children?: React.ReactNode;
|
|
10
28
|
}
|
|
29
|
+
/**
|
|
30
|
+
* The `Progress` component displays a Bulma-styled progress bar.
|
|
31
|
+
*
|
|
32
|
+
* @function
|
|
33
|
+
* @param {ProgressProps} props - Props for the Progress component.
|
|
34
|
+
* @returns {JSX.Element} The rendered progress bar element.
|
|
35
|
+
* @see {@link https://bulma.io/documentation/elements/progress/ | Bulma Progress documentation}
|
|
36
|
+
*/
|
|
11
37
|
export declare const Progress: React.FC<ProgressProps>;
|