editor-modal-media.vue 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. <template lang='pug'>
  2. v-card.editor-modal-media.animated.fadeInLeft(flat, tile)
  3. v-container.pa-3(grid-list-lg, fluid)
  4. v-layout(row, wrap)
  5. v-flex(xs3)
  6. v-card.radius-7.animated.fadeInLeft.wait-p1s(light)
  7. v-card-text
  8. file-pond(
  9. name='mediaUpload'
  10. ref='pond'
  11. label-idle='Drop files here...'
  12. allow-multiple='true'
  13. accepted-file-types='image/jpeg, image/png'
  14. :files='files'
  15. )
  16. v-flex(xs9)
  17. v-card.radius-7.animated.fadeInLeft.wait-p3s(light)
  18. v-card-text Beep boop
  19. </template>
  20. <script>
  21. // import _ from 'lodash'
  22. // import { sync } from 'vuex-pathify'
  23. import vueFilePond from 'vue-filepond'
  24. import 'filepond/dist/filepond.min.css'
  25. import 'filepond-plugin-image-preview/dist/filepond-plugin-image-preview.min.css'
  26. import FilePondPluginFileValidateType from 'filepond-plugin-file-validate-type'
  27. import FilePondPluginImagePreview from 'filepond-plugin-image-preview'
  28. const FilePond = vueFilePond(FilePondPluginFileValidateType, FilePondPluginImagePreview)
  29. export default {
  30. components: {
  31. FilePond
  32. },
  33. props: {
  34. value: {
  35. type: Boolean,
  36. default: false
  37. }
  38. },
  39. data() {
  40. return {
  41. files: []
  42. }
  43. },
  44. computed: {
  45. isShown: {
  46. get() { return this.value },
  47. set(val) { this.$emit('input', val) }
  48. }
  49. },
  50. methods: {
  51. }
  52. }
  53. </script>
  54. <style lang='scss'>
  55. .editor-modal-media {
  56. position: fixed;
  57. top: 112px;
  58. left: 64px;
  59. z-index: 10;
  60. width: calc(100vw - 64px - 17px);
  61. height: calc(100vh - 112px - 24px);
  62. background-color: rgba(darken(mc('grey', '900'), 3%), .9) !important;
  63. }
  64. </style>