@crisp-ui-kit/crisp 0.57.1 → 0.57.3
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/authshell.css +9 -4
- package/dist/authshell.layered.css +9 -4
- package/dist/badge.css +3 -3
- package/dist/badge.layered.css +3 -3
- package/dist/board.css +28 -8
- package/dist/board.layered.css +28 -8
- package/dist/bottomsheet.css +26 -0
- package/dist/bottomsheet.d.ts +7 -0
- package/dist/bottomsheet.layered.css +28 -0
- package/dist/button.css +10 -6
- package/dist/button.d.ts +2 -2
- package/dist/button.layered.css +10 -6
- package/dist/checkbox.css +7 -3
- package/dist/checkbox.layered.css +7 -3
- package/dist/chip.css +16 -1
- package/dist/chip.d.ts +3 -1
- package/dist/chip.layered.css +16 -1
- package/dist/chipgroup.css +5 -0
- package/dist/chipgroup.d.ts +7 -0
- package/dist/chipgroup.layered.css +7 -0
- package/dist/cjs/components/badge/badge.recipe.js +22 -8
- package/dist/cjs/components/bottomsheet/bottomsheet.js +90 -0
- package/dist/cjs/components/bottomsheet/bottomsheet.recipe.js +77 -0
- package/dist/cjs/components/bottomsheet/index.js +9 -0
- package/dist/cjs/components/breadcrumb/breadcrumb.js +1 -1
- package/dist/cjs/components/button/button.recipe.js +67 -15
- package/dist/cjs/components/checkbox/checkbox.recipe.js +61 -9
- package/dist/cjs/components/chip/chip.js +14 -2
- package/dist/cjs/components/chip/chip.recipe.js +72 -2
- package/dist/cjs/components/chipgroup/chipgroup.js +51 -0
- package/dist/cjs/components/chipgroup/chipgroup.recipe.js +36 -0
- package/dist/cjs/components/chipgroup/index.js +7 -0
- package/dist/cjs/components/datatable/datatable.js +5 -1
- package/dist/cjs/components/datatable/datatable.recipe.js +21 -6
- package/dist/cjs/components/datepickerfield/datepickerfield.js +2 -2
- package/dist/cjs/components/datepickerfield/datepickerfield.recipe.js +16 -3
- package/dist/cjs/components/dialog/dialog.recipe.js +21 -10
- package/dist/cjs/components/emptystate/emptystate.recipe.js +7 -2
- package/dist/cjs/components/fileupload/fileupload.js +21 -4
- package/dist/cjs/components/input/index.js +2 -1
- package/dist/cjs/components/input/input.js +31 -1
- package/dist/cjs/components/input/input.recipe.js +16 -9
- package/dist/cjs/components/menu/menu.js +18 -2
- package/dist/cjs/components/menu/menu.recipe.js +21 -7
- package/dist/cjs/components/menusheet/index.js +9 -0
- package/dist/cjs/components/menusheet/menusheet.js +133 -0
- package/dist/cjs/components/menusheet/menusheet.recipe.js +103 -0
- package/dist/cjs/components/multiselect/multiselect.js +1 -1
- package/dist/cjs/components/multiselect/multiselect.recipe.js +33 -9
- package/dist/cjs/components/select/select.js +1 -1
- package/dist/cjs/components/select/select.recipe.js +38 -12
- package/dist/cjs/components/snackbar/index.js +8 -0
- package/dist/cjs/components/snackbar/snackbar.js +121 -0
- package/dist/cjs/components/snackbar/snackbar.recipe.js +71 -0
- package/dist/cjs/components/table/table.recipe.js +7 -1
- package/dist/cjs/components/tabletoolbar/tabletoolbar.chrome.js +7 -2
- package/dist/cjs/components/tabletoolbar/tabletoolbar.js +37 -12
- package/dist/cjs/components/tabs/tabs.js +10 -4
- package/dist/cjs/components/tabs/tabs.recipe.js +23 -6
- package/dist/cjs/components/textarea/textarea.recipe.js +11 -8
- package/dist/cjs/core/floating-portal.js +7 -4
- package/dist/cjs/index.js +7 -0
- package/dist/cjs/product/authshell/authshell.recipe.js +5 -1
- package/dist/cjs/product/command/command.recipe.js +4 -1
- package/dist/cjs/product/comments/comments.js +7 -2
- package/dist/cjs/product/comments/comments.recipe.js +25 -7
- package/dist/cjs/product/inbox/inbox.js +11 -3
- package/dist/cjs/product/memberssettings/index.js +6 -0
- package/dist/cjs/product/memberssettings/memberssettings.js +99 -0
- package/dist/cjs/product/memberssettings/memberssettings.recipe.js +83 -0
- package/dist/cjs/product/notificationssettings/index.js +5 -0
- package/dist/cjs/product/notificationssettings/notificationssettings.js +19 -0
- package/dist/cjs/product/notificationssettings/notificationssettings.recipe.js +44 -0
- package/dist/cjs/product/recordpage/index.js +2 -1
- package/dist/cjs/product/recordpage/recordpage.js +106 -9
- package/dist/cjs/product/recordpage/recordpage.recipe.js +68 -6
- package/dist/cjs/product/workspacegeneralsettings/index.js +5 -0
- package/dist/cjs/product/workspacegeneralsettings/workspacegeneralsettings.js +21 -0
- package/dist/cjs/product/workspacegeneralsettings/workspacegeneralsettings.recipe.js +51 -0
- package/dist/cjs/tokens/contract.js +1 -0
- package/dist/cjs/tokens/elevation.js +8 -5
- package/dist/cjs/tokens/palette.js +28 -8
- package/dist/cjs/tokens/scale.js +44 -2
- package/dist/cjs/tokens/semantic.js +2 -0
- package/dist/columncalc.css +15 -7
- package/dist/columncalc.layered.css +15 -7
- package/dist/command.css +23 -19
- package/dist/command.layered.css +23 -19
- package/dist/comments.css +28 -19
- package/dist/comments.d.ts +2 -2
- package/dist/comments.layered.css +28 -19
- package/dist/datatable.css +171 -71
- package/dist/datatable.layered.css +171 -71
- package/dist/datepicker.css +13 -41
- package/dist/datepicker.layered.css +13 -41
- package/dist/datepickerfield.css +12 -3
- package/dist/datepickerfield.d.ts +2 -2
- package/dist/datepickerfield.layered.css +12 -3
- package/dist/dialog.css +12 -7
- package/dist/dialog.layered.css +12 -7
- package/dist/emptystate.css +5 -3
- package/dist/emptystate.layered.css +5 -3
- package/dist/esm/components/badge/badge.recipe.js +22 -8
- package/dist/esm/components/bottomsheet/bottomsheet.js +52 -0
- package/dist/esm/components/bottomsheet/bottomsheet.recipe.js +74 -0
- package/dist/esm/components/bottomsheet/index.js +2 -0
- package/dist/esm/components/breadcrumb/breadcrumb.js +1 -1
- package/dist/esm/components/button/button.recipe.js +68 -16
- package/dist/esm/components/checkbox/checkbox.recipe.js +61 -9
- package/dist/esm/components/chip/chip.js +14 -2
- package/dist/esm/components/chip/chip.recipe.js +72 -2
- package/dist/esm/components/chipgroup/chipgroup.js +15 -0
- package/dist/esm/components/chipgroup/chipgroup.recipe.js +33 -0
- package/dist/esm/components/chipgroup/index.js +2 -0
- package/dist/esm/components/datatable/datatable.js +5 -1
- package/dist/esm/components/datatable/datatable.recipe.js +21 -6
- package/dist/esm/components/datepickerfield/datepickerfield.js +2 -2
- package/dist/esm/components/datepickerfield/datepickerfield.recipe.js +16 -3
- package/dist/esm/components/dialog/dialog.recipe.js +22 -11
- package/dist/esm/components/emptystate/emptystate.recipe.js +7 -2
- package/dist/esm/components/fileupload/fileupload.js +20 -5
- package/dist/esm/components/input/index.js +1 -1
- package/dist/esm/components/input/input.js +30 -0
- package/dist/esm/components/input/input.recipe.js +17 -10
- package/dist/esm/components/menu/menu.js +18 -2
- package/dist/esm/components/menu/menu.recipe.js +21 -7
- package/dist/esm/components/menusheet/index.js +2 -0
- package/dist/esm/components/menusheet/menusheet.js +95 -0
- package/dist/esm/components/menusheet/menusheet.recipe.js +100 -0
- package/dist/esm/components/multiselect/multiselect.js +1 -1
- package/dist/esm/components/multiselect/multiselect.recipe.js +33 -9
- package/dist/esm/components/select/select.js +1 -1
- package/dist/esm/components/select/select.recipe.js +38 -12
- package/dist/esm/components/snackbar/index.js +2 -0
- package/dist/esm/components/snackbar/snackbar.js +84 -0
- package/dist/esm/components/snackbar/snackbar.recipe.js +68 -0
- package/dist/esm/components/table/table.recipe.js +7 -1
- package/dist/esm/components/tabletoolbar/tabletoolbar.chrome.js +7 -2
- package/dist/esm/components/tabletoolbar/tabletoolbar.js +37 -12
- package/dist/esm/components/tabs/tabs.js +10 -4
- package/dist/esm/components/tabs/tabs.recipe.js +23 -6
- package/dist/esm/components/textarea/textarea.recipe.js +12 -9
- package/dist/esm/core/floating-portal.js +7 -4
- package/dist/esm/index.js +7 -0
- package/dist/esm/product/authshell/authshell.recipe.js +5 -1
- package/dist/esm/product/command/command.recipe.js +4 -1
- package/dist/esm/product/comments/comments.js +7 -2
- package/dist/esm/product/comments/comments.recipe.js +25 -7
- package/dist/esm/product/inbox/inbox.js +11 -3
- package/dist/esm/product/memberssettings/index.js +1 -0
- package/dist/esm/product/memberssettings/memberssettings.js +62 -0
- package/dist/esm/product/memberssettings/memberssettings.recipe.js +80 -0
- package/dist/esm/product/notificationssettings/index.js +1 -0
- package/dist/esm/product/notificationssettings/notificationssettings.js +16 -0
- package/dist/esm/product/notificationssettings/notificationssettings.recipe.js +41 -0
- package/dist/esm/product/recordpage/index.js +1 -1
- package/dist/esm/product/recordpage/recordpage.js +106 -10
- package/dist/esm/product/recordpage/recordpage.recipe.js +68 -6
- package/dist/esm/product/workspacegeneralsettings/index.js +1 -0
- package/dist/esm/product/workspacegeneralsettings/workspacegeneralsettings.js +18 -0
- package/dist/esm/product/workspacegeneralsettings/workspacegeneralsettings.recipe.js +48 -0
- package/dist/esm/tokens/contract.js +2 -1
- package/dist/esm/tokens/elevation.js +8 -5
- package/dist/esm/tokens/palette.js +28 -8
- package/dist/esm/tokens/scale.js +43 -1
- package/dist/esm/tokens/semantic.js +2 -0
- package/dist/fileupload.css +3 -1
- package/dist/fileupload.layered.css +3 -1
- package/dist/input.css +6 -4
- package/dist/input.layered.css +6 -4
- package/dist/listpage.css +3 -1
- package/dist/listpage.layered.css +3 -1
- package/dist/memberssettings.css +67 -0
- package/dist/memberssettings.d.ts +7 -0
- package/dist/memberssettings.layered.css +69 -0
- package/dist/menu.css +2 -2
- package/dist/menu.layered.css +2 -2
- package/dist/menusheet.css +36 -0
- package/dist/menusheet.d.ts +7 -0
- package/dist/menusheet.layered.css +38 -0
- package/dist/multiselect.css +13 -6
- package/dist/multiselect.layered.css +13 -6
- package/dist/native/tokens.d.ts +2 -1
- package/dist/native/tokens.js +20 -3
- package/dist/notificationssettings.css +22 -0
- package/dist/notificationssettings.d.ts +7 -0
- package/dist/notificationssettings.layered.css +24 -0
- package/dist/objectsettings.css +4 -4
- package/dist/objectsettings.layered.css +4 -4
- package/dist/recordpage.css +90 -23
- package/dist/recordpage.layered.css +90 -23
- package/dist/recordpanel.css +35 -16
- package/dist/recordpanel.layered.css +35 -16
- package/dist/resizablepanel.css +8 -5
- package/dist/resizablepanel.layered.css +8 -5
- package/dist/richtext.css +24 -8
- package/dist/richtext.layered.css +24 -8
- package/dist/savedviews.css +9 -2
- package/dist/savedviews.layered.css +9 -2
- package/dist/select.css +25 -5
- package/dist/select.layered.css +25 -5
- package/dist/settingsshell.css +2 -3
- package/dist/settingsshell.layered.css +2 -3
- package/dist/slider.css +6 -27
- package/dist/slider.layered.css +6 -27
- package/dist/snackbar.css +24 -0
- package/dist/snackbar.d.ts +7 -0
- package/dist/snackbar.layered.css +26 -0
- package/dist/statcard.css +3 -1
- package/dist/statcard.layered.css +3 -1
- package/dist/styles.css +911 -354
- package/dist/styles.layered.css +911 -354
- package/dist/table.css +35 -12
- package/dist/table.layered.css +35 -12
- package/dist/tabletoolbar.css +35 -24
- package/dist/tabletoolbar.layered.css +35 -24
- package/dist/tabs.css +18 -4
- package/dist/tabs.layered.css +18 -4
- package/dist/textarea.css +2 -6
- package/dist/textarea.layered.css +2 -6
- package/dist/themepicker.css +2 -1
- package/dist/themepicker.layered.css +2 -1
- package/dist/tokens.css +13 -2
- package/dist/tokens.json +20 -3
- package/dist/types/components/bottomsheet/bottomsheet.d.ts +35 -0
- package/dist/types/components/bottomsheet/bottomsheet.recipe.d.ts +3 -0
- package/dist/types/components/bottomsheet/index.d.ts +2 -0
- package/dist/types/components/breadcrumb/breadcrumb.d.ts +9 -1
- package/dist/types/components/button/button.d.ts +2 -0
- package/dist/types/components/button/button.recipe.d.ts +24 -6
- package/dist/types/components/checkbox/checkbox.recipe.d.ts +28 -5
- package/dist/types/components/chip/chip.d.ts +22 -0
- package/dist/types/components/chip/chip.recipe.d.ts +49 -1
- package/dist/types/components/chipgroup/chipgroup.d.ts +14 -0
- package/dist/types/components/chipgroup/chipgroup.recipe.d.ts +5 -0
- package/dist/types/components/chipgroup/index.d.ts +2 -0
- package/dist/types/components/datatable/datatable.d.ts +19 -0
- package/dist/types/components/datepickerfield/datepickerfield.d.ts +4 -1
- package/dist/types/components/datepickerfield/datepickerfield.recipe.d.ts +18 -3
- package/dist/types/components/fileupload/fileupload.d.ts +26 -0
- package/dist/types/components/input/index.d.ts +1 -1
- package/dist/types/components/input/input.d.ts +72 -0
- package/dist/types/components/menusheet/index.d.ts +2 -0
- package/dist/types/components/menusheet/menusheet.d.ts +42 -0
- package/dist/types/components/menusheet/menusheet.recipe.d.ts +3 -0
- package/dist/types/components/snackbar/index.d.ts +2 -0
- package/dist/types/components/snackbar/snackbar.d.ts +36 -0
- package/dist/types/components/snackbar/snackbar.recipe.d.ts +5 -0
- package/dist/types/components/tabletoolbar/tabletoolbar.d.ts +28 -1
- package/dist/types/components/tabs/tabs.d.ts +11 -1
- package/dist/types/core/floating-portal.d.ts +6 -5
- package/dist/types/index.d.ts +7 -0
- package/dist/types/product/comments/comments.d.ts +9 -3
- package/dist/types/product/comments/comments.recipe.d.ts +12 -2
- package/dist/types/product/inbox/inbox.d.ts +13 -1
- package/dist/types/product/memberssettings/index.d.ts +1 -0
- package/dist/types/product/memberssettings/memberssettings.d.ts +85 -0
- package/dist/types/product/memberssettings/memberssettings.recipe.d.ts +3 -0
- package/dist/types/product/notificationssettings/index.d.ts +1 -0
- package/dist/types/product/notificationssettings/notificationssettings.d.ts +37 -0
- package/dist/types/product/notificationssettings/notificationssettings.recipe.d.ts +3 -0
- package/dist/types/product/recordpage/index.d.ts +1 -1
- package/dist/types/product/recordpage/recordpage.d.ts +99 -2
- package/dist/types/product/workspacegeneralsettings/index.d.ts +1 -0
- package/dist/types/product/workspacegeneralsettings/workspacegeneralsettings.d.ts +48 -0
- package/dist/types/product/workspacegeneralsettings/workspacegeneralsettings.recipe.d.ts +3 -0
- package/dist/types/tokens/contract.d.ts +4 -1
- package/dist/types/tokens/elevation.d.ts +8 -5
- package/dist/types/tokens/palette.d.ts +9 -1
- package/dist/types/tokens/scale.d.ts +11 -1
- package/dist/types/tokens/semantic.d.ts +2 -0
- package/dist/wheelpicker.css +4 -2
- package/dist/wheelpicker.layered.css +4 -2
- package/dist/workspacegeneralsettings.css +30 -0
- package/dist/workspacegeneralsettings.d.ts +7 -0
- package/dist/workspacegeneralsettings.layered.css +32 -0
- package/package.json +36 -1
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
export type MenuSheetProps = Omit<React.ComponentPropsWithoutRef<"div">, "title" | "children"> & {
|
|
3
|
+
open: boolean;
|
|
4
|
+
onOpenChange: (open: boolean) => void;
|
|
5
|
+
title?: React.ReactNode;
|
|
6
|
+
description?: React.ReactNode;
|
|
7
|
+
footer?: React.ReactNode;
|
|
8
|
+
"aria-label"?: string;
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
};
|
|
11
|
+
/**
|
|
12
|
+
* A mobile menu sheet -- a focus-trapped bottom sheet (same Zag dialog
|
|
13
|
+
* machine as BottomSheet) whose body is a role=menu list, with the identical
|
|
14
|
+
* keyboard model Menu already uses: arrow keys move, Home/End jump,
|
|
15
|
+
* typeahead, Enter/Space select, Escape closes. Compose items with
|
|
16
|
+
* MenuSheetItem, and group a run of them in one rounded card with
|
|
17
|
+
* MenuSheetGroup.
|
|
18
|
+
*/
|
|
19
|
+
export declare function MenuSheet({ open, onOpenChange, title, description, footer, "aria-label": ariaLabel, children, className, "aria-describedby": describedBy, ...rest }: MenuSheetProps): React.JSX.Element | null;
|
|
20
|
+
export declare namespace MenuSheet {
|
|
21
|
+
var displayName: string;
|
|
22
|
+
}
|
|
23
|
+
export declare function MenuSheetGroup({ children }: {
|
|
24
|
+
children?: React.ReactNode;
|
|
25
|
+
}): React.JSX.Element;
|
|
26
|
+
export declare namespace MenuSheetGroup {
|
|
27
|
+
var displayName: string;
|
|
28
|
+
}
|
|
29
|
+
export type MenuSheetItemProps = {
|
|
30
|
+
children: React.ReactNode;
|
|
31
|
+
icon?: React.ReactNode;
|
|
32
|
+
description?: React.ReactNode;
|
|
33
|
+
tone?: "neutral" | "critical";
|
|
34
|
+
disabled?: boolean;
|
|
35
|
+
onSelect?: () => void;
|
|
36
|
+
/** Keep the sheet open after selecting (default closes). */
|
|
37
|
+
closeOnSelect?: boolean;
|
|
38
|
+
};
|
|
39
|
+
export declare function MenuSheetItem({ children, icon, description, tone, disabled, onSelect, closeOnSelect, }: MenuSheetItemProps): React.JSX.Element;
|
|
40
|
+
export declare namespace MenuSheetItem {
|
|
41
|
+
var displayName: string;
|
|
42
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
export type SnackbarVariant = "default" | "positive" | "critical";
|
|
3
|
+
export type SnackbarOptions = {
|
|
4
|
+
message: React.ReactNode;
|
|
5
|
+
variant?: SnackbarVariant;
|
|
6
|
+
/** Auto-dismiss after this many ms (0 = sticky). Defaults to the provider's. */
|
|
7
|
+
duration?: number;
|
|
8
|
+
action?: {
|
|
9
|
+
label: string;
|
|
10
|
+
onClick: () => void;
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
type SnackbarApi = {
|
|
14
|
+
show: (o: SnackbarOptions) => number;
|
|
15
|
+
dismiss: (id: number) => void;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Wrap your app in a `SnackbarProvider`, then call `useSnackbar().show({...})`
|
|
19
|
+
* from anywhere to queue a bottom-anchored snackbar. Only one shows at a time
|
|
20
|
+
* (seed-design's mobile pattern, crisp#911) -- a second call queues behind the
|
|
21
|
+
* first and shows once it dismisses. Auto-dismisses after `duration` (default
|
|
22
|
+
* 4s; 0 keeps it until `dismiss()` or its action fires -- there is no close
|
|
23
|
+
* button, matching seed's own anatomy, which has none).
|
|
24
|
+
*/
|
|
25
|
+
export declare function SnackbarProvider({ children, duration, regionLabel: regionLabelProp, }: {
|
|
26
|
+
children: React.ReactNode;
|
|
27
|
+
duration?: number;
|
|
28
|
+
/** aria-label on the always-mounted notifications region (default
|
|
29
|
+
* "Notifications"). */
|
|
30
|
+
regionLabel?: string;
|
|
31
|
+
}): React.JSX.Element;
|
|
32
|
+
export declare namespace SnackbarProvider {
|
|
33
|
+
var displayName: string;
|
|
34
|
+
}
|
|
35
|
+
export declare function useSnackbar(): SnackbarApi;
|
|
36
|
+
export {};
|
|
@@ -152,6 +152,26 @@ export type TableToolbarProps = Omit<React.ComponentPropsWithoutRef<"div">, "chi
|
|
|
152
152
|
* "Delete filter" (this prop's original default) after a re-measurement
|
|
153
153
|
* caught the wrong word. */
|
|
154
154
|
deleteFilterLabel?: string;
|
|
155
|
+
/**
|
|
156
|
+
* Overrides for the filter chip's operator words ("contains", "is any
|
|
157
|
+
* of", …) — crisp/#962: these came from a plain internal lookup table
|
|
158
|
+
* with no prop of their own, so a consumer's own non-English UI (GRC's
|
|
159
|
+
* Mongolian locale) had no discoverable way to translate them short of
|
|
160
|
+
* adding entries to a `CrispMessagesProvider` dictionary keyed by the
|
|
161
|
+
* exact English string, undocumented and easy to miss. Partial, same as
|
|
162
|
+
* `RecordPage`'s/`RecordsTable`'s own `labels` object (`core/i18n.tsx`'s
|
|
163
|
+
* own doc comment: "a handful of product components already take their
|
|
164
|
+
* own translatable text as one big labels object rather than a prop per
|
|
165
|
+
* string") — this is the one TableToolbar string that's a lookup table
|
|
166
|
+
* keyed by an enum rather than a single piece of text, so it gets that
|
|
167
|
+
* treatment instead of thirteen new individual `xLabel` props. A
|
|
168
|
+
* `CrispMessagesProvider`'s `componentDefaults.tableToolbar` (see
|
|
169
|
+
* `useToolbarOperatorLabels` below) sits between the built-in English
|
|
170
|
+
* words and this prop; the OLD whole-dictionary-by-English-string path
|
|
171
|
+
* still works underneath both, unchanged, for any consumer already
|
|
172
|
+
* relying on it.
|
|
173
|
+
*/
|
|
174
|
+
operatorLabels?: Partial<ToolbarOperatorLabels>;
|
|
155
175
|
/** Label on the "ascending" sort-direction option (default "Ascending"). */
|
|
156
176
|
ascendingLabel?: string;
|
|
157
177
|
/** Label on the "descending" sort-direction option (default "Descending"). */
|
|
@@ -288,6 +308,13 @@ export type TableToolbarProps = Omit<React.ComponentPropsWithoutRef<"div">, "chi
|
|
|
288
308
|
*/
|
|
289
309
|
nestedFieldPlaceholder?: (noun: string) => string;
|
|
290
310
|
};
|
|
311
|
+
/** crisp/#962: the canonical English operator words, keyed the same way
|
|
312
|
+
* `RecordPageLabels` keys its own defaults — exported so a consumer's
|
|
313
|
+
* `CrispMessagesProvider` or `operatorLabels` override can be typed
|
|
314
|
+
* against the real key set instead of guessing `ToolbarFilterOp`'s
|
|
315
|
+
* strings by hand. */
|
|
316
|
+
export type ToolbarOperatorLabels = Record<ToolbarFilterOp, string>;
|
|
317
|
+
export declare const toolbarOperatorLabels: ToolbarOperatorLabels;
|
|
291
318
|
/**
|
|
292
319
|
* Applies a toolbar's filter conditions to any row array. Reads the raw value
|
|
293
320
|
* at `row[key]` (override with `get` for derived fields) — never a formatted
|
|
@@ -313,7 +340,7 @@ export declare function applySorts<T>(rows: T[], sorts: ToolbarSort[], get?: (ro
|
|
|
313
340
|
* this (Sort: Due date/Assignee/Creation date; Filter: Assignee/Record/
|
|
314
341
|
* Created by), which one shared list can't reproduce.
|
|
315
342
|
*/
|
|
316
|
-
export declare function TableToolbar({ columns, sortColumns: sortColumnsProp, filterColumns: filterColumnsProp, sorts: sortsProp, defaultSorts, onSortsChange, filters: filtersProp, defaultFilters, onFiltersChange, count, children, helpHref, className, sortLabel: sortLabelProp, filterLabel: filterLabelProp, reorderSortLabel: reorderSortLabelProp, noSortsLabel: noSortsLabelProp, addSortLabel: addSortLabelProp, learnSortingLabel: learnSortingLabelProp, selectConditionLabel: selectConditionLabelProp, sortFieldLabel: sortFieldLabelProp, sortDirectionLabel: sortDirectionLabelProp, removeSortLabel: removeSortLabelProp, filterFieldLabel: filterFieldLabelProp, filterFieldPlaceholder: filterFieldPlaceholderProp, filterValuePlaceholder: filterValuePlaceholderProp, filterOptionsLabel: filterOptionsLabelProp, deleteFilterLabel: deleteFilterLabelProp, ascendingLabel: ascendingLabelProp, descendingLabel: descendingLabelProp, sortTriggerLabel, filterTriggerLabel, inline, showSort, showViewSettings, viewSettingsRef, importExportRef, viewColumns: viewColumnsProp, shownKeys: shownKeysProp, defaultShownKeys, onShownKeysChange, viewSettingsLabel: viewSettingsLabelProp, reorderAttributeLabel: reorderAttributeLabelProp, hideAttributeLabel, addAttributeToViewLabel: addAttributeToViewLabelProp, searchAttributesPlaceholder: searchAttributesPlaceholderProp, importExportLabel: importExportLabelProp, onImportCsv, onExportCsv, onExportExcel, importExportHelpHref, importCsvLabel: importCsvLabelProp, exportCsvLabel: exportCsvLabelProp, exportExcelLabel: exportExcelLabelProp, learnImportExportLabel: learnImportExportLabelProp, backLabel: backLabelProp, nestedFieldPlaceholder, ...rest }: TableToolbarProps): React.JSX.Element;
|
|
343
|
+
export declare function TableToolbar({ columns, sortColumns: sortColumnsProp, filterColumns: filterColumnsProp, sorts: sortsProp, defaultSorts, onSortsChange, filters: filtersProp, defaultFilters, onFiltersChange, count, children, helpHref, className, sortLabel: sortLabelProp, filterLabel: filterLabelProp, reorderSortLabel: reorderSortLabelProp, noSortsLabel: noSortsLabelProp, addSortLabel: addSortLabelProp, learnSortingLabel: learnSortingLabelProp, selectConditionLabel: selectConditionLabelProp, sortFieldLabel: sortFieldLabelProp, sortDirectionLabel: sortDirectionLabelProp, removeSortLabel: removeSortLabelProp, filterFieldLabel: filterFieldLabelProp, filterFieldPlaceholder: filterFieldPlaceholderProp, filterValuePlaceholder: filterValuePlaceholderProp, filterOptionsLabel: filterOptionsLabelProp, deleteFilterLabel: deleteFilterLabelProp, operatorLabels, ascendingLabel: ascendingLabelProp, descendingLabel: descendingLabelProp, sortTriggerLabel, filterTriggerLabel, inline, showSort, showViewSettings, viewSettingsRef, importExportRef, viewColumns: viewColumnsProp, shownKeys: shownKeysProp, defaultShownKeys, onShownKeysChange, viewSettingsLabel: viewSettingsLabelProp, reorderAttributeLabel: reorderAttributeLabelProp, hideAttributeLabel, addAttributeToViewLabel: addAttributeToViewLabelProp, searchAttributesPlaceholder: searchAttributesPlaceholderProp, importExportLabel: importExportLabelProp, onImportCsv, onExportCsv, onExportExcel, importExportHelpHref, importCsvLabel: importCsvLabelProp, exportCsvLabel: exportCsvLabelProp, exportExcelLabel: exportExcelLabelProp, learnImportExportLabel: learnImportExportLabelProp, backLabel: backLabelProp, nestedFieldPlaceholder, ...rest }: TableToolbarProps): React.JSX.Element;
|
|
317
344
|
export type ToolbarToolProps = React.ComponentPropsWithoutRef<"button"> & {
|
|
318
345
|
/** Drawn the way Sort/Filter are once a condition is set (#399). */
|
|
319
346
|
active?: boolean;
|
|
@@ -28,6 +28,16 @@ export type TabsProps = Omit<React.ComponentPropsWithoutRef<"div">, "value" | "d
|
|
|
28
28
|
moreLabel?: (count: number) => React.ReactNode;
|
|
29
29
|
/** aria-label on the overflow trigger/menu (default "More tabs"). */
|
|
30
30
|
moreMenuLabel?: string;
|
|
31
|
+
/**
|
|
32
|
+
* How the tab row handles running out of width. `"collapse"` (default,
|
|
33
|
+
* crisp#863) hides trailing tabs behind a "+N more" menu, matching
|
|
34
|
+
* Attio's own record-view tabs. `"scroll"` (crisp#908) never hides a
|
|
35
|
+
* tab — the row scrolls horizontally instead, snapping each tab to the
|
|
36
|
+
* left edge, the pattern Naver/Kakao's own tab rows use
|
|
37
|
+
* (`docs/study/korean/`). Mutually exclusive: `"scroll"` never computes
|
|
38
|
+
* or renders the "+N more" trigger.
|
|
39
|
+
*/
|
|
40
|
+
overflow?: "collapse" | "scroll";
|
|
31
41
|
className?: string;
|
|
32
42
|
"aria-label"?: string;
|
|
33
43
|
};
|
|
@@ -37,7 +47,7 @@ export type TabsProps = Omit<React.ComponentPropsWithoutRef<"div">, "value" | "d
|
|
|
37
47
|
* Home/End jump); activation follows focus. Controlled via
|
|
38
48
|
* `value`/`onValueChange`, or uncontrolled from `defaultValue`.
|
|
39
49
|
*/
|
|
40
|
-
export declare function Tabs({ tabs, value, defaultValue, onValueChange, leading, children, moreLabel, moreMenuLabel, className, fill, "aria-label": ariaLabel, ...rest }: TabsProps): React.JSX.Element;
|
|
50
|
+
export declare function Tabs({ tabs, value, defaultValue, onValueChange, leading, children, moreLabel, moreMenuLabel, overflow, className, fill, "aria-label": ariaLabel, ...rest }: TabsProps): React.JSX.Element;
|
|
41
51
|
export declare namespace Tabs {
|
|
42
52
|
var displayName: string;
|
|
43
53
|
}
|
|
@@ -15,10 +15,11 @@ import * as React from "react";
|
|
|
15
15
|
* `Dialog` was rendering offset by the dialog's own box instead of anchored
|
|
16
16
|
* to its trigger.
|
|
17
17
|
*
|
|
18
|
-
* Every caller renders this conditionally on its own `open` state
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
18
|
+
* Every caller renders this conditionally on its own `open` state. A fixture
|
|
19
|
+
* CAN set that true at mount (crisp#964 needs exactly that, to give Menu's
|
|
20
|
+
* roving-tabindex guard something to inspect), so this checks for `window`
|
|
21
|
+
* itself rather than assuming the caller never does — the same guard
|
|
22
|
+
* `@zag-js/react`'s own `Portal` uses for the identical reason.
|
|
22
23
|
*
|
|
23
24
|
* `sourceRef` is the caller's own root — still in its original DOM position,
|
|
24
25
|
* never portaled — used to carry a `data-theme` set on some ancestor of it
|
|
@@ -36,4 +37,4 @@ import * as React from "react";
|
|
|
36
37
|
export declare function FloatingPortal({ children, sourceRef, }: {
|
|
37
38
|
children: React.ReactElement;
|
|
38
39
|
sourceRef: React.RefObject<HTMLElement | null>;
|
|
39
|
-
}): React.
|
|
40
|
+
}): React.ReactElement;
|
package/dist/types/index.d.ts
CHANGED
|
@@ -4,6 +4,7 @@ export * from "./components/avatar";
|
|
|
4
4
|
export * from "./components/avatargroup";
|
|
5
5
|
export * from "./components/badge";
|
|
6
6
|
export * from "./components/barchart";
|
|
7
|
+
export * from "./components/bottomsheet";
|
|
7
8
|
export * from "./components/breadcrumb";
|
|
8
9
|
export * from "./components/bulkbar";
|
|
9
10
|
export * from "./components/button";
|
|
@@ -11,6 +12,7 @@ export * from "./components/callout";
|
|
|
11
12
|
export * from "./components/card";
|
|
12
13
|
export * from "./components/checkbox";
|
|
13
14
|
export * from "./components/chip";
|
|
15
|
+
export * from "./components/chipgroup";
|
|
14
16
|
export * from "./components/columncalc";
|
|
15
17
|
export * from "./components/composewindow";
|
|
16
18
|
export * from "./components/contextmenu";
|
|
@@ -32,6 +34,7 @@ export * from "./components/kbd";
|
|
|
32
34
|
export * from "./components/linechart";
|
|
33
35
|
export * from "./components/mentionchip";
|
|
34
36
|
export * from "./components/menu";
|
|
37
|
+
export * from "./components/menusheet";
|
|
35
38
|
export * from "./components/middletruncate";
|
|
36
39
|
export * from "./components/multiselect";
|
|
37
40
|
export * from "./components/personchip";
|
|
@@ -45,6 +48,7 @@ export * from "./components/select";
|
|
|
45
48
|
export * from "./components/skeleton";
|
|
46
49
|
export * from "./components/skiplink";
|
|
47
50
|
export * from "./components/slider";
|
|
51
|
+
export * from "./components/snackbar";
|
|
48
52
|
export * from "./components/spinner";
|
|
49
53
|
export * from "./components/stagebar";
|
|
50
54
|
export * from "./components/statcard";
|
|
@@ -75,7 +79,9 @@ export * from "./product/headerbar";
|
|
|
75
79
|
export * from "./product/importdialog";
|
|
76
80
|
export * from "./product/inbox";
|
|
77
81
|
export * from "./product/listpage";
|
|
82
|
+
export * from "./product/memberssettings";
|
|
78
83
|
export * from "./product/navitem";
|
|
84
|
+
export * from "./product/notificationssettings";
|
|
79
85
|
export * from "./product/objectsettings";
|
|
80
86
|
export * from "./product/onboarding";
|
|
81
87
|
export * from "./product/recordpage";
|
|
@@ -90,4 +96,5 @@ export * from "./product/tasklist";
|
|
|
90
96
|
export * from "./product/themepicker";
|
|
91
97
|
export * from "./product/trialbanner";
|
|
92
98
|
export * from "./product/viewtoggle";
|
|
99
|
+
export * from "./product/workspacegeneralsettings";
|
|
93
100
|
export * from "./tokens";
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
-
import { type MentionAnchor } from "../../core";
|
|
2
|
+
import { type MentionAnchor, type VariantProps } from "../../core";
|
|
3
|
+
import { commentsRecipe } from "./comments.recipe";
|
|
3
4
|
/** One participant — crisp has no user model of its own, so every field
|
|
4
5
|
* beyond `id`/`name` (avatar image, colour) is fully consumer-supplied, the
|
|
5
6
|
* same split `Inbox`'s own `avatar` prop already draws. */
|
|
@@ -76,7 +77,7 @@ export type CommentMentionTriggerState = {
|
|
|
76
77
|
* never read from the part that changed.
|
|
77
78
|
*/
|
|
78
79
|
export declare function serializeComposerField(field: HTMLElement): string;
|
|
79
|
-
export type CommentsPanelProps = Omit<React.ComponentPropsWithoutRef<"div">, "children" | "title" | "onCopy"> & {
|
|
80
|
+
export type CommentsPanelProps = Omit<React.ComponentPropsWithoutRef<"div">, "children" | "title" | "onCopy"> & VariantProps<typeof commentsRecipe> & {
|
|
80
81
|
threads: CommentThread[];
|
|
81
82
|
currentUserId: string;
|
|
82
83
|
/** The record/page these comments belong to -- shown in the single-thread
|
|
@@ -168,8 +169,13 @@ export type CommentsPanelProps = Omit<React.ComponentPropsWithoutRef<"div">, "ch
|
|
|
168
169
|
* nothing on its own beyond that data. See `CommentCountBadge` for the
|
|
169
170
|
* separate row affordance (P-051) — deliberately NOT part of this
|
|
170
171
|
* component, since it lives in a table cell this component doesn't own.
|
|
172
|
+
*
|
|
173
|
+
* `variant="drawer"` (default) is today's measured 320px + left-border
|
|
174
|
+
* look; `variant="pane"` (crisp#960) fills its container's width instead,
|
|
175
|
+
* for a consumer embedding this in a full-width tab pane rather than a
|
|
176
|
+
* true slide-over/drawer.
|
|
171
177
|
*/
|
|
172
|
-
export declare function CommentsPanel({ threads, currentUserId, subject, subjectIcon, showResolved, onShowResolvedChange, onlyMine, onOnlyMineChange, activeThreadId: activeThreadIdProp, onActiveThreadChange, onPost, onReact, onResolve, onDelete, onCopyLink, emojiOptions, mentionTrigger, renderMentionPicker, onClose, closeLabel: closeLabelProp, backLabel: backLabelProp, title: titleProp, threadTitle: threadTitleProp, breadcrumbPrefix: breadcrumbPrefixProp, composerPlaceholder: composerPlaceholderProp, replyPlaceholder: replyPlaceholderProp, postLabel: postLabelProp, replyPostLabel: replyPostLabelProp, emptyLabel, filterLabel: filterLabelProp, showResolvedLabel: showResolvedLabelProp, onlyMineLabel: onlyMineLabelProp, replyActionLabel: replyActionLabelProp, reactActionLabel: reactActionLabelProp, resolveActionLabel: resolveActionLabelProp, resolvedByYouLabel: resolvedByYouLabelProp, resolvedByLabel, moreActionsLabel: moreActionsLabelProp, copyLinkLabel: copyLinkLabelProp, deleteLabel: deleteLabelProp, addReactionLabel: addReactionLabelProp, reactionSearchLabel: reactionSearchLabelProp, deleteConfirmTitle: deleteConfirmTitleProp, deleteConfirmBody: deleteConfirmBodyProp, deleteConfirmActionLabel: deleteConfirmActionLabelProp, cancelLabel: cancelLabelProp, composerMentionToolLabel: composerMentionToolLabelProp, className, ...rest }: CommentsPanelProps): React.JSX.Element;
|
|
178
|
+
export declare function CommentsPanel({ threads, currentUserId, subject, subjectIcon, showResolved, onShowResolvedChange, onlyMine, onOnlyMineChange, activeThreadId: activeThreadIdProp, onActiveThreadChange, onPost, onReact, onResolve, onDelete, onCopyLink, emojiOptions, mentionTrigger, renderMentionPicker, onClose, closeLabel: closeLabelProp, backLabel: backLabelProp, title: titleProp, threadTitle: threadTitleProp, breadcrumbPrefix: breadcrumbPrefixProp, composerPlaceholder: composerPlaceholderProp, replyPlaceholder: replyPlaceholderProp, postLabel: postLabelProp, replyPostLabel: replyPostLabelProp, emptyLabel, filterLabel: filterLabelProp, showResolvedLabel: showResolvedLabelProp, onlyMineLabel: onlyMineLabelProp, replyActionLabel: replyActionLabelProp, reactActionLabel: reactActionLabelProp, resolveActionLabel: resolveActionLabelProp, resolvedByYouLabel: resolvedByYouLabelProp, resolvedByLabel, moreActionsLabel: moreActionsLabelProp, copyLinkLabel: copyLinkLabelProp, deleteLabel: deleteLabelProp, addReactionLabel: addReactionLabelProp, reactionSearchLabel: reactionSearchLabelProp, deleteConfirmTitle: deleteConfirmTitleProp, deleteConfirmBody: deleteConfirmBodyProp, deleteConfirmActionLabel: deleteConfirmActionLabelProp, cancelLabel: cancelLabelProp, composerMentionToolLabel: composerMentionToolLabelProp, variant, className, ...rest }: CommentsPanelProps): React.JSX.Element;
|
|
173
179
|
export declare namespace CommentsPanel {
|
|
174
180
|
var displayName: string;
|
|
175
181
|
}
|
|
@@ -1,3 +1,13 @@
|
|
|
1
|
-
declare const config: import("../..").RecipeConfig<{
|
|
2
|
-
|
|
1
|
+
declare const config: import("../..").RecipeConfig<{
|
|
2
|
+
variant: {
|
|
3
|
+
drawer: string;
|
|
4
|
+
pane: string;
|
|
5
|
+
};
|
|
6
|
+
}>;
|
|
7
|
+
export declare const commentsRecipe: import("../..").RecipeFn<{
|
|
8
|
+
variant: {
|
|
9
|
+
drawer: string;
|
|
10
|
+
pane: string;
|
|
11
|
+
};
|
|
12
|
+
}>;
|
|
3
13
|
export default config;
|
|
@@ -15,6 +15,14 @@ export type InboxTab = {
|
|
|
15
15
|
label: React.ReactNode;
|
|
16
16
|
count?: number;
|
|
17
17
|
disabled?: boolean;
|
|
18
|
+
/**
|
|
19
|
+
* Empty-state copy for this tab only, e.g. Notifications vs. Requests
|
|
20
|
+
* ("Requests from other users will be displayed here."). Falls back to
|
|
21
|
+
* the instance-level `emptyTitle`/`emptySubtitle`/`emptyAction` when unset.
|
|
22
|
+
*/
|
|
23
|
+
emptyTitle?: React.ReactNode;
|
|
24
|
+
emptySubtitle?: React.ReactNode;
|
|
25
|
+
emptyAction?: React.ReactNode;
|
|
18
26
|
};
|
|
19
27
|
export type InboxProps = Omit<React.ComponentPropsWithoutRef<"div">, "children" | "title"> & {
|
|
20
28
|
notifications?: InboxNotification[];
|
|
@@ -23,7 +31,11 @@ export type InboxProps = Omit<React.ComponentPropsWithoutRef<"div">, "children"
|
|
|
23
31
|
tabs?: InboxTab[];
|
|
24
32
|
activeTab?: string;
|
|
25
33
|
onTabChange?: (id: string) => void;
|
|
26
|
-
/**
|
|
34
|
+
/**
|
|
35
|
+
* Empty-state text (shown when there are no notifications). A tab in
|
|
36
|
+
* `tabs` that sets its own `emptyTitle`/`emptySubtitle` overrides this
|
|
37
|
+
* for that tab only.
|
|
38
|
+
*/
|
|
27
39
|
emptyTitle?: React.ReactNode;
|
|
28
40
|
emptySubtitle?: React.ReactNode;
|
|
29
41
|
/** Optional action under the empty state (e.g. a Settings button). */
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { InviteMembersDialog, type InviteMembersDialogProps, type MemberRow, MembersSettings, type MembersSettingsProps, } from "./memberssettings";
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import type { SelectOption } from "../../components/select";
|
|
3
|
+
export type MemberRow = {
|
|
4
|
+
id: string;
|
|
5
|
+
name: React.ReactNode;
|
|
6
|
+
isYou?: boolean;
|
|
7
|
+
email: string;
|
|
8
|
+
/** "Admin" renders Attio's measured purple role badge; any other value
|
|
9
|
+
* renders as plain text (Attio's own Member role has no pill). */
|
|
10
|
+
role: "Admin" | React.ReactNode;
|
|
11
|
+
teams?: React.ReactNode;
|
|
12
|
+
avatarSrc?: string;
|
|
13
|
+
};
|
|
14
|
+
export type MembersSettingsProps = Omit<React.ComponentPropsWithoutRef<"div">, "title"> & {
|
|
15
|
+
members: MemberRow[];
|
|
16
|
+
/** Search box value (controlled). */
|
|
17
|
+
searchValue?: string;
|
|
18
|
+
onSearchChange?: (value: string) => void;
|
|
19
|
+
onFilterClick?: () => void;
|
|
20
|
+
onInviteClick?: () => void;
|
|
21
|
+
onRowMenuClick?: (member: MemberRow) => void;
|
|
22
|
+
/** Which pill is active — Members is the only tab with a built shape
|
|
23
|
+
* (P-119/P-120); Teams renders `teamsContent` or a muted placeholder,
|
|
24
|
+
* since Attio's Teams tab body wasn't part of this issue's measurement. */
|
|
25
|
+
tab?: "members" | "teams";
|
|
26
|
+
onTabChange?: (tab: "members" | "teams") => void;
|
|
27
|
+
teamsContent?: React.ReactNode;
|
|
28
|
+
className?: string;
|
|
29
|
+
/** Chrome strings, each overridable for non-English UIs. */
|
|
30
|
+
title?: string;
|
|
31
|
+
description?: string;
|
|
32
|
+
learnMoreLabel?: string;
|
|
33
|
+
learnMoreHref?: string;
|
|
34
|
+
membersTabLabel?: string;
|
|
35
|
+
teamsTabLabel?: string;
|
|
36
|
+
tablistLabel?: string;
|
|
37
|
+
searchPlaceholder?: string;
|
|
38
|
+
filterLabel?: string;
|
|
39
|
+
inviteLabel?: string;
|
|
40
|
+
userColumnLabel?: string;
|
|
41
|
+
roleColumnLabel?: string;
|
|
42
|
+
teamsColumnLabel?: string;
|
|
43
|
+
memberActionsLabel?: string;
|
|
44
|
+
noTeamsLabel?: string;
|
|
45
|
+
};
|
|
46
|
+
/**
|
|
47
|
+
* Attio's "Members and teams" settings page (crisp#636, P-119/P-120):
|
|
48
|
+
* title + description, a Members/Teams segmented switcher, a
|
|
49
|
+
* search+Filter+Invite toolbar, and the members table (User/Role/Teams).
|
|
50
|
+
* Compose `InviteMembersDialog` alongside for the "Invite members" flow.
|
|
51
|
+
*/
|
|
52
|
+
export declare function MembersSettings({ members, searchValue, onSearchChange, onFilterClick, onInviteClick, onRowMenuClick, tab: tabProp, onTabChange, teamsContent, className, title, description, learnMoreLabel, learnMoreHref, membersTabLabel, teamsTabLabel, tablistLabel, searchPlaceholder, filterLabel, inviteLabel, userColumnLabel, roleColumnLabel, teamsColumnLabel, memberActionsLabel, noTeamsLabel, ...rest }: MembersSettingsProps): React.JSX.Element;
|
|
53
|
+
export declare namespace MembersSettings {
|
|
54
|
+
var displayName: string;
|
|
55
|
+
}
|
|
56
|
+
export type InviteMembersDialogProps = Omit<React.ComponentPropsWithoutRef<"div">, "title" | "onSend" | "children"> & {
|
|
57
|
+
open: boolean;
|
|
58
|
+
onOpenChange: (open: boolean) => void;
|
|
59
|
+
/** Comma/newline-separated email list, as typed into the composer. */
|
|
60
|
+
emails: string;
|
|
61
|
+
onEmailsChange: (value: string) => void;
|
|
62
|
+
inviteAs: "member" | "admin";
|
|
63
|
+
onInviteAsChange: (value: "member" | "admin") => void;
|
|
64
|
+
team: string;
|
|
65
|
+
onTeamChange: (value: string) => void;
|
|
66
|
+
teamOptions?: SelectOption[];
|
|
67
|
+
onSend: () => void;
|
|
68
|
+
title?: string;
|
|
69
|
+
emailsPlaceholder?: string;
|
|
70
|
+
inviteAsFieldLabel?: string;
|
|
71
|
+
memberOptionLabel?: string;
|
|
72
|
+
adminOptionLabel?: string;
|
|
73
|
+
addToTeamFieldLabel?: string;
|
|
74
|
+
addToTeamPlaceholder?: string;
|
|
75
|
+
sendLabel?: string;
|
|
76
|
+
};
|
|
77
|
+
/**
|
|
78
|
+
* Attio's "Invite members" modal (crisp#636, P-120), measured live: 708px
|
|
79
|
+
* wide, a multi-email composer, an "Invite as" select (default Member) and
|
|
80
|
+
* an optional "Add to team" search-or-create select, footer "Send Invites".
|
|
81
|
+
*/
|
|
82
|
+
export declare function InviteMembersDialog({ open, onOpenChange, emails, onEmailsChange, inviteAs, onInviteAsChange, team, onTeamChange, teamOptions, onSend, title, emailsPlaceholder, inviteAsFieldLabel, memberOptionLabel, adminOptionLabel, addToTeamFieldLabel, addToTeamPlaceholder, sendLabel, ...rest }: InviteMembersDialogProps): React.JSX.Element;
|
|
83
|
+
export declare namespace InviteMembersDialog {
|
|
84
|
+
var displayName: string;
|
|
85
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { type NotificationMatrixRow, NotificationsSettings, type NotificationsSettingsProps, } from "./notificationssettings";
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type * as React from "react";
|
|
2
|
+
export type NotificationMatrixRow = {
|
|
3
|
+
id: string;
|
|
4
|
+
title: React.ReactNode;
|
|
5
|
+
description: React.ReactNode;
|
|
6
|
+
email: boolean;
|
|
7
|
+
app: boolean;
|
|
8
|
+
};
|
|
9
|
+
export type NotificationsSettingsProps = Omit<React.ComponentPropsWithoutRef<"div">, "title"> & {
|
|
10
|
+
dailyDigestEnabled: boolean;
|
|
11
|
+
onDailyDigestChange: (enabled: boolean) => void;
|
|
12
|
+
rows: NotificationMatrixRow[];
|
|
13
|
+
onEmailChange: (id: string, checked: boolean) => void;
|
|
14
|
+
onAppChange: (id: string, checked: boolean) => void;
|
|
15
|
+
/** Chrome strings, each overridable for non-English UIs. */
|
|
16
|
+
title?: string;
|
|
17
|
+
description?: string;
|
|
18
|
+
learnMoreLabel?: string;
|
|
19
|
+
learnMoreHref?: string;
|
|
20
|
+
dailyDigestSectionTitle?: string;
|
|
21
|
+
dailyDigestRowTitle?: string;
|
|
22
|
+
dailyDigestRowDescription?: string;
|
|
23
|
+
collaborationSectionTitle?: string;
|
|
24
|
+
notifyMeAboutLabel?: string;
|
|
25
|
+
emailColumnLabel?: string;
|
|
26
|
+
appColumnLabel?: string;
|
|
27
|
+
};
|
|
28
|
+
/**
|
|
29
|
+
* Attio's "Notifications" settings page (crisp#630, P-083): title +
|
|
30
|
+
* description, a "Daily digest" card (a single toggle row), and a
|
|
31
|
+
* "Collaboration notifications" matrix — a header row plus one row per
|
|
32
|
+
* event, each with an Email and an App checkbox. Measured live.
|
|
33
|
+
*/
|
|
34
|
+
export declare function NotificationsSettings({ dailyDigestEnabled, onDailyDigestChange, rows, onEmailChange, onAppChange, className, title, description, learnMoreLabel, learnMoreHref, dailyDigestSectionTitle, dailyDigestRowTitle, dailyDigestRowDescription, collaborationSectionTitle, notifyMeAboutLabel, emailColumnLabel, appColumnLabel, ...rest }: NotificationsSettingsProps): React.JSX.Element;
|
|
35
|
+
export declare namespace NotificationsSettings {
|
|
36
|
+
var displayName: string;
|
|
37
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export { type Column, type ColumnType, type EntityValue, type ReferenceOption, type Row, type StatusOption, tagTone, } from "./column";
|
|
2
2
|
export { type EditableOption, editableInputType, useEditableField, } from "./editable-field";
|
|
3
|
-
export { RecordDetails, type RecordDetailsProps, RecordPage, type RecordPageHighlight, type RecordPageLabels, type RecordPageLabelsInput, type RecordPageNote, type RecordPageProps, type RecordPageSection, type RecordPageTab, type RecordPageTask, recordPageLabels, } from "./recordpage";
|
|
3
|
+
export { RecordDetails, type RecordDetailsProps, RecordPage, type RecordPageHighlight, type RecordPageLabels, type RecordPageLabelsInput, RecordPageMain, type RecordPageMainProps, type RecordPageNote, type RecordPageProps, type RecordPageSection, type RecordPageTab, type RecordPageTask, recordPageLabels, } from "./recordpage";
|
|
4
4
|
export { recordpageRecipe } from "./recordpage.recipe";
|
|
@@ -2,8 +2,17 @@ import { type LucideIcon } from "lucide-react";
|
|
|
2
2
|
import * as React from "react";
|
|
3
3
|
import { type CommentAuthor, type CommentThread } from "../comments";
|
|
4
4
|
import { type Column, type Row } from "./column";
|
|
5
|
+
/**
|
|
6
|
+
* `title` is optional (#871) — Attio's own note preview always has one (a
|
|
7
|
+
* real note defaults to "Untitled note" until renamed, confirmed live), but
|
|
8
|
+
* crisp's own data model has never carried a separate note title, only
|
|
9
|
+
* `text`, and no existing consumer supplies one. Adding it as optional
|
|
10
|
+
* rather than required keeps every existing `notes` array valid; a consumer
|
|
11
|
+
* with no title concept just gets the single remaining string inline.
|
|
12
|
+
*/
|
|
5
13
|
export type RecordPageNote = {
|
|
6
14
|
id: string;
|
|
15
|
+
title?: string;
|
|
7
16
|
text: string;
|
|
8
17
|
time: string;
|
|
9
18
|
};
|
|
@@ -91,6 +100,26 @@ export type RecordPageProps = Omit<React.ComponentPropsWithoutRef<"div">, "child
|
|
|
91
100
|
/** When provided, shows a maximise/minimise button in the top bar. */
|
|
92
101
|
onToggleFull?: () => void;
|
|
93
102
|
full?: boolean;
|
|
103
|
+
/**
|
|
104
|
+
* The peek-style header (#624) — measured live: expanding a peek to its
|
|
105
|
+
* full record does NOT revert to the plain breadcrumb, it keeps a hybrid
|
|
106
|
+
* header (Close, Previous/Next, "N of M in <view>" counter), replacing the
|
|
107
|
+
* breadcrumb entirely rather than adding to it. Naming mirrors
|
|
108
|
+
* `RecordPanel`'s own identical props exactly (`onClose`/`closeLabel`,
|
|
109
|
+
* `onPrevious`/`previousRecordLabel`, `onNext`/`nextRecordLabel`,
|
|
110
|
+
* `counterLabel`) — a consumer wiring both components together (a list
|
|
111
|
+
* whose peek expands to this page) reuses the same handlers and state,
|
|
112
|
+
* not a second parallel API. `onClose` alone is enough to switch the
|
|
113
|
+
* topbar into this mode; Previous/Next/counter are each independently
|
|
114
|
+
* optional, same as `RecordPanel`'s own toolbar.
|
|
115
|
+
*/
|
|
116
|
+
onClose?: () => void;
|
|
117
|
+
closeLabel?: string;
|
|
118
|
+
onPrevious?: () => void;
|
|
119
|
+
previousRecordLabel?: string;
|
|
120
|
+
onNext?: () => void;
|
|
121
|
+
nextRecordLabel?: string;
|
|
122
|
+
counterLabel?: React.ReactNode;
|
|
94
123
|
className?: string;
|
|
95
124
|
/**
|
|
96
125
|
* Replaces the built-in CRM tab set. An app with a non-CRM domain (a
|
|
@@ -210,6 +239,29 @@ export type RecordPageLabels = {
|
|
|
210
239
|
comments: string;
|
|
211
240
|
/** Empty state under the Lists panel. */
|
|
212
241
|
noLists: string;
|
|
242
|
+
/** Activity tab toolbar (#622). */
|
|
243
|
+
filters: string;
|
|
244
|
+
addMeeting: string;
|
|
245
|
+
/** Files tab empty state (#622): title, hint body, and its two actions. */
|
|
246
|
+
noFiles: string;
|
|
247
|
+
filesHint: string;
|
|
248
|
+
newFolder: string;
|
|
249
|
+
uploadFile: string;
|
|
250
|
+
/** aria-label on the Files tab empty state's "⋮" overflow button (#622). */
|
|
251
|
+
fileMoreActions: string;
|
|
252
|
+
/** Associated deals tab empty state (#622). */
|
|
253
|
+
noDealsFound: string;
|
|
254
|
+
noDealsHint: string;
|
|
255
|
+
newDeal: string;
|
|
256
|
+
/** Emails tab empty state (#987): the dedicated tab's own illustrated
|
|
257
|
+
* state, distinct from `noEmailsWith` (Overview's condensed embed). */
|
|
258
|
+
noEmails: string;
|
|
259
|
+
noEmailsHint: string;
|
|
260
|
+
configureMailbox: string;
|
|
261
|
+
/** Calls tab empty state (#988): chrome only, no real gating. */
|
|
262
|
+
upgradeToViewCalls: string;
|
|
263
|
+
callsUpgradeHint: string;
|
|
264
|
+
upgrade: string;
|
|
213
265
|
highlights: string;
|
|
214
266
|
recordDetails: string;
|
|
215
267
|
searchFields: string;
|
|
@@ -270,6 +322,28 @@ export type RecordDetailsProps = Omit<React.ComponentPropsWithoutRef<"div">, "ch
|
|
|
270
322
|
onEdit?: (id: string, key: string, value: string) => Promise<void> | void;
|
|
271
323
|
labels?: RecordPageLabelsInput;
|
|
272
324
|
className?: string;
|
|
325
|
+
/**
|
|
326
|
+
* Drag-to-resize (#930) — the same shape `RecordPanel`'s own resize props
|
|
327
|
+
* already have (`resizable`/`width`/`defaultWidth`/`onWidthChange`/
|
|
328
|
+
* `minWidth`/`maxWidth`), so a consumer composing `RecordDetails`
|
|
329
|
+
* standalone (GRC's own record-page rail: its own header/tabs, this
|
|
330
|
+
* component for the details column only) gets Attio's real record-page
|
|
331
|
+
* details-column resize without reimplementing the drag math `RecordPage`
|
|
332
|
+
* already has internally for its own aside. Uncontrolled by default
|
|
333
|
+
* (`defaultWidth`); pass `width`/`onWidthChange` together to own it
|
|
334
|
+
* instead — same controlled/uncontrolled split as `RecordPanel`'s.
|
|
335
|
+
* `minWidth`/`maxWidth`/`defaultWidth` default to the exact clamp
|
|
336
|
+
* `RecordPage`'s own resizer already uses (#798, live-measured: 619/1170,
|
|
337
|
+
* 734 default) — reused, not re-measured. Omit `resizable` (the default)
|
|
338
|
+
* to keep rendering the plain, non-resizing block this component has
|
|
339
|
+
* always been.
|
|
340
|
+
*/
|
|
341
|
+
resizable?: boolean;
|
|
342
|
+
width?: number;
|
|
343
|
+
defaultWidth?: number;
|
|
344
|
+
onWidthChange?: (width: number) => void;
|
|
345
|
+
minWidth?: number;
|
|
346
|
+
maxWidth?: number;
|
|
273
347
|
};
|
|
274
348
|
/**
|
|
275
349
|
* The Details column's own field list, on its own (#528) — `RecordPage`'s
|
|
@@ -292,10 +366,33 @@ export type RecordDetailsProps = Omit<React.ComponentPropsWithoutRef<"div">, "ch
|
|
|
292
366
|
* `RecordPage`'s own root does: `<div className={recordpageRecipe()}>`
|
|
293
367
|
* (also exported from this package).
|
|
294
368
|
*/
|
|
295
|
-
export declare function RecordDetails({ record, columns, sections, onEdit, labels, className, ...rest }: RecordDetailsProps): React.JSX.Element;
|
|
369
|
+
export declare function RecordDetails({ record, columns, sections, onEdit, labels, className, resizable, width: controlledWidth, defaultWidth, onWidthChange, minWidth, maxWidth, ...rest }: RecordDetailsProps): React.JSX.Element;
|
|
296
370
|
export declare namespace RecordDetails {
|
|
297
371
|
var displayName: string;
|
|
298
372
|
}
|
|
373
|
+
export type RecordPageMainProps = React.ComponentPropsWithoutRef<"main">;
|
|
374
|
+
/**
|
|
375
|
+
* The main/tab-content column's own box, on its own (#750) — the same
|
|
376
|
+
* "standalone piece" `RecordDetails` already is for the Details column,
|
|
377
|
+
* mirrored to the other side of the layout. `RecordPage` composes this
|
|
378
|
+
* internally for its own tabbed body (below) — this exact box, not a second
|
|
379
|
+
* copy — so a consumer building a custom record page (its own tab set, its
|
|
380
|
+
* own menu, `RecordDetails` for the left column, but not the full
|
|
381
|
+
* `RecordPage`, which hardcodes the CRM tab set) gets the same
|
|
382
|
+
* Attio-measured inset: `flex: 1; min-width: 0; display: flex;
|
|
383
|
+
* flex-direction: column; min-height: 0; overflow-y: auto; padding: 12px
|
|
384
|
+
* 20px` (`recordpage.recipe.ts`'s own `.crisp-recordpage-main`) — without
|
|
385
|
+
* reaching for that internal class name directly, the only option before
|
|
386
|
+
* this existed.
|
|
387
|
+
*
|
|
388
|
+
* Needs the same single `.crisp-recordpage`-scoped ancestor `RecordDetails`
|
|
389
|
+
* already documents — wrap both in `recordpageRecipe()`, the way
|
|
390
|
+
* `RecordPage`'s own root does.
|
|
391
|
+
*/
|
|
392
|
+
export declare function RecordPageMain({ className, children, ...rest }: RecordPageMainProps): React.JSX.Element;
|
|
393
|
+
export declare namespace RecordPageMain {
|
|
394
|
+
var displayName: string;
|
|
395
|
+
}
|
|
299
396
|
/**
|
|
300
397
|
* The full-page company record view — the page that opens when you click into a
|
|
301
398
|
* record (as opposed to the peek [RecordPanel]). A top breadcrumb bar with
|
|
@@ -304,7 +401,7 @@ export declare namespace RecordDetails {
|
|
|
304
401
|
* Emails sections (Notes & Tasks are live — add and check things off). Drop it
|
|
305
402
|
* into the app's main content area.
|
|
306
403
|
*/
|
|
307
|
-
export declare function RecordPage({ record, columns, collection, labels, onBack, onToggleFull, full, className, onEdit, tabs: tabsProp, defaultTab, notes: notesProp, onAddNote, tasks: tasksProp, onAddTask, onToggleTask, sections, highlights: highlightsProp, quickActions: quickActionsProp, comments: commentsProp, onPostComment, currentUser, onShare, ...rest }: RecordPageProps): React.JSX.Element;
|
|
404
|
+
export declare function RecordPage({ record, columns, collection, labels, onBack, onToggleFull, full, onClose, closeLabel, onPrevious, previousRecordLabel, onNext, nextRecordLabel, counterLabel, className, onEdit, tabs: tabsProp, defaultTab, notes: notesProp, onAddNote, tasks: tasksProp, onAddTask, onToggleTask, sections, highlights: highlightsProp, quickActions: quickActionsProp, comments: commentsProp, onPostComment, currentUser, onShare, ...rest }: RecordPageProps): React.JSX.Element;
|
|
308
405
|
export declare namespace RecordPage {
|
|
309
406
|
var displayName: string;
|
|
310
407
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { type WorkspaceExportRow, WorkspaceGeneralSettings, type WorkspaceGeneralSettingsProps, } from "./workspacegeneralsettings";
|