@genesislcap/web-core 14.225.1 → 14.225.2-alpha-a51f60c.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/dts/patterns/define.d.ts.map +1 -1
- package/dist/dts/tsdoc-metadata.json +1 -1
- package/dist/web-core.api.json +54 -15
- package/docs/api/web-core.definefactory.md +14 -1
- package/docs/api/web-core.md +1 -1
- package/package.json +4 -4
- /package/docs/{api-report.md → api-report.md.api.md} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"define.d.ts","sourceRoot":"","sources":["../../../src/patterns/define.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,+BAA+B,EAAE,MAAM,SAAS,CAAC;AAEzF;;GAEG;AACH,MAAM,MAAM,cAAc,CAAC,KAAK,IAAI,CAAC,UAAU,EAAE,+BAA+B,KAAK,KAAK,CAAC;AAE3F;;GAEG;AACH,MAAM,MAAM,mBAAmB,GAAG,CAChC,QAAQ,EAAE,+BAA+B,KACtC,+BAA+B,CAAC;AASrC;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,eAAO,MAAM,aAAa,
|
|
1
|
+
{"version":3,"file":"define.d.ts","sourceRoot":"","sources":["../../../src/patterns/define.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,+BAA+B,EAAE,MAAM,SAAS,CAAC;AAEzF;;GAEG;AACH,MAAM,MAAM,cAAc,CAAC,KAAK,IAAI,CAAC,UAAU,EAAE,+BAA+B,KAAK,KAAK,CAAC;AAE3F;;GAEG;AACH,MAAM,MAAM,mBAAmB,GAAG,CAChC,QAAQ,EAAE,+BAA+B,KACtC,+BAA+B,CAAC;AASrC;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,eAAO,MAAM,aAAa,sDAEhB,KAAK,mBACM,mBAAmB,GAAG,+BAA+B,KACrE,eAAe,KAAK,CAOtB,CAAC"}
|
package/dist/web-core.api.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"metadata": {
|
|
3
3
|
"toolPackage": "@microsoft/api-extractor",
|
|
4
|
-
"toolVersion": "7.
|
|
4
|
+
"toolVersion": "7.48.0",
|
|
5
5
|
"schemaVersion": 1011,
|
|
6
6
|
"oldestForwardsCompatibleVersion": 1001,
|
|
7
7
|
"tsdocConfig": {
|
|
@@ -260,17 +260,13 @@
|
|
|
260
260
|
}
|
|
261
261
|
},
|
|
262
262
|
{
|
|
263
|
-
"kind": "
|
|
264
|
-
"canonicalReference": "@genesislcap/web-core!defineFactory:
|
|
263
|
+
"kind": "Function",
|
|
264
|
+
"canonicalReference": "@genesislcap/web-core!defineFactory:function(1)",
|
|
265
265
|
"docComment": "/**\n * Defines a platform custom element based on the provided type and definition.\n *\n * @param Type - The custom element Type / Class to define.\n *\n * @param overriderOrBase - A function that merges definitions, or the base definition if custom merging is not needed.\n *\n * @returns The type class.\n *\n * @example\n *\n * An example using custom definition merge logic, useful if you need to impose hard restrictions.\n * ```ts\n * const definitionOverrider = (definition) => ({\n * ...baseDefinition,\n * ...definition,\n * styles: baseDefinition.styles,\n * shadowOptions: {\n * mode: 'closed,\n * },\n * });\n * export const define = defineFactory(LoginForm, definitionOverrider);\n * ```\n *\n * @example\n *\n * You can provide the base definition if you're happy with the default spread operator merge logic.\n * ```ts\n * export const define = defineFactory(LoginForm, baseDefinition);\n * ```\n *\n * @beta\n */\n",
|
|
266
266
|
"excerptTokens": [
|
|
267
267
|
{
|
|
268
268
|
"kind": "Content",
|
|
269
|
-
"text": "defineFactory: "
|
|
270
|
-
},
|
|
271
|
-
{
|
|
272
|
-
"kind": "Content",
|
|
273
|
-
"text": "<TType extends "
|
|
269
|
+
"text": "defineFactory: <TType extends "
|
|
274
270
|
},
|
|
275
271
|
{
|
|
276
272
|
"kind": "Reference",
|
|
@@ -288,7 +284,19 @@
|
|
|
288
284
|
},
|
|
289
285
|
{
|
|
290
286
|
"kind": "Content",
|
|
291
|
-
"text": "
|
|
287
|
+
"text": ">"
|
|
288
|
+
},
|
|
289
|
+
{
|
|
290
|
+
"kind": "Content",
|
|
291
|
+
"text": ">(Type: "
|
|
292
|
+
},
|
|
293
|
+
{
|
|
294
|
+
"kind": "Content",
|
|
295
|
+
"text": "TType"
|
|
296
|
+
},
|
|
297
|
+
{
|
|
298
|
+
"kind": "Content",
|
|
299
|
+
"text": ", overriderOrBase: "
|
|
292
300
|
},
|
|
293
301
|
{
|
|
294
302
|
"kind": "Reference",
|
|
@@ -319,13 +327,44 @@
|
|
|
319
327
|
}
|
|
320
328
|
],
|
|
321
329
|
"fileUrlPath": "src/patterns/define.ts",
|
|
322
|
-
"
|
|
330
|
+
"returnTypeTokenRange": {
|
|
331
|
+
"startIndex": 12,
|
|
332
|
+
"endIndex": 14
|
|
333
|
+
},
|
|
323
334
|
"releaseTag": "Beta",
|
|
324
|
-
"
|
|
325
|
-
"
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
335
|
+
"overloadIndex": 1,
|
|
336
|
+
"parameters": [
|
|
337
|
+
{
|
|
338
|
+
"parameterName": "Type",
|
|
339
|
+
"parameterTypeTokenRange": {
|
|
340
|
+
"startIndex": 6,
|
|
341
|
+
"endIndex": 7
|
|
342
|
+
},
|
|
343
|
+
"isOptional": false
|
|
344
|
+
},
|
|
345
|
+
{
|
|
346
|
+
"parameterName": "overriderOrBase",
|
|
347
|
+
"parameterTypeTokenRange": {
|
|
348
|
+
"startIndex": 8,
|
|
349
|
+
"endIndex": 11
|
|
350
|
+
},
|
|
351
|
+
"isOptional": false
|
|
352
|
+
}
|
|
353
|
+
],
|
|
354
|
+
"typeParameters": [
|
|
355
|
+
{
|
|
356
|
+
"typeParameterName": "TType",
|
|
357
|
+
"constraintTokenRange": {
|
|
358
|
+
"startIndex": 1,
|
|
359
|
+
"endIndex": 5
|
|
360
|
+
},
|
|
361
|
+
"defaultTypeTokenRange": {
|
|
362
|
+
"startIndex": 0,
|
|
363
|
+
"endIndex": 0
|
|
364
|
+
}
|
|
365
|
+
}
|
|
366
|
+
],
|
|
367
|
+
"name": "defineFactory"
|
|
329
368
|
},
|
|
330
369
|
{
|
|
331
370
|
"kind": "TypeAlias",
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
[Home](./index.md) > [@genesislcap/web-core](./web-core.md) > [defineFactory](./web-core.definefactory.md)
|
|
4
4
|
|
|
5
|
-
## defineFactory
|
|
5
|
+
## defineFactory() function
|
|
6
6
|
|
|
7
7
|
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
8
8
|
>
|
|
@@ -15,6 +15,19 @@ Defines a platform custom element based on the provided type and definition.
|
|
|
15
15
|
defineFactory: <TType extends Constructable<GenesisElement>>(Type: TType, overriderOrBase: DefinitionOverrider | PartialGenesisElementDefinition) => DefineFunction<TType>
|
|
16
16
|
```
|
|
17
17
|
|
|
18
|
+
## Parameters
|
|
19
|
+
|
|
20
|
+
| Parameter | Type | Description |
|
|
21
|
+
| --- | --- | --- |
|
|
22
|
+
| Type | TType | The custom element Type / Class to define. |
|
|
23
|
+
| overriderOrBase | [DefinitionOverrider](./web-core.definitionoverrider.md) \| PartialGenesisElementDefinition | A function that merges definitions, or the base definition if custom merging is not needed. |
|
|
24
|
+
|
|
25
|
+
**Returns:**
|
|
26
|
+
|
|
27
|
+
[DefineFunction](./web-core.definefunction.md)<!-- --><TType>
|
|
28
|
+
|
|
29
|
+
The type class.
|
|
30
|
+
|
|
18
31
|
## Example 1
|
|
19
32
|
|
|
20
33
|
An example using custom definition merge logic, useful if you need to impose hard restrictions.
|
package/docs/api/web-core.md
CHANGED
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
| Function | Description |
|
|
10
10
|
| --- | --- |
|
|
11
|
+
| [defineFactory(Type, overriderOrBase)](./web-core.definefactory.md) | **_(BETA)_** Defines a platform custom element based on the provided type and definition. |
|
|
11
12
|
| [deprecatedAttr(config)](./web-core.deprecatedattr.md) | Decorator: Specifies an HTML attribute. |
|
|
12
13
|
| [deprecatedAttr(target, prop)](./web-core.deprecatedattr_1.md) | Decorator: Specifies an HTML attribute. |
|
|
13
14
|
| [sync(binding, conversionType, eventName, keyAttr)](./web-core.sync.md) | Creates a synchronization directive that binds a data source to an HTML element, |
|
|
@@ -19,7 +20,6 @@
|
|
|
19
20
|
| Variable | Description |
|
|
20
21
|
| --- | --- |
|
|
21
22
|
| [defaultEventMap](./web-core.defaulteventmap.md) | A map that associates specific HTML element tags with their corresponding default event names. |
|
|
22
|
-
| [defineFactory](./web-core.definefactory.md) | **_(BETA)_** Defines a platform custom element based on the provided type and definition. |
|
|
23
23
|
|
|
24
24
|
## Type Aliases
|
|
25
25
|
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@genesislcap/web-core",
|
|
3
3
|
"description": "Genesis Foundation Web Core",
|
|
4
|
-
"version": "14.225.
|
|
4
|
+
"version": "14.225.2-alpha-a51f60c.0",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"license": "SEE LICENSE IN license.txt",
|
|
7
7
|
"main": "dist/esm/index.js",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
},
|
|
24
24
|
"devDependencies": {
|
|
25
25
|
"@microsoft/api-documenter": "^7.19.13",
|
|
26
|
-
"@microsoft/api-extractor": "7.
|
|
26
|
+
"@microsoft/api-extractor": "7.48.0",
|
|
27
27
|
"rimraf": "^5.0.0"
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
"@microsoft/fast-foundation": "2.49.6",
|
|
34
34
|
"@microsoft/fast-router": "0.4.8",
|
|
35
35
|
"@microsoft/fast-web-utilities": "5.4.1",
|
|
36
|
-
"tslib": "
|
|
36
|
+
"tslib": "2.8.1"
|
|
37
37
|
},
|
|
38
38
|
"repository": {
|
|
39
39
|
"type": "git",
|
|
@@ -43,5 +43,5 @@
|
|
|
43
43
|
"publishConfig": {
|
|
44
44
|
"access": "public"
|
|
45
45
|
},
|
|
46
|
-
"gitHead": "
|
|
46
|
+
"gitHead": "4e2f49c901b8ee0f06d4df645c355d7f6c7bde70"
|
|
47
47
|
}
|
|
File without changes
|