diff --git a/.gitignore b/.gitignore index 23fbfcf..754af37 100644 --- a/.gitignore +++ b/.gitignore @@ -10,3 +10,5 @@ node_modules /locale /index.* + +/scss diff --git a/README.md b/README.md index dd4c050..6c50821 100644 --- a/README.md +++ b/README.md @@ -57,6 +57,19 @@ $ npm install vue2-datepicker --save ``` +## Theme + +If your project uses SCSS, you can change the default style variables. + +To create a scss file. e.g. `datepicker.scss`: + +```scss +$default-color: #555; +$primary-color: #1284e7; + +@import '~vue2-datepicker/scss/index.scss'; +``` + ## Internationalization The default language of v3.x is English. If you need other locales. diff --git a/README.zh-CN.md b/README.zh-CN.md index eb1736b..01f2636 100644 --- a/README.zh-CN.md +++ b/README.zh-CN.md @@ -29,7 +29,20 @@ $ npm install vue2-datepicker --save ``` -## Usage +## 主题 + +如果你的项目使用了 SCSS, 你可以改变默认的变量. + +创建一个新的文件. e.g. `datepicker.scss`: + +```scss +$default-color: #555; +$primary-color: #1284e7; + +@import '~vue2-datepicker/scss/index.scss'; +``` + +## 用法 ```html