Giter Club home page Giter Club logo

vue2-mdl's Introduction

vue2-mdl

A set of Vue components for using the MDL CSS framework.

Requirements

For the moment MDL and the polyfill can/should be included directly in your root html, as can be seen in the usage section

Included components

  • Button, in various style variations
  • TextField, regular, expandable and multiline
  • Icon
  • Spacer
  • Layout, with vue-router slot by default
  • Header
  • Drawer, to go along with the layout
  • Navigation, with nav links
  • Menu, with menu actions and menu button
  • Grid, rows and cells
  • Card, with actions, media, menu, text and title

Usage

short version

import Vue2Mdl from 'vue2-mdl'
Vue.use(Vue2Mdl)

long version

<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <title>Your Application</title>
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/dialog-polyfill/0.4.4/dialog-polyfill.min.css">
    <link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">
    <link rel="stylesheet" href="https://code.getmdl.io/1.1.3/material.blue_grey-indigo.min.css" />
    <script defer type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/dialog-polyfill/0.4.4/dialog-polyfill.min.js"></script>
    <script defer src="https://code.getmdl.io/1.1.3/material.min.js"></script>
    <script defer src="your-built-app.js"></script>
  </head>
  <body>
    <div id="app"></div>
  </body>
</html>
import Vue from 'vue'
import VueRouter from 'vue-router'
import YourApp from './YourApp.vue'

// import components and make globally available
import Vue2Mdl from 'vue2-mdl'
Vue.use(Vue2Mdl)

// mount your application
const router = new VueRouter({
  // router options
})

const AppComponent = Vue.extend(YourApp)

new AppComponent({
  el: "#app",
  router
})

Components

Buttons

<mdl-button>Test Button</mdl-button>
<mdl-button fab icon="add"></mdl-button>
<mdl-button colored>Test Button</mdl-button>
<mdl-button colored accent>Test Button</mdl-button>

...

No more content as of yet.

vue2-mdl's People

Contributors

senritsu avatar

Watchers

James Cloos avatar Jon 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.