Skip to content

Commit 0c20d2d

Browse files
authored
Merge pull request #8 from schubergphilis/bugfix/date-check
Bugfix/date check
2 parents aad7c15 + 4970ce2 commit 0c20d2d

File tree

10 files changed

+8845
-7459
lines changed

10 files changed

+8845
-7459
lines changed

.github/workflows/deploy-frontend.yml

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,14 @@ jobs:
2222
- uses: actions/checkout@v4
2323
with:
2424
ref: ${{github.head_ref}}
25-
25+
- uses: pnpm/action-setup@v4
26+
with:
27+
version: 10
2628
- uses: actions/setup-node@v4
2729
with:
2830
node-version: 22
29-
cache: "yarn"
30-
cache-dependency-path: "**/yarn.lock"
31+
cache: "pnpm"
32+
cache-dependency-path: "**/pnpm-lock.yaml"
3133
always-auth: true
3234
scope: '@schubergphilis'
3335
registry-url: 'https://npm.pkg.github.com'
@@ -40,19 +42,19 @@ jobs:
4042
4143
- name: Install dependencies
4244
working-directory: sbp-frontend-style
43-
run: yarn install
45+
run: pnpm install
4446

4547
- name: Build component list
4648
working-directory: sbp-frontend-style
47-
run: yarn prebuild
49+
run: pnpm prebuild
4850

4951
- name: Run Tests
5052
working-directory: sbp-frontend-style
51-
run: yarn test
53+
run: pnpm test
5254

5355
- name: Build project
5456
working-directory: sbp-frontend-style
55-
run: yarn build
57+
run: pnpm build
5658
env:
5759
GENERATE_SOURCEMAP: "false"
5860

@@ -75,7 +77,7 @@ jobs:
7577
7678
- name: Package project
7779
working-directory: sbp-frontend-style
78-
run: yarn pack && yarn publish
80+
run: pnpm pack && pnpm publish
7981
env:
8082
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
8183

.github/workflows/on_all_pull_requests.yml

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,14 @@ jobs:
2121
- uses: actions/checkout@v4
2222
with:
2323
ref: ${{github.head_ref}}
24-
24+
- uses: pnpm/action-setup@v4
25+
with:
26+
version: 10
2527
- uses: actions/setup-node@v4
2628
with:
2729
node-version: 22
28-
cache: "yarn"
29-
cache-dependency-path: "**/yarn.lock"
30+
cache: "pnpm"
31+
cache-dependency-path: "**/pnpm-lock.yaml"
3032
always-auth: true
3133
scope: '@schubergphilis'
3234
registry-url: 'https://npm.pkg.github.com'
@@ -39,19 +41,19 @@ jobs:
3941
4042
- name: Install dependencies
4143
working-directory: sbp-frontend-style
42-
run: yarn install
44+
run: pnpm install
4345

4446
- name: Build component list
4547
working-directory: sbp-frontend-style
46-
run: yarn prebuild
48+
run: pnpm prebuild
4749

4850
- name: Run Tests
4951
working-directory: sbp-frontend-style
50-
run: yarn test
52+
run: pnpm test
5153

5254
- name: Build project
5355
working-directory: sbp-frontend-style
54-
run: yarn build
56+
run: pnpm build
5557
env:
5658
GENERATE_SOURCEMAP: "false"
5759

@@ -63,7 +65,7 @@ jobs:
6365

6466
- name: Package project
6567
working-directory: sbp-frontend-style
66-
run: yarn pack && yarn publish
68+
run: pnpm pack && pnpm publish --no-git-checks
6769
env:
6870
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6971

sbp-frontend-style/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ Using these components you only need to add this package to your project
2424
### Install
2525

