@stackone/malachite 2.69.0 → 2.71.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.
package/dist/index.d.ts CHANGED
@@ -9,6 +9,29 @@ import { NamedExoticComponent } from 'react';
9
9
  import { ReactNode } from 'react';
10
10
  import { UseFormReturn } from 'react-hook-form';
11
11
 
12
+ export declare type AccessEffect = 'read' | 'write' | 'delete';
13
+
14
+ export declare const AccessPills: default_2.FC<AccessPillsProps>;
15
+
16
+ export declare interface AccessPillsProps {
17
+ value: Record<AccessEffect, AccessPillState>;
18
+ /** Reports the pill pressed. Cascading the change to the other effects is the caller's call. */
19
+ onToggle: (effect: AccessEffect) => void;
20
+ /** An effect with nothing to grant, e.g. a connector with no delete actions. */
21
+ disabled?: Partial<Record<AccessEffect, boolean>>;
22
+ /** Why a pill is disabled, per effect or one sentence for all of them. */
23
+ disabledReason?: string | Partial<Record<AccessEffect, string>>;
24
+ size?: AccessPillsSize;
25
+ 'aria-label'?: string;
26
+ 'aria-labelledby'?: string;
27
+ }
28
+
29
+ /** `dense` draws the pills smaller, for a narrow screen. */
30
+ export declare type AccessPillsSize = 'default' | 'dense';
31
+
32
+ /** `'mixed'` is partly on: some, not all, of the effect's actions are allowed. */
33
+ export declare type AccessPillState = boolean | 'mixed';
34
+
12
35
  export declare const Accordion: default_2.FC<AccordionProps>;
13
36
 
