Skip to content

Commit b9c60b0

Browse files
michaelcartnererictuvessonmikaeltellhedmrtamagotchianders-topp
committed
Initial commit
Co-Authored-By: Eric Tuvesson <[email protected]> Co-Authored-By: mikaeltellhed <[email protected]> Co-Authored-By: kotte <[email protected]> Co-Authored-By: Anders Larsson <[email protected]> Co-Authored-By: Johan <[email protected]> Co-Authored-By: Tore Knudsen <[email protected]> Co-Authored-By: victoratndl <[email protected]>
0 parents  commit b9c60b0

File tree

2,789 files changed

+868795
-0
lines changed

Some content is hidden

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

2,789 files changed

+868795
-0
lines changed

Diff for: .editorconfig

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
root = true
2+
3+
[*]
4+
end_of_line = lf
5+
insert_final_newline = true

Diff for: .eslintrc.js

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
module.exports = {
2+
env: {
3+
browser: true,
4+
es2021: true,
5+
node: true
6+
},
7+
extends: ['eslint:recommended', 'plugin:react/recommended', 'plugin:@typescript-eslint/recommended'],
8+
overrides: [],
9+
parser: '@typescript-eslint/parser',
10+
parserOptions: {
11+
ecmaVersion: 'latest',
12+
sourceType: 'module'
13+
},
14+
plugins: ['react', '@typescript-eslint'],
15+
rules: {
16+
'@typescript-eslint/no-namespace': 'off',
17+
'no-prototype-builtins': 'off'
18+
},
19+
settings: {
20+
react: {
21+
version: 'detect'
22+
}
23+
}
24+
};

Diff for: .github/workflows/build-noodl-editor.yml

+76
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
name: Build noodl-editor
2+
3+
on:
4+
# Allows you to run this workflow manually from the Actions tab
5+
workflow_dispatch:
6+
7+
# Allows you to run this workflow from another workflow
8+
workflow_call:
9+
10+
# release:
11+
# types: [created]
12+
13+
jobs:
14+
build_noodl_editor:
15+
runs-on: ${{ matrix.os }}
16+
17+
strategy:
18+
fail-fast: false
19+
matrix:
20+
include:
21+
- node: 16
22+
os: windows-latest
23+
platform: win32-x64
24+
- node: 16
25+
os: macos-latest
26+
platform: darwin-arm64
27+
- node: 16
28+
os: macos-latest
29+
platform: darwin-x64
30+
# - node: 16
31+
# os: ubuntu-latest
32+
# platform: linux-x64
33+
34+
steps:
35+
- if: ${{ matrix.platform == 'darwin-arm64' }}
36+
name: Setup
37+
uses: actions/setup-python@v5
38+
with:
39+
python-version: '3.11'
40+
41+
- name: Checkout
42+
uses: actions/checkout@v4
43+
44+
- name: Setup node env 🏗
45+
uses: actions/setup-node@v4
46+
with:
47+
node-version: ${{ matrix.node }}
48+
49+
# - name: Clean up
50+
# continue-on-error: true
51+
# run: |
52+
# npx rimraf node_modules
53+
# npx lerna clean --yes
54+
55+
- name: Install dependencies 🏗
56+
run: npm install
57+
58+
- name: Build Noodl Viewer (build bundles and copy them to Noodl Editor)
59+
run: npm run build:editor:_viewer
60+
env:
61+
WORKSPACE_PATH: .
62+
63+
- name: Build Noodl Editor (build bundles etc and signing)
64+
run: npm run build:editor:_editor
65+
env:
66+
WORKSPACE_PATH: .
67+
TARGET_PLATFORM: ${{ matrix.platform }}
68+
69+
- run: npm run build:editor:pack
70+
71+
- name: Upload artifact
72+
uses: actions/upload-artifact@v3
73+
with:
74+
name: noodl-editor-${{ matrix.platform }}-${{ github.head_ref }}-${{ github.sha }}
75+
path: publish
76+
retention-days: "12"

Diff for: .github/workflows/publish-cloud-runtime.yml

