@genesislcap/foundation-utils 14.22.1 → 14.23.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.
- package/dist/custom-elements.json +286 -169
- package/dist/dts/data/inMemoryDatabase.d.ts +17 -0
- package/dist/dts/data/inMemoryDatabase.d.ts.map +1 -1
- package/dist/dts/directives/sync/sync.d.ts +16 -0
- package/dist/dts/directives/sync/sync.d.ts.map +1 -1
- package/dist/dts/directives/when-else/when-else.d.ts +1 -1
- package/dist/dts/env/is-dev.d.ts +4 -0
- package/dist/dts/env/is-dev.d.ts.map +1 -1
- package/dist/dts/env/variables.d.ts +37 -0
- package/dist/dts/env/variables.d.ts.map +1 -1
- package/dist/dts/formatters/datetime.d.ts +2 -2
- package/dist/dts/logger/logger.d.ts +29 -3
- package/dist/dts/logger/logger.d.ts.map +1 -1
- package/dist/dts/mappers/dto/serverRow.d.ts +46 -14
- package/dist/dts/mappers/dto/serverRow.d.ts.map +1 -1
- package/dist/dts/mappers/dto/types.d.ts +3 -0
- package/dist/dts/mappers/dto/types.d.ts.map +1 -1
- package/dist/dts/mixins/lifecycle/lifecycle.d.ts +11 -5
- package/dist/dts/mixins/lifecycle/lifecycle.d.ts.map +1 -1
- package/dist/dts/mixins/pendingState/pendingState.d.ts +55 -9
- package/dist/dts/mixins/pendingState/pendingState.d.ts.map +1 -1
- package/dist/dts/observer/observer.d.ts +19 -4
- package/dist/dts/observer/observer.d.ts.map +1 -1
- package/dist/dts/resource/types.d.ts +2 -0
- package/dist/dts/resource/types.d.ts.map +1 -1
- package/dist/dts/serializers/json/json.d.ts +28 -0
- package/dist/dts/serializers/json/json.d.ts.map +1 -1
- package/dist/dts/styles/color.d.ts +4 -0
- package/dist/dts/styles/color.d.ts.map +1 -1
- package/dist/dts/styles/dom.d.ts +13 -0
- package/dist/dts/styles/dom.d.ts.map +1 -1
- package/dist/dts/styles/slotted-styles.d.ts +13 -0
- package/dist/dts/styles/slotted-styles.d.ts.map +1 -1
- package/dist/dts/styles/typography.d.ts +27 -1
- package/dist/dts/styles/typography.d.ts.map +1 -1
- package/dist/dts/tsdoc-metadata.json +11 -0
- package/dist/dts/uuid/uuid.d.ts +22 -3
- package/dist/dts/uuid/uuid.d.ts.map +1 -1
- package/dist/dts/window/window.d.ts +27 -0
- package/dist/dts/window/window.d.ts.map +1 -1
- package/dist/esm/data/inMemoryDatabase.js +1 -0
- package/dist/esm/directives/sync/sync.js +8 -0
- package/dist/esm/directives/when-else/when-else.js +1 -1
- package/dist/esm/env/is-dev.js +4 -0
- package/dist/esm/env/variables.js +37 -0
- package/dist/esm/formatters/datetime.js +2 -2
- package/dist/esm/logger/logger.js +11 -0
- package/dist/esm/mappers/dto/serverRow.js +20 -0
- package/dist/esm/mixins/pendingState/pendingState.js +37 -1
- package/dist/esm/observer/observer.js +5 -1
- package/dist/esm/resource/types.js +1 -0
- package/dist/esm/serializers/json/json.js +14 -0
- package/dist/esm/styles/color.js +11 -1
- package/dist/esm/styles/dom.js +13 -0
- package/dist/esm/styles/slotted-styles.js +13 -0
- package/dist/esm/styles/typography.js +26 -0
- package/dist/esm/uuid/uuid.js +20 -11
- package/dist/esm/window/window.js +27 -0
- package/dist/foundation-utils.api.json +10996 -0
- package/dist/foundation-utils.d.ts +1462 -0
- package/docs/api/foundation-utils.activecolorscheme.md +13 -0
- package/docs/api/foundation-utils.api_host.md +18 -0
- package/docs/api/foundation-utils.assuredesignsystem.md +23 -0
- package/docs/api/foundation-utils.constructablelifecyclehandler.md +12 -0
- package/docs/api/foundation-utils.constructablependingstate.md +13 -0
- package/docs/api/foundation-utils.conversiontype.md +13 -0
- package/docs/api/foundation-utils.createlogger.md +27 -0
- package/docs/api/foundation-utils.createobserver.md +13 -0
- package/docs/api/foundation-utils.database.create.md +22 -0
- package/docs/api/foundation-utils.database.delete.md +22 -0
- package/docs/api/foundation-utils.database.isworking.md +11 -0
- package/docs/api/foundation-utils.database.md +32 -0
- package/docs/api/foundation-utils.database.onafterupdate.md +22 -0
- package/docs/api/foundation-utils.database.onbeforeupdate.md +22 -0
- package/docs/api/foundation-utils.database.read.md +22 -0
- package/docs/api/foundation-utils.database.update.md +23 -0
- package/docs/api/foundation-utils.database.visit.md +22 -0
- package/docs/api/foundation-utils.databaseaccessresult.access.md +18 -0
- package/docs/api/foundation-utils.databaseaccessresult.access.value.md +11 -0
- package/docs/api/foundation-utils.databaseaccessresult.create.md +13 -0
- package/docs/api/foundation-utils.databaseaccessresult.delete.id.md +11 -0
- package/docs/api/foundation-utils.databaseaccessresult.delete.md +19 -0
- package/docs/api/foundation-utils.databaseaccessresult.delete.success.md +11 -0
- package/docs/api/foundation-utils.databaseaccessresult.md +24 -0
- package/docs/api/foundation-utils.databaseaccessresult.read.md +13 -0
- package/docs/api/foundation-utils.databaseaccessresult.update.md +13 -0
- package/docs/api/foundation-utils.databaseevent.afterupdate.md +13 -0
- package/docs/api/foundation-utils.databaseevent.beforeupdate.md +19 -0
- package/docs/api/foundation-utils.databaseevent.beforeupdate.newvalue.md +11 -0
- package/docs/api/foundation-utils.databaseevent.md +22 -0
- package/docs/api/foundation-utils.databaseevent.update.md +18 -0
- package/docs/api/foundation-utils.databaseevent.update.value.md +11 -0
- package/docs/api/foundation-utils.databaserecord.id.md +11 -0
- package/docs/api/foundation-utils.databaserecord.md +20 -0
- package/docs/api/foundation-utils.default_organisation.md +18 -0
- package/docs/api/foundation-utils.default_password.md +18 -0
- package/docs/api/foundation-utils.default_user.md +18 -0
- package/docs/api/foundation-utils.defaulteventmap.md +13 -0
- package/docs/api/foundation-utils.defaultloggeroptions.md +13 -0
- package/docs/api/foundation-utils.defaultserverrowdtomapper.fromdto.md +13 -0
- package/docs/api/foundation-utils.defaultserverrowdtomapper.md +22 -0
- package/docs/api/foundation-utils.defaultserverrowdtomapper.todto.md +13 -0
- package/docs/api/foundation-utils.designsystemmodule.md +19 -0
- package/docs/api/foundation-utils.designsystemmodule.providedesignsystem.md +23 -0
- package/docs/api/foundation-utils.designsystemresource.md +14 -0
- package/docs/api/foundation-utils.dtomapper.fromargs.md +11 -0
- package/docs/api/foundation-utils.dtomapper.fromdto.md +11 -0
- package/docs/api/foundation-utils.dtomapper.md +21 -0
- package/docs/api/foundation-utils.dtomapper.todto.md +11 -0
- package/docs/api/foundation-utils.eventname.md +13 -0
- package/docs/api/foundation-utils.fontstyle.md +21 -0
- package/docs/api/foundation-utils.fontweight.md +25 -0
- package/docs/api/foundation-utils.force_http.md +18 -0
- package/docs/api/foundation-utils.formatdatetimestamp.md +24 -0
- package/docs/api/foundation-utils.formatdatetimetimestamp.md +24 -0
- package/docs/api/foundation-utils.formattimestamp.md +25 -0
- package/docs/api/foundation-utils.getfontmixin.md +13 -0
- package/docs/api/foundation-utils.http_config.md +18 -0
- package/docs/api/foundation-utils.iniframe.md +13 -0
- package/docs/api/foundation-utils.inmemorydatabase._constructor_.md +20 -0
- package/docs/api/foundation-utils.inmemorydatabase.create.md +22 -0
- package/docs/api/foundation-utils.inmemorydatabase.delete.md +22 -0
- package/docs/api/foundation-utils.inmemorydatabase.isworking.md +11 -0
- package/docs/api/foundation-utils.inmemorydatabase.md +39 -0
- package/docs/api/foundation-utils.inmemorydatabase.onafterupdate.md +22 -0
- package/docs/api/foundation-utils.inmemorydatabase.onbeforeupdate.md +22 -0
- package/docs/api/foundation-utils.inmemorydatabase.read.md +22 -0
- package/docs/api/foundation-utils.inmemorydatabase.update.md +23 -0
- package/docs/api/foundation-utils.inmemorydatabase.visit.md +22 -0
- package/docs/api/foundation-utils.insertdocumentcssrule.md +13 -0
- package/docs/api/foundation-utils.insertdocumentlink.md +13 -0
- package/docs/api/foundation-utils.insymphonydesktop.md +13 -0
- package/docs/api/foundation-utils.isdev.md +13 -0
- package/docs/api/foundation-utils.jsonserializer.deserialize.md +26 -0
- package/docs/api/foundation-utils.jsonserializer.deserialize_1.md +26 -0
- package/docs/api/foundation-utils.jsonserializer.deserialize_2.md +26 -0
- package/docs/api/foundation-utils.jsonserializer.md +13 -0
- package/docs/api/foundation-utils.jsonserializer.serialize.md +26 -0
- package/docs/api/foundation-utils.layoutcachedocument.md +13 -0
- package/docs/api/foundation-utils.lifecyclemixin.md +342 -0
- package/docs/api/foundation-utils.listener.md +13 -0
- package/docs/api/foundation-utils.loadfontfaces.md +13 -0
- package/docs/api/foundation-utils.logger.deprecated.md +45 -0
- package/docs/api/foundation-utils.logger.md +25 -0
- package/docs/api/foundation-utils.loggeroptions.md +15 -0
- package/docs/api/foundation-utils.md +111 -0
- package/docs/api/foundation-utils.observer.md +21 -0
- package/docs/api/foundation-utils.observer.publish.md +11 -0
- package/docs/api/foundation-utils.observer.subscribe.md +11 -0
- package/docs/api/foundation-utils.openpopup.md +13 -0
- package/docs/api/foundation-utils.pendingstate.md +334 -0
- package/docs/api/foundation-utils.pendingstateerrorevent.md +13 -0
- package/docs/api/foundation-utils.pendingstateevent.md +13 -0
- package/docs/api/foundation-utils.pendingstateevents.md +21 -0
- package/docs/api/foundation-utils.popup_default_height.md +13 -0
- package/docs/api/foundation-utils.popup_default_width.md +13 -0
- package/docs/api/foundation-utils.publish.md +13 -0
- package/docs/api/foundation-utils.renderonchange.md +51 -0
- package/docs/api/foundation-utils.resourcetype.md +16 -0
- package/docs/api/foundation-utils.respondtovisibility.md +13 -0
- package/docs/api/foundation-utils.serverrowdto.md +18 -0
- package/docs/api/foundation-utils.serverrowdtomapper.md +13 -0
- package/docs/api/foundation-utils.serverrowentity.md +18 -0
- package/docs/api/foundation-utils.slottedstyles.md +27 -0
- package/docs/api/foundation-utils.slottedstyles.styles.md +13 -0
- package/docs/api/foundation-utils.slottedstyles.styleschanged.md +25 -0
- package/docs/api/foundation-utils.socket_ext.md +18 -0
- package/docs/api/foundation-utils.subscribe.md +15 -0
- package/docs/api/foundation-utils.sync.md +27 -0
- package/docs/api/foundation-utils.typerampvalues.md +22 -0
- package/docs/api/foundation-utils.uuid.createid.md +26 -0
- package/docs/api/foundation-utils.uuid.createremoteid.md +26 -0
- package/docs/api/foundation-utils.uuid.md +13 -0
- package/docs/api/foundation-utils.uuidconfig.md +13 -0
- package/docs/api/foundation-utils.whenelse.md +26 -0
- package/docs/api/index.md +12 -0
- package/docs/api-report.md +1075 -0
- package/package.json +6 -9
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [renderOnChange](./foundation-utils.renderonchange.md)
|
|
4
|
+
|
|
5
|
+
## renderOnChange() function
|
|
6
|
+
|
|
7
|
+
Defines a property changed handler that calls a render() method on the target as an internal observation enhancement.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export declare function renderOnChange(target: FASTElement & {
|
|
13
|
+
render(): void;
|
|
14
|
+
}, name: string): void;
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
## Parameters
|
|
18
|
+
|
|
19
|
+
| Parameter | Type | Description |
|
|
20
|
+
| --- | --- | --- |
|
|
21
|
+
| target | FASTElement & { render(): void; } | The target to define the property change handler on. |
|
|
22
|
+
| name | string | The property name. |
|
|
23
|
+
|
|
24
|
+
**Returns:**
|
|
25
|
+
|
|
26
|
+
void
|
|
27
|
+
|
|
28
|
+
## Remarks
|
|
29
|
+
|
|
30
|
+
This is useful if you have a lot of properties that all invalidate the internal state. See [https://www.fast.design/docs/fast-element/observables-and-state\#internal-observation](https://www.fast.design/docs/fast-element/observables-and-state#internal-observation) for more information.
|
|
31
|
+
|
|
32
|
+
## Example
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
```ts
|
|
36
|
+
@attr({ mode: 'boolean', attribute: 'line-numbers' })
|
|
37
|
+
@renderOnChange
|
|
38
|
+
lineNumbers: boolean = true;
|
|
39
|
+
|
|
40
|
+
@attr
|
|
41
|
+
@renderOnChange
|
|
42
|
+
indent: number | 'tab' = 2;
|
|
43
|
+
|
|
44
|
+
render() {
|
|
45
|
+
if (!this.$fastController.isConnected) {
|
|
46
|
+
return;
|
|
47
|
+
}
|
|
48
|
+
// Do something...
|
|
49
|
+
}
|
|
50
|
+
```
|
|
51
|
+
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [ResourceType](./foundation-utils.resourcetype.md)
|
|
4
|
+
|
|
5
|
+
## ResourceType variable
|
|
6
|
+
|
|
7
|
+
An object that defines two resource types: "local" and "remote".
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
ResourceType: {
|
|
13
|
+
readonly local: "local";
|
|
14
|
+
readonly remote: "remote";
|
|
15
|
+
}
|
|
16
|
+
```
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [respondToVisibility](./foundation-utils.respondtovisibility.md)
|
|
4
|
+
|
|
5
|
+
## respondToVisibility variable
|
|
6
|
+
|
|
7
|
+
Setup an `IntersectionObserver` which will activate a callback function when an element becomes visible on screen
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
respondToVisibility: (element: HTMLElement, callback: (arg0: boolean) => any) => void
|
|
13
|
+
```
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [ServerRowDTO](./foundation-utils.serverrowdto.md)
|
|
4
|
+
|
|
5
|
+
## ServerRowDTO type
|
|
6
|
+
|
|
7
|
+
The data for a server row DTO.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export type ServerRowDTO = {
|
|
13
|
+
DETAILS: {
|
|
14
|
+
OPERATION: UppercaseOperation;
|
|
15
|
+
ROW_REF: string;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
```
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [ServerRowDTOMapper](./foundation-utils.serverrowdtomapper.md)
|
|
4
|
+
|
|
5
|
+
## ServerRowDTOMapper variable
|
|
6
|
+
|
|
7
|
+
A DI token used to obtain a `ServerRowDTOMapper` instance.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
ServerRowDTOMapper: import("@microsoft/fast-foundation").InterfaceSymbol<ServerRowDTOMapper>
|
|
13
|
+
```
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [ServerRowEntity](./foundation-utils.serverrowentity.md)
|
|
4
|
+
|
|
5
|
+
## ServerRowEntity type
|
|
6
|
+
|
|
7
|
+
The data for a server row entity.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export type ServerRowEntity = {
|
|
13
|
+
serverRowMetadata: {
|
|
14
|
+
operation: LowercaseOperation;
|
|
15
|
+
rowRef: string;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
```
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [SlottedStyles](./foundation-utils.slottedstyles.md)
|
|
4
|
+
|
|
5
|
+
## SlottedStyles class
|
|
6
|
+
|
|
7
|
+
A custom element that encapsulates a set of styles that can be applied to slotted elements.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export declare class SlottedStyles extends FASTElement
|
|
13
|
+
```
|
|
14
|
+
**Extends:** FASTElement
|
|
15
|
+
|
|
16
|
+
## Properties
|
|
17
|
+
|
|
18
|
+
| Property | Modifiers | Type | Description |
|
|
19
|
+
| --- | --- | --- | --- |
|
|
20
|
+
| [styles](./foundation-utils.slottedstyles.styles.md) | | ElementStyles | The styles to apply to slotted elements. |
|
|
21
|
+
|
|
22
|
+
## Methods
|
|
23
|
+
|
|
24
|
+
| Method | Modifiers | Description |
|
|
25
|
+
| --- | --- | --- |
|
|
26
|
+
| [stylesChanged(prev, next)](./foundation-utils.slottedstyles.styleschanged.md) | | Called when the <code>styles</code> property changes. Removes the previous styles from the parent element's FAST controller and adds the new styles. |
|
|
27
|
+
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [SlottedStyles](./foundation-utils.slottedstyles.md) > [styles](./foundation-utils.slottedstyles.styles.md)
|
|
4
|
+
|
|
5
|
+
## SlottedStyles.styles property
|
|
6
|
+
|
|
7
|
+
The styles to apply to slotted elements.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
styles: ElementStyles;
|
|
13
|
+
```
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [SlottedStyles](./foundation-utils.slottedstyles.md) > [stylesChanged](./foundation-utils.slottedstyles.styleschanged.md)
|
|
4
|
+
|
|
5
|
+
## SlottedStyles.stylesChanged() method
|
|
6
|
+
|
|
7
|
+
Called when the `styles` property changes. Removes the previous styles from the parent element's FAST controller and adds the new styles.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
stylesChanged(prev: ElementStyles, next: ElementStyles): void;
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
| Parameter | Type | Description |
|
|
18
|
+
| --- | --- | --- |
|
|
19
|
+
| prev | ElementStyles | The previous value of the <code>styles</code> property. |
|
|
20
|
+
| next | ElementStyles | The new value of the <code>styles</code> property. |
|
|
21
|
+
|
|
22
|
+
**Returns:**
|
|
23
|
+
|
|
24
|
+
void
|
|
25
|
+
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [SOCKET\_EXT](./foundation-utils.socket_ext.md)
|
|
4
|
+
|
|
5
|
+
## SOCKET\_EXT variable
|
|
6
|
+
|
|
7
|
+
The sub-path used for WebSocket connections. Example: API\_HOST + '/' + SOCKET\_EXT - wss://localhost:9064/gwf.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
_SOCKET_EXT: string
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Remarks
|
|
16
|
+
|
|
17
|
+
Optional. Default is "API\_HOST/gwf"
|
|
18
|
+
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [Subscribe](./foundation-utils.subscribe.md)
|
|
4
|
+
|
|
5
|
+
## Subscribe type
|
|
6
|
+
|
|
7
|
+
Subscribes a listener function to receive events of a specific type.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export type Subscribe<EventType> = (listener: Listener<EventType>) => () => void;
|
|
13
|
+
```
|
|
14
|
+
**References:** [Listener](./foundation-utils.listener.md)
|
|
15
|
+
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [sync](./foundation-utils.sync.md)
|
|
4
|
+
|
|
5
|
+
## sync() function
|
|
6
|
+
|
|
7
|
+
Creates a synchronization directive that binds a data source to an HTML element,
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export declare function sync<TSource = any, TReturn = any>(binding: Binding<TSource, TReturn>, conversionType?: ConversionType, eventName?: EventName, keyAttr?: string): CaptureType<TSource>;
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
| Parameter | Type | Description |
|
|
18
|
+
| --- | --- | --- |
|
|
19
|
+
| binding | Binding<TSource, TReturn> | |
|
|
20
|
+
| conversionType | [ConversionType](./foundation-utils.conversiontype.md) | _(Optional)_ |
|
|
21
|
+
| eventName | [EventName](./foundation-utils.eventname.md) | _(Optional)_ |
|
|
22
|
+
| keyAttr | string | _(Optional)_ |
|
|
23
|
+
|
|
24
|
+
**Returns:**
|
|
25
|
+
|
|
26
|
+
CaptureType<TSource>
|
|
27
|
+
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [TypeRampValues](./foundation-utils.typerampvalues.md)
|
|
4
|
+
|
|
5
|
+
## TypeRampValues variable
|
|
6
|
+
|
|
7
|
+
An object containing type ramp values.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
TypeRampValues: {
|
|
13
|
+
readonly minusOne: -1;
|
|
14
|
+
readonly minusTwo: -2;
|
|
15
|
+
readonly plusOne: 1;
|
|
16
|
+
readonly plusTwo: 2;
|
|
17
|
+
readonly plusThree: 3;
|
|
18
|
+
readonly plusFour: 4;
|
|
19
|
+
readonly plusFive: 5;
|
|
20
|
+
readonly plusSix: 6;
|
|
21
|
+
}
|
|
22
|
+
```
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [UUID](./foundation-utils.uuid.md) > [createId](./foundation-utils.uuid.createid.md)
|
|
4
|
+
|
|
5
|
+
## UUID.createId() method
|
|
6
|
+
|
|
7
|
+
Generates a new UUID.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
createId(withLogging?: boolean): string;
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
| Parameter | Type | Description |
|
|
18
|
+
| --- | --- | --- |
|
|
19
|
+
| withLogging | boolean | _(Optional)_ Optional. Whether to log the generated UUID to the console. Defaults to false. |
|
|
20
|
+
|
|
21
|
+
**Returns:**
|
|
22
|
+
|
|
23
|
+
string
|
|
24
|
+
|
|
25
|
+
The generated UUID.
|
|
26
|
+
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [UUID](./foundation-utils.uuid.md) > [createRemoteId](./foundation-utils.uuid.createremoteid.md)
|
|
4
|
+
|
|
5
|
+
## UUID.createRemoteId() method
|
|
6
|
+
|
|
7
|
+
Generates a new UUID for a remote object.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
createRemoteId(withLogging?: boolean): Promise<string>;
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
| Parameter | Type | Description |
|
|
18
|
+
| --- | --- | --- |
|
|
19
|
+
| withLogging | boolean | _(Optional)_ Optional. Whether to log the generated UUID to the console. Defaults to false. |
|
|
20
|
+
|
|
21
|
+
**Returns:**
|
|
22
|
+
|
|
23
|
+
Promise<string>
|
|
24
|
+
|
|
25
|
+
A promise that resolves to the generated UUID.
|
|
26
|
+
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [UUID](./foundation-utils.uuid.md)
|
|
4
|
+
|
|
5
|
+
## UUID variable
|
|
6
|
+
|
|
7
|
+
A dependency injection token for the UUID interface.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
UUID: import("@microsoft/fast-foundation").InterfaceSymbol<UUID>
|
|
13
|
+
```
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [UUIDConfig](./foundation-utils.uuidconfig.md)
|
|
4
|
+
|
|
5
|
+
## UUIDConfig interface
|
|
6
|
+
|
|
7
|
+
A configuration object for customizing UUID generation.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export interface UUIDConfig
|
|
13
|
+
```
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-utils](./foundation-utils.md) > [whenElse](./foundation-utils.whenelse.md)
|
|
4
|
+
|
|
5
|
+
## whenElse() function
|
|
6
|
+
|
|
7
|
+
Directive that allows supplying an "else" template to the traditional [https://www.fast.design/docs/api/fast-element.when/\#when-function](https://www.fast.design/docs/api/fast-element.when/#when-function) directive
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export declare function whenElse<TSource = any, TReturn = any>(binding: Binding<TSource, TReturn>, trueTemplateOrTemplateBinding: WhenTemplate<TSource>, falseTemplateOrTemplateBinding: WhenTemplate<TSource>): CaptureType<TSource>;
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
| Parameter | Type | Description |
|
|
18
|
+
| --- | --- | --- |
|
|
19
|
+
| binding | Binding<TSource, TReturn> | The condition to test for rendering. |
|
|
20
|
+
| trueTemplateOrTemplateBinding | WhenTemplate<TSource> | The template or a binding that gets the template to render when the condition is true. |
|
|
21
|
+
| falseTemplateOrTemplateBinding | WhenTemplate<TSource> | The template or a binding that gets the template to render when the condition is false. |
|
|
22
|
+
|
|
23
|
+
**Returns:**
|
|
24
|
+
|
|
25
|
+
CaptureType<TSource>
|
|
26
|
+
|