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.
 
 
 
 
 

359 lines
10 KiB

  1. /**
  2. * This file provides the design styles for the direct / menu jump links.
  3. */
  4. #dokuwiki__usertools.nav-usertools {
  5. @media @screen_min-md {
  6. right: 1.25rem;
  7. }
  8. @media @screen_max-md {
  9. position: absolute;
  10. top: 0;
  11. left: (@toggle-size + 1.25); // margin-left content
  12. right: @headericons-margin-xxs;
  13. margin-top: 0;
  14. margin-right: 0;
  15. }
  16. &.has-bar {
  17. @media @screen_min-md {
  18. margin-top: @height-context-bar;
  19. padding-top: .5em;
  20. }
  21. }
  22. /* + + + + + icon list + + + + + */
  23. ul {
  24. float: right;
  25. padding: 0;
  26. margin: (@very-small-spacing * 2) -.25rem 0 0;
  27. @media @screen_max-md {
  28. margin-right: .5rem;
  29. }
  30. @media @screen_max-xxs {
  31. margin-right: -.3rem;
  32. }
  33. li {
  34. .btn-usertools-wrapper(); // uniform li
  35. .btn-usertools-num();
  36. float: right;
  37. @media @screen_max-xs {
  38. display: block;
  39. float: none;
  40. margin-bottom: @headericons-margin-xxs;
  41. }
  42. @media @screen_max-xxs {
  43. margin-bottom: (@headericons-margin-xxs - .2);
  44. display: none;
  45. }
  46. > span,
  47. > a {
  48. display: block;
  49. width: auto;
  50. min-width: (@toggle-size + .25);
  51. min-height: @toggle-size;
  52. overflow: hidden;
  53. border: 1px solid @wikiicons-border;
  54. border-radius: @ini_default_border_radius; // @ini_default_border_radius vs. @fix_border-radius
  55. text-align: center;
  56. margin: 0;
  57. @media @screen_md-xlg {
  58. padding-top: .14rem;
  59. }
  60. }
  61. /* !!! &.user-task FIND in plugins/do_tasks.less !!! */
  62. &.user {
  63. position: relative;
  64. display: table-cell;
  65. background-color: @ini_background_site;
  66. border: solid 1px @wikiicons-border;
  67. border-radius: @ini_default_border_radius; // @ini_default_border_radius vs. @fix_border-radius
  68. color: @ini_text_webframe;
  69. padding-right: .3rem;
  70. @media @screen_min-md {
  71. padding-top: .35rem;
  72. }
  73. @media @screen_max-md {
  74. min-height: @toggle-size;
  75. padding-top: .3rem;
  76. }
  77. @media @screen_max-sm {
  78. padding-top: .35rem;
  79. }
  80. @media @screen_max-xs {
  81. position: absolute;
  82. top: @headericons-margin-xxs;
  83. right: (@toggle-size + @headericons-margin-xxs + 1); // 1.75rem + 1 + (button login/out margin-right)
  84. overflow: hidden;
  85. white-space: nowrap;
  86. margin: -1px 0 0;
  87. padding-top: .4rem;
  88. }
  89. @media @screen_max-xxs {
  90. left: -10px;
  91. right: 0;
  92. width: auto;
  93. padding-top: .35rem;
  94. }
  95. > a {
  96. .display-flex();
  97. .align-items();
  98. position: relative;
  99. height: 1rem; // for IE11
  100. overflow: visible;
  101. background: @ini_nav_menu_hover_bg; // for removing bg-image
  102. border: 0 none;
  103. color: @ini_nav_menu_hover_color;
  104. text-indent: 0;
  105. font-size: inherit;
  106. margin-right: -.3rem;
  107. padding: 0 .2em 0 0;
  108. @media @screen_min-xxlg {
  109. min-height: (@toggle-size - .1);
  110. margin-top: -.4rem;
  111. }
  112. @media @screen_max-xxlg {
  113. min-height: (@toggle-size - .15);
  114. margin-top: -.35rem;
  115. }
  116. @media @screen_max-md {
  117. min-height: (@toggle-size - .1);
  118. margin-top: -.35rem;
  119. }
  120. @media @screen_max-sm {
  121. margin-top: -.35rem;
  122. }
  123. @media @screen_max-xs {
  124. margin-top: -.4rem;
  125. }
  126. &::before {
  127. content: '';
  128. top: -1px;
  129. bottom: -1px;
  130. left: -1px;
  131. right: -1px;
  132. width: auto;
  133. opacity: 0;
  134. border: solid 1px @ini_nav_menu_hover_color;
  135. border-radius: @ini_default_border_radius; // @ini_default_border_radius vs. @fix_border-radius
  136. color: inherit;
  137. transform: none;
  138. }
  139. &:hover,
  140. &:focus,
  141. &:active {
  142. background-color: @ini_nav_menu_hover_color;
  143. color: @ini_nav_menu_hover_bg;
  144. &::before {
  145. opacity: 1;
  146. border-color: @ini_nav_menu_hover_color;
  147. }
  148. bdi,
  149. bdi:first-of-type {
  150. color: @ini_nav_menu_hover_bg;
  151. }
  152. }
  153. }
  154. bdi {
  155. display: inline-block;
  156. color: inherit;
  157. }
  158. bdi:first-of-type {
  159. .fontello();
  160. .icon-user-circle();
  161. position: relative;
  162. margin: 0 0 0 .25rem;
  163. padding: 0 .1rem 0 1.3rem;
  164. &::before {
  165. position: absolute;
  166. left: -2px;
  167. font-size: 1.4rem;
  168. margin: 0;
  169. @media @screen_min-xxlg {
  170. top: -.25rem;
  171. }
  172. @media @screen_max-xxlg {
  173. top: -.2rem;
  174. }
  175. @media @screen_max-xs {
  176. top: -.25rem;
  177. }
  178. }
  179. }
  180. } // user
  181. } // li
  182. /* + + + icons + + + */
  183. .menuitem, button {
  184. padding: 2px 0 0 2px;
  185. min-height: @toggle-size; // overrides button[type="submit"] styles
  186. border: solid 1px @wikiicons-border; // overrides button[type="submit"] styles
  187. .btn-hover();
  188. &:hover svg, &:focus svg {
  189. transition: @transition fill;
  190. fill: @ini_nav_menu_hover_bg;
  191. }
  192. svg {
  193. fill: @ini_nav_menu_hover_color;
  194. height: @font-size-default + (@font-scale-factor * 4);
  195. }
  196. span {
  197. display: none;
  198. }
  199. }
  200. a { // Pre-Greebo backwards compatibility, remove after transitioning to Greebo
  201. .fontello();
  202. .hide-text-show-before();
  203. .btn-hover();
  204. cursor: pointer;
  205. position: relative;
  206. line-height: 1;
  207. text-decoration: none;
  208. &::before {
  209. .center-middle();
  210. content: "?";
  211. cursor: pointer;
  212. display: block;
  213. width: 100%;
  214. box-sizing: border-box;
  215. font-size: @font-size-default + (@font-scale-factor * 4);
  216. line-height: 1;
  217. }
  218. /* icon register new user */
  219. &.register {
  220. .icon-user();
  221. }
  222. /* icon log-out */
  223. &.logout {
  224. .icon-logout();
  225. }
  226. /* icon log-in */
  227. &.login {
  228. .icon-login();
  229. }
  230. /* icon admin */
  231. &.admin {
  232. .icon-cog();
  233. &::before {
  234. vertical-align: top;
  235. }
  236. }
  237. } // a
  238. } // ul
  239. } // nav-usertools
  240. /* + + + + + layout option compact + + + + + */
  241. .header-compact {
  242. #dokuwiki__usertools.nav-usertools {
  243. // mobile
  244. @media @screen_max-md {
  245. left: 6rem;
  246. ul {
  247. overflow: hidden;
  248. li.user {
  249. color: @ini_background_site;
  250. bdi {
  251. position: absolute;
  252. width: 0;
  253. padding: 0;
  254. text-indent: -10000px;
  255. &:before {
  256. transition: @transition background-color;
  257. background-color: @ini_background_site;
  258. color: @ini_nav_menu_color;
  259. text-indent: 0;
  260. }
  261. }
  262. > a {
  263. padding: 0 .2em;
  264. color: @ini_nav_menu_hover_bg;
  265. bdi {
  266. &:before {
  267. background-color: @ini_nav_menu_hover_bg;
  268. color: @ini_nav_menu_hover_color;
  269. }
  270. }
  271. &:hover {
  272. color: @ini_nav_menu_hover_color;
  273. bdi {
  274. &:before {
  275. background-color: @ini_nav_menu_hover_color;
  276. color: @ini_nav_menu_hover_bg;
  277. }
  278. }
  279. }
  280. }
  281. bdi + bdi {
  282. display: none;
  283. }
  284. }
  285. }
  286. }
  287. @media @screen_max-sm {
  288. ul li {
  289. position: static;
  290. float: right;
  291. top: 0; right: 0;
  292. }
  293. }
  294. }
  295. }