django-spire 0.18.3__py3-none-any.whl → 0.19.1__py3-none-any.whl

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 (246) hide show
  1. django_spire/ai/admin.py +1 -0
  2. django_spire/ai/chat/apps.py +1 -8
  3. django_spire/ai/chat/intelligence/decoders/tools.py +29 -0
  4. django_spire/ai/chat/intelligence/prompts.py +13 -7
  5. django_spire/ai/chat/intelligence/workflows/chat_workflow.py +55 -57
  6. django_spire/ai/chat/models.py +2 -1
  7. django_spire/ai/chat/querysets.py +1 -3
  8. django_spire/ai/chat/responses.py +5 -0
  9. django_spire/ai/chat/templates/django_spire/ai/chat/card/chat_card.html +2 -2
  10. django_spire/ai/chat/templates/django_spire/ai/chat/dropdown/ellipsis_dropdown.html +1 -1
  11. django_spire/ai/chat/templates/django_spire/ai/chat/element/recent_chat_select_element.html +82 -44
  12. django_spire/ai/chat/templates/django_spire/ai/chat/message/loading_response_message.html +9 -4
  13. django_spire/ai/chat/templates/django_spire/ai/chat/message/message.html +33 -33
  14. django_spire/ai/chat/templates/django_spire/ai/chat/message/request_message.html +5 -8
  15. django_spire/ai/chat/templates/django_spire/ai/chat/message/response_message.html +14 -10
  16. django_spire/ai/chat/templates/django_spire/ai/chat/page/chat_page.html +35 -0
  17. django_spire/ai/chat/templates/django_spire/ai/chat/widget/dialog_widget.html +72 -24
  18. django_spire/ai/chat/templates/django_spire/ai/chat/widget/selection_widget.html +42 -0
  19. django_spire/ai/chat/tests/test_urls/test_json_urls.py +4 -2
  20. django_spire/ai/chat/urls/__init__.py +1 -1
  21. django_spire/ai/chat/urls/json_urls.py +1 -1
  22. django_spire/ai/chat/urls/page_urls.py +1 -1
  23. django_spire/ai/chat/urls/{template_urls.py → template/template_urls.py} +1 -1
  24. django_spire/ai/chat/views/json_views.py +4 -3
  25. django_spire/ai/chat/views/message_request_views.py +32 -14
  26. django_spire/ai/chat/views/message_response_views.py +14 -11
  27. django_spire/ai/chat/views/message_views.py +7 -1
  28. django_spire/ai/chat/views/page_views.py +2 -2
  29. django_spire/ai/chat/views/{template_views.py → template/template_views.py} +1 -7
  30. django_spire/ai/context/__init__.py +0 -0
  31. django_spire/ai/context/admin.py +15 -0
  32. django_spire/ai/context/apps.py +16 -0
  33. django_spire/ai/context/choices.py +11 -0
  34. django_spire/ai/context/intelligence/__init__.py +0 -0
  35. django_spire/ai/context/intelligence/prompts/__init__.py +0 -0
  36. django_spire/ai/context/intelligence/prompts/organization_prompts.py +19 -0
  37. django_spire/ai/context/migrations/0001_initial.py +67 -0
  38. django_spire/ai/context/migrations/__init__.py +0 -0
  39. django_spire/ai/context/models.py +67 -0
  40. django_spire/ai/context/querysets.py +15 -0
  41. django_spire/ai/context/seeding/__init__.py +0 -0
  42. django_spire/ai/context/seeding/seed.py +24 -0
  43. django_spire/ai/prompt/system/bots.py +3 -5
  44. django_spire/ai/prompt/tuning/bots.py +5 -10
  45. django_spire/ai/sms/admin.py +2 -0
  46. django_spire/ai/sms/apps.py +2 -7
  47. django_spire/ai/sms/decorators.py +2 -2
  48. django_spire/ai/sms/intelligence/workflows/sms_conversation_workflow.py +18 -18
  49. django_spire/ai/sms/tests/test_webhook.py +5 -4
  50. django_spire/ai/sms/urls.py +3 -0
  51. django_spire/ai/sms/views.py +3 -5
  52. django_spire/ai/urls.py +2 -0
  53. django_spire/auth/templates/django_spire/auth/form/login_form.html +25 -0
  54. django_spire/auth/templates/django_spire/auth/page/auth_page.html +2 -3
  55. django_spire/auth/templates/django_spire/auth/page/login_page.html +1 -25
  56. django_spire/conf.py +1 -3
  57. django_spire/consts.py +1 -7
  58. django_spire/contrib/seeding/intelligence/bots/seeder_generator_bot.py +3 -2
  59. django_spire/contrib/utils.py +2 -0
  60. django_spire/core/management/commands/spire_startapp_pkg/__init__.py +4 -20
  61. django_spire/core/management/commands/spire_startapp_pkg/builder.py +2 -2
  62. django_spire/core/management/commands/spire_startapp_pkg/config.py +2 -2
  63. django_spire/core/management/commands/spire_startapp_pkg/filesystem.py +1 -19
  64. django_spire/core/management/commands/spire_startapp_pkg/generator.py +8 -8
  65. django_spire/core/management/commands/spire_startapp_pkg/processor.py +3 -3
  66. django_spire/core/management/commands/spire_startapp_pkg/registry.py +0 -16
  67. django_spire/core/management/commands/spire_startapp_pkg/reporter.py +1 -21
  68. django_spire/core/management/commands/spire_startapp_pkg/resolver.py +0 -15
  69. django_spire/core/management/commands/spire_startapp_pkg/template/app/views/form_views.py.template +2 -2
  70. django_spire/core/management/commands/spire_startapp_pkg/template/app/views/page_views.py.template +2 -2
  71. django_spire/core/management/commands/spire_startapp_pkg/validator.py +9 -9
  72. django_spire/core/static/django_spire/css/app-button.css +11 -1
  73. django_spire/core/static/django_spire/css/app-import.css +2 -0
  74. django_spire/core/static/django_spire/css/app-layout.css +15 -0
  75. django_spire/core/static/django_spire/css/app-navigation.css +24 -2
  76. django_spire/core/static/django_spire/css/app-page.css +8 -0
  77. django_spire/core/static/django_spire/css/app-side-panel.css +102 -0
  78. django_spire/core/static/django_spire/css/app-text.css +19 -1
  79. django_spire/core/static/django_spire/css/bootstrap-extension.css +128 -7
  80. django_spire/core/static/django_spire/css/bootstrap-override.css +161 -111
  81. django_spire/core/static/django_spire/css/themes/ayu/app-dark.css +0 -4
  82. django_spire/core/static/django_spire/css/themes/ayu/app-light.css +0 -4
  83. django_spire/core/static/django_spire/css/themes/catppuccin/app-dark.css +0 -4
  84. django_spire/core/static/django_spire/css/themes/catppuccin/app-light.css +0 -4
  85. django_spire/core/static/django_spire/css/themes/default/app-dark.css +0 -4
  86. django_spire/core/static/django_spire/css/themes/default/app-light.css +0 -4
  87. django_spire/core/static/django_spire/css/themes/dracula/app-dark.css +0 -4
  88. django_spire/core/static/django_spire/css/themes/dracula/app-light.css +0 -4
  89. django_spire/core/static/django_spire/css/themes/gruvbox/app-dark.css +0 -4
  90. django_spire/core/static/django_spire/css/themes/gruvbox/app-light.css +0 -4
  91. django_spire/core/static/django_spire/css/themes/material/app-dark.css +0 -4
  92. django_spire/core/static/django_spire/css/themes/material/app-light.css +0 -4
  93. django_spire/core/static/django_spire/css/themes/nord/app-dark.css +0 -4
  94. django_spire/core/static/django_spire/css/themes/nord/app-light.css +0 -4
  95. django_spire/core/static/django_spire/css/themes/oceanic-next/app-dark.css +0 -4
  96. django_spire/core/static/django_spire/css/themes/oceanic-next/app-light.css +0 -4
  97. django_spire/core/static/django_spire/css/themes/one-dark/app-dark.css +0 -4
  98. django_spire/core/static/django_spire/css/themes/one-dark/app-light.css +0 -4
  99. django_spire/core/static/django_spire/css/themes/palenight/app-dark.css +0 -4
  100. django_spire/core/static/django_spire/css/themes/palenight/app-light.css +0 -4
  101. django_spire/core/static/django_spire/css/themes/rose-pine/app-dark.css +0 -4
  102. django_spire/core/static/django_spire/css/themes/rose-pine/app-light.css +0 -4
  103. django_spire/core/static/django_spire/css/themes/synthwave/app-dark.css +0 -4
  104. django_spire/core/static/django_spire/css/themes/synthwave/app-light.css +0 -4
  105. django_spire/core/static/django_spire/css/themes/tokyo-night/app-dark.css +0 -4
  106. django_spire/core/static/django_spire/css/themes/tokyo-night/app-light.css +0 -4
  107. django_spire/core/static/django_spire/font/Poppins-Black.ttf +0 -0
  108. django_spire/core/static/django_spire/font/Poppins-BlackItalic.ttf +0 -0
  109. django_spire/core/static/django_spire/font/Poppins-Bold.ttf +0 -0
  110. django_spire/core/static/django_spire/font/Poppins-BoldItalic.ttf +0 -0
  111. django_spire/core/static/django_spire/font/Poppins-ExtraBold.ttf +0 -0
  112. django_spire/core/static/django_spire/font/Poppins-ExtraBoldItalic.ttf +0 -0
  113. django_spire/core/static/django_spire/font/Poppins-ExtraLight.ttf +0 -0
  114. django_spire/core/static/django_spire/font/Poppins-ExtraLightItalic.ttf +0 -0
  115. django_spire/core/static/django_spire/font/Poppins-Italic.ttf +0 -0
  116. django_spire/core/static/django_spire/font/Poppins-Light.ttf +0 -0
  117. django_spire/core/static/django_spire/font/Poppins-LightItalic.ttf +0 -0
  118. django_spire/core/static/django_spire/font/Poppins-Medium.ttf +0 -0
  119. django_spire/core/static/django_spire/font/Poppins-MediumItalic.ttf +0 -0
  120. django_spire/core/static/django_spire/font/Poppins-SemiBold.ttf +0 -0
  121. django_spire/core/static/django_spire/font/Poppins-SemiBoldItalic.ttf +0 -0
  122. django_spire/core/static/django_spire/font/Poppins-Thin.ttf +0 -0
  123. django_spire/core/static/django_spire/font/Poppins-ThinItalic.ttf +0 -0
  124. django_spire/core/static/django_spire/js/ui.js +12 -0
  125. django_spire/core/templates/django_spire/button/base_button.html +1 -1
  126. django_spire/core/templates/django_spire/button/primary_dark_outlined_button.html +3 -0
  127. django_spire/core/templates/django_spire/dropdown/element/dropdown_link_element.html +12 -8
  128. django_spire/core/templates/django_spire/dropdown/element/ellipsis_dropdown_modal_link_element.html +2 -1
  129. django_spire/core/templates/django_spire/dropdown/ellipsis_dropdown.html +2 -1
  130. django_spire/core/templates/django_spire/navigation/accordion/nav_accordion.html +1 -1
  131. django_spire/core/templates/django_spire/navigation/elements/nav_link.html +1 -1
  132. django_spire/core/templates/django_spire/navigation/elements/nav_title_divider.html +1 -1
  133. django_spire/core/templates/django_spire/navigation/side_navigation.html +52 -8
  134. django_spire/core/templates/django_spire/navigation/top_navigation.html +8 -2
  135. django_spire/core/templates/django_spire/page/full_page.html +223 -11
  136. django_spire/core/utils.py +26 -2
  137. django_spire/knowledge/collection/models.py +24 -0
  138. django_spire/knowledge/collection/services/transformation_service.py +2 -1
  139. django_spire/knowledge/collection/tests/test_services/test_transformation_service.py +44 -42
  140. django_spire/knowledge/collection/urls/form_urls.py +1 -0
  141. django_spire/knowledge/collection/urls/page_urls.py +1 -0
  142. django_spire/knowledge/collection/views/form_views.py +13 -2
  143. django_spire/knowledge/collection/views/page_views.py +36 -4
  144. django_spire/knowledge/entry/models.py +32 -0
  145. django_spire/knowledge/entry/services/transformation_services.py +10 -10
  146. django_spire/knowledge/entry/version/block/data/data.py +2 -1
  147. django_spire/knowledge/entry/version/block/data/heading_data.py +2 -2
  148. django_spire/knowledge/entry/version/block/data/list/data.py +3 -4
  149. django_spire/knowledge/entry/version/block/data/maps.py +3 -5
  150. django_spire/knowledge/entry/version/block/data/text_data.py +2 -2
  151. django_spire/knowledge/entry/version/block/models.py +10 -7
  152. django_spire/knowledge/entry/version/block/services/factory_service.py +11 -10
  153. django_spire/knowledge/entry/version/block/tests/factories.py +6 -5
  154. django_spire/knowledge/entry/version/converters/docx_converter.py +1 -1
  155. django_spire/knowledge/entry/version/intelligence/bots/markdown_format_llm_bot.py +14 -12
  156. django_spire/knowledge/entry/version/seeding/seeder.py +3 -3
  157. django_spire/knowledge/entry/version/services/processor_service.py +36 -10
  158. django_spire/knowledge/entry/version/tests/test_converters/test_docx_converter.py +1 -1
  159. django_spire/knowledge/entry/version/tests/test_urls/test_page_urls.py +1 -1
  160. django_spire/knowledge/entry/version/urls/page_urls.py +1 -1
  161. django_spire/knowledge/entry/version/views/json_views.py +5 -3
  162. django_spire/knowledge/entry/version/views/page_views.py +11 -12
  163. django_spire/knowledge/entry/version/views/redirect_views.py +1 -1
  164. django_spire/knowledge/entry/views/form_views.py +1 -1
  165. django_spire/knowledge/intelligence/bots/entry_search_llm_bot.py +33 -11
  166. django_spire/knowledge/intelligence/decoders/__init__.py +0 -0
  167. django_spire/knowledge/intelligence/{maps/collection_map.py → decoders/collection_decoder.py} +5 -5
  168. django_spire/knowledge/intelligence/{maps/entry_map.py → decoders/entry_decoder.py} +3 -3
  169. django_spire/knowledge/intelligence/intel/collection_intel.py +1 -0
  170. django_spire/knowledge/intelligence/intel/entry_intel.py +5 -2
  171. django_spire/knowledge/intelligence/intel/message_intel.py +2 -0
  172. django_spire/knowledge/intelligence/workflows/knowledge_workflow.py +43 -51
  173. django_spire/knowledge/migrations/0007_alter_collection_options.py +17 -0
  174. django_spire/knowledge/static/django_spire/knowledge/entry/version/js/editor.js +24 -5
  175. django_spire/knowledge/templates/django_spire/knowledge/collection/card/top_level_list_card.html +21 -0
  176. django_spire/knowledge/templates/django_spire/knowledge/collection/component/x_collection_navigation.html +15 -6
  177. django_spire/knowledge/templates/django_spire/knowledge/collection/element/ellipsis_dropdown.html +22 -0
  178. django_spire/knowledge/templates/django_spire/knowledge/collection/form/form.html +21 -9
  179. django_spire/knowledge/templates/django_spire/knowledge/collection/item/collection_item.html +19 -0
  180. django_spire/knowledge/templates/django_spire/knowledge/collection/page/display_page.html +49 -0
  181. django_spire/knowledge/templates/django_spire/knowledge/collection/page/form_page.html +1 -1
  182. django_spire/knowledge/templates/django_spire/knowledge/container/container.html +33 -0
  183. django_spire/knowledge/templates/django_spire/knowledge/entry/file/page/list_page.html +1 -1
  184. django_spire/knowledge/templates/django_spire/knowledge/entry/item/list_item.html +2 -2
  185. django_spire/knowledge/templates/django_spire/knowledge/entry/page/form_page.html +1 -1
  186. django_spire/knowledge/templates/django_spire/knowledge/entry/page/import_form_page.html +1 -1
  187. django_spire/knowledge/templates/django_spire/knowledge/entry/version/container/detail_container.html +51 -45
  188. django_spire/knowledge/templates/django_spire/knowledge/entry/version/page/editor_page.html +54 -0
  189. django_spire/knowledge/templates/django_spire/knowledge/entry/version/page/form_page.html +1 -1
  190. django_spire/knowledge/templates/django_spire/knowledge/message/knowledge_message_intel.html +18 -1
  191. django_spire/knowledge/templates/django_spire/knowledge/page/full_page.html +37 -0
  192. django_spire/knowledge/templates/django_spire/knowledge/page/home_page.html +2 -2
  193. django_spire/knowledge/templates/django_spire/knowledge/sub_navigation/item/collection_sub_navigation_item.html +29 -0
  194. django_spire/knowledge/templates/django_spire/knowledge/sub_navigation/item/entry_sub_navigation_item.html +20 -0
  195. django_spire/knowledge/templates/django_spire/knowledge/{navigation/content/navigation_content.html → sub_navigation/widget/collection_entry_sub_navigation_widget.html} +42 -19
  196. django_spire/knowledge/views/page_views.py +4 -4
  197. django_spire/settings.py +3 -3
  198. django_spire/theme/templates/django_spire/theme/card/badges_preview_card.html +0 -1
  199. django_spire/theme/templates/django_spire/theme/card/base_preview_card.html +1 -0
  200. django_spire/theme/templates/django_spire/theme/card/typography_preview_card.html +1 -1
  201. django_spire/theme/templates/django_spire/theme/example/form/example_form.html +2 -0
  202. django_spire/theme/templates/django_spire/theme/example/form/example_form_card.html +5 -0
  203. django_spire/theme/templates/django_spire/theme/page/badges_page.html +7 -9
  204. django_spire/theme/templates/django_spire/theme/page/borders_page.html +6 -9
  205. django_spire/theme/templates/django_spire/theme/page/buttons_page.html +6 -9
  206. django_spire/theme/templates/django_spire/theme/page/colors_page.html +6 -6
  207. django_spire/theme/templates/django_spire/theme/page/dashboard_page.html +57 -0
  208. django_spire/theme/templates/django_spire/theme/page/django_glue_page.html +7 -9
  209. django_spire/theme/templates/django_spire/theme/page/theme_page.html +24 -0
  210. django_spire/theme/templates/django_spire/theme/page/typography_page.html +6 -9
  211. django_spire/theme/templates/django_spire/theme/section/badge_section_card.html +5 -0
  212. django_spire/theme/templates/django_spire/theme/section/border_section_card.html +5 -0
  213. django_spire/theme/templates/django_spire/theme/section/button_section.html +1 -0
  214. django_spire/theme/templates/django_spire/theme/section/button_section_card.html +5 -0
  215. django_spire/theme/templates/django_spire/theme/section/color_section.html +10 -10
  216. django_spire/theme/templates/django_spire/theme/section/color_section_card.html +5 -0
  217. django_spire/theme/templates/django_spire/theme/section/typography_section.html +41 -1
  218. django_spire/theme/templates/django_spire/theme/section/typography_section_card.html +5 -0
  219. {django_spire-0.18.3.dist-info → django_spire-0.19.1.dist-info}/METADATA +3 -3
  220. {django_spire-0.18.3.dist-info → django_spire-0.19.1.dist-info}/RECORD +229 -190
  221. django_spire/ai/chat/intelligence/bots/chat_bot.py +0 -8
  222. django_spire/ai/chat/intelligence/maps/intent_llm_map.py +0 -10
  223. django_spire/ai/chat/templates/django_spire/ai/chat/page/home_page.html +0 -9
  224. django_spire/ai/chat/templates/django_spire/ai/chat/widget/chat_widget.html +0 -64
  225. django_spire/ai/chat/templates/django_spire/ai/chat/widget/search_chat_results_widget.html +0 -25
  226. django_spire/ai/chat/templates/django_spire/ai/chat/widget/search_chat_widget.html +0 -39
  227. django_spire/ai/chat/templates/django_spire/ai/chat/widget/select_chat_widget.html +0 -24
  228. django_spire/ai/chat/tools.py +0 -57
  229. django_spire/ai/sms/tools.py +0 -57
  230. django_spire/core/static/django_spire/font/Karla-Bold.ttf +0 -0
  231. django_spire/core/static/django_spire/font/Merriweather.ttf +0 -0
  232. django_spire/knowledge/context_processors.py +0 -18
  233. django_spire/knowledge/templates/django_spire/knowledge/entry/version/page/detail_page.html +0 -25
  234. django_spire/knowledge/templates/django_spire/knowledge/navigation/card/navigation_card.html +0 -9
  235. django_spire/knowledge/templates/django_spire/knowledge/navigation/item/collection/collection_item.html +0 -29
  236. django_spire/knowledge/templates/django_spire/knowledge/navigation/item/entry/entry_item.html +0 -18
  237. django_spire/knowledge/templates/django_spire/knowledge/navigation/page/full_page.html +0 -90
  238. /django_spire/ai/chat/intelligence/{bots → decoders}/__init__.py +0 -0
  239. /django_spire/ai/chat/{intelligence/maps → urls/template}/__init__.py +0 -0
  240. /django_spire/{knowledge/intelligence/maps → ai/chat/views/template}/__init__.py +0 -0
  241. /django_spire/knowledge/entry/version/{constants.py → consts.py} +0 -0
  242. /django_spire/knowledge/templates/django_spire/knowledge/{navigation/item/collection/dropdown/navigation_ellipsis_dropdown.html → sub_navigation/element/collection_sub_navigation_ellipsis_dropdown.html} +0 -0
  243. /django_spire/knowledge/templates/django_spire/knowledge/{navigation/item/entry/dropdown/navigation_ellipsis_dropdown.html → sub_navigation/element/entry_sub_navigation_ellipsis_dropdown.html} +0 -0
  244. {django_spire-0.18.3.dist-info → django_spire-0.19.1.dist-info}/WHEEL +0 -0
  245. {django_spire-0.18.3.dist-info → django_spire-0.19.1.dist-info}/licenses/LICENSE.md +0 -0
  246. {django_spire-0.18.3.dist-info → django_spire-0.19.1.dist-info}/top_level.txt +0 -0
