Skip to content

Commit 927d007

Browse files
authored
Merge branch 'main' into feat/new-cards
2 parents 1315cf7 + 7c6acc0 commit 927d007

File tree

5 files changed

+75
-3
lines changed

5 files changed

+75
-3
lines changed
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
name: publiccode.yml validation
2+
3+
on: [pull_request, push]
4+
5+
jobs:
6+
publiccode_yml_validation:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v4
10+
- uses: italia/publiccode-parser-action@v1
11+
with:
12+
publiccode: 'publiccode.yml'

README.EN.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,26 @@ The `design-react-kit` module does not include the CSS and font files in the bun
8282
yarn add bootstrap-italia typeface-lora typeface-roboto-mono typeface-titillium-web --save
8383
```
8484

85+
#### Note for `vite` users
86+
87+
If you are using `vite` as a bundler and want to customize the standard appearance of Bootstrap Italia, you need to
88+
add an alias in the `vite.config.js` file:
89+
90+
```js
91+
import { defineConfig } from 'vite';
92+
import react from '@vitejs/plugin-react';
93+
94+
export default defineConfig({
95+
plugins: [react()],
96+
resolve: {
97+
alias: {
98+
"@splidejs/splide/src/css/core/index":
99+
"node_modules/@splidejs/splide/src/css/core/index.scss",
100+
}
101+
}
102+
});
103+
```
104+
85105
### Example
86106

87107
Then, you just need to import CSS e font editing `./src/App.js` as shown:

README.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,26 @@ export default App;
106106
Puoi consultare questo template web con StackBlitz:
107107
[Template web](https://stackblitz.com/edit/vitejs-vite-yy8bnk?file=src%2FApp.tsx)
108108

109+
#### Nota per chi utilizza `vite`
110+
111+
Se si utilizza `vite` come bundler e si vuole personalizzare l'aspetto standard di Bootstrap Italia, è necessario
112+
aggiungere un alias nel file `vite.config.js`:
113+
114+
```js
115+
import { defineConfig } from 'vite';
116+
import react from '@vitejs/plugin-react';
117+
118+
export default defineConfig({
119+
plugins: [react()],
120+
resolve: {
121+
alias: {
122+
"@splidejs/splide/src/css/core/index":
123+
"node_modules/@splidejs/splide/src/css/core/index.scss",
124+
}
125+
}
126+
});
127+
```
128+
109129
### Caricamento Font
110130

111131
Il tema Bootstrap Italia utilizza un set specifico di font typeface: `titillium-web`, `roboto-mono` e `lora`. Il caricamento di questi font è lasciato al browser ma, volendo può essere controllato tramite l'apposito componente `FontLoader`.

stories/faq.mdx

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,26 @@ Si. Ti invitiamo ad aprire un ticket [sul repository Github](https://github.com/
2525

2626
Una guida completa su come personalizzare lo stile è possibile reperirla sul sito Bootstrap Italia nell'apposita pagina: [Personalizzazione della libreria](https://italia.github.io/bootstrap-italia/docs/come-iniziare/personalizzazione-della-libreria/). Poichè il kit ha una dipendenza unicamente sul css di Bootstrap Italia, è possibile importare il nuovo stile personalizzato come mostrato nell'esempio finale nella pagina.
2727

28+
#### Nota per chi utilizza `vite`
29+
30+
Se si utilizza `vite` come bundler e si vuole personalizzare l'aspetto standard di Bootstrap Italia, è necessario
31+
aggiungere un alias nel file `vite.config.js`:
32+
33+
```js
34+
import { defineConfig } from 'vite';
35+
import react from '@vitejs/plugin-react';
36+
37+
export default defineConfig({
38+
plugins: [react()],
39+
resolve: {
40+
alias: {
41+
"@splidejs/splide/src/css/core/index":
42+
"node_modules/@splidejs/splide/src/css/core/index.scss",
43+
}
44+
}
45+
});
46+
```
47+
2848
### I tipi Typescript del componente X non sono corretti. È un bug?
2949

3050
Si. Ti invitiamo ad aprire un ticket [sul repository Github](https://github.com/italia/design-react-kit/issues).

yarn.lock

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8545,9 +8545,9 @@ [email protected]:
85458545
global "^4.3.1"
85468546

85478547
vite@^5.2.7:
8548-
version "5.4.19"
8549-
resolved "https://registry.yarnpkg.com/vite/-/vite-5.4.19.tgz#20efd060410044b3ed555049418a5e7d1998f959"
8550-
integrity sha512-qO3aKv3HoQC8QKiNSTuUM1l9o/XX3+c+VTgLHbJWHZGeTPVAg2XwazI9UWzoxjIJCGCV2zU60uqMzjeLZuULqA==
8548+
version "5.4.20"
8549+
resolved "https://registry.yarnpkg.com/vite/-/vite-5.4.20.tgz#3267a5e03f21212f44edfd72758138e8fcecd76a"
8550+
integrity sha512-j3lYzGC3P+B5Yfy/pfKNgVEg4+UtcIJcVRt2cDjIOmhLourAqPqf8P7acgxeiSgUB7E3p2P8/3gNIgDLpwzs4g==
85518551
dependencies:
85528552
esbuild "^0.21.3"
85538553
postcss "^8.4.43"

0 commit comments

Comments
 (0)