-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Switched from vue-material to mdl #2
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some weird things (like the max-height on the expandable items, or the manual DOM manipulations on checkboxes), but really nice overall, great job!
Some of the changes can be done later (like moving things into components), but some needs to be fixed before I can merge
src/components/layout/ExpandList.vue
Outdated
} | ||
.expand-list.expanded { | ||
overflow: visible; | ||
max-height: 1024px; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This makes the closing animation really weird.
Ideally this value is calculated on the fly when opening, and set to the element
</template> | ||
|
||
<script> | ||
import router from '@/router'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this needed?
<div class="mdl-layout-spacer"></div> | ||
|
||
<!-- Actions --> | ||
<button class="mdl-button mdl-js-button mdl-button--icon"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe move this in a component with a sane lifecycle (and not a global DOM upgrade after each transition)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(doesn't have to be in this PR though)
</button> | ||
|
||
<!-- Menu --> | ||
<ul class="mdl-menu mdl-menu--bottom-right mdl-js-menu mdl-js-ripple-effect" for="header-menu-lower-right"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same as for the buttons, as it will certainly be reused
} | ||
.expand-list.expanded { | ||
overflow: visible; | ||
max-height: 1024px; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here
|
||
<script> | ||
export default { | ||
name: 'expand-list-two', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
those could have been one component with some props
@@ -60,10 +68,30 @@ export default { | |||
}, | |||
}, | |||
computed: mapGetters('jmap', ['mailboxes']), | |||
mounted() { | |||
const table = document.querySelector('table'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this seems hacky as fuck. wth
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's just that the checkboxes feature are depreciated for this mdl version and that's the patch for making it working again.
See https://github.com/google/material-design-lite/wiki/Deprecations#automatic-selection-checkboxes for more informations about it..
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no, minimal-ui"> | ||
</head> | ||
<body> | ||
<div id="app"></div> | ||
<script src="//code.getmdl.io/1.3.0/material.min.js"></script> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this will need to be integrated in the build pipeline somehow. Will do later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, will do later.
@@ -0,0 +1,42 @@ | |||
<template> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
those header could be refactored
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
have a generic header with a named route view for tabs & buttons?
src/components/headers/Default.vue
Outdated
@@ -0,0 +1,42 @@ | |||
<template> | |||
<header class="mdl-layout__header"> | |||
<div class="mdl-layout__header-row"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No hamburger button for closing the sidebar?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No hamburger button for closing the sidebar for the desktop version yet; not a priority for the moment. Will do later.
Removed vue-material for Material Design Lite instead, for performances reasons.
All fonctionalities that worked before are also working well here, and I added the support for custom header bar depending of routes.