Skip to content

Commit

Permalink
names prototype, fix errors
Browse files Browse the repository at this point in the history
  • Loading branch information
a-type committed Nov 29, 2024
1 parent a4e0d45 commit 3d9b02c
Show file tree
Hide file tree
Showing 84 changed files with 15,629 additions and 14,481 deletions.
2 changes: 1 addition & 1 deletion apps/gnocchi/hub/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"typecheck": "tsc --build tsconfig.json"
},
"dependencies": {
"@a-type/ui": "^1.1.29",
"@a-type/ui": "^1.2.0",
"@a-type/utils": "^1.0.8",
"@tiptap/core": "^2.2.4",
"@tiptap/extension-document": "^2.2.4",
Expand Down
219 changes: 111 additions & 108 deletions apps/gnocchi/verdant/src/client/schemaVersions/v1.js
Original file line number Diff line number Diff line change
@@ -1,118 +1,121 @@
/** @generated - do not modify this file. */

// src/client/schemaVersions/v1.ts
import { collection, schema } from "@verdant-web/store";
var categoryCollection = collection({
name: "categories",
primaryKey: "id",
fields: {
id: {
type: "string",
indexed: true,
unique: true
},
name: {
type: "string",
indexed: false,
unique: false
}
},
synthetics: {},
compounds: {}
import { schema } from '@verdant-web/store';
var categoryCollection = schema.collection({
name: 'categories',
primaryKey: 'id',
fields: {
id: {
type: 'string',
indexed: true,
unique: true,
},
name: {
type: 'string',
indexed: false,
unique: false,
},
},
synthetics: {},
compounds: {},
});
var foodCategoryLookupCollection = collection({
name: "foodCategoryLookups",
primaryKey: "foodName",
fields: {
foodName: {
type: "string",
indexed: true,
unique: true
},
categoryId: {
type: "string",
indexed: true,
unique: false
}
},
synthetics: {},
compounds: {}
var foodCategoryLookupCollection = schema.collection({
name: 'foodCategoryLookups',
primaryKey: 'foodName',
fields: {
foodName: {
type: 'string',
indexed: true,
unique: true,
},
categoryId: {
type: 'string',
indexed: true,
unique: false,
},
},
synthetics: {},
compounds: {},
});
var itemCollection = collection({
name: "items",
primaryKey: "id",
fields: {
id: {
type: "string",
indexed: true,
unique: true
},
categoryId: {
type: "string",
indexed: true,
unique: false
},
createdAt: {
type: "number",
indexed: false,
unique: false
},
totalQuantity: {
type: "number",
indexed: false,
unique: false
},
purchasedQuantity: {
type: "number",
indexed: false,
unique: false
},
unit: {
type: "string",
indexed: false,
unique: false
},
food: {
type: "string",
indexed: true,
unique: false
},
sortKey: {
type: "string",
indexed: false,
unique: false
},
inputs: {
type: "array",
items: {
type: "object",
properties: {
text: {
type: "string"
}
}
}
}
},
synthetics: {
purchased: {
type: "string",
compute: (doc) => doc.totalQuantity > 0 && doc.purchasedQuantity >= doc.totalQuantity ? "yes" : "no"
}
},
compounds: {}
var itemCollection = schema.collection({
name: 'items',
primaryKey: 'id',
fields: {
id: {
type: 'string',
indexed: true,
unique: true,
},
categoryId: {
type: 'string',
indexed: true,
unique: false,
},
createdAt: {
type: 'number',
indexed: false,
unique: false,
},
totalQuantity: {
type: 'number',
indexed: false,
unique: false,
},
purchasedQuantity: {
type: 'number',
indexed: false,
unique: false,
},
unit: {
type: 'string',
indexed: false,
unique: false,
},
food: {
type: 'string',
indexed: true,
unique: false,
},
sortKey: {
type: 'string',
indexed: false,
unique: false,
},
inputs: {
type: 'array',
items: {
type: 'object',
properties: {
text: {
type: 'string',
},
},
},
},
},
synthetics: {
purchased: {
type: 'string',
compute: (doc) =>
doc.totalQuantity > 0 && doc.purchasedQuantity >= doc.totalQuantity ?
'yes'
: 'no',
},
},
compounds: {},
});
var v1_default = schema({
version: 1,
collections: {
categories: categoryCollection,
foodCategoryLookups: foodCategoryLookupCollection,
items: itemCollection
}
version: 1,
collections: {
categories: categoryCollection,
foodCategoryLookups: foodCategoryLookupCollection,
items: itemCollection,
},
});
export {
categoryCollection,
v1_default as default,
foodCategoryLookupCollection,
itemCollection
categoryCollection,
v1_default as default,
foodCategoryLookupCollection,
itemCollection,
};
Loading

0 comments on commit 3d9b02c

Please sign in to comment.