mirror of
https://github.com/hugo-fixit/FixIt.git
synced 2026-08-24 15:28:57 +00:00
09e08d0772
**Breaking changes**: 1. Legacy custom style/script files are no longer loaded automatically. 2. Users must migrate custom files to: - `custom.scss` - `override.scss` - `_variables.scss` - `assets/js/custom.js` **Migration guide**: 1. Move `assets/css/_custom.scss` to `assets/scss/custom.scss`. 2. Move `assets/css/_override.scss` to `assets/scss/override.scss`. 3. Keep variables in `assets/scss/_variables.scss`. 4. Move `assets/js/_custom.js` to `assets/js/custom.js`. 5. Rebuild site and verify no deprecation warnings remain.
32 lines
1.4 KiB
HTML
32 lines
1.4 KiB
HTML
{{- /* Deprecated parameter detection */ -}}
|
|
{{- $warns := slice -}}
|
|
{{- $errors := slice -}}
|
|
|
|
{{- with .Site.Params.externalIcon -}}
|
|
{{- $warns = $warns | append "The parameter `params.externalIcon` is deprecated since v1.0.0, use `params.link.external_icon` instead." -}}
|
|
{{- end -}}
|
|
|
|
{{- with resources.Get "css/_custom.scss" -}}
|
|
{{- $warns = $warns | append "The file `assets/css/_custom.scss` is deprecated. Please move your custom styles to `assets/scss/custom.scss`." -}}
|
|
{{- end -}}
|
|
|
|
{{- with resources.Get "css/_override.scss" -}}
|
|
{{- $warns = $warns | append "The file `assets/css/_override.scss` is deprecated. Please move your custom styles to `assets/scss/override.scss`." -}}
|
|
{{- end -}}
|
|
|
|
{{- with resources.Get "css/_variables.scss" -}}
|
|
{{- $warns = $warns | append "The file `assets/css/_variables.scss` is deprecated. Please move your variables to `assets/scss/_variables.scss`." -}}
|
|
{{- end -}}
|
|
|
|
{{- with resources.Get "js/_custom.js" -}}
|
|
{{- $warns = $warns | append "The file `assets/js/_custom.js` is deprecated. Please move your custom scripts to `assets/js/custom.js`." -}}
|
|
{{- end -}}
|
|
|
|
{{- if len $warns -}}
|
|
{{- warnf "FixIt deprecation warnings (%v):\n • %v\n\n" (hugo.Store.Get "version") (delimit $warns "\n • ") -}}
|
|
{{- end -}}
|
|
|
|
{{- if len $errors -}}
|
|
{{- errorf "FixIt deprecation errors (%v):\n • %v\n\n" (hugo.Store.Get "version") (delimit $errors "\n • ") -}}
|
|
{{- end -}}
|