views-ui.pcss.css

Same filename in other branches
  1. 9 core/themes/claro/css/components/views-ui.pcss.css
  2. 8.9.x core/themes/claro/css/components/views-ui.pcss.css
  3. 11.x core/themes/claro/css/components/views-ui.pcss.css
/**
 * Views styling
 */

/* @group Forms */

/**
 * Claro positions the summary absolutely, but does not have a way to ignore
 * details without a summary so we make one up.
 *
 * @todo Neither a fieldset without legend nor a details without summary is
 *   valid HTML markup in any way. Refactor Views UI to not produce such invalid
 *   markup.
 */
details.fieldset-no-legend {
  padding-top: 0;
}

/**
 * Being extra safe here and scoping this to the add view wizard form (where
 * a layout problem occurs for the Display format details if we don't fix its
 * padding), but it's probably safe to just let it apply everywhere.
 */
.views-ui-dialog input.form-submit,
.views-admin a.button,
.views-ui-dialog a.button {
  margin-top: 0;
  margin-right: 0;
  margin-bottom: 0;
}
[dir="rtl"] .views-ui-dialog input.form-submit,
[dir="rtl"] .views-admin a.button,
[dir="rtl"] .views-ui-dialog a.button {
  margin-right: 1em;
  margin-left: 0;
}
[dir="rtl"] .views-ui-dialog input.form-submit:first-child,
[dir="rtl"] .views-admin a.button:first-child,
[dir="rtl"] .views-ui-dialog a.button:first-child {
  margin-right: 0;
}

.views-ui-dialog .form--flex {
  display: flex;
  overflow: hidden;
  flex-wrap: wrap;
}

.views-ui-dialog .form-item {
  margin-top: var(--space-m);
  margin-bottom: var(--space-m);
}
.views-ui-dialog .form-type--boolean {
  margin-right: 0;
  margin-left: 0;
}
.views-ui-dialog .form-type--boolean .form-boolean {
  top: 0;
  float: none;
  margin: 0 0.25rem 0 0; /* LTR */
  transform: none;
}
[dir="rtl"] .views-ui-dialog .form-type--boolean .form-boolean {
  margin-right: 0;
  margin-left: 0.25rem;
}

.views-ui-dialog .form-boolean-group .form-type--boolean {
  margin-top: 0.4em;
  margin-bottom: 0.4em;
}

.views-ui-dialog .form-item:first-of-type.description {
  margin: 0 0 var(--space-l) 0;
  padding-bottom: var(--space-s);
  border-bottom: 0.0625rem solid var(--color-gray-200);
  font-weight: bold;
}

/* So "remove" link appears next to the checkbox. */
.views-ui-dialog .draggable .form-type--checkbox {
  display: inline-block;
  margin: 0 0.25rem;
}

.views-ui-dialog .form-element {
  min-height: calc(((var(--input-padding-vertical--small) + var(--input-border-size)) * 2) + var(--input-line-height--small)); /* iOS. */
  padding: var(--input-padding-vertical--small) var(--input-padding-horizontal--small);
  font-size: var(--input-font-size--small);
  line-height: var(--input-line-height--small);
}
.views-ui-dialog .form-element--type-select {
  padding-inline-end: calc(2rem - var(--input-border-size));
  background-position-y: 56%;
}
.views-ui-dialog td .form-element {
  width: auto;
}

/* @group Dependent options */

/* This is necessary to supercede the Claro .form-item
 * reset declaration that sets the margin to zero.
 */
.form-item-options-expose-required,
.form-item-options-expose-label,
.form-item-options-expose-field-identifier,
.form-item-options-expose-description {
  margin-left: 1.5em; /* LTR */
}
[dir="rtl"] .form-item-options-expose-required,
[dir="rtl"] .form-item-options-expose-label,
[dir="rtl"] .form-item-options-expose-field-identifier,
[dir="rtl"] .form-item-options-expose-description {
  margin-right: 1.5em;
  margin-left: 0;
}

.views-admin-dependent .form-item .form-item,
.views-admin-dependent .form-type-checkboxes,
.views-admin-dependent .form-type-radios,
.views-admin-dependent .form-item .form-item,
.form-item-options-expose-required,
.form-item-options-expose-label,
.form-item-options-expose-field-identifier,
.form-item-options-expose-description {
  margin-top: 6px;
  margin-bottom: 6px;
}

.views-admin-dependent .form-type-radio,
.views-admin-dependent .form-radios .form-item {
  margin-top: 2px;
  margin-bottom: 2px;
}

/* @end */

/* @group Lists */

.views-admin .item-list ul {
  margin: 0;
  padding: 0;
}

.views-admin .links li {
  padding-right: 0; /* LTR */
}
[dir="rtl"] .views-admin .links li {
  padding-left: 0;
}

