@fibery/views 19.0.0 → 19.1.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.
Files changed (195) hide show
  1. package/lib/src/errors.d.ts +2 -0
  2. package/lib/src/errors.js +6 -0
  3. package/lib/src/field-utils/avatar.d.ts +1 -1
  4. package/lib/src/field-utils/avatar.js +1 -1
  5. package/lib/src/field-utils/back-references.d.ts +1 -1
  6. package/lib/src/field-utils/comments.d.ts +1 -1
  7. package/lib/src/field-utils/date-time.d.ts +5 -5
  8. package/lib/src/field-utils/date-time.js +1 -1
  9. package/lib/src/field-utils/enum-value.d.ts +1 -1
  10. package/lib/src/field-utils/file.d.ts +1 -1
  11. package/lib/src/field-utils/file.js +1 -1
  12. package/lib/src/field-utils/icon.d.ts +1 -1
  13. package/lib/src/field-utils/number.d.ts +1 -1
  14. package/lib/src/field-utils/reference-collection.d.ts +2 -2
  15. package/lib/src/field-utils/reference-collection.js +4 -4
  16. package/lib/src/field-utils/reference.d.ts +2 -2
  17. package/lib/src/field-utils/reference.js +4 -4
  18. package/lib/src/field-utils/relation-view.d.ts +1 -1
  19. package/lib/src/field-utils/rich-text.d.ts +2 -2
  20. package/lib/src/field-utils/rich-text.js +1 -1
  21. package/lib/src/field-utils/text.d.ts +1 -1
  22. package/lib/src/field-utils/user-active.d.ts +2 -2
  23. package/lib/src/field-utils/user-role.d.ts +1 -1
  24. package/lib/src/field-utils/workflow.d.ts +2 -2
  25. package/lib/src/index.d.ts +30 -16
  26. package/lib/src/index.js +7 -2
  27. package/lib/src/meta-validation.d.ts +10 -0
  28. package/lib/src/meta-validation.js +78 -0
  29. package/lib/src/private/board.d.ts +15 -11
  30. package/lib/src/private/board.js +8 -7
  31. package/lib/src/private/calendar.d.ts +14 -10
  32. package/lib/src/private/calendar.js +4 -3
  33. package/lib/src/private/feed.d.ts +14 -10
  34. package/lib/src/private/feed.js +4 -3
  35. package/lib/src/private/form.d.ts +25 -3
  36. package/lib/src/private/form.js +3 -3
  37. package/lib/src/private/map.d.ts +14 -10
  38. package/lib/src/private/map.js +4 -3
  39. package/lib/src/private/smart-folder.d.ts +23 -15
  40. package/lib/src/private/smart-folder.js +16 -13
  41. package/lib/src/private/timeline.d.ts +39 -10
  42. package/lib/src/private/timeline.js +8 -6
  43. package/lib/src/private/units.d.ts +10 -6
  44. package/lib/src/private/units.js +32 -24
  45. package/lib/src/private/utils.d.ts +64 -17
  46. package/lib/src/private/utils.js +26 -20
  47. package/lib/src/truthy.d.ts +1 -0
  48. package/lib/src/truthy.js +7 -0
  49. package/lib/src/unit-definitions/avatar-collection.d.ts +1 -1
  50. package/lib/src/unit-definitions/avatar-collection.js +5 -10
  51. package/lib/src/unit-definitions/avatar-input.d.ts +1 -1
  52. package/lib/src/unit-definitions/avatar-input.js +1 -1
  53. package/lib/src/unit-definitions/avatar.d.ts +1 -1
  54. package/lib/src/unit-definitions/avatar.js +5 -7
  55. package/lib/src/unit-definitions/back-references-list.d.ts +1 -1
  56. package/lib/src/unit-definitions/back-references-list.js +3 -3
  57. package/lib/src/unit-definitions/bool-checkbox.d.ts +1 -1
  58. package/lib/src/unit-definitions/bool-checkbox.js +2 -2
  59. package/lib/src/unit-definitions/bool.d.ts +1 -1
  60. package/lib/src/unit-definitions/bool.js +1 -1
  61. package/lib/src/unit-definitions/collection-count.d.ts +1 -1
  62. package/lib/src/unit-definitions/collection-count.js +4 -2
  63. package/lib/src/unit-definitions/color-input.d.ts +1 -1
  64. package/lib/src/unit-definitions/color-input.js +1 -1
  65. package/lib/src/unit-definitions/comments-list.d.ts +1 -1
  66. package/lib/src/unit-definitions/comments-list.js +1 -1
  67. package/lib/src/unit-definitions/date-range-combobox.d.ts +1 -1
  68. package/lib/src/unit-definitions/date-range-combobox.js +1 -1
  69. package/lib/src/unit-definitions/date-range.d.ts +1 -1
  70. package/lib/src/unit-definitions/date-range.js +1 -1
  71. package/lib/src/unit-definitions/date-time-combobox.d.ts +1 -1
  72. package/lib/src/unit-definitions/date-time-combobox.js +2 -2
  73. package/lib/src/unit-definitions/date.d.ts +1 -1
  74. package/lib/src/unit-definitions/date.js +2 -2
  75. package/lib/src/unit-definitions/email-input.d.ts +1 -1
  76. package/lib/src/unit-definitions/email-input.js +1 -1
  77. package/lib/src/unit-definitions/email.d.ts +1 -1
  78. package/lib/src/unit-definitions/email.js +1 -1
  79. package/lib/src/unit-definitions/emoji.d.ts +1 -1
  80. package/lib/src/unit-definitions/emoji.js +1 -1
  81. package/lib/src/unit-definitions/file-collection-count.d.ts +1 -1
  82. package/lib/src/unit-definitions/file-collection-count.js +11 -9
  83. package/lib/src/unit-definitions/file-compact-collection.d.ts +1 -1
  84. package/lib/src/unit-definitions/file-compact-collection.js +11 -9
  85. package/lib/src/unit-definitions/file-compact-reference.d.ts +1 -1
  86. package/lib/src/unit-definitions/file-compact-reference.js +3 -12
  87. package/lib/src/unit-definitions/file-reference.d.ts +1 -1
  88. package/lib/src/unit-definitions/file-reference.js +8 -6
  89. package/lib/src/unit-definitions/files-gallery.d.ts +1 -1
  90. package/lib/src/unit-definitions/files-gallery.js +11 -9
  91. package/lib/src/unit-definitions/files-l-list-item.d.ts +1 -1
  92. package/lib/src/unit-definitions/files-l-list-item.js +8 -6
  93. package/lib/src/unit-definitions/files-l-list.d.ts +1 -1
  94. package/lib/src/unit-definitions/files-l-list.js +11 -9
  95. package/lib/src/unit-definitions/files-list-item.d.ts +1 -1
  96. package/lib/src/unit-definitions/files-list-item.js +8 -6
  97. package/lib/src/unit-definitions/files-list.d.ts +1 -1
  98. package/lib/src/unit-definitions/files-list.js +11 -9
  99. package/lib/src/unit-definitions/geometry-preview.d.ts +1 -1
  100. package/lib/src/unit-definitions/geometry-preview.js +1 -1
  101. package/lib/src/unit-definitions/icon-button.d.ts +1 -1
  102. package/lib/src/unit-definitions/icon-button.js +1 -1
  103. package/lib/src/unit-definitions/icon-input.d.ts +1 -1
  104. package/lib/src/unit-definitions/icon-input.js +1 -1
  105. package/lib/src/unit-definitions/id.d.ts +1 -1
  106. package/lib/src/unit-definitions/json-input.d.ts +1 -1
  107. package/lib/src/unit-definitions/json-input.js +1 -1
  108. package/lib/src/unit-definitions/location-input.d.ts +1 -1
  109. package/lib/src/unit-definitions/location-input.js +1 -1
  110. package/lib/src/unit-definitions/location.d.ts +1 -1
  111. package/lib/src/unit-definitions/location.js +1 -1
  112. package/lib/src/unit-definitions/not-found.d.ts +1 -1
  113. package/lib/src/unit-definitions/number-input.d.ts +1 -1
  114. package/lib/src/unit-definitions/number-input.js +2 -2
  115. package/lib/src/unit-definitions/number.d.ts +1 -1
  116. package/lib/src/unit-definitions/number.js +2 -4
  117. package/lib/src/unit-definitions/phone-input.d.ts +1 -1
  118. package/lib/src/unit-definitions/phone-input.js +1 -1
  119. package/lib/src/unit-definitions/phone.d.ts +1 -1
  120. package/lib/src/unit-definitions/phone.js +1 -1
  121. package/lib/src/unit-definitions/progress-bar.d.ts +1 -1
  122. package/lib/src/unit-definitions/progress-bar.js +1 -4
  123. package/lib/src/unit-definitions/reference-collection-combobox.d.ts +1 -1
  124. package/lib/src/unit-definitions/reference-collection-combobox.js +1 -1
  125. package/lib/src/unit-definitions/reference-collection-list.d.ts +1 -1
  126. package/lib/src/unit-definitions/reference-collection-list.js +1 -1
  127. package/lib/src/unit-definitions/reference-collection-view.d.ts +1 -1
  128. package/lib/src/unit-definitions/reference-collection-view.js +1 -1
  129. package/lib/src/unit-definitions/reference-collection.d.ts +1 -1
  130. package/lib/src/unit-definitions/reference-collection.js +3 -3
  131. package/lib/src/unit-definitions/reference-combobox.d.ts +1 -1
  132. package/lib/src/unit-definitions/reference-combobox.js +1 -1
  133. package/lib/src/unit-definitions/reference-icon.d.ts +1 -1
  134. package/lib/src/unit-definitions/reference-icon.js +1 -1
  135. package/lib/src/unit-definitions/reference.d.ts +1 -1
  136. package/lib/src/unit-definitions/reference.js +1 -1
  137. package/lib/src/unit-definitions/rich-text-document.d.ts +1 -1
  138. package/lib/src/unit-definitions/rich-text-document.js +2 -2
  139. package/lib/src/unit-definitions/rich-text-snippet.d.ts +2 -1
  140. package/lib/src/unit-definitions/rich-text-snippet.js +6 -11
  141. package/lib/src/unit-definitions/single-location-preview.d.ts +1 -1
  142. package/lib/src/unit-definitions/single-location-preview.js +1 -1
  143. package/lib/src/unit-definitions/text-input.d.ts +1 -1
  144. package/lib/src/unit-definitions/text-input.js +2 -2
  145. package/lib/src/unit-definitions/text.d.ts +1 -1
  146. package/lib/src/unit-definitions/text.js +2 -2
  147. package/lib/src/unit-definitions/title-input.d.ts +1 -1
  148. package/lib/src/unit-definitions/title.d.ts +1 -1
  149. package/lib/src/unit-definitions/type-badge-abbr.d.ts +1 -1
  150. package/lib/src/unit-definitions/type-badge.d.ts +1 -1
  151. package/lib/src/unit-definitions/type-icon.d.ts +1 -1
  152. package/lib/src/unit-definitions/url-input.d.ts +1 -1
  153. package/lib/src/unit-definitions/url-input.js +1 -1
  154. package/lib/src/unit-definitions/url.d.ts +1 -1
  155. package/lib/src/unit-definitions/url.js +1 -1
  156. package/lib/src/unit-definitions/user-button.d.ts +1 -1
  157. package/lib/src/unit-definitions/user-role-input.d.ts +1 -1
  158. package/lib/src/unit-definitions/user-role-input.js +1 -1
  159. package/lib/src/unit-definitions/user-role.d.ts +1 -1
  160. package/lib/src/unit-definitions/user-role.js +1 -1
  161. package/lib/src/unit-utils/access.d.ts +2 -2
  162. package/lib/src/unit-utils/can-edit-field.d.ts +2 -2
  163. package/lib/src/unit-utils/common.d.ts +3 -3
  164. package/lib/src/unit-utils/common.js +1 -1
  165. package/lib/src/unit-utils/enums.d.ts +2 -2
  166. package/lib/src/unit-utils/formatters.d.ts +2 -2
  167. package/lib/src/unit-utils/get-export-value.d.ts +4 -4
  168. package/lib/src/unit-utils/get-export-value.js +3 -3
  169. package/lib/src/unit-utils/get-field-label.d.ts +2 -2
  170. package/lib/src/unit-utils/get-unmatched-unit-label.d.ts +1 -1
  171. package/lib/src/unit-utils/schema.d.ts +1 -1
  172. package/lib/src/unit-utils/wrap-normalized-in-expression.d.ts +3 -0
  173. package/lib/src/unit-utils/wrap-normalized-in-expression.js +14 -0
  174. package/lib/src/units/board.d.ts +5 -5
  175. package/lib/src/units/board.js +1 -1
  176. package/lib/src/units/canvas/index.d.ts +4 -4
  177. package/lib/src/units/canvas/index.js +1 -1
  178. package/lib/src/units/canvas/type-badge-abbr.d.ts +1 -1
  179. package/lib/src/units/canvas/type-badge.d.ts +1 -1
  180. package/lib/src/units/default.d.ts +5 -5
  181. package/lib/src/units/default.js +1 -1
  182. package/lib/src/units/gallery.d.ts +1 -1
  183. package/lib/src/units/gantt.d.ts +5 -5
  184. package/lib/src/units/gantt.js +1 -1
  185. package/lib/src/units/get-unit-definitions-for-view-type.js +4 -4
  186. package/lib/src/units/grid.d.ts +4 -4
  187. package/lib/src/units/grid.js +7 -7
  188. package/lib/src/units/list.d.ts +5 -5
  189. package/lib/src/units/list.js +1 -1
  190. package/lib/src/units/make-factory.d.ts +4 -5
  191. package/lib/src/units/make-factory.js +26 -15
  192. package/lib/src/units/types.d.ts +5 -5
  193. package/package.json +18 -18
  194. package/lib/jest.config.cjs +0 -34
  195. package/lib/jest.config.d.cts +0 -3