@@ -8,7 +8,7 @@ from django_spire.core.management.commands.spire_startapp_pkg.maps import genera
8
8
  if TYPE_CHECKING:
9
9
  from pathlib import Path
10
10
 
11
- from django_spire.core.management.commands.spire_startapp_pkg.filesystem import FileSystemInterface
11
+ from django_spire.core.management.commands.spire_startapp_pkg.filesystem import FileSystem
12
12
 
13
13
 
14
14
  class TemplateEngine:
@@ -40,12 +40,12 @@ class TemplateProcessor:
40
40
  and manages file renaming based on user configuration.
41
41
  """
42
42
 
43
- def __init__(self, engine: TemplateEngine, filesystem: FileSystemInterface):
43
+ def __init__(self, engine: TemplateEngine, filesystem: FileSystem):
44
44
  """
45
45
  Initializes the processor with an engine and file system.
46
46
 
47
47
  :param engine: Template engine for rendering strings.
48
- :param filesystem: File system interface for file operations.
48
+ :param filesystem: File system for file operations.
49
49
  """
50
50
 
51
51
  self._engine = engine
@@ -1,25 +1,9 @@
1
1
  from __future__ import annotations
2
2
 
3
- from typing import Protocol
4
-
5
3
  from django.apps import apps
6
4
  from django.conf import settings
7
5
 
8
6
 
9
- class AppRegistryInterface(Protocol):
10
- """
11
- Protocol defining the interface for Django app registry operations.
12
-
13
- This protocol specifies methods for querying registered apps and
14
- validating app component paths.
15
- """
16
-
17
- def get_installed_apps(self) -> list[str]: ...
18
- def get_missing_components(self, components: list[str]) -> list[str]: ...
19
- def get_valid_root_apps(self) -> set[str]: ...
20
- def is_app_registered(self, app_path: str) -> bool: ...
21
-
22
-
23
7
  class AppRegistry:
24
8
  """
