@genesislcap/foundation-filters 9.0.1-alpha-b5c5eb7.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/MODULE_FEDERATION.md +11 -0
- package/README.md +173 -0
- package/dist/1.0.0.remoteEntry.js +1 -0
- package/dist/191.191.64feeeeeb6c4132a6cae.js +2 -0
- package/dist/191.d7c8a7fc5c69e4190ea53a04618e0459.js.map +1 -0
- package/dist/195.195.2c71a4e018ba860ab228.js +3 -0
- package/dist/195.195.2c71a4e018ba860ab228.js.LICENSE.txt +4 -0
- package/dist/195.331a5c4d39a8a3d001d3344cb66ef3b8.js.map +1 -0
- package/dist/259.0acac2573f700ecd1acac239926438a5.js.map +1 -0
- package/dist/259.259.3aa926921ed1388957f1.js +2 -0
- package/dist/338.338.cd6e49db31e7adc808c6.js +3 -0
- package/dist/338.338.cd6e49db31e7adc808c6.js.LICENSE.txt +1 -0
- package/dist/338.7a143cd09921b756e7fe871d338dcb67.js.map +1 -0
- package/dist/410.410.76d9d4b118ba230b93c4.js +2 -0
- package/dist/410.cda4ae21eb38efbf2dbfd913db12d66f.js.map +1 -0
- package/dist/755.755.ec31a791472b4b3fcb0f.js +2 -0
- package/dist/755.c71c3a1801dd2c0461f8b831d09ec90f.js.map +1 -0
- package/dist/dashboard.json +1 -0
- package/dist/dts/clientFilter.d.ts +108 -0
- package/dist/dts/clientFilter.d.ts.map +1 -0
- package/dist/dts/index.d.ts +9 -0
- package/dist/dts/index.d.ts.map +1 -0
- package/dist/dts/index.federated.d.ts +1 -0
- package/dist/dts/index.federated.d.ts.map +1 -0
- package/dist/dts/logger.d.ts +17 -0
- package/dist/dts/logger.d.ts.map +1 -0
- package/dist/dts/nodeEnv.d.ts +81 -0
- package/dist/dts/nodeEnv.d.ts.map +1 -0
- package/dist/dts/percentage.d.ts +81 -0
- package/dist/dts/percentage.d.ts.map +1 -0
- package/dist/dts/timeWindow.d.ts +91 -0
- package/dist/dts/timeWindow.d.ts.map +1 -0
- package/dist/dts/tsdoc-metadata.json +11 -0
- package/dist/dts/urlTargeting.d.ts +94 -0
- package/dist/dts/urlTargeting.d.ts.map +1 -0
- package/dist/dts/userAgent.d.ts +96 -0
- package/dist/dts/userAgent.d.ts.map +1 -0
- package/dist/dts/userTargeting.d.ts +107 -0
- package/dist/dts/userTargeting.d.ts.map +1 -0
- package/dist/esm/clientFilter.js +84 -0
- package/dist/esm/clientFilter.js.map +1 -0
- package/dist/esm/index.federated.js +2 -0
- package/dist/esm/index.federated.js.map +1 -0
- package/dist/esm/index.js +9 -0
- package/dist/esm/index.js.map +1 -0
- package/dist/esm/logger.js +18 -0
- package/dist/esm/logger.js.map +1 -0
- package/dist/esm/nodeEnv.js +48 -0
- package/dist/esm/nodeEnv.js.map +1 -0
- package/dist/esm/percentage.js +38 -0
- package/dist/esm/percentage.js.map +1 -0
- package/dist/esm/timeWindow.js +49 -0
- package/dist/esm/timeWindow.js.map +1 -0
- package/dist/esm/urlTargeting.js +68 -0
- package/dist/esm/urlTargeting.js.map +1 -0
- package/dist/esm/userAgent.js +59 -0
- package/dist/esm/userAgent.js.map +1 -0
- package/dist/esm/userTargeting.js +73 -0
- package/dist/esm/userTargeting.js.map +1 -0
- package/dist/favicon.ico +0 -0
- package/dist/foundation-filters.api.json +3065 -0
- package/dist/foundation-filters.d.ts +707 -0
- package/dist/foundation-filters.iife.min.js +3 -0
- package/dist/foundation-filters.js +8608 -0
- package/dist/foundation-filters.min.js +3 -0
- package/dist/foundationFilters.c0ca375607bf5b49304e9efbcfb9ec0d.js.map +1 -0
- package/dist/index.ejs +23 -0
- package/dist/index.html +16 -0
- package/dist/info.ejs +13 -0
- package/dist/main.479db3c6a61354c4d21c4a52177a4fc9.js.map +1 -0
- package/dist/main.8bf3ac27c0d922605d1f.js +2 -0
- package/dist/npm.analytics.343.d4561facd9660fd45482.js +2 -0
- package/dist/npm.analytics.50acd47759b15e99bc3ad79caad7c672.js.map +1 -0
- package/dist/npm.consola.0f92c98545c00deac8a01e6e5c25e63c.js.map +1 -0
- package/dist/npm.consola.713.4cfd0e26a2fd1e472409.js +2 -0
- package/dist/npm.finos.690.4b909dcccf246b8fb074.js +2 -0
- package/dist/npm.finos.83f8bd7cc8c58aabd1049256a8d005fe.js.map +1 -0
- package/dist/npm.microsoft.127.2934a743e3e0797a43e6.js +1469 -0
- package/dist/npm.microsoft.127.2934a743e3e0797a43e6.js.LICENSE.txt +14 -0
- package/dist/npm.microsoft.e17056c760df168ceb07617558d61f7e.js.map +1 -0
- package/dist/npm.rxjs.271.11caf676e6c2aaf1715a.js +2 -0
- package/dist/npm.rxjs.2d42120c7dd915e4ea92bdec64a19f45.js.map +1 -0
- package/dist/npm.ua-parser-js.809.92491f7cd444ab77d377.js +2 -0
- package/dist/npm.ua-parser-js.b1390f6f6c6080318a30bc73abe8add8.js.map +1 -0
- package/dist/remoteEntry.js +2 -0
- package/dist/serve.json +3 -0
- package/docs/api/foundation-filters.clientfilter.filter.md +24 -0
- package/docs/api/foundation-filters.clientfilter.md +24 -0
- package/docs/api/foundation-filters.clientfiltername.md +19 -0
- package/docs/api/foundation-filters.clientfilterrunner.md +20 -0
- package/docs/api/foundation-filters.clientfilterrunner.run.md +23 -0
- package/docs/api/foundation-filters.clientfilterschema.md +22 -0
- package/docs/api/foundation-filters.clientfilterschemas.md +15 -0
- package/docs/api/foundation-filters.defaultclientfilterrunner.container.md +11 -0
- package/docs/api/foundation-filters.defaultclientfilterrunner.md +27 -0
- package/docs/api/foundation-filters.defaultclientfilterrunner.run.md +23 -0
- package/docs/api/foundation-filters.defaultnodeenv.filter.md +24 -0
- package/docs/api/foundation-filters.defaultnodeenv.isdevelopment.md +16 -0
- package/docs/api/foundation-filters.defaultnodeenv.isproduction.md +16 -0
- package/docs/api/foundation-filters.defaultnodeenv.istesting.md +16 -0
- package/docs/api/foundation-filters.defaultnodeenv.md +29 -0
- package/docs/api/foundation-filters.defaultpercentage.filter.md +24 -0
- package/docs/api/foundation-filters.defaultpercentage.md +21 -0
- package/docs/api/foundation-filters.defaulttimewindow.filter.md +24 -0
- package/docs/api/foundation-filters.defaulttimewindow.md +21 -0
- package/docs/api/foundation-filters.defaulturltargeting.filter.md +24 -0
- package/docs/api/foundation-filters.defaulturltargeting.issecure.md +26 -0
- package/docs/api/foundation-filters.defaulturltargeting.md +22 -0
- package/docs/api/foundation-filters.defaultuseragent.filter.md +24 -0
- package/docs/api/foundation-filters.defaultuseragent.issafari.md +16 -0
- package/docs/api/foundation-filters.defaultuseragent.md +27 -0
- package/docs/api/foundation-filters.defaultusertargeting._constructor_.md +20 -0
- package/docs/api/foundation-filters.defaultusertargeting.auth.md +11 -0
- package/docs/api/foundation-filters.defaultusertargeting.filter.md +24 -0
- package/docs/api/foundation-filters.defaultusertargeting.hasadminprofile.md +16 -0
- package/docs/api/foundation-filters.defaultusertargeting.isloggedin.md +16 -0
- package/docs/api/foundation-filters.defaultusertargeting.md +35 -0
- package/docs/api/foundation-filters.getfilterbyname.md +25 -0
- package/docs/api/foundation-filters.logger.md +27 -0
- package/docs/api/foundation-filters.md +71 -0
- package/docs/api/foundation-filters.nodeenv.isdevelopment.md +16 -0
- package/docs/api/foundation-filters.nodeenv.isproduction.md +16 -0
- package/docs/api/foundation-filters.nodeenv.istesting.md +16 -0
- package/docs/api/foundation-filters.nodeenv.md +23 -0
- package/docs/api/foundation-filters.nodeenvfilter.md +28 -0
- package/docs/api/foundation-filters.nodeenvparams.md +25 -0
- package/docs/api/foundation-filters.nodeenvschema.md +19 -0
- package/docs/api/foundation-filters.percentage.md +19 -0
- package/docs/api/foundation-filters.percentagefilter.md +29 -0
- package/docs/api/foundation-filters.percentageparams.md +41 -0
- package/docs/api/foundation-filters.percentageschema.md +19 -0
- package/docs/api/foundation-filters.runner.md +29 -0
- package/docs/api/foundation-filters.timewindow.md +19 -0
- package/docs/api/foundation-filters.timewindowfilter.md +29 -0
- package/docs/api/foundation-filters.timewindowparams.md +59 -0
- package/docs/api/foundation-filters.timewindowschema.md +19 -0
- package/docs/api/foundation-filters.urltargeting.issecure.md +26 -0
- package/docs/api/foundation-filters.urltargeting.md +21 -0
- package/docs/api/foundation-filters.urltargetingfilter.md +32 -0
- package/docs/api/foundation-filters.urltargetingparams.md +30 -0
- package/docs/api/foundation-filters.urltargetingschema.md +19 -0
- package/docs/api/foundation-filters.useragent.issafari.md +16 -0
- package/docs/api/foundation-filters.useragent.md +25 -0
- package/docs/api/foundation-filters.useragentfilter.md +31 -0
- package/docs/api/foundation-filters.useragentparams.md +30 -0
- package/docs/api/foundation-filters.useragentschema.md +19 -0
- package/docs/api/foundation-filters.usertargeting.hasadminprofile.md +16 -0
- package/docs/api/foundation-filters.usertargeting.isloggedin.md +16 -0
- package/docs/api/foundation-filters.usertargeting.md +26 -0
- package/docs/api/foundation-filters.usertargetingfilter.md +31 -0
- package/docs/api/foundation-filters.usertargetingparams.md +29 -0
- package/docs/api/foundation-filters.usertargetingschema.md +19 -0
- package/docs/api/index.md +12 -0
- package/docs/api-report.md +283 -0
- package/jsdom.setup.ts +1 -0
- package/license.txt +46 -0
- package/package.json +122 -0
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [runner](./foundation-filters.runner.md)
|
|
4
|
+
|
|
5
|
+
## runner() function
|
|
6
|
+
|
|
7
|
+
Client filter runner function.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export declare function runner(filters: ClientFilterSchemas[], container: Container): boolean;
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
| Parameter | Type | Description |
|
|
18
|
+
| --- | --- | --- |
|
|
19
|
+
| filters | [ClientFilterSchemas](./foundation-filters.clientfilterschemas.md)<!-- -->\[\] | An array of client filters to run. |
|
|
20
|
+
| container | Container | The DI container. |
|
|
21
|
+
|
|
22
|
+
**Returns:**
|
|
23
|
+
|
|
24
|
+
boolean
|
|
25
|
+
|
|
26
|
+
## Remarks
|
|
27
|
+
|
|
28
|
+
This will return true when all the filters in the array pass.
|
|
29
|
+
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [TimeWindow](./foundation-filters.timewindow.md)
|
|
4
|
+
|
|
5
|
+
## TimeWindow interface
|
|
6
|
+
|
|
7
|
+
TimeWindow client filter DI interface.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export interface TimeWindow extends ClientFilter<TimeWindowParams>
|
|
13
|
+
```
|
|
14
|
+
**Extends:** [ClientFilter](./foundation-filters.clientfilter.md)<!-- --><[TimeWindowParams](./foundation-filters.timewindowparams.md)<!-- -->>
|
|
15
|
+
|
|
16
|
+
## Remarks
|
|
17
|
+
|
|
18
|
+
Simplifies access to runtime data / state contained within the DI container.
|
|
19
|
+
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [timeWindowFilter](./foundation-filters.timewindowfilter.md)
|
|
4
|
+
|
|
5
|
+
## timeWindowFilter() function
|
|
6
|
+
|
|
7
|
+
TimeWindow client filter function.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export declare function timeWindowFilter(start?: string, end?: string): boolean;
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
| Parameter | Type | Description |
|
|
18
|
+
| --- | --- | --- |
|
|
19
|
+
| start | string | _(Optional)_ The start of the time window. |
|
|
20
|
+
| end | string | _(Optional)_ The end of the time window. |
|
|
21
|
+
|
|
22
|
+
**Returns:**
|
|
23
|
+
|
|
24
|
+
boolean
|
|
25
|
+
|
|
26
|
+
## Remarks
|
|
27
|
+
|
|
28
|
+
This will return true between a certain time window. Start and end can be provided in any format recognized by the Date.parse() method.
|
|
29
|
+
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [TimeWindowParams](./foundation-filters.timewindowparams.md)
|
|
4
|
+
|
|
5
|
+
## TimeWindowParams type
|
|
6
|
+
|
|
7
|
+
TimeWindowParams
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export type TimeWindowParams = {
|
|
13
|
+
readonly start?: string;
|
|
14
|
+
readonly end?: string;
|
|
15
|
+
};
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
## Remarks
|
|
19
|
+
|
|
20
|
+
Both params can be provided in any format recognized by the Date.parse() method.
|
|
21
|
+
|
|
22
|
+
## Example 1
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
```json
|
|
26
|
+
{
|
|
27
|
+
"start": "Sun Sep 25 2022 16:51:55 GMT+0000",
|
|
28
|
+
"end": "Fri Nov 25 2022 17:51:55 GMT+0000"
|
|
29
|
+
}
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## Example 2
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
```json
|
|
36
|
+
{
|
|
37
|
+
"start": "2022-10-01",
|
|
38
|
+
"end": "2022-12-01"
|
|
39
|
+
}
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## Example 3
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
```json
|
|
46
|
+
{
|
|
47
|
+
"end": "Dec 31, 2022"
|
|
48
|
+
}
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
## Example 4
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
```json
|
|
55
|
+
{
|
|
56
|
+
"start": "2023-01-01T00:00:00.000+00:00"
|
|
57
|
+
}
|
|
58
|
+
```
|
|
59
|
+
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [TimeWindowSchema](./foundation-filters.timewindowschema.md)
|
|
4
|
+
|
|
5
|
+
## TimeWindowSchema type
|
|
6
|
+
|
|
7
|
+
TimeWindowSchema type.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export type TimeWindowSchema = ClientFilterSchema<typeof ClientFilterName.timeWindow, TimeWindowParams>;
|
|
13
|
+
```
|
|
14
|
+
**References:** [ClientFilterSchema](./foundation-filters.clientfilterschema.md)<!-- -->, [TimeWindowParams](./foundation-filters.timewindowparams.md)
|
|
15
|
+
|
|
16
|
+
## Remarks
|
|
17
|
+
|
|
18
|
+
JSON schema type.
|
|
19
|
+
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [URLTargeting](./foundation-filters.urltargeting.md) > [isSecure](./foundation-filters.urltargeting.issecure.md)
|
|
4
|
+
|
|
5
|
+
## URLTargeting.isSecure() method
|
|
6
|
+
|
|
7
|
+
**Signature:**
|
|
8
|
+
|
|
9
|
+
```typescript
|
|
10
|
+
isSecure(url: string): boolean;
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Parameters
|
|
14
|
+
|
|
15
|
+
| Parameter | Type | Description |
|
|
16
|
+
| --- | --- | --- |
|
|
17
|
+
| url | string | A url. |
|
|
18
|
+
|
|
19
|
+
**Returns:**
|
|
20
|
+
|
|
21
|
+
boolean
|
|
22
|
+
|
|
23
|
+
## Remarks
|
|
24
|
+
|
|
25
|
+
Check if a url is secure.
|
|
26
|
+
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [URLTargeting](./foundation-filters.urltargeting.md)
|
|
4
|
+
|
|
5
|
+
## URLTargeting interface
|
|
6
|
+
|
|
7
|
+
URLTargeting client filter DI interface.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export interface URLTargeting extends ClientFilter<URLTargetingParams>
|
|
13
|
+
```
|
|
14
|
+
**Extends:** [ClientFilter](./foundation-filters.clientfilter.md)<!-- --><[URLTargetingParams](./foundation-filters.urltargetingparams.md)<!-- -->>
|
|
15
|
+
|
|
16
|
+
## Methods
|
|
17
|
+
|
|
18
|
+
| Method | Description |
|
|
19
|
+
| --- | --- |
|
|
20
|
+
| [isSecure(url)](./foundation-filters.urltargeting.issecure.md) | |
|
|
21
|
+
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [urlTargetingFilter](./foundation-filters.urltargetingfilter.md)
|
|
4
|
+
|
|
5
|
+
## urlTargetingFilter() function
|
|
6
|
+
|
|
7
|
+
URLTargeting client filter function.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export declare function urlTargetingFilter(url: string, pattern?: RegExp, schemes?: string[], hosts?: string[], paths?: string[]): boolean;
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
| Parameter | Type | Description |
|
|
18
|
+
| --- | --- | --- |
|
|
19
|
+
| url | string | A url. |
|
|
20
|
+
| pattern | RegExp | _(Optional)_ A regex. |
|
|
21
|
+
| schemes | string\[\] | _(Optional)_ Schemes/protocols to target. |
|
|
22
|
+
| hosts | string\[\] | _(Optional)_ Hosts to target. |
|
|
23
|
+
| paths | string\[\] | _(Optional)_ Paths to target. |
|
|
24
|
+
|
|
25
|
+
**Returns:**
|
|
26
|
+
|
|
27
|
+
boolean
|
|
28
|
+
|
|
29
|
+
## Remarks
|
|
30
|
+
|
|
31
|
+
This will return true when the current URL matches on ANY of the parameters. If you wish to match on multiple parameters, consider chaining an array of urlTargeting filters together.
|
|
32
|
+
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [URLTargetingParams](./foundation-filters.urltargetingparams.md)
|
|
4
|
+
|
|
5
|
+
## URLTargetingParams type
|
|
6
|
+
|
|
7
|
+
URLTargetingParams
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export type URLTargetingParams = {
|
|
13
|
+
readonly url?: string;
|
|
14
|
+
readonly pattern?: RegExp;
|
|
15
|
+
readonly schemes?: string[];
|
|
16
|
+
readonly hosts?: string[];
|
|
17
|
+
readonly paths?: string[];
|
|
18
|
+
};
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Example
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
```json
|
|
25
|
+
{
|
|
26
|
+
"schemes": ["https"],
|
|
27
|
+
"hosts": ["neptx.genesislab.global", "neptune-uat2-axes-server2"]
|
|
28
|
+
}
|
|
29
|
+
```
|
|
30
|
+
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [URLTargetingSchema](./foundation-filters.urltargetingschema.md)
|
|
4
|
+
|
|
5
|
+
## URLTargetingSchema type
|
|
6
|
+
|
|
7
|
+
URLTargetingSchema type.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export type URLTargetingSchema = ClientFilterSchema<typeof ClientFilterName.urlTargeting, URLTargetingParams>;
|
|
13
|
+
```
|
|
14
|
+
**References:** [ClientFilterSchema](./foundation-filters.clientfilterschema.md)<!-- -->, [URLTargetingParams](./foundation-filters.urltargetingparams.md)
|
|
15
|
+
|
|
16
|
+
## Remarks
|
|
17
|
+
|
|
18
|
+
JSON schema type.
|
|
19
|
+
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [UserAgent](./foundation-filters.useragent.md) > [isSafari](./foundation-filters.useragent.issafari.md)
|
|
4
|
+
|
|
5
|
+
## UserAgent.isSafari property
|
|
6
|
+
|
|
7
|
+
**Signature:**
|
|
8
|
+
|
|
9
|
+
```typescript
|
|
10
|
+
readonly isSafari: boolean;
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Remarks
|
|
14
|
+
|
|
15
|
+
Is the user-agent safari.
|
|
16
|
+
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [UserAgent](./foundation-filters.useragent.md)
|
|
4
|
+
|
|
5
|
+
## UserAgent interface
|
|
6
|
+
|
|
7
|
+
UserAgent client filter DI interface.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export interface UserAgent extends ClientFilter<UserAgentParams>
|
|
13
|
+
```
|
|
14
|
+
**Extends:** [ClientFilter](./foundation-filters.clientfilter.md)<!-- --><[UserAgentParams](./foundation-filters.useragentparams.md)<!-- -->>
|
|
15
|
+
|
|
16
|
+
## Remarks
|
|
17
|
+
|
|
18
|
+
Simplifies access to runtime data / state contained within the DI container.
|
|
19
|
+
|
|
20
|
+
## Properties
|
|
21
|
+
|
|
22
|
+
| Property | Modifiers | Type | Description |
|
|
23
|
+
| --- | --- | --- | --- |
|
|
24
|
+
| [isSafari](./foundation-filters.useragent.issafari.md) | <code>readonly</code> | boolean | |
|
|
25
|
+
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [userAgentFilter](./foundation-filters.useragentfilter.md)
|
|
4
|
+
|
|
5
|
+
## userAgentFilter() function
|
|
6
|
+
|
|
7
|
+
UserAgent client filter function.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export declare function userAgentFilter(browsers?: string[], devices?: string[], oss?: string[], ua?: string): boolean;
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
| Parameter | Type | Description |
|
|
18
|
+
| --- | --- | --- |
|
|
19
|
+
| browsers | string\[\] | _(Optional)_ Browser names to target. |
|
|
20
|
+
| devices | string\[\] | _(Optional)_ Device types to target. |
|
|
21
|
+
| oss | string\[\] | _(Optional)_ Operating system names to target. |
|
|
22
|
+
| ua | string | _(Optional)_ User-agent string (required in nodejs environment). |
|
|
23
|
+
|
|
24
|
+
**Returns:**
|
|
25
|
+
|
|
26
|
+
boolean
|
|
27
|
+
|
|
28
|
+
## Remarks
|
|
29
|
+
|
|
30
|
+
See [https://github.com/faisalman/ua-parser-js](https://github.com/faisalman/ua-parser-js) for more information.
|
|
31
|
+
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [UserAgentParams](./foundation-filters.useragentparams.md)
|
|
4
|
+
|
|
5
|
+
## UserAgentParams type
|
|
6
|
+
|
|
7
|
+
UserAgentParams
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export type UserAgentParams = {
|
|
13
|
+
readonly browsers?: string[];
|
|
14
|
+
readonly devices?: string[];
|
|
15
|
+
readonly oss?: string[];
|
|
16
|
+
readonly ua?: string;
|
|
17
|
+
};
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## Example
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
```json
|
|
24
|
+
{
|
|
25
|
+
"browsers": ["Safari", "Firefox", "Chrome", "Chromium"],
|
|
26
|
+
"devices": ["mobile", "tablet"],
|
|
27
|
+
"oss": ["Mac OS", "Linux"]
|
|
28
|
+
}
|
|
29
|
+
```
|
|
30
|
+
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [UserAgentSchema](./foundation-filters.useragentschema.md)
|
|
4
|
+
|
|
5
|
+
## UserAgentSchema type
|
|
6
|
+
|
|
7
|
+
UserAgentSchema type.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export type UserAgentSchema = ClientFilterSchema<typeof ClientFilterName.userAgent, UserAgentParams>;
|
|
13
|
+
```
|
|
14
|
+
**References:** [ClientFilterSchema](./foundation-filters.clientfilterschema.md)<!-- -->, [UserAgentParams](./foundation-filters.useragentparams.md)
|
|
15
|
+
|
|
16
|
+
## Remarks
|
|
17
|
+
|
|
18
|
+
JSON schema type.
|
|
19
|
+
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [UserTargeting](./foundation-filters.usertargeting.md) > [hasAdminProfile](./foundation-filters.usertargeting.hasadminprofile.md)
|
|
4
|
+
|
|
5
|
+
## UserTargeting.hasAdminProfile property
|
|
6
|
+
|
|
7
|
+
**Signature:**
|
|
8
|
+
|
|
9
|
+
```typescript
|
|
10
|
+
readonly hasAdminProfile: boolean;
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Remarks
|
|
14
|
+
|
|
15
|
+
Has the user got the 'ADMIN' profile assigned.
|
|
16
|
+
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [UserTargeting](./foundation-filters.usertargeting.md) > [isLoggedIn](./foundation-filters.usertargeting.isloggedin.md)
|
|
4
|
+
|
|
5
|
+
## UserTargeting.isLoggedIn property
|
|
6
|
+
|
|
7
|
+
**Signature:**
|
|
8
|
+
|
|
9
|
+
```typescript
|
|
10
|
+
readonly isLoggedIn: boolean;
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Remarks
|
|
14
|
+
|
|
15
|
+
Has the user logged in, regardless of their identity.
|
|
16
|
+
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [UserTargeting](./foundation-filters.usertargeting.md)
|
|
4
|
+
|
|
5
|
+
## UserTargeting interface
|
|
6
|
+
|
|
7
|
+
UserTargeting client filter DI interface.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export interface UserTargeting extends ClientFilter<UserTargetingParams>
|
|
13
|
+
```
|
|
14
|
+
**Extends:** [ClientFilter](./foundation-filters.clientfilter.md)<!-- --><[UserTargetingParams](./foundation-filters.usertargetingparams.md)<!-- -->>
|
|
15
|
+
|
|
16
|
+
## Remarks
|
|
17
|
+
|
|
18
|
+
Simplifies access to runtime data / state contained within the DI container.
|
|
19
|
+
|
|
20
|
+
## Properties
|
|
21
|
+
|
|
22
|
+
| Property | Modifiers | Type | Description |
|
|
23
|
+
| --- | --- | --- | --- |
|
|
24
|
+
| [hasAdminProfile](./foundation-filters.usertargeting.hasadminprofile.md) | <code>readonly</code> | boolean | |
|
|
25
|
+
| [isLoggedIn](./foundation-filters.usertargeting.isloggedin.md) | <code>readonly</code> | boolean | |
|
|
26
|
+
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [userTargetingFilter](./foundation-filters.usertargetingfilter.md)
|
|
4
|
+
|
|
5
|
+
## userTargetingFilter() function
|
|
6
|
+
|
|
7
|
+
UserTargeting client filter function.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export declare function userTargetingFilter(user: User, usernames?: string[], profiles?: string[], permissions?: string[]): boolean;
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
| Parameter | Type | Description |
|
|
18
|
+
| --- | --- | --- |
|
|
19
|
+
| user | User | A user object. |
|
|
20
|
+
| usernames | string\[\] | _(Optional)_ Usernames to target. |
|
|
21
|
+
| profiles | string\[\] | _(Optional)_ Profiles to target. |
|
|
22
|
+
| permissions | string\[\] | _(Optional)_ Permissions to target. |
|
|
23
|
+
|
|
24
|
+
**Returns:**
|
|
25
|
+
|
|
26
|
+
boolean
|
|
27
|
+
|
|
28
|
+
## Remarks
|
|
29
|
+
|
|
30
|
+
This will return true when the current user matches on ANY of the parameters. If you wish to match on multiple parameters, consider chaining an array of userTargeting filters together.
|
|
31
|
+
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [UserTargetingParams](./foundation-filters.usertargetingparams.md)
|
|
4
|
+
|
|
5
|
+
## UserTargetingParams type
|
|
6
|
+
|
|
7
|
+
UserTargetingParams
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export type UserTargetingParams = {
|
|
13
|
+
readonly usernames?: string[];
|
|
14
|
+
readonly profiles?: string[];
|
|
15
|
+
readonly permissions?: string[];
|
|
16
|
+
};
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
## Example
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
```json
|
|
23
|
+
{
|
|
24
|
+
"usernames": ["JohnDoe"],
|
|
25
|
+
"profiles": ["ADMIN", "READ_WRITE_DEALER"],
|
|
26
|
+
"permissions": ["ExportClientDashboard"]
|
|
27
|
+
}
|
|
28
|
+
```
|
|
29
|
+
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@genesislcap/foundation-filters](./foundation-filters.md) > [UserTargetingSchema](./foundation-filters.usertargetingschema.md)
|
|
4
|
+
|
|
5
|
+
## UserTargetingSchema type
|
|
6
|
+
|
|
7
|
+
UserTargetingSchema type.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
export type UserTargetingSchema = ClientFilterSchema<typeof ClientFilterName.userTargeting, UserTargetingParams>;
|
|
13
|
+
```
|
|
14
|
+
**References:** [ClientFilterSchema](./foundation-filters.clientfilterschema.md)<!-- -->, [UserTargetingParams](./foundation-filters.usertargetingparams.md)
|
|
15
|
+
|
|
16
|
+
## Remarks
|
|
17
|
+
|
|
18
|
+
JSON schema type.
|
|
19
|
+
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md)
|
|
4
|
+
|
|
5
|
+
## API Reference
|
|
6
|
+
|
|
7
|
+
## Packages
|
|
8
|
+
|
|
9
|
+
| Package | Description |
|
|
10
|
+
| --- | --- |
|
|
11
|
+
| [@genesislcap/foundation-filters](./foundation-filters.md) | |
|
|
12
|
+
|