+41
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: Publish cloud-runtime
2+
3+
on:
4+
# Allows you to run this workflow manually from the Actions tab
5+
workflow_dispatch:
6+
7+
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
8+
concurrency:
9+
group: "publish-cloud-runtime"
10+
11+
jobs:
12+
publish:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Checkout
16+
uses: actions/checkout@v3
17+
18+
- name: Setup node env 🏗
19+
uses: actions/setup-node@v2
20+
with:
21+
node-version: 16
22+
registry-url: 'https://registry.npmjs.org'
23+
24+
- name: Install dependencies 🏗
25+
run: npm install
26+
27+
- name: Build
28+
run: npm run build:cloud-runtime
29+
30+
- name: Upload artifact
31+
uses: actions/upload-pages-artifact@v2
32+
with:
33+
name: "noodl-cloud-runtime"
34+
path: "packages/noodl-viewer-cloud/publish"
35+
retention-days: "12"
36+
37+
- name: Publish
38+
run: npm publish --access=public
39+
working-directory: packages/noodl-viewer-cloud/publish
40+
env:
41+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

Diff for: .github/workflows/test-noodl-editor.yml

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Test noodl-editor
2+
3+
on:
4+
# Allows you to run this workflow manually from the Actions tab
5+
workflow_dispatch:
6+
7+
jobs:
8+
test_platform:
9+
runs-on: ${{ matrix.os }}
10+
11+
strategy:
12+
fail-fast: false
13+
matrix:
14+
include:
15+
- node: 16
16+
os: ubuntu-latest
17+
platform: linux-x64
18+
19+
steps:
20+
- name: Checkout
21+
uses: actions/checkout@v3
22+
23+
- name: Setup node env 🏗
24+
uses: actions/setup-node@v2
25+
with:
26+
node-version: 16
27+
28+
- name: Install dependencies 🏗
29+
run: npm install
30+
31+
- name: Run tests headless
32+
run: /usr/bin/xvfb-run --auto-servernum -s "-screen 0 1280x1024x24" npm run test:editor

Diff for: .github/workflows/test-platform-node.yml

+41
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: Test noodl/platform-node
2+
3+
on:
4+
push:
5+
branches: ["main"]
6+
paths:
7+
- 'packages/noodl-platform/**'
8+
- 'packages/noodl-platform-node/**'
9+
- 'packages/noodl-platform-electron/**'
10+
11+
pull_request:
12+
paths:
13+
- 'packages/noodl-platform/**'
14+
- 'packages/noodl-platform-node/**'
15+
- 'packages/noodl-platform-electron/**'
16+
17+
# Allows you to run this workflow manually from the Actions tab
18+
workflow_dispatch:
19+
20+
jobs:
21+
test_platform:
22+
23+
runs-on: ubuntu-latest
24+
25+
steps:
26+
- name: Checkout
27+
uses: actions/checkout@v3
28+
29+
- name: Setup node env 🏗
30+
uses: actions/setup-node@v2
31+
with:
32+
node-version: 16
33+
34+
- name: Install dependencies 🏗
35+
run: npm install
36+
37+
- name: Run tests
38+
run: npx lerna exec --scope @noodl/platform-node -- npm run test
39+
40+
- name: Print coverage
41+
run: npx lerna exec --scope @noodl/platform-node -- npm run test:coverage

Diff for: .gitignore

