@klippa/ngx-enhancy-forms 16.7.0 → 16.7.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,6 +1,7 @@
1
1
  import * as i0 from "@angular/core";
2
+ export type ButtonVariant = 'white' | 'greenFilled' | 'greenOutlined' | 'greenLink' | 'contextMenuItem' | 'redFilled' | 'redOutlined' | 'orangeFilled';
2
3
  export declare class ButtonComponent {
3
- variant: 'white' | 'greenFilled' | 'greenOutlined' | 'greenLink' | 'contextMenuItem' | 'redFilled' | 'redOutlined' | 'orangeFilled';
4
+ variant: ButtonVariant;
4
5
  size: 'small' | 'medium' | 'large';
5
6
  fullWidth: boolean;
6
7
  hasBorder: boolean;
@@ -1,4 +1,4 @@
1
- import { AfterViewInit, ElementRef, EventEmitter, InjectionToken, OnChanges, SimpleChanges, TemplateRef } from '@angular/core';
1
+ import { AfterViewInit, ElementRef, EventEmitter, InjectionToken, OnChanges, OnDestroy, SimpleChanges, TemplateRef } from '@angular/core';
2
2
  import { ControlContainer } from '@angular/forms';
3
3
  import { ValueAccessorBase } from '../value-accessor-base/value-accessor-base.component';
4
4
  import { FormElementComponent } from '../../form/form-element/form-element.component';
@@ -16,7 +16,7 @@ export declare class KlpSelectOptionTemplateDirective {
16
16
  static ɵfac: i0.ɵɵFactoryDeclaration<KlpSelectOptionTemplateDirective, never>;
17
17
  static ɵdir: i0.ɵɵDirectiveDeclaration<KlpSelectOptionTemplateDirective, "[klpSelectOptionTpl]", never, {}, {}, never, never, false, never>;
18
18
  }
19
- export declare class SelectComponent extends ValueAccessorBase<string | string[]> implements OnChanges, AfterViewInit {
19
+ export declare class SelectComponent extends ValueAccessorBase<string | string[]> implements OnChanges, AfterViewInit, OnDestroy {
20
20
  protected parent: FormElementComponent;
21
21
  protected controlContainer: ControlContainer;
22
22
  private translations;
@@ -44,12 +44,14 @@ export declare class SelectComponent extends ValueAccessorBase<string | string[]
44
44
  onClosed: EventEmitter<void>;
45
45
  onBlur: EventEmitter<void>;
46
46
  onClear: EventEmitter<void>;
47
+ onEnterKey: EventEmitter<string>;
47
48
  ngSelect: any;
48
49
  customOptionTpl: TemplateRef<any>;
49
50
  private lastItemIndexReached;
50
51
  dropdownPositionToUse: 'auto' | 'bottom' | 'top' | 'left' | 'right';
51
52
  constructor(parent: FormElementComponent, controlContainer: ControlContainer, translations: any, elRef: ElementRef);
52
53
  ngAfterViewInit(): void;
54
+ private keyListener;
53
55
  private addPrefix;
54
56
  ngOnChanges(changes: SimpleChanges): void;
55
57
  getDefaultTranslation(key: string): (x: any) => string;
@@ -61,7 +63,9 @@ export declare class SelectComponent extends ValueAccessorBase<string | string[]
61
63
  private determineDropdownPosition;
62
64
  private isLimitingContainer;
63
65
  focus: () => void;
66
+ close: () => void;
64
67
  onClose(): void;
68
+ ngOnDestroy(): void;
65
69
  static ɵfac: i0.ɵɵFactoryDeclaration<SelectComponent, [{ optional: true; host: true; }, { optional: true; host: true; }, { optional: true; }, null]>;
66
- static ɵcmp: i0.ɵɵComponentDeclaration<SelectComponent, "klp-form-select", never, { "placeholder": { "alias": "placeholder"; "required": false; }; "prefix": { "alias": "prefix"; "required": false; }; "orientation": { "alias": "orientation"; "required": false; }; "options": { "alias": "options"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "multipleDisplayedAsAmount": { "alias": "multipleDisplayedAsAmount"; "required": false; }; "clearable": { "alias": "clearable"; "required": false; }; "truncateOptions": { "alias": "truncateOptions"; "required": false; }; "withSeparatingLine": { "alias": "withSeparatingLine"; "required": false; }; "searchable": { "alias": "searchable"; "required": false; }; "dropdownPosition": { "alias": "dropdownPosition"; "required": false; }; "customSearchFn": { "alias": "customSearchFn"; "required": false; }; "footerElement": { "alias": "footerElement"; "required": false; }; }, { "onSearch": "onSearch"; "onEndReached": "onEndReached"; "onOpened": "onOpened"; "onClosed": "onClosed"; "onBlur": "onBlur"; "onClear": "onClear"; }, ["customOptionTpl"], never, false, never>;
70
+ static ɵcmp: i0.ɵɵComponentDeclaration<SelectComponent, "klp-form-select", never, { "placeholder": { "alias": "placeholder"; "required": false; }; "prefix": { "alias": "prefix"; "required": false; }; "orientation": { "alias": "orientation"; "required": false; }; "options": { "alias": "options"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "multipleDisplayedAsAmount": { "alias": "multipleDisplayedAsAmount"; "required": false; }; "clearable": { "alias": "clearable"; "required": false; }; "truncateOptions": { "alias": "truncateOptions"; "required": false; }; "withSeparatingLine": { "alias": "withSeparatingLine"; "required": false; }; "searchable": { "alias": "searchable"; "required": false; }; "dropdownPosition": { "alias": "dropdownPosition"; "required": false; }; "customSearchFn": { "alias": "customSearchFn"; "required": false; }; "footerElement": { "alias": "footerElement"; "required": false; }; }, { "onSearch": "onSearch"; "onEndReached": "onEndReached"; "onOpened": "onOpened"; "onClosed": "onClosed"; "onBlur": "onBlur"; "onClear": "onClear"; "onEnterKey": "onEnterKey"; }, ["customOptionTpl"], never, false, never>;
67
71
  }
@@ -1,10 +1,12 @@
1
1
  import { FormComponent } from '../form.component';
2
+ import { ButtonVariant } from '../../elements/button/button.component';
2
3
  import * as i0 from "@angular/core";
4
+ export type SubmitButtonVariant = Extract<ButtonVariant, 'greenFilled' | 'redFilled' | 'greenOutlined' | 'white'>;
3
5
  export declare class FormSubmitButtonComponent {
4
6
  private parentForm;
5
7
  isLoading: boolean;
6
8
  fullWidth: boolean;
7
- variant: 'greenFilled' | 'redFilled' | 'greenOutlined';
9
+ variant: SubmitButtonVariant;
8
10
  before: () => Promise<any>;
9
11
  after: () => Promise<any>;
10
12
  submitCallback: (renderedAndEnabledValues: object, renderedButDisabledValues: object) => Promise<any>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@klippa/ngx-enhancy-forms",
3
- "version": "16.7.0",
3
+ "version": "16.7.6",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },