This repository was archived by the owner on Apr 30, 2018. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +15
-4
lines changed Expand file tree Collapse file tree 3 files changed +15
-4
lines changed Original file line number Diff line number Diff line change
1
+ # 4.3.0
2
+
3
+ - Adding ` onClick ` to addons
4
+
1
5
# 4.2.0
2
6
3
7
- Allowing any type to have an addon.
Original file line number Diff line number Diff line change 1
1
< div ng-class ="{'input-group': to.addonLeft || to.addonRight} ">
2
- < div class ="input-group-addon " ng-if ="to.addonLeft ">
2
+ < div class ="input-group-addon "
3
+ ng-if ="to.addonLeft "
4
+ ng-style ="{cursor: to.addonLeft.onClick ? 'pointer' : 'inherit'} "
5
+ ng-click ="to.addonLeft.onClick(options, scope) ">
3
6
< i class ="{{to.addonLeft.class}} " ng-if ="to.addonLeft.class "> </ i >
4
7
< span ng-if ="to.addonLeft.text "> {{to.addonLeft.text}}</ span >
5
8
</ div >
6
9
< formly-transclude > </ formly-transclude >
7
- < div class ="input-group-addon " ng-if ="to.addonRight ">
10
+ < div class ="input-group-addon "
11
+ ng-if ="to.addonRight "
12
+ ng-style ="{cursor: to.addonRight.onClick ? 'pointer' : 'inherit'} "
13
+ ng-click ="to.addonRight.onClick(options, scope) ">
8
14
< i class ="{{to.addonRight.class}} " ng-if ="to.addonRight.class "> </ i >
9
15
< span ng-if ="to.addonRight.text "> {{to.addonRight.text}}</ span >
10
16
</ div >
11
- </ div >
17
+ </ div >
Original file line number Diff line number Diff line change @@ -5,7 +5,8 @@ export default ngModule => {
5
5
var addonTemplate = require ( './addons.html' ) ;
6
6
const addonChecker = formlyBootstrapApiCheck . shape ( {
7
7
class : formlyBootstrapApiCheck . string . optional ,
8
- text : formlyBootstrapApiCheck . string . optional
8
+ text : formlyBootstrapApiCheck . string . optional ,
9
+ onClick : formlyBootstrapApiCheck . func . optional
9
10
} ) . strict . optional ;
10
11
const api = formlyBootstrapApiCheck . shape ( {
11
12
templateOptions : formlyBootstrapApiCheck . shape ( {
You can’t perform that action at this time.
0 commit comments