25
9
  Manages Django app registration information.
@@ -1,7 +1,7 @@
1
1
  from __future__ import annotations
2
2
 
3
3
  from string import Template
4
- from typing import Protocol, TYPE_CHECKING
4
+ from typing import TYPE_CHECKING
5
5
 
6
6
  from django_spire.core.management.commands.spire_startapp_pkg.maps import generate_replacement_map
7
7
 
@@ -12,26 +12,6 @@ if TYPE_CHECKING:
12
12
  from django.core.management.base import BaseCommand
13
13
 
14
14
 
15
- class ReporterInterface(Protocol):
16
- """
17
- Protocol defining the interface for reporting and user interaction.
18
-
19
- This protocol specifies methods for displaying messages, prompts,
20
- and tree structures to the user during app creation.
21
- """
22
-
23
- def prompt_confirmation(self, message: str) -> bool: ...
24
- def report_app_creation_success(self, app: str) -> None: ...
25
- def report_app_exists(self, app: str, destination: Path) -> None: ...
26
- def report_creating_app(self, app: str, destination: Path) -> None: ...
27
- def report_creating_templates(self, app: str, destination: Path) -> None: ...
28
- def report_installed_apps_suggestion(self, missing_components: list[str]) -> None: ...
29
- def report_missing_components(self, missing_components: list[str]) -> None: ...
30
- def report_templates_creation_success(self, app: str) -> None: ...
31
- def report_templates_exist(self, app: str, destination: Path) -> None: ...
32
- def write(self, message: str, style: Callable[[str], str]) -> None: ...
33
-
34
-
35
15
  class Reporter:
