vux修改主题配色

webpack.base.conf.js 中修改 plugins

module.exports = vuxLoader.merge(webpackConfig, {
  plugins: [
    {
      name: 'vux-ui'
    },
    {
      name: 'duplicate-style'
    },
    {
      name: 'less-theme',
      path: 'src/theme.less'
    }
  ]
})

theme.less

@namespace: vux;

@theme-color: #04BE02;
@opacity-disabled: 0.5;

/**
* actionsheet
*/
@actionsheet-label-primary-color: #1AAD19;
@actionsheet-label-warn-color: #E64340;
@actionsheet-label-default-color: #000;
@actionsheet-label-disabled-color: #ccc;

/**
* datetime
*/
@datetime-header-item-font-color: @theme-color;
@datetime-header-item-cancel-font-color: #828282;
@datetime-header-item-confirm-font-color: @datetime-header-item-font-color;

/**
* tabbar
*/
@tabbar-text-active-color: #09BB07;

/**
* tab
*/
@tab-text-disabled-color: #ddd;
@tab-text-default-color: #666;
@tab-text-active-color: @theme-color;
@tab-bar-active-color: @theme-color;

/**
* dialog
*/
@dialog-button-text-primary-color: #0BB20C;
@dialog-button-text-default-color: #353535;
@dialog-button-text-warn-color: #E64340;
@dialog-width: 80%; // also affects alert confirm
@dialog-max-width: 300px; // also affects alert confirm

/**
* x-number
*/
@number-button-font-color: #3cc51f;
@number-input-font-color: #666;
@number-button-enabled-border-color: #ececec;
@number-square-button-enabled-border-color: @number-button-enabled-border-color;
@number-round-button-enabled-border-color: @number-button-font-color;
@number-button-disabled-border-color: @number-button-enabled-border-color;
@number-round-button-disabled-border-color: @number-button-enabled-border-color;

/**
* checkbox
*/
@checkbox-icon-color-checked: #09BB07;

/**
* check-icon
*/
@check-icon-color-checked: @checkbox-icon-color-checked;

/**
* Cell
*/
@cell-label-color: #000;
@cell-font-size: 17px;
@cell-tips-font-size: 14px;
@cell-default-arrow-color: #C8C8CD;
@cell-disabled-arrow-color: #e2e2e2;
@cell-default-arrow-border-width: 2px;
@cell-default-arrow-width: 6px;
@cell-value-color: #999;
@cell-placeholder-color: #999;

/**
* Mask
*/
@dialog-mask-background: rgba(0, 0, 0, .6);

/**
* Range
*/
@range-disabled-opacity: @opacity-disabled;
@range-bar-default-color: #a9acb1;
@range-bar-active-color: @theme-color;

/**
* Tabbar
*/
@tabbar-index: 100;

/**
* Header
*/
@header-background-color: #35495e;
@header-title-color: #fff;
@header-text-color: #ccc;
@header-arrow-color: #ccc;

/**
* Timeline
*/
@timeline-item-bg-color: @theme-color;

/**
* Switch
*/
@switch-checked-bg-color: @theme-color;
@switch-checked-border-color: @theme-color;
@switch-disabled-opacity: 0.6;
@switch-height: 32px;

/**
* Button
*/
@button-global-border-radius: 5px;
@button-global-font-color: #FFFFFF;
@button-global-margin-top: 15px;
@button-global-height: 42px;
@button-global-disabled-font-color: rgba(255,255,255,.6);
@button-global-active-font-color: rgba(255,255,255,.6);
@button-global-font-size: 18px;

@button-warn-bg-color: #E64340;
@button-warn-active-color: #CE3C39;
@button-warn-disabled-bg-color: #EC8B89;

@button-default-bg-color: #F8F8F8;
@button-default-font-color: #000000;
@button-default-active-bg-color: #DEDEDE;
@button-default-disabled-font-color: rgba(0,0,0,.3);
@button-default-disabled-bg-color: #F7F7F7;
@button-default-active-font-color: rgba(0,0,0,.6);

