项目作者: jloh

项目描述 :
Bulma prefers dark theme
高级语言: CSS
项目地址: git://github.com/jloh/bulma-prefers-dark.git
创建时间: 2019-03-30T11:20:05Z
项目社区:https://github.com/jloh/bulma-prefers-dark

开源协议:MIT License

下载


bulma-prefers-dark

Safari screenshot

Bulma now supports dark mdoe out of the box, this repo is no longer maintained
See the docs https://bulma.io/documentation/features/dark-mode/

A Bulma extension that adds support for the prefers-color-scheme: dark media query

npm
npm

Installation

  1. npm install bulma-prefers-dark
  2. ... Or ...
  3. yarn add bulma-prefers-dark

Usage

This extension works as-is in combination with Bulma by adding an alternative dark theme via the @media (prefers-color-scheme: dark) media query.

Include it in your SaSS pipeline after you’ve included Bulma and you’re good to go:

  1. @import "../../node_modules/bulma/bulma.sass";
  2. @import "../../bulma-prefers-dark/bulma-prefers-dark.sass";

Alternatively include it in your HTML via unpkg:

  1. <link rel="stylesheet" type="text/css" href="https://unpkg.com/bulma-prefers-dark" />

Code copyright 2019 James Loh. Code released under the MIT license.