tosijs-ui 1.0.4 → 1.0.6

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.
@@ -1,4 +1,5 @@
1
- import { Component as WebComponent, ElementCreator } from 'tosijs';
1
+ import { Component as WebComponent, ElementCreator, PartsMap } from 'tosijs';
2
+ import { XinSelect } from './select';
2
3
  type ObjectTest = (obj: any) => boolean;
3
4
  type ArrayFilter = (array: any[]) => any[];
4
5
  interface FilterMaker {
@@ -23,7 +24,13 @@ export interface FilterPartState {
23
24
  condition: string;
24
25
  needle: string;
25
26
  }
26
- export declare class FilterPart extends WebComponent {
27
+ interface FilterPartParts extends PartsMap {
28
+ haystack: XinSelect;
29
+ condition: XinSelect;
30
+ needle: HTMLInputElement;
31
+ remove: HTMLButtonElement;
32
+ }
33
+ export declare class FilterPart extends WebComponent<FilterPartParts> {
27
34
  fields: Fields;
28
35
  filters: {
29
36
  [key: string]: FilterMaker;
@@ -31,7 +38,7 @@ export declare class FilterPart extends WebComponent {
31
38
  haystack: string;
32
39
  condition: string;
33
40
  needle: string;
34
- content: () => (SVGElement | HTMLSpanElement)[];
41
+ content: () => HTMLSpanElement[];
35
42
  filter: Filter;
36
43
  constructor();
37
44
  get state(): FilterPartState;
@@ -42,7 +49,11 @@ export declare class FilterPart extends WebComponent {
42
49
  }
43
50
  export declare const filterPart: ElementCreator<FilterPart>;
44
51
  export type FilterState = FilterPartState[];
45
- export declare class FilterBuilder extends WebComponent {
52
+ export interface FilterBuilderParts extends PartsMap {
53
+ add: HTMLButtonElement;
54
+ resent: HTMLButtonElement;
55
+ }
56
+ export declare class FilterBuilder extends WebComponent<FilterBuilderParts> {
46
57
  private _fields;
47
58
  get fields(): Fields;
48
59
  set fields(_fields: Fields);