reinstate profile.hamlet
This commit is contained in:
parent
ed9c1ce461
commit
3b14a4f03d
@ -116,10 +116,11 @@ postProfileR = do
|
||||
|
||||
siteLayout [whamlet|_{MsgProfileFor} ^{nameWidget userDisplayName userSurname}|] $ do
|
||||
setTitle . toHtml $ "Profil " <> userIdent
|
||||
wrapForm formWidget def
|
||||
{ formAction = Just $ SomeRoute ProfileR
|
||||
, formEncoding = formEnctype
|
||||
}
|
||||
let settingsForm = wrapForm formWidget def
|
||||
{ formAction = Just $ SomeRoute ProfileR
|
||||
, formEncoding = formEnctype
|
||||
}
|
||||
$(widgetFile "profile")
|
||||
|
||||
|
||||
getProfileDataR :: Handler Html
|
||||
|
||||
@ -44,30 +44,3 @@ if (I18n) {
|
||||
document.addEventListener('DOMContentLoaded', function() {
|
||||
setupDatepicker(document.body);
|
||||
});
|
||||
|
||||
/**
|
||||
* The following code should be moved to profile.julius as soon as the widget file is actually used.
|
||||
*/
|
||||
(function() {
|
||||
'use strict';
|
||||
|
||||
var DEFAULT_THEME = 'theme--default';
|
||||
|
||||
document.addEventListener('DOMContentLoaded', function() {
|
||||
|
||||
var themeSwitcher = document.querySelector('#theme-select');
|
||||
var currentTheme = DEFAULT_THEME;
|
||||
|
||||
if (themeSwitcher) {
|
||||
currentTheme = 'theme--' + themeSwitcher.value;
|
||||
themeSwitcher.addEventListener('input', function() {
|
||||
|
||||
var desiredTheme = 'theme--' + themeSwitcher.value;
|
||||
document.body.classList.remove(currentTheme);
|
||||
document.body.classList.add(desiredTheme);
|
||||
currentTheme = desiredTheme;
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
})();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user