@data-fair/lib-vuetify 1.9.1 → 1.9.2

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.
Files changed (3) hide show
  1. package/index.d.ts +1 -1
  2. package/index.js +2 -1
  3. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
1
  import { type Session } from '@data-fair/lib-vue/session.js';
2
2
  import { VuetifyOptions } from 'vuetify';
3
- export declare function vuetifySessionOptions(session: Session): VuetifyOptions;
3
+ export declare function vuetifySessionOptions(session: Session, cspNonce?: string): VuetifyOptions;
4
4
  export declare function defaultOptions(searchParams: Record<string, string>, darkCookie?: boolean, locale?: string): VuetifyOptions;
package/index.js CHANGED
@@ -13,7 +13,7 @@ const baseDarkColors = {
13
13
  primary: '#2196F3', // blue.base
14
14
  success: '#00E676' // green.accent3
15
15
  }
16
- export function vuetifySessionOptions (session) {
16
+ export function vuetifySessionOptions (session, cspNonce) {
17
17
  if (!session.site.value) { throw new Error('vuetifySessionOptions requires fething site info in session util') }
18
18
  const colors = { ...baseColors, ...session.site.value?.colors }
19
19
  return {
@@ -23,6 +23,7 @@ export function vuetifySessionOptions (session) {
23
23
  messages: { fr, en }
24
24
  },
25
25
  theme: {
26
+ cspNonce,
26
27
  defaultTheme: session.theme.value ?? 'default',
27
28
  themes: {
28
29
  [session.theme.value ?? 'default']: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@data-fair/lib-vuetify",
3
- "version": "1.9.1",
3
+ "version": "1.9.2",
4
4
  "description": "Components based on the Vuetify 3 UI lib for the data-fair stack.",
5
5
  "main": "index.js",
6
6
  "files": [