@@ -1,2 +1,3 @@
1
- import { FieldUnit, UnitDataDefinition } from "../units/types";
1
+ import type { FieldUnit, UnitDataDefinition } from "../units/types";
2
+ export declare const type = "rich-text-snippet";
2
3
  export declare const RichTextSnippet: UnitDataDefinition<FieldUnit>;
@@ -1,25 +1,20 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.RichTextSnippet = void 0;
3
+ exports.RichTextSnippet = exports.type = void 0;
4
4
  const query_1 = require("@fibery/query-utils/src/query");
5
- const utils_1 = require("@fibery/expression-utils/src/utils");
6
5
  const common_1 = require("../unit-utils/common");
7
6
  const get_export_value_1 = require("../unit-utils/get-export-value");
8
- const type = "rich-text-snippet";
7
+ const get_field_label_1 = require("../unit-utils/get-field-label");
8
+ exports.type = "rich-text-snippet";
9
9
  exports.RichTextSnippet = {
10
- type,
10
+ type: exports.type,
11
11
  name: "Snippet",
12
12
  canEdit() {
13
13
  return false;
14
14
  },
15
- makeUnit: (0, common_1.makeUnitMethod)(type),
15
+ makeUnit: (0, common_1.makeUnitMethod)(exports.type),
16
16
  getLabel({ typeObject, unit }) {
17
- const { expression } = unit;
18
- const fieldObject = (0, utils_1.getFieldObjectByFieldExpression)({
19
- typeObject,
20
- expression,
21
- });
22
- return `${fieldObject.title} (Snippet)`;
17
+ return `${(0, get_field_label_1.getFieldLabel)({ typeObject, unit })} (Snippet)`;
23
18
  },
24
19
  getQuerySelect({ typeObject, unit: { expression } }) {
25
20
  return (0, query_1.getQuerySelectForExpression)({
@@ -1,2 +1,2 @@
1
- import { FieldUnit, UnitDataDefinition } from "../units/types";
1
+ import type { FieldUnit, UnitDataDefinition } from "../units/types";
2
2
  export declare const SingleLocationPreview: UnitDataDefinition<FieldUnit>;
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SingleLocationPreview = void 0;
4
- const text_1 = require("./text");
5
4
  const common_1 = require("../unit-utils/common");
5
+ const text_1 = require("./text");
6
6
  const type = "single-location-preview";
7
7
  exports.SingleLocationPreview = {
8
8
  type,
@@ -1,2 +1,2 @@
1
- import { FieldUnit, UnitDataDefinition } from "../units/types";
1
+ import type { FieldUnit, UnitDataDefinition } from "../units/types";
2
2
  export declare const TextInput: UnitDataDefinition<FieldUnit>;
@@ -2,10 +2,10 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.TextInput = void 0;
4
4
  const query_1 = require("@fibery/query-utils/src/query");
5
+ const can_edit_field_1 = require("../unit-utils/can-edit-field");
5
6
  const common_1 = require("../unit-utils/common");
6
- const get_field_label_1 = require("../unit-utils/get-field-label");
7
7
  const get_export_value_1 = require("../unit-utils/get-export-value");
8
- const can_edit_field_1 = require("../unit-utils/can-edit-field");
8
+ const get_field_label_1 = require("../unit-utils/get-field-label");
9
9
  const type = "text-input";
10
10
  exports.TextInput = {
11
11
  type,
@@ -1,2 +1,2 @@
1
- import { FieldUnit, UnitDataDefinition } from "../units/types";
1
+ import type { FieldUnit, UnitDataDefinition } from "../units/types";
2
2
  export declare const Text: UnitDataDefinition<FieldUnit>;
@@ -3,9 +3,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.Text = void 0;
4
4
  const query_1 = require("@fibery/query-utils/src/query");
5
5
  const can_edit_field_1 = require("../unit-utils/can-edit-field");
6
- const get_field_label_1 = require("../unit-utils/get-field-label");
7
- const get_export_value_1 = require("../unit-utils/get-export-value");
8
6
  const common_1 = require("../unit-utils/common");
7
+ const get_export_value_1 = require("../unit-utils/get-export-value");
8
+ const get_field_label_1 = require("../unit-utils/get-field-label");
9
9
  const type = "text";
10
10
  exports.Text = {
11
11
  type,
@@ -1,2 +1,2 @@
1
- import { FieldUnit, UnitDataDefinition } from "../units/types";
1
+ import type { FieldUnit, UnitDataDefinition } from "../units/types";
2
2
  export declare const TitleInput: UnitDataDefinition<FieldUnit>;
@@ -1,2 +1,2 @@
1
- import { FieldUnit, UnitDataDefinition } from "../units/types";
1
+ import type { FieldUnit, UnitDataDefinition } from "../units/types";
2
2
  export declare const Title: UnitDataDefinition<FieldUnit>;
@@ -1,2 +1,2 @@
1
- import { DbUnit, UnitDataDefinition } from "../units/types";
1
+ import type { DbUnit, UnitDataDefinition } from "../units/types";
2
2
  export declare const TypeBadgeAbbr: UnitDataDefinition<DbUnit>;
@@ -1,2 +1,2 @@
1
- import { DbUnit, UnitDataDefinition } from "../units/types";
1
+ import type { DbUnit, UnitDataDefinition } from "../units/types";
2
2
  export declare const TypeBadge: UnitDataDefinition<DbUnit>;
@@ -1,2 +1,2 @@
1
- import { DbUnit, UnitDataDefinition } from "../units/types";
1
+ import type { DbUnit, UnitDataDefinition } from "../units/types";
2
2
  export declare const TypeIcon: UnitDataDefinition<DbUnit>;
@@ -1,2 +1,2 @@
1
- import { FieldUnit, UnitDataDefinition } from "../units/types";
1
+ import type { FieldUnit, UnitDataDefinition } from "../units/types";
2
2
  export declare const UrlInput: UnitDataDefinition<FieldUnit>;
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.UrlInput = void 0;
4
- const text_input_1 = require("./text-input");
5
4
  const common_1 = require("../unit-utils/common");
5
+ const text_input_1 = require("./text-input");
6
6
  const type = "url-input";
7
7
  exports.UrlInput = {
8
8
  ...text_input_1.TextInput,
@@ -1,2 +1,2 @@
1
- import { FieldUnit, UnitDataDefinition } from "../units/types";
1
+ import type { FieldUnit, UnitDataDefinition } from "../units/types";
2
2
  export declare const Url: UnitDataDefinition<FieldUnit>;
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.Url = void 0;
4
- const text_1 = require("./text");
5
4
  const common_1 = require("../unit-utils/common");
5
+ const text_1 = require("./text");
6
6
  const type = "url";
7
7
  exports.Url = {
8
8
  type,
@@ -1,2 +1,2 @@
1
- import { ButtonUnit, UnitDataDefinition } from "../units/types";
1
+ import type { ButtonUnit, UnitDataDefinition } from "../units/types";
2
2
  export declare const UserButton: UnitDataDefinition<ButtonUnit>;
@@ -1,2 +1,2 @@
1
- import { FieldUnit, UnitDataDefinition } from "../units/types";
1
+ import type { FieldUnit, UnitDataDefinition } from "../units/types";
2
2
  export declare const UserRoleInput: UnitDataDefinition<FieldUnit>;
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.UserRoleInput = void 0;
4
- const user_role_1 = require("./user-role");
5
4
  const common_1 = require("../unit-utils/common");
5
+ const user_role_1 = require("./user-role");
6
6
  const type = "user-role-input";
7
7
  exports.UserRoleInput = {
8
8
  ...user_role_1.UserRole,
@@ -1,2 +1,2 @@
1
- import { FieldUnit, UnitDataDefinition } from "../units/types";
1
+ import type { FieldUnit, UnitDataDefinition } from "../units/types";
2
2
  export declare const UserRole: UnitDataDefinition<FieldUnit>;
@@ -2,9 +2,9 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.UserRole = void 0;
4
4
  const query_1 = require("@fibery/query-utils/src/query");
5
- const common_1 = require("../unit-utils/common");
6
5
  const user_role_1 = require("../field-utils/user-role");
7
6
  const can_edit_field_1 = require("../unit-utils/can-edit-field");
7
+ const common_1 = require("../unit-utils/common");
8
8
  const get_export_value_1 = require("../unit-utils/get-export-value");
9
9
  const type = "user-role";
10
10
  exports.UserRole = {
@@ -1,5 +1,5 @@
1
- import { TypeObject } from "@fibery/schema";
2
- import { FieldExpression } from "@fibery/expression-utils";
1
+ import type { FieldExpression } from "@fibery/expression-utils";
2
+ import type { TypeObject } from "@fibery/schema";
3
3
  export declare const accessCheckKey: string;
4
4
  export declare const generateAccessCheckQueryExpression: ({ typeObject, contextPath, }: {
5
5
  typeObject: TypeObject;
@@ -1,5 +1,5 @@
1
- import { TypeObject } from "@fibery/schema";
2
- import { FieldUnit } from "../units/types";
1
+ import type { TypeObject } from "@fibery/schema";
2
+ import type { FieldUnit } from "../units/types";
3
3
  export declare const canEditField: ({ typeObject, unit: { expression } }: {
4
4
  typeObject: TypeObject;
5
5
  unit: FieldUnit;
@@ -1,6 +1,6 @@
1
- import { TypeObject } from "@fibery/schema";
2
- import { FieldUnit, PureUnit, Unit, UnitExpression } from "../units/types";
3
- import { $TSFixMe } from "../tsfixme";
1
+ import type { TypeObject } from "@fibery/schema";
2
+ import type { $TSFixMe } from "../tsfixme";
3
+ import type { FieldUnit, PureUnit, Unit, UnitExpression } from "../units/types";
4
4
  export declare const makeUnitMethod: (type: FieldUnit["type"]) => ({ expression }?: {
5
5
  expression?: UnitExpression;
6
6
  }) => FieldUnit;
@@ -4,9 +4,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.canEditFieldExpression = exports.asString = exports.toPureUnit = exports.isUnitEnabled = exports.calculateUnitExpressionErrors = exports.makeUnitMethod = void 0;
7
+ const utils_1 = require("@fibery/expression-utils/src/utils");
7
8
  const omit_1 = __importDefault(require("lodash/omit"));
8
9
  const get_unmatched_unit_label_1 = require("./get-unmatched-unit-label");
9
- const utils_1 = require("@fibery/expression-utils/src/utils");
10
10
  const makeUnitMethod = (type) => ({ expression } = {}) => {
11
11
  (0, utils_1.assertIsValidExpression)(expression);
12
12
  return { type, kind: "field", expression: expression };
@@ -1,6 +1,6 @@
1
- import { TypeObject } from "@fibery/schema";
2
- import { FieldExpression } from "@fibery/expression-utils";
1
+ import type { FieldExpression } from "@fibery/expression-utils";
3
2
  import type { Select } from "@fibery/expression-utils/src/types";
3
+ import type { TypeObject } from "@fibery/schema";
4
4
  export declare const getEnumIconColorQuery: ({ typeObject, contextPath, }: {
5
5
  typeObject: TypeObject;
6
6
  contextPath?: FieldExpression;
@@ -1,5 +1,5 @@
1
- import { FieldObject } from "@fibery/schema";
2
- import { NumberDisplaySettings } from "../field-utils/number";
1
+ import type { FieldObject } from "@fibery/schema";
2
+ import type { NumberDisplaySettings } from "../field-utils/number";
3
3
  export declare const defaultLocale = "en-US";
4
4
  export declare const defaultDateFormat = "MMM D, YYYY";
5
5
  export declare const defaultDateTimeFormat = "MMM D, YYYY HH:mm";
@@ -1,7 +1,7 @@
1
- import { FieldUnit } from "../units/types";
2
- import { FieldObject, TypeObject } from "@fibery/schema";
3
- import { NumberDisplaySettings } from "../field-utils/number";
4
- import { FiberyObject } from "@fibery/expression-utils/src/types";
1
+ import type { FiberyObject } from "@fibery/expression-utils/src/types";
2
+ import type { FieldObject, TypeObject } from "@fibery/schema";
3
+ import type { NumberDisplaySettings } from "../field-utils/number";
4
+ import type { FieldUnit } from "../units/types";
5
5
  export declare const getExportValue: ({ object, unit }: {
6
6
  object: FiberyObject;
7
7
  unit: FieldUnit;
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getNumberExportValue = exports.getTitleExportValue = exports.getLocationExportValue = exports.getDateRangeExportValue = exports.formatDateRangeExportValue = exports.getSnippetExportValue = exports.getReferenceExportValue = exports.getReferenceCollectionExportValue = exports.getExportValue = void 0;
4
+ const utils_1 = require("@fibery/expression-utils/src/utils");
4
5
  const query_1 = require("@fibery/query-utils/src/query");
5
6
  const date_fns_1 = require("date-fns");
6
7
  const number_1 = require("../field-utils/number");
@@ -14,8 +15,7 @@ const getReferenceCollectionExportValue = ({ unit, typeObject, object, }) => {
14
15
  if (!value || value.length === 0) {
15
16
  return value;
16
17
  }
17
- const [field] = unit.expression;
18
- const fieldObject = typeObject.fieldObjectsByName[field];
18
+ const fieldObject = (0, utils_1.getFieldObjectByFieldExpression)({ typeObject, expression: unit.expression });
19
19
  return value.map((v) => v[fieldObject.typeObject.titleField]);
20
20
  };
21
21
  exports.getReferenceCollectionExportValue = getReferenceCollectionExportValue;
@@ -51,7 +51,7 @@ const formatDateRangeExportValue = (value, fieldObject) => {
51
51
  exports.formatDateRangeExportValue = formatDateRangeExportValue;
52
52
  const getDateRangeExportValue = ({ object, unit, typeObject, }) => {
53
53
  const value = (0, exports.getExportValue)({ object, unit });
54
- const fieldObject = (0, query_1.extractFieldObjectFromExpression)({ expression: unit.expression, typeObject });
54
+ const fieldObject = (0, utils_1.getFieldObjectByFieldExpression)({ expression: unit.expression, typeObject });
55
55
  return (0, exports.formatDateRangeExportValue)(value, fieldObject);
56
56
  };
57
57
  exports.getDateRangeExportValue = getDateRangeExportValue;
@@ -1,5 +1,5 @@
1
- import { TypeObject } from "@fibery/schema";
2
- import { FieldUnit } from "../units/types";
1
+ import type { TypeObject } from "@fibery/schema";
2
+ import type { FieldUnit } from "../units/types";
3
3
  export declare const getFieldLabel: ({ typeObject, unit }: {
4
4
  typeObject: TypeObject;
5
5
  unit: FieldUnit;
@@ -1,2 +1,2 @@
1
- import { Unit } from "../units/types";
1
+ import type { Unit } from "../units/types";
2
2
  export declare const getUnmatchedUnitLabel: (unit: Unit) => string;
@@ -1,4 +1,4 @@
1
- import { Schema } from "@fibery/schema";
1
+ import type { Schema } from "@fibery/schema";
2
2
  export declare const extractTypePart: (type: string) => string;
3
3
  export declare const extractTypeNamespacePart: (type: string) => string;
4
4
  export declare const getTypeById: (schema: Schema, id: string) => import("@fibery/schema").TypeObject | undefined;
@@ -0,0 +1,3 @@
1
+ import type { FieldExpression } from "@fibery/expression-utils/src/types";
2
+ import type { FieldObject } from "@fibery/schema";
3
+ export declare const wrapNormalizedInExpression: (innerNormalized: Record<string, unknown>, fieldObjects: FieldObject[], expression: FieldExpression) => Record<string, unknown>;
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.wrapNormalizedInExpression = void 0;
4
+ const wrapNormalizedInExpression = (innerNormalized, fieldObjects, expression) => [...expression].reverse().reduce((inner, field, reversedIndex) => {
5
+ const originalIndex = expression.length - 1 - reversedIndex;
6
+ const isTerminal = originalIndex === expression.length - 1;
7
+ if (!isTerminal) {
8
+ const { idField } = fieldObjects[originalIndex].typeObject;
9
+ const innerWithId = idField ? { [idField]: idField, ...inner } : inner;
10
+ return { [field]: innerWithId };
11
+ }
12
+ return { [field]: inner };
13
+ }, innerNormalized);
14
+ exports.wrapNormalizedInExpression = wrapNormalizedInExpression;
@@ -1,24 +1,24 @@
1
- import { TypeObject } from "@fibery/schema";
1
+ import type { TypeObject } from "@fibery/schema";
2
2
  export declare const getTypeUnits: () => import("./types").PureUnit[], getUnitName: (unit: import("./types").Unit) => string | null, getUnitsForType: (typeObject: TypeObject, options?: {
3
- parentExpression?: import("@fibery/expression-utils").FieldExpression;
3
+ parentFieldObjects?: import("@fibery/schema").FieldObject[];
4
4
  showHiddenFields?: boolean;
5
5
  isSharingMode?: boolean;
6
6
  }) => {
7
7
  unit: import("./types").Unit;
8
8
  fieldObject: import("@fibery/schema").FieldObject;
9
9
  }[], getUnitsForField: (fieldObject: import("@fibery/schema").FieldObject, options?: {
10
- parentExpression?: import("@fibery/expression-utils").FieldExpression;
10
+ parentFieldObjects?: import("@fibery/schema").FieldObject[];
11
11
  showHiddenFields?: boolean;
12
12
  isSharingMode?: boolean;
13
13
  }) => import("./types").Unit[], getUnitsForTypePerField: (typeObject: TypeObject, options?: {
14
- parentExpression?: import("@fibery/expression-utils").FieldExpression;
14
+ parentFieldObjects?: import("@fibery/schema").FieldObject[];
15
15
  showHiddenFields?: boolean;
16
16
  isSharingMode?: boolean;
17
17
  }) => {
18
18
  fieldObject: import("@fibery/schema").FieldObject;
19
19
  units: import("./types").Unit[];
20
20
  }[], getUnitLabel: (typeObject: TypeObject, unit: import("./types").Unit) => string, getHardcodedUnitsForView: (typeObject: TypeObject) => ({
21
- type: "avatar" | "avatar-collection" | "avatar-input" | "back-references-list" | "bool" | "bool-checkbox" | "collection-count" | "color-input" | "comments-list" | "date" | "date-time" | "date-time-combobox" | "date-range" | "date-range-combobox" | "email" | "email-input" | "emoji" | "field" | "files-gallery" | "files-list" | "files-list-item" | "files-l-list" | "files-l-list-item" | "file-reference" | "file-compact-collection" | "file-compact-reference" | "file-collection-count" | "geometry-preview" | "icon-button" | "icon-input" | "id" | "json-input" | "location" | "location-input" | "number" | "number-input" | "phone" | "phone-input" | "progress-bar" | "reference" | "reference-icon" | "reference-combobox" | "reference-collection" | "reference-collection-list" | "reference-collection-view" | "reference-collection-combobox" | "rich-text-snippet" | "rich-text-document" | "single-location-preview" | "text" | "text-input" | "title" | "title-input" | "url" | "url-input" | "user-role" | "user-role-input";
21
+ type: "avatar" | "avatar-collection" | "avatar-input" | "back-references-list" | "bool" | "bool-checkbox" | "collection-count" | "color-input" | "comments-list" | "date" | "date-time" | "date-time-range" | "date-time-combobox" | "date-range" | "date-range-combobox" | "email" | "email-input" | "emoji" | "field" | "files-collection" | "files-gallery" | "files-list" | "files-list-item" | "files-l-list" | "files-l-list-item" | "file-reference" | "file-compact-collection" | "file-compact-reference" | "file-collection-count" | "geometry-preview" | "icon-button" | "icon-input" | "id" | "json-input" | "location" | "location-input" | "number" | "number-input" | "phone" | "phone-input" | "progress-bar" | "reference" | "reference-icon" | "reference-combobox" | "reference-collection" | "reference-collection-list" | "reference-collection-view" | "reference-collection-combobox" | "rich-text-snippet" | "rich-text-document" | "single-location-preview" | "text" | "text-input" | "title" | "title-input" | "url" | "url-input" | "user-role" | "user-role-input";
22
22
  expression: import("./types").UnitExpression;
23
23
  kind: "field";
24
24
  settings?: Record<string, unknown> | undefined;
@@ -36,8 +36,8 @@ var _a;
36
36
  Object.defineProperty(exports, "__esModule", { value: true });
37
37
  exports.getDefaultUnits = exports.getUnitDataDefinition = exports.getCardUnitsSelect = exports.getHardcodedUnitsForView = exports.getUnitLabel = exports.getUnitsForTypePerField = exports.getUnitsForField = exports.getUnitsForType = exports.getUnitName = exports.getTypeUnits = void 0;
38
38
  const avatar_1 = require("../field-utils/avatar");
39
- const make_factory_1 = require("./make-factory");
40
39
  const allUnitDefinitions = __importStar(require("../unit-definitions"));
40
+ const make_factory_1 = require("./make-factory");
41
41
  _a = (0, make_factory_1.makeUnitDefinitionsFactory)(allUnitDefinitions), exports.getTypeUnits = _a.getTypeUnits, exports.getUnitName = _a.getUnitName, exports.getUnitsForType = _a.getUnitsForType, exports.getUnitsForField = _a.getUnitsForField, exports.getUnitsForTypePerField = _a.getUnitsForTypePerField, exports.getUnitLabel = _a.getUnitLabel, exports.getHardcodedUnitsForView = _a.getHardcodedUnitsForView, exports.getCardUnitsSelect = _a.getCardUnitsSelect, exports.getUnitDataDefinition = _a.getUnitDataDefinition;
42
42
  const getDefaultUnits = (typeObject) => {
43
43
  const { Title, Avatar, TypeBadgeAbbr } = allUnitDefinitions;
@@ -1,16 +1,16 @@
1
1
  export declare const getTypeUnits: () => import("../types").PureUnit[], getUnitName: (unit: import("../types").Unit) => string | null, getUnitsForField: (fieldObject: import("@fibery/schema").FieldObject, options?: {
2
- parentExpression?: import("@fibery/expression-utils").FieldExpression;
2
+ parentFieldObjects?: import("@fibery/schema").FieldObject[];
3
3
  showHiddenFields?: boolean;
4
4
  isSharingMode?: boolean;
5
5
  }) => import("../types").Unit[], getUnitsForType: (typeObject: import("@fibery/schema").TypeObject, options?: {
6
- parentExpression?: import("@fibery/expression-utils").FieldExpression;
6
+ parentFieldObjects?: import("@fibery/schema").FieldObject[];
7
7
  showHiddenFields?: boolean;
8
8
  isSharingMode?: boolean;
9
9
  }) => {
10
10
  unit: import("../types").Unit;
11
11
  fieldObject: import("@fibery/schema").FieldObject;
12
12
  }[], getUnitsForTypePerField: (typeObject: import("@fibery/schema").TypeObject, options?: {
13
- parentExpression?: import("@fibery/expression-utils").FieldExpression;
13
+ parentFieldObjects?: import("@fibery/schema").FieldObject[];
14
14
  showHiddenFields?: boolean;
15
15
  isSharingMode?: boolean;
16
16
  }) => {
@@ -21,7 +21,7 @@ export declare const getTypeUnits: () => import("../types").PureUnit[], getUnitN
21
21
  typeObject: import("@fibery/schema").TypeObject;
22
22
  units: import("../types").Unit[];
23
23
  }) => any, getHardcodedUnitsForView: (typeObject: import("@fibery/schema").TypeObject) => ({
24
- type: "avatar" | "avatar-collection" | "avatar-input" | "back-references-list" | "bool" | "bool-checkbox" | "collection-count" | "color-input" | "comments-list" | "date" | "date-time" | "date-time-combobox" | "date-range" | "date-range-combobox" | "email" | "email-input" | "emoji" | "field" | "files-gallery" | "files-list" | "files-list-item" | "files-l-list" | "files-l-list-item" | "file-reference" | "file-compact-collection" | "file-compact-reference" | "file-collection-count" | "geometry-preview" | "icon-button" | "icon-input" | "id" | "json-input" | "location" | "location-input" | "number" | "number-input" | "phone" | "phone-input" | "progress-bar" | "reference" | "reference-icon" | "reference-combobox" | "reference-collection" | "reference-collection-list" | "reference-collection-view" | "reference-collection-combobox" | "rich-text-snippet" | "rich-text-document" | "single-location-preview" | "text" | "text-input" | "title" | "title-input" | "url" | "url-input" | "user-role" | "user-role-input";
24
+ type: "avatar" | "avatar-collection" | "avatar-input" | "back-references-list" | "bool" | "bool-checkbox" | "collection-count" | "color-input" | "comments-list" | "date" | "date-time" | "date-time-range" | "date-time-combobox" | "date-range" | "date-range-combobox" | "email" | "email-input" | "emoji" | "field" | "files-collection" | "files-gallery" | "files-list" | "files-list-item" | "files-l-list" | "files-l-list-item" | "file-reference" | "file-compact-collection" | "file-compact-reference" | "file-collection-count" | "geometry-preview" | "icon-button" | "icon-input" | "id" | "json-input" | "location" | "location-input" | "number" | "number-input" | "phone" | "phone-input" | "progress-bar" | "reference" | "reference-icon" | "reference-combobox" | "reference-collection" | "reference-collection-list" | "reference-collection-view" | "reference-collection-combobox" | "rich-text-snippet" | "rich-text-document" | "single-location-preview" | "text" | "text-input" | "title" | "title-input" | "url" | "url-input" | "user-role" | "user-role-input";
25
25
  expression: import("../types").UnitExpression;
26
26
  kind: "field";
27
27
  settings?: Record<string, unknown> | undefined;
@@ -35,8 +35,8 @@ var __importStar = (this && this.__importStar) || (function () {
35
35
  var _a;
36
36
  Object.defineProperty(exports, "__esModule", { value: true });
37
37
  exports.getDefaultUnits = exports.getHardcodedUnitsForView = exports.getCardUnitsSelect = exports.getUnitLabel = exports.getUnitsForTypePerField = exports.getUnitsForType = exports.getUnitsForField = exports.getUnitName = exports.getTypeUnits = void 0;
38
- const make_factory_1 = require("../make-factory");
39
38
  const rich_text_snippet_1 = require("../../unit-definitions/rich-text-snippet");
39
+ const make_factory_1 = require("../make-factory");
40
40
  const unitDefinitions = __importStar(require("./all-units-data-definitions"));
41
41
  const allUnitDefinitions = { ...unitDefinitions, RichTextSnippet: rich_text_snippet_1.RichTextSnippet };
42
42
  // noinspection JSUnusedGlobalSymbols
@@ -1,4 +1,4 @@
1
- import { TypeObject } from "@fibery/schema";
1
+ import type { TypeObject } from "@fibery/schema";
2
2
  export declare const TypeBadgeAbbr: {
3
3
  getQuerySelect({ typeObject }: {
4
4
  typeObject: TypeObject;
@@ -1,4 +1,4 @@
1
- import { TypeObject } from "@fibery/schema";
1
+ import type { TypeObject } from "@fibery/schema";
2
2
  export declare const TypeBadge: {
3
3
  getQuerySelect({ typeObject }: {
4
4
  typeObject: TypeObject;
@@ -1,17 +1,17 @@
1
- import { TypeObject } from "@fibery/schema";
1
+ import type { TypeObject } from "@fibery/schema";
2
2
  export declare const getTypeUnits: () => import("./types").PureUnit[], getUnitName: (unit: import("./types").Unit) => string | null, getUnitsForType: (typeObject: TypeObject, options?: {
3
- parentExpression?: import("@fibery/expression-utils").FieldExpression;
3
+ parentFieldObjects?: import("@fibery/schema").FieldObject[];
4
4
  showHiddenFields?: boolean;
5
5
  isSharingMode?: boolean;
6
6
  }) => {
7
7
  unit: import("./types").Unit;
8
8
  fieldObject: import("@fibery/schema").FieldObject;
9
9
  }[], getUnitsForField: (fieldObject: import("@fibery/schema").FieldObject, options?: {
10
- parentExpression?: import("@fibery/expression-utils").FieldExpression;
10
+ parentFieldObjects?: import("@fibery/schema").FieldObject[];
11
11
  showHiddenFields?: boolean;
12
12
  isSharingMode?: boolean;
13
13
  }) => import("./types").Unit[], getUnitsForTypePerField: (typeObject: TypeObject, options?: {
14
- parentExpression?: import("@fibery/expression-utils").FieldExpression;
14
+ parentFieldObjects?: import("@fibery/schema").FieldObject[];
15
15
  showHiddenFields?: boolean;
16
16
  isSharingMode?: boolean;
17
17
  }) => {
@@ -22,7 +22,7 @@ export declare const getTypeUnits: () => import("./types").PureUnit[], getUnitNa
22
22
  typeObject: TypeObject;
23
23
  units: import("./types").Unit[];
24
24
  }) => any, getUnitLabel: (typeObject: TypeObject, unit: import("./types").Unit) => string, getHardcodedUnitsForView: (typeObject: TypeObject) => ({
25
- type: "avatar" | "avatar-collection" | "avatar-input" | "back-references-list" | "bool" | "bool-checkbox" | "collection-count" | "color-input" | "comments-list" | "date" | "date-time" | "date-time-combobox" | "date-range" | "date-range-combobox" | "email" | "email-input" | "emoji" | "field" | "files-gallery" | "files-list" | "files-list-item" | "files-l-list" | "files-l-list-item" | "file-reference" | "file-compact-collection" | "file-compact-reference" | "file-collection-count" | "geometry-preview" | "icon-button" | "icon-input" | "id" | "json-input" | "location" | "location-input" | "number" | "number-input" | "phone" | "phone-input" | "progress-bar" | "reference" | "reference-icon" | "reference-combobox" | "reference-collection" | "reference-collection-list" | "reference-collection-view" | "reference-collection-combobox" | "rich-text-snippet" | "rich-text-document" | "single-location-preview" | "text" | "text-input" | "title" | "title-input" | "url" | "url-input" | "user-role" | "user-role-input";
25
+ type: "avatar" | "avatar-collection" | "avatar-input" | "back-references-list" | "bool" | "bool-checkbox" | "collection-count" | "color-input" | "comments-list" | "date" | "date-time" | "date-time-range" | "date-time-combobox" | "date-range" | "date-range-combobox" | "email" | "email-input" | "emoji" | "field" | "files-collection" | "files-gallery" | "files-list" | "files-list-item" | "files-l-list" | "files-l-list-item" | "file-reference" | "file-compact-collection" | "file-compact-reference" | "file-collection-count" | "geometry-preview" | "icon-button" | "icon-input" | "id" | "json-input" | "location" | "location-input" | "number" | "number-input" | "phone" | "phone-input" | "progress-bar" | "reference" | "reference-icon" | "reference-combobox" | "reference-collection" | "reference-collection-list" | "reference-collection-view" | "reference-collection-combobox" | "rich-text-snippet" | "rich-text-document" | "single-location-preview" | "text" | "text-input" | "title" | "title-input" | "url" | "url-input" | "user-role" | "user-role-input";
26
26
  expression: import("./types").UnitExpression;
27
27
  kind: "field";
28
28
  settings?: Record<string, unknown> | undefined;
@@ -36,8 +36,8 @@ var _a;
36
36
  Object.defineProperty(exports, "__esModule", { value: true });
37
37
  exports.getDefaultUnits = exports.getHardcodedUnitsForView = exports.getUnitLabel = exports.getCardUnitsSelect = exports.getUnitsForTypePerField = exports.getUnitsForField = exports.getUnitsForType = exports.getUnitName = exports.getTypeUnits = void 0;
38
38
  const avatar_1 = require("../field-utils/avatar");
39
- const make_factory_1 = require("./make-factory");
40
39
  const allUnitDefinitions = __importStar(require("../unit-definitions"));
40
+ const make_factory_1 = require("./make-factory");
41
41
  _a = (0, make_factory_1.makeUnitDefinitionsFactory)(allUnitDefinitions), exports.getTypeUnits = _a.getTypeUnits, exports.getUnitName = _a.getUnitName, exports.getUnitsForType = _a.getUnitsForType, exports.getUnitsForField = _a.getUnitsForField, exports.getUnitsForTypePerField = _a.getUnitsForTypePerField, exports.getCardUnitsSelect = _a.getCardUnitsSelect, exports.getUnitLabel = _a.getUnitLabel, exports.getHardcodedUnitsForView = _a.getHardcodedUnitsForView;
42
42
  const getDefaultUnits = (typeObject) => {
43
43
  const { Title, Avatar, TypeBadgeAbbr } = allUnitDefinitions;
@@ -1,3 +1,3 @@
1
- import { TypeObject } from "@fibery/schema";
1
+ import type { TypeObject } from "@fibery/schema";
2
2
  export { getCardUnitsSelect, getHardcodedUnitsForView, getTypeUnits, getUnitDataDefinition, getUnitLabel, getUnitName, getUnitsForField, getUnitsForType, getUnitsForTypePerField, } from "./board";
3
3
  export declare const getDefaultUnits: (_typeObject: TypeObject) => import("./types").PureUnit[];
@@ -1,17 +1,17 @@
1
- import { TypeObject } from "@fibery/schema";
1
+ import type { TypeObject } from "@fibery/schema";
2
2
  export declare const getTypeUnits: () => import("./types").PureUnit[], getUnitName: (unit: import("./types").Unit) => string | null, getUnitsForType: (typeObject: TypeObject, options?: {
3
- parentExpression?: import("@fibery/expression-utils").FieldExpression;
3
+ parentFieldObjects?: import("@fibery/schema").FieldObject[];
4
4
  showHiddenFields?: boolean;
5
5
  isSharingMode?: boolean;
6
6
  }) => {
7
7
  unit: import("./types").Unit;
8
8
  fieldObject: import("@fibery/schema").FieldObject;
9
9
  }[], getUnitsForField: (fieldObject: import("@fibery/schema").FieldObject, options?: {
10
- parentExpression?: import("@fibery/expression-utils").FieldExpression;
10
+ parentFieldObjects?: import("@fibery/schema").FieldObject[];
11
11
  showHiddenFields?: boolean;
12
12
  isSharingMode?: boolean;
13
13
  }) => import("./types").Unit[], getUnitsForTypePerField: (typeObject: TypeObject, options?: {
14
- parentExpression?: import("@fibery/expression-utils").FieldExpression;
14
+ parentFieldObjects?: import("@fibery/schema").FieldObject[];
15
15
  showHiddenFields?: boolean;
16
16
  isSharingMode?: boolean;
17
17
  }) => {
@@ -22,7 +22,7 @@ export declare const getTypeUnits: () => import("./types").PureUnit[], getUnitNa
22
22
  typeObject: TypeObject;
23
23
  units: import("./types").Unit[];
24
24
  }) => any, getUnitLabel: (typeObject: TypeObject, unit: import("./types").Unit) => string, getHardcodedUnitsForView: (typeObject: TypeObject) => ({
25
- type: "avatar" | "avatar-collection" | "avatar-input" | "back-references-list" | "bool" | "bool-checkbox" | "collection-count" | "color-input" | "comments-list" | "date" | "date-time" | "date-time-combobox" | "date-range" | "date-range-combobox" | "email" | "email-input" | "emoji" | "field" | "files-gallery" | "files-list" | "files-list-item" | "files-l-list" | "files-l-list-item" | "file-reference" | "file-compact-collection" | "file-compact-reference" | "file-collection-count" | "geometry-preview" | "icon-button" | "icon-input" | "id" | "json-input" | "location" | "location-input" | "number" | "number-input" | "phone" | "phone-input" | "progress-bar" | "reference" | "reference-icon" | "reference-combobox" | "reference-collection" | "reference-collection-list" | "reference-collection-view" | "reference-collection-combobox" | "rich-text-snippet" | "rich-text-document" | "single-location-preview" | "text" | "text-input" | "title" | "title-input" | "url" | "url-input" | "user-role" | "user-role-input";
25
+ type: "avatar" | "avatar-collection" | "avatar-input" | "back-references-list" | "bool" | "bool-checkbox" | "collection-count" | "color-input" | "comments-list" | "date" | "date-time" | "date-time-range" | "date-time-combobox" | "date-range" | "date-range-combobox" | "email" | "email-input" | "emoji" | "field" | "files-collection" | "files-gallery" | "files-list" | "files-list-item" | "files-l-list" | "files-l-list-item" | "file-reference" | "file-compact-collection" | "file-compact-reference" | "file-collection-count" | "geometry-preview" | "icon-button" | "icon-input" | "id" | "json-input" | "location" | "location-input" | "number" | "number-input" | "phone" | "phone-input" | "progress-bar" | "reference" | "reference-icon" | "reference-combobox" | "reference-collection" | "reference-collection-list" | "reference-collection-view" | "reference-collection-combobox" | "rich-text-snippet" | "rich-text-document" | "single-location-preview" | "text" | "text-input" | "title" | "title-input" | "url" | "url-input" | "user-role" | "user-role-input";
26
26
  expression: import("./types").UnitExpression;
27
27
  kind: "field";
28
28
  settings?: Record<string, unknown> | undefined;
@@ -36,8 +36,8 @@ var _a;
36
36
  Object.defineProperty(exports, "__esModule", { value: true });
37
37
  exports.getDefaultLaneUnits = exports.getDefaultUnits = exports.getHardcodedUnitsForView = exports.getUnitLabel = exports.getCardUnitsSelect = exports.getUnitsForTypePerField = exports.getUnitsForField = exports.getUnitsForType = exports.getUnitName = exports.getTypeUnits = void 0;
38
38
  const avatar_1 = require("../field-utils/avatar");
39
- const make_factory_1 = require("./make-factory");
40
39
  const allUnitDefinitions = __importStar(require("../unit-definitions"));
40
+ const make_factory_1 = require("./make-factory");
41
41
  _a = (0, make_factory_1.makeUnitDefinitionsFactory)(allUnitDefinitions), exports.getTypeUnits = _a.getTypeUnits, exports.getUnitName = _a.getUnitName, exports.getUnitsForType = _a.getUnitsForType, exports.getUnitsForField = _a.getUnitsForField, exports.getUnitsForTypePerField = _a.getUnitsForTypePerField, exports.getCardUnitsSelect = _a.getCardUnitsSelect, exports.getUnitLabel = _a.getUnitLabel, exports.getHardcodedUnitsForView = _a.getHardcodedUnitsForView;
42
42
  const getDefaultUnits = () => {
43
43
  const { Title } = allUnitDefinitions;
@@ -34,13 +34,13 @@ var __importStar = (this && this.__importStar) || (function () {
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
36
  exports.getUnitDefinitionsForViewType = void 0;
37
- const defaultDefinitions = __importStar(require("./default"));
38
37
  const boardDefinitions = __importStar(require("./board"));
39
38
  const canvasDefinitions = __importStar(require("./canvas"));
40
- const listDefinitions = __importStar(require("./list"));
41
- const gridDefinitions = __importStar(require("./grid"));
42
- const ganttDefinitions = __importStar(require("./gantt"));
39
+ const defaultDefinitions = __importStar(require("./default"));
43
40
  const galleryDefinitions = __importStar(require("./gallery"));
41
+ const ganttDefinitions = __importStar(require("./gantt"));
42
+ const gridDefinitions = __importStar(require("./grid"));
43
+ const listDefinitions = __importStar(require("./list"));
44
44
  const getUnitDefinitionsForViewType = (viewType) => {
45
45
  switch (viewType) {
46
46
  case "board":