@stackone/malachite 2.116.0 → 2.118.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.
Files changed (50) hide show
  1. package/COMPONENTS.md +19 -9
  2. package/dist/assets/icons/caret_down.svg.js +2 -2
  3. package/dist/assets/icons/caret_down.svg.js.map +1 -1
  4. package/dist/assets/icons/caret_up.svg.js +2 -2
  5. package/dist/assets/icons/caret_up.svg.js.map +1 -1
  6. package/dist/assets/icons/minus.svg.js +6 -0
  7. package/dist/assets/icons/minus.svg.js.map +1 -0
  8. package/dist/assets/icons/warning_circle_filled.svg.js +3 -3
  9. package/dist/assets/icons/warning_circle_filled.svg.js.map +1 -1
  10. package/dist/components/Alert.js +3 -3
  11. package/dist/components/Alert.js.map +1 -1
  12. package/dist/components/BaseFormComponent.js +84 -64
  13. package/dist/components/BaseFormComponent.js.map +1 -1
  14. package/dist/components/ClampText.js +89 -15
  15. package/dist/components/ClampText.js.map +1 -1
  16. package/dist/components/CustomIcons/MinusIcon.js +16 -0
  17. package/dist/components/CustomIcons/MinusIcon.js.map +1 -0
  18. package/dist/components/CustomIcons/index.js +150 -147
  19. package/dist/components/CustomIcons/index.js.map +1 -1
  20. package/dist/components/Dropdown.js +449 -439
  21. package/dist/components/Dropdown.js.map +1 -1
  22. package/dist/components/FieldBlock.js +32 -21
  23. package/dist/components/FieldBlock.js.map +1 -1
  24. package/dist/components/GuideTimeline/GuideJumpMenu.js +74 -0
  25. package/dist/components/GuideTimeline/GuideJumpMenu.js.map +1 -0
  26. package/dist/components/GuideTimeline/GuideProgress.js +81 -0
  27. package/dist/components/GuideTimeline/GuideProgress.js.map +1 -0
  28. package/dist/components/GuideTimeline/GuideTimeline.js +313 -0
  29. package/dist/components/GuideTimeline/GuideTimeline.js.map +1 -0
  30. package/dist/components/GuideTimeline/guideTimelinePositions.js +23 -0
  31. package/dist/components/GuideTimeline/guideTimelinePositions.js.map +1 -0
  32. package/dist/components/Link.js +11 -10
  33. package/dist/components/Link.js.map +1 -1
  34. package/dist/components/MultiSelect.js +1 -1
  35. package/dist/components/MultiSelect.js.map +1 -1
  36. package/dist/components/SidePanel.js +382 -227
  37. package/dist/components/SidePanel.js.map +1 -1
  38. package/dist/components/Tooltip.js +1 -1
  39. package/dist/components/Tooltip.js.map +1 -1
  40. package/dist/components/TruncatedTooltip.js +1 -1
  41. package/dist/components/TruncatedTooltip.js.map +1 -1
  42. package/dist/components/ZoomableImage.js +144 -32
  43. package/dist/components/ZoomableImage.js.map +1 -1
  44. package/dist/components/sidePanelOverlay.js +7 -0
  45. package/dist/components/sidePanelOverlay.js.map +1 -0
  46. package/dist/index.d.ts +149 -11
  47. package/dist/index.js +265 -255
  48. package/dist/index.js.map +1 -1
  49. package/dist/tailwind.css.js +1 -1
  50. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"ZoomableImage.js","sources":["../../src/components/ZoomableImage.tsx"],"sourcesContent":["import type React from 'react';\nimport { useState } from 'react';\nimport Modal from './Modal';\nimport { FOCUS_RING, FOCUS_RING_INSET } from './focusRing';\n\nexport interface ZoomableImageProps {\n src: string;\n /**\n * Describes the image. Required and non-empty: it names the thumbnail's button and the\n * enlarged view, so an empty `alt` leaves both unnamed.\n */\n alt: string;\n /** Names the enlarged view for assistive tech. Default: `alt`, also when `title` is empty. */\n title?: string;\n /**\n * The thumbnail failed to load, so the caller can leave the image out. A thumbnail loads\n * lazily, so for one below the fold this fires once it nears the viewport, not on render.\n */\n onError?: () => void;\n}\n\n/**\n * An image that enlarges on click, for a screenshot too detailed to read inline. The enlarged\n * image is as large as the window allows at its own aspect ratio, up to its natural size, and a\n * click anywhere closes it.\n */\nconst ZoomableImage: React.FC<ZoomableImageProps> = ({ src, alt, title, onError }) => {\n const [isEnlarged, setIsEnlarged] = useState(false);\n // Latched on first enlarge, so an idle thumbnail mounts no Modal; never reset, so the exit transition still plays.\n const [hasEnlarged, setHasEnlarged] = useState(false);\n const close = () => setIsEnlarged(false);\n const enlarge = () => {\n setHasEnlarged(true);\n setIsEnlarged(true);\n };\n\n return (\n <>\n <button\n type=\"button\"\n aria-label={`Enlarge image: ${alt}`}\n onClick={enlarge}\n className={`block max-h-[240px] w-fit max-w-full cursor-zoom-in overflow-hidden rounded-lg border border-solid border-[var(--malachite-card-border)] bg-transparent p-0 ${FOCUS_RING}`}\n >\n {/* At its own width up to the container's, never stretched. The button, not the image,\n caps the height and clips a tall image to its top: a `max-h` on the image would\n narrow it instead, and the button would fit that narrower width.\n Keyed on `src`: a reused <img> keeps drawing the old image until the new one loads. */}\n <img\n key={src}\n src={src}\n alt={alt}\n loading=\"lazy\"\n decoding=\"async\"\n onError={onError ? () => onError() : undefined}\n className=\"block h-auto w-full\"\n />\n </button>\n {hasEnlarged && (\n <Modal\n open={isEnlarged}\n onClose={close}\n title={title || alt}\n size=\"fullscreen\"\n surface=\"none\"\n >\n {/* The image sits beside the close button, not inside it: a button's children are\n presentational, so an image inside it would never reach assistive tech. */}\n <div className=\"relative flex h-full w-full items-center justify-center\">\n <button\n type=\"button\"\n aria-label=\"Close enlarged image\"\n onClick={close}\n className={`absolute inset-0 z-10 cursor-zoom-out border-0 bg-transparent p-0 ${FOCUS_RING_INSET}`}\n />\n <img\n key={src}\n src={src}\n alt={alt}\n className=\"max-h-full max-w-full rounded-lg object-contain\"\n />\n </div>\n </Modal>\n )}\n </>\n );\n};\n\nexport { ZoomableImage };\nexport default ZoomableImage;\n"],"names":["ZoomableImage","src","alt","title","onError","isEnlarged","setIsEnlarged","useState","hasEnlarged","setHasEnlarged","close","enlarge","jsxs","Fragment","jsx","FOCUS_RING","Modal","FOCUS_RING_INSET"],"mappings":";;;;AA0BA,MAAMA,IAA8C,CAAC,EAAE,KAAAC,GAAK,KAAAC,GAAK,OAAAC,GAAO,SAAAC,QAAc;AAClF,QAAM,CAACC,GAAYC,CAAa,IAAIC,EAAS,EAAK,GAE5C,CAACC,GAAaC,CAAc,IAAIF,EAAS,EAAK,GAC9CG,IAAQ,MAAMJ,EAAc,EAAK,GACjCK,IAAU,MAAM;AAClB,IAAAF,EAAe,EAAI,GACnBH,EAAc,EAAI;AAAA,EACtB;AAEA,SACI,gBAAAM,EAAAC,GAAA,EACI,UAAA;AAAA,IAAA,gBAAAC;AAAA,MAAC;AAAA,MAAA;AAAA,QACG,MAAK;AAAA,QACL,cAAY,kBAAkBZ,CAAG;AAAA,QACjC,SAASS;AAAA,QACT,WAAW,+JAA+JI,CAAU;AAAA,QAMpL,UAAA,gBAAAD;AAAA,UAAC;AAAA,UAAA;AAAA,YAEG,KAAAb;AAAA,YACA,KAAAC;AAAA,YACA,SAAQ;AAAA,YACR,UAAS;AAAA,YACT,SAASE,IAAU,MAAMA,EAAA,IAAY;AAAA,YACrC,WAAU;AAAA,UAAA;AAAA,UANLH;AAAA,QAAA;AAAA,MAOT;AAAA,IAAA;AAAA,IAEHO,KACG,gBAAAM;AAAA,MAACE;AAAA,MAAA;AAAA,QACG,MAAMX;AAAA,QACN,SAASK;AAAA,QACT,OAAOP,KAASD;AAAA,QAChB,MAAK;AAAA,QACL,SAAQ;AAAA,QAIR,UAAA,gBAAAU,EAAC,OAAA,EAAI,WAAU,2DACX,UAAA;AAAA,UAAA,gBAAAE;AAAA,YAAC;AAAA,YAAA;AAAA,cACG,MAAK;AAAA,cACL,cAAW;AAAA,cACX,SAASJ;AAAA,cACT,WAAW,qEAAqEO,CAAgB;AAAA,YAAA;AAAA,UAAA;AAAA,UAEpG,gBAAAH;AAAA,YAAC;AAAA,YAAA;AAAA,cAEG,KAAAb;AAAA,cACA,KAAAC;AAAA,cACA,WAAU;AAAA,YAAA;AAAA,YAHLD;AAAA,UAAA;AAAA,QAIT,EAAA,CACJ;AAAA,MAAA;AAAA,IAAA;AAAA,EACJ,GAER;AAER;"}
