Sort button in the drive

pull/1/head
yflory 5 years ago
parent c8bac778d5
commit 4cf775e613

@ -716,6 +716,9 @@
}
}
}
.cp-app-drive-element-state {
display: none !important;
}
}
}
.cp-app-drive-element {
@ -729,6 +732,9 @@
.cp-app-drive-element-type, .cp-app-drive-element-filler {
display: none !important;
}
.cp-app-drive-element-sort {
display: block !important;
}
}
@media screen and (max-width: 740px) {
@ -744,9 +750,6 @@
.cp-app-drive-element-header .cp-app-drive-element-state {
display: none !important;
}
.cp-app-drive-element-sort {
display: block !important;
}
}
}

@ -2157,6 +2157,11 @@ define([
e.stopPropagation();
var state = $innerblock.is(':visible');
$('.cp-dropdown-content').hide();
var $c = $container.closest('.cp-toolbar-drawer-content');
$c.removeClass('cp-dropdown-visible');
if (!state) { $c.addClass('cp-dropdown-visible'); }
try {
$('iframe').each(function (idx, ifrw) {
$(ifrw).contents().find('.cp-dropdown-content').hide();

@ -311,14 +311,7 @@ define([
common: Common
};
var $block = exp.$language = UIElements.createDropdown(dropdownConfig);
$block.find('button').attr('title', Messages.languageButtonTitle).click(function () {
var state = $block.find('.cp-dropdown-content').is(':visible');
var $c = $block.closest('.cp-toolbar-drawer-content');
$c.removeClass('cp-dropdown-visible');
if (!state) {
$c.addClass('cp-dropdown-visible');
}
});
$block.find('button').attr('title', Messages.languageButtonTitle);
var isHovering = false;
var $aLanguages = $block.find('a');
@ -368,15 +361,7 @@ define([
common: Common
};
var $block = exp.$theme = UIElements.createDropdown(dropdownConfig);
$block.find('button').attr('title', Messages.themeButtonTitle).click(function () {
// XXX copy-pasted code from configureLanguage. We can refactor this.
var state = $block.find('.cp-dropdown-content').is(':visible');
var $c = $block.closest('.cp-toolbar-drawer-content');
$c.removeClass('cp-dropdown-visible');
if (!state) {
$c.addClass('cp-dropdown-visible');
}
});
$block.find('button').attr('title', Messages.themeButtonTitle);
setTheme(lastTheme, $block);

Loading…
Cancel
Save