@d4l/collect-lib 1.10.0 → 1.10.2

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.
package/dist/index.d.mts CHANGED
@@ -115,7 +115,7 @@ interface SeenDisplay {
115
115
  */
116
116
  content?: DisplayContent;
117
117
  }
118
- type DisplayPath = `content.${DisplayContentPath}` | `content.blocks.${number}.image` | `content.blocks.${number}.text` | 'content.blocks' | `charts.${ProgramDeviceType}` | 'name' | `frequency.${keyof TaskFrequency}` | 'frequency';
118
+ type DisplayPath = RecursiveKeyOf<Display>;
119
119
 
120
120
  interface EligibilityScore {
121
121
  /**
@@ -525,7 +525,7 @@ type RecursiveKeyOf<TObj extends object> = {
525
525
  type RecursiveKeyOfInner<TObj extends object> = {
526
526
  [TKey in keyof TObj & (string | number)]: RecursiveKeyOfHandleValue<TObj[TKey], `.${TKey}`>;
527
527
  }[keyof TObj & (string | number)];
528
- type RecursiveKeyOfHandleValue<TValue, Text extends string> = TValue extends any[] ? Text : TValue extends object ? Text | `${Text}${RecursiveKeyOfInner<TValue>}` : Text;
528
+ type RecursiveKeyOfHandleValue<TValue, Text extends string> = TValue extends Function ? undefined : TValue extends any[] ? Text | `${Text}.${number}` | `${Text}.${number}${RecursiveKeyOfInner<TValue[0]>}` : TValue extends object ? Text | `${Text}${RecursiveKeyOfInner<TValue>}` : Text;
529
529
 
530
530
  declare function toDeviceConfig(devices: ProgramDevice[]): DeviceConfig[];
531
531
 
package/dist/index.d.ts CHANGED
@@ -115,7 +115,7 @@ interface SeenDisplay {
115
115
  */
116
116
  content?: DisplayContent;
117
117
  }
118
- type DisplayPath = `content.${DisplayContentPath}` | `content.blocks.${number}.image` | `content.blocks.${number}.text` | 'content.blocks' | `charts.${ProgramDeviceType}` | 'name' | `frequency.${keyof TaskFrequency}` | 'frequency';
118
+ type DisplayPath = RecursiveKeyOf<Display>;
119
119
 
120
120
  interface EligibilityScore {
121
121
  /**
@@ -525,7 +525,7 @@ type RecursiveKeyOf<TObj extends object> = {
525
525
  type RecursiveKeyOfInner<TObj extends object> = {
526
526
  [TKey in keyof TObj & (string | number)]: RecursiveKeyOfHandleValue<TObj[TKey], `.${TKey}`>;
527
527
  }[keyof TObj & (string | number)];
528
- type RecursiveKeyOfHandleValue<TValue, Text extends string> = TValue extends any[] ? Text : TValue extends object ? Text | `${Text}${RecursiveKeyOfInner<TValue>}` : Text;
528
+ type RecursiveKeyOfHandleValue<TValue, Text extends string> = TValue extends Function ? undefined : TValue extends any[] ? Text | `${Text}.${number}` | `${Text}.${number}${RecursiveKeyOfInner<TValue[0]>}` : TValue extends object ? Text | `${Text}${RecursiveKeyOfInner<TValue>}` : Text;
529
529
 
530
530
  declare function toDeviceConfig(devices: ProgramDevice[]): DeviceConfig[];
531
531
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@d4l/collect-lib",
3
- "version": "1.10.0",
3
+ "version": "1.10.2",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.mjs",
6
6
  "types": "./dist/index.d.ts",