Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: bump [email protected] #192

Merged
merged 5 commits into from
Apr 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions .dumirc.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import { defineConfig } from 'dumi';

export default defineConfig({
favicons: ['https://avatars0.githubusercontent.com/u/9441414?s=200&v=4'],
themeConfig: {
name: 'resize-observer',
logo: 'https://avatars0.githubusercontent.com/u/9441414?s=200&v=4',
},
styles: [
`
section.dumi-default-header-left {
width: 230px;
}
.markdown table {
width: auto !important;
}
`,
],
});
4 changes: 2 additions & 2 deletions .github/workflows/react-component-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

- uses: actions/setup-node@v1
with:
node-version: '16'
node-version: '18'

- name: cache package-lock.json
uses: actions/cache@v2
Expand All @@ -24,7 +24,7 @@ jobs:
key: lock-${{ github.sha }}

- name: create package-lock.json
run: npm i --package-lock-only
run: npm i --package-lock-only --ignore-scripts

- name: hack for singe file
run: |
Expand Down
11 changes: 6 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
.storybook
*.iml
*.log
.idea/
Expand Down Expand Up @@ -29,8 +28,10 @@ yarn.lock
package-lock.json
coverage/
.doc
# umi
.umi
.umi-production
.umi-test
# dumi
.dumi/tmp
.dumi/tmp-test
.dumi/tmp-production
.env.local
.node
dist/
2 changes: 0 additions & 2 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
.storybook
node_modules
lib
es
Expand All @@ -8,5 +7,4 @@ package-lock.json
public
.site
_site
.umi
.doc
4 changes: 0 additions & 4 deletions .umirc.gh.ts

This file was deleted.

21 changes: 0 additions & 21 deletions .umirc.ts

This file was deleted.

9 changes: 7 additions & 2 deletions docs/demo/basic.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## Basic
---
title: basic
nav:
title: Demo
path: /demo
---

<code src="../../examples/basic.tsx">
<code src="../../examples/basic.tsx"></code>
9 changes: 7 additions & 2 deletions docs/demo/collection.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
## Collection
---
title: Collection
nav:
title: Demo
path: /demo
---

Use `ResizeObserver.Collection` to collect multiple `ResizeObserver` resize event within frame.

<code src="../../examples/collection.tsx">
<code src="../../examples/collection.tsx"></code>
9 changes: 7 additions & 2 deletions docs/demo/debug.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## debug
---
title: debug
nav:
title: Demo
path: /demo
---

<code src="../../examples/debug.tsx">
<code src="../../examples/debug.tsx"></code>
9 changes: 7 additions & 2 deletions docs/demo/renderProps.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## renderProps
---
title: renderProps
nav:
title: Demo
path: /demo
---

<code src="../../examples/renderProps.tsx">
<code src="../../examples/renderProps.tsx"></code>
4 changes: 3 additions & 1 deletion docs/index.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
---
title: rc-resize-observer
hero:
title: rc-resize-observer
description: React Resize-Observer Component
---

<embed src="../README.md"></embed>
2 changes: 1 addition & 1 deletion now.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
{
"src": "package.json",
"use": "@now/static-build",
"config": { "distDir": ".doc" }
"config": { "distDir": "dist" }
}
],
"routes": [
Expand Down
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
"compile": "father build && lessc assets/index.less assets/index.css",
"deploy": "UMI_ENV=gh npm run build && gh-pages -d .doc",
"gh-pages": "npm run deploy",
"prepare": "dumi setup",
"prepublishOnly": "npm run compile && np --no-cleanup --yolo --no-publish",
"postpublish": "npm run gh-pages",
"lint": "eslint src/ --ext .ts,.tsx,.jsx,.js,.md",
Expand All @@ -56,7 +57,7 @@
"@umijs/fabric": "^2.0.9",
"coveralls": "^3.0.6",
"cross-env": "^7.0.2",
"dumi": "^1.1.12",
"dumi": "^2.0.0",
"enzyme": "^3.0.0",
"enzyme-adapter-react-16": "^1.15.6",
"enzyme-to-json": "^3.4.0",
Expand All @@ -65,8 +66,8 @@
"glob": "^7.1.6",
"less": "^4.1.3",
"np": "^9.0.0",
"prettier": "^3.1.0",
"pretty-quick": "^3.0.1",
"prettier": "^3.2.5",
"pretty-quick": "^4.0.0",
"rc-test": "^7.0.15",
"react": "^16.0.0",
"react-dom": "^16.0.0",
Expand Down
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"src/*"
],
"@@/*": [
"src/.umi/*"
".dumi/tmp/*"
],
"rc-resize-observer": [
"src/index.tsx"
Expand Down
9 changes: 7 additions & 2 deletions update-example.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,14 @@ paths.forEach(path => {
const name = path.split('/').pop().split('.')[0];
fs.writeFile(
`./docs/demo/${name}.md`,
`## ${name}
`---
title: ${name}
nav:
title: Demo
path: /demo
---

<code src="../../examples/${name}.tsx">
<code src="../../examples/${name}.tsx"></code>
`,
'utf8',
function(error) {
Expand Down
Loading