2626
```bash
27-
yarn add @schubergphilis/sbp-frontend-style
27+
pnpm add @schubergphilis/sbp-frontend-style
2828

2929
# Or with npm:
3030

@@ -72,20 +72,20 @@ Within the CloudStyle component it is possible to make changes to the overall co
7272

7373
In the project directory, you can run:
7474

75-
### `yarn start`
75+
### `pnpm start`
7676

7777
Runs the app in the development mode.\
7878
Open [https://localhost:3005](https://localhost:3005) to view it in the browser.
7979

8080
The page will reload if you make edits.\
8181
You will also see any lint errors in the console.
8282

83-
### `yarn test`
83+
### `pnpm test`
8484

8585
Launches the test runner in the interactive watch mode.\
8686
See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information.
8787

88-
### `yarn build`
88+
### `pnpm build`
8989

9090
Builds the app for production to the `build` folder.\
9191
It correctly bundles React in production mode and optimizes the build for the best performance.

sbp-frontend-style/__tests__/App.test.tsx

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,29 @@ global.ResizeObserver = jest.fn().mockImplementation(() => ({
1212
disconnect: jest.fn()
1313
}))
1414

15+
jest.mock('react-syntax-highlighter', () => {
16+
const MockLight = jest.fn(({ children, language }) => (
17+
<div data-testid="syntax-highlighter" data-language={language}>
18+
{children}
19+
</div>
20+
)) as any
21+
MockLight.registerLanguage = jest.fn()
22+
23+
return {
24+
Light: MockLight
25+
}
26+
})
27+
28+
jest.mock(
29+
'react-syntax-highlighter/dist/esm/languages/hljs/typescript',
30+
() => ({})
31+
)
32+
jest.mock('react-syntax-highlighter/dist/esm/languages/hljs/xml', () => ({}))
33+
jest.mock(
34+
'react-syntax-highlighter/dist/esm/styles/hljs/atom-one-dark',
35+
() => ({})
36+
)
37+
1538
describe('App', () => {
1639
it('should render the app', async () => {
1740
await act(async () => {

sbp-frontend-style/package.json

Lines changed: 47 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@schubergphilis/sbp-frontend-style",
3-
"version": "1.8.0",
3+
"version": "1.8.1-3",
44
"license": "MIT",
55
"type": "module",
66
"types": "./dist/index.d.ts",
@@ -19,13 +19,13 @@
1919
"url": "git://github.com/schubergphilis/sbp-frontend-style.git"
2020
},
2121
"scripts": {
22-
"predev": "yarn prebuild",
22+
"predev": "pnpm prebuild",
2323
"dev": "vite --port 3005",
2424
"prebuild": "node --trace-warnings component-list.js",
2525
"lint": "eslint ./src --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
2626
"preview": "vite preview",
2727
"clean": "rimraf dist",
28-
"build": "yarn clean && rollup -c",
28+
"build": "pnpm clean && rollup -c",
2929
"release": "standard-version",
3030
"test": "jest --coverage --colors --silent --verbose --watchAll=false",
3131
"test:debug": "jest --watchAll --coverage --color --detectOpenHandles --silent false --verbose true --debug",
@@ -34,69 +34,69 @@
3434
"test:clear": "jest --clearCache"
3535
},
3636
"peerDependencies": {
37-
"react": "^19.1.1",
38-
"react-dom": "^19.1.1"
37+
"react": "^19.2.3",
38+
"react-dom": "^19.2.3"
3939
},
4040
"dependencies": {
41-
"styled-components": "^6.1.19"
41+
"styled-components": "^6.3.5"
4242
},
4343
"devDependencies": {
44-
"@eslint/compat": "^1.3.2",
45-
"@eslint/eslintrc": "^3.3.1",
46-
"@eslint/js": "^9.35.0",
47-
"@inrupt/jest-jsdom-polyfills": "^4.0.5",
48-
"@reduxjs/toolkit": "^2.9.0",
49-
"@rollup/plugin-commonjs": "^28.0.6",
50-
"@rollup/plugin-node-resolve": "^16.0.1",
44+
"@eslint/compat": "^2.0.1",
45+
"@eslint/eslintrc": "^3.3.3",
46+
"@eslint/js": "^9.39.2",
47+
"@inrupt/jest-jsdom-polyfills": "^4.0.8",
48+
"@reduxjs/toolkit": "^2.11.2",
49+
"@rollup/plugin-commonjs": "^29.0.0",
50+
"@rollup/plugin-node-resolve": "^16.0.3",
5151
"@rollup/plugin-sucrase": "^5.0.2",
5252
"@rollup/plugin-typescript": "^11.1.2",
5353
"@testing-library/dom": "^10.4.1",
54-
"@testing-library/jest-dom": "^6.8.0",
55-
"@testing-library/react": "^16.3.0",
54+
"@testing-library/jest-dom": "^6.9.1",
55+
"@testing-library/react": "^16.3.1",
5656
"@testing-library/user-event": "^14.6.1",
5757
"@types/jest": "^30.0.0",
58-
"@types/node": "^24.3.1",
59-
"@types/react": "^19.1.12",
60-
"@types/react-dom": "^19.1.9",
58+
"@types/node": "^25.0.6",
59+
"@types/react": "^19.2.8",
60+
"@types/react-dom": "^19.2.3",
6161
"@types/react-redux": "^7.1.34",
6262
"@types/react-syntax-highlighter": "^15.5.13",
63-
"@types/styled-components": "^5.1.34",
64-
"@typescript-eslint/eslint-plugin": "^8.43.0",
65-
"@typescript-eslint/parser": "^8.43.0",
66-
"@vitejs/plugin-react": "^5.0.2",
67-
"@vitejs/plugin-react-swc": "^4.0.1",
63+
"@types/styled-components": "^5.1.36",
64+
"@typescript-eslint/eslint-plugin": "^8.52.0",
65+
"@typescript-eslint/parser": "^8.52.0",
66+
"@vitejs/plugin-react": "^5.1.2",
67+
"@vitejs/plugin-react-swc": "^4.2.2",
6868
"directory-tree": "^3.5.2",
69-
"eslint": "9.35.0",
70-
"eslint-config-prettier": "10.1.5",
69+
"eslint": "9.39.2",
70+
"eslint-config-prettier": "10.1.8",
7171
"eslint-plugin-prettier": "5.5.4",
7272
"eslint-plugin-react": "^7.37.5",
73-
"eslint-plugin-react-hooks": "^5.2.0",
74-
"eslint-plugin-react-refresh": "^0.4.20",
75-
"globals": "^16.3.0",
76-
"html-react-parser": "^5.2.6",
77-
"jest": "^30.1.3",
78-
"jest-environment-jsdom": "^30.1.2",
79-
"jest-environment-node": "^30.1.2",
80-
"prettier": "^3.6.2",
81-
"prettier-plugin-organize-imports": "^4.2.0",
82-
"react": "^19.1.1",
83-
"react-dom": "^19.1.1",
73+
"eslint-plugin-react-hooks": "^7.0.1",
74+
"eslint-plugin-react-refresh": "^0.4.26",
75+
"globals": "^17.0.0",
76+
"html-react-parser": "^5.2.11",
77+
"jest": "^30.2.0",
78+
"jest-environment-jsdom": "^30.2.0",
79+
"jest-environment-node": "^30.2.0",
80+
"prettier": "^3.7.4",
81+
"prettier-plugin-organize-imports": "^4.3.0",
82+
"react": "^19.2.3",
83+
"react-dom": "^19.2.3",
8484
"react-element-to-jsx-string": "^17.0.1",
8585
"react-redux": "^9.2.0",
86-
"react-router-dom": "^7.8.2",
87-
"react-syntax-highlighter": "^15.6.6",
88-
"rimraf": "^6.0.1",
89-
"rollup": "^4.50.1",
90-
"rollup-plugin-delete": "^3.0.1",
91-
"rollup-plugin-dts": "^6.2.3",
86+
"react-router-dom": "^7.12.0",
87+
"react-syntax-highlighter": "^16.1.0",
88+
"rimraf": "^6.1.2",
89+
"rollup": "^4.55.1",
90+
"rollup-plugin-delete": "^3.0.2",
91+
"rollup-plugin-dts": "^6.3.0",
9292
"rollup-plugin-peer-deps-external": "^2.2.4",
9393
"rollup-plugin-terser": "^7.0.2",
9494
"rollup-plugin-tsconfig-paths": "^1.5.2",
9595
"standard-version": "^9.5.0",
96-
"ts-jest": "^29.4.1",
97-
"typescript": "5.9.2",
98-
"vite": "^7.1.5",
99-
"vite-tsconfig-paths": "^5.1.4",
96+
"ts-jest": "^29.4.6",
97+
"typescript": "5.9.3",
98+
"vite": "^7.3.1",
99+
"vite-tsconfig-paths": "^6.0.4",
100100
"web-vitals": "^5.1.0"
101101
},
102102
"release": {
@@ -147,6 +147,5 @@
147147
"transformIgnorePatterns": [
148148
"<rootDir>/node_modules/(?!variables|react-syntax-highlighter)"
149149
]
150-
},
151-
"packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e"
150+
}
152151
}

0 commit comments

Comments
 (0)