github.com/cosmos/cosmos-sdk@v0.50.10/docs/src/css/custom.css (about)

     1  /*
     2    Slighlty modified version of https://github.com/ignite/cli/blob/develop/docs/src/css/custom.css
     3  */
     4  
     5  @import "tailwindcss/base";
     6  @import "./fonts.css";
     7  @import "./base.css";
     8  @import "tailwindcss/components";
     9  @import "tailwindcss/utilities";
    10  
    11  /* You can override the default Infima variables here. */
    12  :root {
    13    --ifm-color-primary: #5064fb;
    14    --ifm-color-primary-dark: theme(colors.gray.1000);
    15    --ifm-color-primary-darker: theme(colors.gray.1000);
    16    --ifm-color-primary-darkest: theme(colors.gray.1000);
    17    --ifm-color-primary-light: theme(colors.gray.1000);
    18    --ifm-color-primary-lighter: theme(colors.gray.1000);
    19    --ifm-color-primary-lightest: theme(colors.gray.1000);
    20    --ifm-code-font-size: 95%;
    21    --ifm-breadcrumb-item-background-active: transparent;
    22    --ifm-breadcrumb-padding-horizontal: 0;
    23    --ifm-list-paragraph-margin: 0;
    24    --ifm-spacing-horizontal: theme(spacing.7);
    25    --ifm-blockquote-border-color: theme(colors.gray.1000);
    26    --ifm-menu-link-padding-vertical: 0.6rem;
    27    --ifm-background-color: theme(colors.gray.0);
    28    --ifm-footer-link-color: var(--ifm-font-color-base);
    29    --ifm-menu-link-sublist-icon: url("~/img/ico-chevron.svg");
    30    --docsearch-searchbox-background: #f7f7f7;
    31    --docsearch-modal-background: theme(colors.card) !important;
    32    --ifm-navbar-height: 5.563rem;
    33    --ifm-navbar-sidebar-width: 100vw;
    34    --docsearch-highlight-color: theme(colors.fg) !important;
    35    --docsearch-searchbox-shadow: inset 0 0 0 1px var(--docsearch-primary-color);
    36  
    37    /* temp: local search bar */
    38    --aa-primary-color-rgb: 0, 0, 0;
    39  
    40    @media screen and (prefers-reduced-motion) {
    41      transition: ;
    42    }
    43    --ifm-menu-color-background-active: none;
    44    --ifm-menu-color-background-hover: none;
    45    --docusaurus-highlighted-code-line-bg: rgba(0, 0, 0, 0.1);
    46  }
    47  
    48  /* For readability concerns, you should choose a lighter palette in dark mode. */
    49  html[data-theme="dark"] {
    50    --ifm-color-primary: theme(colors.gray.0);
    51    --ifm-color-primary-dark: #e6e6e6;
    52    --ifm-color-primary-darker: #d9d9d9;
    53    --ifm-color-primary-darkest: #b3b3b3;
    54    --ifm-color-primary-light: theme(colors.gray.0);
    55    --ifm-color-primary-lighter: theme(colors.gray.0);
    56    --ifm-color-primary-lightest: theme(colors.gray.0);
    57    --ifm-background-color: theme(colors.gray.1000);
    58    --docusaurus-highlighted-code-line-bg: theme(colors.inactive);
    59    --docsearch-modal-background: theme(colors.gray.1000) !important;
    60    --docsearch-highlight-color: theme(colors.inactiveLight) !important;
    61    --docsearch-hit-background: theme(colors.lightfg) !important;
    62    --docsearch-searchbox-shadow: inset 0 0 0 1px var(--docsearch-primary-color);
    63    --docsearch-key-gradient: linear-gradient(
    64      -26.5deg,
    65      #5d5d5d,
    66      #3c3c3c
    67    ) !important;
    68    --docsearch-key-shadow: inset 0 -2px 0 0 #353535, inset 0 0 1px 1px #7a7a7b,
    69      0 2px 2px 0 rgba(45, 45, 45, 0.3) !important;
    70  }
    71  
    72  html {
    73    @apply bg-docusaurusBgColor;
    74    /* Banner */
    75  
    76    #__docusaurus > div[role="banner"] {
    77      @apply bg-gray-30 text-gray-1000 font-normal;
    78      a {
    79        @apply no-underline w-full text-2;
    80      }
    81    }
    82  
    83    /* MAINNAV */
    84    .navbar {
    85      @apply py-2 h-auto border-b border-b-docusaurusColorBorder shadow-none bg-docusaurusBgColor;
    86      &__toggle {
    87        @apply bg-card rounded-s h-8 w-8 flex justify-center items-center;
    88        @media (min-width: 997px) {
    89          @apply hidden;
    90        }
    91      }
    92      &__brand {
    93        & + * {
    94          @apply ml-auto;
    95        }
    96      }
    97      &__link--active {
    98        @apply text-muted;
    99      }
   100      &__items:not(:last-child) {
   101        @apply justify-between;
   102        @media (min-width: 997px) {
   103          @apply justify-start px-3;
   104        }
   105        button {
   106          @apply order-2 mr-0;
   107        }
   108      }
   109      &__items--right > :last-child {
   110        @apply right-8.5;
   111      }
   112    }
   113    &[data-theme="dark"] .navbar__item {
   114      @apply text-mutedLight;
   115    }
   116    &[data-theme="dark"] .navbar__toggle {
   117      @apply bg-fg;
   118    }
   119  
   120    .github-icon {
   121      @apply hover:opacity-50;
   122    }
   123  
   124    /* SEARCHBAR */
   125    /* algolia */
   126    .DocSearch {
   127      &-Hits mark {
   128        @apply text-docusaurusColorBase;
   129      }
   130      &-Button {
   131        @apply text-inactive rounded-sm h-8 w-8 bg-card justify-center mr-3;
   132        @media (min-width: 997px) {
   133          @apply w-auto justify-between;
   134        }
   135        .DocSearch-Search-Icon {
   136          @apply text-docusaurusColorBase;
   137        }
   138        .DocSearch-Button-Keys {
   139          @apply hidden;
   140        }
   141        .DocSearch-Button-Placeholder {
   142          @apply pr-10;
   143        }
   144      }
   145  
   146      &-Logo path {
   147        @apply fill-docusaurusColorBase;
   148      }
   149    }
   150  
   151    .navbar-sidebar {
   152      @apply w-full;
   153      &__brand {
   154        @apply px-6 h-auto;
   155      }
   156      &__item {
   157        @apply px-6 w-full;
   158      }
   159      &__back {
   160        @apply px-0 hidden;
   161      }
   162      &__close {
   163        @apply bg-gray-1000 rounded-s h-8 w-8 flex justify-center items-center ml-0;
   164        & > svg > g {
   165          @apply stroke-gray-0;
   166        }
   167      }
   168    }
   169    &[data-theme="dark"] .navbar-sidebar {
   170      @apply bg-gray-1000;
   171      &__brand {
   172        @apply shadow-none relative;
   173        &::after {
   174          content: "";
   175          @apply absolute block h-px  bg-linkHover bottom-0 right-3 left-0 mx-6;
   176        }
   177      }
   178      &__close {
   179        @apply bg-gray-0;
   180        & > svg > g {
   181          @apply stroke-gray-1000;
   182        }
   183      }
   184    }
   185    &[data-theme="dark"] .DocSearch-Modal {
   186      @apply bg-gray-1000;
   187    }
   188    &[data-theme="dark"] .DocSearch-Footer {
   189      @apply bg-gray-1000;
   190    }
   191    &[data-theme="dark"] .DocSearch-Button {
   192      @apply bg-fg text-inactiveLight;
   193    }
   194    &[data-theme="dark"] .DocSearch-Button-Key {
   195      @apply text-inactiveLight border-inactiveLight;
   196    }
   197  
   198    /* BREADCRUMBS */
   199    .breadcrumbs__item {
   200      &:first-child {
   201        & > a {
   202          &::after {
   203            content: "Docs";
   204          }
   205          & > svg {
   206            @apply hidden;
   207          }
   208        }
   209      }
   210      &:not(:last-child)::after {
   211        content: ">";
   212        @apply bg-none;
   213      }
   214    }
   215    .theme-doc-breadcrumbs {
   216      @media (min-width: 997px) {
   217        @apply pt-[calc(theme(spacing.7)-1rem)];
   218      }
   219    }
   220    .theme-doc-toc-mobile {
   221      @apply bg-card px-6 py-5.5 pb-0 rounded;
   222      & > button {
   223        @apply p-0 pb-5.5 flex justify-between;
   224        &::after {
   225          @apply order-last ml-5;
   226          background-image: var(--ifm-menu-link-sublist-icon);
   227          background-size: 70%;
   228        }
   229      }
   230      & ul li {
   231        @apply my-5 mx-0;
   232      }
   233    }
   234    &[data-theme="dark"] .theme-doc-toc-mobile {
   235      @apply bg-fg;
   236    }
   237  
   238    /* SIDEBAR */
   239    .theme-doc-sidebar-container {
   240      @media (min-width: 997px) {
   241        @apply ml-4 border-r border-r-docusaurusColorBorder;
   242      }
   243      & > div:first-child > a {
   244        @apply m-0;
   245      }
   246    }
   247  
   248    &[data-theme="dark"] .theme-doc-sidebar-menu .menu__list::before {
   249      @apply bg-inactiveLight;
   250    }
   251    .theme-doc-sidebar-menu {
   252      @apply font-normal;
   253  
   254      .menu__list {
   255        @apply relative pl-0;
   256        &::before {
   257          content: "";
   258          @apply absolute block left-3 top-0 h-full w-[2px] bg-border;
   259        }
   260        ul::before {
   261          @apply hidden;
   262        }
   263      }
   264  
   265      .menu__link {
   266        @apply pl-0 pr-5;
   267        &--active:not(.menu__link--sublist) {
   268          @apply text-docusaurusColorBase font-medium;
   269        }
   270      }
   271  
   272      li li {
   273        @apply pl-7;
   274        .menu__link--active:not(.menu__link--sublist) {
   275          @apply relative text-docusaurusColorBase font-medium;
   276          &::before {
   277            content: "";
   278            @apply absolute block left-0 top-0 h-full w-[2px] bg-docusaurusColorBase;
   279            @apply -left-[calc(theme(space.7)-theme(space.3))];
   280          }
   281        }
   282      }
   283      li li li {
   284        @apply pl-5;
   285      }
   286      li li li .menu__link--active:not(.menu__link--sublist)::before {
   287        @apply -left-[calc(theme(space.5)*1+theme(space.7)-theme(space.3))];
   288      }
   289      li li li li .menu__link--active:not(.menu__link--sublist)::before {
   290        @apply -left-[calc(theme(space.5)*2+theme(space.7)-theme(space.3))];
   291      }
   292      li li li li li .menu__link--active:not(.menu__link--sublist)::before {
   293        @apply -left-[calc(theme(space.5)*3+theme(space.7)-theme(space.3))];
   294      }
   295      li li li li li li .menu__link--active:not(.menu__link--sublist)::before {
   296        @apply -left-[calc(theme(space.5)*4+theme(space.7)-theme(space.3))];
   297      }
   298      li li li li li li li .menu__link--active:not(.menu__link--sublist)::before {
   299        @apply -left-[calc(theme(space.5)*5+theme(space.7)-theme(space.3))];
   300      }
   301    }
   302  
   303    &[data-theme="dark"] .menu__link {
   304      @apply text-mutedLight;
   305    }
   306    .theme-doc-sidebar-item-link .menu__link[target="_blank"] {
   307      &::after {
   308        content: "\2197";
   309        @apply ml-1;
   310      }
   311    }
   312    .menu__link {
   313      @apply text-muted;
   314      &:hover {
   315        text-shadow: 0.1px 0.1px 0 var(--ifm-font-color-base),
   316          -0.1px -0.1px 0 var(--ifm-font-color-base),
   317          0.1px -0.1px 0 var(--ifm-font-color-base),
   318          -0.1px 0.1px 0 var(--ifm-font-color-base),
   319          -0.1px 0 0 var(--ifm-font-color-base),
   320          0.1px 0 0 var(--ifm-font-color-base),
   321          0 0.1px 0 var(--ifm-font-color-base),
   322          0 -0.1px 0 var(--ifm-font-color-base);
   323        @apply text-docusaurusColorBase;
   324      }
   325  
   326      & > svg {
   327        @apply hidden;
   328      }
   329    }
   330  
   331    .menu__link--sublist-caret {
   332      @apply flex;
   333      &::after {
   334        background-size: 16px;
   335        background-repeat: no-repeat;
   336        @apply order-first ml-0 mr-4;
   337      }
   338    }
   339    .menu__list-item--collapsed .menu__link--sublist:after,
   340    .menu__list-item--collapsed .menu__caret:before {
   341      transform: rotateZ(0);
   342    }
   343    .menu__caret,
   344    li li .menu__link--sublist-caret::after {
   345      @apply hidden;
   346    }
   347  
   348    /* TOC */
   349    .table-of-contents__link:hover,
   350    .table-of-contents__link--active {
   351      text-shadow: 0.1px 0.1px 0 var(--ifm-font-color-base),
   352        -0.1px -0.1px 0 var(--ifm-font-color-base),
   353        0.1px -0.1px 0 var(--ifm-font-color-base),
   354        -0.1px 0.1px 0 var(--ifm-font-color-base),
   355        -0.1px 0 0 var(--ifm-font-color-base),
   356        0.1px 0 0 var(--ifm-font-color-base), 0 0.1px 0 var(--ifm-font-color-base),
   357        0 -0.1px 0 var(--ifm-font-color-base);
   358    }
   359  
   360    /* RELATED ARTICLES */
   361    &[data-theme="dark"] .pagination-nav > a {
   362      @apply bg-fg;
   363    }
   364    .pagination-nav {
   365      @apply pb-7 mt-9;
   366      & > a {
   367        box-shadow: 0px 0px 80px rgba(0, 0, 0, 0.07);
   368        @apply border-transparent rounded pb-8.5 col-span-2 pt-6 px-6 hover:shadow-none;
   369  
   370        @media (min-width: 997px) {
   371          @apply col-span-1;
   372        }
   373      }
   374  
   375      .pagination-nav {
   376        &__link--next {
   377          @apply text-left;
   378          @media (min-width: 997px) {
   379            @apply text-right;
   380          }
   381        }
   382        &__sublabel {
   383          @apply mb-3.5 text-gray-1000 dark:text-docusaurusColorBase text-3;
   384        }
   385        &__label {
   386          @apply text-4 font-semibold;
   387        }
   388      }
   389    }
   390  
   391    /* FOOTER */
   392    .footer {
   393      background-color: var(--ifm-background-color);
   394      @apply border-t border-t-docusaurusColorBorder pt-10 mb-10;
   395      &__link-item {
   396        @apply hover:underline;
   397      }
   398      &__bottom {
   399        margin: 0 calc(var(--ifm-spacing-horizontal) * -1);
   400      }
   401      &__copyright {
   402        @apply text-center mt-9 text-2;
   403      }
   404    }
   405    .footer__col:not(:first-child) {
   406      @apply basis-1/2;
   407      @media (min-width: 997px) {
   408        @apply basis-0;
   409      }
   410    }
   411    .footer__col:first-child .footer__title {
   412      @apply hidden;
   413    }
   414    .footer__link-item {
   415      & > svg {
   416        @apply hidden;
   417      }
   418    }
   419  
   420    .theme-back-to-top-button {
   421      @apply rotate-180;
   422      &::after {
   423        @apply w-1/2;
   424      }
   425    }
   426  
   427    /* MARKDOWN */
   428    .theme-code-block {
   429      @apply font-jetbrain mt-3;
   430    }
   431  
   432    .markdown {
   433      --ifm-heading-vertical-rhythm-bottom: 1;
   434      --ifm-h1-vertical-rhythm-bottom: 1;
   435    }
   436    .theme-doc-markdown {
   437      @apply mt-7 pb-8 border-b border-b-border;
   438  
   439      h1 {
   440        @apply text-7 font-bold leading-10 tracking-tight;
   441      }
   442      h2 {
   443        @apply text-6 font-bold leading-9 tracking-tight;
   444      }
   445      h3 {
   446        @apply text-4 font-semibold leading-8 tracking-tight;
   447      }
   448      h4 {
   449        @apply text-3 font-semibold leading-7 tracking-tight;
   450      }
   451      h5 {
   452        @apply text-3 font-semibold leading-6 tracking-wide;
   453      }
   454      p {
   455        @apply leading-relaxed;
   456      }
   457      p,
   458      ul,
   459      ol,
   460      blockquote {
   461        @apply text-[1rem];
   462      }
   463      code {
   464        @apply border-0 px-3;
   465      }
   466      blockquote {
   467        @apply my-7;
   468      }
   469      a {
   470        @apply no-underline hover:underline;
   471        color: var(--ifm-color-primary);
   472      }
   473      ol,
   474      ul {
   475        @apply my-6;
   476      }
   477      ul li {
   478        @apply relative pl-6 mb-4 before:absolute before:block before:w-[4px] before:h-[4px] before:bg-current before:left-0 before:top-[calc(1em/2)];
   479      }
   480      ul li li {
   481        @apply last:mb-6 before:border before:border-current before:bg-transparent;
   482      }
   483      li:last-child li {
   484        @apply last:mb-0;
   485      }
   486      ol {
   487        list-style-type: none;
   488        counter-reset: item;
   489        & > li {
   490          @apply relative pl-8 mb-5.5;
   491          &::before {
   492            counter-increment: item;
   493            content: counters(item, ".", decimal-leading-zero) ".";
   494            @apply absolute flex left-0 top-[.2rem] text-3 font-semibold tracking-tight;
   495          }
   496        }
   497      }
   498      ol ol {
   499        counter-reset: subitem;
   500        & > li {
   501          &::before {
   502            counter-increment: subitem;
   503            content: counters(subitem, ".", decimal-leading-zero) ".";
   504          }
   505        }
   506      }
   507      li {
   508        & > ul,
   509        & > ol {
   510          @apply my-5;
   511        }
   512      }
   513    }
   514  }