@luigi-project/client 2.19.3-dev.202502110031 → 2.19.3-dev.202502111818
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/luigi-element.d.ts +78 -0
- package/package.json +1 -1
package/luigi-element.d.ts
CHANGED
|
@@ -61,7 +61,59 @@ export declare interface NodeParams {
|
|
|
61
61
|
[key: string]: string;
|
|
62
62
|
}
|
|
63
63
|
|
|
64
|
+
export declare interface UserSettings {
|
|
65
|
+
[key: string]: number | string | boolean;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* Returns the anchor of active URL.
|
|
70
|
+
* @returns {String} the anchor string
|
|
71
|
+
* @memberof Lifecycle
|
|
72
|
+
* @example
|
|
73
|
+
* LuigiClient.getAnchor();
|
|
74
|
+
*/
|
|
75
|
+
export function getAnchor(): String;
|
|
76
|
+
export type getAnchor = () => String;
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* Returns the current user settings.
|
|
80
|
+
* @returns {Object} current user settings
|
|
81
|
+
* @memberof Lifecycle
|
|
82
|
+
*/
|
|
83
|
+
export function getUserSettings(): UserSettings;
|
|
84
|
+
export type getUserSettings = () => UserSettings;
|
|
85
|
+
|
|
86
|
+
/**
|
|
87
|
+
* Allows you to change node labels within the same view group, e.g. in your node config: `label: 'my Node {viewGroupData.vg1}'`.
|
|
88
|
+
* @param {Object} value a data object containing the view group name and desired label
|
|
89
|
+
* @memberof Lifecycle
|
|
90
|
+
* @example
|
|
91
|
+
* LuigiClient.setViewGroupData({'vg1':' Luigi rocks!'})
|
|
92
|
+
*/
|
|
93
|
+
export function setViewGroupData(value: Object): void;
|
|
94
|
+
export type setViewGroupData = (value: Object) => void;
|
|
95
|
+
|
|
64
96
|
export declare interface UxManager {
|
|
97
|
+
/**
|
|
98
|
+
* Gets the current theme.
|
|
99
|
+
* @returns {*} current themeObj
|
|
100
|
+
* @memberof uxManager
|
|
101
|
+
*/
|
|
102
|
+
getCurrentTheme: () => any;
|
|
103
|
+
|
|
104
|
+
/**
|
|
105
|
+
* Gets the dirty status, which is set by the Client.
|
|
106
|
+
* @returns {boolean} dirty status
|
|
107
|
+
* @memberof uxManager
|
|
108
|
+
*/
|
|
109
|
+
getDirtyStatus: () => boolean;
|
|
110
|
+
|
|
111
|
+
/**
|
|
112
|
+
* Removes the backdrop.
|
|
113
|
+
* @memberof uxManager
|
|
114
|
+
*/
|
|
115
|
+
removeBackdrop: () => void;
|
|
116
|
+
|
|
65
117
|
/**
|
|
66
118
|
* Hides the app loading indicator.
|
|
67
119
|
* @memberof uxManager
|
|
@@ -212,6 +264,23 @@ export declare interface LinkManager {
|
|
|
212
264
|
drawerSettings?: DrawerSettings
|
|
213
265
|
) => void;
|
|
214
266
|
|
|
267
|
+
/**
|
|
268
|
+
* Offers an alternative way of navigating with intents. This involves specifying a semanticSlug and an object containing
|
|
269
|
+
* parameters.
|
|
270
|
+
* This method internally generates a URL of the form `#?intent=<semantic object>-<action>?<param_name>=<param_value>` through the given
|
|
271
|
+
* input arguments. This then follows a call to the original `linkManager.navigate(...)` function.
|
|
272
|
+
* Consequently, the following calls shall have the exact same effect:
|
|
273
|
+
* - linkManager().navigateToIntent('Sales-settings', {project: 'pr2', user: 'john'})
|
|
274
|
+
* - linkManager().navigate('/#?intent=Sales-settings?project=pr2&user=john')
|
|
275
|
+
* @memberof LuigiNavigation
|
|
276
|
+
* @param {string} semanticSlug concatenation of semantic object and action connected with a dash (-), i.e.: `<semanticObject>-<action>`
|
|
277
|
+
* @param {Object} params an object representing all the parameters passed, i.e.: `{param1: '1', param2: 2, param3: 'value3'}`.
|
|
278
|
+
* @example
|
|
279
|
+
* LuigiClient.linkManager().navigateToIntent('Sales-settings', {project: 'pr2', user: 'john'})
|
|
280
|
+
* LuigiClient.linkManager().navigateToIntent('Sales-settings')
|
|
281
|
+
*/
|
|
282
|
+
navigateToIntent: (semanticSlug: string, params?: Object) => void;
|
|
283
|
+
|
|
215
284
|
/**
|
|
216
285
|
* Opens a view in a modal. You can specify the modal's title and size. If you do not specify the title, it is the node label. If there is no node label, the title remains empty. The default size of the modal is `l`, which means 80%. You can also use `m` (60%) and `s` (40%) to set the modal size. Optionally, use it in combination with any of the navigation functions.
|
|
217
286
|
* @memberof linkManager
|
|
@@ -271,6 +340,15 @@ export declare interface LinkManager {
|
|
|
271
340
|
*/
|
|
272
341
|
fromContext: (navigationContext: string) => this;
|
|
273
342
|
|
|
343
|
+
/**
|
|
344
|
+
* Enables navigating to sibling nodes without knowing the absolute path
|
|
345
|
+
* @memberof linkManager
|
|
346
|
+
* @returns {linkManager} link manager instance
|
|
347
|
+
* @example
|
|
348
|
+
* LuigiClient.linkManager().fromParent().navigate('/sibling')
|
|
349
|
+
*/
|
|
350
|
+
fromParent: () => this;
|
|
351
|
+
|
|
274
352
|
/**
|
|
275
353
|
* Sets the current navigation context which is then used by the `navigate` function. This has to be a parent navigation context, it is not possible to use the child navigation contexts.
|
|
276
354
|
* @memberof linkManager
|
package/package.json
CHANGED