mirror of https://github.com/1099438829/macUI.git
UI优化
This commit is contained in:
parent
9103ded9e7
commit
b8c778b688
|
|
@ -94,8 +94,8 @@ body {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: 0;
|
top: 0;
|
||||||
height: 30px;
|
height: 24px;
|
||||||
line-height:30px;
|
line-height:24px;
|
||||||
/* IE9+ */
|
/* IE9+ */
|
||||||
background-color:rgba(255,255,255,0.4);
|
background-color:rgba(255,255,255,0.4);
|
||||||
/* IE6-IE8 */
|
/* IE6-IE8 */
|
||||||
|
|
@ -113,7 +113,7 @@ body {
|
||||||
font-weight:bold;
|
font-weight:bold;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
line-height: 30px;
|
line-height: 24px;
|
||||||
text-overflow:ellipsis;
|
text-overflow:ellipsis;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
transition: background-color 0.3s;
|
transition: background-color 0.3s;
|
||||||
|
|
@ -190,12 +190,12 @@ body {
|
||||||
}
|
}
|
||||||
|
|
||||||
#win10_btn_time {
|
#win10_btn_time {
|
||||||
font-size: 12px;
|
font-size: 14px;
|
||||||
/*line-height: 30px !important */
|
/*line-height: 30px !important */
|
||||||
}
|
}
|
||||||
#win10-menu {
|
#win10-menu {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: 31px;
|
top: 24px;
|
||||||
left: 0.5%;
|
left: 0.5%;
|
||||||
background-color: rgba(255,255,255,0.55);
|
background-color: rgba(255,255,255,0.55);
|
||||||
height: auto;
|
height: auto;
|
||||||
|
|
@ -381,10 +381,10 @@ body {
|
||||||
#win10_command_center {
|
#win10_command_center {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
right: 0;
|
right: 0;
|
||||||
top: 31px;
|
top: 25px;
|
||||||
width: 350px;
|
width: 300px;
|
||||||
background-color: rgba(255, 255, 255, 0.7);
|
background-color: rgba(255, 255, 255, 0.7);
|
||||||
height: calc(100% - 32px);
|
height: calc(100% - 25px);
|
||||||
transition: all 0.5s;
|
transition: all 0.5s;
|
||||||
overflow-x: hidden;
|
overflow-x: hidden;
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
|
|
@ -394,7 +394,7 @@ body {
|
||||||
}
|
}
|
||||||
|
|
||||||
#win10_command_center.hidden_right {
|
#win10_command_center.hidden_right {
|
||||||
right: -350px;
|
right: -300px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#win10_command_center > .title{
|
#win10_command_center > .title{
|
||||||
|
|
@ -481,7 +481,7 @@ body {
|
||||||
}
|
}
|
||||||
|
|
||||||
#win10_command_center .command-body .notice .notice-header {
|
#win10_command_center .command-body .notice .notice-header {
|
||||||
background-color: #ffffffbf;
|
background-color:#dee7e7;
|
||||||
height: 25px;
|
height: 25px;
|
||||||
border-radius: 5px 5px 0 0;
|
border-radius: 5px 5px 0 0;
|
||||||
line-height: 25px;
|
line-height: 25px;
|
||||||
|
|
@ -567,7 +567,7 @@ body {
|
||||||
}
|
}
|
||||||
|
|
||||||
#win10_btn_group_right #win10_btn_command{
|
#win10_btn_group_right #win10_btn_command{
|
||||||
font-size: 20px;
|
font-size: 14px;
|
||||||
}
|
}
|
||||||
#win10_btn_command .msgNof{
|
#win10_btn_command .msgNof{
|
||||||
position: fixed;
|
position: fixed;
|
||||||
|
|
@ -677,7 +677,7 @@ body {
|
||||||
|
|
||||||
.win10-open-iframe .layui-layer-content{
|
.win10-open-iframe .layui-layer-content{
|
||||||
background-color: white;
|
background-color: white;
|
||||||
max-height: calc(100% - 30px);
|
max-height: calc(100% - 24px);
|
||||||
}
|
}
|
||||||
|
|
||||||
.win10-open-iframe .layui-layer-title{
|
.win10-open-iframe .layui-layer-title{
|
||||||
|
|
@ -818,7 +818,7 @@ body {
|
||||||
.win10-open-iframe .layui-layer-title img.icon,#win10_btn_group_middle .btn_title img.icon{
|
.win10-open-iframe .layui-layer-title img.icon,#win10_btn_group_middle .btn_title img.icon{
|
||||||
width: 20px;
|
width: 20px;
|
||||||
position: relative;
|
position: relative;
|
||||||
top:4px ;
|
top:0px ;
|
||||||
}
|
}
|
||||||
|
|
||||||
#win10-menu>.list>.sub-item img.icon,#win10-menu>.list>.item img.icon{
|
#win10-menu>.list>.sub-item img.icon,#win10-menu>.list>.item img.icon{
|
||||||
|
|
@ -936,16 +936,16 @@ body {
|
||||||
@media screen and (max-width:767px){
|
@media screen and (max-width:767px){
|
||||||
#win10-menu{
|
#win10-menu{
|
||||||
width:100%;
|
width:100%;
|
||||||
top: 30px;
|
top: 24px;
|
||||||
left:0;
|
left:0;
|
||||||
height: calc(100% - 31px);
|
height: calc(100% - 25px);
|
||||||
border-radius:0 0 2px 2px;
|
border-radius:0 0 2px 2px;
|
||||||
}
|
}
|
||||||
#win10-menu.hidden{
|
#win10-menu.hidden{
|
||||||
top: calc(-100% + 31px);
|
top: calc(-100% + 25px);
|
||||||
}
|
}
|
||||||
#win10_command_center{
|
#win10_command_center{
|
||||||
top: 30px;
|
top: 24px;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
#win10_command_center.hidden_right {
|
#win10_command_center.hidden_right {
|
||||||
|
|
|
||||||
26
js/mac.js
26
js/mac.js
|
|
@ -389,7 +389,7 @@ window.Win10 = {
|
||||||
setInterval(function () {
|
setInterval(function () {
|
||||||
//重新写mac时间
|
//重新写mac时间
|
||||||
var myDate = Win10.getLunarObj();
|
var myDate = Win10.getLunarObj();
|
||||||
$("#win10_btn_time").html(myDate.week+myDate.hour+':'+myDate.minute);
|
$("#win10_btn_time").html(myDate.weekDay+myDate.hour+':'+myDate.minute);
|
||||||
},1000);
|
},1000);
|
||||||
//离开前警告
|
//离开前警告
|
||||||
document.body.onbeforeunload = function(event){
|
document.body.onbeforeunload = function(event){
|
||||||
|
|
@ -664,7 +664,13 @@ window.Win10 = {
|
||||||
return Animals[(year-4)%12];
|
return Animals[(year-4)%12];
|
||||||
}
|
}
|
||||||
//获取周
|
//获取周
|
||||||
function get_week(date){
|
function get_weekday(date){
|
||||||
|
var values = ["周日", "周一", "周二", "周三", "周四", "周五", "周六"];
|
||||||
|
return values[date.getDay()];
|
||||||
|
}
|
||||||
|
|
||||||
|
//获取星期
|
||||||
|
function get_week(date){
|
||||||
var values = ["星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六"];
|
var values = ["星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六"];
|
||||||
return values[date.getDay()];
|
return values[date.getDay()];
|
||||||
}
|
}
|
||||||
|
|
@ -704,6 +710,8 @@ window.Win10 = {
|
||||||
viewdate.day = date.getDate();
|
viewdate.day = date.getDate();
|
||||||
//星期
|
//星期
|
||||||
viewdate.week = get_week(date);
|
viewdate.week = get_week(date);
|
||||||
|
//星期
|
||||||
|
viewdate.weekDay = get_weekday(date);
|
||||||
//月
|
//月
|
||||||
viewdate.month = date.getMonth()+1;
|
viewdate.month = date.getMonth()+1;
|
||||||
//完整的年份(4位,1970-????)
|
//完整的年份(4位,1970-????)
|
||||||
|
|
@ -773,7 +781,7 @@ window.Win10 = {
|
||||||
$("#win10-msg-nof").removeClass('on-new-msg fa-commenting-o');
|
$("#win10-msg-nof").removeClass('on-new-msg fa-commenting-o');
|
||||||
},
|
},
|
||||||
renderShortcuts:function () {
|
renderShortcuts:function () {
|
||||||
var h=parseInt(($("#win10 #win10-shortcuts")[0].offsetHeight-90)/100);
|
var h=parseInt(($("#win10 #win10-shortcuts")[0].offsetHeight-85)/100);
|
||||||
var x=0,y=0;
|
var x=0,y=0;
|
||||||
$("#win10 #win10-shortcuts .shortcut").each(function () {
|
$("#win10 #win10-shortcuts .shortcut").each(function () {
|
||||||
$(this).css({
|
$(this).css({
|
||||||
|
|
@ -924,8 +932,8 @@ window.Win10 = {
|
||||||
}
|
}
|
||||||
var area,offset;
|
var area,offset;
|
||||||
if (this.isSmallScreen() || areaAndOffset==='max') {
|
if (this.isSmallScreen() || areaAndOffset==='max') {
|
||||||
area = ['100%', (document.body.clientHeight - 30) + 'px'];
|
area = ['100%', (document.body.clientHeight - 24) + 'px'];
|
||||||
offset = ['30px', '0'];
|
offset = ['24px', '0'];
|
||||||
}else if(typeof areaAndOffset ==='object'){
|
}else if(typeof areaAndOffset ==='object'){
|
||||||
area=areaAndOffset[0];
|
area=areaAndOffset[0];
|
||||||
offset=areaAndOffset[1];
|
offset=areaAndOffset[1];
|
||||||
|
|
@ -962,7 +970,7 @@ window.Win10 = {
|
||||||
},
|
},
|
||||||
full:function (layero) {
|
full:function (layero) {
|
||||||
layero.find('.layui-layer-min').css('display','inline-block');
|
layero.find('.layui-layer-min').css('display','inline-block');
|
||||||
layero_opened.css('top',30);
|
layero_opened.css('top',24);
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
$('#win10_btn_group_middle .btn.active').removeClass('active');
|
$('#win10_btn_group_middle .btn.active').removeClass('active');
|
||||||
|
|
@ -981,9 +989,9 @@ window.Win10 = {
|
||||||
var height=layero_opened.css('height');
|
var height=layero_opened.css('height');
|
||||||
height=parseInt(height.replace('px',''));
|
height=parseInt(height.replace('px',''));
|
||||||
if (height>=document.body.clientHeight){
|
if (height>=document.body.clientHeight){
|
||||||
layero_opened.css('height',height-32);
|
layero_opened.css('height',height-25);
|
||||||
layero_opened.find('.layui-layer-content').css('height',height-62);
|
layero_opened.find('.layui-layer-content').css('height',height-55);
|
||||||
layero_opened.find('.layui-layer-content iframe').css('height',height-62);
|
layero_opened.find('.layui-layer-content iframe').css('height',height-55);
|
||||||
}
|
}
|
||||||
},300);
|
},300);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue