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.

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