1
+ {"version":3,"file":"ZoomableImage.js","sources":["../../src/components/ZoomableImage.tsx"],"sourcesContent":["import type React from 'react';\nimport { useEffect, useRef, useState } from 'react';\nimport { createPortal } from 'react-dom';\nimport DismissIcon from './CustomIcons/DismissIcon';\nimport Modal from './Modal';\nimport { pushEscapeLayer } from './escapeLayers';\nimport { FOCUS_RING, FOCUS_RING_INSET } from './focusRing';\nimport { useSidePanelOverlay } from './sidePanelOverlay';\n\nconst OUT_MS = 230;\n\nconst prefersReducedMotion = (): boolean =>\n typeof window !== 'undefined' &&\n typeof window.matchMedia === 'function' &&\n window.matchMedia('(prefers-reduced-motion: reduce)').matches;\n\nconst play = (\n element: HTMLElement | null,\n keyframes: Keyframe[],\n options: KeyframeAnimationOptions,\n) => {\n if (element && typeof element.animate === 'function' && !prefersReducedMotion()) {\n element.animate(keyframes, { fill: 'both', ...options });\n }\n};\n\ninterface PanelLightboxProps {\n src: string;\n alt: string;\n label: string;\n onClose: () => void;\n}\n\n/**\n * The enlarged image inside a SidePanel: over the panel and its aside, on a blurred veil,\n * rather than over the whole window. A click on the veil, the close button or Escape closes it.\n */\nconst PanelLightbox: React.FC<PanelLightboxProps> = ({ src, alt, label, onClose }) => {\n const veilRef = useRef<HTMLDivElement | null>(null);\n const frameRef = useRef<HTMLDivElement | null>(null);\n const closeRef = useRef<HTMLButtonElement | null>(null);\n const closing = useRef(false);\n const onCloseRef = useRef(onClose);\n useEffect(() => {\n onCloseRef.current = onClose;\n });\n\n const close = () => {\n if (closing.current) {\n return;\n }\n closing.current = true;\n play(veilRef.current, [{ opacity: 1 }, { opacity: 0 }], {\n duration: 200,\n delay: 20,\n easing: 'ease-in',\n });\n play(\n frameRef.current,\n [\n { opacity: 1, transform: 'none' },\n { opacity: 0, transform: 'translateY(4px) scale(0.97)' },\n ],\n { duration: 180, easing: 'cubic-bezier(0.4, 0, 1, 1)' },\n );\n setTimeout(() => onCloseRef.current(), prefersReducedMotion() ? 0 : OUT_MS);\n };\n\n useEffect(() => {\n play(veilRef.current, [{ opacity: 0 }, { opacity: 1 }], {\n duration: 220,\n easing: 'ease-out',\n });\n play(\n frameRef.current,\n [\n { opacity: 0, transform: 'translateY(6px) scale(0.97)' },\n { opacity: 1, transform: 'none' },\n ],\n { duration: 280, delay: 40, easing: 'cubic-bezier(0.2, 0.8, 0.2, 1)' },\n );\n closeRef.current?.focus({ preventScroll: true });\n return pushEscapeLayer(() => closeRef.current?.click());\n }, []);\n\n return (\n <div\n role=\"dialog\"\n aria-modal=\"true\"\n aria-label={label}\n className=\"pointer-events-auto absolute inset-0\"\n >\n <div\n ref={veilRef}\n aria-hidden=\"true\"\n onClick={close}\n className=\"absolute inset-0 cursor-zoom-out rounded-[16px]\"\n style={{\n background:\n 'color-mix(in srgb, var(--malachite-card-background, rgb(255, 255, 255)) 8%, transparent)',\n backdropFilter: 'blur(5px)',\n WebkitBackdropFilter: 'blur(5px)',\n }}\n />\n <div className=\"pointer-events-none absolute inset-[20px] flex items-center justify-center\">\n <div\n ref={frameRef}\n className=\"pointer-events-auto relative flex max-h-full max-w-full\"\n >\n <img\n src={src}\n alt={alt}\n className=\"block max-h-full max-w-full rounded-[16px] object-contain [box-shadow:var(--malachite-shadow-lg)]\"\n />\n <button\n ref={closeRef}\n type=\"button\"\n aria-label=\"Close enlarged image\"\n title=\"Close\"\n onClick={close}\n className={`absolute top-[8px] right-[8px] flex h-[30px] w-[30px] cursor-pointer items-center justify-center rounded-[12px] border border-solid border-[var(--malachite-card-border)] bg-[var(--malachite-card-background)] p-0 text-[var(--malachite-text-primary)] ${FOCUS_RING}`}\n >\n <DismissIcon size={10} />\n </button>\n </div>\n </div>\n </div>\n );\n};\n\nexport interface ZoomableImageProps {\n src: string;\n /**\n * Describes the image. Required and non-empty: it names the thumbnail's button and the\n * enlarged view, so an empty `alt` leaves both unnamed.\n */\n alt: string;\n /** Names the enlarged view for assistive tech. Default: `alt`, also when `title` is empty. */\n title?: string;\n /**\n * The thumbnail failed to load, so the caller can leave the image out. A thumbnail loads\n * lazily, so for one below the fold this fires once it nears the viewport, not on render.\n */\n onError?: () => void;\n}\n\n/**\n * An image that enlarges on click, for a screenshot too detailed to read inline. The enlarged\n * image is as large as the window allows at its own aspect ratio, up to its natural size, and a\n * click anywhere closes it. Inside a SidePanel it enlarges over the panel and its aside instead\n * of the whole window.\n */\nconst ZoomableImage: React.FC<ZoomableImageProps> = ({ src, alt, title, onError }) => {\n const overlay = useSidePanelOverlay();\n const thumbnailRef = useRef<HTMLButtonElement | null>(null);\n const [isEnlarged, setIsEnlarged] = useState(false);\n // Latched on first enlarge, so an idle thumbnail mounts no Modal; never reset, so the exit transition still plays.\n const [hasEnlarged, setHasEnlarged] = useState(false);\n const close = () => setIsEnlarged(false);\n const enlarge = () => {\n setHasEnlarged(true);\n setIsEnlarged(true);\n };\n\n return (\n <>\n <button\n ref={thumbnailRef}\n type=\"button\"\n aria-label={`Enlarge image: ${alt}`}\n onClick={enlarge}\n className={`block max-h-[240px] w-fit max-w-full cursor-zoom-in overflow-hidden rounded-lg border border-solid border-[var(--malachite-card-border)] bg-transparent p-0 ${FOCUS_RING}`}\n >\n {/* At its own width up to the container's, never stretched. The button, not the image,\n caps the height and clips a tall image to its top: a `max-h` on the image would\n narrow it instead, and the button would fit that narrower width.\n Keyed on `src`: a reused <img> keeps drawing the old image until the new one loads. */}\n <img\n key={src}\n src={src}\n alt={alt}\n loading=\"lazy\"\n decoding=\"async\"\n onError={onError ? () => onError() : undefined}\n className=\"block h-auto w-full\"\n />\n </button>\n {overlay !== null &&\n isEnlarged &&\n createPortal(\n <PanelLightbox\n key={src}\n src={src}\n alt={alt}\n label={title || alt}\n onClose={() => {\n close();\n thumbnailRef.current?.focus({ preventScroll: true });\n }}\n />,\n overlay,\n )}\n {overlay === null && hasEnlarged && (\n <Modal\n open={isEnlarged}\n onClose={close}\n title={title || alt}\n size=\"fullscreen\"\n surface=\"none\"\n >\n {/* The image sits beside the close button, not inside it: a button's children are\n presentational, so an image inside it would never reach assistive tech. */}\n <div className=\"relative flex h-full w-full items-center justify-center\">\n <button\n type=\"button\"\n aria-label=\"Close enlarged image\"\n onClick={close}\n className={`absolute inset-0 z-10 cursor-zoom-out border-0 bg-transparent p-0 ${FOCUS_RING_INSET}`}\n />\n <img\n key={src}\n src={src}\n alt={alt}\n className=\"max-h-full max-w-full rounded-lg object-contain\"\n />\n </div>\n </Modal>\n )}\n </>\n );\n};\n\nexport { ZoomableImage };\nexport default ZoomableImage;\n"],"names":["OUT_MS","prefersReducedMotion","play","element","keyframes","options","PanelLightbox","src","alt","label","onClose","veilRef","useRef","frameRef","closeRef","closing","onCloseRef","useEffect","close","_a","pushEscapeLayer","jsxs","jsx","FOCUS_RING","DismissIcon","ZoomableImage","title","onError","overlay","useSidePanelOverlay","thumbnailRef","isEnlarged","setIsEnlarged","useState","hasEnlarged","setHasEnlarged","enlarge","Fragment","createPortal","Modal","FOCUS_RING_INSET"],"mappings":";;;;;;;;AASA,MAAMA,IAAS,KAETC,IAAuB,MACzB,OAAO,SAAW,OAClB,OAAO,OAAO,cAAe,cAC7B,OAAO,WAAW,kCAAkC,EAAE,SAEpDC,IAAO,CACTC,GACAC,GACAC,MACC;AACD,EAAIF,KAAW,OAAOA,EAAQ,WAAY,cAAc,CAACF,OACrDE,EAAQ,QAAQC,GAAW,EAAE,MAAM,QAAQ,GAAGC,GAAS;AAE/D,GAaMC,IAA8C,CAAC,EAAE,KAAAC,GAAK,KAAAC,GAAK,OAAAC,GAAO,SAAAC,QAAc;AAClF,QAAMC,IAAUC,EAA8B,IAAI,GAC5CC,IAAWD,EAA8B,IAAI,GAC7CE,IAAWF,EAAiC,IAAI,GAChDG,IAAUH,EAAO,EAAK,GACtBI,IAAaJ,EAAOF,CAAO;AACjC,EAAAO,EAAU,MAAM;AACZ,IAAAD,EAAW,UAAUN;AAAA,EACzB,CAAC;AAED,QAAMQ,IAAQ,MAAM;AAChB,IAAIH,EAAQ,YAGZA,EAAQ,UAAU,IAClBb,EAAKS,EAAQ,SAAS,CAAC,EAAE,SAAS,EAAA,GAAK,EAAE,SAAS,EAAA,CAAG,GAAG;AAAA,MACpD,UAAU;AAAA,MACV,OAAO;AAAA,MACP,QAAQ;AAAA,I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Q;AAAA,YACR,UAAS;AAAA,YACT,SAASmB,IAAU,MAAMA,EAAA,IAAY;AAAA,YACrC,WAAU;AAAA,UAAA;AAAA,UANLpB;AAAA,QAAA;AAAA,MAOT;AAAA,IAAA;AAAA,IAEHqB,MAAY,QACTG,KACAO;AAAA,MACI,gBAAAhB;AAAA,QAAChB;AAAA,QAAA;AAAA,UAEG,KAAAC;AAAA,UACA,KAAAC;AAAA,UACA,OAAOkB,KAASlB;AAAA,UAChB,SAAS,MAAM;;AACX,YAAAU,EAAA,IACAC,IAAAW,EAAa,YAAb,QAAAX,EAAsB,MAAM,EAAE,eAAe;UACjD;AAAA,QAAA;AAAA,QAPKZ;AAAA,MAAA;AAAA,MASTqB;AAAA,IAAA;AAAA,IAEPA,MAAY,QAAQM,KACjB,gBAAAZ;AAAA,MAACiB;AAAA,MAAA;AAAA,QACG,MAAMR;AAAA,QACN,SAASb;AAAA,QACT,OAAOQ,KAASlB;AAAA,QAChB,MAAK;AAAA,QACL,SAAQ;AAAA,QAIR,UAAA,gBAAAa,EAAC,OAAA,EAAI,WAAU,2DACX,UAAA;AAAA,UAAA,gBAAAC;AAAA,YAAC;AAAA,YAAA;AAAA,cACG,MAAK;AAAA,cACL,cAAW;AAAA,cACX,SAASJ;AAAA,cACT,WAAW,qEAAqEsB,CAAgB;AAAA,YAAA;AAAA,UAAA;AAAA,UAEpG,gBAAAlB;AAAA,YAAC;AAAA,YAAA;AAAA,cAEG,KAAAf;AAAA,cACA,KAAAC;AAAA,cACA,WAAU;AAAA,YAAA;AAAA,YAHLD;AAAA,UAAA;AAAA,QAIT,EAAA,CACJ;AAAA,MAAA;AAAA,IAAA;AAAA,EACJ,GAER;AAER;"}
@@ -0,0 +1,7 @@
1
+ import { createContext as e, useContext as t } from "react";
2
+ const n = e(null), l = () => t(n);
3
+ export {
4
+ n as SidePanelOverlayContext,
5
+ l as useSidePanelOverlay
6
+ };
7
+ //# sourceMappingURL=sidePanelOverlay.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sidePanelOverlay.js","sources":["../../src/components/sidePanelOverlay.ts"],"sourcesContent":["import { createContext, useContext } from 'react';\n\n/**\n * A layer over the open SidePanel, its aside included, for something shown above both, such\n * as an enlarged image. Null outside a SidePanel.\n */\nexport const SidePanelOverlayContext = createContext<HTMLElement | null>(null);\n\nexport const useSidePanelOverlay = (): HTMLElement | null => useContext(SidePanelOverlayContext);\n"],"names":["SidePanelOverlayContext","createContext","useSidePanelOverlay","useContext"],"mappings":";AAMO,MAAMA,IAA0BC,EAAkC,IAAI,GAEhEC,IAAsB,MAA0BC,EAAWH,CAAuB;"}
package/dist/index.d.ts CHANGED
@@ -1191,6 +1191,12 @@ export declare interface ClampTextProps {
1191
1191
  children: default_2.ReactNode;
1192
1192
  lines?: number;
1193
1193
  expandOnHover?: boolean;
1194
+ /**
1195
+ * Ends text that runs past `lines` with `… Read More` in the accent, which opens it in full
1196
+ * and follows it as `Show Less`. Instead of `expandOnHover`, which it turns off. The text should
1197
+ * flow inline, e.g. a `MarkdownBlock` with `variant="flow"`, so `Show Less` follows its last word.
1198
+ */
1199
+ expandable?: boolean;
1194
1200
  className?: string;
1195
1201
  }