36
16
  """
37
17
  Handles user interaction and console output for the app creation command.
@@ -1,25 +1,10 @@
1
1
  from __future__ import annotations
2
2
 
3
3
  from pathlib import Path
4
- from typing import Protocol
5
4
 
6
5
  from django.conf import settings
7
6
 
8
7
 
9
- class PathResolverInterface(Protocol):
10
- """
11
- Protocol defining the interface for resolving file system paths.
12
-
13
- This protocol specifies methods for determining where apps and
14
- templates should be created in the file system.
15
- """
16
-
17
- def get_app_destination(self, components: list[str]) -> Path: ...
18
- def get_base_dir(self) -> Path: ...
19
- def get_template_destination(self, components: list[str]) -> Path: ...
20
- def get_template_dir(self) -> Path: ...
21
-
22
-
23
8
  class PathResolver:
24
9
  """
25
10
  Resolves file system paths for app and template creation.
@@ -89,7 +89,7 @@ def _modal_form_view(request: WSGIRequest, pk: int = 0) -> TemplateResponse:
89
89
  return TemplateResponse(
90
90
  request,
91
91
  context=context_data,
92
- template='${template_directory_path}/modal/content/${form_template_name}'
92
+ template='${template_directory_path}/modal/content/${form_template_name}.html'
93
93
  )
