Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
nookery committed Oct 21, 2024
0 parents commit 46eb08e
Show file tree
Hide file tree
Showing 3,284 changed files with 1,448,603 additions and 0 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Auto detect text files and perform LF normalization
* text=auto
7 changes: 7 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
version: 2
updates:
- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "daily"

26 changes: 26 additions & 0 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: 📦 Publish to npm

on:
workflow_run:
workflows:
- 'Release'
types:
- completed

jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '18'
registry-url: 'https://registry.npmjs.org'
- run: npm -v
- run: npm install -g pnpm
- run: pnpm install
- run: npm run build
- run: ls -la dist
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
113 changes: 113 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
---
name: 🎉 Release

on:
push:
branches: [main]
tags:
- '*'

permissions:
contents: write

env:
tag: ${{ github.event.head_commit.id }}

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: 当前用户
run: whoami
- name: Checkout
uses: actions/checkout@v4
- name: NPM 版本
run: npm -v
- name: 安装PNPM
run: npm i -g pnpm
- name: NPM 安装
run: pnpm i
- name: NPM 构建
run: npm run build
- name: 上传构件
uses: actions/upload-artifact@v4
with:
name: dist
path: dist
retention-days: 1

tag:
needs: [build]
runs-on: ubuntu-latest
steps:
- name: 当前用户
run: whoami
- uses: actions/checkout@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
- name: 生成标签
run: |
git config --global user.name "GitHub Action"
git config --global user.email "[email protected]"
npm version patch -m "👷 CI: Upgrade to v%s"
git push origin main --tags
- name: 读取版本,写入文件
run: |
version=$(node -p "require('./package.json').version")
echo $version
echo "${version}" >> version.txt
- name: 上传构件
uses: actions/upload-artifact@v4
with:
name: version
path: version.txt
retention-days: 1

release:
runs-on: ubuntu-latest
needs: [tag]
steps:
- uses: actions/checkout@v4
- name: 下载版本构件
uses: actions/download-artifact@v4
with:
name: version
path: temp
- run: ls -alhR
- name: 读取版本号
run: |
version=$(cat temp/version.txt)
echo $version
# 写入环境变量
echo "tag=v$version" >> $GITHUB_ENV
- uses: softprops/action-gh-release@v1
with:
tag_name: ${{ env.tag }}
files: |
./**/*.dmg
./**/*.zip
./**/*.exe
./**/*.pkg
./**/*.deb
./**/*.ipa
./**/*.AppImage
./**/*.snap
clear:
needs:
- release
runs-on: ubuntu-latest
permissions:
actions: write
steps:
- name: 当前用户
run: whoami
- name: 清理构件
uses: geekyeggo/delete-artifact@v4
with:
token: ${{ github.token }}
name: |
dist
version
24 changes: 24 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*

node_modules
dist
dist-ssr
*.local

# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
.DS_Store
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?
37 changes: 37 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# @juice-editor/draw

JuiceEditor 是一个功能强大的编辑器,现已支持画图功能。以下是如何使用该功能的指南。

## 功能特性

- **画图功能**: 允许用户在编辑器中创建和编辑图形。
- **用户友好界面**: 提供直观的工具栏和快捷键。
- **多种图形支持**: 支持矩形、圆形、线条等基本图形。

## 安装

1. 安装包:

```bash
npm i @juice-editor/draw
```

2. 复制构件到项目目录:

```bash
cp -r node_modules/@juice-editor/draw/dist ./public/draw
```

3. 配置编辑器:

```typescript
window.api.setDrawURL('http://localhost:5173/draw')
```

## 贡献

欢迎贡献代码!请提交 Pull Request 或报告问题。

## 许可证

