Skip to content

Commit

Permalink
A11y fix
Browse files Browse the repository at this point in the history
  • Loading branch information
francescozaia committed Jun 12, 2018
1 parent 2e67cb2 commit b01ec53
Show file tree
Hide file tree
Showing 12 changed files with 114 additions and 142 deletions.
6 changes: 3 additions & 3 deletions _includes/cookiebar.html
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<div class="cookiebar bg-dark p-4 hide" aria-hidden="true">
<div class="container">
<div class="row d-flex align-items-center">
<div class="col-12 col-md-6">
<div class="col-12 col-md-7">
<span class="text-white small">Questo sito utilizza cookie tecnici, analytics e di terze parti.<br>Proseguendo nella navigazione accetti l’utilizzo dei cookie.</span>
</div>
<div class="col-12 col-md-6 mt-4 mt-md-0 d-flex justify-content-end">
<div class="col-12 col-md-5 mt-2 mt-md-0 text-right">
<a class="btn btn-link" href="https://designers.italia.it/privacy-policy/" >Privacy policy</a>
<button class="btn btn-primary mr-2" data-accept="cookiebar">Accetto</button>
<button class="btn btn-sm btn-primary mr-2" data-accept="cookiebar">Accetto</button>
</div>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion _includes/scripts.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<script src="{{ site.baseurl }}/dist/js/bootstrap-italia.bundle.min.js?{{ buildTime }}"></script>

<script src="https://cdnjs.cloudflare.com/ajax/libs/anchor-js/4.1.0/anchor.min.js" integrity="sha256-lZaRhKri35AyJSypXXs4o6OPFTbTmUoltBbDCbdzegg=" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/1.7.1/clipboard.min.js" integrity="sha256-Daf8GuI2eLKHJlOWLRR/zRy9Clqcj4TUSumbxYH9kGI=" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/2.0.1/clipboard.min.js" integrity="sha256-hIvIxeqhGZF+VVeM55k0mJvWpQ6gTkWk3Emc+NmowYA=" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/holder/2.9.4/holder.min.js" integrity="sha256-ifihHN6L/pNU1ZQikrAb7CnyMBvisKG3SUAab0F3kVU=" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/particles.js/2.0.0/particles.min.js" integrity="sha256-+u54FaX9J+k40eAcg5K2YzICSQjrEYBI9gju5nE3HfY=" crossorigin="anonymous"></script>

Expand Down
2 changes: 1 addition & 1 deletion docs/assets/src/js/docs.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
})

