@allxsmith/bestax-bulma 5.8.4 → 5.9.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.
@@ -4,7 +4,7 @@ import { ButtonProps } from './Button';
4
4
  * Props for the LinkButton component.
5
5
  */
6
6
  export interface LinkButtonProps extends Omit<ButtonProps, 'color' | 'isOutlined' | 'isInverted' | 'isLight'> {
7
- /** Display mode. `text` has no underline; `ghost` uses default text color. */
7
+ /** Display mode. `text` has no underline and highlights its background on hover; `ghost` uses the default text color and underlines on hover; `underline` drops the button chrome entirely (transparent background and border) and underlines on hover or focus. */
8
8
  variant?: 'text' | 'ghost' | 'underline';
9
9
  /** Text color override for the button. */
10
10
  color?: 'primary' | 'link' | 'info' | 'success' | 'warning' | 'danger' | 'white' | 'light' | 'dark' | 'black';
@@ -12,11 +12,11 @@ export interface FieldProps extends React.HTMLAttributes<HTMLDivElement>, Omit<B
12
12
  hasAddons?: boolean | 'centered' | 'right';
13
13
  /** Constrains the field to its content's width (used inside horizontal field bodies). */
14
14
  narrow?: boolean;
15
- /** Field label, rendered above the widget. `Field` itself does not associate it with any control — pass `labelProps={{ htmlFor }}` and a matching `id` on your control (the single-control convenience inputs do this automatically when they render their own `Field`). */
15
+ /** Field label, rendered above the widget. Automatically associated with a single composed `InputBase`, `SelectBase`, or `TextAreaBase` via a generated id and `htmlFor`. Pass `labelProps={{ htmlFor }}` to wire your own `id`, or `labelProps={{ htmlFor: undefined }}` to opt out. Skipped for `grouped`/`hasAddons` fields (multiple controls). */
16
16
  label?: React.ReactNode;
17
17
  /** Size for the label. */
18
18
  labelSize?: 'small' | 'normal' | 'medium' | 'large';
19
- /** Props for the label element — where `htmlFor` goes when composing. */
19
+ /** Props for the label element. An explicit `htmlFor` key — even set to `undefined` — takes over the association. */
20
20
  labelProps?: React.LabelHTMLAttributes<HTMLLabelElement> & {
21
21
  [key: string]: unknown;
22
22
  };
@@ -12,6 +12,16 @@ export declare const useInsideControl: () => boolean;
12
12
  export declare const FieldProvider: import("react").Provider<boolean>;
13
13
  /** Provider for Control context — used internally by Control component. */
14
14
  export declare const ControlProvider: import("react").Provider<boolean>;
15
+ /**
16
+ * The id a labeled Field wants its single composed control to adopt (#495).
17
+ * `undefined` outside a Field, in unlabeled/grouped/addons Fields, or when the
18
+ * user took over the association with an explicit `labelProps.htmlFor`.
19
+ * Consumed only by the single-control bases (InputBase, SelectBase,
20
+ * TextAreaBase). Internal; not part of the public API.
21
+ */
22
+ export declare const useFieldLabelId: () => string | undefined;
23
+ /** Provider for the Field label-target id — used internally by Field. */
24
+ export declare const FieldLabelIdProvider: import("react").Provider<string | undefined>;
15
25
  /**
16
26
  * Shape of the Radios group context. The group provides:
17
27
  * - `name`: shared form field name (Stage 1)
@@ -10,11 +10,11 @@ import { InputBaseProps } from './InputBase';
10
10
  * Control-level (icons, loading) props.
11
11
  */
12
12
  export interface InputProps extends InputBaseProps {
13
- /** Field label. Automatically associated with the input via `htmlFor` — uses your `id` when provided, otherwise a generated one. Dropped inside an outer `Field` (label that `Field` yourself). */
13
+ /** Field label. Automatically associated with the input via `htmlFor` — uses your `id` when provided, otherwise a generated one. Dropped inside an outer `Field`, whose own label associates instead when that `Field` generates a target id (not `grouped`/`hasAddons`, no explicit `labelProps.htmlFor`). */
14
14
  label?: React.ReactNode;
15
15
  /** Size for the label. */
16
16
  labelSize?: FieldProps['labelSize'];
17
- /** Props for the label element. An explicit `htmlFor` here overrides the automatic association (no id is generated then). */
17
+ /** Props for the label element when the component renders its own `Field`; dropped inside an outer `Field` (use that `Field`'s `labelProps` instead). An explicit `htmlFor` key — even `undefined` — overrides the automatic association and no id is generated. */
18
18
  labelProps?: FieldProps['labelProps'];
19
19
  /** Horizontal field layout. */
20
20
  horizontal?: boolean;
@@ -10,11 +10,11 @@ import { SelectBaseProps } from './SelectBase';
10
10
  * Control-level (icons, loading) props.
11
11
  */
12
12
  export interface SelectProps extends SelectBaseProps {
13
- /** Field label. Automatically associated with the select via `htmlFor` — uses your `id` when provided, otherwise a generated one. Dropped inside an outer `Field` (label that `Field` yourself). */
13
+ /** Field label. Automatically associated with the select via `htmlFor` — uses your `id` when provided, otherwise a generated one. Dropped inside an outer `Field`, whose own label associates instead when that `Field` generates a target id (not `grouped`/`hasAddons`, no explicit `labelProps.htmlFor`). */
14
14
  label?: React.ReactNode;
15
15
  /** Size for the label. */
16
16
  labelSize?: FieldProps['labelSize'];
17
- /** Props for the label element. An explicit `htmlFor` here overrides the automatic association (no id is generated then). */
17
+ /** Props for the label element when the component renders its own `Field`; dropped inside an outer `Field` (use that `Field`'s `labelProps` instead). An explicit `htmlFor` key — even `undefined` — overrides the automatic association and no id is generated. */
18
18
  labelProps?: FieldProps['labelProps'];
19
19
  /** Horizontal field layout. */
20
20
  horizontal?: boolean;
@@ -10,11 +10,11 @@ import { TextAreaBaseProps } from './TextAreaBase';
10
10
  * Control-level (loading) props.
11
11
  */
12
12
  export interface TextAreaProps extends TextAreaBaseProps {
13
- /** Field label. Automatically associated with the textarea via `htmlFor` — uses your `id` when provided, otherwise a generated one. Dropped inside an outer `Field` (label that `Field` yourself). */
13
+ /** Field label. Automatically associated with the textarea via `htmlFor` — uses your `id` when provided, otherwise a generated one. Dropped inside an outer `Field`, whose own label associates instead when that `Field` generates a target id (not `grouped`/`hasAddons`, no explicit `labelProps.htmlFor`). */
14
14
  label?: React.ReactNode;
15
15
  /** Size for the label. */
16
16
  labelSize?: FieldProps['labelSize'];
17
- /** Props for the label element. An explicit `htmlFor` here overrides the automatic association (no id is generated then). */
17
+ /** Props for the label element when the component renders its own `Field`; dropped inside an outer `Field` (use that `Field`'s `labelProps` instead). An explicit `htmlFor` key — even `undefined` — overrides the automatic association and no id is generated. */
18
18
  labelProps?: FieldProps['labelProps'];
19
19
  /** Horizontal field layout. */
20
20
  horizontal?: boolean;
@@ -18,8 +18,9 @@ interface UseAutoLabelIdOptions {
18
18
  * Associates the convenience `label` prop with its control (#368): generates
19
19
  * an id for the control and returns labelProps carrying a matching `htmlFor`.
20
20
  * A user-supplied `id` is used as the target instead of the generated one, and
21
- * an explicit `labelProps.htmlFor` disables generation entirely — the user has
22
- * taken over the association. Internal; not part of the public API.
21
+ * an explicit `htmlFor` key in labelProps — even set to `undefined` — disables
22
+ * generation entirely: the user has taken over the association (#495 presence
23
+ * semantics). Internal; not part of the public API.
23
24
  */
24
25
  export declare function useAutoLabelId({ label, id, labelProps, rendersLabel, }: UseAutoLabelIdOptions): {
25
26
  controlId: string | undefined;
package/llms.txt CHANGED
@@ -7,3 +7,4 @@ React components for Bulma v1.
7
7
  - Any docs page as markdown: append .md (e.g. https://bestax.io/docs/api/elements/button.md)
8
8
  - LLM guide: https://bestax.io/docs/guides/llms
9
9
  - Agent skills: https://bestax.io/docs/skills/intro
10
+ - MCP server: `npx bestax-mcp` — setup at https://bestax.io/docs/guides/llms#mcp-server
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@allxsmith/bestax-bulma",
3
- "version": "5.8.4",
3
+ "version": "5.9.1",
4
4
  "description": "A fully-typed React component library for the Bulma CSS framework. Build modern UIs quickly with reusable, accessible, and customizable Bulma-based React components.",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.esm.js",