@button-primary-bg-color: #1AAD19;
@button-primary-active-bg-color: #179B16;
@button-primary-disabled-bg-color: #9ED99D;

/**
* swipeout
*/
@swipeout-button-primary-bg-color: @button-primary-bg-color;
@swipeout-button-warn-bg-color: @button-warn-bg-color;
@swipeout-button-default-bg-color: #c8c7cd;

@swipeout-content-bg-color: #FFF;
@swipeout-button-font-color: #FFF;

/**
* Cell
*/
@cell-body-label-color: #000;

/**
* Badge
*/
@badge-bg-color: #f74c31;

/**
* Popover
*/
@popover-bg-color: #35495e;
@popover-font-color: #fff;
@popover-border-radius: 3px;
@popover-border-width: 5px;

/**
* Button tab
*/
@button-tab-border-width: 1px;
@button-tab-border-radius: 16px;

@button-tab-border-color: @theme-color;
@button-tab-default-border-color: @button-tab-border-color;
@button-tab-active-border-color: @button-tab-border-color;

@button-tab-default-background-color: #fdfdfd;
@button-tab-active-background-color: @theme-color;

@button-tab-active-font-color: #FFF; /* alias */
@button-tab-active-text-color: @button-tab-active-font-color;
@button-tab-default-text-color: #999;

@button-tab-height: 30px;
@button-tab-line-height: 31px;

/**
* Swiper
*/
@swiper-indicator-active-color: @theme-color;

/**
* checklist
*/
@checklist-icon-active-color: #09BB07;

/**
* popup-picker
*/
@popup-picker-header-text-color: @theme-color;
@popup-picker-header-bg-color: #fbf9fe;
@popup-picker-header-font-size: 16px;
@popup-picker-header-cancel-text-color: #828282;

/**
* popup
*/
@popup-background-color: #eee;

/**
* popup-header
*/
@popup-header-height: 44px;
@popup-header-bg-color: #fbf9fe;
@popup-header-font-size: 16px;
@popup-header-left-text-color: #828282;
@popup-header-right-text-color: @theme-color;
@popup-header-title-text-color: #222;
@popup-header-left-text-padding: 15px;
@popup-header-right-text-padding: 15px;

/**
* form-preview
*/
@form-preview-button-primary-color: #0BB20C;

/**
* sticky
*/
@sticky-zindex: 500;

/**
* group
*/
@group-title-margin-top: .77em;
@group-title-margin-bottom: .3em;
@group-footer-title-margin-top: .3em;
@group-footer-title-margin-bottom: .77em;

/**
* toast
*/
@toast-content-font-size: 16px;
@toast-top: 180px;
@toast-position-top-offset: 10px;
@toast-position-bottom-offset: 10px;
@toast-z-index: 5001;

/**
* icon
*/
@icon-success-color: #09BB07;

/**
* calendar
*/
@calendar-arrow-color: @theme-color;
@calendar-highlight-color: #E59313;
@calendar-selected-bg-color: @theme-color;
@calendar-disabled-font-color: #c0c0c0;
@calendar-today-font-color: @theme-color;
@calendar-date-item-font-size: 16px;
@calendar-bg-color: #fff;
@calendar-each-date-item-size: 26px;
@calendar-each-date-item-line-height: 25px;
@calendar-header-day-item-color: #000;

/**
* week-calendar
*/
@week-calendar-bg: #fff;
@week-calendar-each-date-item-size: 26px;
@week-calendar-each-date-item-line-height: 25px;
@week-calendar-each-date-item-color: #444;
@week-calendar-selected-item-bg-color: @theme-color;
@week-calendar-selected-item-text-color: #fff;
@week-calendar-dot-color: #f74c31;
@week-calendar-header-day-item-color: #000;

/**
* search
*/
@search-cancel-font-color: #09BB07;
@search-bg-color: #EFEFF4;
@search-placeholder-font-color: #9B9B9B;

/**
* radio
*/
@radio-checked-icon-color: #09BB07;

/**
* loadmore
*/
@load-more-line-color: #E5E5E5;

你可能感兴趣的:(vux修改主题配色)