You are here

webform_structured_text.css in Webform Structured Text 6

Same filename and directory in other branches
  1. 7 webform_structured_text.css
/*
    Webform Structured Text CSS
    ===========================
    Used when field is rendered to mimic a single input field.

    Customising the look of your structured text boxes:
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    1.  Either
        a) copy the contents of CSS file into your theme's CSS file, or
        b) copy this entire file into your theme where your other CSS files are,
           rename it to <your_theme_name>_webform_structured_text.css, and then
           include it as a CSS file to be loaded (usually done through your theme's
           .info file; make sure you rename the CSS file so it's name doesn't clash
           with this file),
    and then modify the style elements as outlined below.
*/

/*  The surrounding div used to make the collection of input text boxes look like
    a single text box.  Override this selector's style in your theme to mimic how
    your input text boxes are rendered.  This will usually involve modifying border
    styles, padding, margins, and potentially the background.
*/
div.structured-text-one-field {
  border: 1px solid #CCC;
  background: #FFF;
  padding: 0.1em;
  margin: 4px 0;
  line-height: normal;
  display: inline-block !important;
}

/*  If your theme makes input text boxes appear different when the user hovers over
    them (eg., the boarder colour or background colour changes, etc.), override
    this selector in your theme.
*/
div.structured-text-one-field:hover {
}

/*  Override this selector in your theme to match how errors are highlighted in
    input text boxes.
*/
div.structured-text-one-field.has-error {
  border: 1px solid #ed541d;
}

/*  You should not need to modify this selector's styles below.  They alter the
    appearance of the inner input text fields to make them appear borderless and
    not distinct from the larger field.
*/
div.structured-text-one-field input.structured-text {
  padding: 0 !important;
  margin: 0 !important;
  border: none !important;
  background: transparent !important;
}

/*  You may wish to alter the background and border-bottom colours when the
    individual input boxes have focus if you are using a theme with light-coloured
    text in form fields (eg., white text on a dark background).  The colours used
    below are a pale yellow with a slightly darker yellow dotted underline, against
    which light-coloured text would be difficult to read.
*/
div.structured-text-one-field input.structured-text:focus {
  background: #FFFFDF !important;
  border-bottom: 1px dotted #FFCC00 !important;
}

File

webform_structured_text.css
View source
  1. /*
  2. Webform Structured Text CSS
  3. ===========================
  4. Used when field is rendered to mimic a single input field.
  5. Customising the look of your structured text boxes:
  6. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  7. 1. Either
  8. a) copy the contents of CSS file into your theme's CSS file, or
  9. b) copy this entire file into your theme where your other CSS files are,
  10. rename it to _webform_structured_text.css, and then
  11. include it as a CSS file to be loaded (usually done through your theme's
  12. .info file; make sure you rename the CSS file so it's name doesn't clash
  13. with this file),
  14. and then modify the style elements as outlined below.
  15. */
  16. /* The surrounding div used to make the collection of input text boxes look like
  17. a single text box. Override this selector's style in your theme to mimic how
  18. your input text boxes are rendered. This will usually involve modifying border
  19. styles, padding, margins, and potentially the background.
  20. */
  21. div.structured-text-one-field {
  22. border: 1px solid #CCC;
  23. background: #FFF;
  24. padding: 0.1em;
  25. margin: 4px 0;
  26. line-height: normal;
  27. display: inline-block !important;
  28. }
  29. /* If your theme makes input text boxes appear different when the user hovers over
  30. them (eg., the boarder colour or background colour changes, etc.), override
  31. this selector in your theme.
  32. */
  33. div.structured-text-one-field:hover {
  34. }
  35. /* Override this selector in your theme to match how errors are highlighted in
  36. input text boxes.
  37. */
  38. div.structured-text-one-field.has-error {
  39. border: 1px solid #ed541d;
  40. }
  41. /* You should not need to modify this selector's styles below. They alter the
  42. appearance of the inner input text fields to make them appear borderless and
  43. not distinct from the larger field.
  44. */
  45. div.structured-text-one-field input.structured-text {
  46. padding: 0 !important;
  47. margin: 0 !important;
  48. border: none !important;
  49. background: transparent !important;
  50. }
  51. /* You may wish to alter the background and border-bottom colours when the
  52. individual input boxes have focus if you are using a theme with light-coloured
  53. text in form fields (eg., white text on a dark background). The colours used
  54. below are a pale yellow with a slightly darker yellow dotted underline, against
  55. which light-coloured text would be difficult to read.
  56. */
  57. div.structured-text-one-field input.structured-text:focus {
  58. background: #FFFFDF !important;
  59. border-bottom: 1px dotted #FFCC00 !important;
  60. }