14
37
  declare interface AccordionBaseProps {
@@ -157,6 +180,8 @@ export declare const AdvancedLogsIcon: React.FC<IconProps_4>;
157
180
 
158
181
  export declare const Alert: default_2.FC<AlertProps>;
159
182
 
183
+ export declare type AlertLayout = 'inline' | 'banner';
184
+
160
185
  declare interface AlertProps {
161
186
  type?: AlertType;
162
187
  message: string;
@@ -176,6 +201,10 @@ declare interface AlertProps {
176
201
  live?: boolean;
177
202
  /** Routes root-relative links in `message` through the app's router; see `MarkdownBlock`. */
178
203
  renderLink?: RenderLink;
204
+ /** `banner`: a 48px page-wide band. Applies only without `children`. */
205
+ layout?: AlertLayout;
206
+ /** A bold sentence the message runs on from. Plain text, not markdown. */
207
+ lead?: string;
179
208
  }
180
209
 
181
210
  export declare type AlertType = 'info' | 'success' | 'error' | 'warning' | 'assistant';
@@ -383,6 +412,8 @@ declare interface ButtonProps extends default_2.ButtonHTMLAttributes<HTMLButtonE
383
412
  tooltip?: string;
384
413
  tooltipPlacement?: 'top' | 'bottom' | 'left' | 'right';
385
414
  iconOnly?: boolean;
415
+ /** Pulls a borderless button out by its own padding, so its label lines up with the text around it. */
416
+ flush?: boolean;
386
417
  children?: default_2.ReactNode;
387
418
  onClick?: default_2.MouseEventHandler<HTMLButtonElement & HTMLAnchorElement>;
388
419
  /** Renders the button as a real anchor, so a link action is never an <a> nested in a <button>. */
@@ -1627,6 +1658,7 @@ declare interface EllipsisTextProps {
1627
1658
  maxWidth?: string;
1628
1659
  color?: TextColor;
1629
1660
  size?: FontSize;
1661
+ fontWeight?: FontWeight;
1630
1662
  /**
1631
1663
  * Show `tooltip` only when the text is actually cut off. Opt-in, because `tooltip` is any
1632
1664
  * node: a caller repeating the label wants this, and one supplying something the label does
@@ -3542,6 +3574,8 @@ export declare interface ModalProps {
3542
3574
  closeOnOverlayClick?: boolean;
3543
3575
  /** Whether the body gets default padding. Default: true. */
3544
3576
  bodyPadding?: boolean;
3577
+ /** `tall`: 600px, or the viewport less 160px, for content that sizes to its box. */
3578
+ bodyHeight?: 'auto' | 'tall';
3545
3579
  /** Full-width Alert bands at the top of the body, above `children`, in order. Unaffected by
3546
3580
  * `bodyPadding`, and announced ahead of the dialog's description. The message is markdown. */
3547
3581
  callouts?: {
@@ -4004,6 +4038,8 @@ declare type PopoverFocusSource = {
4004
4038
  export declare interface PopoverHeaderProps {
4005
4039
  title: string;
4006
4040
  action?: default_2.ReactNode;
4041
+ /** `false` drops the rule and sits the header 4px over the list. */
4042
+ divider?: boolean;
4007
4043
  }
4008
4044
 
4009
4045
  export declare type PopoverInitialFocus = default_2.RefObject<HTMLElement | null> | (() => HTMLElement | null | undefined);
@@ -4287,6 +4323,7 @@ export declare interface SearchProps {
4287
4323
  /** 'large' (42px) for form inputs; 'medium' (32px) for toolbars; 'small' (28px) in a table. */
4288
4324
  size?: SearchSize;
4289
4325
  variant?: SearchVariant;
4326
+ textSize?: SearchTextSize;
4290
4327
  disabled?: boolean;
4291
4328
  autoFocus?: boolean;
4292
4329
  className?: string;
@@ -4308,6 +4345,9 @@ export declare interface SearchProps {
4308
4345
 
4309
4346
  export declare type SearchSize = 'small' | 'medium' | 'large';
4310
4347
 
4348
+ /** `body` is the 14px body step at any size. */
4349
+ export declare type SearchTextSize = 'control' | 'body';
4350
+
4311
4351
  export declare const SearchTrigger: default_2.ForwardRefExoticComponent<SearchTriggerProps & default_2.RefAttributes<HTMLButtonElement>>;
4312
4352
 
4313
4353
  export declare interface SearchTriggerProps extends Omit<default_2.ButtonHTMLAttributes<HTMLButtonElement>, 'children' | 'className' | 'style' | 'color' | 'type'> {
@@ -4830,6 +4870,26 @@ export declare interface StatusBadgeProps {
4830
4870
 
4831
4871
  export declare type StatusBadgeType = 'success' | 'error' | 'warning' | 'info';
4832
4872
 
4873
+ export declare const StatusPill: default_2.FC<StatusPillProps>;
4874
+
4875
+ export declare interface StatusPillProps {
4876
+ label: string;
4877
+ /** Set in the mono face after a `·`. */
4878
+ detail?: string;
4879
+ tone?: StatusPillTone;
4880
+ icon?: default_2.ReactNode;
4881
+ busy?: boolean;
4882
+ /** Makes it a `status` live region. Off by default, as on `Alert`. */
4883
+ live?: boolean;
4884
+ /** Names the live region; only applies with `live`. */
4885
+ 'aria-label'?: string;
4886
+ /** Only applies with `live`. */
4887
+ 'aria-labelledby'?: string;
4888
+ className?: string;
4889
+ }
4890
+
4891
+ export declare type StatusPillTone = 'success' | 'neutral' | 'warning' | 'error';
4892
+
4833
4893
  export declare const StepCurrentIcon: React.FC<IconProps_104>;
4834
4894
 
4835
4895
  export declare const Stepper: default_2.FC<StepperProps>;
@@ -4962,6 +5022,8 @@ declare interface SurfaceRowChromeProps {
4962
5022
  * an outcome, where the result belongs to the whole line rather than to one cell in it.
4963
5023
  */
4964
5024
  tone?: 'default' | 'muted' | 'success' | 'error';
5025
+ /** `compact` is an 8px by 16px inset the row owns. */
5026
+ inset?: 'none' | 'compact';
4965
5027
  className?: string;
4966
5028
  style?: default_2.CSSProperties;
4967
5029
  }
@@ -5300,6 +5362,7 @@ export declare interface TextProps {
5300
5362
  children: default_2.ReactNode;
5301
5363
  tooltip?: string;
5302
5364
  textAlign?: 'left' | 'center' | 'right' | 'justify';
5365
+ wrap?: boolean;
5303
5366
  /** The element it renders, for a heading or paragraph that keeps Text's look. */
5304
5367
  as?: TextElement;
5305
5368
  className?: string;
@@ -5431,6 +5494,9 @@ export declare interface ToolbarProps {
5431
5494
  * the content it pins over — the consumer then owns the gutter. */
5432
5495
  padding?: 'none' | 'compact' | 'default';
5433
5496
  layout?: 'plain' | 'filters';
5497
+ /** `page` paints the sunken page ground, for a bar that sits above a card. */
5498
+ surface?: 'card' | 'page';
5499
+ sticky?: boolean;
5434
5500
  className?: string;
5435
5501
  style?: default_2.CSSProperties;
5436
5502
  }
@@ -5560,12 +5626,18 @@ export declare interface WizardLayoutProps {
5560
5626
  showBack?: boolean;
5561
5627
  onBack?: () => void;
5562
5628
  backDisabled?: boolean;
5629
+ /** `false` drops the hidden back button's square, so `leading` sits at the same inset as `trailing`. */
5630
+ reserveBack?: boolean;
5631
+ /** `large`: a 60px bar with 28px insets (52px and 16px below 640px), items centred. */
5632
+ topBarSize?: 'default' | 'large';
5563
5633
  /** Top-left slot beside the back button — e.g. a user avatar menu. */
5564
5634
  leading?: default_2.ReactNode;
5565
5635
  /** Right top-bar slot (sits just before `stepper`) — e.g. a theme toggle. */
5566
5636
  stepper?: default_2.ReactNode;
5567
5637
  /** Far-right top-bar slot — e.g. a theme toggle. */
5568
5638
  trailing?: default_2.ReactNode;
5639
+ /** A page-wide notice under the top bar, above `header`. */
5640
+ banner?: default_2.ReactNode;
5569
5641
  /**
5570
5642
  * Pinned below the top bar and always visible while the content scrolls —
5571
5643
  * e.g. connection logos + a step title. Rendered in the same centred column
@@ -5580,6 +5652,8 @@ export declare interface WizardLayoutProps {
5580
5652
  * above sticky body content, so it reads as glass over the scrolling list.
5581
5653
  */
5582
5654
  footerGlass?: boolean;
5655
+ /** `content` holds the footer to the content column, so a full-width action lines up with the list. */
5656
+ footerAlign?: 'full' | 'content';
5583
5657
  /** Vertically centre the content (used for terminal/success screens). */
5584
5658
  center?: boolean;
5585
5659
  /** Max width of the centered content column. */