94
94
 
95
95
 
@@ -130,5 +130,5 @@ def _form_view(request: WSGIRequest, pk: int = 0) -> TemplateResponse|HttpRespon
130
130
  request,
131
131
  form=form,
132
132
  obj=${context_single_var},
133
- template='${template_directory_path}/page/${form_page_template_name}'
133
+ template='${template_directory_path}/page/${form_page_template_name}.html'
134
134
  )
@@ -26,7 +26,7 @@ def ${detail_page_view_name}(request: WSGIRequest, pk: int) -> TemplateResponse:
26
26
  request,
27
27
  obj=${context_single_var},
28
28
  context_data=context_data,
29
- template='${template_directory_path}/page/${detail_page_template_name}'
29
+ template='${template_directory_path}/page/${detail_page_template_name}.html'
30
30
  )
31
31
 
32
32
 
@@ -40,5 +40,5 @@ def ${list_page_view_name}(request: WSGIRequest) -> TemplateResponse:
40
40
  request,
41
41
  model=models.${model_class_name},
42
42
  context_data=context_data,
43
- template='${template_directory_path}/page/${list_page_template_name}'
43
+ template='${template_directory_path}/page/${list_page_template_name}.html'
44
44
  )
@@ -5,10 +5,10 @@ from typing import TYPE_CHECKING
5
5
  from django.core.management.base import CommandError