.views-admin .button .links li {
  padding-right: 12px; /* LTR */
}
[dir="rtl"] .views-admin .button .links li {
  padding-left: 12px;
}

.views-display-top__extra-actions-wrapper {
  margin: calc(var(--space-xs) / 2) var(--space-xs) var(--space-xs);
}

/* @end */

/* @group Tables */

.views-ui-rearrange-filter-form td,
.views-ui-rearrange-filter-form th {
  vertical-align: top;
}

/* @end */

/* @group Attachment details */

#edit-display-settings-title {
  color: var(--color-blue-400);
}

/* @end */

/* @group Attachment details tabs
 *
 * The tabs that switch between sections
 *
 * @todo this group contains lots of duplicates from core styles because Claro
 *   has its custom markup for views tabs. Some of these could be removed after
 *   https://www.drupal.org/node/3051605 has been solved.
 */

.views-tabs {
  display: flex;
  overflow: visible;
  flex-wrap: wrap;
  margin: 0 var(--space-l) 0 0; /* LTR */
  padding: 0;
  list-style: none;
  text-align: left; /* LTR */
  border-bottom: 0 none;
}
[dir="rtl"] .views-tabs {
  margin-right: 0;
  margin-left: var(--space-l);
  text-align: right;
}
.views-tabs .views-display-deleted-link {
  text-decoration: line-through;
}
.views-tabs li,
.views-tabs li.is-active {
  width: auto;
  padding: 0;
  border: 0;
  background: transparent;
}
.views-tabs li.add ul.action-list li {
  margin: 0;
}
.views-tabs li {
  margin: 0 5px 5px 6px; /* LTR */
}
[dir="rtl"] .views-tabs li {
  margin-right: 6px;
  margin-left: 5px;
}
.views-tabs li + li {
  border-top: 0;
}
.views-tabs li:hover {
  padding-left: 0; /* LTR */
  border: 0;
}
[dir="rtl"] .views-tabs li:hover {
  padding-right: 0;
}
.views-tabs a {
  display: inline-block;
  padding: 10px;
  border: var(--input-border-size) solid #cbcbcb;
  border-radius: 7px;
  font-size: small;
  line-height: 1.3333;
}

/* Display a red border if the display doesn't validate. */
.views-tabs li.is-active a.is-active.error,
.views-tabs .error {
  padding: 8px;
  border: 2px solid #ed541d;
}
.views-tabs a:focus {
  outline: none;
}
.views-tabs li a {
  text-decoration: none;
  background-color: #fff;
}
.views-tabs li a:hover,
.views-tabs li.is-active a,
.views-tabs li.is-active a.is-active {
  color: #fff;
  background-color: #555;
}
.views-tabs .add {
  position: relative;
}
.views-tabs .add a {
  padding: 9px 13px 9px 9px;
  color: var(--color-gray-800);
  border: none;
  border-radius: var(--base-border-radius);
  background-color: transparent;
  font-size: var(--font-size-base);
  font-weight: 700;
}
.views-tabs .add a::before {
  display: inline-block;
  width: 1em;
  height: calc(1em - (var(--input-border-size) * 2));
  content: "";
  /* Copy of icon from .action-link--icon-plus */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' stroke-width='2' stroke='%23545560'%3E%3Cpath d='m3 8h10'/%3E%3Cpath d='m8 3v10'/%3E%3C/svg%3E");
}
.views-tabs .add a:hover {
  color: var(--color-absolutezero-hover);
  background-color: var(--color-bgblue-hover);
}
.views-tabs .add a:hover::before {
  /* Copy of icon from .action-link--icon-plus:hover */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' stroke-width='2' stroke='%230036b1'%3E%3Cpath d='m3 8h10'/%3E%3Cpath d='m8 3v10'/%3E%3C/svg%3E");
}
.views-tabs .add a:focus {
  background-color: var(--color-bgblue-active);
  box-shadow: 0 0 0 3px #26a769;
}
.views-tabs .add.open a {
  color: var(--color-white);
  background-color: var(--color-absolutezero);
}
.views-tabs .add.open a::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' stroke-width='2' stroke='%23FFFFFF'%3E%3Cpath d='m3 8h10'/%3E%3Cpath d='m8 3v10'/%3E%3C/svg%3E");
}
/* Hide core icon, added via JS that isn't accessible via theme function. */
.views-tabs .add .icon.add {
  display: none;
}
.views-tabs .action-list {
  position: absolute;
  z-index: 50;
  top: 38px;
  left: -2px; /* LTR */
  margin: 0;
  box-shadow: var(--details-box-shadow);
}
[dir="rtl"] .views-tabs .action-list {
  right: 0;
  left: auto;
}
.views-tabs .action-list li {
  display: block;
}
.views-tabs .action-list li {
  border-width: 0 1px;
  border-style: solid;
  border-color: #cbcbcb;
  background-color: #fff;
}
.views-tabs .action-list li:first-child {
  border-width: 1px 1px 0;
  border-radius: 0 var(--base-border-radius) 0 0; /* LTR */
}
[dir="rtl"] .views-tabs .action-list li:first-child {
  border-radius: 0 0 0 var(--base-border-radius);
}
.views-tabs .action-list li:last-child,
.views-displays .action-list li:last-child {
  padding-bottom: 0.4rem;
  border-width: 0 1px 1px;
  border-bottom-right-radius: var(--button-border-radius-size);
  border-bottom-left-radius: var(--button-border-radius-size);
}
.views-tabs__action-list-button {
  width: 100%;
  margin: 0;
  padding: var(--space-s) var(--space-l);
  text-align: left;
  border: medium none;
  border-radius: 0;
  background: none repeat scroll 0 0 transparent;
  font-weight: normal;
}

