@truenas/ui-components 0.2.3 → 0.2.4
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/package.json
CHANGED
|
@@ -3394,7 +3394,18 @@ declare class TnFormFieldComponent implements AfterContentInit {
|
|
|
3394
3394
|
required: _angular_core.InputSignal<boolean>;
|
|
3395
3395
|
testId: _angular_core.InputSignal<TnTestIdValue>;
|
|
3396
3396
|
subscriptSizing: _angular_core.InputSignal<SubscriptSizing>;
|
|
3397
|
-
/**
|
|
3397
|
+
/**
|
|
3398
|
+
* Optional tooltip shown via a help icon.
|
|
3399
|
+
*
|
|
3400
|
+
* With a `label`, the icon renders next to the label in the label row. Without
|
|
3401
|
+
* one, the icon renders inline after the projected control instead — for
|
|
3402
|
+
* controls that carry their own label (e.g. `tn-checkbox`), where a detached
|
|
3403
|
+
* icon row above the control would look orphaned.
|
|
3404
|
+
*
|
|
3405
|
+
* Inline mode targets compact, self-labeled controls: the wrapper becomes a
|
|
3406
|
+
* flex row, so a full-width control (e.g. a label-less `tn-input`) would
|
|
3407
|
+
* shrink toward its content width. Give such fields a `label` instead.
|
|
3408
|
+
*/
|
|
3398
3409
|
tooltip: _angular_core.InputSignal<string>;
|
|
3399
3410
|
/** Placement of the tooltip relative to its help icon. */
|
|
3400
3411
|
tooltipPosition: _angular_core.InputSignal<TooltipPosition>;
|
|
@@ -3422,10 +3433,24 @@ declare class TnFormFieldComponent implements AfterContentInit {
|
|
|
3422
3433
|
/**
|
|
3423
3434
|
* Whether the required indicator renders: forced via the `required` input, or
|
|
3424
3435
|
* inferred from the projected control's validators (mirrors Angular Material's
|
|
3425
|
-
* `hasValidator(Validators.required)` approach
|
|
3426
|
-
* or custom required-like
|
|
3436
|
+
* `hasValidator(Validators.required)` approach, extended to `requiredTrue` for
|
|
3437
|
+
* boolean controls — reference equality, so composed or custom required-like
|
|
3438
|
+
* validators need the explicit input).
|
|
3427
3439
|
*/
|
|
3428
3440
|
protected showRequired: _angular_core.Signal<boolean>;
|
|
3441
|
+
/**
|
|
3442
|
+
* Whether the tooltip icon renders inline after the projected control rather
|
|
3443
|
+
* than in the label row — true when a tooltip is set but no label is.
|
|
3444
|
+
*/
|
|
3445
|
+
protected showInlineTooltip: _angular_core.Signal<boolean>;
|
|
3446
|
+
/**
|
|
3447
|
+
* Whether the required indicator renders inline after the projected control —
|
|
3448
|
+
* with no label there is no label row to host the asterisk, so a required
|
|
3449
|
+
* self-labeled control (e.g. a consent `tn-checkbox`) still gets one.
|
|
3450
|
+
*/
|
|
3451
|
+
protected showInlineRequired: _angular_core.Signal<boolean>;
|
|
3452
|
+
/** Whether the wrapper hosts any inline extras and lays out as a flex row. */
|
|
3453
|
+
protected showInlineExtras: _angular_core.Signal<boolean>;
|
|
3429
3454
|
protected hasError: _angular_core.Signal<boolean>;
|
|
3430
3455
|
protected errorMessage: _angular_core.Signal<string>;
|
|
3431
3456
|
ngAfterContentInit(): void;
|
|
@@ -3629,6 +3654,19 @@ declare class TnFormFieldHarness extends ComponentHarness {
|
|
|
3629
3654
|
* ```
|
|
3630
3655
|
*/
|
|
3631
3656
|
getTooltip(): Promise<string | null>;
|
|
3657
|
+
/**
|
|
3658
|
+
* Checks whether the tooltip help icon renders inline after the projected
|
|
3659
|
+
* control (label-less mode) rather than in the label row.
|
|
3660
|
+
*
|
|
3661
|
+
* @returns Promise resolving to true if the inline tooltip trigger is present.
|
|
3662
|
+
*
|
|
3663
|
+
* @example
|
|
3664
|
+
* ```typescript
|
|
3665
|
+
* const field = await loader.getHarness(TnFormFieldHarness.with({ testId: 'enable-fxp' }));
|
|
3666
|
+
* expect(await field.isTooltipInline()).toBe(true);
|
|
3667
|
+
* ```
|
|
3668
|
+
*/
|
|
3669
|
+
isTooltipInline(): Promise<boolean>;
|
|
3632
3670
|
/**
|
|
3633
3671
|
* Checks whether the form field is marked as required.
|
|
3634
3672
|
*
|