mount-observer 0.0.51 → 0.0.52

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mount-observer",
3
- "version": "0.0.51",
3
+ "version": "0.0.52",
4
4
  "description": "Observe and act on css matches.",
5
5
  "main": "MountObserver.js",
6
6
  "module": "MountObserver.js",
@@ -3,6 +3,8 @@ import { HasIshList } from '../trans-render/dss/types';
3
3
 
4
4
  export interface EndUserProps extends IEnhancement{
5
5
  statement: string;
6
+ mapIdxTo: string;
7
+ idxStart: number;
6
8
  }
7
9
 
8
10
  export interface AllProps extends EndUserProps{
@@ -219,6 +219,7 @@ export type Compacts<TProps = any, TActions = TProps> =
219
219
  | Partial<{[key in `when_${keyof TProps & string}_changes_call_${keyof TActions & string}`]: number}>
220
220
  | Partial<{[key in `when_${keyof TProps & string}_changes_toggle_${keyof TProps & string}`]: number}>
221
221
  | Partial<{[key in `when_${keyof TProps & string}_changes_inc_${keyof TProps & string}_by`]: number}>
222
+ | Partial<{[key in `when_${keyof TProps & string}_changes_dispatch`]: string}> //TODO
222
223
  ;
223
224
 
224
225
  export type Hitches<TProps = any, TActions = TProps> =
@@ -455,7 +456,7 @@ export interface ICompact{
455
456
  interface CompactStatement {
456
457
  srcKey: string,
457
458
  destKey: string,
458
- op: 'toggle' | 'negate' | 'call' | 'pass_length' | 'echo' | 'inc',
459
+ op: 'toggle' | 'negate' | 'call' | 'pass_length' | 'echo' | 'inc' | 'dispatch',
459
460
  rhsIsDynamic: boolean
460
461
  }
461
462
 
package/waitForIsh.ts CHANGED
@@ -1,4 +1,4 @@
1
- export function waitForIsh(el: Element){
1
+ export function waitForIsh(el: Element) : Promise<EventTarget> {
2
2
  return new Promise((resolve, reject) => {
3
3
  const ish = (<any>el)['ish']; // [TODO] should we make this something that can
4
4
  // be passed in, more generic function -- waitForProperty?
@@ -7,7 +7,7 @@ export function waitForIsh(el: Element){
7
7
  } else {
8
8
  // If the element is not yet defined, wait for it to be defined
9
9
  el.addEventListener('ishAttached', () => {
10
- const ish = (<any>el)['ish'];
10
+ const ish = (<any>el)['ish'] as EventTarget;
11
11
  if (ish) {
12
12
  resolve(ish);
13
13
  } else {