iolanta 2.1.7__tar.gz → 2.1.8__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 (149) hide show
  1. {iolanta-2.1.7 → iolanta-2.1.8}/PKG-INFO +1 -1
  2. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/cli/main.py +1 -1
  3. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/data/context.yaml +6 -6
  4. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/data/iolanta.yaml +1 -1
  5. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/data/textual-browser.yaml +6 -20
  6. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/declension/data/declension.yamlld +6 -6
  7. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/facet.py +4 -0
  8. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/mkdocs_material_insiders_markdown/__init__.py +3 -1
  9. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/mkdocs_material_insiders_markdown/data/mkdocs_material_insiders_markdown.yamlld +1 -1
  10. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_browser/location.py +3 -1
  11. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_browser/page_switcher.py +10 -0
  12. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_class/facets.py +3 -0
  13. iolanta-2.1.8/iolanta/facets/textual_class/textual-class.yamlld +25 -0
  14. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_default/facets.py +50 -15
  15. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_default/sparql/inverse-properties.sparql +1 -1
  16. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_default/sparql/properties.sparql +2 -2
  17. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_default/widgets.py +14 -6
  18. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/iolanta.py +0 -38
  19. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/labeled_triple_set/data/labeled_triple_set.yamlld +6 -6
  20. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/mcp/cli.py +3 -2
  21. {iolanta-2.1.7 → iolanta-2.1.8}/pyproject.toml +1 -1
  22. {iolanta-2.1.7 → iolanta-2.1.8}/README.md +0 -0
  23. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/__init__.py +0 -0
  24. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/base_plugin.py +0 -0
  25. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/cli/__init__.py +0 -0
  26. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/cli/formatters/__init__.py +0 -0
  27. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/cli/formatters/choose.py +0 -0
  28. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/cli/formatters/csv.py +0 -0
  29. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/cli/formatters/json.py +0 -0
  30. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/cli/formatters/pretty.py +0 -0
  31. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/cli/models.py +0 -0
  32. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/cli/pretty_print.py +0 -0
  33. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/context.py +0 -0
  34. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/conversions.py +0 -0
  35. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/data/graph-triples.yamlld +0 -0
  36. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/declension/__init__.py +0 -0
  37. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/declension/facet.py +0 -0
  38. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/declension/sparql/declension.sparql +0 -0
  39. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/ensure_is_context.py +0 -0
  40. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/entry_points.py +0 -0
  41. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/errors.py +0 -0
  42. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/__init__.py +0 -0
  43. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/cli/__init__.py +0 -0
  44. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/cli/base.py +0 -0
  45. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/cli/default.py +0 -0
  46. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/cli/record.py +0 -0
  47. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/cli/sparql/link.sparql +0 -0
  48. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/cli/sparql/record.sparql +0 -0
  49. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/errors.py +0 -0
  50. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/foaf_person_title/__init__.py +0 -0
  51. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/foaf_person_title/facet.py +0 -0
  52. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/foaf_person_title/sparql/names.sparql +0 -0
  53. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/generic/__init__.py +0 -0
  54. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/generic/bool_literal.py +0 -0
  55. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/generic/date_literal.py +0 -0
  56. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/generic/default.py +0 -0
  57. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/generic/sparql/default.sparql +0 -0
  58. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/html/__init__.py +0 -0
  59. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/html/base.py +0 -0
  60. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/html/code_literal.py +0 -0
  61. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/html/default.py +0 -0
  62. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/icon.py +0 -0
  63. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/locator/sparql/get-query-to-facet.sparql +0 -0
  64. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/locator.py +0 -0
  65. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/mkdocs_material_insiders_markdown/facet.py +0 -0
  66. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/mkdocs_material_insiders_markdown/templates/datatype.jinja2.md +0 -0
  67. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/page_title.py +0 -0
  68. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/qname.py +0 -0
  69. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_browser/__init__.py +0 -0
  70. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_browser/app.py +0 -0
  71. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_browser/facet.py +0 -0
  72. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_browser/history.py +0 -0
  73. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_browser/home.py +0 -0
  74. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_browser/models.py +0 -0
  75. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_browser/page.py +0 -0
  76. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_class/__init__.py +0 -0
  77. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_class/sparql/instances.sparql +0 -0
  78. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_default/__init__.py +0 -0
  79. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_default/sparql/label.sparql +0 -0
  80. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_default/sparql/nodes-for-property.sparql +0 -0
  81. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_default/tcss/default.tcss +0 -0
  82. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_default/templates/default.md +0 -0
  83. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_default/triple_uri_ref.py +0 -0
  84. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_graph/__init__.py +0 -0
  85. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_graph/facets.py +0 -0
  86. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_graph/sparql/triples.sparql +0 -0
  87. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_graph_triples.py +0 -0
  88. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_graphs/__init__.py +0 -0
  89. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_graphs/data/textual_graphs.yamlld +0 -0
  90. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_graphs/facets.py +0 -0
  91. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_graphs/sparql/graphs.sparql +0 -0
  92. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_link/__init__.py +0 -0
  93. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_link/facet.py +0 -0
  94. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_nanopublication/__init__.py +0 -0
  95. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_nanopublication/facet.py +0 -0
  96. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_nanopublication/models.py +0 -0
  97. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_nanopublication/nanopublication_widget.py +0 -0
  98. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_nanopublication/term_list_widget.py +0 -0
  99. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_nanopublication/term_widget.py +0 -0
  100. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_no_facet_found.py +0 -0
  101. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_ontology/__init__.py +0 -0
  102. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_ontology/facets.py +0 -0
  103. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_ontology/sparql/terms.sparql +0 -0
  104. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_ontology/sparql/visualization-vocab.sparql +0 -0
  105. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_property_pairs_table.py +0 -0
  106. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_provenance/__init__.py +0 -0
  107. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_provenance/facets.py +0 -0
  108. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_provenance/sparql/graphs.sparql +0 -0
  109. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/textual_provenance/sparql/triples.sparql +0 -0
  110. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/title/__init__.py +0 -0
  111. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/title/facets.py +0 -0
  112. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/title/sparql/title.sparql +0 -0
  113. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/wikibase_statement_title/__init__.py +0 -0
  114. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/wikibase_statement_title/facets.py +0 -0
  115. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/facets/wikibase_statement_title/sparql/statement-title.sparql +0 -0
  116. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/labeled_triple_set/__init__.py +0 -0
  117. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/labeled_triple_set/labeled_triple_set.py +0 -0
  118. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/labeled_triple_set/sparql/triples.sparql +0 -0
  119. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/mcp/__init__.py +0 -0
  120. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/mcp/prompts/nanopublication_assertion_authoring_rules.md +0 -0
  121. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/mcp/prompts/rules.md +0 -0
  122. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/mermaid/__init__.py +0 -0
  123. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/mermaid/facet.py +0 -0
  124. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/mermaid/mermaid.yamlld +0 -0
  125. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/mermaid/models.py +0 -0
  126. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/mermaid/sparql/ask-has-triples.sparql +0 -0
  127. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/mermaid/sparql/graph.sparql +0 -0
  128. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/mermaid/sparql/subgraphs.sparql +0 -0
  129. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/models.py +0 -0
  130. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/namespaces.py +0 -0
  131. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/node_to_qname.py +0 -0
  132. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/parse_quads.py +0 -0
  133. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/plugin.py +0 -0
  134. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/query_result.py +0 -0
  135. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/reformat_blank_nodes.py +0 -0
  136. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/resolvers/__init__.py +0 -0
  137. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/resolvers/base.py +0 -0
  138. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/resolvers/dispatch.py +0 -0
  139. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/resolvers/pypi.py +0 -0
  140. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/resolvers/python_import.py +0 -0
  141. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/sparqlspace/__init__.py +0 -0
  142. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/sparqlspace/cli.py +0 -0
  143. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/sparqlspace/inference/wikidata-prop-label.sparql +0 -0
  144. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/sparqlspace/inference/wikidata-statement-label.sparql +0 -0
  145. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/sparqlspace/processor.py +0 -0
  146. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/sparqlspace/sparqlspace.py +0 -0
  147. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/widgets/__init__.py +0 -0
  148. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/widgets/description.py +0 -0
  149. {iolanta-2.1.7 → iolanta-2.1.8}/iolanta/widgets/mixin.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: iolanta
