@genesislcap/foundation-entity-management 14.462.0 → 14.463.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.
@@ -1512,6 +1512,36 @@
1512
1512
  "isProtected": false,
1513
1513
  "isAbstract": false
1514
1514
  },
1515
+ {
1516
+ "kind": "Property",
1517
+ "canonicalReference": "@genesislcap/foundation-entity-management!EntityManagement#createLabel:member",
1518
+ "docComment": "/**\n * Custom label for the create button and modal title. When set, overrides the default \"Add {entityLabel}\" text.\n *\n * @example\n *\n * `create-label=\"Reject Price\"` renders a \"Reject Price\" button instead of \"+ Add\"\n *\n * @public\n */\n",
1519
+ "excerptTokens": [
1520
+ {
1521
+ "kind": "Content",
1522
+ "text": "createLabel: "
1523
+ },
1524
+ {
1525
+ "kind": "Content",
1526
+ "text": "string"
1527
+ },
1528
+ {
1529
+ "kind": "Content",
1530
+ "text": ";"
1531
+ }
1532
+ ],
1533
+ "isReadonly": false,
1534
+ "isOptional": false,
1535
+ "releaseTag": "Public",
1536
+ "name": "createLabel",
1537
+ "propertyTypeTokenRange": {
1538
+ "startIndex": 1,
1539
+ "endIndex": 2
1540
+ },
1541
+ "isStatic": false,
1542
+ "isProtected": false,
1543
+ "isAbstract": false
1544
+ },
1515
1545
  {
1516
1546
  "kind": "Property",
1517
1547
  "canonicalReference": "@genesislcap/foundation-entity-management!EntityManagement#crudActionMenuName:member",
@@ -2817,6 +2847,66 @@
2817
2847
  "isProtected": false,
2818
2848
  "isAbstract": false
2819
2849
  },
