qc-trousse-sdg 1.2.5 → 1.3.0-develop.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +18 -23
- package/dist/css/qc-sdg-design-tokens.min.css +1 -1
- package/dist/css/qc-sdg-no-grid.min.css +1 -1
- package/dist/css/qc-sdg.min.css +1 -1
- package/dist/img/QUEBEC_couleur.svg +24 -0
- package/dist/js/qc-sdg.min.js +1 -1
- package/package.json +23 -18
- package/public/css/qc-doc-sdg.css +247 -335
- package/public/css/qc-sdg-design-tokens.css +111 -64
- package/public/css/qc-sdg-no-grid.css +957 -453
- package/public/css/qc-sdg.css +966 -634
- package/public/img/QUEBEC_couleur.svg +24 -0
- package/public/img/ampoule.svg +1 -0
- package/public/img/arrow-up-white.svg +3 -0
- package/public/img/chevron-blue.svg +3 -0
- package/public/img/chevron-white.svg +3 -0
- package/public/img/clipboard.svg +8 -0
- package/public/img/error-white.svg +1 -0
- package/public/img/error.svg +1 -0
- package/public/img/exclamation-white.svg +37 -0
- package/public/img/external-link-white.svg +18 -0
- package/public/img/facebook.svg +6 -0
- package/public/img/information-white.svg +1 -0
- package/public/img/information.svg +1 -0
- package/public/img/linkedin.svg +5 -0
- package/public/img/loupe-piv-droite.svg +1 -0
- package/public/img/loupe-piv-fonce.svg +1 -0
- package/public/img/minus.svg +6 -0
- package/public/img/note.svg +1 -0
- package/public/img/piv-MCE-theme-clair.svg +79 -0
- package/public/img/piv-MCE-theme-sombre.svg +62 -0
- package/public/img/piv-bas-MCE-theme-clair.png +0 -0
- package/public/img/piv-bas-MCE-theme-sombre.png +0 -0
- package/public/img/piv-logo-pied-de-page.svg +37 -0
- package/public/img/plus.svg +6 -0
- package/public/img/question-mark.svg +47 -0
- package/public/img/success-white.svg +1 -0
- package/public/img/success.svg +1 -0
- package/public/img/twitter.svg +8 -0
- package/public/img/warning.svg +1 -0
- package/public/img/xclose-blue.svg +6 -0
- package/public/img/xclose-white.svg +1 -0
- package/public/img/youtube.svg +3 -0
- package/public/index.html +871 -715
- package/public/js/qc-doc-exemple.js +9 -0
- package/public/js/qc-doc-sdg.js +6893 -3724
- package/public/js/qc-sdg.js +2103 -962
- package/rollup.config.js +58 -32
- package/src/doc/components/Code.svelte +69 -0
- package/src/doc/components/Exemple.svelte +71 -0
- package/src/doc/components/Switch.svelte +108 -0
- package/src/doc/components/TopNav.svelte +53 -0
- package/src/doc/components/color-doc.svelte +44 -0
- package/src/doc/qc-doc-sdg.js +25 -14
- package/src/doc/scss/_tables.scss +1 -2
- package/src/doc/scss/components/_button.scss +14 -14
- package/src/doc/scss/components/_code.scss +106 -4
- package/src/doc/scss/jQueryUI/_jquery-ui.autocomplete.scss +48 -0
- package/src/doc/scss/qc-doc-sdg.scss +76 -75
- package/src/sdg/components/Button/IconButton.svelte +29 -0
- package/src/sdg/components/Icon.svelte +39 -0
- package/src/sdg/components/{pivHeader.svelte → PivHeader/pivHeader.svelte} +49 -69
- package/src/sdg/components/SearchBar/searchBar.svelte +87 -0
- package/src/sdg/components/SearchInput/SearchInput.svelte +48 -0
- package/src/sdg/components/alert.svelte +40 -23
- package/src/sdg/components/componentWrapper.js +0 -3
- package/src/sdg/components/externalLink.svelte +92 -0
- package/src/sdg/components/notice.svelte +61 -34
- package/src/sdg/components/pivFooter.svelte +37 -36
- package/src/sdg/components/toTop.svelte +17 -11
- package/src/sdg/components/utils.js +28 -4
- package/src/sdg/qc-sdg.js +11 -3
- package/src/sdg/scss/_qc-sdg-lib.scss +3 -0
- package/src/sdg/scss/base/_accessibility.scss +4 -0
- package/src/sdg/scss/base/_colors.scss +10 -10
- package/src/sdg/scss/base/_figure.scss +14 -9
- package/src/sdg/scss/base/_fonts.scss +4 -4
- package/src/sdg/scss/base/_form.scss +7 -0
- package/src/sdg/scss/base/_layout.scss +45 -0
- package/src/sdg/scss/base/_lists.scss +5 -5
- package/src/sdg/scss/base/_shadings.scss +3 -11
- package/src/sdg/scss/base/_typography.scss +42 -25
- package/src/sdg/scss/components/_alert.scss +11 -34
- package/src/sdg/scss/components/_icons.scss +80 -57
- package/src/sdg/scss/components/_notice.scss +51 -44
- package/src/sdg/scss/components/_pivFooter.scss +35 -23
- package/src/sdg/scss/components/_pivHeader.scss +131 -154
- package/src/sdg/scss/components/_searchBar.scss +75 -0
- package/src/sdg/scss/components/_searchInput.scss +64 -0
- package/src/sdg/scss/components/_separator.scss +2 -5
- package/src/sdg/scss/components/_toTop.scss +4 -6
- package/src/sdg/scss/grid/_grid-lib.scss +516 -0
- package/src/sdg/scss/grid/_grid.scss +78 -0
- package/src/sdg/scss/lib/_functions.scss +78 -0
- package/src/sdg/scss/lib/_gridless-lib.scss +4 -0
- package/src/sdg/scss/lib/_mixins.scss +221 -0
- package/src/sdg/scss/qc-design-tokens.scss +31 -8
- package/src/sdg/scss/qc-sdg-utilities.scss +1 -0
- package/src/sdg/scss/qc-sdg.scss +1 -1
- package/src/sdg/scss/qc-sgd-no-grid.scss +20 -15
- package/src/sdg/scss/settings/_base.scss +58 -0
- package/src/sdg/scss/settings/_tokens.scss +145 -77
- package/src/sdg/scss/utilities/_display.scss +43 -3
- package/src/sdg/scss/utilities/_themes.scss +17 -0
- package/src/sdg/scss/vendor/modern-css-reset/src/reset.css +9 -8
- package/src/doc/components/code.svelte +0 -54
- package/src/sdg/scss/base/_grid.scss +0 -9
- package/src/sdg/scss/functions/_tokens.scss +0 -12
- package/src/sdg/scss/functions/_utils.scss +0 -44
- package/src/sdg/scss/modules/_grid.scss +0 -19
- package/src/sdg/scss/modules/_map.scss +0 -14
- package/src/sdg/scss/modules/_tokens.scss +0 -3
- package/src/sdg/scss/modules/_utils.scss +0 -55
- package/src/sdg/scss/settings/_grid.scss +0 -24
- package/src/sdg/scss/settings/_settings.scss +0 -12
- package/src/sdg/sprites/dist/view/svg/sprite.view.svg +0 -1
- package/src/sdg/sprites/gulpfile.js +0 -41
- package/src/sdg/sprites/package-lock.json +0 -5949
- package/src/sdg/sprites/package.json +0 -16
- package/src/sdg/sprites/svg/QUEBEC_blanc.svg +0 -13
- package/src/sdg/sprites/svg/external-link.svg +0 -10
- package/src/sdg/sprites/svg/logo-quebec-piv-footer.svg +0 -1
- /package/dist/img/{quebec-logo.svg → QUEBEC_blanc.svg} +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/arrow-up-white.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/chevron-blue.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/chevron-white.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/clipboard.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/error-white.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/error.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/exclamation-white.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/external-link-white.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/facebook.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/information-white.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/information.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/linkedin.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/loupe-piv-droite.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/loupe-piv-fonce.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/minus.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/plus.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/question-mark.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/success-white.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/success.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/twitter.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/warning.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/xclose-blue.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/xclose-white.svg +0 -0
- /package/{src/sdg/sprites/svg → dist/img}/youtube.svg +0 -0
- /package/{src/sdg/sprites/svg/quebec-logo.svg → public/img/QUEBEC_blanc.svg} +0 -0
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
@use "
|
|
2
|
-
@use "
|
|
3
|
-
@use "functions
|
|
1
|
+
@use "base" as *;
|
|
2
|
+
@use "sass:color";
|
|
3
|
+
@use "lib/functions" as *;
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
|
|
6
|
+
// TODO remplacer les clés avec tirets par un souligné foo-bar -> foo_bar
|
|
7
|
+
// TODO générer ce fichier à partir d'un json, afin d'avoir les tokens en js
|
|
8
|
+
$lg-tokens: (
|
|
7
9
|
font : (
|
|
8
10
|
family : (
|
|
9
11
|
roboto: google-font(roboto),
|
|
@@ -65,43 +67,50 @@ $xl-tokens: (
|
|
|
65
67
|
xl: token-value(line-height, 200),
|
|
66
68
|
content: token-value(line-height, md),
|
|
67
69
|
),
|
|
68
|
-
max-content-width:
|
|
70
|
+
max-content-width: 825px, //TODO faire une clé max_width : (content:…, component1:…, )
|
|
69
71
|
color: (
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
72
|
+
white : #ffffff,
|
|
73
|
+
blue : (
|
|
74
|
+
extra-pale: token-value(color blue pale),
|
|
75
|
+
pale : #dae6f0,
|
|
76
|
+
light : #4a98d9,
|
|
77
|
+
regular_light: #2586d6,
|
|
78
|
+
regular : #1472bf,
|
|
79
|
+
piv: #095797,
|
|
80
|
+
medium : #19406C,
|
|
81
|
+
dark: #223654,
|
|
82
|
+
),
|
|
83
|
+
purple: #6b4fa1,
|
|
84
|
+
grey : (
|
|
85
|
+
extra-pale: token-value(color grey pale),
|
|
86
|
+
pale : #f1f1f2,
|
|
87
|
+
light : #c5cad2,
|
|
88
|
+
regular: #8893a2,
|
|
89
|
+
medium : #6b778a,
|
|
90
|
+
dark: #4e5662,
|
|
91
|
+
),
|
|
92
|
+
pink : (
|
|
93
|
+
pale: #ffdbd6,
|
|
94
|
+
regular: #e58271,
|
|
95
|
+
),
|
|
96
|
+
red: (
|
|
97
|
+
pale: token-value(color pink pale),
|
|
98
|
+
light: token-value(color pink regular),
|
|
99
|
+
regular: #cb381f,
|
|
100
|
+
dark: #692519,
|
|
101
|
+
),
|
|
102
|
+
green: (
|
|
103
|
+
pale: #d7f0bb,
|
|
104
|
+
regular: #4f813d,
|
|
105
|
+
dark: #2c4024,
|
|
106
|
+
),
|
|
107
|
+
yellow : (
|
|
108
|
+
pale : #f8e69a,
|
|
109
|
+
regular: #e0ad03,
|
|
110
|
+
dark: #ad781c,
|
|
111
|
+
),
|
|
112
|
+
|
|
113
|
+
background : token-value(color white),
|
|
105
114
|
text : (
|
|
106
115
|
primary : token-value(color blue dark)
|
|
107
116
|
),
|
|
@@ -114,23 +123,42 @@ $xl-tokens: (
|
|
|
114
123
|
hover: token-value(color blue piv),
|
|
115
124
|
visited: token-value(color purple),
|
|
116
125
|
active: token-value(color red regular),
|
|
126
|
+
// TODO ajouter le focus cf https://www.figma.com/design/p5kWdGvZk0BvkEGIrdvXL6/%5BSDG-OFFICIEL%5D-Bases-et-composants?node-id=1070-628&node-type=canvas&t=eIMD5cFp9Jq5vMNt-0
|
|
127
|
+
focus: (
|
|
128
|
+
outline: token-value(color blue light),
|
|
129
|
+
)
|
|
130
|
+
),
|
|
131
|
+
formfield: (
|
|
132
|
+
border: token-value(color grey medium ),
|
|
133
|
+
focus: (
|
|
134
|
+
border: token-value(color blue dark),
|
|
135
|
+
outline: token-value(color blue light)
|
|
136
|
+
)
|
|
137
|
+
),
|
|
138
|
+
searchinput: (
|
|
139
|
+
icon: token-value(color blue piv),
|
|
117
140
|
),
|
|
141
|
+
box_shadow: rgba(var(--qc-color-blue-dark-rgb), .24)
|
|
118
142
|
),
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
143
|
+
box_shadow: (
|
|
144
|
+
0: (
|
|
145
|
+
color: token-value(color grey light)
|
|
146
|
+
),
|
|
147
|
+
1: (
|
|
148
|
+
blur: 4px,
|
|
149
|
+
offset: 1px,
|
|
150
|
+
),
|
|
151
|
+
2: (
|
|
152
|
+
blur: 8px,
|
|
153
|
+
offset: 2px,
|
|
154
|
+
),
|
|
155
|
+
3: (
|
|
156
|
+
blur: 16px,
|
|
157
|
+
offset: 4px,
|
|
158
|
+
),
|
|
159
|
+
4: (
|
|
160
|
+
blur: 24px,
|
|
161
|
+
offset: 6px,
|
|
134
162
|
),
|
|
135
163
|
),
|
|
136
164
|
spacer: (
|
|
@@ -173,43 +201,32 @@ $xl-tokens: (
|
|
|
173
201
|
),
|
|
174
202
|
list : (
|
|
175
203
|
pl: token-value(spacer sm),
|
|
176
|
-
mb: token-value(spacer content-block mb),
|
|
177
|
-
embedded-mb : token-value(spacer sm),
|
|
178
204
|
),
|
|
179
205
|
list-item : (
|
|
180
206
|
mb: token-value(spacer sm),
|
|
181
|
-
|
|
182
207
|
),
|
|
183
|
-
notice: (
|
|
184
|
-
my: token-value(spacer, md),
|
|
185
|
-
mx: rem(4 * $base-spacer),
|
|
186
|
-
)
|
|
187
208
|
),
|
|
188
209
|
grid: (
|
|
189
210
|
gutter: 32px,
|
|
190
211
|
breakpoint: (
|
|
191
212
|
xs: 0,
|
|
192
|
-
sm:
|
|
193
|
-
md:
|
|
194
|
-
lg:
|
|
195
|
-
xl: 1200px,
|
|
213
|
+
sm: 768px,
|
|
214
|
+
md: 992px,
|
|
215
|
+
lg: 1200px,
|
|
196
216
|
),
|
|
197
217
|
container-max-width: (
|
|
198
|
-
sm:
|
|
199
|
-
md:
|
|
200
|
-
lg:
|
|
201
|
-
xl: 1200px,
|
|
218
|
+
sm: 768px,
|
|
219
|
+
md: 992px,
|
|
220
|
+
lg: 1200px
|
|
202
221
|
)
|
|
203
222
|
),
|
|
204
223
|
) !default;
|
|
205
224
|
|
|
225
|
+
// legacy
|
|
226
|
+
$xl-tokens : $lg-tokens;
|
|
227
|
+
|
|
206
228
|
$breakpoints-tokens: (
|
|
207
|
-
|
|
208
|
-
lg : (
|
|
209
|
-
grid: (
|
|
210
|
-
gutter: 24px,
|
|
211
|
-
)
|
|
212
|
-
),
|
|
229
|
+
lg : $lg-tokens,
|
|
213
230
|
md : (
|
|
214
231
|
font-size: (
|
|
215
232
|
h3: rem(25),
|
|
@@ -228,6 +245,9 @@ $breakpoints-tokens: (
|
|
|
228
245
|
mb: rem(1 * $base-spacer),
|
|
229
246
|
)
|
|
230
247
|
),
|
|
248
|
+
grid: (
|
|
249
|
+
gutter: 24px,
|
|
250
|
+
)
|
|
231
251
|
),
|
|
232
252
|
sm : (
|
|
233
253
|
grid: (
|
|
@@ -236,6 +256,54 @@ $breakpoints-tokens: (
|
|
|
236
256
|
),
|
|
237
257
|
) !default;
|
|
238
258
|
|
|
259
|
+
$themes-tokens: (
|
|
260
|
+
light: $breakpoints-tokens,
|
|
261
|
+
dark: (
|
|
262
|
+
lg: (
|
|
263
|
+
color: (
|
|
264
|
+
white : #121519,
|
|
265
|
+
blue : (
|
|
266
|
+
pale : #162B47,
|
|
267
|
+
light : #0078CC,
|
|
268
|
+
regular : #3B95E1,
|
|
269
|
+
piv: #72B2EB,
|
|
270
|
+
medium : #ADCDEB,
|
|
271
|
+
dark: #C6DBEE,
|
|
272
|
+
),
|
|
273
|
+
purple: #B3A5D4,
|
|
274
|
+
grey : (
|
|
275
|
+
pale : #1C2025,
|
|
276
|
+
light : #3B424C,
|
|
277
|
+
regular: #6A7688,
|
|
278
|
+
medium : #8590A8,
|
|
279
|
+
dark: #A7ACBC,
|
|
280
|
+
),
|
|
281
|
+
pink : (
|
|
282
|
+
pale: #4F180E,
|
|
283
|
+
regular: #BB3A23,
|
|
284
|
+
),
|
|
285
|
+
red: (
|
|
286
|
+
regular: #F26049,
|
|
287
|
+
dark: #F3BCB6,
|
|
288
|
+
),
|
|
289
|
+
green: (
|
|
290
|
+
pale: #1E2F17,
|
|
291
|
+
regular: #6E9C57,
|
|
292
|
+
dark: #B0D493,
|
|
293
|
+
),
|
|
294
|
+
yellow : (
|
|
295
|
+
pale : #3F240C,
|
|
296
|
+
regular: #6D4512,
|
|
297
|
+
dark: #AC7900,
|
|
298
|
+
),
|
|
299
|
+
text : (
|
|
300
|
+
primary : #D7D8DD
|
|
301
|
+
),
|
|
302
|
+
accent: #F17B6C,
|
|
303
|
+
)
|
|
304
|
+
)
|
|
305
|
+
)
|
|
306
|
+
) !default;
|
|
239
307
|
|
|
240
308
|
|
|
241
309
|
|
|
@@ -1,4 +1,44 @@
|
|
|
1
|
-
|
|
2
|
-
@
|
|
3
|
-
|
|
1
|
+
// retrait de ces utilitaires pour alléger la css
|
|
2
|
+
@use "sass:map";
|
|
3
|
+
@use "lib/gridless-lib" as *;
|
|
4
|
+
@use "grid/grid-lib" as *;
|
|
4
5
|
|
|
6
|
+
$spacers : (
|
|
7
|
+
0: 0,
|
|
8
|
+
1: token-value(spacer sm),
|
|
9
|
+
2: token-value(spacer md),
|
|
10
|
+
3: token-value(spacer lg),
|
|
11
|
+
4: token-value(spacer xl),
|
|
12
|
+
);
|
|
13
|
+
|
|
14
|
+
$displays: none, inline, inline-block, block, table, table-row, table-cell, flex, inline-flex !default;
|
|
15
|
+
|
|
16
|
+
// stylelint-disable declaration-no-important
|
|
17
|
+
|
|
18
|
+
// equivalent à @import(src/sdg/scss/vendor/bootstrap-rewrite/utilities/_display.scss)
|
|
19
|
+
// Utilities for common `display` values
|
|
20
|
+
|
|
21
|
+
@each $breakpoint in map.keys($grid-breakpoints) {
|
|
22
|
+
@include media-breakpoint-up($breakpoint) {
|
|
23
|
+
$infix: breakpoint-infix($breakpoint, $grid-breakpoints);
|
|
24
|
+
|
|
25
|
+
@each $value in $displays {
|
|
26
|
+
.qc-d#{$infix}-#{$value} { display: $value !important; }
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
//
|
|
33
|
+
// Utilities for toggling `display` in print
|
|
34
|
+
//
|
|
35
|
+
|
|
36
|
+
@media print {
|
|
37
|
+
@each $value in $displays {
|
|
38
|
+
.qc-d-print-#{$value} { display: $value !important; }
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.qc-nowrap {
|
|
43
|
+
white-space: nowrap;
|
|
44
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
@use "qc-sdg-lib" as *;
|
|
2
|
+
|
|
3
|
+
:root {
|
|
4
|
+
--qc-light-theme-display: block;
|
|
5
|
+
--qc-dark-theme-display: none;
|
|
6
|
+
&.qc-dark-theme {
|
|
7
|
+
--qc-light-theme-display: none;
|
|
8
|
+
--qc-dark-theme-display: block;
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.qc-light-theme-show {
|
|
13
|
+
display: var(--qc-light-theme-display);
|
|
14
|
+
}
|
|
15
|
+
.qc-dark-theme-show {
|
|
16
|
+
display: var(--qc-dark-theme-display);
|
|
17
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
/*
|
|
1
|
+
/*Box sizing rules */
|
|
2
|
+
|
|
2
3
|
*,
|
|
3
4
|
*::before,
|
|
4
5
|
*::after {
|
|
@@ -49,13 +50,13 @@ picture {
|
|
|
49
50
|
display: block;
|
|
50
51
|
}
|
|
51
52
|
|
|
52
|
-
/* Inherit fonts for inputs and buttons */
|
|
53
|
-
input,
|
|
54
|
-
button,
|
|
55
|
-
textarea,
|
|
56
|
-
select {
|
|
57
|
-
|
|
58
|
-
}
|
|
53
|
+
/* Inherit fonts for inputs and buttons */
|
|
54
|
+
input,
|
|
55
|
+
button,
|
|
56
|
+
textarea,
|
|
57
|
+
select {
|
|
58
|
+
font: inherit;
|
|
59
|
+
}
|
|
59
60
|
|
|
60
61
|
/* Remove all animations and transitions for people that prefer not to see them */
|
|
61
62
|
@media (prefers-reduced-motion: reduce) {
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
<svelte:options customElement="{{
|
|
2
|
-
tag: 'qc-code'
|
|
3
|
-
, props: {
|
|
4
|
-
targetId : {attribute: 'target-id'}
|
|
5
|
-
}
|
|
6
|
-
}}" />
|
|
7
|
-
|
|
8
|
-
<script>
|
|
9
|
-
|
|
10
|
-
import {HighlightJS} from "highlight.js"
|
|
11
|
-
import 'highlight.js/styles/default.css';
|
|
12
|
-
import pretty from "pretty";
|
|
13
|
-
import { onMount } from "svelte";
|
|
14
|
-
import { Utils } from "../../sdg/components/utils"
|
|
15
|
-
|
|
16
|
-
export let
|
|
17
|
-
targetId = ''
|
|
18
|
-
, language = 'html'
|
|
19
|
-
;
|
|
20
|
-
|
|
21
|
-
let
|
|
22
|
-
rawCode = ''
|
|
23
|
-
, hlCode
|
|
24
|
-
, prettyCode
|
|
25
|
-
;
|
|
26
|
-
|
|
27
|
-
onMount(() => {
|
|
28
|
-
rawCode =
|
|
29
|
-
( document.getElementById(targetId)?.outerHTML
|
|
30
|
-
?? ''
|
|
31
|
-
) . replace('class="mounted"', '')
|
|
32
|
-
;
|
|
33
|
-
prettyCode = pretty(rawCode, {wrap_attributes: 'force-aligned'});
|
|
34
|
-
hlCode = HighlightJS.highlight(prettyCode, {language:language}).value;
|
|
35
|
-
})
|
|
36
|
-
|
|
37
|
-
function copy() {
|
|
38
|
-
navigator.clipboard.writeText(prettyCode);
|
|
39
|
-
this.classList.add('copied')
|
|
40
|
-
setTimeout(() => {this.classList.remove('copied')}, 500)
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
</script>
|
|
44
|
-
|
|
45
|
-
<pre
|
|
46
|
-
><code class="hljs"><button class="btn btn-sm btn-primary" on:click={copy}>
|
|
47
|
-
<span class="copy">copier</span>
|
|
48
|
-
<span class="copied">copié !</span>
|
|
49
|
-
</button
|
|
50
|
-
>{@html hlCode}</code
|
|
51
|
-
></pre>
|
|
52
|
-
<link rel='stylesheet'
|
|
53
|
-
href='{Utils.cssRelativePath}{Utils.cssFileName}'>
|
|
54
|
-
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
@use "modules/grid" as *;
|
|
2
|
-
@import "vendor/bootstrap-rewrite/grid";
|
|
3
|
-
|
|
4
|
-
// Décommenter ces lignes pour ajouter les classes utilitaires bootstrap précédées de « qc- »,
|
|
5
|
-
// selon le même principe que pour la grille.
|
|
6
|
-
// ex: mt-lg-4 -> qc-mt-lg-4, d-sm-flex -> qc-d-sm-flex, d-md-none, qc-d-md-none
|
|
7
|
-
//@import "build/bootstrap/scss/utilities/display";
|
|
8
|
-
//@import "build/bootstrap/scss/utilities/flex";
|
|
9
|
-
//@import "build/bootstrap/scss/utilities/spacing";
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
@use "utils" as *;
|
|
2
|
-
// functions
|
|
3
|
-
|
|
4
|
-
// Return css var corresponding to this token
|
|
5
|
-
// token-value("foo","bar"); // var(--qc-foo-bar);
|
|
6
|
-
@function token-value($args...) {
|
|
7
|
-
@return var(#{token-name($args...)});
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
@function token-name($args...) {
|
|
11
|
-
@return --qc-#{deep-implode($args, '-')};
|
|
12
|
-
}
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
@use "settings/settings" as *;
|
|
2
|
-
@use "sass:math";
|
|
3
|
-
@use "sass:map";
|
|
4
|
-
@use "sass:list";
|
|
5
|
-
@use "sass:string";
|
|
6
|
-
|
|
7
|
-
/*
|
|
8
|
-
Return rem size from pixel size according to root font-size as define in settings
|
|
9
|
-
Always use this function for rem values
|
|
10
|
-
// root font-size : 100 %,
|
|
11
|
-
// foo.scss
|
|
12
|
-
.foo { font-size: rem(16); }
|
|
13
|
-
// foo.css
|
|
14
|
-
.foo { font-size: 1rem; }
|
|
15
|
-
|
|
16
|
-
// root font-size : 62.5 %,
|
|
17
|
-
// foo.scss
|
|
18
|
-
.foo { font-size: rem(16); }
|
|
19
|
-
// foo.css
|
|
20
|
-
.foo { font-size: 1.6rem; }
|
|
21
|
-
*/
|
|
22
|
-
@function rem($px-size) {
|
|
23
|
-
@return math.div($px-size, 16 * $percent-root-font-size * .01) * 1rem;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
// implode a list (and flatten inner list : implode( (foo, (bar baz)), '-'); => foo-bar-baz
|
|
27
|
-
@function deep-implode($list, $glue: '-') {
|
|
28
|
-
$separator : '';
|
|
29
|
-
$result : '';
|
|
30
|
-
@each $item in $list {
|
|
31
|
-
$part : $item;
|
|
32
|
-
@if type-of($item) == 'list' {
|
|
33
|
-
$part : deep-implode($item, $glue);
|
|
34
|
-
}
|
|
35
|
-
$result : '#{$result}#{$separator}#{$part}';
|
|
36
|
-
$separator: $glue;
|
|
37
|
-
}
|
|
38
|
-
@return $result;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
@function google-font($font) {
|
|
42
|
-
@return string.unquote(deep-implode(map.get($google-fonts, $font), ','));
|
|
43
|
-
}
|
|
44
|
-
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
@import "settings/grid";
|
|
2
|
-
@import "vendor/bootstrap-rewrite/mixins/breakpoints";
|
|
3
|
-
@import "vendor/bootstrap-rewrite/mixins/deprecate";
|
|
4
|
-
@import "vendor/bootstrap-rewrite/mixins/grid";
|
|
5
|
-
@import "vendor/bootstrap-rewrite/mixins/grid-framework";
|
|
6
|
-
|
|
7
|
-
@mixin media-tablet() {
|
|
8
|
-
@include media-breakpoint-down(sm) {
|
|
9
|
-
@content;
|
|
10
|
-
}
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
@mixin media-mobile() {
|
|
14
|
-
@include media-breakpoint-down(xs) {
|
|
15
|
-
@content;
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
@use "sass:list";
|
|
2
|
-
//
|
|
3
|
-
@mixin map-deep-parse($map, $parents: ()) {
|
|
4
|
-
@each $key, $value in $map {
|
|
5
|
-
$path: list.append($parents, $key);
|
|
6
|
-
@if type-of($value) == 'map' {
|
|
7
|
-
@include map-deep-parse($value, $path) using($path,$value) {
|
|
8
|
-
@content($path, $value);
|
|
9
|
-
}
|
|
10
|
-
} @else {
|
|
11
|
-
@content($path, $value);
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
}
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
@use "functions/utils" as *;
|
|
2
|
-
@use "tokens" as *;
|
|
3
|
-
@forward "settings/settings";
|
|
4
|
-
@forward "functions/utils";
|
|
5
|
-
|
|
6
|
-
// typography
|
|
7
|
-
|
|
8
|
-
// toujours utiliser ces mixins pour la déclarations des tailles de police:
|
|
9
|
-
// cela garantit que la taille police est conforme aux exigences du SDG
|
|
10
|
-
// et ajoute automatiquement le bon interlignage
|
|
11
|
-
@mixin content-font($scale: 'md', $weight: 'regular', $include-family: 0) {
|
|
12
|
-
font-size: token-value(font size $scale);
|
|
13
|
-
line-height: token-value(line-height $scale);
|
|
14
|
-
font-weight: token-value(font weight $weight);
|
|
15
|
-
@if $include-family == 1 {
|
|
16
|
-
font-family: token-value(font family content);
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
@mixin header-font($header) {
|
|
21
|
-
font-family: token-value(font, family, header) ;
|
|
22
|
-
font-size: token-value(font, size, $header) ;
|
|
23
|
-
line-height: token-value(line-height, $header) ;
|
|
24
|
-
font-weight: token-value(font, weight, header, bold);
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
// links
|
|
28
|
-
|
|
29
|
-
@mixin hover-link() {
|
|
30
|
-
color: token-value(color, link, hover);
|
|
31
|
-
text-decoration: none;
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
@mixin active-link() {
|
|
35
|
-
color: token-value(color, link, active);
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
@mixin external-link-img() {
|
|
39
|
-
max-height: rem(11);
|
|
40
|
-
max-width: rem(11);
|
|
41
|
-
margin-bottom: rem(1.6);
|
|
42
|
-
display: inline-block;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
@mixin sr-only() {
|
|
46
|
-
position: absolute;
|
|
47
|
-
width: 1px;
|
|
48
|
-
height: 1px;
|
|
49
|
-
padding: 0;
|
|
50
|
-
margin: -1px;
|
|
51
|
-
overflow: hidden;
|
|
52
|
-
clip: rect(0, 0, 0, 0);
|
|
53
|
-
white-space: nowrap;
|
|
54
|
-
border: 0;
|
|
55
|
-
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
@use "modules/utils" as utils;
|
|
2
|
-
@use "modules/map" as *;
|
|
3
|
-
@use "modules/tokens";
|
|
4
|
-
@use "sass:map";
|
|
5
|
-
// Merci ! / ty Bootstrap
|
|
6
|
-
@import "vendor/bootstrap-rewrite/functions";
|
|
7
|
-
@import "vendor/bootstrap-rewrite/variables";
|
|
8
|
-
|
|
9
|
-
$enable-grid-classes: utils.$enable-grid-classes;
|
|
10
|
-
$enable-deprecation-messages : false;
|
|
11
|
-
$grid-breakpoints: map.get(tokens.$xl-tokens, grid, breakpoint);
|
|
12
|
-
$grid-gutter-width: tokens.token-value(grid gutter);
|
|
13
|
-
$container-max-widths: map.get(tokens.$xl-tokens, grid, container-max-width);
|
|
14
|
-
|
|
15
|
-
$spacers : (
|
|
16
|
-
0: 0,
|
|
17
|
-
1: tokens.token-value(spacer sm),
|
|
18
|
-
2: tokens.token-value(spacer md),
|
|
19
|
-
3: tokens.token-value(spacer lg),
|
|
20
|
-
4: tokens.token-value(spacer xl),
|
|
21
|
-
);
|
|
22
|
-
|
|
23
|
-
@import "vendor/bootstrap-rewrite/mixins/breakpoints";
|
|
24
|
-
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
$percent-root-font-size: 62.5 !default; // so 1.6rem == 16px
|
|
2
|
-
$img-dir: "../img";
|
|
3
|
-
$base-spacer: 8 !default;
|
|
4
|
-
// for local fonts, cf https://google-webfonts-helper.herokuapp.com/fonts
|
|
5
|
-
$google-api-font: true !default;
|
|
6
|
-
$google-fonts : (
|
|
7
|
-
roboto: (Roboto, sans-serif),
|
|
8
|
-
open-sans: ('Open Sans', sans-serif),
|
|
9
|
-
roboto-mono: ('Roboto Mono', monospace)
|
|
10
|
-
);
|
|
11
|
-
|
|
12
|
-
$enable-grid-classes: true;
|