3
- Version: 2.1.7
3
+ Version: 2.1.8
4
4
  Summary: Semantic Web browser
5
5
  License: MIT
6
6
  Author: Anatoly Scherbakov
@@ -11,7 +11,7 @@ from rdflib import Literal, URIRef
11
11
  from rich.console import Console
12
12
  from rich.markdown import Markdown
13
13
  from rich.table import Table
14
- from typer import Argument, Exit, Option, Typer, Context
14
+ from typer import Argument, Context, Exit, Option, Typer
15
15
  from yarl import URL
16
16
 
17
17
  from iolanta.cli.models import LogLevel
@@ -1,13 +1,13 @@
1
1
  "@context":
2
2
  rdfs: "http://www.w3.org/2000/01/rdf-schema#"
3
- rdf: https://www.w3.org/1999/02/22-rdf-syntax-ns#
3
+ rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns#
4
4
  iolanta: https://iolanta.tech/
5
- owl: https://www.w3.org/2002/07/owl#
5
+ owl: http://www.w3.org/2002/07/owl#
6
6
  schema: https://schema.org/
7
- xsd: https://www.w3.org/2001/XMLSchema#
8
- skos: https://www.w3.org/2004/02/skos/core#
9
- foaf: https://xmlns.com/foaf/0.1/
10
- vann: https://purl.org/vocab/vann/
7
+ xsd: http://www.w3.org/2001/XMLSchema#
8
+ skos: http://www.w3.org/2004/02/skos/core#
9
+ foaf: http://xmlns.com/foaf/0.1/
10
+ vann: http://purl.org/vocab/vann/
11
11
 
