first commit

This commit is contained in:
编码猿
2024-09-27 00:57:27 +08:00
commit 18df0f5e4b
2548 changed files with 253280 additions and 0 deletions

32
dbui/.babelrc Normal file
View File

@@ -0,0 +1,32 @@
{
"presets": [
["env", {
"loose": false,
"modules": "commonjs",
"spec": true,
"targets": {
"browsers": [
"last 3 Chrome versions",
"last 3 Firefox versions",
"Safari >= 10",
"Explorer >= 11",
"Edge >= 12",
"iOS >= 10",
"Android >= 6"
]
},
"useBuiltIns": "usage",
"debug": false
}],
"stage-3"
],
"plugins": [
"dynamic-import-node",
"transform-class-properties",
"transform-es5-property-mutators",
"transform-object-rest-spread",
"transform-runtime",
"transform-vue-jsx"
],
"comments": false
}

22
dbui/.gitignore vendored Normal file
View File

@@ -0,0 +1,22 @@
*.iml
.idea
.ipr
.iws
*.diff
*.patch
*.bak
.DS_Store
node_modules/
node_modules2/
.project
.settings
npm-debug.log
.*proj
.svn/
*.swp
*.swo
*.log
examples/dist/
yarn-error.log
.vscode
package-lock.json

1
dbui/.pydio Normal file
View File

@@ -0,0 +1 @@
383258f4-e361-4295-b100-171b16311403

201
dbui/LICENSE Normal file
View File

@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

3
dbui/README.md Normal file
View File

@@ -0,0 +1,3 @@
## DBui-Vue
基于Vue3 + Typescript 写的Vue UI框架

1
dbui/build/.pydio Normal file
View File

@@ -0,0 +1 @@
27cdb2bf-a1ee-4d5e-9e7a-7d1b598078da

View File

@@ -0,0 +1,108 @@
/**
* 公共配置
*/
const path = require('path');
const webpack = require('webpack');
const pkg = require('../package.json');
const VueLoaderPlugin = require('vue-loader/lib/plugin')
function resolve (dir) {
return path.join(__dirname, '..', dir);
}
module.exports = {
// 加载器
module: {
// https://doc.webpack-china.org/guides/migrating/#module-loaders-module-rules
rules: [
{
// https://vue-loader.vuejs.org/en/configurations/extract-css.html
test: /\.vue$/,
loader: 'vue-loader',
options: {
loaders: {
css: [
'vue-style-loader',
{
loader: 'css-loader',
options: {
sourceMap: true,
},
},
],
less: [
'vue-style-loader',
{
loader: 'css-loader',
options: {
sourceMap: true,
},
},
{
loader: 'less-loader',
options: {
sourceMap: true,
},
},
],
},
postLoaders: {
html: 'babel-loader?sourceMap'
},
sourceMap: true,
}
},
{
test: /\.js$/,
loader: 'babel-loader',
options: {
sourceMap: true,
},
exclude: /node_modules/,
},
{
test: /\.ts$/,
loader: 'ts-loader',
options: { appendTsSuffixTo: [/\.vue$/]},
exclude: /node_modules/
},
{
test: /\.css$/,
use: [
'vue-style-loader',
'css-loader'
]
},
{
test: /\.less$/,
use: [
'vue-style-loader',
'css-loader',
'less-loader'
]
},
{
test: /\.(gif|jpg|png|woff|svg|eot|ttf)\??.*$/,
loader: 'url-loader?limit=8192'
},
{
test: /\.(html|tpl)$/,
loader: 'html-loader'
}
]
},
resolve: {
extensions: ['.js', '.vue', '.ts'],
alias: {
'vue': 'vue/dist/vue.esm.js',
'@': resolve('src')
}
},
plugins: [
new VueLoaderPlugin(),
new webpack.optimize.ModuleConcatenationPlugin(),
new webpack.DefinePlugin({
'process.env.VERSION': `'${pkg.version}'`
}),
]
};

View File

