fastapi-voyager 0.10.1__tar.gz → 0.10.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/PKG-INFO +11 -7
  2. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/README.md +10 -6
  3. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/server.py +3 -1
  4. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/version.py +1 -1
  5. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/index.html +4 -3
  6. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/vue-main.js +3 -1
  7. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/.gitignore +0 -0
  8. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/.python-version +0 -0
  9. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/LICENSE +0 -0
  10. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/pyproject.toml +0 -0
  11. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/__init__.py +0 -0
  12. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/cli.py +0 -0
  13. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/filter.py +0 -0
  14. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/module.py +0 -0
  15. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/render.py +0 -0
  16. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/type.py +0 -0
  17. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/type_helper.py +0 -0
  18. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/voyager.py +0 -0
  19. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/component/render-graph.js +0 -0
  20. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/component/route-code-display.js +0 -0
  21. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/component/schema-code-display.js +0 -0
  22. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/component/schema-field-filter.js +0 -0
  23. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/graph-ui.js +0 -0
  24. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/graphviz.svg.css +0 -0
  25. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/graphviz.svg.js +0 -0
  26. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/icon/android-chrome-192x192.png +0 -0
  27. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/icon/android-chrome-512x512.png +0 -0
  28. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/icon/apple-touch-icon.png +0 -0
  29. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/icon/favicon-16x16.png +0 -0
  30. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/icon/favicon-32x32.png +0 -0
  31. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/icon/favicon.ico +0 -0
  32. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/icon/site.webmanifest +0 -0
  33. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/quasar.min.css +0 -0
  34. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/src/fastapi_voyager/web/quasar.min.js +0 -0
  35. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/tests/__init__.py +0 -0
  36. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/tests/demo.py +0 -0
  37. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/tests/demo_anno.py +0 -0
  38. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/tests/programatic.py +0 -0
  39. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/tests/service/__init__.py +0 -0
  40. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/tests/service/schema.py +0 -0
  41. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/tests/test_analysis.py +0 -0
  42. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/tests/test_filter.py +0 -0
  43. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/tests/test_generic.py +0 -0
  44. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/tests/test_import.py +0 -0
  45. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/tests/test_module.py +0 -0
  46. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/tests/test_type_helper.py +0 -0
  47. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/uv.lock +0 -0
  48. {fastapi_voyager-0.10.1 → fastapi_voyager-0.10.2}/voyager.jpg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: fastapi-voyager
3
- Version: 0.10.1
3
+ Version: 0.10.2
4
4
  Summary: Visualize FastAPI application's routing tree and dependencies
5
5
  Project-URL: Homepage, https://github.com/allmonday/fastapi-voyager
6
6
  Project-URL: Source, https://github.com/allmonday/fastapi-voyager
@@ -226,12 +226,16 @@ or you can open router_viz.dot with vscode extension `graphviz interactive previ
226
226
  - [x] route list should have a max height
227
227
 
228
228
  #### 0.10
229
- - [x] refactor voyager.py tag -> route structure
230
- - [x] fix missing route (tag has only one route which return primitive value)
231
- - [x] make right panel resizable by dragging
232
- - [x] allow closing tag expansion item
233
- - [x] hide brief mode if not configured
234
- - [x] add focus button to only show related nodes under current route/tag graph in dialog
229
+ - 0.10.1
230
+ - [x] refactor voyager.py tag -> route structure
231
+ - [x] fix missing route (tag has only one route which return primitive value)
232
+ - [x] make right panel resizable by dragging
233
+ - [x] allow closing tag expansion item
234
+ - [x] hide brief mode if not configured
235
+ - [x] add focus button to only show related nodes under current route/tag graph in dialog
236
+ - 0.10.2
237
+ - [x] fix graph height
238
+ - [x] show version in title
235
239
 
236
240
  #### 0.11
237
241
  - [ ] enable/disable module cluster (to save space)
@@ -199,12 +199,16 @@ or you can open router_viz.dot with vscode extension `graphviz interactive previ
199
199
  - [x] route list should have a max height
200
200
 
201
201
  #### 0.10