+170
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,170 @@
1+
.idea
2+
.DS_Store
3+
4+
# Logs
5+
logs
6+
*.log
7+
npm-debug.log*
8+
yarn-debug.log*
9+
yarn-error.log*
10+
lerna-debug.log*
11+
.pnpm-debug.log*
12+
13+
# Diagnostic reports (https://nodejs.org/api/report.html)
14+
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
15+
16+
# Runtime data
17+
pids
18+
*.pid
19+
*.seed
20+
*.pid.lock
21+
22+
# Directory for instrumented libs generated by jscoverage/JSCover
23+
lib-cov
24+
25+
# Coverage directory used by tools like istanbul
26+
coverage
27+
*.lcov
28+
29+
# nyc test coverage
30+
.nyc_output
31+
32+
# test
33+
tests/index.bundle.js
34+
tests/index.bundle.js.LICENSE.txt
35+
tests/ts.worker.js.LICENSE.txt
36+
tests/ts.worker.js
37+
tests/css.worker.js.LICENSE.txt
38+
tests/css.worker.js
39+
tests/editor.worker.js
40+
tests/vendors-*
41+
tests/node_modules_*
42+
tests/testfs
43+
44+
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
45+
.grunt
46+
47+
# Bower dependency directory (https://bower.io/)
48+
bower_components
49+
50+
# node-waf configuration
51+
.lock-wscript
52+
53+
# Compiled binary addons (https://nodejs.org/api/addons.html)
54+
build/Release
55+
56+
# Dependency directories
57+
node_modules/
58+
jspm_packages/
59+
60+
# Snowpack dependency directory (https://snowpack.dev/)
61+
web_modules/
62+
63+
# TypeScript cache
64+
*.tsbuildinfo
65+
66+
# Optional npm cache directory
67+
.npm
68+
69+
# Optional eslint cache
70+
.eslintcache
71+
72+
# Optional stylelint cache
73+
.stylelintcache
74+
75+
# Microbundle cache
76+
.rpt2_cache/
77+
.rts2_cache_cjs/
78+
.rts2_cache_es/
79+
.rts2_cache_umd/
80+
81+
# Optional REPL history
82+
.node_repl_history
83+
84+
# Output of 'npm pack'
85+
*.tgz
86+
87+
# Yarn Integrity file
88+
.yarn-integrity
89+
90+
# dotenv environment variable files
91+
.env
92+
.env.development.local
93+
.env.test.local
94+
.env.production.local
95+
.env.local
96+
97+
# parcel-bundler cache (https://parceljs.org/)
98+
.cache
99+
.parcel-cache
100+
101+
# Next.js build output
102+
.next
103+
out
104+
105+
# Nuxt.js build / generate output
106+
.nuxt
107+
dist
108+
109+
# Gatsby files
110+
.cache/
111+
# Comment in the public line in if your project uses Gatsby and not Next.js
112+
# https://nextjs.org/blog/next-9-1#public-directory-support
113+
# public
114+
115+
# vuepress build output
116+
.vuepress/dist
117+
118+
# vuepress v2.x temp and cache directory
119+
.temp
120+
.cache
121+
122+
# Docusaurus cache and generated files
123+
.docusaurus
124+
125+
# Serverless directories
126+
.serverless/
127+
128+
# FuseBox cache
129+
.fusebox/
130+
131+
# DynamoDB Local files
132+
.dynamodb/
133+
134+
# TernJS port file
135+
.tern-port
136+
137+
# Stores VSCode versions used for testing VSCode extensions
138+
.vscode-test
139+
140+
# yarn v2
141+
.yarn/cache
142+
.yarn/unplugged
143+
.yarn/build-state.yml
144+
.yarn/install-state.gz
145+
.pnp.*
146+
147+
# Build files
148+
releases/*
149+
build-tmp
150+
dist-cli
151+
packages/noodl-cloud-services/build/*
152+
153+
# Test files
154+
packages/noodl-editor/tests/css.worker.js
155+
packages/noodl-editor/tests/editor.worker.js
156+
packages/noodl-editor/tests/index.bundle.js
157+
packages/noodl-editor/tests/node_modules_monaco-editor_esm_vs_basic-languages_css_css_js.index.bundle.js
158+
packages/noodl-editor/tests/node_modules_monaco-editor_esm_vs_basic-languages_graphql_graphql_js.index.bundle.js
159+
packages/noodl-editor/tests/node_modules_monaco-editor_esm_vs_basic-languages_javascript_javascript_js.index.bundle.js
160+
packages/noodl-editor/tests/node_modules_monaco-editor_esm_vs_basic-languages_typescript_typescript_js.index.bundle.js
161+
packages/noodl-editor/tests/ts.worker.js
162+
packages/noodl-editor/tests/vendors-node_modules_monaco-editor_esm_vs_language_css_cssMode_js.index.bundle.js
163+
packages/noodl-editor/tests/vendors-node_modules_monaco-editor_esm_vs_language_html_htmlMode_js.index.bundle.js
164+
packages/noodl-editor/tests/vendors-node_modules_monaco-editor_esm_vs_language_json_jsonMode_js.index.bundle.js
165+
packages/noodl-editor/tests/vendors-node_modules_monaco-editor_esm_vs_language_typescript_tsMode_js.index.bundle.js
166+
167+
# Other
168+
packages/noodl-editor/src/external
169+
.github/.secrets
170+
packages/noodl-viewer-cloud/publish

Diff for: .npmrc

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
engine-strict=true
2+
runtime = electron

0 commit comments

Comments
 (0)