-
-
Notifications
You must be signed in to change notification settings - Fork 517
/
notification.css
56 lines (55 loc) · 1.72 KB
/
notification.css
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
#template('colorThemeInit.vm')
.xnotification-container {
position : fixed;
bottom: 0;
left: 0%;
width: 100%;
text-align: center;
z-index: 1200;
display: block !important;
}
.xnotification-wrapper {
padding-top: 1px;
}
.xnotification {
cursor: pointer;
display: inline;
background: #333 2px center no-repeat;
border: none;
padding: 0px 6px;
color: #fff;
font-weight: bold;
line-height: 20px;
}
#set($notificationCustommization = [])
/* each element specifies [notification type, bg color, text color, icon] */
#set($discard = $notificationCustommization.add(['info', "$theme.notificationInfoColor", '#fff']))
#set($discard = $notificationCustommization.add(['warning', "$theme.notificationWarningColor ", '#330']))
#set($discard = $notificationCustommization.add(['error', "$theme.notificationErrorColor", '#fff']))
#set($discard = $notificationCustommization.add(['inprogress', '#333', '#fff', 'icons/xwiki/spinner-white.gif']))
#set($discard = $notificationCustommization.add(['done', "$theme.notificationSuccessColor", '#fff']))
#foreach($item in $notificationCustommization)
#set($notificationType = $item.get(0))
#set($bgColor = $item.get(1))
#set($textColor = $item.get(2))
#set($imgUrl = '')
#if ($item.size() >= 4)
#set($imgName = "$!item.get(3)")
#if($imgName.indexOf("/") >= 0)
#set($imgUrl = $xwiki.getSkinFile($imgName))
#else
#set($imgExtension = '.png')
#set($imgUrl = $xwiki.getSkinFile("icons/silk/$imgName$imgExtension"))
#end
#end
/** $notificationType */
.xnotification-${notificationType} {
background-color: $bgColor;
color: $textColor;
border-color: $textColor;
#if($imgUrl != '')
background-image: url($imgUrl);
padding-left: 22px;
#end
}
#end