Skip to content
This repository was archived by the owner on Jan 22, 2018. It is now read-only.

Commit 1435a53

Browse files
author
Kamil Kisiela
committed
Merge branch 'release/v0.4.0'
2 parents 9e0a0ef + c9c32b4 commit 1435a53

File tree

12 files changed

+110
-18
lines changed

12 files changed

+110
-18
lines changed

CHANGELOG.md

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,15 @@
22
All notable changes to this project will be documented in this file.
33
This project adheres to [Semantic Versioning](http://semver.org/).
44

5+
## [0.4.0] - 2015-11-17
6+
### Added
7+
- **md-chip** with placeholder, secondary-placeholder, delete-button-label and delete-hint
8+
9+
### Deprecated
10+
- **mdInputContainer** wrapper. Use **inputContainer**
11+
- **mdMessages** wrapper. Use **messages**
12+
- **mdLabel** wrapper. Use **label**
13+
514
## [0.3.0] - 2015-11-17
615
### Added
716
- datepicker with date range and filtering _(currently in angular-material 1.0_RC4)_
@@ -42,9 +51,10 @@ This project adheres to [Semantic Versioning](http://semver.org/).
4251

4352
## 0.0.1 - 2015-11-06
4453

45-
[0.3.0]: https://github.com/kamilkisiela/meteor-angular-formly-templates-material/compare/v0.2.0...v0.3.0
46-
[0.2.0]: https://github.com/kamilkisiela/meteor-angular-formly-templates-material/compare/v0.1.0...v0.2.0
47-
[0.1.0]: https://github.com/kamilkisiela/meteor-angular-formly-templates-material/compare/v0.0.4...v0.1.0
48-
[0.0.4]: https://github.com/kamilkisiela/meteor-angular-formly-templates-material/compare/v0.0.3...v0.0.4
49-
[0.0.3]: https://github.com/kamilkisiela/meteor-angular-formly-templates-material/compare/v0.0.2...v0.0.3
50-
[0.0.2]: https://github.com/kamilkisiela/meteor-angular-formly-templates-material/compare/v0.0.1...v0.0.2
54+
[0.4.0]: https://github.com/wieldo/meteor-angular-formly-templates-material/compare/v0.3.0...v0.4.0
55+
[0.3.0]: https://github.com/wieldo/meteor-angular-formly-templates-material/compare/v0.2.0...v0.3.0
56+
[0.2.0]: https://github.com/wieldo/meteor-angular-formly-templates-material/compare/v0.1.0...v0.2.0
57+
[0.1.0]: https://github.com/wieldo/meteor-angular-formly-templates-material/compare/v0.0.4...v0.1.0
58+
[0.0.4]: https://github.com/wieldo/meteor-angular-formly-templates-material/compare/v0.0.3...v0.0.4
59+
[0.0.3]: https://github.com/wieldo/meteor-angular-formly-templates-material/compare/v0.0.2...v0.0.3
60+
[0.0.2]: https://github.com/wieldo/meteor-angular-formly-templates-material/compare/v0.0.1...v0.0.2

README.md

Lines changed: 36 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -183,15 +183,48 @@ md-filter-date
183183
}
184184
```
185185

186+
### chips
187+
188+
**placeholder (string, optional)**
189+
190+
placeholder attribute value
191+
192+
**secondaryPlaceholder (string, optional)**
193+
194+
secondary-placeholder attribute value
195+
196+
**deleteButtonLabel (string, optional)**
197+
198+
delete-button-label attribute value
199+
200+
**deleteHint (string, optional)**
201+
202+
delete-hint attribute value
203+
204+
```javascript
205+
{
206+
"type": "chips",
207+
"key": "tags",
208+
"templateOptions": {
209+
"theme": "custom",
210+
"placeholder": "+tags",
211+
"secondaryPlaceholder": "Add tag",
212+
"deleteButtonLabel": "Remove",
213+
"deleteHint": "Remove tag"
214+
}
215+
}
216+
```
217+
218+
186219
## Wrappers
187220

188-
- mdInputContainer
221+
- inputContainer (md-input-container)
189222
- label
190-
- ngMessages
223+
- messages (ng-messages)
191224

192225
## Roadmap
193226

194-
- [ ] add md-chips
227+
- [x] add md-chips
195228
- [x] add md-datepicker
196229
- [ ] add md-icon wrapper
197230
- [x] add md-select

lib/client/types/chips/chips.js

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
var {SetModule} = angular2now;
2+
3+
SetModule('formlyMaterial')
4+
.config((formlyConfigProvider, formlyMaterialProvider) => {
5+
6+
formlyConfigProvider.setType({
7+
name: 'chips',
8+
templateUrl: formlyMaterialProvider.templateUrl('lib/client/types/chips/chips.ng.html'),
9+
defaultOptions: {
10+
defaultValue: [],
11+
ngModelAttrs: {
12+
placeholder: {attribute: 'placeholder'},
13+
secondaryPlaceholder: {attribute: 'secondary-placeholder'},
14+
deleteButtonLabel: {attribute: 'delete-button-label'},
15+
deleteHint: {attribute: 'delete-hint'}
16+
}
17+
},
18+
apiCheck: (check) => ({
19+
templateOptions: {
20+
placeholder: check.string.optional,
21+
secondaryPlaceholder: check.string.optional,
22+
deleteButtonLabel: check.string.optional,
23+
deleteHint: check.string.optional
24+
}
25+
})
26+
});
27+
28+
});

lib/client/types/chips/chips.ng.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<md-chips ng-model="model[options.key]"></md-chips>

lib/client/types/datepicker/datepicker.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ SetModule('formlyMaterial')
66
formlyConfigProvider.setType({
77
name: 'datepicker',
88
templateUrl: formlyMaterialProvider.templateUrl('lib/client/types/datepicker/datepicker.ng.html'),
9-
wrapper: ['mdMessages'],
9+
wrapper: ['messages'],
1010
defaultOptions: {
1111
ngModelAttrs: {
1212
placeholder: {attribute: 'md-placeholder'}

lib/client/types/input/input.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ SetModule('formlyMaterial')
66
formlyConfigProvider.setType({
77
name: 'input',
88
templateUrl: formlyMaterialProvider.templateUrl('lib/client/types/input/input.ng.html'),
9-
wrapper: ['mdLabel', 'mdMessages', 'mdInputContainer'],
9+
wrapper: ['label', 'messages', 'inputContainer'],
1010
defaultOptions: {
1111
ngModelAttrs: {
1212
mdMaxlength: {

lib/client/types/select/select.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ SetModule('formlyMaterial')
66
formlyConfigProvider.setType({
77
name: 'select',
88
templateUrl: formlyMaterialProvider.templateUrl('lib/client/types/select/select.ng.html'),
9-
wrapper: ['mdLabel', 'mdMessages', 'mdInputContainer'],
9+
wrapper: ['label', 'messages', 'inputContainer'],
1010
apiCheck: (check) => ({
1111
templateOptions: {
1212
options: check.arrayOf(check.object),

lib/client/types/textarea/textarea.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ SetModule('formlyMaterial')
66
formlyConfigProvider.setType({
77
name: 'textarea',
88
templateUrl: formlyMaterialProvider.templateUrl('lib/client/types/textarea/textarea.ng.html'),
9-
wrapper: ['mdLabel', 'mdMessages', 'mdInputContainer'],
9+
wrapper: ['label', 'messages', 'inputContainer'],
1010
defaultOptions: {
1111
ngModelAttrs: {
1212
rows: {attribute: 'rows'},

lib/client/wrappers/input-container/input-container.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,17 @@ var {SetModule} = angular2now;
33
SetModule('formlyMaterial')
44
.config((formlyConfigProvider, formlyMaterialProvider) => {
55

6+
/**
7+
* @deprecated since version 0.4.0
8+
*/
69
formlyConfigProvider.setWrapper({
710
name: 'mdInputContainer',
811
templateUrl: formlyMaterialProvider.templateUrl('lib/client/wrappers/input-container/input-container.ng.html')
912
});
1013

14+
formlyConfigProvider.setWrapper({
15+
name: 'inputContainer',
16+
templateUrl: formlyMaterialProvider.templateUrl('lib/client/wrappers/input-container/input-container.ng.html')
17+
});
18+
1119
});

lib/client/wrappers/label/label.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ SetModule('formlyMaterial')
44
.config((formlyConfigProvider, formlyMaterialProvider) => {
55

66
formlyConfigProvider.setWrapper({
7-
name: 'mdLabel',
7+
name: 'label',
88
templateUrl: formlyMaterialProvider.templateUrl('lib/client/wrappers/label/label.ng.html'),
99
apiCheck: (check) => ({
1010
templateOptions: {
@@ -13,4 +13,4 @@ SetModule('formlyMaterial')
1313
})
1414
});
1515

16-
});
16+
});

0 commit comments

Comments
 (0)