Skip to content

Commit 25ad04f

Browse files
committed
feat(all): ready to publish
affects: @he-tree/dnd-utils, @he-tree/vue, @he-tree/tree-utils, sub-vue2
0 parents  commit 25ad04f

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

73 files changed

+22987
-0
lines changed

.gitignore

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
node_modules
2+
dist/
3+
4+
# yarn
5+
.yarn/*
6+
!.yarn/patches
7+
!.yarn/releases
8+
!.yarn/plugins
9+
!.yarn/sdks
10+
!.yarn/versions
11+
.pnp.*
12+
13+
# log
14+
*.log
15+
16+
# edtior
17+
.vscode

.pnpmfile.cjs

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
function readPackage(pkg, context) {
2+
// Override the manifest of [email protected] after downloading it from the registry
3+
if (pkg.name === "vue-template-compiler") {
4+
pkg.dependencies = {
5+
...pkg.dependencies,
6+
vue: pkg.version,
7+
};
8+
console.log("Force set dependence vue for vue-template-compiler.\n");
9+
}
10+
11+
return pkg;
12+
}
13+
14+
module.exports = {
15+
hooks: {
16+
readPackage,
17+
},
18+
};

.prettierignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
dist
2+
node_modules

lerna.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"packages": [
3+
"packages/*",
4+
"packages/he-tree-vue/sub-vue2"
5+
],
6+
"version": "independent"
7+
}

package.json

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{
2+
"name": "root",
3+
"private": true,
4+
"devDependencies": {
5+
"commitizen": "^4.1.2",
6+
"cz-lerna-changelog": "^2.0.2",
7+
"lerna": "^4.0.0"
8+
},
9+
"scripts": {
10+
"commit": "git-cz"
11+
},
12+
"config": {
13+
"commitizen": {
14+
"path": "./node_modules/cz-lerna-changelog"
15+
}
16+
}
17+
}

packages/dnd-utils/.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
.DS_Store
2+
node_modules/
3+
npm-debug.log
4+
dist/

packages/dnd-utils/LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2022 phphe
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

packages/dnd-utils/README.MD

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# one-drag

packages/dnd-utils/index.html

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8" />
5+
<link rel="icon" type="image/svg+xml" href="favicon.svg" />
6+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
7+
<title>Vite App</title>
8+
</head>
9+
<body>
10+
<div id="app"></div>
11+
<template id="template">
12+
<h1>one-darg example</h1>
13+
<div style="display: flex">
14+
<ol style="width: 200px" id="list">
15+
<li>Coffee</li>
16+
<li>Tea</li>
17+
<li>Milk</li>
18+
<li>Coffee</li>
19+
<li>Tea</li>
20+
<li>Milk</li>
21+
<li>Coffee</li>
22+
<li>Tea</li>
23+
<li>Milk</li>
24+
<li>Coffee</li>
25+
<li>Tea</li>
26+
<li>Milk</li>
27+
<li>Coffee</li>
28+
<li>Tea</li>
29+
<li>Milk</li>
30+
<li>Coffee</li>
31+
<li>Tea</li>
32+
<li>Milk</li>
33+
</ol>
34+
<div>
35+
<h3>Check test/main.ts for source</h3>
36+
<button onclick="initOnFirst()">init on first element</button><br />
37+
<button onclick="initOnRoot()">init on list root</button><br />
38+
<button onclick="initClone()">clone when drag</button><br />
39+
</div>
40+
<div style="width: 300px; height: 3000px; margin-left: 20px">
41+
<h3>Scrollable box for test edge scroll</h3>
42+
<div style="height: 300px; overflow: auto">
43+
<div style="width: 3000px; height: 3000px"></div>
44+
</div>
45+
</div>
46+
</div>
47+
</template>
48+
<script type="module" src="/test/main.ts"></script>
49+
</body>
50+
</html>

packages/dnd-utils/package.json

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
{
2+
"name": "@he-tree/dnd-utils",
3+
"version": "0.0.1",
4+
"description": "",
5+
"main": "dist/index.cjs.js",
6+
"module": "dist/index.esm.js",
7+
"types": "dist/index.d.ts",
8+
"jsdelivr": "dist/index.iife.js",
9+
"unpkg": "dist/index.iife.js",
10+
"files": [
11+
"dist",
12+
"src"
13+
],
14+
"scripts": {
15+
"dev": "vite",
16+
"build": "rogo",
17+
"watch": "rogo -w"
18+
},
19+
"author": "phphe <[email protected]> (https://github.com/phphe)",
20+
"devDependencies": {
21+
"rogo": "^3.1.4",
22+
"typescript": "^4",
23+
"vite": "^2.8.6"
24+
},
25+
"dependencies": {
26+
"@babel/runtime": "^7.7.7",
27+
"drag-event-service": "^2.0.0",
28+
"helper-js": "^3.1.2"
29+
},
30+
"license": "MIT"
31+
}

0 commit comments

Comments
 (0)