Merge branch 'master' into develop

This commit is contained in:
kuaifan 2022-03-02 08:28:24 +08:00
commit 4cd47a5c77
7 changed files with 21 additions and 11 deletions

View File

@ -342,19 +342,15 @@ class Base
{
if (strtolower($charset) == 'utf-8') {
if (Base::getStrlen($string) <= $length) return $string;
$strcut = str_replace(array('&amp;', '&quot;', '&lt;', '&gt;'), array('&', '"', '<', '>'), $string);
$strcut = Base::utf8Substr($strcut, $length, $start);
$strcut = str_replace(array('&', '"', '<', '>'), array('&amp;', '&quot;', '&lt;', '&gt;'), $strcut);
$strcut = Base::utf8Substr($string, $length, $start);
return $strcut . $dot;
} else {
$length = $length * 2;
if (strlen($string) <= $length) return $string;
$string = str_replace(array('&amp;', '&quot;', '&lt;', '&gt;'), array('&', '"', '<', '>'), $string);
$strcut = '';
for ($i = 0; $i < $length; $i++) {
$strcut .= ord($string[$i]) > 127 ? $string[$i] . $string[++$i] : $string[$i];
}
$strcut = str_replace(array('&', '"', '<', '>'), array('&amp;', '&quot;', '&lt;', '&gt;'), $strcut);
}
return $strcut . $dot;
}

View File

@ -2,7 +2,7 @@
<div class="teditor-wrapper">
<div class="teditor-box" :class="[!inline && spinShow ? 'teditor-loadstyle' : 'teditor-loadedstyle']">
<template v-if="inline">
<div ref="myTextarea" :id="id" v-html="content"></div>
<div ref="myTextarea" :id="id" v-html="spinShow ? '' : content"></div>
<Icon v-if="spinShow" type="ios-loading" :size="18" class="icon-loading icon-inline"></Icon>
</template>
<template v-else>

View File

@ -157,8 +157,10 @@
let time = Math.round(this.Date(date).getTime() / 1000) - nowTime;
if (time < 86400 * 7 && time > 0 ) {
return this.formatSeconds(time);
} else if (time <= 0) {
} else if (time < 0) {
return '-' + this.formatSeconds(time * -1);
} else if (time == 0) {
return 0;
}
return this.formatTime(date)
},

View File

@ -37,7 +37,7 @@
<i class="taskfont">&#xe689;</i>
</div>
<Dropdown-menu slot="list" class="login-setting-menu">
<Dropdown placement="right-start" @on-click="setTheme">
<Dropdown placement="right" @on-click="setTheme">
<DropdownItem>
<div class="login-setting-item">
{{$L('主题皮肤')}}
@ -48,7 +48,7 @@
<Dropdown-item v-for="(item, key) in themeList" :key="key" :name="item.value" :selected="themeMode === item.value">{{$L(item.name)}}</Dropdown-item>
</DropdownMenu>
</Dropdown>
<Dropdown placement="right-start" @on-click="setLanguage">
<Dropdown placement="right" @on-click="setLanguage">
<DropdownItem divided>
<div class="login-setting-item">
{{currentLanguage}}

View File

@ -77,6 +77,13 @@
img {
max-width: 100%;
}
pre {
padding: 14px;
margin: 7px 0;
overflow: auto;
background: #f5f2f0;
border-radius: 5px;
}
&[data-mce-placeholder]:not(.mce-visualblocks)::before {
color: #bbbbbb;
}

View File

@ -163,6 +163,13 @@
img {
max-width: 100%;
}
pre {
padding: 14px;
margin: 7px 0;
overflow: auto;
background: #f5f2f0;
border-radius: 5px;
}
&[data-mce-placeholder]:not(.mce-visualblocks)::before {
color: #bbbbbb;
}

View File

@ -51,8 +51,6 @@
&:last-child {
background-color: #98de6e;
margin-right: 0;
cursor: default;
box-shadow: none;
}
.block-title {
color: rgba(255, 255, 255, 0.6);