/* JS moves Views action buttons under a secondary tabs container, which causes
a large layout shift. We mitigate this by using animations to temporarily hide
the buttons, but they will appear after a set amount of time just in case the JS
is loaded but does not properly run. */
@media (scripting: enabled) {
  .views-tabs__action-list-button:not(.views-tabs--secondary *) {
    animation-name: appear;
    animation-duration: 0.1s;
    /* Buttons will be hidden for the amount of time in the animation-delay if
    not moved. Note this is the approximate time to download the views
    aggregate CSS with slow 3G. */
    animation-delay: 5s;
    animation-iteration-count: 1;
    animation-fill-mode: backwards;
  }
}

@keyframes appear {
  from {
    display: none;
  }

  to {
    display: unset;
  }
}

/* RTL required for precedence over core's styles. */
[dir="rtl"] .views-tabs__action-list-button {
  margin: 0;
}
.views-tabs__action-list-button.button:hover,
.views-tabs__action-list-button.button:focus {
  color: var(--color-white);
  background-color: var(--color-absolutezero);
}
/* Remove outline provided by default styling */
.views-tabs__action-list-button:not(:focus) {
  box-shadow: none;
}

/* @end */

/* @group Attachment buckets
 *
 * These are the individual "buckets," or boxes, inside the display settings area
 */

.views-ui-display-tab-bucket .links {
  padding: 2px 6px 4px;
}

.views-ui-display-tab-bucket .links li + li {
  margin-left: 3px; /* LTR */
}
[dir="rtl"] .views-ui-display-tab-bucket .links li + li {
  margin-right: 3px;
  margin-left: 0;
}

/* @end */

/* @group Rearrange filter criteria */

.views-ui-rearrange-filter-form tr {
  border-bottom: 0;
}
.views-ui-rearrange-filter-form tr:first-of-type {
  border-top: 0.0625rem solid var(--color-gray-200);
}
.views-ui-rearrange-filter-form tr:not(.draggable):hover {
  background: inherit;
}
.views-ui-rearrange-filter-form .action-links {
  float: left;
  margin: 0 0 1em;
  padding: 0;
}
.views-ui-rearrange-filter-form .tabledrag-toggle-weight-wrapper {
  float: right;
}

.views-ui-rearrange-filter-form .tabledrag-cell {
  position: relative;
}

.views-ui-rearrange-filter-form [id^="views-row"] {
  border: medium none;
}

.views-ui-rearrange-filter-form tr td:last-child {
  border-right: medium none; /* LTR */
}
[dir="rtl"] .views-ui-rearrange-filter-form tr td:last-child {
  border-right: initial;
  border-left: medium none;
}

.views-ui-rearrange-filter-form .filter-group-operator-row {
  border-right: 1px solid transparent !important;
  border-left: 1px solid transparent !important;
}

.views-ui-rearrange-filter-form tr.drag td {
  background-color: #fe7 !important;
}

.views-ui-rearrange-filter-form tr.drag-previous td {
  background-color: #ffb !important;
}

.views-ui-rearrange-filter-form .draggable td {
  vertical-align: middle;
}

/* @end */

/* @group Live preview elements */

.views-query-info pre {
  margin-top: 0;
  margin-bottom: 0;
}

/* @group Query info table */

.views-query-info table {
  border-spacing: 1px;
  border-radius: 7px;
}

.views-query-info table tr td:last-child {
  /* Fixes a Claro style that bleeds down into this table unnecessarily */
  border-right: 0 none; /* LTR */
}
[dir="rtl"] .views-query-info table tr td:last-child {
  border-right: initial;
  border-left: 0 none;
}

/* @end */

