mirror of
https://github.com/fastapi/full-stack-fastapi-template.git
synced 2026-11-03 20:36:27 +00:00
Compare commits
593 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| d40de23896 | |||
| 46e9e1926e | |||
| 43fac49a14 | |||
| 64eac127f0 | |||
| 3d2fffd138 | |||
| a8fa3455ab | |||
| 3c1f7c4cdb | |||
| 2720308701 | |||
| 6c3323547b | |||
| 7a542cade6 | |||
| e6c973060a | |||
| 4c65c018ac | |||
| 0d2a360857 | |||
| 12b2a95a58 | |||
| de9661fc4f | |||
| 0564d65041 | |||
| da603ebaac | |||
| 61e161bfb9 | |||
| c3577c0526 | |||
| ca37099b01 | |||
| d74c794054 | |||
| cdc5fba430 | |||
| 9ba793038e | |||
| 540766b961 | |||
| 1f332b89b4 | |||
| 6ab7a40cdd | |||
| 03bca13d17 | |||
| e8418cb027 | |||
| 8ab41e3b24 | |||
| 6a49131003 | |||
| 97a4346c98 | |||
| 689d7105e1 | |||
| 7107f7e83a | |||
| 730c6e9ebb | |||
| a0fe8a236f | |||
| ca9cecf6c1 | |||
| d0d06d18d7 | |||
| 458fddd772 | |||
| 608bb80106 | |||
| 9fe3a4d221 | |||
| a45258f520 | |||
| e3ead78f84 | |||
| d5ee4a7276 | |||
| 352cded1cf | |||
| f8c4e68472 | |||
| 4cab9e972f | |||
| fe3bafc6f6 | |||
| 22b884a69e | |||
| bbfa6ec46c | |||
| 9ceac2cfaf | |||
| 1690b598aa | |||
| dd11319612 | |||
| e75db847d8 | |||
| 23435b1053 | |||
| c68ca3b989 | |||
| 54cd72e08d | |||
| 8574ea4397 | |||
| fb2a02345b | |||
| ab7c28c038 | |||
| e0c80050f1 | |||
| 00e55ccabb | |||
| 565ddb61f7 | |||
| a42f89b892 | |||
| 7201b88628 | |||
| 92460ee1fe | |||
| 3a5611aa7f | |||
| fcad8f8270 | |||
| 87747c30cb | |||
| e5236814e0 | |||
| 4fcaa97ac6 | |||
| be7ff79aa7 | |||
| 88eade2231 | |||
| 63f167d462 | |||
| 11f2fc90d1 | |||
| 2e0db3f9b4 | |||
| 2059d2e271 | |||
| ac9319d841 | |||
| f21b70bd8c | |||
| 9f94fda46d | |||
| 7b0c7e8a1a | |||
| eadcf5c9d5 | |||
| e36bcf0e87 | |||
| bdf5e26363 | |||
| bd6f0d4edd | |||
| 650a33d98b | |||
| 44b2e67ced | |||
| 3826039f51 | |||
| 7d2307bb9a | |||
| 7f4befa0a9 | |||
| d512a6a5f8 | |||
| 6a91475bf6 | |||
| 9db30ed04c | |||
| c5b3d05aa3 | |||
| 31892f31d5 | |||
| a5d93de972 | |||
| c9a09fca7d | |||
| 9581560edb | |||
| 68726e4191 | |||
| 0f3423a818 | |||
| b376e16adb | |||
| 7ce4aa0904 | |||
| 6250e97f4e | |||
| ee316abde0 | |||
| 27a81ea023 | |||
| e4022a9502 | |||
| 686f786b13 | |||
| 1321241572 | |||
| 5a7c5b1a10 | |||
| a6e5812021 | |||
| a8863840dc | |||
| 153a295767 | |||
| d3a14929c3 | |||
| 4e678c3925 | |||
| ac9eddd9cf | |||
| 5521b23141 | |||
| 84e4d7491b | |||
| e4d3771e01 | |||
| 901a6d0508 | |||
| 8a86ce29de | |||
| fdc0acb941 | |||
| e430446bac | |||
| 00a85c1b2c | |||
| c04e324207 | |||
| fd39ace1bf | |||
| 1df9cfde7e | |||
| 996f22129b | |||
| 4b708d1187 | |||
| 7450503938 | |||
| e6e3063106 | |||
| 3318f26df1 | |||
| 2fcdf03fcb | |||
| 272c4c2dc6 | |||
| 69743fa3ca | |||
| 429e7e8379 | |||
| 2476ee7f36 | |||
| 83acb33908 | |||
| 8c2532a5c3 | |||
| 61b7cd673a | |||
| 6106b898e3 | |||
| 0c228d554b | |||
| d27647ffe0 | |||
| 6c08a05f48 | |||
| b9ca4d3ab2 | |||
| 34b09af4f3 | |||
| f1c3145e87 | |||
| 73e94a6680 | |||
| 725ea4b302 | |||
| 54a797b9bf | |||
| bf91b30e98 | |||
| 91ce13e8f2 | |||
| 9fab11a9f8 | |||
| 59d9d82716 | |||
| 838a974069 | |||
| 1d95d01fc7 | |||
| 758f7507e8 | |||
| 057840589b | |||
| 53ed9a5e22 | |||
| 12859acccf | |||
| 282962851d | |||
| 1834c107ab | |||
| fe886d0d6f | |||
| 10ee759780 | |||
| a742011bec | |||
| e3be7f8959 | |||
| af76b6d075 | |||
| 40261268f8 | |||
| 2002447e06 | |||
| 6704482e5a | |||
| e4cf037d38 | |||
| 116f2bbf77 | |||
| c788f943ef | |||
| fa9c79ead4 | |||
| c2fdc6680f | |||
| 493d4ed13a | |||
| 22892d7507 | |||
| 9272d369e6 | |||
| 2604dcbaef | |||
| c3f5427c4a | |||
| bf1243ef85 | |||
| 8f35b76384 | |||
| 98a515fb07 | |||
| 0f488061a6 | |||
| a1b68b17de | |||
| 66b92191c3 | |||
| 20799b39e0 | |||
| 7eaae4d2aa | |||
| 80fb16c0a9 | |||
| 1d36577d79 | |||
| efad48a2fb | |||
| ad9375169e | |||
| 0278f13186 | |||
| 75ac042c22 | |||
| 73f37aae51 | |||
| c1e3b2668b | |||
| 06cd9aa762 | |||
| 2bf8d79119 | |||
| b50dbc36ea | |||
| 8d0e240af4 | |||
| 740b1f84fd | |||
| 8a584cafb4 | |||
| c34911cb86 | |||
| 77c6633b07 | |||
| 53723696f3 | |||
| 0f37fc60fa | |||
| a4b99df319 | |||
| bec7e0ee42 | |||
| 483d9b5966 | |||
| adeb872199 | |||
| 83efa4f28d | |||
| ea6b168f19 | |||
| 37c961e051 | |||
| 176476bcad | |||
| de79cc2626 | |||
| 45d94ee6f8 | |||
| 66e7f918e2 | |||
| d573e0595d | |||
| 42572c56f6 | |||
| 963bd8a77d | |||
| 9b1d095aee | |||
| 77b524df60 | |||
| c612641e92 | |||
| fd74a4de94 | |||
| 5882a2952b | |||
| 978e1f8151 | |||
| 3c643e3a21 | |||
| 3f913b786b | |||
| 74b0399eb4 | |||
| 55221e457c | |||
| b3561c43a0 | |||
| 9cfa77e265 | |||
| a0c6e96b21 | |||
| f745ebf87f | |||
| 8d49d7e3f7 | |||
| 68f6a33d8e | |||
| 2b5d798344 | |||
| 2e107b4d0a | |||
| 8694881478 | |||
| 64fbc8e5d8 | |||
| bac4d8f5a2 | |||
| c6e99db70f | |||
| 0c22075d52 | |||
| c9c9d6c364 | |||
| 6e75aa3710 | |||
| 632f1ac4b3 | |||
| 1a2baee6ad | |||
| 62fa5d8993 | |||
| 89ed10be98 | |||
| 46e904fd61 | |||
| 0162fd36a0 | |||
| d65a69e89a | |||
| 7ffcd2c357 | |||
| 0a68dd19a1 | |||
| e0f969a692 | |||
| 598b74bda6 | |||
| 40e99d2113 | |||
| e5e7308f95 | |||
| e7d18f11c1 | |||
| 1c5d2de404 | |||
| 748490a8bc | |||
| 8366155c77 | |||
| 77992a5d38 | |||
| 984cc5847e | |||
| 0b473f5b6f | |||
| 46e86d4d4d | |||
| dceea46002 | |||
| da58e61dcc | |||
| 8f267e9b60 | |||
| e178566027 | |||
| 028caf1421 | |||
| fed081f586 | |||
| 83f8c00bc6 | |||
| 3f6219634d | |||
| 137a133b42 | |||
| 88635c61d7 | |||
| a8e6c5d025 | |||
| 4758dda2f9 | |||
| 9df6335bab | |||
| 54ff123ebb | |||
| 8febe03244 | |||
| 62becd2482 | |||
| 4ff9b341e1 | |||
| a0a5e39c07 | |||
| db104eb455 | |||
| 3bdb6dd8d2 | |||
| 4d3096cc77 | |||
| f47138448f | |||
| 417f1da8c5 | |||
| f5032c2209 | |||
| e843c15863 | |||
| 2e95aea2bf | |||
| 1b9ba20e13 | |||
| 9ec0244de0 | |||
| 2ea21b08b5 | |||
| 3c8d2f1111 | |||
| aa00321ca3 | |||
| 12203cc205 | |||
| 6eb43ec7bd | |||
| b11c2a3ef5 | |||
| d5b456cc2a | |||
| 5fee1fdc6a | |||
| 943eaeb337 | |||
| f5e66ea69a | |||
| f813161912 | |||
| 61174f1806 | |||
| cce6f884d3 | |||
| 4db05d6abe | |||
| 6e0881d284 | |||
| 0d1da3e09d | |||
| 4434677497 | |||
| e5e6ca5158 | |||
| 2906473557 | |||
| d05e93d396 | |||
| 67be5fa7a5 | |||
| 6dbc9aa7b0 | |||
| 83ad72e193 | |||
| d5eca12ed1 | |||
| 6f778fdcc3 | |||
| 68535c6eda | |||
| 7b5c348cef | |||
| 36ddc1a190 | |||
| 5f1ba46404 | |||
| d8bdcb2ef2 | |||
| 780e6691a0 | |||
| 3f2005a427 | |||
| 12a5fce8b2 | |||
| 92a44c6e70 | |||
| eb0b2c2f45 | |||
| 5da9b867c4 | |||
| 404a712063 | |||
| f84f57884f | |||
| 162029d230 | |||
| 2198748628 | |||
| fce1c2a5cf | |||
| 32dc098c24 | |||
| 96e42344e7 | |||
| c678c2e5f0 | |||
| 981f821e23 | |||
| a650663d8a | |||
| 47afef8720 | |||
| 918847682a | |||
| e4bfdfa856 | |||
| 948e7c92c6 | |||
| 51454b223e | |||
| b6c4e98922 | |||
| 53dd6ea4b2 | |||
| fe028c5ff9 | |||
| e3f1f69d15 | |||
| b0e228049d | |||
| af654fae06 | |||
| 0e33d6bc28 | |||
| f6a284fd6e | |||
| 96d2869c21 | |||
| ea32978f38 | |||
| 26acc1a6c4 | |||
| c1cfd729ee | |||
| 45d7b83b5f | |||
| f8dba14cdf | |||
| 8af907c763 | |||
| 0c51c5f66c | |||
| 6453dea7ff | |||
| 882f951e8a | |||
| c539db8c91 | |||
| 7c9815b167 | |||
| 283c9de1e9 | |||
| 74860873a0 | |||
| 2f5ccf5676 | |||
| cd53ad3fb6 | |||
| ac60caeaaa | |||
| 1503b5cd18 | |||
| e4387f4832 | |||
| ffacbad7ce | |||
| 6c9b1fa2ce | |||
| 531ecb75f7 | |||
| 3b4561848a | |||
| 88bd7fe68b | |||
| 453ccf5ca4 | |||
| 8028b3c8e3 | |||
| 277c1c2493 | |||
| be40eb6741 | |||
| 11099310f8 | |||
| 0dd78c5d84 | |||
| 0328e80eb8 | |||
| da01b69304 | |||
| 3a81472ff8 | |||
| dd414058f0 | |||
| c4aa1fbbb4 | |||
| bd615fc655 | |||
| cd3ecd4c04 | |||
| 2ff7bc813c | |||
| 0e74243a71 | |||
| 43934f1ecb | |||
| c71a101985 | |||
| cd7162372a | |||
| 7db5099493 | |||
| a7723743b4 | |||
| 02cce07150 | |||
| 7965f02a21 | |||
| 9f769cf63f | |||
| 4d95e382f0 | |||
| 1cca3804d3 | |||
| a855046127 | |||
| f0d68e872c | |||
| 92e758e035 | |||
| 37b03e37a5 | |||
| 08956affa8 | |||
| 5dde6a41da | |||
| 84f133ca2e | |||
| e51fe626ad | |||
| a4eebf0c0b | |||
| b9c9737741 | |||
| 1024bd7829 | |||
| 335e62fd54 | |||
| 893f5ff3ce | |||
| 399bd5b4e1 | |||
| e0a0bc4848 | |||
| 75159910d5 | |||
| 043409d6a5 | |||
| de5ab25785 | |||
| 084da0c71d | |||
| ee49a985d9 | |||
| d85f58fe2c | |||
| d1df85e809 | |||
| 83c65459d3 | |||
| 9f2c3d24a2 | |||
| 54ca043e27 | |||
| 521e6e4eda | |||
| 05bebffba1 | |||
| 6efd3ba9a0 | |||
| c067292fec | |||
| b64e374d76 | |||
| d18cf4b6be | |||
| e46b8d9421 | |||
| ccbdb30a87 | |||
| 2eb8f5b624 | |||
| 558b466d43 | |||
| 496c7090b3 | |||
| 50d2a3bfe1 | |||
| 1523c20cae | |||
| f8e35a5249 | |||
| 9f6f8f088b | |||
| ff5079079b | |||
| 7b05fc1f6d | |||
| 86ef743226 | |||
| ed34e5e170 | |||
| 322975dd6e | |||
| 55df823739 | |||
| 74e2604faf | |||
| 631980a876 | |||
| f178e58bfe | |||
| aee08490e5 | |||
| 42fd54e06b | |||
| 16997dabf0 | |||
| 7cffa83649 | |||
| 15f41f755b | |||
| f2eb1b5c5f | |||
| 6042eda4bc | |||
| ba1706b489 | |||
| c754a0058b | |||
| 2d553dda53 | |||
| 846dd9e81a | |||
| d4df197c59 | |||
| 87afb074a3 | |||
| 98a2d7ddcf | |||
| b95dea6d26 | |||
| 88c83cc06c | |||
| 3e6ed0157e | |||
| b0f6195827 | |||
| 30832076f5 | |||
| aa71abedcc | |||
| 14129f7a50 | |||
| 414864d848 | |||
| 953e9e5416 | |||
| b7d2df2f81 | |||
| a21c57ab2b | |||
| e34527325b | |||
| 19764d5307 | |||
| 3aad3fb877 | |||
| 61fa9431b7 | |||
| 24c4f13629 | |||
| e684f3c8d6 | |||
| d3d370cad0 | |||
| c23c91bd4e | |||
| 6768359244 | |||
| a2e3a8ae11 | |||
| f5612ed7cd | |||
| 12a13b4108 | |||
| db7ea2cbbe | |||
| 86d2fcc2e8 | |||
| 67e3f35491 | |||
| 1c3e464acd | |||
| 372c9f8f91 | |||
| 8d52d018b4 | |||
| 88e1a607b0 | |||
| 6047623ad1 | |||
| 0a5f1025d6 | |||
| 172bfd9349 | |||
| 79883c879f | |||
| 721a44ab2f | |||
| ddb4235bfe | |||
| 2939b7723b | |||
| 4d5b0a065c | |||
| 3793150fe4 | |||
| ab0d1bb12f | |||
| 3136437bcb | |||
| b9ec1943eb | |||
| fe7f4f7949 | |||
| b67fb44e5b | |||
| 945fbc7699 | |||
| 109a7454c7 | |||
| 38843cbe28 | |||
| 1030118247 | |||
| 08dd87d0f2 | |||
| 6a8fc240b3 | |||
| c297e9ee9e | |||
| 7e5ca88dc2 | |||
| 451c656fb0 | |||
| 911223516c | |||
| 1f666c4907 | |||
| 32227c4020 | |||
| cdc7b50fec | |||
| 284527b7bc | |||
| 6ed7aee371 | |||
| 39325ad421 | |||
| b3a77946cb | |||
| 9b2e5813ae | |||
| 55ad3b21ee | |||
| d2020c1a37 | |||
| 6fc03d1bf4 | |||
| 0435937f8e | |||
| 8d9af8cb80 | |||
| 4fc9610175 | |||
| 4b6fb7c465 | |||
| 81048277c7 | |||
| fa97b372b4 | |||
| c8104d8ced | |||
| 7ed8694643 | |||
| 4cd67f3483 | |||
| b262c2053c | |||
| 651643982b | |||
| 224d0e31a8 | |||
| 87254dd79e | |||
| 68a7fe0899 | |||
| 8fe66c1cc1 | |||
| d87b6391b5 | |||
| 889a9bf5bf | |||
| 44ff5730b7 | |||
| e64c9100ec | |||
| a292dbe10d | |||
| 79d240f5b7 | |||
| 110a59c71d | |||
| 2062b5b671 | |||
| 07b568b4f6 | |||
| 8a8a90459d | |||
| eb88b52ff8 | |||
| 18a5cb21db | |||
| 46ac6a3c6f | |||
| 97d04cd7ff | |||
| b3a49ae32e | |||
| 4af652aa73 | |||
| ad3580703c | |||
| 2241d75131 | |||
| 33b379bd46 | |||
| bbad34aa8d | |||
| e8c73ff614 | |||
| 644de7f186 | |||
| 90e3e337cb | |||
| 2fb7354923 | |||
| 05bc1412b3 | |||
| 375170c386 | |||
| 5005e5a5c1 | |||
| 77040adf86 | |||
| 65c66f2050 | |||
| 8187a5283f | |||
| 66c4ff169d | |||
| d7d245a108 | |||
| 6eff776fc1 | |||
| de57a7bac1 | |||
| 0f082d1265 | |||
| 5a138697ec | |||
| 79ed422871 | |||
| d275c6224b | |||
| 972714512b | |||
| 4b9285643a | |||
| cdf9a6548e | |||
| 10c6cc72eb | |||
| 7351d21fae | |||
| 974340c8ff | |||
| 572f513458 | |||
| b4c34c63d6 | |||
| ee82165ec7 | |||
| e46ba68301 | |||
| 7a6107ff41 | |||
| df94e73a5a |
@@ -1,6 +1,14 @@
|
|||||||
# Domain
|
# Domain
|
||||||
# This would be set to the production domain with an env var on deployment
|
# This would be set to the production domain with an env var on deployment
|
||||||
|
# used by Traefik to transmit traffic and aqcuire TLS certificates
|
||||||
DOMAIN=localhost
|
DOMAIN=localhost
|
||||||
|
# To test the local Traefik config
|
||||||
|
# DOMAIN=localhost.tiangolo.com
|
||||||
|
|
||||||
|
# Used by the backend to generate links in emails to the frontend
|
||||||
|
FRONTEND_HOST=http://localhost:5173
|
||||||
|
# In staging and production, set this env var to the frontend host, e.g.
|
||||||
|
# FRONTEND_HOST=https://dashboard.example.com
|
||||||
|
|
||||||
# Environment: local, staging, production
|
# Environment: local, staging, production
|
||||||
ENVIRONMENT=local
|
ENVIRONMENT=local
|
||||||
|
|||||||
+37
-7
@@ -1,16 +1,46 @@
|
|||||||
version: 2
|
version: 2
|
||||||
updates:
|
updates:
|
||||||
# GitHub Actions
|
# GitHub Actions
|
||||||
- package-ecosystem: "github-actions"
|
- package-ecosystem: github-actions
|
||||||
directory: "/"
|
directory: /
|
||||||
schedule:
|
schedule:
|
||||||
interval: "daily"
|
interval: daily
|
||||||
commit-message:
|
commit-message:
|
||||||
prefix: ⬆
|
prefix: ⬆
|
||||||
# Python
|
labels: [dependencies, internal]
|
||||||
- package-ecosystem: "pip"
|
# Python uv
|
||||||
directory: "/"
|
- package-ecosystem: uv
|
||||||
|
directory: /
|
||||||
schedule:
|
schedule:
|
||||||
interval: "daily"
|
interval: weekly
|
||||||
commit-message:
|
commit-message:
|
||||||
prefix: ⬆
|
prefix: ⬆
|
||||||
|
labels: [dependencies, internal]
|
||||||
|
# bun
|
||||||
|
- package-ecosystem: bun
|
||||||
|
directory: /
|
||||||
|
schedule:
|
||||||
|
interval: weekly
|
||||||
|
commit-message:
|
||||||
|
prefix: ⬆
|
||||||
|
labels: [dependencies, internal]
|
||||||
|
ignore:
|
||||||
|
- dependency-name: "@hey-api/openapi-ts"
|
||||||
|
# Docker
|
||||||
|
- package-ecosystem: docker
|
||||||
|
directories:
|
||||||
|
- /backend
|
||||||
|
- /frontend
|
||||||
|
schedule:
|
||||||
|
interval: weekly
|
||||||
|
commit-message:
|
||||||
|
prefix: ⬆
|
||||||
|
labels: [dependencies, internal]
|
||||||
|
# Docker Compose
|
||||||
|
- package-ecosystem: docker-compose
|
||||||
|
directory: /
|
||||||
|
schedule:
|
||||||
|
interval: weekly
|
||||||
|
commit-message:
|
||||||
|
prefix: ⬆
|
||||||
|
labels: [dependencies, internal]
|
||||||
|
|||||||
@@ -0,0 +1,25 @@
|
|||||||
|
docs:
|
||||||
|
- all:
|
||||||
|
- changed-files:
|
||||||
|
- any-glob-to-any-file:
|
||||||
|
- '**/*.md'
|
||||||
|
- all-globs-to-all-files:
|
||||||
|
- '!frontend/**'
|
||||||
|
- '!backend/**'
|
||||||
|
- '!.github/**'
|
||||||
|
- '!scripts/**'
|
||||||
|
- '!.gitignore'
|
||||||
|
- '!.pre-commit-config.yaml'
|
||||||
|
|
||||||
|
internal:
|
||||||
|
- all:
|
||||||
|
- changed-files:
|
||||||
|
- any-glob-to-any-file:
|
||||||
|
- .github/**
|
||||||
|
- scripts/**
|
||||||
|
- .gitignore
|
||||||
|
- .pre-commit-config.yaml
|
||||||
|
- all-globs-to-all-files:
|
||||||
|
- '!./**/*.md'
|
||||||
|
- '!frontend/**'
|
||||||
|
- '!backend/**'
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
name: Add to Project
|
||||||
|
|
||||||
|
on:
|
||||||
|
pull_request_target:
|
||||||
|
issues:
|
||||||
|
types:
|
||||||
|
- opened
|
||||||
|
- reopened
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
add-to-project:
|
||||||
|
name: Add to project
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/add-to-project@v1.0.2
|
||||||
|
with:
|
||||||
|
project-url: https://github.com/orgs/fastapi/projects/2
|
||||||
|
github-token: ${{ secrets.PROJECTS_TOKEN }}
|
||||||
@@ -27,6 +27,6 @@ jobs:
|
|||||||
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
|
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v6
|
||||||
- run: docker compose -f docker-compose.yml --project-name ${{ secrets.STACK_NAME_PRODUCTION }} build
|
- run: docker compose -f compose.yml --project-name ${{ secrets.STACK_NAME_PRODUCTION }} build
|
||||||
- run: docker compose -f docker-compose.yml --project-name ${{ secrets.STACK_NAME_PRODUCTION }} up -d
|
- run: docker compose -f compose.yml --project-name ${{ secrets.STACK_NAME_PRODUCTION }} up -d
|
||||||
|
|||||||
@@ -27,6 +27,6 @@ jobs:
|
|||||||
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
|
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v6
|
||||||
- run: docker compose -f docker-compose.yml --project-name ${{ secrets.STACK_NAME_STAGING }} build
|
- run: docker compose -f compose.yml --project-name ${{ secrets.STACK_NAME_STAGING }} build
|
||||||
- run: docker compose -f docker-compose.yml --project-name ${{ secrets.STACK_NAME_STAGING }} up -d
|
- run: docker compose -f compose.yml --project-name ${{ secrets.STACK_NAME_STAGING }} up -d
|
||||||
|
|||||||
@@ -0,0 +1,19 @@
|
|||||||
|
name: "Conflict detector"
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
pull_request_target:
|
||||||
|
types: [synchronize]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
main:
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
pull-requests: write
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Check if PRs have merge conflicts
|
||||||
|
uses: eps1lon/actions-label-merge-conflict@v3
|
||||||
|
with:
|
||||||
|
dirtyLabel: "conflicts"
|
||||||
|
repoToken: "${{ secrets.GITHUB_TOKEN }}"
|
||||||
|
commentOnDirty: "This pull request has a merge conflict that needs to be resolved."
|
||||||
@@ -2,30 +2,54 @@ name: Issue Manager
|
|||||||
|
|
||||||
on:
|
on:
|
||||||
schedule:
|
schedule:
|
||||||
- cron: "0 0 * * *"
|
- cron: "21 17 * * *"
|
||||||
issue_comment:
|
issue_comment:
|
||||||
types:
|
types:
|
||||||
- created
|
- created
|
||||||
- edited
|
|
||||||
issues:
|
issues:
|
||||||
types:
|
types:
|
||||||
- labeled
|
- labeled
|
||||||
|
pull_request_target:
|
||||||
|
types:
|
||||||
|
- labeled
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
issues: write
|
issues: write
|
||||||
|
pull-requests: write
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
issue-manager:
|
issue-manager:
|
||||||
|
if: github.repository_owner == 'fastapi'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: tiangolo/issue-manager@0.5.0
|
- name: Dump GitHub context
|
||||||
|
env:
|
||||||
|
GITHUB_CONTEXT: ${{ toJson(github) }}
|
||||||
|
run: echo "$GITHUB_CONTEXT"
|
||||||
|
- uses: tiangolo/issue-manager@0.6.0
|
||||||
with:
|
with:
|
||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
config: >
|
config: >
|
||||||
{
|
{
|
||||||
"answered": {
|
"answered": {
|
||||||
"users": ["tiangolo"],
|
|
||||||
"delay": 864000,
|
"delay": 864000,
|
||||||
"message": "Assuming the original issue was solved, it will be automatically closed now. But feel free to add more comments or create new issues."
|
"message": "Assuming the original need was handled, this will be automatically closed now. But feel free to add more comments or create new issues or PRs."
|
||||||
|
},
|
||||||
|
"waiting": {
|
||||||
|
"delay": 2628000,
|
||||||
|
"message": "As this PR has been waiting for the original user for a while but seems to be inactive, it's now going to be closed. But if there's anyone interested, feel free to create a new PR.",
|
||||||
|
"reminder": {
|
||||||
|
"before": "P3D",
|
||||||
|
"message": "Heads-up: this will be closed in 3 days unless there's new activity."
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"invalid": {
|
||||||
|
"delay": 0,
|
||||||
|
"message": "This was marked as invalid and will be closed now. If this is an error, please provide additional details."
|
||||||
|
},
|
||||||
|
"maybe-ai": {
|
||||||
|
"delay": 0,
|
||||||
|
"message": "This was marked as potentially AI generated and will be closed now. If this is an error, please provide additional details, make sure to read the docs about contributing and AI."
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,33 @@
|
|||||||
|
name: Labels
|
||||||
|
on:
|
||||||
|
pull_request_target:
|
||||||
|
types:
|
||||||
|
- opened
|
||||||
|
- synchronize
|
||||||
|
- reopened
|
||||||
|
# For label-checker
|
||||||
|
- labeled
|
||||||
|
- unlabeled
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
labeler:
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
pull-requests: write
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/labeler@v6
|
||||||
|
if: ${{ github.event.action != 'labeled' && github.event.action != 'unlabeled' }}
|
||||||
|
- run: echo "Done adding labels"
|
||||||
|
# Run this after labeler applied labels
|
||||||
|
check-labels:
|
||||||
|
needs:
|
||||||
|
- labeler
|
||||||
|
permissions:
|
||||||
|
pull-requests: read
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: docker://agilepathway/pull-request-label-checker:latest
|
||||||
|
with:
|
||||||
|
one_of: breaking,security,feature,bug,refactor,upgrade,docs,lang-all,internal
|
||||||
|
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
@@ -12,9 +12,9 @@ on:
|
|||||||
description: PR number
|
description: PR number
|
||||||
required: true
|
required: true
|
||||||
debug_enabled:
|
debug_enabled:
|
||||||
description: 'Run the build with tmate debugging enabled (https://github.com/marketplace/actions/debugging-with-tmate)'
|
description: "Run the build with tmate debugging enabled (https://github.com/marketplace/actions/debugging-with-tmate)"
|
||||||
required: false
|
required: false
|
||||||
default: 'false'
|
default: "false"
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
latest-changes:
|
latest-changes:
|
||||||
@@ -26,16 +26,15 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
GITHUB_CONTEXT: ${{ toJson(github) }}
|
GITHUB_CONTEXT: ${{ toJson(github) }}
|
||||||
run: echo "$GITHUB_CONTEXT"
|
run: echo "$GITHUB_CONTEXT"
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
with:
|
with:
|
||||||
# To allow latest-changes to commit to the main branch
|
# To allow latest-changes to commit to the main branch
|
||||||
token: ${{ secrets.LATEST_CHANGES }}
|
token: ${{ secrets.LATEST_CHANGES }}
|
||||||
- uses: docker://tiangolo/latest-changes:0.3.0
|
- uses: tiangolo/latest-changes@0.4.1
|
||||||
# - uses: tiangolo/latest-changes@main
|
|
||||||
with:
|
with:
|
||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
latest_changes_file: ./release-notes.md
|
latest_changes_file: ./release-notes.md
|
||||||
latest_changes_header: '## Latest Changes'
|
latest_changes_header: "## Latest Changes"
|
||||||
end_regex: '^## '
|
end_regex: "^## "
|
||||||
debug_logs: true
|
debug_logs: true
|
||||||
label_header_prefix: '### '
|
label_header_prefix: "### "
|
||||||
|
|||||||
@@ -16,16 +16,40 @@ on:
|
|||||||
default: 'false'
|
default: 'false'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
changes:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
# Set job outputs to values from filter step
|
||||||
|
outputs:
|
||||||
|
changed: ${{ steps.filter.outputs.changed }}
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v6
|
||||||
|
# For pull requests it's not necessary to checkout the code but for the main branch it is
|
||||||
|
- uses: dorny/paths-filter@v3
|
||||||
|
id: filter
|
||||||
|
with:
|
||||||
|
filters: |
|
||||||
|
changed:
|
||||||
|
- backend/**
|
||||||
|
- frontend/**
|
||||||
|
- .env
|
||||||
|
- compose*.yml
|
||||||
|
- .github/workflows/playwright.yml
|
||||||
|
|
||||||
test:
|
test-playwright:
|
||||||
|
needs:
|
||||||
|
- changes
|
||||||
|
if: ${{ needs.changes.outputs.changed == 'true' }}
|
||||||
timeout-minutes: 60
|
timeout-minutes: 60
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
shardIndex: [1, 2, 3, 4]
|
||||||
|
shardTotal: [4]
|
||||||
|
fail-fast: false
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v6
|
||||||
- uses: actions/setup-node@v4
|
- uses: oven-sh/setup-bun@v2
|
||||||
with:
|
- uses: actions/setup-python@v6
|
||||||
node-version: lts/*
|
|
||||||
- uses: actions/setup-python@v5
|
|
||||||
with:
|
with:
|
||||||
python-version: '3.10'
|
python-version: '3.10'
|
||||||
- name: Setup tmate session
|
- name: Setup tmate session
|
||||||
@@ -33,34 +57,65 @@ jobs:
|
|||||||
if: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.debug_enabled == 'true' }}
|
if: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.debug_enabled == 'true' }}
|
||||||
with:
|
with:
|
||||||
limit-access-to-actor: true
|
limit-access-to-actor: true
|
||||||
- name: Install dependencies
|
- name: Install uv
|
||||||
run: npm ci
|
uses: astral-sh/setup-uv@v7
|
||||||
working-directory: frontend
|
- run: uv sync
|
||||||
- name: Install Playwright Browsers
|
working-directory: backend
|
||||||
run: npx playwright install --with-deps
|
- run: bun ci
|
||||||
working-directory: frontend
|
working-directory: frontend
|
||||||
|
- run: bash scripts/generate-client.sh
|
||||||
- run: docker compose build
|
- run: docker compose build
|
||||||
- run: docker compose down -v --remove-orphans
|
- run: docker compose down -v --remove-orphans
|
||||||
- run: docker compose up -d
|
|
||||||
- name: Run Playwright tests
|
- name: Run Playwright tests
|
||||||
run: npx playwright test
|
run: docker compose run --rm playwright bunx playwright test --fail-on-flaky-tests --trace=retain-on-failure --shard=${{ matrix.shardIndex }}/${{ matrix.shardTotal }}
|
||||||
working-directory: frontend
|
|
||||||
- run: docker compose down -v --remove-orphans
|
- run: docker compose down -v --remove-orphans
|
||||||
- uses: actions/upload-artifact@v4
|
- name: Upload blob report to GitHub Actions Artifacts
|
||||||
if: always()
|
if: ${{ !cancelled() }}
|
||||||
|
uses: actions/upload-artifact@v6
|
||||||
with:
|
with:
|
||||||
name: playwright-report
|
name: blob-report-${{ matrix.shardIndex }}
|
||||||
path: frontend/playwright-report/
|
path: frontend/blob-report
|
||||||
|
include-hidden-files: true
|
||||||
|
retention-days: 1
|
||||||
|
|
||||||
|
merge-playwright-reports:
|
||||||
|
needs:
|
||||||
|
- test-playwright
|
||||||
|
- changes
|
||||||
|
# Merge reports after playwright-tests, even if some shards have failed
|
||||||
|
if: ${{ !cancelled() && needs.changes.outputs.changed == 'true' }}
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v6
|
||||||
|
- uses: oven-sh/setup-bun@v2
|
||||||
|
- name: Install dependencies
|
||||||
|
run: bun ci
|
||||||
|
- name: Download blob reports from GitHub Actions Artifacts
|
||||||
|
uses: actions/download-artifact@v7
|
||||||
|
with:
|
||||||
|
path: frontend/all-blob-reports
|
||||||
|
pattern: blob-report-*
|
||||||
|
merge-multiple: true
|
||||||
|
- name: Merge into HTML Report
|
||||||
|
run: bunx playwright merge-reports --reporter html ./all-blob-reports
|
||||||
|
working-directory: frontend
|
||||||
|
- name: Upload HTML report
|
||||||
|
uses: actions/upload-artifact@v6
|
||||||
|
with:
|
||||||
|
name: html-report--attempt-${{ github.run_attempt }}
|
||||||
|
path: frontend/playwright-report
|
||||||
retention-days: 30
|
retention-days: 30
|
||||||
|
include-hidden-files: true
|
||||||
|
|
||||||
# https://github.com/marketplace/actions/alls-green#why
|
# https://github.com/marketplace/actions/alls-green#why
|
||||||
e2e-alls-green: # This job does nothing and is only used for the branch protection
|
alls-green-playwright: # This job does nothing and is only used for the branch protection
|
||||||
if: always()
|
if: always()
|
||||||
needs:
|
needs:
|
||||||
- test
|
- test-playwright
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Decide whether the needed jobs succeeded or failed
|
- name: Decide whether the needed jobs succeeded or failed
|
||||||
uses: re-actors/alls-green@release/v1
|
uses: re-actors/alls-green@release/v1
|
||||||
with:
|
with:
|
||||||
jobs: ${{ toJSON(needs) }}
|
jobs: ${{ toJSON(needs) }}
|
||||||
|
allowed-skips: test-playwright
|
||||||
|
|||||||
@@ -0,0 +1,94 @@
|
|||||||
|
name: pre-commit
|
||||||
|
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
types:
|
||||||
|
- opened
|
||||||
|
- synchronize
|
||||||
|
|
||||||
|
env:
|
||||||
|
# Forks and Dependabot don't have access to secrets
|
||||||
|
HAS_SECRETS: ${{ secrets.PRE_COMMIT != '' }}
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
pre-commit:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Dump GitHub context
|
||||||
|
env:
|
||||||
|
GITHUB_CONTEXT: ${{ toJson(github) }}
|
||||||
|
run: echo "$GITHUB_CONTEXT"
|
||||||
|
- uses: actions/checkout@v6
|
||||||
|
name: Checkout PR for own repo
|
||||||
|
if: env.HAS_SECRETS == 'true'
|
||||||
|
with:
|
||||||
|
# To be able to commit it needs to fetch the head of the branch, not the
|
||||||
|
# merge commit
|
||||||
|
ref: ${{ github.head_ref }}
|
||||||
|
# And it needs the full history to be able to compute diffs
|
||||||
|
fetch-depth: 0
|
||||||
|
# A token other than the default GITHUB_TOKEN is needed to be able to trigger CI
|
||||||
|
token: ${{ secrets.PRE_COMMIT }}
|
||||||
|
# pre-commit lite ci needs the default checkout configs to work
|
||||||
|
- uses: actions/checkout@v6
|
||||||
|
name: Checkout PR for fork
|
||||||
|
if: env.HAS_SECRETS == 'false'
|
||||||
|
with:
|
||||||
|
# To be able to commit it needs the head branch of the PR, the remote one
|
||||||
|
ref: ${{ github.event.pull_request.head.sha }}
|
||||||
|
fetch-depth: 0
|
||||||
|
- uses: oven-sh/setup-bun@v2
|
||||||
|
- name: Set up Python
|
||||||
|
uses: actions/setup-python@v6
|
||||||
|
with:
|
||||||
|
python-version: "3.11"
|
||||||
|
- name: Setup uv
|
||||||
|
uses: astral-sh/setup-uv@v7
|
||||||
|
with:
|
||||||
|
cache-dependency-glob: |
|
||||||
|
requirements**.txt
|
||||||
|
pyproject.toml
|
||||||
|
uv.lock
|
||||||
|
- name: Install backend dependencies
|
||||||
|
run: uv sync --all-packages
|
||||||
|
- name: Install frontend dependencies
|
||||||
|
run: bun ci
|
||||||
|
- name: Run prek - pre-commit
|
||||||
|
id: precommit
|
||||||
|
run: uvx prek run --from-ref origin/${GITHUB_BASE_REF} --to-ref HEAD --show-diff-on-failure
|
||||||
|
continue-on-error: true
|
||||||
|
- name: Commit and push changes
|
||||||
|
if: env.HAS_SECRETS == 'true'
|
||||||
|
run: |
|
||||||
|
git config user.name "github-actions[bot]"
|
||||||
|
git config user.email "github-actions[bot]@users.noreply.github.com"
|
||||||
|
git add -A
|
||||||
|
if git diff --staged --quiet; then
|
||||||
|
echo "No changes to commit"
|
||||||
|
else
|
||||||
|
git commit -m "🎨 Auto format and update with pre-commit"
|
||||||
|
git push
|
||||||
|
fi
|
||||||
|
- uses: pre-commit-ci/lite-action@v1.1.0
|
||||||
|
if: env.HAS_SECRETS == 'false'
|
||||||
|
with:
|
||||||
|
msg: 🎨 Auto format and update with pre-commit
|
||||||
|
- name: Error out on pre-commit errors
|
||||||
|
if: steps.precommit.outcome == 'failure'
|
||||||
|
run: exit 1
|
||||||
|
|
||||||
|
# https://github.com/marketplace/actions/alls-green#why
|
||||||
|
pre-commit-alls-green: # This job does nothing and is only used for the branch protection
|
||||||
|
if: always()
|
||||||
|
needs:
|
||||||
|
- pre-commit
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Dump GitHub context
|
||||||
|
env:
|
||||||
|
GITHUB_CONTEXT: ${{ toJson(github) }}
|
||||||
|
run: echo "$GITHUB_CONTEXT"
|
||||||
|
- name: Decide whether the needed jobs succeeded or failed
|
||||||
|
uses: re-actors/alls-green@release/v1
|
||||||
|
with:
|
||||||
|
jobs: ${{ toJSON(needs) }}
|
||||||
@@ -2,31 +2,28 @@ name: Smokeshow
|
|||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_run:
|
workflow_run:
|
||||||
workflows: [Test]
|
workflows: [Test Backend]
|
||||||
types: [completed]
|
types: [completed]
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
smokeshow:
|
smokeshow:
|
||||||
if: ${{ github.event.workflow_run.conclusion == 'success' }}
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
permissions:
|
permissions:
|
||||||
actions: read
|
actions: read
|
||||||
statuses: write
|
statuses: write
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/setup-python@v5
|
- uses: actions/checkout@v6
|
||||||
|
- uses: actions/setup-python@v6
|
||||||
with:
|
with:
|
||||||
python-version: '3.9'
|
python-version: "3.13"
|
||||||
|
|
||||||
- run: pip install smokeshow
|
- run: pip install smokeshow
|
||||||
|
- uses: actions/download-artifact@v7
|
||||||
- uses: actions/download-artifact@v4
|
|
||||||
with:
|
with:
|
||||||
name: coverage-html
|
name: coverage-html
|
||||||
path: backend/htmlcov
|
path: backend/htmlcov
|
||||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
run-id: ${{ github.event.workflow_run.id }}
|
run-id: ${{ github.event.workflow_run.id }}
|
||||||
|
|
||||||
- run: smokeshow upload backend/htmlcov
|
- run: smokeshow upload backend/htmlcov
|
||||||
env:
|
env:
|
||||||
SMOKESHOW_GITHUB_STATUS_DESCRIPTION: Coverage {coverage-percentage}
|
SMOKESHOW_GITHUB_STATUS_DESCRIPTION: Coverage {coverage-percentage}
|
||||||
|
|||||||
@@ -0,0 +1,41 @@
|
|||||||
|
name: Test Backend
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
pull_request:
|
||||||
|
types:
|
||||||
|
- opened
|
||||||
|
- synchronize
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
test-backend:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v6
|
||||||
|
- name: Set up Python
|
||||||
|
uses: actions/setup-python@v6
|
||||||
|
with:
|
||||||
|
python-version: "3.10"
|
||||||
|
- name: Install uv
|
||||||
|
uses: astral-sh/setup-uv@v7
|
||||||
|
- run: docker compose down -v --remove-orphans
|
||||||
|
- run: docker compose up -d db mailcatcher
|
||||||
|
- name: Migrate DB
|
||||||
|
run: uv run bash scripts/prestart.sh
|
||||||
|
working-directory: backend
|
||||||
|
- name: Run tests
|
||||||
|
run: uv run bash scripts/tests-start.sh "Coverage for ${{ github.sha }}"
|
||||||
|
working-directory: backend
|
||||||
|
- run: docker compose down -v --remove-orphans
|
||||||
|
- name: Store coverage files
|
||||||
|
uses: actions/upload-artifact@v6
|
||||||
|
with:
|
||||||
|
name: coverage-html
|
||||||
|
path: backend/htmlcov
|
||||||
|
include-hidden-files: true
|
||||||
|
- name: Coverage report
|
||||||
|
run: uv run coverage report --fail-under=90
|
||||||
|
working-directory: backend
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
name: Test Docker Compose
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
pull_request:
|
||||||
|
types:
|
||||||
|
- opened
|
||||||
|
- synchronize
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
test-docker-compose:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v6
|
||||||
|
- run: docker compose build
|
||||||
|
- run: docker compose down -v --remove-orphans
|
||||||
|
- run: docker compose up -d --wait backend frontend adminer
|
||||||
|
- name: Test backend is up
|
||||||
|
run: curl http://localhost:8000/api/v1/utils/health-check
|
||||||
|
- name: Test frontend is up
|
||||||
|
run: curl http://localhost:5173
|
||||||
|
- run: docker compose down -v --remove-orphans
|
||||||
@@ -1,49 +0,0 @@
|
|||||||
name: Test
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- master
|
|
||||||
pull_request:
|
|
||||||
types:
|
|
||||||
- opened
|
|
||||||
- synchronize
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
|
|
||||||
test:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Set up Python
|
|
||||||
uses: actions/setup-python@v5
|
|
||||||
with:
|
|
||||||
python-version: '3.10'
|
|
||||||
|
|
||||||
- run: docker compose build
|
|
||||||
- run: docker compose down -v --remove-orphans
|
|
||||||
- run: docker compose up -d
|
|
||||||
- name: Lint
|
|
||||||
run: docker compose exec -T backend bash /app/scripts/lint.sh
|
|
||||||
- name: Run tests
|
|
||||||
run: docker compose exec -T backend bash /app/tests-start.sh "Coverage for ${{ github.sha }}"
|
|
||||||
- run: docker compose down -v --remove-orphans
|
|
||||||
- name: Store coverage files
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: coverage-html
|
|
||||||
path: backend/htmlcov
|
|
||||||
|
|
||||||
# https://github.com/marketplace/actions/alls-green#why
|
|
||||||
alls-green: # This job does nothing and is only used for the branch protection
|
|
||||||
if: always()
|
|
||||||
needs:
|
|
||||||
- test
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Decide whether the needed jobs succeeded or failed
|
|
||||||
uses: re-actors/alls-green@release/v1
|
|
||||||
with:
|
|
||||||
jobs: ${{ toJSON(needs) }}
|
|
||||||
+2
-1
@@ -1,4 +1,5 @@
|
|||||||
.vscode
|
.vscode/*
|
||||||
|
!.vscode/extensions.json
|
||||||
node_modules/
|
node_modules/
|
||||||
/test-results/
|
/test-results/
|
||||||
/playwright-report/
|
/playwright-report/
|
||||||
|
|||||||
+32
-10
@@ -10,17 +10,39 @@ repos:
|
|||||||
args:
|
args:
|
||||||
- --unsafe
|
- --unsafe
|
||||||
- id: end-of-file-fixer
|
- id: end-of-file-fixer
|
||||||
exclude: ^frontend/src/client/.*
|
exclude: |
|
||||||
|
(?x)^(
|
||||||
|
frontend/src/client/.*|
|
||||||
|
backend/app/email-templates/build/.*
|
||||||
|
)$
|
||||||
- id: trailing-whitespace
|
- id: trailing-whitespace
|
||||||
exclude: ^frontend/src/client/.*
|
exclude: ^frontend/src/client/.*
|
||||||
- repo: https://github.com/charliermarsh/ruff-pre-commit
|
- repo: local
|
||||||
rev: v0.2.2
|
|
||||||
hooks:
|
hooks:
|
||||||
- id: ruff
|
- id: local-biome-check
|
||||||
args:
|
name: biome check
|
||||||
- --fix
|
entry: npm run lint
|
||||||
- id: ruff-format
|
language: system
|
||||||
|
types: [text]
|
||||||
|
files: ^frontend/
|
||||||
|
|
||||||
ci:
|
- id: local-ruff-check
|
||||||
autofix_commit_msg: 🎨 [pre-commit.ci] Auto format from pre-commit.com hooks
|
name: ruff check
|
||||||
autoupdate_commit_msg: ⬆ [pre-commit.ci] pre-commit autoupdate
|
entry: uv run ruff check --force-exclude --fix --exit-non-zero-on-fix
|
||||||
|
require_serial: true
|
||||||
|
language: unsupported
|
||||||
|
types: [python]
|
||||||
|
|
||||||
|
- id: local-ruff-format
|
||||||
|
name: ruff format
|
||||||
|
entry: uv run ruff format --force-exclude --exit-non-zero-on-format
|
||||||
|
require_serial: true
|
||||||
|
language: unsupported
|
||||||
|
types: [python]
|
||||||
|
|
||||||
|
- id: generate-frontend-sdk
|
||||||
|
name: Generate Frontend SDK
|
||||||
|
entry: bash ./scripts/generate-client.sh
|
||||||
|
pass_filenames: false
|
||||||
|
language: unsupported
|
||||||
|
files: ^backend/.*$|^scripts/generate-client\.sh$
|
||||||
|
|||||||
Vendored
+14
@@ -0,0 +1,14 @@
|
|||||||
|
{
|
||||||
|
"recommendations": [
|
||||||
|
"astral-sh.ty",
|
||||||
|
"biomejs.biome",
|
||||||
|
"bradlc.vscode-tailwindcss",
|
||||||
|
"charliermarsh.ruff",
|
||||||
|
"docker.docker",
|
||||||
|
"github.vscode-github-actions",
|
||||||
|
"mjmlio.vscode-mjml",
|
||||||
|
"ms-playwright.playwright",
|
||||||
|
"ms-python.python",
|
||||||
|
"tombi-toml.tombi"
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -1,24 +1,26 @@
|
|||||||
# Full Stack FastAPI Template
|
# Full Stack FastAPI Template
|
||||||
|
|
||||||
<a href="https://github.com/fastapi/full-stack-fastapi-template/actions?query=workflow%3ATest" target="_blank"><img src="https://github.com/fastapi/full-stack-fastapi-template/workflows/Test/badge.svg" alt="Test"></a>
|
<a href="https://github.com/fastapi/full-stack-fastapi-template/actions?query=workflow%3A%22Test+Docker+Compose%22" target="_blank"><img src="https://github.com/fastapi/full-stack-fastapi-template/workflows/Test%20Docker%20Compose/badge.svg" alt="Test Docker Compose"></a>
|
||||||
|
<a href="https://github.com/fastapi/full-stack-fastapi-template/actions?query=workflow%3A%22Test+Backend%22" target="_blank"><img src="https://github.com/fastapi/full-stack-fastapi-template/workflows/Test%20Backend/badge.svg" alt="Test Backend"></a>
|
||||||
<a href="https://coverage-badge.samuelcolvin.workers.dev/redirect/fastapi/full-stack-fastapi-template" target="_blank"><img src="https://coverage-badge.samuelcolvin.workers.dev/fastapi/full-stack-fastapi-template.svg" alt="Coverage"></a>
|
<a href="https://coverage-badge.samuelcolvin.workers.dev/redirect/fastapi/full-stack-fastapi-template" target="_blank"><img src="https://coverage-badge.samuelcolvin.workers.dev/fastapi/full-stack-fastapi-template.svg" alt="Coverage"></a>
|
||||||
|
|
||||||
## Technology Stack and Features
|
## Technology Stack and Features
|
||||||
|
|
||||||
- ⚡ [**FastAPI**](https://fastapi.tiangolo.com) for the Python backend API.
|
- ⚡ [**FastAPI**](https://fastapi.tiangolo.com) for the Python backend API.
|
||||||
- 🧰 [SQLModel](https://sqlmodel.tiangolo.com) for the Python SQL database interactions (ORM).
|
- 🧰 [SQLModel](https://sqlmodel.tiangolo.com) for the Python SQL database interactions (ORM).
|
||||||
- 🔍 [Pydantic](https://docs.pydantic.dev), used by FastAPI, for the data validation and settings management.
|
- 🔍 [Pydantic](https://docs.pydantic.dev), used by FastAPI, for the data validation and settings management.
|
||||||
- 💾 [PostgreSQL](https://www.postgresql.org) as the SQL database.
|
- 💾 [PostgreSQL](https://www.postgresql.org) as the SQL database.
|
||||||
- 🚀 [React](https://react.dev) for the frontend.
|
- 🚀 [React](https://react.dev) for the frontend.
|
||||||
- 💃 Using TypeScript, hooks, Vite, and other parts of a modern frontend stack.
|
- 💃 Using TypeScript, hooks, [Vite](https://vitejs.dev), and other parts of a modern frontend stack.
|
||||||
- 🎨 [Chakra UI](https://chakra-ui.com) for the frontend components.
|
- 🎨 [Tailwind CSS](https://tailwindcss.com) and [shadcn/ui](https://ui.shadcn.com) for the frontend components.
|
||||||
- 🤖 An automatically generated frontend client.
|
- 🤖 An automatically generated frontend client.
|
||||||
- 🧪 [Playwright](https://playwright.dev) for End-to-End testing.
|
- 🧪 [Playwright](https://playwright.dev) for End-to-End testing.
|
||||||
- 🦇 Dark mode support.
|
- 🦇 Dark mode support.
|
||||||
- 🐋 [Docker Compose](https://www.docker.com) for development and production.
|
- 🐋 [Docker Compose](https://www.docker.com) for development and production.
|
||||||
- 🔒 Secure password hashing by default.
|
- 🔒 Secure password hashing by default.
|
||||||
- 🔑 JWT (JSON Web Token) authentication.
|
- 🔑 JWT (JSON Web Token) authentication.
|
||||||
- 📫 Email based password recovery.
|
- 📫 Email based password recovery.
|
||||||
|
- 📬 [Mailcatcher](https://mailcatcher.me) for local email testing during development.
|
||||||
- ✅ Tests with [Pytest](https://pytest.org).
|
- ✅ Tests with [Pytest](https://pytest.org).
|
||||||
- 📞 [Traefik](https://traefik.io) as a reverse proxy / load balancer.
|
- 📞 [Traefik](https://traefik.io) as a reverse proxy / load balancer.
|
||||||
- 🚢 Deployment instructions using Docker Compose, including how to set up a frontend Traefik proxy to handle automatic HTTPS certificates.
|
- 🚢 Deployment instructions using Docker Compose, including how to set up a frontend Traefik proxy to handle automatic HTTPS certificates.
|
||||||
@@ -32,18 +34,10 @@
|
|||||||
|
|
||||||
[](https://github.com/fastapi/full-stack-fastapi-template)
|
[](https://github.com/fastapi/full-stack-fastapi-template)
|
||||||
|
|
||||||
### Dashboard - Create User
|
|
||||||
|
|
||||||
[](https://github.com/fastapi/full-stack-fastapi-template)
|
|
||||||
|
|
||||||
### Dashboard - Items
|
### Dashboard - Items
|
||||||
|
|
||||||
[](https://github.com/fastapi/full-stack-fastapi-template)
|
[](https://github.com/fastapi/full-stack-fastapi-template)
|
||||||
|
|
||||||
### Dashboard - User Settings
|
|
||||||
|
|
||||||
[](https://github.com/fastapi/full-stack-fastapi-template)
|
|
||||||
|
|
||||||
### Dashboard - Dark Mode
|
### Dashboard - Dark Mode
|
||||||
|
|
||||||
[](https://github.com/fastapi/full-stack-fastapi-template)
|
[](https://github.com/fastapi/full-stack-fastapi-template)
|
||||||
|
|||||||
+35
-18
@@ -1,28 +1,45 @@
|
|||||||
FROM tiangolo/uvicorn-gunicorn-fastapi:python3.10
|
FROM python:3.10
|
||||||
|
|
||||||
|
ENV PYTHONUNBUFFERED=1
|
||||||
|
|
||||||
|
# Install uv
|
||||||
|
# Ref: https://docs.astral.sh/uv/guides/integration/docker/#installing-uv
|
||||||
|
COPY --from=ghcr.io/astral-sh/uv:0.9.26 /uv /uvx /bin/
|
||||||
|
|
||||||
|
# Compile bytecode
|
||||||
|
# Ref: https://docs.astral.sh/uv/guides/integration/docker/#compiling-bytecode
|
||||||
|
ENV UV_COMPILE_BYTECODE=1
|
||||||
|
|
||||||
|
# uv Cache
|
||||||
|
# Ref: https://docs.astral.sh/uv/guides/integration/docker/#caching
|
||||||
|
ENV UV_LINK_MODE=copy
|
||||||
|
|
||||||
WORKDIR /app/
|
WORKDIR /app/
|
||||||
|
|
||||||
# Install Poetry
|
# Place executables in the environment at the front of the path
|
||||||
RUN curl -sSL https://install.python-poetry.org | POETRY_HOME=/opt/poetry python && \
|
# Ref: https://docs.astral.sh/uv/guides/integration/docker/#using-the-environment
|
||||||
cd /usr/local/bin && \
|
ENV PATH="/app/.venv/bin:$PATH"
|
||||||
ln -s /opt/poetry/bin/poetry && \
|
|
||||||
poetry config virtualenvs.create false
|
|
||||||
|
|
||||||
# Copy poetry.lock* in case it doesn't exist in the repo
|
# Install dependencies
|
||||||
COPY ./pyproject.toml ./poetry.lock* /app/
|
# Ref: https://docs.astral.sh/uv/guides/integration/docker/#intermediate-layers
|
||||||
|
RUN --mount=type=cache,target=/root/.cache/uv \
|
||||||
|
--mount=type=bind,source=uv.lock,target=uv.lock \
|
||||||
|
--mount=type=bind,source=pyproject.toml,target=pyproject.toml \
|
||||||
|
uv sync --frozen --no-install-workspace --package app
|
||||||
|
|
||||||
# Allow installing dev dependencies to run tests
|
COPY ./backend/scripts /app/backend/scripts
|
||||||
ARG INSTALL_DEV=false
|
|
||||||
RUN bash -c "if [ $INSTALL_DEV == 'true' ] ; then poetry install --no-root ; else poetry install --no-root --only main ; fi"
|
|
||||||
|
|
||||||
ENV PYTHONPATH=/app
|
COPY ./backend/pyproject.toml ./backend/alembic.ini /app/backend/
|
||||||
|
|
||||||
COPY ./scripts/ /app/
|
COPY ./backend/app /app/backend/app
|
||||||
|
|
||||||
COPY ./alembic.ini /app/
|
# Sync the project
|
||||||
|
# Ref: https://docs.astral.sh/uv/guides/integration/docker/#intermediate-layers
|
||||||
|
RUN --mount=type=cache,target=/root/.cache/uv \
|
||||||
|
--mount=type=bind,source=uv.lock,target=uv.lock \
|
||||||
|
--mount=type=bind,source=pyproject.toml,target=pyproject.toml \
|
||||||
|
uv sync --frozen --package app
|
||||||
|
|
||||||
COPY ./prestart.sh /app/
|
WORKDIR /app/backend/
|
||||||
|
|
||||||
COPY ./tests-start.sh /app/
|
CMD ["fastapi", "run", "--workers", "4", "app/main.py"]
|
||||||
|
|
||||||
COPY ./app /app/app
|
|
||||||
|
|||||||
+37
-63
@@ -3,84 +3,50 @@
|
|||||||
## Requirements
|
## Requirements
|
||||||
|
|
||||||
* [Docker](https://www.docker.com/).
|
* [Docker](https://www.docker.com/).
|
||||||
* [Poetry](https://python-poetry.org/) for Python package and environment management.
|
* [uv](https://docs.astral.sh/uv/) for Python package and environment management.
|
||||||
|
|
||||||
## Local Development
|
## Docker Compose
|
||||||
|
|
||||||
* Start the stack with Docker Compose:
|
Start the local development environment with Docker Compose following the guide in [../development.md](../development.md).
|
||||||
|
|
||||||
```bash
|
## General Workflow
|
||||||
docker compose up -d
|
|
||||||
```
|
|
||||||
|
|
||||||
* Now you can open your browser and interact with these URLs:
|
By default, the dependencies are managed with [uv](https://docs.astral.sh/uv/), go there and install it.
|
||||||
|
|
||||||
Frontend, built with Docker, with routes handled based on the path: http://localhost
|
|
||||||
|
|
||||||
Backend, JSON based web API based on OpenAPI: http://localhost/api/
|
|
||||||
|
|
||||||
Automatic interactive documentation with Swagger UI (from the OpenAPI backend): http://localhost/docs
|
|
||||||
|
|
||||||
Adminer, database web administration: http://localhost:8080
|
|
||||||
|
|
||||||
Traefik UI, to see how the routes are being handled by the proxy: http://localhost:8090
|
|
||||||
|
|
||||||
**Note**: The first time you start your stack, it might take a minute for it to be ready. While the backend waits for the database to be ready and configures everything. You can check the logs to monitor it.
|
|
||||||
|
|
||||||
To check the logs, run:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
docker compose logs
|
|
||||||
```
|
|
||||||
|
|
||||||
To check the logs of a specific service, add the name of the service, e.g.:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
docker compose logs backend
|
|
||||||
```
|
|
||||||
|
|
||||||
If your Docker is not running in `localhost` (the URLs above wouldn't work) you would need to use the IP or domain where your Docker is running.
|
|
||||||
|
|
||||||
## Backend local development, additional details
|
|
||||||
|
|
||||||
### General workflow
|
|
||||||
|
|
||||||
By default, the dependencies are managed with [Poetry](https://python-poetry.org/), go there and install it.
|
|
||||||
|
|
||||||
From `./backend/` you can install all the dependencies with:
|
From `./backend/` you can install all the dependencies with:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ poetry install
|
$ uv sync
|
||||||
```
|
```
|
||||||
|
|
||||||
Then you can start a shell session with the new environment with:
|
Then you can activate the virtual environment with:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ poetry shell
|
$ source .venv/bin/activate
|
||||||
```
|
```
|
||||||
|
|
||||||
Make sure your editor is using the correct Python virtual environment.
|
Make sure your editor is using the correct Python virtual environment, with the interpreter at `backend/.venv/bin/python`.
|
||||||
|
|
||||||
Modify or add SQLModel models for data and SQL tables in `./backend/app/models.py`, API endpoints in `./backend/app/api/`, CRUD (Create, Read, Update, Delete) utils in `./backend/app/crud.py`.
|
Modify or add SQLModel models for data and SQL tables in `./backend/app/models.py`, API endpoints in `./backend/app/api/`, CRUD (Create, Read, Update, Delete) utils in `./backend/app/crud.py`.
|
||||||
|
|
||||||
### VS Code
|
## VS Code
|
||||||
|
|
||||||
There are already configurations in place to run the backend through the VS Code debugger, so that you can use breakpoints, pause and explore variables, etc.
|
There are already configurations in place to run the backend through the VS Code debugger, so that you can use breakpoints, pause and explore variables, etc.
|
||||||
|
|
||||||
The setup is also already configured so you can run the tests through the VS Code Python tests tab.
|
The setup is also already configured so you can run the tests through the VS Code Python tests tab.
|
||||||
|
|
||||||
### Docker Compose Override
|
## Docker Compose Override
|
||||||
|
|
||||||
During development, you can change Docker Compose settings that will only affect the local development environment in the file `docker-compose.override.yml`.
|
During development, you can change Docker Compose settings that will only affect the local development environment in the file `compose.override.yml`.
|
||||||
|
|
||||||
The changes to that file only affect the local development environment, not the production environment. So, you can add "temporary" changes that help the development workflow.
|
The changes to that file only affect the local development environment, not the production environment. So, you can add "temporary" changes that help the development workflow.
|
||||||
|
|
||||||
For example, the directory with the backend code is mounted as a Docker "host volume", mapping the code you change live to the directory inside the container. That allows you to test your changes right away, without having to build the Docker image again. It should only be done during development, for production, you should build the Docker image with a recent version of the backend code. But during development, it allows you to iterate very fast.
|
For example, the directory with the backend code is synchronized in the Docker container, copying the code you change live to the directory inside the container. That allows you to test your changes right away, without having to build the Docker image again. It should only be done during development, for production, you should build the Docker image with a recent version of the backend code. But during development, it allows you to iterate very fast.
|
||||||
|
|
||||||
There is also a command override that runs `/start-reload.sh` (included in the base image) instead of the default `/start.sh` (also included in the base image). It starts a single server process (instead of multiple, as would be for production) and reloads the process whenever the code changes. Have in mind that if you have a syntax error and save the Python file, it will break and exit, and the container will stop. After that, you can restart the container by fixing the error and running again:
|
There is also a command override that runs `fastapi run --reload` instead of the default `fastapi run`. It starts a single server process (instead of multiple, as would be for production) and reloads the process whenever the code changes. Have in mind that if you have a syntax error and save the Python file, it will break and exit, and the container will stop. After that, you can restart the container by fixing the error and running again:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ docker compose up -d
|
$ docker compose watch
|
||||||
```
|
```
|
||||||
|
|
||||||
There is also a commented out `command` override, you can uncomment it and comment the default one. It makes the backend container run a process that does "nothing", but keeps the container alive. That allows you to get inside your running container and execute commands inside, for example a Python interpreter to test installed dependencies, or start the development server that reloads when it detects changes.
|
There is also a commented out `command` override, you can uncomment it and comment the default one. It makes the backend container run a process that does "nothing", but keeps the container alive. That allows you to get inside your running container and execute commands inside, for example a Python interpreter to test installed dependencies, or start the development server that reloads when it detects changes.
|
||||||
@@ -88,10 +54,10 @@ There is also a commented out `command` override, you can uncomment it and comme
|
|||||||
To get inside the container with a `bash` session you can start the stack with:
|
To get inside the container with a `bash` session you can start the stack with:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ docker compose up -d
|
$ docker compose watch
|
||||||
```
|
```
|
||||||
|
|
||||||
and then `exec` inside the running container:
|
and then in another terminal, `exec` inside the running container:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ docker compose exec backend bash
|
$ docker compose exec backend bash
|
||||||
@@ -105,16 +71,16 @@ root@7f2607af31c3:/app#
|
|||||||
|
|
||||||
that means that you are in a `bash` session inside your container, as a `root` user, under the `/app` directory, this directory has another directory called "app" inside, that's where your code lives inside the container: `/app/app`.
|
that means that you are in a `bash` session inside your container, as a `root` user, under the `/app` directory, this directory has another directory called "app" inside, that's where your code lives inside the container: `/app/app`.
|
||||||
|
|
||||||
There you can use the script `/start-reload.sh` to run the debug live reloading server. You can run that script from inside the container with:
|
There you can use the `fastapi run --reload` command to run the debug live reloading server.
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ bash /start-reload.sh
|
$ fastapi run --reload app/main.py
|
||||||
```
|
```
|
||||||
|
|
||||||
...it will look like:
|
...it will look like:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
root@7f2607af31c3:/app# bash /start-reload.sh
|
root@7f2607af31c3:/app# fastapi run --reload app/main.py
|
||||||
```
|
```
|
||||||
|
|
||||||
and then hit enter. That runs the live reloading server that auto reloads when it detects code changes.
|
and then hit enter. That runs the live reloading server that auto reloads when it detects code changes.
|
||||||
@@ -123,7 +89,7 @@ Nevertheless, if it doesn't detect a change but a syntax error, it will just sto
|
|||||||
|
|
||||||
...this previous detail is what makes it useful to have the container alive doing nothing and then, in a Bash session, make it run the live reload server.
|
...this previous detail is what makes it useful to have the container alive doing nothing and then, in a Bash session, make it run the live reload server.
|
||||||
|
|
||||||
### Backend tests
|
## Backend tests
|
||||||
|
|
||||||
To test the backend run:
|
To test the backend run:
|
||||||
|
|
||||||
@@ -131,31 +97,31 @@ To test the backend run:
|
|||||||
$ bash ./scripts/test.sh
|
$ bash ./scripts/test.sh
|
||||||
```
|
```
|
||||||
|
|
||||||
The tests run with Pytest, modify and add tests to `./backend/app/tests/`.
|
The tests run with Pytest, modify and add tests to `./backend/tests/`.
|
||||||
|
|
||||||
If you use GitHub Actions the tests will run automatically.
|
If you use GitHub Actions the tests will run automatically.
|
||||||
|
|
||||||
#### Test running stack
|
### Test running stack
|
||||||
|
|
||||||
If your stack is already up and you just want to run the tests, you can use:
|
If your stack is already up and you just want to run the tests, you can use:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker compose exec backend bash /app/tests-start.sh
|
docker compose exec backend bash scripts/tests-start.sh
|
||||||
```
|
```
|
||||||
|
|
||||||
That `/app/tests-start.sh` script just calls `pytest` after making sure that the rest of the stack is running. If you need to pass extra arguments to `pytest`, you can pass them to that command and they will be forwarded.
|
That `/app/scripts/tests-start.sh` script just calls `pytest` after making sure that the rest of the stack is running. If you need to pass extra arguments to `pytest`, you can pass them to that command and they will be forwarded.
|
||||||
|
|
||||||
For example, to stop on first error:
|
For example, to stop on first error:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker compose exec backend bash /app/tests-start.sh -x
|
docker compose exec backend bash scripts/tests-start.sh -x
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Test Coverage
|
### Test Coverage
|
||||||
|
|
||||||
When the tests are run, a file `htmlcov/index.html` is generated, you can open it in your browser to see the coverage of the tests.
|
When the tests are run, a file `htmlcov/index.html` is generated, you can open it in your browser to see the coverage of the tests.
|
||||||
|
|
||||||
### Migrations
|
## Migrations
|
||||||
|
|
||||||
As during local development your app directory is mounted as a volume inside the container, you can also run the migrations with `alembic` commands inside the container and the migration code will be in your app directory (instead of being only inside the container). So you can add it to your git repository.
|
As during local development your app directory is mounted as a volume inside the container, you can also run the migrations with `alembic` commands inside the container and the migration code will be in your app directory (instead of being only inside the container). So you can add it to your git repository.
|
||||||
|
|
||||||
@@ -189,10 +155,18 @@ If you don't want to use migrations at all, uncomment the lines in the file at `
|
|||||||
SQLModel.metadata.create_all(engine)
|
SQLModel.metadata.create_all(engine)
|
||||||
```
|
```
|
||||||
|
|
||||||
and comment the line in the file `prestart.sh` that contains:
|
and comment the line in the file `scripts/prestart.sh` that contains:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ alembic upgrade head
|
$ alembic upgrade head
|
||||||
```
|
```
|
||||||
|
|
||||||
If you don't want to start with the default models and want to remove them / modify them, from the beginning, without having any previous revision, you can remove the revision files (`.py` Python files) under `./backend/app/alembic/versions/`. And then create a first migration as described above.
|
If you don't want to start with the default models and want to remove them / modify them, from the beginning, without having any previous revision, you can remove the revision files (`.py` Python files) under `./backend/app/alembic/versions/`. And then create a first migration as described above.
|
||||||
|
|
||||||
|
## Email Templates
|
||||||
|
|
||||||
|
The email templates are in `./backend/app/email-templates/`. Here, there are two directories: `build` and `src`. The `src` directory contains the source files that are used to build the final email templates. The `build` directory contains the final email templates that are used by the application.
|
||||||
|
|
||||||
|
Before continuing, ensure you have the [MJML extension](https://github.com/mjmlio/vscode-mjml) installed in your VS Code.
|
||||||
|
|
||||||
|
Once you have the MJML extension installed, you can create a new email template in the `src` directory. After creating the new email template and with the `.mjml` file open in your editor, open the command palette with `Ctrl+Shift+P` and search for `MJML: Export to HTML`. This will convert the `.mjml` file to a `.html` file and now you can save it in the build directory.
|
||||||
|
|||||||
@@ -0,0 +1,31 @@
|
|||||||
|
"""Add created_at to User and Item
|
||||||
|
|
||||||
|
Revision ID: fe56fa70289e
|
||||||
|
Revises: 1a31ce608336
|
||||||
|
Create Date: 2026-01-23 15:50:37.171462
|
||||||
|
|
||||||
|
"""
|
||||||
|
from alembic import op
|
||||||
|
import sqlalchemy as sa
|
||||||
|
import sqlmodel.sql.sqltypes
|
||||||
|
|
||||||
|
|
||||||
|
# revision identifiers, used by Alembic.
|
||||||
|
revision = 'fe56fa70289e'
|
||||||
|
down_revision = '1a31ce608336'
|
||||||
|
branch_labels = None
|
||||||
|
depends_on = None
|
||||||
|
|
||||||
|
|
||||||
|
def upgrade():
|
||||||
|
# ### commands auto generated by Alembic - please adjust! ###
|
||||||
|
op.add_column('item', sa.Column('created_at', sa.DateTime(timezone=True), nullable=True))
|
||||||
|
op.add_column('user', sa.Column('created_at', sa.DateTime(timezone=True), nullable=True))
|
||||||
|
# ### end Alembic commands ###
|
||||||
|
|
||||||
|
|
||||||
|
def downgrade():
|
||||||
|
# ### commands auto generated by Alembic - please adjust! ###
|
||||||
|
op.drop_column('user', 'created_at')
|
||||||
|
op.drop_column('item', 'created_at')
|
||||||
|
# ### end Alembic commands ###
|
||||||
+10
-5
@@ -1,9 +1,14 @@
|
|||||||
from fastapi import APIRouter
|
from fastapi import APIRouter
|
||||||
|
|
||||||
from app.api.routes import items, login, users, utils
|
from app.api.routes import items, login, private, users, utils
|
||||||
|
from app.core.config import settings
|
||||||
|
|
||||||
api_router = APIRouter()
|
api_router = APIRouter()
|
||||||
api_router.include_router(login.router, tags=["login"])
|
api_router.include_router(login.router)
|
||||||
api_router.include_router(users.router, prefix="/users", tags=["users"])
|
api_router.include_router(users.router)
|
||||||
api_router.include_router(utils.router, prefix="/utils", tags=["utils"])
|
api_router.include_router(utils.router)
|
||||||
api_router.include_router(items.router, prefix="/items", tags=["items"])
|
api_router.include_router(items.router)
|
||||||
|
|
||||||
|
|
||||||
|
if settings.ENVIRONMENT == "local":
|
||||||
|
api_router.include_router(private.router)
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ from sqlmodel import func, select
|
|||||||
from app.api.deps import CurrentUser, SessionDep
|
from app.api.deps import CurrentUser, SessionDep
|
||||||
from app.models import Item, ItemCreate, ItemPublic, ItemsPublic, ItemUpdate, Message
|
from app.models import Item, ItemCreate, ItemPublic, ItemsPublic, ItemUpdate, Message
|
||||||
|
|
||||||
router = APIRouter()
|
router = APIRouter(prefix="/items", tags=["items"])
|
||||||
|
|
||||||
|
|
||||||
@router.get("/", response_model=ItemsPublic)
|
@router.get("/", response_model=ItemsPublic)
|
||||||
@@ -21,7 +21,9 @@ def read_items(
|
|||||||
if current_user.is_superuser:
|
if current_user.is_superuser:
|
||||||
count_statement = select(func.count()).select_from(Item)
|
count_statement = select(func.count()).select_from(Item)
|
||||||
count = session.exec(count_statement).one()
|
count = session.exec(count_statement).one()
|
||||||
statement = select(Item).offset(skip).limit(limit)
|
statement = (
|
||||||
|
select(Item).order_by(Item.created_at.desc()).offset(skip).limit(limit)
|
||||||
|
)
|
||||||
items = session.exec(statement).all()
|
items = session.exec(statement).all()
|
||||||
else:
|
else:
|
||||||
count_statement = (
|
count_statement = (
|
||||||
@@ -33,6 +35,7 @@ def read_items(
|
|||||||
statement = (
|
statement = (
|
||||||
select(Item)
|
select(Item)
|
||||||
.where(Item.owner_id == current_user.id)
|
.where(Item.owner_id == current_user.id)
|
||||||
|
.order_by(Item.created_at.desc())
|
||||||
.offset(skip)
|
.offset(skip)
|
||||||
.limit(limit)
|
.limit(limit)
|
||||||
)
|
)
|
||||||
@@ -50,7 +53,7 @@ def read_item(session: SessionDep, current_user: CurrentUser, id: uuid.UUID) ->
|
|||||||
if not item:
|
if not item:
|
||||||
raise HTTPException(status_code=404, detail="Item not found")
|
raise HTTPException(status_code=404, detail="Item not found")
|
||||||
if not current_user.is_superuser and (item.owner_id != current_user.id):
|
if not current_user.is_superuser and (item.owner_id != current_user.id):
|
||||||
raise HTTPException(status_code=400, detail="Not enough permissions")
|
raise HTTPException(status_code=403, detail="Not enough permissions")
|
||||||
return item
|
return item
|
||||||
|
|
||||||
|
|
||||||
@@ -83,7 +86,7 @@ def update_item(
|
|||||||
if not item:
|
if not item:
|
||||||
raise HTTPException(status_code=404, detail="Item not found")
|
raise HTTPException(status_code=404, detail="Item not found")
|
||||||
if not current_user.is_superuser and (item.owner_id != current_user.id):
|
if not current_user.is_superuser and (item.owner_id != current_user.id):
|
||||||
raise HTTPException(status_code=400, detail="Not enough permissions")
|
raise HTTPException(status_code=403, detail="Not enough permissions")
|
||||||
update_dict = item_in.model_dump(exclude_unset=True)
|
update_dict = item_in.model_dump(exclude_unset=True)
|
||||||
item.sqlmodel_update(update_dict)
|
item.sqlmodel_update(update_dict)
|
||||||
session.add(item)
|
session.add(item)
|
||||||
@@ -103,7 +106,7 @@ def delete_item(
|
|||||||
if not item:
|
if not item:
|
||||||
raise HTTPException(status_code=404, detail="Item not found")
|
raise HTTPException(status_code=404, detail="Item not found")
|
||||||
if not current_user.is_superuser and (item.owner_id != current_user.id):
|
if not current_user.is_superuser and (item.owner_id != current_user.id):
|
||||||
raise HTTPException(status_code=400, detail="Not enough permissions")
|
raise HTTPException(status_code=403, detail="Not enough permissions")
|
||||||
session.delete(item)
|
session.delete(item)
|
||||||
session.commit()
|
session.commit()
|
||||||
return Message(message="Item deleted successfully")
|
return Message(message="Item deleted successfully")
|
||||||
|
|||||||
@@ -9,8 +9,7 @@ from app import crud
|
|||||||
from app.api.deps import CurrentUser, SessionDep, get_current_active_superuser
|
from app.api.deps import CurrentUser, SessionDep, get_current_active_superuser
|
||||||
from app.core import security
|
from app.core import security
|
||||||
from app.core.config import settings
|
from app.core.config import settings
|
||||||
from app.core.security import get_password_hash
|
from app.models import Message, NewPassword, Token, UserPublic, UserUpdate
|
||||||
from app.models import Message, NewPassword, Token, UserPublic
|
|
||||||
from app.utils import (
|
from app.utils import (
|
||||||
generate_password_reset_token,
|
generate_password_reset_token,
|
||||||
generate_reset_password_email,
|
generate_reset_password_email,
|
||||||
@@ -18,7 +17,7 @@ from app.utils import (
|
|||||||
verify_password_reset_token,
|
verify_password_reset_token,
|
||||||
)
|
)
|
||||||
|
|
||||||
router = APIRouter()
|
router = APIRouter(tags=["login"])
|
||||||
|
|
||||||
|
|
||||||
@router.post("/login/access-token")
|
@router.post("/login/access-token")
|
||||||
@@ -58,21 +57,21 @@ def recover_password(email: str, session: SessionDep) -> Message:
|
|||||||
"""
|
"""
|
||||||
user = crud.get_user_by_email(session=session, email=email)
|
user = crud.get_user_by_email(session=session, email=email)
|
||||||
|
|
||||||
if not user:
|
# Always return the same response to prevent email enumeration attacks
|
||||||
raise HTTPException(
|
# Only send email if user actually exists
|
||||||
status_code=404,
|
if user:
|
||||||
detail="The user with this email does not exist in the system.",
|
password_reset_token = generate_password_reset_token(email=email)
|
||||||
|
email_data = generate_reset_password_email(
|
||||||
|
email_to=user.email, email=email, token=password_reset_token
|
||||||
)
|
)
|
||||||
password_reset_token = generate_password_reset_token(email=email)
|
send_email(
|
||||||
email_data = generate_reset_password_email(
|
email_to=user.email,
|
||||||
email_to=user.email, email=email, token=password_reset_token
|
subject=email_data.subject,
|
||||||
|
html_content=email_data.html_content,
|
||||||
|
)
|
||||||
|
return Message(
|
||||||
|
message="If that email is registered, we sent a password recovery link"
|
||||||
)
|
)
|
||||||
send_email(
|
|
||||||
email_to=user.email,
|
|
||||||
subject=email_data.subject,
|
|
||||||
html_content=email_data.html_content,
|
|
||||||
)
|
|
||||||
return Message(message="Password recovery email sent")
|
|
||||||
|
|
||||||
|
|
||||||
@router.post("/reset-password/")
|
@router.post("/reset-password/")
|
||||||
@@ -85,16 +84,16 @@ def reset_password(session: SessionDep, body: NewPassword) -> Message:
|
|||||||
raise HTTPException(status_code=400, detail="Invalid token")
|
raise HTTPException(status_code=400, detail="Invalid token")
|
||||||
user = crud.get_user_by_email(session=session, email=email)
|
user = crud.get_user_by_email(session=session, email=email)
|
||||||
if not user:
|
if not user:
|
||||||
raise HTTPException(
|
# Don't reveal that the user doesn't exist - use same error as invalid token
|
||||||
status_code=404,
|
raise HTTPException(status_code=400, detail="Invalid token")
|
||||||
detail="The user with this email does not exist in the system.",
|
|
||||||
)
|
|
||||||
elif not user.is_active:
|
elif not user.is_active:
|
||||||
raise HTTPException(status_code=400, detail="Inactive user")
|
raise HTTPException(status_code=400, detail="Inactive user")
|
||||||
hashed_password = get_password_hash(password=body.new_password)
|
user_in_update = UserUpdate(password=body.new_password)
|
||||||
user.hashed_password = hashed_password
|
crud.update_user(
|
||||||
session.add(user)
|
session=session,
|
||||||
session.commit()
|
db_user=user,
|
||||||
|
user_in=user_in_update,
|
||||||
|
)
|
||||||
return Message(message="Password updated successfully")
|
return Message(message="Password updated successfully")
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,38 @@
|
|||||||
|
from typing import Any
|
||||||
|
|
||||||
|
from fastapi import APIRouter
|
||||||
|
from pydantic import BaseModel
|
||||||
|
|
||||||
|
from app.api.deps import SessionDep
|
||||||
|
from app.core.security import get_password_hash
|
||||||
|
from app.models import (
|
||||||
|
User,
|
||||||
|
UserPublic,
|
||||||
|
)
|
||||||
|
|
||||||
|
router = APIRouter(tags=["private"], prefix="/private")
|
||||||
|
|
||||||
|
|
||||||
|
class PrivateUserCreate(BaseModel):
|
||||||
|
email: str
|
||||||
|
password: str
|
||||||
|
full_name: str
|
||||||
|
is_verified: bool = False
|
||||||
|
|
||||||
|
|
||||||
|
@router.post("/users/", response_model=UserPublic)
|
||||||
|
def create_user(user_in: PrivateUserCreate, session: SessionDep) -> Any:
|
||||||
|
"""
|
||||||
|
Create a new user.
|
||||||
|
"""
|
||||||
|
|
||||||
|
user = User(
|
||||||
|
email=user_in.email,
|
||||||
|
full_name=user_in.full_name,
|
||||||
|
hashed_password=get_password_hash(user_in.password),
|
||||||
|
)
|
||||||
|
|
||||||
|
session.add(user)
|
||||||
|
session.commit()
|
||||||
|
|
||||||
|
return user
|
||||||
@@ -26,7 +26,7 @@ from app.models import (
|
|||||||
)
|
)
|
||||||
from app.utils import generate_new_account_email, send_email
|
from app.utils import generate_new_account_email, send_email
|
||||||
|
|
||||||
router = APIRouter()
|
router = APIRouter(prefix="/users", tags=["users"])
|
||||||
|
|
||||||
|
|
||||||
@router.get(
|
@router.get(
|
||||||
@@ -42,7 +42,7 @@ def read_users(session: SessionDep, skip: int = 0, limit: int = 100) -> Any:
|
|||||||
count_statement = select(func.count()).select_from(User)
|
count_statement = select(func.count()).select_from(User)
|
||||||
count = session.exec(count_statement).one()
|
count = session.exec(count_statement).one()
|
||||||
|
|
||||||
statement = select(User).offset(skip).limit(limit)
|
statement = select(User).order_by(User.created_at.desc()).offset(skip).limit(limit)
|
||||||
users = session.exec(statement).all()
|
users = session.exec(statement).all()
|
||||||
|
|
||||||
return UsersPublic(data=users, count=count)
|
return UsersPublic(data=users, count=count)
|
||||||
@@ -104,7 +104,8 @@ def update_password_me(
|
|||||||
"""
|
"""
|
||||||
Update own password.
|
Update own password.
|
||||||
"""
|
"""
|
||||||
if not verify_password(body.current_password, current_user.hashed_password):
|
verified, _ = verify_password(body.current_password, current_user.hashed_password)
|
||||||
|
if not verified:
|
||||||
raise HTTPException(status_code=400, detail="Incorrect password")
|
raise HTTPException(status_code=400, detail="Incorrect password")
|
||||||
if body.current_password == body.new_password:
|
if body.current_password == body.new_password:
|
||||||
raise HTTPException(
|
raise HTTPException(
|
||||||
@@ -134,8 +135,6 @@ def delete_user_me(session: SessionDep, current_user: CurrentUser) -> Any:
|
|||||||
raise HTTPException(
|
raise HTTPException(
|
||||||
status_code=403, detail="Super users are not allowed to delete themselves"
|
status_code=403, detail="Super users are not allowed to delete themselves"
|
||||||
)
|
)
|
||||||
statement = delete(Item).where(col(Item.owner_id) == current_user.id)
|
|
||||||
session.exec(statement) # type: ignore
|
|
||||||
session.delete(current_user)
|
session.delete(current_user)
|
||||||
session.commit()
|
session.commit()
|
||||||
return Message(message="User deleted successfully")
|
return Message(message="User deleted successfully")
|
||||||
@@ -172,6 +171,8 @@ def read_user_by_id(
|
|||||||
status_code=403,
|
status_code=403,
|
||||||
detail="The user doesn't have enough privileges",
|
detail="The user doesn't have enough privileges",
|
||||||
)
|
)
|
||||||
|
if user is None:
|
||||||
|
raise HTTPException(status_code=404, detail="User not found")
|
||||||
return user
|
return user
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ from app.api.deps import get_current_active_superuser
|
|||||||
from app.models import Message
|
from app.models import Message
|
||||||
from app.utils import generate_test_email, send_email
|
from app.utils import generate_test_email, send_email
|
||||||
|
|
||||||
router = APIRouter()
|
router = APIRouter(prefix="/utils", tags=["utils"])
|
||||||
|
|
||||||
|
|
||||||
@router.post(
|
@router.post(
|
||||||
@@ -24,3 +24,8 @@ def test_email(email_to: EmailStr) -> Message:
|
|||||||
html_content=email_data.html_content,
|
html_content=email_data.html_content,
|
||||||
)
|
)
|
||||||
return Message(message="Test email sent")
|
return Message(message="Test email sent")
|
||||||
|
|
||||||
|
|
||||||
|
@router.get("/health-check/")
|
||||||
|
async def health_check() -> bool:
|
||||||
|
return True
|
||||||
|
|||||||
+18
-19
@@ -5,19 +5,19 @@ from typing import Annotated, Any, Literal
|
|||||||
from pydantic import (
|
from pydantic import (
|
||||||
AnyUrl,
|
AnyUrl,
|
||||||
BeforeValidator,
|
BeforeValidator,
|
||||||
|
EmailStr,
|
||||||
HttpUrl,
|
HttpUrl,
|
||||||
PostgresDsn,
|
PostgresDsn,
|
||||||
computed_field,
|
computed_field,
|
||||||
model_validator,
|
model_validator,
|
||||||
)
|
)
|
||||||
from pydantic_core import MultiHostUrl
|
|
||||||
from pydantic_settings import BaseSettings, SettingsConfigDict
|
from pydantic_settings import BaseSettings, SettingsConfigDict
|
||||||
from typing_extensions import Self
|
from typing_extensions import Self
|
||||||
|
|
||||||
|
|
||||||
def parse_cors(v: Any) -> list[str] | str:
|
def parse_cors(v: Any) -> list[str] | str:
|
||||||
if isinstance(v, str) and not v.startswith("["):
|
if isinstance(v, str) and not v.startswith("["):
|
||||||
return [i.strip() for i in v.split(",")]
|
return [i.strip() for i in v.split(",") if i.strip()]
|
||||||
elif isinstance(v, list | str):
|
elif isinstance(v, list | str):
|
||||||
return v
|
return v
|
||||||
raise ValueError(v)
|
raise ValueError(v)
|
||||||
@@ -25,27 +25,29 @@ def parse_cors(v: Any) -> list[str] | str:
|
|||||||
|
|
||||||
class Settings(BaseSettings):
|
class Settings(BaseSettings):
|
||||||
model_config = SettingsConfigDict(
|
model_config = SettingsConfigDict(
|
||||||
env_file=".env", env_ignore_empty=True, extra="ignore"
|
# Use top level .env file (one level above ./backend/)
|
||||||
|
env_file="../.env",
|
||||||
|
env_ignore_empty=True,
|
||||||
|
extra="ignore",
|
||||||
)
|
)
|
||||||
API_V1_STR: str = "/api/v1"
|
API_V1_STR: str = "/api/v1"
|
||||||
SECRET_KEY: str = secrets.token_urlsafe(32)
|
SECRET_KEY: str = secrets.token_urlsafe(32)
|
||||||
# 60 minutes * 24 hours * 8 days = 8 days
|
# 60 minutes * 24 hours * 8 days = 8 days
|
||||||
ACCESS_TOKEN_EXPIRE_MINUTES: int = 60 * 24 * 8
|
ACCESS_TOKEN_EXPIRE_MINUTES: int = 60 * 24 * 8
|
||||||
DOMAIN: str = "localhost"
|
FRONTEND_HOST: str = "http://localhost:5173"
|
||||||
ENVIRONMENT: Literal["local", "staging", "production"] = "local"
|
ENVIRONMENT: Literal["local", "staging", "production"] = "local"
|
||||||
|
|
||||||
@computed_field # type: ignore[prop-decorator]
|
|
||||||
@property
|
|
||||||
def server_host(self) -> str:
|
|
||||||
# Use HTTPS for anything other than local development
|
|
||||||
if self.ENVIRONMENT == "local":
|
|
||||||
return f"http://{self.DOMAIN}"
|
|
||||||
return f"https://{self.DOMAIN}"
|
|
||||||
|
|
||||||
BACKEND_CORS_ORIGINS: Annotated[
|
BACKEND_CORS_ORIGINS: Annotated[
|
||||||
list[AnyUrl] | str, BeforeValidator(parse_cors)
|
list[AnyUrl] | str, BeforeValidator(parse_cors)
|
||||||
] = []
|
] = []
|
||||||
|
|
||||||
|
@computed_field # type: ignore[prop-decorator]
|
||||||
|
@property
|
||||||
|
def all_cors_origins(self) -> list[str]:
|
||||||
|
return [str(origin).rstrip("/") for origin in self.BACKEND_CORS_ORIGINS] + [
|
||||||
|
self.FRONTEND_HOST
|
||||||
|
]
|
||||||
|
|
||||||
PROJECT_NAME: str
|
PROJECT_NAME: str
|
||||||
SENTRY_DSN: HttpUrl | None = None
|
SENTRY_DSN: HttpUrl | None = None
|
||||||
POSTGRES_SERVER: str
|
POSTGRES_SERVER: str
|
||||||
@@ -57,7 +59,7 @@ class Settings(BaseSettings):
|
|||||||
@computed_field # type: ignore[prop-decorator]
|
@computed_field # type: ignore[prop-decorator]
|
||||||
@property
|
@property
|
||||||
def SQLALCHEMY_DATABASE_URI(self) -> PostgresDsn:
|
def SQLALCHEMY_DATABASE_URI(self) -> PostgresDsn:
|
||||||
return MultiHostUrl.build(
|
return PostgresDsn.build(
|
||||||
scheme="postgresql+psycopg",
|
scheme="postgresql+psycopg",
|
||||||
username=self.POSTGRES_USER,
|
username=self.POSTGRES_USER,
|
||||||
password=self.POSTGRES_PASSWORD,
|
password=self.POSTGRES_PASSWORD,
|
||||||
@@ -72,8 +74,7 @@ class Settings(BaseSettings):
|
|||||||
SMTP_HOST: str | None = None
|
SMTP_HOST: str | None = None
|
||||||
SMTP_USER: str | None = None
|
SMTP_USER: str | None = None
|
||||||
SMTP_PASSWORD: str | None = None
|
SMTP_PASSWORD: str | None = None
|
||||||
# TODO: update type to EmailStr when sqlmodel supports it
|
EMAILS_FROM_EMAIL: EmailStr | None = None
|
||||||
EMAILS_FROM_EMAIL: str | None = None
|
|
||||||
EMAILS_FROM_NAME: str | None = None
|
EMAILS_FROM_NAME: str | None = None
|
||||||
|
|
||||||
@model_validator(mode="after")
|
@model_validator(mode="after")
|
||||||
@@ -89,10 +90,8 @@ class Settings(BaseSettings):
|
|||||||
def emails_enabled(self) -> bool:
|
def emails_enabled(self) -> bool:
|
||||||
return bool(self.SMTP_HOST and self.EMAILS_FROM_EMAIL)
|
return bool(self.SMTP_HOST and self.EMAILS_FROM_EMAIL)
|
||||||
|
|
||||||
# TODO: update type to EmailStr when sqlmodel supports it
|
EMAIL_TEST_USER: EmailStr = "test@example.com"
|
||||||
EMAIL_TEST_USER: str = "test@example.com"
|
FIRST_SUPERUSER: EmailStr
|
||||||
# TODO: update type to EmailStr when sqlmodel supports it
|
|
||||||
FIRST_SUPERUSER: str
|
|
||||||
FIRST_SUPERUSER_PASSWORD: str
|
FIRST_SUPERUSER_PASSWORD: str
|
||||||
|
|
||||||
def _check_default_secret(self, var_name: str, value: str | None) -> None:
|
def _check_default_secret(self, var_name: str, value: str | None) -> None:
|
||||||
|
|||||||
@@ -18,7 +18,6 @@ def init_db(session: Session) -> None:
|
|||||||
# the tables un-commenting the next lines
|
# the tables un-commenting the next lines
|
||||||
# from sqlmodel import SQLModel
|
# from sqlmodel import SQLModel
|
||||||
|
|
||||||
# from app.core.engine import engine
|
|
||||||
# This works because the models are already imported and registered from app.models
|
# This works because the models are already imported and registered from app.models
|
||||||
# SQLModel.metadata.create_all(engine)
|
# SQLModel.metadata.create_all(engine)
|
||||||
|
|
||||||
|
|||||||
@@ -2,11 +2,18 @@ from datetime import datetime, timedelta, timezone
|
|||||||
from typing import Any
|
from typing import Any
|
||||||
|
|
||||||
import jwt
|
import jwt
|
||||||
from passlib.context import CryptContext
|
from pwdlib import PasswordHash
|
||||||
|
from pwdlib.hashers.argon2 import Argon2Hasher
|
||||||
|
from pwdlib.hashers.bcrypt import BcryptHasher
|
||||||
|
|
||||||
from app.core.config import settings
|
from app.core.config import settings
|
||||||
|
|
||||||
pwd_context = CryptContext(schemes=["bcrypt"], deprecated="auto")
|
password_hash = PasswordHash(
|
||||||
|
(
|
||||||
|
Argon2Hasher(),
|
||||||
|
BcryptHasher(),
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
ALGORITHM = "HS256"
|
ALGORITHM = "HS256"
|
||||||
@@ -19,9 +26,11 @@ def create_access_token(subject: str | Any, expires_delta: timedelta) -> str:
|
|||||||
return encoded_jwt
|
return encoded_jwt
|
||||||
|
|
||||||
|
|
||||||
def verify_password(plain_password: str, hashed_password: str) -> bool:
|
def verify_password(
|
||||||
return pwd_context.verify(plain_password, hashed_password)
|
plain_password: str, hashed_password: str
|
||||||
|
) -> tuple[bool, str | None]:
|
||||||
|
return password_hash.verify_and_update(plain_password, hashed_password)
|
||||||
|
|
||||||
|
|
||||||
def get_password_hash(password: str) -> str:
|
def get_password_hash(password: str) -> str:
|
||||||
return pwd_context.hash(password)
|
return password_hash.hash(password)
|
||||||
|
|||||||
+15
-1
@@ -37,12 +37,26 @@ def get_user_by_email(*, session: Session, email: str) -> User | None:
|
|||||||
return session_user
|
return session_user
|
||||||
|
|
||||||
|
|
||||||
|
# Dummy hash to use for timing attack prevention when user is not found
|
||||||
|
# This is an Argon2 hash of a random password, used to ensure constant-time comparison
|
||||||
|
DUMMY_HASH = "$argon2id$v=19$m=65536,t=3,p=4$MjQyZWE1MzBjYjJlZTI0Yw$YTU4NGM5ZTZmYjE2NzZlZjY0ZWY3ZGRkY2U2OWFjNjk"
|
||||||
|
|
||||||
|
|
||||||
def authenticate(*, session: Session, email: str, password: str) -> User | None:
|
def authenticate(*, session: Session, email: str, password: str) -> User | None:
|
||||||
db_user = get_user_by_email(session=session, email=email)
|
db_user = get_user_by_email(session=session, email=email)
|
||||||
if not db_user:
|
if not db_user:
|
||||||
|
# Prevent timing attacks by running password verification even when user doesn't exist
|
||||||
|
# This ensures the response time is similar whether or not the email exists
|
||||||
|
verify_password(password, DUMMY_HASH)
|
||||||
return None
|
return None
|
||||||
if not verify_password(password, db_user.hashed_password):
|
verified, updated_password_hash = verify_password(password, db_user.hashed_password)
|
||||||
|
if not verified:
|
||||||
return None
|
return None
|
||||||
|
if updated_password_hash:
|
||||||
|
db_user.hashed_password = updated_password_hash
|
||||||
|
session.add(db_user)
|
||||||
|
session.commit()
|
||||||
|
session.refresh(db_user)
|
||||||
return db_user
|
return db_user
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+2
-4
@@ -21,12 +21,10 @@ app = FastAPI(
|
|||||||
)
|
)
|
||||||
|
|
||||||
# Set all CORS enabled origins
|
# Set all CORS enabled origins
|
||||||
if settings.BACKEND_CORS_ORIGINS:
|
if settings.all_cors_origins:
|
||||||
app.add_middleware(
|
app.add_middleware(
|
||||||
CORSMiddleware,
|
CORSMiddleware,
|
||||||
allow_origins=[
|
allow_origins=settings.all_cors_origins,
|
||||||
str(origin).strip("/") for origin in settings.BACKEND_CORS_ORIGINS
|
|
||||||
],
|
|
||||||
allow_credentials=True,
|
allow_credentials=True,
|
||||||
allow_methods=["*"],
|
allow_methods=["*"],
|
||||||
allow_headers=["*"],
|
allow_headers=["*"],
|
||||||
|
|||||||
+23
-8
@@ -1,9 +1,15 @@
|
|||||||
import uuid
|
import uuid
|
||||||
|
from datetime import datetime, timezone
|
||||||
|
|
||||||
from pydantic import EmailStr
|
from pydantic import EmailStr
|
||||||
|
from sqlalchemy import DateTime
|
||||||
from sqlmodel import Field, Relationship, SQLModel
|
from sqlmodel import Field, Relationship, SQLModel
|
||||||
|
|
||||||
|
|
||||||
|
def get_datetime_utc() -> datetime:
|
||||||
|
return datetime.now(timezone.utc)
|
||||||
|
|
||||||
|
|
||||||
# Shared properties
|
# Shared properties
|
||||||
class UserBase(SQLModel):
|
class UserBase(SQLModel):
|
||||||
email: EmailStr = Field(unique=True, index=True, max_length=255)
|
email: EmailStr = Field(unique=True, index=True, max_length=255)
|
||||||
@@ -14,19 +20,19 @@ class UserBase(SQLModel):
|
|||||||
|
|
||||||
# Properties to receive via API on creation
|
# Properties to receive via API on creation
|
||||||
class UserCreate(UserBase):
|
class UserCreate(UserBase):
|
||||||
password: str = Field(min_length=8, max_length=40)
|
password: str = Field(min_length=8, max_length=128)
|
||||||
|
|
||||||
|
|
||||||
class UserRegister(SQLModel):
|
class UserRegister(SQLModel):
|
||||||
email: EmailStr = Field(max_length=255)
|
email: EmailStr = Field(max_length=255)
|
||||||
password: str = Field(min_length=8, max_length=40)
|
password: str = Field(min_length=8, max_length=128)
|
||||||
full_name: str | None = Field(default=None, max_length=255)
|
full_name: str | None = Field(default=None, max_length=255)
|
||||||
|
|
||||||
|
|
||||||
# Properties to receive via API on update, all are optional
|
# Properties to receive via API on update, all are optional
|
||||||
class UserUpdate(UserBase):
|
class UserUpdate(UserBase):
|
||||||
email: EmailStr | None = Field(default=None, max_length=255) # type: ignore
|
email: EmailStr | None = Field(default=None, max_length=255) # type: ignore
|
||||||
password: str | None = Field(default=None, min_length=8, max_length=40)
|
password: str | None = Field(default=None, min_length=8, max_length=128)
|
||||||
|
|
||||||
|
|
||||||
class UserUpdateMe(SQLModel):
|
class UserUpdateMe(SQLModel):
|
||||||
@@ -35,20 +41,25 @@ class UserUpdateMe(SQLModel):
|
|||||||
|
|
||||||
|
|
||||||
class UpdatePassword(SQLModel):
|
class UpdatePassword(SQLModel):
|
||||||
current_password: str = Field(min_length=8, max_length=40)
|
current_password: str = Field(min_length=8, max_length=128)
|
||||||
new_password: str = Field(min_length=8, max_length=40)
|
new_password: str = Field(min_length=8, max_length=128)
|
||||||
|
|
||||||
|
|
||||||
# Database model, database table inferred from class name
|
# Database model, database table inferred from class name
|
||||||
class User(UserBase, table=True):
|
class User(UserBase, table=True):
|
||||||
id: uuid.UUID = Field(default_factory=uuid.uuid4, primary_key=True)
|
id: uuid.UUID = Field(default_factory=uuid.uuid4, primary_key=True)
|
||||||
hashed_password: str
|
hashed_password: str
|
||||||
|
created_at: datetime | None = Field(
|
||||||
|
default_factory=get_datetime_utc,
|
||||||
|
sa_type=DateTime(timezone=True), # type: ignore
|
||||||
|
)
|
||||||
items: list["Item"] = Relationship(back_populates="owner", cascade_delete=True)
|
items: list["Item"] = Relationship(back_populates="owner", cascade_delete=True)
|
||||||
|
|
||||||
|
|
||||||
# Properties to return via API, id is always required
|
# Properties to return via API, id is always required
|
||||||
class UserPublic(UserBase):
|
class UserPublic(UserBase):
|
||||||
id: uuid.UUID
|
id: uuid.UUID
|
||||||
|
created_at: datetime | None = None
|
||||||
|
|
||||||
|
|
||||||
class UsersPublic(SQLModel):
|
class UsersPublic(SQLModel):
|
||||||
@@ -64,7 +75,7 @@ class ItemBase(SQLModel):
|
|||||||
|
|
||||||
# Properties to receive on item creation
|
# Properties to receive on item creation
|
||||||
class ItemCreate(ItemBase):
|
class ItemCreate(ItemBase):
|
||||||
title: str = Field(min_length=1, max_length=255)
|
pass
|
||||||
|
|
||||||
|
|
||||||
# Properties to receive on item update
|
# Properties to receive on item update
|
||||||
@@ -75,7 +86,10 @@ class ItemUpdate(ItemBase):
|
|||||||
# Database model, database table inferred from class name
|
# Database model, database table inferred from class name
|
||||||
class Item(ItemBase, table=True):
|
class Item(ItemBase, table=True):
|
||||||
id: uuid.UUID = Field(default_factory=uuid.uuid4, primary_key=True)
|
id: uuid.UUID = Field(default_factory=uuid.uuid4, primary_key=True)
|
||||||
title: str = Field(max_length=255)
|
created_at: datetime | None = Field(
|
||||||
|
default_factory=get_datetime_utc,
|
||||||
|
sa_type=DateTime(timezone=True), # type: ignore
|
||||||
|
)
|
||||||
owner_id: uuid.UUID = Field(
|
owner_id: uuid.UUID = Field(
|
||||||
foreign_key="user.id", nullable=False, ondelete="CASCADE"
|
foreign_key="user.id", nullable=False, ondelete="CASCADE"
|
||||||
)
|
)
|
||||||
@@ -86,6 +100,7 @@ class Item(ItemBase, table=True):
|
|||||||
class ItemPublic(ItemBase):
|
class ItemPublic(ItemBase):
|
||||||
id: uuid.UUID
|
id: uuid.UUID
|
||||||
owner_id: uuid.UUID
|
owner_id: uuid.UUID
|
||||||
|
created_at: datetime | None = None
|
||||||
|
|
||||||
|
|
||||||
class ItemsPublic(SQLModel):
|
class ItemsPublic(SQLModel):
|
||||||
@@ -111,4 +126,4 @@ class TokenPayload(SQLModel):
|
|||||||
|
|
||||||
class NewPassword(SQLModel):
|
class NewPassword(SQLModel):
|
||||||
token: str
|
token: str
|
||||||
new_password: str = Field(min_length=8, max_length=40)
|
new_password: str = Field(min_length=8, max_length=128)
|
||||||
|
|||||||
@@ -1,104 +0,0 @@
|
|||||||
from unittest.mock import patch
|
|
||||||
|
|
||||||
from fastapi.testclient import TestClient
|
|
||||||
from sqlmodel import Session, select
|
|
||||||
|
|
||||||
from app.core.config import settings
|
|
||||||
from app.core.security import verify_password
|
|
||||||
from app.models import User
|
|
||||||
from app.utils import generate_password_reset_token
|
|
||||||
|
|
||||||
|
|
||||||
def test_get_access_token(client: TestClient) -> None:
|
|
||||||
login_data = {
|
|
||||||
"username": settings.FIRST_SUPERUSER,
|
|
||||||
"password": settings.FIRST_SUPERUSER_PASSWORD,
|
|
||||||
}
|
|
||||||
r = client.post(f"{settings.API_V1_STR}/login/access-token", data=login_data)
|
|
||||||
tokens = r.json()
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert "access_token" in tokens
|
|
||||||
assert tokens["access_token"]
|
|
||||||
|
|
||||||
|
|
||||||
def test_get_access_token_incorrect_password(client: TestClient) -> None:
|
|
||||||
login_data = {
|
|
||||||
"username": settings.FIRST_SUPERUSER,
|
|
||||||
"password": "incorrect",
|
|
||||||
}
|
|
||||||
r = client.post(f"{settings.API_V1_STR}/login/access-token", data=login_data)
|
|
||||||
assert r.status_code == 400
|
|
||||||
|
|
||||||
|
|
||||||
def test_use_access_token(
|
|
||||||
client: TestClient, superuser_token_headers: dict[str, str]
|
|
||||||
) -> None:
|
|
||||||
r = client.post(
|
|
||||||
f"{settings.API_V1_STR}/login/test-token",
|
|
||||||
headers=superuser_token_headers,
|
|
||||||
)
|
|
||||||
result = r.json()
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert "email" in result
|
|
||||||
|
|
||||||
|
|
||||||
def test_recovery_password(
|
|
||||||
client: TestClient, normal_user_token_headers: dict[str, str]
|
|
||||||
) -> None:
|
|
||||||
with (
|
|
||||||
patch("app.core.config.settings.SMTP_HOST", "smtp.example.com"),
|
|
||||||
patch("app.core.config.settings.SMTP_USER", "admin@example.com"),
|
|
||||||
):
|
|
||||||
email = "test@example.com"
|
|
||||||
r = client.post(
|
|
||||||
f"{settings.API_V1_STR}/password-recovery/{email}",
|
|
||||||
headers=normal_user_token_headers,
|
|
||||||
)
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert r.json() == {"message": "Password recovery email sent"}
|
|
||||||
|
|
||||||
|
|
||||||
def test_recovery_password_user_not_exits(
|
|
||||||
client: TestClient, normal_user_token_headers: dict[str, str]
|
|
||||||
) -> None:
|
|
||||||
email = "jVgQr@example.com"
|
|
||||||
r = client.post(
|
|
||||||
f"{settings.API_V1_STR}/password-recovery/{email}",
|
|
||||||
headers=normal_user_token_headers,
|
|
||||||
)
|
|
||||||
assert r.status_code == 404
|
|
||||||
|
|
||||||
|
|
||||||
def test_reset_password(
|
|
||||||
client: TestClient, superuser_token_headers: dict[str, str], db: Session
|
|
||||||
) -> None:
|
|
||||||
token = generate_password_reset_token(email=settings.FIRST_SUPERUSER)
|
|
||||||
data = {"new_password": "changethis", "token": token}
|
|
||||||
r = client.post(
|
|
||||||
f"{settings.API_V1_STR}/reset-password/",
|
|
||||||
headers=superuser_token_headers,
|
|
||||||
json=data,
|
|
||||||
)
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert r.json() == {"message": "Password updated successfully"}
|
|
||||||
|
|
||||||
user_query = select(User).where(User.email == settings.FIRST_SUPERUSER)
|
|
||||||
user = db.exec(user_query).first()
|
|
||||||
assert user
|
|
||||||
assert verify_password(data["new_password"], user.hashed_password)
|
|
||||||
|
|
||||||
|
|
||||||
def test_reset_password_invalid_token(
|
|
||||||
client: TestClient, superuser_token_headers: dict[str, str]
|
|
||||||
) -> None:
|
|
||||||
data = {"new_password": "changethis", "token": "invalid"}
|
|
||||||
r = client.post(
|
|
||||||
f"{settings.API_V1_STR}/reset-password/",
|
|
||||||
headers=superuser_token_headers,
|
|
||||||
json=data,
|
|
||||||
)
|
|
||||||
response = r.json()
|
|
||||||
|
|
||||||
assert "detail" in response
|
|
||||||
assert r.status_code == 400
|
|
||||||
assert response["detail"] == "Invalid token"
|
|
||||||
+11
-5
@@ -9,8 +9,12 @@ import jwt
|
|||||||
from jinja2 import Template
|
from jinja2 import Template
|
||||||
from jwt.exceptions import InvalidTokenError
|
from jwt.exceptions import InvalidTokenError
|
||||||
|
|
||||||
|
from app.core import security
|
||||||
from app.core.config import settings
|
from app.core.config import settings
|
||||||
|
|
||||||
|
logging.basicConfig(level=logging.INFO)
|
||||||
|
logger = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
|
||||||
@dataclass
|
@dataclass
|
||||||
class EmailData:
|
class EmailData:
|
||||||
@@ -48,7 +52,7 @@ def send_email(
|
|||||||
if settings.SMTP_PASSWORD:
|
if settings.SMTP_PASSWORD:
|
||||||
smtp_options["password"] = settings.SMTP_PASSWORD
|
smtp_options["password"] = settings.SMTP_PASSWORD
|
||||||
response = message.send(to=email_to, smtp=smtp_options)
|
response = message.send(to=email_to, smtp=smtp_options)
|
||||||
logging.info(f"send email result: {response}")
|
logger.info(f"send email result: {response}")
|
||||||
|
|
||||||
|
|
||||||
def generate_test_email(email_to: str) -> EmailData:
|
def generate_test_email(email_to: str) -> EmailData:
|
||||||
@@ -64,7 +68,7 @@ def generate_test_email(email_to: str) -> EmailData:
|
|||||||
def generate_reset_password_email(email_to: str, email: str, token: str) -> EmailData:
|
def generate_reset_password_email(email_to: str, email: str, token: str) -> EmailData:
|
||||||
project_name = settings.PROJECT_NAME
|
project_name = settings.PROJECT_NAME
|
||||||
subject = f"{project_name} - Password recovery for user {email}"
|
subject = f"{project_name} - Password recovery for user {email}"
|
||||||
link = f"{settings.server_host}/reset-password?token={token}"
|
link = f"{settings.FRONTEND_HOST}/reset-password?token={token}"
|
||||||
html_content = render_email_template(
|
html_content = render_email_template(
|
||||||
template_name="reset_password.html",
|
template_name="reset_password.html",
|
||||||
context={
|
context={
|
||||||
@@ -90,7 +94,7 @@ def generate_new_account_email(
|
|||||||
"username": username,
|
"username": username,
|
||||||
"password": password,
|
"password": password,
|
||||||
"email": email_to,
|
"email": email_to,
|
||||||
"link": settings.server_host,
|
"link": settings.FRONTEND_HOST,
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
return EmailData(html_content=html_content, subject=subject)
|
return EmailData(html_content=html_content, subject=subject)
|
||||||
@@ -104,14 +108,16 @@ def generate_password_reset_token(email: str) -> str:
|
|||||||
encoded_jwt = jwt.encode(
|
encoded_jwt = jwt.encode(
|
||||||
{"exp": exp, "nbf": now, "sub": email},
|
{"exp": exp, "nbf": now, "sub": email},
|
||||||
settings.SECRET_KEY,
|
settings.SECRET_KEY,
|
||||||
algorithm="HS256",
|
algorithm=security.ALGORITHM,
|
||||||
)
|
)
|
||||||
return encoded_jwt
|
return encoded_jwt
|
||||||
|
|
||||||
|
|
||||||
def verify_password_reset_token(token: str) -> str | None:
|
def verify_password_reset_token(token: str) -> str | None:
|
||||||
try:
|
try:
|
||||||
decoded_token = jwt.decode(token, settings.SECRET_KEY, algorithms=["HS256"])
|
decoded_token = jwt.decode(
|
||||||
|
token, settings.SECRET_KEY, algorithms=[security.ALGORITHM]
|
||||||
|
)
|
||||||
return str(decoded_token["sub"])
|
return str(decoded_token["sub"])
|
||||||
except InvalidTokenError:
|
except InvalidTokenError:
|
||||||
return None
|
return None
|
||||||
|
|||||||
Generated
-2084
File diff suppressed because it is too large
Load Diff
+41
-34
@@ -1,43 +1,38 @@
|
|||||||
[tool.poetry]
|
[project]
|
||||||
name = "app"
|
name = "app"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
description = ""
|
description = ""
|
||||||
authors = ["Admin <admin@example.com>"]
|
requires-python = ">=3.10,<4.0"
|
||||||
|
dependencies = [
|
||||||
|
"fastapi[standard]<1.0.0,>=0.114.2",
|
||||||
|
"python-multipart<1.0.0,>=0.0.7",
|
||||||
|
"email-validator<3.0.0.0,>=2.1.0.post1",
|
||||||
|
"tenacity<9.0.0,>=8.2.3",
|
||||||
|
"pydantic>2.0",
|
||||||
|
"emails<1.0,>=0.6",
|
||||||
|
"jinja2<4.0.0,>=3.1.4",
|
||||||
|
"alembic<2.0.0,>=1.12.1",
|
||||||
|
"httpx<1.0.0,>=0.25.1",
|
||||||
|
"psycopg[binary]<4.0.0,>=3.1.13",
|
||||||
|
"sqlmodel<1.0.0,>=0.0.21",
|
||||||
|
"pydantic-settings<3.0.0,>=2.2.1",
|
||||||
|
"sentry-sdk[fastapi]<2.0.0,>=1.40.6",
|
||||||
|
"pyjwt<3.0.0,>=2.8.0",
|
||||||
|
"pwdlib[argon2,bcrypt]>=0.3.0",
|
||||||
|
]
|
||||||
|
|
||||||
[tool.poetry.dependencies]
|
[dependency-groups]
|
||||||
python = "^3.10"
|
dev = [
|
||||||
uvicorn = {extras = ["standard"], version = "^0.24.0.post1"}
|
"pytest<8.0.0,>=7.4.3",
|
||||||
fastapi = "^0.109.1"
|
"mypy<2.0.0,>=1.8.0",
|
||||||
python-multipart = "^0.0.7"
|
"ruff<1.0.0,>=0.2.2",
|
||||||
email-validator = "^2.1.0.post1"
|
"prek>=0.2.24,<1.0.0",
|
||||||
passlib = {extras = ["bcrypt"], version = "^1.7.4"}
|
"coverage<8.0.0,>=7.4.3",
|
||||||
tenacity = "^8.2.3"
|
]
|
||||||
pydantic = ">2.0"
|
|
||||||
emails = "^0.6"
|
|
||||||
|
|
||||||
gunicorn = "^22.0.0"
|
|
||||||
jinja2 = "^3.1.4"
|
|
||||||
alembic = "^1.12.1"
|
|
||||||
httpx = "^0.25.1"
|
|
||||||
psycopg = {extras = ["binary"], version = "^3.1.13"}
|
|
||||||
sqlmodel = "^0.0.21"
|
|
||||||
# Pin bcrypt until passlib supports the latest
|
|
||||||
bcrypt = "4.0.1"
|
|
||||||
pydantic-settings = "^2.2.1"
|
|
||||||
sentry-sdk = {extras = ["fastapi"], version = "^1.40.6"}
|
|
||||||
pyjwt = "^2.8.0"
|
|
||||||
|
|
||||||
[tool.poetry.group.dev.dependencies]
|
|
||||||
pytest = "^7.4.3"
|
|
||||||
mypy = "^1.8.0"
|
|
||||||
ruff = "^0.2.2"
|
|
||||||
pre-commit = "^3.6.2"
|
|
||||||
types-passlib = "^1.7.7.20240106"
|
|
||||||
coverage = "^7.4.3"
|
|
||||||
|
|
||||||
[build-system]
|
[build-system]
|
||||||
requires = ["poetry>=0.12"]
|
requires = ["hatchling"]
|
||||||
build-backend = "poetry.masonry.api"
|
build-backend = "hatchling.build"
|
||||||
|
|
||||||
[tool.mypy]
|
[tool.mypy]
|
||||||
strict = true
|
strict = true
|
||||||
@@ -57,6 +52,7 @@ select = [
|
|||||||
"C4", # flake8-comprehensions
|
"C4", # flake8-comprehensions
|
||||||
"UP", # pyupgrade
|
"UP", # pyupgrade
|
||||||
"ARG001", # unused arguments in functions
|
"ARG001", # unused arguments in functions
|
||||||
|
"T201", # print statements are not allowed
|
||||||
]
|
]
|
||||||
ignore = [
|
ignore = [
|
||||||
"E501", # line too long, handled by black
|
"E501", # line too long, handled by black
|
||||||
@@ -68,3 +64,14 @@ ignore = [
|
|||||||
[tool.ruff.lint.pyupgrade]
|
[tool.ruff.lint.pyupgrade]
|
||||||
# Preserve types, even if a file imports `from __future__ import annotations`.
|
# Preserve types, even if a file imports `from __future__ import annotations`.
|
||||||
keep-runtime-typing = true
|
keep-runtime-typing = true
|
||||||
|
|
||||||
|
[tool.coverage.run]
|
||||||
|
source = ["app"]
|
||||||
|
dynamic_context = "test_function"
|
||||||
|
|
||||||
|
[tool.coverage.report]
|
||||||
|
show_missing = true
|
||||||
|
sort = "-Cover"
|
||||||
|
|
||||||
|
[tool.coverage.html]
|
||||||
|
show_contexts = true
|
||||||
|
|||||||
@@ -1,10 +1,13 @@
|
|||||||
#! /usr/bin/env bash
|
#! /usr/bin/env bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
set -x
|
||||||
|
|
||||||
# Let the DB start
|
# Let the DB start
|
||||||
python /app/app/backend_pre_start.py
|
python app/backend_pre_start.py
|
||||||
|
|
||||||
# Run migrations
|
# Run migrations
|
||||||
alembic upgrade head
|
alembic upgrade head
|
||||||
|
|
||||||
# Create initial data in DB
|
# Create initial data in DB
|
||||||
python /app/app/initial_data.py
|
python app/initial_data.py
|
||||||
@@ -3,6 +3,6 @@
|
|||||||
set -e
|
set -e
|
||||||
set -x
|
set -x
|
||||||
|
|
||||||
coverage run --source=app -m pytest
|
coverage run -m pytest tests/
|
||||||
coverage report --show-missing
|
coverage report
|
||||||
coverage html --title "${@-coverage}"
|
coverage html --title "${@-coverage}"
|
||||||
|
|||||||
@@ -0,0 +1,7 @@
|
|||||||
|
#! /usr/bin/env bash
|
||||||
|
set -e
|
||||||
|
set -x
|
||||||
|
|
||||||
|
python app/tests_pre_start.py
|
||||||
|
|
||||||
|
bash scripts/test.sh "$@"
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
#! /usr/bin/env bash
|
|
||||||
set -e
|
|
||||||
set -x
|
|
||||||
|
|
||||||
python /app/app/tests_pre_start.py
|
|
||||||
|
|
||||||
bash ./scripts/test.sh "$@"
|
|
||||||
@@ -4,7 +4,7 @@ from fastapi.testclient import TestClient
|
|||||||
from sqlmodel import Session
|
from sqlmodel import Session
|
||||||
|
|
||||||
from app.core.config import settings
|
from app.core.config import settings
|
||||||
from app.tests.utils.item import create_random_item
|
from tests.utils.item import create_random_item
|
||||||
|
|
||||||
|
|
||||||
def test_create_item(
|
def test_create_item(
|
||||||
@@ -60,7 +60,7 @@ def test_read_item_not_enough_permissions(
|
|||||||
f"{settings.API_V1_STR}/items/{item.id}",
|
f"{settings.API_V1_STR}/items/{item.id}",
|
||||||
headers=normal_user_token_headers,
|
headers=normal_user_token_headers,
|
||||||
)
|
)
|
||||||
assert response.status_code == 400
|
assert response.status_code == 403
|
||||||
content = response.json()
|
content = response.json()
|
||||||
assert content["detail"] == "Not enough permissions"
|
assert content["detail"] == "Not enough permissions"
|
||||||
|
|
||||||
@@ -121,7 +121,7 @@ def test_update_item_not_enough_permissions(
|
|||||||
headers=normal_user_token_headers,
|
headers=normal_user_token_headers,
|
||||||
json=data,
|
json=data,
|
||||||
)
|
)
|
||||||
assert response.status_code == 400
|
assert response.status_code == 403
|
||||||
content = response.json()
|
content = response.json()
|
||||||
assert content["detail"] == "Not enough permissions"
|
assert content["detail"] == "Not enough permissions"
|
||||||
|
|
||||||
@@ -159,6 +159,6 @@ def test_delete_item_not_enough_permissions(
|
|||||||
f"{settings.API_V1_STR}/items/{item.id}",
|
f"{settings.API_V1_STR}/items/{item.id}",
|
||||||
headers=normal_user_token_headers,
|
headers=normal_user_token_headers,
|
||||||
)
|
)
|
||||||
assert response.status_code == 400
|
assert response.status_code == 403
|
||||||
content = response.json()
|
content = response.json()
|
||||||
assert content["detail"] == "Not enough permissions"
|
assert content["detail"] == "Not enough permissions"
|
||||||
@@ -0,0 +1,191 @@
|
|||||||
|
from unittest.mock import patch
|
||||||
|
|
||||||
|
from fastapi.testclient import TestClient
|
||||||
|
from pwdlib.hashers.bcrypt import BcryptHasher
|
||||||
|
from sqlmodel import Session
|
||||||
|
|
||||||
|
from app.core.config import settings
|
||||||
|
from app.core.security import get_password_hash, verify_password
|
||||||
|
from app.crud import create_user
|
||||||
|
from app.models import User, UserCreate
|
||||||
|
from app.utils import generate_password_reset_token
|
||||||
|
from tests.utils.user import user_authentication_headers
|
||||||
|
from tests.utils.utils import random_email, random_lower_string
|
||||||
|
|
||||||
|
|
||||||
|
def test_get_access_token(client: TestClient) -> None:
|
||||||
|
login_data = {
|
||||||
|
"username": settings.FIRST_SUPERUSER,
|
||||||
|
"password": settings.FIRST_SUPERUSER_PASSWORD,
|
||||||
|
}
|
||||||
|
r = client.post(f"{settings.API_V1_STR}/login/access-token", data=login_data)
|
||||||
|
tokens = r.json()
|
||||||
|
assert r.status_code == 200
|
||||||
|
assert "access_token" in tokens
|
||||||
|
assert tokens["access_token"]
|
||||||
|
|
||||||
|
|
||||||
|
def test_get_access_token_incorrect_password(client: TestClient) -> None:
|
||||||
|
login_data = {
|
||||||
|
"username": settings.FIRST_SUPERUSER,
|
||||||
|
"password": "incorrect",
|
||||||
|
}
|
||||||
|
r = client.post(f"{settings.API_V1_STR}/login/access-token", data=login_data)
|
||||||
|
assert r.status_code == 400
|
||||||
|
|
||||||
|
|
||||||
|
def test_use_access_token(
|
||||||
|
client: TestClient, superuser_token_headers: dict[str, str]
|
||||||
|
) -> None:
|
||||||
|
r = client.post(
|
||||||
|
f"{settings.API_V1_STR}/login/test-token",
|
||||||
|
headers=superuser_token_headers,
|
||||||
|
)
|
||||||
|
result = r.json()
|
||||||
|
assert r.status_code == 200
|
||||||
|
assert "email" in result
|
||||||
|
|
||||||
|
|
||||||
|
def test_recovery_password(
|
||||||
|
client: TestClient, normal_user_token_headers: dict[str, str]
|
||||||
|
) -> None:
|
||||||
|
with (
|
||||||
|
patch("app.core.config.settings.SMTP_HOST", "smtp.example.com"),
|
||||||
|
patch("app.core.config.settings.SMTP_USER", "admin@example.com"),
|
||||||
|
):
|
||||||
|
email = "test@example.com"
|
||||||
|
r = client.post(
|
||||||
|
f"{settings.API_V1_STR}/password-recovery/{email}",
|
||||||
|
headers=normal_user_token_headers,
|
||||||
|
)
|
||||||
|
assert r.status_code == 200
|
||||||
|
assert r.json() == {
|
||||||
|
"message": "If that email is registered, we sent a password recovery link"
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
def test_recovery_password_user_not_exits(
|
||||||
|
client: TestClient, normal_user_token_headers: dict[str, str]
|
||||||
|
) -> None:
|
||||||
|
email = "jVgQr@example.com"
|
||||||
|
r = client.post(
|
||||||
|
f"{settings.API_V1_STR}/password-recovery/{email}",
|
||||||
|
headers=normal_user_token_headers,
|
||||||
|
)
|
||||||
|
# Should return 200 with generic message to prevent email enumeration attacks
|
||||||
|
assert r.status_code == 200
|
||||||
|
assert r.json() == {
|
||||||
|
"message": "If that email is registered, we sent a password recovery link"
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
def test_reset_password(client: TestClient, db: Session) -> None:
|
||||||
|
email = random_email()
|
||||||
|
password = random_lower_string()
|
||||||
|
new_password = random_lower_string()
|
||||||
|
|
||||||
|
user_create = UserCreate(
|
||||||
|
email=email,
|
||||||
|
full_name="Test User",
|
||||||
|
password=password,
|
||||||
|
is_active=True,
|
||||||
|
is_superuser=False,
|
||||||
|
)
|
||||||
|
user = create_user(session=db, user_create=user_create)
|
||||||
|
token = generate_password_reset_token(email=email)
|
||||||
|
headers = user_authentication_headers(client=client, email=email, password=password)
|
||||||
|
data = {"new_password": new_password, "token": token}
|
||||||
|
|
||||||
|
r = client.post(
|
||||||
|
f"{settings.API_V1_STR}/reset-password/",
|
||||||
|
headers=headers,
|
||||||
|
json=data,
|
||||||
|
)
|
||||||
|
|
||||||
|
assert r.status_code == 200
|
||||||
|
assert r.json() == {"message": "Password updated successfully"}
|
||||||
|
|
||||||
|
db.refresh(user)
|
||||||
|
verified, _ = verify_password(new_password, user.hashed_password)
|
||||||
|
assert verified
|
||||||
|
|
||||||
|
|
||||||
|
def test_reset_password_invalid_token(
|
||||||
|
client: TestClient, superuser_token_headers: dict[str, str]
|
||||||
|
) -> None:
|
||||||
|
data = {"new_password": "changethis", "token": "invalid"}
|
||||||
|
r = client.post(
|
||||||
|
f"{settings.API_V1_STR}/reset-password/",
|
||||||
|
headers=superuser_token_headers,
|
||||||
|
json=data,
|
||||||
|
)
|
||||||
|
response = r.json()
|
||||||
|
|
||||||
|
assert "detail" in response
|
||||||
|
assert r.status_code == 400
|
||||||
|
assert response["detail"] == "Invalid token"
|
||||||
|
|
||||||
|
|
||||||
|
def test_login_with_bcrypt_password_upgrades_to_argon2(
|
||||||
|
client: TestClient, db: Session
|
||||||
|
) -> None:
|
||||||
|
"""Test that logging in with a bcrypt password hash upgrades it to argon2."""
|
||||||
|
email = random_email()
|
||||||
|
password = random_lower_string()
|
||||||
|
|
||||||
|
# Create a bcrypt hash directly (simulating legacy password)
|
||||||
|
bcrypt_hasher = BcryptHasher()
|
||||||
|
bcrypt_hash = bcrypt_hasher.hash(password)
|
||||||
|
assert bcrypt_hash.startswith("$2") # bcrypt hashes start with $2
|
||||||
|
|
||||||
|
user = User(email=email, hashed_password=bcrypt_hash, is_active=True)
|
||||||
|
db.add(user)
|
||||||
|
db.commit()
|
||||||
|
db.refresh(user)
|
||||||
|
|
||||||
|
assert user.hashed_password.startswith("$2")
|
||||||
|
|
||||||
|
login_data = {"username": email, "password": password}
|
||||||
|
r = client.post(f"{settings.API_V1_STR}/login/access-token", data=login_data)
|
||||||
|
assert r.status_code == 200
|
||||||
|
tokens = r.json()
|
||||||
|
assert "access_token" in tokens
|
||||||
|
|
||||||
|
db.refresh(user)
|
||||||
|
|
||||||
|
# Verify the hash was upgraded to argon2
|
||||||
|
assert user.hashed_password.startswith("$argon2")
|
||||||
|
|
||||||
|
verified, updated_hash = verify_password(password, user.hashed_password)
|
||||||
|
assert verified
|
||||||
|
# Should not need another update since it's already argon2
|
||||||
|
assert updated_hash is None
|
||||||
|
|
||||||
|
|
||||||
|
def test_login_with_argon2_password_keeps_hash(client: TestClient, db: Session) -> None:
|
||||||
|
"""Test that logging in with an argon2 password hash does not update it."""
|
||||||
|
email = random_email()
|
||||||
|
password = random_lower_string()
|
||||||
|
|
||||||
|
# Create an argon2 hash (current default)
|
||||||
|
argon2_hash = get_password_hash(password)
|
||||||
|
assert argon2_hash.startswith("$argon2")
|
||||||
|
|
||||||
|
# Create user with argon2 hash
|
||||||
|
user = User(email=email, hashed_password=argon2_hash, is_active=True)
|
||||||
|
db.add(user)
|
||||||
|
db.commit()
|
||||||
|
db.refresh(user)
|
||||||
|
|
||||||
|
original_hash = user.hashed_password
|
||||||
|
|
||||||
|
login_data = {"username": email, "password": password}
|
||||||
|
r = client.post(f"{settings.API_V1_STR}/login/access-token", data=login_data)
|
||||||
|
assert r.status_code == 200
|
||||||
|
tokens = r.json()
|
||||||
|
assert "access_token" in tokens
|
||||||
|
|
||||||
|
db.refresh(user)
|
||||||
|
|
||||||
|
assert user.hashed_password == original_hash
|
||||||
|
assert user.hashed_password.startswith("$argon2")
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
from fastapi.testclient import TestClient
|
||||||
|
from sqlmodel import Session, select
|
||||||
|
|
||||||
|
from app.core.config import settings
|
||||||
|
from app.models import User
|
||||||
|
|
||||||
|
|
||||||
|
def test_create_user(client: TestClient, db: Session) -> None:
|
||||||
|
r = client.post(
|
||||||
|
f"{settings.API_V1_STR}/private/users/",
|
||||||
|
json={
|
||||||
|
"email": "pollo@listo.com",
|
||||||
|
"password": "password123",
|
||||||
|
"full_name": "Pollo Listo",
|
||||||
|
},
|
||||||
|
)
|
||||||
|
|
||||||
|
assert r.status_code == 200
|
||||||
|
|
||||||
|
data = r.json()
|
||||||
|
|
||||||
|
user = db.exec(select(User).where(User.id == data["id"])).first()
|
||||||
|
|
||||||
|
assert user
|
||||||
|
assert user.email == "pollo@listo.com"
|
||||||
|
assert user.full_name == "Pollo Listo"
|
||||||
+42
-7
@@ -8,7 +8,8 @@ from app import crud
|
|||||||
from app.core.config import settings
|
from app.core.config import settings
|
||||||
from app.core.security import verify_password
|
from app.core.security import verify_password
|
||||||
from app.models import User, UserCreate
|
from app.models import User, UserCreate
|
||||||
from app.tests.utils.utils import random_email, random_lower_string
|
from tests.utils.user import create_random_user
|
||||||
|
from tests.utils.utils import random_email, random_lower_string
|
||||||
|
|
||||||
|
|
||||||
def test_get_users_superuser_me(
|
def test_get_users_superuser_me(
|
||||||
@@ -56,7 +57,7 @@ def test_create_user_new_email(
|
|||||||
assert user.email == created_user["email"]
|
assert user.email == created_user["email"]
|
||||||
|
|
||||||
|
|
||||||
def test_get_existing_user(
|
def test_get_existing_user_as_superuser(
|
||||||
client: TestClient, superuser_token_headers: dict[str, str], db: Session
|
client: TestClient, superuser_token_headers: dict[str, str], db: Session
|
||||||
) -> None:
|
) -> None:
|
||||||
username = random_email()
|
username = random_email()
|
||||||
@@ -75,6 +76,17 @@ def test_get_existing_user(
|
|||||||
assert existing_user.email == api_user["email"]
|
assert existing_user.email == api_user["email"]
|
||||||
|
|
||||||
|
|
||||||
|
def test_get_non_existing_user_as_superuser(
|
||||||
|
client: TestClient, superuser_token_headers: dict[str, str]
|
||||||
|
) -> None:
|
||||||
|
r = client.get(
|
||||||
|
f"{settings.API_V1_STR}/users/{uuid.uuid4()}",
|
||||||
|
headers=superuser_token_headers,
|
||||||
|
)
|
||||||
|
assert r.status_code == 404
|
||||||
|
assert r.json() == {"detail": "User not found"}
|
||||||
|
|
||||||
|
|
||||||
def test_get_existing_user_current_user(client: TestClient, db: Session) -> None:
|
def test_get_existing_user_current_user(client: TestClient, db: Session) -> None:
|
||||||
username = random_email()
|
username = random_email()
|
||||||
password = random_lower_string()
|
password = random_lower_string()
|
||||||
@@ -103,10 +115,28 @@ def test_get_existing_user_current_user(client: TestClient, db: Session) -> None
|
|||||||
|
|
||||||
|
|
||||||
def test_get_existing_user_permissions_error(
|
def test_get_existing_user_permissions_error(
|
||||||
client: TestClient, normal_user_token_headers: dict[str, str]
|
db: Session,
|
||||||
|
client: TestClient,
|
||||||
|
normal_user_token_headers: dict[str, str],
|
||||||
) -> None:
|
) -> None:
|
||||||
|
user = create_random_user(db)
|
||||||
|
|
||||||
r = client.get(
|
r = client.get(
|
||||||
f"{settings.API_V1_STR}/users/{uuid.uuid4()}",
|
f"{settings.API_V1_STR}/users/{user.id}",
|
||||||
|
headers=normal_user_token_headers,
|
||||||
|
)
|
||||||
|
assert r.status_code == 403
|
||||||
|
assert r.json() == {"detail": "The user doesn't have enough privileges"}
|
||||||
|
|
||||||
|
|
||||||
|
def test_get_non_existing_user_permissions_error(
|
||||||
|
client: TestClient,
|
||||||
|
normal_user_token_headers: dict[str, str],
|
||||||
|
) -> None:
|
||||||
|
user_id = uuid.uuid4()
|
||||||
|
|
||||||
|
r = client.get(
|
||||||
|
f"{settings.API_V1_STR}/users/{user_id}",
|
||||||
headers=normal_user_token_headers,
|
headers=normal_user_token_headers,
|
||||||
)
|
)
|
||||||
assert r.status_code == 403
|
assert r.status_code == 403
|
||||||
@@ -212,7 +242,8 @@ def test_update_password_me(
|
|||||||
user_db = db.exec(user_query).first()
|
user_db = db.exec(user_query).first()
|
||||||
assert user_db
|
assert user_db
|
||||||
assert user_db.email == settings.FIRST_SUPERUSER
|
assert user_db.email == settings.FIRST_SUPERUSER
|
||||||
assert verify_password(new_password, user_db.hashed_password)
|
verified, _ = verify_password(new_password, user_db.hashed_password)
|
||||||
|
assert verified
|
||||||
|
|
||||||
# Revert to the old password to keep consistency in test
|
# Revert to the old password to keep consistency in test
|
||||||
old_data = {
|
old_data = {
|
||||||
@@ -227,7 +258,10 @@ def test_update_password_me(
|
|||||||
db.refresh(user_db)
|
db.refresh(user_db)
|
||||||
|
|
||||||
assert r.status_code == 200
|
assert r.status_code == 200
|
||||||
assert verify_password(settings.FIRST_SUPERUSER_PASSWORD, user_db.hashed_password)
|
verified, _ = verify_password(
|
||||||
|
settings.FIRST_SUPERUSER_PASSWORD, user_db.hashed_password
|
||||||
|
)
|
||||||
|
assert verified
|
||||||
|
|
||||||
|
|
||||||
def test_update_password_me_incorrect_password(
|
def test_update_password_me_incorrect_password(
|
||||||
@@ -301,7 +335,8 @@ def test_register_user(client: TestClient, db: Session) -> None:
|
|||||||
assert user_db
|
assert user_db
|
||||||
assert user_db.email == username
|
assert user_db.email == username
|
||||||
assert user_db.full_name == full_name
|
assert user_db.full_name == full_name
|
||||||
assert verify_password(password, user_db.hashed_password)
|
verified, _ = verify_password(password, user_db.hashed_password)
|
||||||
|
assert verified
|
||||||
|
|
||||||
|
|
||||||
def test_register_user_already_exists_error(client: TestClient) -> None:
|
def test_register_user_already_exists_error(client: TestClient) -> None:
|
||||||
@@ -8,8 +8,8 @@ from app.core.config import settings
|
|||||||
from app.core.db import engine, init_db
|
from app.core.db import engine, init_db
|
||||||
from app.main import app
|
from app.main import app
|
||||||
from app.models import Item, User
|
from app.models import Item, User
|
||||||
from app.tests.utils.user import authentication_token_from_email
|
from tests.utils.user import authentication_token_from_email
|
||||||
from app.tests.utils.utils import get_superuser_token_headers
|
from tests.utils.utils import get_superuser_token_headers
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture(scope="session", autouse=True)
|
@pytest.fixture(scope="session", autouse=True)
|
||||||
@@ -1,10 +1,11 @@
|
|||||||
from fastapi.encoders import jsonable_encoder
|
from fastapi.encoders import jsonable_encoder
|
||||||
|
from pwdlib.hashers.bcrypt import BcryptHasher
|
||||||
from sqlmodel import Session
|
from sqlmodel import Session
|
||||||
|
|
||||||
from app import crud
|
from app import crud
|
||||||
from app.core.security import verify_password
|
from app.core.security import verify_password
|
||||||
from app.models import User, UserCreate, UserUpdate
|
from app.models import User, UserCreate, UserUpdate
|
||||||
from app.tests.utils.utils import random_email, random_lower_string
|
from tests.utils.utils import random_email, random_lower_string
|
||||||
|
|
||||||
|
|
||||||
def test_create_user(db: Session) -> None:
|
def test_create_user(db: Session) -> None:
|
||||||
@@ -44,9 +45,9 @@ def test_check_if_user_is_active(db: Session) -> None:
|
|||||||
def test_check_if_user_is_active_inactive(db: Session) -> None:
|
def test_check_if_user_is_active_inactive(db: Session) -> None:
|
||||||
email = random_email()
|
email = random_email()
|
||||||
password = random_lower_string()
|
password = random_lower_string()
|
||||||
user_in = UserCreate(email=email, password=password, disabled=True)
|
user_in = UserCreate(email=email, password=password, is_active=False)
|
||||||
user = crud.create_user(session=db, user_create=user_in)
|
user = crud.create_user(session=db, user_create=user_in)
|
||||||
assert user.is_active
|
assert user.is_active is False
|
||||||
|
|
||||||
|
|
||||||
def test_check_if_user_is_superuser(db: Session) -> None:
|
def test_check_if_user_is_superuser(db: Session) -> None:
|
||||||
@@ -88,4 +89,42 @@ def test_update_user(db: Session) -> None:
|
|||||||
user_2 = db.get(User, user.id)
|
user_2 = db.get(User, user.id)
|
||||||
assert user_2
|
assert user_2
|
||||||
assert user.email == user_2.email
|
assert user.email == user_2.email
|
||||||
assert verify_password(new_password, user_2.hashed_password)
|
verified, _ = verify_password(new_password, user_2.hashed_password)
|
||||||
|
assert verified
|
||||||
|
|
||||||
|
|
||||||
|
def test_authenticate_user_with_bcrypt_upgrades_to_argon2(db: Session) -> None:
|
||||||
|
"""Test that a user with bcrypt password hash gets upgraded to argon2 on login."""
|
||||||
|
email = random_email()
|
||||||
|
password = random_lower_string()
|
||||||
|
|
||||||
|
# Create a bcrypt hash directly (simulating legacy password)
|
||||||
|
bcrypt_hasher = BcryptHasher()
|
||||||
|
bcrypt_hash = bcrypt_hasher.hash(password)
|
||||||
|
assert bcrypt_hash.startswith("$2") # bcrypt hashes start with $2
|
||||||
|
|
||||||
|
# Create user with bcrypt hash directly in the database
|
||||||
|
user = User(email=email, hashed_password=bcrypt_hash)
|
||||||
|
db.add(user)
|
||||||
|
db.commit()
|
||||||
|
db.refresh(user)
|
||||||
|
|
||||||
|
# Verify the hash is bcrypt before authentication
|
||||||
|
assert user.hashed_password.startswith("$2")
|
||||||
|
|
||||||
|
# Authenticate - this should upgrade the hash to argon2
|
||||||
|
authenticated_user = crud.authenticate(session=db, email=email, password=password)
|
||||||
|
assert authenticated_user
|
||||||
|
assert authenticated_user.email == email
|
||||||
|
|
||||||
|
db.refresh(authenticated_user)
|
||||||
|
|
||||||
|
# Verify the hash was upgraded to argon2
|
||||||
|
assert authenticated_user.hashed_password.startswith("$argon2")
|
||||||
|
|
||||||
|
verified, updated_hash = verify_password(
|
||||||
|
password, authenticated_user.hashed_password
|
||||||
|
)
|
||||||
|
assert verified
|
||||||
|
# Should not need another update since it's already argon2
|
||||||
|
assert updated_hash is None
|
||||||
+9
-9
@@ -9,11 +9,13 @@ def test_init_successful_connection() -> None:
|
|||||||
engine_mock = MagicMock()
|
engine_mock = MagicMock()
|
||||||
|
|
||||||
session_mock = MagicMock()
|
session_mock = MagicMock()
|
||||||
exec_mock = MagicMock(return_value=True)
|
session_mock.__enter__.return_value = session_mock
|
||||||
session_mock.configure_mock(**{"exec.return_value": exec_mock})
|
|
||||||
|
select1 = select(1)
|
||||||
|
|
||||||
with (
|
with (
|
||||||
patch("sqlmodel.Session", return_value=session_mock),
|
patch("app.backend_pre_start.Session", return_value=session_mock),
|
||||||
|
patch("app.backend_pre_start.select", return_value=select1),
|
||||||
patch.object(logger, "info"),
|
patch.object(logger, "info"),
|
||||||
patch.object(logger, "error"),
|
patch.object(logger, "error"),
|
||||||
patch.object(logger, "warn"),
|
patch.object(logger, "warn"),
|
||||||
@@ -24,10 +26,8 @@ def test_init_successful_connection() -> None:
|
|||||||
except Exception:
|
except Exception:
|
||||||
connection_successful = False
|
connection_successful = False
|
||||||
|
|
||||||
assert (
|
assert connection_successful, (
|
||||||
connection_successful
|
"The database connection should be successful and not raise an exception."
|
||||||
), "The database connection should be successful and not raise an exception."
|
)
|
||||||
|
|
||||||
assert session_mock.exec.called_once_with(
|
session_mock.exec.assert_called_once_with(select1)
|
||||||
select(1)
|
|
||||||
), "The session should execute a select statement once."
|
|
||||||
+9
-9
@@ -9,11 +9,13 @@ def test_init_successful_connection() -> None:
|
|||||||
engine_mock = MagicMock()
|
engine_mock = MagicMock()
|
||||||
|
|
||||||
session_mock = MagicMock()
|
session_mock = MagicMock()
|
||||||
exec_mock = MagicMock(return_value=True)
|
session_mock.__enter__.return_value = session_mock
|
||||||
session_mock.configure_mock(**{"exec.return_value": exec_mock})
|
|
||||||
|
select1 = select(1)
|
||||||
|
|
||||||
with (
|
with (
|
||||||
patch("sqlmodel.Session", return_value=session_mock),
|
patch("app.tests_pre_start.Session", return_value=session_mock),
|
||||||
|
patch("app.tests_pre_start.select", return_value=select1),
|
||||||
patch.object(logger, "info"),
|
patch.object(logger, "info"),
|
||||||
patch.object(logger, "error"),
|
patch.object(logger, "error"),
|
||||||
patch.object(logger, "warn"),
|
patch.object(logger, "warn"),
|
||||||
@@ -24,10 +26,8 @@ def test_init_successful_connection() -> None:
|
|||||||
except Exception:
|
except Exception:
|
||||||
connection_successful = False
|
connection_successful = False
|
||||||
|
|
||||||
assert (
|
assert connection_successful, (
|
||||||
connection_successful
|
"The database connection should be successful and not raise an exception."
|
||||||
), "The database connection should be successful and not raise an exception."
|
)
|
||||||
|
|
||||||
assert session_mock.exec.called_once_with(
|
session_mock.exec.assert_called_once_with(select1)
|
||||||
select(1)
|
|
||||||
), "The session should execute a select statement once."
|
|
||||||
@@ -2,8 +2,8 @@ from sqlmodel import Session
|
|||||||
|
|
||||||
from app import crud
|
from app import crud
|
||||||
from app.models import Item, ItemCreate
|
from app.models import Item, ItemCreate
|
||||||
from app.tests.utils.user import create_random_user
|
from tests.utils.user import create_random_user
|
||||||
from app.tests.utils.utils import random_lower_string
|
from tests.utils.utils import random_lower_string
|
||||||
|
|
||||||
|
|
||||||
def create_random_item(db: Session) -> Item:
|
def create_random_item(db: Session) -> Item:
|
||||||
@@ -4,7 +4,7 @@ from sqlmodel import Session
|
|||||||
from app import crud
|
from app import crud
|
||||||
from app.core.config import settings
|
from app.core.config import settings
|
||||||
from app.models import User, UserCreate, UserUpdate
|
from app.models import User, UserCreate, UserUpdate
|
||||||
from app.tests.utils.utils import random_email, random_lower_string
|
from tests.utils.utils import random_email, random_lower_string
|
||||||
|
|
||||||
|
|
||||||
def user_authentication_headers(
|
def user_authentication_headers(
|
||||||
@@ -0,0 +1,921 @@
|
|||||||
|
{
|
||||||
|
"lockfileVersion": 1,
|
||||||
|
"configVersion": 0,
|
||||||
|
"workspaces": {
|
||||||
|
"": {
|
||||||
|
"name": "fastapi-cloud",
|
||||||
|
},
|
||||||
|
"frontend": {
|
||||||
|
"name": "frontend",
|
||||||
|
"version": "0.0.0",
|
||||||
|
"dependencies": {
|
||||||
|
"@hookform/resolvers": "^5.2.2",
|
||||||
|
"@radix-ui/react-avatar": "^1.1.11",
|
||||||
|
"@radix-ui/react-checkbox": "^1.3.3",
|
||||||
|
"@radix-ui/react-dialog": "^1.1.15",
|
||||||
|
"@radix-ui/react-dropdown-menu": "^2.1.16",
|
||||||
|
"@radix-ui/react-label": "^2.1.8",
|
||||||
|
"@radix-ui/react-radio-group": "^1.3.8",
|
||||||
|
"@radix-ui/react-scroll-area": "^1.2.10",
|
||||||
|
"@radix-ui/react-select": "^2.2.6",
|
||||||
|
"@radix-ui/react-separator": "^1.1.8",
|
||||||
|
"@radix-ui/react-slot": "^1.2.4",
|
||||||
|
"@radix-ui/react-tabs": "^1.1.13",
|
||||||
|
"@radix-ui/react-tooltip": "^1.2.8",
|
||||||
|
"@tailwindcss/vite": "^4.1.18",
|
||||||
|
"@tanstack/react-query": "^5.90.12",
|
||||||
|
"@tanstack/react-query-devtools": "^5.91.1",
|
||||||
|
"@tanstack/react-router": "^1.142.11",
|
||||||
|
"@tanstack/react-router-devtools": "^1.142.8",
|
||||||
|
"@tanstack/react-table": "^8.21.3",
|
||||||
|
"axios": "1.13.2",
|
||||||
|
"class-variance-authority": "^0.7.1",
|
||||||
|
"clsx": "^2.1.1",
|
||||||
|
"form-data": "4.0.5",
|
||||||
|
"lucide-react": "^0.562.0",
|
||||||
|
"next-themes": "^0.4.6",
|
||||||
|
"react": "^19.1.1",
|
||||||
|
"react-dom": "^19.2.3",
|
||||||
|
"react-error-boundary": "^6.0.0",
|
||||||
|
"react-hook-form": "^7.68.0",
|
||||||
|
"react-icons": "^5.5.0",
|
||||||
|
"sonner": "^2.0.7",
|
||||||
|
"tailwind-merge": "^3.4.0",
|
||||||
|
"tailwindcss": "^4.1.17",
|
||||||
|
"zod": "^4.2.1",
|
||||||
|
},
|
||||||
|
"devDependencies": {
|
||||||
|
"@biomejs/biome": "^2.3.10",
|
||||||
|
"@hey-api/openapi-ts": "0.73.0",
|
||||||
|
"@playwright/test": "1.57.0",
|
||||||
|
"@tanstack/router-devtools": "^1.142.11",
|
||||||
|
"@tanstack/router-plugin": "^1.140.0",
|
||||||
|
"@types/node": "^25.0.2",
|
||||||
|
"@types/react": "^19.2.7",
|
||||||
|
"@types/react-dom": "^19.2.3",
|
||||||
|
"@vitejs/plugin-react-swc": "^4.2.2",
|
||||||
|
"dotenv": "^17.2.3",
|
||||||
|
"tw-animate-css": "^1.4.0",
|
||||||
|
"typescript": "^5.9.3",
|
||||||
|
"vite": "^7.3.0",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
"packages": {
|
||||||
|
"@babel/code-frame": ["@babel/code-frame@7.28.6", "", { "dependencies": { "@babel/helper-validator-identifier": "^7.28.5", "js-tokens": "^4.0.0", "picocolors": "^1.1.1" } }, "sha512-JYgintcMjRiCvS8mMECzaEn+m3PfoQiyqukOMCCVQtoJGYJw8j/8LBJEiqkHLkfwCcs74E3pbAUFNg7d9VNJ+Q=="],
|
||||||
|
|
||||||
|
"@babel/compat-data": ["@babel/compat-data@7.28.6", "", {}, "sha512-2lfu57JtzctfIrcGMz992hyLlByuzgIk58+hhGCxjKZ3rWI82NnVLjXcaTqkI2NvlcvOskZaiZ5kjUALo3Lpxg=="],
|
||||||
|
|
||||||
|
"@babel/core": ["@babel/core@7.28.6", "", { "dependencies": { "@babel/code-frame": "^7.28.6", "@babel/generator": "^7.28.6", "@babel/helper-compilation-targets": "^7.28.6", "@babel/helper-module-transforms": "^7.28.6", "@babel/helpers": "^7.28.6", "@babel/parser": "^7.28.6", "@babel/template": "^7.28.6", "@babel/traverse": "^7.28.6", "@babel/types": "^7.28.6", "@jridgewell/remapping": "^2.3.5", "convert-source-map": "^2.0.0", "debug": "^4.1.0", "gensync": "^1.0.0-beta.2", "json5": "^2.2.3", "semver": "^6.3.1" } }, "sha512-H3mcG6ZDLTlYfaSNi0iOKkigqMFvkTKlGUYlD8GW7nNOYRrevuA46iTypPyv+06V3fEmvvazfntkBU34L0azAw=="],
|
||||||
|
|
||||||
|
"@babel/generator": ["@babel/generator@7.28.6", "", { "dependencies": { "@babel/parser": "^7.28.6", "@babel/types": "^7.28.6", "@jridgewell/gen-mapping": "^0.3.12", "@jridgewell/trace-mapping": "^0.3.28", "jsesc": "^3.0.2" } }, "sha512-lOoVRwADj8hjf7al89tvQ2a1lf53Z+7tiXMgpZJL3maQPDxh0DgLMN62B2MKUOFcoodBHLMbDM6WAbKgNy5Suw=="],
|
||||||
|
|
||||||
|
"@babel/helper-compilation-targets": ["@babel/helper-compilation-targets@7.28.6", "", { "dependencies": { "@babel/compat-data": "^7.28.6", "@babel/helper-validator-option": "^7.27.1", "browserslist": "^4.24.0", "lru-cache": "^5.1.1", "semver": "^6.3.1" } }, "sha512-JYtls3hqi15fcx5GaSNL7SCTJ2MNmjrkHXg4FSpOA/grxK8KwyZ5bubHsCq8FXCkua6xhuaaBit+3b7+VZRfcA=="],
|
||||||
|
|
||||||
|
"@babel/helper-globals": ["@babel/helper-globals@7.28.0", "", {}, "sha512-+W6cISkXFa1jXsDEdYA8HeevQT/FULhxzR99pxphltZcVaugps53THCeiWA8SguxxpSp3gKPiuYfSWopkLQ4hw=="],
|
||||||
|
|
||||||
|
"@babel/helper-module-imports": ["@babel/helper-module-imports@7.28.6", "", { "dependencies": { "@babel/traverse": "^7.28.6", "@babel/types": "^7.28.6" } }, "sha512-l5XkZK7r7wa9LucGw9LwZyyCUscb4x37JWTPz7swwFE/0FMQAGpiWUZn8u9DzkSBWEcK25jmvubfpw2dnAMdbw=="],
|
||||||
|
|
||||||
|
"@babel/helper-module-transforms": ["@babel/helper-module-transforms@7.28.6", "", { "dependencies": { "@babel/helper-module-imports": "^7.28.6", "@babel/helper-validator-identifier": "^7.28.5", "@babel/traverse": "^7.28.6" }, "peerDependencies": { "@babel/core": "^7.0.0" } }, "sha512-67oXFAYr2cDLDVGLXTEABjdBJZ6drElUSI7WKp70NrpyISso3plG9SAGEF6y7zbha/wOzUByWWTJvEDVNIUGcA=="],
|
||||||
|
|
||||||
|
"@babel/helper-plugin-utils": ["@babel/helper-plugin-utils@7.28.6", "", {}, "sha512-S9gzZ/bz83GRysI7gAD4wPT/AI3uCnY+9xn+Mx/KPs2JwHJIz1W8PZkg2cqyt3RNOBM8ejcXhV6y8Og7ly/Dug=="],
|
||||||
|
|
||||||
|
"@babel/helper-string-parser": ["@babel/helper-string-parser@7.27.1", "", {}, "sha512-qMlSxKbpRlAridDExk92nSobyDdpPijUq2DW6oDnUqd0iOGxmQjyqhMIihI9+zv4LPyZdRje2cavWPbCbWm3eA=="],
|
||||||
|
|
||||||
|
"@babel/helper-validator-identifier": ["@babel/helper-validator-identifier@7.28.5", "", {}, "sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q=="],
|
||||||
|
|
||||||
|
"@babel/helper-validator-option": ["@babel/helper-validator-option@7.27.1", "", {}, "sha512-YvjJow9FxbhFFKDSuFnVCe2WxXk1zWc22fFePVNEaWJEu8IrZVlda6N0uHwzZrUM1il7NC9Mlp4MaJYbYd9JSg=="],
|
||||||
|
|
||||||
|
"@babel/helpers": ["@babel/helpers@7.28.6", "", { "dependencies": { "@babel/template": "^7.28.6", "@babel/types": "^7.28.6" } }, "sha512-xOBvwq86HHdB7WUDTfKfT/Vuxh7gElQ+Sfti2Cy6yIWNW05P8iUslOVcZ4/sKbE+/jQaukQAdz/gf3724kYdqw=="],
|
||||||
|
|
||||||
|
"@babel/parser": ["@babel/parser@7.28.6", "", { "dependencies": { "@babel/types": "^7.28.6" }, "bin": { "parser": "bin/babel-parser.js" } }, "sha512-TeR9zWR18BvbfPmGbLampPMW+uW1NZnJlRuuHso8i87QZNq2JRF9i6RgxRqtEq+wQGsS19NNTWr2duhnE49mfQ=="],
|
||||||
|
|
||||||
|
"@babel/plugin-syntax-jsx": ["@babel/plugin-syntax-jsx@7.28.6", "", { "dependencies": { "@babel/helper-plugin-utils": "^7.28.6" }, "peerDependencies": { "@babel/core": "^7.0.0-0" } }, "sha512-wgEmr06G6sIpqr8YDwA2dSRTE3bJ+V0IfpzfSY3Lfgd7YWOaAdlykvJi13ZKBt8cZHfgH1IXN+CL656W3uUa4w=="],
|
||||||
|
|
||||||
|
"@babel/plugin-syntax-typescript": ["@babel/plugin-syntax-typescript@7.28.6", "", { "dependencies": { "@babel/helper-plugin-utils": "^7.28.6" }, "peerDependencies": { "@babel/core": "^7.0.0-0" } }, "sha512-+nDNmQye7nlnuuHDboPbGm00Vqg3oO8niRRL27/4LYHUsHYh0zJ1xWOz0uRwNFmM1Avzk8wZbc6rdiYhomzv/A=="],
|
||||||
|
|
||||||
|
"@babel/template": ["@babel/template@7.28.6", "", { "dependencies": { "@babel/code-frame": "^7.28.6", "@babel/parser": "^7.28.6", "@babel/types": "^7.28.6" } }, "sha512-YA6Ma2KsCdGb+WC6UpBVFJGXL58MDA6oyONbjyF/+5sBgxY/dwkhLogbMT2GXXyU84/IhRw/2D1Os1B/giz+BQ=="],
|
||||||
|
|
||||||
|
"@babel/traverse": ["@babel/traverse@7.28.6", "", { "dependencies": { "@babel/code-frame": "^7.28.6", "@babel/generator": "^7.28.6", "@babel/helper-globals": "^7.28.0", "@babel/parser": "^7.28.6", "@babel/template": "^7.28.6", "@babel/types": "^7.28.6", "debug": "^4.3.1" } }, "sha512-fgWX62k02qtjqdSNTAGxmKYY/7FSL9WAS1o2Hu5+I5m9T0yxZzr4cnrfXQ/MX0rIifthCSs6FKTlzYbJcPtMNg=="],
|
||||||
|
|
||||||
|
"@babel/types": ["@babel/types@7.28.6", "", { "dependencies": { "@babel/helper-string-parser": "^7.27.1", "@babel/helper-validator-identifier": "^7.28.5" } }, "sha512-0ZrskXVEHSWIqZM/sQZ4EV3jZJXRkio/WCxaqKZP1g//CEWEPSfeZFcms4XeKBCHU0ZKnIkdJeU/kF+eRp5lBg=="],
|
||||||
|
|
||||||
|
"@biomejs/biome": ["@biomejs/biome@2.3.11", "", { "optionalDependencies": { "@biomejs/cli-darwin-arm64": "2.3.11", "@biomejs/cli-darwin-x64": "2.3.11", "@biomejs/cli-linux-arm64": "2.3.11", "@biomejs/cli-linux-arm64-musl": "2.3.11", "@biomejs/cli-linux-x64": "2.3.11", "@biomejs/cli-linux-x64-musl": "2.3.11", "@biomejs/cli-win32-arm64": "2.3.11", "@biomejs/cli-win32-x64": "2.3.11" }, "bin": { "biome": "bin/biome" } }, "sha512-/zt+6qazBWguPG6+eWmiELqO+9jRsMZ/DBU3lfuU2ngtIQYzymocHhKiZRyrbra4aCOoyTg/BmY+6WH5mv9xmQ=="],
|
||||||
|
|
||||||
|
"@biomejs/cli-darwin-arm64": ["@biomejs/cli-darwin-arm64@2.3.11", "", { "os": "darwin", "cpu": "arm64" }, "sha512-/uXXkBcPKVQY7rc9Ys2CrlirBJYbpESEDme7RKiBD6MmqR2w3j0+ZZXRIL2xiaNPsIMMNhP1YnA+jRRxoOAFrA=="],
|
||||||
|
|
||||||
|
"@biomejs/cli-darwin-x64": ["@biomejs/cli-darwin-x64@2.3.11", "", { "os": "darwin", "cpu": "x64" }, "sha512-fh7nnvbweDPm2xEmFjfmq7zSUiox88plgdHF9OIW4i99WnXrAC3o2P3ag9judoUMv8FCSUnlwJCM1B64nO5Fbg=="],
|
||||||
|
|
||||||
|
"@biomejs/cli-linux-arm64": ["@biomejs/cli-linux-arm64@2.3.11", "", { "os": "linux", "cpu": "arm64" }, "sha512-l4xkGa9E7Uc0/05qU2lMYfN1H+fzzkHgaJoy98wO+b/7Gl78srbCRRgwYSW+BTLixTBrM6Ede5NSBwt7rd/i6g=="],
|
||||||
|
|
||||||
|
"@biomejs/cli-linux-arm64-musl": ["@biomejs/cli-linux-arm64-musl@2.3.11", "", { "os": "linux", "cpu": "arm64" }, "sha512-XPSQ+XIPZMLaZ6zveQdwNjbX+QdROEd1zPgMwD47zvHV+tCGB88VH+aynyGxAHdzL+Tm/+DtKST5SECs4iwCLg=="],
|
||||||
|
|
||||||
|
"@biomejs/cli-linux-x64": ["@biomejs/cli-linux-x64@2.3.11", "", { "os": "linux", "cpu": "x64" }, "sha512-/1s9V/H3cSe0r0Mv/Z8JryF5x9ywRxywomqZVLHAoa/uN0eY7F8gEngWKNS5vbbN/BsfpCG5yeBT5ENh50Frxg=="],
|
||||||
|
|
||||||
|
"@biomejs/cli-linux-x64-musl": ["@biomejs/cli-linux-x64-musl@2.3.11", "", { "os": "linux", "cpu": "x64" }, "sha512-vU7a8wLs5C9yJ4CB8a44r12aXYb8yYgBn+WeyzbMjaCMklzCv1oXr8x+VEyWodgJt9bDmhiaW/I0RHbn7rsNmw=="],
|
||||||
|
|
||||||
|
"@biomejs/cli-win32-arm64": ["@biomejs/cli-win32-arm64@2.3.11", "", { "os": "win32", "cpu": "arm64" }, "sha512-PZQ6ElCOnkYapSsysiTy0+fYX+agXPlWugh6+eQ6uPKI3vKAqNp6TnMhoM3oY2NltSB89hz59o8xIfOdyhi9Iw=="],
|
||||||
|
|
||||||
|
"@biomejs/cli-win32-x64": ["@biomejs/cli-win32-x64@2.3.11", "", { "os": "win32", "cpu": "x64" }, "sha512-43VrG813EW+b5+YbDbz31uUsheX+qFKCpXeY9kfdAx+ww3naKxeVkTD9zLIWxUPfJquANMHrmW3wbe/037G0Qg=="],
|
||||||
|
|
||||||
|
"@esbuild/aix-ppc64": ["@esbuild/aix-ppc64@0.27.2", "", { "os": "aix", "cpu": "ppc64" }, "sha512-GZMB+a0mOMZs4MpDbj8RJp4cw+w1WV5NYD6xzgvzUJ5Ek2jerwfO2eADyI6ExDSUED+1X8aMbegahsJi+8mgpw=="],
|
||||||
|
|
||||||
|
"@esbuild/android-arm": ["@esbuild/android-arm@0.27.2", "", { "os": "android", "cpu": "arm" }, "sha512-DVNI8jlPa7Ujbr1yjU2PfUSRtAUZPG9I1RwW4F4xFB1Imiu2on0ADiI/c3td+KmDtVKNbi+nffGDQMfcIMkwIA=="],
|
||||||
|
|
||||||
|
"@esbuild/android-arm64": ["@esbuild/android-arm64@0.27.2", "", { "os": "android", "cpu": "arm64" }, "sha512-pvz8ZZ7ot/RBphf8fv60ljmaoydPU12VuXHImtAs0XhLLw+EXBi2BLe3OYSBslR4rryHvweW5gmkKFwTiFy6KA=="],
|
||||||
|
|
||||||
|
"@esbuild/android-x64": ["@esbuild/android-x64@0.27.2", "", { "os": "android", "cpu": "x64" }, "sha512-z8Ank4Byh4TJJOh4wpz8g2vDy75zFL0TlZlkUkEwYXuPSgX8yzep596n6mT7905kA9uHZsf/o2OJZubl2l3M7A=="],
|
||||||
|
|
||||||
|
"@esbuild/darwin-arm64": ["@esbuild/darwin-arm64@0.27.2", "", { "os": "darwin", "cpu": "arm64" }, "sha512-davCD2Zc80nzDVRwXTcQP/28fiJbcOwvdolL0sOiOsbwBa72kegmVU0Wrh1MYrbuCL98Omp5dVhQFWRKR2ZAlg=="],
|
||||||
|
|
||||||
|
"@esbuild/darwin-x64": ["@esbuild/darwin-x64@0.27.2", "", { "os": "darwin", "cpu": "x64" }, "sha512-ZxtijOmlQCBWGwbVmwOF/UCzuGIbUkqB1faQRf5akQmxRJ1ujusWsb3CVfk/9iZKr2L5SMU5wPBi1UWbvL+VQA=="],
|
||||||
|
|
||||||
|
"@esbuild/freebsd-arm64": ["@esbuild/freebsd-arm64@0.27.2", "", { "os": "freebsd", "cpu": "arm64" }, "sha512-lS/9CN+rgqQ9czogxlMcBMGd+l8Q3Nj1MFQwBZJyoEKI50XGxwuzznYdwcav6lpOGv5BqaZXqvBSiB/kJ5op+g=="],
|
||||||
|
|
||||||
|
"@esbuild/freebsd-x64": ["@esbuild/freebsd-x64@0.27.2", "", { "os": "freebsd", "cpu": "x64" }, "sha512-tAfqtNYb4YgPnJlEFu4c212HYjQWSO/w/h/lQaBK7RbwGIkBOuNKQI9tqWzx7Wtp7bTPaGC6MJvWI608P3wXYA=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-arm": ["@esbuild/linux-arm@0.27.2", "", { "os": "linux", "cpu": "arm" }, "sha512-vWfq4GaIMP9AIe4yj1ZUW18RDhx6EPQKjwe7n8BbIecFtCQG4CfHGaHuh7fdfq+y3LIA2vGS/o9ZBGVxIDi9hw=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-arm64": ["@esbuild/linux-arm64@0.27.2", "", { "os": "linux", "cpu": "arm64" }, "sha512-hYxN8pr66NsCCiRFkHUAsxylNOcAQaxSSkHMMjcpx0si13t1LHFphxJZUiGwojB1a/Hd5OiPIqDdXONia6bhTw=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-ia32": ["@esbuild/linux-ia32@0.27.2", "", { "os": "linux", "cpu": "ia32" }, "sha512-MJt5BRRSScPDwG2hLelYhAAKh9imjHK5+NE/tvnRLbIqUWa+0E9N4WNMjmp/kXXPHZGqPLxggwVhz7QP8CTR8w=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-loong64": ["@esbuild/linux-loong64@0.27.2", "", { "os": "linux", "cpu": "none" }, "sha512-lugyF1atnAT463aO6KPshVCJK5NgRnU4yb3FUumyVz+cGvZbontBgzeGFO1nF+dPueHD367a2ZXe1NtUkAjOtg=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-mips64el": ["@esbuild/linux-mips64el@0.27.2", "", { "os": "linux", "cpu": "none" }, "sha512-nlP2I6ArEBewvJ2gjrrkESEZkB5mIoaTswuqNFRv/WYd+ATtUpe9Y09RnJvgvdag7he0OWgEZWhviS1OTOKixw=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-ppc64": ["@esbuild/linux-ppc64@0.27.2", "", { "os": "linux", "cpu": "ppc64" }, "sha512-C92gnpey7tUQONqg1n6dKVbx3vphKtTHJaNG2Ok9lGwbZil6DrfyecMsp9CrmXGQJmZ7iiVXvvZH6Ml5hL6XdQ=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-riscv64": ["@esbuild/linux-riscv64@0.27.2", "", { "os": "linux", "cpu": "none" }, "sha512-B5BOmojNtUyN8AXlK0QJyvjEZkWwy/FKvakkTDCziX95AowLZKR6aCDhG7LeF7uMCXEJqwa8Bejz5LTPYm8AvA=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-s390x": ["@esbuild/linux-s390x@0.27.2", "", { "os": "linux", "cpu": "s390x" }, "sha512-p4bm9+wsPwup5Z8f4EpfN63qNagQ47Ua2znaqGH6bqLlmJ4bx97Y9JdqxgGZ6Y8xVTixUnEkoKSHcpRlDnNr5w=="],
|
||||||
|
|
||||||
|
"@esbuild/linux-x64": ["@esbuild/linux-x64@0.27.2", "", { "os": "linux", "cpu": "x64" }, "sha512-uwp2Tip5aPmH+NRUwTcfLb+W32WXjpFejTIOWZFw/v7/KnpCDKG66u4DLcurQpiYTiYwQ9B7KOeMJvLCu/OvbA=="],
|
||||||
|
|
||||||
|
"@esbuild/netbsd-arm64": ["@esbuild/netbsd-arm64@0.27.2", "", { "os": "none", "cpu": "arm64" }, "sha512-Kj6DiBlwXrPsCRDeRvGAUb/LNrBASrfqAIok+xB0LxK8CHqxZ037viF13ugfsIpePH93mX7xfJp97cyDuTZ3cw=="],
|
||||||
|
|
||||||
|
"@esbuild/netbsd-x64": ["@esbuild/netbsd-x64@0.27.2", "", { "os": "none", "cpu": "x64" }, "sha512-HwGDZ0VLVBY3Y+Nw0JexZy9o/nUAWq9MlV7cahpaXKW6TOzfVno3y3/M8Ga8u8Yr7GldLOov27xiCnqRZf0tCA=="],
|
||||||
|
|
||||||
|
"@esbuild/openbsd-arm64": ["@esbuild/openbsd-arm64@0.27.2", "", { "os": "openbsd", "cpu": "arm64" }, "sha512-DNIHH2BPQ5551A7oSHD0CKbwIA/Ox7+78/AWkbS5QoRzaqlev2uFayfSxq68EkonB+IKjiuxBFoV8ESJy8bOHA=="],
|
||||||
|
|
||||||
|
"@esbuild/openbsd-x64": ["@esbuild/openbsd-x64@0.27.2", "", { "os": "openbsd", "cpu": "x64" }, "sha512-/it7w9Nb7+0KFIzjalNJVR5bOzA9Vay+yIPLVHfIQYG/j+j9VTH84aNB8ExGKPU4AzfaEvN9/V4HV+F+vo8OEg=="],
|
||||||
|
|
||||||
|
"@esbuild/openharmony-arm64": ["@esbuild/openharmony-arm64@0.27.2", "", { "os": "none", "cpu": "arm64" }, "sha512-LRBbCmiU51IXfeXk59csuX/aSaToeG7w48nMwA6049Y4J4+VbWALAuXcs+qcD04rHDuSCSRKdmY63sruDS5qag=="],
|
||||||
|
|
||||||
|
"@esbuild/sunos-x64": ["@esbuild/sunos-x64@0.27.2", "", { "os": "sunos", "cpu": "x64" }, "sha512-kMtx1yqJHTmqaqHPAzKCAkDaKsffmXkPHThSfRwZGyuqyIeBvf08KSsYXl+abf5HDAPMJIPnbBfXvP2ZC2TfHg=="],
|
||||||
|
|
||||||
|
"@esbuild/win32-arm64": ["@esbuild/win32-arm64@0.27.2", "", { "os": "win32", "cpu": "arm64" }, "sha512-Yaf78O/B3Kkh+nKABUF++bvJv5Ijoy9AN1ww904rOXZFLWVc5OLOfL56W+C8F9xn5JQZa3UX6m+IktJnIb1Jjg=="],
|
||||||
|
|
||||||
|
"@esbuild/win32-ia32": ["@esbuild/win32-ia32@0.27.2", "", { "os": "win32", "cpu": "ia32" }, "sha512-Iuws0kxo4yusk7sw70Xa2E2imZU5HoixzxfGCdxwBdhiDgt9vX9VUCBhqcwY7/uh//78A1hMkkROMJq9l27oLQ=="],
|
||||||
|
|
||||||
|
"@esbuild/win32-x64": ["@esbuild/win32-x64@0.27.2", "", { "os": "win32", "cpu": "x64" }, "sha512-sRdU18mcKf7F+YgheI/zGf5alZatMUTKj/jNS6l744f9u3WFu4v7twcUI9vu4mknF4Y9aDlblIie0IM+5xxaqQ=="],
|
||||||
|
|
||||||
|
"@floating-ui/core": ["@floating-ui/core@1.7.3", "", { "dependencies": { "@floating-ui/utils": "^0.2.10" } }, "sha512-sGnvb5dmrJaKEZ+LDIpguvdX3bDlEllmv4/ClQ9awcmCZrlx5jQyyMWFM5kBI+EyNOCDDiKk8il0zeuX3Zlg/w=="],
|
||||||
|
|
||||||
|
"@floating-ui/dom": ["@floating-ui/dom@1.7.4", "", { "dependencies": { "@floating-ui/core": "^1.7.3", "@floating-ui/utils": "^0.2.10" } }, "sha512-OOchDgh4F2CchOX94cRVqhvy7b3AFb+/rQXyswmzmGakRfkMgoWVjfnLWkRirfLEfuD4ysVW16eXzwt3jHIzKA=="],
|
||||||
|
|
||||||
|
"@floating-ui/react-dom": ["@floating-ui/react-dom@2.1.6", "", { "dependencies": { "@floating-ui/dom": "^1.7.4" }, "peerDependencies": { "react": ">=16.8.0", "react-dom": ">=16.8.0" } }, "sha512-4JX6rEatQEvlmgU80wZyq9RT96HZJa88q8hp0pBd+LrczeDI4o6uA2M+uvxngVHo4Ihr8uibXxH6+70zhAFrVw=="],
|
||||||
|
|
||||||
|
"@floating-ui/utils": ["@floating-ui/utils@0.2.10", "", {}, "sha512-aGTxbpbg8/b5JfU1HXSrbH3wXZuLPJcNEcZQFMxLs3oSzgtVu6nFPkbbGGUvBcUjKV2YyB9Wxxabo+HEH9tcRQ=="],
|
||||||
|
|
||||||
|
"@hey-api/json-schema-ref-parser": ["@hey-api/json-schema-ref-parser@1.0.6", "", { "dependencies": { "@jsdevtools/ono": "^7.1.3", "@types/json-schema": "^7.0.15", "js-yaml": "^4.1.0", "lodash": "^4.17.21" } }, "sha512-yktiFZoWPtEW8QKS65eqKwA5MTKp88CyiL8q72WynrBs/73SAaxlSWlA2zW/DZlywZ5hX1OYzrCC0wFdvO9c2w=="],
|
||||||
|
|
||||||
|
"@hey-api/openapi-ts": ["@hey-api/openapi-ts@0.73.0", "", { "dependencies": { "@hey-api/json-schema-ref-parser": "1.0.6", "ansi-colors": "4.1.3", "c12": "2.0.1", "color-support": "1.1.3", "commander": "13.0.0", "handlebars": "4.7.8", "open": "10.1.2" }, "peerDependencies": { "typescript": "^5.5.3" }, "bin": { "openapi-ts": "bin/index.cjs" } }, "sha512-sUscR3OIGW0k9U//28Cu6BTp3XaogWMDORj9H+5Du9E5AvTT7LZbCEDvkLhebFOPkp2cZAQfd66HiZsiwssBcQ=="],
|
||||||
|
|
||||||
|
"@hookform/resolvers": ["@hookform/resolvers@5.2.2", "", { "dependencies": { "@standard-schema/utils": "^0.3.0" }, "peerDependencies": { "react-hook-form": "^7.55.0" } }, "sha512-A/IxlMLShx3KjV/HeTcTfaMxdwy690+L/ZADoeaTltLx+CVuzkeVIPuybK3jrRfw7YZnmdKsVVHAlEPIAEUNlA=="],
|
||||||
|
|
||||||
|
"@jridgewell/gen-mapping": ["@jridgewell/gen-mapping@0.3.13", "", { "dependencies": { "@jridgewell/sourcemap-codec": "^1.5.0", "@jridgewell/trace-mapping": "^0.3.24" } }, "sha512-2kkt/7niJ6MgEPxF0bYdQ6etZaA+fQvDcLKckhy1yIQOzaoKjBBjSj63/aLVjYE3qhRt5dvM+uUyfCg6UKCBbA=="],
|
||||||
|
|
||||||
|
"@jridgewell/remapping": ["@jridgewell/remapping@2.3.5", "", { "dependencies": { "@jridgewell/gen-mapping": "^0.3.5", "@jridgewell/trace-mapping": "^0.3.24" } }, "sha512-LI9u/+laYG4Ds1TDKSJW2YPrIlcVYOwi2fUC6xB43lueCjgxV4lffOCZCtYFiH6TNOX+tQKXx97T4IKHbhyHEQ=="],
|
||||||
|
|
||||||
|
"@jridgewell/resolve-uri": ["@jridgewell/resolve-uri@3.1.2", "", {}, "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw=="],
|
||||||
|
|
||||||
|
"@jridgewell/sourcemap-codec": ["@jridgewell/sourcemap-codec@1.5.5", "", {}, "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og=="],
|
||||||
|
|
||||||
|
"@jridgewell/trace-mapping": ["@jridgewell/trace-mapping@0.3.31", "", { "dependencies": { "@jridgewell/resolve-uri": "^3.1.0", "@jridgewell/sourcemap-codec": "^1.4.14" } }, "sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw=="],
|
||||||
|
|
||||||
|
"@jsdevtools/ono": ["@jsdevtools/ono@7.1.3", "", {}, "sha512-4JQNk+3mVzK3xh2rqd6RB4J46qUR19azEHBneZyTZM+c456qOrbbM/5xcR8huNCCcbVt7+UmizG6GuUvPvKUYg=="],
|
||||||
|
|
||||||
|
"@playwright/test": ["@playwright/test@1.57.0", "", { "dependencies": { "playwright": "1.57.0" }, "bin": { "playwright": "cli.js" } }, "sha512-6TyEnHgd6SArQO8UO2OMTxshln3QMWBtPGrOCgs3wVEmQmwyuNtB10IZMfmYDE0riwNR1cu4q+pPcxMVtaG3TA=="],
|
||||||
|
|
||||||
|
"@radix-ui/number": ["@radix-ui/number@1.1.1", "", {}, "sha512-MkKCwxlXTgz6CFoJx3pCwn07GKp36+aZyu/u2Ln2VrA5DcdyCZkASEDBTd8x5whTQQL5CiYf4prXKLcgQdv29g=="],
|
||||||
|
|
||||||
|
"@radix-ui/primitive": ["@radix-ui/primitive@1.1.3", "", {}, "sha512-JTF99U/6XIjCBo0wqkU5sK10glYe27MRRsfwoiq5zzOEZLHU3A3KCMa5X/azekYRCJ0HlwI0crAXS/5dEHTzDg=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-arrow": ["@radix-ui/react-arrow@1.1.7", "", { "dependencies": { "@radix-ui/react-primitive": "2.1.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-F+M1tLhO+mlQaOWspE8Wstg+z6PwxwRd8oQ8IXceWz92kfAmalTRf0EjrouQeo7QssEPfCn05B4Ihs1K9WQ/7w=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-avatar": ["@radix-ui/react-avatar@1.1.11", "", { "dependencies": { "@radix-ui/react-context": "1.1.3", "@radix-ui/react-primitive": "2.1.4", "@radix-ui/react-use-callback-ref": "1.1.1", "@radix-ui/react-use-is-hydrated": "0.1.0", "@radix-ui/react-use-layout-effect": "1.1.1" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-0Qk603AHGV28BOBO34p7IgD5m+V5Sg/YovfayABkoDDBM5d3NCx0Mp4gGrjzLGes1jV5eNOE1r3itqOR33VC6Q=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-checkbox": ["@radix-ui/react-checkbox@1.3.3", "", { "dependencies": { "@radix-ui/primitive": "1.1.3", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-presence": "1.1.5", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-use-controllable-state": "1.2.2", "@radix-ui/react-use-previous": "1.1.1", "@radix-ui/react-use-size": "1.1.1" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-wBbpv+NQftHDdG86Qc0pIyXk5IR3tM8Vd0nWLKDcX8nNn4nXFOFwsKuqw2okA/1D/mpaAkmuyndrPJTYDNZtFw=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-collection": ["@radix-ui/react-collection@1.1.7", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-Fh9rGN0MoI4ZFUNyfFVNU4y9LUz93u9/0K+yLgA2bwRojxM8JU1DyvvMBabnZPBgMWREAJvU2jjVzq+LrFUglw=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-compose-refs": ["@radix-ui/react-compose-refs@1.1.2", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-z4eqJvfiNnFMHIIvXP3CY57y2WJs5g2v3X0zm9mEJkrkNv4rDxu+sg9Jh8EkXyeqBkB7SOcboo9dMVqhyrACIg=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-context": ["@radix-ui/react-context@1.1.3", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-ieIFACdMpYfMEjF0rEf5KLvfVyIkOz6PDGyNnP+u+4xQ6jny3VCgA4OgXOwNx2aUkxn8zx9fiVcM8CfFYv9Lxw=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-dialog": ["@radix-ui/react-dialog@1.1.15", "", { "dependencies": { "@radix-ui/primitive": "1.1.3", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-dismissable-layer": "1.1.11", "@radix-ui/react-focus-guards": "1.1.3", "@radix-ui/react-focus-scope": "1.1.7", "@radix-ui/react-id": "1.1.1", "@radix-ui/react-portal": "1.1.9", "@radix-ui/react-presence": "1.1.5", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-slot": "1.2.3", "@radix-ui/react-use-controllable-state": "1.2.2", "aria-hidden": "^1.2.4", "react-remove-scroll": "^2.6.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-TCglVRtzlffRNxRMEyR36DGBLJpeusFcgMVD9PZEzAKnUs1lKCgX5u9BmC2Yg+LL9MgZDugFFs1Vl+Jp4t/PGw=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-direction": ["@radix-ui/react-direction@1.1.1", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-1UEWRX6jnOA2y4H5WczZ44gOOjTEmlqv1uNW4GAJEO5+bauCBhv8snY65Iw5/VOS/ghKN9gr2KjnLKxrsvoMVw=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-dismissable-layer": ["@radix-ui/react-dismissable-layer@1.1.11", "", { "dependencies": { "@radix-ui/primitive": "1.1.3", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-use-callback-ref": "1.1.1", "@radix-ui/react-use-escape-keydown": "1.1.1" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-Nqcp+t5cTB8BinFkZgXiMJniQH0PsUt2k51FUhbdfeKvc4ACcG2uQniY/8+h1Yv6Kza4Q7lD7PQV0z0oicE0Mg=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-dropdown-menu": ["@radix-ui/react-dropdown-menu@2.1.16", "", { "dependencies": { "@radix-ui/primitive": "1.1.3", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-id": "1.1.1", "@radix-ui/react-menu": "2.1.16", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-use-controllable-state": "1.2.2" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-1PLGQEynI/3OX/ftV54COn+3Sud/Mn8vALg2rWnBLnRaGtJDduNW/22XjlGgPdpcIbiQxjKtb7BkcjP00nqfJw=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-focus-guards": ["@radix-ui/react-focus-guards@1.1.3", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-0rFg/Rj2Q62NCm62jZw0QX7a3sz6QCQU0LpZdNrJX8byRGaGVTqbrW9jAoIAHyMQqsNpeZ81YgSizOt5WXq0Pw=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-focus-scope": ["@radix-ui/react-focus-scope@1.1.7", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-use-callback-ref": "1.1.1" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-t2ODlkXBQyn7jkl6TNaw/MtVEVvIGelJDCG41Okq/KwUsJBwQ4XVZsHAVUkK4mBv3ewiAS3PGuUWuY2BoK4ZUw=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-id": ["@radix-ui/react-id@1.1.1", "", { "dependencies": { "@radix-ui/react-use-layout-effect": "1.1.1" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-kGkGegYIdQsOb4XjsfM97rXsiHaBwco+hFI66oO4s9LU+PLAC5oJ7khdOVFxkhsmlbpUqDAvXw11CluXP+jkHg=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-label": ["@radix-ui/react-label@2.1.8", "", { "dependencies": { "@radix-ui/react-primitive": "2.1.4" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-FmXs37I6hSBVDlO4y764TNz1rLgKwjJMQ0EGte6F3Cb3f4bIuHB/iLa/8I9VKkmOy+gNHq8rql3j686ACVV21A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-menu": ["@radix-ui/react-menu@2.1.16", "", { "dependencies": { "@radix-ui/primitive": "1.1.3", "@radix-ui/react-collection": "1.1.7", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-direction": "1.1.1", "@radix-ui/react-dismissable-layer": "1.1.11", "@radix-ui/react-focus-guards": "1.1.3", "@radix-ui/react-focus-scope": "1.1.7", "@radix-ui/react-id": "1.1.1", "@radix-ui/react-popper": "1.2.8", "@radix-ui/react-portal": "1.1.9", "@radix-ui/react-presence": "1.1.5", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-roving-focus": "1.1.11", "@radix-ui/react-slot": "1.2.3", "@radix-ui/react-use-callback-ref": "1.1.1", "aria-hidden": "^1.2.4", "react-remove-scroll": "^2.6.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-72F2T+PLlphrqLcAotYPp0uJMr5SjP5SL01wfEspJbru5Zs5vQaSHb4VB3ZMJPimgHHCHG7gMOeOB9H3Hdmtxg=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-popper": ["@radix-ui/react-popper@1.2.8", "", { "dependencies": { "@floating-ui/react-dom": "^2.0.0", "@radix-ui/react-arrow": "1.1.7", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-use-callback-ref": "1.1.1", "@radix-ui/react-use-layout-effect": "1.1.1", "@radix-ui/react-use-rect": "1.1.1", "@radix-ui/react-use-size": "1.1.1", "@radix-ui/rect": "1.1.1" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-0NJQ4LFFUuWkE7Oxf0htBKS6zLkkjBH+hM1uk7Ng705ReR8m/uelduy1DBo0PyBXPKVnBA6YBlU94MBGXrSBCw=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-portal": ["@radix-ui/react-portal@1.1.9", "", { "dependencies": { "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-use-layout-effect": "1.1.1" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-bpIxvq03if6UNwXZ+HTK71JLh4APvnXntDc6XOX8UVq4XQOVl7lwok0AvIl+b8zgCw3fSaVTZMpAPPagXbKmHQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-presence": ["@radix-ui/react-presence@1.1.5", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-use-layout-effect": "1.1.1" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-/jfEwNDdQVBCNvjkGit4h6pMOzq8bHkopq458dPt2lMjx+eBQUohZNG9A7DtO/O5ukSbxuaNGXMjHicgwy6rQQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.4", "", { "dependencies": { "@radix-ui/react-slot": "1.2.4" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-9hQc4+GNVtJAIEPEqlYqW5RiYdrr8ea5XQ0ZOnD6fgru+83kqT15mq2OCcbe8KnjRZl5vF3ks69AKz3kh1jrhg=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-radio-group": ["@radix-ui/react-radio-group@1.3.8", "", { "dependencies": { "@radix-ui/primitive": "1.1.3", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-direction": "1.1.1", "@radix-ui/react-presence": "1.1.5", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-roving-focus": "1.1.11", "@radix-ui/react-use-controllable-state": "1.2.2", "@radix-ui/react-use-previous": "1.1.1", "@radix-ui/react-use-size": "1.1.1" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-VBKYIYImA5zsxACdisNQ3BjCBfmbGH3kQlnFVqlWU4tXwjy7cGX8ta80BcrO+WJXIn5iBylEH3K6ZTlee//lgQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-roving-focus": ["@radix-ui/react-roving-focus@1.1.11", "", { "dependencies": { "@radix-ui/primitive": "1.1.3", "@radix-ui/react-collection": "1.1.7", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-direction": "1.1.1", "@radix-ui/react-id": "1.1.1", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-use-callback-ref": "1.1.1", "@radix-ui/react-use-controllable-state": "1.2.2" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-7A6S9jSgm/S+7MdtNDSb+IU859vQqJ/QAtcYQcfFC6W8RS4IxIZDldLR0xqCFZ6DCyrQLjLPsxtTNch5jVA4lA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-scroll-area": ["@radix-ui/react-scroll-area@1.2.10", "", { "dependencies": { "@radix-ui/number": "1.1.1", "@radix-ui/primitive": "1.1.3", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-direction": "1.1.1", "@radix-ui/react-presence": "1.1.5", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-use-callback-ref": "1.1.1", "@radix-ui/react-use-layout-effect": "1.1.1" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-tAXIa1g3sM5CGpVT0uIbUx/U3Gs5N8T52IICuCtObaos1S8fzsrPXG5WObkQN3S6NVl6wKgPhAIiBGbWnvc97A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-select": ["@radix-ui/react-select@2.2.6", "", { "dependencies": { "@radix-ui/number": "1.1.1", "@radix-ui/primitive": "1.1.3", "@radix-ui/react-collection": "1.1.7", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-direction": "1.1.1", "@radix-ui/react-dismissable-layer": "1.1.11", "@radix-ui/react-focus-guards": "1.1.3", "@radix-ui/react-focus-scope": "1.1.7", "@radix-ui/react-id": "1.1.1", "@radix-ui/react-popper": "1.2.8", "@radix-ui/react-portal": "1.1.9", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-slot": "1.2.3", "@radix-ui/react-use-callback-ref": "1.1.1", "@radix-ui/react-use-controllable-state": "1.2.2", "@radix-ui/react-use-layout-effect": "1.1.1", "@radix-ui/react-use-previous": "1.1.1", "@radix-ui/react-visually-hidden": "1.2.3", "aria-hidden": "^1.2.4", "react-remove-scroll": "^2.6.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-I30RydO+bnn2PQztvo25tswPH+wFBjehVGtmagkU78yMdwTwVf12wnAOF+AeP8S2N8xD+5UPbGhkUfPyvT+mwQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-separator": ["@radix-ui/react-separator@1.1.8", "", { "dependencies": { "@radix-ui/react-primitive": "2.1.4" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-sDvqVY4itsKwwSMEe0jtKgfTh+72Sy3gPmQpjqcQneqQ4PFmr/1I0YA+2/puilhggCe2gJcx5EBAYFkWkdpa5g=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.4", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-Jl+bCv8HxKnlTLVrcDE8zTMJ09R9/ukw4qBs/oZClOfoQk/cOTbDn+NceXfV7j09YPVQUryJPHurafcSg6EVKA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-tabs": ["@radix-ui/react-tabs@1.1.13", "", { "dependencies": { "@radix-ui/primitive": "1.1.3", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-direction": "1.1.1", "@radix-ui/react-id": "1.1.1", "@radix-ui/react-presence": "1.1.5", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-roving-focus": "1.1.11", "@radix-ui/react-use-controllable-state": "1.2.2" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-7xdcatg7/U+7+Udyoj2zodtI9H/IIopqo+YOIcZOq1nJwXWBZ9p8xiu5llXlekDbZkca79a/fozEYQXIA4sW6A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-tooltip": ["@radix-ui/react-tooltip@1.2.8", "", { "dependencies": { "@radix-ui/primitive": "1.1.3", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-dismissable-layer": "1.1.11", "@radix-ui/react-id": "1.1.1", "@radix-ui/react-popper": "1.2.8", "@radix-ui/react-portal": "1.1.9", "@radix-ui/react-presence": "1.1.5", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-slot": "1.2.3", "@radix-ui/react-use-controllable-state": "1.2.2", "@radix-ui/react-visually-hidden": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-tY7sVt1yL9ozIxvmbtN5qtmH2krXcBCfjEiCgKGLqunJHvgvZG2Pcl2oQ3kbcZARb1BGEHdkLzcYGO8ynVlieg=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-use-callback-ref": ["@radix-ui/react-use-callback-ref@1.1.1", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-FkBMwD+qbGQeMu1cOHnuGB6x4yzPjho8ap5WtbEJ26umhgqVXbhekKUQO+hZEL1vU92a3wHwdp0HAcqAUF5iDg=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-use-controllable-state": ["@radix-ui/react-use-controllable-state@1.2.2", "", { "dependencies": { "@radix-ui/react-use-effect-event": "0.0.2", "@radix-ui/react-use-layout-effect": "1.1.1" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-BjasUjixPFdS+NKkypcyyN5Pmg83Olst0+c6vGov0diwTEo6mgdqVR6hxcEgFuh4QrAs7Rc+9KuGJ9TVCj0Zzg=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-use-effect-event": ["@radix-ui/react-use-effect-event@0.0.2", "", { "dependencies": { "@radix-ui/react-use-layout-effect": "1.1.1" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-Qp8WbZOBe+blgpuUT+lw2xheLP8q0oatc9UpmiemEICxGvFLYmHm9QowVZGHtJlGbS6A6yJ3iViad/2cVjnOiA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-use-escape-keydown": ["@radix-ui/react-use-escape-keydown@1.1.1", "", { "dependencies": { "@radix-ui/react-use-callback-ref": "1.1.1" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-Il0+boE7w/XebUHyBjroE+DbByORGR9KKmITzbR7MyQ4akpORYP/ZmbhAr0DG7RmmBqoOnZdy2QlvajJ2QA59g=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-use-is-hydrated": ["@radix-ui/react-use-is-hydrated@0.1.0", "", { "dependencies": { "use-sync-external-store": "^1.5.0" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-U+UORVEq+cTnRIaostJv9AGdV3G6Y+zbVd+12e18jQ5A3c0xL03IhnHuiU4UV69wolOQp5GfR58NW/EgdQhwOA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-use-layout-effect": ["@radix-ui/react-use-layout-effect@1.1.1", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-RbJRS4UWQFkzHTTwVymMTUv8EqYhOp8dOOviLj2ugtTiXRaRQS7GLGxZTLL1jWhMeoSCf5zmcZkqTl9IiYfXcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-use-previous": ["@radix-ui/react-use-previous@1.1.1", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-2dHfToCj/pzca2Ck724OZ5L0EVrr3eHRNsG/b3xQJLA2hZpVCS99bLAX+hm1IHXDEnzU6by5z/5MIY794/a8NQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-use-rect": ["@radix-ui/react-use-rect@1.1.1", "", { "dependencies": { "@radix-ui/rect": "1.1.1" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-QTYuDesS0VtuHNNvMh+CjlKJ4LJickCMUAqjlE3+j8w+RlRpwyX3apEQKGFzbZGdo7XNG1tXa+bQqIE7HIXT2w=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-use-size": ["@radix-ui/react-use-size@1.1.1", "", { "dependencies": { "@radix-ui/react-use-layout-effect": "1.1.1" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-ewrXRDTAqAXlkl6t/fkXWNAhFX9I+CkKlw6zjEwk86RSPKwZr3xpBRso655aqYafwtnbpHLj6toFzmd6xdVptQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-visually-hidden": ["@radix-ui/react-visually-hidden@1.2.3", "", { "dependencies": { "@radix-ui/react-primitive": "2.1.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-pzJq12tEaaIhqjbzpCuv/OypJY/BPavOofm+dbab+MHLajy277+1lLm6JFcGgF5eskJ6mquGirhXY2GD/8u8Ug=="],
|
||||||
|
|
||||||
|
"@radix-ui/rect": ["@radix-ui/rect@1.1.1", "", {}, "sha512-HPwpGIzkl28mWyZqG52jiqDJ12waP11Pa1lGoiyUkIEuMLBP0oeK/C89esbXrxsky5we7dfd8U58nm0SgAWpVw=="],
|
||||||
|
|
||||||
|
"@rolldown/pluginutils": ["@rolldown/pluginutils@1.0.0-beta.47", "", {}, "sha512-8QagwMH3kNCuzD8EWL8R2YPW5e4OrHNSAHRFDdmFqEwEaD/KcNKjVoumo+gP2vW5eKB2UPbM6vTYiGZX0ixLnw=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-android-arm-eabi": ["@rollup/rollup-android-arm-eabi@4.55.2", "", { "os": "android", "cpu": "arm" }, "sha512-21J6xzayjy3O6NdnlO6aXi/urvSRjm6nCI6+nF6ra2YofKruGixN9kfT+dt55HVNwfDmpDHJcaS3JuP/boNnlA=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-android-arm64": ["@rollup/rollup-android-arm64@4.55.2", "", { "os": "android", "cpu": "arm64" }, "sha512-eXBg7ibkNUZ+sTwbFiDKou0BAckeV6kIigK7y5Ko4mB/5A1KLhuzEKovsmfvsL8mQorkoincMFGnQuIT92SKqA=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-darwin-arm64": ["@rollup/rollup-darwin-arm64@4.55.2", "", { "os": "darwin", "cpu": "arm64" }, "sha512-UCbaTklREjrc5U47ypLulAgg4njaqfOVLU18VrCrI+6E5MQjuG0lSWaqLlAJwsD7NpFV249XgB0Bi37Zh5Sz4g=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-darwin-x64": ["@rollup/rollup-darwin-x64@4.55.2", "", { "os": "darwin", "cpu": "x64" }, "sha512-dP67MA0cCMHFT2g5XyjtpVOtp7y4UyUxN3dhLdt11at5cPKnSm4lY+EhwNvDXIMzAMIo2KU+mc9wxaAQJTn7sQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-freebsd-arm64": ["@rollup/rollup-freebsd-arm64@4.55.2", "", { "os": "freebsd", "cpu": "arm64" }, "sha512-WDUPLUwfYV9G1yxNRJdXcvISW15mpvod1Wv3ok+Ws93w1HjIVmCIFxsG2DquO+3usMNCpJQ0wqO+3GhFdl6Fow=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-freebsd-x64": ["@rollup/rollup-freebsd-x64@4.55.2", "", { "os": "freebsd", "cpu": "x64" }, "sha512-Ng95wtHVEulRwn7R0tMrlUuiLVL/HXA8Lt/MYVpy88+s5ikpntzZba1qEulTuPnPIZuOPcW9wNEiqvZxZmgmqQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-arm-gnueabihf": ["@rollup/rollup-linux-arm-gnueabihf@4.55.2", "", { "os": "linux", "cpu": "arm" }, "sha512-AEXMESUDWWGqD6LwO/HkqCZgUE1VCJ1OhbvYGsfqX2Y6w5quSXuyoy/Fg3nRqiwro+cJYFxiw5v4kB2ZDLhxrw=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-arm-musleabihf": ["@rollup/rollup-linux-arm-musleabihf@4.55.2", "", { "os": "linux", "cpu": "arm" }, "sha512-ZV7EljjBDwBBBSv570VWj0hiNTdHt9uGznDtznBB4Caj3ch5rgD4I2K1GQrtbvJ/QiB+663lLgOdcADMNVC29Q=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-arm64-gnu": ["@rollup/rollup-linux-arm64-gnu@4.55.2", "", { "os": "linux", "cpu": "arm64" }, "sha512-uvjwc8NtQVPAJtq4Tt7Q49FOodjfbf6NpqXyW/rjXoV+iZ3EJAHLNAnKT5UJBc6ffQVgmXTUL2ifYiLABlGFqA=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-arm64-musl": ["@rollup/rollup-linux-arm64-musl@4.55.2", "", { "os": "linux", "cpu": "arm64" }, "sha512-s3KoWVNnye9mm/2WpOZ3JeUiediUVw6AvY/H7jNA6qgKA2V2aM25lMkVarTDfiicn/DLq3O0a81jncXszoyCFA=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-loong64-gnu": ["@rollup/rollup-linux-loong64-gnu@4.55.2", "", { "os": "linux", "cpu": "none" }, "sha512-gi21faacK+J8aVSyAUptML9VQN26JRxe484IbF+h3hpG+sNVoMXPduhREz2CcYr5my0NE3MjVvQ5bMKX71pfVA=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-loong64-musl": ["@rollup/rollup-linux-loong64-musl@4.55.2", "", { "os": "linux", "cpu": "none" }, "sha512-qSlWiXnVaS/ceqXNfnoFZh4IiCA0EwvCivivTGbEu1qv2o+WTHpn1zNmCTAoOG5QaVr2/yhCoLScQtc/7RxshA=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-ppc64-gnu": ["@rollup/rollup-linux-ppc64-gnu@4.55.2", "", { "os": "linux", "cpu": "ppc64" }, "sha512-rPyuLFNoF1B0+wolH277E780NUKf+KoEDb3OyoLbAO18BbeKi++YN6gC/zuJoPPDlQRL3fIxHxCxVEWiem2yXw=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-ppc64-musl": ["@rollup/rollup-linux-ppc64-musl@4.55.2", "", { "os": "linux", "cpu": "ppc64" }, "sha512-g+0ZLMook31iWV4PvqKU0i9E78gaZgYpSrYPed/4Bu+nGTgfOPtfs1h11tSSRPXSjC5EzLTjV/1A7L2Vr8pJoQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-riscv64-gnu": ["@rollup/rollup-linux-riscv64-gnu@4.55.2", "", { "os": "linux", "cpu": "none" }, "sha512-i+sGeRGsjKZcQRh3BRfpLsM3LX3bi4AoEVqmGDyc50L6KfYsN45wVCSz70iQMwPWr3E5opSiLOwsC9WB4/1pqg=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-riscv64-musl": ["@rollup/rollup-linux-riscv64-musl@4.55.2", "", { "os": "linux", "cpu": "none" }, "sha512-C1vLcKc4MfFV6I0aWsC7B2Y9QcsiEcvKkfxprwkPfLaN8hQf0/fKHwSF2lcYzA9g4imqnhic729VB9Fo70HO3Q=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-s390x-gnu": ["@rollup/rollup-linux-s390x-gnu@4.55.2", "", { "os": "linux", "cpu": "s390x" }, "sha512-68gHUK/howpQjh7g7hlD9DvTTt4sNLp1Bb+Yzw2Ki0xvscm2cOdCLZNJNhd2jW8lsTPrHAHuF751BygifW4bkQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-x64-gnu": ["@rollup/rollup-linux-x64-gnu@4.55.2", "", { "os": "linux", "cpu": "x64" }, "sha512-1e30XAuaBP1MAizaOBApsgeGZge2/Byd6wV4a8oa6jPdHELbRHBiw7wvo4dp7Ie2PE8TZT4pj9RLGZv9N4qwlw=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-linux-x64-musl": ["@rollup/rollup-linux-x64-musl@4.55.2", "", { "os": "linux", "cpu": "x64" }, "sha512-4BJucJBGbuGnH6q7kpPqGJGzZnYrpAzRd60HQSt3OpX/6/YVgSsJnNzR8Ot74io50SeVT4CtCWe/RYIAymFPwA=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-openbsd-x64": ["@rollup/rollup-openbsd-x64@4.55.2", "", { "os": "openbsd", "cpu": "x64" }, "sha512-cT2MmXySMo58ENv8p6/O6wI/h/gLnD3D6JoajwXFZH6X9jz4hARqUhWpGuQhOgLNXscfZYRQMJvZDtWNzMAIDw=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-openharmony-arm64": ["@rollup/rollup-openharmony-arm64@4.55.2", "", { "os": "none", "cpu": "arm64" }, "sha512-sZnyUgGkuzIXaK3jNMPmUIyJrxu/PjmATQrocpGA1WbCPX8H5tfGgRSuYtqBYAvLuIGp8SPRb1O4d1Fkb5fXaQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-win32-arm64-msvc": ["@rollup/rollup-win32-arm64-msvc@4.55.2", "", { "os": "win32", "cpu": "arm64" }, "sha512-sDpFbenhmWjNcEbBcoTV0PWvW5rPJFvu+P7XoTY0YLGRupgLbFY0XPfwIbJOObzO7QgkRDANh65RjhPmgSaAjQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-win32-ia32-msvc": ["@rollup/rollup-win32-ia32-msvc@4.55.2", "", { "os": "win32", "cpu": "ia32" }, "sha512-GvJ03TqqaweWCigtKQVBErw2bEhu1tyfNQbarwr94wCGnczA9HF8wqEe3U/Lfu6EdeNP0p6R+APeHVwEqVxpUQ=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-win32-x64-gnu": ["@rollup/rollup-win32-x64-gnu@4.55.2", "", { "os": "win32", "cpu": "x64" }, "sha512-KvXsBvp13oZz9JGe5NYS7FNizLe99Ny+W8ETsuCyjXiKdiGrcz2/J/N8qxZ/RSwivqjQguug07NLHqrIHrqfYw=="],
|
||||||
|
|
||||||
|
"@rollup/rollup-win32-x64-msvc": ["@rollup/rollup-win32-x64-msvc@4.55.2", "", { "os": "win32", "cpu": "x64" }, "sha512-xNO+fksQhsAckRtDSPWaMeT1uIM+JrDRXlerpnWNXhn1TdB3YZ6uKBMBTKP0eX9XtYEP978hHk1f8332i2AW8Q=="],
|
||||||
|
|
||||||
|
"@standard-schema/utils": ["@standard-schema/utils@0.3.0", "", {}, "sha512-e7Mew686owMaPJVNNLs55PUvgz371nKgwsc4vxE49zsODpJEnxgxRo2y/OKrqueavXgZNMDVj3DdHFlaSAeU8g=="],
|
||||||
|
|
||||||
|
"@swc/core": ["@swc/core@1.15.10", "", { "dependencies": { "@swc/counter": "^0.1.3", "@swc/types": "^0.1.25" }, "optionalDependencies": { "@swc/core-darwin-arm64": "1.15.10", "@swc/core-darwin-x64": "1.15.10", "@swc/core-linux-arm-gnueabihf": "1.15.10", "@swc/core-linux-arm64-gnu": "1.15.10", "@swc/core-linux-arm64-musl": "1.15.10", "@swc/core-linux-x64-gnu": "1.15.10", "@swc/core-linux-x64-musl": "1.15.10", "@swc/core-win32-arm64-msvc": "1.15.10", "@swc/core-win32-ia32-msvc": "1.15.10", "@swc/core-win32-x64-msvc": "1.15.10" }, "peerDependencies": { "@swc/helpers": ">=0.5.17" }, "optionalPeers": ["@swc/helpers"] }, "sha512-udNofxftduMUEv7nqahl2nvodCiCDQ4Ge0ebzsEm6P8s0RC2tBM0Hqx0nNF5J/6t9uagFJyWIDjXy3IIWMHDJw=="],
|
||||||
|
|
||||||
|
"@swc/core-darwin-arm64": ["@swc/core-darwin-arm64@1.15.10", "", { "os": "darwin", "cpu": "arm64" }, "sha512-U72pGqmJYbjrLhMndIemZ7u9Q9owcJczGxwtfJlz/WwMaGYAV/g4nkGiUVk/+QSX8sFCAjanovcU1IUsP2YulA=="],
|
||||||
|
|
||||||
|
"@swc/core-darwin-x64": ["@swc/core-darwin-x64@1.15.10", "", { "os": "darwin", "cpu": "x64" }, "sha512-NZpDXtwHH083L40xdyj1sY31MIwLgOxKfZEAGCI8xHXdHa+GWvEiVdGiu4qhkJctoHFzAEc7ZX3GN5phuJcPuQ=="],
|
||||||
|
|
||||||
|
"@swc/core-linux-arm-gnueabihf": ["@swc/core-linux-arm-gnueabihf@1.15.10", "", { "os": "linux", "cpu": "arm" }, "sha512-ioieF5iuRziUF1HkH1gg1r93e055dAdeBAPGAk40VjqpL5/igPJ/WxFHGvc6WMLhUubSJI4S0AiZAAhEAp1jDg=="],
|
||||||
|
|
||||||
|
"@swc/core-linux-arm64-gnu": ["@swc/core-linux-arm64-gnu@1.15.10", "", { "os": "linux", "cpu": "arm64" }, "sha512-tD6BClOrxSsNus9cJL7Gxdv7z7Y2hlyvZd9l0NQz+YXzmTWqnfzLpg16ovEI7gknH2AgDBB5ywOsqu8hUgSeEQ=="],
|
||||||
|
|
||||||
|
"@swc/core-linux-arm64-musl": ["@swc/core-linux-arm64-musl@1.15.10", "", { "os": "linux", "cpu": "arm64" }, "sha512-4uAHO3nbfbrTcmO/9YcVweTQdx5fN3l7ewwl5AEK4yoC4wXmoBTEPHAVdKNe4r9+xrTgd4BgyPsy0409OjjlMw=="],
|
||||||
|
|
||||||
|
"@swc/core-linux-x64-gnu": ["@swc/core-linux-x64-gnu@1.15.10", "", { "os": "linux", "cpu": "x64" }, "sha512-W0h9ONNw1pVIA0cN7wtboOSTl4Jk3tHq+w2cMPQudu9/+3xoCxpFb9ZdehwCAk29IsvdWzGzY6P7dDVTyFwoqg=="],
|
||||||
|
|
||||||
|
"@swc/core-linux-x64-musl": ["@swc/core-linux-x64-musl@1.15.10", "", { "os": "linux", "cpu": "x64" }, "sha512-XQNZlLZB62S8nAbw7pqoqwy91Ldy2RpaMRqdRN3T+tAg6Xg6FywXRKCsLh6IQOadr4p1+lGnqM/Wn35z5a/0Vw=="],
|
||||||
|
|
||||||
|
"@swc/core-win32-arm64-msvc": ["@swc/core-win32-arm64-msvc@1.15.10", "", { "os": "win32", "cpu": "arm64" }, "sha512-qnAGrRv5Nj/DATxAmCnJQRXXQqnJwR0trxLndhoHoxGci9MuguNIjWahS0gw8YZFjgTinbTxOwzatkoySihnmw=="],
|
||||||
|
|
||||||
|
"@swc/core-win32-ia32-msvc": ["@swc/core-win32-ia32-msvc@1.15.10", "", { "os": "win32", "cpu": "ia32" }, "sha512-i4X/q8QSvzVlaRtv1xfnfl+hVKpCfiJ+9th484rh937fiEZKxZGf51C+uO0lfKDP1FfnT6C1yBYwHy7FLBVXFw=="],
|
||||||
|
|
||||||
|
"@swc/core-win32-x64-msvc": ["@swc/core-win32-x64-msvc@1.15.10", "", { "os": "win32", "cpu": "x64" }, "sha512-HvY8XUFuoTXn6lSccDLYFlXv1SU/PzYi4PyUqGT++WfTnbw/68N/7BdUZqglGRwiSqr0qhYt/EhmBpULj0J9rA=="],
|
||||||
|
|
||||||
|
"@swc/counter": ["@swc/counter@0.1.3", "", {}, "sha512-e2BR4lsJkkRlKZ/qCHPw9ZaSxc0MVUd7gtbtaB7aMvHeJVYe8sOB8DBZkP2DtISHGSku9sCK6T6cnY0CtXrOCQ=="],
|
||||||
|
|
||||||
|
"@swc/types": ["@swc/types@0.1.25", "", { "dependencies": { "@swc/counter": "^0.1.3" } }, "sha512-iAoY/qRhNH8a/hBvm3zKj9qQ4oc2+3w1unPJa2XvTK3XjeLXtzcCingVPw/9e5mn1+0yPqxcBGp9Jf0pkfMb1g=="],
|
||||||
|
|
||||||
|
"@tailwindcss/node": ["@tailwindcss/node@4.1.18", "", { "dependencies": { "@jridgewell/remapping": "^2.3.4", "enhanced-resolve": "^5.18.3", "jiti": "^2.6.1", "lightningcss": "1.30.2", "magic-string": "^0.30.21", "source-map-js": "^1.2.1", "tailwindcss": "4.1.18" } }, "sha512-DoR7U1P7iYhw16qJ49fgXUlry1t4CpXeErJHnQ44JgTSKMaZUdf17cfn5mHchfJ4KRBZRFA/Coo+MUF5+gOaCQ=="],
|
||||||
|
|
||||||
|
"@tailwindcss/oxide": ["@tailwindcss/oxide@4.1.18", "", { "optionalDependencies": { "@tailwindcss/oxide-android-arm64": "4.1.18", "@tailwindcss/oxide-darwin-arm64": "4.1.18", "@tailwindcss/oxide-darwin-x64": "4.1.18", "@tailwindcss/oxide-freebsd-x64": "4.1.18", "@tailwindcss/oxide-linux-arm-gnueabihf": "4.1.18", "@tailwindcss/oxide-linux-arm64-gnu": "4.1.18", "@tailwindcss/oxide-linux-arm64-musl": "4.1.18", "@tailwindcss/oxide-linux-x64-gnu": "4.1.18", "@tailwindcss/oxide-linux-x64-musl": "4.1.18", "@tailwindcss/oxide-wasm32-wasi": "4.1.18", "@tailwindcss/oxide-win32-arm64-msvc": "4.1.18", "@tailwindcss/oxide-win32-x64-msvc": "4.1.18" } }, "sha512-EgCR5tTS5bUSKQgzeMClT6iCY3ToqE1y+ZB0AKldj809QXk1Y+3jB0upOYZrn9aGIzPtUsP7sX4QQ4XtjBB95A=="],
|
||||||
|
|
||||||
|
"@tailwindcss/oxide-android-arm64": ["@tailwindcss/oxide-android-arm64@4.1.18", "", { "os": "android", "cpu": "arm64" }, "sha512-dJHz7+Ugr9U/diKJA0W6N/6/cjI+ZTAoxPf9Iz9BFRF2GzEX8IvXxFIi/dZBloVJX/MZGvRuFA9rqwdiIEZQ0Q=="],
|
||||||
|
|
||||||
|
"@tailwindcss/oxide-darwin-arm64": ["@tailwindcss/oxide-darwin-arm64@4.1.18", "", { "os": "darwin", "cpu": "arm64" }, "sha512-Gc2q4Qhs660bhjyBSKgq6BYvwDz4G+BuyJ5H1xfhmDR3D8HnHCmT/BSkvSL0vQLy/nkMLY20PQ2OoYMO15Jd0A=="],
|
||||||
|
|
||||||
|
"@tailwindcss/oxide-darwin-x64": ["@tailwindcss/oxide-darwin-x64@4.1.18", "", { "os": "darwin", "cpu": "x64" }, "sha512-FL5oxr2xQsFrc3X9o1fjHKBYBMD1QZNyc1Xzw/h5Qu4XnEBi3dZn96HcHm41c/euGV+GRiXFfh2hUCyKi/e+yw=="],
|
||||||
|
|
||||||
|
"@tailwindcss/oxide-freebsd-x64": ["@tailwindcss/oxide-freebsd-x64@4.1.18", "", { "os": "freebsd", "cpu": "x64" }, "sha512-Fj+RHgu5bDodmV1dM9yAxlfJwkkWvLiRjbhuO2LEtwtlYlBgiAT4x/j5wQr1tC3SANAgD+0YcmWVrj8R9trVMA=="],
|
||||||
|
|
||||||
|
"@tailwindcss/oxide-linux-arm-gnueabihf": ["@tailwindcss/oxide-linux-arm-gnueabihf@4.1.18", "", { "os": "linux", "cpu": "arm" }, "sha512-Fp+Wzk/Ws4dZn+LV2Nqx3IilnhH51YZoRaYHQsVq3RQvEl+71VGKFpkfHrLM/Li+kt5c0DJe/bHXK1eHgDmdiA=="],
|
||||||
|
|
||||||
|
"@tailwindcss/oxide-linux-arm64-gnu": ["@tailwindcss/oxide-linux-arm64-gnu@4.1.18", "", { "os": "linux", "cpu": "arm64" }, "sha512-S0n3jboLysNbh55Vrt7pk9wgpyTTPD0fdQeh7wQfMqLPM/Hrxi+dVsLsPrycQjGKEQk85Kgbx+6+QnYNiHalnw=="],
|
||||||
|
|
||||||
|
"@tailwindcss/oxide-linux-arm64-musl": ["@tailwindcss/oxide-linux-arm64-musl@4.1.18", "", { "os": "linux", "cpu": "arm64" }, "sha512-1px92582HkPQlaaCkdRcio71p8bc8i/ap5807tPRDK/uw953cauQBT8c5tVGkOwrHMfc2Yh6UuxaH4vtTjGvHg=="],
|
||||||
|
|
||||||
|
"@tailwindcss/oxide-linux-x64-gnu": ["@tailwindcss/oxide-linux-x64-gnu@4.1.18", "", { "os": "linux", "cpu": "x64" }, "sha512-v3gyT0ivkfBLoZGF9LyHmts0Isc8jHZyVcbzio6Wpzifg/+5ZJpDiRiUhDLkcr7f/r38SWNe7ucxmGW3j3Kb/g=="],
|
||||||
|
|
||||||
|
"@tailwindcss/oxide-linux-x64-musl": ["@tailwindcss/oxide-linux-x64-musl@4.1.18", "", { "os": "linux", "cpu": "x64" }, "sha512-bhJ2y2OQNlcRwwgOAGMY0xTFStt4/wyU6pvI6LSuZpRgKQwxTec0/3Scu91O8ir7qCR3AuepQKLU/kX99FouqQ=="],
|
||||||
|
|
||||||
|
"@tailwindcss/oxide-wasm32-wasi": ["@tailwindcss/oxide-wasm32-wasi@4.1.18", "", { "cpu": "none" }, "sha512-LffYTvPjODiP6PT16oNeUQJzNVyJl1cjIebq/rWWBF+3eDst5JGEFSc5cWxyRCJ0Mxl+KyIkqRxk1XPEs9x8TA=="],
|
||||||
|
|
||||||
|
"@tailwindcss/oxide-win32-arm64-msvc": ["@tailwindcss/oxide-win32-arm64-msvc@4.1.18", "", { "os": "win32", "cpu": "arm64" }, "sha512-HjSA7mr9HmC8fu6bdsZvZ+dhjyGCLdotjVOgLA2vEqxEBZaQo9YTX4kwgEvPCpRh8o4uWc4J/wEoFzhEmjvPbA=="],
|
||||||
|
|
||||||
|
"@tailwindcss/oxide-win32-x64-msvc": ["@tailwindcss/oxide-win32-x64-msvc@4.1.18", "", { "os": "win32", "cpu": "x64" }, "sha512-bJWbyYpUlqamC8dpR7pfjA0I7vdF6t5VpUGMWRkXVE3AXgIZjYUYAK7II1GNaxR8J1SSrSrppRar8G++JekE3Q=="],
|
||||||
|
|
||||||
|
"@tailwindcss/vite": ["@tailwindcss/vite@4.1.18", "", { "dependencies": { "@tailwindcss/node": "4.1.18", "@tailwindcss/oxide": "4.1.18", "tailwindcss": "4.1.18" }, "peerDependencies": { "vite": "^5.2.0 || ^6 || ^7" } }, "sha512-jVA+/UpKL1vRLg6Hkao5jldawNmRo7mQYrZtNHMIVpLfLhDml5nMRUo/8MwoX2vNXvnaXNNMedrMfMugAVX1nA=="],
|
||||||
|
|
||||||
|
"@tanstack/history": ["@tanstack/history@1.153.2", "", {}, "sha512-TVa0Wju5w6JZGq/S74Q7TQNtKXDatJaB4NYrhMZVU9ETlkgpr35NhDfOzsCJ93P0KCo1ZoDodlFp3c54/dLsyw=="],
|
||||||
|
|
||||||
|
"@tanstack/query-core": ["@tanstack/query-core@5.90.19", "", {}, "sha512-GLW5sjPVIvH491VV1ufddnfldyVB+teCnpPIvweEfkpRx7CfUmUGhoh9cdcUKBh/KwVxk22aNEDxeTsvmyB/WA=="],
|
||||||
|
|
||||||
|
"@tanstack/query-devtools": ["@tanstack/query-devtools@5.92.0", "", {}, "sha512-N8D27KH1vEpVacvZgJL27xC6yPFUy0Zkezn5gnB3L3gRCxlDeSuiya7fKge8Y91uMTnC8aSxBQhcK6ocY7alpQ=="],
|
||||||
|
|
||||||
|
"@tanstack/react-query": ["@tanstack/react-query@5.90.19", "", { "dependencies": { "@tanstack/query-core": "5.90.19" }, "peerDependencies": { "react": "^18 || ^19" } }, "sha512-qTZRZ4QyTzQc+M0IzrbKHxSeISUmRB3RPGmao5bT+sI6ayxSRhn0FXEnT5Hg3as8SBFcRosrXXRFB+yAcxVxJQ=="],
|
||||||
|
|
||||||
|
"@tanstack/react-query-devtools": ["@tanstack/react-query-devtools@5.91.2", "", { "dependencies": { "@tanstack/query-devtools": "5.92.0" }, "peerDependencies": { "@tanstack/react-query": "^5.90.14", "react": "^18 || ^19" } }, "sha512-ZJ1503ay5fFeEYFUdo7LMNFzZryi6B0Cacrgr2h1JRkvikK1khgIq6Nq2EcblqEdIlgB/r7XDW8f8DQ89RuUgg=="],
|
||||||
|
|
||||||
|
"@tanstack/react-router": ["@tanstack/react-router@1.153.2", "", { "dependencies": { "@tanstack/history": "1.153.2", "@tanstack/react-store": "^0.8.0", "@tanstack/router-core": "1.153.2", "isbot": "^5.1.22", "tiny-invariant": "^1.3.3", "tiny-warning": "^1.0.3" }, "peerDependencies": { "react": ">=18.0.0 || >=19.0.0", "react-dom": ">=18.0.0 || >=19.0.0" } }, "sha512-fAXUBA2gZAId7h2eSHsRcgTeF8pioUz8V5rrQ+IrvA0a6IsxhbTSKLYyqUg4jRDkkcUKtM8StKtvbZCY+0IYWw=="],
|
||||||
|
|
||||||
|
"@tanstack/react-router-devtools": ["@tanstack/react-router-devtools@1.153.2", "", { "dependencies": { "@tanstack/router-devtools-core": "1.153.2" }, "peerDependencies": { "@tanstack/react-router": "^1.153.2", "@tanstack/router-core": "^1.153.2", "react": ">=18.0.0 || >=19.0.0", "react-dom": ">=18.0.0 || >=19.0.0" } }, "sha512-LCEuRIyrF0tNKCBspR+TQj13MQ7sTCE4QkkuKAOp30nSdWLxq53bltnGs9bj/V/PTD52JibuAOYyxB94ssWZUA=="],
|
||||||
|
|
||||||
|
"@tanstack/react-store": ["@tanstack/react-store@0.8.0", "", { "dependencies": { "@tanstack/store": "0.8.0", "use-sync-external-store": "^1.6.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0", "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" } }, "sha512-1vG9beLIuB7q69skxK9r5xiLN3ztzIPfSQSs0GfeqWGO2tGIyInZx0x1COhpx97RKaONSoAb8C3dxacWksm1ow=="],
|
||||||
|
|
||||||
|
"@tanstack/react-table": ["@tanstack/react-table@8.21.3", "", { "dependencies": { "@tanstack/table-core": "8.21.3" }, "peerDependencies": { "react": ">=16.8", "react-dom": ">=16.8" } }, "sha512-5nNMTSETP4ykGegmVkhjcS8tTLW6Vl4axfEGQN3v0zdHYbK4UfoqfPChclTrJ4EoK9QynqAu9oUf8VEmrpZ5Ww=="],
|
||||||
|
|
||||||
|
"@tanstack/router-core": ["@tanstack/router-core@1.153.2", "", { "dependencies": { "@tanstack/history": "1.153.2", "@tanstack/store": "^0.8.0", "cookie-es": "^2.0.0", "seroval": "^1.4.1", "seroval-plugins": "^1.4.0", "tiny-invariant": "^1.3.3", "tiny-warning": "^1.0.3" } }, "sha512-WLaR+rSNW7bj9UCJQ3SKpuh6nZBZkpGnf2mpjn/uRB6joIQ3BU7aRdhb7w9Via/MP52iaHh5sd8NY3MaLpF2tQ=="],
|
||||||
|
|
||||||
|
"@tanstack/router-devtools": ["@tanstack/router-devtools@1.153.2", "", { "dependencies": { "@tanstack/react-router-devtools": "1.153.2", "clsx": "^2.1.1", "goober": "^2.1.16" }, "peerDependencies": { "@tanstack/react-router": "^1.153.2", "csstype": "^3.0.10", "react": ">=18.0.0 || >=19.0.0", "react-dom": ">=18.0.0 || >=19.0.0" } }, "sha512-rEGv1fogaknyYg3WbJBnRXrupI2HWUfpbcUOGkw0ltPYJZZOH5qotYBC92DJMMsy9MdBjcE3d8iqfgVycF7iwA=="],
|
||||||
|
|
||||||
|
"@tanstack/router-devtools-core": ["@tanstack/router-devtools-core@1.153.2", "", { "dependencies": { "clsx": "^2.1.1", "goober": "^2.1.16", "tiny-invariant": "^1.3.3" }, "peerDependencies": { "@tanstack/router-core": "^1.153.2", "csstype": "^3.0.10" } }, "sha512-53gFlnz2oUeGvRwu7hzi+jlqm5F5X1XwNniirCTjggsV5P+FVQ7YJ+gfMuN5MHonWmVCLd1QqGkl2nYRTGHeTg=="],
|
||||||
|
|
||||||
|
"@tanstack/router-generator": ["@tanstack/router-generator@1.153.2", "", { "dependencies": { "@tanstack/router-core": "1.153.2", "@tanstack/router-utils": "1.143.11", "@tanstack/virtual-file-routes": "1.145.4", "prettier": "^3.5.0", "recast": "^0.23.11", "source-map": "^0.7.4", "tsx": "^4.19.2", "zod": "^3.24.2" } }, "sha512-bEhmCtXq5vv3HukKq5zmTDBNDRqVllYxsHoWtqEvHv5hCb5xwKKfUMGemRoiQ96/wLFuGnA5DYkem2GZWcG3wg=="],
|
||||||
|
|
||||||
|
"@tanstack/router-plugin": ["@tanstack/router-plugin@1.153.2", "", { "dependencies": { "@babel/core": "^7.28.5", "@babel/plugin-syntax-jsx": "^7.27.1", "@babel/plugin-syntax-typescript": "^7.27.1", "@babel/template": "^7.27.2", "@babel/traverse": "^7.28.5", "@babel/types": "^7.28.5", "@tanstack/router-core": "1.153.2", "@tanstack/router-generator": "1.153.2", "@tanstack/router-utils": "1.143.11", "@tanstack/virtual-file-routes": "1.145.4", "babel-dead-code-elimination": "^1.0.11", "chokidar": "^3.6.0", "unplugin": "^2.1.2", "zod": "^3.24.2" }, "peerDependencies": { "@rsbuild/core": ">=1.0.2", "@tanstack/react-router": "^1.153.2", "vite": ">=5.0.0 || >=6.0.0 || >=7.0.0", "vite-plugin-solid": "^2.11.10", "webpack": ">=5.92.0" }, "optionalPeers": ["@rsbuild/core", "vite-plugin-solid", "webpack"] }, "sha512-aMMc70ChM0wBYOToq39kTMKI2A0EKWpumiKTJyAwEglXf0raF48+26Fmv0gr9/5CLvD0g8ljllsskVDyzg8oDw=="],
|
||||||
|
|
||||||
|
"@tanstack/router-utils": ["@tanstack/router-utils@1.143.11", "", { "dependencies": { "@babel/core": "^7.28.5", "@babel/generator": "^7.28.5", "@babel/parser": "^7.28.5", "ansis": "^4.1.0", "diff": "^8.0.2", "pathe": "^2.0.3", "tinyglobby": "^0.2.15" } }, "sha512-N24G4LpfyK8dOlnP8BvNdkuxg1xQljkyl6PcrdiPSA301pOjatRT1y8wuCCJZKVVD8gkd0MpCZ0VEjRMGILOtA=="],
|
||||||
|
|
||||||
|
"@tanstack/store": ["@tanstack/store@0.8.0", "", {}, "sha512-Om+BO0YfMZe//X2z0uLF2j+75nQga6TpTJgLJQBiq85aOyZNIhkCgleNcud2KQg4k4v9Y9l+Uhru3qWMPGTOzQ=="],
|
||||||
|
|
||||||
|
"@tanstack/table-core": ["@tanstack/table-core@8.21.3", "", {}, "sha512-ldZXEhOBb8Is7xLs01fR3YEc3DERiz5silj8tnGkFZytt1abEvl/GhUmCE0PMLaMPTa3Jk4HbKmRlHmu+gCftg=="],
|
||||||
|
|
||||||
|
"@tanstack/virtual-file-routes": ["@tanstack/virtual-file-routes@1.145.4", "", {}, "sha512-CI75JrfqSluhdGwLssgVeQBaCphgfkMQpi8MCY3UJX1hoGzXa8kHYJcUuIFMOLs1q7zqHy++EVVtMK03osR5wQ=="],
|
||||||
|
|
||||||
|
"@types/estree": ["@types/estree@1.0.8", "", {}, "sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w=="],
|
||||||
|
|
||||||
|
"@types/json-schema": ["@types/json-schema@7.0.15", "", {}, "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA=="],
|
||||||
|
|
||||||
|
"@types/node": ["@types/node@25.0.9", "", { "dependencies": { "undici-types": "~7.16.0" } }, "sha512-/rpCXHlCWeqClNBwUhDcusJxXYDjZTyE8v5oTO7WbL8eij2nKhUeU89/6xgjU7N4/Vh3He0BtyhJdQbDyhiXAw=="],
|
||||||
|
|
||||||
|
"@types/react": ["@types/react@19.2.9", "", { "dependencies": { "csstype": "^3.2.2" } }, "sha512-Lpo8kgb/igvMIPeNV2rsYKTgaORYdO1XGVZ4Qz3akwOj0ySGYMPlQWa8BaLn0G63D1aSaAQ5ldR06wCpChQCjA=="],
|
||||||
|
|
||||||
|
"@types/react-dom": ["@types/react-dom@19.2.3", "", { "peerDependencies": { "@types/react": "^19.2.0" } }, "sha512-jp2L/eY6fn+KgVVQAOqYItbF0VY/YApe5Mz2F0aykSO8gx31bYCZyvSeYxCHKvzHG5eZjc+zyaS5BrBWya2+kQ=="],
|
||||||
|
|
||||||
|
"@vitejs/plugin-react-swc": ["@vitejs/plugin-react-swc@4.2.2", "", { "dependencies": { "@rolldown/pluginutils": "1.0.0-beta.47", "@swc/core": "^1.13.5" }, "peerDependencies": { "vite": "^4 || ^5 || ^6 || ^7" } }, "sha512-x+rE6tsxq/gxrEJN3Nv3dIV60lFflPj94c90b+NNo6n1QV1QQUTLoL0MpaOVasUZ0zqVBn7ead1B5ecx1JAGfA=="],
|
||||||
|
|
||||||
|
"acorn": ["acorn@8.15.0", "", { "bin": "bin/acorn" }, "sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg=="],
|
||||||
|
|
||||||
|
"ansi-colors": ["ansi-colors@4.1.3", "", {}, "sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw=="],
|
||||||
|
|
||||||
|
"ansis": ["ansis@4.2.0", "", {}, "sha512-HqZ5rWlFjGiV0tDm3UxxgNRqsOTniqoKZu0pIAfh7TZQMGuZK+hH0drySty0si0QXj1ieop4+SkSfPZBPPkHig=="],
|
||||||
|
|
||||||
|
"anymatch": ["anymatch@3.1.3", "", { "dependencies": { "normalize-path": "^3.0.0", "picomatch": "^2.0.4" } }, "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw=="],
|
||||||
|
|
||||||
|
"argparse": ["argparse@2.0.1", "", {}, "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q=="],
|
||||||
|
|
||||||
|
"aria-hidden": ["aria-hidden@1.2.6", "", { "dependencies": { "tslib": "^2.0.0" } }, "sha512-ik3ZgC9dY/lYVVM++OISsaYDeg1tb0VtP5uL3ouh1koGOaUMDPpbFIei4JkFimWUFPn90sbMNMXQAIVOlnYKJA=="],
|
||||||
|
|
||||||
|
"ast-types": ["ast-types@0.16.1", "", { "dependencies": { "tslib": "^2.0.1" } }, "sha512-6t10qk83GOG8p0vKmaCr8eiilZwO171AvbROMtvvNiwrTly62t+7XkA8RdIIVbpMhCASAsxgAzdRSwh6nw/5Dg=="],
|
||||||
|
|
||||||
|
"asynckit": ["asynckit@0.4.0", "", {}, "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q=="],
|
||||||
|
|
||||||
|
"axios": ["axios@1.13.2", "", { "dependencies": { "follow-redirects": "^1.15.6", "form-data": "^4.0.4", "proxy-from-env": "^1.1.0" } }, "sha512-VPk9ebNqPcy5lRGuSlKx752IlDatOjT9paPlm8A7yOuW2Fbvp4X3JznJtT4f0GzGLLiWE9W8onz51SqLYwzGaA=="],
|
||||||
|
|
||||||
|
"babel-dead-code-elimination": ["babel-dead-code-elimination@1.0.12", "", { "dependencies": { "@babel/core": "^7.23.7", "@babel/parser": "^7.23.6", "@babel/traverse": "^7.23.7", "@babel/types": "^7.23.6" } }, "sha512-GERT7L2TiYcYDtYk1IpD+ASAYXjKbLTDPhBtYj7X1NuRMDTMtAx9kyBenub1Ev41lo91OHCKdmP+egTDmfQ7Ig=="],
|
||||||
|
|
||||||
|
"baseline-browser-mapping": ["baseline-browser-mapping@2.9.16", "", { "bin": "dist/cli.js" }, "sha512-KeUZdBuxngy825i8xvzaK1Ncnkx0tBmb3k8DkEuqjKRkmtvNTjey2ZsNeh8Dw4lfKvbCOu9oeNx2TKm2vHqcRw=="],
|
||||||
|
|
||||||
|
"binary-extensions": ["binary-extensions@2.3.0", "", {}, "sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw=="],
|
||||||
|
|
||||||
|
"braces": ["braces@3.0.3", "", { "dependencies": { "fill-range": "^7.1.1" } }, "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA=="],
|
||||||
|
|
||||||
|
"browserslist": ["browserslist@4.28.1", "", { "dependencies": { "baseline-browser-mapping": "^2.9.0", "caniuse-lite": "^1.0.30001759", "electron-to-chromium": "^1.5.263", "node-releases": "^2.0.27", "update-browserslist-db": "^1.2.0" }, "bin": "cli.js" }, "sha512-ZC5Bd0LgJXgwGqUknZY/vkUQ04r8NXnJZ3yYi4vDmSiZmC/pdSN0NbNRPxZpbtO4uAfDUAFffO8IZoM3Gj8IkA=="],
|
||||||
|
|
||||||
|
"bundle-name": ["bundle-name@4.1.0", "", { "dependencies": { "run-applescript": "^7.0.0" } }, "sha512-tjwM5exMg6BGRI+kNmTntNsvdZS1X8BFYS6tnJ2hdH0kVxM6/eVZ2xy+FqStSWvYmtfFMDLIxurorHwDKfDz5Q=="],
|
||||||
|
|
||||||
|
"c12": ["c12@2.0.1", "", { "dependencies": { "chokidar": "^4.0.1", "confbox": "^0.1.7", "defu": "^6.1.4", "dotenv": "^16.4.5", "giget": "^1.2.3", "jiti": "^2.3.0", "mlly": "^1.7.1", "ohash": "^1.1.4", "pathe": "^1.1.2", "perfect-debounce": "^1.0.0", "pkg-types": "^1.2.0", "rc9": "^2.1.2" }, "peerDependencies": { "magicast": "^0.3.5" }, "optionalPeers": ["magicast"] }, "sha512-Z4JgsKXHG37C6PYUtIxCfLJZvo6FyhHJoClwwb9ftUkLpPSkuYqn6Tr+vnaN8hymm0kIbcg6Ey3kv/Q71k5w/A=="],
|
||||||
|
|
||||||
|
"call-bind-apply-helpers": ["call-bind-apply-helpers@1.0.2", "", { "dependencies": { "es-errors": "^1.3.0", "function-bind": "^1.1.2" } }, "sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ=="],
|
||||||
|
|
||||||
|
"caniuse-lite": ["caniuse-lite@1.0.30001765", "", {}, "sha512-LWcNtSyZrakjECqmpP4qdg0MMGdN368D7X8XvvAqOcqMv0RxnlqVKZl2V6/mBR68oYMxOZPLw/gO7DuisMHUvQ=="],
|
||||||
|
|
||||||
|
"chokidar": ["chokidar@3.6.0", "", { "dependencies": { "anymatch": "~3.1.2", "braces": "~3.0.2", "glob-parent": "~5.1.2", "is-binary-path": "~2.1.0", "is-glob": "~4.0.1", "normalize-path": "~3.0.0", "readdirp": "~3.6.0" }, "optionalDependencies": { "fsevents": "~2.3.2" } }, "sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw=="],
|
||||||
|
|
||||||
|
"chownr": ["chownr@2.0.0", "", {}, "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ=="],
|
||||||
|
|
||||||
|
"citty": ["citty@0.1.6", "", { "dependencies": { "consola": "^3.2.3" } }, "sha512-tskPPKEs8D2KPafUypv2gxwJP8h/OaJmC82QQGGDQcHvXX43xF2VDACcJVmZ0EuSxkpO9Kc4MlrA3q0+FG58AQ=="],
|
||||||
|
|
||||||
|
"class-variance-authority": ["class-variance-authority@0.7.1", "", { "dependencies": { "clsx": "^2.1.1" } }, "sha512-Ka+9Trutv7G8M6WT6SeiRWz792K5qEqIGEGzXKhAE6xOWAY6pPH8U+9IY3oCMv6kqTmLsv7Xh/2w2RigkePMsg=="],
|
||||||
|
|
||||||
|
"clsx": ["clsx@2.1.1", "", {}, "sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA=="],
|
||||||
|
|
||||||
|
"color-support": ["color-support@1.1.3", "", { "bin": "bin.js" }, "sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg=="],
|
||||||
|
|
||||||
|
"combined-stream": ["combined-stream@1.0.8", "", { "dependencies": { "delayed-stream": "~1.0.0" } }, "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg=="],
|
||||||
|
|
||||||
|
"commander": ["commander@13.0.0", "", {}, "sha512-oPYleIY8wmTVzkvQq10AEok6YcTC4sRUBl8F9gVuwchGVUCTbl/vhLTaQqutuuySYOsu8YTgV+OxKc/8Yvx+mQ=="],
|
||||||
|
|
||||||
|
"confbox": ["confbox@0.1.8", "", {}, "sha512-RMtmw0iFkeR4YV+fUOSucriAQNb9g8zFR52MWCtl+cCZOFRNL6zeB395vPzFhEjjn4fMxXudmELnl/KF/WrK6w=="],
|
||||||
|
|
||||||
|
"consola": ["consola@3.4.2", "", {}, "sha512-5IKcdX0nnYavi6G7TtOhwkYzyjfJlatbjMjuLSfE2kYT5pMDOilZ4OvMhi637CcDICTmz3wARPoyhqyX1Y+XvA=="],
|
||||||
|
|
||||||
|
"convert-source-map": ["convert-source-map@2.0.0", "", {}, "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg=="],
|
||||||
|
|
||||||
|
"cookie-es": ["cookie-es@2.0.0", "", {}, "sha512-RAj4E421UYRgqokKUmotqAwuplYw15qtdXfY+hGzgCJ/MBjCVZcSoHK/kH9kocfjRjcDME7IiDWR/1WX1TM2Pg=="],
|
||||||
|
|
||||||
|
"csstype": ["csstype@3.2.3", "", {}, "sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ=="],
|
||||||
|
|
||||||
|
"debug": ["debug@4.4.3", "", { "dependencies": { "ms": "^2.1.3" } }, "sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA=="],
|
||||||
|
|
||||||
|
"default-browser": ["default-browser@5.4.0", "", { "dependencies": { "bundle-name": "^4.1.0", "default-browser-id": "^5.0.0" } }, "sha512-XDuvSq38Hr1MdN47EDvYtx3U0MTqpCEn+F6ft8z2vYDzMrvQhVp0ui9oQdqW3MvK3vqUETglt1tVGgjLuJ5izg=="],
|
||||||
|
|
||||||
|
"default-browser-id": ["default-browser-id@5.0.1", "", {}, "sha512-x1VCxdX4t+8wVfd1so/9w+vQ4vx7lKd2Qp5tDRutErwmR85OgmfX7RlLRMWafRMY7hbEiXIbudNrjOAPa/hL8Q=="],
|
||||||
|
|
||||||
|
"define-lazy-prop": ["define-lazy-prop@3.0.0", "", {}, "sha512-N+MeXYoqr3pOgn8xfyRPREN7gHakLYjhsHhWGT3fWAiL4IkAt0iDw14QiiEm2bE30c5XX5q0FtAA3CK5f9/BUg=="],
|
||||||
|
|
||||||
|
"defu": ["defu@6.1.4", "", {}, "sha512-mEQCMmwJu317oSz8CwdIOdwf3xMif1ttiM8LTufzc3g6kR+9Pe236twL8j3IYT1F7GfRgGcW6MWxzZjLIkuHIg=="],
|
||||||
|
|
||||||
|
"delayed-stream": ["delayed-stream@1.0.0", "", {}, "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ=="],
|
||||||
|
|
||||||
|
"destr": ["destr@2.0.5", "", {}, "sha512-ugFTXCtDZunbzasqBxrK93Ik/DRYsO6S/fedkWEMKqt04xZ4csmnmwGDBAb07QWNaGMAmnTIemsYZCksjATwsA=="],
|
||||||
|
|
||||||
|
"detect-libc": ["detect-libc@2.1.2", "", {}, "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ=="],
|
||||||
|
|
||||||
|
"detect-node-es": ["detect-node-es@1.1.0", "", {}, "sha512-ypdmJU/TbBby2Dxibuv7ZLW3Bs1QEmM7nHjEANfohJLvE0XVujisn1qPJcZxg+qDucsr+bP6fLD1rPS3AhJ7EQ=="],
|
||||||
|
|
||||||
|
"diff": ["diff@8.0.3", "", {}, "sha512-qejHi7bcSD4hQAZE0tNAawRK1ZtafHDmMTMkrrIGgSLl7hTnQHmKCeB45xAcbfTqK2zowkM3j3bHt/4b/ARbYQ=="],
|
||||||
|
|
||||||
|
"dotenv": ["dotenv@17.2.3", "", {}, "sha512-JVUnt+DUIzu87TABbhPmNfVdBDt18BLOWjMUFJMSi/Qqg7NTYtabbvSNJGOJ7afbRuv9D/lngizHtP7QyLQ+9w=="],
|
||||||
|
|
||||||
|
"dunder-proto": ["dunder-proto@1.0.1", "", { "dependencies": { "call-bind-apply-helpers": "^1.0.1", "es-errors": "^1.3.0", "gopd": "^1.2.0" } }, "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A=="],
|
||||||
|
|
||||||
|
"electron-to-chromium": ["electron-to-chromium@1.5.267", "", {}, "sha512-0Drusm6MVRXSOJpGbaSVgcQsuB4hEkMpHXaVstcPmhu5LIedxs1xNK/nIxmQIU/RPC0+1/o0AVZfBTkTNJOdUw=="],
|
||||||
|
|
||||||
|
"enhanced-resolve": ["enhanced-resolve@5.18.4", "", { "dependencies": { "graceful-fs": "^4.2.4", "tapable": "^2.2.0" } }, "sha512-LgQMM4WXU3QI+SYgEc2liRgznaD5ojbmY3sb8LxyguVkIg5FxdpTkvk72te2R38/TGKxH634oLxXRGY6d7AP+Q=="],
|
||||||
|
|
||||||
|
"es-define-property": ["es-define-property@1.0.1", "", {}, "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g=="],
|
||||||
|
|
||||||
|
"es-errors": ["es-errors@1.3.0", "", {}, "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw=="],
|
||||||
|
|
||||||
|
"es-object-atoms": ["es-object-atoms@1.1.1", "", { "dependencies": { "es-errors": "^1.3.0" } }, "sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA=="],
|
||||||
|
|
||||||
|
"es-set-tostringtag": ["es-set-tostringtag@2.1.0", "", { "dependencies": { "es-errors": "^1.3.0", "get-intrinsic": "^1.2.6", "has-tostringtag": "^1.0.2", "hasown": "^2.0.2" } }, "sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA=="],
|
||||||
|
|
||||||
|
"esbuild": ["esbuild@0.27.2", "", { "optionalDependencies": { "@esbuild/aix-ppc64": "0.27.2", "@esbuild/android-arm": "0.27.2", "@esbuild/android-arm64": "0.27.2", "@esbuild/android-x64": "0.27.2", "@esbuild/darwin-arm64": "0.27.2", "@esbuild/darwin-x64": "0.27.2", "@esbuild/freebsd-arm64": "0.27.2", "@esbuild/freebsd-x64": "0.27.2", "@esbuild/linux-arm": "0.27.2", "@esbuild/linux-arm64": "0.27.2", "@esbuild/linux-ia32": "0.27.2", "@esbuild/linux-loong64": "0.27.2", "@esbuild/linux-mips64el": "0.27.2", "@esbuild/linux-ppc64": "0.27.2", "@esbuild/linux-riscv64": "0.27.2", "@esbuild/linux-s390x": "0.27.2", "@esbuild/linux-x64": "0.27.2", "@esbuild/netbsd-arm64": "0.27.2", "@esbuild/netbsd-x64": "0.27.2", "@esbuild/openbsd-arm64": "0.27.2", "@esbuild/openbsd-x64": "0.27.2", "@esbuild/openharmony-arm64": "0.27.2", "@esbuild/sunos-x64": "0.27.2", "@esbuild/win32-arm64": "0.27.2", "@esbuild/win32-ia32": "0.27.2", "@esbuild/win32-x64": "0.27.2" }, "bin": "bin/esbuild" }, "sha512-HyNQImnsOC7X9PMNaCIeAm4ISCQXs5a5YasTXVliKv4uuBo1dKrG0A+uQS8M5eXjVMnLg3WgXaKvprHlFJQffw=="],
|
||||||
|
|
||||||
|
"escalade": ["escalade@3.2.0", "", {}, "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA=="],
|
||||||
|
|
||||||
|
"esprima": ["esprima@4.0.1", "", { "bin": { "esparse": "bin/esparse.js", "esvalidate": "bin/esvalidate.js" } }, "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A=="],
|
||||||
|
|
||||||
|
"fdir": ["fdir@6.5.0", "", { "peerDependencies": { "picomatch": "^3 || ^4" } }, "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg=="],
|
||||||
|
|
||||||
|
"fill-range": ["fill-range@7.1.1", "", { "dependencies": { "to-regex-range": "^5.0.1" } }, "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg=="],
|
||||||
|
|
||||||
|
"follow-redirects": ["follow-redirects@1.15.11", "", {}, "sha512-deG2P0JfjrTxl50XGCDyfI97ZGVCxIpfKYmfyrQ54n5FO/0gfIES8C/Psl6kWVDolizcaaxZJnTS0QSMxvnsBQ=="],
|
||||||
|
|
||||||
|
"form-data": ["form-data@4.0.5", "", { "dependencies": { "asynckit": "^0.4.0", "combined-stream": "^1.0.8", "es-set-tostringtag": "^2.1.0", "hasown": "^2.0.2", "mime-types": "^2.1.12" } }, "sha512-8RipRLol37bNs2bhoV67fiTEvdTrbMUYcFTiy3+wuuOnUog2QBHCZWXDRijWQfAkhBj2Uf5UnVaiWwA5vdd82w=="],
|
||||||
|
|
||||||
|
"frontend": ["frontend@workspace:frontend"],
|
||||||
|
|
||||||
|
"fs-minipass": ["fs-minipass@2.1.0", "", { "dependencies": { "minipass": "^3.0.0" } }, "sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg=="],
|
||||||
|
|
||||||
|
"fsevents": ["fsevents@2.3.3", "", { "os": "darwin" }, "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw=="],
|
||||||
|
|
||||||
|
"function-bind": ["function-bind@1.1.2", "", {}, "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA=="],
|
||||||
|
|
||||||
|
"gensync": ["gensync@1.0.0-beta.2", "", {}, "sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg=="],
|
||||||
|
|
||||||
|
"get-intrinsic": ["get-intrinsic@1.3.0", "", { "dependencies": { "call-bind-apply-helpers": "^1.0.2", "es-define-property": "^1.0.1", "es-errors": "^1.3.0", "es-object-atoms": "^1.1.1", "function-bind": "^1.1.2", "get-proto": "^1.0.1", "gopd": "^1.2.0", "has-symbols": "^1.1.0", "hasown": "^2.0.2", "math-intrinsics": "^1.1.0" } }, "sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ=="],
|
||||||
|
|
||||||
|
"get-nonce": ["get-nonce@1.0.1", "", {}, "sha512-FJhYRoDaiatfEkUK8HKlicmu/3SGFD51q3itKDGoSTysQJBnfOcxU5GxnhE1E6soB76MbT0MBtnKJuXyAx+96Q=="],
|
||||||
|
|
||||||
|
"get-proto": ["get-proto@1.0.1", "", { "dependencies": { "dunder-proto": "^1.0.1", "es-object-atoms": "^1.0.0" } }, "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g=="],
|
||||||
|
|
||||||
|
"get-tsconfig": ["get-tsconfig@4.13.0", "", { "dependencies": { "resolve-pkg-maps": "^1.0.0" } }, "sha512-1VKTZJCwBrvbd+Wn3AOgQP/2Av+TfTCOlE4AcRJE72W1ksZXbAx8PPBR9RzgTeSPzlPMHrbANMH3LbltH73wxQ=="],
|
||||||
|
|
||||||
|
"giget": ["giget@1.2.5", "", { "dependencies": { "citty": "^0.1.6", "consola": "^3.4.0", "defu": "^6.1.4", "node-fetch-native": "^1.6.6", "nypm": "^0.5.4", "pathe": "^2.0.3", "tar": "^6.2.1" }, "bin": "dist/cli.mjs" }, "sha512-r1ekGw/Bgpi3HLV3h1MRBIlSAdHoIMklpaQ3OQLFcRw9PwAj2rqigvIbg+dBUI51OxVI2jsEtDywDBjSiuf7Ug=="],
|
||||||
|
|
||||||
|
"glob-parent": ["glob-parent@5.1.2", "", { "dependencies": { "is-glob": "^4.0.1" } }, "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow=="],
|
||||||
|
|
||||||
|
"goober": ["goober@2.1.18", "", { "peerDependencies": { "csstype": "^3.0.10" } }, "sha512-2vFqsaDVIT9Gz7N6kAL++pLpp41l3PfDuusHcjnGLfR6+huZkl6ziX+zgVC3ZxpqWhzH6pyDdGrCeDhMIvwaxw=="],
|
||||||
|
|
||||||
|
"gopd": ["gopd@1.2.0", "", {}, "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg=="],
|
||||||
|
|
||||||
|
"graceful-fs": ["graceful-fs@4.2.11", "", {}, "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ=="],
|
||||||
|
|
||||||
|
"handlebars": ["handlebars@4.7.8", "", { "dependencies": { "minimist": "^1.2.5", "neo-async": "^2.6.2", "source-map": "^0.6.1", "wordwrap": "^1.0.0" }, "optionalDependencies": { "uglify-js": "^3.1.4" }, "bin": "bin/handlebars" }, "sha512-vafaFqs8MZkRrSX7sFVUdo3ap/eNiLnb4IakshzvP56X5Nr1iGKAIqdX6tMlm6HcNRIkr6AxO5jFEoJzzpT8aQ=="],
|
||||||
|
|
||||||
|
"has-symbols": ["has-symbols@1.1.0", "", {}, "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ=="],
|
||||||
|
|
||||||
|
"has-tostringtag": ["has-tostringtag@1.0.2", "", { "dependencies": { "has-symbols": "^1.0.3" } }, "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw=="],
|
||||||
|
|
||||||
|
"hasown": ["hasown@2.0.2", "", { "dependencies": { "function-bind": "^1.1.2" } }, "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ=="],
|
||||||
|
|
||||||
|
"is-binary-path": ["is-binary-path@2.1.0", "", { "dependencies": { "binary-extensions": "^2.0.0" } }, "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw=="],
|
||||||
|
|
||||||
|
"is-docker": ["is-docker@3.0.0", "", { "bin": "cli.js" }, "sha512-eljcgEDlEns/7AXFosB5K/2nCM4P7FQPkGc/DWLy5rmFEWvZayGrik1d9/QIY5nJ4f9YsVvBkA6kJpHn9rISdQ=="],
|
||||||
|
|
||||||
|
"is-extglob": ["is-extglob@2.1.1", "", {}, "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ=="],
|
||||||
|
|
||||||
|
"is-glob": ["is-glob@4.0.3", "", { "dependencies": { "is-extglob": "^2.1.1" } }, "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg=="],
|
||||||
|
|
||||||
|
"is-inside-container": ["is-inside-container@1.0.0", "", { "dependencies": { "is-docker": "^3.0.0" }, "bin": "cli.js" }, "sha512-KIYLCCJghfHZxqjYBE7rEy0OBuTd5xCHS7tHVgvCLkx7StIoaxwNW3hCALgEUjFfeRk+MG/Qxmp/vtETEF3tRA=="],
|
||||||
|
|
||||||
|
"is-number": ["is-number@7.0.0", "", {}, "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng=="],
|
||||||
|
|
||||||
|
"is-wsl": ["is-wsl@3.1.0", "", { "dependencies": { "is-inside-container": "^1.0.0" } }, "sha512-UcVfVfaK4Sc4m7X3dUSoHoozQGBEFeDC+zVo06t98xe8CzHSZZBekNXH+tu0NalHolcJ/QAGqS46Hef7QXBIMw=="],
|
||||||
|
|
||||||
|
"isbot": ["isbot@5.1.33", "", {}, "sha512-P4Hgb5NqswjkI0J1CM6XKXon/sxKY1SuowE7Qx2hrBhIwICFyXy54mfgB5eMHXsbe/eStzzpbIGNOvGmz+dlKg=="],
|
||||||
|
|
||||||
|
"jiti": ["jiti@2.6.1", "", { "bin": "lib/jiti-cli.mjs" }, "sha512-ekilCSN1jwRvIbgeg/57YFh8qQDNbwDb9xT/qu2DAHbFFZUicIl4ygVaAvzveMhMVr3LnpSKTNnwt8PoOfmKhQ=="],
|
||||||
|
|
||||||
|
"js-tokens": ["js-tokens@4.0.0", "", {}, "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ=="],
|
||||||
|
|
||||||
|
"js-yaml": ["js-yaml@4.1.1", "", { "dependencies": { "argparse": "^2.0.1" }, "bin": "bin/js-yaml.js" }, "sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA=="],
|
||||||
|
|
||||||
|
"jsesc": ["jsesc@3.1.0", "", { "bin": "bin/jsesc" }, "sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA=="],
|
||||||
|
|
||||||
|
"json5": ["json5@2.2.3", "", { "bin": "lib/cli.js" }, "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg=="],
|
||||||
|
|
||||||
|
"lightningcss": ["lightningcss@1.30.2", "", { "dependencies": { "detect-libc": "^2.0.3" }, "optionalDependencies": { "lightningcss-android-arm64": "1.30.2", "lightningcss-darwin-arm64": "1.30.2", "lightningcss-darwin-x64": "1.30.2", "lightningcss-freebsd-x64": "1.30.2", "lightningcss-linux-arm-gnueabihf": "1.30.2", "lightningcss-linux-arm64-gnu": "1.30.2", "lightningcss-linux-arm64-musl": "1.30.2", "lightningcss-linux-x64-gnu": "1.30.2", "lightningcss-linux-x64-musl": "1.30.2", "lightningcss-win32-arm64-msvc": "1.30.2", "lightningcss-win32-x64-msvc": "1.30.2" } }, "sha512-utfs7Pr5uJyyvDETitgsaqSyjCb2qNRAtuqUeWIAKztsOYdcACf2KtARYXg2pSvhkt+9NfoaNY7fxjl6nuMjIQ=="],
|
||||||
|
|
||||||
|
"lightningcss-android-arm64": ["lightningcss-android-arm64@1.30.2", "", { "os": "android", "cpu": "arm64" }, "sha512-BH9sEdOCahSgmkVhBLeU7Hc9DWeZ1Eb6wNS6Da8igvUwAe0sqROHddIlvU06q3WyXVEOYDZ6ykBZQnjTbmo4+A=="],
|
||||||
|
|
||||||
|
"lightningcss-darwin-arm64": ["lightningcss-darwin-arm64@1.30.2", "", { "os": "darwin", "cpu": "arm64" }, "sha512-ylTcDJBN3Hp21TdhRT5zBOIi73P6/W0qwvlFEk22fkdXchtNTOU4Qc37SkzV+EKYxLouZ6M4LG9NfZ1qkhhBWA=="],
|
||||||
|
|
||||||
|
"lightningcss-darwin-x64": ["lightningcss-darwin-x64@1.30.2", "", { "os": "darwin", "cpu": "x64" }, "sha512-oBZgKchomuDYxr7ilwLcyms6BCyLn0z8J0+ZZmfpjwg9fRVZIR5/GMXd7r9RH94iDhld3UmSjBM6nXWM2TfZTQ=="],
|
||||||
|
|
||||||
|
"lightningcss-freebsd-x64": ["lightningcss-freebsd-x64@1.30.2", "", { "os": "freebsd", "cpu": "x64" }, "sha512-c2bH6xTrf4BDpK8MoGG4Bd6zAMZDAXS569UxCAGcA7IKbHNMlhGQ89eRmvpIUGfKWNVdbhSbkQaWhEoMGmGslA=="],
|
||||||
|
|
||||||
|
"lightningcss-linux-arm-gnueabihf": ["lightningcss-linux-arm-gnueabihf@1.30.2", "", { "os": "linux", "cpu": "arm" }, "sha512-eVdpxh4wYcm0PofJIZVuYuLiqBIakQ9uFZmipf6LF/HRj5Bgm0eb3qL/mr1smyXIS1twwOxNWndd8z0E374hiA=="],
|
||||||
|
|
||||||
|
"lightningcss-linux-arm64-gnu": ["lightningcss-linux-arm64-gnu@1.30.2", "", { "os": "linux", "cpu": "arm64" }, "sha512-UK65WJAbwIJbiBFXpxrbTNArtfuznvxAJw4Q2ZGlU8kPeDIWEX1dg3rn2veBVUylA2Ezg89ktszWbaQnxD/e3A=="],
|
||||||
|
|
||||||
|
"lightningcss-linux-arm64-musl": ["lightningcss-linux-arm64-musl@1.30.2", "", { "os": "linux", "cpu": "arm64" }, "sha512-5Vh9dGeblpTxWHpOx8iauV02popZDsCYMPIgiuw97OJ5uaDsL86cnqSFs5LZkG3ghHoX5isLgWzMs+eD1YzrnA=="],
|
||||||
|
|
||||||
|
"lightningcss-linux-x64-gnu": ["lightningcss-linux-x64-gnu@1.30.2", "", { "os": "linux", "cpu": "x64" }, "sha512-Cfd46gdmj1vQ+lR6VRTTadNHu6ALuw2pKR9lYq4FnhvgBc4zWY1EtZcAc6EffShbb1MFrIPfLDXD6Xprbnni4w=="],
|
||||||
|
|
||||||
|
"lightningcss-linux-x64-musl": ["lightningcss-linux-x64-musl@1.30.2", "", { "os": "linux", "cpu": "x64" }, "sha512-XJaLUUFXb6/QG2lGIW6aIk6jKdtjtcffUT0NKvIqhSBY3hh9Ch+1LCeH80dR9q9LBjG3ewbDjnumefsLsP6aiA=="],
|
||||||
|
|
||||||
|
"lightningcss-win32-arm64-msvc": ["lightningcss-win32-arm64-msvc@1.30.2", "", { "os": "win32", "cpu": "arm64" }, "sha512-FZn+vaj7zLv//D/192WFFVA0RgHawIcHqLX9xuWiQt7P0PtdFEVaxgF9rjM/IRYHQXNnk61/H/gb2Ei+kUQ4xQ=="],
|
||||||
|
|
||||||
|
"lightningcss-win32-x64-msvc": ["lightningcss-win32-x64-msvc@1.30.2", "", { "os": "win32", "cpu": "x64" }, "sha512-5g1yc73p+iAkid5phb4oVFMB45417DkRevRbt/El/gKXJk4jid+vPFF/AXbxn05Aky8PapwzZrdJShv5C0avjw=="],
|
||||||
|
|
||||||
|
"lodash": ["lodash@4.17.21", "", {}, "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg=="],
|
||||||
|
|
||||||
|
"lru-cache": ["lru-cache@5.1.1", "", { "dependencies": { "yallist": "^3.0.2" } }, "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w=="],
|
||||||
|
|
||||||
|
"lucide-react": ["lucide-react@0.562.0", "", { "peerDependencies": { "react": "^16.5.1 || ^17.0.0 || ^18.0.0 || ^19.0.0" } }, "sha512-82hOAu7y0dbVuFfmO4bYF1XEwYk/mEbM5E+b1jgci/udUBEE/R7LF5Ip0CCEmXe8AybRM8L+04eP+LGZeDvkiw=="],
|
||||||
|
|
||||||
|
"magic-string": ["magic-string@0.30.21", "", { "dependencies": { "@jridgewell/sourcemap-codec": "^1.5.5" } }, "sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ=="],
|
||||||
|
|
||||||
|
"math-intrinsics": ["math-intrinsics@1.1.0", "", {}, "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g=="],
|
||||||
|
|
||||||
|
"mime-db": ["mime-db@1.52.0", "", {}, "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg=="],
|
||||||
|
|
||||||
|
"mime-types": ["mime-types@2.1.35", "", { "dependencies": { "mime-db": "1.52.0" } }, "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw=="],
|
||||||
|
|
||||||
|
"minimist": ["minimist@1.2.8", "", {}, "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA=="],
|
||||||
|
|
||||||
|
"minipass": ["minipass@5.0.0", "", {}, "sha512-3FnjYuehv9k6ovOEbyOswadCDPX1piCfhV8ncmYtHOjuPwylVWsghTLo7rabjC3Rx5xD4HDx8Wm1xnMF7S5qFQ=="],
|
||||||
|
|
||||||
|
"minizlib": ["minizlib@2.1.2", "", { "dependencies": { "minipass": "^3.0.0", "yallist": "^4.0.0" } }, "sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg=="],
|
||||||
|
|
||||||
|
"mkdirp": ["mkdirp@1.0.4", "", { "bin": "bin/cmd.js" }, "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw=="],
|
||||||
|
|
||||||
|
"mlly": ["mlly@1.8.0", "", { "dependencies": { "acorn": "^8.15.0", "pathe": "^2.0.3", "pkg-types": "^1.3.1", "ufo": "^1.6.1" } }, "sha512-l8D9ODSRWLe2KHJSifWGwBqpTZXIXTeo8mlKjY+E2HAakaTeNpqAyBZ8GSqLzHgw4XmHmC8whvpjJNMbFZN7/g=="],
|
||||||
|
|
||||||
|
"ms": ["ms@2.1.3", "", {}, "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA=="],
|
||||||
|
|
||||||
|
"nanoid": ["nanoid@3.3.11", "", { "bin": "bin/nanoid.cjs" }, "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w=="],
|
||||||
|
|
||||||
|
"neo-async": ["neo-async@2.6.2", "", {}, "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw=="],
|
||||||
|
|
||||||
|
"next-themes": ["next-themes@0.4.6", "", { "peerDependencies": { "react": "^16.8 || ^17 || ^18 || ^19 || ^19.0.0-rc", "react-dom": "^16.8 || ^17 || ^18 || ^19 || ^19.0.0-rc" } }, "sha512-pZvgD5L0IEvX5/9GWyHMf3m8BKiVQwsCMHfoFosXtXBMnaS0ZnIJ9ST4b4NqLVKDEm8QBxoNNGNaBv2JNF6XNA=="],
|
||||||
|
|
||||||
|
"node-fetch-native": ["node-fetch-native@1.6.7", "", {}, "sha512-g9yhqoedzIUm0nTnTqAQvueMPVOuIY16bqgAJJC8XOOubYFNwz6IER9qs0Gq2Xd0+CecCKFjtdDTMA4u4xG06Q=="],
|
||||||
|
|
||||||
|
"node-releases": ["node-releases@2.0.27", "", {}, "sha512-nmh3lCkYZ3grZvqcCH+fjmQ7X+H0OeZgP40OierEaAptX4XofMh5kwNbWh7lBduUzCcV/8kZ+NDLCwm2iorIlA=="],
|
||||||
|
|
||||||
|
"normalize-path": ["normalize-path@3.0.0", "", {}, "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA=="],
|
||||||
|
|
||||||
|
"nypm": ["nypm@0.5.4", "", { "dependencies": { "citty": "^0.1.6", "consola": "^3.4.0", "pathe": "^2.0.3", "pkg-types": "^1.3.1", "tinyexec": "^0.3.2", "ufo": "^1.5.4" }, "bin": "dist/cli.mjs" }, "sha512-X0SNNrZiGU8/e/zAB7sCTtdxWTMSIO73q+xuKgglm2Yvzwlo8UoC5FNySQFCvl84uPaeADkqHUZUkWy4aH4xOA=="],
|
||||||
|
|
||||||
|
"ohash": ["ohash@1.1.6", "", {}, "sha512-TBu7PtV8YkAZn0tSxobKY2n2aAQva936lhRrj6957aDaCf9IEtqsKbgMzXE/F/sjqYOwmrukeORHNLe5glk7Cg=="],
|
||||||
|
|
||||||
|
"open": ["open@10.1.2", "", { "dependencies": { "default-browser": "^5.2.1", "define-lazy-prop": "^3.0.0", "is-inside-container": "^1.0.0", "is-wsl": "^3.1.0" } }, "sha512-cxN6aIDPz6rm8hbebcP7vrQNhvRcveZoJU72Y7vskh4oIm+BZwBECnx5nTmrlres1Qapvx27Qo1Auukpf8PKXw=="],
|
||||||
|
|
||||||
|
"pathe": ["pathe@1.1.2", "", {}, "sha512-whLdWMYL2TwI08hn8/ZqAbrVemu0LNaNNJZX73O6qaIdCTfXutsLhMkjdENX0qhsQ9uIimo4/aQOmXkoon2nDQ=="],
|
||||||
|
|
||||||
|
"perfect-debounce": ["perfect-debounce@1.0.0", "", {}, "sha512-xCy9V055GLEqoFaHoC1SoLIaLmWctgCUaBaWxDZ7/Zx4CTyX7cJQLJOok/orfjZAh9kEYpjJa4d0KcJmCbctZA=="],
|
||||||
|
|
||||||
|
"picocolors": ["picocolors@1.1.1", "", {}, "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA=="],
|
||||||
|
|
||||||
|
"picomatch": ["picomatch@4.0.3", "", {}, "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q=="],
|
||||||
|
|
||||||
|
"pkg-types": ["pkg-types@1.3.1", "", { "dependencies": { "confbox": "^0.1.8", "mlly": "^1.7.4", "pathe": "^2.0.1" } }, "sha512-/Jm5M4RvtBFVkKWRu2BLUTNP8/M2a+UwuAX+ae4770q1qVGtfjG+WTCupoZixokjmHiry8uI+dlY8KXYV5HVVQ=="],
|
||||||
|
|
||||||
|
"playwright": ["playwright@1.57.0", "", { "dependencies": { "playwright-core": "1.57.0" }, "optionalDependencies": { "fsevents": "2.3.2" }, "bin": "cli.js" }, "sha512-ilYQj1s8sr2ppEJ2YVadYBN0Mb3mdo9J0wQ+UuDhzYqURwSoW4n1Xs5vs7ORwgDGmyEh33tRMeS8KhdkMoLXQw=="],
|
||||||
|
|
||||||
|
"playwright-core": ["playwright-core@1.57.0", "", { "bin": "cli.js" }, "sha512-agTcKlMw/mjBWOnD6kFZttAAGHgi/Nw0CZ2o6JqWSbMlI219lAFLZZCyqByTsvVAJq5XA5H8cA6PrvBRpBWEuQ=="],
|
||||||
|
|
||||||
|
"postcss": ["postcss@8.5.6", "", { "dependencies": { "nanoid": "^3.3.11", "picocolors": "^1.1.1", "source-map-js": "^1.2.1" } }, "sha512-3Ybi1tAuwAP9s0r1UQ2J4n5Y0G05bJkpUIO0/bI9MhwmD70S5aTWbXGBwxHrelT+XM1k6dM0pk+SwNkpTRN7Pg=="],
|
||||||
|
|
||||||
|
"prettier": ["prettier@3.8.0", "", { "bin": "bin/prettier.cjs" }, "sha512-yEPsovQfpxYfgWNhCfECjG5AQaO+K3dp6XERmOepyPDVqcJm+bjyCVO3pmU+nAPe0N5dDvekfGezt/EIiRe1TA=="],
|
||||||
|
|
||||||
|
"proxy-from-env": ["proxy-from-env@1.1.0", "", {}, "sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg=="],
|
||||||
|
|
||||||
|
"rc9": ["rc9@2.1.2", "", { "dependencies": { "defu": "^6.1.4", "destr": "^2.0.3" } }, "sha512-btXCnMmRIBINM2LDZoEmOogIZU7Qe7zn4BpomSKZ/ykbLObuBdvG+mFq11DL6fjH1DRwHhrlgtYWG96bJiC7Cg=="],
|
||||||
|
|
||||||
|
"react": ["react@19.2.3", "", {}, "sha512-Ku/hhYbVjOQnXDZFv2+RibmLFGwFdeeKHFcOTlrt7xplBnya5OGn/hIRDsqDiSUcfORsDC7MPxwork8jBwsIWA=="],
|
||||||
|
|
||||||
|
"react-dom": ["react-dom@19.2.3", "", { "dependencies": { "scheduler": "^0.27.0" }, "peerDependencies": { "react": "^19.2.3" } }, "sha512-yELu4WmLPw5Mr/lmeEpox5rw3RETacE++JgHqQzd2dg+YbJuat3jH4ingc+WPZhxaoFzdv9y33G+F7Nl5O0GBg=="],
|
||||||
|
|
||||||
|
"react-error-boundary": ["react-error-boundary@6.1.0", "", { "peerDependencies": { "react": "^18.0.0 || ^19.0.0" } }, "sha512-02k9WQ/mUhdbXir0tC1NiMesGzRPaCsJEWU/4bcFrbY1YMZOtHShtZP6zw0SJrBWA/31H0KT9/FgdL8+sPKgHA=="],
|
||||||
|
|
||||||
|
"react-hook-form": ["react-hook-form@7.71.1", "", { "peerDependencies": { "react": "^16.8.0 || ^17 || ^18 || ^19" } }, "sha512-9SUJKCGKo8HUSsCO+y0CtqkqI5nNuaDqTxyqPsZPqIwudpj4rCrAz/jZV+jn57bx5gtZKOh3neQu94DXMc+w5w=="],
|
||||||
|
|
||||||
|
"react-icons": ["react-icons@5.5.0", "", { "peerDependencies": { "react": "*" } }, "sha512-MEFcXdkP3dLo8uumGI5xN3lDFNsRtrjbOEKDLD7yv76v4wpnEq2Lt2qeHaQOr34I/wPN3s3+N08WkQ+CW37Xiw=="],
|
||||||
|
|
||||||
|
"react-remove-scroll": ["react-remove-scroll@2.7.2", "", { "dependencies": { "react-remove-scroll-bar": "^2.3.7", "react-style-singleton": "^2.2.3", "tslib": "^2.1.0", "use-callback-ref": "^1.3.3", "use-sidecar": "^1.1.3" }, "peerDependencies": { "@types/react": "*", "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc" } }, "sha512-Iqb9NjCCTt6Hf+vOdNIZGdTiH1QSqr27H/Ek9sv/a97gfueI/5h1s3yRi1nngzMUaOOToin5dI1dXKdXiF+u0Q=="],
|
||||||
|
|
||||||
|
"react-remove-scroll-bar": ["react-remove-scroll-bar@2.3.8", "", { "dependencies": { "react-style-singleton": "^2.2.2", "tslib": "^2.0.0" }, "peerDependencies": { "@types/react": "*", "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" } }, "sha512-9r+yi9+mgU33AKcj6IbT9oRCO78WriSj6t/cF8DWBZJ9aOGPOTEDvdUDz1FwKim7QXWwmHqtdHnRJfhAxEG46Q=="],
|
||||||
|
|
||||||
|
"react-style-singleton": ["react-style-singleton@2.2.3", "", { "dependencies": { "get-nonce": "^1.0.0", "tslib": "^2.0.0" }, "peerDependencies": { "@types/react": "*", "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc" } }, "sha512-b6jSvxvVnyptAiLjbkWLE/lOnR4lfTtDAl+eUC7RZy+QQWc6wRzIV2CE6xBuMmDxc2qIihtDCZD5NPOFl7fRBQ=="],
|
||||||
|
|
||||||
|
"readdirp": ["readdirp@3.6.0", "", { "dependencies": { "picomatch": "^2.2.1" } }, "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA=="],
|
||||||
|
|
||||||
|
"recast": ["recast@0.23.11", "", { "dependencies": { "ast-types": "^0.16.1", "esprima": "~4.0.0", "source-map": "~0.6.1", "tiny-invariant": "^1.3.3", "tslib": "^2.0.1" } }, "sha512-YTUo+Flmw4ZXiWfQKGcwwc11KnoRAYgzAE2E7mXKCjSviTKShtxBsN6YUUBB2gtaBzKzeKunxhUwNHQuRryhWA=="],
|
||||||
|
|
||||||
|
"resolve-pkg-maps": ["resolve-pkg-maps@1.0.0", "", {}, "sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw=="],
|
||||||
|
|
||||||
|
"rollup": ["rollup@4.55.2", "", { "dependencies": { "@types/estree": "1.0.8" }, "optionalDependencies": { "@rollup/rollup-android-arm-eabi": "4.55.2", "@rollup/rollup-android-arm64": "4.55.2", "@rollup/rollup-darwin-arm64": "4.55.2", "@rollup/rollup-darwin-x64": "4.55.2", "@rollup/rollup-freebsd-arm64": "4.55.2", "@rollup/rollup-freebsd-x64": "4.55.2", "@rollup/rollup-linux-arm-gnueabihf": "4.55.2", "@rollup/rollup-linux-arm-musleabihf": "4.55.2", "@rollup/rollup-linux-arm64-gnu": "4.55.2", "@rollup/rollup-linux-arm64-musl": "4.55.2", "@rollup/rollup-linux-loong64-gnu": "4.55.2", "@rollup/rollup-linux-loong64-musl": "4.55.2", "@rollup/rollup-linux-ppc64-gnu": "4.55.2", "@rollup/rollup-linux-ppc64-musl": "4.55.2", "@rollup/rollup-linux-riscv64-gnu": "4.55.2", "@rollup/rollup-linux-riscv64-musl": "4.55.2", "@rollup/rollup-linux-s390x-gnu": "4.55.2", "@rollup/rollup-linux-x64-gnu": "4.55.2", "@rollup/rollup-linux-x64-musl": "4.55.2", "@rollup/rollup-openbsd-x64": "4.55.2", "@rollup/rollup-openharmony-arm64": "4.55.2", "@rollup/rollup-win32-arm64-msvc": "4.55.2", "@rollup/rollup-win32-ia32-msvc": "4.55.2", "@rollup/rollup-win32-x64-gnu": "4.55.2", "@rollup/rollup-win32-x64-msvc": "4.55.2", "fsevents": "~2.3.2" }, "bin": "dist/bin/rollup" }, "sha512-PggGy4dhwx5qaW+CKBilA/98Ql9keyfnb7lh4SR6shQ91QQQi1ORJ1v4UinkdP2i87OBs9AQFooQylcrrRfIcg=="],
|
||||||
|
|
||||||
|
"run-applescript": ["run-applescript@7.1.0", "", {}, "sha512-DPe5pVFaAsinSaV6QjQ6gdiedWDcRCbUuiQfQa2wmWV7+xC9bGulGI8+TdRmoFkAPaBXk8CrAbnlY2ISniJ47Q=="],
|
||||||
|
|
||||||
|
"scheduler": ["scheduler@0.27.0", "", {}, "sha512-eNv+WrVbKu1f3vbYJT/xtiF5syA5HPIMtf9IgY/nKg0sWqzAUEvqY/xm7OcZc/qafLx/iO9FgOmeSAp4v5ti/Q=="],
|
||||||
|
|
||||||
|
"semver": ["semver@6.3.1", "", { "bin": "bin/semver.js" }, "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA=="],
|
||||||
|
|
||||||
|
"seroval": ["seroval@1.4.2", "", {}, "sha512-N3HEHRCZYn3cQbsC4B5ldj9j+tHdf4JZoYPlcI4rRYu0Xy4qN8MQf1Z08EibzB0WpgRG5BGK08FTrmM66eSzKQ=="],
|
||||||
|
|
||||||
|
"seroval-plugins": ["seroval-plugins@1.4.2", "", { "peerDependencies": { "seroval": "^1.0" } }, "sha512-X7p4MEDTi+60o2sXZ4bnDBhgsUYDSkQEvzYZuJyFqWg9jcoPsHts5nrg5O956py2wyt28lUrBxk0M0/wU8URpA=="],
|
||||||
|
|
||||||
|
"sonner": ["sonner@2.0.7", "", { "peerDependencies": { "react": "^18.0.0 || ^19.0.0 || ^19.0.0-rc", "react-dom": "^18.0.0 || ^19.0.0 || ^19.0.0-rc" } }, "sha512-W6ZN4p58k8aDKA4XPcx2hpIQXBRAgyiWVkYhT7CvK6D3iAu7xjvVyhQHg2/iaKJZ1XVJ4r7XuwGL+WGEK37i9w=="],
|
||||||
|
|
||||||
|
"source-map": ["source-map@0.6.1", "", {}, "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g=="],
|
||||||
|
|
||||||
|
"source-map-js": ["source-map-js@1.2.1", "", {}, "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA=="],
|
||||||
|
|
||||||
|
"tailwind-merge": ["tailwind-merge@3.4.0", "", {}, "sha512-uSaO4gnW+b3Y2aWoWfFpX62vn2sR3skfhbjsEnaBI81WD1wBLlHZe5sWf0AqjksNdYTbGBEd0UasQMT3SNV15g=="],
|
||||||
|
|
||||||
|
"tailwindcss": ["tailwindcss@4.1.18", "", {}, "sha512-4+Z+0yiYyEtUVCScyfHCxOYP06L5Ne+JiHhY2IjR2KWMIWhJOYZKLSGZaP5HkZ8+bY0cxfzwDE5uOmzFXyIwxw=="],
|
||||||
|
|
||||||
|
"tapable": ["tapable@2.3.0", "", {}, "sha512-g9ljZiwki/LfxmQADO3dEY1CbpmXT5Hm2fJ+QaGKwSXUylMybePR7/67YW7jOrrvjEgL1Fmz5kzyAjWVWLlucg=="],
|
||||||
|
|
||||||
|
"tar": ["tar@6.2.1", "", { "dependencies": { "chownr": "^2.0.0", "fs-minipass": "^2.0.0", "minipass": "^5.0.0", "minizlib": "^2.1.1", "mkdirp": "^1.0.3", "yallist": "^4.0.0" } }, "sha512-DZ4yORTwrbTj/7MZYq2w+/ZFdI6OZ/f9SFHR+71gIVUZhOQPHzVCLpvRnPgyaMpfWxxk/4ONva3GQSyNIKRv6A=="],
|
||||||
|
|
||||||
|
"tiny-invariant": ["tiny-invariant@1.3.3", "", {}, "sha512-+FbBPE1o9QAYvviau/qC5SE3caw21q3xkvWKBtja5vgqOWIHHJ3ioaq1VPfn/Szqctz2bU/oYeKd9/z5BL+PVg=="],
|
||||||
|
|
||||||
|
"tiny-warning": ["tiny-warning@1.0.3", "", {}, "sha512-lBN9zLN/oAf68o3zNXYrdCt1kP8WsiGW8Oo2ka41b2IM5JL/S1CTyX1rW0mb/zSuJun0ZUrDxx4sqvYS2FWzPA=="],
|
||||||
|
|
||||||
|
"tinyexec": ["tinyexec@0.3.2", "", {}, "sha512-KQQR9yN7R5+OSwaK0XQoj22pwHoTlgYqmUscPYoknOoWCWfj/5/ABTMRi69FrKU5ffPVh5QcFikpWJI/P1ocHA=="],
|
||||||
|
|
||||||
|
"tinyglobby": ["tinyglobby@0.2.15", "", { "dependencies": { "fdir": "^6.5.0", "picomatch": "^4.0.3" } }, "sha512-j2Zq4NyQYG5XMST4cbs02Ak8iJUdxRM0XI5QyxXuZOzKOINmWurp3smXu3y5wDcJrptwpSjgXHzIQxR0omXljQ=="],
|
||||||
|
|
||||||
|
"to-regex-range": ["to-regex-range@5.0.1", "", { "dependencies": { "is-number": "^7.0.0" } }, "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ=="],
|
||||||
|
|
||||||
|
"tslib": ["tslib@2.8.1", "", {}, "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w=="],
|
||||||
|
|
||||||
|
"tsx": ["tsx@4.21.0", "", { "dependencies": { "esbuild": "~0.27.0", "get-tsconfig": "^4.7.5" }, "optionalDependencies": { "fsevents": "~2.3.3" }, "bin": "dist/cli.mjs" }, "sha512-5C1sg4USs1lfG0GFb2RLXsdpXqBSEhAaA/0kPL01wxzpMqLILNxIxIOKiILz+cdg/pLnOUxFYOR5yhHU666wbw=="],
|
||||||
|
|
||||||
|
"tw-animate-css": ["tw-animate-css@1.4.0", "", {}, "sha512-7bziOlRqH0hJx80h/3mbicLW7o8qLsH5+RaLR2t+OHM3D0JlWGODQKQ4cxbK7WlvmUxpcj6Kgu6EKqjrGFe3QQ=="],
|
||||||
|
|
||||||
|
"typescript": ["typescript@5.9.3", "", { "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" } }, "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw=="],
|
||||||
|
|
||||||
|
"ufo": ["ufo@1.6.3", "", {}, "sha512-yDJTmhydvl5lJzBmy/hyOAA0d+aqCBuwl818haVdYCRrWV84o7YyeVm4QlVHStqNrrJSTb6jKuFAVqAFsr+K3Q=="],
|
||||||
|
|
||||||
|
"uglify-js": ["uglify-js@3.19.3", "", { "bin": { "uglifyjs": "bin/uglifyjs" } }, "sha512-v3Xu+yuwBXisp6QYTcH4UbH+xYJXqnq2m/LtQVWKWzYc1iehYnLixoQDN9FH6/j9/oybfd6W9Ghwkl8+UMKTKQ=="],
|
||||||
|
|
||||||
|
"undici-types": ["undici-types@7.16.0", "", {}, "sha512-Zz+aZWSj8LE6zoxD+xrjh4VfkIG8Ya6LvYkZqtUQGJPZjYl53ypCaUwWqo7eI0x66KBGeRo+mlBEkMSeSZ38Nw=="],
|
||||||
|
|
||||||
|
"unplugin": ["unplugin@2.3.11", "", { "dependencies": { "@jridgewell/remapping": "^2.3.5", "acorn": "^8.15.0", "picomatch": "^4.0.3", "webpack-virtual-modules": "^0.6.2" } }, "sha512-5uKD0nqiYVzlmCRs01Fhs2BdkEgBS3SAVP6ndrBsuK42iC2+JHyxM05Rm9G8+5mkmRtzMZGY8Ct5+mliZxU/Ww=="],
|
||||||
|
|
||||||
|
"update-browserslist-db": ["update-browserslist-db@1.2.3", "", { "dependencies": { "escalade": "^3.2.0", "picocolors": "^1.1.1" }, "peerDependencies": { "browserslist": ">= 4.21.0" }, "bin": "cli.js" }, "sha512-Js0m9cx+qOgDxo0eMiFGEueWztz+d4+M3rGlmKPT+T4IS/jP4ylw3Nwpu6cpTTP8R1MAC1kF4VbdLt3ARf209w=="],
|
||||||
|
|
||||||
|
"use-callback-ref": ["use-callback-ref@1.3.3", "", { "dependencies": { "tslib": "^2.0.0" }, "peerDependencies": { "@types/react": "*", "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc" } }, "sha512-jQL3lRnocaFtu3V00JToYz/4QkNWswxijDaCVNZRiRTO3HQDLsdu1ZtmIUvV4yPp+rvWm5j0y0TG/S61cuijTg=="],
|
||||||
|
|
||||||
|
"use-sidecar": ["use-sidecar@1.1.3", "", { "dependencies": { "detect-node-es": "^1.1.0", "tslib": "^2.0.0" }, "peerDependencies": { "@types/react": "*", "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc" } }, "sha512-Fedw0aZvkhynoPYlA5WXrMCAMm+nSWdZt6lzJQ7Ok8S6Q+VsHmHpRWndVRJ8Be0ZbkfPc5LRYH+5XrzXcEeLRQ=="],
|
||||||
|
|
||||||
|
"use-sync-external-store": ["use-sync-external-store@1.6.0", "", { "peerDependencies": { "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" } }, "sha512-Pp6GSwGP/NrPIrxVFAIkOQeyw8lFenOHijQWkUTrDvrF4ALqylP2C/KCkeS9dpUM3KvYRQhna5vt7IL95+ZQ9w=="],
|
||||||
|
|
||||||
|
"vite": ["vite@7.3.1", "", { "dependencies": { "esbuild": "^0.27.0", "fdir": "^6.5.0", "picomatch": "^4.0.3", "postcss": "^8.5.6", "rollup": "^4.43.0", "tinyglobby": "^0.2.15" }, "optionalDependencies": { "fsevents": "~2.3.3" }, "peerDependencies": { "@types/node": "^20.19.0 || >=22.12.0", "jiti": ">=1.21.0", "less": "^4.0.0", "lightningcss": "^1.21.0", "sass": "^1.70.0", "sass-embedded": "^1.70.0", "stylus": ">=0.54.8", "sugarss": "^5.0.0", "terser": "^5.16.0", "tsx": "^4.8.1", "yaml": "^2.4.2" }, "optionalPeers": ["less", "sass", "sass-embedded", "stylus", "sugarss", "terser", "yaml"], "bin": "bin/vite.js" }, "sha512-w+N7Hifpc3gRjZ63vYBXA56dvvRlNWRczTdmCBBa+CotUzAPf5b7YMdMR/8CQoeYE5LX3W4wj6RYTgonm1b9DA=="],
|
||||||
|
|
||||||
|
"webpack-virtual-modules": ["webpack-virtual-modules@0.6.2", "", {}, "sha512-66/V2i5hQanC51vBQKPH4aI8NMAcBW59FVBs+rC7eGHupMyfn34q7rZIE+ETlJ+XTevqfUhVVBgSUNSW2flEUQ=="],
|
||||||
|
|
||||||
|
"wordwrap": ["wordwrap@1.0.0", "", {}, "sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q=="],
|
||||||
|
|
||||||
|
"yallist": ["yallist@4.0.0", "", {}, "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A=="],
|
||||||
|
|
||||||
|
"zod": ["zod@4.3.5", "", {}, "sha512-k7Nwx6vuWx1IJ9Bjuf4Zt1PEllcwe7cls3VNzm4CQ1/hgtFUK2bRNG3rvnpPUhFjmqJKAKtjV576KnUkHocg/g=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-arrow/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-checkbox/@radix-ui/react-context": ["@radix-ui/react-context@1.1.2", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-checkbox/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-collection/@radix-ui/react-context": ["@radix-ui/react-context@1.1.2", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-collection/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-collection/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-dialog/@radix-ui/react-context": ["@radix-ui/react-context@1.1.2", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-dialog/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-dialog/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-dismissable-layer/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-dropdown-menu/@radix-ui/react-context": ["@radix-ui/react-context@1.1.2", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-dropdown-menu/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-focus-scope/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-menu/@radix-ui/react-context": ["@radix-ui/react-context@1.1.2", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-menu/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-menu/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-popper/@radix-ui/react-context": ["@radix-ui/react-context@1.1.2", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-popper/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-portal/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-radio-group/@radix-ui/react-context": ["@radix-ui/react-context@1.1.2", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-radio-group/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-roving-focus/@radix-ui/react-context": ["@radix-ui/react-context@1.1.2", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-roving-focus/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-scroll-area/@radix-ui/react-context": ["@radix-ui/react-context@1.1.2", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-scroll-area/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-select/@radix-ui/react-context": ["@radix-ui/react-context@1.1.2", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-select/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-select/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-tabs/@radix-ui/react-context": ["@radix-ui/react-context@1.1.2", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-tabs/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-tooltip/@radix-ui/react-context": ["@radix-ui/react-context@1.1.2", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-tooltip/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-tooltip/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-visually-hidden/@radix-ui/react-primitive": ["@radix-ui/react-primitive@2.1.3", "", { "dependencies": { "@radix-ui/react-slot": "1.2.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ=="],
|
||||||
|
|
||||||
|
"@tanstack/router-generator/source-map": ["source-map@0.7.6", "", {}, "sha512-i5uvt8C3ikiWeNZSVZNWcfZPItFQOsYTUAOkcUPGd8DqDy1uOUikjt5dG+uRlwyvR108Fb9DOd4GvXfT0N2/uQ=="],
|
||||||
|
|
||||||
|
"@tanstack/router-generator/zod": ["zod@3.25.76", "", {}, "sha512-gzUt/qt81nXsFGKIFcC3YnfEAx5NkunCfnDlvuBSSFS02bcXu4Lmea0AFIUwbLWxWPx3d9p8S5QoaujKcNQxcQ=="],
|
||||||
|
|
||||||
|
"@tanstack/router-plugin/zod": ["zod@3.25.76", "", {}, "sha512-gzUt/qt81nXsFGKIFcC3YnfEAx5NkunCfnDlvuBSSFS02bcXu4Lmea0AFIUwbLWxWPx3d9p8S5QoaujKcNQxcQ=="],
|
||||||
|
|
||||||
|
"@tanstack/router-utils/pathe": ["pathe@2.0.3", "", {}, "sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w=="],
|
||||||
|
|
||||||
|
"anymatch/picomatch": ["picomatch@2.3.1", "", {}, "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA=="],
|
||||||
|
|
||||||
|
"c12/chokidar": ["chokidar@4.0.3", "", { "dependencies": { "readdirp": "^4.0.1" } }, "sha512-Qgzu8kfBvo+cA4962jnP1KkS6Dop5NS6g7R5LFYJr4b8Ub94PPQXUksCw9PvXoeXPRRddRNC5C1JQUR2SMGtnA=="],
|
||||||
|
|
||||||
|
"c12/dotenv": ["dotenv@16.6.1", "", {}, "sha512-uBq4egWHTcTt33a72vpSG0z3HnPuIl6NqYcTrKEg2azoEyl2hpW0zqlxysq2pK9HlDIHyHyakeYaYnSAwd8bow=="],
|
||||||
|
|
||||||
|
"fs-minipass/minipass": ["minipass@3.3.6", "", { "dependencies": { "yallist": "^4.0.0" } }, "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw=="],
|
||||||
|
|
||||||
|
"giget/pathe": ["pathe@2.0.3", "", {}, "sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w=="],
|
||||||
|
|
||||||
|
"lru-cache/yallist": ["yallist@3.1.1", "", {}, "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g=="],
|
||||||
|
|
||||||
|
"minizlib/minipass": ["minipass@3.3.6", "", { "dependencies": { "yallist": "^4.0.0" } }, "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw=="],
|
||||||
|
|
||||||
|
"mlly/pathe": ["pathe@2.0.3", "", {}, "sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w=="],
|
||||||
|
|
||||||
|
"nypm/pathe": ["pathe@2.0.3", "", {}, "sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w=="],
|
||||||
|
|
||||||
|
"pkg-types/pathe": ["pathe@2.0.3", "", {}, "sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w=="],
|
||||||
|
|
||||||
|
"playwright/fsevents": ["fsevents@2.3.2", "", { "os": "darwin" }, "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA=="],
|
||||||
|
|
||||||
|
"readdirp/picomatch": ["picomatch@2.3.1", "", {}, "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-arrow/@radix-ui/react-primitive/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-checkbox/@radix-ui/react-primitive/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-dismissable-layer/@radix-ui/react-primitive/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-dropdown-menu/@radix-ui/react-primitive/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-focus-scope/@radix-ui/react-primitive/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-popper/@radix-ui/react-primitive/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-portal/@radix-ui/react-primitive/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-radio-group/@radix-ui/react-primitive/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-roving-focus/@radix-ui/react-primitive/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-scroll-area/@radix-ui/react-primitive/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-tabs/@radix-ui/react-primitive/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"@radix-ui/react-visually-hidden/@radix-ui/react-primitive/@radix-ui/react-slot": ["@radix-ui/react-slot@1.2.3", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" } }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],
|
||||||
|
|
||||||
|
"c12/chokidar/readdirp": ["readdirp@4.1.2", "", {}, "sha512-GDhwkLfywWL2s6vEjyhri+eXmfH6j1L7JE27WhqLeYzoh/A3DBaYGEj2H/HFZCn/kMfim73FXxEJTw06WtxQwg=="],
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,13 +1,18 @@
|
|||||||
services:
|
services:
|
||||||
|
|
||||||
|
# Local services are available on their ports, but also available on:
|
||||||
|
# http://api.localhost.tiangolo.com: backend
|
||||||
|
# http://dashboard.localhost.tiangolo.com: frontend
|
||||||
|
# etc. To enable it, update .env, set:
|
||||||
|
# DOMAIN=localhost.tiangolo.com
|
||||||
proxy:
|
proxy:
|
||||||
image: traefik:3.0
|
image: traefik:3.6
|
||||||
volumes:
|
volumes:
|
||||||
- /var/run/docker.sock:/var/run/docker.sock
|
- /var/run/docker.sock:/var/run/docker.sock
|
||||||
ports:
|
ports:
|
||||||
- "80:80"
|
- "80:80"
|
||||||
- "8090:8080"
|
- "8090:8080"
|
||||||
# Duplicate the command from docker-compose.yml to add --api.insecure=true
|
# Duplicate the command from compose.yml to add --api.insecure=true
|
||||||
command:
|
command:
|
||||||
# Enable Docker in Traefik, so that it reads labels from Docker services
|
# Enable Docker in Traefik, so that it reads labels from Docker services
|
||||||
- --providers.docker
|
- --providers.docker
|
||||||
@@ -53,15 +58,29 @@ services:
|
|||||||
backend:
|
backend:
|
||||||
restart: "no"
|
restart: "no"
|
||||||
ports:
|
ports:
|
||||||
- "8888:8888"
|
- "8000:8000"
|
||||||
volumes:
|
|
||||||
- ./backend/:/app
|
|
||||||
build:
|
build:
|
||||||
context: ./backend
|
context: .
|
||||||
args:
|
dockerfile: backend/Dockerfile
|
||||||
INSTALL_DEV: ${INSTALL_DEV-true}
|
|
||||||
# command: sleep infinity # Infinite loop to keep container alive doing nothing
|
# command: sleep infinity # Infinite loop to keep container alive doing nothing
|
||||||
command: /start-reload.sh
|
command:
|
||||||
|
- fastapi
|
||||||
|
- run
|
||||||
|
- --reload
|
||||||
|
- "app/main.py"
|
||||||
|
develop:
|
||||||
|
watch:
|
||||||
|
- path: ./backend
|
||||||
|
action: sync
|
||||||
|
target: /app/backend
|
||||||
|
ignore:
|
||||||
|
- ./backend/.venv
|
||||||
|
- .venv
|
||||||
|
- path: ./backend/pyproject.toml
|
||||||
|
action: rebuild
|
||||||
|
# TODO: remove once coverage is done locally
|
||||||
|
volumes:
|
||||||
|
- ./backend/htmlcov:/app/backend/htmlcov
|
||||||
environment:
|
environment:
|
||||||
SMTP_HOST: "mailcatcher"
|
SMTP_HOST: "mailcatcher"
|
||||||
SMTP_PORT: "1025"
|
SMTP_PORT: "1025"
|
||||||
@@ -76,12 +95,40 @@ services:
|
|||||||
|
|
||||||
frontend:
|
frontend:
|
||||||
restart: "no"
|
restart: "no"
|
||||||
|
ports:
|
||||||
|
- "5173:80"
|
||||||
build:
|
build:
|
||||||
context: ./frontend
|
context: .
|
||||||
|
dockerfile: frontend/Dockerfile
|
||||||
args:
|
args:
|
||||||
- VITE_API_URL=http://${DOMAIN?Variable not set}
|
- VITE_API_URL=http://localhost:8000
|
||||||
- NODE_ENV=development
|
- NODE_ENV=development
|
||||||
|
|
||||||
|
playwright:
|
||||||
|
build:
|
||||||
|
context: .
|
||||||
|
dockerfile: frontend/Dockerfile.playwright
|
||||||
|
args:
|
||||||
|
- VITE_API_URL=http://backend:8000
|
||||||
|
- NODE_ENV=production
|
||||||
|
ipc: host
|
||||||
|
depends_on:
|
||||||
|
- backend
|
||||||
|
- mailcatcher
|
||||||
|
env_file:
|
||||||
|
- .env
|
||||||
|
environment:
|
||||||
|
- VITE_API_URL=http://backend:8000
|
||||||
|
- MAILCATCHER_HOST=http://mailcatcher:1080
|
||||||
|
# For the reports when run locally
|
||||||
|
- PLAYWRIGHT_HTML_HOST=0.0.0.0
|
||||||
|
- CI=${CI}
|
||||||
|
volumes:
|
||||||
|
- ./frontend/blob-report:/app/frontend/blob-report
|
||||||
|
- ./frontend/test-results:/app/frontend/test-results
|
||||||
|
ports:
|
||||||
|
- 9323:9323
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
traefik-public:
|
traefik-public:
|
||||||
# For local dev, don't expect an external Traefik network
|
# For local dev, don't expect an external Traefik network
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
services:
|
services:
|
||||||
traefik:
|
traefik:
|
||||||
image: traefik:3.0
|
image: traefik:3.6
|
||||||
ports:
|
ports:
|
||||||
# Listen on port 80, default for HTTP, necessary to redirect to HTTPS
|
# Listen on port 80, default for HTTP, necessary to redirect to HTTPS
|
||||||
- 80:80
|
- 80:80
|
||||||
@@ -1,7 +1,14 @@
|
|||||||
services:
|
services:
|
||||||
|
|
||||||
db:
|
db:
|
||||||
image: postgres:12
|
image: postgres:18
|
||||||
restart: always
|
restart: always
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER} -d ${POSTGRES_DB}"]
|
||||||
|
interval: 10s
|
||||||
|
retries: 5
|
||||||
|
start_period: 30s
|
||||||
|
timeout: 10s
|
||||||
volumes:
|
volumes:
|
||||||
- app-db-data:/var/lib/postgresql/data/pgdata
|
- app-db-data:/var/lib/postgresql/data/pgdata
|
||||||
env_file:
|
env_file:
|
||||||
@@ -35,18 +42,24 @@ services:
|
|||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-adminer-https.tls.certresolver=le
|
- traefik.http.routers.${STACK_NAME?Variable not set}-adminer-https.tls.certresolver=le
|
||||||
- traefik.http.services.${STACK_NAME?Variable not set}-adminer.loadbalancer.server.port=8080
|
- traefik.http.services.${STACK_NAME?Variable not set}-adminer.loadbalancer.server.port=8080
|
||||||
|
|
||||||
backend:
|
prestart:
|
||||||
image: '${DOCKER_IMAGE_BACKEND?Variable not set}:${TAG-latest}'
|
image: '${DOCKER_IMAGE_BACKEND?Variable not set}:${TAG-latest}'
|
||||||
restart: always
|
build:
|
||||||
|
context: .
|
||||||
|
dockerfile: backend/Dockerfile
|
||||||
networks:
|
networks:
|
||||||
- traefik-public
|
- traefik-public
|
||||||
- default
|
- default
|
||||||
depends_on:
|
depends_on:
|
||||||
- db
|
db:
|
||||||
|
condition: service_healthy
|
||||||
|
restart: true
|
||||||
|
command: bash scripts/prestart.sh
|
||||||
env_file:
|
env_file:
|
||||||
- .env
|
- .env
|
||||||
environment:
|
environment:
|
||||||
- DOMAIN=${DOMAIN}
|
- DOMAIN=${DOMAIN}
|
||||||
|
- FRONTEND_HOST=${FRONTEND_HOST?Variable not set}
|
||||||
- ENVIRONMENT=${ENVIRONMENT}
|
- ENVIRONMENT=${ENVIRONMENT}
|
||||||
- BACKEND_CORS_ORIGINS=${BACKEND_CORS_ORIGINS}
|
- BACKEND_CORS_ORIGINS=${BACKEND_CORS_ORIGINS}
|
||||||
- SECRET_KEY=${SECRET_KEY?Variable not set}
|
- SECRET_KEY=${SECRET_KEY?Variable not set}
|
||||||
@@ -63,34 +76,65 @@ services:
|
|||||||
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD?Variable not set}
|
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD?Variable not set}
|
||||||
- SENTRY_DSN=${SENTRY_DSN}
|
- SENTRY_DSN=${SENTRY_DSN}
|
||||||
|
|
||||||
|
backend:
|
||||||
|
image: '${DOCKER_IMAGE_BACKEND?Variable not set}:${TAG-latest}'
|
||||||
|
restart: always
|
||||||
|
networks:
|
||||||
|
- traefik-public
|
||||||
|
- default
|
||||||
|
depends_on:
|
||||||
|
db:
|
||||||
|
condition: service_healthy
|
||||||
|
restart: true
|
||||||
|
prestart:
|
||||||
|
condition: service_completed_successfully
|
||||||
|
env_file:
|
||||||
|
- .env
|
||||||
|
environment:
|
||||||
|
- DOMAIN=${DOMAIN}
|
||||||
|
- FRONTEND_HOST=${FRONTEND_HOST?Variable not set}
|
||||||
|
- ENVIRONMENT=${ENVIRONMENT}
|
||||||
|
- BACKEND_CORS_ORIGINS=${BACKEND_CORS_ORIGINS}
|
||||||
|
- SECRET_KEY=${SECRET_KEY?Variable not set}
|
||||||
|
- FIRST_SUPERUSER=${FIRST_SUPERUSER?Variable not set}
|
||||||
|
- FIRST_SUPERUSER_PASSWORD=${FIRST_SUPERUSER_PASSWORD?Variable not set}
|
||||||
|
- SMTP_HOST=${SMTP_HOST}
|
||||||
|
- SMTP_USER=${SMTP_USER}
|
||||||
|
- SMTP_PASSWORD=${SMTP_PASSWORD}
|
||||||
|
- EMAILS_FROM_EMAIL=${EMAILS_FROM_EMAIL}
|
||||||
|
- POSTGRES_SERVER=db
|
||||||
|
- POSTGRES_PORT=${POSTGRES_PORT}
|
||||||
|
- POSTGRES_DB=${POSTGRES_DB}
|
||||||
|
- POSTGRES_USER=${POSTGRES_USER?Variable not set}
|
||||||
|
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD?Variable not set}
|
||||||
|
- SENTRY_DSN=${SENTRY_DSN}
|
||||||
|
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD", "curl", "-f", "http://localhost:8000/api/v1/utils/health-check/"]
|
||||||
|
interval: 10s
|
||||||
|
timeout: 5s
|
||||||
|
retries: 5
|
||||||
|
|
||||||
build:
|
build:
|
||||||
context: ./backend
|
context: .
|
||||||
args:
|
dockerfile: backend/Dockerfile
|
||||||
INSTALL_DEV: ${INSTALL_DEV-false}
|
|
||||||
platform: linux/amd64 # Patch for M1 Mac
|
|
||||||
labels:
|
labels:
|
||||||
- traefik.enable=true
|
- traefik.enable=true
|
||||||
- traefik.docker.network=traefik-public
|
- traefik.docker.network=traefik-public
|
||||||
- traefik.constraint-label=traefik-public
|
- traefik.constraint-label=traefik-public
|
||||||
|
|
||||||
- traefik.http.services.${STACK_NAME?Variable not set}-backend.loadbalancer.server.port=80
|
- traefik.http.services.${STACK_NAME?Variable not set}-backend.loadbalancer.server.port=8000
|
||||||
|
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-http.rule=(Host(`${DOMAIN?Variable not set}`) || Host(`www.${DOMAIN?Variable not set}`)) && (PathPrefix(`/api`) || PathPrefix(`/docs`) || PathPrefix(`/redoc`))
|
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-http.rule=Host(`api.${DOMAIN?Variable not set}`)
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-http.entrypoints=http
|
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-http.entrypoints=http
|
||||||
|
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-https.rule=(Host(`${DOMAIN?Variable not set}`) || Host(`www.${DOMAIN?Variable not set}`)) && (PathPrefix(`/api`) || PathPrefix(`/docs`) || PathPrefix(`/redoc`))
|
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-https.rule=Host(`api.${DOMAIN?Variable not set}`)
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-https.entrypoints=https
|
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-https.entrypoints=https
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-https.tls=true
|
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-https.tls=true
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-https.tls.certresolver=le
|
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-https.tls.certresolver=le
|
||||||
|
|
||||||
# Define Traefik Middleware to handle domain with and without "www" to redirect to only one
|
# Enable redirection for HTTP and HTTPS
|
||||||
- traefik.http.middlewares.${STACK_NAME?Variable not set}-www-redirect.redirectregex.regex=^http(s)?://www.(${DOMAIN?Variable not set})/(.*)
|
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-http.middlewares=https-redirect
|
||||||
# Redirect a domain with www to non-www
|
|
||||||
- traefik.http.middlewares.${STACK_NAME?Variable not set}-www-redirect.redirectregex.replacement=http$${1}://${DOMAIN?Variable not set}/$${3}
|
|
||||||
|
|
||||||
# Enable www redirection for HTTP and HTTPS
|
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-http.middlewares=https-redirect,${STACK_NAME?Variable not set}-www-redirect
|
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-backend-https.middlewares=${STACK_NAME?Variable not set}-www-redirect
|
|
||||||
|
|
||||||
frontend:
|
frontend:
|
||||||
image: '${DOCKER_IMAGE_FRONTEND?Variable not set}:${TAG-latest}'
|
image: '${DOCKER_IMAGE_FRONTEND?Variable not set}:${TAG-latest}'
|
||||||
@@ -99,9 +143,10 @@ services:
|
|||||||
- traefik-public
|
- traefik-public
|
||||||
- default
|
- default
|
||||||
build:
|
build:
|
||||||
context: ./frontend
|
context: .
|
||||||
|
dockerfile: frontend/Dockerfile
|
||||||
args:
|
args:
|
||||||
- VITE_API_URL=https://${DOMAIN?Variable not set}
|
- VITE_API_URL=https://api.${DOMAIN?Variable not set}
|
||||||
- NODE_ENV=production
|
- NODE_ENV=production
|
||||||
labels:
|
labels:
|
||||||
- traefik.enable=true
|
- traefik.enable=true
|
||||||
@@ -110,17 +155,16 @@ services:
|
|||||||
|
|
||||||
- traefik.http.services.${STACK_NAME?Variable not set}-frontend.loadbalancer.server.port=80
|
- traefik.http.services.${STACK_NAME?Variable not set}-frontend.loadbalancer.server.port=80
|
||||||
|
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-http.rule=Host(`${DOMAIN?Variable not set}`) || Host(`www.${DOMAIN?Variable not set}`)
|
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-http.rule=Host(`dashboard.${DOMAIN?Variable not set}`)
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-http.entrypoints=http
|
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-http.entrypoints=http
|
||||||
|
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.rule=Host(`${DOMAIN?Variable not set}`) || Host(`www.${DOMAIN?Variable not set}`)
|
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.rule=Host(`dashboard.${DOMAIN?Variable not set}`)
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.entrypoints=https
|
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.entrypoints=https
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.tls=true
|
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.tls=true
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.tls.certresolver=le
|
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.tls.certresolver=le
|
||||||
|
|
||||||
# Enable www redirection for HTTP and HTTPS
|
# Enable redirection for HTTP and HTTPS
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-https.middlewares=${STACK_NAME?Variable not set}-www-redirect
|
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-http.middlewares=https-redirect
|
||||||
- traefik.http.routers.${STACK_NAME?Variable not set}-frontend-http.middlewares=https-redirect,${STACK_NAME?Variable not set}-www-redirect
|
|
||||||
volumes:
|
volumes:
|
||||||
app-db-data:
|
app-db-data:
|
||||||
|
|
||||||
+1
-3
@@ -63,7 +63,6 @@ _exclude:
|
|||||||
# Global
|
# Global
|
||||||
- .vscode
|
- .vscode
|
||||||
- .mypy_cache
|
- .mypy_cache
|
||||||
- poetry.lock
|
|
||||||
# Python
|
# Python
|
||||||
- __pycache__
|
- __pycache__
|
||||||
- app.egg-info
|
- app.egg-info
|
||||||
@@ -71,7 +70,6 @@ _exclude:
|
|||||||
- .mypy_cache
|
- .mypy_cache
|
||||||
- .coverage
|
- .coverage
|
||||||
- htmlcov
|
- htmlcov
|
||||||
- poetry.lock
|
|
||||||
- .cache
|
- .cache
|
||||||
- .venv
|
- .venv
|
||||||
# Frontend
|
# Frontend
|
||||||
@@ -99,4 +97,4 @@ _exclude:
|
|||||||
_answers_file: .copier/.copier-answers.yml
|
_answers_file: .copier/.copier-answers.yml
|
||||||
|
|
||||||
_tasks:
|
_tasks:
|
||||||
- "python .copier/update_dotenv.py"
|
- ["{{ _copier_python }}", .copier/update_dotenv.py]
|
||||||
|
|||||||
+97
-56
@@ -12,7 +12,7 @@ But you have to configure a couple things first. 🤓
|
|||||||
|
|
||||||
* Have a remote server ready and available.
|
* Have a remote server ready and available.
|
||||||
* Configure the DNS records of your domain to point to the IP of the server you just created.
|
* Configure the DNS records of your domain to point to the IP of the server you just created.
|
||||||
* Configure a wildcard subdomain for your domain, so that you can have multiple subdomains for different services, e.g. `*.fastapi-project.example.com`. This will be useful for accessing different components, like `traefik.fastapi-project.example.com`, `adminer.fastapi-project.example.com`, etc. And also for `staging`, like `staging.fastapi-project.example.com`, `staging.adminer.fastapi-project.example.com`, etc.
|
* Configure a wildcard subdomain for your domain, so that you can have multiple subdomains for different services, e.g. `*.fastapi-project.example.com`. This will be useful for accessing different components, like `dashboard.fastapi-project.example.com`, `api.fastapi-project.example.com`, `traefik.fastapi-project.example.com`, `adminer.fastapi-project.example.com`, etc. And also for `staging`, like `dashboard.staging.fastapi-project.example.com`, `adminer.staging.fastapi-project.example.com`, etc.
|
||||||
* Install and configure [Docker](https://docs.docker.com/engine/install/) on the remote server (Docker Engine, not Docker Desktop).
|
* Install and configure [Docker](https://docs.docker.com/engine/install/) on the remote server (Docker Engine, not Docker Desktop).
|
||||||
|
|
||||||
## Public Traefik
|
## Public Traefik
|
||||||
@@ -32,7 +32,7 @@ mkdir -p /root/code/traefik-public/
|
|||||||
Copy the Traefik Docker Compose file to your server. You could do it by running the command `rsync` in your local terminal:
|
Copy the Traefik Docker Compose file to your server. You could do it by running the command `rsync` in your local terminal:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
rsync -a docker-compose.traefik.yml root@your-server.example.com:/root/code/traefik-public/
|
rsync -a compose.traefik.yml root@your-server.example.com:/root/code/traefik-public/
|
||||||
```
|
```
|
||||||
|
|
||||||
### Traefik Public Network
|
### Traefik Public Network
|
||||||
@@ -97,10 +97,10 @@ Go to the directory where you copied the Traefik Docker Compose file in your rem
|
|||||||
cd /root/code/traefik-public/
|
cd /root/code/traefik-public/
|
||||||
```
|
```
|
||||||
|
|
||||||
Now with the environment variables set and the `docker-compose.traefik.yml` in place, you can start the Traefik Docker Compose running the following command:
|
Now with the environment variables set and the `compose.traefik.yml` in place, you can start the Traefik Docker Compose running the following command:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker compose -f docker-compose.traefik.yml up -d
|
docker compose -f compose.traefik.yml up -d
|
||||||
```
|
```
|
||||||
|
|
||||||
## Deploy the FastAPI Project
|
## Deploy the FastAPI Project
|
||||||
@@ -109,48 +109,18 @@ Now that you have Traefik in place you can deploy your FastAPI project with Dock
|
|||||||
|
|
||||||
**Note**: You might want to jump ahead to the section about Continuous Deployment with GitHub Actions.
|
**Note**: You might want to jump ahead to the section about Continuous Deployment with GitHub Actions.
|
||||||
|
|
||||||
|
## Copy the Code
|
||||||
|
|
||||||
|
```bash
|
||||||
|
rsync -av --filter=":- .gitignore" ./ root@your-server.example.com:/root/code/app/
|
||||||
|
```
|
||||||
|
|
||||||
|
Note: `--filter=":- .gitignore"` tells `rsync` to use the same rules as git, ignore files ignored by git, like the Python virtual environment.
|
||||||
|
|
||||||
## Environment Variables
|
## Environment Variables
|
||||||
|
|
||||||
You need to set some environment variables first.
|
You need to set some environment variables first.
|
||||||
|
|
||||||
Set the `ENVIRONMENT`, by default `local` (for development), but when deploying to a server you would put something like `staging` or `production`:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
export ENVIRONMENT=production
|
|
||||||
```
|
|
||||||
|
|
||||||
Set the `DOMAIN`, by default `localhost` (for development), but when deploying you would use your own domain, for example:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
export DOMAIN=fastapi-project.example.com
|
|
||||||
```
|
|
||||||
|
|
||||||
You can set several variables, like:
|
|
||||||
|
|
||||||
* `PROJECT_NAME`: The name of the project, used in the API for the docs and emails.
|
|
||||||
* `STACK_NAME`: The name of the stack used for Docker Compose labels and project name, this should be different for `staging`, `production`, etc. You could use the same domain replacing dots with dashes, e.g. `fastapi-project-example-com` and `staging-fastapi-project-example-com`.
|
|
||||||
* `BACKEND_CORS_ORIGINS`: A list of allowed CORS origins separated by commas.
|
|
||||||
* `SECRET_KEY`: The secret key for the FastAPI project, used to sign tokens.
|
|
||||||
* `FIRST_SUPERUSER`: The email of the first superuser, this superuser will be the one that can create new users.
|
|
||||||
* `FIRST_SUPERUSER_PASSWORD`: The password of the first superuser.
|
|
||||||
* `SMTP_HOST`: The SMTP server host to send emails, this would come from your email provider (E.g. Mailgun, Sparkpost, Sendgrid, etc).
|
|
||||||
* `SMTP_USER`: The SMTP server user to send emails.
|
|
||||||
* `SMTP_PASSWORD`: The SMTP server password to send emails.
|
|
||||||
* `EMAILS_FROM_EMAIL`: The email account to send emails from.
|
|
||||||
* `POSTGRES_SERVER`: The hostname of the PostgreSQL server. You can leave the default of `db`, provided by the same Docker Compose. You normally wouldn't need to change this unless you are using a third-party provider.
|
|
||||||
* `POSTGRES_PORT`: The port of the PostgreSQL server. You can leave the default. You normally wouldn't need to change this unless you are using a third-party provider.
|
|
||||||
* `POSTGRES_PASSWORD`: The Postgres password.
|
|
||||||
* `POSTGRES_USER`: The Postgres user, you can leave the default.
|
|
||||||
* `POSTGRES_DB`: The database name to use for this application. You can leave the default of `app`.
|
|
||||||
* `SENTRY_DSN`: The DSN for Sentry, if you are using it.
|
|
||||||
|
|
||||||
## GitHub Actions Environment Variables
|
|
||||||
|
|
||||||
There are some environment variables only used by GitHub Actions that you can configure:
|
|
||||||
|
|
||||||
* `LATEST_CHANGES`: Used by the GitHub Action [latest-changes](https://github.com/tiangolo/latest-changes) to automatically add release notes based on the PRs merged. It's a personal access token, read the docs for details.
|
|
||||||
* `SMOKESHOW_AUTH_KEY`: Used to handle and publish the code coverage using [Smokeshow](https://github.com/samuelcolvin/smokeshow), follow their instructions to create a (free) Smokeshow key.
|
|
||||||
|
|
||||||
### Generate secret keys
|
### Generate secret keys
|
||||||
|
|
||||||
Some environment variables in the `.env` file have a default value of `changethis`.
|
Some environment variables in the `.env` file have a default value of `changethis`.
|
||||||
@@ -163,15 +133,80 @@ python -c "import secrets; print(secrets.token_urlsafe(32))"
|
|||||||
|
|
||||||
Copy the content and use that as password / secret key. And run that again to generate another secure key.
|
Copy the content and use that as password / secret key. And run that again to generate another secure key.
|
||||||
|
|
||||||
|
### Required Environment Variables
|
||||||
|
|
||||||
|
Set the `ENVIRONMENT`, by default `local` (for development), but when deploying to a server you would put something like `staging` or `production`:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
export ENVIRONMENT=production
|
||||||
|
```
|
||||||
|
|
||||||
|
Set the `DOMAIN`, by default `localhost` (for development), but when deploying you would use your own domain, for example:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
export DOMAIN=fastapi-project.example.com
|
||||||
|
```
|
||||||
|
|
||||||
|
Set the `POSTGRES_PASSWORD` to something different than `changethis`:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
export POSTGRES_PASSWORD="changethis"
|
||||||
|
```
|
||||||
|
|
||||||
|
Set the `SECRET_KEY`, used to sign tokens:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
export SECRET_KEY="changethis"
|
||||||
|
```
|
||||||
|
|
||||||
|
Note: you can use the Python command above to generate a secure secret key.
|
||||||
|
|
||||||
|
Set the `FIRST_SUPER_USER_PASSWORD` to something different than `changethis`:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
export FIRST_SUPERUSER_PASSWORD="changethis"
|
||||||
|
```
|
||||||
|
|
||||||
|
Set the `BACKEND_CORS_ORIGINS` to include your domain:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
export BACKEND_CORS_ORIGINS="https://dashboard.${DOMAIN?Variable not set},https://api.${DOMAIN?Variable not set}"
|
||||||
|
```
|
||||||
|
|
||||||
|
You can set several other environment variables:
|
||||||
|
|
||||||
|
* `PROJECT_NAME`: The name of the project, used in the API for the docs and emails.
|
||||||
|
* `STACK_NAME`: The name of the stack used for Docker Compose labels and project name, this should be different for `staging`, `production`, etc. You could use the same domain replacing dots with dashes, e.g. `fastapi-project-example-com` and `staging-fastapi-project-example-com`.
|
||||||
|
* `BACKEND_CORS_ORIGINS`: A list of allowed CORS origins separated by commas.
|
||||||
|
* `FIRST_SUPERUSER`: The email of the first superuser, this superuser will be the one that can create new users.
|
||||||
|
* `SMTP_HOST`: The SMTP server host to send emails, this would come from your email provider (E.g. Mailgun, Sparkpost, Sendgrid, etc).
|
||||||
|
* `SMTP_USER`: The SMTP server user to send emails.
|
||||||
|
* `SMTP_PASSWORD`: The SMTP server password to send emails.
|
||||||
|
* `EMAILS_FROM_EMAIL`: The email account to send emails from.
|
||||||
|
* `POSTGRES_SERVER`: The hostname of the PostgreSQL server. You can leave the default of `db`, provided by the same Docker Compose. You normally wouldn't need to change this unless you are using a third-party provider.
|
||||||
|
* `POSTGRES_PORT`: The port of the PostgreSQL server. You can leave the default. You normally wouldn't need to change this unless you are using a third-party provider.
|
||||||
|
* `POSTGRES_USER`: The Postgres user, you can leave the default.
|
||||||
|
* `POSTGRES_DB`: The database name to use for this application. You can leave the default of `app`.
|
||||||
|
* `SENTRY_DSN`: The DSN for Sentry, if you are using it.
|
||||||
|
|
||||||
|
## GitHub Actions Environment Variables
|
||||||
|
|
||||||
|
There are some environment variables only used by GitHub Actions that you can configure:
|
||||||
|
|
||||||
|
* `LATEST_CHANGES`: Used by the GitHub Action [latest-changes](https://github.com/tiangolo/latest-changes) to automatically add release notes based on the PRs merged. It's a personal access token, read the docs for details.
|
||||||
|
* `SMOKESHOW_AUTH_KEY`: Used to handle and publish the code coverage using [Smokeshow](https://github.com/samuelcolvin/smokeshow), follow their instructions to create a (free) Smokeshow key.
|
||||||
|
|
||||||
### Deploy with Docker Compose
|
### Deploy with Docker Compose
|
||||||
|
|
||||||
With the environment variables in place, you can deploy with Docker Compose:
|
With the environment variables in place, you can deploy with Docker Compose:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker compose -f docker-compose.yml up -d
|
cd /root/code/app/
|
||||||
|
docker compose -f compose.yml build
|
||||||
|
docker compose -f compose.yml up -d
|
||||||
```
|
```
|
||||||
|
|
||||||
For production you wouldn't want to have the overrides in `docker-compose.override.yml`, that's why we explicitly specify `docker-compose.yml` as the file to use.
|
For production you wouldn't want to have the overrides in `compose.override.yml`, that's why we explicitly specify `compose.yml` as the file to use.
|
||||||
|
|
||||||
## Continuous Deployment (CD)
|
## Continuous Deployment (CD)
|
||||||
|
|
||||||
@@ -183,22 +218,22 @@ There are already two environments configured, `staging` and `production`. 🚀
|
|||||||
|
|
||||||
### Install GitHub Actions Runner
|
### Install GitHub Actions Runner
|
||||||
|
|
||||||
* On your remote server, if you are running as the `root` user, create a user for your GitHub Actions:
|
* On your remote server, create a user for your GitHub Actions:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
adduser github
|
sudo adduser github
|
||||||
```
|
```
|
||||||
|
|
||||||
* Add Docker permissions to the `github` user:
|
* Add Docker permissions to the `github` user:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
usermod -aG docker github
|
sudo usermod -aG docker github
|
||||||
```
|
```
|
||||||
|
|
||||||
* Temporarily switch to the `github` user:
|
* Temporarily switch to the `github` user:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
su - github
|
sudo su - github
|
||||||
```
|
```
|
||||||
|
|
||||||
* Go to the `github` user's home directory:
|
* Go to the `github` user's home directory:
|
||||||
@@ -219,9 +254,15 @@ To make sure it runs on startup and continues running, you can install it as a s
|
|||||||
exit
|
exit
|
||||||
```
|
```
|
||||||
|
|
||||||
After you do it, you would be on the `root` user again. And you will be on the previous directory, belonging to the `root` user.
|
After you do it, you will be on the previous user again. And you will be on the previous directory, belonging to that user.
|
||||||
|
|
||||||
* Go to the `actions-runner` directory inside of the `github` user's home directory:
|
Before being able to go the `github` user directory, you need to become the `root` user (you might already be):
|
||||||
|
|
||||||
|
```bash
|
||||||
|
sudo su
|
||||||
|
```
|
||||||
|
|
||||||
|
* As the `root` user, go to the `actions-runner` directory inside of the `github` user's home directory:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
cd /home/github/actions-runner
|
cd /home/github/actions-runner
|
||||||
@@ -284,20 +325,20 @@ Traefik UI: `https://traefik.fastapi-project.example.com`
|
|||||||
|
|
||||||
### Production
|
### Production
|
||||||
|
|
||||||
Frontend: `https://fastapi-project.example.com`
|
Frontend: `https://dashboard.fastapi-project.example.com`
|
||||||
|
|
||||||
Backend API docs: `https://fastapi-project.example.com/docs`
|
Backend API docs: `https://api.fastapi-project.example.com/docs`
|
||||||
|
|
||||||
Backend API base URL: `https://fastapi-project.example.com/api/`
|
Backend API base URL: `https://api.fastapi-project.example.com`
|
||||||
|
|
||||||
Adminer: `https://adminer.fastapi-project.example.com`
|
Adminer: `https://adminer.fastapi-project.example.com`
|
||||||
|
|
||||||
### Staging
|
### Staging
|
||||||
|
|
||||||
Frontend: `https://staging.fastapi-project.example.com`
|
Frontend: `https://dashboard.staging.fastapi-project.example.com`
|
||||||
|
|
||||||
Backend API docs: `https://staging.fastapi-project.example.com/docs`
|
Backend API docs: `https://api.staging.fastapi-project.example.com/docs`
|
||||||
|
|
||||||
Backend API base URL: `https://staging.fastapi-project.example.com/api/`
|
Backend API base URL: `https://api.staging.fastapi-project.example.com`
|
||||||
|
|
||||||
Adminer: `https://adminer.staging.fastapi-project.example.com`
|
Adminer: `https://adminer.staging.fastapi-project.example.com`
|
||||||
|
|||||||
+125
-79
@@ -1,141 +1,183 @@
|
|||||||
# FastAPI Project - Development
|
# FastAPI Project - Development
|
||||||
|
|
||||||
## Development in `localhost` with a custom domain
|
## Docker Compose
|
||||||
|
|
||||||
You might want to use something different than `localhost` as the domain. For example, if you are having problems with cookies that need a subdomain, and Chrome is not allowing you to use `localhost`.
|
* Start the local stack with Docker Compose:
|
||||||
|
|
||||||
In that case, you have two options: you could use the instructions to modify your system `hosts` file with the instructions below in **Development with a custom IP** or you can just use `localhost.tiangolo.com`, it is set up to point to `localhost` (to the IP `127.0.0.1`) and all its subdomains too. And as it is an actual domain, the browsers will store the cookies you set during development, etc.
|
```bash
|
||||||
|
docker compose watch
|
||||||
If you used the default CORS enabled domains while generating the project, `localhost.tiangolo.com` was configured to be allowed. If you didn't, you will need to add it to the list in the variable `BACKEND_CORS_ORIGINS` in the `.env` file.
|
|
||||||
|
|
||||||
To configure it in your stack, follow the section **Change the development "domain"** below, using the domain `localhost.tiangolo.com`.
|
|
||||||
|
|
||||||
After performing those steps you should be able to open: http://localhost.tiangolo.com and it will be served by your stack in `localhost`.
|
|
||||||
|
|
||||||
Check all the corresponding available URLs in the section at the end.
|
|
||||||
|
|
||||||
## Development with a custom IP
|
|
||||||
|
|
||||||
If you are running Docker in an IP address different than `127.0.0.1` (`localhost`), you will need to perform some additional steps. That will be the case if you are running a custom Virtual Machine or your Docker is located in a different machine in your network.
|
|
||||||
|
|
||||||
In that case, you will need to use a fake local domain (`dev.example.com`) and make your computer think that the domain is served by the custom IP (e.g. `192.168.99.150`).
|
|
||||||
|
|
||||||
If you have a custom domain like that, you need to add it to the list in the variable `BACKEND_CORS_ORIGINS` in the `.env` file.
|
|
||||||
|
|
||||||
* Open your `hosts` file with administrative privileges using a text editor:
|
|
||||||
|
|
||||||
* **Note for Windows**: If you are in Windows, open the main Windows menu, search for "notepad", right click on it, and select the option "open as Administrator" or similar. Then click the "File" menu, "Open file", go to the directory `c:\Windows\System32\Drivers\etc\`, select the option to show "All files" instead of only "Text (.txt) files", and open the `hosts` file.
|
|
||||||
* **Note for Mac and Linux**: Your `hosts` file is probably located at `/etc/hosts`, you can edit it in a terminal running `sudo nano /etc/hosts`.
|
|
||||||
|
|
||||||
* Additional to the contents it might have, add a new line with the custom IP (e.g. `192.168.99.150`) a space character, and your fake local domain: `dev.example.com`.
|
|
||||||
|
|
||||||
The new line might look like:
|
|
||||||
|
|
||||||
```
|
|
||||||
192.168.99.150 dev.example.com
|
|
||||||
```
|
```
|
||||||
|
|
||||||
* Save the file.
|
* Now you can open your browser and interact with these URLs:
|
||||||
* **Note for Windows**: Make sure you save the file as "All files", without an extension of `.txt`. By default, Windows tries to add the extension. Make sure the file is saved as is, without extension.
|
|
||||||
|
|
||||||
...that will make your computer think that the fake local domain is served by that custom IP, and when you open that URL in your browser, it will talk directly to your locally running server when it is asked to go to `dev.example.com` and think that it is a remote server while it is actually running in your computer.
|
Frontend, built with Docker, with routes handled based on the path: <http://localhost:5173>
|
||||||
|
|
||||||
To configure it in your stack, follow the section **Change the development "domain"** below, using the domain `dev.example.com`.
|
Backend, JSON based web API based on OpenAPI: <http://localhost:8000>
|
||||||
|
|
||||||
After performing those steps you should be able to open: http://dev.example.com and it will be server by your stack in `192.168.99.150`.
|
Automatic interactive documentation with Swagger UI (from the OpenAPI backend): <http://localhost:8000/docs>
|
||||||
|
|
||||||
Check all the corresponding available URLs in the section at the end.
|
Adminer, database web administration: <http://localhost:8080>
|
||||||
|
|
||||||
## Change the development "domain"
|
Traefik UI, to see how the routes are being handled by the proxy: <http://localhost:8090>
|
||||||
|
|
||||||
If you need to use your local stack with a different domain than `localhost`, you need to make sure the domain you use points to the IP where your stack is set up.
|
**Note**: The first time you start your stack, it might take a minute for it to be ready. While the backend waits for the database to be ready and configures everything. You can check the logs to monitor it.
|
||||||
|
|
||||||
To simplify your Docker Compose setup, for example, so that the API docs (Swagger UI) knows where is your API, you should let it know you are using that domain for development.
|
To check the logs, run (in another terminal):
|
||||||
|
|
||||||
* Open the file located at `./.env`. It would have a line like:
|
```bash
|
||||||
|
docker compose logs
|
||||||
```
|
|
||||||
DOMAIN=localhost
|
|
||||||
```
|
```
|
||||||
|
|
||||||
* Change it to the domain you are going to use, e.g.:
|
To check the logs of a specific service, add the name of the service, e.g.:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker compose logs backend
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Mailcatcher
|
||||||
|
|
||||||
|
Mailcatcher is a simple SMTP server that catches all emails sent by the backend during local development. Instead of sending real emails, they are captured and displayed in a web interface.
|
||||||
|
|
||||||
|
This is useful for:
|
||||||
|
|
||||||
|
* Testing email functionality during development
|
||||||
|
* Verifying email content and formatting
|
||||||
|
* Debugging email-related functionality without sending real emails
|
||||||
|
|
||||||
|
The backend is automatically configured to use Mailcatcher when running with Docker Compose locally (SMTP on port 1025). All captured emails can be viewed at <http://localhost:1080>.
|
||||||
|
|
||||||
|
## Local Development
|
||||||
|
|
||||||
|
The Docker Compose files are configured so that each of the services is available in a different port in `localhost`.
|
||||||
|
|
||||||
|
For the backend and frontend, they use the same port that would be used by their local development server, so, the backend is at `http://localhost:8000` and the frontend at `http://localhost:5173`.
|
||||||
|
|
||||||
|
This way, you could turn off a Docker Compose service and start its local development service, and everything would keep working, because it all uses the same ports.
|
||||||
|
|
||||||
|
For example, you can stop that `frontend` service in the Docker Compose, in another terminal, run:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker compose stop frontend
|
||||||
|
```
|
||||||
|
|
||||||
|
And then start the local frontend development server:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
bun run dev
|
||||||
|
```
|
||||||
|
|
||||||
|
Or you could stop the `backend` Docker Compose service:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker compose stop backend
|
||||||
|
```
|
||||||
|
|
||||||
|
And then you can run the local development server for the backend:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cd backend
|
||||||
|
fastapi dev app/main.py
|
||||||
|
```
|
||||||
|
|
||||||
|
## Docker Compose in `localhost.tiangolo.com`
|
||||||
|
|
||||||
|
When you start the Docker Compose stack, it uses `localhost` by default, with different ports for each service (backend, frontend, adminer, etc).
|
||||||
|
|
||||||
|
When you deploy it to production (or staging), it will deploy each service in a different subdomain, like `api.example.com` for the backend and `dashboard.example.com` for the frontend.
|
||||||
|
|
||||||
|
In the guide about [deployment](deployment.md) you can read about Traefik, the configured proxy. That's the component in charge of transmitting traffic to each service based on the subdomain.
|
||||||
|
|
||||||
|
If you want to test that it's all working locally, you can edit the local `.env` file, and change:
|
||||||
|
|
||||||
|
```dotenv
|
||||||
DOMAIN=localhost.tiangolo.com
|
DOMAIN=localhost.tiangolo.com
|
||||||
```
|
```
|
||||||
|
|
||||||
That variable will be used by the Docker Compose files.
|
That will be used by the Docker Compose files to configure the base domain for the services.
|
||||||
|
|
||||||
After that, you can restart your stack with:
|
Traefik will use this to transmit traffic at `api.localhost.tiangolo.com` to the backend, and traffic at `dashboard.localhost.tiangolo.com` to the frontend.
|
||||||
|
|
||||||
|
The domain `localhost.tiangolo.com` is a special domain that is configured (with all its subdomains) to point to `127.0.0.1`. This way you can use that for your local development.
|
||||||
|
|
||||||
|
After you update it, run again:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker compose up -d
|
docker compose watch
|
||||||
```
|
```
|
||||||
|
|
||||||
and check all the corresponding available URLs in the section at the end.
|
When deploying, for example in production, the main Traefik is configured outside of the Docker Compose files. For local development, there's an included Traefik in `compose.override.yml`, just to let you test that the domains work as expected, for example with `api.localhost.tiangolo.com` and `dashboard.localhost.tiangolo.com`.
|
||||||
|
|
||||||
## Docker Compose files and env vars
|
## Docker Compose files and env vars
|
||||||
|
|
||||||
There is a main `docker-compose.yml` file with all the configurations that apply to the whole stack, it is used automatically by `docker compose`.
|
There is a main `compose.yml` file with all the configurations that apply to the whole stack, it is used automatically by `docker compose`.
|
||||||
|
|
||||||
And there's also a `docker-compose.override.yml` with overrides for development, for example to mount the source code as a volume. It is used automatically by `docker compose` to apply overrides on top of `docker-compose.yml`.
|
And there's also a `compose.override.yml` with overrides for development, for example to mount the source code as a volume. It is used automatically by `docker compose` to apply overrides on top of `compose.yml`.
|
||||||
|
|
||||||
These Docker Compose files use the `.env` file containing configurations to be injected as environment variables in the containers.
|
These Docker Compose files use the `.env` file containing configurations to be injected as environment variables in the containers.
|
||||||
|
|
||||||
They also use some additional configurations taken from environment variables set in the scripts before calling the `docker compose` command.
|
They also use some additional configurations taken from environment variables set in the scripts before calling the `docker compose` command.
|
||||||
|
|
||||||
|
After changing variables, make sure you restart the stack:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker compose watch
|
||||||
|
```
|
||||||
|
|
||||||
## The .env file
|
## The .env file
|
||||||
|
|
||||||
The `.env` file is the one that contains all your configurations, generated keys and passwords, etc.
|
The `.env` file is the one that contains all your configurations, generated keys and passwords, etc.
|
||||||
|
|
||||||
Depending on your workflow, you could want to exclude it from Git, for example if your project is public. In that case, you would have to make sure to set up a way for your CI tools to obtain it while building or deploying your project.
|
Depending on your workflow, you could want to exclude it from Git, for example if your project is public. In that case, you would have to make sure to set up a way for your CI tools to obtain it while building or deploying your project.
|
||||||
|
|
||||||
One way to do it could be to add each environment variable to your CI/CD system, and updating the `docker-compose.yml` file to read that specific env var instead of reading the `.env` file.
|
One way to do it could be to add each environment variable to your CI/CD system, and updating the `compose.yml` file to read that specific env var instead of reading the `.env` file.
|
||||||
|
|
||||||
### Pre-commits and code linting
|
## Pre-commits and code linting
|
||||||
|
|
||||||
we are using a tool called [pre-commit](https://pre-commit.com/) for code linting and formatting.
|
we are using a tool called [prek](https://prek.j178.dev/) (modern alternative to [Pre-commit](https://pre-commit.com/)) for code linting and formatting.
|
||||||
|
|
||||||
When you install it, it runs right before making a commit in git. This way it ensures that the code is consistent and formatted even before it is committed.
|
When you install it, it runs right before making a commit in git. This way it ensures that the code is consistent and formatted even before it is committed.
|
||||||
|
|
||||||
You can find a file `.pre-commit-config.yaml` with configurations at the root of the project.
|
You can find a file `.pre-commit-config.yaml` with configurations at the root of the project.
|
||||||
|
|
||||||
#### Install pre-commit to run automatically
|
#### Install prek to run automatically
|
||||||
|
|
||||||
`pre-commit` is already part of the dependencies of the project, but you could also install it globally if you prefer to, following [the official pre-commit docs](https://pre-commit.com/).
|
`prek` is already part of the dependencies of the project.
|
||||||
|
|
||||||
After having the `pre-commit` tool installed and available, you need to "install" it in the local repository, so that it runs automatically before each commit.
|
After having the `prek` tool installed and available, you need to "install" it in the local repository, so that it runs automatically before each commit.
|
||||||
|
|
||||||
Using Poetry, you could do it with:
|
Using `uv`, you could do it with (make sure you are inside `backend` folder):
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
❯ poetry run pre-commit install
|
❯ uv run prek install -f
|
||||||
pre-commit installed at .git/hooks/pre-commit
|
prek installed at `../.git/hooks/pre-commit`
|
||||||
```
|
```
|
||||||
|
|
||||||
|
The `-f` flag forces the installation, in case there was already a `pre-commit` hook previously installed.
|
||||||
|
|
||||||
Now whenever you try to commit, e.g. with:
|
Now whenever you try to commit, e.g. with:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git commit
|
git commit
|
||||||
```
|
```
|
||||||
|
|
||||||
...pre-commit will run and check and format the code you are about to commit, and will ask you to add that code (stage it) with git again before committing.
|
...prek will run and check and format the code you are about to commit, and will ask you to add that code (stage it) with git again before committing.
|
||||||
|
|
||||||
Then you can `git add` the modified/fixed files again and now you can commit.
|
Then you can `git add` the modified/fixed files again and now you can commit.
|
||||||
|
|
||||||
#### Running pre-commit hooks manually
|
#### Running prek hooks manually
|
||||||
|
|
||||||
you can also run `pre-commit` manually on all the files, you can do it using Poetry with:
|
you can also run `prek` manually on all the files, you can do it using `uv` with:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
❯ poetry run pre-commit run --all-files
|
❯ uv run prek run --all-files
|
||||||
check for added large files..............................................Passed
|
check for added large files..............................................Passed
|
||||||
check toml...............................................................Passed
|
check toml...............................................................Passed
|
||||||
check yaml...............................................................Passed
|
check yaml...............................................................Passed
|
||||||
|
fix end of files.........................................................Passed
|
||||||
|
trim trailing whitespace.................................................Passed
|
||||||
ruff.....................................................................Passed
|
ruff.....................................................................Passed
|
||||||
ruff-format..............................................................Passed
|
ruff-format..............................................................Passed
|
||||||
eslint...................................................................Passed
|
biome check..............................................................Passed
|
||||||
prettier.................................................................Passed
|
|
||||||
```
|
```
|
||||||
|
|
||||||
## URLs
|
## URLs
|
||||||
@@ -146,30 +188,34 @@ The production or staging URLs would use these same paths, but with your own dom
|
|||||||
|
|
||||||
Development URLs, for local development.
|
Development URLs, for local development.
|
||||||
|
|
||||||
Frontend: http://localhost
|
Frontend: <http://localhost:5173>
|
||||||
|
|
||||||
Backend: http://localhost/api/
|
Backend: <http://localhost:8000>
|
||||||
|
|
||||||
Automatic Interactive Docs (Swagger UI): http://localhost/docs
|
Automatic Interactive Docs (Swagger UI): <http://localhost:8000/docs>
|
||||||
|
|
||||||
Automatic Alternative Docs (ReDoc): http://localhost/redoc
|
Automatic Alternative Docs (ReDoc): <http://localhost:8000/redoc>
|
||||||
|
|
||||||
Adminer: http://localhost:8080
|
Adminer: <http://localhost:8080>
|
||||||
|
|
||||||
Traefik UI: http://localhost:8090
|
Traefik UI: <http://localhost:8090>
|
||||||
|
|
||||||
### Development in localhost with a custom domain URLs
|
MailCatcher: <http://localhost:1080>
|
||||||
|
|
||||||
|
### Development URLs with `localhost.tiangolo.com` Configured
|
||||||
|
|
||||||
Development URLs, for local development.
|
Development URLs, for local development.
|
||||||
|
|
||||||
Frontend: http://localhost.tiangolo.com
|
Frontend: <http://dashboard.localhost.tiangolo.com>
|
||||||
|
|
||||||
Backend: http://localhost.tiangolo.com/api/
|
Backend: <http://api.localhost.tiangolo.com>
|
||||||
|
|
||||||
Automatic Interactive Docs (Swagger UI): http://localhost.tiangolo.com/docs
|
Automatic Interactive Docs (Swagger UI): <http://api.localhost.tiangolo.com/docs>
|
||||||
|
|
||||||
Automatic Alternative Docs (ReDoc): http://localhost.tiangolo.com/redoc
|
Automatic Alternative Docs (ReDoc): <http://api.localhost.tiangolo.com/redoc>
|
||||||
|
|
||||||
Adminer: http://localhost.tiangolo.com:8080
|
Adminer: <http://localhost.tiangolo.com:8080>
|
||||||
|
|
||||||
Traefik UI: http://localhost.tiangolo.com:8090
|
Traefik UI: <http://localhost.tiangolo.com:8090>
|
||||||
|
|
||||||
|
MailCatcher: <http://localhost.tiangolo.com:1080>
|
||||||
|
|||||||
+2
-1
@@ -1 +1,2 @@
|
|||||||
VITE_API_URL=http://localhost
|
VITE_API_URL=http://localhost:8000
|
||||||
|
MAILCATCHER_HOST=http://localhost:1080
|
||||||
|
|||||||
@@ -27,3 +27,4 @@ openapi.json
|
|||||||
/playwright-report/
|
/playwright-report/
|
||||||
/blob-report/
|
/blob-report/
|
||||||
/playwright/.cache/
|
/playwright/.cache/
|
||||||
|
/playwright/.auth/
|
||||||
|
|||||||
@@ -1 +0,0 @@
|
|||||||
20
|
|
||||||
+13
-10
@@ -1,23 +1,26 @@
|
|||||||
# Stage 0, "build-stage", based on Node.js, to build and compile the frontend
|
# Stage 0, "build-stage", based on Bun, to build and compile the frontend
|
||||||
FROM node:20 AS build-stage
|
FROM oven/bun:1 AS build-stage
|
||||||
|
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|
||||||
COPY package*.json /app/
|
COPY package.json bun.lock /app/
|
||||||
|
|
||||||
RUN npm install
|
COPY frontend/package.json /app/frontend/
|
||||||
|
|
||||||
COPY ./ /app/
|
WORKDIR /app/frontend
|
||||||
|
|
||||||
ARG VITE_API_URL=${VITE_API_URL}
|
RUN bun install
|
||||||
|
|
||||||
RUN npm run build
|
COPY ./frontend /app/frontend
|
||||||
|
ARG VITE_API_URL
|
||||||
|
|
||||||
|
RUN bun run build
|
||||||
|
|
||||||
|
|
||||||
# Stage 1, based on Nginx, to have only the compiled app, ready for production with Nginx
|
# Stage 1, based on Nginx, to have only the compiled app, ready for production with Nginx
|
||||||
FROM nginx:1
|
FROM nginx:1
|
||||||
|
|
||||||
COPY --from=build-stage /app/dist/ /usr/share/nginx/html
|
COPY --from=build-stage /app/frontend/dist/ /usr/share/nginx/html
|
||||||
|
|
||||||
COPY ./nginx.conf /etc/nginx/conf.d/default.conf
|
COPY ./frontend/nginx.conf /etc/nginx/conf.d/default.conf
|
||||||
COPY ./nginx-backend-not-found.conf /etc/nginx/extra-conf.d/backend-not-found.conf
|
COPY ./frontend/nginx-backend-not-found.conf /etc/nginx/extra-conf.d/backend-not-found.conf
|
||||||
|
|||||||
@@ -0,0 +1,21 @@
|
|||||||
|
FROM mcr.microsoft.com/playwright:v1.57.0-noble
|
||||||
|
|
||||||
|
WORKDIR /app
|
||||||
|
|
||||||
|
RUN apt-get update && apt-get install -y unzip \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
RUN curl -fsSL https://bun.sh/install | bash
|
||||||
|
ENV PATH="/root/.bun/bin:$PATH"
|
||||||
|
|
||||||
|
COPY package.json bun.lock /app/
|
||||||
|
|
||||||
|
COPY frontend/package.json /app/frontend/
|
||||||
|
|
||||||
|
WORKDIR /app/frontend
|
||||||
|
|
||||||
|
RUN bun install
|
||||||
|
|
||||||
|
COPY ./frontend /app/frontend
|
||||||
|
|
||||||
|
ARG VITE_API_URL
|
||||||
+26
-52
@@ -1,48 +1,16 @@
|
|||||||
# FastAPI Project - Frontend
|
# FastAPI Project - Frontend
|
||||||
|
|
||||||
The frontend is built with [Vite](https://vitejs.dev/), [React](https://reactjs.org/), [TypeScript](https://www.typescriptlang.org/), [TanStack Query](https://tanstack.com/query), [TanStack Router](https://tanstack.com/router) and [Chakra UI](https://chakra-ui.com/).
|
The frontend is built with [Vite](https://vitejs.dev/), [React](https://reactjs.org/), [TypeScript](https://www.typescriptlang.org/), [TanStack Query](https://tanstack.com/query), [TanStack Router](https://tanstack.com/router) and [Tailwind CSS](https://tailwindcss.com/).
|
||||||
|
|
||||||
## Frontend development
|
## Requirements
|
||||||
|
|
||||||
Before you begin, ensure that you have either the Node Version Manager (nvm) or Fast Node Manager (fnm) installed on your system.
|
- [Bun](https://bun.sh/) (recommended) or [Node.js](https://nodejs.org/)
|
||||||
|
|
||||||
* To install fnm follow the [official fnm guide](https://github.com/Schniz/fnm#installation). If you prefer nvm, you can install it using the [official nvm guide](https://github.com/nvm-sh/nvm#installing-and-updating).
|
## Quick Start
|
||||||
|
|
||||||
* After installing either nvm or fnm, proceed to the `frontend` directory:
|
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
cd frontend
|
bun install
|
||||||
```
|
bun run dev
|
||||||
* If the Node.js version specified in the `.nvmrc` file isn't installed on your system, you can install it using the appropriate command:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# If using fnm
|
|
||||||
fnm install
|
|
||||||
|
|
||||||
# If using nvm
|
|
||||||
nvm install
|
|
||||||
```
|
|
||||||
|
|
||||||
* Once the installation is complete, switch to the installed version:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# If using fnm
|
|
||||||
fnm use
|
|
||||||
|
|
||||||
# If using nvm
|
|
||||||
nvm use
|
|
||||||
```
|
|
||||||
|
|
||||||
* Within the `frontend` directory, install the necessary NPM packages:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
npm install
|
|
||||||
```
|
|
||||||
|
|
||||||
* And start the live server with the following `npm` script:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
npm run dev
|
|
||||||
```
|
```
|
||||||
|
|
||||||
* Then open your browser at http://localhost:5173/.
|
* Then open your browser at http://localhost:5173/.
|
||||||
@@ -57,9 +25,9 @@ If you are developing an API-only app and want to remove the frontend, you can d
|
|||||||
|
|
||||||
* Remove the `./frontend` directory.
|
* Remove the `./frontend` directory.
|
||||||
|
|
||||||
* In the `docker-compose.yml` file, remove the whole service / section `frontend`.
|
* In the `compose.yml` file, remove the whole service / section `frontend`.
|
||||||
|
|
||||||
* In the `docker-compose.override.yml` file, remove the whole service / section `frontend`.
|
* In the `compose.override.yml` file, remove the whole service / section `frontend` and `playwright`.
|
||||||
|
|
||||||
Done, you have a frontend-less (api-only) app. 🤓
|
Done, you have a frontend-less (api-only) app. 🤓
|
||||||
|
|
||||||
@@ -74,20 +42,27 @@ But it would be only to clean them up, leaving them won't really have any effect
|
|||||||
|
|
||||||
## Generate Client
|
## Generate Client
|
||||||
|
|
||||||
|
### Automatically
|
||||||
|
|
||||||
|
* Activate the backend virtual environment.
|
||||||
|
* From the top level project directory, run the script:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
bash ./scripts/generate-client.sh
|
||||||
|
```
|
||||||
|
|
||||||
|
* Commit the changes.
|
||||||
|
|
||||||
|
### Manually
|
||||||
|
|
||||||
* Start the Docker Compose stack.
|
* Start the Docker Compose stack.
|
||||||
|
|
||||||
* Download the OpenAPI JSON file from `http://localhost/api/v1/openapi.json` and copy it to a new file `openapi.json` at the root of the `frontend` directory.
|
* Download the OpenAPI JSON file from `http://localhost/api/v1/openapi.json` and copy it to a new file `openapi.json` at the root of the `frontend` directory.
|
||||||
|
|
||||||
* To simplify the names in the generated frontend client code, modify the `openapi.json` file by running the following script:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
node modify-openapi-operationids.js
|
|
||||||
```
|
|
||||||
|
|
||||||
* To generate the frontend client, run:
|
* To generate the frontend client, run:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
npm run generate-client
|
bun run generate-client
|
||||||
```
|
```
|
||||||
|
|
||||||
* Commit the changes.
|
* Commit the changes.
|
||||||
@@ -99,7 +74,7 @@ Notice that everytime the backend changes (changing the OpenAPI schema), you sho
|
|||||||
If you want to use a remote API, you can set the environment variable `VITE_API_URL` to the URL of the remote API. For example, you can set it in the `frontend/.env` file:
|
If you want to use a remote API, you can set the environment variable `VITE_API_URL` to the URL of the remote API. For example, you can set it in the `frontend/.env` file:
|
||||||
|
|
||||||
```env
|
```env
|
||||||
VITE_API_URL=https://my-remote-api.example.com
|
VITE_API_URL=https://api.my-domain.example.com
|
||||||
```
|
```
|
||||||
|
|
||||||
Then, when you run the frontend, it will use that URL as the base URL for the API.
|
Then, when you run the frontend, it will use that URL as the base URL for the API.
|
||||||
@@ -114,26 +89,25 @@ The frontend code is structured as follows:
|
|||||||
* `frontend/src/components` - The different components of the frontend.
|
* `frontend/src/components` - The different components of the frontend.
|
||||||
* `frontend/src/hooks` - Custom hooks.
|
* `frontend/src/hooks` - Custom hooks.
|
||||||
* `frontend/src/routes` - The different routes of the frontend which include the pages.
|
* `frontend/src/routes` - The different routes of the frontend which include the pages.
|
||||||
* `theme.tsx` - The Chakra UI custom theme.
|
|
||||||
|
|
||||||
## End-to-End Testing with Playwright
|
## End-to-End Testing with Playwright
|
||||||
|
|
||||||
The frontend includes initial end-to-end tests using Playwright. To run the tests, you need to have the Docker Compose stack running. Start the stack with the following command:
|
The frontend includes initial end-to-end tests using Playwright. To run the tests, you need to have the Docker Compose stack running. Start the stack with the following command:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker compose up -d
|
docker compose up -d --wait backend
|
||||||
```
|
```
|
||||||
|
|
||||||
Then, you can run the tests with the following command:
|
Then, you can run the tests with the following command:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
npx playwright test
|
bunx playwright test
|
||||||
```
|
```
|
||||||
|
|
||||||
You can also run your tests in UI mode to see the browser and interact with it running:
|
You can also run your tests in UI mode to see the browser and interact with it running:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
npx playwright test --ui
|
bunx playwright test --ui
|
||||||
```
|
```
|
||||||
|
|
||||||
To stop and remove the Docker Compose stack and clean the data created in tests, use the following command:
|
To stop and remove the Docker Compose stack and clean the data created in tests, use the following command:
|
||||||
|
|||||||
+20
-11
@@ -1,15 +1,16 @@
|
|||||||
{
|
{
|
||||||
"$schema": "https://biomejs.dev/schemas/1.6.1/schema.json",
|
"$schema": "https://biomejs.dev/schemas/2.3.11/schema.json",
|
||||||
"organizeImports": {
|
"assist": { "actions": { "source": { "organizeImports": "on" } } },
|
||||||
"enabled": true
|
|
||||||
},
|
|
||||||
"files": {
|
"files": {
|
||||||
"ignore": [
|
"includes": [
|
||||||
"node_modules",
|
"**",
|
||||||
"src/client/",
|
"!**/dist/**/*",
|
||||||
"src/routeTree.gen.ts",
|
"!**/node_modules/**/*",
|
||||||
"playwright.config.ts",
|
"!**/src/routeTree.gen.ts",
|
||||||
"playwright-report"
|
"!**/src/client/**/*",
|
||||||
|
"!**/src/components/ui/**/*",
|
||||||
|
"!**/playwright-report",
|
||||||
|
"!**/playwright.config.ts"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"linter": {
|
"linter": {
|
||||||
@@ -21,7 +22,10 @@
|
|||||||
"noArrayIndexKey": "off"
|
"noArrayIndexKey": "off"
|
||||||
},
|
},
|
||||||
"style": {
|
"style": {
|
||||||
"noNonNullAssertion": "off"
|
"noNonNullAssertion": "off",
|
||||||
|
"noParameterAssign": "error",
|
||||||
|
"useSelfClosingElements": "error",
|
||||||
|
"noUselessElse": "error"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -33,5 +37,10 @@
|
|||||||
"quoteStyle": "double",
|
"quoteStyle": "double",
|
||||||
"semicolons": "asNeeded"
|
"semicolons": "asNeeded"
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"css": {
|
||||||
|
"parser": {
|
||||||
|
"tailwindDirectives": true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,22 @@
|
|||||||
|
{
|
||||||
|
"$schema": "https://ui.shadcn.com/schema.json",
|
||||||
|
"style": "new-york",
|
||||||
|
"rsc": false,
|
||||||
|
"tsx": true,
|
||||||
|
"tailwind": {
|
||||||
|
"config": "",
|
||||||
|
"css": "src/index.css",
|
||||||
|
"baseColor": "neutral",
|
||||||
|
"cssVariables": true,
|
||||||
|
"prefix": ""
|
||||||
|
},
|
||||||
|
"iconLibrary": "lucide",
|
||||||
|
"aliases": {
|
||||||
|
"components": "@/components",
|
||||||
|
"utils": "@/lib/utils",
|
||||||
|
"ui": "@/components/ui",
|
||||||
|
"lib": "@/lib",
|
||||||
|
"hooks": "@/hooks"
|
||||||
|
},
|
||||||
|
"registries": {}
|
||||||
|
}
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
import * as fs from "node:fs"
|
|
||||||
|
|
||||||
async function modifyOpenAPIFile(filePath) {
|
|
||||||
try {
|
|
||||||
const data = await fs.promises.readFile(filePath)
|
|
||||||
const openapiContent = JSON.parse(data)
|
|
||||||
|
|
||||||
const paths = openapiContent.paths
|
|
||||||
for (const pathKey of Object.keys(paths)) {
|
|
||||||
const pathData = paths[pathKey]
|
|
||||||
for (const method of Object.keys(pathData)) {
|
|
||||||
const operation = pathData[method]
|
|
||||||
if (operation.tags && operation.tags.length > 0) {
|
|
||||||
const tag = operation.tags[0]
|
|
||||||
const operationId = operation.operationId
|
|
||||||
const toRemove = `${tag}-`
|
|
||||||
if (operationId.startsWith(toRemove)) {
|
|
||||||
const newOperationId = operationId.substring(toRemove.length)
|
|
||||||
operation.operationId = newOperationId
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
await fs.promises.writeFile(
|
|
||||||
filePath,
|
|
||||||
JSON.stringify(openapiContent, null, 2),
|
|
||||||
)
|
|
||||||
console.log("File successfully modified")
|
|
||||||
} catch (err) {
|
|
||||||
console.error("Error:", err)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
const filePath = "./openapi.json"
|
|
||||||
modifyOpenAPIFile(filePath)
|
|
||||||
@@ -0,0 +1,33 @@
|
|||||||
|
import { defineConfig } from "@hey-api/openapi-ts"
|
||||||
|
|
||||||
|
export default defineConfig({
|
||||||
|
input: "./openapi.json",
|
||||||
|
output: "./src/client",
|
||||||
|
|
||||||
|
plugins: [
|
||||||
|
"legacy/axios",
|
||||||
|
{
|
||||||
|
name: "@hey-api/sdk",
|
||||||
|
// NOTE: this doesn't allow tree-shaking
|
||||||
|
asClass: true,
|
||||||
|
operationId: true,
|
||||||
|
classNameBuilder: "{{name}}Service",
|
||||||
|
methodNameBuilder: (operation) => {
|
||||||
|
// @ts-expect-error
|
||||||
|
let name: string = operation.name
|
||||||
|
// @ts-expect-error
|
||||||
|
const service: string = operation.service
|
||||||
|
|
||||||
|
if (service && name.toLowerCase().startsWith(service.toLowerCase())) {
|
||||||
|
name = name.slice(service.length)
|
||||||
|
}
|
||||||
|
|
||||||
|
return name.charAt(0).toLowerCase() + name.slice(1)
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: "@hey-api/schemas",
|
||||||
|
type: "json",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
})
|
||||||
Generated
-6478
File diff suppressed because it is too large
Load Diff
+52
-30
@@ -5,40 +5,62 @@
|
|||||||
"type": "module",
|
"type": "module",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "vite",
|
"dev": "vite",
|
||||||
"build": "tsc && vite build",
|
"build": "tsc -p tsconfig.build.json && vite build",
|
||||||
"lint": "biome check --apply-unsafe --no-errors-on-unmatched --files-ignore-unknown=true ./",
|
"lint": "biome check --write --unsafe --no-errors-on-unmatched --files-ignore-unknown=true ./",
|
||||||
"preview": "vite preview",
|
"preview": "vite preview",
|
||||||
"generate-client": "openapi-ts --input ./openapi.json --output ./src/client --client axios --exportSchemas true && biome format --write ./src/client"
|
"generate-client": "openapi-ts",
|
||||||
|
"test": "bunx playwright test",
|
||||||
|
"test:ui": "bunx playwright test --ui"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@chakra-ui/icons": "2.1.1",
|
"@hookform/resolvers": "^5.2.2",
|
||||||
"@chakra-ui/react": "2.8.2",
|
"@radix-ui/react-avatar": "^1.1.11",
|
||||||
"@emotion/react": "11.11.3",
|
"@radix-ui/react-checkbox": "^1.3.3",
|
||||||
"@emotion/styled": "11.11.0",
|
"@radix-ui/react-dialog": "^1.1.15",
|
||||||
"@tanstack/react-query": "^5.28.14",
|
"@radix-ui/react-dropdown-menu": "^2.1.16",
|
||||||
"@tanstack/react-query-devtools": "^5.28.14",
|
"@radix-ui/react-label": "^2.1.8",
|
||||||
"@tanstack/react-router": "1.19.1",
|
"@radix-ui/react-radio-group": "^1.3.8",
|
||||||
"axios": "1.6.2",
|
"@radix-ui/react-scroll-area": "^1.2.10",
|
||||||
"form-data": "4.0.0",
|
"@radix-ui/react-select": "^2.2.6",
|
||||||
"framer-motion": "10.16.16",
|
"@radix-ui/react-separator": "^1.1.8",
|
||||||
"react": "^18.2.0",
|
"@radix-ui/react-slot": "^1.2.4",
|
||||||
"react-dom": "^18.2.0",
|
"@radix-ui/react-tabs": "^1.1.13",
|
||||||
"react-error-boundary": "^4.0.13",
|
"@radix-ui/react-tooltip": "^1.2.8",
|
||||||
"react-hook-form": "7.49.3",
|
"@tailwindcss/vite": "^4.1.18",
|
||||||
"react-icons": "5.0.1"
|
"@tanstack/react-query": "^5.90.12",
|
||||||
|
"@tanstack/react-query-devtools": "^5.91.1",
|
||||||
|
"@tanstack/react-router": "^1.142.11",
|
||||||
|
"@tanstack/react-router-devtools": "^1.142.8",
|
||||||
|
"@tanstack/react-table": "^8.21.3",
|
||||||
|
"axios": "1.13.2",
|
||||||
|
"class-variance-authority": "^0.7.1",
|
||||||
|
"clsx": "^2.1.1",
|
||||||
|
"form-data": "4.0.5",
|
||||||
|
"lucide-react": "^0.562.0",
|
||||||
|
"next-themes": "^0.4.6",
|
||||||
|
"react": "^19.1.1",
|
||||||
|
"react-dom": "^19.2.3",
|
||||||
|
"react-error-boundary": "^6.0.0",
|
||||||
|
"react-hook-form": "^7.68.0",
|
||||||
|
"react-icons": "^5.5.0",
|
||||||
|
"sonner": "^2.0.7",
|
||||||
|
"tailwind-merge": "^3.4.0",
|
||||||
|
"tailwindcss": "^4.1.17",
|
||||||
|
"zod": "^4.2.1"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@biomejs/biome": "1.6.1",
|
"@biomejs/biome": "^2.3.10",
|
||||||
"@hey-api/openapi-ts": "^0.34.1",
|
"@hey-api/openapi-ts": "0.73.0",
|
||||||
"@playwright/test": "^1.45.2",
|
"@playwright/test": "1.57.0",
|
||||||
"@tanstack/router-devtools": "1.19.1",
|
"@tanstack/router-devtools": "^1.142.11",
|
||||||
"@tanstack/router-vite-plugin": "1.19.0",
|
"@tanstack/router-plugin": "^1.140.0",
|
||||||
"@types/node": "^20.10.5",
|
"@types/node": "^25.0.2",
|
||||||
"@types/react": "^18.2.37",
|
"@types/react": "^19.2.7",
|
||||||
"@types/react-dom": "^18.2.15",
|
"@types/react-dom": "^19.2.3",
|
||||||
"@vitejs/plugin-react-swc": "^3.5.0",
|
"@vitejs/plugin-react-swc": "^4.2.2",
|
||||||
"dotenv": "^16.4.5",
|
"dotenv": "^17.2.3",
|
||||||
"typescript": "^5.2.2",
|
"tw-animate-css": "^1.4.0",
|
||||||
"vite": "^5.0.13"
|
"typescript": "^5.9.3",
|
||||||
|
"vite": "^7.3.0"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,11 +1,10 @@
|
|||||||
import { defineConfig, devices } from '@playwright/test';
|
import { defineConfig, devices } from '@playwright/test';
|
||||||
|
import 'dotenv/config'
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Read environment variables from file.
|
* Read environment variables from file.
|
||||||
* https://github.com/motdotla/dotenv
|
* https://github.com/motdotla/dotenv
|
||||||
*/
|
*/
|
||||||
// require('dotenv').config();
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* See https://playwright.dev/docs/test-configuration.
|
* See https://playwright.dev/docs/test-configuration.
|
||||||
@@ -21,7 +20,7 @@ export default defineConfig({
|
|||||||
/* Opt out of parallel tests on CI. */
|
/* Opt out of parallel tests on CI. */
|
||||||
workers: process.env.CI ? 1 : undefined,
|
workers: process.env.CI ? 1 : undefined,
|
||||||
/* Reporter to use. See https://playwright.dev/docs/test-reporters */
|
/* Reporter to use. See https://playwright.dev/docs/test-reporters */
|
||||||
reporter: 'html',
|
reporter: process.env.CI ? 'blob' : 'html',
|
||||||
/* Shared settings for all the projects below. See https://playwright.dev/docs/api/class-testoptions. */
|
/* Shared settings for all the projects below. See https://playwright.dev/docs/api/class-testoptions. */
|
||||||
use: {
|
use: {
|
||||||
/* Base URL to use in actions like `await page.goto('/')`. */
|
/* Base URL to use in actions like `await page.goto('/')`. */
|
||||||
@@ -85,7 +84,7 @@ export default defineConfig({
|
|||||||
|
|
||||||
/* Run your local dev server before starting the tests */
|
/* Run your local dev server before starting the tests */
|
||||||
webServer: {
|
webServer: {
|
||||||
command: 'npm run dev',
|
command: 'bun run dev',
|
||||||
url: 'http://localhost:5173',
|
url: 'http://localhost:5173',
|
||||||
reuseExistingServer: !process.env.CI,
|
reuseExistingServer: !process.env.CI,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -0,0 +1,77 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
|
<svg
|
||||||
|
width="500"
|
||||||
|
height="500"
|
||||||
|
viewBox="0 0 132.29167 132.29166"
|
||||||
|
version="1.1"
|
||||||
|
id="svg8"
|
||||||
|
sodipodi:docname="icon-white-nomargin-transparent.svg"
|
||||||
|
inkscape:version="1.3.2 (091e20e, 2023-11-25)"
|
||||||
|
inkscape:export-filename="icon-teal-nomargin-transparent-500.png"
|
||||||
|
inkscape:export-xdpi="96"
|
||||||
|
inkscape:export-ydpi="96"
|
||||||
|
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||||
|
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||||
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
|
xmlns:svg="http://www.w3.org/2000/svg"
|
||||||
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||||
|
xmlns:cc="http://creativecommons.org/ns#"
|
||||||
|
xmlns:dc="http://purl.org/dc/elements/1.1/">
|
||||||
|
<sodipodi:namedview
|
||||||
|
pagecolor="#ffffff"
|
||||||
|
bordercolor="#666666"
|
||||||
|
borderopacity="1"
|
||||||
|
objecttolerance="10"
|
||||||
|
gridtolerance="10"
|
||||||
|
guidetolerance="10"
|
||||||
|
inkscape:pageopacity="0"
|
||||||
|
inkscape:pageshadow="2"
|
||||||
|
inkscape:window-width="1720"
|
||||||
|
inkscape:window-height="1371"
|
||||||
|
id="namedview10"
|
||||||
|
showgrid="false"
|
||||||
|
inkscape:zoom="0.73657628"
|
||||||
|
inkscape:cx="448.01877"
|
||||||
|
inkscape:cy="-91.640203"
|
||||||
|
inkscape:window-x="1720"
|
||||||
|
inkscape:window-y="32"
|
||||||
|
inkscape:window-maximized="0"
|
||||||
|
inkscape:current-layer="g1"
|
||||||
|
inkscape:showpageshadow="2"
|
||||||
|
inkscape:pagecheckerboard="0"
|
||||||
|
inkscape:deskcolor="#d1d1d1"
|
||||||
|
inkscape:document-units="mm" />
|
||||||
|
<defs
|
||||||
|
id="defs2" />
|
||||||
|
<metadata
|
||||||
|
id="metadata5">
|
||||||
|
<rdf:RDF>
|
||||||
|
<cc:Work
|
||||||
|
rdf:about="">
|
||||||
|
<dc:format>image/svg+xml</dc:format>
|
||||||
|
<dc:type
|
||||||
|
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||||
|
</cc:Work>
|
||||||
|
</rdf:RDF>
|
||||||
|
</metadata>
|
||||||
|
<g
|
||||||
|
id="g2149">
|
||||||
|
<g
|
||||||
|
id="g2141">
|
||||||
|
<g
|
||||||
|
id="g1">
|
||||||
|
<path
|
||||||
|
id="path875-5-9-7-3-2-3-9-9-8-0-0-5-87-7"
|
||||||
|
style="fill:#ffffff;fill-opacity:0.980392;stroke:none;stroke-width:0.28098;stop-color:#000000"
|
||||||
|
d="M 66.145833 0 A 66.145836 65.931923 0 0 0 0 65.931893 A 66.145836 65.931923 0 0 0 66.145833 131.86379 A 66.145836 65.931923 0 0 0 132.29167 65.931893 A 66.145836 65.931923 0 0 0 66.145833 0 z M 61.581771 29.853992 L 103.20042 29.853992 L 61.410205 59.222742 L 89.976937 59.222742 L 29.091248 102.00979 L 42.315763 72.641044 L 48.358289 59.222742 L 61.581771 29.853992 z " />
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
<rect
|
||||||
|
y="-49.422424"
|
||||||
|
x="-51.908718"
|
||||||
|
height="162.82199"
|
||||||
|
width="451.52316"
|
||||||
|
id="rect824"
|
||||||
|
style="opacity:0.98;fill:none;fill-opacity:1;stroke-width:0.311037" />
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 2.5 KiB |
@@ -0,0 +1,77 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
|
<svg
|
||||||
|
width="500"
|
||||||
|
height="500"
|
||||||
|
viewBox="0 0 132.29167 132.29166"
|
||||||
|
version="1.1"
|
||||||
|
id="svg8"
|
||||||
|
sodipodi:docname="icon-teal-nomargin-transparent.svg"
|
||||||
|
inkscape:version="1.3.2 (091e20e, 2023-11-25)"
|
||||||
|
inkscape:export-filename="icon-teal-nomargin-192.png"
|
||||||
|
inkscape:export-xdpi="36.863998"
|
||||||
|
inkscape:export-ydpi="36.863998"
|
||||||
|
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||||
|
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||||
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
|
xmlns:svg="http://www.w3.org/2000/svg"
|
||||||
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||||
|
xmlns:cc="http://creativecommons.org/ns#"
|
||||||
|
xmlns:dc="http://purl.org/dc/elements/1.1/">
|
||||||
|
<sodipodi:namedview
|
||||||
|
pagecolor="#ffffff"
|
||||||
|
bordercolor="#666666"
|
||||||
|
borderopacity="1"
|
||||||
|
objecttolerance="10"
|
||||||
|
gridtolerance="10"
|
||||||
|
guidetolerance="10"
|
||||||
|
inkscape:pageopacity="0"
|
||||||
|
inkscape:pageshadow="2"
|
||||||
|
inkscape:window-width="1720"
|
||||||
|
inkscape:window-height="1371"
|
||||||
|
id="namedview10"
|
||||||
|
showgrid="false"
|
||||||
|
inkscape:zoom="0.73657628"
|
||||||
|
inkscape:cx="448.01877"
|
||||||
|
inkscape:cy="-91.640203"
|
||||||
|
inkscape:window-x="1720"
|
||||||
|
inkscape:window-y="32"
|
||||||
|
inkscape:window-maximized="0"
|
||||||
|
inkscape:current-layer="g1"
|
||||||
|
inkscape:showpageshadow="2"
|
||||||
|
inkscape:pagecheckerboard="0"
|
||||||
|
inkscape:deskcolor="#d1d1d1"
|
||||||
|
inkscape:document-units="mm" />
|
||||||
|
<defs
|
||||||
|
id="defs2" />
|
||||||
|
<metadata
|
||||||
|
id="metadata5">
|
||||||
|
<rdf:RDF>
|
||||||
|
<cc:Work
|
||||||
|
rdf:about="">
|
||||||
|
<dc:format>image/svg+xml</dc:format>
|
||||||
|
<dc:type
|
||||||
|
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||||
|
</cc:Work>
|
||||||
|
</rdf:RDF>
|
||||||
|
</metadata>
|
||||||
|
<g
|
||||||
|
id="g2149">
|
||||||
|
<g
|
||||||
|
id="g2141">
|
||||||
|
<g
|
||||||
|
id="g1">
|
||||||
|
<path
|
||||||
|
id="path875-5-9-7-3-2-3-9-9-8-0-0-5-87-7"
|
||||||
|
style="fill:#009688;fill-opacity:0.980392;stroke:none;stroke-width:0.28098;stop-color:#000000"
|
||||||
|
d="M 66.145833 0 A 66.145836 65.931923 0 0 0 0 65.931893 A 66.145836 65.931923 0 0 0 66.145833 131.86379 A 66.145836 65.931923 0 0 0 132.29167 65.931893 A 66.145836 65.931923 0 0 0 66.145833 0 z M 61.581771 29.853992 L 103.20042 29.853992 L 61.410205 59.222742 L 89.976937 59.222742 L 29.091248 102.00979 L 42.315763 72.641044 L 48.358289 59.222742 L 61.581771 29.853992 z " />
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
<rect
|
||||||
|
y="-49.422424"
|
||||||
|
x="-51.908718"
|
||||||
|
height="162.82199"
|
||||||
|
width="451.52316"
|
||||||
|
id="rect824"
|
||||||
|
style="opacity:0.98;fill:none;fill-opacity:1;stroke-width:0.311037" />
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 2.5 KiB |
@@ -0,0 +1,83 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
|
<svg
|
||||||
|
width="341.26324mm"
|
||||||
|
height="63.977489mm"
|
||||||
|
viewBox="0 0 341.26324 63.977485"
|
||||||
|
version="1.1"
|
||||||
|
id="svg8"
|
||||||
|
sodipodi:docname="logo-white-nomargin-vector.svg"
|
||||||
|
inkscape:version="1.3.2 (091e20e, 2023-11-25)"
|
||||||
|
inkscape:export-filename="logo-white-margin-vector.png"
|
||||||
|
inkscape:export-xdpi="57.604134"
|
||||||
|
inkscape:export-ydpi="57.604134"
|
||||||
|
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||||
|
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||||
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
|
xmlns:svg="http://www.w3.org/2000/svg"
|
||||||
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||||
|
xmlns:cc="http://creativecommons.org/ns#"
|
||||||
|
xmlns:dc="http://purl.org/dc/elements/1.1/">
|
||||||
|
<sodipodi:namedview
|
||||||
|
pagecolor="#ffffff"
|
||||||
|
bordercolor="#666666"
|
||||||
|
borderopacity="1"
|
||||||
|
objecttolerance="10"
|
||||||
|
gridtolerance="10"
|
||||||
|
guidetolerance="10"
|
||||||
|
inkscape:pageopacity="0"
|
||||||
|
inkscape:pageshadow="2"
|
||||||
|
inkscape:window-width="1720"
|
||||||
|
inkscape:window-height="1371"
|
||||||
|
id="namedview10"
|
||||||
|
showgrid="false"
|
||||||
|
inkscape:zoom="0.73657628"
|
||||||
|
inkscape:cx="644.8755"
|
||||||
|
inkscape:cy="95.713101"
|
||||||
|
inkscape:window-x="1720"
|
||||||
|
inkscape:window-y="32"
|
||||||
|
inkscape:window-maximized="0"
|
||||||
|
inkscape:current-layer="g2141"
|
||||||
|
inkscape:showpageshadow="2"
|
||||||
|
inkscape:pagecheckerboard="0"
|
||||||
|
inkscape:deskcolor="#d1d1d1"
|
||||||
|
inkscape:document-units="mm" />
|
||||||
|
<defs
|
||||||
|
id="defs2" />
|
||||||
|
<metadata
|
||||||
|
id="metadata5">
|
||||||
|
<rdf:RDF>
|
||||||
|
<cc:Work
|
||||||
|
rdf:about="">
|
||||||
|
<dc:format>image/svg+xml</dc:format>
|
||||||
|
<dc:type
|
||||||
|
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||||
|
</cc:Work>
|
||||||
|
</rdf:RDF>
|
||||||
|
</metadata>
|
||||||
|
<g
|
||||||
|
id="g2149"
|
||||||
|
transform="translate(2.5752783e-4,1.1668595e-4)">
|
||||||
|
<g
|
||||||
|
id="g2141">
|
||||||
|
<g
|
||||||
|
id="g1">
|
||||||
|
<path
|
||||||
|
id="path875-5-9-7-3-2-3-9-9-8-0-0-5-87-7"
|
||||||
|
style="fill:#ffffff;fill-opacity:0.980392;stroke:none;stroke-width:0.136325;stop-color:#000000"
|
||||||
|
d="M 32.092357,-1.166849e-4 A 32.092354,31.988569 0 0 0 -2.5752734e-4,31.988628 32.092354,31.988569 0 0 0 32.092357,63.977374 32.092354,31.988569 0 0 0 64.184455,31.988628 32.092354,31.988569 0 0 0 32.092357,-1.166849e-4 Z M 29.878022,14.484271 H 50.070588 L 29.794823,28.73353 H 43.654442 L 14.114126,49.49247 20.530789,35.243727 23.462393,28.73353 Z" />
|
||||||
|
<path
|
||||||
|
style="font-size:79.7151px;line-height:1.25;font-family:Ubuntu;-inkscape-font-specification:Ubuntu;letter-spacing:0px;word-spacing:0px;fill:#ffffff;stroke-width:1.99288"
|
||||||
|
d="M 89.762163,59.410606 V 4.1680399 H 121.88735 V 9.5089518 H 95.979941 V 28.082571 h 22.957949 v 5.340912 H 95.979941 v 25.987123 z m 51.017587,0.876867 q -4.46405,0 -7.97152,-1.275442 -3.50746,-1.275442 -5.50034,-4.145185 -1.99288,-2.869744 -1.99288,-7.572935 0,-4.543761 2.23203,-7.33379 2.23202,-2.869743 6.13806,-4.145185 3.98576,-1.275442 8.92809,-1.275442 2.23203,0 4.70319,0.398576 2.47117,0.398575 3.10889,0.717436 v -2.391453 q 0,-2.710314 -0.71743,-5.181482 -0.63772,-2.550883 -2.71032,-4.145186 -2.07259,-1.594302 -6.29749,-1.594302 -4.38433,0 -6.69607,0.637721 -2.31174,0.637721 -3.42775,1.036297 l -0.79715,-5.101767 q 1.43487,-0.637721 4.38433,-1.195727 2.94946,-0.558005 6.93522,-0.558005 5.65977,0 8.92809,1.992877 3.34803,1.992878 4.7829,5.500342 1.51459,3.42775 1.51459,7.891796 v 25.907408 q -1.67402,0.398576 -5.97863,1.116012 -4.30462,0.717436 -9.56581,0.717436 z m 0.87686,-5.101767 q 2.79003,0 5.02205,-0.15943 2.23203,-0.239146 3.74661,-0.558006 V 40.597842 q -0.79715,-0.398575 -2.71031,-0.797151 -1.91316,-0.398576 -4.94234,-0.398576 -2.55088,0 -5.18148,0.558006 -2.6306,0.558006 -4.46404,2.232023 -1.75374,1.674017 -1.75374,5.022052 0,4.464045 2.79003,6.217778 2.79003,1.753732 7.49322,1.753732 z m 36.4298,5.181482 q -5.34092,0 -8.37009,-0.956582 -2.94946,-0.876866 -3.98575,-1.355156 l 1.43487,-5.261197 q 0.87686,0.31886 3.58718,1.355157 2.71031,1.036296 7.33379,1.036296 4.38433,0 7.09464,-1.355157 2.71031,-1.355157 2.71031,-4.703191 0,-2.152308 -0.95658,-3.427749 -0.95658,-1.355157 -3.10889,-2.471169 -2.07259,-1.116011 -5.73948,-2.550883 -3.10889,-1.275442 -5.73949,-2.710313 -2.6306,-1.434872 -4.30462,-3.666895 -1.5943,-2.232023 -1.5943,-5.739488 0,-3.427749 1.75373,-5.978632 1.75374,-2.550884 4.94234,-3.985755 3.26832,-1.434872 7.73237,-1.434872 4.14518,0 7.01492,0.717436 2.86975,0.717436 4.06547,1.275441 l -1.35515,5.181482 q -1.0363,-0.558006 -3.34804,-1.275442 -2.31173,-0.797151 -6.53663,-0.797151 -3.34804,0 -5.81921,1.434872 -2.47117,1.355157 -2.47117,4.384331 0,2.152308 1.0363,3.507464 1.0363,1.275442 3.10889,2.311738 2.07259,1.036297 5.10177,2.232023 3.42775,1.355157 6.13806,2.869744 2.79003,1.434872 4.46405,3.74661 1.67401,2.311738 1.67401,6.138063 0,3.74661 -1.91316,6.377208 -1.91316,2.550883 -5.50034,3.826325 -3.50747,1.275442 -8.4498,1.275442 z m 39.21967,-0.07972 q -5.2612,0 -8.29037,-1.833448 -3.02917,-1.833447 -4.30461,-5.500342 -1.19573,-3.666895 -1.19573,-9.167237 V 6.1609175 L 209.494,5.1246211 V 18.118183 h 16.18217 v 5.022051 H 209.494 v 21.124503 q 0,4.38433 0.95658,6.696068 1.0363,2.311738 2.86975,3.188605 1.91316,0.797151 4.46404,0.797151 3.02918,0 5.02205,-0.717436 2.0726,-0.717436 3.26832,-1.275442 l 1.27544,4.862621 q -1.19572,0.717436 -3.98575,1.594302 -2.71031,0.876867 -6.05835,0.876867 z m 11.95723,-0.876867 q 4.30462,-11.55869 7.8918,-21.044787 3.58718,-9.486097 7.01493,-17.776468 3.50746,-8.370086 7.4135,-16.4213111 h 5.58006 q 2.86974,6.0583481 5.50034,12.2761261 2.71032,6.138063 5.34091,12.754416 2.6306,6.616354 5.42063,14.109574 2.86975,7.413504 6.05835,16.10245 h -6.77578 q -1.43488,-3.985755 -2.79003,-7.572934 -1.35516,-3.666895 -2.55089,-7.17436 h -26.30598 q -1.27544,3.507465 -2.6306,7.17436 -1.35516,3.587179 -2.71031,7.572934 z M 242.8946,39.402115 h 22.63909 q -1.51459,-3.985755 -2.94946,-7.732365 -1.43487,-3.746609 -2.86975,-7.254074 -1.35515,-3.507464 -2.79002,-6.775784 -1.35516,-3.348034 -2.79003,-6.536638 -1.35516,3.188604 -2.79003,6.536638 -1.35516,3.26832 -2.79003,6.775784 -1.35516,3.507465 -2.79003,7.254074 -1.43487,3.74661 -2.86974,7.732365 z m 44.481,20.008491 V 5.2043362 q 3.02917,-0.797151 6.93521,-1.1160114 3.98576,-0.3985755 7.33379,-0.3985755 11.71812,0 17.53732,4.5437609 5.89892,4.4640458 5.89892,12.7544168 0,6.297493 -2.94946,10.123818 -2.86974,3.826325 -8.37008,5.580057 -5.42063,1.674017 -13.07328,1.674017 h -7.09465 v 21.044787 z m 6.21777,-26.385699 h 6.53664 q 5.65978,0 9.80496,-0.956581 4.14519,-1.036296 6.37721,-3.666895 2.31174,-2.630598 2.31174,-7.493219 0,-4.703192 -2.39146,-7.254075 -2.39145,-2.550883 -6.21777,-3.587179 -3.82633,-1.0362968 -8.13094,-1.0362968 -2.79003,0 -4.86263,0.2391453 -1.99287,0.1594302 -3.42775,0.3188604 z M 335.0452,59.410606 V 4.1680399 h 6.21778 V 59.410606 Z"
|
||||||
|
id="text979-3"
|
||||||
|
aria-label="FastAPI" />
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
<rect
|
||||||
|
y="-49.422306"
|
||||||
|
x="-51.908459"
|
||||||
|
height="162.82199"
|
||||||
|
width="451.52316"
|
||||||
|
id="rect824"
|
||||||
|
style="opacity:0.98;fill:none;fill-opacity:1;stroke-width:0.311037" />
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 7.0 KiB |
@@ -1,15 +1,43 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
<svg
|
<svg
|
||||||
id="svg8"
|
width="341.26297mm"
|
||||||
version="1.1"
|
|
||||||
viewBox="0 0 346.52395 63.977134"
|
|
||||||
height="63.977139mm"
|
height="63.977139mm"
|
||||||
width="346.52396mm"
|
viewBox="0 0 341.26297 63.977134"
|
||||||
|
version="1.1"
|
||||||
|
id="svg8"
|
||||||
|
sodipodi:docname="logo-teal-nomargin-vector.svg"
|
||||||
|
inkscape:version="1.3.2 (091e20e, 2023-11-25)"
|
||||||
|
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||||
|
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
xmlns:svg="http://www.w3.org/2000/svg"
|
xmlns:svg="http://www.w3.org/2000/svg"
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||||
xmlns:cc="http://creativecommons.org/ns#"
|
xmlns:cc="http://creativecommons.org/ns#"
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/">
|
xmlns:dc="http://purl.org/dc/elements/1.1/">
|
||||||
|
<sodipodi:namedview
|
||||||
|
pagecolor="#ffffff"
|
||||||
|
bordercolor="#666666"
|
||||||
|
borderopacity="1"
|
||||||
|
objecttolerance="10"
|
||||||
|
gridtolerance="10"
|
||||||
|
guidetolerance="10"
|
||||||
|
inkscape:pageopacity="0"
|
||||||
|
inkscape:pageshadow="2"
|
||||||
|
inkscape:window-width="1720"
|
||||||
|
inkscape:window-height="1371"
|
||||||
|
id="namedview10"
|
||||||
|
showgrid="false"
|
||||||
|
inkscape:zoom="0.73657628"
|
||||||
|
inkscape:cx="448.01877"
|
||||||
|
inkscape:cy="-91.640203"
|
||||||
|
inkscape:window-x="1720"
|
||||||
|
inkscape:window-y="32"
|
||||||
|
inkscape:window-maximized="0"
|
||||||
|
inkscape:current-layer="g1"
|
||||||
|
inkscape:showpageshadow="2"
|
||||||
|
inkscape:pagecheckerboard="0"
|
||||||
|
inkscape:deskcolor="#d1d1d1"
|
||||||
|
inkscape:document-units="mm" />
|
||||||
<defs
|
<defs
|
||||||
id="defs2" />
|
id="defs2" />
|
||||||
<metadata
|
<metadata
|
||||||
@@ -28,24 +56,36 @@
|
|||||||
<g
|
<g
|
||||||
id="g2141">
|
id="g2141">
|
||||||
<g
|
<g
|
||||||
id="g2106"
|
id="g1">
|
||||||
transform="matrix(0.96564264,0,0,0.96251987,-899.3295,194.86874)">
|
<g
|
||||||
<circle
|
id="g2106"
|
||||||
style="fill:#009688;fill-opacity:0.980392;stroke:none;stroke-width:0.141404;stop-color:#000000"
|
transform="matrix(0.96564264,0,0,0.96251987,-899.3295,194.86874)">
|
||||||
id="path875-5-9-7-3-2-3-9-9-8-0-0-5-87-7"
|
<circle
|
||||||
cx="964.56165"
|
style="fill:#009688;fill-opacity:0.980392;stroke:none;stroke-width:0.141404;stop-color:#000000"
|
||||||
cy="-169.22266"
|
id="path875-5-9-7-3-2-3-9-9-8-0-0-5-87-7"
|
||||||
r="33.234192" />
|
cx="964.56165"
|
||||||
|
cy="-169.22266"
|
||||||
|
r="33.234192"
|
||||||
|
inkscape:export-xdpi="1543.8315"
|
||||||
|
inkscape:export-ydpi="1543.8315" />
|
||||||
|
<path
|
||||||
|
id="rect1249-6-3-4-4-3-6-6-1-2"
|
||||||
|
style="fill:#ffffff;fill-opacity:0.980392;stroke:none;stroke-width:0.146895;stop-color:#000000"
|
||||||
|
d="m 962.2685,-187.40837 -6.64403,14.80375 -3.03599,6.76393 -6.64456,14.80375 30.59142,-21.56768 h -14.35312 l 20.99715,-14.80375 z" />
|
||||||
|
</g>
|
||||||
<path
|
<path
|
||||||
id="rect1249-6-3-4-4-3-6-6-1-2"
|
style="font-size:79.7151px;line-height:1.25;font-family:Ubuntu;-inkscape-font-specification:Ubuntu;letter-spacing:0px;word-spacing:0px;fill:#009688;stroke-width:1.99288"
|
||||||
style="fill:#ffffff;fill-opacity:0.980392;stroke:none;stroke-width:0.146895;stop-color:#000000"
|
d="M 89.762163,59.410606 V 4.1680399 H 121.88735 V 9.5089518 H 95.979941 V 28.082571 h 22.957949 v 5.340912 H 95.979941 v 25.987123 z m 51.017587,0.876867 q -4.46405,0 -7.97152,-1.275442 -3.50746,-1.275442 -5.50034,-4.145185 -1.99288,-2.869744 -1.99288,-7.572935 0,-4.543761 2.23203,-7.33379 2.23202,-2.869743 6.13806,-4.145185 3.98576,-1.275442 8.92809,-1.275442 2.23203,0 4.70319,0.398576 2.47117,0.398575 3.10889,0.717436 v -2.391453 q 0,-2.710314 -0.71743,-5.181482 -0.63772,-2.550883 -2.71032,-4.145186 -2.07259,-1.594302 -6.29749,-1.594302 -4.38433,0 -6.69607,0.637721 -2.31174,0.637721 -3.42775,1.036297 l -0.79715,-5.101767 q 1.43487,-0.637721 4.38433,-1.195727 2.94946,-0.558005 6.93522,-0.558005 5.65977,0 8.92809,1.992877 3.34803,1.992878 4.7829,5.500342 1.51459,3.42775 1.51459,7.891796 v 25.907408 q -1.67402,0.398576 -5.97863,1.116012 -4.30462,0.717436 -9.56581,0.717436 z m 0.87686,-5.101767 q 2.79003,0 5.02205,-0.15943 2.23203,-0.239146 3.74661,-0.558006 V 40.597842 q -0.79715,-0.398575 -2.71031,-0.797151 -1.91316,-0.398576 -4.94234,-0.398576 -2.55088,0 -5.18148,0.558006 -2.6306,0.558006 -4.46404,2.232023 -1.75374,1.674017 -1.75374,5.022052 0,4.464045 2.79003,6.217778 2.79003,1.753732 7.49322,1.753732 z m 36.4298,5.181482 q -5.34092,0 -8.37009,-0.956582 -2.94946,-0.876866 -3.98575,-1.355156 l 1.43487,-5.261197 q 0.87686,0.31886 3.58718,1.355157 2.71031,1.036296 7.33379,1.036296 4.38433,0 7.09464,-1.355157 2.71031,-1.355157 2.71031,-4.703191 0,-2.152308 -0.95658,-3.427749 -0.95658,-1.355157 -3.10889,-2.471169 -2.07259,-1.116011 -5.73948,-2.550883 -3.10889,-1.275442 -5.73949,-2.710313 -2.6306,-1.434872 -4.30462,-3.666895 -1.5943,-2.232023 -1.5943,-5.739488 0,-3.427749 1.75373,-5.978632 1.75374,-2.550884 4.94234,-3.985755 3.26832,-1.434872 7.73237,-1.434872 4.14518,0 7.01492,0.717436 2.86975,0.717436 4.06547,1.275441 l -1.35515,5.181482 q -1.0363,-0.558006 -3.34804,-1.275442 -2.31173,-0.797151 -6.53663,-0.797151 -3.34804,0 -5.81921,1.434872 -2.47117,1.355157 -2.47117,4.384331 0,2.152308 1.0363,3.507464 1.0363,1.275442 3.10889,2.311738 2.07259,1.036297 5.10177,2.232023 3.42775,1.355157 6.13806,2.869744 2.79003,1.434872 4.46405,3.74661 1.67401,2.311738 1.67401,6.138063 0,3.74661 -1.91316,6.377208 -1.91316,2.550883 -5.50034,3.826325 -3.50747,1.275442 -8.4498,1.275442 z m 39.21967,-0.07972 q -5.2612,0 -8.29037,-1.833448 -3.02917,-1.833447 -4.30461,-5.500342 -1.19573,-3.666895 -1.19573,-9.167237 V 6.1609175 L 209.494,5.1246211 V 18.118183 h 16.18217 v 5.022051 H 209.494 v 21.124503 q 0,4.38433 0.95658,6.696068 1.0363,2.311738 2.86975,3.188605 1.91316,0.797151 4.46404,0.797151 3.02918,0 5.02205,-0.717436 2.0726,-0.717436 3.26832,-1.275442 l 1.27544,4.862621 q -1.19572,0.717436 -3.98575,1.594302 -2.71031,0.876867 -6.05835,0.876867 z m 11.95723,-0.876867 q 4.30462,-11.55869 7.8918,-21.044787 3.58718,-9.486097 7.01493,-17.776468 3.50746,-8.370086 7.4135,-16.4213111 h 5.58006 q 2.86974,6.0583481 5.50034,12.2761261 2.71032,6.138063 5.34091,12.754416 2.6306,6.616354 5.42063,14.109574 2.86975,7.413504 6.05835,16.10245 h -6.77578 q -1.43488,-3.985755 -2.79003,-7.572934 -1.35516,-3.666895 -2.55089,-7.17436 h -26.30598 q -1.27544,3.507465 -2.6306,7.17436 -1.35516,3.587179 -2.71031,7.572934 z M 242.8946,39.402115 h 22.63909 q -1.51459,-3.985755 -2.94946,-7.732365 -1.43487,-3.746609 -2.86975,-7.254074 -1.35515,-3.507464 -2.79002,-6.775784 -1.35516,-3.348034 -2.79003,-6.536638 -1.35516,3.188604 -2.79003,6.536638 -1.35516,3.26832 -2.79003,6.775784 -1.35516,3.507465 -2.79003,7.254074 -1.43487,3.74661 -2.86974,7.732365 z m 44.481,20.008491 V 5.2043362 q 3.02917,-0.797151 6.93521,-1.1160114 3.98576,-0.3985755 7.33379,-0.3985755 11.71812,0 17.53732,4.5437609 5.89892,4.4640458 5.89892,12.7544168 0,6.297493 -2.94946,10.123818 -2.86974,3.826325 -8.37008,5.580057 -5.42063,1.674017 -13.07328,1.674017 h -7.09465 v 21.044787 z m 6.21777,-26.385699 h 6.53664 q 5.65978,0 9.80496,-0.956581 4.14519,-1.036296 6.37721,-3.666895 2.31174,-2.630598 2.31174,-7.493219 0,-4.703192 -2.39146,-7.254075 -2.39145,-2.550883 -6.21777,-3.587179 -3.82633,-1.0362968 -8.13094,-1.0362968 -2.79003,0 -4.86263,0.2391453 -1.99287,0.1594302 -3.42775,0.3188604 z M 335.0452,59.410606 V 4.1680399 h 6.21778 V 59.410606 Z"
|
||||||
d="m 962.2685,-187.40837 -6.64403,14.80375 -3.03599,6.76393 -6.64456,14.80375 30.59142,-21.56768 h -14.35312 l 20.99715,-14.80375 z" />
|
id="text979-3"
|
||||||
|
aria-label="FastAPI" />
|
||||||
</g>
|
</g>
|
||||||
<path
|
|
||||||
style="font-size:79.7151px;line-height:1.25;font-family:Ubuntu;-inkscape-font-specification:Ubuntu;letter-spacing:0px;word-spacing:0px;fill:#009688;stroke-width:1.99288"
|
|
||||||
d="M 89.523017,59.410606 V 4.1680399 H 122.84393 V 10.784393 H 97.255382 V 27.44485 h 22.718808 v 6.536638 H 97.255382 v 25.429118 z m 52.292963,-5.340912 q 2.6306,0 4.62348,-0.07972 2.07259,-0.15943 3.42774,-0.47829 V 41.155848 q -0.79715,-0.398576 -2.63059,-0.637721 -1.75374,-0.31886 -4.30462,-0.31886 -1.67402,0 -3.58718,0.239145 -1.83345,0.239145 -3.42775,1.036296 -1.51459,0.717436 -2.55088,2.072593 -1.0363,1.275442 -1.0363,3.427749 0,3.985755 2.55089,5.580058 2.55088,1.514586 6.93521,1.514586 z m -0.63772,-37.147238 q 4.46404,0 7.49322,1.195727 3.10889,1.116011 4.94233,3.268319 1.91317,2.072593 2.71032,5.022052 0.79715,2.869743 0.79715,6.377208 V 58.69317 q -0.95658,0.159431 -2.71031,0.478291 -1.67402,0.239145 -3.82633,0.478291 -2.15231,0.239145 -4.70319,0.398575 -2.47117,0.239146 -4.94234,0.239146 -3.50746,0 -6.45692,-0.717436 -2.94946,-0.717436 -5.10177,-2.232023 -2.1523,-1.594302 -3.34803,-4.145186 -1.19573,-2.550883 -1.19573,-6.138063 0,-3.427749 1.35516,-5.898917 1.43487,-2.471168 3.82632,-3.985755 2.39146,-1.514587 5.58006,-2.232023 3.18861,-0.717436 6.69607,-0.717436 1.11601,0 2.31174,0.15943 1.19572,0.07972 2.23202,0.31886 1.11601,0.159431 1.91316,0.318861 0.79715,0.15943 1.11601,0.239145 v -2.072593 q 0,-1.833447 -0.39857,-3.587179 -0.39858,-1.833448 -1.43487,-3.188604 -1.0363,-1.434872 -2.86975,-2.232023 -1.75373,-0.876866 -4.62347,-0.876866 -3.6669,0 -6.45693,0.558005 -2.71031,0.478291 -4.06547,1.036297 l -0.87686,-6.138063 q 1.43487,-0.637721 4.7829,-1.195727 3.34804,-0.637721 7.25408,-0.637721 z m 37.86462,37.147238 q 4.54377,0 6.69607,-1.195726 2.23203,-1.195727 2.23203,-3.826325 0,-2.710314 -2.15231,-4.304616 -2.15231,-1.594302 -7.09465,-3.587179 -2.39145,-0.956581 -4.62347,-1.913163 -2.15231,-1.036296 -3.74661,-2.391453 -1.5943,-1.355157 -2.55088,-3.268319 -0.95659,-1.913163 -0.95659,-4.703191 0,-5.500342 4.06547,-8.688946 4.06547,-3.26832 11.0804,-3.26832 1.75374,0 3.50747,0.239146 1.75373,0.15943 3.26832,0.47829 1.51458,0.239146 2.6306,0.558006 1.19572,0.31886 1.83344,0.558006 l -1.35515,6.377208 q -1.19573,-0.637721 -3.74661,-1.275442 -2.55089,-0.717436 -6.13807,-0.717436 -3.10889,0 -5.42062,1.275442 -2.31174,1.195727 -2.31174,3.826325 0,1.355157 0.47829,2.391453 0.55801,1.036296 1.5943,1.913163 1.11601,0.797151 2.71031,1.514587 1.59431,0.717436 3.82633,1.514587 2.94946,1.116011 5.2612,2.232022 2.31173,1.036297 3.90604,2.471169 1.67401,1.434871 2.55088,3.507464 0.87687,1.992878 0.87687,4.942337 0,5.739487 -4.30462,8.688946 -4.2249,2.949459 -12.1167,2.949459 -5.50034,0 -8.60923,-0.956582 -3.10889,-0.876866 -4.2249,-1.355156 l 1.35516,-6.377209 q 1.27544,0.478291 4.06547,1.434872 2.79003,0.956581 7.4135,0.956581 z m 32.84256,-36.110941 h 15.70387 v 6.217778 h -15.70387 v 19.131625 q 0,3.108889 0.47829,5.181481 0.47829,1.992878 1.43487,3.188604 0.95658,1.116012 2.39145,1.594302 1.43487,0.478291 3.34804,0.478291 3.34803,0 5.34091,-0.717436 2.07259,-0.797151 2.86974,-1.116011 l 1.43487,6.138063 q -1.11601,0.558005 -3.90604,1.355156 -2.79003,0.876867 -6.37721,0.876867 -4.2249,0 -7.01492,-1.036297 -2.71032,-1.116011 -4.38434,-3.268319 -1.67401,-2.152308 -2.39145,-5.261197 -0.63772,-3.188604 -0.63772,-7.333789 V 6.4000628 l 7.41351,-1.2754417 z m 62.49652,41.451853 q -1.35516,-3.587179 -2.55088,-7.014929 -1.19573,-3.507464 -2.47117,-7.094644 h -25.03054 l -5.02205,14.109573 h -8.05123 q 3.18861,-8.768661 5.97863,-16.182166 2.79003,-7.493219 5.42063,-14.189288 2.71031,-6.696069 5.34091,-12.754416 2.6306,-6.138063 5.50034,-12.1166961 h 7.09465 q 2.86974,5.9786331 5.50034,12.1166961 2.6306,6.058347 5.2612,12.754416 2.71031,6.696069 5.50034,14.189288 2.79003,7.413505 5.97863,16.182166 z m -7.25407,-20.486781 q -2.55089,-6.935214 -5.10177,-13.392137 -2.47117,-6.536639 -5.18148,-12.515272 -2.79003,5.978633 -5.34091,12.515272 -2.47117,6.456923 -4.94234,13.392137 z M 304.99242,3.6100342 q 11.6384,0 17.85618,4.4640458 6.29749,4.384331 6.29749,13.152992 0,4.782906 -1.75373,8.210656 -1.67402,3.348034 -4.94234,5.500342 -3.1886,2.072592 -7.81208,3.029174 -4.62347,0.956581 -10.44268,0.956581 h -6.13806 v 20.486781 h -7.73236 V 4.9651909 q 3.26832,-0.797151 7.25407,-1.0362963 4.06547,-0.3188604 7.41351,-0.3188604 z m 0.63772,6.7757838 q -4.94234,0 -7.57294,0.239145 v 21.682508 h 5.8192 q 3.98576,0 7.17436,-0.47829 3.18861,-0.558006 5.34092,-1.753733 2.23202,-1.275441 3.42774,-3.427749 1.19573,-2.152308 1.19573,-5.500342 0,-3.188604 -1.27544,-5.261197 -1.19573,-2.072593 -3.34803,-3.268319 -2.0726,-1.275442 -4.86263,-1.753732 -2.79002,-0.478291 -5.89891,-0.478291 z M 338.7916,4.1680399 h 7.73237 V 59.410606 h -7.73237 z"
|
|
||||||
id="text979"
|
|
||||||
aria-label="FastAPI" />
|
|
||||||
</g>
|
</g>
|
||||||
</g>
|
</g>
|
||||||
|
<rect
|
||||||
|
y="-49.422424"
|
||||||
|
x="-51.908718"
|
||||||
|
height="162.82199"
|
||||||
|
width="451.52316"
|
||||||
|
id="rect824"
|
||||||
|
style="opacity:0.98;fill:none;fill-opacity:1;stroke-width:0.311037" />
|
||||||
</svg>
|
</svg>
|
||||||
|
|||||||
|
Before Width: | Height: | Size: 6.2 KiB After Width: | Height: | Size: 7.1 KiB |
@@ -1,25 +1,21 @@
|
|||||||
import type { ApiRequestOptions } from "./ApiRequestOptions"
|
import type { ApiRequestOptions } from './ApiRequestOptions';
|
||||||
import type { ApiResult } from "./ApiResult"
|
import type { ApiResult } from './ApiResult';
|
||||||
|
|
||||||
export class ApiError extends Error {
|
export class ApiError extends Error {
|
||||||
public readonly url: string
|
public readonly url: string;
|
||||||
public readonly status: number
|
public readonly status: number;
|
||||||
public readonly statusText: string
|
public readonly statusText: string;
|
||||||
public readonly body: unknown
|
public readonly body: unknown;
|
||||||
public readonly request: ApiRequestOptions
|
public readonly request: ApiRequestOptions;
|
||||||
|
|
||||||
constructor(
|
constructor(request: ApiRequestOptions, response: ApiResult, message: string) {
|
||||||
request: ApiRequestOptions,
|
super(message);
|
||||||
response: ApiResult,
|
|
||||||
message: string,
|
|
||||||
) {
|
|
||||||
super(message)
|
|
||||||
|
|
||||||
this.name = "ApiError"
|
this.name = 'ApiError';
|
||||||
this.url = response.url
|
this.url = response.url;
|
||||||
this.status = response.status
|
this.status = response.status;
|
||||||
this.statusText = response.statusText
|
this.statusText = response.statusText;
|
||||||
this.body = response.body
|
this.body = response.body;
|
||||||
this.request = request
|
this.request = request;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,20 +1,21 @@
|
|||||||
export type ApiRequestOptions = {
|
export type ApiRequestOptions<T = unknown> = {
|
||||||
readonly method:
|
readonly body?: any;
|
||||||
| "GET"
|
readonly cookies?: Record<string, unknown>;
|
||||||
| "PUT"
|
readonly errors?: Record<number | string, string>;
|
||||||
| "POST"
|
readonly formData?: Record<string, unknown> | any[] | Blob | File;
|
||||||
| "DELETE"
|
readonly headers?: Record<string, unknown>;
|
||||||
| "OPTIONS"
|
readonly mediaType?: string;
|
||||||
| "HEAD"
|
readonly method:
|
||||||
| "PATCH"
|
| 'DELETE'
|
||||||
readonly url: string
|
| 'GET'
|
||||||
readonly path?: Record<string, unknown>
|
| 'HEAD'
|
||||||
readonly cookies?: Record<string, unknown>
|
| 'OPTIONS'
|
||||||
readonly headers?: Record<string, unknown>
|
| 'PATCH'
|
||||||
readonly query?: Record<string, unknown>
|
| 'POST'
|
||||||
readonly formData?: Record<string, unknown>
|
| 'PUT';
|
||||||
readonly body?: any
|
readonly path?: Record<string, unknown>;
|
||||||
readonly mediaType?: string
|
readonly query?: Record<string, unknown>;
|
||||||
readonly responseHeader?: string
|
readonly responseHeader?: string;
|
||||||
readonly errors?: Record<number, string>
|
readonly responseTransformer?: (data: unknown) => Promise<T>;
|
||||||
}
|
readonly url: string;
|
||||||
|
};
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
export type ApiResult<TData = any> = {
|
export type ApiResult<TData = any> = {
|
||||||
readonly body: TData
|
readonly body: TData;
|
||||||
readonly ok: boolean
|
readonly ok: boolean;
|
||||||
readonly status: number
|
readonly status: number;
|
||||||
readonly statusText: string
|
readonly statusText: string;
|
||||||
readonly url: string
|
readonly url: string;
|
||||||
}
|
};
|
||||||
@@ -1,126 +1,126 @@
|
|||||||
export class CancelError extends Error {
|
export class CancelError extends Error {
|
||||||
constructor(message: string) {
|
constructor(message: string) {
|
||||||
super(message)
|
super(message);
|
||||||
this.name = "CancelError"
|
this.name = 'CancelError';
|
||||||
}
|
}
|
||||||
|
|
||||||
public get isCancelled(): boolean {
|
public get isCancelled(): boolean {
|
||||||
return true
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface OnCancel {
|
export interface OnCancel {
|
||||||
readonly isResolved: boolean
|
readonly isResolved: boolean;
|
||||||
readonly isRejected: boolean
|
readonly isRejected: boolean;
|
||||||
readonly isCancelled: boolean
|
readonly isCancelled: boolean;
|
||||||
|
|
||||||
(cancelHandler: () => void): void
|
(cancelHandler: () => void): void;
|
||||||
}
|
}
|
||||||
|
|
||||||
export class CancelablePromise<T> implements Promise<T> {
|
export class CancelablePromise<T> implements Promise<T> {
|
||||||
private _isResolved: boolean
|
private _isResolved: boolean;
|
||||||
private _isRejected: boolean
|
private _isRejected: boolean;
|
||||||
private _isCancelled: boolean
|
private _isCancelled: boolean;
|
||||||
readonly cancelHandlers: (() => void)[]
|
readonly cancelHandlers: (() => void)[];
|
||||||
readonly promise: Promise<T>
|
readonly promise: Promise<T>;
|
||||||
private _resolve?: (value: T | PromiseLike<T>) => void
|
private _resolve?: (value: T | PromiseLike<T>) => void;
|
||||||
private _reject?: (reason?: unknown) => void
|
private _reject?: (reason?: unknown) => void;
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
executor: (
|
executor: (
|
||||||
resolve: (value: T | PromiseLike<T>) => void,
|
resolve: (value: T | PromiseLike<T>) => void,
|
||||||
reject: (reason?: unknown) => void,
|
reject: (reason?: unknown) => void,
|
||||||
onCancel: OnCancel,
|
onCancel: OnCancel
|
||||||
) => void,
|
) => void
|
||||||
) {
|
) {
|
||||||
this._isResolved = false
|
this._isResolved = false;
|
||||||
this._isRejected = false
|
this._isRejected = false;
|
||||||
this._isCancelled = false
|
this._isCancelled = false;
|
||||||
this.cancelHandlers = []
|
this.cancelHandlers = [];
|
||||||
this.promise = new Promise<T>((resolve, reject) => {
|
this.promise = new Promise<T>((resolve, reject) => {
|
||||||
this._resolve = resolve
|
this._resolve = resolve;
|
||||||
this._reject = reject
|
this._reject = reject;
|
||||||
|
|
||||||
const onResolve = (value: T | PromiseLike<T>): void => {
|
const onResolve = (value: T | PromiseLike<T>): void => {
|
||||||
if (this._isResolved || this._isRejected || this._isCancelled) {
|
if (this._isResolved || this._isRejected || this._isCancelled) {
|
||||||
return
|
return;
|
||||||
}
|
}
|
||||||
this._isResolved = true
|
this._isResolved = true;
|
||||||
if (this._resolve) this._resolve(value)
|
if (this._resolve) this._resolve(value);
|
||||||
}
|
};
|
||||||
|
|
||||||
const onReject = (reason?: unknown): void => {
|
const onReject = (reason?: unknown): void => {
|
||||||
if (this._isResolved || this._isRejected || this._isCancelled) {
|
if (this._isResolved || this._isRejected || this._isCancelled) {
|
||||||
return
|
return;
|
||||||
}
|
}
|
||||||
this._isRejected = true
|
this._isRejected = true;
|
||||||
if (this._reject) this._reject(reason)
|
if (this._reject) this._reject(reason);
|
||||||
}
|
};
|
||||||
|
|
||||||
const onCancel = (cancelHandler: () => void): void => {
|
const onCancel = (cancelHandler: () => void): void => {
|
||||||
if (this._isResolved || this._isRejected || this._isCancelled) {
|
if (this._isResolved || this._isRejected || this._isCancelled) {
|
||||||
return
|
return;
|
||||||
}
|
}
|
||||||
this.cancelHandlers.push(cancelHandler)
|
this.cancelHandlers.push(cancelHandler);
|
||||||
}
|
};
|
||||||
|
|
||||||
Object.defineProperty(onCancel, "isResolved", {
|
Object.defineProperty(onCancel, 'isResolved', {
|
||||||
get: (): boolean => this._isResolved,
|
get: (): boolean => this._isResolved,
|
||||||
})
|
});
|
||||||
|
|
||||||
Object.defineProperty(onCancel, "isRejected", {
|
Object.defineProperty(onCancel, 'isRejected', {
|
||||||
get: (): boolean => this._isRejected,
|
get: (): boolean => this._isRejected,
|
||||||
})
|
});
|
||||||
|
|
||||||
Object.defineProperty(onCancel, "isCancelled", {
|
Object.defineProperty(onCancel, 'isCancelled', {
|
||||||
get: (): boolean => this._isCancelled,
|
get: (): boolean => this._isCancelled,
|
||||||
})
|
});
|
||||||
|
|
||||||
return executor(onResolve, onReject, onCancel as OnCancel)
|
return executor(onResolve, onReject, onCancel as OnCancel);
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
get [Symbol.toStringTag]() {
|
get [Symbol.toStringTag]() {
|
||||||
return "Cancellable Promise"
|
return "Cancellable Promise";
|
||||||
}
|
}
|
||||||
|
|
||||||
public then<TResult1 = T, TResult2 = never>(
|
public then<TResult1 = T, TResult2 = never>(
|
||||||
onFulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | null,
|
onFulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | null,
|
||||||
onRejected?: ((reason: unknown) => TResult2 | PromiseLike<TResult2>) | null,
|
onRejected?: ((reason: unknown) => TResult2 | PromiseLike<TResult2>) | null
|
||||||
): Promise<TResult1 | TResult2> {
|
): Promise<TResult1 | TResult2> {
|
||||||
return this.promise.then(onFulfilled, onRejected)
|
return this.promise.then(onFulfilled, onRejected);
|
||||||
}
|
}
|
||||||
|
|
||||||
public catch<TResult = never>(
|
public catch<TResult = never>(
|
||||||
onRejected?: ((reason: unknown) => TResult | PromiseLike<TResult>) | null,
|
onRejected?: ((reason: unknown) => TResult | PromiseLike<TResult>) | null
|
||||||
): Promise<T | TResult> {
|
): Promise<T | TResult> {
|
||||||
return this.promise.catch(onRejected)
|
return this.promise.catch(onRejected);
|
||||||
}
|
}
|
||||||
|
|
||||||
public finally(onFinally?: (() => void) | null): Promise<T> {
|
public finally(onFinally?: (() => void) | null): Promise<T> {
|
||||||
return this.promise.finally(onFinally)
|
return this.promise.finally(onFinally);
|
||||||
}
|
}
|
||||||
|
|
||||||
public cancel(): void {
|
public cancel(): void {
|
||||||
if (this._isResolved || this._isRejected || this._isCancelled) {
|
if (this._isResolved || this._isRejected || this._isCancelled) {
|
||||||
return
|
return;
|
||||||
}
|
}
|
||||||
this._isCancelled = true
|
this._isCancelled = true;
|
||||||
if (this.cancelHandlers.length) {
|
if (this.cancelHandlers.length) {
|
||||||
try {
|
try {
|
||||||
for (const cancelHandler of this.cancelHandlers) {
|
for (const cancelHandler of this.cancelHandlers) {
|
||||||
cancelHandler()
|
cancelHandler();
|
||||||
}
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.warn("Cancellation threw an error", error)
|
console.warn('Cancellation threw an error', error);
|
||||||
return
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
this.cancelHandlers.length = 0
|
this.cancelHandlers.length = 0;
|
||||||
if (this._reject) this._reject(new CancelError("Request aborted"))
|
if (this._reject) this._reject(new CancelError('Request aborted'));
|
||||||
}
|
}
|
||||||
|
|
||||||
public get isCancelled(): boolean {
|
public get isCancelled(): boolean {
|
||||||
return this._isCancelled
|
return this._isCancelled;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,57 +1,57 @@
|
|||||||
import type { AxiosRequestConfig, AxiosResponse } from "axios"
|
import type { AxiosRequestConfig, AxiosResponse } from 'axios';
|
||||||
import type { ApiRequestOptions } from "./ApiRequestOptions"
|
import type { ApiRequestOptions } from './ApiRequestOptions';
|
||||||
import type { TResult } from "./types"
|
|
||||||
|
|
||||||
type Headers = Record<string, string>
|
type Headers = Record<string, string>;
|
||||||
type Middleware<T> = (value: T) => T | Promise<T>
|
type Middleware<T> = (value: T) => T | Promise<T>;
|
||||||
type Resolver<T> = (options: ApiRequestOptions) => Promise<T>
|
type Resolver<T> = (options: ApiRequestOptions<T>) => Promise<T>;
|
||||||
|
|
||||||
export class Interceptors<T> {
|
export class Interceptors<T> {
|
||||||
_fns: Middleware<T>[]
|
_fns: Middleware<T>[];
|
||||||
|
|
||||||
constructor() {
|
constructor() {
|
||||||
this._fns = []
|
this._fns = [];
|
||||||
}
|
}
|
||||||
|
|
||||||
eject(fn: Middleware<T>) {
|
eject(fn: Middleware<T>): void {
|
||||||
const index = this._fns.indexOf(fn)
|
const index = this._fns.indexOf(fn);
|
||||||
if (index !== -1) {
|
if (index !== -1) {
|
||||||
this._fns = [...this._fns.slice(0, index), ...this._fns.slice(index + 1)]
|
this._fns = [...this._fns.slice(0, index), ...this._fns.slice(index + 1)];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
use(fn: Middleware<T>) {
|
use(fn: Middleware<T>): void {
|
||||||
this._fns = [...this._fns, fn]
|
this._fns = [...this._fns, fn];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export type OpenAPIConfig = {
|
export type OpenAPIConfig = {
|
||||||
BASE: string
|
BASE: string;
|
||||||
CREDENTIALS: "include" | "omit" | "same-origin"
|
CREDENTIALS: 'include' | 'omit' | 'same-origin';
|
||||||
ENCODE_PATH?: ((path: string) => string) | undefined
|
ENCODE_PATH?: ((path: string) => string) | undefined;
|
||||||
HEADERS?: Headers | Resolver<Headers> | undefined
|
HEADERS?: Headers | Resolver<Headers> | undefined;
|
||||||
PASSWORD?: string | Resolver<string> | undefined
|
PASSWORD?: string | Resolver<string> | undefined;
|
||||||
RESULT?: TResult
|
TOKEN?: string | Resolver<string> | undefined;
|
||||||
TOKEN?: string | Resolver<string> | undefined
|
USERNAME?: string | Resolver<string> | undefined;
|
||||||
USERNAME?: string | Resolver<string> | undefined
|
VERSION: string;
|
||||||
VERSION: string
|
WITH_CREDENTIALS: boolean;
|
||||||
WITH_CREDENTIALS: boolean
|
interceptors: {
|
||||||
interceptors: {
|
request: Interceptors<AxiosRequestConfig>;
|
||||||
request: Interceptors<AxiosRequestConfig>
|
response: Interceptors<AxiosResponse>;
|
||||||
response: Interceptors<AxiosResponse>
|
};
|
||||||
}
|
};
|
||||||
}
|
|
||||||
|
|
||||||
export const OpenAPI: OpenAPIConfig = {
|
export const OpenAPI: OpenAPIConfig = {
|
||||||
BASE: "",
|
BASE: '',
|
||||||
CREDENTIALS: "include",
|
CREDENTIALS: 'include',
|
||||||
ENCODE_PATH: undefined,
|
ENCODE_PATH: undefined,
|
||||||
HEADERS: undefined,
|
HEADERS: undefined,
|
||||||
PASSWORD: undefined,
|
PASSWORD: undefined,
|
||||||
RESULT: "body",
|
TOKEN: undefined,
|
||||||
TOKEN: undefined,
|
USERNAME: undefined,
|
||||||
USERNAME: undefined,
|
VERSION: '0.1.0',
|
||||||
VERSION: "0.1.0",
|
WITH_CREDENTIALS: false,
|
||||||
WITH_CREDENTIALS: false,
|
interceptors: {
|
||||||
interceptors: { request: new Interceptors(), response: new Interceptors() },
|
request: new Interceptors(),
|
||||||
}
|
response: new Interceptors(),
|
||||||
|
},
|
||||||
|
};
|
||||||
+280
-309
@@ -1,319 +1,301 @@
|
|||||||
import axios from "axios"
|
import axios from 'axios';
|
||||||
import type {
|
import type { AxiosError, AxiosRequestConfig, AxiosResponse, AxiosInstance } from 'axios';
|
||||||
AxiosError,
|
|
||||||
AxiosInstance,
|
|
||||||
AxiosRequestConfig,
|
|
||||||
AxiosResponse,
|
|
||||||
} from "axios"
|
|
||||||
|
|
||||||
import { ApiError } from "./ApiError"
|
import { ApiError } from './ApiError';
|
||||||
import type { ApiRequestOptions } from "./ApiRequestOptions"
|
import type { ApiRequestOptions } from './ApiRequestOptions';
|
||||||
import type { ApiResult } from "./ApiResult"
|
import type { ApiResult } from './ApiResult';
|
||||||
import { CancelablePromise } from "./CancelablePromise"
|
import { CancelablePromise } from './CancelablePromise';
|
||||||
import type { OnCancel } from "./CancelablePromise"
|
import type { OnCancel } from './CancelablePromise';
|
||||||
import type { OpenAPIConfig } from "./OpenAPI"
|
import type { OpenAPIConfig } from './OpenAPI';
|
||||||
|
|
||||||
export const isString = (value: unknown): value is string => {
|
export const isString = (value: unknown): value is string => {
|
||||||
return typeof value === "string"
|
return typeof value === 'string';
|
||||||
}
|
};
|
||||||
|
|
||||||
export const isStringWithValue = (value: unknown): value is string => {
|
export const isStringWithValue = (value: unknown): value is string => {
|
||||||
return isString(value) && value !== ""
|
return isString(value) && value !== '';
|
||||||
}
|
};
|
||||||
|
|
||||||
export const isBlob = (value: any): value is Blob => {
|
export const isBlob = (value: any): value is Blob => {
|
||||||
return value instanceof Blob
|
return value instanceof Blob;
|
||||||
}
|
};
|
||||||
|
|
||||||
export const isFormData = (value: unknown): value is FormData => {
|
export const isFormData = (value: unknown): value is FormData => {
|
||||||
return value instanceof FormData
|
return value instanceof FormData;
|
||||||
}
|
};
|
||||||
|
|
||||||
export const isSuccess = (status: number): boolean => {
|
export const isSuccess = (status: number): boolean => {
|
||||||
return status >= 200 && status < 300
|
return status >= 200 && status < 300;
|
||||||
}
|
};
|
||||||
|
|
||||||
export const base64 = (str: string): string => {
|
export const base64 = (str: string): string => {
|
||||||
try {
|
try {
|
||||||
return btoa(str)
|
return btoa(str);
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
return Buffer.from(str).toString("base64")
|
return Buffer.from(str).toString('base64');
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
|
|
||||||
export const getQueryString = (params: Record<string, unknown>): string => {
|
export const getQueryString = (params: Record<string, unknown>): string => {
|
||||||
const qs: string[] = []
|
const qs: string[] = [];
|
||||||
|
|
||||||
const append = (key: string, value: unknown) => {
|
const append = (key: string, value: unknown) => {
|
||||||
qs.push(`${encodeURIComponent(key)}=${encodeURIComponent(String(value))}`)
|
qs.push(`${encodeURIComponent(key)}=${encodeURIComponent(String(value))}`);
|
||||||
}
|
};
|
||||||
|
|
||||||
const encodePair = (key: string, value: unknown) => {
|
const encodePair = (key: string, value: unknown) => {
|
||||||
if (value === undefined || value === null) {
|
if (value === undefined || value === null) {
|
||||||
return
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Array.isArray(value)) {
|
if (value instanceof Date) {
|
||||||
value.forEach((v) => encodePair(key, v))
|
append(key, value.toISOString());
|
||||||
} else if (typeof value === "object") {
|
} else if (Array.isArray(value)) {
|
||||||
Object.entries(value).forEach(([k, v]) => encodePair(`${key}[${k}]`, v))
|
value.forEach(v => encodePair(key, v));
|
||||||
} else {
|
} else if (typeof value === 'object') {
|
||||||
append(key, value)
|
Object.entries(value).forEach(([k, v]) => encodePair(`${key}[${k}]`, v));
|
||||||
}
|
} else {
|
||||||
}
|
append(key, value);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
Object.entries(params).forEach(([key, value]) => encodePair(key, value))
|
Object.entries(params).forEach(([key, value]) => encodePair(key, value));
|
||||||
|
|
||||||
return qs.length ? `?${qs.join("&")}` : ""
|
return qs.length ? `?${qs.join('&')}` : '';
|
||||||
}
|
};
|
||||||
|
|
||||||
const getUrl = (config: OpenAPIConfig, options: ApiRequestOptions): string => {
|
const getUrl = (config: OpenAPIConfig, options: ApiRequestOptions): string => {
|
||||||
const encoder = config.ENCODE_PATH || encodeURI
|
const encoder = config.ENCODE_PATH || encodeURI;
|
||||||
|
|
||||||
const path = options.url
|
const path = options.url
|
||||||
.replace("{api-version}", config.VERSION)
|
.replace('{api-version}', config.VERSION)
|
||||||
.replace(/{(.*?)}/g, (substring: string, group: string) => {
|
.replace(/{(.*?)}/g, (substring: string, group: string) => {
|
||||||
if (options.path?.hasOwnProperty(group)) {
|
if (options.path?.hasOwnProperty(group)) {
|
||||||
return encoder(String(options.path[group]))
|
return encoder(String(options.path[group]));
|
||||||
}
|
}
|
||||||
return substring
|
return substring;
|
||||||
})
|
});
|
||||||
|
|
||||||
const url = config.BASE + path
|
const url = config.BASE + path;
|
||||||
return options.query ? url + getQueryString(options.query) : url
|
return options.query ? url + getQueryString(options.query) : url;
|
||||||
}
|
};
|
||||||
|
|
||||||
export const getFormData = (
|
export const getFormData = (options: ApiRequestOptions): FormData | undefined => {
|
||||||
options: ApiRequestOptions,
|
if (options.formData) {
|
||||||
): FormData | undefined => {
|
const formData = new FormData();
|
||||||
if (options.formData) {
|
|
||||||
const formData = new FormData()
|
|
||||||
|
|
||||||
const process = (key: string, value: unknown) => {
|
const process = (key: string, value: unknown) => {
|
||||||
if (isString(value) || isBlob(value)) {
|
if (isString(value) || isBlob(value)) {
|
||||||
formData.append(key, value)
|
formData.append(key, value);
|
||||||
} else {
|
} else {
|
||||||
formData.append(key, JSON.stringify(value))
|
formData.append(key, JSON.stringify(value));
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
|
|
||||||
Object.entries(options.formData)
|
Object.entries(options.formData)
|
||||||
.filter(([, value]) => value !== undefined && value !== null)
|
.filter(([, value]) => value !== undefined && value !== null)
|
||||||
.forEach(([key, value]) => {
|
.forEach(([key, value]) => {
|
||||||
if (Array.isArray(value)) {
|
if (Array.isArray(value)) {
|
||||||
value.forEach((v) => process(key, v))
|
value.forEach(v => process(key, v));
|
||||||
} else {
|
} else {
|
||||||
process(key, value)
|
process(key, value);
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
|
|
||||||
return formData
|
return formData;
|
||||||
}
|
}
|
||||||
return undefined
|
return undefined;
|
||||||
}
|
};
|
||||||
|
|
||||||
type Resolver<T> = (options: ApiRequestOptions) => Promise<T>
|
type Resolver<T> = (options: ApiRequestOptions<T>) => Promise<T>;
|
||||||
|
|
||||||
export const resolve = async <T>(
|
export const resolve = async <T>(options: ApiRequestOptions<T>, resolver?: T | Resolver<T>): Promise<T | undefined> => {
|
||||||
options: ApiRequestOptions,
|
if (typeof resolver === 'function') {
|
||||||
resolver?: T | Resolver<T>,
|
return (resolver as Resolver<T>)(options);
|
||||||
): Promise<T | undefined> => {
|
}
|
||||||
if (typeof resolver === "function") {
|
return resolver;
|
||||||
return (resolver as Resolver<T>)(options)
|
};
|
||||||
}
|
|
||||||
return resolver
|
|
||||||
}
|
|
||||||
|
|
||||||
export const getHeaders = async (
|
export const getHeaders = async <T>(config: OpenAPIConfig, options: ApiRequestOptions<T>): Promise<Record<string, string>> => {
|
||||||
config: OpenAPIConfig,
|
const [token, username, password, additionalHeaders] = await Promise.all([
|
||||||
options: ApiRequestOptions,
|
// @ts-ignore
|
||||||
): Promise<Record<string, string>> => {
|
resolve(options, config.TOKEN),
|
||||||
const [token, username, password, additionalHeaders] = await Promise.all([
|
// @ts-ignore
|
||||||
resolve(options, config.TOKEN),
|
resolve(options, config.USERNAME),
|
||||||
resolve(options, config.USERNAME),
|
// @ts-ignore
|
||||||
resolve(options, config.PASSWORD),
|
resolve(options, config.PASSWORD),
|
||||||
resolve(options, config.HEADERS),
|
// @ts-ignore
|
||||||
])
|
resolve(options, config.HEADERS),
|
||||||
|
]);
|
||||||
|
|
||||||
const headers = Object.entries({
|
const headers = Object.entries({
|
||||||
Accept: "application/json",
|
Accept: 'application/json',
|
||||||
...additionalHeaders,
|
...additionalHeaders,
|
||||||
...options.headers,
|
...options.headers,
|
||||||
})
|
})
|
||||||
.filter(([, value]) => value !== undefined && value !== null)
|
.filter(([, value]) => value !== undefined && value !== null)
|
||||||
.reduce(
|
.reduce((headers, [key, value]) => ({
|
||||||
(headers, [key, value]) => ({
|
...headers,
|
||||||
...headers,
|
[key]: String(value),
|
||||||
[key]: String(value),
|
}), {} as Record<string, string>);
|
||||||
}),
|
|
||||||
{} as Record<string, string>,
|
|
||||||
)
|
|
||||||
|
|
||||||
if (isStringWithValue(token)) {
|
if (isStringWithValue(token)) {
|
||||||
headers.Authorization = `Bearer ${token}`
|
headers['Authorization'] = `Bearer ${token}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isStringWithValue(username) && isStringWithValue(password)) {
|
if (isStringWithValue(username) && isStringWithValue(password)) {
|
||||||
const credentials = base64(`${username}:${password}`)
|
const credentials = base64(`${username}:${password}`);
|
||||||
headers.Authorization = `Basic ${credentials}`
|
headers['Authorization'] = `Basic ${credentials}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (options.body !== undefined) {
|
if (options.body !== undefined) {
|
||||||
if (options.mediaType) {
|
if (options.mediaType) {
|
||||||
headers["Content-Type"] = options.mediaType
|
headers['Content-Type'] = options.mediaType;
|
||||||
} else if (isBlob(options.body)) {
|
} else if (isBlob(options.body)) {
|
||||||
headers["Content-Type"] = options.body.type || "application/octet-stream"
|
headers['Content-Type'] = options.body.type || 'application/octet-stream';
|
||||||
} else if (isString(options.body)) {
|
} else if (isString(options.body)) {
|
||||||
headers["Content-Type"] = "text/plain"
|
headers['Content-Type'] = 'text/plain';
|
||||||
} else if (!isFormData(options.body)) {
|
} else if (!isFormData(options.body)) {
|
||||||
headers["Content-Type"] = "application/json"
|
headers['Content-Type'] = 'application/json';
|
||||||
}
|
}
|
||||||
} else if (options.formData !== undefined) {
|
} else if (options.formData !== undefined) {
|
||||||
if (options.mediaType) {
|
if (options.mediaType) {
|
||||||
headers["Content-Type"] = options.mediaType
|
headers['Content-Type'] = options.mediaType;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return headers
|
return headers;
|
||||||
}
|
};
|
||||||
|
|
||||||
export const getRequestBody = (options: ApiRequestOptions): unknown => {
|
export const getRequestBody = (options: ApiRequestOptions): unknown => {
|
||||||
if (options.body) {
|
if (options.body) {
|
||||||
return options.body
|
return options.body;
|
||||||
}
|
}
|
||||||
return undefined
|
return undefined;
|
||||||
}
|
};
|
||||||
|
|
||||||
export const sendRequest = async <T>(
|
export const sendRequest = async <T>(
|
||||||
config: OpenAPIConfig,
|
config: OpenAPIConfig,
|
||||||
options: ApiRequestOptions,
|
options: ApiRequestOptions<T>,
|
||||||
url: string,
|
url: string,
|
||||||
body: unknown,
|
body: unknown,
|
||||||
formData: FormData | undefined,
|
formData: FormData | undefined,
|
||||||
headers: Record<string, string>,
|
headers: Record<string, string>,
|
||||||
onCancel: OnCancel,
|
onCancel: OnCancel,
|
||||||
axiosClient: AxiosInstance,
|
axiosClient: AxiosInstance
|
||||||
): Promise<AxiosResponse<T>> => {
|
): Promise<AxiosResponse<T>> => {
|
||||||
const controller = new AbortController()
|
const controller = new AbortController();
|
||||||
|
|
||||||
let requestConfig: AxiosRequestConfig = {
|
let requestConfig: AxiosRequestConfig = {
|
||||||
data: body ?? formData,
|
data: body ?? formData,
|
||||||
headers,
|
headers,
|
||||||
method: options.method,
|
method: options.method,
|
||||||
signal: controller.signal,
|
signal: controller.signal,
|
||||||
url,
|
url,
|
||||||
withCredentials: config.WITH_CREDENTIALS,
|
withCredentials: config.WITH_CREDENTIALS,
|
||||||
}
|
};
|
||||||
|
|
||||||
onCancel(() => controller.abort())
|
onCancel(() => controller.abort());
|
||||||
|
|
||||||
for (const fn of config.interceptors.request._fns) {
|
for (const fn of config.interceptors.request._fns) {
|
||||||
requestConfig = await fn(requestConfig)
|
requestConfig = await fn(requestConfig);
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
return await axiosClient.request(requestConfig)
|
return await axiosClient.request(requestConfig);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
const axiosError = error as AxiosError<T>
|
const axiosError = error as AxiosError<T>;
|
||||||
if (axiosError.response) {
|
if (axiosError.response) {
|
||||||
return axiosError.response
|
return axiosError.response;
|
||||||
}
|
}
|
||||||
throw error
|
throw error;
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
|
|
||||||
export const getResponseHeader = (
|
export const getResponseHeader = (response: AxiosResponse<unknown>, responseHeader?: string): string | undefined => {
|
||||||
response: AxiosResponse<unknown>,
|
if (responseHeader) {
|
||||||
responseHeader?: string,
|
const content = response.headers[responseHeader];
|
||||||
): string | undefined => {
|
if (isString(content)) {
|
||||||
if (responseHeader) {
|
return content;
|
||||||
const content = response.headers[responseHeader]
|
}
|
||||||
if (isString(content)) {
|
}
|
||||||
return content
|
return undefined;
|
||||||
}
|
};
|
||||||
}
|
|
||||||
return undefined
|
|
||||||
}
|
|
||||||
|
|
||||||
export const getResponseBody = (response: AxiosResponse<unknown>): unknown => {
|
export const getResponseBody = (response: AxiosResponse<unknown>): unknown => {
|
||||||
if (response.status !== 204) {
|
if (response.status !== 204) {
|
||||||
return response.data
|
return response.data;
|
||||||
}
|
}
|
||||||
return undefined
|
return undefined;
|
||||||
}
|
};
|
||||||
|
|
||||||
export const catchErrorCodes = (
|
export const catchErrorCodes = (options: ApiRequestOptions, result: ApiResult): void => {
|
||||||
options: ApiRequestOptions,
|
const errors: Record<number, string> = {
|
||||||
result: ApiResult,
|
400: 'Bad Request',
|
||||||
): void => {
|
401: 'Unauthorized',
|
||||||
const errors: Record<number, string> = {
|
402: 'Payment Required',
|
||||||
400: "Bad Request",
|
403: 'Forbidden',
|
||||||
401: "Unauthorized",
|
404: 'Not Found',
|
||||||
402: "Payment Required",
|
405: 'Method Not Allowed',
|
||||||
403: "Forbidden",
|
406: 'Not Acceptable',
|
||||||
404: "Not Found",
|
407: 'Proxy Authentication Required',
|
||||||
405: "Method Not Allowed",
|
408: 'Request Timeout',
|
||||||
406: "Not Acceptable",
|
409: 'Conflict',
|
||||||
407: "Proxy Authentication Required",
|
410: 'Gone',
|
||||||
408: "Request Timeout",
|
411: 'Length Required',
|
||||||
409: "Conflict",
|
412: 'Precondition Failed',
|
||||||
410: "Gone",
|
413: 'Payload Too Large',
|
||||||
411: "Length Required",
|
414: 'URI Too Long',
|
||||||
412: "Precondition Failed",
|
415: 'Unsupported Media Type',
|
||||||
413: "Payload Too Large",
|
416: 'Range Not Satisfiable',
|
||||||
414: "URI Too Long",
|
417: 'Expectation Failed',
|
||||||
415: "Unsupported Media Type",
|
418: 'Im a teapot',
|
||||||
416: "Range Not Satisfiable",
|
421: 'Misdirected Request',
|
||||||
417: "Expectation Failed",
|
422: 'Unprocessable Content',
|
||||||
418: "Im a teapot",
|
423: 'Locked',
|
||||||
421: "Misdirected Request",
|
424: 'Failed Dependency',
|
||||||
422: "Unprocessable Content",
|
425: 'Too Early',
|
||||||
423: "Locked",
|
426: 'Upgrade Required',
|
||||||
424: "Failed Dependency",
|
428: 'Precondition Required',
|
||||||
425: "Too Early",
|
429: 'Too Many Requests',
|
||||||
426: "Upgrade Required",
|
431: 'Request Header Fields Too Large',
|
||||||
428: "Precondition Required",
|
451: 'Unavailable For Legal Reasons',
|
||||||
429: "Too Many Requests",
|
500: 'Internal Server Error',
|
||||||
431: "Request Header Fields Too Large",
|
501: 'Not Implemented',
|
||||||
451: "Unavailable For Legal Reasons",
|
502: 'Bad Gateway',
|
||||||
500: "Internal Server Error",
|
503: 'Service Unavailable',
|
||||||
501: "Not Implemented",
|
504: 'Gateway Timeout',
|
||||||
502: "Bad Gateway",
|
505: 'HTTP Version Not Supported',
|
||||||
503: "Service Unavailable",
|
506: 'Variant Also Negotiates',
|
||||||
504: "Gateway Timeout",
|
507: 'Insufficient Storage',
|
||||||
505: "HTTP Version Not Supported",
|
508: 'Loop Detected',
|
||||||
506: "Variant Also Negotiates",
|
510: 'Not Extended',
|
||||||
507: "Insufficient Storage",
|
511: 'Network Authentication Required',
|
||||||
508: "Loop Detected",
|
...options.errors,
|
||||||
510: "Not Extended",
|
}
|
||||||
511: "Network Authentication Required",
|
|
||||||
...options.errors,
|
|
||||||
}
|
|
||||||
|
|
||||||
const error = errors[result.status]
|
const error = errors[result.status];
|
||||||
if (error) {
|
if (error) {
|
||||||
throw new ApiError(options, result, error)
|
throw new ApiError(options, result, error);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!result.ok) {
|
if (!result.ok) {
|
||||||
const errorStatus = result.status ?? "unknown"
|
const errorStatus = result.status ?? 'unknown';
|
||||||
const errorStatusText = result.statusText ?? "unknown"
|
const errorStatusText = result.statusText ?? 'unknown';
|
||||||
const errorBody = (() => {
|
const errorBody = (() => {
|
||||||
try {
|
try {
|
||||||
return JSON.stringify(result.body, null, 2)
|
return JSON.stringify(result.body, null, 2);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
return undefined
|
return undefined;
|
||||||
}
|
}
|
||||||
})()
|
})();
|
||||||
|
|
||||||
throw new ApiError(
|
throw new ApiError(options, result,
|
||||||
options,
|
`Generic Error: status: ${errorStatus}; status text: ${errorStatusText}; body: ${errorBody}`
|
||||||
result,
|
);
|
||||||
`Generic Error: status: ${errorStatus}; status text: ${errorStatusText}; body: ${errorBody}`,
|
}
|
||||||
)
|
};
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Request method
|
* Request method
|
||||||
@@ -323,54 +305,43 @@ export const catchErrorCodes = (
|
|||||||
* @returns CancelablePromise<T>
|
* @returns CancelablePromise<T>
|
||||||
* @throws ApiError
|
* @throws ApiError
|
||||||
*/
|
*/
|
||||||
export const request = <T>(
|
export const request = <T>(config: OpenAPIConfig, options: ApiRequestOptions<T>, axiosClient: AxiosInstance = axios): CancelablePromise<T> => {
|
||||||
config: OpenAPIConfig,
|
return new CancelablePromise(async (resolve, reject, onCancel) => {
|
||||||
options: ApiRequestOptions,
|
try {
|
||||||
axiosClient: AxiosInstance = axios,
|
const url = getUrl(config, options);
|
||||||
): CancelablePromise<T> => {
|
const formData = getFormData(options);
|
||||||
return new CancelablePromise(async (resolve, reject, onCancel) => {
|
const body = getRequestBody(options);
|
||||||
try {
|
const headers = await getHeaders(config, options);
|
||||||
const url = getUrl(config, options)
|
|
||||||
const formData = getFormData(options)
|
|
||||||
const body = getRequestBody(options)
|
|
||||||
const headers = await getHeaders(config, options)
|
|
||||||
|
|
||||||
if (!onCancel.isCancelled) {
|
if (!onCancel.isCancelled) {
|
||||||
let response = await sendRequest<T>(
|
let response = await sendRequest<T>(config, options, url, body, formData, headers, onCancel, axiosClient);
|
||||||
config,
|
|
||||||
options,
|
|
||||||
url,
|
|
||||||
body,
|
|
||||||
formData,
|
|
||||||
headers,
|
|
||||||
onCancel,
|
|
||||||
axiosClient,
|
|
||||||
)
|
|
||||||
|
|
||||||
for (const fn of config.interceptors.response._fns) {
|
for (const fn of config.interceptors.response._fns) {
|
||||||
response = await fn(response)
|
response = await fn(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
const responseBody = getResponseBody(response)
|
const responseBody = getResponseBody(response);
|
||||||
const responseHeader = getResponseHeader(
|
const responseHeader = getResponseHeader(response, options.responseHeader);
|
||||||
response,
|
|
||||||
options.responseHeader,
|
|
||||||
)
|
|
||||||
|
|
||||||
const result: ApiResult = {
|
let transformedBody = responseBody;
|
||||||
url,
|
if (options.responseTransformer && isSuccess(response.status)) {
|
||||||
ok: isSuccess(response.status),
|
transformedBody = await options.responseTransformer(responseBody)
|
||||||
status: response.status,
|
}
|
||||||
statusText: response.statusText,
|
|
||||||
body: responseHeader ?? responseBody,
|
|
||||||
}
|
|
||||||
|
|
||||||
catchErrorCodes(options, result)
|
const result: ApiResult = {
|
||||||
|
url,
|
||||||
|
ok: isSuccess(response.status),
|
||||||
|
status: response.status,
|
||||||
|
statusText: response.statusText,
|
||||||
|
body: responseHeader ?? transformedBody,
|
||||||
|
};
|
||||||
|
|
||||||
resolve(result.body)
|
catchErrorCodes(options, result);
|
||||||
}
|
|
||||||
} catch (error) {
|
resolve(result.body);
|
||||||
reject(error)
|
}
|
||||||
}
|
} catch (error) {
|
||||||
})
|
reject(error);
|
||||||
}
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
@@ -1,14 +0,0 @@
|
|||||||
import type { ApiResult } from "./ApiResult"
|
|
||||||
|
|
||||||
export type TResult = "body" | "raw"
|
|
||||||
|
|
||||||
export type TApiResponse<T extends TResult, TData> = Exclude<
|
|
||||||
T,
|
|
||||||
"raw"
|
|
||||||
> extends never
|
|
||||||
? ApiResult<TData>
|
|
||||||
: ApiResult<TData>["body"]
|
|
||||||
|
|
||||||
export type TConfig<T extends TResult> = {
|
|
||||||
_result?: T
|
|
||||||
}
|
|
||||||
@@ -1,8 +1,6 @@
|
|||||||
export { ApiError } from "./core/ApiError"
|
// This file is auto-generated by @hey-api/openapi-ts
|
||||||
export { CancelablePromise, CancelError } from "./core/CancelablePromise"
|
export { ApiError } from './core/ApiError';
|
||||||
export { OpenAPI } from "./core/OpenAPI"
|
export { CancelablePromise, CancelError } from './core/CancelablePromise';
|
||||||
export type { OpenAPIConfig } from "./core/OpenAPI"
|
export { OpenAPI, type OpenAPIConfig } from './core/OpenAPI';
|
||||||
|
export * from './sdk.gen';
|
||||||
export * from "./models"
|
export * from './types.gen';
|
||||||
export * from "./schemas"
|
|
||||||
export * from "./services"
|
|
||||||
@@ -1,99 +0,0 @@
|
|||||||
export type Body_login_login_access_token = {
|
|
||||||
grant_type?: string | null
|
|
||||||
username: string
|
|
||||||
password: string
|
|
||||||
scope?: string
|
|
||||||
client_id?: string | null
|
|
||||||
client_secret?: string | null
|
|
||||||
}
|
|
||||||
|
|
||||||
export type HTTPValidationError = {
|
|
||||||
detail?: Array<ValidationError>
|
|
||||||
}
|
|
||||||
|
|
||||||
export type ItemCreate = {
|
|
||||||
title: string
|
|
||||||
description?: string | null
|
|
||||||
}
|
|
||||||
|
|
||||||
export type ItemPublic = {
|
|
||||||
title: string
|
|
||||||
description?: string | null
|
|
||||||
id: string
|
|
||||||
owner_id: string
|
|
||||||
}
|
|
||||||
|
|
||||||
export type ItemUpdate = {
|
|
||||||
title?: string | null
|
|
||||||
description?: string | null
|
|
||||||
}
|
|
||||||
|
|
||||||
export type ItemsPublic = {
|
|
||||||
data: Array<ItemPublic>
|
|
||||||
count: number
|
|
||||||
}
|
|
||||||
|
|
||||||
export type Message = {
|
|
||||||
message: string
|
|
||||||
}
|
|
||||||
|
|
||||||
export type NewPassword = {
|
|
||||||
token: string
|
|
||||||
new_password: string
|
|
||||||
}
|
|
||||||
|
|
||||||
export type Token = {
|
|
||||||
access_token: string
|
|
||||||
token_type?: string
|
|
||||||
}
|
|
||||||
|
|
||||||
export type UpdatePassword = {
|
|
||||||
current_password: string
|
|
||||||
new_password: string
|
|
||||||
}
|
|
||||||
|
|
||||||
export type UserCreate = {
|
|
||||||
email: string
|
|
||||||
is_active?: boolean
|
|
||||||
is_superuser?: boolean
|
|
||||||
full_name?: string | null
|
|
||||||
password: string
|
|
||||||
}
|
|
||||||
|
|
||||||
export type UserPublic = {
|
|
||||||
email: string
|
|
||||||
is_active?: boolean
|
|
||||||
is_superuser?: boolean
|
|
||||||
full_name?: string | null
|
|
||||||
id: string
|
|
||||||
}
|
|
||||||
|
|
||||||
export type UserRegister = {
|
|
||||||
email: string
|
|
||||||
password: string
|
|
||||||
full_name?: string | null
|
|
||||||
}
|
|
||||||
|
|
||||||
export type UserUpdate = {
|
|
||||||
email?: string | null
|
|
||||||
is_active?: boolean
|
|
||||||
is_superuser?: boolean
|
|
||||||
full_name?: string | null
|
|
||||||
password?: string | null
|
|
||||||
}
|
|
||||||
|
|
||||||
export type UserUpdateMe = {
|
|
||||||
full_name?: string | null
|
|
||||||
email?: string | null
|
|
||||||
}
|
|
||||||
|
|
||||||
export type UsersPublic = {
|
|
||||||
data: Array<UserPublic>
|
|
||||||
count: number
|
|
||||||
}
|
|
||||||
|
|
||||||
export type ValidationError = {
|
|
||||||
loc: Array<string | number>
|
|
||||||
msg: string
|
|
||||||
type: string
|
|
||||||
}
|
|
||||||
@@ -0,0 +1,552 @@
|
|||||||
|
// This file is auto-generated by @hey-api/openapi-ts
|
||||||
|
|
||||||
|
export const Body_login_login_access_tokenSchema = {
|
||||||
|
properties: {
|
||||||
|
grant_type: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
pattern: '^password$'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Grant Type'
|
||||||
|
},
|
||||||
|
username: {
|
||||||
|
type: 'string',
|
||||||
|
title: 'Username'
|
||||||
|
},
|
||||||
|
password: {
|
||||||
|
type: 'string',
|
||||||
|
format: 'password',
|
||||||
|
title: 'Password'
|
||||||
|
},
|
||||||
|
scope: {
|
||||||
|
type: 'string',
|
||||||
|
title: 'Scope',
|
||||||
|
default: ''
|
||||||
|
},
|
||||||
|
client_id: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Client Id'
|
||||||
|
},
|
||||||
|
client_secret: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
format: 'password',
|
||||||
|
title: 'Client Secret'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['username', 'password'],
|
||||||
|
title: 'Body_login-login_access_token'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const HTTPValidationErrorSchema = {
|
||||||
|
properties: {
|
||||||
|
detail: {
|
||||||
|
items: {
|
||||||
|
'$ref': '#/components/schemas/ValidationError'
|
||||||
|
},
|
||||||
|
type: 'array',
|
||||||
|
title: 'Detail'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
title: 'HTTPValidationError'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const ItemCreateSchema = {
|
||||||
|
properties: {
|
||||||
|
title: {
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255,
|
||||||
|
minLength: 1,
|
||||||
|
title: 'Title'
|
||||||
|
},
|
||||||
|
description: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Description'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['title'],
|
||||||
|
title: 'ItemCreate'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const ItemPublicSchema = {
|
||||||
|
properties: {
|
||||||
|
title: {
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255,
|
||||||
|
minLength: 1,
|
||||||
|
title: 'Title'
|
||||||
|
},
|
||||||
|
description: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Description'
|
||||||
|
},
|
||||||
|
id: {
|
||||||
|
type: 'string',
|
||||||
|
format: 'uuid',
|
||||||
|
title: 'Id'
|
||||||
|
},
|
||||||
|
owner_id: {
|
||||||
|
type: 'string',
|
||||||
|
format: 'uuid',
|
||||||
|
title: 'Owner Id'
|
||||||
|
},
|
||||||
|
created_at: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
format: 'date-time'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Created At'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['title', 'id', 'owner_id'],
|
||||||
|
title: 'ItemPublic'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const ItemUpdateSchema = {
|
||||||
|
properties: {
|
||||||
|
title: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255,
|
||||||
|
minLength: 1
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Title'
|
||||||
|
},
|
||||||
|
description: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Description'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
title: 'ItemUpdate'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const ItemsPublicSchema = {
|
||||||
|
properties: {
|
||||||
|
data: {
|
||||||
|
items: {
|
||||||
|
'$ref': '#/components/schemas/ItemPublic'
|
||||||
|
},
|
||||||
|
type: 'array',
|
||||||
|
title: 'Data'
|
||||||
|
},
|
||||||
|
count: {
|
||||||
|
type: 'integer',
|
||||||
|
title: 'Count'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['data', 'count'],
|
||||||
|
title: 'ItemsPublic'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const MessageSchema = {
|
||||||
|
properties: {
|
||||||
|
message: {
|
||||||
|
type: 'string',
|
||||||
|
title: 'Message'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['message'],
|
||||||
|
title: 'Message'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const NewPasswordSchema = {
|
||||||
|
properties: {
|
||||||
|
token: {
|
||||||
|
type: 'string',
|
||||||
|
title: 'Token'
|
||||||
|
},
|
||||||
|
new_password: {
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 128,
|
||||||
|
minLength: 8,
|
||||||
|
title: 'New Password'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['token', 'new_password'],
|
||||||
|
title: 'NewPassword'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const PrivateUserCreateSchema = {
|
||||||
|
properties: {
|
||||||
|
email: {
|
||||||
|
type: 'string',
|
||||||
|
title: 'Email'
|
||||||
|
},
|
||||||
|
password: {
|
||||||
|
type: 'string',
|
||||||
|
title: 'Password'
|
||||||
|
},
|
||||||
|
full_name: {
|
||||||
|
type: 'string',
|
||||||
|
title: 'Full Name'
|
||||||
|
},
|
||||||
|
is_verified: {
|
||||||
|
type: 'boolean',
|
||||||
|
title: 'Is Verified',
|
||||||
|
default: false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['email', 'password', 'full_name'],
|
||||||
|
title: 'PrivateUserCreate'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const TokenSchema = {
|
||||||
|
properties: {
|
||||||
|
access_token: {
|
||||||
|
type: 'string',
|
||||||
|
title: 'Access Token'
|
||||||
|
},
|
||||||
|
token_type: {
|
||||||
|
type: 'string',
|
||||||
|
title: 'Token Type',
|
||||||
|
default: 'bearer'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['access_token'],
|
||||||
|
title: 'Token'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const UpdatePasswordSchema = {
|
||||||
|
properties: {
|
||||||
|
current_password: {
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 128,
|
||||||
|
minLength: 8,
|
||||||
|
title: 'Current Password'
|
||||||
|
},
|
||||||
|
new_password: {
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 128,
|
||||||
|
minLength: 8,
|
||||||
|
title: 'New Password'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['current_password', 'new_password'],
|
||||||
|
title: 'UpdatePassword'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const UserCreateSchema = {
|
||||||
|
properties: {
|
||||||
|
email: {
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255,
|
||||||
|
format: 'email',
|
||||||
|
title: 'Email'
|
||||||
|
},
|
||||||
|
is_active: {
|
||||||
|
type: 'boolean',
|
||||||
|
title: 'Is Active',
|
||||||
|
default: true
|
||||||
|
},
|
||||||
|
is_superuser: {
|
||||||
|
type: 'boolean',
|
||||||
|
title: 'Is Superuser',
|
||||||
|
default: false
|
||||||
|
},
|
||||||
|
full_name: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Full Name'
|
||||||
|
},
|
||||||
|
password: {
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 128,
|
||||||
|
minLength: 8,
|
||||||
|
title: 'Password'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['email', 'password'],
|
||||||
|
title: 'UserCreate'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const UserPublicSchema = {
|
||||||
|
properties: {
|
||||||
|
email: {
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255,
|
||||||
|
format: 'email',
|
||||||
|
title: 'Email'
|
||||||
|
},
|
||||||
|
is_active: {
|
||||||
|
type: 'boolean',
|
||||||
|
title: 'Is Active',
|
||||||
|
default: true
|
||||||
|
},
|
||||||
|
is_superuser: {
|
||||||
|
type: 'boolean',
|
||||||
|
title: 'Is Superuser',
|
||||||
|
default: false
|
||||||
|
},
|
||||||
|
full_name: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Full Name'
|
||||||
|
},
|
||||||
|
id: {
|
||||||
|
type: 'string',
|
||||||
|
format: 'uuid',
|
||||||
|
title: 'Id'
|
||||||
|
},
|
||||||
|
created_at: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
format: 'date-time'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Created At'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['email', 'id'],
|
||||||
|
title: 'UserPublic'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const UserRegisterSchema = {
|
||||||
|
properties: {
|
||||||
|
email: {
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255,
|
||||||
|
format: 'email',
|
||||||
|
title: 'Email'
|
||||||
|
},
|
||||||
|
password: {
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 128,
|
||||||
|
minLength: 8,
|
||||||
|
title: 'Password'
|
||||||
|
},
|
||||||
|
full_name: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Full Name'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['email', 'password'],
|
||||||
|
title: 'UserRegister'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const UserUpdateSchema = {
|
||||||
|
properties: {
|
||||||
|
email: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255,
|
||||||
|
format: 'email'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Email'
|
||||||
|
},
|
||||||
|
is_active: {
|
||||||
|
type: 'boolean',
|
||||||
|
title: 'Is Active',
|
||||||
|
default: true
|
||||||
|
},
|
||||||
|
is_superuser: {
|
||||||
|
type: 'boolean',
|
||||||
|
title: 'Is Superuser',
|
||||||
|
default: false
|
||||||
|
},
|
||||||
|
full_name: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Full Name'
|
||||||
|
},
|
||||||
|
password: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 128,
|
||||||
|
minLength: 8
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Password'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
title: 'UserUpdate'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const UserUpdateMeSchema = {
|
||||||
|
properties: {
|
||||||
|
full_name: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Full Name'
|
||||||
|
},
|
||||||
|
email: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string',
|
||||||
|
maxLength: 255,
|
||||||
|
format: 'email'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'null'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
title: 'Email'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
title: 'UserUpdateMe'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const UsersPublicSchema = {
|
||||||
|
properties: {
|
||||||
|
data: {
|
||||||
|
items: {
|
||||||
|
'$ref': '#/components/schemas/UserPublic'
|
||||||
|
},
|
||||||
|
type: 'array',
|
||||||
|
title: 'Data'
|
||||||
|
},
|
||||||
|
count: {
|
||||||
|
type: 'integer',
|
||||||
|
title: 'Count'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['data', 'count'],
|
||||||
|
title: 'UsersPublic'
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const ValidationErrorSchema = {
|
||||||
|
properties: {
|
||||||
|
loc: {
|
||||||
|
items: {
|
||||||
|
anyOf: [
|
||||||
|
{
|
||||||
|
type: 'string'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'integer'
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
type: 'array',
|
||||||
|
title: 'Location'
|
||||||
|
},
|
||||||
|
msg: {
|
||||||
|
type: 'string',
|
||||||
|
title: 'Message'
|
||||||
|
},
|
||||||
|
type: {
|
||||||
|
type: 'string',
|
||||||
|
title: 'Error Type'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
type: 'object',
|
||||||
|
required: ['loc', 'msg', 'type'],
|
||||||
|
title: 'ValidationError'
|
||||||
|
} as const;
|
||||||
@@ -1,444 +0,0 @@
|
|||||||
export const $Body_login_login_access_token = {
|
|
||||||
properties: {
|
|
||||||
grant_type: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
pattern: "password",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
username: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
},
|
|
||||||
password: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
},
|
|
||||||
scope: {
|
|
||||||
type: "string",
|
|
||||||
default: "",
|
|
||||||
},
|
|
||||||
client_id: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
client_secret: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $HTTPValidationError = {
|
|
||||||
properties: {
|
|
||||||
detail: {
|
|
||||||
type: "array",
|
|
||||||
contains: {
|
|
||||||
type: "ValidationError",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $ItemCreate = {
|
|
||||||
properties: {
|
|
||||||
title: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
maxLength: 255,
|
|
||||||
minLength: 1,
|
|
||||||
},
|
|
||||||
description: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
maxLength: 255,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $ItemPublic = {
|
|
||||||
properties: {
|
|
||||||
title: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
maxLength: 255,
|
|
||||||
minLength: 1,
|
|
||||||
},
|
|
||||||
description: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
maxLength: 255,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
id: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
format: "uuid",
|
|
||||||
},
|
|
||||||
owner_id: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
format: "uuid",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $ItemUpdate = {
|
|
||||||
properties: {
|
|
||||||
title: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
maxLength: 255,
|
|
||||||
minLength: 1,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
description: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
maxLength: 255,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $ItemsPublic = {
|
|
||||||
properties: {
|
|
||||||
data: {
|
|
||||||
type: "array",
|
|
||||||
contains: {
|
|
||||||
type: "ItemPublic",
|
|
||||||
},
|
|
||||||
isRequired: true,
|
|
||||||
},
|
|
||||||
count: {
|
|
||||||
type: "number",
|
|
||||||
isRequired: true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $Message = {
|
|
||||||
properties: {
|
|
||||||
message: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $NewPassword = {
|
|
||||||
properties: {
|
|
||||||
token: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
},
|
|
||||||
new_password: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
maxLength: 40,
|
|
||||||
minLength: 8,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $Token = {
|
|
||||||
properties: {
|
|
||||||
access_token: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
},
|
|
||||||
token_type: {
|
|
||||||
type: "string",
|
|
||||||
default: "bearer",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $UpdatePassword = {
|
|
||||||
properties: {
|
|
||||||
current_password: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
maxLength: 40,
|
|
||||||
minLength: 8,
|
|
||||||
},
|
|
||||||
new_password: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
maxLength: 40,
|
|
||||||
minLength: 8,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $UserCreate = {
|
|
||||||
properties: {
|
|
||||||
email: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
format: "email",
|
|
||||||
maxLength: 255,
|
|
||||||
},
|
|
||||||
is_active: {
|
|
||||||
type: "boolean",
|
|
||||||
default: true,
|
|
||||||
},
|
|
||||||
is_superuser: {
|
|
||||||
type: "boolean",
|
|
||||||
default: false,
|
|
||||||
},
|
|
||||||
full_name: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
maxLength: 255,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
password: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
maxLength: 40,
|
|
||||||
minLength: 8,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $UserPublic = {
|
|
||||||
properties: {
|
|
||||||
email: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
format: "email",
|
|
||||||
maxLength: 255,
|
|
||||||
},
|
|
||||||
is_active: {
|
|
||||||
type: "boolean",
|
|
||||||
default: true,
|
|
||||||
},
|
|
||||||
is_superuser: {
|
|
||||||
type: "boolean",
|
|
||||||
default: false,
|
|
||||||
},
|
|
||||||
full_name: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
maxLength: 255,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
id: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
format: "uuid",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $UserRegister = {
|
|
||||||
properties: {
|
|
||||||
email: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
format: "email",
|
|
||||||
maxLength: 255,
|
|
||||||
},
|
|
||||||
password: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
maxLength: 40,
|
|
||||||
minLength: 8,
|
|
||||||
},
|
|
||||||
full_name: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
maxLength: 255,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $UserUpdate = {
|
|
||||||
properties: {
|
|
||||||
email: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
format: "email",
|
|
||||||
maxLength: 255,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
is_active: {
|
|
||||||
type: "boolean",
|
|
||||||
default: true,
|
|
||||||
},
|
|
||||||
is_superuser: {
|
|
||||||
type: "boolean",
|
|
||||||
default: false,
|
|
||||||
},
|
|
||||||
full_name: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
maxLength: 255,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
password: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
maxLength: 40,
|
|
||||||
minLength: 8,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $UserUpdateMe = {
|
|
||||||
properties: {
|
|
||||||
full_name: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
maxLength: 255,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
email: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
format: "email",
|
|
||||||
maxLength: 255,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "null",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $UsersPublic = {
|
|
||||||
properties: {
|
|
||||||
data: {
|
|
||||||
type: "array",
|
|
||||||
contains: {
|
|
||||||
type: "UserPublic",
|
|
||||||
},
|
|
||||||
isRequired: true,
|
|
||||||
},
|
|
||||||
count: {
|
|
||||||
type: "number",
|
|
||||||
isRequired: true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
|
|
||||||
export const $ValidationError = {
|
|
||||||
properties: {
|
|
||||||
loc: {
|
|
||||||
type: "array",
|
|
||||||
contains: {
|
|
||||||
type: "any-of",
|
|
||||||
contains: [
|
|
||||||
{
|
|
||||||
type: "string",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
type: "number",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
isRequired: true,
|
|
||||||
},
|
|
||||||
msg: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
},
|
|
||||||
type: {
|
|
||||||
type: "string",
|
|
||||||
isRequired: true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
} as const
|
|
||||||
@@ -0,0 +1,468 @@
|
|||||||
|
// This file is auto-generated by @hey-api/openapi-ts
|
||||||
|
|
||||||
|
import type { CancelablePromise } from './core/CancelablePromise';
|
||||||
|
import { OpenAPI } from './core/OpenAPI';
|
||||||
|
import { request as __request } from './core/request';
|
||||||
|
import type { ItemsReadItemsData, ItemsReadItemsResponse, ItemsCreateItemData, ItemsCreateItemResponse, ItemsReadItemData, ItemsReadItemResponse, ItemsUpdateItemData, ItemsUpdateItemResponse, ItemsDeleteItemData, ItemsDeleteItemResponse, LoginLoginAccessTokenData, LoginLoginAccessTokenResponse, LoginTestTokenResponse, LoginRecoverPasswordData, LoginRecoverPasswordResponse, LoginResetPasswordData, LoginResetPasswordResponse, LoginRecoverPasswordHtmlContentData, LoginRecoverPasswordHtmlContentResponse, PrivateCreateUserData, PrivateCreateUserResponse, UsersReadUsersData, UsersReadUsersResponse, UsersCreateUserData, UsersCreateUserResponse, UsersReadUserMeResponse, UsersDeleteUserMeResponse, UsersUpdateUserMeData, UsersUpdateUserMeResponse, UsersUpdatePasswordMeData, UsersUpdatePasswordMeResponse, UsersRegisterUserData, UsersRegisterUserResponse, UsersReadUserByIdData, UsersReadUserByIdResponse, UsersUpdateUserData, UsersUpdateUserResponse, UsersDeleteUserData, UsersDeleteUserResponse, UtilsTestEmailData, UtilsTestEmailResponse, UtilsHealthCheckResponse } from './types.gen';
|
||||||
|
|
||||||
|
export class ItemsService {
|
||||||
|
/**
|
||||||
|
* Read Items
|
||||||
|
* Retrieve items.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.skip
|
||||||
|
* @param data.limit
|
||||||
|
* @returns ItemsPublic Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static readItems(data: ItemsReadItemsData = {}): CancelablePromise<ItemsReadItemsResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'GET',
|
||||||
|
url: '/api/v1/items/',
|
||||||
|
query: {
|
||||||
|
skip: data.skip,
|
||||||
|
limit: data.limit
|
||||||
|
},
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Create Item
|
||||||
|
* Create new item.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.requestBody
|
||||||
|
* @returns ItemPublic Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static createItem(data: ItemsCreateItemData): CancelablePromise<ItemsCreateItemResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'POST',
|
||||||
|
url: '/api/v1/items/',
|
||||||
|
body: data.requestBody,
|
||||||
|
mediaType: 'application/json',
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Read Item
|
||||||
|
* Get item by ID.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.id
|
||||||
|
* @returns ItemPublic Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static readItem(data: ItemsReadItemData): CancelablePromise<ItemsReadItemResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'GET',
|
||||||
|
url: '/api/v1/items/{id}',
|
||||||
|
path: {
|
||||||
|
id: data.id
|
||||||
|
},
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update Item
|
||||||
|
* Update an item.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.id
|
||||||
|
* @param data.requestBody
|
||||||
|
* @returns ItemPublic Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static updateItem(data: ItemsUpdateItemData): CancelablePromise<ItemsUpdateItemResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'PUT',
|
||||||
|
url: '/api/v1/items/{id}',
|
||||||
|
path: {
|
||||||
|
id: data.id
|
||||||
|
},
|
||||||
|
body: data.requestBody,
|
||||||
|
mediaType: 'application/json',
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Delete Item
|
||||||
|
* Delete an item.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.id
|
||||||
|
* @returns Message Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static deleteItem(data: ItemsDeleteItemData): CancelablePromise<ItemsDeleteItemResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'DELETE',
|
||||||
|
url: '/api/v1/items/{id}',
|
||||||
|
path: {
|
||||||
|
id: data.id
|
||||||
|
},
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export class LoginService {
|
||||||
|
/**
|
||||||
|
* Login Access Token
|
||||||
|
* OAuth2 compatible token login, get an access token for future requests
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.formData
|
||||||
|
* @returns Token Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static loginAccessToken(data: LoginLoginAccessTokenData): CancelablePromise<LoginLoginAccessTokenResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'POST',
|
||||||
|
url: '/api/v1/login/access-token',
|
||||||
|
formData: data.formData,
|
||||||
|
mediaType: 'application/x-www-form-urlencoded',
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Test Token
|
||||||
|
* Test access token
|
||||||
|
* @returns UserPublic Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static testToken(): CancelablePromise<LoginTestTokenResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'POST',
|
||||||
|
url: '/api/v1/login/test-token'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Recover Password
|
||||||
|
* Password Recovery
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.email
|
||||||
|
* @returns Message Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static recoverPassword(data: LoginRecoverPasswordData): CancelablePromise<LoginRecoverPasswordResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'POST',
|
||||||
|
url: '/api/v1/password-recovery/{email}',
|
||||||
|
path: {
|
||||||
|
email: data.email
|
||||||
|
},
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Reset Password
|
||||||
|
* Reset password
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.requestBody
|
||||||
|
* @returns Message Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static resetPassword(data: LoginResetPasswordData): CancelablePromise<LoginResetPasswordResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'POST',
|
||||||
|
url: '/api/v1/reset-password/',
|
||||||
|
body: data.requestBody,
|
||||||
|
mediaType: 'application/json',
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Recover Password Html Content
|
||||||
|
* HTML Content for Password Recovery
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.email
|
||||||
|
* @returns string Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static recoverPasswordHtmlContent(data: LoginRecoverPasswordHtmlContentData): CancelablePromise<LoginRecoverPasswordHtmlContentResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'POST',
|
||||||
|
url: '/api/v1/password-recovery-html-content/{email}',
|
||||||
|
path: {
|
||||||
|
email: data.email
|
||||||
|
},
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export class PrivateService {
|
||||||
|
/**
|
||||||
|
* Create User
|
||||||
|
* Create a new user.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.requestBody
|
||||||
|
* @returns UserPublic Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static createUser(data: PrivateCreateUserData): CancelablePromise<PrivateCreateUserResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'POST',
|
||||||
|
url: '/api/v1/private/users/',
|
||||||
|
body: data.requestBody,
|
||||||
|
mediaType: 'application/json',
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export class UsersService {
|
||||||
|
/**
|
||||||
|
* Read Users
|
||||||
|
* Retrieve users.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.skip
|
||||||
|
* @param data.limit
|
||||||
|
* @returns UsersPublic Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static readUsers(data: UsersReadUsersData = {}): CancelablePromise<UsersReadUsersResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'GET',
|
||||||
|
url: '/api/v1/users/',
|
||||||
|
query: {
|
||||||
|
skip: data.skip,
|
||||||
|
limit: data.limit
|
||||||
|
},
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Create User
|
||||||
|
* Create new user.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.requestBody
|
||||||
|
* @returns UserPublic Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static createUser(data: UsersCreateUserData): CancelablePromise<UsersCreateUserResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'POST',
|
||||||
|
url: '/api/v1/users/',
|
||||||
|
body: data.requestBody,
|
||||||
|
mediaType: 'application/json',
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Read User Me
|
||||||
|
* Get current user.
|
||||||
|
* @returns UserPublic Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static readUserMe(): CancelablePromise<UsersReadUserMeResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'GET',
|
||||||
|
url: '/api/v1/users/me'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Delete User Me
|
||||||
|
* Delete own user.
|
||||||
|
* @returns Message Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static deleteUserMe(): CancelablePromise<UsersDeleteUserMeResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'DELETE',
|
||||||
|
url: '/api/v1/users/me'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update User Me
|
||||||
|
* Update own user.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.requestBody
|
||||||
|
* @returns UserPublic Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static updateUserMe(data: UsersUpdateUserMeData): CancelablePromise<UsersUpdateUserMeResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'PATCH',
|
||||||
|
url: '/api/v1/users/me',
|
||||||
|
body: data.requestBody,
|
||||||
|
mediaType: 'application/json',
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update Password Me
|
||||||
|
* Update own password.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.requestBody
|
||||||
|
* @returns Message Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static updatePasswordMe(data: UsersUpdatePasswordMeData): CancelablePromise<UsersUpdatePasswordMeResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'PATCH',
|
||||||
|
url: '/api/v1/users/me/password',
|
||||||
|
body: data.requestBody,
|
||||||
|
mediaType: 'application/json',
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Register User
|
||||||
|
* Create new user without the need to be logged in.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.requestBody
|
||||||
|
* @returns UserPublic Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static registerUser(data: UsersRegisterUserData): CancelablePromise<UsersRegisterUserResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'POST',
|
||||||
|
url: '/api/v1/users/signup',
|
||||||
|
body: data.requestBody,
|
||||||
|
mediaType: 'application/json',
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Read User By Id
|
||||||
|
* Get a specific user by id.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.userId
|
||||||
|
* @returns UserPublic Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static readUserById(data: UsersReadUserByIdData): CancelablePromise<UsersReadUserByIdResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'GET',
|
||||||
|
url: '/api/v1/users/{user_id}',
|
||||||
|
path: {
|
||||||
|
user_id: data.userId
|
||||||
|
},
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update User
|
||||||
|
* Update a user.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.userId
|
||||||
|
* @param data.requestBody
|
||||||
|
* @returns UserPublic Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static updateUser(data: UsersUpdateUserData): CancelablePromise<UsersUpdateUserResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'PATCH',
|
||||||
|
url: '/api/v1/users/{user_id}',
|
||||||
|
path: {
|
||||||
|
user_id: data.userId
|
||||||
|
},
|
||||||
|
body: data.requestBody,
|
||||||
|
mediaType: 'application/json',
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Delete User
|
||||||
|
* Delete a user.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.userId
|
||||||
|
* @returns Message Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static deleteUser(data: UsersDeleteUserData): CancelablePromise<UsersDeleteUserResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'DELETE',
|
||||||
|
url: '/api/v1/users/{user_id}',
|
||||||
|
path: {
|
||||||
|
user_id: data.userId
|
||||||
|
},
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export class UtilsService {
|
||||||
|
/**
|
||||||
|
* Test Email
|
||||||
|
* Test emails.
|
||||||
|
* @param data The data for the request.
|
||||||
|
* @param data.emailTo
|
||||||
|
* @returns Message Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static testEmail(data: UtilsTestEmailData): CancelablePromise<UtilsTestEmailResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'POST',
|
||||||
|
url: '/api/v1/utils/test-email/',
|
||||||
|
query: {
|
||||||
|
email_to: data.emailTo
|
||||||
|
},
|
||||||
|
errors: {
|
||||||
|
422: 'Validation Error'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Health Check
|
||||||
|
* @returns boolean Successful Response
|
||||||
|
* @throws ApiError
|
||||||
|
*/
|
||||||
|
public static healthCheck(): CancelablePromise<UtilsHealthCheckResponse> {
|
||||||
|
return __request(OpenAPI, {
|
||||||
|
method: 'GET',
|
||||||
|
url: '/api/v1/utils/health-check/'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,517 +0,0 @@
|
|||||||
import type { CancelablePromise } from "./core/CancelablePromise"
|
|
||||||
import { OpenAPI } from "./core/OpenAPI"
|
|
||||||
import { request as __request } from "./core/request"
|
|
||||||
|
|
||||||
import type {
|
|
||||||
Body_login_login_access_token,
|
|
||||||
ItemCreate,
|
|
||||||
ItemPublic,
|
|
||||||
ItemUpdate,
|
|
||||||
ItemsPublic,
|
|
||||||
Message,
|
|
||||||
NewPassword,
|
|
||||||
Token,
|
|
||||||
UpdatePassword,
|
|
||||||
UserCreate,
|
|
||||||
UserPublic,
|
|
||||||
UserRegister,
|
|
||||||
UserUpdate,
|
|
||||||
UserUpdateMe,
|
|
||||||
UsersPublic,
|
|
||||||
} from "./models"
|
|
||||||
|
|
||||||
export type TDataLoginAccessToken = {
|
|
||||||
formData: Body_login_login_access_token
|
|
||||||
}
|
|
||||||
export type TDataRecoverPassword = {
|
|
||||||
email: string
|
|
||||||
}
|
|
||||||
export type TDataResetPassword = {
|
|
||||||
requestBody: NewPassword
|
|
||||||
}
|
|
||||||
export type TDataRecoverPasswordHtmlContent = {
|
|
||||||
email: string
|
|
||||||
}
|
|
||||||
|
|
||||||
export class LoginService {
|
|
||||||
/**
|
|
||||||
* Login Access Token
|
|
||||||
* OAuth2 compatible token login, get an access token for future requests
|
|
||||||
* @returns Token Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static loginAccessToken(
|
|
||||||
data: TDataLoginAccessToken,
|
|
||||||
): CancelablePromise<Token> {
|
|
||||||
const { formData } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "POST",
|
|
||||||
url: "/api/v1/login/access-token",
|
|
||||||
formData: formData,
|
|
||||||
mediaType: "application/x-www-form-urlencoded",
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Test Token
|
|
||||||
* Test access token
|
|
||||||
* @returns UserPublic Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static testToken(): CancelablePromise<UserPublic> {
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "POST",
|
|
||||||
url: "/api/v1/login/test-token",
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Recover Password
|
|
||||||
* Password Recovery
|
|
||||||
* @returns Message Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static recoverPassword(
|
|
||||||
data: TDataRecoverPassword,
|
|
||||||
): CancelablePromise<Message> {
|
|
||||||
const { email } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "POST",
|
|
||||||
url: "/api/v1/password-recovery/{email}",
|
|
||||||
path: {
|
|
||||||
email,
|
|
||||||
},
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Reset Password
|
|
||||||
* Reset password
|
|
||||||
* @returns Message Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static resetPassword(
|
|
||||||
data: TDataResetPassword,
|
|
||||||
): CancelablePromise<Message> {
|
|
||||||
const { requestBody } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "POST",
|
|
||||||
url: "/api/v1/reset-password/",
|
|
||||||
body: requestBody,
|
|
||||||
mediaType: "application/json",
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Recover Password Html Content
|
|
||||||
* HTML Content for Password Recovery
|
|
||||||
* @returns string Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static recoverPasswordHtmlContent(
|
|
||||||
data: TDataRecoverPasswordHtmlContent,
|
|
||||||
): CancelablePromise<string> {
|
|
||||||
const { email } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "POST",
|
|
||||||
url: "/api/v1/password-recovery-html-content/{email}",
|
|
||||||
path: {
|
|
||||||
email,
|
|
||||||
},
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
export type TDataReadUsers = {
|
|
||||||
limit?: number
|
|
||||||
skip?: number
|
|
||||||
}
|
|
||||||
export type TDataCreateUser = {
|
|
||||||
requestBody: UserCreate
|
|
||||||
}
|
|
||||||
export type TDataUpdateUserMe = {
|
|
||||||
requestBody: UserUpdateMe
|
|
||||||
}
|
|
||||||
export type TDataUpdatePasswordMe = {
|
|
||||||
requestBody: UpdatePassword
|
|
||||||
}
|
|
||||||
export type TDataRegisterUser = {
|
|
||||||
requestBody: UserRegister
|
|
||||||
}
|
|
||||||
export type TDataReadUserById = {
|
|
||||||
userId: string
|
|
||||||
}
|
|
||||||
export type TDataUpdateUser = {
|
|
||||||
requestBody: UserUpdate
|
|
||||||
userId: string
|
|
||||||
}
|
|
||||||
export type TDataDeleteUser = {
|
|
||||||
userId: string
|
|
||||||
}
|
|
||||||
|
|
||||||
export class UsersService {
|
|
||||||
/**
|
|
||||||
* Read Users
|
|
||||||
* Retrieve users.
|
|
||||||
* @returns UsersPublic Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static readUsers(
|
|
||||||
data: TDataReadUsers = {},
|
|
||||||
): CancelablePromise<UsersPublic> {
|
|
||||||
const { limit = 100, skip = 0 } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "GET",
|
|
||||||
url: "/api/v1/users/",
|
|
||||||
query: {
|
|
||||||
skip,
|
|
||||||
limit,
|
|
||||||
},
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Create User
|
|
||||||
* Create new user.
|
|
||||||
* @returns UserPublic Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static createUser(
|
|
||||||
data: TDataCreateUser,
|
|
||||||
): CancelablePromise<UserPublic> {
|
|
||||||
const { requestBody } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "POST",
|
|
||||||
url: "/api/v1/users/",
|
|
||||||
body: requestBody,
|
|
||||||
mediaType: "application/json",
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Read User Me
|
|
||||||
* Get current user.
|
|
||||||
* @returns UserPublic Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static readUserMe(): CancelablePromise<UserPublic> {
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "GET",
|
|
||||||
url: "/api/v1/users/me",
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Delete User Me
|
|
||||||
* Delete own user.
|
|
||||||
* @returns Message Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static deleteUserMe(): CancelablePromise<Message> {
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "DELETE",
|
|
||||||
url: "/api/v1/users/me",
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Update User Me
|
|
||||||
* Update own user.
|
|
||||||
* @returns UserPublic Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static updateUserMe(
|
|
||||||
data: TDataUpdateUserMe,
|
|
||||||
): CancelablePromise<UserPublic> {
|
|
||||||
const { requestBody } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "PATCH",
|
|
||||||
url: "/api/v1/users/me",
|
|
||||||
body: requestBody,
|
|
||||||
mediaType: "application/json",
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Update Password Me
|
|
||||||
* Update own password.
|
|
||||||
* @returns Message Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static updatePasswordMe(
|
|
||||||
data: TDataUpdatePasswordMe,
|
|
||||||
): CancelablePromise<Message> {
|
|
||||||
const { requestBody } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "PATCH",
|
|
||||||
url: "/api/v1/users/me/password",
|
|
||||||
body: requestBody,
|
|
||||||
mediaType: "application/json",
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Register User
|
|
||||||
* Create new user without the need to be logged in.
|
|
||||||
* @returns UserPublic Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static registerUser(
|
|
||||||
data: TDataRegisterUser,
|
|
||||||
): CancelablePromise<UserPublic> {
|
|
||||||
const { requestBody } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "POST",
|
|
||||||
url: "/api/v1/users/signup",
|
|
||||||
body: requestBody,
|
|
||||||
mediaType: "application/json",
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Read User By Id
|
|
||||||
* Get a specific user by id.
|
|
||||||
* @returns UserPublic Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static readUserById(
|
|
||||||
data: TDataReadUserById,
|
|
||||||
): CancelablePromise<UserPublic> {
|
|
||||||
const { userId } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "GET",
|
|
||||||
url: "/api/v1/users/{user_id}",
|
|
||||||
path: {
|
|
||||||
user_id: userId,
|
|
||||||
},
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Update User
|
|
||||||
* Update a user.
|
|
||||||
* @returns UserPublic Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static updateUser(
|
|
||||||
data: TDataUpdateUser,
|
|
||||||
): CancelablePromise<UserPublic> {
|
|
||||||
const { requestBody, userId } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "PATCH",
|
|
||||||
url: "/api/v1/users/{user_id}",
|
|
||||||
path: {
|
|
||||||
user_id: userId,
|
|
||||||
},
|
|
||||||
body: requestBody,
|
|
||||||
mediaType: "application/json",
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Delete User
|
|
||||||
* Delete a user.
|
|
||||||
* @returns Message Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static deleteUser(data: TDataDeleteUser): CancelablePromise<Message> {
|
|
||||||
const { userId } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "DELETE",
|
|
||||||
url: "/api/v1/users/{user_id}",
|
|
||||||
path: {
|
|
||||||
user_id: userId,
|
|
||||||
},
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
export type TDataTestEmail = {
|
|
||||||
emailTo: string
|
|
||||||
}
|
|
||||||
|
|
||||||
export class UtilsService {
|
|
||||||
/**
|
|
||||||
* Test Email
|
|
||||||
* Test emails.
|
|
||||||
* @returns Message Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static testEmail(data: TDataTestEmail): CancelablePromise<Message> {
|
|
||||||
const { emailTo } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "POST",
|
|
||||||
url: "/api/v1/utils/test-email/",
|
|
||||||
query: {
|
|
||||||
email_to: emailTo,
|
|
||||||
},
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
export type TDataReadItems = {
|
|
||||||
limit?: number
|
|
||||||
skip?: number
|
|
||||||
}
|
|
||||||
export type TDataCreateItem = {
|
|
||||||
requestBody: ItemCreate
|
|
||||||
}
|
|
||||||
export type TDataReadItem = {
|
|
||||||
id: string
|
|
||||||
}
|
|
||||||
export type TDataUpdateItem = {
|
|
||||||
id: string
|
|
||||||
requestBody: ItemUpdate
|
|
||||||
}
|
|
||||||
export type TDataDeleteItem = {
|
|
||||||
id: string
|
|
||||||
}
|
|
||||||
|
|
||||||
export class ItemsService {
|
|
||||||
/**
|
|
||||||
* Read Items
|
|
||||||
* Retrieve items.
|
|
||||||
* @returns ItemsPublic Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static readItems(
|
|
||||||
data: TDataReadItems = {},
|
|
||||||
): CancelablePromise<ItemsPublic> {
|
|
||||||
const { limit = 100, skip = 0 } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "GET",
|
|
||||||
url: "/api/v1/items/",
|
|
||||||
query: {
|
|
||||||
skip,
|
|
||||||
limit,
|
|
||||||
},
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Create Item
|
|
||||||
* Create new item.
|
|
||||||
* @returns ItemPublic Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static createItem(
|
|
||||||
data: TDataCreateItem,
|
|
||||||
): CancelablePromise<ItemPublic> {
|
|
||||||
const { requestBody } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "POST",
|
|
||||||
url: "/api/v1/items/",
|
|
||||||
body: requestBody,
|
|
||||||
mediaType: "application/json",
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Read Item
|
|
||||||
* Get item by ID.
|
|
||||||
* @returns ItemPublic Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static readItem(data: TDataReadItem): CancelablePromise<ItemPublic> {
|
|
||||||
const { id } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "GET",
|
|
||||||
url: "/api/v1/items/{id}",
|
|
||||||
path: {
|
|
||||||
id,
|
|
||||||
},
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Update Item
|
|
||||||
* Update an item.
|
|
||||||
* @returns ItemPublic Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static updateItem(
|
|
||||||
data: TDataUpdateItem,
|
|
||||||
): CancelablePromise<ItemPublic> {
|
|
||||||
const { id, requestBody } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "PUT",
|
|
||||||
url: "/api/v1/items/{id}",
|
|
||||||
path: {
|
|
||||||
id,
|
|
||||||
},
|
|
||||||
body: requestBody,
|
|
||||||
mediaType: "application/json",
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Delete Item
|
|
||||||
* Delete an item.
|
|
||||||
* @returns Message Successful Response
|
|
||||||
* @throws ApiError
|
|
||||||
*/
|
|
||||||
public static deleteItem(data: TDataDeleteItem): CancelablePromise<Message> {
|
|
||||||
const { id } = data
|
|
||||||
return __request(OpenAPI, {
|
|
||||||
method: "DELETE",
|
|
||||||
url: "/api/v1/items/{id}",
|
|
||||||
path: {
|
|
||||||
id,
|
|
||||||
},
|
|
||||||
errors: {
|
|
||||||
422: "Validation Error",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -0,0 +1,236 @@
|
|||||||
|
// This file is auto-generated by @hey-api/openapi-ts
|
||||||
|
|
||||||
|
export type Body_login_login_access_token = {
|
||||||
|
grant_type?: (string | null);
|
||||||
|
username: string;
|
||||||
|
password: string;
|
||||||
|
scope?: string;
|
||||||
|
client_id?: (string | null);
|
||||||
|
client_secret?: (string | null);
|
||||||
|
};
|
||||||
|
|
||||||
|
export type HTTPValidationError = {
|
||||||
|
detail?: Array<ValidationError>;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type ItemCreate = {
|
||||||
|
title: string;
|
||||||
|
description?: (string | null);
|
||||||
|
};
|
||||||
|
|
||||||
|
export type ItemPublic = {
|
||||||
|
title: string;
|
||||||
|
description?: (string | null);
|
||||||
|
id: string;
|
||||||
|
owner_id: string;
|
||||||
|
created_at?: (string | null);
|
||||||
|
};
|
||||||
|
|
||||||
|
export type ItemsPublic = {
|
||||||
|
data: Array<ItemPublic>;
|
||||||
|
count: number;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type ItemUpdate = {
|
||||||
|
title?: (string | null);
|
||||||
|
description?: (string | null);
|
||||||
|
};
|
||||||
|
|
||||||
|
export type Message = {
|
||||||
|
message: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type NewPassword = {
|
||||||
|
token: string;
|
||||||
|
new_password: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type PrivateUserCreate = {
|
||||||
|
email: string;
|
||||||
|
password: string;
|
||||||
|
full_name: string;
|
||||||
|
is_verified?: boolean;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type Token = {
|
||||||
|
access_token: string;
|
||||||
|
token_type?: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UpdatePassword = {
|
||||||
|
current_password: string;
|
||||||
|
new_password: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UserCreate = {
|
||||||
|
email: string;
|
||||||
|
is_active?: boolean;
|
||||||
|
is_superuser?: boolean;
|
||||||
|
full_name?: (string | null);
|
||||||
|
password: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UserPublic = {
|
||||||
|
email: string;
|
||||||
|
is_active?: boolean;
|
||||||
|
is_superuser?: boolean;
|
||||||
|
full_name?: (string | null);
|
||||||
|
id: string;
|
||||||
|
created_at?: (string | null);
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UserRegister = {
|
||||||
|
email: string;
|
||||||
|
password: string;
|
||||||
|
full_name?: (string | null);
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UsersPublic = {
|
||||||
|
data: Array<UserPublic>;
|
||||||
|
count: number;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UserUpdate = {
|
||||||
|
email?: (string | null);
|
||||||
|
is_active?: boolean;
|
||||||
|
is_superuser?: boolean;
|
||||||
|
full_name?: (string | null);
|
||||||
|
password?: (string | null);
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UserUpdateMe = {
|
||||||
|
full_name?: (string | null);
|
||||||
|
email?: (string | null);
|
||||||
|
};
|
||||||
|
|
||||||
|
export type ValidationError = {
|
||||||
|
loc: Array<(string | number)>;
|
||||||
|
msg: string;
|
||||||
|
type: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type ItemsReadItemsData = {
|
||||||
|
limit?: number;
|
||||||
|
skip?: number;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type ItemsReadItemsResponse = (ItemsPublic);
|
||||||
|
|
||||||
|
export type ItemsCreateItemData = {
|
||||||
|
requestBody: ItemCreate;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type ItemsCreateItemResponse = (ItemPublic);
|
||||||
|
|
||||||
|
export type ItemsReadItemData = {
|
||||||
|
id: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type ItemsReadItemResponse = (ItemPublic);
|
||||||
|
|
||||||
|
export type ItemsUpdateItemData = {
|
||||||
|
id: string;
|
||||||
|
requestBody: ItemUpdate;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type ItemsUpdateItemResponse = (ItemPublic);
|
||||||
|
|
||||||
|
export type ItemsDeleteItemData = {
|
||||||
|
id: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type ItemsDeleteItemResponse = (Message);
|
||||||
|
|
||||||
|
export type LoginLoginAccessTokenData = {
|
||||||
|
formData: Body_login_login_access_token;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type LoginLoginAccessTokenResponse = (Token);
|
||||||
|
|
||||||
|
export type LoginTestTokenResponse = (UserPublic);
|
||||||
|
|
||||||
|
export type LoginRecoverPasswordData = {
|
||||||
|
email: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type LoginRecoverPasswordResponse = (Message);
|
||||||
|
|
||||||
|
export type LoginResetPasswordData = {
|
||||||
|
requestBody: NewPassword;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type LoginResetPasswordResponse = (Message);
|
||||||
|
|
||||||
|
export type LoginRecoverPasswordHtmlContentData = {
|
||||||
|
email: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type LoginRecoverPasswordHtmlContentResponse = (string);
|
||||||
|
|
||||||
|
export type PrivateCreateUserData = {
|
||||||
|
requestBody: PrivateUserCreate;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type PrivateCreateUserResponse = (UserPublic);
|
||||||
|
|
||||||
|
export type UsersReadUsersData = {
|
||||||
|
limit?: number;
|
||||||
|
skip?: number;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UsersReadUsersResponse = (UsersPublic);
|
||||||
|
|
||||||
|
export type UsersCreateUserData = {
|
||||||
|
requestBody: UserCreate;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UsersCreateUserResponse = (UserPublic);
|
||||||
|
|
||||||
|
export type UsersReadUserMeResponse = (UserPublic);
|
||||||
|
|
||||||
|
export type UsersDeleteUserMeResponse = (Message);
|
||||||
|
|
||||||
|
export type UsersUpdateUserMeData = {
|
||||||
|
requestBody: UserUpdateMe;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UsersUpdateUserMeResponse = (UserPublic);
|
||||||
|
|
||||||
|
export type UsersUpdatePasswordMeData = {
|
||||||
|
requestBody: UpdatePassword;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UsersUpdatePasswordMeResponse = (Message);
|
||||||
|
|
||||||
|
export type UsersRegisterUserData = {
|
||||||
|
requestBody: UserRegister;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UsersRegisterUserResponse = (UserPublic);
|
||||||
|
|
||||||
|
export type UsersReadUserByIdData = {
|
||||||
|
userId: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UsersReadUserByIdResponse = (UserPublic);
|
||||||
|
|
||||||
|
export type UsersUpdateUserData = {
|
||||||
|
requestBody: UserUpdate;
|
||||||
|
userId: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UsersUpdateUserResponse = (UserPublic);
|
||||||
|
|
||||||
|
export type UsersDeleteUserData = {
|
||||||
|
userId: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UsersDeleteUserResponse = (Message);
|
||||||
|
|
||||||
|
export type UtilsTestEmailData = {
|
||||||
|
emailTo: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type UtilsTestEmailResponse = (Message);
|
||||||
|
|
||||||
|
export type UtilsHealthCheckResponse = (boolean);
|
||||||
@@ -1,46 +1,64 @@
|
|||||||
import {
|
import { zodResolver } from "@hookform/resolvers/zod"
|
||||||
Button,
|
|
||||||
Checkbox,
|
|
||||||
Flex,
|
|
||||||
FormControl,
|
|
||||||
FormErrorMessage,
|
|
||||||
FormLabel,
|
|
||||||
Input,
|
|
||||||
Modal,
|
|
||||||
ModalBody,
|
|
||||||
ModalCloseButton,
|
|
||||||
ModalContent,
|
|
||||||
ModalFooter,
|
|
||||||
ModalHeader,
|
|
||||||
ModalOverlay,
|
|
||||||
} from "@chakra-ui/react"
|
|
||||||
import { useMutation, useQueryClient } from "@tanstack/react-query"
|
import { useMutation, useQueryClient } from "@tanstack/react-query"
|
||||||
import { type SubmitHandler, useForm } from "react-hook-form"
|
import { Plus } from "lucide-react"
|
||||||
|
import { useState } from "react"
|
||||||
|
import { useForm } from "react-hook-form"
|
||||||
|
import { z } from "zod"
|
||||||
|
|
||||||
import { type UserCreate, UsersService } from "../../client"
|
import { type UserCreate, UsersService } from "@/client"
|
||||||
import type { ApiError } from "../../client/core/ApiError"
|
import { Button } from "@/components/ui/button"
|
||||||
import useCustomToast from "../../hooks/useCustomToast"
|
import { Checkbox } from "@/components/ui/checkbox"
|
||||||
import { emailPattern, handleError } from "../../utils"
|
import {
|
||||||
|
Dialog,
|
||||||
|
DialogClose,
|
||||||
|
DialogContent,
|
||||||
|
DialogDescription,
|
||||||
|
DialogFooter,
|
||||||
|
DialogHeader,
|
||||||
|
DialogTitle,
|
||||||
|
DialogTrigger,
|
||||||
|
} from "@/components/ui/dialog"
|
||||||
|
import {
|
||||||
|
Form,
|
||||||
|
FormControl,
|
||||||
|
FormField,
|
||||||
|
FormItem,
|
||||||
|
FormLabel,
|
||||||
|
FormMessage,
|
||||||
|
} from "@/components/ui/form"
|
||||||
|
import { Input } from "@/components/ui/input"
|
||||||
|
import { LoadingButton } from "@/components/ui/loading-button"
|
||||||
|
import useCustomToast from "@/hooks/useCustomToast"
|
||||||
|
import { handleError } from "@/utils"
|
||||||
|
|
||||||
interface AddUserProps {
|
const formSchema = z
|
||||||
isOpen: boolean
|
.object({
|
||||||
onClose: () => void
|
email: z.email({ message: "Invalid email address" }),
|
||||||
}
|
full_name: z.string().optional(),
|
||||||
|
password: z
|
||||||
|
.string()
|
||||||
|
.min(1, { message: "Password is required" })
|
||||||
|
.min(8, { message: "Password must be at least 8 characters" }),
|
||||||
|
confirm_password: z
|
||||||
|
.string()
|
||||||
|
.min(1, { message: "Please confirm your password" }),
|
||||||
|
is_superuser: z.boolean(),
|
||||||
|
is_active: z.boolean(),
|
||||||
|
})
|
||||||
|
.refine((data) => data.password === data.confirm_password, {
|
||||||
|
message: "The passwords don't match",
|
||||||
|
path: ["confirm_password"],
|
||||||
|
})
|
||||||
|
|
||||||
interface UserCreateForm extends UserCreate {
|
type FormData = z.infer<typeof formSchema>
|
||||||
confirm_password: string
|
|
||||||
}
|
|
||||||
|
|
||||||
const AddUser = ({ isOpen, onClose }: AddUserProps) => {
|
const AddUser = () => {
|
||||||
|
const [isOpen, setIsOpen] = useState(false)
|
||||||
const queryClient = useQueryClient()
|
const queryClient = useQueryClient()
|
||||||
const showToast = useCustomToast()
|
const { showSuccessToast, showErrorToast } = useCustomToast()
|
||||||
const {
|
|
||||||
register,
|
const form = useForm<FormData>({
|
||||||
handleSubmit,
|
resolver: zodResolver(formSchema),
|
||||||
reset,
|
|
||||||
getValues,
|
|
||||||
formState: { errors, isSubmitting },
|
|
||||||
} = useForm<UserCreateForm>({
|
|
||||||
mode: "onBlur",
|
mode: "onBlur",
|
||||||
criteriaMode: "all",
|
criteriaMode: "all",
|
||||||
defaultValues: {
|
defaultValues: {
|
||||||
@@ -57,125 +75,163 @@ const AddUser = ({ isOpen, onClose }: AddUserProps) => {
|
|||||||
mutationFn: (data: UserCreate) =>
|
mutationFn: (data: UserCreate) =>
|
||||||
UsersService.createUser({ requestBody: data }),
|
UsersService.createUser({ requestBody: data }),
|
||||||
onSuccess: () => {
|
onSuccess: () => {
|
||||||
showToast("Success!", "User created successfully.", "success")
|
showSuccessToast("User created successfully")
|
||||||
reset()
|
form.reset()
|
||||||
onClose()
|
setIsOpen(false)
|
||||||
},
|
|
||||||
onError: (err: ApiError) => {
|
|
||||||
handleError(err, showToast)
|
|
||||||
},
|
},
|
||||||
|
onError: handleError.bind(showErrorToast),
|
||||||
onSettled: () => {
|
onSettled: () => {
|
||||||
queryClient.invalidateQueries({ queryKey: ["users"] })
|
queryClient.invalidateQueries({ queryKey: ["users"] })
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
const onSubmit: SubmitHandler<UserCreateForm> = (data) => {
|
const onSubmit = (data: FormData) => {
|
||||||
mutation.mutate(data)
|
mutation.mutate(data)
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<Dialog open={isOpen} onOpenChange={setIsOpen}>
|
||||||
<Modal
|
<DialogTrigger asChild>
|
||||||
isOpen={isOpen}
|
<Button className="my-4">
|
||||||
onClose={onClose}
|
<Plus className="mr-2" />
|
||||||
size={{ base: "sm", md: "md" }}
|
Add User
|
||||||
isCentered
|
</Button>
|
||||||
>
|
</DialogTrigger>
|
||||||
<ModalOverlay />
|
<DialogContent className="sm:max-w-md">
|
||||||
<ModalContent as="form" onSubmit={handleSubmit(onSubmit)}>
|
<DialogHeader>
|
||||||
<ModalHeader>Add User</ModalHeader>
|
<DialogTitle>Add User</DialogTitle>
|
||||||
<ModalCloseButton />
|
<DialogDescription>
|
||||||
<ModalBody pb={6}>
|
Fill in the form below to add a new user to the system.
|
||||||
<FormControl isRequired isInvalid={!!errors.email}>
|
</DialogDescription>
|
||||||
<FormLabel htmlFor="email">Email</FormLabel>
|
</DialogHeader>
|
||||||
<Input
|
<Form {...form}>
|
||||||
id="email"
|
<form onSubmit={form.handleSubmit(onSubmit)}>
|
||||||
{...register("email", {
|
<div className="grid gap-4 py-4">
|
||||||
required: "Email is required",
|
<FormField
|
||||||
pattern: emailPattern,
|
control={form.control}
|
||||||
})}
|
name="email"
|
||||||
placeholder="Email"
|
render={({ field }) => (
|
||||||
type="email"
|
<FormItem>
|
||||||
|
<FormLabel>
|
||||||
|
Email <span className="text-destructive">*</span>
|
||||||
|
</FormLabel>
|
||||||
|
<FormControl>
|
||||||
|
<Input
|
||||||
|
placeholder="Email"
|
||||||
|
type="email"
|
||||||
|
{...field}
|
||||||
|
required
|
||||||
|
/>
|
||||||
|
</FormControl>
|
||||||
|
<FormMessage />
|
||||||
|
</FormItem>
|
||||||
|
)}
|
||||||
/>
|
/>
|
||||||
{errors.email && (
|
|
||||||
<FormErrorMessage>{errors.email.message}</FormErrorMessage>
|
<FormField
|
||||||
)}
|
control={form.control}
|
||||||
</FormControl>
|
name="full_name"
|
||||||
<FormControl mt={4} isInvalid={!!errors.full_name}>
|
render={({ field }) => (
|
||||||
<FormLabel htmlFor="name">Full name</FormLabel>
|
<FormItem>
|
||||||
<Input
|
<FormLabel>Full Name</FormLabel>
|
||||||
id="name"
|
<FormControl>
|
||||||
{...register("full_name")}
|
<Input placeholder="Full name" type="text" {...field} />
|
||||||
placeholder="Full name"
|
</FormControl>
|
||||||
type="text"
|
<FormMessage />
|
||||||
|
</FormItem>
|
||||||
|
)}
|
||||||
/>
|
/>
|
||||||
{errors.full_name && (
|
|
||||||
<FormErrorMessage>{errors.full_name.message}</FormErrorMessage>
|
<FormField
|
||||||
)}
|
control={form.control}
|
||||||
</FormControl>
|
name="password"
|
||||||
<FormControl mt={4} isRequired isInvalid={!!errors.password}>
|
render={({ field }) => (
|
||||||
<FormLabel htmlFor="password">Set Password</FormLabel>
|
<FormItem>
|
||||||
<Input
|
<FormLabel>
|
||||||
id="password"
|
Set Password <span className="text-destructive">*</span>
|
||||||
{...register("password", {
|
</FormLabel>
|
||||||
required: "Password is required",
|
<FormControl>
|
||||||
minLength: {
|
<Input
|
||||||
value: 8,
|
placeholder="Password"
|
||||||
message: "Password must be at least 8 characters",
|
type="password"
|
||||||
},
|
{...field}
|
||||||
})}
|
required
|
||||||
placeholder="Password"
|
/>
|
||||||
type="password"
|
</FormControl>
|
||||||
|
<FormMessage />
|
||||||
|
</FormItem>
|
||||||
|
)}
|
||||||
/>
|
/>
|
||||||
{errors.password && (
|
|
||||||
<FormErrorMessage>{errors.password.message}</FormErrorMessage>
|
<FormField
|
||||||
)}
|
control={form.control}
|
||||||
</FormControl>
|
name="confirm_password"
|
||||||
<FormControl
|
render={({ field }) => (
|
||||||
mt={4}
|
<FormItem>
|
||||||
isRequired
|
<FormLabel>
|
||||||
isInvalid={!!errors.confirm_password}
|
Confirm Password{" "}
|
||||||
>
|
<span className="text-destructive">*</span>
|
||||||
<FormLabel htmlFor="confirm_password">Confirm Password</FormLabel>
|
</FormLabel>
|
||||||
<Input
|
<FormControl>
|
||||||
id="confirm_password"
|
<Input
|
||||||
{...register("confirm_password", {
|
placeholder="Password"
|
||||||
required: "Please confirm your password",
|
type="password"
|
||||||
validate: (value) =>
|
{...field}
|
||||||
value === getValues().password ||
|
required
|
||||||
"The passwords do not match",
|
/>
|
||||||
})}
|
</FormControl>
|
||||||
placeholder="Password"
|
<FormMessage />
|
||||||
type="password"
|
</FormItem>
|
||||||
|
)}
|
||||||
/>
|
/>
|
||||||
{errors.confirm_password && (
|
|
||||||
<FormErrorMessage>
|
<FormField
|
||||||
{errors.confirm_password.message}
|
control={form.control}
|
||||||
</FormErrorMessage>
|
name="is_superuser"
|
||||||
)}
|
render={({ field }) => (
|
||||||
</FormControl>
|
<FormItem className="flex items-center gap-3 space-y-0">
|
||||||
<Flex mt={4}>
|
<FormControl>
|
||||||
<FormControl>
|
<Checkbox
|
||||||
<Checkbox {...register("is_superuser")} colorScheme="teal">
|
checked={field.value}
|
||||||
Is superuser?
|
onCheckedChange={field.onChange}
|
||||||
</Checkbox>
|
/>
|
||||||
</FormControl>
|
</FormControl>
|
||||||
<FormControl>
|
<FormLabel className="font-normal">Is superuser?</FormLabel>
|
||||||
<Checkbox {...register("is_active")} colorScheme="teal">
|
</FormItem>
|
||||||
Is active?
|
)}
|
||||||
</Checkbox>
|
/>
|
||||||
</FormControl>
|
|
||||||
</Flex>
|
<FormField
|
||||||
</ModalBody>
|
control={form.control}
|
||||||
<ModalFooter gap={3}>
|
name="is_active"
|
||||||
<Button variant="primary" type="submit" isLoading={isSubmitting}>
|
render={({ field }) => (
|
||||||
Save
|
<FormItem className="flex items-center gap-3 space-y-0">
|
||||||
</Button>
|
<FormControl>
|
||||||
<Button onClick={onClose}>Cancel</Button>
|
<Checkbox
|
||||||
</ModalFooter>
|
checked={field.value}
|
||||||
</ModalContent>
|
onCheckedChange={field.onChange}
|
||||||
</Modal>
|
/>
|
||||||
</>
|
</FormControl>
|
||||||
|
<FormLabel className="font-normal">Is active?</FormLabel>
|
||||||
|
</FormItem>
|
||||||
|
)}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<DialogFooter>
|
||||||
|
<DialogClose asChild>
|
||||||
|
<Button variant="outline" disabled={mutation.isPending}>
|
||||||
|
Cancel
|
||||||
|
</Button>
|
||||||
|
</DialogClose>
|
||||||
|
<LoadingButton type="submit" loading={mutation.isPending}>
|
||||||
|
Save
|
||||||
|
</LoadingButton>
|
||||||
|
</DialogFooter>
|
||||||
|
</form>
|
||||||
|
</Form>
|
||||||
|
</DialogContent>
|
||||||
|
</Dialog>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,95 @@
|
|||||||
|
import { useMutation, useQueryClient } from "@tanstack/react-query"
|
||||||
|
import { Trash2 } from "lucide-react"
|
||||||
|
import { useState } from "react"
|
||||||
|
import { useForm } from "react-hook-form"
|
||||||
|
|
||||||
|
import { UsersService } from "@/client"
|
||||||
|
import { Button } from "@/components/ui/button"
|
||||||
|
import {
|
||||||
|
Dialog,
|
||||||
|
DialogClose,
|
||||||
|
DialogContent,
|
||||||
|
DialogDescription,
|
||||||
|
DialogFooter,
|
||||||
|
DialogHeader,
|
||||||
|
DialogTitle,
|
||||||
|
} from "@/components/ui/dialog"
|
||||||
|
import { DropdownMenuItem } from "@/components/ui/dropdown-menu"
|
||||||
|
import { LoadingButton } from "@/components/ui/loading-button"
|
||||||
|
import useCustomToast from "@/hooks/useCustomToast"
|
||||||
|
import { handleError } from "@/utils"
|
||||||
|
|
||||||
|
interface DeleteUserProps {
|
||||||
|
id: string
|
||||||
|
onSuccess: () => void
|
||||||
|
}
|
||||||
|
|
||||||
|
const DeleteUser = ({ id, onSuccess }: DeleteUserProps) => {
|
||||||
|
const [isOpen, setIsOpen] = useState(false)
|
||||||
|
const queryClient = useQueryClient()
|
||||||
|
const { showSuccessToast, showErrorToast } = useCustomToast()
|
||||||
|
const { handleSubmit } = useForm()
|
||||||
|
|
||||||
|
const deleteUser = async (id: string) => {
|
||||||
|
await UsersService.deleteUser({ userId: id })
|
||||||
|
}
|
||||||
|
|
||||||
|
const mutation = useMutation({
|
||||||
|
mutationFn: deleteUser,
|
||||||
|
onSuccess: () => {
|
||||||
|
showSuccessToast("The user was deleted successfully")
|
||||||
|
setIsOpen(false)
|
||||||
|
onSuccess()
|
||||||
|
},
|
||||||
|
onError: handleError.bind(showErrorToast),
|
||||||
|
onSettled: () => {
|
||||||
|
queryClient.invalidateQueries()
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
const onSubmit = async () => {
|
||||||
|
mutation.mutate(id)
|
||||||
|
}
|
||||||
|
|
||||||
|
return (
|
||||||
|
<Dialog open={isOpen} onOpenChange={setIsOpen}>
|
||||||
|
<DropdownMenuItem
|
||||||
|
variant="destructive"
|
||||||
|
onSelect={(e) => e.preventDefault()}
|
||||||
|
onClick={() => setIsOpen(true)}
|
||||||
|
>
|
||||||
|
<Trash2 />
|
||||||
|
Delete User
|
||||||
|
</DropdownMenuItem>
|
||||||
|
<DialogContent className="sm:max-w-md">
|
||||||
|
<form onSubmit={handleSubmit(onSubmit)}>
|
||||||
|
<DialogHeader>
|
||||||
|
<DialogTitle>Delete User</DialogTitle>
|
||||||
|
<DialogDescription>
|
||||||
|
All items associated with this user will also be{" "}
|
||||||
|
<strong>permanently deleted.</strong> Are you sure? You will not
|
||||||
|
be able to undo this action.
|
||||||
|
</DialogDescription>
|
||||||
|
</DialogHeader>
|
||||||
|
|
||||||
|
<DialogFooter className="mt-4">
|
||||||
|
<DialogClose asChild>
|
||||||
|
<Button variant="outline" disabled={mutation.isPending}>
|
||||||
|
Cancel
|
||||||
|
</Button>
|
||||||
|
</DialogClose>
|
||||||
|
<LoadingButton
|
||||||
|
variant="destructive"
|
||||||
|
type="submit"
|
||||||
|
loading={mutation.isPending}
|
||||||
|
>
|
||||||
|
Delete
|
||||||
|
</LoadingButton>
|
||||||
|
</DialogFooter>
|
||||||
|
</form>
|
||||||
|
</DialogContent>
|
||||||
|
</Dialog>
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
export default DeleteUser
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user