@rippling/rippling-sdk 0.2.0-alpha.34 → 0.2.0-alpha.36
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/client.d.mts +6 -0
- package/client.d.mts.map +1 -1
- package/client.d.ts +6 -0
- package/client.d.ts.map +1 -1
- package/client.js +6 -0
- package/client.js.map +1 -1
- package/client.mjs +6 -0
- package/client.mjs.map +1 -1
- package/examples/.keep +4 -0
- package/examples/manifest/dental-practice-management/dental-practice-management.ts +651 -0
- package/examples/manifest/dental-practice-management/manifest.json +1870 -0
- package/examples/manifest/gym-membership-management/gym-membership-management.ts +757 -0
- package/examples/manifest/gym-membership-management/manifest.json +1975 -0
- package/examples/sdui/sdui-crud-todo/rippling-function.ts +367 -0
- package/examples/sdui/sdui-crud-todo/sdui-crud-todo.ts +282 -0
- package/examples/sdui/sdui-showcase/rippling-function.ts +381 -0
- package/examples/sdui/sdui-showcase/sdui-showcase.ts +351 -0
- package/examples/sdui/sdui-tab-multi-view/rippling-function.ts +1061 -0
- package/examples/sdui/sdui-tab-multi-view/sdui-tab-multi-view.ts +924 -0
- package/examples/sdui/vote/rippling-function.ts +330 -0
- package/examples/sdui/vote/vote.ts +298 -0
- package/lib/manifest/app.d.mts +81 -13
- package/lib/manifest/app.d.mts.map +1 -1
- package/lib/manifest/app.d.ts +81 -13
- package/lib/manifest/app.d.ts.map +1 -1
- package/lib/manifest/app.js +37 -16
- package/lib/manifest/app.js.map +1 -1
- package/lib/manifest/app.mjs +37 -16
- package/lib/manifest/app.mjs.map +1 -1
- package/lib/manifest/category.d.mts +63 -7
- package/lib/manifest/category.d.mts.map +1 -1
- package/lib/manifest/category.d.ts +63 -7
- package/lib/manifest/category.d.ts.map +1 -1
- package/lib/manifest/category.js +45 -10
- package/lib/manifest/category.js.map +1 -1
- package/lib/manifest/category.mjs +43 -8
- package/lib/manifest/category.mjs.map +1 -1
- package/lib/manifest/custom-object-field-section.d.mts +56 -6
- package/lib/manifest/custom-object-field-section.d.mts.map +1 -1
- package/lib/manifest/custom-object-field-section.d.ts +56 -6
- package/lib/manifest/custom-object-field-section.d.ts.map +1 -1
- package/lib/manifest/custom-object-field-section.js +41 -14
- package/lib/manifest/custom-object-field-section.js.map +1 -1
- package/lib/manifest/custom-object-field-section.mjs +39 -12
- package/lib/manifest/custom-object-field-section.mjs.map +1 -1
- package/lib/manifest/custom-object-page-layout.d.mts +201 -41
- package/lib/manifest/custom-object-page-layout.d.mts.map +1 -1
- package/lib/manifest/custom-object-page-layout.d.ts +201 -41
- package/lib/manifest/custom-object-page-layout.d.ts.map +1 -1
- package/lib/manifest/custom-object-page-layout.js +76 -30
- package/lib/manifest/custom-object-page-layout.js.map +1 -1
- package/lib/manifest/custom-object-page-layout.mjs +74 -28
- package/lib/manifest/custom-object-page-layout.mjs.map +1 -1
- package/lib/manifest/custom-object.d.mts +128 -15
- package/lib/manifest/custom-object.d.mts.map +1 -1
- package/lib/manifest/custom-object.d.ts +128 -15
- package/lib/manifest/custom-object.d.ts.map +1 -1
- package/lib/manifest/custom-object.js +61 -26
- package/lib/manifest/custom-object.js.map +1 -1
- package/lib/manifest/custom-object.mjs +61 -26
- package/lib/manifest/custom-object.mjs.map +1 -1
- package/lib/manifest/field.d.mts +265 -54
- package/lib/manifest/field.d.mts.map +1 -1
- package/lib/manifest/field.d.ts +265 -54
- package/lib/manifest/field.d.ts.map +1 -1
- package/lib/manifest/field.js +100 -57
- package/lib/manifest/field.js.map +1 -1
- package/lib/manifest/field.mjs +100 -57
- package/lib/manifest/field.mjs.map +1 -1
- package/lib/manifest/list-view.d.mts +105 -14
- package/lib/manifest/list-view.d.mts.map +1 -1
- package/lib/manifest/list-view.d.ts +105 -14
- package/lib/manifest/list-view.d.ts.map +1 -1
- package/lib/manifest/list-view.js +50 -14
- package/lib/manifest/list-view.js.map +1 -1
- package/lib/manifest/list-view.mjs +48 -12
- package/lib/manifest/list-view.mjs.map +1 -1
- package/lib/manifest/manifest-builder.d.mts +77 -11
- package/lib/manifest/manifest-builder.d.mts.map +1 -1
- package/lib/manifest/manifest-builder.d.ts +77 -11
- package/lib/manifest/manifest-builder.d.ts.map +1 -1
- package/lib/manifest/manifest-builder.js +46 -24
- package/lib/manifest/manifest-builder.js.map +1 -1
- package/lib/manifest/manifest-builder.mjs +44 -22
- package/lib/manifest/manifest-builder.mjs.map +1 -1
- package/lib/manifest/manifest-function.d.mts +92 -12
- package/lib/manifest/manifest-function.d.mts.map +1 -1
- package/lib/manifest/manifest-function.d.ts +92 -12
- package/lib/manifest/manifest-function.d.ts.map +1 -1
- package/lib/manifest/manifest-function.js +40 -11
- package/lib/manifest/manifest-function.js.map +1 -1
- package/lib/manifest/manifest-function.mjs +38 -9
- package/lib/manifest/manifest-function.mjs.map +1 -1
- package/lib/manifest/rule.d.mts +94 -16
- package/lib/manifest/rule.d.mts.map +1 -1
- package/lib/manifest/rule.d.ts +94 -16
- package/lib/manifest/rule.d.ts.map +1 -1
- package/lib/manifest/rule.js +36 -15
- package/lib/manifest/rule.js.map +1 -1
- package/lib/manifest/rule.mjs +36 -15
- package/lib/manifest/rule.mjs.map +1 -1
- package/lib/manifest/sdui-page.d.mts +67 -11
- package/lib/manifest/sdui-page.d.mts.map +1 -1
- package/lib/manifest/sdui-page.d.ts +67 -11
- package/lib/manifest/sdui-page.d.ts.map +1 -1
- package/lib/manifest/sdui-page.js +44 -13
- package/lib/manifest/sdui-page.js.map +1 -1
- package/lib/manifest/sdui-page.mjs +42 -11
- package/lib/manifest/sdui-page.mjs.map +1 -1
- package/lib/manifest/validation.d.mts +87 -12
- package/lib/manifest/validation.d.mts.map +1 -1
- package/lib/manifest/validation.d.ts +87 -12
- package/lib/manifest/validation.d.ts.map +1 -1
- package/lib/manifest/validation.js +41 -15
- package/lib/manifest/validation.js.map +1 -1
- package/lib/manifest/validation.mjs +39 -13
- package/lib/manifest/validation.mjs.map +1 -1
- package/lib/sdui/actions.d.mts +25 -0
- package/lib/sdui/actions.d.mts.map +1 -0
- package/lib/sdui/actions.d.ts +25 -0
- package/lib/sdui/actions.d.ts.map +1 -0
- package/lib/sdui/actions.js +53 -0
- package/lib/sdui/actions.js.map +1 -0
- package/lib/sdui/actions.mjs +42 -0
- package/lib/sdui/actions.mjs.map +1 -0
- package/lib/sdui/component.d.mts +41 -0
- package/lib/sdui/component.d.mts.map +1 -0
- package/lib/sdui/component.d.ts +41 -0
- package/lib/sdui/component.d.ts.map +1 -0
- package/lib/sdui/component.js +95 -0
- package/lib/sdui/component.js.map +1 -0
- package/lib/sdui/component.mjs +91 -0
- package/lib/sdui/component.mjs.map +1 -0
- package/lib/sdui/components.d.mts +149 -0
- package/lib/sdui/components.d.mts.map +1 -0
- package/lib/sdui/components.d.ts +149 -0
- package/lib/sdui/components.d.ts.map +1 -0
- package/lib/sdui/components.js +303 -0
- package/lib/sdui/components.js.map +1 -0
- package/lib/sdui/components.mjs +298 -0
- package/lib/sdui/components.mjs.map +1 -0
- package/lib/sdui/conditions.d.mts +25 -0
- package/lib/sdui/conditions.d.mts.map +1 -0
- package/lib/sdui/conditions.d.ts +25 -0
- package/lib/sdui/conditions.d.ts.map +1 -0
- package/lib/sdui/conditions.js +47 -0
- package/lib/sdui/conditions.js.map +1 -0
- package/lib/sdui/conditions.mjs +35 -0
- package/lib/sdui/conditions.mjs.map +1 -0
- package/lib/sdui/directives.d.mts +18 -0
- package/lib/sdui/directives.d.mts.map +1 -0
- package/lib/sdui/directives.d.ts +18 -0
- package/lib/sdui/directives.d.ts.map +1 -0
- package/lib/sdui/directives.js +28 -0
- package/lib/sdui/directives.js.map +1 -0
- package/lib/sdui/directives.mjs +21 -0
- package/lib/sdui/directives.mjs.map +1 -0
- package/lib/sdui/index.d.mts +362 -0
- package/lib/sdui/index.d.mts.map +1 -0
- package/lib/sdui/index.d.ts +362 -0
- package/lib/sdui/index.d.ts.map +1 -0
- package/lib/sdui/index.js +375 -0
- package/lib/sdui/index.js.map +1 -0
- package/lib/sdui/index.mjs +199 -0
- package/lib/sdui/index.mjs.map +1 -0
- package/lib/sdui/props.d.mts +12 -0
- package/lib/sdui/props.d.mts.map +1 -0
- package/lib/sdui/props.d.ts +12 -0
- package/lib/sdui/props.d.ts.map +1 -0
- package/lib/sdui/props.js +25 -0
- package/lib/sdui/props.js.map +1 -0
- package/lib/sdui/props.mjs +21 -0
- package/lib/sdui/props.mjs.map +1 -0
- package/lib/sdui/render.d.mts +23 -0
- package/lib/sdui/render.d.mts.map +1 -0
- package/lib/sdui/render.d.ts +23 -0
- package/lib/sdui/render.d.ts.map +1 -0
- package/lib/sdui/render.js +40 -0
- package/lib/sdui/render.js.map +1 -0
- package/lib/sdui/render.mjs +37 -0
- package/lib/sdui/render.mjs.map +1 -0
- package/lib/sdui/state.d.mts +22 -0
- package/lib/sdui/state.d.mts.map +1 -0
- package/lib/sdui/state.d.ts +22 -0
- package/lib/sdui/state.d.ts.map +1 -0
- package/lib/sdui/state.js +57 -0
- package/lib/sdui/state.js.map +1 -0
- package/lib/sdui/state.mjs +53 -0
- package/lib/sdui/state.mjs.map +1 -0
- package/package.json +11 -1
- package/resources/company-legal-entity-workers.d.mts +79 -0
- package/resources/company-legal-entity-workers.d.mts.map +1 -0
- package/resources/company-legal-entity-workers.d.ts +79 -0
- package/resources/company-legal-entity-workers.d.ts.map +1 -0
- package/resources/company-legal-entity-workers.js +30 -0
- package/resources/company-legal-entity-workers.js.map +1 -0
- package/resources/company-legal-entity-workers.mjs +26 -0
- package/resources/company-legal-entity-workers.mjs.map +1 -0
- package/resources/draft-hires.d.mts +4 -0
- package/resources/draft-hires.d.mts.map +1 -1
- package/resources/draft-hires.d.ts +4 -0
- package/resources/draft-hires.d.ts.map +1 -1
- package/resources/files.d.mts +16 -1
- package/resources/files.d.mts.map +1 -1
- package/resources/files.d.ts +16 -1
- package/resources/files.d.ts.map +1 -1
- package/resources/headcount-positions.d.mts +2 -2
- package/resources/headcount-positions.d.mts.map +1 -1
- package/resources/headcount-positions.d.ts +2 -2
- package/resources/headcount-positions.d.ts.map +1 -1
- package/resources/index.d.mts +1 -0
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +1 -0
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +4 -2
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +1 -0
- package/resources/index.mjs.map +1 -1
- package/resources/legal-entities.d.mts +1 -1
- package/resources/legal-entities.d.mts.map +1 -1
- package/resources/legal-entities.d.ts +1 -1
- package/resources/legal-entities.d.ts.map +1 -1
- package/resources/location-factors.d.mts +2 -2
- package/resources/location-factors.d.mts.map +1 -1
- package/resources/location-factors.d.ts +2 -2
- package/resources/location-factors.d.ts.map +1 -1
- package/resources/shared.d.mts +1 -1
- package/resources/shared.d.mts.map +1 -1
- package/resources/shared.d.ts +1 -1
- package/resources/shared.d.ts.map +1 -1
- package/resources/workers.d.mts +2 -2
- package/resources/workers.d.mts.map +1 -1
- package/resources/workers.d.ts +2 -2
- package/resources/workers.d.ts.map +1 -1
- package/src/client.ts +20 -0
- package/src/lib/manifest/app.ts +81 -26
- package/src/lib/manifest/category.ts +63 -14
- package/src/lib/manifest/custom-object-field-section.ts +56 -17
- package/src/lib/manifest/custom-object-page-layout.ts +201 -66
- package/src/lib/manifest/custom-object.ts +128 -37
- package/src/lib/manifest/field.ts +265 -75
- package/src/lib/manifest/list-view.ts +105 -25
- package/src/lib/manifest/manifest-builder.ts +75 -32
- package/src/lib/manifest/manifest-function.ts +92 -22
- package/src/lib/manifest/rule.ts +95 -29
- package/src/lib/manifest/sdui-page.ts +67 -21
- package/src/lib/manifest/validation.ts +87 -24
- package/src/lib/sdui/actions.ts +58 -0
- package/src/lib/sdui/component.ts +122 -0
- package/src/lib/sdui/components.ts +308 -0
- package/src/lib/sdui/conditions.ts +59 -0
- package/src/lib/sdui/directives.ts +42 -0
- package/src/lib/sdui/index.ts +365 -0
- package/src/lib/sdui/props.ts +32 -0
- package/src/lib/sdui/render.ts +58 -0
- package/src/lib/sdui/state.ts +60 -0
- package/src/resources/company-legal-entity-workers.ts +115 -0
- package/src/resources/draft-hires.ts +5 -0
- package/src/resources/files.ts +18 -1
- package/src/resources/headcount-positions.ts +2 -0
- package/src/resources/index.ts +7 -0
- package/src/resources/legal-entities.ts +1 -0
- package/src/resources/location-factors.ts +2 -0
- package/src/resources/shared.ts +1 -0
- package/src/resources/workers.ts +2 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -1,28 +1,3 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* The contents of this file were inserted manually and are not generated by Stainless.
|
|
3
|
-
*
|
|
4
|
-
* Custom object page layouts (detail page structure).
|
|
5
|
-
* Backend schema: CUSTOM_OBJECT_PAGE_LAYOUT (v2)
|
|
6
|
-
*
|
|
7
|
-
* CDK-style: `new CustomObjectPageLayout(customObject, props)` auto-registers
|
|
8
|
-
* with the CO's scope. `blueprint_key` defaults to the CO's api_name.
|
|
9
|
-
* For the layout that drives **Add** and the default detail view, use
|
|
10
|
-
* `apiName: 'default'` (one per custom object). `CustomObjectPageLayout.basic`
|
|
11
|
-
* uses `default` automatically.
|
|
12
|
-
*
|
|
13
|
-
* TabEditsDTO / HeaderEditsDTO / VisibilityConditionsDTO are strict
|
|
14
|
-
* dataclasses on the backend. They expect camelCase keys on the wire
|
|
15
|
-
* (newTabs, systemTabEdits, fieldRqlName, newTitleField, ...). Snake_case
|
|
16
|
-
* keys are silently dropped and produce an empty layout on deploy. The
|
|
17
|
-
* interfaces below mirror the DTO field aliases exactly.
|
|
18
|
-
*
|
|
19
|
-
* TS catches misspellings on direct object literals but not on spreads,
|
|
20
|
-
* `as` casts, or loosely-typed variables — so be careful when constructing
|
|
21
|
-
* these objects dynamically.
|
|
22
|
-
*
|
|
23
|
-
* DTO references: types/edits.py, types/layout.py, types/sections.py.
|
|
24
|
-
*/
|
|
25
|
-
|
|
26
1
|
import { generateId } from './_helpers';
|
|
27
2
|
import type { CustomObject } from './custom-object';
|
|
28
3
|
import type { Field } from './field';
|
|
@@ -33,34 +8,56 @@ import type { Field } from './field';
|
|
|
33
8
|
|
|
34
9
|
/** Edit to a built-in (system) header field. */
|
|
35
10
|
export interface SystemHeaderFieldEdit {
|
|
11
|
+
/** Replace the system field's RQL field reference. Optional. */
|
|
36
12
|
newRqlField?: string;
|
|
13
|
+
/** Remove this system field from the header. Optional. */
|
|
37
14
|
deleted?: boolean;
|
|
38
15
|
}
|
|
39
16
|
|
|
40
|
-
/**
|
|
17
|
+
/**
|
|
18
|
+
* Custom header field added via `newFields`.
|
|
19
|
+
*
|
|
20
|
+
* `key` is required and must be non-empty — it is used as the stable identity
|
|
21
|
+
* for this field in `headerFieldsOrder` and visibility conditions.
|
|
22
|
+
*/
|
|
41
23
|
export interface NewHeaderField {
|
|
24
|
+
/** RQL field name to display. Required. */
|
|
42
25
|
rqlName: string;
|
|
26
|
+
/** Stable key for this field. Required. */
|
|
43
27
|
key: string;
|
|
28
|
+
/** Whether the user can remove this field. Optional. */
|
|
44
29
|
canBeDeleted?: boolean;
|
|
30
|
+
/** Whether the user can swap this field for another. Optional. */
|
|
45
31
|
canBeChanged?: boolean;
|
|
32
|
+
/** Whether the user can reorder this field. Optional. */
|
|
46
33
|
canBeMoved?: boolean;
|
|
47
34
|
}
|
|
48
35
|
|
|
49
36
|
/**
|
|
50
|
-
*
|
|
51
|
-
*
|
|
52
|
-
*
|
|
37
|
+
* Header configuration for a page layout (`header_edits`).
|
|
38
|
+
*
|
|
39
|
+
* Only the keys listed here are accepted — anything else is silently dropped
|
|
40
|
+
* on the wire. Pass `{}` for an unchanged header.
|
|
41
|
+
*
|
|
42
|
+
* > **Caution:** key names are camelCase on the wire. Snake_case keys are
|
|
43
|
+
* > silently dropped and produce an empty header on deploy.
|
|
53
44
|
*/
|
|
54
45
|
export interface HeaderEdits {
|
|
46
|
+
/** Replace the record title field (pass the field's api_name). Optional. */
|
|
55
47
|
newTitleField?: string | null;
|
|
48
|
+
/** Remove the title field from the header. Optional. */
|
|
56
49
|
titleFieldDeleted?: boolean;
|
|
50
|
+
/** Replace the record description field. Optional. */
|
|
57
51
|
newDescriptionField?: string | null;
|
|
52
|
+
/** Remove the description field from the header. Optional. */
|
|
58
53
|
descriptionFieldDeleted?: boolean;
|
|
59
|
-
/**
|
|
54
|
+
/** Edits to built-in system header fields, keyed by system field key. Optional. */
|
|
60
55
|
systemFieldEdits?: Record<string, SystemHeaderFieldEdit>;
|
|
56
|
+
/** Additional custom fields to add to the header. Optional. */
|
|
61
57
|
newFields?: NewHeaderField[];
|
|
62
|
-
/**
|
|
58
|
+
/** Ordered list of header field `key` values (custom + system). Optional. */
|
|
63
59
|
headerFieldsOrder?: string[];
|
|
60
|
+
/** Action button keys to show in the header. Optional. */
|
|
64
61
|
buttons?: string[];
|
|
65
62
|
}
|
|
66
63
|
|
|
@@ -68,81 +65,109 @@ export interface HeaderEdits {
|
|
|
68
65
|
// tab_edits — TabEditsDTO + section/tab DTOs
|
|
69
66
|
// ---------------------------------------------------------------------------
|
|
70
67
|
|
|
71
|
-
/**
|
|
68
|
+
/** One field entry inside a `fields_section`. */
|
|
72
69
|
export interface SectionField {
|
|
70
|
+
/** RQL name of the field to display. Required. */
|
|
73
71
|
fieldRqlName: string;
|
|
72
|
+
/** Hide this field from view. Optional. */
|
|
74
73
|
hidden?: boolean;
|
|
74
|
+
/** Allow inline editing of this field. Optional. */
|
|
75
75
|
editable?: boolean;
|
|
76
|
+
/** Controls how the field can be moved in the UI. Optional. */
|
|
76
77
|
movementOption?: 'tab' | 'free';
|
|
77
78
|
}
|
|
78
79
|
|
|
79
|
-
/**
|
|
80
|
+
/** A standard field-grid section inside a tab. */
|
|
80
81
|
export interface FieldsSection {
|
|
81
82
|
type: 'fields_section';
|
|
83
|
+
/** Stable key for this section. Required. */
|
|
82
84
|
key: string;
|
|
85
|
+
/** Display name of the section. Required. */
|
|
83
86
|
name: string;
|
|
87
|
+
/** Fields to display in this section. Required. */
|
|
84
88
|
fields: SectionField[];
|
|
85
89
|
}
|
|
86
90
|
|
|
87
|
-
/**
|
|
88
|
-
*
|
|
91
|
+
/**
|
|
92
|
+
* A section inside a page layout tab.
|
|
93
|
+
*
|
|
94
|
+
* Only `fields_section` is modeled today. Add other section types
|
|
95
|
+
* (`related_object_section`, `custom_section`, …) explicitly as needed.
|
|
96
|
+
*/
|
|
89
97
|
export type PageLayoutSection = FieldsSection;
|
|
90
98
|
|
|
91
|
-
/**
|
|
99
|
+
/** A tab that contains one or more field-grid sections. */
|
|
92
100
|
export interface TabWithSections {
|
|
93
101
|
type: 'tab_with_sections';
|
|
102
|
+
/** Stable key for this tab. Required. */
|
|
94
103
|
key: string;
|
|
104
|
+
/** Display name of the tab. Required. */
|
|
95
105
|
name: string;
|
|
106
|
+
/** Sections inside this tab. Required. */
|
|
96
107
|
sections: PageLayoutSection[];
|
|
97
108
|
}
|
|
98
109
|
|
|
99
|
-
/**
|
|
110
|
+
/** A tab that hosts a custom UI component. */
|
|
100
111
|
export interface CustomTab {
|
|
101
112
|
type: 'custom_tab';
|
|
113
|
+
/** Stable key for this tab. Required. */
|
|
102
114
|
key: string;
|
|
115
|
+
/** Display name of the tab. Required. */
|
|
103
116
|
name: string;
|
|
117
|
+
/** Key of the custom component to render. Required. */
|
|
104
118
|
componentKey: string;
|
|
105
119
|
}
|
|
106
120
|
|
|
121
|
+
/** A tab entry in a page layout — either a sections-based tab or a custom component tab. */
|
|
107
122
|
export type PageLayoutTab = TabWithSections | CustomTab;
|
|
108
123
|
|
|
109
|
-
/**
|
|
124
|
+
/** Column layout for a `fields_section`. */
|
|
110
125
|
export type SectionFieldsLayout = 'one_column' | 'two_column' | 'three_column' | 'responsive';
|
|
111
126
|
|
|
112
|
-
/**
|
|
127
|
+
/** Edits to a built-in section inside a system tab. */
|
|
113
128
|
export interface SystemSectionEdit {
|
|
129
|
+
/** Rename this section. Optional. */
|
|
114
130
|
newName?: string;
|
|
131
|
+
/** Remove this section. Optional. */
|
|
115
132
|
deleted?: boolean;
|
|
133
|
+
/** Change the column layout. Optional. */
|
|
116
134
|
newLayout?: SectionFieldsLayout;
|
|
135
|
+
/** Add fields to this section. Optional. */
|
|
117
136
|
newFields?: SectionField[];
|
|
137
|
+
/** Hide the section name header. Optional. */
|
|
118
138
|
newHideName?: boolean;
|
|
119
139
|
}
|
|
120
140
|
|
|
121
|
-
/**
|
|
141
|
+
/** Edits to a built-in (system) tab. */
|
|
122
142
|
export interface SystemTabEdit {
|
|
143
|
+
/** Rename this tab. Optional. */
|
|
123
144
|
newName?: string;
|
|
145
|
+
/** Remove this tab. Optional. */
|
|
124
146
|
deleted?: boolean;
|
|
147
|
+
/** Add new sections to this tab. Optional. */
|
|
125
148
|
newSections?: PageLayoutSection[];
|
|
149
|
+
/** Edits to built-in sections inside this tab, keyed by section key. Optional. */
|
|
126
150
|
systemSectionEdits?: Record<string, SystemSectionEdit>;
|
|
151
|
+
/** Reorder sections by key. Optional. */
|
|
127
152
|
sectionsOrder?: string[];
|
|
128
153
|
}
|
|
129
154
|
|
|
130
155
|
/**
|
|
131
|
-
*
|
|
156
|
+
* Tab structure configuration for a page layout (`tab_edits`).
|
|
132
157
|
*
|
|
133
|
-
* All fields are optional
|
|
134
|
-
* list / empty dict). An omitted `tabEdits` defaults to `{}` in the
|
|
135
|
-
* constructor; partial objects rely on backend per-field defaults.
|
|
158
|
+
* All fields are optional. An omitted `tabEdits` defaults to `{}`.
|
|
136
159
|
*
|
|
137
|
-
*
|
|
138
|
-
*
|
|
139
|
-
* - tabsOrder: ordered list of tab `key` values (new + system)
|
|
140
|
-
* - newTabLayout: optional orientation
|
|
160
|
+
* > **Caution:** key names are camelCase on the wire. Snake_case keys are
|
|
161
|
+
* > silently dropped and produce an empty layout on deploy.
|
|
141
162
|
*/
|
|
142
163
|
export interface TabEdits {
|
|
164
|
+
/** New tabs to add to this layout. Each must include a `type` discriminator. Optional. */
|
|
143
165
|
newTabs?: PageLayoutTab[];
|
|
166
|
+
/** Edits to existing system tabs, keyed by tab key. Optional. */
|
|
144
167
|
systemTabEdits?: Record<string, SystemTabEdit>;
|
|
168
|
+
/** Ordered list of tab `key` values (new + system). Optional. */
|
|
145
169
|
tabsOrder?: string[];
|
|
170
|
+
/** Tab strip orientation. Optional. */
|
|
146
171
|
newTabLayout?: 'vertical' | 'horizontal';
|
|
147
172
|
}
|
|
148
173
|
|
|
@@ -151,17 +176,27 @@ export interface TabEdits {
|
|
|
151
176
|
// ---------------------------------------------------------------------------
|
|
152
177
|
|
|
153
178
|
/**
|
|
154
|
-
*
|
|
155
|
-
*
|
|
179
|
+
* A single visibility condition applied to a section or tab.
|
|
180
|
+
*
|
|
181
|
+
* Both fields are required by the backend — pass an empty string / empty object
|
|
182
|
+
* if you have no formula or condition tree.
|
|
156
183
|
*/
|
|
157
184
|
export interface VisibilityCondition {
|
|
185
|
+
/** RQL formula that controls visibility. Required. */
|
|
158
186
|
rqlFormula: string;
|
|
187
|
+
/** Layered conditions tree (AST). Required. */
|
|
159
188
|
layeredConditionsTree: Record<string, any>;
|
|
160
189
|
}
|
|
161
190
|
|
|
162
|
-
/**
|
|
191
|
+
/**
|
|
192
|
+
* Visibility conditions for sections and tabs on a page layout.
|
|
193
|
+
*
|
|
194
|
+
* Pass `{}` for no conditions.
|
|
195
|
+
*/
|
|
163
196
|
export interface VisibilityConditions {
|
|
197
|
+
/** Per-section visibility conditions, keyed by section key. Optional. */
|
|
164
198
|
sections?: Record<string, VisibilityCondition>;
|
|
199
|
+
/** Per-tab visibility conditions, keyed by tab key. Optional. */
|
|
165
200
|
tabs?: Record<string, VisibilityCondition>;
|
|
166
201
|
}
|
|
167
202
|
|
|
@@ -169,24 +204,54 @@ export interface VisibilityConditions {
|
|
|
169
204
|
// Public props
|
|
170
205
|
// ---------------------------------------------------------------------------
|
|
171
206
|
|
|
207
|
+
/**
|
|
208
|
+
* Initialization properties for {@link CustomObjectPageLayout}.
|
|
209
|
+
*/
|
|
172
210
|
export interface CustomObjectPageLayoutProps {
|
|
173
211
|
/**
|
|
174
|
-
*
|
|
175
|
-
*
|
|
176
|
-
*
|
|
212
|
+
* Stable identifier for this layout (e.g. `'default'`).
|
|
213
|
+
*
|
|
214
|
+
* Required. Use `'default'` for the layout that drives the **Add** form and
|
|
215
|
+
* the default record detail view. Each custom object supports one `'default'`
|
|
216
|
+
* layout.
|
|
177
217
|
*/
|
|
178
218
|
apiName: string;
|
|
179
|
-
/**
|
|
219
|
+
/**
|
|
220
|
+
* Display name of this layout shown in the layout selector.
|
|
221
|
+
*
|
|
222
|
+
* Required.
|
|
223
|
+
*/
|
|
180
224
|
name: string;
|
|
181
|
-
/**
|
|
225
|
+
/**
|
|
226
|
+
* Tab structure — which tabs and sections to show on the detail page.
|
|
227
|
+
*
|
|
228
|
+
* Optional. @default `{}`
|
|
229
|
+
*/
|
|
182
230
|
tabEdits?: TabEdits;
|
|
183
|
-
/**
|
|
231
|
+
/**
|
|
232
|
+
* Header configuration — title field, description field, and action buttons.
|
|
233
|
+
*
|
|
234
|
+
* Optional. @default `{}`
|
|
235
|
+
*/
|
|
184
236
|
headerEdits?: HeaderEdits;
|
|
185
|
-
/**
|
|
237
|
+
/**
|
|
238
|
+
* Visibility conditions for individual tabs and sections.
|
|
239
|
+
*
|
|
240
|
+
* Optional. @default `{}`
|
|
241
|
+
*/
|
|
186
242
|
visibilityConditions?: VisibilityConditions;
|
|
187
|
-
/**
|
|
243
|
+
/**
|
|
244
|
+
* Stable identifier for this layout record. Pass a human-readable slug
|
|
245
|
+
* to keep it stable across regenerations.
|
|
246
|
+
*
|
|
247
|
+
* Optional. Auto-generated when omitted. @default generateId('layout')
|
|
248
|
+
*/
|
|
188
249
|
layoutId?: string;
|
|
189
|
-
/**
|
|
250
|
+
/**
|
|
251
|
+
* Blueprint key used during install. Defaults to the parent object's api_name.
|
|
252
|
+
*
|
|
253
|
+
* Optional.
|
|
254
|
+
*/
|
|
190
255
|
blueprintKey?: string;
|
|
191
256
|
}
|
|
192
257
|
|
|
@@ -194,6 +259,46 @@ export interface CustomObjectPageLayoutProps {
|
|
|
194
259
|
// Class
|
|
195
260
|
// ---------------------------------------------------------------------------
|
|
196
261
|
|
|
262
|
+
/**
|
|
263
|
+
* Defines a page layout and registers it with the manifest.
|
|
264
|
+
*
|
|
265
|
+
* A page layout controls the tab structure, section groupings, header fields,
|
|
266
|
+
* and visibility conditions on a custom object's record detail page. You would
|
|
267
|
+
* normally define one layout per custom object using `apiName: 'default'`.
|
|
268
|
+
*
|
|
269
|
+
* For simple single-tab layouts, use the {@link CustomObjectPageLayout.basic}
|
|
270
|
+
* factory instead of constructing the full props manually.
|
|
271
|
+
*
|
|
272
|
+
* > **Caution:** all keys inside `tabEdits` and `headerEdits` must be camelCase.
|
|
273
|
+
* > Snake_case keys are silently dropped on the wire and produce an empty layout.
|
|
274
|
+
*
|
|
275
|
+
* @example
|
|
276
|
+
* ```ts
|
|
277
|
+
* new CustomObjectPageLayout(memberObj, {
|
|
278
|
+
* apiName: 'default',
|
|
279
|
+
* name: 'Member',
|
|
280
|
+
* layoutId: 'layout_gym_member',
|
|
281
|
+
* headerEdits: { newTitleField: memberDisplayName.getApiName() },
|
|
282
|
+
* tabEdits: {
|
|
283
|
+
* newTabs: [{
|
|
284
|
+
* key: 'member', name: 'Member', type: 'tab_with_sections',
|
|
285
|
+
* sections: [{
|
|
286
|
+
* key: 'profile', name: 'Profile', type: 'fields_section',
|
|
287
|
+
* fields: [
|
|
288
|
+
* { fieldRqlName: memberFirstName.getApiName() },
|
|
289
|
+
* { fieldRqlName: memberEmail.getApiName() },
|
|
290
|
+
* ],
|
|
291
|
+
* }],
|
|
292
|
+
* }],
|
|
293
|
+
* systemTabEdits: {},
|
|
294
|
+
* tabsOrder: ['member'],
|
|
295
|
+
* },
|
|
296
|
+
* visibilityConditions: {},
|
|
297
|
+
* });
|
|
298
|
+
* ```
|
|
299
|
+
*
|
|
300
|
+
* @see {@link CustomObjectPageLayout.basic} — factory for simple single-tab layouts.
|
|
301
|
+
*/
|
|
197
302
|
export class CustomObjectPageLayout {
|
|
198
303
|
private readonly _layoutId: string;
|
|
199
304
|
private readonly _apiName: string;
|
|
@@ -204,7 +309,11 @@ export class CustomObjectPageLayout {
|
|
|
204
309
|
private readonly _visibilityConditions: VisibilityConditions;
|
|
205
310
|
private readonly _blueprintKey: string | undefined;
|
|
206
311
|
|
|
207
|
-
/**
|
|
312
|
+
/**
|
|
313
|
+
* @param customObject - The custom object this layout belongs to.
|
|
314
|
+
* @param props - Initialization properties.
|
|
315
|
+
* @throws {Error} If `apiName` or `name` is empty.
|
|
316
|
+
*/
|
|
208
317
|
constructor(customObject: CustomObject, props: CustomObjectPageLayoutProps) {
|
|
209
318
|
if (!props.apiName) throw new Error('CustomObjectPageLayout: apiName cannot be empty');
|
|
210
319
|
if (!props.name) throw new Error('CustomObjectPageLayout: name cannot be empty');
|
|
@@ -219,22 +328,32 @@ export class CustomObjectPageLayout {
|
|
|
219
328
|
customObject._register(this);
|
|
220
329
|
}
|
|
221
330
|
|
|
222
|
-
/**
|
|
331
|
+
/**
|
|
332
|
+
* Returns the stable identifier for this layout record (e.g. `'layout_gym_member'`).
|
|
333
|
+
*/
|
|
223
334
|
getLayoutId(): string {
|
|
224
335
|
return this._layoutId;
|
|
225
336
|
}
|
|
226
337
|
|
|
227
|
-
/**
|
|
338
|
+
/**
|
|
339
|
+
* Returns the api_name of this layout (e.g. `'default'`).
|
|
340
|
+
*/
|
|
228
341
|
getApiName(): string {
|
|
229
342
|
return this._apiName;
|
|
230
343
|
}
|
|
231
344
|
|
|
232
|
-
/**
|
|
345
|
+
/**
|
|
346
|
+
* Returns the api_name of the custom object this layout belongs to.
|
|
347
|
+
*/
|
|
233
348
|
getCustomObjectApiName(): string {
|
|
234
349
|
return this._customObjectApiName;
|
|
235
350
|
}
|
|
236
351
|
|
|
237
|
-
/**
|
|
352
|
+
/**
|
|
353
|
+
* Serializes this layout to the wire format consumed by the manifest install endpoint.
|
|
354
|
+
*
|
|
355
|
+
* @returns A plain object with `type: 'CUSTOM_OBJECT_PAGE_LAYOUT'`.
|
|
356
|
+
*/
|
|
238
357
|
toDict(): Record<string, any> {
|
|
239
358
|
const d: Record<string, any> = {
|
|
240
359
|
type: 'CUSTOM_OBJECT_PAGE_LAYOUT',
|
|
@@ -252,7 +371,23 @@ export class CustomObjectPageLayout {
|
|
|
252
371
|
return d;
|
|
253
372
|
}
|
|
254
373
|
|
|
255
|
-
/**
|
|
374
|
+
/**
|
|
375
|
+
* Creates a simple single-tab "Details" layout with a single "General" section.
|
|
376
|
+
*
|
|
377
|
+
* Use this factory when you want a straightforward layout without customizing
|
|
378
|
+
* tabs or sections. Always uses `apiName: 'default'`.
|
|
379
|
+
*
|
|
380
|
+
* @param customObject - The custom object to create the layout for.
|
|
381
|
+
* @param props - Optional. Pass `fields` to populate the General section.
|
|
382
|
+
* @returns A new `CustomObjectPageLayout` registered with the manifest.
|
|
383
|
+
*
|
|
384
|
+
* @example
|
|
385
|
+
* ```ts
|
|
386
|
+
* CustomObjectPageLayout.basic(memberObj, {
|
|
387
|
+
* fields: [memberFirstName, memberEmail, memberStatusField],
|
|
388
|
+
* });
|
|
389
|
+
* ```
|
|
390
|
+
*/
|
|
256
391
|
static basic(
|
|
257
392
|
customObject: CustomObject,
|
|
258
393
|
props: {
|
|
@@ -1,25 +1,3 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* The contents of this file were inserted manually and are not generated by Stainless.
|
|
3
|
-
*
|
|
4
|
-
* CustomObject builder. Backend schema: CUSTOM_OBJECT (v2).
|
|
5
|
-
*
|
|
6
|
-
* Construction is CDK-style: `new CustomObject(scope, props)` where `scope`
|
|
7
|
-
* is the `ManifestBuilder` (or any `ManifestScope`). The CO also acts as a
|
|
8
|
-
* scope for its own children (fields, validations, rules, list views, page
|
|
9
|
-
* layouts, sections, actions) — those take the CO as their first arg and
|
|
10
|
-
* auto-register with the manifest through it.
|
|
11
|
-
*
|
|
12
|
-
* Every CO auto-registers 9 platform-managed standard field stubs at
|
|
13
|
-
* construction, matching `STANDARD_FIELDS` in the backend's `constants.py`:
|
|
14
|
-
* id, created_at, updated_at, system_updated_at, external_id, name,
|
|
15
|
-
* owner_role, last_modified_by, created_by
|
|
16
|
-
* The backend's closed-world `extract_from_configs` path (used by
|
|
17
|
-
* `POST /metadata/v2/validate`) treats these as hard dependencies of the CO —
|
|
18
|
-
* for any brand-new CO their configs must already be present in the submitted
|
|
19
|
-
* manifest, else validation raises `DEPENDENCY_ERROR`. Users never declare
|
|
20
|
-
* them explicitly; the SDK emits them with `is_standard: true`.
|
|
21
|
-
*/
|
|
22
|
-
|
|
23
1
|
import { Category } from './category';
|
|
24
2
|
import type { ManifestComponent, ManifestScope } from './manifest-builder';
|
|
25
3
|
|
|
@@ -161,36 +139,134 @@ class _StandardField implements ManifestComponent {
|
|
|
161
139
|
}
|
|
162
140
|
}
|
|
163
141
|
|
|
142
|
+
/**
|
|
143
|
+
* Icon displayed next to the custom object name in the Rippling UI.
|
|
144
|
+
*/
|
|
164
145
|
export interface IconConfig {
|
|
146
|
+
/**
|
|
147
|
+
* A Unicode emoji character, e.g. `'🏋️'`.
|
|
148
|
+
*
|
|
149
|
+
* Optional. Omit all four sources (or pass `null`) to show no icon.
|
|
150
|
+
*/
|
|
165
151
|
emoji?: string | null;
|
|
152
|
+
/**
|
|
153
|
+
* Name of a built-in Rippling icon asset.
|
|
154
|
+
*
|
|
155
|
+
* Optional.
|
|
156
|
+
*/
|
|
166
157
|
ripplingIcon?: string | null;
|
|
158
|
+
/**
|
|
159
|
+
* S3 bucket for a custom image asset.
|
|
160
|
+
*
|
|
161
|
+
* Optional. Must be set together with `s3Key`.
|
|
162
|
+
*/
|
|
167
163
|
s3Bucket?: string;
|
|
164
|
+
/**
|
|
165
|
+
* S3 key (path) within `s3Bucket`.
|
|
166
|
+
*
|
|
167
|
+
* Optional. Must be set together with `s3Bucket`.
|
|
168
|
+
*/
|
|
168
169
|
s3Key?: string;
|
|
169
170
|
}
|
|
170
171
|
|
|
172
|
+
/**
|
|
173
|
+
* Initialization properties for {@link CustomObject}.
|
|
174
|
+
*/
|
|
171
175
|
export interface CustomObjectProps {
|
|
172
|
-
/**
|
|
176
|
+
/**
|
|
177
|
+
* Unique identifier for this custom object.
|
|
178
|
+
*
|
|
179
|
+
* Required. Must end with `__c` (e.g. `'gym_member__c'`). The constructor throws
|
|
180
|
+
* immediately if this suffix is missing.
|
|
181
|
+
*/
|
|
173
182
|
apiName: string;
|
|
174
|
-
/**
|
|
183
|
+
/**
|
|
184
|
+
* Singular display name shown in the Rippling UI (e.g. `'Member'`).
|
|
185
|
+
*
|
|
186
|
+
* Required.
|
|
187
|
+
*/
|
|
175
188
|
name: string;
|
|
176
189
|
/**
|
|
177
|
-
*
|
|
178
|
-
*
|
|
179
|
-
*
|
|
190
|
+
* The category this object belongs to.
|
|
191
|
+
*
|
|
192
|
+
* Required. Pass a {@link Category} instance defined in the same manifest, or a raw
|
|
193
|
+
* api_name string for categories defined outside this manifest.
|
|
180
194
|
*/
|
|
181
195
|
category: Category | string;
|
|
182
|
-
/**
|
|
196
|
+
/**
|
|
197
|
+
* Human-readable description of what this entity represents.
|
|
198
|
+
*
|
|
199
|
+
* Optional. @default null
|
|
200
|
+
*/
|
|
183
201
|
description?: string | null;
|
|
184
|
-
/**
|
|
202
|
+
/**
|
|
203
|
+
* Icon shown next to the object name in the Rippling UI.
|
|
204
|
+
*
|
|
205
|
+
* Optional. @default null
|
|
206
|
+
*/
|
|
185
207
|
icon?: IconConfig | null;
|
|
186
|
-
/**
|
|
208
|
+
/**
|
|
209
|
+
* Plural form of the display name, used in list headings (e.g. `'Members'`).
|
|
210
|
+
*
|
|
211
|
+
* Optional. @default null
|
|
212
|
+
*/
|
|
187
213
|
pluralLabel?: string | null;
|
|
188
|
-
/**
|
|
214
|
+
/**
|
|
215
|
+
* Overrides for the auto-number name field — controls the format string and starting number.
|
|
216
|
+
* Leave `null` to use the default name field behavior.
|
|
217
|
+
*
|
|
218
|
+
* Optional. @default null
|
|
219
|
+
*/
|
|
189
220
|
nameFieldDetails?: Record<string, any> | null;
|
|
190
|
-
/**
|
|
221
|
+
/**
|
|
222
|
+
* API name of the field section that newly created fields are grouped into by default.
|
|
223
|
+
*
|
|
224
|
+
* Optional. @default null
|
|
225
|
+
*/
|
|
191
226
|
defaultFieldSectionName?: string | null;
|
|
192
227
|
}
|
|
193
228
|
|
|
229
|
+
/**
|
|
230
|
+
* Defines a custom object and registers it with the manifest.
|
|
231
|
+
*
|
|
232
|
+
* A custom object is a new entity type with its own fields, validations, rules, list views,
|
|
233
|
+
* and page layouts. You would normally define all custom objects near the top of your manifest
|
|
234
|
+
* file, then define their children (fields, sections, rules, etc.) below. Each child takes
|
|
235
|
+
* the `CustomObject` instance as its first argument and registers automatically.
|
|
236
|
+
*
|
|
237
|
+
* @example
|
|
238
|
+
* ```ts
|
|
239
|
+
* const manifest = new ManifestBuilder({
|
|
240
|
+
* key: 'gym_membership_management',
|
|
241
|
+
* name: 'Gym Membership Management',
|
|
242
|
+
* });
|
|
243
|
+
*
|
|
244
|
+
* const gymCategory = new Category(manifest, { apiName: 'gym__c', name: 'Gym' });
|
|
245
|
+
*
|
|
246
|
+
* const memberObj = new CustomObject(manifest, {
|
|
247
|
+
* apiName: 'gym_member__c',
|
|
248
|
+
* name: 'Member',
|
|
249
|
+
* pluralLabel: 'Members',
|
|
250
|
+
* category: gymCategory,
|
|
251
|
+
* description: 'Gym member profile, contact, and membership status',
|
|
252
|
+
* icon: { emoji: '🏋️' },
|
|
253
|
+
* });
|
|
254
|
+
*
|
|
255
|
+
* // The object is now a scope — children register through it:
|
|
256
|
+
* const firstName = new TextField(memberObj, {
|
|
257
|
+
* apiName: 'first_name__c',
|
|
258
|
+
* displayName: 'First name',
|
|
259
|
+
* required: true,
|
|
260
|
+
* });
|
|
261
|
+
* ```
|
|
262
|
+
*
|
|
263
|
+
* @remarks
|
|
264
|
+
* **Required: every `CustomObject` must have at least one `CustomObjectPageLayout` in the
|
|
265
|
+
* manifest.** Omitting it passes component-level validation but fails at the package level
|
|
266
|
+
* with `DEPENDENCY_ERROR: Page layout config for CO (api_name=...) not found in package
|
|
267
|
+
* configs. CO requires at least one page layout in the package.`
|
|
268
|
+
* Use {@link CustomObjectPageLayout.basic} for a minimal single-tab layout.
|
|
269
|
+
*/
|
|
194
270
|
export class CustomObject implements ManifestScope {
|
|
195
271
|
private readonly _scope: ManifestScope;
|
|
196
272
|
private readonly _apiName: string;
|
|
@@ -202,7 +278,11 @@ export class CustomObject implements ManifestScope {
|
|
|
202
278
|
private _nameFieldDetails: Record<string, any> | null | undefined;
|
|
203
279
|
private _defaultFieldSectionName: string | null | undefined;
|
|
204
280
|
|
|
205
|
-
/**
|
|
281
|
+
/**
|
|
282
|
+
* @param scope - The manifest or parent scope to register this object with.
|
|
283
|
+
* @param props - Initialization properties.
|
|
284
|
+
* @throws {Error} If `props.apiName` does not end with `__c`.
|
|
285
|
+
*/
|
|
206
286
|
constructor(scope: ManifestScope, props: CustomObjectProps) {
|
|
207
287
|
if (!props.apiName.endsWith('__c')) {
|
|
208
288
|
throw new Error(`Custom object api_name must end with __c: ${props.apiName}`);
|
|
@@ -224,22 +304,33 @@ export class CustomObject implements ManifestScope {
|
|
|
224
304
|
}
|
|
225
305
|
}
|
|
226
306
|
|
|
227
|
-
/** @internal Scope hook
|
|
307
|
+
/** @internal Scope hook — forwards child registration up to the root builder. */
|
|
228
308
|
_register(component: ManifestComponent): void {
|
|
229
309
|
this._scope._register(component);
|
|
230
310
|
}
|
|
231
311
|
|
|
232
|
-
/**
|
|
312
|
+
/**
|
|
313
|
+
* Returns the api_name of this custom object (e.g. `'gym_member__c'`).
|
|
314
|
+
*
|
|
315
|
+
* Use the return value wherever a field or layout needs to reference this object by name.
|
|
316
|
+
*/
|
|
233
317
|
getApiName(): string {
|
|
234
318
|
return this._apiName;
|
|
235
319
|
}
|
|
236
320
|
|
|
237
|
-
/**
|
|
321
|
+
/**
|
|
322
|
+
* Returns the singular display name of this custom object (e.g. `'Member'`).
|
|
323
|
+
*/
|
|
238
324
|
getName(): string {
|
|
239
325
|
return this._name;
|
|
240
326
|
}
|
|
241
327
|
|
|
242
|
-
/**
|
|
328
|
+
/**
|
|
329
|
+
* Serializes this custom object to the wire format consumed by the manifest install endpoint.
|
|
330
|
+
*
|
|
331
|
+
* @returns A plain object with `type: 'CUSTOM_OBJECT'` and all configured fields.
|
|
332
|
+
* Optional fields are omitted when `null`. An `icon` with no populated keys is omitted entirely.
|
|
333
|
+
*/
|
|
243
334
|
toDict(): Record<string, any> {
|
|
244
335
|
const component: Record<string, any> = {
|
|
245
336
|
type: 'CUSTOM_OBJECT',
|