12
12
  "@vocab": "local:"
13
13
  "@base": "local:"
@@ -5,7 +5,7 @@
5
5
  owl: https://www.w3.org/2002/07/owl#
6
6
  iolanta: https://iolanta.tech/
7
7
  rdfs: "http://www.w3.org/2000/01/rdf-schema#"
8
- rdf: https://www.w3.org/1999/02/22-rdf-syntax-ns#
8
+ rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns#
9
9
 
10
10
  $included:
11
11
  - $id: iolanta:Facet
@@ -1,14 +1,14 @@
1
1
  "@context":
2
2
  "@import": https://json-ld.org/contexts/dollar-convenience.jsonld
3
- vann: https://purl.org/vocab/vann/
4
- foaf: https://xmlns.com/foaf/0.1/
5
- owl: https://www.w3.org/2002/07/owl#
3
+ vann: http://purl.org/vocab/vann/
4
+ foaf: http://xmlns.com/foaf/0.1/
5
+ owl: http://www.w3.org/2002/07/owl#
6
6
  iolanta: https://iolanta.tech/
7
7
  rdfs: "http://www.w3.org/2000/01/rdf-schema#"
8
- rdf: https://www.w3.org/1999/02/22-rdf-syntax-ns#
8
+ rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns#
9
9
  np: https://www.nanopub.org/nschema#
10
- dcterms: https://purl.org/dc/terms/
11
- xsd: https://www.w3.org/2001/XMLSchema#
10
+ dcterms: http://purl.org/dc/terms/
11
+ xsd: http://www.w3.org/2001/XMLSchema#
12
12
 
13
13
  iolanta:outputs:
14
14
  "@type": "@id"
@@ -88,15 +88,6 @@
88
88
  iolanta:hasDefaultFacet:
89
89
  $id: pkg:pypi/iolanta#textual-link
90
90
 
91
- - $id: rdfs:Class
92
- iolanta:hasInstanceFacet:
93
- $id: pkg:pypi/iolanta#textual-class
94
- $: Instances
95
- →: https://iolanta.tech/cli/textual
96
- ⪯:
97
- - pkg:pypi/iolanta#textual-browser
98
- - pkg:pypi/iolanta#textual-inverse-properties
99
-
100
91
  - $id: owl:Ontology
101
92
  iolanta:hasInstanceFacet:
102
93
  $id: pkg:pypi/iolanta#textual-ontology
