@mechane-ai/elements 0.8.0 → 0.10.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 (94) hide show
  1. package/NOTICE +24 -0
  2. package/README.md +67 -40
  3. package/dist/ai.js +274 -209
  4. package/dist/{categorical-values-dGbaZ0tp.js → categorical-values-DLRE4EEW.js} +4 -4
  5. package/dist/{chart-frame-DgPdIguO.js → chart-frame-et6f6Vhg.js} +22 -14
  6. package/dist/{chart-input-Sac4StHN.js → chart-input-CdLkFomi.js} +2 -2
  7. package/dist/charts/cartesian.js +529 -450
  8. package/dist/charts/distribution.js +302 -261
  9. package/dist/charts/graph.js +137 -103
  10. package/dist/charts/hierarchy.js +7 -7
  11. package/dist/charts/matrix.js +187 -174
  12. package/dist/charts/timeline.js +118 -92
  13. package/dist/charts.js +1 -1
  14. package/dist/code-block-D77maJBB.js +180 -0
  15. package/dist/collections.js +388 -300
  16. package/dist/content/code.js +1 -1
  17. package/dist/content/diff.js +81 -63
  18. package/dist/content/link.js +1 -1
  19. package/dist/content/markdown.js +115 -96
  20. package/dist/content/tree.js +43 -38
  21. package/dist/{content-link-Dd8gapwc.js → content-link-BpSZeTNK.js} +6 -2
  22. package/dist/content.js +169 -150
  23. package/dist/{assets/stylex.css → elements.css} +862 -338
  24. package/dist/feedback.js +1 -1
  25. package/dist/forms/dates.js +31 -31
  26. package/dist/forms.js +1 -1
  27. package/dist/index.js +1 -1
  28. package/dist/layout.js +286 -187
  29. package/dist/navigation/commands.js +45 -42
  30. package/dist/{navigation-yxK3iQXo.js → navigation-D2_sGy3C.js} +2 -2
  31. package/dist/navigation.js +10 -10
  32. package/dist/overlays.js +1 -1
  33. package/dist/packages/ai/src/conversation.d.ts +2 -1
  34. package/dist/packages/ai/src/index.d.ts +4 -0
  35. package/dist/packages/ai/src/message-action.d.ts +10 -0
  36. package/dist/packages/ai/src/message-boundary.d.ts +6 -0
  37. package/dist/packages/ai/src/message.d.ts +2 -1
  38. package/dist/packages/charts/src/cartesian/bar-chart.d.ts +5 -0
  39. package/dist/packages/charts/src/cartesian/index.d.ts +2 -2
  40. package/dist/packages/charts/src/chart-frame.d.ts +3 -0
  41. package/dist/packages/charts/src/chart-theme.d.ts +2 -1
  42. package/dist/packages/charts/src/distribution/distribution-plot.d.ts +22 -2
  43. package/dist/packages/collections/src/collection-scroll.d.ts +2 -1
  44. package/dist/packages/collections/src/data-table.d.ts +6 -0
  45. package/dist/packages/collections/src/index.d.ts +2 -2
  46. package/dist/packages/collections/src/timeline.d.ts +10 -3
  47. package/dist/packages/content/src/diff/pierre-diff.d.ts +2 -1
  48. package/dist/packages/content/src/viewer-styles.d.ts +64 -0
  49. package/dist/packages/core/src/actions.d.ts +7 -0
  50. package/dist/packages/core/src/agent-avatar-glyphs.d.ts +5 -0
  51. package/dist/packages/core/src/agent-avatar.d.ts +17 -0
  52. package/dist/packages/core/src/copy-value.d.ts +2 -1
  53. package/dist/packages/core/src/index.d.ts +6 -2
  54. package/dist/packages/core/src/surfaces.d.ts +5 -0
  55. package/dist/packages/feedback/src/index.d.ts +4 -1
  56. package/dist/packages/feedback/src/toast.d.ts +5 -27
  57. package/dist/packages/forms/src/agent-avatar-picker.d.ts +8 -0
  58. package/dist/packages/forms/src/field-styles.d.ts +28 -0
  59. package/dist/packages/forms/src/forms.d.ts +2 -1
  60. package/dist/packages/forms/src/index.d.ts +2 -0
  61. package/dist/packages/forms/src/selection-styles.d.ts +18 -2
  62. package/dist/packages/foundations/src/overlay-styles.d.ts +3 -1
  63. package/dist/packages/foundations/src/popup-styles.d.ts +7 -0
  64. package/dist/packages/foundations/src/tokens.stylex.d.ts +61 -0
  65. package/dist/packages/layout/src/app-shell.d.ts +2 -1
  66. package/dist/packages/layout/src/frame.stylex.d.ts +1 -0
  67. package/dist/packages/layout/src/index.d.ts +2 -1
  68. package/dist/packages/layout/src/page-toolbar.d.ts +3 -1
  69. package/dist/packages/layout/src/sidebar.d.ts +7 -1
  70. package/dist/packages/layout/src/view-stack.d.ts +13 -0
  71. package/dist/packages/layout/src/workbench.d.ts +5 -2
  72. package/dist/packages/overlays/src/alert-dialog.d.ts +5 -2
  73. package/dist/packages/overlays/src/dialog.d.ts +7 -3
  74. package/dist/pierre-diff--zsiHCCB.js +71 -0
  75. package/dist/pierre-theme-D9hnHv3Z.js +126 -0
  76. package/dist/{pierre-tree-DdE1boiT.js → pierre-tree-BFxEuxwb.js} +3 -3
  77. package/dist/src-Be7NLG8c.js +1242 -0
  78. package/dist/src-CBspCKfO.js +969 -0
  79. package/dist/src-Cs0dRc4X.js +617 -0
  80. package/dist/src-sU9b0oZW.js +1168 -0
  81. package/dist/theme.js +1 -1
  82. package/dist/tokens.js +69 -10
  83. package/dist/viewer-styles-CpHqp5Qv.js +70 -0
  84. package/package.json +2 -1
  85. package/packages/foundations/src/tokens.stylex.ts +61 -0
  86. package/styles.css +1 -1
  87. package/dist/code-block-BRNdtTaP.js +0 -175
  88. package/dist/pierre-diff-CZdzgiYm.js +0 -66
  89. package/dist/pierre-theme-BpESNIsV.js +0 -96
  90. package/dist/popup-styles-CvtZDE2t.js +0 -135
  91. package/dist/src-Bc5sEhdO.js +0 -680
  92. package/dist/src-CfDf8TY8.js +0 -466
  93. package/dist/src-DV0BNk1M.js +0 -360
  94. package/dist/src-Eg_ytPjv.js +0 -1107
