Skip to content

Commit 4b1938c

Browse files
authored
Merge pull request #23 from moevm/Dudkin-frontend
Dudkin frontend
2 parents 4ddf3a3 + 65ab51c commit 4b1938c

29 files changed

+1227
-40
lines changed

dentistry/frontend/.gitignore

Lines changed: 0 additions & 24 deletions
This file was deleted.

dentistry/frontend/README.md

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,10 @@
11
# React + Vite
22

3-
This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
3+
Use `npm run dev` to start the development server.
44

5-
Currently, two official plugins are available:
5+
Use `VITE_API_MOCK` to mock the API. Set it to `true` to use the mock API, or `false` to use the real API.
6+
Command to start the development server with mock API:
67

7-
- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react) uses [Babel](https://babeljs.io/) for Fast Refresh
8-
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh
9-
10-
## Expanding the ESLint configuration
11-
12-
If you are developing a production application, we recommend using TypeScript with type-aware lint rules enabled. Check out the [TS template](https://github.com/vitejs/vite/tree/main/packages/create-vite/template-react-ts) for information on how to integrate TypeScript and [`typescript-eslint`](https://typescript-eslint.io) in your project.
8+
```bash
9+
VITE_API_MOCK=true npm run dev
10+
```

dentistry/frontend/package-lock.json

Lines changed: 256 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dentistry/frontend/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
"preview": "vite preview"
1111
},
1212
"dependencies": {
13+
"axios": "^1.8.4",
1314
"clsx": "^2.1.1",
1415
"react": "^19.0.0",
1516
"react-dom": "^19.0.0",
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
import styles from "./Button.module.css";
2+
3+
const AuthButton = ({ children, type = "submit", onClick, disabled }) => (
4+
<button
5+
type={type}
6+
className={styles.button}
7+
onClick={onClick}
8+
disabled={disabled}
9+
>
10+
{children}
11+
</button>
12+
);
13+
14+
export default AuthButton;

0 commit comments

Comments
 (0)