forms.less 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882
  1. // stylelint-disable selector-no-qualifying-type, property-no-vendor-prefix, media-feature-name-no-vendor-prefix
  2. // Form validation states
  3. //
  4. // Used in forms.less to generate the form validation CSS for warnings, errors,
  5. // and successes.
  6. .form-control-validation(@text-color: #555; @border-color: #ccc; @background-color: #f5f5f5) {
  7. // Color the label and help text
  8. .help-block,
  9. .control-label,
  10. .radio,
  11. .checkbox,
  12. .radio-inline,
  13. .checkbox-inline,
  14. &.radio label,
  15. &.checkbox label,
  16. &.radio-inline label,
  17. &.checkbox-inline label {
  18. color: @text-color;
  19. }
  20. // Set the border and box shadow on specific inputs to match
  21. .form-control {
  22. border-color: @border-color;
  23. box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); // Redeclare so transitions work
  24. &:focus {
  25. border-color: darken(@border-color, 10%);
  26. box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075),
  27. 0 0 6px lighten(@border-color, 20%);
  28. }
  29. }
  30. // Optional feedback icon
  31. .form-control-feedback {
  32. color: @text-color;
  33. }
  34. }
  35. // Form control focus state
  36. //
  37. // Generate a customized focus state and for any input with the specified color,
  38. // which defaults to the `@input-border-focus` variable.
  39. //
  40. // We highly encourage you to not customize the default value, but instead use
  41. // this to tweak colors on an as-needed basis. This aesthetic change is based on
  42. // WebKit's default styles, but applicable to a wider range of browsers. Its
  43. // usability and accessibility should be taken into account with any change.
  44. //
  45. // Example usage: change the default blue border and shadow to white for better
  46. // contrast against a dark gray background.
  47. .form-control-focus(@color: @input-border-focus) {
  48. @color-rgba: rgba(red(@color), green(@color), blue(@color), 0.6);
  49. &:focus {
  50. border-color: @color;
  51. outline: 0;
  52. box-shadow: ~'inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 8px @{color-rgba}';
  53. }
  54. }
  55. // Form control sizing
  56. //
  57. // Relative text size, padding, and border-radii changes for form controls. For
  58. // horizontal sizing, wrap controls in the predefined grid classes. `<select>`
  59. // element gets special love because it's special, and that's a fact!
  60. .input-size(@input-height; @padding-vertical; @padding-horizontal; @font-size; @line-height; @border-radius) {
  61. height: @input-height;
  62. padding: @padding-vertical @padding-horizontal;
  63. font-size: @font-size;
  64. line-height: @line-height;
  65. border-radius: @border-radius;
  66. select& {
  67. height: @input-height;
  68. line-height: @input-height;
  69. }
  70. textarea&,
  71. select[multiple]& {
  72. height: auto;
  73. }
  74. }
  75. //
  76. // Forms
  77. // --------------------------------------------------
  78. // Normalize non-controls
  79. //
  80. // Restyle and baseline non-control form elements.
  81. fieldset {
  82. // Chrome and Firefox set a `min-width: min-content;` on fieldsets,
  83. // so we reset that to ensure it behaves more like a standard block element.
  84. // See https://github.com/twbs/bootstrap/issues/12359.
  85. min-width: 0;
  86. padding: 0;
  87. margin: 0;
  88. border: 0;
  89. }
  90. legend {
  91. display: block;
  92. width: 100%;
  93. padding: 0;
  94. margin-bottom: @line-height-computed;
  95. font-size: (@font-size-base * 1.5);
  96. line-height: inherit;
  97. color: @legend-color;
  98. border: 0;
  99. border-bottom: 1px solid @legend-border-color;
  100. }
  101. label {
  102. display: inline-block;
  103. max-width: 100%; // Force IE8 to wrap long content (see https://github.com/twbs/bootstrap/issues/13141)
  104. margin-bottom: 5px;
  105. font-weight: 700;
  106. }
  107. // Normalize form controls
  108. //
  109. // While most of our form styles require extra classes, some basic normalization
  110. // is required to ensure optimum display with or without those classes to better
  111. // address browser inconsistencies.
  112. input[type='search'] {
  113. // Override content-box in Normalize (* isn't specific enough)
  114. box-sizing: border-box;
  115. // Search inputs in iOS
  116. //
  117. // This overrides the extra rounded corners on search inputs in iOS so that our
  118. // `.form-control` class can properly style them. Note that this cannot simply
  119. // be added to `.form-control` as it's not specific enough. For details, see
  120. // https://github.com/twbs/bootstrap/issues/11586.
  121. -webkit-appearance: none;
  122. appearance: none;
  123. }
  124. // Position radios and checkboxes better
  125. input[type='radio'],
  126. input[type='checkbox'] {
  127. margin: 4px 0 0;
  128. margin-top: 1px \9; // IE8-9
  129. line-height: normal;
  130. // Apply same disabled cursor tweak as for inputs
  131. // Some special care is needed because <label>s don't inherit their parent's `cursor`.
  132. //
  133. // Note: Neither radios nor checkboxes can be readonly.
  134. &[disabled],
  135. &.disabled,
  136. fieldset[disabled] & {
  137. cursor: @cursor-disabled;
  138. }
  139. }
  140. input[type='file'] {
  141. display: block;
  142. }
  143. // Make range inputs behave like textual form controls
  144. input[type='range'] {
  145. display: block;
  146. width: 100%;
  147. }
  148. // Make multiple select elements height not fixed
  149. select[multiple],
  150. select[size] {
  151. height: auto;
  152. }
  153. // Adjust output element
  154. output {
  155. display: block;
  156. padding-top: (@padding-base-vertical + 1);
  157. font-size: @font-size-base;
  158. line-height: @line-height-base;
  159. color: @input-color;
  160. }
  161. // Common form controls
  162. //
  163. // Shared size and type resets for form controls. Apply `.form-control` to any
  164. // of the following form controls:
  165. //
  166. // select
  167. // textarea
  168. // input[type="text"]
  169. // input[type="password"]
  170. // input[type="datetime"]
  171. // input[type="datetime-local"]
  172. // input[type="date"]
  173. // input[type="month"]
  174. // input[type="time"]
  175. // input[type="week"]
  176. // input[type="number"]
  177. // input[type="email"]
  178. // input[type="url"]
  179. // input[type="search"]
  180. // input[type="tel"]
  181. // input[type="color"]
  182. .form-control {
  183. display: block;
  184. width: 100%;
  185. height: @input-height-base; // Make inputs at least the height of their button counterpart (base line-height + padding + border)
  186. padding: @padding-base-vertical @padding-base-horizontal;
  187. font-size: @font-size-base;
  188. line-height: @line-height-base;
  189. color: @input-color;
  190. background-color: @input-bg;
  191. background-image: none; // Reset unusual Firefox-on-Android default style; see https://github.com/necolas/normalize.css/issues/214
  192. border: 1px solid @input-border;
  193. border-radius: @input-border-radius; // Note: This has no effect on <select>s in some browsers, due to the limited stylability of <select>s in CSS.
  194. box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
  195. transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
  196. // Customize the `:focus` state to imitate native WebKit styles.
  197. .form-control-focus();
  198. &::-moz-placeholder {
  199. color: @input-color-placeholder;
  200. opacity: 1;
  201. }
  202. &:-ms-input-placeholder {
  203. color: @input-color-placeholder;
  204. }
  205. &::-webkit-input-placeholder {
  206. color: @input-color-placeholder;
  207. }
  208. // Unstyle the caret on `<select>`s in IE10+.
  209. &::-ms-expand {
  210. background-color: transparent;
  211. border: 0;
  212. }
  213. // Disabled and read-only inputs
  214. //
  215. // HTML5 says that controls under a fieldset > legend:first-child won't be
  216. // disabled if the fieldset is disabled. Due to implementation difficulty, we
  217. // don't honor that edge case; we style them as disabled anyway.
  218. &[disabled],
  219. &[readonly],
  220. fieldset[disabled] & {
  221. background-color: @input-bg-disabled;
  222. opacity: 1; // iOS fix for unreadable disabled content; see https://github.com/twbs/bootstrap/issues/11655
  223. }
  224. &[disabled],
  225. fieldset[disabled] & {
  226. cursor: @cursor-disabled;
  227. }
  228. // Reset height for `textarea`s
  229. textarea& {
  230. height: auto;
  231. }
  232. }
  233. // Special styles for iOS temporal inputs
  234. //
  235. // In Mobile Safari, setting `display: block` on temporal inputs causes the
  236. // text within the input to become vertically misaligned. As a workaround, we
  237. // set a pixel line-height that matches the given height of the input, but only
  238. // for Safari. See https://bugs.webkit.org/show_bug.cgi?id=139848
  239. //
  240. // Note that as of 9.3, iOS doesn't support `week`.
  241. @media screen and (-webkit-min-device-pixel-ratio: 0) {
  242. input[type='date'],
  243. input[type='time'],
  244. input[type='datetime-local'],
  245. input[type='month'] {
  246. &.form-control {
  247. line-height: @input-height-base;
  248. }
  249. &.input-sm {
  250. line-height: @input-height-small;
  251. }
  252. &.input-lg {
  253. line-height: @input-height-large;
  254. }
  255. }
  256. }
  257. // Form groups
  258. //
  259. // Designed to help with the organization and spacing of vertical forms. For
  260. // horizontal forms, use the predefined grid classes.
  261. .form-group {
  262. margin-bottom: @form-group-margin-bottom;
  263. }
  264. // Checkboxes and radios
  265. //
  266. // Indent the labels to position radios/checkboxes as hanging controls.
  267. .radio,
  268. .checkbox {
  269. position: relative;
  270. display: block;
  271. margin-top: 10px;
  272. margin-bottom: 10px;
  273. // These are used on elements with <label> descendants
  274. &.disabled,
  275. fieldset[disabled] & {
  276. label {
  277. cursor: @cursor-disabled;
  278. }
  279. }
  280. label {
  281. min-height: @line-height-computed; // Ensure the input doesn't jump when there is no text
  282. padding-left: 20px;
  283. margin-bottom: 0;
  284. font-weight: 400;
  285. cursor: pointer;
  286. }
  287. }
  288. .radio input[type='radio'],
  289. .radio-inline input[type='radio'],
  290. .checkbox input[type='checkbox'],
  291. .checkbox-inline input[type='checkbox'] {
  292. position: absolute;
  293. margin-top: 4px \9;
  294. margin-left: -20px;
  295. }
  296. .radio + .radio,
  297. .checkbox + .checkbox {
  298. margin-top: -5px; // Move up sibling radios or checkboxes for tighter spacing
  299. }
  300. // Radios and checkboxes on same line
  301. .radio-inline,
  302. .checkbox-inline {
  303. position: relative;
  304. display: inline-block;
  305. padding-left: 20px;
  306. margin-bottom: 0;
  307. font-weight: 400;
  308. vertical-align: middle;
  309. cursor: pointer;
  310. // These are used directly on <label>s
  311. &.disabled,
  312. fieldset[disabled] & {
  313. cursor: @cursor-disabled;
  314. }
  315. }
  316. .radio-inline + .radio-inline,
  317. .checkbox-inline + .checkbox-inline {
  318. margin-top: 0;
  319. margin-left: 10px; // space out consecutive inline controls
  320. }
  321. // Static form control text
  322. //
  323. // Apply class to a `p` element to make any string of text align with labels in
  324. // a horizontal form layout.
  325. .form-control-static {
  326. min-height: (@line-height-computed + @font-size-base);
  327. // Size it appropriately next to real form controls
  328. padding-top: (@padding-base-vertical + 1);
  329. padding-bottom: (@padding-base-vertical + 1);
  330. // Remove default margin from `p`
  331. margin-bottom: 0;
  332. &.input-lg,
  333. &.input-sm {
  334. padding-right: 0;
  335. padding-left: 0;
  336. }
  337. }
  338. // Form control sizing
  339. //
  340. // Build on `.form-control` with modifier classes to decrease or increase the
  341. // height and font-size of form controls.
  342. //
  343. // The `.form-group-* form-control` variations are sadly duplicated to avoid the
  344. // issue documented in https://github.com/twbs/bootstrap/issues/15074.
  345. .input-sm {
  346. .input-size(
  347. @input-height-small; @padding-small-vertical; @padding-small-horizontal;
  348. @font-size-small; @line-height-small; @input-border-radius-small
  349. );
  350. }
  351. .form-group-sm {
  352. .form-control {
  353. height: @input-height-small;
  354. padding: @padding-small-vertical @padding-small-horizontal;
  355. font-size: @font-size-small;
  356. line-height: @line-height-small;
  357. border-radius: @input-border-radius-small;
  358. }
  359. select.form-control {
  360. height: @input-height-small;
  361. line-height: @input-height-small;
  362. }
  363. textarea.form-control,
  364. select[multiple].form-control {
  365. height: auto;
  366. }
  367. .form-control-static {
  368. height: @input-height-small;
  369. min-height: (@line-height-computed + @font-size-small);
  370. padding: (@padding-small-vertical + 1) @padding-small-horizontal;
  371. font-size: @font-size-small;
  372. line-height: @line-height-small;
  373. }
  374. }
  375. .input-lg {
  376. .input-size(
  377. @input-height-large; @padding-large-vertical; @padding-large-horizontal;
  378. @font-size-large; @line-height-large; @input-border-radius-large
  379. );
  380. }
  381. .form-group-lg {
  382. .form-control {
  383. height: @input-height-large;
  384. padding: @padding-large-vertical @padding-large-horizontal;
  385. font-size: @font-size-large;
  386. line-height: @line-height-large;
  387. border-radius: @input-border-radius-large;
  388. }
  389. select.form-control {
  390. height: @input-height-large;
  391. line-height: @input-height-large;
  392. }
  393. textarea.form-control,
  394. select[multiple].form-control {
  395. height: auto;
  396. }
  397. .form-control-static {
  398. height: @input-height-large;
  399. min-height: (@line-height-computed + @font-size-large);
  400. padding: (@padding-large-vertical + 1) @padding-large-horizontal;
  401. font-size: @font-size-large;
  402. line-height: @line-height-large;
  403. }
  404. }
  405. // Form control feedback states
  406. //
  407. // Apply contextual and semantic states to individual form controls.
  408. .has-feedback {
  409. // Enable absolute positioning
  410. position: relative;
  411. // Ensure icons don't overlap text
  412. .form-control {
  413. padding-right: (@input-height-base * 1.25);
  414. }
  415. }
  416. // Feedback icon (requires .glyphicon classes)
  417. .form-control-feedback {
  418. position: absolute;
  419. top: 0;
  420. right: 0;
  421. z-index: 2; // Ensure icon is above input groups
  422. display: block;
  423. width: @input-height-base;
  424. height: @input-height-base;
  425. line-height: @input-height-base;
  426. text-align: center;
  427. pointer-events: none;
  428. }
  429. .input-lg + .form-control-feedback,
  430. .form-group-lg .form-control + .form-control-feedback {
  431. width: @input-height-large;
  432. height: @input-height-large;
  433. line-height: @input-height-large;
  434. }
  435. .input-sm + .form-control-feedback,
  436. .form-group-sm .form-control + .form-control-feedback {
  437. width: @input-height-small;
  438. height: @input-height-small;
  439. line-height: @input-height-small;
  440. }
  441. // Feedback states
  442. .has-success {
  443. .form-control-validation(@state-success-text; @state-success-text; @state-success-bg);
  444. }
  445. .has-warning {
  446. .form-control-validation(@state-warning-text; @state-warning-text; @state-warning-bg);
  447. }
  448. .has-error {
  449. .form-control-validation(@state-danger-text; @state-danger-text; @state-danger-bg);
  450. }
  451. // Reposition feedback icon if input has visible label above
  452. .has-feedback label {
  453. & ~ .form-control-feedback {
  454. top: (@line-height-computed + 5); // Height of the `label` and its margin
  455. }
  456. &.sr-only ~ .form-control-feedback {
  457. top: 0;
  458. }
  459. }
  460. // Help text
  461. //
  462. // Apply to any element you wish to create light text for placement immediately
  463. // below a form control. Use for general help, formatting, or instructional text.
  464. .help-block {
  465. display: block; // account for any element using help-block
  466. margin-top: 5px;
  467. margin-bottom: 10px;
  468. color: lighten(@text-color, 25%); // lighten the text some for contrast
  469. }
  470. // Inline forms
  471. //
  472. // Make forms appear inline(-block) by adding the `.form-inline` class. Inline
  473. // forms begin stacked on extra small (mobile) devices and then go inline when
  474. // viewports reach <768px.
  475. //
  476. // Requires wrapping inputs and labels with `.form-group` for proper display of
  477. // default HTML form controls and our custom form controls (e.g., input groups).
  478. //
  479. // Heads up! This is mixin-ed into `.navbar-form` in navbars.less.
  480. .form-inline {
  481. // Kick in the inline
  482. @media (min-width: @screen-sm-min) {
  483. // Inline-block all the things for "inline"
  484. .form-group {
  485. display: inline-block;
  486. margin-bottom: 0;
  487. vertical-align: middle;
  488. }
  489. // In navbar-form, allow folks to *not* use `.form-group`
  490. .form-control {
  491. display: inline-block;
  492. width: auto; // Prevent labels from stacking above inputs in `.form-group`
  493. vertical-align: middle;
  494. }
  495. // Make static controls behave like regular ones
  496. .form-control-static {
  497. display: inline-block;
  498. }
  499. .control-label {
  500. margin-bottom: 0;
  501. vertical-align: middle;
  502. }
  503. // Remove default margin on radios/checkboxes that were used for stacking, and
  504. // then undo the floating of radios and checkboxes to match.
  505. .radio,
  506. .checkbox {
  507. display: inline-block;
  508. margin-top: 0;
  509. margin-bottom: 0;
  510. vertical-align: middle;
  511. label {
  512. padding-left: 0;
  513. }
  514. }
  515. .radio input[type='radio'],
  516. .checkbox input[type='checkbox'] {
  517. position: relative;
  518. margin-left: 0;
  519. }
  520. // Re-override the feedback icon.
  521. .has-feedback .form-control-feedback {
  522. top: 0;
  523. }
  524. }
  525. }
  526. // Horizontal forms
  527. //
  528. // Horizontal forms are built on grid classes and allow you to create forms with
  529. // labels on the left and inputs on the right.
  530. .form-horizontal {
  531. // Consistent vertical alignment of radios and checkboxes
  532. //
  533. // Labels also get some reset styles, but that is scoped to a media query below.
  534. .radio,
  535. .checkbox,
  536. .radio-inline,
  537. .checkbox-inline {
  538. padding-top: (@padding-base-vertical + 1); // Default padding plus a border
  539. margin-top: 0;
  540. margin-bottom: 0;
  541. }
  542. // Account for padding we're adding to ensure the alignment and of help text
  543. // and other content below items
  544. .radio,
  545. .checkbox {
  546. min-height: (@line-height-computed + (@padding-base-vertical + 1));
  547. }
  548. // Make form groups behave like rows
  549. .form-group {
  550. .make-row();
  551. }
  552. // Reset spacing and right align labels, but scope to media queries so that
  553. // labels on narrow viewports stack the same as a default form example.
  554. @media (min-width: @screen-sm-min) {
  555. .control-label {
  556. padding-top: (@padding-base-vertical + 1); // Default padding plus a border
  557. margin-bottom: 0;
  558. text-align: right;
  559. }
  560. }
  561. // Validation states
  562. //
  563. // Reposition the icon because it's now within a grid column and columns have
  564. // `position: relative;` on them. Also accounts for the grid gutter padding.
  565. .has-feedback .form-control-feedback {
  566. right: floor((@grid-gutter-width / 2));
  567. }
  568. // Form group sizes
  569. //
  570. // Quick utility class for applying `.input-lg` and `.input-sm` styles to the
  571. // inputs and labels within a `.form-group`.
  572. .form-group-lg {
  573. @media (min-width: @screen-sm-min) {
  574. .control-label {
  575. padding-top: (@padding-large-vertical + 1);
  576. font-size: @font-size-large;
  577. }
  578. }
  579. }
  580. .form-group-sm {
  581. @media (min-width: @screen-sm-min) {
  582. .control-label {
  583. padding-top: (@padding-small-vertical + 1);
  584. font-size: @font-size-small;
  585. }
  586. }
  587. }
  588. }
  589. /**
  590. * Forms
  591. * ============================================================================
  592. */
  593. .form-control {
  594. box-shadow: inset 0 2px 0 rgba(0, 0, 0, 0.04);
  595. height: auto;
  596. border: 1px solid lighten(@gray-lighter, 10);
  597. padding: 8px 12px 7px;
  598. position: relative;
  599. border-radius: 3px;
  600. color: @gray-dark;
  601. &.disabled {
  602. border: 1px solid @trim;
  603. background: #f7f8f9;
  604. color: @gray-dark;
  605. }
  606. &::-moz-placeholder {
  607. color: @gray-light;
  608. opacity: 1;
  609. }
  610. &:-ms-input-placeholder {
  611. color: @gray-light;
  612. }
  613. &::-webkit-input-placeholder {
  614. color: @gray-light;
  615. }
  616. &:focus {
  617. border-color: darken(@gray-lighter, 4);
  618. box-shadow: inset 0 2px 0 rgba(0, 0, 0, 0.04), 0 0 6px rgba(177, 171, 225, 0.3);
  619. outline: none;
  620. }
  621. object {
  622. position: absolute;
  623. top: 10px;
  624. right: 9px;
  625. }
  626. }
  627. .control-label.requiredField,
  628. .form-stacked .required .controls label {
  629. &:after {
  630. margin-left: 10px;
  631. vertical-align: bottom;
  632. content: '[required]';
  633. font-size: 12px;
  634. color: #999;
  635. text-transform: uppercase;
  636. }
  637. // Hide the crispy-forms required asterisk
  638. .asteriskField {
  639. display: none;
  640. }
  641. }
  642. .form-stacked .required .controls .radio label {
  643. // it should only appear on the first label (e.g. multi inputs)
  644. &:after {
  645. content: '';
  646. }
  647. }
  648. .form-group,
  649. .control-group {
  650. margin-bottom: 15px;
  651. }
  652. .form-actions {
  653. border-top: 1px solid #e9ebec;
  654. background: none;
  655. padding: 20px 0 0;
  656. margin-bottom: 20px;
  657. p {
  658. padding: 0;
  659. line-height: 15px;
  660. }
  661. .note {
  662. color: @gray;
  663. line-height: 30px;
  664. }
  665. }
  666. .help-block {
  667. font-weight: normal;
  668. color: @gray;
  669. font-size: 90%;
  670. margin-bottom: 0;
  671. }
  672. textarea.form-control {
  673. height: 150px;
  674. min-height: 150px;
  675. min-width: 100%;
  676. max-width: 100%;
  677. }
  678. legend {
  679. margin: 20px 0;
  680. border-bottom: 1px solid #e9ebec;
  681. padding-bottom: 10px;
  682. }
  683. .inputs-list label {
  684. padding-left: 18px;
  685. }
  686. .inputs-list label input[type='radio'],
  687. .inputs-list label input[type='checkbox'] {
  688. float: left;
  689. margin-left: -18px;
  690. }
  691. label {
  692. font-weight: 600;
  693. &.checkbox,
  694. &.radio {
  695. padding-left: 25px;
  696. position: relative;
  697. input[type='checkbox'] {
  698. top: 1px;
  699. left: 0;
  700. margin-left: 0 !important;
  701. }
  702. }
  703. }
  704. .boolean-radio-select .inputs-list ul {
  705. list-style: none;
  706. margin-bottom: 0;
  707. padding-left: 0;
  708. li {
  709. margin-bottom: 5px;
  710. &:last-child {
  711. margin-bottom: 0;
  712. }
  713. label {
  714. font-weight: normal;
  715. }
  716. }
  717. }
  718. .radio,
  719. .checkbox {
  720. label {
  721. font-weight: 600;
  722. }
  723. }
  724. .has-error .form-control {
  725. border-color: #c9c0d1;
  726. box-shadow: inset 0 2px 0 rgba(0, 0, 0, 0.04);
  727. }
  728. .has-error .form-control:focus {
  729. border-color: #a598b2;
  730. box-shadow: inset 0 2px 0 rgba(0, 0, 0, 0.04), 0 0 6px rgba(177, 171, 225, 0.3);
  731. outline: none;
  732. }
  733. .error,
  734. .has-error .help-block,
  735. .has-error .control-label,
  736. .has-error .radio,
  737. .has-error .checkbox,
  738. .has-error .radio-inline,
  739. .has-error .checkbox-inline,
  740. .has-error.radio label,
  741. .has-error.checkbox label,
  742. .has-error.radio-inline label,
  743. .has-error.checkbox-inline label {
  744. color: @red;
  745. }
  746. input.form-control[disabled],
  747. textarea.form-control[disabled] {
  748. background: #f9f9f9;
  749. color: #999;
  750. }
  751. .disabled-indicator {
  752. margin-left: 5px;
  753. font-size: 80%;
  754. }
  755. .form-password {
  756. &.editing {
  757. div:first-child {
  758. width: 85%;
  759. display: inline-block;
  760. }
  761. div:last-child {
  762. line-height: 37px;
  763. margin-left: 10px;
  764. display: inline-block;
  765. }
  766. }
  767. &.saved {
  768. a {
  769. margin-left: 10px;
  770. }
  771. }
  772. }
  773. .deploy-form {
  774. display: flex;
  775. align-items: baseline;
  776. justify-content: space-between;
  777. .controls {
  778. display: flex;
  779. align-items: baseline;
  780. justify-content: space-around;
  781. }
  782. }