2850
+ {
2851
+ "kind": "Property",
2852
+ "canonicalReference": "@genesislcap/foundation-entity-management!EntityManagement#successNotificationBody:member",
2853
+ "docComment": "/**\n * Overrides the success notification body shown after a successful form submission. When not set, the default \"The {label} was successfully added/updated/deleted\" body is used.\n *\n * @public\n */\n",
2854
+ "excerptTokens": [
2855
+ {
2856
+ "kind": "Content",
2857
+ "text": "successNotificationBody: "
2858
+ },
2859
+ {
2860
+ "kind": "Content",
2861
+ "text": "string"
2862
+ },
2863
+ {
2864
+ "kind": "Content",
2865
+ "text": ";"
2866
+ }
2867
+ ],
2868
+ "isReadonly": false,
2869
+ "isOptional": false,
2870
+ "releaseTag": "Public",
2871
+ "name": "successNotificationBody",
2872
+ "propertyTypeTokenRange": {
2873
+ "startIndex": 1,
2874
+ "endIndex": 2
2875
+ },
2876
+ "isStatic": false,
2877
+ "isProtected": false,
2878
+ "isAbstract": false
2879
+ },
2880
+ {
2881
+ "kind": "Property",
2882
+ "canonicalReference": "@genesislcap/foundation-entity-management!EntityManagement#successNotificationTitle:member",
2883
+ "docComment": "/**\n * Overrides the success notification title shown after a successful form submission. When not set, the default \"{label} Added / Updated / Deleted\" title is used.\n *\n * @public\n */\n",
2884
+ "excerptTokens": [
2885
+ {
2886
+ "kind": "Content",
2887
+ "text": "successNotificationTitle: "
2888
+ },
2889
+ {
2890
+ "kind": "Content",
2891
+ "text": "string"
2892
+ },
2893
+ {
2894
+ "kind": "Content",
2895
+ "text": ";"
2896
+ }
2897
+ ],
2898
+ "isReadonly": false,
2899
+ "isOptional": false,
2900
+ "releaseTag": "Public",
2901
+ "name": "successNotificationTitle",
2902
+ "propertyTypeTokenRange": {
2903
+ "startIndex": 1,
2904
+ "endIndex": 2
2905
+ },
2906
+ "isStatic": false,
2907
+ "isProtected": false,
2908
+ "isAbstract": false
2909
+ },
2820
2910
  {
2821
2911
  "kind": "Property",
2822
2912
  "canonicalReference": "@genesislcap/foundation-entity-management!EntityManagement#title:member",
@@ -5588,7 +5678,7 @@
5588
5678
  {
5589
5679
  "kind": "Class",
5590
5680
  "canonicalReference": "@genesislcap/foundation-entity-management!SmartFormModal:class",
5591
- "docComment": "/**\n * The Smart Form Modal element. Allows to open a modal with an auto-generated form based on the resource schema.\n *\n * @alpha\n */\n",
5681
+ "docComment": "/**\n * A focused form dialog component that renders a single trigger button which opens a modal containing an auto-generated form.\n *\n * @remarks\n *\n * `smart-form-modal` is a trimmed-down variant of {@link EntityManagement} intended for single-action use cases — approval submissions, bespoke inserts — where you want a button that opens a form modal without the accompanying data grid.\n *\n * The component inherits the full `entity-management` API but exposes a purpose-fit surface of its own:\n *\n * | `smart-form-modal` attr | Underlying property | Notes | |---|---|---| | `event` | `createEvent` | The Genesis event handler that processes the form submission | | `button-label` | `createLabel` | Button and modal title text; replaces the default \"Add {entityLabel}\" | | `form-ui-schema` (`:formUiSchema`) | `createFormUiSchema` | UI schema passed as a property binding | | `success-notification-title` | — | Overrides the toast title shown on successful submit | | `success-notification-body` | — | Overrides the toast body shown on successful submit |\n *\n * The underlying `entity-management` attributes (`createEvent`, `createFormUiSchema`, `create-label`, `confirmation-message`, `default-entity-values`, `design-system-prefix`, `set-approval-message`, `approval-message-label`, `form-renderers`, `additional-form-renderers`, `readonly`) all continue to work — the aliases listed above are simply the preferred vocabulary for this component.\n *\n * Attributes that belong to the grid (`updateEvent`, `deleteEvent`, `columns`, `gridOptions`, `datasource-config`, `resource-name`, `enable-search-bar`, `enable-filter-bar`, etc.) are inherited but have no effect because the grid is always hidden.\n *\n * **Defaults that differ from `entity-management`:** - `modalPosition` defaults to `'centre'` (entity-management defaults to `'right'`) - `crudMenuPosition` defaults to `'top'` (entity-management defaults to `'column'`)\n *\n * @example\n *\n * Minimal usage — form fields are auto-generated from the event schema:\n * ```html\n * <smart-form-modal\n * event=\"EVENT_TRADE_INSERT\"\n * entity-label=\"Trade\"\n * ></smart-form-modal>\n * ```\n *\n * @example\n *\n * Custom action label with styled button via CSS part:\n * ```html\n * <smart-form-modal\n * event=\"EVENT_PRICE_REJECT\"\n * button-label=\"Reject Price\"\n * success-notification-title=\"Price Rejected\"\n * success-notification-body=\"The price was successfully rejected.\"\n * ></smart-form-modal>\n * ```\n *\n * ```css\n * smart-form-modal::part(create-button) {\n * background-color: #d32f2f;\n * color: #fff;\n * }\n * ```\n *\n * @example\n *\n * Controlled form layout via `formUiSchema` property binding:\n * ```html\n * <smart-form-modal\n * event=\"EVENT_COUNTERPARTY_INSERT\"\n * entity-label=\"Counterparty\"\n * :formUiSchema=\"${() => myUiSchema}\"\n * ></smart-form-modal>\n * ```\n *\n * @example\n *\n * Confirmation dialog before submit:\n * ```html\n * <smart-form-modal\n * event=\"EVENT_COUNTERPARTY_INSERT\"\n * entity-label=\"Counterparty\"\n * confirmation-message=\"Are you sure you want to submit?\"\n * ></smart-form-modal>\n * ```\n *\n * @example\n *\n * Read-only view mode:\n * ```html\n * <smart-form-modal\n * event=\"EVENT_TRADE_INSERT\"\n * entity-label=\"Trade\"\n * readonly\n * ></smart-form-modal>\n * ```\n *\n * @csspart create-button - The trigger button that opens the modal. Style via `::part(create-button)`.\n *\n * @fires\n *\n * submit-success - Fired when the form is submitted successfully.\n *\n * @fires\n *\n * submit-failure - Fired when the form submission returns an error.\n *\n * @public\n */\n",
5592
5682
  "excerptTokens": [
5593
5683
  {
5594
5684
  "kind": "Content",
@@ -5605,23 +5695,147 @@
5605
5695
  }
5606
5696
  ],
5607
5697
  "fileUrlPath": "src/entities/smartFormModal.ts",
5608
- "releaseTag": "Alpha",
5698
+ "releaseTag": "Public",
5609
5699
  "isAbstract": false,
5610
5700
  "name": "SmartFormModal",
5611
5701
  "preserveMemberOrder": false,
5612
5702
  "members": [
5613
5703
  {
5614
5704
  "kind": "Property",
5615
- "canonicalReference": "@genesislcap/foundation-entity-management!SmartFormModal#gridVisible:member",
5705
+ "canonicalReference": "@genesislcap/foundation-entity-management!SmartFormModal#buttonLabel:member",
5706
+ "docComment": "/**\n * Text displayed on the trigger button and as the modal title.\n *\n * @remarks\n *\n * Alias for `create-label`. When set, the default \"Add {entityLabel}\" text is replaced entirely and the `+` icon is hidden so the label stands alone.\n *\n * @example\n * ```html\n * <smart-form-modal button-label=\"Reject Price\"></smart-form-modal>\n * ```\n *\n * @public\n */\n",
5707
+ "excerptTokens": [
5708
+ {
5709
+ "kind": "Content",
5710
+ "text": "buttonLabel: "
5711
+ },
5712
+ {
5713
+ "kind": "Content",
5714
+ "text": "string"
5715
+ },
5716
+ {
5717
+ "kind": "Content",
5718
+ "text": ";"
5719
+ }
5720
+ ],
5721
+ "isReadonly": false,
5722
+ "isOptional": false,
5723
+ "releaseTag": "Public",
5724
+ "name": "buttonLabel",
5725
+ "propertyTypeTokenRange": {
5726
+ "startIndex": 1,
5727
+ "endIndex": 2
5728
+ },
5729
+ "isStatic": false,
5730
+ "isProtected": false,
5731
+ "isAbstract": false
5732
+ },
5733
+ {
5734
+ "kind": "Method",
5735
+ "canonicalReference": "@genesislcap/foundation-entity-management!SmartFormModal#buttonLabelChanged:member(1)",
5616
5736
  "docComment": "",
5617
5737
  "excerptTokens": [
5618
5738
  {
5619
5739
  "kind": "Content",
5620
- "text": "gridVisible: "
5740
+ "text": "buttonLabelChanged(_: "
5621
5741
  },
5622
5742
  {
5623
5743
  "kind": "Content",
5624
- "text": "boolean"
5744
+ "text": "string"
5745
+ },
5746
+ {
5747
+ "kind": "Content",
5748
+ "text": ", next: "
5749
+ },
5750
+ {
5751
+ "kind": "Content",
5752
+ "text": "string"
5753
+ },
5754
+ {
5755
+ "kind": "Content",
5756
+ "text": "): "
5757
+ },
5758
+ {
5759
+ "kind": "Content",
5760
+ "text": "void"
5761
+ },
5762
+ {
5763
+ "kind": "Content",
5764
+ "text": ";"
5765
+ }
5766
+ ],
5767
+ "isStatic": false,
5768
+ "returnTypeTokenRange": {
5769
+ "startIndex": 5,
5770
+ "endIndex": 6
5771
+ },
5772
+ "releaseTag": "Public",
5773
+ "isProtected": false,
5774
+ "overloadIndex": 1,
5775
+ "parameters": [
5776
+ {
5777
+ "parameterName": "_",
5778
+ "parameterTypeTokenRange": {
5779
+ "startIndex": 1,
5780
+ "endIndex": 2
5781
+ },
5782
+ "isOptional": false
5783
+ },
5784
+ {
5785
+ "parameterName": "next",
5786
+ "parameterTypeTokenRange": {
5787
+ "startIndex": 3,
5788
+ "endIndex": 4
5789
+ },
5790
+ "isOptional": false
5791
+ }
5792
+ ],
5793
+ "isOptional": false,
5794
+ "isAbstract": false,
5795
+ "name": "buttonLabelChanged"
5796
+ },
5797
+ {
5798
+ "kind": "Property",
5799
+ "canonicalReference": "@genesislcap/foundation-entity-management!SmartFormModal#entityLabel:member",
5800
+ "docComment": "/**\n * Label appended to the default button text, producing \"Add {entity-label}\".\n *\n * @remarks\n *\n * Re-declares the inherited `entityLabel` attr explicitly so FAST observes it on this element. Has no effect when `button-label` is also set — `button-label` takes full precedence.\n *\n * @example\n * ```html\n * <smart-form-modal event=\"EVENT_TRADE_INSERT\" entity-label=\"Trade\"></smart-form-modal>\n * ```\n *\n * @public\n */\n",
5801
+ "excerptTokens": [
5802
+ {
5803
+ "kind": "Content",
5804
+ "text": "entityLabel: "
5805
+ },
5806
+ {
5807
+ "kind": "Content",
5808
+ "text": "string"
5809
+ },
5810
+ {
5811
+ "kind": "Content",
5812
+ "text": ";"
5813
+ }
5814
+ ],
5815
+ "isReadonly": false,
5816
+ "isOptional": false,
5817
+ "releaseTag": "Public",
5818
+ "name": "entityLabel",
5819
+ "propertyTypeTokenRange": {
5820
+ "startIndex": 1,
5821
+ "endIndex": 2
5822
+ },
5823
+ "isStatic": false,
5824
+ "isProtected": false,
5825
+ "isAbstract": false
5826
+ },
5827
+ {
5828
+ "kind": "Property",
5829
+ "canonicalReference": "@genesislcap/foundation-entity-management!SmartFormModal#event:member",
5830
+ "docComment": "/**\n * The Genesis event handler that processes the form submission.\n *\n * @remarks\n *\n * Alias for `createEvent`. Prefer `event` when using `smart-form-modal` — it reads more naturally for single-action components where the CRUD framing of `createEvent` does not apply.\n *\n * @example\n * ```html\n * <smart-form-modal event=\"EVENT_TRADE_INSERT\"></smart-form-modal>\n * ```\n *\n * @public\n */\n",
5831
+ "excerptTokens": [
5832
+ {
5833
+ "kind": "Content",
5834
+ "text": "event: "
5835
+ },
5836
+ {
5837
+ "kind": "Content",
5838
+ "text": "string"
5625
5839
  },
5626
5840
  {
5627
5841
  "kind": "Content",
@@ -5630,8 +5844,8 @@
5630
5844
  ],
5631
5845
  "isReadonly": false,
5632
5846
  "isOptional": false,
5633
- "releaseTag": "Alpha",
5634
- "name": "gridVisible",
5847
+ "releaseTag": "Public",
5848
+ "name": "event",
5635
5849
  "propertyTypeTokenRange": {
5636
5850
  "startIndex": 1,
5637
5851
  "endIndex": 2
@@ -5639,6 +5853,167 @@
5639
5853
  "isStatic": false,
5640
5854
  "isProtected": false,
5641
5855
  "isAbstract": false
5856
+ },
5857
+ {
5858
+ "kind": "Method",
5859
+ "canonicalReference": "@genesislcap/foundation-entity-management!SmartFormModal#eventChanged:member(1)",
5860
+ "docComment": "",
5861
+ "excerptTokens": [
5862
+ {
5863
+ "kind": "Content",
5864
+ "text": "eventChanged(_: "
5865
+ },
5866
+ {
5867
+ "kind": "Content",
5868
+ "text": "string"
5869
+ },
5870
+ {
5871
+ "kind": "Content",
5872
+ "text": ", next: "
5873
+ },
5874
+ {
5875
+ "kind": "Content",
5876
+ "text": "string"
5877
+ },
5878
+ {
5879
+ "kind": "Content",
5880
+ "text": "): "
5881
+ },
5882
+ {
5883
+ "kind": "Content",
5884
+ "text": "void"
5885
+ },
5886
+ {
5887
+ "kind": "Content",
5888
+ "text": ";"
5889
+ }
5890
+ ],
5891
+ "isStatic": false,
5892
+ "returnTypeTokenRange": {
5893
+ "startIndex": 5,
5894
+ "endIndex": 6
5895
+ },
5896
+ "releaseTag": "Public",
5897
+ "isProtected": false,
5898
+ "overloadIndex": 1,
5899
+ "parameters": [
5900
+ {
5901
+ "parameterName": "_",
5902
+ "parameterTypeTokenRange": {
5903
+ "startIndex": 1,
5904
+ "endIndex": 2
5905
+ },
5906
+ "isOptional": false
5907
+ },
5908
+ {
5909
+ "parameterName": "next",
5910
+ "parameterTypeTokenRange": {
5911
+ "startIndex": 3,
5912
+ "endIndex": 4
5913
+ },
5914
+ "isOptional": false
5915
+ }
5916
+ ],
5917
+ "isOptional": false,
5918
+ "isAbstract": false,
5919
+ "name": "eventChanged"
5920
+ },
5921
+ {
5922
+ "kind": "Property",
5923
+ "canonicalReference": "@genesislcap/foundation-entity-management!SmartFormModal#formUiSchema:member",
5924
+ "docComment": "/**\n * UI schema that controls the layout and visibility of form fields.\n *\n * @remarks\n *\n * Alias for `createFormUiSchema`. Must be set as a property binding (`:formUiSchema`) since it accepts a `UiSchema` object, not a plain string attribute.\n *\n * When omitted, the form is auto-generated from the event's server-side schema.\n *\n * @example\n * ```html\n * <smart-form-modal\n * event=\"EVENT_COUNTERPARTY_INSERT\"\n * :formUiSchema=\"${() => ({\n * type: 'VerticalLayout',\n * elements: [\n * { type: 'Control', scope: '#/properties/NAME' },\n * { type: 'Control', scope: '#/properties/ENABLED' },\n * ],\n * })}\"\n * ></smart-form-modal>\n * ```\n *\n * @public\n */\n",
5925
+ "excerptTokens": [
5926
+ {
5927
+ "kind": "Content",
5928
+ "text": "formUiSchema: "
5929
+ },
5930
+ {
5931
+ "kind": "Reference",
5932
+ "text": "UiSchema",
5933
+ "canonicalReference": "@genesislcap/foundation-forms!UiSchema:type"
5934
+ },
5935
+ {
5936
+ "kind": "Content",
5937
+ "text": ";"
5938
+ }
5939
+ ],
5940
+ "isReadonly": false,
5941
+ "isOptional": false,
5942
+ "releaseTag": "Public",
5943
+ "name": "formUiSchema",
5944
+ "propertyTypeTokenRange": {
5945
+ "startIndex": 1,
5946
+ "endIndex": 2
5947
+ },
5948
+ "isStatic": false,
5949
+ "isProtected": false,
5950
+ "isAbstract": false
5951
+ },
5952
+ {
5953
+ "kind": "Method",
5954
+ "canonicalReference": "@genesislcap/foundation-entity-management!SmartFormModal#formUiSchemaChanged:member(1)",
5955
+ "docComment": "",
5956
+ "excerptTokens": [
5957
+ {
5958
+ "kind": "Content",
5959
+ "text": "formUiSchemaChanged(_: "
5960
+ },
5961
+ {
5962
+ "kind": "Reference",
5963
+ "text": "UiSchema",
5964
+ "canonicalReference": "@genesislcap/foundation-forms!UiSchema:type"
5965
+ },
5966
+ {
5967
+ "kind": "Content",
5968
+ "text": ", next: "
5969
+ },
5970
+ {
5971
+ "kind": "Reference",
5972
+ "text": "UiSchema",
5973
+ "canonicalReference": "@genesislcap/foundation-forms!UiSchema:type"
5974
+ },
5975
+ {
5976
+ "kind": "Content",
5977
+ "text": "): "
5978
+ },
5979
+ {
5980
+ "kind": "Content",
5981
+ "text": "void"
5982
+ },
5983
+ {
5984
+ "kind": "Content",
5985
+ "text": ";"
5986
+ }
5987
+ ],
5988
+ "isStatic": false,
5989
+ "returnTypeTokenRange": {
5990
+ "startIndex": 5,
5991
+ "endIndex": 6
5992
+ },
5993
+ "releaseTag": "Public",
5994
+ "isProtected": false,
5995
+ "overloadIndex": 1,
5996
+ "parameters": [
5997
+ {
5998
+ "parameterName": "_",
5999
+ "parameterTypeTokenRange": {
6000
+ "startIndex": 1,
6001
+ "endIndex": 2
6002
+ },
6003
+ "isOptional": false
6004
+ },
6005
+ {
6006
+ "parameterName": "next",
6007
+ "parameterTypeTokenRange": {
6008
+ "startIndex": 3,
6009
+ "endIndex": 4
6010
+ },
6011
+ "isOptional": false
6012
+ }
6013
+ ],
6014
+ "isOptional": false,
6015
+ "isAbstract": false,
6016
+ "name": "formUiSchemaChanged"
5642
6017
  }
5643
6018
  ],
5644
6019
  "extendsTokenRange": {
@@ -335,6 +335,18 @@ export declare class EntityManagement extends EntityManagement_base {
335
335
  * @public
336
336
  */
337
337
  errorNotificationConfig: NotificationStructure['config'];
338
+ /**
339
+ * Overrides the success notification title shown after a successful form submission.
340
+ * When not set, the default "{label} Added / Updated / Deleted" title is used.
341
+ * @public
342
+ */
343
+ successNotificationTitle: string;
344
+ /**
345
+ * Overrides the success notification body shown after a successful form submission.
346
+ * When not set, the default "The {label} was successfully added/updated/deleted" body is used.
347
+ * @public
348
+ */
349
+ successNotificationBody: string;
338
350
  /**
339
351
  * Title of the grid
340
352
  * @public
@@ -345,6 +357,12 @@ export declare class EntityManagement extends EntityManagement_base {
345
357
  * @public
346
358
  */
347
359
  entityLabel: string;
360
+ /**
361
+ * Custom label for the create button and modal title. When set, overrides the default "Add {entityLabel}" text.
362
+ * @example `create-label="Reject Price"` renders a "Reject Price" button instead of "+ Add"
363
+ * @public
364
+ */
365
+ createLabel: string;
348
366
  /**
349
367
  * Whether to use the `applyTransactionAsync` function for *add* transactions
350
368
  * @remarks Defaults to false
@@ -1088,7 +1106,17 @@ declare const EntityManagement_base: (new (...args: any[]) => {
1088
1106
  setAttributeNodeNS(attr: Attr): Attr | null;
1089
1107
  setHTMLUnsafe(html: string): void;
1090
1108
  setPointerCapture(pointerId: number): void;
1091
- toggleAttribute(qualifiedName: string, force?: boolean): boolean;
1109
+ toggleAttribute(qualifiedName: string, force
1110
+ /**
1111
+ * Whether to use the `applyTransactionAsync` function for *update* transactions
1112
+ * @remarks Defaults to true
1113
+ * @internal
1114
+ */
1115
+ ? /**
1116
+ * Whether to use the `applyTransactionAsync` function for *update* transactions
1117
+ * @remarks Defaults to true
1118
+ * @internal
1119
+ */: boolean): boolean;
1092
1120
  webkitMatchesSelector(selectors: string): boolean;
1093
1121
  textContent: string;
1094
1122
  readonly baseURI: string;
@@ -1910,12 +1938,179 @@ declare type RouterSettings = {
1910
1938
  };
1911
1939
 
1912
1940
  /**
1913
- * The Smart Form Modal element. Allows to open a modal with an auto-generated form based
1914
- * on the resource schema.
1915
- * @alpha
1941
+ * A focused form dialog component that renders a single trigger button which opens a modal
1942
+ * containing an auto-generated form.
1943
+ *
1944
+ * @remarks
1945
+ * `smart-form-modal` is a trimmed-down variant of {@link EntityManagement} intended for
1946
+ * single-action use cases — approval submissions, bespoke inserts —
1947
+ * where you want a button that opens a form modal without the accompanying data grid.
1948
+ *
1949
+ * The component inherits the full `entity-management` API but exposes a purpose-fit surface
1950
+ * of its own:
1951
+ *
1952
+ * | `smart-form-modal` attr | Underlying property | Notes |
1953
+ * |---|---|---|
1954
+ * | `event` | `createEvent` | The Genesis event handler that processes the form submission |
1955
+ * | `button-label` | `createLabel` | Button and modal title text; replaces the default "Add {entityLabel}" |
1956
+ * | `form-ui-schema` (`:formUiSchema`) | `createFormUiSchema` | UI schema passed as a property binding |
1957
+ * | `success-notification-title` | — | Overrides the toast title shown on successful submit |
1958
+ * | `success-notification-body` | — | Overrides the toast body shown on successful submit |
1959
+ *
1960
+ * The underlying `entity-management` attributes (`createEvent`, `createFormUiSchema`,
1961
+ * `create-label`, `confirmation-message`, `default-entity-values`, `design-system-prefix`,
1962
+ * `set-approval-message`, `approval-message-label`, `form-renderers`,
1963
+ * `additional-form-renderers`, `readonly`) all continue to work — the aliases listed above
1964
+ * are simply the preferred vocabulary for this component.
1965
+ *
1966
+ * Attributes that belong to the grid (`updateEvent`, `deleteEvent`, `columns`, `gridOptions`,
1967
+ * `datasource-config`, `resource-name`, `enable-search-bar`, `enable-filter-bar`, etc.) are
1968
+ * inherited but have no effect because the grid is always hidden.
1969
+ *
1970
+ * **Defaults that differ from `entity-management`:**
1971
+ * - `modalPosition` defaults to `'centre'` (entity-management defaults to `'right'`)
1972
+ * - `crudMenuPosition` defaults to `'top'` (entity-management defaults to `'column'`)
1973
+ *
1974
+ * @example
1975
+ * Minimal usage — form fields are auto-generated from the event schema:
1976
+ * ```html
1977
+ * <smart-form-modal
1978
+ * event="EVENT_TRADE_INSERT"
1979
+ * entity-label="Trade"
1980
+ * ></smart-form-modal>
1981
+ * ```
1982
+ *
1983
+ * @example
1984
+ * Custom action label with styled button via CSS part:
1985
+ * ```html
1986
+ * <smart-form-modal
1987
+ * event="EVENT_PRICE_REJECT"
1988
+ * button-label="Reject Price"
1989
+ * success-notification-title="Price Rejected"
1990
+ * success-notification-body="The price was successfully rejected."
1991
+ * ></smart-form-modal>
1992
+ * ```
1993
+ * ```css
1994
+ * smart-form-modal::part(create-button) {
1995
+ * background-color: #d32f2f;
1996
+ * color: #fff;
1997
+ * }
1998
+ * ```
1999
+ *
2000
+ * @example
2001
+ * Controlled form layout via `formUiSchema` property binding:
2002
+ * ```html
2003
+ * <smart-form-modal
2004
+ * event="EVENT_COUNTERPARTY_INSERT"
2005
+ * entity-label="Counterparty"
2006
+ * :formUiSchema="${() => myUiSchema}"
2007
+ * ></smart-form-modal>
2008
+ * ```
2009
+ *
2010
+ * @example
2011
+ * Confirmation dialog before submit:
2012
+ * ```html
2013
+ * <smart-form-modal
2014
+ * event="EVENT_COUNTERPARTY_INSERT"
2015
+ * entity-label="Counterparty"
2016
+ * confirmation-message="Are you sure you want to submit?"
2017
+ * ></smart-form-modal>
2018
+ * ```
2019
+ *
2020
+ * @example
2021
+ * Read-only view mode:
2022
+ * ```html
2023
+ * <smart-form-modal
2024
+ * event="EVENT_TRADE_INSERT"
2025
+ * entity-label="Trade"
2026
+ * readonly
2027
+ * ></smart-form-modal>
2028
+ * ```
2029
+ *
2030
+ * @csspart create-button - The trigger button that opens the modal. Style via `::part(create-button)`.
2031
+ *
2032
+ * @fires submit-success - Fired when the form is submitted successfully.
2033
+ * @fires submit-failure - Fired when the form submission returns an error.
2034
+ *
2035
+ * @public
1916
2036
  */
1917
2037
  export declare class SmartFormModal extends EntityManagement {
2038
+ /** @internal */
1918
2039
  gridVisible: boolean;
2040
+ /** @internal */
2041
+ modalPosition: 'centre' | 'left' | 'right';
2042
+ /** @internal */
2043
+ crudMenuPosition: CrudMenuPosition;
2044
+ /**
2045
+ * The Genesis event handler that processes the form submission.
2046
+ *
2047
+ * @remarks
2048
+ * Alias for `createEvent`. Prefer `event` when using `smart-form-modal` — it reads more
2049
+ * naturally for single-action components where the CRUD framing of `createEvent` does not apply.
2050
+ *
2051
+ * @example
2052
+ * ```html
2053
+ * <smart-form-modal event="EVENT_TRADE_INSERT"></smart-form-modal>
2054
+ * ```
2055
+ * @public
2056
+ */
2057
+ event: string;
2058
+ eventChanged(_: string, next: string): void;
2059
+ /**
2060
+ * Label appended to the default button text, producing "Add {entity-label}".
2061
+ *
2062
+ * @remarks
2063
+ * Re-declares the inherited `entityLabel` attr explicitly so FAST observes it on this element.
2064
+ * Has no effect when `button-label` is also set — `button-label` takes full precedence.
2065
+ *
2066
+ * @example
2067
+ * ```html
2068
+ * <smart-form-modal event="EVENT_TRADE_INSERT" entity-label="Trade"></smart-form-modal>
2069
+ * ```
2070
+ * @public
2071
+ */
2072
+ entityLabel: string;
2073
+ /**
2074
+ * UI schema that controls the layout and visibility of form fields.
2075
+ *
2076
+ * @remarks
2077
+ * Alias for `createFormUiSchema`. Must be set as a property binding (`:formUiSchema`) since it
2078
+ * accepts a `UiSchema` object, not a plain string attribute.
2079
+ *
2080
+ * When omitted, the form is auto-generated from the event's server-side schema.
2081
+ *
2082
+ * @example
2083
+ * ```html
2084
+ * <smart-form-modal
2085
+ * event="EVENT_COUNTERPARTY_INSERT"
2086
+ * :formUiSchema="${() => ({
2087
+ * type: 'VerticalLayout',
2088
+ * elements: [
2089
+ * { type: 'Control', scope: '#/properties/NAME' },
2090
+ * { type: 'Control', scope: '#/properties/ENABLED' },
2091
+ * ],
2092
+ * })}"
2093
+ * ></smart-form-modal>
2094
+ * ```
2095
+ * @public
2096
+ */
2097
+ formUiSchema: UiSchema;
2098
+ formUiSchemaChanged(_: UiSchema, next: UiSchema): void;
2099
+ /**
2100
+ * Text displayed on the trigger button and as the modal title.
2101
+ *
2102
+ * @remarks
2103
+ * Alias for `create-label`. When set, the default "Add {entityLabel}" text is replaced
2104
+ * entirely and the `+` icon is hidden so the label stands alone.
2105
+ *
2106
+ * @example
2107
+ * ```html
2108
+ * <smart-form-modal button-label="Reject Price"></smart-form-modal>
2109
+ * ```
2110
+ * @public
2111
+ */
2112
+ buttonLabel: string;
2113
+ buttonLabelChanged(_: string, next: string): void;
1919
2114
  }
1920
2115
 
1921
2116
  export { UiSchema }