Code Monkey home page Code Monkey logo

jimo-antd-theme's Introduction

jimo-antd-theme

Antd theme for jimengio

Build Status npm GitHub license

Theme

Preview: https://jimengio.github.io/jimo-antd-theme/

Antd variables

  1. platform / platformV3
  2. q806V3 / q806HCV3
  3. ...

css

lib
├── platform.min.css
├── platform_v3.min.css
├── platform_hc.min.css
├── platform_hc_v3.min.css
├── q806_hc_v3.min.css
├── q806_v3.min.css

less

lib
├── platform.theme.less
├── platform_v3.theme.less
├── platform_hc.theme.less
├── platform_hc_v3.theme.less
├── q806_v3.theme.less
├── q806_hc_v3.theme.less

Usage

Installation

yarn add -D @jimengio/jimo-antd-theme

less

import "antd/dist/antd.less";
import "@jimengio/jimo-antd-theme/lib/platform.theme.less";

webpack

// Entry file

// import "antd/dist/antd.css";
import "antd/dist/antd.less";
const jimoTheme = require("@jimengio/jimo-antd-theme");

// add rule
exports.matchLessRule = {
  test: /\.less$/,
  use: [
    {
      loader: "style-loader",
    },
    {
      loader: "css-loader",
    },
    {
      loader: "less-loader",
      options: {
        modifyVars: {
          ...jimoTheme.platform,
        },
        javascriptEnabled: true,
      },
    },
  ],
};

css

不是很推荐,根据具体 antd 版本打包,会有兼容性问题

// import "antd/dist/antd.min.css";
import "@jimengio/jimo-antd-theme/lib/platform.min.css";

Dev

# install dependencies
yarn

# example
yarn example

# build package
yarn build

# sync less type (src)
yarn gen-type
# generated from local files
yarn gen-type local

# generate less files (lib)
yarn gen-less

# generate css files (example/lib)
yarn gen-css [compress, type, build]

# generate css file (for example)
yarn gen-css
# generate compressed css file (for example)
yarn gen-css compress
# generate typescript css string file (for example)
yarn gen-css type
# generate compressed css file (for lib)
yarn gen-css build

License

MIT

jimo-antd-theme's People

Contributors

wangcch avatar dependabot[bot] avatar xcrazylei avatar tiye avatar chenyong avatar

Watchers

astaxie avatar Fossil avatar James Cloos avatar arieslx avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.