@@ -0,0 +1,48 @@
/**
* 本地预览
*/
const path = require('path');
const webpack = require('webpack');
// const ExtractTextPlugin = require('extract-text-webpack-plugin');
const HtmlWebpackPlugin = require('html-webpack-plugin');
const merge = require('webpack-merge');
const webpackBaseConfig = require('./webpack.base.config.js');
const FriendlyErrorsPlugin = require('friendly-errors-webpack-plugin');
module.exports = merge(webpackBaseConfig, {
devtool: 'eval-source-map',
// 入口
entry: {
main: './examples/main.ts',
vendors: ['vue', 'vue-router']
},
// 输出
output: {
path: path.join(__dirname, '../examples/dist'),
publicPath: '',
filename: '[name].js',
chunkFilename: '[name].chunk.js'
},
resolve: {
alias: {
vue: 'vue/dist/vue.esm.js'
}
},
optimization: {
splitChunks: {
chunks: 'all',
name:'vendor'
}
},
plugins: [
new HtmlWebpackPlugin({
inject: true,
filename: path.join(__dirname, '../examples/dist/index.html'),
template: path.join(__dirname, '../examples/index.html')
}),
new FriendlyErrorsPlugin()
]
});

View File

@@ -0,0 +1,48 @@
const path = require('path');
const webpack = require('webpack');
const merge = require('webpack-merge');
const webpackBaseConfig = require('./webpack.base.config.js');
const CompressionPlugin = require('compression-webpack-plugin');
const UglifyJsPlugin = require('uglifyjs-webpack-plugin');
process.env.NODE_ENV = 'production';
module.exports = merge(webpackBaseConfig, {
devtool: 'source-map',
entry: {
main: './src/index.js'
},
output: {
path: path.resolve(__dirname, '../dist'),
publicPath: '/dist/',
filename: 'dbui.min.js',
library: 'dbui',
libraryTarget: 'umd',
umdNamedDefine: true
},
externals: {
vue: {
root: 'Vue',
commonjs: 'vue',
commonjs2: 'vue',
amd: 'vue'
}
},
plugins: [
// @todo
new webpack.DefinePlugin({
'process.env.NODE_ENV': '"production"'
}),
new UglifyJsPlugin({
parallel: true,
sourceMap: true
}),
new CompressionPlugin({
filename: '[path].gz[query]',
algorithm: 'gzip',
test: /\.(js|css)$/,
threshold: 10240,
minRatio: 0.8
})
]
});

1
dbui/dist/.pydio vendored Normal file
View File

@@ -0,0 +1 @@
2d94005e-d772-4f7a-8455-999f35be7c87

17
dbui/dist/dbui.min.js vendored Normal file

File diff suppressed because one or more lines are too long

BIN
dbui/dist/dbui.min.js.gz vendored Normal file

Binary file not shown.

1
dbui/dist/dbui.min.js.map vendored Normal file

File diff suppressed because one or more lines are too long

1
dbui/examples/.pydio Normal file
View File

@@ -0,0 +1 @@
154e13d6-d6bb-4f8a-bd25-10bc67af4e59

20
dbui/examples/App.vue Normal file
View File

@@ -0,0 +1,20 @@
<template>
<div id="app">
<div id="nav">
<h2>App.vue</h2>
<router-link to="/">Home</router-link> |
<router-link to="/about">About</router-link>
</div>
<router-view/>
</div>
</template>
<script lang="ts">
export default {
name: 'App'
}
</script>
<style lang="less">
@import "../src/styles/index.less";
</style>

View File

@@ -0,0 +1 @@
7554f392-f21f-47ac-a4e0-eac2b183a954

16
dbui/examples/index.html Normal file
View File

@@ -0,0 +1,16 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<title>demo案例</title>
</head>
<body>
<noscript>
<strong>We're sorry but <%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript enabled. Please enable it to continue.</strong>
</noscript>
<div class="app"></div>
<!-- built files will be auto injected -->
</body>
</html>

20
dbui/examples/main.ts Normal file
View File

@@ -0,0 +1,20 @@
import Vue from 'vue';
import App from './App.vue';
import router from './router';
// 导入正在编写的UI框架
import Dbui from './../src';
// Vue3 CompositionApi
import VueCompositionApi from '@vue/composition-api';
Vue.use(Dbui);
Vue.use(VueCompositionApi);
Vue.config.productionTip = false;
new Vue({
router,
render: h => h(App)
}).$mount('.app')

View File

@@ -0,0 +1 @@
47a9a44f-42ce-4a96-9c9a-a3652874ef9e

View File

@@ -0,0 +1,21 @@
<template>
<div class="home">
<h2>{{ title }}</h2>
</div>
</template>
<script lang="ts">
import { onMounted, toRefs, reactive, computed } from '@vue/composition-api'
export default {
setup(props: any) {
const state = reactive({
title: '关于我'
});
return {
...toRefs(state)
}
}
}
</script>

View File

@@ -0,0 +1,23 @@
<template>
<div class="home">
<h2>{{ title }}</h2>
<db-list :Demos="[1,2,3,4,5,6]"></db-list>
<db-buttons></db-buttons>
</div>
</template>
<script lang="ts">
import { onMounted, toRefs, reactive, computed } from '@vue/composition-api'
export default {
setup(props: any) {
const state = reactive({
title: '首页'
});
return {
...toRefs(state)
}
}
}
</script>

View File

@@ -0,0 +1 @@
5142dc80-d25e-496c-93a2-7fd1e5ceafca

View File

@@ -0,0 +1,24 @@
import Vue from 'vue'
import VueRouter from 'vue-router'
Vue.use(VueRouter)
const routes = [
{
path: '/',
name: 'Home',
component: () => import(/* webpackChunkName: "Home" */ '../page/Home.vue')
},
{
path: '/about',
name: 'About',
component: () => import(/* webpackChunkName: "About" */ '../page/About.vue')
}
];
const router = new VueRouter({
mode: 'history',
routes
});
export default router

57
dbui/package.json Normal file
View File

@@ -0,0 +1,57 @@
{
"name": "dbui",
"version": "1.0.0",
"description": "",
"main": "dist/dbui.min.js",
"typings": "types/index.d.ts",
"scripts": {
"dev": "webpack-dev-server --open --inline --hot --compress --history-api-fallback --port 8081 --config build/webpack.dev.config.js",
"prod": "webpack --config build/webpack.dist.prod.config.js --mode production"
},
"keywords": [],
"author": "",
"license": "ISC",
"dependencies": {
"@vue/composition-api": "^0.3.4",
"vue": "^2.6.11",
"vue-class-component": "^7.2.2",
"vue-property-decorator": "^8.4.0",
"vue-router": "^3.1.5"
},
"devDependencies": {
"babel-cli": "^6.26.0",
"babel-core": "^6.26.0",
"babel-helper-vue-jsx-merge-props": "^2.0.3",
"babel-loader": "^7.1.5",
"babel-plugin-dynamic-import-node": "^1.2.0",
"babel-plugin-syntax-jsx": "^6.18.0",
"babel-plugin-transform-class-properties": "^6.24.1",
"babel-plugin-transform-es5-property-mutators": "^6.24.1",
"babel-plugin-transform-object-rest-spread": "^6.26.0",
"babel-plugin-transform-runtime": "^6.23.0",
"babel-plugin-transform-vue-jsx": "^3.7.0",
"babel-preset-env": "^1.6.1",
"babel-preset-stage-3": "^6.24.1",
"babel-runtime": "^6.26.0",
"compression-webpack-plugin": "^3.1.0",
"css-loader": "^3.4.2",
"friendly-errors-webpack-plugin": "^1.7.0",
"html-loader": "^0.5.5",
"html-webpack-plugin": "^3.2.0",
"less": "^3.11.0",
"less-loader": "^5.0.0",
"style-loader": "^1.1.3",
"ts-loader": "^6.2.1",
"typescript": "^3.7.5",
"uglifyjs-webpack-plugin": "^2.2.0",
"url-loader": "^3.0.0",
"vue-html-loader": "^1.2.4",
"vue-loader": "^15.8.3",
"vue-style-loader": "^4.1.2",
"vue-template-compiler": "^2.6.11",
"webpack": "^4.41.5",
"webpack-cli": "^3.3.10",
"webpack-dev-server": "^3.10.3",
"webpack-merge": "^4.2.2"
}
}