本项目采用 MIT 许可证。
52 changes: 52 additions & 0 deletions drawio/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
bin
# build
classes
node_modules
.vscode/settings.json
src/main/webapp/WEB-INF/lib/animal-sniffer-annotations-*.jar
src/main/webapp/WEB-INF/lib/annotations-*.jar
src/main/webapp/WEB-INF/lib/api-common-*.jar
src/main/webapp/WEB-INF/lib/auto-value-annotations-*.jar
src/main/webapp/WEB-INF/lib/bcpkix-jdk15on-*.jar
src/main/webapp/WEB-INF/lib/bcprov-jdk15on-*.jar
src/main/webapp/WEB-INF/lib/checker-qual-*.jar
src/main/webapp/WEB-INF/lib/conscrypt-openjdk-uber-*.jar
src/main/webapp/WEB-INF/lib/error_prone_annotations-*.jar
src/main/webapp/WEB-INF/lib/failureaccess-*.jar
src/main/webapp/WEB-INF/lib/gax-*.jar
src/main/webapp/WEB-INF/lib/gax-grpc-*.jar
src/main/webapp/WEB-INF/lib/google-auth-library-credentials-*.jar
src/main/webapp/WEB-INF/lib/google-auth-library-oauth2-http-*.jar
src/main/webapp/WEB-INF/lib/google-cloud-secretmanager-*.jar
src/main/webapp/WEB-INF/lib/google-http-client-*.jar
src/main/webapp/WEB-INF/lib/google-http-client-gson-*.jar
src/main/webapp/WEB-INF/lib/grpc-alts-*.jar
src/main/webapp/WEB-INF/lib/grpc-api-*.jar
src/main/webapp/WEB-INF/lib/grpc-auth-*.jar
src/main/webapp/WEB-INF/lib/grpc-context-*.jar
src/main/webapp/WEB-INF/lib/grpc-core-*.jar
src/main/webapp/WEB-INF/lib/grpc-grpclb-*.jar
src/main/webapp/WEB-INF/lib/grpc-netty-shaded-*.jar
src/main/webapp/WEB-INF/lib/grpc-protobuf-*.jar
src/main/webapp/WEB-INF/lib/grpc-protobuf-lite-*.jar
src/main/webapp/WEB-INF/lib/grpc-services-*.jar
src/main/webapp/WEB-INF/lib/grpc-stub-*.jar
src/main/webapp/WEB-INF/lib/grpc-xds-*.jar
src/main/webapp/WEB-INF/lib/guava-*-jre.jar
src/main/webapp/WEB-INF/lib/httpcore-*.jar
src/main/webapp/WEB-INF/lib/j2objc-annotations-*.jar
src/main/webapp/WEB-INF/lib/javax.annotation-api-*.jar
src/main/webapp/WEB-INF/lib/jsr305-*.jar
src/main/webapp/WEB-INF/lib/listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar
src/main/webapp/WEB-INF/lib/opencensus-api-*.jar
src/main/webapp/WEB-INF/lib/opencensus-contrib-http-util-*.jar
src/main/webapp/WEB-INF/lib/opencensus-proto-*.jar
src/main/webapp/WEB-INF/lib/perfmark-api-*.jar
src/main/webapp/WEB-INF/lib/proto-google-cloud-secretmanager-v1-*.jar
src/main/webapp/WEB-INF/lib/proto-google-cloud-secretmanager-v1beta1-*.jar
src/main/webapp/WEB-INF/lib/proto-google-common-protos-*.jar
src/main/webapp/WEB-INF/lib/proto-google-iam-v1-*.jar
src/main/webapp/WEB-INF/lib/protobuf-java-*.jar
src/main/webapp/WEB-INF/lib/protobuf-java-util-*.jar
src/main/webapp/WEB-INF/lib/re2j-*.jar
src/main/webapp/WEB-INF/lib/threetenbp-*.jar
1 change: 1 addition & 0 deletions drawio/VERSION
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
24.7.5
13 changes: 13 additions & 0 deletions drawio/webapp/CITATION.cff
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
cff-version: 1.2.0
message: "To cite draw.io in publications please use:"
type: software
license: Apache-2.0
abstract: "draw.io - JavaScript Diagramming and Whiteboard Application"
authors:
- name: "JGraph"
website: "http://www.drawio.com"
title: "draw.io"
version: 15.5.2
date-released: 2021-10-14
repository-code: "https://github.com/jgraph/drawio"
url: "https://www.drawio.com/"
3 changes: 3 additions & 0 deletions drawio/webapp/META-INF/MANIFEST.MF
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Manifest-Version: 1.0
Class-Path:

32 changes: 32 additions & 0 deletions drawio/webapp/WEB-INF/appengine-web.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<?xml version="1.0" encoding="utf-8"?>
<appengine-web-app xmlns="http://appengine.google.com/ns/1.0">

<threadsafe>true</threadsafe>
<sessions-enabled>false</sessions-enabled>
<runtime>java8</runtime>

<!-- Configure java.util.logging -->
<system-properties>
<property name="java.util.logging.config.file" value="WEB-INF/logging.properties"/>
</system-properties>

