domma-cms 0.107.1 → 0.109.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/scripts/build.js CHANGED
@@ -65,6 +65,12 @@ const PLUGIN_AS_IS_PATTERNS = [
65
65
  // built against its documented API worked in development and broke on an
66
66
  // installed copy.
67
67
  'plugins/_lib/**/*.js',
68
+ // The call page's background blur: MediaPipe, vendored (already minified) with
69
+ // its WebAssembly and model. Without these the Blur button reports that it
70
+ // could not start - on an installed site only, never in development.
71
+ 'plugins/_lib/public/**/*.mjs',
72
+ 'plugins/_lib/public/**/*.wasm',
73
+ 'plugins/_lib/public/**/*.tflite',
68
74
  // A plugin's root-level JS, not just plugin.js and config.js. blog and
69
75
  // surveys each keep their PUBLIC SITE routes in plugin.public.js and the
70
76
  // invoice plugin its PDF renderer in pdf.js; none of them shipped, so an
package/server/server.js CHANGED
@@ -114,7 +114,9 @@ await app.register(helmet, {
114
114
  contentSecurityPolicy: {
115
115
  directives: {
116
116
  defaultSrc: ["'self'"],
117
- scriptSrc: ["'self'", "'unsafe-inline'", 'https://cdn.jsdelivr.net'],
117
+ // 'wasm-unsafe-eval' lets a page compile WebAssembly (the call page's background blur) - it allows
118
+ // nothing for JavaScript: eval and new Function stay blocked.
119
+ scriptSrc: ["'self'", "'unsafe-inline'", "'wasm-unsafe-eval'", 'https://cdn.jsdelivr.net'],
118
120
  styleSrc: ["'self'", "'unsafe-inline'", 'https://cdn.jsdelivr.net', 'https://fonts.googleapis.com'],
119
121
  imgSrc: ["'self'", 'data:', 'blob:'],
120
122
  fontSrc: ["'self'", 'data:', 'https://fonts.gstatic.com'],