Ohm-Management - Projektarbeit B-ME
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

rippleable.js 992B

123456789101112131415161718192021222324252627282930313233
  1. // Directives
  2. import Ripple from '../directives/ripple';
  3. // Types
  4. import Vue from 'vue';
  5. export default Vue.extend({
  6. name: 'rippleable',
  7. directives: { Ripple: Ripple },
  8. props: {
  9. ripple: {
  10. type: [Boolean, Object],
  11. default: true
  12. }
  13. },
  14. methods: {
  15. genRipple: function genRipple() {
  16. var data = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  17. if (!this.ripple) return null;
  18. data.staticClass = 'v-input--selection-controls__ripple';
  19. data.directives = data.directives || [];
  20. data.directives.push({
  21. name: 'ripple',
  22. value: { center: true }
  23. });
  24. data.on = Object.assign({
  25. click: this.onChange
  26. }, this.$listeners);
  27. return this.$createElement('div', data);
  28. },
  29. onChange: function onChange() {}
  30. }
  31. });
  32. //# sourceMappingURL=rippleable.js.map