You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

426 lines
7.6 KiB

10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
  1. /*
  2. * # Semantic - Message
  3. * http://github.com/semantic-org/semantic-ui/
  4. *
  5. *
  6. * Copyright 2014 Contributor
  7. * Released under the MIT license
  8. * http://opensource.org/licenses/MIT
  9. *
  10. */
  11. /*******************************
  12. Theme
  13. *******************************/
  14. @type : 'collection';
  15. @element : 'message';
  16. @import '../../semantic.config';
  17. /*******************************
  18. Message
  19. *******************************/
  20. .ui.message {
  21. position: relative;
  22. min-height: 1em;
  23. margin: @verticalMargin 0em;
  24. background: @background;
  25. padding: @verticalPadding @horizontalPadding;
  26. line-height: @lineHeight;
  27. color: @textColor;
  28. transition: @transition;
  29. border-radius: @borderRadius;
  30. box-shadow: @boxShadow;
  31. }
  32. .ui.message:first-child {
  33. margin-top: 0em;
  34. }
  35. .ui.message:last-child {
  36. margin-bottom: 0em;
  37. }
  38. /*--------------
  39. Content
  40. ---------------*/
  41. /* Header */
  42. .ui.message .header {
  43. display: @headerDisplay;
  44. font-family: @headerFont;
  45. font-weight: @headerFontWeight;
  46. margin: 0em 0em 0em @headerDistance;
  47. }
  48. /* Default font size */
  49. .ui.message .header:not(.ui) {
  50. font-size: @headerFontSize;
  51. }
  52. /* Paragraph */
  53. .ui.message p {
  54. opacity: @messageTextOpacity;
  55. margin: @messageParagraphMargin 0em;
  56. }
  57. .ui.message p:first-child {
  58. margin-top: 0em;
  59. }
  60. .ui.message p:last-child {
  61. margin-bottom: 0em;
  62. }
  63. .ui.message .header + p {
  64. margin-top: @headerParagraphDistance;
  65. }
  66. /* List */
  67. .ui.message ul.list {
  68. opacity: @listOpacity;
  69. list-style-position: @listStylePosition;
  70. margin: @listMargin 0em 0em;
  71. padding: 0em;
  72. }
  73. .ui.message ul.list:first-child {
  74. margin-top: 0em;
  75. }
  76. .ui.message ul.list:last-child {
  77. margin-bottom: 0em;
  78. }
  79. .ui.message ul.list li {
  80. position: relative;
  81. list-style-type: none;
  82. margin: 0em 0em @listItemMargin @listItemIndent;
  83. padding: 0em;
  84. }
  85. .ui.message ul.list li:before {
  86. position: absolute;
  87. content: '•';
  88. left: -1em;
  89. height: 100%;
  90. vertical-align: baseline;
  91. }
  92. .ui.message ul.list li:last-child {
  93. margin-bottom: 0em;
  94. }
  95. /* Icon */
  96. .ui.message > .icon {
  97. margin-right: @iconDistance;
  98. }
  99. /* Close Icon */
  100. .ui.message > .close.icon {
  101. cursor: pointer;
  102. position: absolute;
  103. margin: 0em;
  104. top: @closeTopDistance;
  105. right: @closeRightDistance;
  106. opacity: @closeOpacity;
  107. transition:
  108. opacity 0.1s linear
  109. ;
  110. }
  111. .ui.message > .close.icon:hover {
  112. opacity: 1;
  113. }
  114. /* First / Last Element */
  115. .ui.message > :first-child {
  116. margin-top: 0em;
  117. }
  118. .ui.message > :last-child {
  119. margin-bottom: 0em;
  120. }
  121. /*******************************
  122. States
  123. *******************************/
  124. .ui.message.visible,
  125. .ui.header.visible {
  126. display: block !important;
  127. }
  128. .ui.message.hidden,
  129. .ui.header.hidden {
  130. display: none;
  131. }
  132. /*******************************
  133. Variations
  134. *******************************/
  135. /*--------------
  136. Compact
  137. ---------------*/
  138. .ui.compact.message {
  139. display: inline-block;
  140. }
  141. /*--------------
  142. Attached
  143. ---------------*/
  144. .ui.attached.message {
  145. margin-bottom: @attachedYOffset;
  146. border-radius: @borderRadius @borderRadius 0em 0em;
  147. box-shadow:
  148. @attachedBoxShadow
  149. ;
  150. margin-left: @attachedXOffset;
  151. margin-right: @attachedXOffset;
  152. }
  153. .ui.attached + .ui.attached.message:not(.top):not(.bottom) {
  154. margin-top: @attachedYOffset;
  155. border-radius: 0em;
  156. }
  157. .ui.bottom.attached.message {
  158. margin-top: @attachedYOffset;
  159. border-radius: 0em 0em @borderRadius @borderRadius;
  160. box-shadow: @attachedBottomBoxShadow;
  161. }
  162. .ui.bottom.attached.message:not(:last-child) {
  163. margin-bottom: @verticalMargin;
  164. }
  165. .ui.attached.icon.message {
  166. display: block;
  167. width: auto;
  168. }
  169. /*--------------
  170. Icon
  171. ---------------*/
  172. .ui.icon.message {
  173. display: table;
  174. width: 100%;
  175. }
  176. .ui.icon.message > .icon:not(.close) {
  177. display: table-cell;
  178. vertical-align: @iconVerticalAlign;
  179. font-size: @iconSize;
  180. opacity: @iconOpacity;
  181. width: 1em;
  182. }
  183. .ui.icon.message > .content {
  184. display: table-cell;
  185. vertical-align: @iconVerticalAlign;
  186. }
  187. .ui.icon.message .icon:not(.close) + .content {
  188. padding-left: @iconContentDistance;
  189. }
  190. .ui.icon.message .circular.icon + .content {
  191. padding-left: @circularIconContentDistance;
  192. }
  193. /*--------------
  194. Floating
  195. ---------------*/
  196. .ui.floating.message {
  197. box-shadow: @floatingBoxShadow;
  198. }
  199. /*--------------
  200. Colors
  201. ---------------*/
  202. .ui.black.message {
  203. background-color: @black;
  204. color: @invertedTextColor;
  205. }
  206. /*--------------
  207. Types
  208. ---------------*/
  209. /* Positive */
  210. .ui.positive.message {
  211. background-color: @positiveBackgroundColor;
  212. color: @positiveTextColor;
  213. }
  214. .ui.positive.message,
  215. .ui.attached.positive.message {
  216. box-shadow:
  217. 0px 0px 0px 1px @positiveBorderColor inset,
  218. @subtleShadow
  219. ;
  220. }
  221. .ui.positive.message .header {
  222. color: @positiveHeaderColor;
  223. }
  224. /* Negative */
  225. .ui.negative.message {
  226. background-color: @negativeBackgroundColor;
  227. color: @negativeTextColor;
  228. }
  229. .ui.negative.message,
  230. .ui.attached.negative.message {
  231. box-shadow:
  232. 0px 0px 0px 1px @negativeBorderColor inset,
  233. @subtleShadow
  234. ;
  235. }
  236. .ui.negative.message .header {
  237. color: @negativeHeaderColor;
  238. }
  239. /* Info */
  240. .ui.info.message {
  241. background-color: @infoBackgroundColor;
  242. color: @infoTextColor;
  243. }
  244. .ui.info.message,
  245. .ui.attached.info.message {
  246. box-shadow:
  247. 0px 0px 0px 1px @infoBorderColor inset,
  248. @subtleShadow
  249. ;
  250. }
  251. .ui.info.message .header {
  252. color: @infoHeaderColor;
  253. }
  254. /* Warning */
  255. .ui.warning.message {
  256. background-color: @warningBackgroundColor;
  257. color: @warningTextColor;
  258. }
  259. .ui.warning.message,
  260. .ui.attached.warning.message {
  261. box-shadow:
  262. 0px 0px 0px 1px @warningBorderColor inset,
  263. @subtleShadow
  264. ;
  265. }
  266. .ui.warning.message .header {
  267. color: @warningHeaderColor;
  268. }
  269. /* Error */
  270. .ui.error.message {
  271. background-color: @errorBackgroundColor;
  272. color: @errorTextColor;
  273. }
  274. .ui.error.message,
  275. .ui.attached.error.message {
  276. box-shadow:
  277. 0px 0px 0px 1px @errorBorderColor inset,
  278. @subtleShadow
  279. ;
  280. }
  281. .ui.error.message .header {
  282. color: @errorHeaderColor;
  283. }
  284. /* Success */
  285. .ui.success.message {
  286. background-color: @successBackgroundColor;
  287. color: @successTextColor;
  288. }
  289. .ui.success.message,
  290. .ui.attached.success.message {
  291. box-shadow:
  292. 0px 0px 0px 1px @successBorderColor inset,
  293. @subtleShadow
  294. ;
  295. }
  296. .ui.success.message .header {
  297. color: @successHeaderColor;
  298. }
  299. /* Colors */
  300. .ui.inverted.message,
  301. .ui.black.message {
  302. background-color: @black;
  303. color: @invertedTextColor;
  304. }
  305. .ui.blue.message {
  306. background-color: @blueBackground;
  307. color: @blueTextColor;
  308. }
  309. .ui.blue.message .header {
  310. color: @blueHeaderColor;
  311. }
  312. .ui.green.message {
  313. background-color: @greenBackground;
  314. color: @greenTextColor;
  315. }
  316. .ui.green.message .header {
  317. color: @greenHeaderColor;
  318. }
  319. .ui.orange.message {
  320. background-color: @orangeBackground;
  321. color: @orangeTextColor;
  322. }
  323. .ui.orange.message .header {
  324. color: @orangeHeaderColor;
  325. }
  326. .ui.pink.message {
  327. background-color: @pinkBackground;
  328. color: @pinkTextColor;
  329. }
  330. .ui.pink.message .header {
  331. color: @pinkHeaderColor;
  332. }
  333. .ui.purple.message {
  334. background-color: @purpleBackground;
  335. color: @purpleTextColor;
  336. }
  337. .ui.purple.message .header {
  338. color: @purpleHeaderColor;
  339. }
  340. .ui.red.message {
  341. background-color: @redBackground;
  342. color: @redTextColor;
  343. }
  344. .ui.red.message .header {
  345. color: @redHeaderColor;
  346. }
  347. .ui.teal.message {
  348. background-color: @tealBackground;
  349. color: @tealTextColor;
  350. }
  351. .ui.teal.message .header {
  352. color: @tealHeaderColor;
  353. }
  354. .ui.yellow.message {
  355. background-color: @yellowBackground;
  356. color: @yellowTextColor;
  357. }
  358. .ui.yellow.message .header {
  359. color: @yellowHeaderColor;
  360. }
  361. /*--------------
  362. Sizes
  363. ---------------*/
  364. .ui.small.message {
  365. font-size: @small;
  366. }
  367. .ui.message {
  368. font-size: @medium;
  369. }
  370. .ui.large.message {
  371. font-size: @large;
  372. }
  373. .ui.huge.message {
  374. font-size: @huge;
  375. }
  376. .ui.massive.message {
  377. font-size: @massive;
  378. }
  379. .loadUIOverrides();