当前位置:   article > 正文

fluent design_实施Microsoft Fluent Design的Vue.js组件

fluent design vue

fluent design

u (Vuent)

Vuent is a set of reusable UI components for Vue created according to Microsoft Fluent Design, in particular its official variation about building Universal Windows Platform (UWP) applications.

Vuent是根据Microsoft Fluent Design创建的Vue的一组可重用UI组件,尤其是其有关构建通用Windows平台(UWP)应用程序的官方变体。

The project aims to help developers build web or UWP apps with Fluent's look'n'feel leveraging Vue as a framework for UI/view layer.

该项目旨在帮助开发人员以Fluent的外观来构建Web或UWP应用,并利用Vue作为UI /视图层的框架。

如何使用 (How to use)

快速开始 (Quickstart)

The following snippets can get you up and running with simple demo containing basic text field:

以下代码片段可帮助您启动并运行包含基本文本字段的简单演示:

  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8" />
  5. <title>Vuent Demo</title>
  6. <link href="https://unpkg.com/vuent/dist/vuent.css" type="text/css" rel="stylesheet" media="screen" />
  7. </head>
  8. <body>
  9. <div id="app">
  10. <p>{{ message }}</p>
  11. <vnt-input v-model="message" label="Text field"></vnt-input>
  12. <script src="https://unpkg.com/[email protected]/dist/vue.js"></script>
  13. <script src="https://unpkg.com/vuent/dist/vuent.umd.js"></script>
  14. <script src="main.js"></script>
  15. </div>
  16. </body>
  17. </html>
  1. // main.js
  2. var app = new Vue({
  3. el: '#app',
  4. data: {
  5. message: 'Hello Vuent!'
  6. }
  7. });

npm /纱线 (npm / Yarn)

Go to your project's directory and run in terminal:

转到项目的目录并在终端中运行:

npm install vuent --save # OR yarn add vuent

Once Vuent is installed in your project, somewhere in your JavaScript code use it as follows:

一旦在项目中安装了Vuent,就可以在JavaScript代码中的某处使用它,如下所示:

  1. import Vue from 'vue';
  2. import Vuent from 'vuent';
  3. Vue.use(Vuent);

翻译自: https://vuejsexamples.com/vue-js-components-implementing-microsoft-fluent-design/

fluent design

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/菜鸟追梦旅行/article/detail/179451
推荐阅读
相关标签
  

闽ICP备14008679号