@kigi/components 1.11.2 → 1.11.3-beta.1

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": "@kigi/components",
3
- "version": "1.11.2",
3
+ "version": "1.11.3-beta.1",
4
4
  "description": "@kigi/components",
5
5
  "main": "src/components/index.ts",
6
6
  "scripts": {
@@ -8,13 +8,7 @@ class MbgInputNumberController {
8
8
  private ngDisabled
9
9
  private props
10
10
 
11
- constructor(
12
- public $scope,
13
- public $element,
14
- public $attrs,
15
- public $compile,
16
- public $timeout
17
- ) { }
11
+ constructor(public $scope, public $element, public $attrs, public $compile, public $timeout) {}
18
12
 
19
13
  $onInit() {
20
14
  this.$timeout(() => {
@@ -28,7 +22,7 @@ class MbgInputNumberController {
28
22
  placeholder: this.$attrs.placeholder || '',
29
23
  precision: this.$attrs.precision || 0,
30
24
  allowNegative: this.$attrs.allowNegative ? JSON.parse(this.$attrs.allowNegative) : false,
31
- uiHideGroupSep: typeof this.$attrs.uiHideGroupSep !== undefined ? true : undefined
25
+ uiHideGroupSep: typeof this.$attrs.uiHideGroupSep !== undefined ? true : undefined,
32
26
  }
33
27
  if (this.$attrs.min) {
34
28
  this.props.min = this.$attrs.min
@@ -53,19 +47,12 @@ class MbgInputNumberController {
53
47
 
54
48
  onChange() {
55
49
  if (this.ngChange) {
56
- this.ngChange({})
50
+ this.ngChange({ newCount: this.ngModel })
57
51
  }
58
52
  }
59
-
60
53
  }
61
54
 
62
- MbgInputNumberController.$inject = [
63
- '$scope',
64
- '$element',
65
- '$attrs',
66
- '$compile',
67
- '$timeout'
68
- ]
55
+ MbgInputNumberController.$inject = ['$scope', '$element', '$attrs', '$compile', '$timeout']
69
56
 
70
57
  const mbgInputNumber = {
71
58
  bindings: {
@@ -76,7 +63,7 @@ const mbgInputNumber = {
76
63
  ngBlur: '&?',
77
64
  ngFocus: '&?',
78
65
  positive: '=?',
79
- ngModelOptions: '=?'
66
+ ngModelOptions: '=?',
80
67
  },
81
68
  template,
82
69
  controller: MbgInputNumberController,
@@ -45,6 +45,7 @@ class MbgSelectController {
45
45
  private getCustomModel: Function
46
46
  private capitalize
47
47
  private manyFavorite: boolean
48
+ private executeAfterOnInit: Function
48
49
 
49
50
  constructor(
50
51
  public $scope,
@@ -602,6 +603,9 @@ class MbgSelectController {
602
603
  favorite = MbgCookie.get(this.getFavoriteKey())
603
604
  if (favorite && this.enableFavorite && !this.ngModel) {
604
605
  this.selectOption(favorite)
606
+ if (this.executeAfterOnInit) {
607
+ this.executeAfterOnInit()
608
+ }
605
609
  }
606
610
  }, 300)
607
611
  }
@@ -699,6 +703,7 @@ const mbgSelect = {
699
703
  getCustomModel: '&?',
700
704
  capitalize: '=?',
701
705
  manyFavorite: '=?',
706
+ executeAfterOnInit: '&?',
702
707
  },
703
708
  controller: MbgSelectController,
704
709
  template,