@pastelarai/pastelarai-shared-types 1.0.46 → 1.0.48

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.
@@ -18,7 +18,7 @@ export interface DaySummary {
18
18
  last_week: number;
19
19
  last_month: number;
20
20
  };
21
- production_day_by_tm: ProductionDayByTM;
22
- production_day_content: ContentDayProd;
23
- sales_plan_day: SalesPlanDay;
21
+ production_day_by_tm_list: ProductionDayByTM[] | null;
22
+ production_day_content: ContentDayProd | null;
23
+ sales_plan_day: SalesPlanDay | null;
24
24
  }
@@ -0,0 +1,2 @@
1
+ export declare const normalizeName: (name: string) => string;
2
+ export declare const generateId: (name: string) => string;
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.generateId = exports.normalizeName = void 0;
4
+ const normalizeName = (name) => {
5
+ if (!name)
6
+ return "";
7
+ return name.charAt(0).toUpperCase() + name.slice(1).toLowerCase();
8
+ };
9
+ exports.normalizeName = normalizeName;
10
+ // Utility function to generate _id from the name by normalizing it
11
+ const generateId = (name) => {
12
+ return name
13
+ .toLowerCase()
14
+ .trim()
15
+ .replace(/\s+/g, "-") // Replace spaces with dashes
16
+ .replace(/[^a-z0-9-]/g, ""); // Remove non-alphanumeric characters
17
+ };
18
+ exports.generateId = generateId;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pastelarai/pastelarai-shared-types",
3
- "version": "1.0.46",
3
+ "version": "1.0.48",
4
4
  "description": "Shared types for PastelarAI",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",