[英]Drupal: Sub Theme CSS Won't work
我是Drupal的初学者。 我设置了一个Drupal Sub Theme,它已经激活并且可以工作。 我选择了Bootstrap主题。 现在,我试图添加我的自定义CSS。
library.yml
global-styling:
css:
theme:
css/style.css: {}
info.yml
core: 8.x
type: theme
base theme: bootstrap
name: 'Recipes'
description: 'Uses the jsDelivr CDN for all CSS and JavaScript. No source files or compiling is necessary and is recommended for simple sites or beginners.'
package: 'Bootstrap'
regions:
navigation: 'Navigation'
navigation_collapsible: 'Navigation (Collapsible)'
header: 'Top Bar'
highlighted: 'Highlighted'
help: 'Help'
content: 'Content'
sidebar_first: 'Primary'
sidebar_second: 'Secondary'
footer: 'Footer'
page_top: 'Page top'
page_bottom: 'Page bottom'
myregion: 'meine neue Region'
libraries:
- 'recipes/global-styling'
我希望你能帮帮我 :)
试试这个
library.yml
global-styling:
version: VERSION
css:
base:
css/style.css: {}
info.yml
libraries:
- recipes/global-styling
您的解决方案应该可以工作,您必须从管理员或数据库中清除缓存。 它可以像我一样工作。
global-styling:
css:
theme:
css/style.css: {}
css/custom.css: {}
libraries:
- 'bootstrap_subtheme/global-styling'
谢谢
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.