Skip to content
This repository has been archived by the owner on Nov 30, 2020. It is now read-only.

Commit

Permalink
feat(notched-outline): Synchronise with mdc-web v0.33.0 (add component)
Browse files Browse the repository at this point in the history
  • Loading branch information
matsp committed Mar 23, 2018
1 parent c07500b commit bbfa8eb
Show file tree
Hide file tree
Showing 5 changed files with 57 additions and 0 deletions.
29 changes: 29 additions & 0 deletions components/notched-outline/NotchedOutline.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<script>
import { MDCNotchedOutline } from '@material/notched-outline'
import themeClassMixin from '../base/themeClassMixin.js'
export default {
functional: true,
mixins: [themeClassMixin],
data () {
return {
mdcNotchedOutline: null
}
},
mounted () {
this.mdcNotchedOutline = MDCNotchedOutline.attachTo(this.$el)
},
render (h) {
return [
h('div', {'class': 'mdc-notched-outline'},
[
h('svg', [
h('path', {'class': 'mdc-notched-outline__path'})
])
]
),
h('div', {'class': 'mdc-notched-outline__idle'})]
}
}
</script>
13 changes: 13 additions & 0 deletions components/notched-outline/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
## NotchedOutline

### Markup

```html
<m-textfield
outlined
id="outlined">
<m-floating-label for="outlined">Outlined</m-floating-label>
<m-notched-outline />
</m-textfield>
```

13 changes: 13 additions & 0 deletions components/notched-outline/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import NotchedOutline from './NotchedOutline.vue'
import './styles.scss'

import { initPlugin } from '../'

const plugin = {
install (vm) {
vm.component('m-notched-outline', NotchedOutline)
}
}
export default plugin

initPlugin(plugin)
1 change: 1 addition & 0 deletions components/notched-outline/styles.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@import "@material/notched-outline/mdc-notched-outline";
1 change: 1 addition & 0 deletions webpack.config.lib.common.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ module.exports = {
'line-ripple': path.resolve(components + '/line-ripple/index.js'),
list: path.resolve(components + '/list/index.js'),
menu: path.resolve(components + '/menu/index.js'),
'notched-outline': path.resolve(components + '/notched-outline/index.js'),
radio: path.resolve(components + '/radio/index.js'),
ripple: path.resolve(components + '/ripple/index.js'),
select: path.resolve(components + '/select/index.js'),
Expand Down

0 comments on commit bbfa8eb

Please sign in to comment.