4
dbui/shims-vue.d.ts vendored Normal file
View File

@@ -0,0 +1,4 @@
declare module '*.vue' {
import Vue from 'vue';
export default Vue;
}

1
dbui/src/.pydio Normal file
View File

@@ -0,0 +1 @@
1111167e-d835-4bcb-9d23-9089feeeb73e

View File

@@ -0,0 +1 @@
1b4a0a61-b747-47d6-a981-f33346867abd

View File

@@ -0,0 +1 @@
2c931ee0-6442-413d-8ead-85ec0c2ad0ba

View File

@@ -0,0 +1,27 @@
<template>
<div class="db-button">
<button>button 按钮组件</button>
</div>
</template>
<script lang="ts">
import { toRefs, Ref, ref, reactive, PropOptions } from '@vue/composition-api'
import { UnwrapRef} from '@vue/composition-api/dist/reactivity'
export default {
name: 'buttons',
props: {
},
setup(props: PropOptions) {
const state: UnwrapRef<{
title: Ref<string>
}> = reactive({
title: ref('ui框架组件 - button')
});
return {
...toRefs(state)
}
}
}
</script>

View File

@@ -0,0 +1,2 @@
import Button from "./button.vue";
export default Button;

View File

@@ -0,0 +1 @@
3cf06485-1939-4912-b71f-f9f9a45c8969

View File

@@ -0,0 +1,2 @@
import List from './list.vue';
export default List;

View File

@@ -0,0 +1,34 @@
<template>
<div class="home">
<h2>{{ title }}</h2>
<ul>
<li v-for="(item,index) in Demos" :key="index">{{ item }}</li>
</ul>
</div>
</template>
<script lang="ts">
import { toRefs, Ref, ref, reactive, PropOptions } from '@vue/composition-api'
import { UnwrapRef} from '@vue/composition-api/dist/reactivity'
export default {
name: 'list',
props: {
Demos: {
type: Array,
default: []
}
},
setup(props: PropOptions) {
const state: UnwrapRef<{
title: Ref<string>
}> = reactive({
title: ref('ui框架组件 - List : ')
});
return {
...toRefs(state)
}
}
}
</script>

1
dbui/src/config/.pydio Normal file
View File

@@ -0,0 +1 @@
b5e0166f-3002-466a-95b7-f10cb0889549

4
dbui/src/config/index.ts Normal file
View File

@@ -0,0 +1,4 @@
export class Config {
// 所有class前缀
public static domPrefix: string = 'db-';
}

48
dbui/src/index.ts Normal file
View File

@@ -0,0 +1,48 @@
import Vue, { VueConstructor, PluginObject, PluginFunction } from 'vue';
import { Config } from './config';
import List from './components/list';
import Button from './components/button';
export class Init {
/**
* 框架中所有UI组件
*/
public DbUiComponents: Array<VueConstructor<Vue>> = [
List, Button
];
/**
* Vue.use 入口在install中实现循环注册
*/
public UIComponents!: PluginObject<Vue>;
/**
* 批量注册Vue组件
* @constructor
*/
public InstallVueConstructor (): PluginObject<Vue> {
this.UIComponents = {
install: <PluginFunction>(Vue: VueConstructor<Vue>, options: object | undefined) => {
this.DbUiComponents.forEach((key: VueConstructor<Vue>, _index: number, _arr: VueConstructor<Vue>[]) => {
Vue.component(`${Config.domPrefix}${key.name}`, key);
});
}
};
this.AutoInstall();
return this.UIComponents;
}
/**
* 挂载Vue到windows上
* @constructor
*/
public AutoInstall(): void{
if (typeof window !== 'undefined' && window.Vue) {
this.UIComponents.install(window.Vue);
}
}
}
export default (new Init).InstallVueConstructor();