@@ -1,28 +1,6 @@
1
- import { Toast as BaseToast } from '@base-ui/react/toast';
2
- import type { ComponentProps, ReactNode } from 'react';
3
- type ToastViewportProps = ComponentProps<typeof BaseToast.Viewport>;
4
- type ToastRootProps = ComponentProps<typeof BaseToast.Root>;
5
- type ToastContentProps = ComponentProps<typeof BaseToast.Content>;
6
- type ToastTitleProps = ComponentProps<typeof BaseToast.Title>;
7
- type ToastDescriptionProps = ComponentProps<typeof BaseToast.Description>;
8
- type ToastCloseProps = ComponentProps<typeof BaseToast.Close>;
9
- declare function ToastViewport({ className, style, ...props }: ToastViewportProps): ReactNode;
10
- declare function ToastRoot({ className, style, ...props }: ToastRootProps): ReactNode;
11
- declare function ToastContent({ className, style, ...props }: ToastContentProps): ReactNode;
12
- declare function ToastTitle({ className, style, ...props }: ToastTitleProps): ReactNode;
13
- declare function ToastDescription({ className, style, ...props }: ToastDescriptionProps): ReactNode;
14
- declare function ToastClose(props: ToastCloseProps): ReactNode;
15
- export declare const Toast: {
16
- Provider: import("react").FC<import("@base-ui/react").ToastProviderProps>;
17
- Portal: import("react").ForwardRefExoticComponent<Omit<import("@base-ui/react").ToastPortalProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
18
- Viewport: typeof ToastViewport;
19
- Root: typeof ToastRoot;
20
- Content: typeof ToastContent;
21
- Title: typeof ToastTitle;
22
- Description: typeof ToastDescription;
23
- Close: typeof ToastClose;
24
- Action: import("react").ForwardRefExoticComponent<Omit<import("@base-ui/react").ToastActionProps, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
25
- useManager: typeof BaseToast.useToastManager;
26
- createManager: typeof BaseToast.createToastManager;
1
+ import type { ReactNode } from 'react';
2
+ import type { ToasterProps as SonnerToasterProps } from 'sonner';
3
+ export type ToasterProps = Pick<SonnerToasterProps, 'id' | 'position' | 'hotkey' | 'expand' | 'duration' | 'visibleToasts' | 'closeButton' | 'offset' | 'mobileOffset' | 'dir' | 'swipeDirections' | 'containerAriaLabel'> & {
4
+ readonly closeButtonAriaLabel?: string;
27
5
  };
28
- export {};
6
+ export declare function Toaster({ closeButton, closeButtonAriaLabel, offset, mobileOffset, ...props }: ToasterProps): ReactNode;
@@ -0,0 +1,8 @@
1
+ import type { ReactNode } from 'react';
2
+ import type { AgentAppearance } from '../../core/src/index.ts';
3
+ export type AgentAvatarPickerProps = {
4
+ readonly value: AgentAppearance;
5
+ readonly onValueChange: (value: AgentAppearance) => void;
6
+ readonly disabled?: boolean;
7
+ };
8
+ export declare function AgentAvatarPicker({ value, onValueChange, disabled }: AgentAvatarPickerProps): ReactNode;
@@ -6,27 +6,35 @@ export declare const fieldStyles: Readonly<{
6
6
  readonly gap: stylex.StyleXClassNameFor<"gap", string>;
7
7
  readonly minWidth: stylex.StyleXClassNameFor<"minWidth", 0>;
8
8
  readonly fontFamily: stylex.StyleXClassNameFor<"fontFamily", string>;
9
+ readonly fontWeight: stylex.StyleXClassNameFor<"fontWeight", string>;
10
+ readonly WebkitFontSmoothing: stylex.StyleXClassNameFor<"WebkitFontSmoothing", "antialiased">;
9
11
  }>;
10
12
  readonly label: Readonly<{
11
13
  readonly color: stylex.StyleXClassNameFor<"color", string>;
14
+ readonly fontFamily: stylex.StyleXClassNameFor<"fontFamily", string>;
12
15
  readonly fontSize: stylex.StyleXClassNameFor<"fontSize", string>;
16
+ readonly fontWeight: stylex.StyleXClassNameFor<"fontWeight", string>;
13
17
  readonly lineHeight: stylex.StyleXClassNameFor<"lineHeight", string>;
18
+ readonly overflowWrap: stylex.StyleXClassNameFor<"overflowWrap", "anywhere">;
14
19
  }>;
15
20
  readonly description: Readonly<{
16
21
  readonly margin: stylex.StyleXClassNameFor<"margin", 0>;
17
22
  readonly color: stylex.StyleXClassNameFor<"color", string>;
18
23
  readonly fontSize: stylex.StyleXClassNameFor<"fontSize", string>;
19
24
  readonly lineHeight: stylex.StyleXClassNameFor<"lineHeight", string>;
25
+ readonly overflowWrap: stylex.StyleXClassNameFor<"overflowWrap", "anywhere">;
20
26
  }>;
21
27
  readonly error: Readonly<{
22
28
  readonly color: stylex.StyleXClassNameFor<"color", string>;
23
29
  readonly fontSize: stylex.StyleXClassNameFor<"fontSize", string>;
24
30
  readonly lineHeight: stylex.StyleXClassNameFor<"lineHeight", string>;
31
+ readonly overflowWrap: stylex.StyleXClassNameFor<"overflowWrap", "anywhere">;
25
32
  }>;
26
33
  readonly input: Readonly<{
27
34
  readonly display: stylex.StyleXClassNameFor<"display", "block">;
28
35
  readonly boxSizing: stylex.StyleXClassNameFor<"boxSizing", "border-box">;
29
36
  readonly width: stylex.StyleXClassNameFor<"width", "100%">;
37
+ readonly minWidth: stylex.StyleXClassNameFor<"minWidth", 0>;
30
38
  readonly minHeight: stylex.StyleXClassNameFor<"minHeight", string>;
31
39
  readonly backgroundColor: stylex.StyleXClassNameFor<"backgroundColor", string>;
32
40
  readonly color: stylex.StyleXClassNameFor<"color", string>;
@@ -37,6 +45,7 @@ export declare const fieldStyles: Readonly<{
37
45
  readonly paddingBlock: stylex.StyleXClassNameFor<"paddingBlock", string>;
38
46
  readonly paddingInline: stylex.StyleXClassNameFor<"paddingInline", string>;
39
47
  readonly fontFamily: stylex.StyleXClassNameFor<"fontFamily", string>;
48
+ readonly fontWeight: stylex.StyleXClassNameFor<"fontWeight", string>;
40
49
  readonly WebkitFontSmoothing: stylex.StyleXClassNameFor<"WebkitFontSmoothing", "antialiased">;
41
50
  readonly fontSize: stylex.StyleXClassNameFor<"fontSize", string>;
42
51
  readonly lineHeight: stylex.StyleXClassNameFor<"lineHeight", string>;
@@ -68,6 +77,25 @@ export declare const fieldStyles: Readonly<{
68
77
  readonly maxHeight: stylex.StyleXClassNameFor<"maxHeight", "30dvh">;
69
78
  }>;
70
79
  }>;
80
+ export declare const textareaAppearanceStyles: Readonly<{
81
+ readonly field: {};
82
+ readonly plain: Readonly<{
83
+ readonly minHeight: stylex.StyleXClassNameFor<"minHeight", string>;
84
+ readonly maxHeight: stylex.StyleXClassNameFor<"maxHeight", "30dvh">;
85
+ readonly fieldSizing: stylex.StyleXClassNameFor<"fieldSizing", "content">;
86
+ readonly resize: stylex.StyleXClassNameFor<"resize", "none">;
87
+ readonly padding: stylex.StyleXClassNameFor<"padding", 0>;
88
+ readonly borderWidth: stylex.StyleXClassNameFor<"borderWidth", 0>;
89
+ readonly borderRadius: stylex.StyleXClassNameFor<"borderRadius", 0>;
90
+ readonly backgroundColor: stylex.StyleXClassNameFor<"backgroundColor", "transparent">;
91
+ readonly ':focus-visible': stylex.StyleXClassNameFor<":focus-visible", {
92
+ readonly outlineStyle: "none";
93
+ }>;
94
+ readonly ':disabled': stylex.StyleXClassNameFor<":disabled", {
95
+ readonly backgroundColor: "transparent";
96
+ }>;
97
+ }>;
98
+ }>;
71
99
  export declare const inputSizeStyles: Readonly<{
72
100
  readonly sm: Readonly<{
73
101
  readonly minHeight: stylex.StyleXClassNameFor<"minHeight", string>;
@@ -18,6 +18,7 @@ type NativeTextareaProps = ComponentProps<'textarea'>;
18
18
  type TextareaProps = Omit<NativeTextareaProps, 'value' | 'defaultValue' | 'onChange' | 'readOnly'> & TextValueProperties<NonNullable<NativeTextareaProps['value']>, NonNullable<NativeTextareaProps['onChange']>, NonNullable<BaseInputProps['onValueChange']>> & {
19
19
  readonly xstyle?: PlacementStyle;
20
20
  readonly compact?: boolean;
21
+ readonly appearance?: 'field' | 'plain';
21
22
  };
22
23
  declare function FieldRoot({ className, style, xstyle, ...props }: FieldRootProps): ReactNode;
23
24
  declare function FieldLabel({ className, style, ...props }: FieldLabelProps): ReactNode;
@@ -30,5 +31,5 @@ export declare const Field: {
30
31
  Error: typeof FieldError;
31
32
  };
32
33
  export declare function Input({ className, style, xstyle, size, ...props }: InputProps): ReactNode;
33
- export declare function Textarea({ compact, value, defaultValue, onValueChange, name, disabled, readOnly, required, className, style, xstyle, ...props }: TextareaProps): ReactNode;
34
+ export declare function Textarea({ compact, appearance, value, defaultValue, onValueChange, name, disabled, readOnly, required, className, style, xstyle, ...props }: TextareaProps): ReactNode;
34
35
  export {};
@@ -1,4 +1,6 @@
1
1
  export { Combobox } from './combobox.tsx';
2
+ export type { AgentAvatarPickerProps } from './agent-avatar-picker.tsx';
3
+ export { AgentAvatarPicker } from './agent-avatar-picker.tsx';
2
4
  export { FilePicker, Fieldset, InputGroup, NumberField, Slider } from './form-controls.tsx';
3
5
  export { Field, Input, Textarea } from './forms.tsx';
4
6
  export { Select } from './select.tsx';
@@ -15,17 +15,21 @@ export declare const selectionStyles: Readonly<{
15
15
  readonly borderStyle: stylex.StyleXClassNameFor<"borderStyle", "solid">;
16
16
  readonly borderRadius: stylex.StyleXClassNameFor<"borderRadius", string>;
17
17
  readonly fontFamily: stylex.StyleXClassNameFor<"fontFamily", string>;
18
+ readonly fontWeight: stylex.StyleXClassNameFor<"fontWeight", string>;
18
19
  readonly WebkitFontSmoothing: stylex.StyleXClassNameFor<"WebkitFontSmoothing", "antialiased">;
19
20
  readonly fontSize: stylex.StyleXClassNameFor<"fontSize", string>;
20
21
  readonly lineHeight: stylex.StyleXClassNameFor<"lineHeight", string>;
21
22
  readonly textAlign: stylex.StyleXClassNameFor<"textAlign", "left">;
22
23
  readonly color: stylex.StyleXClassNameFor<"color", string>;
23
24
  readonly cursor: stylex.StyleXClassNameFor<"cursor", "pointer">;
24
- readonly ':hover:not([data-disabled])': stylex.StyleXClassNameFor<":hover:not([data-disabled])", {
25
+ readonly ':hover:not(:active, [data-disabled])': stylex.StyleXClassNameFor<":hover:not(:active, [data-disabled])", {
25
26
  readonly backgroundColor: {
26
27
  readonly [conditions.hoverPointer]: stylex.StyleXVar<string>;
27
28
  };
28
29
  }>;
30
+ readonly ':active:not([data-disabled])': stylex.StyleXClassNameFor<":active:not([data-disabled])", {
31
+ readonly backgroundColor: stylex.StyleXVar<string>;
32
+ }>;
29
33
  readonly ':is([data-disabled])': stylex.StyleXClassNameFor<":is([data-disabled])", {
30
34
  readonly opacity: stylex.StyleXVar<string>;
31
35
  readonly cursor: "default";
@@ -67,6 +71,8 @@ export declare const selectionStyles: Readonly<{
67
71
  readonly maxWidth: stylex.StyleXClassNameFor<"maxWidth", "calc(100vw - 16px)">;
68
72
  }>;
69
73
  readonly popup: Readonly<{
74
+ readonly boxSizing: stylex.StyleXClassNameFor<"boxSizing", "border-box">;
75
+ readonly minWidth: stylex.StyleXClassNameFor<"minWidth", 0>;
70
76
  readonly borderWidth: stylex.StyleXClassNameFor<"borderWidth", 1>;
71
77
  readonly borderStyle: stylex.StyleXClassNameFor<"borderStyle", "solid">;
72
78
  readonly borderColor: stylex.StyleXClassNameFor<"borderColor", string>;
@@ -75,6 +81,9 @@ export declare const selectionStyles: Readonly<{
75
81
  readonly backgroundColor: stylex.StyleXClassNameFor<"backgroundColor", string>;
76
82
  readonly color: stylex.StyleXClassNameFor<"color", string>;
77
83
  readonly fontFamily: stylex.StyleXClassNameFor<"fontFamily", string>;
84
+ readonly fontWeight: stylex.StyleXClassNameFor<"fontWeight", string>;
85
+ readonly fontSize: stylex.StyleXClassNameFor<"fontSize", string>;
86
+ readonly lineHeight: stylex.StyleXClassNameFor<"lineHeight", string>;
78
87
  readonly WebkitFontSmoothing: stylex.StyleXClassNameFor<"WebkitFontSmoothing", "antialiased">;
79
88
  readonly boxShadow: stylex.StyleXClassNameFor<"boxShadow", string>;
80
89
  readonly maxHeight: stylex.StyleXClassNameFor<"maxHeight", "var(--available-height)">;
@@ -83,22 +92,29 @@ export declare const selectionStyles: Readonly<{
83
92
  }>;
84
93
  readonly option: Readonly<{
85
94
  readonly display: stylex.StyleXClassNameFor<"display", "flex">;
95
+ readonly boxSizing: stylex.StyleXClassNameFor<"boxSizing", "border-box">;
86
96
  readonly alignItems: stylex.StyleXClassNameFor<"alignItems", "center">;
87
97
  readonly gap: stylex.StyleXClassNameFor<"gap", string>;
88
98
  readonly minHeight: stylex.StyleXClassNameFor<"minHeight", string>;
89
99
  readonly paddingInline: stylex.StyleXClassNameFor<"paddingInline", string>;
100
+ readonly paddingBlock: stylex.StyleXClassNameFor<"paddingBlock", string>;
90
101
  readonly borderRadius: stylex.StyleXClassNameFor<"borderRadius", string>;
91
102
  readonly fontFamily: stylex.StyleXClassNameFor<"fontFamily", string>;
103
+ readonly fontWeight: stylex.StyleXClassNameFor<"fontWeight", string>;
92
104
  readonly WebkitFontSmoothing: stylex.StyleXClassNameFor<"WebkitFontSmoothing", "antialiased">;
93
105
  readonly fontSize: stylex.StyleXClassNameFor<"fontSize", string>;
94
106
  readonly lineHeight: stylex.StyleXClassNameFor<"lineHeight", string>;
107
+ readonly overflowWrap: stylex.StyleXClassNameFor<"overflowWrap", "anywhere">;
95
108
  readonly cursor: stylex.StyleXClassNameFor<"cursor", "pointer">;
96
109
  readonly outlineWidth: stylex.StyleXClassNameFor<"outlineWidth", 0>;
97
110
  readonly ':is([data-highlighted])': stylex.StyleXClassNameFor<":is([data-highlighted])", {
98
111
  readonly backgroundColor: stylex.StyleXVar<string>;
99
112
  }>;
113
+ readonly ':active:not([data-disabled])': stylex.StyleXClassNameFor<":active:not([data-disabled])", {
114
+ readonly backgroundColor: stylex.StyleXVar<string>;
115
+ }>;
100
116
  readonly ':is([data-disabled])': stylex.StyleXClassNameFor<":is([data-disabled])", {
101
- readonly color: stylex.StyleXVar<string>;
117
+ readonly opacity: stylex.StyleXVar<string>;
102
118
  readonly cursor: "default";
103
119
  }>;
104
120
  }>;
@@ -25,8 +25,9 @@ export declare const overlayStyles: Readonly<{
25
25
  readonly WebkitFontSmoothing: stylex.StyleXClassNameFor<"WebkitFontSmoothing", "antialiased">;
26
26
  readonly fontSize: stylex.StyleXClassNameFor<"fontSize", string>;
27
27
  readonly lineHeight: stylex.StyleXClassNameFor<"lineHeight", string>;
28
- readonly fontWeight: stylex.StyleXClassNameFor<"fontWeight", 600>;
28
+ readonly fontWeight: stylex.StyleXClassNameFor<"fontWeight", string>;
29
29
  readonly color: stylex.StyleXClassNameFor<"color", string>;
30
+ readonly overflowWrap: stylex.StyleXClassNameFor<"overflowWrap", "anywhere">;
30
31
  }>;
31
32
  readonly description: Readonly<{
32
33
  readonly margin: stylex.StyleXClassNameFor<"margin", 0>;
@@ -34,6 +35,7 @@ export declare const overlayStyles: Readonly<{
34
35
  readonly WebkitFontSmoothing: stylex.StyleXClassNameFor<"WebkitFontSmoothing", "antialiased">;
35
36
  readonly fontSize: stylex.StyleXClassNameFor<"fontSize", string>;
36
37
  readonly lineHeight: stylex.StyleXClassNameFor<"lineHeight", string>;
38
+ readonly fontWeight: stylex.StyleXClassNameFor<"fontWeight", string>;
37
39
  readonly color: stylex.StyleXClassNameFor<"color", string>;
38
40
  readonly overflowWrap: stylex.StyleXClassNameFor<"overflowWrap", "anywhere">;
39
41
  }>;
@@ -21,6 +21,7 @@ export declare const popupStyles: Readonly<{
21
21
  readonly WebkitFontSmoothing: stylex.StyleXClassNameFor<"WebkitFontSmoothing", "antialiased">;
22
22
  readonly fontSize: stylex.StyleXClassNameFor<"fontSize", string>;
23
23
  readonly lineHeight: stylex.StyleXClassNameFor<"lineHeight", string>;
24
+ readonly fontWeight: stylex.StyleXClassNameFor<"fontWeight", string>;
24
25
  readonly outlineWidth: stylex.StyleXClassNameFor<"outlineWidth", 0>;
25
26
  }>;
26
27
  readonly content: Readonly<{
@@ -37,6 +38,8 @@ export declare const popupStyles: Readonly<{
37
38
  readonly display: stylex.StyleXClassNameFor<"display", "flex">;
38
39
  readonly boxSizing: stylex.StyleXClassNameFor<"boxSizing", "border-box">;
39
40
  readonly alignItems: stylex.StyleXClassNameFor<"alignItems", "center">;
41
+ readonly minWidth: stylex.StyleXClassNameFor<"minWidth", 0>;
42
+ readonly overflowWrap: stylex.StyleXClassNameFor<"overflowWrap", "anywhere">;
40
43
  readonly gap: stylex.StyleXClassNameFor<"gap", string>;
41
44
  readonly minHeight: stylex.StyleXClassNameFor<"minHeight", string>;
42
45
  readonly paddingInline: stylex.StyleXClassNameFor<"paddingInline", string>;
@@ -49,6 +52,9 @@ export declare const popupStyles: Readonly<{
49
52
  readonly ':is([data-highlighted])': stylex.StyleXClassNameFor<":is([data-highlighted])", {
50
53
  readonly backgroundColor: stylex.StyleXVar<string>;
51
54
  }>;
55
+ readonly ':active:not([data-disabled])': stylex.StyleXClassNameFor<":active:not([data-disabled])", {
56
+ readonly backgroundColor: stylex.StyleXVar<string>;
57
+ }>;
52
58
  readonly ':is([data-disabled])': stylex.StyleXClassNameFor<":is([data-disabled])", {
53
59
  readonly opacity: stylex.StyleXVar<string>;
54
60
  readonly cursor: "default";
@@ -66,6 +72,7 @@ export declare const popupStyles: Readonly<{
66
72
  readonly color: stylex.StyleXClassNameFor<"color", string>;
67
73
  readonly fontSize: stylex.StyleXClassNameFor<"fontSize", string>;
68
74
  readonly lineHeight: stylex.StyleXClassNameFor<"lineHeight", string>;
75
+ readonly fontWeight: stylex.StyleXClassNameFor<"fontWeight", string>;
69
76
  }>;
70
77
  readonly separator: Readonly<{
71
78
  readonly height: stylex.StyleXClassNameFor<"height", 1>;
@@ -59,6 +59,58 @@ export declare const darkChartColors: {
59
59
  positive: string;
60
60
  missing: string;
61
61
  };
62
+ export declare const avatarColors: stylex.VarGroup<Readonly<{
63
+ identity1: string;
64
+ identity2: string;
65
+ identity3: string;
66
+ identity4: string;
67
+ identity5: string;
68
+ identity6: string;
69
+ identity7: string;
70
+ identity8: string;
71
+ identity9: string;
72
+ identity10: string;
73
+ identity11: string;
74
+ identity12: string;
75
+ identity13: string;
76
+ identity14: string;
77
+ identity15: string;
78
+ identity16: string;
79
+ identity17: string;
80
+ identity18: string;
81
+ identity19: string;
82
+ identity20: string;
83
+ identity21: string;
84
+ identity22: string;
85
+ identity23: string;
86
+ identity24: string;
87
+ }>, symbol>;
88
+ export declare const darkAvatarColors: {
89
+ identity1: string;
90
+ identity2: string;
91
+ identity3: string;
92
+ identity4: string;
93
+ identity5: string;
94
+ identity6: string;
95
+ identity7: string;
96
+ identity8: string;
97
+ identity9: string;
98
+ identity10: string;
99
+ identity11: string;
100
+ identity12: string;
101
+ identity13: string;
102
+ identity14: string;
103
+ identity15: string;
104
+ identity16: string;
105
+ identity17: string;
106
+ identity18: string;
107
+ identity19: string;
108
+ identity20: string;
109
+ identity21: string;
110
+ identity22: string;
111
+ identity23: string;
112
+ identity24: string;
113
+ };
62
114
  export declare const syntaxColors: stylex.VarGroup<Readonly<{
63
115
  keyword: string;
64
116
  string: string;
@@ -85,9 +137,14 @@ export declare const spacing: stylex.VarGroup<Readonly<{
85
137
  export declare const typography: stylex.VarGroup<Readonly<{
86
138
  fontFamily: string;
87
139
  monoFamily: string;
140
+ regularWeight: string;
141
+ mediumWeight: string;
142
+ strongWeight: string;
143
+ boldWeight: string;
88
144
  bodySize: string;
89
145
  bodyLineHeight: string;
90
146
  multilineLineHeight: string;
147
+ proseLineHeight: string;
91
148
  captionSize: string;
92
149
  captionLineHeight: string;
93
150
  inputSize: string;
@@ -134,6 +191,10 @@ export declare const layers: {
134
191
  tooltip: string;
135
192
  skipLink: string;
136
193
  };
194
+ export declare const tableGeometry: {
195
+ rowHeight: number;
196
+ headerHeight: number;
197
+ };
137
198
  export declare const conditions: {
138
199
  coarsePointer: string;
139
200
  hoverPointer: string;
@@ -5,6 +5,7 @@ type AppShellProps = {
5
5
  readonly footer?: ReactNode;
6
6
  readonly children: ReactNode;
7
7
  readonly mainId?: string;
8
+ readonly focus?: boolean;
8
9
  };
9
- export declare function AppShell({ sidebarHeader, sidebar, footer, children, mainId }: AppShellProps): ReactNode;
10
+ export declare function AppShell({ sidebarHeader, sidebar, footer, children, mainId, focus, }: AppShellProps): ReactNode;
10
11
  export {};
@@ -22,4 +22,5 @@ export declare const frameConditions: {
22
22
  sidebarCoarse: string;
23
23
  detailMobile: string;
24
24
  toolbarCompact: string;
25
+ workbenchCompact: string;
25
26
  };
@@ -2,9 +2,10 @@ export { AppShell } from './app-shell.tsx';
2
2
  export { DetailPage } from './detail-page.tsx';
3
3
  export { FocusPage } from './focus-page.tsx';
4
4
  export { Workbench, WorkbenchScroll, WorkbenchFooter } from './workbench.tsx';
5
+ export { ViewStack } from './view-stack.tsx';
5
6
  export { PageToolbar, ToolbarAction } from './page-toolbar.tsx';
6
7
  export type { RecordPageRootProps, RecordPageToolbarProps, RecordPageBodyProps, RecordPageHeaderProps, RecordPageContentProps, RecordPageAsideProps, } from './record-page.tsx';
7
8
  export { RecordPage } from './record-page.tsx';
8
9
  export type { ResizableRootProps, ResizablePaneProps, ResizableHandleProps } from './resizable.tsx';
9
10
  export { Resizable } from './resizable.tsx';
10
- export { Navigation, NavigationItem, NavigationLink, SidebarLabel, SidebarFooter } from './sidebar.tsx';
11
+ export { Navigation, NavigationSection, NavigationItem, NavigationLink, SidebarLabel, SidebarFooter, } from './sidebar.tsx';
@@ -5,10 +5,12 @@ type PageToolbarProps = {
5
5
  readonly actions?: ReactNode;
6
6
  readonly breadcrumb?: boolean;
7
7
  readonly navigation?: boolean;
8
+ readonly views?: ReactNode;
9
+ readonly leading?: ReactNode;
8
10
  };
9
11
  type ToolbarActionProps = Omit<ComponentProps<typeof Button>, 'variant' | 'size' | 'xstyle'> & {
10
12
  readonly icon?: ReactNode;
11
13
  };
12
- export declare function PageToolbar({ title, actions, breadcrumb, navigation }: PageToolbarProps): ReactNode;
14
+ export declare function PageToolbar({ title, actions, breadcrumb, navigation, views, leading, }: PageToolbarProps): ReactNode;
13
15
  export declare function ToolbarAction({ icon, children, ...props }: ToolbarActionProps): ReactNode;
14
16
  export {};
@@ -33,15 +33,21 @@ type SidebarLabelProps = {
33
33
  readonly children: ReactNode;
34
34
  readonly grow?: boolean;
35
35
  };
36
+ type SidebarFooterLayout = 'inline' | 'navigation';
36
37
  type SidebarFooterProps = {
37
38
  readonly children: ReactNode;
39
+ readonly layout?: SidebarFooterLayout;
38
40
  };
39
41
  export declare function Sidebar({ header, footer, close, children }: SidebarProps): ReactNode;
40
42
  export declare function SidebarClose(): ReactNode;
41
43
  export declare function Navigation({ children, label }: NavigationProps): ReactNode;
44
+ export declare function NavigationSection({ children, label, }: {
45
+ readonly children: ReactNode;
46
+ readonly label: string;
47
+ }): ReactNode;
42
48
  export declare function NavigationItem({ children, icon, selected, onClick, ...props }: NavigationItemProps): ReactNode;
43
49
  export declare function NavigationLink({ children, icon, selected, onClick, className, style, ...props }: NavigationLinkProps): ReactNode;
44
50
  export declare function SidebarLabel({ children, grow }: SidebarLabelProps): ReactNode;
45
- export declare function SidebarFooter({ children }: SidebarFooterProps): ReactNode;
51
+ export declare function SidebarFooter({ children, layout }: SidebarFooterProps): ReactNode;
46
52
  export declare function SidebarToggle(): ReactNode;
47
53
  export {};
@@ -0,0 +1,13 @@
1
+ import type { ReactNode } from 'react';
2
+ declare function ViewStackRoot({ children }: {
3
+ readonly children: ReactNode;
4
+ }): ReactNode;
5
+ declare function ViewStackPanel({ active, children }: {
6
+ readonly active: boolean;
7
+ readonly children: ReactNode;
8
+ }): ReactNode;
9
+ export declare const ViewStack: {
10
+ Root: typeof ViewStackRoot;
11
+ Panel: typeof ViewStackPanel;
12
+ };
13
+ export {};
@@ -1,11 +1,14 @@
1
1
  import type { ReactNode } from 'react';
2
2
  export declare function Workbench({ header, children, inspector, }: {
3
- readonly header: ReactNode;
3
+ readonly header?: ReactNode;
4
4
  readonly children: ReactNode;
5
5
  readonly inspector?: ReactNode;
6
6
  }): ReactNode;
7
- export declare function WorkbenchScroll({ children }: {
7
+ export declare function WorkbenchScroll({ label, children, flush, scrollRestorationId, }: {
8
+ readonly label: string;
8
9
  readonly children: ReactNode;
10
+ readonly flush?: boolean;
11
+ readonly scrollRestorationId?: string;
9
12
  }): ReactNode;
10
13
  export declare function WorkbenchFooter({ children }: {
11
14
  readonly children: ReactNode;
@@ -7,9 +7,12 @@ export declare const AlertDialog: {
7
7
  Root: typeof AlertDialogRoot;
8
8
  Trigger: BaseAlertDialog.Trigger;
9
9
  Portal: import("react").ForwardRefExoticComponent<Omit<import("@base-ui/react").DialogPortalProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
10
- Backdrop: ({ className, style, ...props }: Omit<import("@base-ui/react").DialogBackdropProps, "ref"> & import("react").RefAttributes<HTMLDivElement>) => ReactNode;
11
- Popup: ({ className, style, xstyle, ...props }: Omit<import("@base-ui/react").DialogPopupProps, "ref"> & import("react").RefAttributes<HTMLDivElement> & {
10
+ Backdrop: ({ className, style, motion, ...props }: Omit<import("@base-ui/react").DialogBackdropProps, "ref"> & import("react").RefAttributes<HTMLDivElement> & {
11
+ readonly motion?: "none" | "standard";
12
+ }) => ReactNode;
13
+ Popup: ({ className, style, xstyle, motion, ...props }: Omit<import("@base-ui/react").DialogPopupProps, "ref"> & import("react").RefAttributes<HTMLDivElement> & {
12
14
  readonly xstyle?: import("../../foundations/src/style-composition.ts").PlacementStyle;
15
+ readonly motion?: "none" | "standard";
13
16
  }) => ReactNode;
14
17
  Title: ({ className, style, ...props }: Omit<import("@base-ui/react").DialogTitleProps, "ref"> & import("react").RefAttributes<HTMLHeadingElement>) => ReactNode;
15
18
  Description: ({ className, style, ...props }: Omit<import("@base-ui/react").DialogDescriptionProps, "ref"> & import("react").RefAttributes<HTMLParagraphElement>) => ReactNode;
@@ -2,16 +2,20 @@ import { Dialog as BaseDialog } from '@base-ui/react/dialog';
2
2
  import type { ComponentProps, ReactNode } from 'react';
3
3
  import type { OpenStateProperties } from '../../foundations/src/control-state.ts';
4
4
  import type { PlacementStyle } from '../../foundations/src/style-composition.ts';
5
+ type DialogMotion = 'standard' | 'none';
5
6
  type DialogRootProps<Payload> = Omit<BaseDialog.Root.Props<Payload>, 'open' | 'defaultOpen' | 'onOpenChange'> & OpenStateProperties<NonNullable<BaseDialog.Root.Props<Payload>['onOpenChange']>>;
6
- type DialogBackdropProps = ComponentProps<typeof BaseDialog.Backdrop>;
7
+ type DialogBackdropProps = ComponentProps<typeof BaseDialog.Backdrop> & {
8
+ readonly motion?: DialogMotion;
9
+ };
7
10
  type DialogPopupProps = ComponentProps<typeof BaseDialog.Popup> & {
8
11
  readonly xstyle?: PlacementStyle;
12
+ readonly motion?: DialogMotion;
9
13
  };
10
14
  type DialogTitleProps = ComponentProps<typeof BaseDialog.Title>;
11
15
  type DialogDescriptionProps = ComponentProps<typeof BaseDialog.Description>;
12
16
  declare function DialogRoot<Payload = unknown>(props: DialogRootProps<Payload>): ReactNode;
13
- declare function DialogBackdrop({ className, style, ...props }: DialogBackdropProps): ReactNode;
14
- declare function DialogPopup({ className, style, xstyle, ...props }: DialogPopupProps): ReactNode;
17
+ declare function DialogBackdrop({ className, style, motion, ...props }: DialogBackdropProps): ReactNode;
18
+ declare function DialogPopup({ className, style, xstyle, motion, ...props }: DialogPopupProps): ReactNode;
15
19
  declare function DialogTitle({ className, style, ...props }: DialogTitleProps): ReactNode;
16
20
  declare function DialogDescription({ className, style, ...props }: DialogDescriptionProps): ReactNode;
17
21
  export declare const Dialog: {
@@ -0,0 +1,71 @@
1
+ import { n as e, t } from "./pierre-theme-D9hnHv3Z.js";
2
+ import { t as n } from "./viewer-styles-CpHqp5Qv.js";
3
+ import * as r from "@stylexjs/stylex";
4
+ import { useCallback as i, useState as a } from "react";
5
+ import { jsx as o } from "react/jsx-runtime";
6
+ import { Virtualizer as s, parseDiffFromFile as c, parsePatchFiles as l, registerCustomTheme as u } from "@pierre/diffs";
7
+ import { FileDiff as d, VirtualizerContext as f } from "@pierre/diffs/react";
8
+ // packages/content/src/diff/pierre-diff.tsx
9
+ var p = {
10
+ kVQacm: "xysyzu8",
11
+ $$css: !0
12
+ }, m = { viewport: (e) => [
13
+ p,
14
+ {
15
+ kskxy: e == null ? e : "x1jols5v",
16
+ $$css: !0
17
+ },
18
+ { "--x-maxHeight": ((e) => typeof e == "number" ? e + "px" : e ?? void 0)(e) }
19
+ ] };
20
+ u("mechane", () => Promise.resolve(t), "zed");
21
+ function h(e) {
22
+ return e === null ? null : {
23
+ name: e.name,
24
+ contents: e.code,
25
+ lang: e.language ?? "text"
26
+ };
27
+ }
28
+ function g(e) {
29
+ return e.patch === void 0 ? [c(h(e.before), h(e.after), {}, !0)] : l(e.patch, { throwOnError: !0 }).flatMap((e) => e.files);
30
+ }
31
+ function _({ files: t, layout: c, wrap: l, showUnchanged: u, annotations: p, maxHeight: h, label: g }) {
32
+ let [_] = a(() => new s()), v = i((e) => {
33
+ e === null ? _.cleanUp() : _.setup(e);
34
+ }, [_]);
35
+ return /* @__PURE__ */ o(f.Provider, {
36
+ value: _,
37
+ children: /* @__PURE__ */ o("div", {
38
+ ref: v,
39
+ role: "region",
40
+ "aria-label": `${g} changes`,
41
+ tabIndex: 0,
42
+ ...r.props(n.scrollRegion, m.viewport(h)),
43
+ children: /* @__PURE__ */ o("div", { children: t.map((t) => /* @__PURE__ */ o(d, {
44
+ fileDiff: t,
45
+ disableWorkerPool: !0,
46
+ options: {
47
+ preferredHighlighter: "highlights",
48
+ theme: "mechane",
49
+ themeType: "system",
50
+ unsafeCSS: e,
51
+ diffStyle: c,
52
+ overflow: l ? "wrap" : "scroll",
53
+ hunkSeparators: "metadata",
54
+ expandUnchanged: u,
55
+ tokenizeMaxLength: 2e5,
56
+ tokenizeMaxLineLength: 4096
57
+ },
58
+ lineAnnotations: p.filter((e) => e.file === t.name).map((e) => ({
59
+ side: e.side === "old" ? "deletions" : "additions",
60
+ lineNumber: e.line,
61
+ metadata: e.content
62
+ })),
63
+ renderAnnotation: (e) => /* @__PURE__ */ o("div", {
64
+ className: "x1mvvolr xeuugli x1hz01jw xtqrqnz x1778rvt xj0a0fe",
65
+ children: e.metadata
66
+ })
67
+ }, t.name)) })
68
+ })
69
+ });
70
+ }
71
+ export { _ as PierreDiff, g as prepareDiff };