202
- - [x] refactor voyager.py tag -> route structure
203
- - [x] fix missing route (tag has only one route which return primitive value)
204
- - [x] make right panel resizable by dragging
205
- - [x] allow closing tag expansion item
206
- - [x] hide brief mode if not configured
207
- - [x] add focus button to only show related nodes under current route/tag graph in dialog
202
+ - 0.10.1
203
+ - [x] refactor voyager.py tag -> route structure
204
+ - [x] fix missing route (tag has only one route which return primitive value)
205
+ - [x] make right panel resizable by dragging
206
+ - [x] allow closing tag expansion item
207
+ - [x] hide brief mode if not configured
208
+ - [x] add focus button to only show related nodes under current route/tag graph in dialog
209
+ - 0.10.2
210
+ - [x] fix graph height
211
+ - [x] show version in title
208
212
 
209
213
  #### 0.11
210
214
  - [ ] enable/disable module cluster (to save space)
@@ -9,6 +9,7 @@ from fastapi_voyager.voyager import Voyager
9
9
  from fastapi_voyager.type import Tag, FieldInfo, CoreData, SchemaNode
10
10
  from fastapi_voyager.render import Renderer
11
11
  from fastapi_voyager.type_helper import get_source, get_vscode_link
12
+ from fastapi_voyager.version import __version__
12
13
 
13
14
 
14
15
  WEB_DIR = Path(__file__).parent / "web"
@@ -20,6 +21,7 @@ class OptionParam(BaseModel):
20
21
  schemas: list[SchemaNode]
21
22
  dot: str
22
23
  enable_brief_mode: bool
24
+ version: str
23
25
 
24
26
  class Payload(BaseModel):
25
27
  tags: Optional[list[str]] = None
@@ -54,7 +56,7 @@ def create_route(
54
56
  schemas = voyager.nodes[:]
55
57
  schemas.sort(key=lambda s: s.name)
56
58
 
57
- return OptionParam(tags=tags, schemas=schemas, dot=dot, enable_brief_mode=bool(module_prefix))
59
+ return OptionParam(tags=tags, schemas=schemas, dot=dot, enable_brief_mode=bool(module_prefix), version=__version__)
58
60
 
59
61
  @router.post("/dot", response_class=PlainTextResponse)
60
62
  def get_filtered_dot(payload: Payload) -> str:
@@ -1,2 +1,2 @@
1
1
  __all__ = ["__version__"]
2
- __version__ = "0.10.1"
2
+ __version__ = "0.10.2"
@@ -57,7 +57,7 @@
57
57
  }
58
58
 
59
59
  .adjust-fit {
60
- height: calc(100% - 54px);
60
+ height: calc(100vh - 54px);
61
61
  }
62
62
  </style>
63
63
  <body>
@@ -67,10 +67,11 @@
67
67
  <q-toolbar class="row text-grey-9 bg-white" style="width: 100%">
68
68
  <div
69
69
  class="col-auto text-primary"
70
- style="font-size: 16px; font-weight: bold"
70
+ style="font-size: 18px; font-weight: bold; display: flex; align-items: baseline;"
71
71
  >
72
72
  <q-icon class="q-mr-sm" name="satellite_alt"></q-icon>
73
73
  <span> FastAPI Voyager </span>
74
+ <span v-if="state.version" style="font-size: 12px; margin-left: 8px; font-weight: normal;">{{ state.version }}</span>
74
75
  </div>
75
76
  <div class="col-auto" style="font-size: 16px">
76
77
  <q-option-group
@@ -279,7 +280,7 @@
279
280
 
280
281
  <template #after>
281
282
  <div style="position: relative; width: 100%; height: 100%;">
282
- <div id="graph" class="fit"></div>
283
+ <div id="graph" class="adjust-fit"></div>
283
284
  <q-toggle
284
285
  v-model="state.focus"
285
286
  v-show="schemaCodeName"
@@ -31,7 +31,8 @@ const app = createApp({
31
31
  // Splitter size (left panel width in px)
32
32
  splitter: 300,
33
33
  detailDrawer: false,
34
- drawerWidth: 500, // drawer 宽度
34
+ drawerWidth: 300, // drawer 宽度
35
+ version: "", // version from backend
35
36
  });
36
37
 
37
38
  const showDetail = ref(false);
@@ -75,6 +76,7 @@ const app = createApp({
75
76
  return acc;
76
77
  }, {});
77
78
  state.enableBriefMode = data.enable_brief_mode || false;
79
+ state.version = data.version || "";
78
80
 
79
81
  // default route options placeholder
80
82
  } catch (e) {