1
dbui/src/styles/.pydio Normal file
View File

@@ -0,0 +1 @@
e31f46b4-4528-4262-9e14-eee38529996e

View File

@@ -0,0 +1 @@
0ee3c174-bee0-42b2-8513-a28274bd0fcb

View File

View File

@@ -0,0 +1 @@
@import "base";

View File

@@ -0,0 +1,2 @@
@import "light";
@import "dart";

View File

@@ -0,0 +1 @@
@import "base";

View File

@@ -0,0 +1 @@
10dba2d1-7cd4-4cda-8a9f-e0c051ec86b4

View File

@@ -0,0 +1 @@
@import "normalize";

462
dbui/src/styles/common/normalize.less vendored Normal file
View File

@@ -0,0 +1,462 @@
/*! normalize.css v5.0.0 | MIT License | github.com/necolas/normalize.css */
/**
* 1. Change the default font family in all browsers (opinionated).
* 2. Correct the line height in all browsers.
* 3. Prevent adjustments of font size after orientation changes in
* IE on Windows Phone and in iOS.
*/
/* Document
========================================================================== */
html {
font-family: sans-serif; /* 1 */
line-height: 1.15; /* 2 */
-ms-text-size-adjust: 100%; /* 3 */
-webkit-text-size-adjust: 100%; /* 3 */
}
/* Sections
========================================================================== */
/**
* Remove the margin in all browsers (opinionated).
*/
body {
margin: 0;
}
/**
* Add the correct display in IE 9-.
*/
article,
aside,
footer,
header,
nav,
section {
display: block;
}
/**
* Correct the font size and margin on `h1` elements within `section` and
* `article` contexts in Chrome, Firefox, and Safari.
*/
h1 {
font-size: 2em;
margin: 0.67em 0;
}
/* Grouping content
========================================================================== */
/**
* Add the correct display in IE 9-.
* 1. Add the correct display in IE.
*/
figcaption,
figure,
main { /* 1 */
display: block;
}
/**
* Add the correct margin in IE 8.
*/
figure {
margin: 1em 40px;
}
/**
* 1. Add the correct box sizing in Firefox.
* 2. Show the overflow in Edge and IE.
*/
hr {
box-sizing: content-box; /* 1 */
height: 0; /* 1 */
overflow: visible; /* 2 */
}
/**
* 1. Correct the inheritance and scaling of font size in all browsers.
* 2. Correct the odd `em` font sizing in all browsers.
*/
pre {
font-family: monospace, monospace; /* 1 */
font-size: 1em; /* 2 */
}
/* Text-level semantics
========================================================================== */
/**
* 1. Remove the gray background on active links in IE 10.
* 2. Remove gaps in links underline in iOS 8+ and Safari 8+.
*/
a {
background-color: transparent; /* 1 */
-webkit-text-decoration-skip: objects; /* 2 */
}
/**
* Remove the outline on focused links when they are also active or hovered
* in all browsers (opinionated).
*/
a:active,
a:hover {
outline-width: 0;
}
/**
* 1. Remove the bottom border in Firefox 39-.
* 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.
*/
abbr[title] {
border-bottom: none; /* 1 */
text-decoration: underline; /* 2 */
text-decoration: underline dotted; /* 2 */
}
/**
* Prevent the duplicate application of `bolder` by the next rule in Safari 6.
*/
b,
strong {
font-weight: inherit;
}
/**
* Add the correct font weight in Chrome, Edge, and Safari.
*/
b,
strong {
font-weight: bolder;
}
/**
* 1. Correct the inheritance and scaling of font size in all browsers.
* 2. Correct the odd `em` font sizing in all browsers.
*/
code,
kbd,
samp {
font-family: monospace, monospace; /* 1 */
font-size: 1em; /* 2 */
}
/**
* Add the correct font style in Android 4.3-.
*/
dfn {
font-style: italic;
}
/**
* Add the correct background and color in IE 9-.
*/
mark {
background-color: #ff0;
color: #000;
}
/**
* Add the correct font size in all browsers.
*/
small {
font-size: 80%;
}
/**
* Prevent `sub` and `sup` elements from affecting the line height in
* all browsers.
*/
sub,
sup {
font-size: 75%;
line-height: 0;
position: relative;
vertical-align: baseline;
}
sub {
bottom: -0.25em;
}
sup {
top: -0.5em;
}
/* Embedded content
========================================================================== */
/**
* Add the correct display in IE 9-.
*/
audio,
video {
display: inline-block;
}
/**
* Add the correct display in iOS 4-7.
*/
audio:not([controls]) {
display: none;
height: 0;
}
/**
* Remove the border on images inside links in IE 10-.
*/
img {
border-style: none;
}
/**
* Hide the overflow in IE.
*/
svg:not(:root) {
overflow: hidden;
}
/* Forms
========================================================================== */
/**
* 1. Change the font styles in all browsers (opinionated).
* 2. Remove the margin in Firefox and Safari.
*/
button,
input,
optgroup,
select,
textarea {
font-family: sans-serif; /* 1 */
font-size: 100%; /* 1 */
line-height: 1.15; /* 1 */
margin: 0; /* 2 */
}
/**
* Show the overflow in IE.
* 1. Show the overflow in Edge.
*/
button,
input { /* 1 */
overflow: visible;
}
/**
* Remove the inheritance of text transform in Edge, Firefox, and IE.
* 1. Remove the inheritance of text transform in Firefox.
*/
button,
select { /* 1 */
text-transform: none;
}
/**
* 1. Prevent a WebKit bug where (2) destroys native `audio` and `video`
* controls in Android 4.
* 2. Correct the inability to style clickable types in iOS and Safari.
*/
button,
html [type="button"], /* 1 */
[type="reset"],
[type="submit"] {
-webkit-appearance: button; /* 2 */
}
/**
* Remove the inner border and padding in Firefox.
*/
button::-moz-focus-inner,
[type="button"]::-moz-focus-inner,
[type="reset"]::-moz-focus-inner,
[type="submit"]::-moz-focus-inner {
border-style: none;
padding: 0;
}
/**
* Restore the focus styles unset by the previous rule.
*/
button:-moz-focusring,
[type="button"]:-moz-focusring,
[type="reset"]:-moz-focusring,
[type="submit"]:-moz-focusring {
outline: 1px dotted ButtonText;
}
/**
* Change the border, margin, and padding in all browsers (opinionated).
*/
fieldset {
border: 1px solid #c0c0c0;
margin: 0 2px;
padding: 0.35em 0.625em 0.75em;
}
/**
* 1. Correct the text wrapping in Edge and IE.
* 2. Correct the color inheritance from `fieldset` elements in IE.
* 3. Remove the padding so developers are not caught out when they zero out
* `fieldset` elements in all browsers.
*/
legend {
box-sizing: border-box; /* 1 */
color: inherit; /* 2 */
display: table; /* 1 */
max-width: 100%; /* 1 */
padding: 0; /* 3 */
white-space: normal; /* 1 */
}
/**
* 1. Add the correct display in IE 9-.
* 2. Add the correct vertical alignment in Chrome, Firefox, and Opera.
*/
progress {
display: inline-block; /* 1 */
vertical-align: baseline; /* 2 */
}
/**
* Remove the default vertical scrollbar in IE.
*/
textarea {
overflow: auto;
resize: vertical;
}
/**
* 1. Add the correct box sizing in IE 10-.
* 2. Remove the padding in IE 10-.
*/
[type="checkbox"],
[type="radio"] {
box-sizing: border-box; /* 1 */
padding: 0; /* 2 */
}
/**
* Correct the cursor style of increment and decrement buttons in Chrome.
*/
[type="number"]::-webkit-inner-spin-button,
[type="number"]::-webkit-outer-spin-button {
height: auto;
}
/**
* 1. Correct the odd appearance in Chrome and Safari.
* 2. Correct the outline style in Safari.
*/
[type="search"] {
-webkit-appearance: textfield; /* 1 */
outline-offset: -2px; /* 2 */
}
/**
* Remove the inner padding and cancel buttons in Chrome and Safari on macOS.
*/
[type="search"]::-webkit-search-cancel-button,
[type="search"]::-webkit-search-decoration {
-webkit-appearance: none;
}
/**
* 1. Correct the inability to style clickable types in iOS and Safari.
* 2. Change font properties to `inherit` in Safari.
*/
::-webkit-file-upload-button {
-webkit-appearance: button; /* 1 */
font: inherit; /* 2 */
}
/* Interactive
========================================================================== */
/*
* Add the correct display in IE 9-.
* 1. Add the correct display in Edge, IE, and Firefox.
*/
details, /* 1 */
menu {
display: block;
}
/*
* Add the correct display in all browsers.
*/
summary {
display: list-item;
}
/* Scripting
========================================================================== */
/**
* Add the correct display in IE 9-.
*/
canvas {
display: inline-block;
}
/**
* Add the correct display in IE.
*/
template {
display: none;
}
/* Hidden
========================================================================== */
/**
* Add the correct display in IE 10-.
*/
[hidden] {
display: none;
}

