Last active
May 11, 2017 07:46
-
-
Save denysdesign/090d857c58f555fe0af966ec5cd9431f to your computer and use it in GitHub Desktop.
Joomla! calendar + UIKIT 3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(document).ready(function () { | |
// calendar | |
uikit_jcalendar(); | |
// button | |
uikit_jcalendar_btn('#news_created_btn', 'uk-button-primary', 'calendar'); | |
uikit_jcalendar_btn('#news_publish_up_btn', 'uk-button-secondary', 'future'); | |
}); | |
// calendar | |
function uikit_jcalendar() | |
{ | |
jQuery('.js-calendar .table').removeClass('table').addClass('uk-table'); | |
jQuery('.js-calendar .daysrow, .js-calendar .day').addClass('uk-text-large'); | |
jQuery('.js-calendar select.time').addClass('uk-select'); | |
jQuery('.js-calendar .btn-group .js-btn').addClass('uk-width-1-3 uk-button uk-button-default uk-padding-remove-top uk-padding-remove-bottom uk-padding-small'); | |
jQuery('.js-calendar .btn-group').removeClass('btn-group').addClass('uk-button-group'); | |
} | |
// button | |
function uikit_jcalendar_btn(trigger, tm_button, tm_icon) | |
{ | |
jQuery(trigger).addClass('uk-button uk-button-small '+ tm_button); | |
jQuery(trigger +' span').append('<i uk-icon="icon: '+ tm_icon +'"></i>'); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Before:
After: