@cratis/event-models 0.352.0 → 0.352.2

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.
@@ -1,4 +1,4 @@
1
- import { B as N, V as E, c as B, d as F, f as I, h as L, l as j, m as M, t as k, u as Q } from "./DataBindingSections-DAYezlvg.js";
1
+ import { B as N, V as E, c as B, d as F, f as I, h as L, l as j, m as M, t as k, u as Q } from "./DataBindingSections-C5fdyulB.js";
2
2
  import { useState as R } from "react";
3
3
  import { Fragment as S, jsx as o, jsxs as d } from "react/jsx-runtime";
4
4
  import { validateBinding as V } from "@cratis/scene.engine";
@@ -0,0 +1,13 @@
1
+ export interface FormFieldView {
2
+ name: string;
3
+ label: string;
4
+ required?: boolean;
5
+ type?: 'text' | 'number' | 'date' | 'checkbox';
6
+ value?: string | boolean;
7
+ }
8
+ export interface FormFieldsProps {
9
+ fields: readonly FormFieldView[];
10
+ layout?: unknown;
11
+ readOnly?: boolean;
12
+ }
13
+ export declare const FormFields: ({ fields, layout, readOnly }: FormFieldsProps) => import("react").JSX.Element;
@@ -0,0 +1,10 @@
1
+ export interface FormFieldPlacement {
2
+ gridRow?: string;
3
+ gridColumn?: string;
4
+ }
5
+ export interface FormFieldGrid {
6
+ columns: string;
7
+ gap?: string;
8
+ placements: Record<string, FormFieldPlacement>;
9
+ }
10
+ export declare function formFieldGridOf(layout: unknown): FormFieldGrid;
@@ -1,3 +1,4 @@
1
+ import type { ReactNode } from 'react';
1
2
  import type { ChangeLayoutTypeEdit, NodeInspection } from '@cratis/scene.model';
2
3
  import type { SceneOrderedItem } from '../Collections/orderedItems';
3
4
  import type { ScreenEditorController } from '../Host/ScreenEditorController';
@@ -10,6 +11,7 @@ export interface PropertiesPanelProps {
10
11
  strings: ScreenEditorStrings;
11
12
  ownership: Ownership | undefined;
12
13
  authoringTemplate?: string;
14
+ screenProperties?: ReactNode;
13
15
  }
14
- export declare const PropertiesPanel: ({ controller, environment, strings, ownership, authoringTemplate }: PropertiesPanelProps) => import("react").JSX.Element;
16
+ export declare const PropertiesPanel: ({ controller, environment, strings, ownership, authoringTemplate, screenProperties }: PropertiesPanelProps) => import("react").JSX.Element;
15
17
  export type { NodeInspection, ChangeLayoutTypeEdit, SceneOrderedItem };
@@ -8,6 +8,7 @@ export interface ScreenInspectorProps {
8
8
  environment: ScreenEditorEnvironment;
9
9
  authoringTemplate?: string;
10
10
  structure: ReactNode;
11
+ screenProperties?: ReactNode;
11
12
  onClose: () => void;
12
13
  }
13
- export declare const ScreenInspector: ({ strings, controller, environment, authoringTemplate, structure, onClose }: ScreenInspectorProps) => import("react").JSX.Element;
14
+ export declare const ScreenInspector: ({ strings, controller, environment, authoringTemplate, structure, screenProperties, onClose }: ScreenInspectorProps) => import("react").JSX.Element;
@@ -1,3 +1,4 @@
1
+ import type { ReactNode } from 'react';
1
2
  import type { ScreenEditorController } from '../Host/ScreenEditorController';
2
3
  import type { ScreenEditorEnvironment } from '../Host/ScreenEditorHost';
3
4
  import type { ScreenEditorStrings } from './ScreenEditorStrings';
@@ -6,5 +7,6 @@ export interface ScreenPropertiesProps {
6
7
  environment: ScreenEditorEnvironment;
7
8
  strings: ScreenEditorStrings;
8
9
  authoringTemplate?: string;
10
+ hostProperties?: ReactNode;
9
11
  }
10
- export declare const ScreenProperties: ({ controller, environment, strings, authoringTemplate }: ScreenPropertiesProps) => import("react").JSX.Element;
12
+ export declare const ScreenProperties: ({ controller, environment, strings, authoringTemplate, hostProperties }: ScreenPropertiesProps) => import("react").JSX.Element;
@@ -5,6 +5,9 @@ export interface MenuPopoverProps {
5
5
  heading: string;
6
6
  closeLabel: string;
7
7
  className?: string;
8
+ label?: string;
9
+ disabled?: boolean;
10
+ disabledReason?: string;
8
11
  children: ReactNode;
9
12
  }
10
- export declare const MenuPopover: ({ icon, title, heading, closeLabel, className, children }: MenuPopoverProps) => import("react").JSX.Element;
13
+ export declare const MenuPopover: ({ icon, title, heading, closeLabel, className, label, disabled, disabledReason, children }: MenuPopoverProps) => import("react").JSX.Element;
@@ -10,6 +10,9 @@ export interface PaletteFoldersProps {
10
10
  closeLabel: string;
11
11
  strings?: ComponentPickerStrings;
12
12
  usageVersion: number;
13
+ labelled?: boolean;
14
+ disabled?: boolean;
15
+ disabledReason?: string;
13
16
  onAdd: (entry: PickerEntry) => void;
14
17
  }
15
- export declare const PaletteFolders: ({ entries, memory, icon, title, closeLabel, strings, usageVersion, onAdd }: PaletteFoldersProps) => import("react").JSX.Element;
18
+ export declare const PaletteFolders: ({ entries, memory, icon, title, closeLabel, strings, usageVersion, labelled, disabled, disabledReason, onAdd }: PaletteFoldersProps) => import("react").JSX.Element;
@@ -11,8 +11,11 @@ export interface ComponentPaletteInputs {
11
11
  paletteSources: readonly PaletteSource[];
12
12
  onAdd: (entry: PickerEntry) => void;
13
13
  memory?: ComponentPickerMemory;
14
+ labelled?: boolean;
15
+ disabled?: boolean;
16
+ disabledReason?: string;
14
17
  }
15
- export declare function useComponentPalette({ strings, layoutLabels, icons, paletteSources, onAdd, memory: given }: ComponentPaletteInputs): {
18
+ export declare function useComponentPalette({ strings, layoutLabels, icons, paletteSources, onAdd, memory: given, labelled, disabled, disabledReason }: ComponentPaletteInputs): {
16
19
  palette: ReactNode;
17
20
  recordInserted: (key: string) => void;
18
21
  };
@@ -0,0 +1,2 @@
1
+ import type { Screen } from '@cratis/scene.model';
2
+ export declare function dialogTitleOf(screen: Pick<Screen, 'forms'> | undefined): string | undefined;
@@ -18,6 +18,7 @@ export interface FormStandInSource {
18
18
  name?: string;
19
19
  label?: string;
20
20
  }[];
21
+ layout?: unknown;
21
22
  }
22
23
  /**
23
24
  * The stand-ins for the command forms of a screen.