View File

@@ -0,0 +1 @@
56f654dd-b50e-444b-ba71-7a8a0c9a816b

View File

View File

@@ -0,0 +1,2 @@
@import "list";
@import "button";

View File

View File

@@ -0,0 +1,8 @@
// ui组件样式
@import "components/index";
// 公共函数样式
@import "common/index";
// 基础颜色样式
@import "color/index";

View File

@@ -0,0 +1 @@
6c4c88fe-a929-4a87-bc3c-15ef45848bb4

1
dbui/test/.pydio Normal file
View File

@@ -0,0 +1 @@
5685b3e4-d0a9-4ebc-9e4b-efb968cd5fba

29
dbui/test/index.html Normal file
View File

@@ -0,0 +1,29 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Title</title>
<script src="https://cdn.jsdelivr.net/npm/vue"></script>
<script type="text/javascript" src="../dist/dbui.min.js"></script>
</head>
<body>
<div id="app">
<db-list :Demos="'打包后测试dbui.min.js'"></db-list>
{{ message }}
</div>
<script>
var app = new Vue({
el: '#app',
data: {
message: 'Hello Vue!'
}
})
</script>
</body>
</html>

36
dbui/tsconfig.json Normal file
View File

@@ -0,0 +1,36 @@
{
"compilerOptions": {
"target": "es5",
"module": "esnext",
"strict": true,
"jsx": "preserve",
"importHelpers": true,
"moduleResolution": "node",
"experimentalDecorators": true,
"emitDecoratorMetadata": true,
"esModuleInterop": true,
"allowSyntheticDefaultImports": true,
"sourceMap": true,
"baseUrl": ".",
"paths": {
"@/*": ["src/*"]
},
"lib": [
"esnext",
"dom",
"dom.iterable",
"scripthost"
]
},
"include": [
"types/*.ts",
"src/**/*.ts",
"src/**/*.tsx",
"src/**/*.vue",
"examples/**/*.vue",
"examples/**/*.ts"
],
"exclude": [
"node_modules"
]
}

1
dbui/types/.pydio Normal file
View File

@@ -0,0 +1 @@
64c4fffe-e3df-4ab4-bc17-ab130374231f

4
dbui/types/shims-vue.d.ts vendored Normal file
View File

@@ -0,0 +1,4 @@
declare module "*.vue" {
import Vue from "vue";
export default Vue;
}