weui-wxss README

The project's README from github.com/Tencent/weui-wxss. As one markdown file: README.md.

WeUI for 小程序 为微信小程序量身设计

npm version Gitter

概述

WeUI 是一套同微信原生视觉体验一致的基础样式库,由微信官方设计团队为微信内网页和微信小程序量身设计,令用户的使用感知更加统一。包含button、cell、dialog、 progress、 toast、article、actionsheet、icon等各式元素。

以下内容是纯UI库,如果想使用逻辑封装版本,请看小程序组件库 - WeUI

使用

rpx版本

默认版本使用的是px。这里也提供rpx版本,文件在dist-rpx-mode目录下。

WeUI 黑暗模式

在根结点增加属性 data-weui-theme="dark" 如:

<view data-weui-theme="dark">
    ...
</view>

预览

用微信web开发者工具打开dist目录(请注意,是dist目录,不是整个项目)

preview

WeUI for 小程序

文档

WeUI 视觉标准参考 weui-design

License

The MIT License(http://opensource.org/licenses/MIT)

请自由地享受和参与开源

贡献

如果你有好的意见或建议,欢迎给我们提issue或pull request。

weui-wxss (Tencent/weui-wxss)

Searching Database…

15.3K ·GitHub
What is this?WeUI for Mini Programs is a basic WXSS/CSS style library that matches WeChat's native visual look, designed by WeChat's own design team for WeChat web pages and Mini Programs.
Is this a UI toolkit with logic, or just styles?It is a pure CSS/WXSS style library with no JS behavior — if you want ready-made interactive components with logic baked in, the README points you to the separate WeUI Mini Program component library instead.
How do I add it to a Mini Program project?Reference dist/style/weui.wxss directly, or import just the widgets you need from dist/style/widget; matching wxml markup examples for each component live in dist/example.
Are there different unit versions I should know about?The default build uses px units. If your Mini Program needs the scalable rpx unit instead, there's a separate pre-built version in the dist-rpx-mode directory.
What widgets does WeUI include?Button, cell, dialog, progress, toast, article, actionsheet and icon, among other common Mini Program UI elements.
How do I preview the components?Open the dist directory (not the whole repo) in WeChat's web developer tool to see the styled components in action.
How do I enable dark mode?Add the attribute data-weui-theme='dark' to the root node of your page to switch WeUI into its dark theme.
Where can I see the visual design rules behind these styles?The weui-design reference documents the WeUI visual standards that this style library implements.
Creator
Tencent
Size
2.6 MB
Stars
15.3K
Age
9y
Commits · 90 Days