-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathhome2.php
118 lines (105 loc) · 5.73 KB
/
home2.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
<?php
/**
* My Material 主题 一般模式
*/
if (!defined('__TYPECHO_ROOT_DIR__')) exit; ?>
<?php Typecho_Widget::widget('Widget_Stat')->to($stat); ?>
<?php $this->widget('Widget_Contents_Page_List')->to($pages); ?>
<div id="home2-left-column" class="mdl-cell--8-col mdl-cell--5-col-tablet" style="position: relative">
<?php if (!empty($this->options->homeCard) && in_array('showBreadcrumb', $this->options->homeCard)): ?>
<?php if (!$this->is('index') || $this->getCurrentPage() != 1): ?>
<div class="breadcrumb mdl-cell mdl-cell--12-col hover-shadow--3dp shadow--1dp translation-all-3">
<a class="mdl-color-text--primary" href="<?php $this->options->siteUrl(); ?>">
<i class="material-icons">home</i>
首页
</a>
<?php if (!$this->is('index')): ?>
<a>
<?php $this->archiveTitle(array(
'category' => _t('分类 %s'),
'search' => _t('包含关键字 %s'),
'tag' => _t('标签 %s'),
'author' => _t('%s')
), '', ''); ?>
</a>
<?php endif; ?>
<?php if ($this->getCurrentPage() != 1): ?>
<a>第<?php echo $this->getCurrentPage() ?>页</a>
<?php endif; ?>
</div>
<?php endif; ?>
<?php endif; ?>
<?php if ($this->is('index') && $this->getCurrentPage() == 1): ?>
<?php if (!empty($this->options->homeCard) && in_array('showLeft', $this->options->homeCard)): ?>
<div class="head-card-left translation-all-3 mdl-card mdl-cell shadow--1dp translation-all-3 hover-shadow--3dp
mdl-cell--12-col menu-dialog-visible">
<div class="has-image mdl-card__title">
<a class="has-image-img"><img alt=""
src="<?php if ($this->options->leftImageUrl): $this->options->leftImageUrl();
else:$this->options->themeUrl('image/left.jpg'); endif; ?>"></a>
<div class="card-text-wrapper">
<h2 class="mdl-card__title-text mdl-color-text--white">
<?php $this->options->title() ?>
</h2>
<div class="mdl-card__subtitle-text color-text-white-second">
<?php $this->options->description() ?>
</div>
</div>
</div>
<div class="mdl-card__actions ">
<div class="avator-wrapper zoom-avator avatar-shadow">
<?php echo $this->author->gravatar(80); ?>
<span class="author-text color-text-block-primary">
<?php $this->author('screenName'); ?>
</span>
<div class="mdl-layout-spacer"></div>
<div class="action-wrapper">
<button id="right-card-pages-phone" style="margin-left: auto;"
class="mdl-button mdl-js-button mdl-button--icon
mdl-cell--hide-desktop mdl-cell--hide-tablet">
<i class="material-icons">short_text</i>
</button>
<ul class="mdl-menu mdl-menu--bottom-right mdl-js-menu mdl-js-ripple-effect"
for="right-card-pages-phone">
<?php while ($pages->next()): ?>
<li class="mdl-menu__item">
<a<?php if ($this->is('page', $pages->slug)): ?>
class="current"<?php endif; ?>
href="<?php $pages->permalink(); ?>"
title="<?php $pages->title(); ?>">
<?php $pages->title(); ?>
</a>
</li>
<?php endwhile; ?>
</ul>
<button id="right-card-menu-phone" style="margin-left: auto;"
class="mdl-button mdl-js-button mdl-button--icon
mdl-cell--hide-desktop mdl-cell--hide-tablet">
<i class="material-icons">more_vert</i>
</button>
<ul class="mdl-menu mdl-menu--bottom-right mdl-js-menu mdl-js-ripple-effect"
for="right-card-menu-phone">
<li class="mdl-menu__item">
<a class="no-pjax" onclick="shareWeibo(
'<?php urlencode($this->options->title() . '-' . $this->options->description()) ?>',
'<?php urlencode($this->options->siteUrl()) ?>')">分享到 微博</a>
</li>
</ul>
</div>
</div>
</div>
</div><!--head-card-left-->
<?php endif; ?>
<?php endif; ?>
<?php $this->need('postCard.php') ?>
<div class="load-more-wrap">
<a id="load-more"
style="margin: 16px 0">
<span class="description">加载更多</span>
</a>
<div id="load-more-anim">
<div class="cube1"></div>
<div class="cube2"></div>
</div>
</div>
</div>