@ronin/compiler 0.13.4-leo-ron-1071-experimental-295 → 0.13.4-leo-ron-1071-experimental-296

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 (2) hide show
  1. package/dist/index.d.ts +9 -8
  2. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -149,8 +149,6 @@ interface Statement {
149
149
  type ModelFieldCollation = 'BINARY' | 'NOCASE' | 'RTRIM';
150
150
  type ModelFieldLinkAction = 'CASCADE' | 'RESTRICT' | 'SET NULL' | 'SET DEFAULT' | 'NO ACTION';
151
151
  type ModelFieldBasics = {
152
- /** The kind of value that should be stored inside the field. */
153
- type?: 'boolean' | 'date' | 'json';
154
152
  /** The label that should be used when displaying the field on the RONIN dashboard. */
155
153
  name?: string;
156
154
  /** Allows for addressing the field programmatically. */
@@ -184,21 +182,24 @@ type ModelFieldBasics = {
184
182
  /** An expression that gets evaluated every time a value is provided for the field. */
185
183
  check?: Expression;
186
184
  };
187
- type ModelField = ModelFieldBasics | (Omit<ModelFieldBasics, 'type'> & {
185
+ type ModelField = (ModelFieldBasics & {
186
+ /** The kind of value that should be stored inside the field. */
187
+ type?: 'boolean' | 'date' | 'json';
188
+ }) | (ModelFieldBasics & {
188
189
  /** The kind of value that should be stored inside the field. */
189
- type: 'string';
190
+ type?: 'string';
190
191
  /** The collation sequence to use for the field value. */
191
192
  collation?: ModelFieldCollation;
192
- }) | (Omit<ModelFieldBasics, 'type'> & {
193
+ }) | (ModelFieldBasics & {
193
194
  /** The kind of value that should be stored inside the field. */
194
- type: 'number';
195
+ type?: 'number';
195
196
  /**
196
197
  * Automatically increments the value of the field with every new inserted record.
197
198
  */
198
199
  increment?: boolean;
199
- }) | (Omit<ModelFieldBasics, 'type'> & {
200
+ }) | (ModelFieldBasics & {
200
201
  /** The kind of value that should be stored inside the field. */
201
- type: 'link';
202
+ type?: 'link';
202
203
  /** The target model of the relationship that is being established. */
203
204
  target: string;
204
205
  /** Whether the field should be related to one record, or many records. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ronin/compiler",
3
- "version": "0.13.4-leo-ron-1071-experimental-295",
3
+ "version": "0.13.4-leo-ron-1071-experimental-296",
4
4
  "type": "module",
5
5
  "description": "Compiles RONIN queries to SQL statements.",
6
6
  "publishConfig": {