6
6
 
7
7
  if TYPE_CHECKING:
8
- from django_spire.core.management.commands.spire_startapp_pkg.filesystem import FileSystemInterface
9
- from django_spire.core.management.commands.spire_startapp_pkg.registry import AppRegistryInterface
10
- from django_spire.core.management.commands.spire_startapp_pkg.reporter import ReporterInterface
11
- from django_spire.core.management.commands.spire_startapp_pkg.resolver import PathResolverInterface
8
+ from django_spire.core.management.commands.spire_startapp_pkg.filesystem import FileSystem
9
+ from django_spire.core.management.commands.spire_startapp_pkg.registry import AppRegistry
10
+ from django_spire.core.management.commands.spire_startapp_pkg.reporter import Reporter
11
+ from django_spire.core.management.commands.spire_startapp_pkg.resolver import PathResolver
12
12
 
13
13
 
14
14
  class AppValidator:
@@ -21,10 +21,10 @@ class AppValidator:
21
21
 
22
22
  def __init__(
23
23
  self,
24
- reporter: ReporterInterface,
25
- registry: AppRegistryInterface,
26
- path_resolver: PathResolverInterface,
27
- filesystem: FileSystemInterface
24
+ reporter: Reporter,
25
+ registry: AppRegistry,
26
+ path_resolver: PathResolver,
27
+ filesystem: FileSystem
28
28
  ):
29
29
  """
30
30
  Initializes the validator with required dependencies.
@@ -32,7 +32,7 @@ class AppValidator:
32
32
  :param reporter: Reporter for displaying error messages.
33
33
  :param registry: Registry for checking installed apps.
34
34
  :param path_resolver: Path resolver for determining file locations.
35
- :param filesystem: File system interface for checking file existence.
35
+ :param filesystem: File system for checking file existence.
36
36
  """
37
37
 
38
38
  self._filesystem = filesystem
@@ -67,11 +67,21 @@
67
67
  }
68
68
 
69
69
  .btn-app-primary-outlined {
70
+ color: var(--app-btn-primary) !important;
71
+ border: 1px solid var(--app-btn-primary) !important;
72
+ }
73
+
74
+ .btn-app-primary-outlined:hover {
75
+ background-color: var(--app-btn-primary) !important;
76
+ color: var(--app-default-button-text-color) !important;
77
+ }
78
+
79
+ .btn-app-primary-dark-outlined {
70
80
  color: var(--app-btn-primary-dark) !important;
71
81
  border: 1px solid var(--app-btn-primary-dark) !important;
72
82
  }
73
83
 
74
- .btn-app-primary-outlined:hover {
84
+ .btn-app-primary-dark-outlined:hover {
75
85
  background-color: var(--app-btn-primary-dark) !important;
76
86
  color: var(--app-default-button-text-color) !important;
77
87
  }
@@ -1,4 +1,5 @@
1
1
  @import url('app-default.css');
2
+ @import url('app-layout.css');
2
3
  @import url('app-theme.css');
3
4
  @import url('app-background.css');
4
5
  @import url('app-border.css');
@@ -6,5 +7,6 @@
6
7
  @import url('app-offcanvas.css');
7
8
  @import url('app-navigation.css');
8
9
  @import url('app-page.css');
10
+ @import url('app-side-panel.css');
9
11
  @import url('app-text.css');
10
12
  @import url('app-template.css');
@@ -0,0 +1,15 @@
1
+ :root {
2
+ --app-footer-height: 70px;
3
+ --app-mobile-navigation-width: 250px;
4
+ --app-side-navigation-width: 250px;
5
+ --app-side-navigation-top-content-height: 230px;
6
+ --app-top-navigation-height: 80px;
7
+
8
+ --app-content-height: calc(100vh - var(--app-top-navigation-height) );
9
+ --app-side-panel-height: calc(100vh - var(--app-top-navigation-height) - 1vh);
10
+ }
11
+
12
+ .vh-minus-top-nav {
13
+ height: calc(100vh - var(--app-top-navigation-height));
14
+ }
15
+
@@ -39,6 +39,11 @@
39
39
  color: var(--app-footer-link-hover-color) !important;
40
40
  }
41
41
 
42
+ .navbar-nav-scroll {
43
+ max-height: calc(100vh - 120px);
44
+ overflow-y: auto;
45
+ }
46
+
42
47
  .top-navigation {
43
48
  background-color: var(--app-top-navigation-bg-color) !important;
44
49
  color: var(--app-top-navigation-text-color) !important;
@@ -52,22 +57,39 @@
52
57
  color: var(--app-top-navigation-link-hover-color) !important;
53
58
  }
54
59
 
55
- /* Must be below top-navigation for mobile side navigation css to be correct */
56
60
  .side-navigation {
57
61
  background-color: var(--app-side-navigation-bg-color) !important;
62
+ border-color: var(--bs-border-color);
63
+ border-right-style: solid;
64
+ border-right-width: 1px;
58
65
  color: var(--app-side-navigation-text-color) !important;
59
66
  width: var(--app-side-navigation-width);
60
67
  }
61
68
 