/* @end */

/* @group Add view */

.form-item-page-create,
.form-item-block-create {
  margin-top: 13px;
}

/* @end */

/* @group Modal dialog box
 *
 * The contents of the popup dialog on the views edit form.
 */

.filterable-option .form-item.form-type-checkbox {
  padding-top: 4px;
  /* This selector is aggressive because Claro's reset for .form-items is aggressive. */
  padding-bottom: 4px;
  padding-left: 4px; /* LTR */
}
[dir="rtl"] .filterable-option .form-item.form-type-checkbox {
  padding-right: 4px;
  padding-left: 8px;
}

/* @end */

/* @group Grouping styles
 *
 * For grouping related form elements together, mainly used with exposed
 * filters.
 */
.views-config-group-region {
  display: table;
  margin: var(--space-l) 0;
  border: 0.0625rem solid var(--color-gray-200);
  border-collapse: collapse;
}
.views-config-group-region .views-group-box {
  position: relative;
  display: table-cell;
  padding: var(--space-l);
  border: 0.0625rem solid var(--color-gray-200);
}
.views-config-group-region .views-group-box--operator {
  padding-right: var(--space-xl);
  border-right-width: 0;
}
[dir="rtl"] .views-config-group-region .views-group-box--operator {
  padding-right: var(--space-l);
  padding-left: var(--space-xl);
  border-right-width: 0.0625rem;
  border-left-width: 0;
}
.views-config-group-region .views-group-box--value {
  padding: 0;
  border-left-width: 0; /* LTR */
}
[dir="rtl"] .views-config-group-region .views-group-box--value {
  border-right-width: 0;
  border-left-width: 0.0625rem;
}
.views-config-group-region .views-group-box--value > .form-item {
  margin-right: var(--space-l); /* LTR */
  margin-left: var(--space-xl); /* LTR */
}
[dir="rtl"] .views-config-group-region .views-group-box--value > .form-item {
  margin-right: var(--space-xl); /* LTR */
  margin-left: var(--space-l); /* LTR */
}
.views-config-group-region .views-group-box--value > .form-item::before {
  position: absolute;
  top: 0;
  left: 0;
  width: 0.0625rem;
  height: 100%;
  content: "";
  border-left: 0.0625rem solid var(--color-gray-200);
}
[dir="rtl"] .views-config-group-region .views-group-box--value > .form-item::before {
  right: 0;
}
.views-config-group-region .views-group-box--value > .form-item::after {
  position: absolute;
  z-index: 1;
  top: 3.8rem;
  left: calc(var(--space-m) * -1); /* LTR */
  padding: 0 0.3rem 0.3rem 0.4rem; /* LTR */
  content: ">";
  color: var(--color-gray-600);
  border: 0.0625rem solid var(--color-gray-200);
  background: #fff;
  font-size: var(--font-size-h1);
  font-weight: bold;
  line-height: var(--font-size-h1);
}

[dir="rtl"] .views-config-group-region .views-group-box--value > .form-item::after {
  right: calc(var(--space-m) * -1);
  left: auto;
  padding-right: 0.4rem;
  padding-left: 0.3rem;
}

File

core/themes/claro/css/components/views-ui.pcss.css

