@itwin/core-common 5.3.0-dev.12 → 5.3.0-dev.16
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/CHANGELOG.md +11 -1
- package/lib/cjs/annotation/TextField.d.ts +4 -2
- package/lib/cjs/annotation/TextField.d.ts.map +1 -1
- package/lib/cjs/annotation/TextField.js.map +1 -1
- package/lib/esm/annotation/TextField.d.ts +4 -2
- package/lib/esm/annotation/TextField.d.ts.map +1 -1
- package/lib/esm/annotation/TextField.js.map +1 -1
- package/package.json +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,16 @@
|
|
|
1
1
|
# Change Log - @itwin/core-common
|
|
2
2
|
|
|
3
|
-
This log was last generated on
|
|
3
|
+
This log was last generated on Fri, 10 Oct 2025 14:50:50 GMT and should not be manually modified.
|
|
4
|
+
|
|
5
|
+
## 5.2.2
|
|
6
|
+
Fri, 10 Oct 2025 14:49:15 GMT
|
|
7
|
+
|
|
8
|
+
_Version update only_
|
|
9
|
+
|
|
10
|
+
## 5.2.1
|
|
11
|
+
Thu, 09 Oct 2025 17:10:26 GMT
|
|
12
|
+
|
|
13
|
+
_Version update only_
|
|
4
14
|
|
|
5
15
|
## 5.2.0
|
|
6
16
|
Wed, 01 Oct 2025 20:22:54 GMT
|
|
@@ -40,8 +40,10 @@ export interface FieldPropertyPath {
|
|
|
40
40
|
accessors?: Array<string | number>;
|
|
41
41
|
}
|
|
42
42
|
/** Describes the source of the property value against which a [[FieldPropertyPath]] is evaluated.
|
|
43
|
-
* A field property is always hosted by an [Element]($backend). It may
|
|
44
|
-
*
|
|
43
|
+
* A field property is always hosted by an [Element]($backend). It may refer to a property belonging to any of the following:
|
|
44
|
+
* - The element's BIS class itself;
|
|
45
|
+
* - One of the element's [ElementAspect]($backend)s;
|
|
46
|
+
* - Or an [EC view]($docs/learning/ECSqlReference/Views.md) with the same ECInstanceId as the element.
|
|
45
47
|
* The [[schemaName]] and [[className]] should always identify the exact class that contains [[FieldPropertyPath.propertyName]] - not a subclass thereof.
|
|
46
48
|
* @beta
|
|
47
49
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextField.d.ts","sourceRoot":"","sources":["../../../src/annotation/TextField.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAEjD;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,iBAAiB,GAAG,UAAU,GAAG,YAAY,GAAG,QAAQ,GAAG,SAAS,GAAG,UAAU,GAAG,UAAU,GAAG,aAAa,CAAC;AAE3H;;;;;;;;;;;;;;;GAeG;AACH,MAAM,WAAW,iBAAiB;IAChC,qGAAqG;IACrG,YAAY,EAAE,MAAM,CAAC;IACrB,kHAAkH;IAClH,SAAS,CAAC,EAAE,KAAK,CAAC,MAAM,GAAG,MAAM,CAAC,CAAC;CACpC;AAED
|
|
1
|
+
{"version":3,"file":"TextField.d.ts","sourceRoot":"","sources":["../../../src/annotation/TextField.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAEjD;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,iBAAiB,GAAG,UAAU,GAAG,YAAY,GAAG,QAAQ,GAAG,SAAS,GAAG,UAAU,GAAG,UAAU,GAAG,aAAa,CAAC;AAE3H;;;;;;;;;;;;;;;GAeG;AACH,MAAM,WAAW,iBAAiB;IAChC,qGAAqG;IACrG,YAAY,EAAE,MAAM,CAAC;IACrB,kHAAkH;IAClH,SAAS,CAAC,EAAE,KAAK,CAAC,MAAM,GAAG,MAAM,CAAC,CAAC;CACpC;AAED;;;;;;;GAOG;AACH,MAAM,WAAW,iBAAiB;IAChC,iEAAiE;IACjE,SAAS,EAAE,UAAU,CAAC;IACtB,+EAA+E;IAC/E,UAAU,EAAE,MAAM,CAAC;IACnB,6HAA6H;IAC7H,SAAS,EAAE,MAAM,CAAC;CACnB;AAED;;;GAGG;AACH,MAAM,MAAM,SAAS,GAAG,OAAO,GAAG,OAAO,GAAG,OAAO,CAAC;AAEpD;;GAEG;AACH,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,MAAM,CAAC,EAAE,IAAI,CAAC,4BAA4B,CAAC;IAC3C,mDAAmD;IACnD,aAAa,CAAC,EAAE,IAAI,CAAC,qBAAqB,CAAC;CAC5C;AAED;;;GAGG;AACH,MAAM,WAAW,kBAAkB;IACjC,8FAA8F;IAC9F,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,6FAA6F;IAC7F,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,iDAAiD;IACjD,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,+DAA+D;IAC/D,QAAQ,CAAC,EAAE,0BAA0B,CAAC;CACvC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextField.js","sourceRoot":"","sources":["../../../src/annotation/TextField.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG","sourcesContent":["/*----------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Annotation\r\n */\r\n\r\nimport { Id64String } from \"@itwin/core-bentley\";\r\n\r\n/** Enumerates the different kinds of [Property]($ecschema-metadata) values that can be used as the basis for a [[FieldRun]]'s display string.\r\n * A field's property type is derived from the property's [PrimitiveType]($ecschema-metadata) and other attributes like its [PrimitiveOrEnumPropertyBase.extendedTypeName]($ecschema-metadata).\r\n * The conversion of the raw property value into a display string can be customized by different [[FieldFormatOptions]] based on its type.\r\n * The following types are currently recognized:\r\n * - \"quantity\": an often-unitized scalar value like a distance or area, formatted using a quantity [Format]($core-quantity).\r\n * - \"coordinate\": a 2- or 3-dimensional point, with each component formatted as a \"quantity\".\r\n * - \"boolean\": a true or false value.\r\n * - \"datetime\": an ECMAScript [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date).\r\n * - \"int-enum\": an integer [EnumerationProperty]($ecschema-metadata) formatted using the enum value's display label.\r\n * - \"string-enum\": a string [EnumerationProperty]($ecschema-metadata) formatted using the enum value's display label.\r\n * - \"string\": a value convertible to a string.\r\n * @note Currently, only formatting of \"string\" and \"datetime\" types is implemented. Other types are converted to and formatted as \"string\".\r\n * @beta\r\n */\r\nexport type FieldPropertyType = \"quantity\" | \"coordinate\" | \"string\" | \"boolean\" | \"datetime\" | \"int-enum\" | \"string-enum\";\r\n\r\n/** A chain of property accesses that resolves to a primitive value that forms the basis of the displayed content\r\n * of a [[FieldRun]].\r\n * The simplest property paths consist of a [[propertyName]] and nothing else, where `propertyName` identifies\r\n * a primitive property.\r\n * If `propertyName` identifies a struct or array property, then additional [[accessors]] are required to identify the specific value.\r\n * Some examples:\r\n * ```\r\n * | Access String | propertyName | accessors |\r\n * | ------------- | ------------ | --------- |\r\n * | name | \"name\" | undefined |\r\n * | spouse.name | \"spouse\" | [name] |\r\n * | colors[2] | \"colors\" | [2] |\r\n * | spouse.favoriteRestaurants[1].address | \"spouse\" | [\"favoriteRestaurants\", 1, \"address\"] |\r\n * ```\r\n * @beta\r\n */\r\nexport interface FieldPropertyPath {\r\n /** The name of the BIS property of the [[FieldPropertyHost]] that serves as the root of the path. */\r\n propertyName: string;\r\n /** Property names and/or array indices describing the path from [[propertyName]] to the ultimate BIS property. */\r\n accessors?: Array<string | number>;\r\n}\r\n\r\n/** Describes the source of the property value against which a [[FieldPropertyPath]] is evaluated.\r\n * A field property is always hosted by an [Element]($backend). It may
|
|
1
|
+
{"version":3,"file":"TextField.js","sourceRoot":"","sources":["../../../src/annotation/TextField.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG","sourcesContent":["/*----------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Annotation\r\n */\r\n\r\nimport { Id64String } from \"@itwin/core-bentley\";\r\n\r\n/** Enumerates the different kinds of [Property]($ecschema-metadata) values that can be used as the basis for a [[FieldRun]]'s display string.\r\n * A field's property type is derived from the property's [PrimitiveType]($ecschema-metadata) and other attributes like its [PrimitiveOrEnumPropertyBase.extendedTypeName]($ecschema-metadata).\r\n * The conversion of the raw property value into a display string can be customized by different [[FieldFormatOptions]] based on its type.\r\n * The following types are currently recognized:\r\n * - \"quantity\": an often-unitized scalar value like a distance or area, formatted using a quantity [Format]($core-quantity).\r\n * - \"coordinate\": a 2- or 3-dimensional point, with each component formatted as a \"quantity\".\r\n * - \"boolean\": a true or false value.\r\n * - \"datetime\": an ECMAScript [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date).\r\n * - \"int-enum\": an integer [EnumerationProperty]($ecschema-metadata) formatted using the enum value's display label.\r\n * - \"string-enum\": a string [EnumerationProperty]($ecschema-metadata) formatted using the enum value's display label.\r\n * - \"string\": a value convertible to a string.\r\n * @note Currently, only formatting of \"string\" and \"datetime\" types is implemented. Other types are converted to and formatted as \"string\".\r\n * @beta\r\n */\r\nexport type FieldPropertyType = \"quantity\" | \"coordinate\" | \"string\" | \"boolean\" | \"datetime\" | \"int-enum\" | \"string-enum\";\r\n\r\n/** A chain of property accesses that resolves to a primitive value that forms the basis of the displayed content\r\n * of a [[FieldRun]].\r\n * The simplest property paths consist of a [[propertyName]] and nothing else, where `propertyName` identifies\r\n * a primitive property.\r\n * If `propertyName` identifies a struct or array property, then additional [[accessors]] are required to identify the specific value.\r\n * Some examples:\r\n * ```\r\n * | Access String | propertyName | accessors |\r\n * | ------------- | ------------ | --------- |\r\n * | name | \"name\" | undefined |\r\n * | spouse.name | \"spouse\" | [name] |\r\n * | colors[2] | \"colors\" | [2] |\r\n * | spouse.favoriteRestaurants[1].address | \"spouse\" | [\"favoriteRestaurants\", 1, \"address\"] |\r\n * ```\r\n * @beta\r\n */\r\nexport interface FieldPropertyPath {\r\n /** The name of the BIS property of the [[FieldPropertyHost]] that serves as the root of the path. */\r\n propertyName: string;\r\n /** Property names and/or array indices describing the path from [[propertyName]] to the ultimate BIS property. */\r\n accessors?: Array<string | number>;\r\n}\r\n\r\n/** Describes the source of the property value against which a [[FieldPropertyPath]] is evaluated.\r\n * A field property is always hosted by an [Element]($backend). It may refer to a property belonging to any of the following:\r\n * - The element's BIS class itself;\r\n * - One of the element's [ElementAspect]($backend)s;\r\n * - Or an [EC view]($docs/learning/ECSqlReference/Views.md) with the same ECInstanceId as the element.\r\n * The [[schemaName]] and [[className]] should always identify the exact class that contains [[FieldPropertyPath.propertyName]] - not a subclass thereof.\r\n * @beta\r\n */\r\nexport interface FieldPropertyHost {\r\n /** The Id of the [Element]($backend) that hosts the property. */\r\n elementId: Id64String;\r\n /** The name of the schema containing the class identified by [[className]]. */\r\n schemaName: string;\r\n /** The name of the exact class (not a subclass) containing the property identified by [[FieldPropertyPath.propertyName]]. */\r\n className: string;\r\n}\r\n\r\n/** As part of [[FieldFormatOptions]], specifies how to modify the case of the display string.\r\n * \"as-is\" leaves it unmodified. \"upper\" and \"lower\" convert it to all upper-case or all lower-case, respectively.\r\n * @beta\r\n */\r\nexport type FieldCase = \"as-is\" | \"upper\" | \"lower\";\r\n\r\n/** As part of a [[FieldFormatOptions]], specifies how to format properties of [[FieldPropertyType]] \"datetime\".\r\n * @beta\r\n */\r\nexport interface DateTimeFieldFormatOptions {\r\n /** The locale with which to localize the display string.\r\n * Default: \"en-US\".\r\n */\r\n locale?: Intl.UnicodeBCP47LocaleIdentifier;\r\n /** Describes how to produce the display string. */\r\n formatOptions?: Intl.DateTimeFormatOptions;\r\n}\r\n\r\n/** Customizes how to format the raw property value resolved by a [[FieldPropertyPath]] into a [[FieldRun]]'s display string.\r\n * The exact options used depend upon the [[FieldPropertyType]].\r\n * @beta\r\n */\r\nexport interface FieldFormatOptions {\r\n /** A string inserted before the formatted string. This string is not affected by [[case]]. */\r\n prefix?: string;\r\n /** A string inserted after the formatted string. This string is not affected by [[case]]. */\r\n suffix?: string;\r\n /** Modifies the case of the formatted string. */\r\n case?: FieldCase;\r\n /** Formatting options for [[FieldPropertyType]] \"datetime\". */\r\n dateTime?: DateTimeFieldFormatOptions;\r\n}\r\n"]}
|
|
@@ -40,8 +40,10 @@ export interface FieldPropertyPath {
|
|
|
40
40
|
accessors?: Array<string | number>;
|
|
41
41
|
}
|
|
42
42
|
/** Describes the source of the property value against which a [[FieldPropertyPath]] is evaluated.
|
|
43
|
-
* A field property is always hosted by an [Element]($backend). It may
|
|
44
|
-
*
|
|
43
|
+
* A field property is always hosted by an [Element]($backend). It may refer to a property belonging to any of the following:
|
|
44
|
+
* - The element's BIS class itself;
|
|
45
|
+
* - One of the element's [ElementAspect]($backend)s;
|
|
46
|
+
* - Or an [EC view]($docs/learning/ECSqlReference/Views.md) with the same ECInstanceId as the element.
|
|
45
47
|
* The [[schemaName]] and [[className]] should always identify the exact class that contains [[FieldPropertyPath.propertyName]] - not a subclass thereof.
|
|
46
48
|
* @beta
|
|
47
49
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextField.d.ts","sourceRoot":"","sources":["../../../src/annotation/TextField.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAEjD;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,iBAAiB,GAAG,UAAU,GAAG,YAAY,GAAG,QAAQ,GAAG,SAAS,GAAG,UAAU,GAAG,UAAU,GAAG,aAAa,CAAC;AAE3H;;;;;;;;;;;;;;;GAeG;AACH,MAAM,WAAW,iBAAiB;IAChC,qGAAqG;IACrG,YAAY,EAAE,MAAM,CAAC;IACrB,kHAAkH;IAClH,SAAS,CAAC,EAAE,KAAK,CAAC,MAAM,GAAG,MAAM,CAAC,CAAC;CACpC;AAED
|
|
1
|
+
{"version":3,"file":"TextField.d.ts","sourceRoot":"","sources":["../../../src/annotation/TextField.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAEjD;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,iBAAiB,GAAG,UAAU,GAAG,YAAY,GAAG,QAAQ,GAAG,SAAS,GAAG,UAAU,GAAG,UAAU,GAAG,aAAa,CAAC;AAE3H;;;;;;;;;;;;;;;GAeG;AACH,MAAM,WAAW,iBAAiB;IAChC,qGAAqG;IACrG,YAAY,EAAE,MAAM,CAAC;IACrB,kHAAkH;IAClH,SAAS,CAAC,EAAE,KAAK,CAAC,MAAM,GAAG,MAAM,CAAC,CAAC;CACpC;AAED;;;;;;;GAOG;AACH,MAAM,WAAW,iBAAiB;IAChC,iEAAiE;IACjE,SAAS,EAAE,UAAU,CAAC;IACtB,+EAA+E;IAC/E,UAAU,EAAE,MAAM,CAAC;IACnB,6HAA6H;IAC7H,SAAS,EAAE,MAAM,CAAC;CACnB;AAED;;;GAGG;AACH,MAAM,MAAM,SAAS,GAAG,OAAO,GAAG,OAAO,GAAG,OAAO,CAAC;AAEpD;;GAEG;AACH,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,MAAM,CAAC,EAAE,IAAI,CAAC,4BAA4B,CAAC;IAC3C,mDAAmD;IACnD,aAAa,CAAC,EAAE,IAAI,CAAC,qBAAqB,CAAC;CAC5C;AAED;;;GAGG;AACH,MAAM,WAAW,kBAAkB;IACjC,8FAA8F;IAC9F,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,6FAA6F;IAC7F,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,iDAAiD;IACjD,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,+DAA+D;IAC/D,QAAQ,CAAC,EAAE,0BAA0B,CAAC;CACvC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextField.js","sourceRoot":"","sources":["../../../src/annotation/TextField.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG","sourcesContent":["/*----------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Annotation\r\n */\r\n\r\nimport { Id64String } from \"@itwin/core-bentley\";\r\n\r\n/** Enumerates the different kinds of [Property]($ecschema-metadata) values that can be used as the basis for a [[FieldRun]]'s display string.\r\n * A field's property type is derived from the property's [PrimitiveType]($ecschema-metadata) and other attributes like its [PrimitiveOrEnumPropertyBase.extendedTypeName]($ecschema-metadata).\r\n * The conversion of the raw property value into a display string can be customized by different [[FieldFormatOptions]] based on its type.\r\n * The following types are currently recognized:\r\n * - \"quantity\": an often-unitized scalar value like a distance or area, formatted using a quantity [Format]($core-quantity).\r\n * - \"coordinate\": a 2- or 3-dimensional point, with each component formatted as a \"quantity\".\r\n * - \"boolean\": a true or false value.\r\n * - \"datetime\": an ECMAScript [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date).\r\n * - \"int-enum\": an integer [EnumerationProperty]($ecschema-metadata) formatted using the enum value's display label.\r\n * - \"string-enum\": a string [EnumerationProperty]($ecschema-metadata) formatted using the enum value's display label.\r\n * - \"string\": a value convertible to a string.\r\n * @note Currently, only formatting of \"string\" and \"datetime\" types is implemented. Other types are converted to and formatted as \"string\".\r\n * @beta\r\n */\r\nexport type FieldPropertyType = \"quantity\" | \"coordinate\" | \"string\" | \"boolean\" | \"datetime\" | \"int-enum\" | \"string-enum\";\r\n\r\n/** A chain of property accesses that resolves to a primitive value that forms the basis of the displayed content\r\n * of a [[FieldRun]].\r\n * The simplest property paths consist of a [[propertyName]] and nothing else, where `propertyName` identifies\r\n * a primitive property.\r\n * If `propertyName` identifies a struct or array property, then additional [[accessors]] are required to identify the specific value.\r\n * Some examples:\r\n * ```\r\n * | Access String | propertyName | accessors |\r\n * | ------------- | ------------ | --------- |\r\n * | name | \"name\" | undefined |\r\n * | spouse.name | \"spouse\" | [name] |\r\n * | colors[2] | \"colors\" | [2] |\r\n * | spouse.favoriteRestaurants[1].address | \"spouse\" | [\"favoriteRestaurants\", 1, \"address\"] |\r\n * ```\r\n * @beta\r\n */\r\nexport interface FieldPropertyPath {\r\n /** The name of the BIS property of the [[FieldPropertyHost]] that serves as the root of the path. */\r\n propertyName: string;\r\n /** Property names and/or array indices describing the path from [[propertyName]] to the ultimate BIS property. */\r\n accessors?: Array<string | number>;\r\n}\r\n\r\n/** Describes the source of the property value against which a [[FieldPropertyPath]] is evaluated.\r\n * A field property is always hosted by an [Element]($backend). It may
|
|
1
|
+
{"version":3,"file":"TextField.js","sourceRoot":"","sources":["../../../src/annotation/TextField.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG","sourcesContent":["/*----------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Annotation\r\n */\r\n\r\nimport { Id64String } from \"@itwin/core-bentley\";\r\n\r\n/** Enumerates the different kinds of [Property]($ecschema-metadata) values that can be used as the basis for a [[FieldRun]]'s display string.\r\n * A field's property type is derived from the property's [PrimitiveType]($ecschema-metadata) and other attributes like its [PrimitiveOrEnumPropertyBase.extendedTypeName]($ecschema-metadata).\r\n * The conversion of the raw property value into a display string can be customized by different [[FieldFormatOptions]] based on its type.\r\n * The following types are currently recognized:\r\n * - \"quantity\": an often-unitized scalar value like a distance or area, formatted using a quantity [Format]($core-quantity).\r\n * - \"coordinate\": a 2- or 3-dimensional point, with each component formatted as a \"quantity\".\r\n * - \"boolean\": a true or false value.\r\n * - \"datetime\": an ECMAScript [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date).\r\n * - \"int-enum\": an integer [EnumerationProperty]($ecschema-metadata) formatted using the enum value's display label.\r\n * - \"string-enum\": a string [EnumerationProperty]($ecschema-metadata) formatted using the enum value's display label.\r\n * - \"string\": a value convertible to a string.\r\n * @note Currently, only formatting of \"string\" and \"datetime\" types is implemented. Other types are converted to and formatted as \"string\".\r\n * @beta\r\n */\r\nexport type FieldPropertyType = \"quantity\" | \"coordinate\" | \"string\" | \"boolean\" | \"datetime\" | \"int-enum\" | \"string-enum\";\r\n\r\n/** A chain of property accesses that resolves to a primitive value that forms the basis of the displayed content\r\n * of a [[FieldRun]].\r\n * The simplest property paths consist of a [[propertyName]] and nothing else, where `propertyName` identifies\r\n * a primitive property.\r\n * If `propertyName` identifies a struct or array property, then additional [[accessors]] are required to identify the specific value.\r\n * Some examples:\r\n * ```\r\n * | Access String | propertyName | accessors |\r\n * | ------------- | ------------ | --------- |\r\n * | name | \"name\" | undefined |\r\n * | spouse.name | \"spouse\" | [name] |\r\n * | colors[2] | \"colors\" | [2] |\r\n * | spouse.favoriteRestaurants[1].address | \"spouse\" | [\"favoriteRestaurants\", 1, \"address\"] |\r\n * ```\r\n * @beta\r\n */\r\nexport interface FieldPropertyPath {\r\n /** The name of the BIS property of the [[FieldPropertyHost]] that serves as the root of the path. */\r\n propertyName: string;\r\n /** Property names and/or array indices describing the path from [[propertyName]] to the ultimate BIS property. */\r\n accessors?: Array<string | number>;\r\n}\r\n\r\n/** Describes the source of the property value against which a [[FieldPropertyPath]] is evaluated.\r\n * A field property is always hosted by an [Element]($backend). It may refer to a property belonging to any of the following:\r\n * - The element's BIS class itself;\r\n * - One of the element's [ElementAspect]($backend)s;\r\n * - Or an [EC view]($docs/learning/ECSqlReference/Views.md) with the same ECInstanceId as the element.\r\n * The [[schemaName]] and [[className]] should always identify the exact class that contains [[FieldPropertyPath.propertyName]] - not a subclass thereof.\r\n * @beta\r\n */\r\nexport interface FieldPropertyHost {\r\n /** The Id of the [Element]($backend) that hosts the property. */\r\n elementId: Id64String;\r\n /** The name of the schema containing the class identified by [[className]]. */\r\n schemaName: string;\r\n /** The name of the exact class (not a subclass) containing the property identified by [[FieldPropertyPath.propertyName]]. */\r\n className: string;\r\n}\r\n\r\n/** As part of [[FieldFormatOptions]], specifies how to modify the case of the display string.\r\n * \"as-is\" leaves it unmodified. \"upper\" and \"lower\" convert it to all upper-case or all lower-case, respectively.\r\n * @beta\r\n */\r\nexport type FieldCase = \"as-is\" | \"upper\" | \"lower\";\r\n\r\n/** As part of a [[FieldFormatOptions]], specifies how to format properties of [[FieldPropertyType]] \"datetime\".\r\n * @beta\r\n */\r\nexport interface DateTimeFieldFormatOptions {\r\n /** The locale with which to localize the display string.\r\n * Default: \"en-US\".\r\n */\r\n locale?: Intl.UnicodeBCP47LocaleIdentifier;\r\n /** Describes how to produce the display string. */\r\n formatOptions?: Intl.DateTimeFormatOptions;\r\n}\r\n\r\n/** Customizes how to format the raw property value resolved by a [[FieldPropertyPath]] into a [[FieldRun]]'s display string.\r\n * The exact options used depend upon the [[FieldPropertyType]].\r\n * @beta\r\n */\r\nexport interface FieldFormatOptions {\r\n /** A string inserted before the formatted string. This string is not affected by [[case]]. */\r\n prefix?: string;\r\n /** A string inserted after the formatted string. This string is not affected by [[case]]. */\r\n suffix?: string;\r\n /** Modifies the case of the formatted string. */\r\n case?: FieldCase;\r\n /** Formatting options for [[FieldPropertyType]] \"datetime\". */\r\n dateTime?: DateTimeFieldFormatOptions;\r\n}\r\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@itwin/core-common",
|
|
3
|
-
"version": "5.3.0-dev.
|
|
3
|
+
"version": "5.3.0-dev.16",
|
|
4
4
|
"description": "iTwin.js components common to frontend and backend",
|
|
5
5
|
"main": "lib/cjs/core-common.js",
|
|
6
6
|
"module": "lib/esm/core-common.js",
|
|
@@ -27,8 +27,8 @@
|
|
|
27
27
|
"js-base64": "^3.6.1"
|
|
28
28
|
},
|
|
29
29
|
"peerDependencies": {
|
|
30
|
-
"@itwin/core-bentley": "5.3.0-dev.
|
|
31
|
-
"@itwin/core-geometry": "5.3.0-dev.
|
|
30
|
+
"@itwin/core-bentley": "5.3.0-dev.16",
|
|
31
|
+
"@itwin/core-geometry": "5.3.0-dev.16"
|
|
32
32
|
},
|
|
33
33
|
"devDependencies": {
|
|
34
34
|
"@itwin/eslint-plugin": "5.2.2-dev.2",
|
|
@@ -42,9 +42,9 @@
|
|
|
42
42
|
"rimraf": "^6.0.1",
|
|
43
43
|
"typescript": "~5.6.2",
|
|
44
44
|
"vitest": "^3.0.6",
|
|
45
|
-
"@itwin/build-tools": "5.3.0-dev.
|
|
46
|
-
"@itwin/core-geometry": "5.3.0-dev.
|
|
47
|
-
"@itwin/core-bentley": "5.3.0-dev.
|
|
45
|
+
"@itwin/build-tools": "5.3.0-dev.16",
|
|
46
|
+
"@itwin/core-geometry": "5.3.0-dev.16",
|
|
47
|
+
"@itwin/core-bentley": "5.3.0-dev.16"
|
|
48
48
|
},
|
|
49
49
|
"nyc": {
|
|
50
50
|
"extends": "./node_modules/@itwin/build-tools/.nycrc",
|