62
69
  .side-navigation a {
63
70
  color: var(--app-side-navigation-link-color) !important;
71
+ display: block;
72
+ padding: 0.75rem 1rem;
73
+ transition: background-color 0.2s ease, color 0.2s ease;
64
74
  }
65
75
 
66
76
  .side-navigation a:hover {
67
77
  color: var(--app-side-navigation-link-hover-color) !important;
68
78
  }
69
79
 
70
- .vh-minus-nav {
80
+ .side-navigation-fade-bottom {
81
+ background: linear-gradient(to top, var(--app-side-navigation-bg-color) 0%, var(--app-side-navigation-bg-color) 50%, transparent 100%);
82
+ height: 100px;
83
+ pointer-events: none;
84
+ }
85
+
86
+ .side-navigation-fade-top {
87
+ background: linear-gradient(to bottom, var(--app-side-navigation-bg-color) 0%, var(--app-side-navigation-bg-color) 50%, transparent 100%);
88
+ height: 75px;
89
+ pointer-events: none;
90
+ }
91
+
92
+ .vh-minus-top-nav {
71
93
  height: calc(100vh - var(--app-top-navigation-height));
72
94
  }
73
95
 
@@ -2,6 +2,14 @@
2
2
  width: 100%;
3
3
  }
4
4
 
5
+ .main-content-with-panels {
6
+ transition: margin-left 0.3s ease, margin-right 0.3s ease;
7
+ }
8
+
9
+ .main-content-with-panels.with-left-panel {
10
+ margin-left: calc(var(--app-side-panel-width) * 0.5);
11
+ }
12
+
5
13
  @media (min-width: 992px) {
6
14
  .full-page-content {
7
15
  width: calc(100% - var(--app-side-navigation-width));
@@ -0,0 +1,102 @@
1
+ .side-panel {
2
+ background: var(--app-layer-one);
3
+ border-color: var(--app-primary);
4
+ height: var(--app-side-panel-height);
5
+ top: var(--app-top-navigation-height);
6
+ }
7
+
8
+ .btn-close-panel {
9
+ align-items: center;
10
+ background: transparent;
11
+ border: none;
12
+ border-radius: 50%;
13
+ color: var(--app-primary);
14
+ cursor: pointer;
15
+ display: flex;
16
+ height: 28px;
17
+ justify-content: center;
18
+ transition: background 0.2s ease, color 0.2s ease;
19
+ width: 28px;
20
+ }
21
+
22
+ .btn-close-panel:hover {
23
+ background: var(--app-primary);
24
+ color: var(--app-default-button-text-color);
25
+ }
26
+
27
+ .panel-toggle-container {
28
+ height: 30px;
29
+ position: fixed;
30
+ top: 50vh;
31
+ transform: translateY(-50%);
32
+ width: 30px;
33
+ }
34
+
35
+ .panel-toggle-container-left {
36
+ left: 1.5rem;
37
+ }
38
+
39
+ .panel-toggle-container-right {
40
+ right: 1.5rem;
41
+ }
42
+
43
+ .panel-toggle-container .btn {
44
+ border-radius: 50% !important;
45
+ height: 30px !important;
46
+ line-height: 30px !important;
47
+ min-width: 30px !important;
48
+ padding: 0 !important;
49
+ text-align: center !important;
50
+ width: 30px !important;
51
+ }
52
+
53
+ .side-panel-transition-enter {
54
+ transition: opacity 0.3s ease;
55
+ }
56
+
57
+ .side-panel-transition-enter-start-left,
58
+ .side-panel-transition-enter-start-right {
59
+ opacity: 0;
60
+ }
61
+
62
+ .side-panel-transition-enter-end {
63
+ opacity: 1;
64
+ }
65
+
66
+ .side-panel-transition-leave {
67
+ transition: opacity 0.3s ease;
68
+ }
69
+
70
+ .side-panel-transition-leave-start {
71
+ opacity: 1;
72
+ }
73
+
74
+ .side-panel-transition-leave-end-left,
75
+ .side-panel-transition-leave-end-right {
76
+ opacity: 0;
77
+ }
78
+
79
+ @media (min-width: 992px) {
80
+ .panel-toggle-container-left {
81
+ left: var(--app-side-navigation-width);
82
+ }
83
+ }
84
+
85
+ @media (max-width: 991px) {
86
+ .mobile-hide {
87
+ display: none !important;
88
+ }
89
+
90
+ .panel-toggle-container-left {
91
+ left: 0.5rem;
92
+ }
93
+
94
+ .panel-toggle-container-right {
95
+ right: 2rem;
96
+ }
97
+
98
+ .side-panel-left,
99
+ .side-panel-right {
100
+ border: none;
101
+ }
102
+ }
@@ -12,7 +12,7 @@
12
12
  --app-text-accent-dark: var(--app-accent-dark);
13
13
 
14
14
  --app-text-success: var(--app-success);
15
- --app-text-success-outlined: var(--app-success-soft);
15
+ --app-text-success-soft: var(--app-success-soft);
16
16
  --app-text-success-dark: var(--app-success-dark);
17
17
 
18
18
  --app-text-warning: var(--app-warning);
@@ -98,6 +98,18 @@
98
98
  color: var(--app-text-accent-dark) !important;
99
99
  }
100
100
 
101
+ .text-app-success, .text-app-success-hover:hover {
102
+ color: var(--app-text-success) !important;
103
+ }
104
+
105
+ .text-app-success-soft, .text-app-success-soft-hover:hover {
106
+ color: var(--app-text-success-soft) !important;
107
+ }
108
+
109
+ .text-app-success-dark, .text-app-success-dark-hover:hover {
110
+ color: var(--app-text-success-dark) !important;
111
+ }
112
+
101
113
  .text-app-warning, .text-app-warning-hover:hover {
102
114
  color: var(--app-text-warning) !important;
103
115
  }
@@ -189,3 +201,9 @@
189
201
  .text-app-link-footer:hover {
190
202
  color: var(--app-link-footer-hover) !important;
191
203
  }
204
+
205
+ .text-truncate {
206
+ overflow: hidden;
207
+ text-overflow: ellipsis;
208
+ white-space: nowrap;
209
+ }
@@ -3,22 +3,143 @@
3
3
  }