View source
  1. /**
  2. * Views styling
  3. */
  4. /* @group Forms */
  5. /**
  6. * Claro positions the summary absolutely, but does not have a way to ignore
  7. * details without a summary so we make one up.
  8. *
  9. * @todo Neither a fieldset without legend nor a details without summary is
  10. * valid HTML markup in any way. Refactor Views UI to not produce such invalid
  11. * markup.
  12. */
  13. details.fieldset-no-legend {
  14. padding-top: 0;
  15. }
  16. /**
  17. * Being extra safe here and scoping this to the add view wizard form (where
  18. * a layout problem occurs for the Display format details if we don't fix its
  19. * padding), but it's probably safe to just let it apply everywhere.
  20. */
  21. .views-ui-dialog input.form-submit,
  22. .views-admin a.button,
  23. .views-ui-dialog a.button {
  24. margin-top: 0;
  25. margin-right: 0;
  26. margin-bottom: 0;
  27. }
  28. [dir="rtl"] .views-ui-dialog input.form-submit,
  29. [dir="rtl"] .views-admin a.button,
  30. [dir="rtl"] .views-ui-dialog a.button {
  31. margin-right: 1em;
  32. margin-left: 0;
  33. }
  34. [dir="rtl"] .views-ui-dialog input.form-submit:first-child,
  35. [dir="rtl"] .views-admin a.button:first-child,
  36. [dir="rtl"] .views-ui-dialog a.button:first-child {
  37. margin-right: 0;
  38. }
  39. .views-ui-dialog .form--flex {
  40. display: flex;
  41. overflow: hidden;
  42. flex-wrap: wrap;
  43. }
  44. .views-ui-dialog .form-item {
  45. margin-top: var(--space-m);
  46. margin-bottom: var(--space-m);
  47. }
  48. .views-ui-dialog .form-type--boolean {
  49. margin-right: 0;
  50. margin-left: 0;
  51. }
  52. .views-ui-dialog .form-type--boolean .form-boolean {
  53. top: 0;
  54. float: none;
  55. margin: 0 0.25rem 0 0; /* LTR */
  56. transform: none;
  57. }
  58. [dir="rtl"] .views-ui-dialog .form-type--boolean .form-boolean {
  59. margin-right: 0;
  60. margin-left: 0.25rem;
  61. }
  62. .views-ui-dialog .form-boolean-group .form-type--boolean {
  63. margin-top: 0.4em;
  64. margin-bottom: 0.4em;
  65. }
  66. .views-ui-dialog .form-item:first-of-type.description {
  67. margin: 0 0 var(--space-l) 0;
  68. padding-bottom: var(--space-s);
  69. border-bottom: 0.0625rem solid var(--color-gray-200);
  70. font-weight: bold;
  71. }
  72. /* So "remove" link appears next to the checkbox. */
  73. .views-ui-dialog .draggable .form-type--checkbox {
  74. display: inline-block;
  75. margin: 0 0.25rem;
  76. }
  77. .views-ui-dialog .form-element {
  78. min-height: calc(((var(--input-padding-vertical--small) + var(--input-border-size)) * 2) + var(--input-line-height--small)); /* iOS. */
  79. padding: var(--input-padding-vertical--small) var(--input-padding-horizontal--small);
  80. font-size: var(--input-font-size--small);
  81. line-height: var(--input-line-height--small);
  82. }
  83. .views-ui-dialog .form-element--type-select {
  84. padding-inline-end: calc(2rem - var(--input-border-size));
  85. background-position-y: 56%;
  86. }
  87. .views-ui-dialog td .form-element {
  88. width: auto;
  89. }
  90. /* @group Dependent options */
  91. /* This is necessary to supercede the Claro .form-item
  92. * reset declaration that sets the margin to zero.
  93. */
  94. .form-item-options-expose-required,
  95. .form-item-options-expose-label,
  96. .form-item-options-expose-field-identifier,
  97. .form-item-options-expose-description {
  98. margin-left: 1.5em; /* LTR */
  99. }
  100. [dir="rtl"] .form-item-options-expose-required,
  101. [dir="rtl"] .form-item-options-expose-label,
  102. [dir="rtl"] .form-item-options-expose-field-identifier,
  103. [dir="rtl"] .form-item-options-expose-description {
  104. margin-right: 1.5em;
  105. margin-left: 0;
  106. }
  107. .views-admin-dependent .form-item .form-item,
  108. .views-admin-dependent .form-type-checkboxes,
  109. .views-admin-dependent .form-type-radios,
  110. .views-admin-dependent .form-item .form-item,
  111. .form-item-options-expose-required,
  112. .form-item-options-expose-label,
  113. .form-item-options-expose-field-identifier,
  114. .form-item-options-expose-description {
  115. margin-top: 6px;
  116. margin-bottom: 6px;
  117. }
  118. .views-admin-dependent .form-type-radio,
  119. .views-admin-dependent .form-radios .form-item {
  120. margin-top: 2px;
  121. margin-bottom: 2px;
  122. }
  123. /* @end */
  124. /* @group Lists */
  125. .views-admin .item-list ul {
  126. margin: 0;
  127. padding: 0;
  128. }
  129. .views-admin .links li {
  130. padding-right: 0; /* LTR */
  131. }
  132. [dir="rtl"] .views-admin .links li {
  133. padding-left: 0;
  134. }
  135. .views-admin .button .links li {
  136. padding-right: 12px; /* LTR */
  137. }
  138. [dir="rtl"] .views-admin .button .links li {
  139. padding-left: 12px;
  140. }
  141. .views-display-top__extra-actions-wrapper {
  142. margin: calc(var(--space-xs) / 2) var(--space-xs) var(--space-xs);
  143. }
  144. /* @end */
  145. /* @group Tables */
  146. .views-ui-rearrange-filter-form td,
  147. .views-ui-rearrange-filter-form th {
  148. vertical-align: top;
  149. }
  150. /* @end */
  151. /* @group Attachment details */
  152. #edit-display-settings-title {
  153. color: var(--color-blue-400);
  154. }
  155. /* @end */
  156. /* @group Attachment details tabs
  157. *
  158. * The tabs that switch between sections
  159. *
  160. * @todo this group contains lots of duplicates from core styles because Claro
  161. * has its custom markup for views tabs. Some of these could be removed after
  162. * https://www.drupal.org/node/3051605 has been solved.
  163. */
  164. .views-tabs {
  165. display: flex;
  166. overflow: visible;
  167. flex-wrap: wrap;
  168. margin: 0 var(--space-l) 0 0; /* LTR */
  169. padding: 0;
  170. list-style: none;
  171. text-align: left; /* LTR */
  172. border-bottom: 0 none;
  173. }
  174. [dir="rtl"] .views-tabs {
  175. margin-right: 0;
  176. margin-left: var(--space-l);
  177. text-align: right;
  178. }
  179. .views-tabs .views-display-deleted-link {
  180. text-decoration: line-through;
  181. }
  182. .views-tabs li,
  183. .views-tabs li.is-active {
  184. width: auto;
  185. padding: 0;
  186. border: 0;
  187. background: transparent;
  188. }
  189. .views-tabs li.add ul.action-list li {
  190. margin: 0;
  191. }
  192. .views-tabs li {
  193. margin: 0 5px 5px 6px; /* LTR */
  194. }
  195. [dir="rtl"] .views-tabs li {
  196. margin-right: 6px;
  197. margin-left: 5px;
  198. }
  199. .views-tabs li + li {
  200. border-top: 0;
  201. }
  202. .views-tabs li:hover {
  203. padding-left: 0; /* LTR */
  204. border: 0;
  205. }
  206. [dir="rtl"] .views-tabs li:hover {
  207. padding-right: 0;
  208. }
  209. .views-tabs a {
  210. display: inline-block;
  211. padding: 10px;
  212. border: var(--input-border-size) solid #cbcbcb;
  213. border-radius: 7px;
  214. font-size: small;
  215. line-height: 1.3333;
  216. }
  217. /* Display a red border if the display doesn't validate. */
  218. .views-tabs li.is-active a.is-active.error,
  219. .views-tabs .error {
  220. padding: 8px;
  221. border: 2px solid #ed541d;
  222. }
  223. .views-tabs a:focus {
  224. outline: none;
  225. }
  226. .views-tabs li a {
  227. text-decoration: none;
  228. background-color: #fff;
  229. }
  230. .views-tabs li a:hover,
  231. .views-tabs li.is-active a,
  232. .views-tabs li.is-active a.is-active {
  233. color: #fff;
  234. background-color: #555;
  235. }
  236. .views-tabs .add {
  237. position: relative;
  238. }
  239. .views-tabs .add a {
  240. padding: 9px 13px 9px 9px;
  241. color: var(--color-gray-800);
  242. border: none;
  243. border-radius: var(--base-border-radius);
  244. background-color: transparent;
  245. font-size: var(--font-size-base);
  246. font-weight: 700;
  247. }
  248. .views-tabs .add a::before {
  249. display: inline-block;
  250. width: 1em;
  251. height: calc(1em - (var(--input-border-size) * 2));
  252. content: "";
  253. /* Copy of icon from .action-link--icon-plus */
  254. background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' stroke-width='2' stroke='%23545560'%3E%3Cpath d='m3 8h10'/%3E%3Cpath d='m8 3v10'/%3E%3C/svg%3E");
  255. }
  256. .views-tabs .add a:hover {
  257. color: var(--color-absolutezero-hover);
  258. background-color: var(--color-bgblue-hover);
  259. }
  260. .views-tabs .add a:hover::before {
  261. /* Copy of icon from .action-link--icon-plus:hover */
  262. background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' stroke-width='2' stroke='%230036b1'%3E%3Cpath d='m3 8h10'/%3E%3Cpath d='m8 3v10'/%3E%3C/svg%3E");
  263. }
  264. .views-tabs .add a:focus {
  265. background-color: var(--color-bgblue-active);
  266. box-shadow: 0 0 0 3px #26a769;
  267. }
  268. .views-tabs .add.open a {
  269. color: var(--color-white);
  270. background-color: var(--color-absolutezero);
  271. }
  272. .views-tabs .add.open a::before {
  273. background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' stroke-width='2' stroke='%23FFFFFF'%3E%3Cpath d='m3 8h10'/%3E%3Cpath d='m8 3v10'/%3E%3C/svg%3E");
  274. }
  275. /* Hide core icon, added via JS that isn't accessible via theme function. */
  276. .views-tabs .add .icon.add {
  277. display: none;
  278. }
  279. .views-tabs .action-list {
  280. position: absolute;
  281. z-index: 50;
  282. top: 38px;
  283. left: -2px; /* LTR */
  284. margin: 0;
  285. box-shadow: var(--details-box-shadow);
  286. }
  287. [dir="rtl"] .views-tabs .action-list {
  288. right: 0;
  289. left: auto;
  290. }
  291. .views-tabs .action-list li {
  292. display: block;
  293. }
  294. .views-tabs .action-list li {
  295. border-width: 0 1px;
  296. border-style: solid;
  297. border-color: #cbcbcb;
  298. background-color: #fff;
  299. }
  300. .views-tabs .action-list li:first-child {
  301. border-width: 1px 1px 0;
  302. border-radius: 0 var(--base-border-radius) 0 0; /* LTR */
  303. }
  304. [dir="rtl"] .views-tabs .action-list li:first-child {
  305. border-radius: 0 0 0 var(--base-border-radius);
  306. }
  307. .views-tabs .action-list li:last-child,
  308. .views-displays .action-list li:last-child {
  309. padding-bottom: 0.4rem;
  310. border-width: 0 1px 1px;
  311. border-bottom-right-radius: var(--button-border-radius-size);
  312. border-bottom-left-radius: var(--button-border-radius-size);
  313. }
  314. .views-tabs__action-list-button {
  315. width: 100%;
  316. margin: 0;
  317. padding: var(--space-s) var(--space-l);
  318. text-align: left;
  319. border: medium none;
  320. border-radius: 0;
  321. background: none repeat scroll 0 0 transparent;
  322. font-weight: normal;
  323. }
  324. /* JS moves Views action buttons under a secondary tabs container, which causes
  325. a large layout shift. We mitigate this by using animations to temporarily hide
  326. the buttons, but they will appear after a set amount of time just in case the JS
  327. is loaded but does not properly run. */
  328. @media (scripting: enabled) {
  329. .views-tabs__action-list-button:not(.views-tabs--secondary *) {
  330. animation-name: appear;
  331. animation-duration: 0.1s;
  332. /* Buttons will be hidden for the amount of time in the animation-delay if
  333. not moved. Note this is the approximate time to download the views
  334. aggregate CSS with slow 3G. */
  335. animation-delay: 5s;
  336. animation-iteration-count: 1;
  337. animation-fill-mode: backwards;
  338. }
  339. }
  340. @keyframes appear {
  341. from {
  342. display: none;
  343. }
  344. to {
  345. display: unset;
  346. }
  347. }
  348. /* RTL required for precedence over core's styles. */
  349. [dir="rtl"] .views-tabs__action-list-button {
  350. margin: 0;
  351. }
  352. .views-tabs__action-list-button.button:hover,
  353. .views-tabs__action-list-button.button:focus {
  354. color: var(--color-white);
  355. background-color: var(--color-absolutezero);
  356. }
  357. /* Remove outline provided by default styling */
  358. .views-tabs__action-list-button:not(:focus) {
  359. box-shadow: none;
  360. }
  361. /* @end */
  362. /* @group Attachment buckets
  363. *
  364. * These are the individual "buckets," or boxes, inside the display settings area
  365. */
  366. .views-ui-display-tab-bucket .links {
  367. padding: 2px 6px 4px;
  368. }
  369. .views-ui-display-tab-bucket .links li + li {
  370. margin-left: 3px; /* LTR */
  371. }
  372. [dir="rtl"] .views-ui-display-tab-bucket .links li + li {
  373. margin-right: 3px;
  374. margin-left: 0;
  375. }
  376. /* @end */
  377. /* @group Rearrange filter criteria */
  378. .views-ui-rearrange-filter-form tr {
  379. border-bottom: 0;
  380. }
  381. .views-ui-rearrange-filter-form tr:first-of-type {
  382. border-top: 0.0625rem solid var(--color-gray-200);
  383. }
  384. .views-ui-rearrange-filter-form tr:not(.draggable):hover {
  385. background: inherit;
  386. }
  387. .views-ui-rearrange-filter-form .action-links {
  388. float: left;
  389. margin: 0 0 1em;
  390. padding: 0;
  391. }
  392. .views-ui-rearrange-filter-form .tabledrag-toggle-weight-wrapper {
  393. float: right;
  394. }
  395. .views-ui-rearrange-filter-form .tabledrag-cell {
  396. position: relative;
  397. }
  398. .views-ui-rearrange-filter-form [id^="views-row"] {
  399. border: medium none;
  400. }
  401. .views-ui-rearrange-filter-form tr td:last-child {
  402. border-right: medium none; /* LTR */
  403. }
  404. [dir="rtl"] .views-ui-rearrange-filter-form tr td:last-child {
  405. border-right: initial;
  406. border-left: medium none;
  407. }
  408. .views-ui-rearrange-filter-form .filter-group-operator-row {
  409. border-right: 1px solid transparent !important;
  410. border-left: 1px solid transparent !important;
  411. }
  412. .views-ui-rearrange-filter-form tr.drag td {
  413. background-color: #fe7 !important;
  414. }
  415. .views-ui-rearrange-filter-form tr.drag-previous td {
  416. background-color: #ffb !important;
  417. }
  418. .views-ui-rearrange-filter-form .draggable td {
  419. vertical-align: middle;
  420. }
  421. /* @end */
  422. /* @group Live preview elements */
  423. .views-query-info pre {
  424. margin-top: 0;
  425. margin-bottom: 0;
  426. }
  427. /* @group Query info table */
  428. .views-query-info table {
  429. border-spacing: 1px;
  430. border-radius: 7px;
  431. }
  432. .views-query-info table tr td:last-child {
  433. /* Fixes a Claro style that bleeds down into this table unnecessarily */
  434. border-right: 0 none; /* LTR */
  435. }
  436. [dir="rtl"] .views-query-info table tr td:last-child {
  437. border-right: initial;
  438. border-left: 0 none;
  439. }
  440. /* @end */
  441. /* @end */
  442. /* @group Add view */
  443. .form-item-page-create,
  444. .form-item-block-create {
  445. margin-top: 13px;
  446. }
  447. /* @end */
  448. /* @group Modal dialog box
  449. *
  450. * The contents of the popup dialog on the views edit form.
  451. */
  452. .filterable-option .form-item.form-type-checkbox {
  453. padding-top: 4px;
  454. /* This selector is aggressive because Claro's reset for .form-items is aggressive. */
  455. padding-bottom: 4px;
  456. padding-left: 4px; /* LTR */
  457. }
  458. [dir="rtl"] .filterable-option .form-item.form-type-checkbox {
  459. padding-right: 4px;
  460. padding-left: 8px;
  461. }
  462. /* @end */
  463. /* @group Grouping styles
  464. *
  465. * For grouping related form elements together, mainly used with exposed
  466. * filters.
  467. */
  468. .views-config-group-region {
  469. display: table;
  470. margin: var(--space-l) 0;
  471. border: 0.0625rem solid var(--color-gray-200);
  472. border-collapse: collapse;
  473. }
  474. .views-config-group-region .views-group-box {
  475. position: relative;
  476. display: table-cell;
  477. padding: var(--space-l);
  478. border: 0.0625rem solid var(--color-gray-200);
  479. }
  480. .views-config-group-region .views-group-box--operator {
  481. padding-right: var(--space-xl);
  482. border-right-width: 0;
  483. }
  484. [dir="rtl"] .views-config-group-region .views-group-box--operator {
  485. padding-right: var(--space-l);
  486. padding-left: var(--space-xl);
  487. border-right-width: 0.0625rem;
  488. border-left-width: 0;
  489. }
  490. .views-config-group-region .views-group-box--value {
  491. padding: 0;
  492. border-left-width: 0; /* LTR */
  493. }
  494. [dir="rtl"] .views-config-group-region .views-group-box--value {
  495. border-right-width: 0;
  496. border-left-width: 0.0625rem;
  497. }
  498. .views-config-group-region .views-group-box--value > .form-item {
  499. margin-right: var(--space-l); /* LTR */
  500. margin-left: var(--space-xl); /* LTR */
  501. }
  502. [dir="rtl"] .views-config-group-region .views-group-box--value > .form-item {
  503. margin-right: var(--space-xl); /* LTR */
  504. margin-left: var(--space-l); /* LTR */
  505. }
  506. .views-config-group-region .views-group-box--value > .form-item::before {
  507. position: absolute;
  508. top: 0;
  509. left: 0;
  510. width: 0.0625rem;
  511. height: 100%;
  512. content: "";
  513. border-left: 0.0625rem solid var(--color-gray-200);
  514. }
  515. [dir="rtl"] .views-config-group-region .views-group-box--value > .form-item::before {
  516. right: 0;
  517. }
  518. .views-config-group-region .views-group-box--value > .form-item::after {
  519. position: absolute;
  520. z-index: 1;
  521. top: 3.8rem;
  522. left: calc(var(--space-m) * -1); /* LTR */
  523. padding: 0 0.3rem 0.3rem 0.4rem; /* LTR */
  524. content: ">";
  525. color: var(--color-gray-600);
  526. border: 0.0625rem solid var(--color-gray-200);
  527. background: #fff;
  528. font-size: var(--font-size-h1);
  529. font-weight: bold;
  530. line-height: var(--font-size-h1);
  531. }
  532. [dir="rtl"] .views-config-group-region .views-group-box--value > .form-item::after {
  533. right: calc(var(--space-m) * -1);
  534. left: auto;
  535. padding-right: 0.4rem;
  536. padding-left: 0.3rem;
  537. }

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.