@fayz-ai/plugin-inventory 0.14.1 → 0.15.1

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 (57) hide show
  1. package/dist/data/registries.d.ts.map +1 -1
  2. package/dist/data/supabase.d.ts.map +1 -1
  3. package/dist/data/tables.d.ts +3 -1
  4. package/dist/data/tables.d.ts.map +1 -1
  5. package/dist/data/types.d.ts +41 -1
  6. package/dist/data/types.d.ts.map +1 -1
  7. package/dist/index.js +3346 -901
  8. package/dist/index.js.map +1 -1
  9. package/dist/lib/recipe-cost.d.ts +8 -2
  10. package/dist/lib/recipe-cost.d.ts.map +1 -1
  11. package/dist/lib/recipe-units.d.ts +26 -0
  12. package/dist/lib/recipe-units.d.ts.map +1 -0
  13. package/dist/lib/setup-guides.d.ts.map +1 -1
  14. package/dist/locales/en.d.ts.map +1 -1
  15. package/dist/locales/pt-BR.d.ts.map +1 -1
  16. package/dist/migrations/index.d.ts +2 -0
  17. package/dist/migrations/index.d.ts.map +1 -1
  18. package/dist/types.d.ts +156 -0
  19. package/dist/types.d.ts.map +1 -1
  20. package/dist/views/GapScreens.d.ts +0 -10
  21. package/dist/views/GapScreens.d.ts.map +1 -1
  22. package/dist/views/InventoryPage.d.ts.map +1 -1
  23. package/dist/views/ProductComplementsTab.d.ts +7 -0
  24. package/dist/views/ProductComplementsTab.d.ts.map +1 -0
  25. package/dist/views/ProductDetailView.d.ts.map +1 -1
  26. package/dist/views/ProductRecipeTab.d.ts +7 -3
  27. package/dist/views/ProductRecipeTab.d.ts.map +1 -1
  28. package/dist/views/RecipesView.d.ts +3 -5
  29. package/dist/views/RecipesView.d.ts.map +1 -1
  30. package/dist/views/productEntity.d.ts.map +1 -1
  31. package/dist/views/recipe/GenerateImageDialog.d.ts +9 -0
  32. package/dist/views/recipe/GenerateImageDialog.d.ts.map +1 -0
  33. package/dist/views/recipe/IngredientCostDialog.d.ts +10 -0
  34. package/dist/views/recipe/IngredientCostDialog.d.ts.map +1 -0
  35. package/dist/views/recipe/QuickIngredientDialog.d.ts +14 -0
  36. package/dist/views/recipe/QuickIngredientDialog.d.ts.map +1 -0
  37. package/dist/views/recipe/RecipeAiDialog.d.ts +10 -0
  38. package/dist/views/recipe/RecipeAiDialog.d.ts.map +1 -0
  39. package/dist/views/recipe/RecipeEditor.d.ts +8 -0
  40. package/dist/views/recipe/RecipeEditor.d.ts.map +1 -0
  41. package/dist/views/recipe/SelectProductDialog.d.ts +12 -0
  42. package/dist/views/recipe/SelectProductDialog.d.ts.map +1 -0
  43. package/dist/views/recipe/TransformIntermediateDialog.d.ts +15 -0
  44. package/dist/views/recipe/TransformIntermediateDialog.d.ts.map +1 -0
  45. package/dist/views/recipe/exportRecipesXlsx.d.ts +3 -0
  46. package/dist/views/recipe/exportRecipesXlsx.d.ts.map +1 -0
  47. package/dist/views/recipe/printRecipe.d.ts +8 -0
  48. package/dist/views/recipe/printRecipe.d.ts.map +1 -0
  49. package/dist/views/recipe/shared.d.ts +12 -0
  50. package/dist/views/recipe/shared.d.ts.map +1 -0
  51. package/package.json +4 -4
  52. package/dist/components/RecipeGapsPanel.d.ts +0 -14
  53. package/dist/components/RecipeGapsPanel.d.ts.map +0 -1
  54. package/dist/views/RecipeDetailView.d.ts +0 -6
  55. package/dist/views/RecipeDetailView.d.ts.map +0 -1
  56. package/dist/views/RecipeFormView.d.ts +0 -7
  57. package/dist/views/RecipeFormView.d.ts.map +0 -1
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RecipeEditor.d.ts","sourceRoot":"","sources":["../../../src/views/recipe/RecipeEditor.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoD,MAAM,OAAO,CAAA;AASxE,OAAO,KAAK,EACV,OAAO,EACR,MAAM,aAAa,CAAA;AAiDpB,wBAAgB,YAAY,CAAC,EAAE,OAAO,EAAE,OAAO,EAAE,EAAE;IACjD,OAAO,EAAE,OAAO,CAAA;IAChB,0DAA0D;IAC1D,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;CACrB,qBAspBA"}
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ /**
3
+ * "Nova Ficha Técnica" creates nothing: it picks the product whose sheet opens.
4
+ * Same picker as a new order — photo, search, price. Only what a sheet makes
5
+ * sense for is offered: sold, intermediate or already produced. A pure
6
+ * ingredient is bought, not produced.
7
+ */
8
+ export declare function SelectProductDialog({ onClose, onPick }: {
9
+ onClose: () => void;
10
+ onPick: (productId: string) => void;
11
+ }): React.JSX.Element;
12
+ //# sourceMappingURL=SelectProductDialog.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SelectProductDialog.d.ts","sourceRoot":"","sources":["../../../src/views/recipe/SelectProductDialog.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAgC,MAAM,OAAO,CAAA;AAOpD;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE;IACvD,OAAO,EAAE,MAAM,IAAI,CAAA;IACnB,MAAM,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAA;CACpC,qBAwCA"}
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ import type { MeasurementUnit, RecipeSheetGroup } from '../../types';
3
+ /**
4
+ * ⋮ → "Transformar em produto intermediário": a new Intermediário product with
5
+ * this block as its own sheet. Written on confirm, as in V1 (V1-084) — the
6
+ * difference is that its sheet goes through the same atomic save.
7
+ */
8
+ export declare function TransformIntermediateDialog({ defaultName, units, group, onClose, onCreated }: {
9
+ defaultName: string;
10
+ units: MeasurementUnit[];
11
+ group: Omit<RecipeSheetGroup, 'name'>;
12
+ onClose: () => void;
13
+ onCreated: (productId: string) => void;
14
+ }): React.JSX.Element;
15
+ //# sourceMappingURL=TransformIntermediateDialog.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TransformIntermediateDialog.d.ts","sourceRoot":"","sources":["../../../src/views/recipe/TransformIntermediateDialog.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAA;AAQvC,OAAO,KAAK,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAA;AAEpE;;;;GAIG;AACH,wBAAgB,2BAA2B,CAAC,EAAE,WAAW,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,SAAS,EAAE,EAAE;IAC7F,WAAW,EAAE,MAAM,CAAA;IACnB,KAAK,EAAE,eAAe,EAAE,CAAA;IACxB,KAAK,EAAE,IAAI,CAAC,gBAAgB,EAAE,MAAM,CAAC,CAAA;IACrC,OAAO,EAAE,MAAM,IAAI,CAAA;IACnB,SAAS,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAA;CACvC,qBAsFA"}
@@ -0,0 +1,3 @@
1
+ import type { RecipeExportSheet } from '../../types';
2
+ export declare function exportRecipesXlsx(sheets: RecipeExportSheet[], brand?: string): Promise<void>;
3
+ //# sourceMappingURL=exportRecipesXlsx.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"exportRecipesXlsx.d.ts","sourceRoot":"","sources":["../../../src/views/recipe/exportRecipesXlsx.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAA;AAgBpD,wBAAsB,iBAAiB,CAAC,MAAM,EAAE,iBAAiB,EAAE,EAAE,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CA2KlG"}
@@ -0,0 +1,8 @@
1
+ import type { InventoryDataProvider } from '../../data/types';
2
+ import type { RecipeListRow } from '../../types';
3
+ /**
4
+ * The printable sheet, as V1 prints it, plus what V1 left out: components by
5
+ * station and the preparation text. Opens in a new window and calls print.
6
+ */
7
+ export declare function printRecipe(provider: InventoryDataProvider, row: RecipeListRow): Promise<void>;
8
+ //# sourceMappingURL=printRecipe.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"printRecipe.d.ts","sourceRoot":"","sources":["../../../src/views/recipe/printRecipe.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,kBAAkB,CAAA;AAC7D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAQhD;;;GAGG;AACH,wBAAsB,WAAW,CAAC,QAAQ,EAAE,qBAAqB,EAAE,GAAG,EAAE,aAAa,GAAG,OAAO,CAAC,IAAI,CAAC,CAuEpG"}
@@ -0,0 +1,12 @@
1
+ import { useSaveBar } from '@fayz-ai/ui';
2
+ export declare const brl: (v: number) => string;
3
+ /** The kit has no textarea; this matches its Input. */
4
+ export declare const TEXTAREA = "w-full rounded-input border border-input bg-card px-3 py-2 text-sm shadow-[inset_0_1px_0_rgb(0_0_0_/0.06)] placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring resize-y";
5
+ /**
6
+ * Registers a tab's form with the page's save bar. Rendered only once the tab
7
+ * has loaded: the product page registers its own (clean) entry, and the bar
8
+ * shows the most recently mounted one — mounting after the page puts the
9
+ * tab's on top.
10
+ */
11
+ export declare function SaveBarSlot(props: Parameters<typeof useSaveBar>[0]): null;
12
+ //# sourceMappingURL=shared.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shared.d.ts","sourceRoot":"","sources":["../../../src/views/recipe/shared.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAA;AACxC,eAAO,MAAM,GAAG,GAAI,GAAG,MAAM,WACqD,CAAA;AAElF,uDAAuD;AACvD,eAAO,MAAM,QAAQ,0MACoL,CAAA;AAEzM;;;;;GAKG;AACH,wBAAgB,WAAW,CAAC,KAAK,EAAE,UAAU,CAAC,OAAO,UAAU,CAAC,CAAC,CAAC,CAAC,QAGlE"}
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "status": "beta",
5
5
  "dependencies": []