4
4
 
5
5
  @font-face {
6
- font-family: 'Poppins-Regular';
6
+ font-family: 'Poppins';
7
+ src: url('../font/Poppins-Thin.ttf') format('truetype');
8
+ font-weight: 100;
9
+ font-style: normal;
10
+ }
11
+
12
+ @font-face {
13
+ font-family: 'Poppins';
14
+ src: url('../font/Poppins-ThinItalic.ttf') format('truetype');
15
+ font-weight: 100;
16
+ font-style: italic;
17
+ }
18
+
19
+ @font-face {
20
+ font-family: 'Poppins';
21
+ src: url('../font/Poppins-ExtraLight.ttf') format('truetype');
22
+ font-weight: 200;
23
+ font-style: normal;
24
+ }
25
+
26
+ @font-face {
27
+ font-family: 'Poppins';
28
+ src: url('../font/Poppins-ExtraLightItalic.ttf') format('truetype');
29
+ font-weight: 200;
30
+ font-style: italic;
31
+ }
32
+
33
+ @font-face {
34
+ font-family: 'Poppins';
35
+ src: url('../font/Poppins-Light.ttf') format('truetype');
36
+ font-weight: 300;
37
+ font-style: normal;
38
+ }
39
+
40
+ @font-face {
41
+ font-family: 'Poppins';
42
+ src: url('../font/Poppins-LightItalic.ttf') format('truetype');
43
+ font-weight: 300;
44
+ font-style: italic;
45
+ }
46
+
47
+ @font-face {
48
+ font-family: 'Poppins';
7
49
  src: url('../font/Poppins-Regular.ttf') format('truetype');
50
+ font-weight: 400;
51
+ font-style: normal;
8
52
  }
9
53
 
10
- a {
11
- color: var(--app-a-primary) !important;
12
- text-decoration: none;
54
+ @font-face {
55
+ font-family: 'Poppins';
56
+ src: url('../font/Poppins-Italic.ttf') format('truetype');
57
+ font-weight: 400;
58
+ font-style: italic;
59
+ }
60
+
61
+ @font-face {
62
+ font-family: 'Poppins';
63
+ src: url('../font/Poppins-Medium.ttf') format('truetype');
64
+ font-weight: 500;
65
+ font-style: normal;
66
+ }
67
+
68
+ @font-face {
69
+ font-family: 'Poppins';
70
+ src: url('../font/Poppins-MediumItalic.ttf') format('truetype');
71
+ font-weight: 500;
72
+ font-style: italic;
73
+ }
74
+
75
+ @font-face {
76
+ font-family: 'Poppins';
77
+ src: url('../font/Poppins-SemiBold.ttf') format('truetype');
78
+ font-weight: 600;
79
+ font-style: normal;
80
+ }
81
+
82
+ @font-face {
83
+ font-family: 'Poppins';
84
+ src: url('../font/Poppins-SemiBoldItalic.ttf') format('truetype');
85
+ font-weight: 600;
86
+ font-style: italic;
87
+ }
88
+
89
+ @font-face {
90
+ font-family: 'Poppins';
91
+ src: url('../font/Poppins-Bold.ttf') format('truetype');
92
+ font-weight: 700;
93
+ font-style: normal;
94
+ }
95
+
96
+ @font-face {
97
+ font-family: 'Poppins';
98
+ src: url('../font/Poppins-BoldItalic.ttf') format('truetype');
99
+ font-weight: 700;
100
+ font-style: italic;
101
+ }
102
+
103
+ @font-face {
104
+ font-family: 'Poppins';
105
+ src: url('../font/Poppins-ExtraBold.ttf') format('truetype');
106
+ font-weight: 800;
107
+ font-style: normal;
108
+ }
109
+
110
+ @font-face {
111
+ font-family: 'Poppins';
112
+ src: url('../font/Poppins-ExtraBoldItalic.ttf') format('truetype');
113
+ font-weight: 800;
114
+ font-style: italic;
115
+ }
116
+
117
+ @font-face {
118
+ font-family: 'Poppins';
119
+ src: url('../font/Poppins-Black.ttf') format('truetype');
120
+ font-weight: 900;
121
+ font-style: normal;
122
+ }
123
+
124
+ @font-face {
125
+ font-family: 'Poppins';
126
+ src: url('../font/Poppins-BlackItalic.ttf') format('truetype');
127
+ font-weight: 900;
128
+ font-style: italic;
13
129
  }
14
130
 
15
131
  body {
16
- font-family: 'Poppins-Regular', sans-serif !important;
17
- font-weight: 500 !important;
132
+ font-family: 'Poppins', sans-serif !important;
133
+ font-weight: 400 !important;
134
+ -webkit-font-smoothing: antialiased;
135
+ -moz-osx-font-smoothing: grayscale;
136
+ text-rendering: optimizeLegibility;
137
+ font-feature-settings: "kern" 1;
138
+ font-kerning: normal;
18
139
  }
19
140
 
20
141
  h1, h2, h3, h4, h5, h6 {
21
- font-family: 'Poppins-Regular', serif !important;
142
+ font-family: 'Poppins', sans-serif !important;
22
143
  font-weight: 600 !important;
23
144
  }
24
145