@@ -119,10 +110,5 @@
119
110
  →: https://iolanta.tech/cli/textual
120
111
  ↦: ASK WHERE { ?subject $this ?object }
121
112
 
122
- - $id: pkg:pypi/iolanta#textual-class
123
- ↦:
124
- - ASK WHERE { ?instance a $this }
125
- - ASK WHERE { $this rdfs:subClassOf ?superclass }
126
-
127
113
  - $id: https://iolanta.tech/cli/textual
128
114
  iolanta:when-no-facet-found: pkg:pypi/iolanta#textual-no-facet-found
@@ -1,13 +1,13 @@
1
1
  "@context":
2
2
  "@import": https://json-ld.org/contexts/dollar-convenience.jsonld
3
- vann: https://purl.org/vocab/vann/
4
- foaf: https://xmlns.com/foaf/0.1/
5
- owl: https://www.w3.org/2002/07/owl#
3
+ vann: http://purl.org/vocab/vann/
4
+ foaf: http://xmlns.com/foaf/0.1/
5
+ owl: http://www.w3.org/2002/07/owl#
6
6
  iolanta: https://iolanta.tech/
7
7
  rdfs: "http://www.w3.org/2000/01/rdf-schema#"
8
- rdf: https://www.w3.org/1999/02/22-rdf-syntax-ns#
9
- dcterms: https://purl.org/dc/terms/
10
- dcam: https://purl.org/dc/dcam/
8
+ rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns#
9
+ dcterms: http://purl.org/dc/terms/
10
+ dcam: http://purl.org/dc/dcam/
11
11
 
12
12
  iolanta:outputs:
13
13
  "@type": "@id"
@@ -20,6 +20,10 @@ class Facet(Generic[FacetOutput]):
20
20
  iolanta: 'iolanta.Iolanta' = field(repr=False)
21
21
  as_datatype: Optional[NotLiteralNode] = None
22
22
 
23
+ def __post_init__(self):
24
+ if type(self.this) == str:
25
+ raise ValueError(f'Facet {self.__class__.__name__} received a string as this: {self.this}')
26
+
23
27
  @property
24
28
  def stored_queries_path(self) -> Path:
25
29
  """Construct directory for stored queries for this facet."""
@@ -1,4 +1,6 @@
1
- from iolanta.facets.mkdocs_material_insiders_markdown.facet import MkDocsMaterialInsidersMarkdownFacet
1
+ from iolanta.facets.mkdocs_material_insiders_markdown.facet import (
2
+ MkDocsMaterialInsidersMarkdownFacet,
3
+ )
2
4
 
3
5
  __all__ = ['MkDocsMaterialInsidersMarkdownFacet']
4
6
 
@@ -1,7 +1,7 @@
1
1
  "@context":
2
2
  "@import": https://json-ld.org/contexts/dollar-convenience.jsonld
3
3
  rdfs: "http://www.w3.org/2000/01/rdf-schema#"
4
- rdf: https://www.w3.org/1999/02/22-rdf-syntax-ns#
4
+ rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns#
5
5
  iolanta: https://iolanta.tech/
6
6
 
7
7
  $: rdfs:label
@@ -2,11 +2,13 @@ from dataclasses import dataclass
2
2
 
3
3
  from rdflib import URIRef
4
4
 
5
+ from iolanta.models import NotLiteralNode
6
+
5
7
 
6
8
  @dataclass
7
9
  class Location:
8
10
  """Unique ID and IRI associated with it."""
9
11
 
10
12
  page_id: str
11
- url: str
13
+ url: NotLiteralNode
12
14
  facet_iri: URIRef | None = None
@@ -217,6 +217,9 @@ class PageSwitcher(IolantaWidgetMixin, ContentSwitcher): # noqa: WPS214
217
217
 
218
218
  def action_reload(self):
219
219
  """Reset Iolanta graph and re-render current view."""
220
+ if self.history.current is None:
221
+ return
222
+
220
223
  self.iolanta.reset()
221
224
 
222
225
  self.run_worker(
@@ -271,6 +274,13 @@ class PageSwitcher(IolantaWidgetMixin, ContentSwitcher): # noqa: WPS214
271
274
  facet_iri: str | None = None,
272
275
  ):