6
6
  },
7
- "version": "0.14.1",
7
+ "version": "0.15.1",
8
8
  "description": "Fayz SDK — plugin-inventory plugin",
9
9
  "type": "module",
10
10
  "sideEffects": false,
@@ -28,9 +28,9 @@
28
28
  },
29
29
  "dependencies": {
30
30
  "@tanstack/react-table": "^8.20.0",
31
- "@fayz-ai/core": "^0.36.1",
32
- "@fayz-ai/ui": "^0.37.0",
33
- "@fayz-ai/admin": "^0.37.0"
31
+ "@fayz-ai/core": "^0.39.0",
32
+ "@fayz-ai/ui": "^0.39.0",
33
+ "@fayz-ai/admin": "^0.39.0"
34
34
  },
35
35
  "devDependencies": {
36
36
  "@types/react": "^18.3.0",
@@ -1,14 +0,0 @@
1
- import React from 'react';
2
- import type { Recipe, RecipeGaps } from '../types';
3
- /**
4
- * What the assistant proposed and could not match to the catalogue, offered
5
- * back for the user to pick or create. Without this the AI path dead-ends on
6
- * "she mentioned bacon and it is not in the recipe" — the recovery loop is what
7
- * made the legacy feature usable.
8
- */
9
- export declare function RecipeGapsPanel({ recipe, gaps, onResolved }: {
10
- recipe: Recipe;
11
- gaps: RecipeGaps;
12
- onResolved: () => void | Promise<void>;
13
- }): React.JSX.Element | null;
14
- //# sourceMappingURL=RecipeGapsPanel.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"RecipeGapsPanel.d.ts","sourceRoot":"","sources":["../../src/components/RecipeGapsPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAA;AAKvC,OAAO,KAAK,EAAW,MAAM,EAAE,UAAU,EAAE,MAAM,UAAU,CAAA;AAE3D;;;;;GAKG;AACH,wBAAgB,eAAe,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,UAAU,EAAE,EAAE;IAC5D,MAAM,EAAE,MAAM,CAAA;IACd,IAAI,EAAE,UAAU,CAAA;IAChB,UAAU,EAAE,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAA;CACvC,4BAiHA"}
@@ -1,6 +0,0 @@
1
- import React from 'react';
2
- export declare function RecipeDetailView({ recipeId, onBack }: {
3
- recipeId: string;
4
- onBack: () => void;
5
- }): React.JSX.Element;
6
- //# sourceMappingURL=RecipeDetailView.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"RecipeDetailView.d.ts","sourceRoot":"","sources":["../../src/views/RecipeDetailView.tsx"],"names":[],"mappings":"AACA,OAAO,KAAuC,MAAM,OAAO,CAAA;AAmD3D,wBAAgB,gBAAgB,CAAC,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE;IAAE,QAAQ,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,IAAI,CAAA;CAAE,qBA4P9F"}
@@ -1,7 +0,0 @@
1
- import React from 'react';
2
- export declare function RecipeFormView({ onSaved, productId: initialProductId }: {
3
- onSaved?: (id?: string) => void;
4
- /** Menu item this ficha is for, when the list started it from a missing row. */
5
- productId?: string;
6
- }): React.JSX.Element;
7
- //# sourceMappingURL=RecipeFormView.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"RecipeFormView.d.ts","sourceRoot":"","sources":["../../src/views/RecipeFormView.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAA;AAuBlD,wBAAgB,cAAc,CAAC,EAAE,OAAO,EAAE,SAAS,EAAE,gBAAgB,EAAE,EAAE;IACvE,OAAO,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,MAAM,KAAK,IAAI,CAAA;IAC/B,gFAAgF;IAChF,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,qBAuOA"}