@cere/cere-design-system 0.0.32 → 0.0.33
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/.specify/memory/components-reference.md +38 -0
- package/dist/index.d.mts +11 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.js +10 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +10 -2
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -513,6 +513,44 @@ const items: BreadcrumbItem[] = [
|
|
|
513
513
|
|
|
514
514
|
## LAYOUT
|
|
515
515
|
|
|
516
|
+
### EntityHeader
|
|
517
|
+
Composite header for entities (workspaces, accounts, etc.) with title, metadata, and action slots.
|
|
518
|
+
|
|
519
|
+
```typescript
|
|
520
|
+
import { EntityHeader } from '@cere/cere-design-system';
|
|
521
|
+
import type { EntityHeaderProps, PrimaryAction } from '@cere/cere-design-system';
|
|
522
|
+
|
|
523
|
+
<EntityHeader
|
|
524
|
+
title="Game Co. WF 1769936170928"
|
|
525
|
+
subtitle="Gaming Demo Account"
|
|
526
|
+
role="Manager"
|
|
527
|
+
id="W1234567890"
|
|
528
|
+
startActions={<Button variant="secondary">Export</Button>}
|
|
529
|
+
primaryAction={{
|
|
530
|
+
label: 'Members',
|
|
531
|
+
count: 5,
|
|
532
|
+
icon: <AddCircleIcon />,
|
|
533
|
+
onClick: () => console.log('Open members')
|
|
534
|
+
}}
|
|
535
|
+
endActions={<Button variant="tertiary">Settings</Button>}
|
|
536
|
+
onCopyId={() => console.log('ID copied')}
|
|
537
|
+
onMoreOptions={(e) => setAnchorEl(e.currentTarget)}
|
|
538
|
+
/>
|
|
539
|
+
```
|
|
540
|
+
|
|
541
|
+
**Props:**
|
|
542
|
+
- `title: string` - Primary title text (required)
|
|
543
|
+
- `subtitle?: string` - Secondary descriptive text
|
|
544
|
+
- `role?: string` - Role/status label displayed as RoleBadge pill
|
|
545
|
+
- `id?: string` - Entity identifier displayed as IDBlock with copy action
|
|
546
|
+
- `primaryAction?: PrimaryAction` - Main action button config (`{ label, count?, icon?, onClick? }`)
|
|
547
|
+
- `startActions?: ReactNode` - Custom content rendered before the primary action button
|
|
548
|
+
- `endActions?: ReactNode` - Custom content rendered after the primary action button (before more-options)
|
|
549
|
+
- `onCopyId?: () => void` - Callback when ID is copied
|
|
550
|
+
- `onMoreOptions?: (event) => void` - Callback when more options button clicked
|
|
551
|
+
- `headingLevel?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6'` - HTML heading level (default: 'h2')
|
|
552
|
+
- `divider?: boolean` - Show bottom divider line (default: true)
|
|
553
|
+
|
|
516
554
|
### Card
|
|
517
555
|
Container card with header, content, and actions.
|
|
518
556
|
|
package/dist/index.d.mts
CHANGED
|
@@ -1230,6 +1230,17 @@ interface EntityHeaderProps {
|
|
|
1230
1230
|
* Main action button configuration
|
|
1231
1231
|
*/
|
|
1232
1232
|
primaryAction?: PrimaryAction;
|
|
1233
|
+
/**
|
|
1234
|
+
* Additional content rendered before the primary action button.
|
|
1235
|
+
* Accepts any ReactNode (buttons, dropdowns, etc.).
|
|
1236
|
+
*/
|
|
1237
|
+
startActions?: React__default.ReactNode;
|
|
1238
|
+
/**
|
|
1239
|
+
* Additional content rendered after the primary action button
|
|
1240
|
+
* but before the more-options icon button.
|
|
1241
|
+
* Accepts any ReactNode (buttons, dropdowns, etc.).
|
|
1242
|
+
*/
|
|
1243
|
+
endActions?: React__default.ReactNode;
|
|
1233
1244
|
/**
|
|
1234
1245
|
* Callback when ID is copied (internal copy + this callback)
|
|
1235
1246
|
*/
|
package/dist/index.d.ts
CHANGED
|
@@ -1230,6 +1230,17 @@ interface EntityHeaderProps {
|
|
|
1230
1230
|
* Main action button configuration
|
|
1231
1231
|
*/
|
|
1232
1232
|
primaryAction?: PrimaryAction;
|
|
1233
|
+
/**
|
|
1234
|
+
* Additional content rendered before the primary action button.
|
|
1235
|
+
* Accepts any ReactNode (buttons, dropdowns, etc.).
|
|
1236
|
+
*/
|
|
1237
|
+
startActions?: React__default.ReactNode;
|
|
1238
|
+
/**
|
|
1239
|
+
* Additional content rendered after the primary action button
|
|
1240
|
+
* but before the more-options icon button.
|
|
1241
|
+
* Accepts any ReactNode (buttons, dropdowns, etc.).
|
|
1242
|
+
*/
|
|
1243
|
+
endActions?: React__default.ReactNode;
|
|
1233
1244
|
/**
|
|
1234
1245
|
* Callback when ID is copied (internal copy + this callback)
|
|
1235
1246
|
*/
|
package/dist/index.js
CHANGED
|
@@ -4991,6 +4991,8 @@ var EntityHeader = ({
|
|
|
4991
4991
|
role,
|
|
4992
4992
|
id,
|
|
4993
4993
|
primaryAction,
|
|
4994
|
+
startActions,
|
|
4995
|
+
endActions,
|
|
4994
4996
|
onCopyId,
|
|
4995
4997
|
onMoreOptions,
|
|
4996
4998
|
headingLevel = "h2",
|
|
@@ -5079,6 +5081,7 @@ var EntityHeader = ({
|
|
|
5079
5081
|
flexShrink: 0
|
|
5080
5082
|
},
|
|
5081
5083
|
children: [
|
|
5084
|
+
startActions,
|
|
5082
5085
|
primaryAction && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
|
|
5083
5086
|
Button,
|
|
5084
5087
|
{
|
|
@@ -5091,6 +5094,7 @@ var EntityHeader = ({
|
|
|
5091
5094
|
children: getPrimaryActionLabel()
|
|
5092
5095
|
}
|
|
5093
5096
|
),
|
|
5097
|
+
endActions,
|
|
5094
5098
|
onMoreOptions && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
|
|
5095
5099
|
import_IconButton4.default,
|
|
5096
5100
|
{
|
|
@@ -8707,14 +8711,18 @@ var configureTypeScript = (monaco) => {
|
|
|
8707
8711
|
target: monaco.languages.typescript.ScriptTarget.ES2020,
|
|
8708
8712
|
allowNonTsExtensions: true,
|
|
8709
8713
|
moduleResolution: monaco.languages.typescript.ModuleResolutionKind.NodeJs,
|
|
8710
|
-
module: monaco.languages.typescript.ModuleKind.
|
|
8714
|
+
module: monaco.languages.typescript.ModuleKind.ESNext,
|
|
8711
8715
|
noEmit: false,
|
|
8712
8716
|
lib: ["es2020", "dom"],
|
|
8713
8717
|
noUnusedLocals: false,
|
|
8714
8718
|
noUnusedParameters: false,
|
|
8715
8719
|
noImplicitAny: false,
|
|
8716
8720
|
noImplicitReturns: false,
|
|
8717
|
-
noFallthroughCasesInSwitch: false
|
|
8721
|
+
noFallthroughCasesInSwitch: false,
|
|
8722
|
+
// Treat every file as a module so top-level declarations don't clash
|
|
8723
|
+
// across files in the workspace (prevents false "Cannot redeclare" errors).
|
|
8724
|
+
moduleDetection: 3
|
|
8725
|
+
// ts.ModuleDetectionKind.Force
|
|
8718
8726
|
});
|
|
8719
8727
|
monaco.languages.typescript.typescriptDefaults.setDiagnosticsOptions({
|
|
8720
8728
|
noSemanticValidation: false,
|