信息提示框图标优化
This commit is contained in:
parent
5c13f51fc0
commit
4a721b6383
|
@ -18,6 +18,9 @@ function themeConfig($form) {
|
||||||
$notification = new Typecho_Widget_Helper_Form_Element_Text('notification', NULL, NULL, _t('网站公告'), _t('显示在首页,留空则不显示'));
|
$notification = new Typecho_Widget_Helper_Form_Element_Text('notification', NULL, NULL, _t('网站公告'), _t('显示在首页,留空则不显示'));
|
||||||
$form->addInput($notification);
|
$form->addInput($notification);
|
||||||
|
|
||||||
|
$notificationIcon = new Typecho_Widget_Helper_Form_Element_Text('notificationIcon', NULL, NULL, _t('网站公告图标'), _t('显示在首页网站公告信息框前的 FontAwesome 图标代码,留空则不显示'));
|
||||||
|
$form->addInput($notificationIcon);
|
||||||
|
|
||||||
$bottomLinks = new Typecho_Widget_Helper_Form_Element_Text('bottomLinks', NULL, NULL, _t('底部链接'), _t('(需要配合<a href="http://www.imhan.com/archives/typecho-links/" target="_blank">友情链接插件</a>使用)网站底部的链接分类名称'));
|
$bottomLinks = new Typecho_Widget_Helper_Form_Element_Text('bottomLinks', NULL, NULL, _t('底部链接'), _t('(需要配合<a href="http://www.imhan.com/archives/typecho-links/" target="_blank">友情链接插件</a>使用)网站底部的链接分类名称'));
|
||||||
$form->addInput($bottomLinks);
|
$form->addInput($bottomLinks);
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,10 @@ if (!defined('__TYPECHO_ROOT_DIR__')) exit;
|
||||||
<div class="col mt-5" id="main" role="main">
|
<div class="col mt-5" id="main" role="main">
|
||||||
<?php if ($this->options->notification !='') { ?>
|
<?php if ($this->options->notification !='') { ?>
|
||||||
<div class="alert alert-primary alert-dismissible fade show shadow" role="alert">
|
<div class="alert alert-primary alert-dismissible fade show shadow" role="alert">
|
||||||
<?php $this->options->notification(); ?>
|
<?php if ($this->options->notificationIcon != '') { ?>
|
||||||
|
<span class="alert-inner--icon"><i class="<?php $this->options->notificationIcon(); ?>"></i></span>
|
||||||
|
<?php } ?>
|
||||||
|
<span class="alert-inner--text"><?php $this->options->notification(); ?></span>
|
||||||
<button type="button" class="close" data-dismiss="alert" aria-label="Close">
|
<button type="button" class="close" data-dismiss="alert" aria-label="Close">
|
||||||
<span aria-hidden="true">×</span>
|
<span aria-hidden="true">×</span>
|
||||||
</button>
|
</button>
|
||||||
|
|
7
post.php
7
post.php
|
@ -22,10 +22,11 @@
|
||||||
<hr>
|
<hr>
|
||||||
<?php $date1=date_create(date('c',$this->date->timeStamp)); $date2=date_create(date('c')); $days=date_diff($date1,$date2); ?>
|
<?php $date1=date_create(date('c',$this->date->timeStamp)); $date2=date_create(date('c')); $days=date_diff($date1,$date2); ?>
|
||||||
<?php if ($this->options->oldPosts == 'able' && $days->format('%a') > 365): ?>
|
<?php if ($this->options->oldPosts == 'able' && $days->format('%a') > 365): ?>
|
||||||
<div class="alert alert-primary shadow mb-5" role="alert">
|
<div class="alert alert-primary alert-dismissible fade show shadow mb-5" role="alert">
|
||||||
这是一篇发布于 <?php echo $days->format('%a'); ?> 天以前的旧文。其中的部分内容可能已经过时。
|
<span class="alert-inner--icon"><i class="fas fa-clock"></i></span>
|
||||||
|
<span class="alert-inner--text">这是一篇发布于 <?php echo $days->format('%a'); ?> 天以前的旧文。其中的部分内容可能已经过时。</span>
|
||||||
<button type="button" class="close" data-dismiss="alert" aria-label="Close">
|
<button type="button" class="close" data-dismiss="alert" aria-label="Close">
|
||||||
<span aria-hidden="true" class="text-white">×</span>
|
<span aria-hidden="true">×</span>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
Loading…
Reference in New Issue