dothtml-interfaces 0.3.4 → 0.3.7

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": "dothtml-interfaces",
3
- "version": "0.3.4",
3
+ "version": "0.3.7",
4
4
  "description": "Dependency injection interfaces for DOTHtml.",
5
5
  "main": "src/index.d.ts",
6
6
  "types": "src/index.d.ts",
package/src/i-dot.d.ts CHANGED
@@ -370,7 +370,7 @@ export interface IDotCore extends IDotDocument {
370
370
  navigate(path: string, noHistory?: boolean, force?: boolean): void;
371
371
  css: IDotCss;
372
372
  bus: IEventBus;
373
- // window: IDotWindowBuilder;
373
+ window: IDotWindowBuilder;
374
374
 
375
375
  watch<Ti = IReactive | Array<any> | { [key: string | number]: any } | string | number | boolean, To = Ti>(initValue?: Ti, props?: { key?: string, transformer?: (value: Ti) => To }): IReactive<Ti, To>;
376
376
 
@@ -388,8 +388,16 @@ export interface IDotCore extends IDotDocument {
388
388
  useStyles(document: Document, styles: Styles): HTMLStyleElement;
389
389
  }
390
390
 
391
+ export interface IDotWindowWrapper{
392
+ open(): void;
393
+ close(): void;
394
+ window: Window;
395
+ document: Document;
396
+ title: string;
397
+ }
398
+
391
399
  export interface IDotWindowBuilder {
392
- (content): Window;
400
+ (options: {content: IDotDocument, width: number, height: number, title: string}): IDotWindowWrapper;
393
401
  }
394
402
 
395
403
  export interface IDotConditionalDocument extends IDotDocument {
@@ -1,6 +1,6 @@
1
- import AngleProp from "./mapped-types/angle-prop";
2
- import { Percentage, ValueOrReactive } from "./css-types";
3
- import LengthProp from "./mapped-types/length-prop";
1
+ import AngleProp from "../mapped-types/angle-prop";
2
+ import { Percentage, ValueOrReactive } from "../css-types";
3
+ import LengthProp from "../mapped-types/length-prop";
4
4
  import IShadowProp from "./i-shadow-prop";
5
5
 
6
6
  export default interface IFilterProp extends
@@ -1,5 +1,5 @@
1
- import ColorProps from "./mapped-types/color-props.js";
2
- import LengthProp from "./mapped-types/length-prop.js";
1
+ import ColorProps from "../mapped-types/color-props.js";
2
+ import LengthProp from "../mapped-types/length-prop.js";
3
3
 
4
4
 
5
5
  export default interface IShadowProp extends
@@ -1,8 +1,10 @@
1
- import AngleProp from "./mapped-types/angle-prop";
2
- import { ValueOrReactive } from "./css-types";
3
- import LengthProp from "./mapped-types/length-prop";
1
+ import AngleProp from "../mapped-types/angle-prop";
2
+ import { ValueOrReactive } from "../css-types";
3
+ import LengthProp from "../mapped-types/length-prop";
4
4
 
5
- export interface ITransformationProp extends
5
+ // Transforms are special because the order matters and functions can be called mulitple times.
6
+ // To support this functionality, we use an array of transform JSON specs.
7
+ export default interface ITransformationProp extends
6
8
  LengthProp<"translate", 1|2>,
7
9
  LengthProp<"translate3d", 3>,
8
10
  LengthProp<"translateX">,
@@ -1,9 +1,9 @@
1
1
 
2
2
  import { IReactive } from "../i-reactive";
3
3
  import { GKV, ValueOrReactive } from "./css-types";
4
- import IFilterProp from "./i-filter-prop";
5
- import IShadowProp from "./i-shadow-prop";
6
- import { ITransformationProp } from "./i-transformation-prop";
4
+ import IFilterProp from "./complex-css-types/i-filter-prop";
5
+ import IShadowProp from "./complex-css-types/i-shadow-prop";
6
+ import ITransformationProp from "./complex-css-types/i-transformation-prop";
7
7
  import ColorProp from "./mapped-types/color-props";
8
8
  import LengthProp from "./mapped-types/length-prop";
9
9
 
@@ -79,7 +79,7 @@ export default interface IDotcssProp extends
79
79
  content?: ValueOrReactive<string>;
80
80
 
81
81
  //complex:
82
- transform?: ValueOrReactive<string>|ITransformationProp;
82
+ transform?: ValueOrReactive<string>|ITransformationProp|Array<ITransformationProp>;
83
83
  filter?: ValueOrReactive<string>|IFilterProp;
84
84
  backdropFilter?: ValueOrReactive<string>|IFilterProp;
85
85