// ClipboardJS - Docs copy code handling
var clipboard = new Clipboard('.btn-clipboard', {
var clipboard = new ClipboardJS('.btn-clipboard', {
target: function (trigger) {
return trigger.parentNode.nextElementSibling
}
Expand Down
9 changes: 9 additions & 0 deletions docs/assets/src/scss/_colors.scss
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,12 @@
background-color: #{$value};
}
}

$docs-blue: rgb(0, 102, 204) !default; // #06C
$docs-blue-bright: lighten(saturate($docs-blue, 5%), 15%) !default;
$docs-blue-light: lighten(saturate($docs-blue, 5%), 45%) !default;
$docs-info: rgb(23, 50, 77) !default;
$docs-warning: rgb(255, 151, 0) !default;
$docs-danger: rgb(248, 62, 90) !default;
$docs-accessibility: rgb(0, 207, 134) !default;
$docs-dark: #3E5266 !default;
40 changes: 0 additions & 40 deletions docs/assets/src/scss/_component-examples.scss
Original file line number Diff line number Diff line change
Expand Up @@ -371,43 +371,3 @@ nav.pagination-wrapper {
border: 1px solid $border-color;
}
}

//
// Code snippets
//

.highlight {
padding: 1rem;
margin-top: 1rem;
margin-bottom: 1rem;
background-color: #f7f7f9;
-ms-overflow-style: -ms-autohiding-scrollbar;

@include media-breakpoint-up(sm) {
padding: 1.5rem;
}
}

.bd-content .highlight {
margin-right: (-$grid-gutter-width / 2);
margin-left: (-$grid-gutter-width / 2);

@include media-breakpoint-up(sm) {
margin-right: 0;
margin-left: 0;
}
}

.highlight {
pre {
padding: 0;
margin-top: 0;
margin-bottom: 0;
background-color: transparent;
border: 0;
}
pre code {
font-size: inherit;
color: $gray-900; // Effectively the base text color
}
}
2 changes: 1 addition & 1 deletion docs/assets/src/scss/_sidebar.scss
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
a {
display: block;
padding: .125rem 1.5rem;
color: #99979c;
color: #77757a;

&:hover {
color: $blue;
Expand Down
162 changes: 86 additions & 76 deletions docs/assets/src/scss/_syntax.scss
Original file line number Diff line number Diff line change
@@ -1,78 +1,88 @@
// stylelint-disable declaration-block-single-line-max-declarations

.hll { background-color: #ffc; }
.c { color: #999; }
.k { color: #069; }
.o { color: #555; }
.cm { color: #999; }
.cp { color: #099; }
.c1 { color: #999; }
.cs { color: #999; }
.gd { background-color: #fcc; border: 1px solid #c00; }
.ge { font-style: italic; }
.gr { color: #f00; }
.gh { color: #030; }
.gi { background-color: #cfc; border: 1px solid #0c0; }
.go { color: #aaa; }
.gp { color: #009; }
.gu { color: #030; }
.gt { color: #9c6; }
.kc { color: #069; }
.kd { color: #069; }
.kn { color: #069; }
.kp { color: #069; }
.kr { color: #069; }
.kt { color: #078; }
.m { color: #f60; }
.s { color: #d44950; }
.na { color: #4f9fcf; }
.nb { color: #366; }
.nc { color: #0a8; }
.no { color: #360; }
.nd { color: #99f; }
.ni { color: #999; }
.ne { color: #c00; }
.nf { color: #c0f; }
.nl { color: #99f; }
.nn { color: #0cf; }
.nt { color: #2f6f9f; }
.nv { color: #033; }
.ow { color: #000; }
.w { color: #bbb; }
.mf { color: #f60; }
.mh { color: #f60; }
.mi { color: #f60; }
.mo { color: #f60; }
.sb { color: #c30; }
.sc { color: #c30; }
.sd { font-style: italic; color: #c30; }
.s2 { color: #c30; }
.se { color: #c30; }
.sh { color: #c30; }
.si { color: #a00; }
.sx { color: #c30; }
.sr { color: #3aa; }
.s1 { color: #c30; }
.ss { color: #fc3; }
.bp { color: #366; }
.vc { color: #033; }
.vg { color: #033; }
.vi { color: #033; }
.il { color: #f60; }

.css .o,
.css .o + .nt,
.css .nt + .nt { color: #999; }

.language-bash::before,
.language-sh::before {
color: #009;
content: "$ ";
user-select: none;
.highlight {
padding: 1rem;
margin-top: 1rem;
margin-bottom: 1rem;
background-color: #404040;
@include media-breakpoint-up(sm) {
padding: 1.5rem;
}
pre {
margin-bottom: 0;
code {
color: #EEE;
}
}
}

.language-powershell::before {
color: #009;
content: "PM> ";
user-select: none;
}
// http://jwarby.github.io/jekyll-pygments-themes/languages/javascript.html
// Native theme
.highlight pre { background-color: #404040 }
.highlight .hll { background-color: #404040 }
.highlight .c { color: #999999; font-style: italic } /* Comment */
.highlight .err { color: #a61717; background-color: #e3d2d2 } /* Error */
.highlight .g { color: #d0d0d0 } /* Generic */
.highlight .k { color: #6ab825; font-weight: bold } /* Keyword */
.highlight .l { color: #d0d0d0 } /* Literal */
.highlight .n { color: #d0d0d0 } /* Name */
.highlight .o { color: #d0d0d0 } /* Operator */
.highlight .x { color: #d0d0d0 } /* Other */
.highlight .p { color: #d0d0d0 } /* Punctuation */
.highlight .cm { color: #999999; font-style: italic } /* Comment.Multiline */
.highlight .cp { color: #cd2828; font-weight: bold } /* Comment.Preproc */
.highlight .c1 { color: #999999; font-style: italic } /* Comment.Single */
.highlight .cs { color: #e50808; font-weight: bold; background-color: #520000 } /* Comment.Special */
.highlight .gd { color: #d22323 } /* Generic.Deleted */
.highlight .ge { color: #d0d0d0; font-style: italic } /* Generic.Emph */
.highlight .gr { color: #d22323 } /* Generic.Error */
.highlight .gh { color: #ffffff; font-weight: bold } /* Generic.Heading */
.highlight .gi { color: #589819 } /* Generic.Inserted */
.highlight .go { color: #cccccc } /* Generic.Output */
.highlight .gp { color: #aaaaaa } /* Generic.Prompt */
.highlight .gs { color: #d0d0d0; font-weight: bold } /* Generic.Strong */
.highlight .gu { color: #ffffff; text-decoration: underline } /* Generic.Subheading */
.highlight .gt { color: #d22323 } /* Generic.Traceback */
.highlight .kc { color: #6ab825; font-weight: bold } /* Keyword.Constant */
.highlight .kd { color: #6ab825; font-weight: bold } /* Keyword.Declaration */
.highlight .kn { color: #6ab825; font-weight: bold } /* Keyword.Namespace */
.highlight .kp { color: #6ab825 } /* Keyword.Pseudo */
.highlight .kr { color: #6ab825; font-weight: bold } /* Keyword.Reserved */
.highlight .kt { color: #6ab825; font-weight: bold } /* Keyword.Type */
.highlight .ld { color: #d0d0d0 } /* Literal.Date */
.highlight .m { color: #3677a9 } /* Literal.Number */
.highlight .s { color: #ed9d13 } /* Literal.String */
.highlight .na { color: #bbbbbb } /* Name.Attribute */
.highlight .nb { color: #24909d } /* Name.Builtin */
.highlight .nc { color: #447fcf; text-decoration: underline } /* Name.Class */
.highlight .no { color: #40ffff } /* Name.Constant */
.highlight .nd { color: #ffa500 } /* Name.Decorator */
.highlight .ni { color: #d0d0d0 } /* Name.Entity */
.highlight .ne { color: #bbbbbb } /* Name.Exception */
.highlight .nf { color: #447fcf } /* Name.Function */
.highlight .nl { color: #d0d0d0 } /* Name.Label */
.highlight .nn { color: #447fcf; text-decoration: underline } /* Name.Namespace */
.highlight .nx { color: #d0d0d0 } /* Name.Other */
.highlight .py { color: #d0d0d0 } /* Name.Property */
.highlight .nt { color: #6ab825; font-weight: bold } /* Name.Tag */
.highlight .nv { color: #40ffff } /* Name.Variable */
.highlight .ow { color: #6ab825; font-weight: bold } /* Operator.Word */
.highlight .w { color: #666666 } /* Text.Whitespace */
.highlight .mf { color: #3677a9 } /* Literal.Number.Float */
.highlight .mh { color: #3677a9 } /* Literal.Number.Hex */
.highlight .mi { color: #3677a9 } /* Literal.Number.Integer */
.highlight .mo { color: #3677a9 } /* Literal.Number.Oct */
.highlight .sb { color: #ed9d13 } /* Literal.String.Backtick */
.highlight .sc { color: #ed9d13 } /* Literal.String.Char */
.highlight .sd { color: #ed9d13 } /* Literal.String.Doc */
.highlight .s2 { color: #ed9d13 } /* Literal.String.Double */
.highlight .se { color: #ed9d13 } /* Literal.String.Escape */
.highlight .sh { color: #ed9d13 } /* Literal.String.Heredoc */
.highlight .si { color: #ed9d13 } /* Literal.String.Interpol */
.highlight .sx { color: #ffa500 } /* Literal.String.Other */
.highlight .sr { color: #ed9d13 } /* Literal.String.Regex */
.highlight .s1 { color: #ed9d13 } /* Literal.String.Single */
.highlight .ss { color: #ed9d13 } /* Literal.String.Symbol */
.highlight .bp { color: #24909d } /* Name.Builtin.Pseudo */
.highlight .vc { color: #40ffff } /* Name.Variable.Class */
.highlight .vg { color: #40ffff } /* Name.Variable.Global */
.highlight .vi { color: #40ffff } /* Name.Variable.Instance */
.highlight .il { color: #3677a9 } /* Literal.Number.Integer.Long */
9 changes: 0 additions & 9 deletions docs/assets/src/scss/_variables.scss

This file was deleted.

3 changes: 1 addition & 2 deletions docs/assets/src/scss/docs.scss
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
@import "node_modules/bootstrap/scss/mixins";

// Load docs components
@import "variables";
@import "colors";
@import "nav";
@import "masthead";
@import "content";
Expand All @@ -49,7 +49,6 @@
@import "callouts";
@import "examples";
@import "index";
@import "colors";
@import "clipboard-js";
@import "brandhead";
@import "custom-color";
Expand Down
8 changes: 4 additions & 4 deletions docs/come-iniziare/introduzione.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,15 +56,15 @@ All'interno della cartella `js` saranno invece presenti due file, che si differe
<th scope="row">
<div><code class="font-weight-normal text-nowrap">bootstrap-italia.bundle.min.js</code></div>
</th>
<td class="text-success">Incluso</td>
<td class="text-success">Incluso</td>
<td class="bg-success">Incluso</td>
<td class="bg-success">Incluso</td>
</tr>
<tr>
<th scope="row">
<div><code class="font-weight-normal text-nowrap">bootstrap-italia.min.js</code></div>
</th>
<td class="bg-light text-muted">Non Incluso</td>
<td class="bg-light text-muted">Non Incluso</td>
<td>Non Incluso</td>
<td>Non Incluso</td>
</tr>
</tbody>
</table>
Expand Down
10 changes: 5 additions & 5 deletions docs/come-iniziare/strumenti-di-compilazione.md
Original file line number Diff line number Diff line change
Expand Up @@ -126,19 +126,19 @@ La struttura delle cartelle della documentazione è la seguente:

Per aggiornare il numero di versione e creare una nuova release, è necessario effettuare i due seguenti step manuali:

```sh
{% highlight sh %}
$ npm run bump-patch
```
{% endhighlight %}

o `bump-minor` oppure `bump-major`, che produrrà:

* Aggiornamento numero di versione in formato [semver](https://semver.org/) su file `package.json`, `package.lock` e `_config.yml`
* Commit delle modifiche
* Tag del commit con numero di versione in formato `vx.x.x`

```sh
{% highlight sh %}
$ git push --follow-tags
```
{% endhighlight %}

che produrrà il push della commit contenente l'avanzamento della versione ed il push della tag.

Expand Down Expand Up @@ -178,7 +178,7 @@ Aggiunta di una [GitHub release](https://help.github.com/articles/about-releases

---

###### Continua la lettura >
##### Continua la lettura >

Se ti interessa sapere come modificare o aggiungere nuovi componenti alla libreria Bootstrap Italia,
continua a leggere alla [pagina che spiega come farlo]({{ site.baseurl }}/docs/come-iniziare/modificare-componenti/).
Expand Down
3 changes: 3 additions & 0 deletions src/scss/custom/_buttons.scss
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@
}

.bg-dark {
.btn-link {
color: $white;
}
.btn-primary {
@include button-variant($white, $primary, lighten($white, 7.5%), darken($primary, 10%), lighten($white, 10%), darken($primary, 12.5%));
color: $primary;
Expand Down

0 comments on commit b01ec53

Please sign in to comment.