1196
1202
 
@@ -1633,6 +1639,7 @@ export declare const CustomIcons: {
1633
1639
  McpIcon: FC<IconProps>;
1634
1640
  MembersIcon: FC<IconProps>;
1635
1641
  ModalIcon: FC<IconProps>;
1642
+ MinusIcon: FC<IconProps>;
1636
1643
  MoreHorizontalIcon: FC<IconProps>;
1637
1644
  MoreVerticalIcon: FC<IconProps>;
1638
1645
  NavbarCollapseIcon: FC<IconProps>;
@@ -1881,7 +1888,7 @@ export declare const DoubleCheckIcon: React.FC<IconProps_47>;
1881
1888
 
1882
1889
  export declare const DownloadIcon: React.FC<IconProps_48>;
1883
1890
 
1884
- export declare const Dropdown: ({ items, onItemSelected, defaultValue, value, disabled, error, tone, label, hint, hintIcon, rightSideContent, tooltip, name, required, requiredIndicator, loading, menuLoading, formControl, description, helperText, placeholder, search, onSearchChange, showSubtitleInTrigger, subtitleLayout, clearable, size, fullWidth, width, minWidth, menuAlign, id, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, }: DropdownProps) => JSX_2.Element;
1891
+ export declare const Dropdown: ({ items, onItemSelected, defaultValue, value, disabled, error, tone, label, hint, hintIcon, rightSideContent, tooltip, name, required, requiredIndicator, loading, menuLoading, formControl, description, helperText, placeholder, search, onSearchChange, showSubtitleInTrigger, triggerTooltip, subtitleLayout, wrapSubtitles, clearable, size, fullWidth, width, minWidth, menuAlign, id, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, }: DropdownProps) => JSX_2.Element;
1885
1892
 
1886
1893
  declare interface DropdownBaseProps {
1887
1894
  label?: string;
@@ -1911,6 +1918,12 @@ declare interface DropdownBaseProps {
1911
1918
  helperText?: default_2.ReactNode;
1912
1919
  placeholder?: string;
1913
1920
  subtitleLayout?: SubtitleLayout;
1921
+ /**
1922
+ * With `subtitleLayout="stacked"`: each option's subtitle wraps to show in full in the open
1923
+ * list, rather than ending in an ellipsis. For a short list, where each option needs its
1924
+ * whole description to be told apart; a long list grows uneven rows.
1925
+ */
1926
+ wrapSubtitles?: boolean;
1914
1927
  /** Adds a clear control to the trigger, reported as `onItemSelected(undefined)`. */
1915
1928
  clearable?: boolean;
1916
1929
  /** 'large' (42px) for form inputs; 'medium' (32px) for toolbar chips; 'small' (28px) beside a title. */
@@ -1972,10 +1985,16 @@ declare type DropdownTriggerModeProps = {
1972
1985
  search?: false;
1973
1986
  /** Promotes the selected item's `subtitle` into the closed trigger, beneath the value. */
1974
1987
  showSubtitleInTrigger?: boolean;
1988
+ /**
1989
+ * With `showSubtitleInTrigger`: a tooltip on the trigger carrying whichever lines it cut
1990
+ * off. Off where opening the menu is the way to read them, as its options wrap. Default: on.
1991
+ */
1992
+ triggerTooltip?: boolean;
1975
1993
  onSearchChange?: never;
1976
1994
  } | {
1977
1995
  search: true;
1978
1996
  showSubtitleInTrigger?: never;
1997
+ triggerTooltip?: never;
1979
1998
  /**
1980
1999
  * Called with the query as typed, and with `''` when a pick, a clear, Escape or a click
1981
2000
  * outside empties it. For offering the typed text as an item of its own: items are still
@@ -2077,6 +2096,12 @@ export declare interface FieldBlockProps {
2077
2096
  /** Sits at the far end of the label row — a copy button, a link. */
2078
2097
  action?: default_2.ReactNode;
2079
2098
  helperText?: default_2.ReactNode;
2099
+ /**
2100
+ * `field` sets the content at an input's full width, under the label rather than in from it,
2101
+ * and lines the action up with the button an input ends with (its copy button, say). For
2102
+ * content that is itself a box, such as a list, set among inputs.
2103
+ */
2104
+ variant?: 'default' | 'field';
2080
2105
  children: default_2.ReactNode;
2081
2106
  className?: string;
2082
2107
  style?: default_2.CSSProperties;
@@ -2425,6 +2450,82 @@ export declare interface GroupedStepperProps extends StepperBaseProps {
2425
2450
  steps?: never;
2426
2451
  }
2427
2452
 
2453
+ /**
2454
+ * Jumps to a step of a `GuideTimeline`. Its button shows the step the reader is on; the menu lists
2455
+ * every section, with the steps of the current one indented under it. Sections already
2456
+ * passed read in the accent colour.
2457
+ */
2458
+ export declare const GuideJumpMenu: default_2.FC<GuideJumpMenuProps>;
2459
+
2460
+ export declare interface GuideJumpMenuProps {
2461
+ sections: GuideTimelineSection[];
2462
+ /** The step the reader is on, as `GuideTimeline`'s `active`. */
2463
+ active?: string;
2464
+ onSelect: (key: string) => void;
2465
+ /** Names the menu. Default: `Jump to step`. */
2466
+ label?: string;
2467
+ }
2468
+
2469
+ /**
2470
+ * Where the reader is in a `GuideTimeline`: `Step 2.2 · title`, and a bar cut into one
2471
+ * segment per section, each as long as its steps and filling as they are passed. For a footer.
2472
+ */
2473
+ export declare const GuideProgress: default_2.FC<GuideProgressProps>;
2474
+
2475
+ export declare interface GuideProgressProps {
2476
+ sections: GuideTimelineSection[];
2477
+ /** The step the reader is on, as `GuideTimeline`'s `active`. */
2478
+ active?: string;
2479
+ /** Names the bar. Default: `Progress`. */
2480
+ 'aria-label'?: string;
2481
+ }
2482
+
2483
+ /**
2484
+ * A guide laid out as one scrolling column: each section a heading with a numbered mark, its
2485
+ * steps strung on a rail below it, coded `1.1`, `1.2` so a step names its section without the
2486
+ * heading in view. Marks before the
2487
+ * `active` step show a check. Place it in a scrolling container with no padding of its own,
2488
+ * such as a SidePanel aside with `bodyPadding: false`; it reports the step scrolled to the
2489
+ * top through `onActiveChange`, and scrolls to a step when `active` is set to it.
2490
+ */
2491
+ export declare const GuideTimeline: default_2.FC<GuideTimelineProps>;
2492
+
2493
+ /** One place a reader can be: a step, or a section that has no steps. */
2494
+ export declare interface GuideTimelinePosition {
2495
+ key: string;
2496
+ /** `2.2` for a section's second step, `3` for a section without steps. */
2497
+ code: string;
2498
+ title: string;
2499
+ sectionIndex: number;
2500
+ }
2501
+
2502
+ export declare const guideTimelinePositions: (sections: readonly GuideTimelineSection[]) => GuideTimelinePosition[];
2503
+
2504
+ export declare interface GuideTimelineProps {
2505
+ sections: GuideTimelineSection[];
2506
+ /** The step in view. Setting it to a step the reader is not on scrolls there. */
2507
+ active?: string;
2508
+ /** Called as the reader scrolls another step to the top, so a menu or progress bar can follow. */
2509
+ onActiveChange?: (key: string) => void;
2510
+ /** After the last section, such as what to do once the steps are done. */
2511
+ end?: default_2.ReactNode;
2512
+ 'aria-label'?: string;
2513
+ }
2514
+
2515
+ export declare interface GuideTimelineSection {
2516
+ key: string;
2517
+ title: string;
2518
+ /** Under the section's heading, above its steps. A section without steps is this alone. */
2519
+ description?: default_2.ReactNode;
2520
+ steps: GuideTimelineStep[];
2521
+ }
2522
+
2523
+ export declare interface GuideTimelineStep {
2524
+ key: string;
2525
+ title: string;
2526
+ children?: default_2.ReactNode;
2527
+ }
2528
+
2428
2529
  export declare const Hexagon: default_2.FC<HexagonProps>;
2429
2530
 
2430
2531
  export declare interface HexagonProps {
@@ -3602,6 +3703,8 @@ export declare interface LinkProps {
3602
3703
  color?: 'default' | 'dimmed';
3603
3704
  size?: FontSize;
3604
3705
  underline?: boolean;
3706
+ /** Lets the link shrink as a flex item and ends an overflowing label with an ellipsis; a wrapper around the link must shrink too. */
3707
+ truncate?: boolean;
3605
3708
  onClick?: default_2.MouseEventHandler<HTMLAnchorElement>;
3606
3709
  /** Renders a root-relative href through the app's router instead of a new-tab anchor, without `target` or `rel`. Other hrefs keep the anchor. */
3607
3710
  renderLink?: RenderLink;
@@ -4196,6 +4299,8 @@ export declare const McpIcon: React.FC<IconProps_81>;
4196
4299
 
4197
4300
  export declare const MembersIcon: React.FC<IconProps_82>;
4198
4301
 
4302
+ export declare const MinusIcon: React.FC<IconProps_84>;
4303
+
4199
4304
  export declare const Modal: default_2.FC<ModalProps>;
4200
4305
 
4201
4306
  export declare const ModalIcon: React.FC<IconProps_83>;
@@ -4280,9 +4385,9 @@ export declare type ModalSurface = 'card' | 'none';
4280
4385
 
4281
4386
  export declare type ModalTrayTone = 'neutral' | 'warning' | 'error' | 'success';
4282
4387
 
4283
- export declare const MoreHorizontalIcon: React.FC<IconProps_84>;
4388
+ export declare const MoreHorizontalIcon: React.FC<IconProps_85>;
4284
4389
 
4285
- export declare const MoreVerticalIcon: React.FC<IconProps_85>;
4390
+ export declare const MoreVerticalIcon: React.FC<IconProps_86>;
4286
4391
 
4287
4392
  export declare const MultiSelect: default_2.FC<MultiSelectProps>;
4288
4393
 
@@ -4376,9 +4481,9 @@ export declare type MultiSelectSize = 'small' | 'medium' | 'large';
4376
4481
 
4377
4482
  declare type NativeProps = Omit<default_2.HTMLAttributes<HTMLElement>, 'children' | 'className' | 'style' | 'color' | 'title'>;
4378
4483
 
4379
- export declare const NavbarCollapseIcon: React.FC<IconProps_86>;
4484
+ export declare const NavbarCollapseIcon: React.FC<IconProps_87>;
4380
4485
 
4381
- export declare const NavbarExpandIcon: React.FC<IconProps_87>;
4486
+ export declare const NavbarExpandIcon: React.FC<IconProps_88>;
4382
4487
 
4383
4488
  export declare const NavItem: default_2.ForwardRefExoticComponent<NavItemProps & default_2.RefAttributes<HTMLElement>>;
4384
4489
 
@@ -4426,7 +4531,7 @@ export declare interface NavItemLinkProps extends NavItemBaseProps {
4426
4531
 
4427
4532
  export declare type NavItemProps = NavItemLinkProps | NavItemAsChildProps;
4428
4533
 
4429
- export declare const NotFoundIcon: React.FC<IconProps_88>;
4534
+ export declare const NotFoundIcon: React.FC<IconProps_89>;
4430
4535
 
4431
4536
  export declare const NumberTag: default_2.FC<NumberTagProps>;
4432
4537
 
@@ -4441,7 +4546,7 @@ export declare interface NumberTagProps {
4441
4546
  className?: string;
4442
4547
  }
4443
4548
 
4444
- export declare const OrganizationIcon: React.FC<IconProps_89>;
4549
+ export declare const OrganizationIcon: React.FC<IconProps_90>;
4445
4550
 
4446
4551
  export declare const OverflowRow: default_2.FC<OverflowRowProps>;
4447
4552
 
@@ -4647,11 +4752,11 @@ declare type PillButtonTone = 'default' | 'assistant';
4647
4752
 
4648
4753
  declare type PillButtonVariant = 'default' | 'inverted';
4649
4754
 
4650
- export declare const PinIcon: React.FC<IconProps_90>;
4755
+ export declare const PinIcon: React.FC<IconProps_91>;
4651
4756
 
4652
- export declare const PlaygroundIcon: React.FC<IconProps_91>;
4757
+ export declare const PlaygroundIcon: React.FC<IconProps_92>;
4653
4758
 
4654
- export declare const PlusIcon: React.FC<IconProps_92>;
4759
+ export declare const PlusIcon: React.FC<IconProps_84>;
4655
4760
 
4656
4761
  export declare const Popover: default_2.FC<PopoverProps> & {
4657
4762
  Header: default_2.FC< PopoverHeaderProps>;
@@ -5025,6 +5130,11 @@ export declare type RightSideContent = {
5025
5130
  type: 'button';
5026
5131
  text: string;
5027
5132
  onClick: () => void;
5133
+ } | {
5134
+ /** A status beside the label, such as a value chosen for the reader: `Preselected`. */
5135
+ type: 'tag';
5136
+ text: string;
5137
+ tagType?: TagType;
5028
5138
  };
5029
5139
 
5030
5140
  declare const Row: default_2.FC<KeyValueListRowProps>;
@@ -5404,6 +5514,23 @@ export declare interface SidePanelAside {
5404
5514
  footer?: default_2.ReactNode;
5405
5515
  /** Whether the aside's body gets default padding, as the panel's `bodyPadding`. Default: true. */
5406
5516
  bodyPadding?: boolean;
5517
+ /**
5518
+ * `detached` draws the aside as a card of its own on the warm ground, tucked behind the
5519
+ * panel's left edge, which slides out from behind it and back. Default: `column`, a column
5520
+ * of the panel itself.
5521
+ */
5522
+ layout?: 'column' | 'detached';
5523
+ /** `detached` only: whether the card is out. Default: true. */
5524
+ open?: boolean;
5525
+ /**
5526
+ * `detached` only: adds a button to the card's header that tucks it away, and while it is
5527
+ * away a tab on the panel's edge that brings it back.
5528
+ */
5529
+ onOpenChange?: (open: boolean) => void;
5530
+ /** `detached` only: the edge tab's text. Default: `Open ` and the title. */
5531
+ tabLabel?: string;
5532
+ /** `detached` only: an icon before the edge tab's text, as the control that opens the aside shows. */
5533
+ tabIcon?: default_2.ReactNode;
5407
5534
  children: default_2.ReactNode;
5408
5535
  }
5409
5536
 
@@ -5435,6 +5562,8 @@ export declare interface SidePanelProps {
5435
5562
  subtitle?: default_2.ReactNode;
5436
5563
  /** `below` stacks the subtitle under the title, so neither truncates the other. */
5437
5564
  subtitlePlacement?: 'inline' | 'below';
5565
+ /** With the subtitle `below`: content at the far end of the subtitle's row, such as what comes next. */
5566
+ subtitleExtra?: default_2.ReactNode;
5438
5567
  /** Content at the end of the title row, after the subtitle (e.g. a status tag). */
5439
5568
  titleExtra?: default_2.ReactNode;
5440
5569
  /** Block paragraph below the title row, spanning the header width. Announced as the panel's description. */
@@ -5486,6 +5615,14 @@ export declare interface SidePanelProps {
5486
5615
  aside?: SidePanelAside;
5487
5616
  /** A drill-in raised over the body and footer, dimming the header; see `SidePanelSheet`. */
5488
5617
  sheet?: SidePanelSheet;
5618
+ /** How far through a multi-step form, from 0 to 1: a line along the foot of the header, or
5619
+ * of the `subheader` when there is one. */
5620
+ progress?: number;
5621
+ /**
5622
+ * A band under the header, above the body, with a rule below it: a wizard's step and what
5623
+ * comes next, say. It leaves the header at its usual height, level with the page's own.
5624
+ */
5625
+ subheader?: default_2.ReactNode;
5489
5626
  children: default_2.ReactNode;
5490
5627
  }
5491
5628
 
@@ -6775,7 +6912,8 @@ export declare interface WizardLayoutProps {
6775
6912
  /**
6776
6913
  * An image that enlarges on click, for a screenshot too detailed to read inline. The enlarged
6777
6914
  * image is as large as the window allows at its own aspect ratio, up to its natural size, and a
6778
- * click anywhere closes it.
6915
+ * click anywhere closes it. Inside a SidePanel it enlarges over the panel and its aside instead
6916
+ * of the whole window.
6779
6917
  */
6780
6918
  export declare const ZoomableImage: default_2.FC<ZoomableImageProps>;
6781
6919