mirror of
https://github.com/utopia-os/utopia-ui.git
synced 2025-12-13 07:46:10 +00:00
commit
c71b4f5ed3
@ -1,3 +1,4 @@
|
||||
node_modules/
|
||||
dist/
|
||||
examples/
|
||||
docs/
|
||||
56
.github/workflows/deploy.docs.yml
vendored
Normal file
56
.github/workflows/deploy.docs.yml
vendored
Normal file
@ -0,0 +1,56 @@
|
||||
name: deploy:docs
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
# Build job
|
||||
build:
|
||||
# Specify runner + build & upload the static files as an artifact
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.1.7
|
||||
- uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.0.3
|
||||
with:
|
||||
node-version-file: './.tool-versions'
|
||||
- name: Install Dependencies & Build Library
|
||||
run: |
|
||||
npm install
|
||||
npm run build
|
||||
npm link
|
||||
working-directory: ./
|
||||
|
||||
- name: Build static files
|
||||
id: build
|
||||
run: npm install && npm run docs:generate
|
||||
working-directory: ./
|
||||
|
||||
- name: Upload static files as artifact
|
||||
id: deployment
|
||||
uses: actions/upload-pages-artifact@v3.0.1
|
||||
with:
|
||||
path: docs/
|
||||
|
||||
# Deploy job
|
||||
deploy:
|
||||
# Add a dependency to the build job
|
||||
needs: build
|
||||
|
||||
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment
|
||||
permissions:
|
||||
pages: write # to deploy to Pages
|
||||
id-token: write # to verify the deployment originates from an appropriate source
|
||||
|
||||
# Deploy to the github-pages environment
|
||||
environment:
|
||||
name: github-pages
|
||||
url: ${{ steps.deployment.outputs.page_url }}
|
||||
|
||||
# Specify runner + deployment step
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Deploy to GitHub Pages
|
||||
id: deployment
|
||||
uses: actions/deploy-pages@v4.0.5
|
||||
47
.github/workflows/test.docs.yml
vendored
Normal file
47
.github/workflows/test.docs.yml
vendored
Normal file
@ -0,0 +1,47 @@
|
||||
name: test:docs
|
||||
|
||||
on: push
|
||||
|
||||
jobs:
|
||||
files-changed:
|
||||
name: Detect File Changes - docs
|
||||
runs-on: ubuntu-latest
|
||||
outputs:
|
||||
docs: ${{ steps.filter.outputs.docs }}
|
||||
steps:
|
||||
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.1.7
|
||||
- uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
|
||||
id: filter
|
||||
with:
|
||||
filters: |
|
||||
docs:
|
||||
- '.github/workflows/**/*'
|
||||
- '**/*'
|
||||
|
||||
# build:
|
||||
# if: needs.files-changed.outputs.frontend == 'true'
|
||||
# name: Build - Frontend
|
||||
# needs: files-changed
|
||||
# runs-on: ubuntu-latest
|
||||
# steps:
|
||||
# - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.1.7
|
||||
# - uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.0.3
|
||||
# with:
|
||||
# node-version-file: './.tool-versions'
|
||||
# - name: Frontend | Build
|
||||
# run: npm install && npm run build
|
||||
# working-directory: ./frontend
|
||||
|
||||
docs:
|
||||
if: needs.files-changed.outputs.docs == 'true'
|
||||
name: Docs
|
||||
needs: files-changed
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.1.7
|
||||
- uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.0.3
|
||||
with:
|
||||
node-version-file: './.tool-versions'
|
||||
- name: Docs
|
||||
run: npm install && npm run docs:generate
|
||||
working-directory: ./
|
||||
3
.gitignore
vendored
3
.gitignore
vendored
@ -89,3 +89,6 @@ lerna-debug.log
|
||||
# System Files
|
||||
.DS_Store
|
||||
Thumbs.db
|
||||
|
||||
# docs
|
||||
/docs
|
||||
1918
package-lock.json
generated
1918
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -10,6 +10,7 @@
|
||||
"build": "rollup -c",
|
||||
"start": "rollup -c -w",
|
||||
"test:lint:eslint": "eslint --ext .ts,.tsx,.js,.jsx,.cjs,.mjs,.json,.yml,.yaml --max-warnings 0 .",
|
||||
"docs:generate": "typedoc src/index.tsx",
|
||||
"update": "npx npm-check-updates"
|
||||
},
|
||||
"files": [
|
||||
@ -22,6 +23,7 @@
|
||||
"@eslint-community/eslint-plugin-eslint-comments": "^4.4.1",
|
||||
"@types/geojson": "^7946.0.14",
|
||||
"@types/leaflet": "^1.7.11",
|
||||
"@types/leaflet.markercluster": "^1.5.5",
|
||||
"@types/react": "^18.2.0",
|
||||
"@types/react-dom": "^18.0.5",
|
||||
"@typescript-eslint/eslint-plugin": "^5.62.0",
|
||||
@ -49,6 +51,7 @@
|
||||
"rollup-plugin-postcss": "^4.0.2",
|
||||
"rollup-plugin-typescript2": "^0.32.1",
|
||||
"tailwindcss": "^3.3.1",
|
||||
"typedoc": "^0.27.6",
|
||||
"typescript": "^5.7.3"
|
||||
},
|
||||
"peerDependencies": {
|
||||
@ -74,7 +77,7 @@
|
||||
"react-string-replace": "^1.1.1",
|
||||
"react-toastify": "^9.1.3",
|
||||
"remark-breaks": "^4.0.0",
|
||||
"tributejs": "^5.1.3",
|
||||
"tributejs": "github:coreydales/tribute#Fix-compile-error-T-does-not-satisfy-the-constraint",
|
||||
"tw-elements": "^1.0.0",
|
||||
"yet-another-react-lightbox": "^3.21.7"
|
||||
},
|
||||
|
||||
@ -67,6 +67,7 @@ export const ItemViewPopup = forwardRef((props: ItemViewPopupProps, ref: any) =>
|
||||
success = true
|
||||
// eslint-disable-next-line no-catch-all/no-catch-all
|
||||
} catch (error) {
|
||||
// eslint-disable-next-line @typescript-eslint/no-unsafe-argument
|
||||
toast.error(error.toString())
|
||||
}
|
||||
if (success) {
|
||||
|
||||
@ -190,7 +190,7 @@ export function UtopiaMapInner({
|
||||
url='https://tile.osmand.net/hd/{z}/{x}/{y}.png'
|
||||
/>
|
||||
<MarkerClusterGroup
|
||||
ref={(r) => setClusterRef(r)}
|
||||
ref={(r) => setClusterRef(r as any)}
|
||||
showCoverageOnHover
|
||||
chunkedLoading
|
||||
maxClusterRadius={50}
|
||||
|
||||
@ -98,6 +98,7 @@ function useSelectPositionManager(): {
|
||||
success = true
|
||||
// eslint-disable-next-line no-catch-all/no-catch-all
|
||||
} catch (error) {
|
||||
// eslint-disable-next-line @typescript-eslint/no-unsafe-argument
|
||||
toast.error(error.toString())
|
||||
}
|
||||
if (success) {
|
||||
@ -123,6 +124,7 @@ function useSelectPositionManager(): {
|
||||
success = true
|
||||
// eslint-disable-next-line no-catch-all/no-catch-all
|
||||
} catch (error) {
|
||||
// eslint-disable-next-line @typescript-eslint/no-unsafe-argument
|
||||
toast.error(error.toString())
|
||||
}
|
||||
if (success) {
|
||||
@ -145,6 +147,7 @@ function useSelectPositionManager(): {
|
||||
success = true
|
||||
// eslint-disable-next-line no-catch-all/no-catch-all
|
||||
} catch (error) {
|
||||
// eslint-disable-next-line @typescript-eslint/no-unsafe-argument
|
||||
toast.error(error.toString())
|
||||
}
|
||||
if (success) {
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
"compilerOptions": {
|
||||
"outDir": "dist",
|
||||
"module": "esnext",
|
||||
"target": "es5",
|
||||
"target": "ESNext",
|
||||
"lib": ["es6", "dom","es2015", "es2016", "es2017", "es2020"],
|
||||
"sourceMap": true,
|
||||
"allowJs": false,
|
||||
@ -16,6 +16,7 @@
|
||||
"strictNullChecks": true,
|
||||
"noUnusedLocals": false,
|
||||
"noUnusedParameters": true,
|
||||
"allowSyntheticDefaultImports": true,
|
||||
"paths": {
|
||||
"#components/*": ["./src/Components/*"],
|
||||
"#utils/*": ["./src/Utils/*"],
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user