<!-- Path patterns not supported in production -->
<static-files>
<include path="/**">
<http-header name="Referrer-Policy" value="strict-origin"/>
<http-header name="Access-Control-Allow-Origin" value="*"/>
<http-header name="X-XSS-Protection" value="1; mode=block"/>
<http-header name="X-Content-Type-Options" value="nosniff"/>
</include>
</static-files>

<!-- App engine has conflicting interfaces for javax.cache.CacheManager -->
<class-loader-config>
<priority-specifier filename="cache-api-1.1.1.jar"/>
</class-loader-config>

<instance-class>F1</instance-class>
<automatic-scaling>
<max-idle-instances>1</max-idle-instances>
</automatic-scaling>
</appengine-web-app>
1 change: 1 addition & 0 deletions drawio/webapp/WEB-INF/cloud_convert_api_key
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Replace_with_your_own_cloud_convert_api_key
1 change: 1 addition & 0 deletions drawio/webapp/WEB-INF/dropbox_client_id
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Replace_with_your_own_dropbox_client_id
1 change: 1 addition & 0 deletions drawio/webapp/WEB-INF/dropbox_client_secret
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Replace_with_your_own_dropbox_client_secret
1 change: 1 addition & 0 deletions drawio/webapp/WEB-INF/github_client_id
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Replace_with_your_own_github_client_id
1 change: 1 addition & 0 deletions drawio/webapp/WEB-INF/github_client_secret
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Replace_with_your_own_github_client_secret
1 change: 1 addition & 0 deletions drawio/webapp/WEB-INF/gitlab_client_id
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Replace_with_your_own_gitlab_client_id
1 change: 1 addition & 0 deletions drawio/webapp/WEB-INF/gitlab_client_secret
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Replace_with_your_own_gitlab_client_secret
1 change: 1 addition & 0 deletions drawio/webapp/WEB-INF/google_client_id
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Replace_with_your_own_google_client_id
1 change: 1 addition & 0 deletions drawio/webapp/WEB-INF/google_client_secret
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Replace_with_your_own_google_client_secret
1 change: 1 addition & 0 deletions drawio/webapp/WEB-INF/iconfinder_client_id
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Replace_with_your_own_iconfinder_client_id
1 change: 1 addition & 0 deletions drawio/webapp/WEB-INF/iconfinder_client_secret
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Replace_with_your_own_iconfinder_client_secret
Binary file added drawio/webapp/WEB-INF/lib/cache-api-1.1.1.jar
Binary file not shown.
Binary file added drawio/webapp/WEB-INF/lib/commons-codec-1.15.jar
Binary file not shown.
Binary file not shown.
Binary file added drawio/webapp/WEB-INF/lib/commons-io-2.11.0.jar
Binary file not shown.
Binary file not shown.
Binary file added drawio/webapp/WEB-INF/lib/commons-logging-1.2.jar
Binary file not shown.
Binary file not shown.
Binary file added drawio/webapp/WEB-INF/lib/ehcache-3.8.1.jar
Binary file not shown.
Binary file added drawio/webapp/WEB-INF/lib/gae-stub-1.0.9.jar
Binary file not shown.
Binary file added drawio/webapp/WEB-INF/lib/gson-2.8.9.jar
Binary file not shown.
Binary file added drawio/webapp/WEB-INF/lib/httpclient-4.5.13.jar
Binary file not shown.
Binary file added drawio/webapp/WEB-INF/lib/httpcore-4.4.13.jar
Binary file not shown.
Binary file not shown.
Binary file added drawio/webapp/WEB-INF/lib/servlet-api.jar
Binary file not shown.
Binary file added drawio/webapp/WEB-INF/lib/slf4j-api-1.7.25.jar
Binary file not shown.
2 changes: 2 additions & 0 deletions drawio/webapp/WEB-INF/logging.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Set the default logging level for all loggers to WARNING
.level = CONFIG
1 change: 1 addition & 0 deletions drawio/webapp/WEB-INF/msgraph_client_id
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Replace_with_your_own_microsoft_graph_client_id
1 change: 1 addition & 0 deletions drawio/webapp/WEB-INF/msgraph_client_secret
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Replace_with_your_own_microsoft_graph_client_secret
4 changes: 4 additions & 0 deletions drawio/webapp/WEB-INF/pusher_properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
app_id=Replace_with_your_pusher_app_id
key=Replace_with_your_pusher_key
secret=Replace_with_your_pusher_secret
cluster=Replace_with_your_pusher_cluster
Loading

0 comments on commit 46eb08e

Please sign in to comment.