273
276
  """Go to an IRI."""
277
+ # Convert string to URIRef if needed.
278
+ # This happens when called via Textual action strings (from keyboard bindings
279
+ # in page.py line 24), which serialize URIRefs to strings in f-strings.
280
+ # Direct calls (like line 77) pass URIRef objects directly.
281
+ if isinstance(this, str):
282
+ this = URIRef(this)
283
+
274
284
  self.run_worker(
275
285
  functools.partial(
276
286
  self.render_iri,
@@ -1,5 +1,6 @@
1
1
  import functools
2
2
  import itertools
3
+ from pathlib import Path
3
4
  from typing import ClassVar, Iterable
4
5
 
5
6
  import funcy
@@ -186,6 +187,8 @@ class InstancesBody(Vertical):
186
187
  class Class(Facet[Widget]):
187
188
  """Render instances of a class."""
188
189
 
190
+ META = Path(__file__).parent / 'textual-class.yamlld'
191
+
189
192
  def stream_instances(self) -> Iterable[NotLiteralNode]:
190
193
  """
191
194
  Query and stream class instances lazily.
@@ -0,0 +1,25 @@
1
+ "@context":
2
+ "@import": https://json-ld.org/contexts/dollar-convenience.jsonld
3
+ iolanta: https://iolanta.tech/
4
+ rdfs: "http://www.w3.org/2000/01/rdf-schema#"
5
+ rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns#
6
+
7
+ $: rdfs:label
8
+ →:
9
+ "@type": "@id"
10
+ "@id": iolanta:outputs
11
+ ⪯:
12
+ "@type": "@id"
13
+ "@id": iolanta:is-preferred-over
14
+ ↦: iolanta:matches
15
+
16
+ $id: pkg:pypi/iolanta#textual-class
17
+
18
+ $: Instances
19
+ →: https://iolanta.tech/cli/textual
20
+
21
+ ⪯:
22
+ - pkg:pypi/iolanta#textual-browser
23
+ - pkg:pypi/iolanta#textual-inverse-properties
24
+
25
+ ↦: ASK WHERE { ?instance a $this }
@@ -4,7 +4,7 @@ from xml.dom import minidom # noqa: S408
4
4
  import funcy
5
5
  from rdflib.term import Literal, Node
6
6
  from rich.syntax import Syntax
7
- from textual.containers import VerticalScroll
7
+ from textual.containers import Vertical, VerticalScroll
8
8
  from textual.widget import Widget
9
9
  from textual.widgets import Static
10
10
 
@@ -22,17 +22,28 @@ from iolanta.models import NotLiteralNode
22
22
  from iolanta.namespaces import DC, RDFS, SDO
23
23
 
24
24
 
25
+ class Description(Static):
26
+ """Static widget with padding for descriptions."""
27
+
28
+ DEFAULT_CSS = """
29
+ Description {
30
+ padding: 1;
31
+ }
32
+ """
33
+
34
+
25
35
  class TextualDefaultFacet(Facet[Widget]): # noqa: WPS214
26
36
  """Default rendering engine."""
27
37
 
28
38
  query_file_name = 'properties.sparql'
39
+ properties_on_the_right = False
29
40
 
30
41
  @functools.cached_property
31
42
  def grouped_properties(self) -> dict[NotLiteralNode, list[Node]]:
32
43
  """Properties of current node & their values."""
33
44
  property_rows = self.stored_query(
34
45
  self.query_file_name,
35
- iri=self.this,
46
+ this=self.this,
36
47
  )
37
48
 
38
49
  property_pairs = [
@@ -75,10 +86,18 @@ class TextualDefaultFacet(Facet[Widget]): # noqa: WPS214
75
86
  for property_value in property_values
76
87
  ]
77
88
 
78
- yield PropertyRow(
79
- property_name,
80
- PropertyValues(*property_values),
81
- )
89
+ if self.properties_on_the_right:
90
+ # Property name on the right (last column), values on the left (first column)
91
+ yield PropertyRow(
92
+ PropertyValues(*property_values),
93
+ property_name,
94
+ )
95
+ else:
96
+ # Property name on the left (first column), values on the right (last column)
97
+ yield PropertyRow(
98
+ property_name,
99
+ PropertyValues(*property_values),
100
+ )
82
101
 
83
102
  @functools.cached_property
84
103
  def description(self) -> str | Syntax | None:
@@ -134,22 +153,38 @@ class TextualDefaultFacet(Facet[Widget]): # noqa: WPS214
134
153
 
135
154
  def show(self) -> Widget:
136
155
  """Render the content."""
137
- return VerticalScroll(
138
- PageTitle(self.this),
139
- Static(self.description or ''),
140
- self.properties,
141
- )
142
156
 
157
+ widgets = [PageTitle(self.this)]
158
+
159
+ if self.description:
160
+ widgets.append(Description(self.description))
161
+
162
+ widgets.append(self.properties)
163
+
164
+ return VerticalScroll(*widgets)
165
+
166
+
167
+ class PageFooter(PageTitle):
168
+ """Page footer."""
169
+
170
+ DEFAULT_CSS = """
171
+ PageFooter {
172
+ dock: bottom;
173
+ background: darkmagenta;
174
+ }
175
+ """
143
176
 
144
177
  class InverseProperties(TextualDefaultFacet):
145
178
  """Inverse properties view."""
146
179
 
147
180
  query_file_name = 'inverse-properties.sparql'
181
+ properties_on_the_right = True
148
182
 
149
183
  def show(self) -> Widget:
150
184
  """Render the content."""
151
- return VerticalScroll(
152
- PageTitle(self.this, extra='[i]& its inverse RDF properties[/i]'),
153
- Static(self.description or ''),
154
- self.properties,
185
+ return Vertical(
186
+ VerticalScroll(
187
+ self.properties,
188
+ ),
189
+ PageFooter(self.this, extra='[i]& its inverse RDF properties[/i]'),
155
190
  )
@@ -1,3 +1,3 @@
1
1
  SELECT ?object ?property WHERE {
2
- ?object ?property $iri .
2
+ ?object ?property $this .
3
3
  }
@@ -1,9 +1,9 @@
1
1
  SELECT ?property ?object WHERE {
2
- $iri ?property ?object .
2
+ $this ?property ?object .
3
3
 
4
4
  # Exclude non-informative tautologies.
5
5
  FILTER (!(
6
- ?object = $iri
6
+ ?object = $this
7
7
  && ?property IN (
8
8
  owl:sameAs,
9
9
  owl:equivalentClass,
@@ -25,6 +25,7 @@ class PropertyName(Widget, can_focus=True, inherit_bindings=False):
25
25
  width: 15%;
26
26
  height: auto;
27
27
  margin-right: 1;
28
+ text-style: bold;
28
29
  }
29
30
 
30
31
  PropertyName:hover {
@@ -60,7 +61,8 @@ class PropertyName(Widget, can_focus=True, inherit_bindings=False):
60
61
 
61
62
  def render_title(self):
62
63
  """Render title in a separate thread."""
63
- return self.app.iolanta.render(self.iri, DATATYPES.title)
64
+ title = self.app.iolanta.render(self.iri, DATATYPES.title)
65
+ return f'⤚{title}→'
64
66
 
65
67
  def render(self) -> RenderResult:
66
68
  """Render node title."""
@@ -147,6 +149,13 @@ class PropertyValue(Widget, can_focus=True, inherit_bindings=False):
147
149
  """Return the property IRI for compatibility."""
148
150
  return self.property_value
149
151
 
152
+ def render_title(self):
153
+ """Render title in a separate thread."""
154
+ return self.app.iolanta.render(
155
+ self.iri,
156
+ as_datatype=DATATYPES.title,
157
+ )
158
+
150
159
  def on_worker_state_changed(self, event: Worker.StateChanged):
151
160
  """Show the title after it has been rendered."""
152
161
  match event.state:
@@ -191,7 +200,9 @@ class PropertiesContainer(Vertical):
191
200
  DEFAULT_CSS = """
192
201
  PropertiesContainer {
193
202
  height: auto;
194
- }"""
203
+ padding: 1;
204
+ }
205
+ """
195
206
 
196
207
  def render_all_properties(self):
197
208
  """Render all property names & values."""
@@ -199,10 +210,7 @@ class PropertiesContainer(Vertical):
199
210
 
200
211
  widget: PropertyName | PropertyValue
201
212
  for widget in widgets:
202
- widget.renderable = self.app.iolanta.render(
203
- widget.iri,
204
- as_datatype=DATATYPES.title,
205
- )
213
+ widget.renderable = widget.render_title()
206
214
 
207
215
  def on_mount(self):
208
216
  """Initiate rendering in the background."""
@@ -308,44 +308,6 @@ class Iolanta: # noqa: WPS214
308
308
  error=err,
309
309
  ) from err
310
310
 
311
- def render_all(
312
- self,
313
- node: Node,
314
- as_datatype: NotLiteralNode,
315
- ) -> Iterable[Any]:
316
- """Find all possible Iolanta facets for a node and render them."""
317
- choices = list(
318
- FacetFinder(
319
- iolanta=self,
320
- node=node,
321
- as_datatype=as_datatype,
322
- ).choices(),
323
- )
324
-
325
- pairs = [
326
- (self.facet_resolver[row['facet']], row['output_datatype'])
327
- for row in choices
328
- ]
329
-
330
- facet_instances = [
331
- facet_class(
332
- this=node,
333
- iolanta=self,
334
- as_datatype=output_datatype,
335
- )
336
- for facet_class, output_datatype in pairs
337
- ]
338
-
339
- for facet in facet_instances:
340
- try:
341
- yield facet.show()
342
- except Exception as err:
343
- raise FacetError(
344
- node=node,
345
- facet_iri=None,
346
- error=err,
347
- ) from err
348
-
349
311
  def node_as_qname(self, node: Node):
350
312
  """Render node as a QName if possible."""
351
313
  qname = node_to_qname(node, self.graph)
@@ -1,13 +1,13 @@
1
1
  "@context":
2
2
  "@import": https://json-ld.org/contexts/dollar-convenience.jsonld
3
- vann: https://purl.org/vocab/vann/
4
- foaf: https://xmlns.com/foaf/0.1/
5
- owl: https://www.w3.org/2002/07/owl#
3
+ vann: http://purl.org/vocab/vann/
4
+ foaf: http://xmlns.com/foaf/0.1/
5
+ owl: http://www.w3.org/2002/07/owl#
6
6
  iolanta: https://iolanta.tech/
7
7
  rdfs: "http://www.w3.org/2000/01/rdf-schema#"
8
- rdf: https://www.w3.org/1999/02/22-rdf-syntax-ns#
9
- dcterms: https://purl.org/dc/terms/
10
- dcam: https://purl.org/dc/dcam/
8
+ rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns#
9
+ dcterms: http://purl.org/dc/terms/
10
+ dcam: http://purl.org/dc/dcam/
11
11
 
12
12
  iolanta:outputs:
13
13
  "@type": "@id"
@@ -1,6 +1,7 @@
1
+ from pathlib import Path
1
2
  from typing import Annotated
3
+
2
4
  from fastmcp import FastMCP
3
- from pathlib import Path
4
5
 
5
6
  from iolanta.cli.main import render_and_return
6
7
 
@@ -10,7 +11,7 @@ mcp = FastMCP("Iolanta MCP Server")
10
11
  @mcp.tool()
11
12
  def render_uri(
12
13
  uri: Annotated[str, 'URL, or file system path, to render'],
13
- as_format: Annotated[str, 'Format to render as. Examples: `labeled-triple-set`, `mermaid`']
14
+ as_format: Annotated[str, 'Format to render as. Examples: `labeled-triple-set`, `mermaid`'],
14
15
  ) -> str:
15
16
  """Render a URI."""
16
17
  result = render_and_return(uri, as_format)
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "iolanta"
3
- version = "2.1.7"
3
+ version = "2.1.8"
4
4
  description = "Semantic Web browser"
5
5
  authors = ["Anatoly Scherbakov <altaisoft@gmail.com>"]
6
6
  license = "MIT"
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes